/* ===== For Mom — shared styles =====
   Two looks share the same color tokens but compose them differently:
   - Light/warm: gate page + uploader view (intimate, hopeful)
   - Dark/cinematic: mom's reels view (full-bleed video, Instagram-feel)
*/
:root {
  --cream: #f7f1e8;
  --cream-deep: #ede4d3;
  --rose: #e6a39a;
  --rose-deep: #c87870;
  --sage: #9bb19a;
  --sage-deep: #6c8a6b;
  --gold: #c89b3c;
  --ink: #2d2a26;
  --ink-soft: #56504a;
  --muted: #8a8278;
  --rule: #e0d6c4;
  --shadow: 0 1px 2px rgba(45, 42, 38, 0.06), 0 8px 24px rgba(45, 42, 38, 0.08);
  --shadow-lg: 0 12px 36px rgba(45, 42, 38, 0.18);
  --radius: 18px;
  --radius-sm: 10px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  color: var(--ink);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
.serif {
  font-family: "Fraunces", "Cormorant Garamond", Georgia, serif;
  font-weight: 500;
  letter-spacing: -0.01em;
}

button { font-family: inherit; cursor: pointer; }
a { color: var(--rose-deep); }

/* ===========================================================
   LIGHT LOOK — gate + uploader
   =========================================================== */
.warm {
  background:
    radial-gradient(circle at 10% 0%,  rgba(230, 163, 154, 0.30), transparent 55%),
    radial-gradient(circle at 90% 10%, rgba(155, 177, 154, 0.28), transparent 55%),
    radial-gradient(circle at 50% 100%, rgba(200, 155, 60, 0.18), transparent 60%),
    var(--cream);
}

.shell {
  max-width: 560px;
  margin: 0 auto;
  padding: 56px 24px 80px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero { text-align: center; margin-bottom: 28px; }
.hero .eyebrow {
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--rose-deep);
  font-weight: 600;
  margin-bottom: 14px;
}
.hero h1 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 500;
  font-size: 44px;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
  color: var(--ink);
}
.hero h1 em { font-style: italic; color: var(--rose-deep); font-weight: 500; }
.hero p {
  color: var(--ink-soft);
  font-size: 17px;
  margin: 0 auto;
  max-width: 460px;
}

.card-soft {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
}

.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 600;
  margin-bottom: 8px;
}
.field input[type="text"],
.field input[type="password"],
.field textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--rule);
  border-radius: var(--radius-sm);
  background: #fff;
  font-family: inherit;
  font-size: 16px;
  color: var(--ink);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field textarea { min-height: 84px; resize: vertical; }
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(230, 163, 154, 0.25);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 22px;
  border-radius: 999px;
  border: none;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: transform 0.06s, filter 0.12s, background 0.15s;
  font-family: inherit;
}
.btn-primary {
  background: var(--rose-deep);
  color: #fff;
  box-shadow: 0 6px 16px rgba(200, 120, 112, 0.35);
}
.btn-primary:hover { background: #b56962; }
.btn-primary:active { transform: scale(0.98); }
.btn-primary:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-block { width: 100%; }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--rule);
}
.btn-ghost:hover { background: rgba(255, 255, 255, 0.6); }

.error {
  color: #b03a30;
  background: #fdecea;
  border: 1px solid #f5c2bd;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  margin-top: 10px;
}
.helper { color: var(--muted); font-size: 13px; margin-top: 6px; }

.note-callout {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  margin: 0 0 22px;
  background: rgba(230, 163, 154, 0.18);
  border: 1px solid rgba(200, 120, 112, 0.45);
  border-radius: var(--radius-sm);
  color: var(--ink-soft);
  font-size: 14px;
  font-style: italic;
  line-height: 1.55;
}
.note-callout .note-icon {
  font-size: 18px;
  line-height: 1.2;
  flex-shrink: 0;
}
.note-callout strong, .note-callout .note-key {
  color: var(--rose-deep);
  font-weight: 700;
  font-style: normal;
}

/* Privacy toggle as a soft card with toggle row on top, helper below */
.toggle-card {
  display: block;
  padding: 14px 16px;
  border: 1px solid var(--rule);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.65);
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}
.toggle-card:hover { background: rgba(255, 255, 255, 0.85); }
.toggle-card:has(input:checked) {
  background: rgba(230, 163, 154, 0.16);
  border-color: rgba(200, 120, 112, 0.45);
}
.toggle-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 1px; height: 1px;
}
.toggle-card-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.toggle-label {
  font-weight: 600;
  font-size: 14px;
  color: var(--ink);
  letter-spacing: 0;
  text-transform: none;
}
.toggle-helper {
  margin-top: 10px;
  color: var(--ink-soft);
  font-size: 12.5px;
  line-height: 1.5;
  font-style: italic;
}
/* Two-state label + helper: only one of each shows based on toggle state. */
.toggle-label-on,  .toggle-helper-on  { display: none; }
.toggle-card:has(input:checked) .toggle-label-off  { display: none; }
.toggle-card:has(input:checked) .toggle-label-on   { display: inline; }
.toggle-card:has(input:checked) .toggle-helper-off { display: none; }
.toggle-card:has(input:checked) .toggle-helper-on  { display: block; }

/* Tiny footnote-style note for the thanks state */
.thanks-asterisk {
  font-size: 12px;
  color: var(--muted);
  font-style: italic;
  margin: 18px auto 0;
  max-width: 380px;
  line-height: 1.5;
}
.thanks-asterisk a { color: var(--rose-deep); }
/* The actual switch — a clearly-visible gray track when off, rose when on */
.toggle-switch {
  width: 50px;
  height: 30px;
  background: #cfc8bd;
  border-radius: 999px;
  position: relative;
  flex-shrink: 0;
  transition: background 0.25s;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.08);
}
.toggle-switch::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 24px;
  height: 24px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.25);
  transition: transform 0.25s cubic-bezier(0.4, 0.2, 0.2, 1);
}
.toggle-card input:checked ~ .toggle-card-row .toggle-switch { background: var(--rose-deep); }
.toggle-card input:checked ~ .toggle-card-row .toggle-switch::after { transform: translateX(20px); }
.toggle-card input:focus-visible ~ .toggle-card-row .toggle-switch {
  outline: 2px solid var(--rose);
  outline-offset: 3px;
}

/* Gallery grid (uploaders' shared view) */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
  margin-top: 16px;
}
.gallery-card {
  background: rgba(255,255,255,0.85);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.gallery-card video { width: 100%; aspect-ratio: 9/16; object-fit: cover; background: #000; border-radius: var(--radius-sm); }
.gallery-card .gc-from { font-weight: 700; font-size: 15px; }
.gallery-card .gc-msg { color: var(--ink-soft); font-size: 13px; line-height: 1.45; white-space: pre-wrap; }

/* Sign-out / corner link */
.corner-link {
  position: absolute;
  top: 18px;
  right: 20px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
  color: var(--ink-soft);
  text-decoration: none;
  background: rgba(255,255,255,0.6);
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--rule);
}
.corner-link:hover { background: #fff; color: var(--rose-deep); text-decoration: none; }

/* Tiny decorative motif on warm pages */
.warm::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(circle at 8% 22%, rgba(200, 155, 60, 0.10) 0, transparent 1.5px),
    radial-gradient(circle at 92% 78%, rgba(155, 177, 154, 0.10) 0, transparent 1.5px),
    radial-gradient(circle at 78% 18%, rgba(230, 163, 154, 0.10) 0, transparent 1.5px);
  background-size: 220px 220px, 260px 260px, 180px 180px;
  z-index: -1;
}

/* ===== Uploader specifics ===== */
.dropzone {
  border: 2px dashed var(--rose);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.5);
  padding: 32px 20px;
  text-align: center;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.dropzone:hover { background: rgba(255, 255, 255, 0.85); }
.dropzone.is-drag { background: rgba(230, 163, 154, 0.12); border-color: var(--rose-deep); }
.dropzone .dz-icon { font-size: 38px; margin-bottom: 8px; }
.dropzone .dz-title { font-weight: 600; margin-bottom: 4px; }
.dropzone .dz-sub { color: var(--muted); font-size: 13px; }
.dropzone input[type="file"] { display: none; }

.preview {
  margin-top: 14px;
  background: rgba(255,255,255,0.85);
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--rule);
}
.preview video { width: 100%; display: block; max-height: 320px; background: #000; }
.preview .pv-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  font-size: 13px;
  color: var(--ink-soft);
}
.preview .pv-clear {
  background: transparent;
  border: none;
  color: var(--rose-deep);
  font-weight: 600;
  cursor: pointer;
}

.progress {
  margin-top: 12px;
  height: 8px;
  background: var(--cream-deep);
  border-radius: 999px;
  overflow: hidden;
}
.progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--rose), var(--rose-deep));
  transition: width 0.2s;
}

.thanks {
  text-align: center;
  padding: 30px 18px 10px;
}
.thanks .check {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--sage), var(--sage-deep));
  color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 36px;
  margin-bottom: 16px;
  box-shadow: 0 8px 20px rgba(108, 138, 107, 0.35);
}
.thanks h2 {
  font-family: "Fraunces", Georgia, serif;
  font-size: 28px;
  font-weight: 500;
  margin: 0 0 8px;
}
.thanks p { color: var(--ink-soft); margin: 0 auto 18px; max-width: 380px; }

.divider {
  display: flex; align-items: center; gap: 12px;
  color: var(--muted); font-size: 12px;
  text-transform: uppercase; letter-spacing: 0.15em;
  margin: 22px 0 12px;
}
.divider::before, .divider::after {
  content: ""; flex: 1; height: 1px; background: var(--rule);
}

/* ===========================================================
   DARK / CINEMATIC LOOK — mom's reels
   =========================================================== */
body.cinema {
  background: #000;
  color: #fff;
  overflow: hidden;
}

.reels {
  position: fixed;
  inset: 0;
  scroll-snap-type: y mandatory;
  overflow-y: scroll;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.reels::-webkit-scrollbar { display: none; }

.reel {
  scroll-snap-align: start;
  scroll-snap-stop: always;
  height: 100vh;
  height: 100dvh;
  width: 100vw;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
}
.reel video {
  max-height: 100%;
  max-width: 100%;
  width: auto;
  height: 100%;
  object-fit: contain;
  background: #000;
}
.reel .reel-overlay {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 24px 24px 36px;
  background: linear-gradient(to top, rgba(0,0,0,0.8) 20%, rgba(0,0,0,0.0));
  pointer-events: none;
}
.reel .reel-from {
  font-family: "Fraunces", Georgia, serif;
  font-size: 22px;
  font-weight: 500;
  margin-bottom: 4px;
  letter-spacing: -0.01em;
}
.reel .reel-msg {
  font-size: 15px;
  line-height: 1.45;
  opacity: 0.92;
  max-width: 560px;
  white-space: pre-wrap;
}

.reel .reel-counter {
  position: absolute;
  top: 18px; right: 18px;
  background: rgba(0,0,0,0.45);
  color: #fff;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 6px 10px;
  border-radius: 999px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.reel .reel-tap {
  position: absolute;
  inset: 0;
  cursor: pointer;
}

.reel-empty, .reel-loading {
  text-align: center;
  padding: 40px;
  color: #fff;
}
.reel-empty h2 {
  font-family: "Fraunces", Georgia, serif;
  font-size: 32px;
  font-weight: 500;
  margin: 0 0 10px;
}
.reel-empty p { color: rgba(255,255,255,0.7); }

.reel-hint {
  position: fixed;
  top: 18px; left: 18px;
  z-index: 10;
  color: rgba(255,255,255,0.7);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: rgba(0,0,0,0.4);
  padding: 6px 12px;
  border-radius: 999px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  pointer-events: none;
  transition: opacity 0.5s;
}

.reel-controls {
  position: fixed;
  bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 10;
  align-items: center;
}
.reel-btn {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.18);
  color: #fff;
  height: 48px;
  padding: 0 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: pointer;
  transition: background 0.15s, transform 0.06s;
}
.reel-btn:hover { background: rgba(255,255,255,0.22); }
.reel-btn:active { transform: scale(0.97); }
.reel-btn .reel-btn-icon { font-size: 18px; }

/* Per-reel favorite (♥) — sits above the overlay text */
.reel-fav {
  position: absolute;
  right: 18px;
  bottom: calc(160px + env(safe-area-inset-bottom, 0px));
  width: 52px; height: 52px;
  background: rgba(0,0,0,0.45);
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  display: inline-flex; align-items: center; justify-content: center;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: pointer;
  z-index: 5;
  transition: transform 0.15s, background 0.15s;
}
.reel-fav:hover { background: rgba(0,0,0,0.65); }
.reel-fav.is-fav { background: var(--rose-deep, #c87870); transform: scale(1.05); }

/* Replay button on the closing card */
.reel-close {
  text-align: center;
  padding: 40px 28px;
  max-width: 480px;
  color: #fff;
}
.reel-close h2 {
  font-family: "Fraunces", Georgia, serif;
  font-size: 36px;
  font-weight: 500;
  margin: 0 0 12px;
  line-height: 1.15;
}
.reel-close p {
  font-size: 16px;
  opacity: 0.85;
  margin: 0 0 22px;
  line-height: 1.55;
}
.reel-close button {
  background: #fff;
  color: #1a1a1a;
  border: none;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  font-family: inherit;
  display: inline-flex; align-items: center; gap: 8px;
}
.reel-close button:hover { background: rgba(255,255,255,0.9); }

/* Tap-to-begin opening splash */
.reel-splash {
  position: fixed;
  inset: 0;
  background: linear-gradient(135deg, #1a0e16 0%, #2d1820 50%, #1a0e16 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 100;
  text-align: center;
  padding: 40px 24px;
  cursor: pointer;
}
.reel-splash .splash-mark {
  font-size: 64px;
  margin-bottom: 18px;
  animation: splash-pulse 2.4s ease-in-out infinite;
}
.reel-splash h1 {
  font-family: "Fraunces", Georgia, serif;
  font-size: 38px;
  font-weight: 500;
  color: #fff;
  margin: 0 0 14px;
  letter-spacing: -0.01em;
}
.reel-splash p {
  color: rgba(255,255,255,0.8);
  font-size: 16px;
  max-width: 380px;
  margin: 0 0 28px;
  line-height: 1.55;
}
.reel-splash .splash-btn {
  background: #fff;
  color: #1a1a1a;
  border: none;
  padding: 16px 32px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  box-shadow: 0 12px 32px rgba(255,255,255,0.18);
}
.reel-splash .splash-btn:hover { background: rgba(255,255,255,0.92); }
.reel-splash .splash-hint {
  margin-top: 18px;
  color: rgba(255,255,255,0.55);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
@keyframes splash-pulse {
  0%, 100% { transform: scale(1); opacity: 0.95; }
  50%      { transform: scale(1.08); opacity: 1; }
}

/* Reel-from name fade-in animation */
@keyframes reel-overlay-rise {
  from { transform: translateY(8px); opacity: 0; }
  to   { transform: translateY(0);   opacity: 1; }
}
.reel.is-active .reel-overlay { animation: reel-overlay-rise 0.45s ease-out; }

/* ===== Responsive ===== */
@media (max-width: 600px) {
  .hero h1 { font-size: 34px; }
  .shell { padding: 40px 18px 64px; }
  .card-soft { padding: 22px; }
  .reel .reel-from { font-size: 19px; }
  .reel-splash h1 { font-size: 32px; }
  .reel-close h2 { font-size: 30px; }
  /* Drag-drop only matters on desktop */
  .dropzone .dz-sub-desktop { display: none; }
}
@media (min-width: 601px) {
  .dropzone .dz-sub-mobile { display: none; }
}
