/* ==========================================================
   PalBuddies – mobile first, Apple-like
   Farben aus der Visitenkarte
   ========================================================== */
:root {
  --yellow: #fbb900;
  --orange: #ec6603;
  --red:    #e20411;
  --pink:   #e5007e;
  --purple: #49277e;
  --violet: #8a24e0;

  --ink: #1d1d1f;          /* Apple-Textschwarz */
  --ink-2: #6e6e73;        /* Apple-Sekundärtext */
  --glass: rgba(255, 255, 255, .78);
  --glass-border: rgba(255, 255, 255, .6);
  --radius: 22px;
  --shadow: 0 10px 30px -12px rgba(40, 10, 60, .45), 0 2px 6px rgba(40, 10, 60, .12);
  --brand-gradient: linear-gradient(100deg, var(--yellow), var(--orange) 25%, var(--red) 50%, var(--pink) 72%, var(--violet));

  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  /* kein Gummiband-Effekt am Seitenende – sonst blitzt die Grundfarbe durch */
  overscroll-behavior-y: none;
}

body {
  margin: 0;
  min-height: 100svh;
  font-family: var(--font);
  color: var(--ink);
  /* unterstes Farbband – falls doch mal Fläche unter dem Hintergrund sichtbar wird */
  background: var(--purple);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }

/* ---------- Wellen-Hintergrund ---------- */
.waves {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  /* feste Höhe (größter Viewport): ändert sich nicht, wenn die Browserleiste
     beim Scrollen ein-/ausfährt – so springen die Wellen nicht mit */
  height: 100vh;
  height: 100lvh;
  z-index: -1;
  overflow: hidden;
  background: var(--yellow);
}

.band {
  position: absolute;
  top: var(--top);
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--c);
}

/* Wellenkante über jedem Farbband – per Maske, damit die Farbe aus --c kommt */
.band::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: 100%;
  margin-bottom: -1px;
  width: calc(100% + 720px);
  height: calc(90px * var(--amp, 1));
  background: var(--c);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 720 100' preserveAspectRatio='none'%3E%3Cpath d='M0 50C90 0 270 0 360 50S630 100 720 50V100H0Z'/%3E%3C/svg%3E") 0 0 / 720px 100% repeat-x;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 720 100' preserveAspectRatio='none'%3E%3Cpath d='M0 50C90 0 270 0 360 50S630 100 720 50V100H0Z'/%3E%3C/svg%3E") 0 0 / 720px 100% repeat-x;
  animation: drift var(--dur, 30s) linear infinite;
  animation-direction: var(--dir, normal);
  will-change: transform;
}

@keyframes drift {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-720px, 0, 0); }
}

/* ---------- Layout ---------- */
.page {
  flex: 1;
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  padding:
    calc(env(safe-area-inset-top, 0px) + 28px)
    calc(env(safe-area-inset-right, 0px) + 18px)
    24px
    calc(env(safe-area-inset-left, 0px) + 18px);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* ---------- Sprachumschalter (Segmented Control wie in iOS) ---------- */
.lang-switch {
  align-self: flex-end;
  display: inline-flex;
  margin-bottom: -10px;
  padding: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .55);
  box-shadow: 0 0 0 .5px rgba(60, 60, 67, .16), 0 6px 16px -10px rgba(40, 10, 60, .45);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
          backdrop-filter: saturate(180%) blur(20px);
  animation: fade-up .6s .1s ease-out both;
}
.lang-switch button {
  min-width: 44px;
  min-height: 30px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(29, 29, 31, .6);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .04em;
  cursor: pointer;
  touch-action: manipulation;
  transition: background .25s ease, color .25s ease, box-shadow .25s ease;
}
.lang-switch button[aria-pressed="true"] {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 2px 6px rgba(40, 10, 60, .18), 0 0 0 .5px rgba(60, 60, 67, .12);
}
.lang-switch button:focus-visible { outline: 3px solid var(--pink); outline-offset: 1px; }

/* ---------- Hero ---------- */
.hero {
  text-align: center;
  padding: 8px 0 6px;
}

.logo {
  margin: 0 auto;
  max-width: 420px;
  filter: drop-shadow(0 8px 18px rgba(80, 20, 0, .25));
  animation: pop-in .7s var(--ease-spring) both;
}
.logo picture { display: block; }
.logo img { width: 100%; }

.tagline {
  margin: 12px 0 0;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -.01em;
  color: #fff;
  text-shadow: 0 1px 8px rgba(120, 40, 0, .35);
  animation: fade-up .6s .15s ease-out both;
}

/* ---------- Glas-Karten ---------- */
.card,
.link-btn,
.share-btn {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
          backdrop-filter: saturate(180%) blur(20px);
}

.section-title {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.02em;
}

/* ---------- Social Links ---------- */
.links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.link-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 76px;
  padding: 12px 18px 12px 12px;
  text-decoration: none;
  background: rgba(255, 255, 255, .92);
  transition: transform .25s var(--ease-spring), box-shadow .25s ease;
  animation: fade-up .6s ease-out both;
  touch-action: manipulation;
}
.link-btn:nth-child(1) { animation-delay: .2s; }
.link-btn:nth-child(2) { animation-delay: .28s; }

/* Verlaufs-Rand wie auf der Karte */
.link-btn::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 2px;
  background: var(--brand-gradient);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  pointer-events: none;
}

.link-btn:active { transform: scale(.97); }
@media (hover: hover) {
  .link-btn:hover { transform: translateY(-2px); box-shadow: 0 16px 36px -14px rgba(40, 10, 60, .55); }
}
.link-btn:focus-visible,
.share-btn:focus-visible,
.marquee:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 3px;
}

.link-icon {
  flex: none;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #fff;
}
.link-icon svg { width: 30px; height: 30px; }
.link-icon.ig {
  background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285aeb 90%);
}
.link-icon.tt {
  background: #000;
  /* TikTok-typischer Cyan/Rot-Versatz */
  filter: drop-shadow(0 0 0 transparent);
}
.link-icon.tt svg { filter: drop-shadow(-1.5px -1px 0 #25f4ee) drop-shadow(1.5px 1px 0 #fe2c55); }

.link-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.link-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-2);
}
.link-handle {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -.02em;
}

.chev {
  flex: none;
  width: 20px;
  height: 20px;
  color: #c7c7cc;
}

/* ---------- Countdown ---------- */
.countdown {
  padding: 18px 20px 20px;
  text-align: center;
  animation: fade-up .6s .32s ease-out both;
}
.countdown:empty { display: none; }

.eyebrow {
  margin: 0 0 4px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  background: var(--brand-gradient);
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
}
.cd-title {
  margin: 0;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -.03em;
}
.cd-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 14px 0 12px;
}
.cd-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 0 8px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .7);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .04);
}
.cd-num {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.cd-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-2);
}
.cd-sub,
.cd-where {
  margin: 8px 0 0;
  font-size: 15px;
  color: var(--ink-2);
}
.cd-where { color: var(--ink); font-weight: 600; }

.progress {
  height: 8px;
  margin: 14px 0 4px;
  border-radius: 4px;
  background: rgba(0, 0, 0, .08);
  overflow: hidden;
}
.progress-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--brand-gradient);
  transition: width .6s ease;
}

.today {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .7);
  text-align: left;
}
.today-title {
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2);
}

/* ---------- Route ---------- */
.route {
  padding: 20px 16px 10px;
  animation: fade-up .6s .4s ease-out both;
}
.route .section-title { padding: 0 4px 12px; }

.route-map svg {
  display: block;
  width: 100%;
  height: auto;
}
.sea { fill: rgba(73, 39, 126, .1); }
.country {
  fill: rgba(255, 255, 255, .6);
  stroke: rgba(73, 39, 126, .25);
  stroke-width: .8;
  stroke-linejoin: round;
}
.country.visited {
  fill: #fff;
  stroke: rgba(229, 0, 126, .35);
}
.country-label {
  font: 700 10px var(--font);
  letter-spacing: .25em;
  fill: rgba(73, 39, 126, .35);
}
.pin-dot {
  fill: #fff;
  stroke: var(--purple);
  stroke-width: 3;
}
.pin.past .pin-dot { fill: var(--pink); stroke: #fff; }
.pin.now .pin-dot { fill: var(--red); stroke: #fff; }
.pin-pulse {
  fill: var(--red);
  opacity: .5;
  transform-box: fill-box;
  transform-origin: center;
  animation: pulse 1.8s ease-out infinite;
}
@keyframes pulse {
  to { transform: scale(2.6); opacity: 0; }
}
.pin-label {
  font: 600 13px var(--font);
  fill: var(--ink);
  paint-order: stroke;
  stroke: rgba(255, 255, 255, .85);
  stroke-width: 4px;
  stroke-linejoin: round;
}

/* Zeitplan */
.timeline {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
}
.stop {
  position: relative;
  padding-left: 22px;
}
/* Linie + Punkt links */
.stop::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: rgba(73, 39, 126, .15);
}
.stop:first-child::before { top: 30px; }
.stop:last-child::before { bottom: calc(100% - 30px); }
.stop::after {
  content: "";
  position: absolute;
  left: 2px;
  top: 25px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid rgba(73, 39, 126, .35);
}
.stop.past::after { background: var(--pink); border-color: var(--pink); }
.stop.now::after {
  background: var(--red);
  border-color: #fff;
  box-shadow: 0 0 0 3px rgba(226, 4, 17, .3);
}

.country-group summary,
.stop summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 60px;
  padding: 10px 8px;
  border-radius: 14px;
  list-style: none;
  cursor: pointer;
  touch-action: manipulation;
  transition: background .2s ease;
}
.country-group summary::-webkit-details-marker,
.stop summary::-webkit-details-marker { display: none; }
.country-group summary:active,
.stop summary:active { background: rgba(0, 0, 0, .05); }
.country-group summary:focus-visible,
.stop summary:focus-visible { outline: 3px solid var(--pink); outline-offset: 0; }

/* Länder-Gruppen (erst aufklappen, dann Städte) */
.country-group + .country-group { border-top: 1px solid rgba(73, 39, 126, .1); }
.country-group > details > summary { min-height: 68px; }
.group-flag { font-size: 34px; line-height: 1; }
.group-name {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -.02em;
}
.group-cities {
  font-size: 13px;
  color: var(--ink-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.country-group.past .group-name,
.country-group.past .group-flag { opacity: .55; }
.country-group > details[open] > summary .stop-chev { transform: rotate(225deg) translate(-2px, -1px); }
.timeline-inner {
  list-style: none;
  margin: 0 0 8px;
  padding: 0 0 0 6px;
}
.country-group > details[open] > .timeline-inner { animation: fade-up .3s ease-out; }

.stop-flag { font-size: 28px; line-height: 1; }
.stop-head {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.stop-name {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -.01em;
}
.stop-dates {
  font-size: 14px;
  color: var(--ink-2);
}
.stop.past .stop-name,
.stop.past .stop-flag { opacity: .55; }

.badge {
  flex: none;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}
.badge.now { background: var(--red); color: #fff; }
.badge.past { background: rgba(229, 0, 126, .12); color: var(--pink); }

.stop-chev {
  flex: none;
  width: 9px;
  height: 9px;
  margin-right: 4px;
  border-right: 2.4px solid #c7c7cc;
  border-bottom: 2.4px solid #c7c7cc;
  transform: rotate(45deg) translateY(-3px);
  transition: transform .25s var(--ease-spring);
}
.stop > details[open] > summary .stop-chev { transform: rotate(225deg) translate(-2px, -1px); }

.stop-body { padding: 0 8px 14px 48px; }
.stop details[open] .stop-body { animation: fade-up .3s ease-out; }
.stop-travel {
  margin: 0 0 8px;
  font-size: 14px;
  color: var(--ink-2);
}
.plan-empty {
  margin: 0;
  font-size: 14px;
  color: var(--ink-2);
  font-style: italic;
}

.plan-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 15px;
}
.plan-day {
  margin-top: 6px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--pink);
}
.plan-day:first-child { margin-top: 0; }
.plan-list li:not(.plan-day) {
  display: flex;
  gap: 10px;
}
.plan-time {
  flex: none;
  min-width: 42px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.plan-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.plan-info {
  margin-top: 2px;
  font-size: 13px;
  line-height: 1.4;
  color: var(--ink-2);
}
.plan-item.open .plan-what { font-style: italic; color: var(--ink-2); }
.plan-item.done { opacity: .5; }
.plan-item.done .plan-what { text-decoration: line-through; }

.stop-tips {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(73, 39, 126, .06);
  font-size: 13px;
  line-height: 1.4;
}
.stop-tips-title {
  margin: 0 0 4px;
  font-weight: 700;
}
.stop-tips ul {
  margin: 0;
  padding-left: 18px;
}
.stop-tips li + li { margin-top: 3px; }

/* ---------- Crew ---------- */
.crew {
  padding: 20px 16px 22px;
  animation: fade-up .6s .48s ease-out both;
}
.crew .section-title { padding: 0 4px 16px; }

.crew-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px 12px;
}

.member {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
}

/* Story-Ring im Kartenverlauf */
.avatar {
  position: relative;
  width: 104px;
  height: 104px;
  border-radius: 50%;
  padding: 4px;
  background: conic-gradient(from 200deg, var(--yellow), var(--orange), var(--red), var(--pink), var(--violet), var(--yellow));
  display: grid;
  place-items: center;
  transition: transform .3s var(--ease-spring);
}
.avatar::before {
  /* Initialen-Fallback */
  content: attr(data-initials);
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  border: 3px solid #fff;
  display: grid;
  place-items: center;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -.03em;
  color: #fff;
  background: linear-gradient(145deg, var(--orange), var(--pink) 60%, var(--purple));
  text-shadow: 0 2px 6px rgba(0, 0, 0, .25);
}
.avatar img {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid #fff;
  background: #fff;
}
.member:active .avatar { transform: scale(.95); }

.member {
  color: inherit;
  text-decoration: none;
  border-radius: 16px;
  padding: 4px 0;
  touch-action: manipulation;
}
.member:focus-visible { outline: 3px solid var(--pink); outline-offset: 2px; }
.member-handle {
  margin-top: -8px;
  font-size: 13px;
  color: var(--ink-2);
}
.member-name {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -.01em;
}

@media (max-width: 340px) {
  .avatar { width: 88px; height: 88px; }
}

/* ---------- Teilen ---------- */
.share-btn {
  align-self: center;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  transition: transform .25s var(--ease-spring);
  animation: fade-up .6s .56s ease-out both;
  touch-action: manipulation;
}
.share-btn svg { width: 20px; height: 20px; }
.share-btn:active { transform: scale(.95); }

/* ---------- Footer ---------- */
.footer {
  padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 18px);
  color: #fff;
  text-align: center;
}

.marquee {
  display: block;
  overflow: hidden;
  padding: 14px 0;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  -webkit-mask: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track {
  display: inline-flex;
  animation: marquee 22s linear infinite;
}
.marquee-track span { padding-right: .3em; }

@keyframes marquee {
  to { transform: translateX(-50%); }
}

.copy {
  margin: 4px 0 0;
  font-size: 12px;
  opacity: .75;
}

/* ---------- Toast (iOS-Style) ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 24px);
  z-index: 100;
  padding: 12px 20px;
  border-radius: 14px;
  background: rgba(29, 29, 31, .86);
  color: #fff;
  font-size: 15px;
  font-weight: 500;
  -webkit-backdrop-filter: blur(20px);
          backdrop-filter: blur(20px);
  transform: translate(-50%, 20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease, transform .35s var(--ease-spring);
}
.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ---------- Einblend-Animationen ---------- */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}
@keyframes pop-in {
  from { opacity: 0; transform: scale(.85) rotate(-3deg); }
  to   { opacity: 1; transform: none; }
}

/* ---------- Gästebuch ---------- */
.guestbook {
  padding: 20px 16px 22px;
  animation: fade-up .6s .52s ease-out both;
}
.guestbook .section-title { padding: 0 4px 14px; }

.gb-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Eingabefelder als gruppierte Liste wie in iOS */
.gb-fields {
  border-radius: 16px;
  background: rgba(255, 255, 255, .88);
  box-shadow: 0 0 0 .5px rgba(60, 60, 67, .16), 0 6px 18px -10px rgba(40, 10, 60, .35);
  overflow: hidden;
  transition: box-shadow .2s ease;
}
.gb-fields:focus-within {
  box-shadow: 0 0 0 2px rgba(229, 0, 126, .55), 0 6px 18px -10px rgba(40, 10, 60, .35);
}
.gb-input {
  display: block;
  width: 100%;
  box-sizing: border-box;
  margin: 0;
  padding: 14px 16px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 17px; /* iOS-Standard, verhindert auch Auto-Zoom */
  line-height: 1.35;
  -webkit-appearance: none;
          appearance: none;
  resize: none;
}
.gb-input:focus { outline: none; }
.gb-input::placeholder { color: rgba(60, 60, 67, .55); }
/* Trennlinie mit Einzug wie in iOS-Listen */
.gb-input + .gb-input {
  background:
    linear-gradient(rgba(60, 60, 67, .18), rgba(60, 60, 67, .18)) 16px 0 / calc(100% - 16px) .5px no-repeat;
}
.gb-input:is(textarea) { min-height: 96px; }

/* Foto-Kacheln */
.gb-photos {
  display: flex;
  gap: 10px;
}
.gb-add,
.gb-preview {
  position: relative;
  flex: none;
  width: 76px;
  height: 76px;
  border-radius: 16px;
}
.gb-add {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  background: rgba(255, 255, 255, .88);
  box-shadow: 0 0 0 .5px rgba(60, 60, 67, .16), 0 6px 18px -10px rgba(40, 10, 60, .35);
  color: var(--pink);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
  transition: transform .25s var(--ease-spring);
}
.gb-add:active { transform: scale(.94); }
.gb-add:focus-within { outline: 3px solid var(--pink); outline-offset: 2px; }
.gb-add svg { width: 26px; height: 26px; }
.gb-add input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.gb-add[hidden] { display: none; }
.gb-preview {
  overflow: hidden;
  box-shadow: 0 6px 18px -10px rgba(40, 10, 60, .45);
  animation: pop-in .35s var(--ease-spring) both;
}
.gb-preview img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gb-preview button {
  position: absolute;
  top: 5px;
  right: 5px;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, .5);
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
  color: #fff;
  cursor: pointer;
}
.gb-preview button svg { width: 10px; height: 10px; }

.gb-hint {
  margin: -4px 4px 0;
  font-size: 13px;
  color: rgba(60, 60, 67, .7);
}

.gb-submit {
  min-height: 52px;
  border: 0;
  border-radius: 16px;
  background: var(--brand-gradient);
  color: #fff;
  font: inherit;
  font-size: 17px;
  font-weight: 600;
  text-shadow: 0 1px 4px rgba(120, 40, 0, .3);
  box-shadow: 0 10px 22px -12px rgba(229, 0, 126, .8);
  cursor: pointer;
  touch-action: manipulation;
  transition: transform .25s var(--ease-spring), opacity .2s;
}
.gb-submit:active { transform: scale(.97); }
.gb-submit:focus-visible { outline: 3px solid var(--purple); outline-offset: 2px; }
.gb-submit:disabled { opacity: .6; cursor: progress; }

/* Einträge */
.gb-list {
  list-style: none;
  margin: 22px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.gb-entry {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 12px;
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, .62);
  box-shadow: 0 0 0 .5px rgba(60, 60, 67, .12);
  animation: fade-up .4s ease-out both;
}
.gb-entry:has(.gb-del) { grid-template-columns: 40px 1fr auto; }
.gb-avatar {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--brand-gradient);
  color: #fff;
  font-size: 17px;
  font-weight: 700;
  text-shadow: 0 1px 4px rgba(120, 40, 0, .3);
}
.gb-body { min-width: 0; }
.gb-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 14px;
  row-gap: 2px;
}
.gb-name {
  font-size: 16px;
  font-weight: 700;
  overflow-wrap: anywhere;
}
.gb-date {
  margin-left: auto;
  font-size: 13px;
  color: rgba(60, 60, 67, .6);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.gb-msg {
  margin: 4px 0 0;
  font-size: 15px;
  line-height: 1.45;
  white-space: pre-line;
  overflow-wrap: anywhere;
}
.gb-tr {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 10px;
  margin-top: 6px;
}
.gb-tr-btn {
  padding: 0;
  border: 0;
  background: none;
  color: var(--pink);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.gb-tr-btn:disabled { opacity: .6; cursor: progress; }
.gb-tr-btn:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; border-radius: 4px; }
.gb-tr-note {
  font-size: 12px;
  color: rgba(60, 60, 67, .6);
}
.gb-tr-note:empty { display: none; }
.gb-empty {
  padding: 6px 4px 0;
  color: rgba(60, 60, 67, .7);
  text-align: center;
}
.gb-images {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 10px;
}
.gb-thumb {
  padding: 0;
  border: 0;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(60, 60, 67, .08);
  aspect-ratio: 1;
  cursor: zoom-in;
  transition: transform .25s var(--ease-spring);
}
.gb-thumb:active { transform: scale(.96); }
.gb-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gb-thumb:focus-visible { outline: 3px solid var(--pink); outline-offset: 2px; }
.gb-del {
  display: grid;
  place-items: center;
  align-self: start;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(226, 4, 17, .12);
  color: var(--red);
  cursor: pointer;
}
.gb-del svg { width: 11px; height: 11px; }

.gb-lightbox {
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-out;
  overflow: hidden;
  /* horizontal wischt JS, vertikal und Zoomen bleiben beim Browser */
  touch-action: pan-y pinch-zoom;
}
.gb-lightbox[open] {
  display: flex;
  align-items: center;
  justify-content: center;
}
.gb-lightbox::backdrop {
  background: rgba(0, 0, 0, .82);
  -webkit-backdrop-filter: blur(10px);
          backdrop-filter: blur(10px);
}
.gb-lightbox img {
  display: block;
  max-width: 94vw;
  max-height: 90vh;
  max-height: 90dvh;
  width: auto;
  height: auto;
  border-radius: 16px;
  transition: transform .2s ease-out;
  user-select: none;
  -webkit-user-drag: none;
}
.lb-nav {
  position: absolute;
  top: 50%;
  translate: 0 -50%;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0 0 4px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .85);
  color: #1c1c1e;
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .3);
}
.lb-nav[hidden] { display: none; }
.lb-prev { left: 12px; }
.lb-next { right: 12px; }
.lb-nav:focus-visible { outline: 3px solid var(--pink); outline-offset: 2px; }
/* Auf dem Handy wird gewischt, die Pfeile stören dort nur */
@media (hover: none) and (pointer: coarse) {
  .lb-nav { display: none; }
}
.lb-count {
  position: absolute;
  bottom: max(14px, env(safe-area-inset-bottom));
  left: 50%;
  translate: -50% 0;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(0, 0, 0, .55);
  color: #fff;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
}
.lb-count[hidden] { display: none; }

/* ---------- Desktop: etwas mehr Luft ---------- */
@media (min-width: 768px) {
  .page { padding-top: 64px; gap: 22px; }
  .crew-grid { grid-template-columns: repeat(4, 1fr); }
  .avatar { width: 92px; height: 92px; }
}

/* ---------- Weniger Bewegung, wenn gewünscht ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .marquee-track { animation: none; }
}

/* Wetter im Countdown (trip.js) */
.cd-weather {
  margin: 1.4em 0 0; /* eine Leerzeile Abstand */
  white-space: pre-line; /* Umbruch zwischen Temperatur und Wetterlage (\n in i18n.js) */
  line-height: 1.4;
  font-size: 15px;
  color: var(--ink-2);
}

/* Reaktionen im Gästebuch */
.gb-react {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.gb-react button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 30px;
  padding: 3px 10px;
  border: 1px solid rgba(0, 0, 0, .1);
  border-radius: 999px;
  background: rgba(0, 0, 0, .03);
  color: var(--ink);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  transition: background-color .15s, border-color .15s, transform .1s;
}
.gb-react button:active { transform: scale(.94); }
.gb-react button[aria-pressed="true"] {
  border-color: var(--pink);
  background: rgba(229, 0, 126, .1);
}
.gb-react button:disabled { cursor: progress; }
.gb-react button:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; }
.gb-react-n {
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--ink-2);
}
.gb-react-n:empty { display: none; }
.gb-react button[aria-pressed="true"] .gb-react-n { color: var(--pink); }
@media (prefers-reduced-motion: reduce) {
  .gb-react button { transition: none; }
  .gb-react button:active { transform: none; }
}

/* Nur für Screenreader sichtbar */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Unterwegs (moments.js) ---------- */
.moments {
  padding: 8px;
  animation: fade-up .6s .4s ease-out both;
}
/* Zugeklappt: Titel, Zusammenfassung, Vorschau (wie die Route-Gruppen) */
.mo-summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 10px 12px;
  border-radius: 16px;
  list-style: none;
  cursor: pointer;
  touch-action: manipulation;
  transition: background .2s ease;
}
.mo-summary::-webkit-details-marker { display: none; }
.mo-summary:active { background: rgba(0, 0, 0, .05); }
.mo-summary:focus-visible { outline: 3px solid var(--pink); outline-offset: 0; }
.mo-wrap[open] > .mo-summary .stop-chev { transform: rotate(225deg) translate(-2px, -1px); }
.mo-sum-head {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.mo-sum-sub {
  font-size: 13px;
  color: var(--ink-2);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mo-sum-sub:empty { display: none; }
.mo-new {
  flex: none;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}
.mo-new[hidden] { display: none; }
/* Vorschaubilder leicht überlappend */
.mo-stack {
  flex: none;
  display: flex;
}
.mo-stack img {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  object-fit: cover;
  border: 2px solid #fff;
  box-shadow: 0 2px 6px rgba(40, 10, 60, .25);
}
.mo-stack img + img { margin-left: -16px; }
.mo-stack-sm img { width: 30px; height: 30px; border-radius: 8px; }
.mo-stack-sm img + img { margin-left: -14px; }
@media (max-width: 380px) {
  .mo-summary > .mo-stack { display: none; }
}
.mo-body { padding: 4px 8px 12px; }
.mo-wrap[open] > .mo-body { animation: fade-up .3s ease-out; }
.mo-form { margin-bottom: 14px; }
.mo-form[hidden] { display: none; }
.mo-photos { flex-wrap: wrap; }
.mo-select {
  cursor: pointer;
  /* Pfeil wie in iOS-Listen */
  padding-right: 40px;
  background:
    linear-gradient(rgba(60, 60, 67, .18), rgba(60, 60, 67, .18)) 16px 0 / calc(100% - 16px) .5px no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7 10l5 5 5-5' fill='none' stroke='%236e6e73' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right 14px center / 18px no-repeat;
}
.mo-gps {
  margin: -4px 4px 0;
  font-size: 13px;
  color: rgba(60, 60, 67, .8);
}
.mo-gps[hidden] { display: none; }

/* Gruppen: ein Tag an einem Ort */
.mo-groups {
  list-style: none;
  margin: 0;
  padding: 0;
}
.mo-group + .mo-group { border-top: 1px solid rgba(73, 39, 126, .1); }
.mo-group summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 56px;
  padding: 8px 4px;
  border-radius: 14px;
  list-style: none;
  cursor: pointer;
  touch-action: manipulation;
}
.mo-group summary::-webkit-details-marker { display: none; }
.mo-group summary:active { background: rgba(0, 0, 0, .05); }
.mo-group summary:focus-visible { outline: 3px solid var(--pink); outline-offset: 0; }
.mo-group > details[open] > summary .stop-chev { transform: rotate(225deg) translate(-2px, -1px); }
.mo-group > details[open] > summary .mo-stack { display: none; }
.mo-group > details[open] > .mo-list { animation: fade-up .3s ease-out; }
.mo-count {
  flex: none;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
}
.mo-list {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.mo-item {
  position: relative;
  padding: 10px 10px 14px;
  border-radius: 20px;
  background: rgba(255, 255, 255, .62);
  box-shadow: 0 0 0 .5px rgba(60, 60, 67, .12);
  animation: fade-up .4s ease-out both;
}
.mo-images {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.mo-images[data-n="1"] { grid-template-columns: 1fr; }
.mo-images[data-n="2"] { grid-template-columns: repeat(2, 1fr); }
.mo-images[data-n="1"] .gb-thumb {
  aspect-ratio: 4 / 3;
  max-height: 70vh;
  border-radius: 14px;
}
.mo-caption {
  margin: 10px 4px 0;
  font-size: 16px;
  line-height: 1.45;
  white-space: pre-line;
  overflow-wrap: anywhere;
}
.mo-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 12px;
  margin: 6px 4px 0;
  font-size: 13px;
  color: rgba(60, 60, 67, .7);
}
.mo-where {
  color: var(--ink-2);
  font-weight: 600;
  overflow-wrap: anywhere;
}
a.mo-where { color: var(--pink); text-decoration: none; }
a.mo-where:hover { text-decoration: underline; }
a.mo-where:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; border-radius: 4px; }
.mo-time {
  margin-left: auto;
  font-variant-numeric: tabular-nums;
}
.mo-del,
.mo-edit-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 2px 8px rgba(0, 0, 0, .2);
}
.mo-edit-btn { right: 50px; color: var(--ink-2); }
.mo-edit-btn svg { width: 12px; height: 12px; }
.mo-edit {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 10px 0 0;
}
.mo-edit-caption { resize: vertical; }
.mo-edit-buttons {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
}
.mo-edit-buttons .gb-submit { min-height: 44px; padding-inline: 22px; }
.mo-edit-buttons .gb-tr-btn { font-size: 15px; padding: 8px; }
.mo-more { position: relative; }
.mo-more img { filter: brightness(.55); }
.mo-more-n {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 22px;
  font-weight: 700;
}

/* ---------- Besucherzähler (stats.js) ---------- */
.stats {
  padding: 16px;
  text-align: center;
  animation: fade-up .6s .56s ease-out both;
}
.st-counts {
  margin: 0;
  font-size: 16px;
  color: var(--ink-2);
}
.st-counts strong {
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.st-sep { color: rgba(60, 60, 67, .4); }
.st-countries {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin: 10px 0 0;
  padding: 0;
}
.st-countries[hidden] { display: none; }
.st-countries li {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, .04);
  border: 1px solid rgba(0, 0, 0, .08);
  font-size: 13px;
}
.st-flag { font-size: 16px; line-height: 1; }
.st-n {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--ink-2);
}

/* ---------- Reels (reels.js) ---------- */
.reels {
  padding: 18px 14px 18px;
  animation: fade-up .6s .45s ease-out both;
}
.reels .section-title { padding: 0 4px 12px; }

/* Tabs als Segmented Control wie der Sprachumschalter */
.re-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
  padding: 3px;
  margin-bottom: 14px;
  border-radius: 12px;
  background: rgba(118, 118, 128, .14);
}
.re-tabs button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 10px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
  transition: background .2s ease, box-shadow .2s ease;
}
.re-tabs button[aria-selected="true"] {
  background: #fff;
  box-shadow: 0 3px 8px rgba(0, 0, 0, .12), 0 3px 1px rgba(0, 0, 0, .04);
}
.re-tabs button:focus-visible { outline: 3px solid var(--pink); outline-offset: 1px; }
.re-n {
  min-width: 20px;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(229, 0, 126, .12);
  color: var(--pink);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.re-n:empty { display: none; }

/* Upload-Formular (Admin) */
.re-form { margin-bottom: 16px; }
.re-form[hidden] { display: none; }
.re-pick {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, .88);
  box-shadow: 0 0 0 .5px rgba(60, 60, 67, .16), 0 6px 18px -10px rgba(40, 10, 60, .35);
  color: var(--pink);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
}
.re-pick:focus-within { outline: 3px solid var(--pink); outline-offset: 2px; }
.re-pick svg { flex: none; width: 26px; height: 26px; }
.re-pick input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.re-pick-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.re-pick.re-picked { color: var(--ink); font-weight: 500; }
.re-resume {
  margin: -4px 4px 0;
  font-size: 13px;
  color: var(--ink-2);
}
.re-resume[hidden] { display: none; }
.re-title-input:is(textarea) { min-height: 64px; }
.re-progress[hidden] { display: none; }
.re-track {
  height: 8px;
  border-radius: 999px;
  background: rgba(118, 118, 128, .18);
  overflow: hidden;
}
.re-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--brand-gradient);
  transition: width .3s ease;
}
.re-progress-text {
  margin: 6px 4px 0;
  font-size: 13px;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
}

/* Raster mit Hochkant-Vorschauen */
.re-grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 0;
  padding: 0;
}
.re-item {
  position: relative;
  min-width: 0;
}
.re-item.re-editing { grid-column: 1 / -1; }
.re-tile {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  padding: 0;
  border: 0;
  border-radius: 14px;
  overflow: hidden;
  background: linear-gradient(160deg, var(--purple), var(--pink));
  box-shadow: 0 6px 16px -8px rgba(40, 10, 60, .5);
  cursor: pointer;
  touch-action: manipulation;
  transition: transform .25s var(--ease-spring);
}
.re-tile:active { transform: scale(.96); }
.re-tile:focus-visible { outline: 3px solid var(--pink); outline-offset: 2px; }
.re-tile img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* Play-Symbol */
.re-play {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 40px;
  height: 40px;
  translate: -50% -50%;
  border-radius: 50%;
  background: rgba(0, 0, 0, .38);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
}
.re-play::after {
  content: "";
  position: absolute;
  inset: 12px 0 0 15px;
  border-style: solid;
  border-width: 8px 0 8px 13px;
  border-color: transparent transparent transparent #fff;
  width: 0;
  height: 0;
}
.re-dur {
  position: absolute;
  right: 6px;
  bottom: 6px;
  padding: 1px 6px;
  border-radius: 6px;
  background: rgba(0, 0, 0, .55);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.re-tile:disabled { cursor: default; }
.re-tile.re-processing { animation: re-pulse 1.6s ease-in-out infinite; }
.re-tile.re-failed { background: linear-gradient(160deg, #6e6e73, var(--red)); }
@keyframes re-pulse { 50% { opacity: .6; } }
.re-state {
  position: absolute;
  inset: auto 6px 10px;
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  text-align: center;
}
.re-title {
  margin: 6px 2px 0;
  font-size: 13px;
  line-height: 1.3;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
}
.re-item > .gb-del {
  position: absolute;
  top: 6px;
  right: 6px;
}
.re-item > .re-edit-btn { right: 38px; }
.re-edit-row {
  display: flex;
  gap: 10px;
}
.re-edit-row > * { flex: 1; }
.re-edit-cancel {
  min-height: 52px;
  border: 0;
  border-radius: 16px;
  background: rgba(118, 118, 128, .14);
  color: var(--ink);
  font: inherit;
  font-size: 17px;
  font-weight: 600;
  cursor: pointer;
}
.re-empty {
  margin: 4px 4px 2px;
  font-size: 15px;
  color: var(--ink-2);
  text-align: center;
}
.re-empty[hidden] { display: none; }
@media (min-width: 560px) {
  .re-grid { gap: 12px; }
}

/* Player */
.re-player {
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: #000;
  color: #fff;
  overflow: hidden;
  /* senkrecht wischt JS */
  touch-action: none;
}
.re-player::backdrop { background: #000; }
.re-stage {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.re-stage video {
  display: block;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: 100%;
  background: #000;
  transition: transform .2s ease-out;
}
.re-top {
  position: absolute;
  top: max(10px, env(safe-area-inset-top));
  left: 10px;
  right: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: none;
}
.re-top > * { pointer-events: auto; }
.re-close {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, .5);
  -webkit-backdrop-filter: blur(10px);
          backdrop-filter: blur(10px);
  color: #fff;
  cursor: pointer;
}
.re-close svg { width: 14px; height: 14px; }
.re-count {
  flex: 1;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 1px 4px rgba(0, 0, 0, .6);
}
.re-quality {
  display: flex;
  gap: 2px;
  padding: 3px;
  border-radius: 10px;
  background: rgba(0, 0, 0, .5);
  -webkit-backdrop-filter: blur(10px);
          backdrop-filter: blur(10px);
}
.re-quality button {
  min-height: 32px;
  padding: 0 10px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: rgba(255, 255, 255, .8);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
}
.re-quality button[aria-pressed="true"] { background: #fff; color: #000; }
.re-close:focus-visible,
.re-quality button:focus-visible { outline: 3px solid var(--pink); outline-offset: 1px; }
.re-caption {
  position: absolute;
  top: calc(max(10px, env(safe-area-inset-top)) + 52px);
  left: 14px;
  right: 14px;
  margin: 0;
  font-size: 15px;
  line-height: 1.35;
  text-shadow: 0 1px 6px rgba(0, 0, 0, .8);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  pointer-events: none;
}
.re-caption[hidden] { display: none; }
