/* Topier base: white first, soft hues, rounded and airy. Shared by home, clip, terms, privacy. */
:root {
  --bg: #ffffff;
  --bg2: #f7f7fb;
  --card: #ffffff;
  --line: #e9e8f0;
  --line2: #d9d8e3;
  --ink: #1b1b2f;
  --muted: #5f5e74;
  --dim: #9b9ab0;
  --accent: #ff7a1a;
  --accent-hi: #ffc25a;
  --accent-2: #7b2cff;
  --magenta: #e23c96;
  --accent-ink: #ffffff;
  --brand-grad: linear-gradient(135deg, #ff7a1a 0%, #ff5e0a 45%, #e23c96 80%, #7b2cff 100%);
  --sky: linear-gradient(120deg, #e8f1ff 0%, #f3e9ff 35%, #ffe9f3 70%, #fff1e3 100%);
  --wash-lilac: #efe6ff; --wash-peach: #ffe9dc; --wash-mint: #e3f8ef; --wash-sky: #e4f0ff; --wash-rose: #ffe4ee; --wash-lemon: #fff6d6;
  --bad: #e5484d;
  --ring: 0 0 0 3px rgba(123, 44, 255, .28);
  --shadow: 0 1px 2px rgba(27, 27, 47, .04), 0 10px 30px rgba(27, 27, 47, .08);
  --shadow-lg: 0 2px 6px rgba(27, 27, 47, .05), 0 24px 60px rgba(27, 27, 47, .14);
  --radius: 18px;
}
* { box-sizing: border-box; }
html { color-scheme: light; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.55 Inter, system-ui, sans-serif; -webkit-text-size-adjust: 100%; -webkit-font-smoothing: antialiased; }
body { min-height: 100vh; padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px; }
.top { padding-top: 36px; padding-bottom: 8px; }
.brand { display: inline-block; line-height: 0; }
.brand img { height: 40px; width: auto; }
h1 { font-weight: 800; font-size: clamp(34px, 5.4vw, 56px); line-height: 1.06; letter-spacing: -.025em; margin: 18px 0 14px; }
h2 { margin: 0 0 14px; font-size: 24px; font-weight: 800; letter-spacing: -.015em; }
.lede { color: var(--muted); max-width: 640px; margin: 0; font-size: 17px; }
.card { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 24px 24px 72px; margin: 22px 0; box-shadow: var(--shadow); }
.card.quiet { padding-left: 24px; }
.step { position: absolute; left: 22px; top: 22px; width: 34px; height: 34px; border-radius: 50%; background: var(--brand-grad); color: #fff; font-weight: 800; display: grid; place-items: center; box-shadow: 0 6px 16px rgba(226, 60, 150, .3); }
.drop { display: grid; place-items: center; min-height: 140px; border: 2px dashed var(--line2); border-radius: 14px; cursor: pointer; text-align: center; padding: 16px; color: var(--muted); background: var(--bg2); transition: border-color .15s, background .15s; }
.drop.over, .drop:hover, .drop:focus-within { border-color: var(--accent-2); color: var(--ink); background: var(--wash-lilac); }
.drop input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
video { width: 100%; max-height: 420px; background: #000; border-radius: 14px; margin-top: 14px; }
.row { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 14px; margin-bottom: 14px; }
label small { font-weight: 400; color: var(--muted); }
input, select { font: inherit; color: var(--ink); background: #fff; border: 1px solid var(--line2); border-radius: 12px; padding: 11px 13px; }
input:focus-visible, select:focus-visible, button:focus-visible, a:focus-visible, .link:focus-visible { outline: none; box-shadow: var(--ring); }
input[type=color] { padding: 2px; height: 44px; width: 80px; }
input[type=range] { padding: 0; accent-color: var(--accent-2); }
.btn { font: inherit; font-weight: 700; background: var(--ink); color: #fff; border: 0; border-radius: 14px; padding: 12px 20px; cursor: pointer; text-decoration: none; display: inline-block; text-align: center; transition: transform .15s, box-shadow .15s, filter .15s; }
.btn:hover { transform: translateY(-1px); filter: brightness(1.08); box-shadow: 0 10px 24px rgba(27, 27, 47, .18); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: .5; cursor: wait; transform: none; }
.btn.big { font-size: 17px; padding: 15px 26px; background: var(--brand-grad); color: #fff; box-shadow: 0 10px 28px rgba(226, 60, 150, .32); }
.btn.ghost { background: #fff; color: var(--ink); border: 1px solid var(--line2); box-shadow: none; }
.link { font: inherit; background: none; border: 0; color: var(--accent-2); text-decoration: underline; cursor: pointer; padding: 0; }
.status { color: var(--muted); min-height: 24px; margin: 10px 0; }
.status.err { color: var(--bad); }
.hint { color: var(--muted); font-size: 14px; }
.cand { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; margin: 8px 0; transition: border-color .15s, background .15s; }
.cand.on { border-color: var(--accent-2); background: var(--wash-lilac); }
.cand .t { font-weight: 800; min-width: 130px; }
.cand .lv { flex: 1; min-width: 80px; height: 8px; background: var(--bg2); border-radius: 4px; overflow: hidden; }
.cand .lv i { display: block; height: 100%; background: var(--brand-grad); }
.chosen { font-weight: 600; }
.grid { display: grid; grid-template-columns: 1fr 220px; gap: 20px; }
.preview { text-align: center; }
.preview canvas { width: 100%; max-width: 220px; aspect-ratio: 9 / 16; border-radius: 14px; background: #000; box-shadow: var(--shadow-lg); }
.preview small { color: var(--muted); display: block; margin-top: 6px; }
.bar { height: 10px; background: var(--bg2); border-radius: 5px; overflow: hidden; margin: 6px 0 14px; }
.bar div { height: 100%; width: 0; background: var(--brand-grad); transition: width .3s; }
#out video { max-width: 320px; display: block; }
#out .btn { margin: 14px 12px 0 0; }
.facts { margin: 0; padding-left: 18px; color: var(--muted); }
.facts li { margin: 6px 0; }
.facts strong { color: var(--ink); }
.foot { color: var(--muted); font-size: 14px; padding-top: 20px; padding-bottom: calc(44px + env(safe-area-inset-bottom)); }
.foot p { margin: 6px 0; }
.foot .tiny { font-size: 13px; }
.foot a { color: var(--accent-2); }
.foot-mark { opacity: .8; vertical-align: -4px; margin-right: 6px; }
.splash { position: fixed; inset: 0; z-index: 50; background: #fff; display: grid; place-content: center; justify-items: center; gap: 22px; transition: opacity .35s; }
.splash.gone { opacity: 0; pointer-events: none; }
.splash img { width: 180px; height: auto; }
.splash-bar { width: 120px; height: 3px; border-radius: 2px; background: var(--line); overflow: hidden; }
.splash-bar i { display: block; height: 100%; width: 40%; background: var(--brand-grad); animation: slide 1s ease-in-out infinite; }
@keyframes slide { from { transform: translateX(-100%); } to { transform: translateX(300%); } }
@media (max-width: 640px) {
  .top { padding-top: 24px; }
  .brand img { height: 34px; }
  .card { padding-left: 20px; padding-top: 64px; }
  .card.quiet, .card.unsupported { padding-top: 22px; }
  .grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* accounts */
.avatar { width: 36px; height: 36px; border-radius: 50%; border: 0; padding: 0; background: var(--brand-grad); color: #fff; font-weight: 800; display: grid; place-items: center; cursor: pointer; overflow: hidden; box-shadow: 0 4px 12px rgba(226, 60, 150, .3); }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.big { width: 56px; height: 56px; font-size: 22px; }
.acct { display: flex; align-items: center; gap: 14px; margin-top: 12px; }
.btn.google { background: #fff; color: var(--ink); border: 1px solid var(--line2); width: 100%; display: flex; align-items: center; justify-content: center; gap: 10px; padding: 12px; margin-top: 14px; }
.btn.google:hover { background: var(--bg2); }
.or { display: flex; align-items: center; gap: 10px; color: var(--dim); font-size: 12px; margin: 14px 0 6px; }
.or::before, .or::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.sheet .f { display: grid; gap: 4px; margin-bottom: 10px; font-size: 13px; font-weight: 600; color: var(--muted); }
.sheet .f input { width: 100%; }
.sheet .btn.block { display: block; width: 100%; }
