/* Wowiator — The Face Animator. Money-page funnel styles.
   Brand: dark theme, neon-violet #C026D3 accent, cyan cat-eye secondary,
   near-black #0B0A10 background. Mobile-first; a phone frame appears on wide
   viewports so the desktop view stays faithful to the handset experience. */

:root {
  --bg: #0B0A10;
  --surface: #16131f;
  --surface-2: #1f1b2e;
  --line: #2b2542;
  --accent: #C026D3;
  --accent-2: #19e3d6;
  --accent-soft: rgba(192, 38, 211, 0.16);
  --text: #f5f3fb;
  --muted: #9a97ad;
  --good: #35d07f;
  --bad: #ff5a78;
  --radius: 18px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, system-ui, sans-serif;
}

* { box-sizing: border-box; }
/* The [hidden] attribute must beat class rules that set display (e.g. .wallet
   uses display:inline-flex), otherwise hidden chrome shows before its step. */
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font);
  background: #050409;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  justify-content: center;
}

/* Phone frame */
.phone {
  position: relative;
  width: 100%;
  max-width: 440px;
  min-height: 100vh;
  background:
    radial-gradient(130% 70% at 50% -10%, rgba(192,38,211,0.20), transparent 60%),
    radial-gradient(120% 60% at 90% 10%, rgba(25,227,214,0.08), transparent 55%),
    var(--bg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
@media (min-width: 560px) {
  body { align-items: center; padding: 24px 0; background: #050409; }
  .phone {
    min-height: min(900px, 94vh);
    max-height: 94vh;
    border-radius: 42px;
    box-shadow: 0 0 0 10px #15131c, 0 0 0 12px #2c2740, 0 40px 120px rgba(160,60,255,0.28);
  }
}

/* Top bar */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px 10px; gap: 10px;
  position: sticky; top: 0; z-index: 20;
  background: linear-gradient(180deg, rgba(11,10,16,0.96), rgba(11,10,16,0.75) 70%, transparent);
  backdrop-filter: blur(8px);
}
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; color: var(--text); }
.brand-goggles { display: inline-flex; gap: 3px; }
.brand-goggles i {
  width: 15px; height: 15px; border-radius: 50%;
  border: 2.5px solid var(--accent);
  background: radial-gradient(circle at 50% 50%, #e85bff 0%, #8e13b3 70%);
  box-shadow: 0 0 8px rgba(192,38,211,0.9), inset 0 0 4px rgba(255,255,255,0.4);
}
.brand-word { font-weight: 800; letter-spacing: -0.02em; font-size: 19px; }
.topbar-right { display: flex; align-items: center; gap: 8px; }
.wallet {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--surface-2); color: var(--text);
  border: 1px solid var(--line); border-radius: 999px;
  padding: 6px 12px; font-weight: 700; font-size: 13px; cursor: pointer;
}
.wallet-ico { color: var(--accent-2); }
.ghost-btn {
  background: transparent; color: var(--muted); border: 1px solid var(--line);
  border-radius: 999px; padding: 6px 12px; font-size: 13px; cursor: pointer;
}
.ghost-btn:hover { color: var(--text); }

/* Progress rail */
.progress-rail { height: 3px; background: var(--line); margin: 0 18px; border-radius: 3px; overflow: hidden; }
.progress-rail span { display: block; height: 100%; width: 0%; background: linear-gradient(90deg, var(--accent), var(--accent-2)); transition: width 0.35s ease; }

/* Toast */
.toast {
  position: absolute; left: 16px; right: 16px; top: 64px; z-index: 40;
  background: #2a0f16; border: 1px solid var(--bad); color: #ffd7df;
  padding: 11px 14px; border-radius: 12px; font-size: 14px; font-weight: 600;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

/* View + screens */
.view { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.screen { padding: 8px 18px 24px; animation: fade 0.3s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.screen h2 { font-size: 23px; letter-spacing: -0.02em; margin: 6px 0 6px; }
.screen .lead { color: var(--muted); font-size: 15px; line-height: 1.45; margin: 0 0 18px; }

/* Landing hero */
.hero { padding-top: 6px; }
.hero-media { position: relative; border-radius: 26px; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 20px 60px rgba(160,60,255,0.22); aspect-ratio: 1/1; background: #000; }
.hero-video { width: 100%; height: 100%; object-fit: cover; display: block; }
.live-badge {
  position: absolute; left: 12px; top: 12px; display: inline-flex; align-items: center; gap: 6px;
  background: rgba(10,8,15,0.7); border: 1px solid var(--line); backdrop-filter: blur(6px);
  padding: 5px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; color: var(--text);
}
.live-badge .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 8px var(--accent-2); animation: pulse 1.4s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }
.hero-title { font-size: 30px; line-height: 1.08; letter-spacing: -0.03em; margin: 20px 0 10px; font-weight: 850; }
.grad { background: linear-gradient(90deg, #e85bff, var(--accent-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-sub { color: var(--muted); font-size: 15.5px; line-height: 1.5; margin: 0 0 20px; }
.trust { list-style: none; padding: 0; margin: 18px 0 8px; display: grid; gap: 9px; }
.trust li { font-size: 14px; color: #cfccdd; }

/* CTA + buttons */
.cta, .btn-primary {
  display: block; width: 100%; border: 0; cursor: pointer;
  background: linear-gradient(100deg, var(--accent), #8e13b3);
  color: #fff; font-weight: 800; font-size: 17px; letter-spacing: -0.01em;
  padding: 16px; border-radius: 15px;
  box-shadow: 0 12px 30px rgba(192,38,211,0.4);
}
.cta:active, .btn-primary:active { transform: translateY(1px); }
.cta:disabled, .btn-primary:disabled, .btn-secondary:disabled {
  opacity: 0.4; cursor: not-allowed; box-shadow: none; filter: saturate(0.4);
  transform: none;
}
.btn-secondary {
  display: block; width: 100%; cursor: pointer;
  background: var(--surface-2); color: var(--text);
  border: 1px solid var(--line); font-weight: 700; font-size: 16px;
  padding: 14px; border-radius: 14px;
}
.linklike { display: block; width: 100%; background: none; border: 0; color: var(--muted); font-size: 14px; padding: 12px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.linklike:hover { color: var(--text); }

/* Feature strip */
.feature-strip { display: flex; gap: 10px; overflow-x: auto; padding: 18px 0 4px; scrollbar-width: none; }
.feature-strip::-webkit-scrollbar { display: none; }
.feat-skeleton { color: var(--muted); font-size: 13px; padding: 20px 0; }
.feat-card {
  flex: 0 0 132px; background: var(--surface); border: 1px solid var(--line);
  border-radius: 16px; padding: 13px; min-height: 92px;
}
.feat-card .ft-title { font-weight: 700; font-size: 14px; margin-bottom: 6px; }
.feat-card .ft-gate { font-size: 11.5px; color: var(--muted); }
.feat-card .ft-badge { display: inline-block; margin-top: 8px; font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 999px; background: var(--accent-soft); color: #f0a9ff; }

/* Action bar */
.actionbar {
  padding: 12px 18px calc(16px + env(safe-area-inset-bottom));
  background: linear-gradient(0deg, var(--bg) 60%, transparent);
  display: grid; gap: 10px; position: sticky; bottom: 0; z-index: 15;
}

/* Tour cards */
.cards { display: grid; gap: 12px; }
.tour-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; display: flex; gap: 13px; align-items: center; }
.tour-card .emoji { font-size: 30px; filter: drop-shadow(0 0 10px rgba(192,38,211,0.4)); }
.tour-card .tc-title { font-weight: 750; font-size: 16px; }
.tour-card .tc-body { color: var(--muted); font-size: 14px; margin-top: 3px; line-height: 1.4; }

/* Quiz */
.quiz-q { margin-bottom: 20px; }
.quiz-q h3 { font-size: 17px; margin: 0 0 11px; }
.chips { display: flex; flex-wrap: wrap; gap: 9px; }
.chip {
  border: 1px solid var(--line); background: var(--surface); color: var(--text);
  border-radius: 999px; padding: 10px 15px; font-size: 14px; font-weight: 600; cursor: pointer;
  transition: all 0.15s;
}
.chip[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); color: #f5c7ff; box-shadow: 0 0 0 1px var(--accent) inset; }

/* Photo guide */
.guide-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 8px; }
.guide-col { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.guide-col h4 { margin: 0 0 10px; font-size: 14px; }
.guide-col.ok h4 { color: var(--good); }
.guide-col.no h4 { color: var(--bad); }
.guide-col ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 13px; line-height: 1.6; }

/* Photo picker */
.dropzone {
  display: flex; flex-direction: column; align-items: center;
  border: 2px dashed var(--line); border-radius: 22px; background: var(--surface);
  padding: 30px 18px; text-align: center; cursor: pointer; transition: border-color 0.2s;
}
.dropzone:hover { border-color: var(--accent); }
.dropzone .dz-ico { font-size: 40px; }
.dropzone .dz-title { font-weight: 750; font-size: 16px; margin-top: 10px; }
.dropzone .dz-hint { color: var(--muted); font-size: 13px; margin-top: 6px; }
.photo-preview { position: relative; border-radius: 22px; overflow: hidden; border: 1px solid var(--line); aspect-ratio: 1/1; background: #000; }
.photo-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-preview .change { position: absolute; right: 10px; bottom: 10px; background: rgba(10,8,15,0.8); border: 1px solid var(--line); color: #fff; border-radius: 999px; padding: 8px 14px; font-size: 13px; font-weight: 700; cursor: pointer; }
.field-error { color: var(--bad); font-size: 13.5px; font-weight: 600; margin-top: 10px; }
.uploading { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 14px; margin-top: 12px; }

/* Consent */
.consent-box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; font-size: 14px; color: #cdcada; line-height: 1.55; }
.consent-box ul { padding-left: 18px; margin: 10px 0 0; }
.consent-check { display: flex; gap: 11px; align-items: flex-start; margin-top: 16px; cursor: pointer; font-size: 14px; }
.consent-check input { width: 22px; height: 22px; accent-color: var(--accent); margin-top: 1px; flex: 0 0 auto; }
.consent-ver { color: var(--muted); font-size: 12px; margin-top: 12px; }

/* Loader */
.loader-wrap { text-align: center; padding-top: 18px; }
.loader-face { width: 150px; height: 150px; border-radius: 50%; margin: 0 auto 20px; overflow: hidden; border: 2px solid var(--accent); box-shadow: 0 0 40px rgba(192,38,211,0.5); position: relative; }
.loader-face img { width: 100%; height: 100%; object-fit: cover; }
.loader-face::after { content: ""; position: absolute; inset: 0; background: linear-gradient(120deg, transparent 30%, rgba(25,227,214,0.25), transparent 70%); animation: sweep 1.3s linear infinite; }
@keyframes sweep { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
.loader-bar { height: 8px; background: var(--line); border-radius: 8px; overflow: hidden; margin: 8px 0 10px; }
.loader-bar span { display: block; height: 100%; width: 5%; background: linear-gradient(90deg, var(--accent), var(--accent-2)); transition: width 0.4s ease; }
.loader-pct { font-weight: 800; font-size: 15px; }
.loader-note { color: var(--muted); font-size: 14px; margin-top: 8px; }

/* Preview / result media */
.result-media { position: relative; border-radius: 24px; overflow: hidden; border: 1px solid var(--line); aspect-ratio: 1/1; background: #000; box-shadow: 0 20px 60px rgba(160,60,255,0.25); }
.result-media img { width: 100%; height: 100%; object-fit: cover; display: block; animation: breathe 3.2s ease-in-out infinite; }
@keyframes breathe { 0%,100% { transform: scale(1); } 50% { transform: scale(1.035); } }
.result-media .goggles-overlay { position: absolute; inset: 0; pointer-events: none; display: flex; align-items: center; justify-content: center; gap: 6%; opacity: 0.0; }
.wm { position: absolute; right: 10px; bottom: 10px; font-size: 11px; font-weight: 800; letter-spacing: 0.04em; color: #fff; background: rgba(10,8,15,0.55); border-radius: 8px; padding: 4px 8px; }
.ai-badge { position: absolute; left: 10px; top: 10px; font-size: 11px; font-weight: 800; color: #0b0a10; background: var(--accent-2); border-radius: 8px; padding: 4px 8px; }
.preview-caption { text-align: center; color: var(--muted); font-size: 13px; margin-top: 12px; }

/* Paywall */
.plan { display: flex; align-items: center; justify-content: space-between; gap: 10px; border: 1.5px solid var(--line); background: var(--surface); border-radius: 16px; padding: 14px 16px; cursor: pointer; margin-bottom: 10px; position: relative; }
.plan[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
.plan .pl-left .pl-name { font-weight: 750; font-size: 15.5px; }
.plan .pl-left .pl-sub { color: var(--muted); font-size: 13px; margin-top: 3px; }
.plan .pl-price { text-align: right; }
.plan .pl-now { font-weight: 800; font-size: 16px; }
.plan .pl-anchor { color: var(--muted); text-decoration: line-through; font-size: 12.5px; margin-right: 5px; }
.plan .pl-badge { position: absolute; top: -9px; right: 14px; font-size: 10.5px; font-weight: 800; letter-spacing: 0.03em; text-transform: uppercase; background: linear-gradient(90deg, var(--accent), var(--accent-2)); color: #fff; padding: 3px 9px; border-radius: 999px; }
.intro-tag { display: inline-block; font-size: 10.5px; font-weight: 800; color: var(--accent-2); border: 1px solid var(--accent-2); border-radius: 6px; padding: 1px 6px; margin-left: 6px; vertical-align: middle; }
.paywall-benefits { list-style: none; padding: 0; margin: 2px 0 16px; display: grid; gap: 7px; }
.paywall-benefits li { font-size: 14px; color: #d6d3e3; display: flex; gap: 9px; }
.paywall-benefits li::before { content: "✓"; color: var(--accent-2); font-weight: 800; }
.restore-line { text-align: center; color: var(--muted); font-size: 12px; margin-top: 10px; line-height: 1.5; }

/* Packs (credits) */
.pack { display: flex; align-items: center; justify-content: space-between; border: 1.5px solid var(--line); background: var(--surface); border-radius: 15px; padding: 14px 16px; margin-bottom: 10px; cursor: pointer; position: relative; }
.pack[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
.pack .pk-cr { font-weight: 800; font-size: 16px; }
.pack .pk-eq { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.pack .pk-price { font-weight: 800; font-size: 15px; }
.pack .pk-badge { position: absolute; top: -9px; right: 14px; font-size: 10px; font-weight: 800; text-transform: uppercase; background: var(--accent); color: #fff; padding: 3px 9px; border-radius: 999px; }

/* Checkout modal (Stripe-style dry-run) */
.modal-backdrop { position: absolute; inset: 0; background: rgba(4,3,9,0.78); z-index: 50; display: flex; align-items: flex-end; justify-content: center; backdrop-filter: blur(4px); }
.sheet { width: 100%; max-width: 440px; background: var(--surface); border-top-left-radius: 24px; border-top-right-radius: 24px; border: 1px solid var(--line); padding: 20px 18px calc(22px + env(safe-area-inset-bottom)); animation: rise 0.28s ease; }
@keyframes rise { from { transform: translateY(100%); } to { transform: none; } }
.sheet h3 { margin: 0 0 4px; font-size: 19px; }
.sheet .sh-sub { color: var(--muted); font-size: 13.5px; margin: 0 0 16px; }
.sheet-row { display: flex; justify-content: space-between; font-size: 14px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.sheet-row:last-of-type { border-bottom: 0; font-weight: 800; }
.card-mock { background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin: 14px 0; font-size: 14px; color: var(--muted); display: flex; justify-content: space-between; }
.dry-note { background: rgba(25,227,214,0.08); border: 1px solid rgba(25,227,214,0.35); color: #9ff3ea; font-size: 12.5px; border-radius: 10px; padding: 10px 12px; margin-bottom: 14px; line-height: 1.45; }

/* Result actions */
.result-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 16px 0; }
.result-actions a, .result-actions button { display: flex; align-items: center; justify-content: center; gap: 7px; text-decoration: none; background: var(--surface-2); border: 1px solid var(--line); color: var(--text); border-radius: 13px; padding: 13px; font-weight: 700; font-size: 14px; cursor: pointer; }
.getapp { display: grid; gap: 10px; margin-top: 10px; }
.store-btns { display: flex; gap: 10px; }
.store-btn { flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px; background: #fff; color: #000; border-radius: 12px; padding: 12px; font-weight: 700; font-size: 13px; text-decoration: none; border: 0; cursor: pointer; }
.cross-sell { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 15px; margin-top: 16px; }
.cross-sell h4 { margin: 0 0 4px; font-size: 15px; }
.cross-sell p { margin: 0 0 12px; color: var(--muted); font-size: 13px; }

/* Generic status (error / empty / done big states) */
.status { text-align: center; padding: 40px 10px; min-height: 62vh; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.status p { max-width: 320px; }
.status .st-ico { font-size: 54px; }
.status h2 { margin: 14px 0 6px; }
.status p { color: var(--muted); font-size: 15px; margin: 0 auto 20px; max-width: 320px; line-height: 1.5; }

.spinner { width: 20px; height: 20px; border: 3px solid var(--line); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Dev strip (shows the server-driven source of truth) */
.dev-strip { margin-top: 20px; border-top: 1px dashed var(--line); padding-top: 12px; font-size: 11.5px; color: #6f6b82; line-height: 1.6; }
.dev-strip b { color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .hero-video { display: none; }
  .result-media img, .loader-face::after, .live-badge .dot { animation: none !important; }
  .screen { animation: none; }
}
