/* Side Quest — soft, warm, iPhone-first interactive date mini-game */
:root {
  --bg: #110e16;
  --card: rgba(28, 23, 36, 0.78);
  --card-2: rgba(40, 33, 52, 0.72);
  --line: rgba(255, 228, 214, 0.13);
  --line-hot: rgba(255, 180, 154, 0.48);
  --text: #fcf7f4;
  --muted: #bbaea8;
  --warm: #ff9a76;
  --warm-2: #ff758f;
  --cozy: #ffb88c;
  --adv: #6ee7b7;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Rounded", "SF Pro Display", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.45 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

button, input, textarea {
  font: inherit;
  color: inherit;
  touch-action: manipulation;
}

/* Soft ambient dusk background */
.bg-glow {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
  background:
    radial-gradient(800px circle at 50% -10%, rgba(255, 154, 118, 0.16), transparent 65%),
    radial-gradient(700px circle at 10% 105%, rgba(110, 231, 183, 0.1), transparent 60%),
    radial-gradient(600px circle at 95% 85%, rgba(255, 117, 143, 0.12), transparent 60%),
    #110e16;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(48px);
  opacity: 0.45;
  animation: floatOrb 14s ease-in-out infinite alternate;
}
.orb-1 { width: 260px; height: 260px; background: rgba(255, 154, 118, 0.25); top: 6%; left: -40px; }
.orb-2 { width: 220px; height: 220px; background: rgba(255, 117, 143, 0.2); bottom: 10%; right: -30px; animation-delay: -5s; }
.orb-3 { width: 180px; height: 180px; background: rgba(110, 231, 183, 0.16); top: 48%; left: 60%; animation-delay: -9s; }

@keyframes floatOrb {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(18px, -24px) scale(1.08); }
}

.stage {
  position: relative;
  z-index: 1;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(20px + env(safe-area-inset-top)) 18px calc(28px + env(safe-area-inset-bottom));
  max-width: 460px;
  margin: 0 auto;
}

.sq-card {
  background: var(--card);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  backdrop-filter: blur(22px) saturate(140%);
  border: 1px solid var(--line);
  border-radius: 28px;
  padding: 28px 22px 24px;
  box-shadow:
    0 24px 60px -15px rgba(0, 0, 0, 0.65),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  animation: cardIn 0.45s cubic-bezier(0.2, 0.85, 0.25, 1) both;
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(18px) scale(0.97); }
  to { opacity: 1; transform: none; }
}

.sq-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.sq-back {
  border: 0;
  background: rgba(255, 255, 255, 0.07);
  color: var(--muted);
  border-radius: 99px;
  padding: 6px 13px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
}
.sq-back:active { transform: scale(0.96); }

.sq-step-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 99px;
  background: rgba(255, 154, 118, 0.14);
  border: 1px solid rgba(255, 154, 118, 0.28);
  color: #ffc2ab;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.sq-emblem {
  width: 68px;
  height: 68px;
  margin: 4px auto 16px;
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(255, 154, 118, 0.22), rgba(255, 117, 143, 0.18));
  border: 1px solid rgba(255, 180, 154, 0.32);
  display: grid;
  place-items: center;
  font-size: 2rem;
  box-shadow: 0 12px 30px -8px rgba(255, 117, 143, 0.35);
  animation: pulseEmblem 3s ease-in-out infinite;
}

@keyframes pulseEmblem {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-4px) scale(1.04); }
}

.sq-center {
  text-align: center;
}

.sq-title {
  margin: 0 0 8px;
  font-size: 1.55rem;
  font-weight: 750;
  letter-spacing: -0.02em;
  line-height: 1.22;
}

.sq-sub {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Step 1: Yes / No arena */
.sq-ask-actions {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 126px;
  justify-content: center;
}

.sq-btn-yes {
  width: 100%;
  border: 0;
  border-radius: 18px;
  padding: 16px 20px;
  font-size: 1.06rem;
  font-weight: 700;
  color: #1f0d07;
  background: linear-gradient(120deg, #ffb88c 0%, #ff9a76 45%, #ff758f 100%);
  box-shadow: 0 10px 28px -6px rgba(255, 130, 110, 0.55);
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.2, 0.85, 0.25, 1), box-shadow 0.2s;
}
.sq-btn-yes:active {
  transform: scale(0.97);
}

.sq-btn-no {
  align-self: center;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  border-radius: 14px;
  padding: 11px 28px;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.22s cubic-bezier(0.2, 0.9, 0.3, 1), opacity 0.2s;
}

.sq-tease {
  margin: 12px 0 0;
  min-height: 1.3em;
  font-size: 0.86rem;
  color: #ffb88c;
  font-weight: 600;
  text-align: center;
}

/* Step 2: Date cards */
.sq-list {
  display: grid;
  gap: 11px;
  margin-top: 6px;
}

.sq-slot {
  width: 100%;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: var(--card-2);
  cursor: pointer;
  transition: transform 0.16s, border-color 0.16s, background 0.16s;
}
.sq-slot:hover, .sq-slot:active {
  transform: translateY(-1px) scale(0.995);
  border-color: var(--line-hot);
  background: rgba(255, 154, 118, 0.13);
}

.sq-cal {
  width: 52px;
  height: 54px;
  border-radius: 15px;
  background: rgba(255, 154, 118, 0.16);
  border: 1px solid rgba(255, 154, 118, 0.3);
  color: #ffc2ab;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: none;
}
.sq-cal small {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  opacity: 0.85;
}
.sq-cal b {
  font-size: 1.2rem;
  line-height: 1.05;
}

.sq-slot-main {
  flex: 1;
  min-width: 0;
}
.sq-slot-main b {
  display: block;
  font-size: 1rem;
  margin-bottom: 2px;
}
.sq-slot-main span {
  display: block;
  font-size: 0.85rem;
  color: var(--muted);
}

.sq-arrow {
  color: #ffb88c;
  font-weight: 700;
  font-size: 1.1rem;
}

/* Step 3: Vibe cards (Cozy vs Adventure) */
.sq-vibes {
  display: grid;
  gap: 14px;
  margin-top: 8px;
}

.sq-vibe {
  width: 100%;
  text-align: left;
  padding: 20px 18px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: var(--card-2);
  cursor: pointer;
  display: grid;
  gap: 8px;
  transition: transform 0.18s, border-color 0.18s, box-shadow 0.18s;
}
.sq-vibe.cozy {
  background: linear-gradient(145deg, rgba(255, 184, 140, 0.14), rgba(40, 33, 52, 0.78));
  border-color: rgba(255, 184, 140, 0.28);
}
.sq-vibe.adventure {
  background: linear-gradient(145deg, rgba(110, 231, 183, 0.13), rgba(40, 33, 52, 0.78));
  border-color: rgba(110, 231, 183, 0.28);
}
.sq-vibe:hover, .sq-vibe:active {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px -12px rgba(0, 0, 0, 0.5);
}
.sq-vibe.cozy:hover, .sq-vibe.cozy:active { border-color: rgba(255, 184, 140, 0.65); }
.sq-vibe.adventure:hover, .sq-vibe.adventure:active { border-color: rgba(110, 231, 183, 0.65); }

.sq-vibe-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.sq-vibe-icon {
  font-size: 1.65rem;
}
.sq-vibe-tag {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 4px 10px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--muted);
}
.sq-vibe.cozy .sq-vibe-tag { color: #ffcaa6; background: rgba(255, 184, 140, 0.15); }
.sq-vibe.adventure .sq-vibe-tag { color: #9ef3ce; background: rgba(110, 231, 183, 0.14); }

.sq-vibe b {
  font-size: 1.15rem;
  display: block;
}
.sq-vibe p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.4;
}

/* Step 4: Date Ticket & Confirmation */
.sq-ticket {
  margin: 10px 0 18px;
  padding: 18px 16px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px dashed rgba(255, 184, 140, 0.4);
  display: grid;
  gap: 12px;
}

.sq-ticket-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.sq-ticket-ico {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  background: rgba(255, 154, 118, 0.14);
  display: grid;
  place-items: center;
  flex: none;
  font-size: 1.1rem;
}
.sq-ticket-row small {
  display: block;
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  font-weight: 650;
}
.sq-ticket-row b {
  display: block;
  font-size: 0.98rem;
}
.sq-ticket-row span {
  display: block;
  font-size: 0.84rem;
  color: var(--muted);
}

.sq-note-label {
  display: block;
  margin-bottom: 16px;
  text-align: left;
}
.sq-note-label span {
  display: block;
  font-size: 0.84rem;
  color: var(--muted);
  margin-bottom: 6px;
}
.sq-note-input {
  width: 100%;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.25);
  padding: 12px 14px;
  font-size: 16px; /* Prevents iOS Safari auto-zoom */
  color: var(--text);
  outline: none;
}
.sq-note-input:focus {
  border-color: var(--line-hot);
}

.sq-confetti {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 20;
  overflow: hidden;
}
.sq-spark {
  position: absolute;
  bottom: -20px;
  font-size: 1.4rem;
  animation: riseSpark 2.8s ease-out forwards;
}
@keyframes riseSpark {
  0% { transform: translateY(0) scale(0.6) rotate(0deg); opacity: 1; }
  100% { transform: translateY(-92dvh) scale(1.25) rotate(25deg); opacity: 0; }
}
