@font-face {
  font-family: "Coolvetica";
  src: url("/assets/Coolvetica-Rg.otf") format("opentype");
  font-display: swap;
}

:root {
  --ink: #0f0d09;
  --ink-2: #1a1711;
  --line: #3a3326;
  --cream: #f4efe2;
  --white: #ffffff;
  --gold: #b68639;
  --gold-2: #d1a24f;
  --radius: 18px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--ink);
  color: var(--white);
  font: 16px/1.5 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
h1, h2 { font-family: "Coolvetica", Inter, sans-serif; font-weight: 400; letter-spacing: 0.2px; line-height: 1.08; margin: 0; }
h1 { font-size: clamp(34px, 9vw, 48px); }
h2 { font-size: clamp(26px, 7vw, 34px); }
p { margin: 0; }
a { color: var(--gold-2); }
.gold { color: var(--gold-2); }

.logo { display: block; width: 150px; height: auto; }

/* ---------- buttons ---------- */
.btn {
  appearance: none; border: 0; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; min-height: 56px; padding: 14px 22px;
  border-radius: 999px; font: 700 17px/1.2 Inter, sans-serif; text-decoration: none;
  background: var(--gold); color: var(--ink);
  transition: transform .08s ease, background .15s ease;
}
.btn:active { transform: scale(.98); }
.btn:hover { background: var(--gold-2); }
.btn[disabled] { cursor: default; background: var(--line); color: var(--white); }
.btn.ghost { background: transparent; color: var(--white); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn.ghost:hover { box-shadow: inset 0 0 0 1.5px var(--gold); }
.btn.light { background: var(--white); color: var(--ink); }
.btn.small { min-height: 40px; width: auto; padding: 8px 16px; font-size: 14px; }
.linkbtn { background: none; border: 0; color: var(--white); font: 600 15px Inter, sans-serif; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; padding: 10px; }

/* ---------- recorder screens ---------- */
.screen { display: none; min-height: 100dvh; }
.screen.on { display: flex; }
.page {
  flex-direction: column; width: 100%; max-width: 520px; margin: 0 auto;
  padding: calc(28px + var(--safe-t)) 20px calc(24px + var(--safe-b));
  gap: 22px;
}
.page .grow { flex: 1; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.center { align-items: center; justify-content: center; text-align: center; }

.qlist { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.qlist li {
  display: flex; gap: 14px; align-items: flex-start;
  background: var(--ink-2); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px;
}
.qlist .n {
  flex: none; width: 26px; height: 26px; border-radius: 50%; background: var(--gold); color: var(--ink);
  font: 800 13px/26px Inter, sans-serif; text-align: center;
}
.tips { display: flex; flex-wrap: wrap; gap: 8px; }
.tip { border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; font-size: 14px; }

.banner { background: var(--cream); color: var(--ink); border-radius: 14px; padding: 14px 16px; font-size: 15px; }
.banner b { display: block; margin-bottom: 2px; }

/* camera */
#s-camera { position: fixed; inset: 0; background: #000; flex-direction: column; }
#preview { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.cam-top { position: relative; z-index: 2; padding: calc(12px + var(--safe-t)) 12px 0; display: flex; flex-direction: column; gap: 10px; }
.cam-bar { display: flex; justify-content: space-between; align-items: center; }
.pill { background: rgba(15,13,9,.75); color: var(--white); border-radius: 999px; padding: 6px 12px; font: 700 14px Inter, sans-serif; display: inline-flex; gap: 8px; align-items: center; }
.pill .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--gold); }
.rec .pill .dot { animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.qcard {
  background: var(--cream); color: var(--ink); border-radius: var(--radius); padding: 14px 14px 12px 16px;
  display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; align-items: center;
  box-shadow: 0 8px 30px rgba(0,0,0,.35);
}
.qcard .k { grid-column: 1 / -1; font: 800 12px Inter, sans-serif; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.qcard .q { font: 700 19px/1.3 Inter, sans-serif; }
.qnav { display: flex; gap: 6px; }
.qnav button {
  width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--ink); color: var(--white);
  font: 700 20px Inter, sans-serif; cursor: pointer;
}
.qnav button[disabled] { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.cam-bottom {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2;
  padding: 16px 20px calc(22px + var(--safe-b));
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  background: linear-gradient(transparent, rgba(0,0,0,.55));
}
.recbtn {
  width: 84px; height: 84px; border-radius: 50%; border: 5px solid var(--white); background: transparent;
  display: grid; place-items: center; cursor: pointer; padding: 0;
}
.recbtn i { width: 64px; height: 64px; border-radius: 50%; background: var(--gold); transition: all .2s ease; }
.rec .recbtn i { width: 32px; height: 32px; border-radius: 8px; }
.cam-bottom .side { display: flex; }
.cam-bottom .side.r { justify-content: flex-end; }
.countdown {
  position: absolute; inset: 0; z-index: 3; display: none; place-items: center;
  font: 400 160px/1 Coolvetica, Inter, sans-serif; color: var(--white); text-shadow: 0 4px 30px rgba(0,0,0,.5);
}
.countdown.on { display: grid; }
.limit { font: 600 13px Inter, sans-serif; }

/* review */
.player { width: 100%; max-height: 62dvh; border-radius: var(--radius); background: #000; object-fit: contain; }

/* consent */
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-weight: 700; font-size: 14px; }
.field input {
  width: 100%; min-height: 52px; padding: 12px 14px; border-radius: 12px;
  border: 1.5px solid var(--line); background: var(--ink-2); color: var(--white); font: 500 17px Inter, sans-serif;
}
.field input:focus { outline: none; border-color: var(--gold); }
.release { background: var(--ink-2); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; font-size: 14px; line-height: 1.55; }
.check { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; cursor: pointer; font-size: 16px; }
.check input { appearance: none; flex: none; width: 26px; height: 26px; margin: 0; border-radius: 7px; border: 2px solid var(--white); background: transparent; display: grid; place-items: center; cursor: pointer; }
.check input:checked { background: var(--gold); border-color: var(--gold); }
.check input:checked::after { content: ""; width: 7px; height: 13px; border: solid var(--ink); border-width: 0 3px 3px 0; transform: rotate(45deg) translate(-1px, -1px); }
.check .req { font-weight: 700; }
.err { background: var(--white); color: var(--ink); border-left: 5px solid var(--gold); border-radius: 10px; padding: 12px 14px; font-weight: 600; display: none; }
.err.on { display: block; }

/* upload */
.bar { height: 14px; border-radius: 999px; background: var(--ink-2); border: 1px solid var(--line); overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; background: var(--gold); transition: width .3s ease; }
.big { font: 400 64px/1 Coolvetica, Inter, sans-serif; }
.check-mark { width: 84px; height: 84px; border-radius: 50%; background: var(--gold); display: grid; place-items: center; }
.check-mark::after { content: ""; width: 20px; height: 38px; border: solid var(--ink); border-width: 0 7px 7px 0; transform: rotate(45deg) translate(-3px, -3px); }
.spinner { width: 36px; height: 36px; border-radius: 50%; border: 4px solid var(--line); border-top-color: var(--gold); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.hidden { display: none !important; }
