:root {
  --bg-1: #ffe9ef;
  --bg-2: #ffd9e0;
  --bg-3: #ffe7d8;
  --card: #ffffff;
  --ink: #4a4350;
  --ink-soft: #8b8190;
  --rose: #e9758f;
  --rose-deep: #d65b78;
  --rose-soft: #ffdfe7;
  --accent: #ff7a98;
  --shadow: 0 22px 60px rgba(196, 110, 130, 0.22);
  --radius: 30px;
  --radius-sm: 18px;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  min-height: 100dvh;
  font-family: "Quicksand", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background: linear-gradient(150deg, var(--bg-1) 0%, var(--bg-2) 45%, var(--bg-3) 100%);
  background-attachment: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(16px, env(safe-area-inset-top)) 16px max(16px, env(safe-area-inset-bottom));
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.stage {
  width: 100%;
  max-width: 1120px;
  display: flex;
  justify-content: center;
  position: relative;
  z-index: 2;
}

.card {
  position: relative;
  width: 100%;
  max-width: 480px;            /* Text-Screens schmal & gut lesbar */
  margin: 0 auto;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(24px, 3.5vw, 44px);
  overflow: hidden;
  transition: max-width 0.35s ease;
}
/* Auswahl-Screens dürfen den ganzen Platz nutzen (Desktop) */
.card:has(.screen[data-screen="dest"].is-active),
.card:has(.screen[data-screen="activities"].is-active) {
  max-width: 1060px;
}
/* Finale (Ticket): etwas breiter -> 2 Spalten auf Desktop */
.card:has(.screen[data-screen="final"].is-active) { max-width: 880px; }

/* ---- Screens ---- */
.screen { display: none; flex-direction: column; align-items: center; text-align: center; }
.screen.is-active { display: flex; animation: screenIn 0.45s ease both; }

@keyframes screenIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.reaction {
  font-size: clamp(54px, 16vw, 78px);
  line-height: 1;
  margin-bottom: 14px;
  filter: drop-shadow(0 8px 14px rgba(0,0,0,0.08));
  animation: pop 0.5s ease both;
}
.reaction.swap { animation: pop 0.3s ease both; }
@keyframes pop {
  0% { transform: scale(0.6); opacity: 0; }
  60% { transform: scale(1.12); }
  100% { transform: scale(1); opacity: 1; }
}

.reaction-img {
  width: clamp(120px, 40vw, 170px);
  height: clamp(120px, 40vw, 170px);
  object-fit: cover;
  border-radius: 26px;
  margin-bottom: 14px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.12);
}

.headline {
  font-family: "Baloo 2", "Quicksand", sans-serif;
  font-weight: 700;
  font-size: clamp(24px, 6.2vw, 32px);
  line-height: 1.18;
  margin: 0 0 10px;
  color: var(--rose-deep);
  letter-spacing: 0.2px;
}
.headline-big { font-size: clamp(25px, 6.6vw, 34px); }
.headline-omg { color: #ff214c; letter-spacing: 0.5px; }

.sub {
  font-size: clamp(15px, 3.9vw, 17px);
  line-height: 1.5;
  color: var(--ink);
  margin: 0 0 22px;
  max-width: 36ch;
}
/* Breite Auswahl-Screens: Untertitel breiter laufen lassen (kein komischer Umbruch) */
.screen[data-screen="dest"] .sub,
.screen[data-screen="activities"] .sub {
  max-width: 58ch;
}

.fineprint {
  font-size: 13px;
  color: var(--ink-soft);
  margin: 16px 0 0;
  max-width: 32ch;
}
.fineprint em { color: var(--rose); font-style: normal; font-weight: 700; }

.ps {
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--ink-soft);
  font-style: italic;
  margin: 18px 0 0;
  max-width: 40ch;
}

/* ---- Buttons ---- */
.btn {
  font-family: inherit;
  font-weight: 700;
  font-size: clamp(16px, 4.2vw, 18px);
  border: none;
  border-radius: 999px;
  padding: 15px 28px;
  cursor: pointer;
  min-height: 52px;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.2s ease;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
.btn-yes {
  background: linear-gradient(135deg, #ff8fab, #ff6f91);
  color: #fff;
  box-shadow: 0 12px 26px rgba(255, 111, 145, 0.42);
}
.btn-yes:hover { transform: translateY(-2px); box-shadow: 0 16px 30px rgba(255, 111, 145, 0.5); }
.btn-yes:active { transform: translateY(0) scale(0.98); }

.btn-weiter { margin-top: 6px; }

.btn-no {
  background: #efeaf0;
  color: #9a8f9f;
  box-shadow: 0 6px 14px rgba(0,0,0,0.06);
}

.ask-buttons {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  min-height: 60px;
  position: relative;
  width: 100%;
}
#yesBtn { transform-origin: center; will-change: transform; }
/* Nein-Button kann frei "fliehen" */
#noBtn.run {
  position: fixed; z-index: 50; margin: 0;
  max-width: min(80vw, 300px); white-space: normal;
  /* Das sichtbare Rüberrutschen macht eine JS-Transform-Animation (zuverlässig). */
}

/* ---- Picker-Grid (Mehrfachauswahl) ---- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  width: 100%;
  margin-bottom: 6px;
}
/* Länder kompakter (mehr passen rein), Aktivitäten großzügiger */
#destGrid { grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); }
#actGrid  { grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.pick {
  position: relative;
  border: 2px solid transparent;
  border-radius: var(--radius-sm);
  padding: 16px 10px;
  cursor: pointer;
  background: var(--grad, linear-gradient(135deg, #f6eef3, #efe7ee));
  color: #4a4350;
  font-weight: 700;
  font-size: 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-height: 130px;
  justify-content: center;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
  overflow: hidden;
  text-align: center;
  -webkit-tap-highlight-color: transparent;
}
.pick:hover { transform: translateY(-2px); }
.pick:active { transform: scale(0.97); }
.pick .emoji { font-size: 34px; line-height: 1; filter: drop-shadow(0 4px 8px rgba(0,0,0,0.12)); }
.pick .label { line-height: 1.2; }

/* Foto-Karten: wenn ein Bild da ist, fuellt es die Karte; sonst bleibt der Verlauf */
.pick.has-img { color: #fff; text-shadow: 0 1px 6px rgba(0,0,0,0.45); }
.pick .photo {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; z-index: 0;
}
.pick.has-img::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.02) 38%, rgba(0,0,0,0.62)); z-index: 1;
}
.pick.has-img .emoji, .pick.has-img .label, .pick.has-img .check { position: relative; z-index: 2; }
/* Foto-Karten: Emoji ausblenden — das Foto ersetzt es. */
.pick.has-img .emoji { display: none; }
/* Foto-Karten größer; Label unten auf dem dunklen Verlauf platzieren. */
.pick.has-img { justify-content: flex-end; min-height: 200px; padding-bottom: 14px; }
.pick.has-img .label { font-size: 18px; font-weight: 700; }

.pick.selected {
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(233, 117, 143, 0.22), 0 12px 22px rgba(233,117,143,0.25);
  transform: translateY(-2px);
}
.pick .check {
  position: absolute; top: 8px; right: 8px;
  width: 24px; height: 24px; border-radius: 50%;
  background: var(--rose); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; opacity: 0; transform: scale(0.5);
  transition: opacity 0.15s ease, transform 0.15s ease; z-index: 3;
}
.pick.selected .check { opacity: 1; transform: scale(1); }

.picker-hint {
  font-size: 13.5px;
  color: var(--rose);
  font-weight: 700;
  min-height: 20px;
  margin: 4px 0 12px;
}

/* Freies Reiseziel ("Ganz woanders") */
.custom-dest {
  width: 100%;
  font-family: inherit;
  font-size: 16px; /* >=16px verhindert iOS-Zoom beim Fokus */
  color: var(--ink);
  border: 2px solid var(--rose-soft);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin: 10px auto 4px;
  max-width: 560px;
  display: block;
  background: #fff;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}
.custom-dest:focus {
  outline: none;
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(233, 117, 143, 0.18);
}
.custom-dest[hidden] { display: none; }

/* ---- Easter Egg: Riechtest ---- */
/* kleiner, unscheinbarer Trigger unten links auf der Wunsch-Seite */
/* Eck-Container: kleines Devious-GIF über dem Button, fix unten links */
.smelltest-corner {
  position: fixed;
  left: 24px;
  bottom: 24px;
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}
.smelltest-corner[hidden] { display: none; }
.smelltest-gif {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 16px;
  border: 2px solid #fff;
  box-shadow: 0 6px 16px rgba(214, 91, 120, 0.22);
}
.smelltest-trigger {
  background: #fff;
  border: 2px solid var(--rose-soft);
  border-radius: 999px;
  padding: 13px 22px;
  font-family: inherit;
  font-weight: 700;
  font-size: 14px;
  color: var(--rose);
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(214, 91, 120, 0.18);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.smelltest-trigger:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(233, 117, 143, 0.32);
}
/* Platz unten, damit der Trigger in der Ecke nicht den "Fertig"-Button berührt */
.screen[data-screen="wish"] { padding-bottom: 40px; }

.smell-phase { display: flex; flex-direction: column; align-items: center; width: 100%; }
.smell-phase[hidden] { display: none; }

/* etwas größeres GIF als auf den anderen Seiten */
.reaction-img-lg {
  width: clamp(190px, 52vw, 260px);
  height: clamp(190px, 52vw, 260px);
}

/* gerade Ladeleiste */
.smell-bar {
  width: 100%;
  max-width: 360px;
  height: 14px;
  background: var(--rose-soft);
  border-radius: 999px;
  overflow: hidden;
  margin: 6px 0 12px;
}
.smell-bar-fill {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, #ff8fab, #ff6f91);
  box-shadow: 0 0 12px rgba(255, 111, 145, 0.5);
}
.smell-pct {
  font-family: "Baloo 2", "Quicksand", sans-serif;
  font-weight: 700;
  font-size: 20px;
  color: var(--rose-deep);
  margin: 0 0 4px;
}

/* regnende Emojis (💩 beim Geruchstest, ❤️ beim Abschicken) */
.rain-emoji {
  position: fixed;
  top: -8vh;
  left: 0;
  z-index: 70;
  pointer-events: none;
  will-change: transform;
}

/* "you right now"-Pfeil beim Fire Kitten (zeigt aufs GIF) */
.fire-arrow {
  position: absolute;
  top: 112px;
  right: 6px;
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 2px;
  transform: rotate(-5deg);
  animation: fireArrowIn 0.3s ease both;
  pointer-events: none;
}
.fire-arrow[hidden] { display: none; }
.fire-arrow-tip { font-size: 26px; line-height: 1; }
.fire-arrow-text {
  font-family: "Baloo 2", "Quicksand", sans-serif;
  font-weight: 700;
  font-size: 15px;
  color: var(--rose-deep);
  background: #fff;
  padding: 5px 11px;
  border-radius: 999px;
  box-shadow: 0 4px 12px rgba(214, 91, 120, 0.2);
  white-space: nowrap;
}
@keyframes fireArrowIn {
  from { opacity: 0; transform: rotate(-5deg) scale(0.6); }
  to   { opacity: 1; transform: rotate(-5deg) scale(1); }
}

/* ---- Freitext ---- */
.wish-input {
  width: 100%;
  font-family: inherit;
  font-size: 16px; /* >=16px verhindert iOS-Zoom beim Fokus */
  line-height: 1.5;
  color: var(--ink);
  border: 2px solid var(--rose-soft);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  resize: vertical;
  min-height: 110px;
  margin-bottom: 18px;
  background: #fff;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}
.wish-input:focus {
  outline: none;
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(233, 117, 143, 0.18);
}

/* ---- Boarding Pass ---- */
.ticket {
  width: 100%;
  background: linear-gradient(135deg, #fff 0%, #fff6f8 100%);
  border-radius: 20px;
  box-shadow: 0 14px 30px rgba(214, 91, 120, 0.2);
  border: 1.5px solid #ffe0e8;
  padding: 18px 18px 14px;
  margin-bottom: 20px;
  text-align: left;
  position: relative;
  overflow: hidden;
}
.ticket-head {
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 2px dashed #f1c9d4; padding-bottom: 10px; margin-bottom: 12px;
}
.ticket-brand {
  font-family: "Baloo 2", sans-serif; font-weight: 700; letter-spacing: 1px;
  color: var(--rose-deep); font-size: 14px;
}
.ticket-stamp {
  font-family: "Baloo 2", sans-serif; font-weight: 700; font-size: 13px;
  color: #36a86b; border: 2px solid #36a86b; border-radius: 8px;
  padding: 2px 8px; transform: rotate(7deg); opacity: 0;
}
.ticket-stamp.show { animation: stampIn 0.5s cubic-bezier(.2,1.4,.4,1) 0.25s both; }
@keyframes stampIn {
  0% { opacity: 0; transform: rotate(7deg) scale(2.2); }
  100% { opacity: 1; transform: rotate(7deg) scale(1); }
}

.ticket-row { display: flex; gap: 10px; margin: 7px 0; font-size: 14px; }
.ticket-row .k {
  color: var(--ink-soft); font-weight: 700; font-size: 11px; letter-spacing: 0.5px;
  text-transform: uppercase; flex: 0 0 92px; padding-top: 2px;
}
.ticket-row .v { color: var(--ink); font-weight: 700; flex: 1; }

.ticket-perf {
  height: 1px; border-top: 2px dashed #f1c9d4; margin: 12px -18px 10px; position: relative;
}
.ticket-foot {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 11px; color: var(--ink-soft); text-transform: uppercase; letter-spacing: 0.5px;
}
.ticket-foot strong { color: var(--rose-deep); }
.ticket-bag { font-size: 32px; line-height: 1; filter: drop-shadow(0 3px 6px rgba(0,0,0,0.12)); }

.status { font-size: 13px; color: var(--ink-soft); min-height: 18px; margin: 12px 0 0; }
.status.ok { color: #36a86b; }

/* Finale: 2 Spalten (Ticket | Text+Button) auf Desktop, gestapelt auf schmal */
.final-layout {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  width: 100%;
  align-items: center;
  justify-content: center;
}
.final-layout .ticket { flex: 1 1 360px; max-width: 460px; margin-bottom: 0; }
.final-side {
  flex: 1 1 320px;
  max-width: 420px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}
.final-side .sub { margin: 0; max-width: 38ch; }

/* "Ich liebe dich" als abgesetzter Absatz mit rotem Herz */
.love-line {
  margin: 16px 0 0;
  font-family: "Baloo 2", "Quicksand", sans-serif;
  font-weight: 700;
  font-size: clamp(18px, 4.5vw, 22px);
  color: var(--rose-deep);
}

/* Handy-Hinweis (nur auf Smartphones sichtbar) */
.mobile-gate {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: linear-gradient(150deg, var(--bg-1) 0%, var(--bg-2) 45%, var(--bg-3) 100%);
}
.mobile-gate[hidden] { display: none; }
.mobile-gate-inner {
  width: 100%;
  max-width: 440px;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 34px 26px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.mobile-gate .sub { margin: 0 0 6px; max-width: 34ch; }
.mobile-gate-note { color: var(--ink-soft); font-size: 14px; margin: 10px 0 0; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* ---- Konfetti / Burst-Partikel ---- */
.burst {
  position: fixed; top: 0; left: 0; pointer-events: none; z-index: 60;
  font-size: 22px; will-change: transform, opacity;
}

/* ---- treibende Hintergrund-Herzchen ---- */
.bg-hearts { position: fixed; inset: 0; pointer-events: none; z-index: 1; overflow: hidden; }
.bg-hearts span {
  position: absolute; bottom: -40px; font-size: 20px; opacity: 0;
  animation: floatUp linear infinite;
}
@keyframes floatUp {
  0% { transform: translateY(0) translateX(0); opacity: 0; }
  10% { opacity: 0.5; }
  90% { opacity: 0.4; }
  100% { transform: translateY(-112vh) translateX(var(--drift, 20px)); opacity: 0; }
}

/* ---- Rücksicht auf Bewegungsempfindlichkeit ---- */
@media (prefers-reduced-motion: reduce) {
  .screen.is-active { animation: fadeIn 0.25s ease both; }
  @keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
  .reaction, .reaction.swap { animation: none; }
  .bg-hearts { display: none; }
  .ticket-stamp.show { animation: none; opacity: 1; }
  .btn-yes:hover { transform: none; }
  .pick:hover { transform: none; }
  * { scroll-behavior: auto; }
}

@media (max-width: 360px) {
  .grid { gap: 9px; }
  .pick { min-height: 92px; font-size: 14px; }
}
