/* ==========================================================================
   MorphLiveCam: deep navy, one warm accent.
   Headlines: DM Serif Display. Everything else: DM Sans.
   ========================================================================== */

:root {
  --bg: #050a1c;          /* deep dark blue */
  --bg-2: #0a1230;        /* raised surface */
  --bg-3: #101a42;        /* hover / inputs */
  --line: rgba(160, 178, 235, 0.14);
  --line-strong: rgba(160, 178, 235, 0.28);
  --text: #eef1fb;
  --muted: #8f9abd;
  --dim: #66719a;
  --accent: #ff6b4a;      /* change this one value to re-brand */
  --accent-ink: #1a0b05;  /* text on the accent */
  --ok: #4ade80;
  --warn: #fbbf24;
  --danger: #f87171;

  --serif: "DM Serif Display", Georgia, "Times New Roman", serif;
  --sans: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius: 14px;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100dvh; display: flex; flex-direction: column;
  background: var(--bg); color: var(--text);
  font: 400 15px/1.6 var(--sans); -webkit-font-smoothing: antialiased;
}
main { flex: 1; }
a { color: inherit; }
[hidden] { display: none !important; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--accent-ink); }

.wrap { width: min(1180px, 100% - 40px); margin-inline: auto; }
.muted { color: var(--muted); }
.mono { font-family: ui-monospace, "SFMono-Regular", Menlo, monospace; }
h1, h2, h3, .display { font-family: var(--serif); font-weight: 400; }
section[id] { scroll-margin-top: 90px; }

/* Small uppercase label (badges, eyebrows). */
.badge-pill {
  display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: rgba(10, 18, 48, .6);
  font: 600 11px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: #c9d0ea;
}
.badge-pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px rgba(255, 107, 74, .18); }
.eyebrow-plain { display: block; font: 600 11px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 16px; }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 30; background: rgba(5, 10, 28, .82); backdrop-filter: blur(12px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.site-header.scrolled { border-bottom-color: var(--line); }
.site-header .wrap { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; height: 76px; }
.brand { justify-self: start; display: inline-flex; align-items: baseline; text-decoration: none; font: 400 26px/1 var(--serif); letter-spacing: .01em; color: var(--text); }
.brand em { font-style: italic; color: var(--accent); }
.nav { display: flex; gap: 34px; font-size: 14px; }
.nav a { text-decoration: none; color: var(--muted); transition: color .15s; }
.nav a:hover, .nav a.active { color: var(--text); }
.header-actions { justify-self: end; display: flex; gap: 22px; align-items: center; }
.header-actions .text-link { font-size: 14px; color: var(--muted); text-decoration: none; }
.header-actions .text-link:hover { color: var(--text); }
.menu-btn { display: none; background: none; border: 1px solid var(--line-strong); border-radius: 10px; padding: 6px 10px; justify-self: end; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); margin-top: 110px; padding: 34px 0 42px; font-size: 14px; color: var(--muted); }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; }
.site-footer nav { display: flex; gap: 24px; margin-left: auto; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--text); }
.site-footer .brand { font-size: 22px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; cursor: pointer; text-decoration: none; white-space: nowrap;
  border: 1px solid var(--line-strong); background: transparent; color: var(--text); border-radius: var(--radius);
  padding: 11px 20px; font: 600 15px/1.2 var(--sans); transition: background .15s, border-color .15s, transform .06s, filter .15s;
}
.btn:hover { background: var(--bg-3); border-color: rgba(160, 178, 235, .4); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: progress; }
.btn.primary, .btn.signal { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover, .btn.signal:hover { filter: brightness(1.08); background: var(--accent); }
.btn.ghost { border-color: transparent; }
.btn.outline { border-color: var(--line-strong); }
.btn.danger { border-color: rgba(248, 113, 113, .5); color: var(--danger); }
.btn.danger:hover { background: rgba(248, 113, 113, .12); }
.btn.small { padding: 8px 14px; font-size: 13px; border-radius: 11px; }
.btn.big { padding: 18px 32px; font-size: 17px; border-radius: 16px; }
.btn.block { width: 100%; }
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.text-link { text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--line-strong); }
.text-link:hover { color: var(--accent); }

/* ---------- forms ---------- */
.field { display: grid; gap: 7px; font-size: 14px; color: var(--muted); margin-bottom: 16px; }
.field > span { font-size: 13px; font-weight: 500; }
.field input, .field select, .field textarea {
  background: var(--bg); border: 1px solid var(--line-strong); border-radius: 12px; padding: 12px 14px; font-size: 15px; outline: none; width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255, 107, 74, .2); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--muted); margin-bottom: 18px; }
.check input { margin-top: 4px; accent-color: var(--accent); }
.form-error, .form-ok { padding: 11px 14px; border-radius: 12px; font-size: 14px; margin-bottom: 16px; border: 1px solid; }
.form-error { background: rgba(248, 113, 113, .1); border-color: rgba(248, 113, 113, .4); color: #fecaca; }
.form-ok { background: rgba(74, 222, 128, .1); border-color: rgba(74, 222, 128, .4); color: #bbf7d0; }

/* ---------- auth pages ---------- */
.auth { display: grid; place-items: center; padding: 72px 20px; }
.auth-card { width: min(440px, 100%); background: var(--bg-2); border: 1px solid var(--line); border-radius: 20px; padding: 36px; }
.auth-card h1 { margin: 0 0 8px; font-size: 40px; line-height: 1.05; letter-spacing: -.02em; }
.auth-card .sub { color: var(--muted); margin: 0 0 26px; font-size: 15px; }
.auth-card .alt { text-align: center; color: var(--muted); font-size: 14px; margin: 20px 0 0; }

/* ---------- home: hero ---------- */
.hero { position: relative; text-align: center; padding: 88px 0 40px; overflow: hidden; }
.hero::before { /* faint grid, fading out */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 56px 56px; opacity: .35;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000, transparent 75%);
}
.hero .wrap { position: relative; }
.hero h1 { margin: 34px auto 26px; max-width: 15em; font-size: clamp(44px, 5.4vw, 76px); line-height: 1.05; letter-spacing: -.025em; }
.hero h1 em { font-style: italic; color: var(--accent); }
.hero .lead { margin: 0 auto 36px; max-width: 40em; font-size: 17px; line-height: 1.6; color: var(--muted); }
.hero-ctas { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero-note { margin-top: 26px; font-size: 13px; color: var(--dim); }

/* Product window mock: camera area + the real studio controls. */
.app-window { margin: 64px auto 0; max-width: 1040px; text-align: left; border: 1px solid var(--line-strong); border-radius: 20px; background: var(--bg-2); overflow: hidden; box-shadow: 0 40px 120px rgba(0, 0, 0, .55); }
.app-bar { display: flex; align-items: center; gap: 8px; padding: 14px 18px; border-bottom: 1px solid var(--line); font-size: 13px; color: var(--dim); }
.app-bar i { width: 10px; height: 10px; border-radius: 50%; background: #1d2754; display: inline-block; }
.app-bar span { margin-left: 12px; }
.app-body { display: grid; grid-template-columns: 1fr 330px; }
.cam-area { position: relative; min-height: 380px; background: radial-gradient(ellipse at 50% 40%, #16224f, #070d24 70%); display: grid; place-items: center; }
.cam-area .frame { position: absolute; inset: 22px; border: 1px dashed var(--line-strong); border-radius: 12px; }
.cam-area .corner { position: absolute; font: 600 11px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; padding: 7px 10px; border-radius: 999px; background: rgba(5, 10, 28, .75); border: 1px solid var(--line-strong); }
.cam-area .tl { top: 36px; left: 36px; }
.cam-area .tr { top: 36px; right: 36px; color: var(--accent); }
.cam-area .tr::before { content: "● "; }
.cam-area .bl { bottom: 36px; left: 36px; color: var(--muted); }
.cam-area .center { text-align: center; color: var(--muted); font-size: 14px; }
.cam-area .center b { display: block; font: 400 30px/1.1 var(--serif); color: var(--text); margin-bottom: 6px; }
.controls-mock { border-left: 1px solid var(--line); padding: 20px; font-size: 14px; }
.cm-label { font: 600 11px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); margin: 0 0 10px; }
.cm-photo { display: grid; grid-template-columns: 56px 1fr; gap: 12px; align-items: center; padding: 12px; border: 1px dashed var(--line-strong); border-radius: 12px; margin-bottom: 16px; }
.cm-photo .thumb { width: 56px; height: 68px; border-radius: 8px; background: linear-gradient(160deg, #1d2a5e, #0d1536); }
.cm-photo b { display: block; font-weight: 600; }
.cm-photo span { color: var(--muted); font-size: 13px; }
.cm-row { display: flex; justify-content: space-between; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); }
.cm-tag { font: 600 10px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); padding: 5px 8px; border: 1px solid var(--line-strong); border-radius: 999px; }
.cm-switch { width: 36px; height: 20px; border-radius: 99px; background: #1d2754; position: relative; }
.cm-switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: #8f9abd; }
.cm-switch.on { background: var(--accent); }
.cm-switch.on::after { left: 19px; background: #fff; }
.cm-meter { display: flex; justify-content: space-between; align-items: baseline; padding: 16px 0; }
.cm-meter b { font: 400 30px/1 var(--serif); }
.cm-meter span { color: var(--muted); font-size: 13px; }
.cm-start { display: block; text-align: center; background: var(--accent); color: var(--accent-ink); border-radius: 12px; padding: 13px; font-weight: 700; }

/* ---------- home: "works in" row ---------- */
.works-in { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 40px; padding: 56px 0 0; color: var(--dim); font-size: 15px; font-weight: 500; }
.works-in span:first-child { color: var(--muted); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; font-weight: 600; align-self: center; }

/* ---------- sections ---------- */
.section { padding: 110px 0 0; }
.section-title { text-align: center; max-width: 720px; margin: 0 auto 52px; }
.section-title h2 { margin: 0; font-size: clamp(34px, 3.6vw, 48px); line-height: 1.1; letter-spacing: -.025em; }
.section-title h2 em { font-style: italic; color: var(--accent); }
.section-title p { margin: 16px auto 0; max-width: 36em; color: var(--muted); font-size: 16px; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.step { background: var(--bg-2); border: 1px solid var(--line); border-radius: 20px; padding: 30px; }
.step .num { font: 400 15px/1 var(--sans); font-weight: 600; color: var(--accent); letter-spacing: .1em; }
.step h3 { margin: 18px 0 10px; font-size: 22px; line-height: 1.15; letter-spacing: .01em; }
.step p { margin: 0; color: var(--muted); }

.spec { max-width: 900px; margin: 0 auto; border-top: 1px solid var(--line); }
.spec-row { display: grid; grid-template-columns: 210px 1fr auto; gap: 24px; padding: 22px 4px; border-bottom: 1px solid var(--line); align-items: baseline; }
.spec-row h3 { margin: 0; font-size: 22px; }
.spec-row p { margin: 0; color: var(--muted); }
.tag { font: 600 10px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; padding: 7px 11px; border: 1px solid var(--line-strong); border-radius: 999px; white-space: nowrap; color: var(--muted); }
.tag.always { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.tag.signal { border-color: rgba(255, 107, 74, .5); color: var(--accent); }

.apps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.app { background: var(--bg-2); border: 1px solid var(--line); border-radius: 18px; padding: 22px 24px; }
.app h3 { margin: 0 0 6px; font-size: 22px; display: flex; justify-content: space-between; gap: 10px; align-items: center; }
.app p { margin: 0; color: var(--muted); font-size: 14px; }

.cta-block { margin-top: 120px; }
.cta-block .wrap { text-align: center; padding: 72px 24px; border: 1px solid var(--line-strong); border-radius: 28px; background: radial-gradient(ellipse at 50% 0%, #15214f, var(--bg-2) 70%); }
.cta-block h2 { margin: 0 0 14px; font-size: clamp(36px, 4.4vw, 60px); line-height: 1.05; letter-spacing: -.025em; }
.cta-block h2 em { font-style: italic; color: var(--accent); }
.cta-block p { margin: 0 0 30px; color: var(--muted); }

/* ---------- pricing ---------- */
.pricing-head { text-align: center; max-width: 720px; margin: 0 auto 52px; }
.pricing-head h2 { margin: 0; font-size: clamp(34px, 3.6vw, 48px); line-height: 1.1; letter-spacing: -.025em; }
.pricing-head p { margin: 16px auto 0; color: var(--muted); font-size: 16px; max-width: 34em; }
.packs { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; }
.pack { position: relative; display: flex; flex-direction: column; padding: 30px 28px 28px; border-radius: 22px; background: var(--bg-2); border: 1px solid var(--line); }
.pack.featured { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 30px 80px -30px rgba(255, 107, 74, .45); }
.pack .badge { position: absolute; top: -13px; left: 26px; background: var(--accent); color: var(--accent-ink); font: 700 11px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; padding: 7px 12px; border-radius: 999px; }
.pack-name { font: 600 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-bottom: 18px; }
.pack-credits { display: flex; align-items: baseline; gap: 10px; }
.pack-credits .num { font: 400 58px/1 var(--serif); letter-spacing: -.01em; }
.pack-credits .unit { font: 400 22px/1 var(--serif); color: var(--muted); }
.pack-price { font-size: 20px; font-weight: 600; margin-top: 14px; }
.pack-minutes { color: var(--dim); font-size: 14px; margin-top: 4px; }
.pack-bonus { color: var(--ok); font-size: 14px; margin-top: 6px; }
.pack-features { list-style: none; padding: 0; margin: 26px 0 30px; display: grid; gap: 13px; flex: 1; font-size: 15px; color: #c9d0ea; }
.pack-features li { position: relative; padding-left: 28px; }
.pack-features li::before { content: ""; position: absolute; left: 3px; top: .38em; width: 10px; height: 6px; border-left: 2px solid var(--accent); border-bottom: 2px solid var(--accent); transform: rotate(-45deg); }
.pack .btn { padding: 15px; border-radius: 14px; }
.rate-line { text-align: center; color: var(--dim); font-size: 14px; margin-top: 24px; }
.fine { text-align: center; color: var(--dim); font-size: 14px; margin-top: 10px; }

/* ---------- FAQ ---------- */
.faq { max-width: 820px; margin: 0 auto; }
.faq details { border-bottom: 1px solid var(--line); padding: 22px 4px; }
.faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 18px; font: 400 22px/1.3 var(--serif); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 300 26px/1 var(--sans); color: var(--accent); }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 12px 0 0; max-width: 44em; color: var(--muted); }
.faq a { color: var(--accent); }

/* ---------- prose (terms/privacy) ---------- */
.prose { max-width: 760px; margin: 0 auto; padding: 64px 0 0; }
.prose h1 { font-size: clamp(40px, 5vw, 60px); line-height: 1.05; letter-spacing: -.025em; margin: 0 0 10px; }
.prose h2 { font-size: 26px; margin: 38px 0 8px; }
.prose p, .prose li { color: #c3cae4; }
.prose a { color: var(--accent); }
.prose .updated { color: var(--dim); font-size: 14px; margin-bottom: 30px; }

/* ---------- account / admin shared ---------- */
.page-head { padding: 44px 0 26px; display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-end; justify-content: space-between; }
.page-head h1 { margin: 0; font-size: clamp(36px, 4vw, 52px); line-height: 1.05; letter-spacing: -.025em; }
.grid-2 { display: grid; grid-template-columns: 1.1fr 1fr; gap: 18px; align-items: start; }
.card { background: var(--bg-2); border: 1px solid var(--line); border-radius: 20px; padding: 26px; }
.card h2 { margin: 0 0 16px; font: 600 12px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.balance-big { font: 400 60px/1 var(--serif); letter-spacing: -.01em; }
.balance-big .muted { font: 400 22px/1 var(--serif) !important; }
.balance-sub { color: var(--muted); margin: 10px 0 24px; }
.mini-packs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.mini-pack { text-align: left; background: var(--bg); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; cursor: pointer; transition: border-color .15s; }
.mini-pack:hover { border-color: var(--accent); }
.mini-pack b { display: block; font: 400 26px/1.1 var(--serif); }
.mini-pack span { color: var(--muted); font-size: 13px; }
.tabs { display: flex; gap: 6px; margin-bottom: 16px; }
.tab { background: none; border: 1px solid transparent; border-radius: 10px; padding: 7px 13px; color: var(--muted); cursor: pointer; font-size: 14px; }
.tab.active { background: var(--bg-3); border-color: var(--line); color: var(--text); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 11px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { font: 600 11px/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }
td { font-variant-numeric: tabular-nums; }
tbody tr:hover { background: rgba(160, 178, 235, .04); }
.empty { color: var(--muted); text-align: center; padding: 28px; }
.status { font: 600 10px/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; padding: 5px 9px; border-radius: 999px; background: var(--bg-3); color: var(--muted); }
.status.successful, .status.active { background: rgba(74, 222, 128, .12); color: var(--ok); }
.status.live { background: var(--accent); color: var(--accent-ink); }
.status.pending, .status.partial { background: rgba(251, 191, 36, .12); color: var(--warn); }
.status.failed, .status.suspended { background: rgba(248, 113, 113, .12); color: var(--danger); }
.status.admin { background: rgba(160, 178, 235, .16); color: #c9d0ea; }

.admin-layout { display: grid; grid-template-columns: 210px 1fr; gap: 30px; padding-top: 30px; }
.admin-nav { display: grid; gap: 4px; align-content: start; position: sticky; top: 100px; }
.admin-nav button { text-align: left; background: none; border: 1px solid transparent; border-radius: 12px; padding: 10px 14px; color: var(--muted); cursor: pointer; font-size: 15px; }
.admin-nav button.active { background: var(--bg-2); border-color: var(--line); color: var(--text); }
.admin-layout .page-head { padding-top: 0; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 18px; }
.stat { background: var(--bg-2); border: 1px solid var(--line); border-radius: 18px; padding: 20px; }
.stat .label { display: block; font-size: 13px; color: var(--muted); }
.stat .value { font: 400 34px/1.1 var(--serif); margin-top: 8px; }
.stat .hint { color: var(--dim); font-size: 13px; margin-top: 4px; }
.stat .value.ok { color: var(--ok); }
.alert { border-radius: 14px; padding: 12px 16px; margin-bottom: 14px; font-size: 14px; border: 1px solid; }
.alert.warn { background: rgba(251, 191, 36, .08); border-color: rgba(251, 191, 36, .35); color: #fde68a; }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.toolbar input, .toolbar select { background: var(--bg); border: 1px solid var(--line-strong); border-radius: 11px; padding: 9px 12px; }
.drawer { position: fixed; inset: 0 0 0 auto; width: min(580px, 100%); background: var(--bg-2); border-left: 1px solid var(--line-strong); z-index: 60; overflow-y: auto; padding: 28px; }
.drawer-backdrop { position: fixed; inset: 0; background: rgba(2, 5, 15, .6); z-index: 55; }
.drawer h2 { margin: 0; font-size: 32px; }
.drawer .card { background: var(--bg); }
.drawer .card h2 { font: 600 12px/1 var(--sans); }
.drawer .row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 12px 0; }
.drawer input { background: var(--bg-2) !important; border: 1px solid var(--line-strong) !important; color: var(--text) !important; border-radius: 10px !important; }
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 8px 12px; font-size: 14px; margin: 18px 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; }
.settings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 18px; }
.preview-box { background: var(--bg); border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 12px; padding: 14px 16px; font-size: 14px; color: var(--muted); margin-bottom: 16px; }
.preview-box b { color: var(--text); }
.pack-row input { width: 100%; background: var(--bg); border: 1px solid var(--line-strong); border-radius: 9px; padding: 7px 9px; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 16px); opacity: 0; pointer-events: none; z-index: 80;
  background: var(--bg-3); border: 1px solid var(--line-strong); color: var(--text); padding: 12px 18px; border-radius: 14px; font-size: 14px;
  transition: opacity .18s, transform .18s; max-width: min(92vw, 520px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.error { border-color: rgba(248, 113, 113, .5); color: #fecaca; }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .site-header .wrap { grid-template-columns: 1fr auto; }
  .nav { display: none; position: absolute; top: 76px; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--bg); border-bottom: 1px solid var(--line); padding: 6px 20px; }
  .nav.open { display: flex; }
  .nav a { padding: 13px 0; border-bottom: 1px solid var(--line); }
  .menu-btn { display: block; margin-left: 14px; }
  .site-header .wrap { grid-template-columns: 1fr auto auto; }
  .header-actions .text-link, .header-actions .hide-mobile { display: none; }
  .app-body { grid-template-columns: 1fr; }
  .controls-mock { border-left: 0; border-top: 1px solid var(--line); }
  .cam-area { min-height: 260px; }
  .steps, .apps, .grid-2 { grid-template-columns: 1fr; }
  .spec-row { grid-template-columns: 1fr; gap: 6px; }
  .spec-row .tag { justify-self: start; }
  .admin-layout { grid-template-columns: 1fr; }
  .admin-nav { position: static; display: flex; overflow-x: auto; }
  .site-footer nav { margin-left: 0; }
}

/* ---------- API docs ---------- */
.docs { display: grid; grid-template-columns: 200px 1fr; gap: 56px; padding-top: 48px; }
.docs-nav { position: sticky; top: 100px; align-self: start; display: grid; gap: 2px; font-size: 14px; }
.docs-nav a { text-decoration: none; color: var(--muted); padding: 7px 12px; border-left: 2px solid var(--line); }
.docs-nav a:hover { color: var(--text); border-left-color: var(--accent); }
.docs-body { min-width: 0; max-width: 820px; }
.docs-body section { padding-bottom: 40px; margin-bottom: 40px; border-bottom: 1px solid var(--line); }
.docs-body h1 { font-size: clamp(38px, 4.4vw, 58px); line-height: 1.05; letter-spacing: -.025em; margin: 0 0 18px; }
.docs-body h1 em { font-style: italic; color: var(--accent); }
.docs-body h2 { font-size: 32px; letter-spacing: -.02em; margin: 0 0 14px; }
.docs-body p, .docs-body li { color: #c3cae4; }
.docs-body .lead { font-size: 17px; color: var(--muted); }
.docs-body a { color: var(--accent); }
.docs-body code { font: 13px/1.5 ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; background: var(--bg-3); border: 1px solid var(--line); border-radius: 6px; padding: 1px 6px; color: #dfe5ff; }
.docs-body pre { background: #030716; border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; overflow-x: auto; margin: 14px 0 20px; }
.docs-body pre code { background: none; border: 0; padding: 0; font-size: 13px; line-height: 1.65; color: #cfd7f5; white-space: pre; }
.docs-body table { margin: 12px 0 18px; }
.docs-body td code { white-space: nowrap; }
.docs-body ol, .docs-body ul { padding-left: 22px; }
.docs-body li { margin-bottom: 8px; }
.endpoint { display: flex; align-items: center; gap: 12px; margin: 30px 0 8px; }
.endpoint code { font-size: 15px; background: none; border: 0; padding: 0; color: var(--text); }
.verb { font: 700 11px/1 var(--sans); letter-spacing: .08em; padding: 6px 9px; border-radius: 6px; }
.verb.get { background: rgba(74, 222, 128, .14); color: var(--ok); }
.verb.post { background: rgba(255, 107, 74, .16); color: var(--accent); }
.callout { background: var(--bg-2); border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 12px; padding: 14px 16px; }
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 18px 0 14px; }
.price-cell { background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; padding: 18px; }
.price-cell span { display: block; font-size: 12px; color: var(--muted); letter-spacing: .06em; text-transform: uppercase; font-weight: 600; }
.price-cell b { display: block; font: 400 32px/1.1 var(--serif); margin-top: 8px; }
.price-cell:first-child { border-color: var(--accent); }
.muted-cell b { color: var(--muted); }
.note { font-size: 14px; color: var(--muted) !important; }
@media (max-width: 960px) {
  .docs { grid-template-columns: 1fr; gap: 20px; }
  .docs-nav { position: static; display: flex; flex-wrap: wrap; }
  .price-grid { grid-template-columns: 1fr 1fr; }
}

.pack-price .usd { font-weight: 500; color: var(--muted); font-size: 16px; }
.mini-pack .usd { color: var(--dim); }
.status.reseller { background: rgba(255, 107, 74, .14); color: var(--accent); }

/* Continue with Google (Google's colours on a white button, per their branding guide). */
.google-btn { background: #fff; color: #1f1f1f; border-color: #fff; gap: 12px; padding: 13px 18px; }
.google-btn:hover { background: #f1f3f4; border-color: #f1f3f4; }
.google-btn svg { width: 20px; height: 20px; }
.or-divider { display: flex; align-items: center; gap: 12px; color: var(--dim); font-size: 13px; margin: 18px 0; }
.or-divider::before, .or-divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* Choose card or crypto */
.pay-modal { position: fixed; inset: 0; z-index: 70; background: rgba(2, 5, 15, .7); display: grid; place-items: center; padding: 16px; }
.pay-sheet { width: min(440px, 100%); background: var(--bg-2); border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 24px; }
.pay-sheet h3 { margin: 0 0 4px; font: 400 26px/1.2 var(--serif); }
.pay-sheet > p { margin: 0 0 18px; font-size: 14px; }
.pay-option { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 14px; text-align: left; background: var(--bg); color: var(--text); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; margin-bottom: 10px; cursor: pointer; font: inherit; transition: border-color .15s; }
.pay-option:hover, .pay-option:focus-visible { border-color: var(--accent); outline: none; }
.pay-option b { display: block; font-weight: 600; }
.pay-option small { display: block; color: var(--muted); font-size: 13px; margin-top: 2px; }
.pay-option strong { font-size: 17px; white-space: nowrap; }
.pay-sheet .btn.block { margin-top: 6px; }

/* Account: "How it works" guide */
.how-it-works { margin-bottom: 18px; padding: 0; }
.how-it-works summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 22px 26px; }
.how-it-works summary::-webkit-details-marker { display: none; }
.how-kicker { display: block; font: 600 12px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.how-title { font: 400 28px/1.1 var(--serif); }
.how-toggle::after { content: "Show guide"; font-size: 14px; color: var(--accent); }
.how-it-works[open] .how-toggle::after { content: "Hide"; }
.how-it-works[open] summary { padding-bottom: 6px; }
.how-video { max-width: 760px; margin: 12px auto 6px; width: calc(100% - 52px); aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: #000; }
.how-video iframe { width: 100%; height: 100%; border: 0; display: block; }
.how-steps { list-style: none; counter-reset: how; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 14px 0 0; padding: 0 26px; }
@media (max-width: 900px) { .how-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.how-steps li { counter-increment: how; background: var(--bg); border: 1px solid var(--line); border-radius: 14px; padding: 18px 18px 16px; }
.how-steps li::before { content: counter(how); display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-weight: 700; font-size: 14px; margin-bottom: 10px; }
.how-steps b { display: block; font-size: 16px; margin-bottom: 6px; }
.how-steps p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.6; }
.how-steps a { color: var(--accent); }
.how-steps kbd { font: 600 12px var(--sans); border: 1px solid var(--line-strong); border-bottom-width: 2px; border-radius: 5px; padding: 1px 6px; color: var(--text); }
.how-rate { color: var(--text); }
.how-note { margin: 16px 26px 24px; font-size: 13px; color: var(--dim); }
@media (max-width: 600px) {
  .how-it-works summary { padding: 18px 16px; }
  .how-steps { padding: 0 16px; grid-template-columns: 1fr; }
  .how-video { width: calc(100% - 32px); }
  .how-note { margin: 14px 16px 20px; }
}

/* ================================================================ dashboard */
.dash-body { background: var(--bg); }
.dash { display: grid; grid-template-columns: 270px minmax(0, 1fr); min-height: 100vh; }
.dash-side {
  position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 6px;
  padding: 26px 18px 22px; border-right: 1px solid var(--line); background: rgba(10, 18, 48, .55); overflow-y: auto;
}
.dash-brand { padding: 0 12px 28px; font-size: 30px; }
.dash-nav { display: flex; flex-direction: column; gap: 4px; }
.dash-nav a {
  display: flex; align-items: center; gap: 14px; padding: 13px 14px; border-radius: 12px;
  color: var(--muted); text-decoration: none; font-size: 15.5px; font-weight: 500; transition: background .15s, color .15s;
}
.dash-nav a:hover { color: var(--text); background: rgba(160, 178, 235, .06); }
.dash-nav a.active { background: var(--accent); color: var(--accent-ink); font-weight: 700; letter-spacing: .02em; }
.dash-nav svg, .dash-logout svg, .quick svg, .go-live svg { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.go-live svg { fill: currentColor; stroke: none; }
.dash-nav-sep { height: 1px; background: var(--line); margin: 14px 10px; }
.side-balance { margin-top: auto; border: 1px solid var(--line); border-radius: 16px; padding: 18px; background: var(--bg-2); }
.side-label, .stat-label { font: 600 12px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.side-credits { margin: 12px 0 10px; color: var(--muted); font-size: 14px; }
.side-credits b { font: 400 24px/1 var(--serif); color: var(--text); margin-right: 4px; }
.side-topup { color: var(--accent); text-decoration: none; font-weight: 600; font-size: 14.5px; }
.side-topup:hover { text-decoration: underline; }
.dash-logout { display: flex; align-items: center; gap: 14px; margin-top: 12px; padding: 12px 14px; background: none; border: 0; border-radius: 12px; color: var(--muted); font: 500 15.5px var(--sans); cursor: pointer; text-align: left; }
.dash-logout:hover { color: var(--text); background: rgba(160, 178, 235, .06); }

.dash-main { padding: 40px clamp(18px, 3.5vw, 48px) 60px; min-width: 0; }
.dash-mobilebar { display: none; }
.dash-banner { margin-bottom: 20px; }
.dash-head { display: flex; flex-wrap: wrap; gap: 18px; align-items: flex-start; justify-content: space-between; margin-bottom: 30px; }
.dash-head h1 { margin: 0 0 8px; font-size: clamp(34px, 4.2vw, 56px); line-height: 1.05; letter-spacing: -.02em; }
.dash-head p { margin: 0; font-size: 17px; }
.go-live { display: inline-flex; align-items: center; gap: 10px; padding: 16px 28px; font-size: 16px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; border-radius: 12px; }

.dash-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin-bottom: 22px; }
.dash-stat { background: var(--bg-2); border: 1px solid var(--line); border-radius: 18px; padding: 26px 28px; min-width: 0; }
.stat-value { font: 400 44px/1 var(--serif); margin: 26px 0 12px; letter-spacing: -.01em; overflow: hidden; text-overflow: ellipsis; }
.stat-hint { color: var(--muted); font-size: 14px; }

.dash-grid { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.dash-card { padding: 0; overflow: hidden; }
.dash-card-head { display: flex; justify-content: space-between; align-items: center; padding: 24px 28px; border-bottom: 1px solid var(--line); }
.dash-card-head h2 { margin: 0; font: 400 19px/1.2 var(--serif); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.dash-link { color: var(--accent); text-decoration: none; font-size: 15px; }
.dash-link:hover { text-decoration: underline; }
.dash-card .table-wrap table th:first-child, .dash-card .table-wrap table td:first-child { padding-left: 28px; }
.dash-card .empty { padding: 60px 28px; }
.dash-card .empty a, .dash-view .empty a { color: var(--accent); }
.quick-actions { display: flex; flex-direction: column; padding: 14px 16px 18px; }
.quick { display: flex; align-items: center; gap: 16px; padding: 15px 14px; border-radius: 12px; color: var(--text); text-decoration: none; background: none; border: 0; font: 500 16px var(--sans); cursor: pointer; text-align: left; }
.quick svg { color: var(--accent); }
.quick:hover { background: rgba(160, 178, 235, .06); }

.wallet-balance { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; justify-content: space-between; margin-bottom: 30px; }
.wallet-balance .balance-big { margin-top: 14px; }
.wallet-balance .balance-sub { margin-bottom: 0; }
.dash-section-title { font: 400 26px/1.2 var(--serif); margin: 0 0 22px; }
.dash-packs { margin-top: 16px; }
.dash-fine { font-size: 13px; margin-top: 18px; }
.profile-row { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.profile-row:last-child { border-bottom: 0; }
.profile-row span { color: var(--muted); }
.profile-row b { font-weight: 500; text-align: right; overflow-wrap: anywhere; }
.dash-view .how-it-works { padding-top: 10px; }
.dash-view .how-steps { margin-top: 20px; }
.dash-view .how-steps a { color: var(--accent); }

.dash-dialog { max-width: 620px; width: calc(100% - 32px); background: var(--bg-2); color: var(--text); border: 1px solid var(--line-strong); border-radius: 18px; padding: 28px; }
.dash-dialog::backdrop { background: rgba(2, 5, 15, .7); }
.dash-dialog h2 { margin: 0 0 14px; font: 400 26px/1.2 var(--serif); }
.dash-dialog ol { padding-left: 20px; line-height: 1.7; color: var(--muted); }
.dash-dialog strong { color: var(--text); }

@media (max-width: 1150px) {
  .dash-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dash-grid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .dash { grid-template-columns: 1fr; }
  .dash-side { position: fixed; z-index: 50; left: 0; top: 0; bottom: 0; width: min(290px, 84vw); transform: translateX(-102%); transition: transform .25s ease; background: var(--bg-2); }
  .dash-side.open { transform: none; }
  .dash-scrim { position: fixed; inset: 0; z-index: 45; background: rgba(2, 5, 15, .6); }
  .dash-main { padding: 0 16px 48px; }
  .dash-mobilebar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 0; margin-bottom: 18px; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; background: var(--bg); }
  .dash-menu { display: inline-block; color: var(--text); font-size: 18px; }
  .dash-mobilebar .brand { margin-right: auto; }
  .go-live { padding: 13px 20px; font-size: 14px; }
}
@media (max-width: 560px) {
  .dash-stats { grid-template-columns: 1fr 1fr; gap: 12px; }
  .dash-stat { padding: 18px; }
  .stat-value { font-size: 32px; margin: 16px 0 8px; }
  .stat-label { font-size: 11px; letter-spacing: .1em; }
  .dash-card-head { padding: 18px; }
  .dash-card .table-wrap table th:first-child, .dash-card .table-wrap table td:first-child { padding-left: 18px; }
}

/* ===================================================================== tour */
.tour { position: fixed; inset: 0; z-index: 90; }
.tour-spot {
  position: fixed; border-radius: 14px; pointer-events: none;
  box-shadow: 0 0 0 9999px rgba(2, 5, 15, .74), 0 0 0 2px var(--accent);
  transition: left .28s ease, top .28s ease, width .28s ease, height .28s ease;
}
.tour-pop {
  position: fixed; width: min(400px, calc(100vw - 24px)); background: var(--bg-2); border: 1px solid var(--line-strong);
  border-radius: 18px; padding: 24px 24px 18px; box-shadow: 0 24px 60px rgba(0, 0, 0, .5);
  transition: left .28s ease, top .28s ease;
}
.tour-pop.center { left: 50% !important; top: 50% !important; transform: translate(-50%, -50%); }
.tour-pop h3 { margin: 0 32px 10px 0; font: 400 26px/1.15 var(--serif); }
.tour-pop p { margin: 0 0 22px; color: var(--muted); font-size: 16px; line-height: 1.6; }
.tour-x { position: absolute; top: 12px; right: 14px; background: none; border: 0; color: var(--dim); font-size: 24px; line-height: 1; cursor: pointer; padding: 4px 6px; }
.tour-x:hover { color: var(--text); }
.tour-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tour-count { color: var(--dim); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; }
.tour-buttons { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.tour-back { background: none; border: 0; color: var(--muted); font: 500 14.5px var(--sans); cursor: pointer; padding: 8px 6px; }
.tour-back:hover { color: var(--text); }
.tour-next { border-radius: 999px; padding: 10px 18px; }
.tour-skip { display: block; margin: 14px auto 0; background: none; border: 0; color: var(--dim); font: 500 13px var(--sans); cursor: pointer; }
.tour-skip:hover { color: var(--muted); text-decoration: underline; }
@media (prefers-reduced-motion: reduce) { .tour-spot, .tour-pop, .dash-side { transition: none; } }

/* Dashboard: voice studio */
.voice-notice { display: flex; gap: 16px; align-items: flex-start; padding: 18px 20px; margin-bottom: 22px; border-radius: 16px; border: 1px solid rgba(251, 191, 36, .35); background: rgba(251, 191, 36, .08); color: var(--text); font-size: 15px; line-height: 1.6; }
.voice-notice svg { width: 26px; height: 26px; flex: none; fill: none; stroke: var(--warn); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; margin-top: 2px; }
.voice-notice b { color: var(--warn); }
.voice-status { padding: 14px 16px; border: 1px dashed var(--line-strong); border-radius: 12px; color: var(--muted); font-size: 14.5px; line-height: 1.6; margin-bottom: 14px; }
.voice-status b { color: var(--text); }
.voice-ok { color: var(--ok); font-weight: 600; }
.voice-consent { font-size: 13.5px; margin-bottom: 14px; }
.voice-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.voice-actions label.btn { cursor: pointer; }
.voice-steps { margin: 0 0 14px; padding-left: 20px; display: grid; gap: 12px; color: var(--muted); font-size: 14.5px; line-height: 1.6; }
.voice-steps b { color: var(--text); }
.voice-steps kbd { font: 600 12px var(--sans); border: 1px solid var(--line-strong); border-bottom-width: 2px; border-radius: 5px; padding: 1px 6px; color: var(--text); }

/* ---------- demo video (homepage) ---------- */
.demo .section-title { margin-bottom: 34px; }
.demo-figure { margin: 0; }
.demo-frame {
  position: relative; border-radius: 22px; overflow: hidden; background: #000;
  border: 1px solid var(--line-strong); box-shadow: 0 30px 80px #0008;
}
.demo-frame video { display: block; width: 100%; height: auto; }
.demo-chip {
  position: absolute; top: 14px; left: 14px; z-index: 2; display: inline-flex; align-items: center; gap: 7px;
  padding: 6px 11px; border-radius: 999px; background: #000000a6; border: 1px solid #ffffff2b;
  color: #fff; font: 600 11px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase;
}
.demo-chip i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.demo-figure figcaption { margin-top: 14px; text-align: center; color: var(--dim); font-size: 14px; }
.demo-figure figcaption b { color: var(--text); font-weight: 600; }
.demo-cta { text-align: center; margin: 26px 0 0; }
@media (max-width: 700px) { .demo-frame { border-radius: 16px; } }

