/* Daito's Opti — sales site. Same design language as the app and the panel:
   near-black, soft dark panels, one red accent, rounded cards, red glow.
   No frameworks, no external fonts, CSP-safe (this file is the only style). */
:root {
  --bg: #0A0A0C;
  --panel: #131316;
  --panel-2: #1A1A1F;
  --border: #232329;
  --border-hot: #3A2328;
  --text: #ECECF1;
  --muted: #9A9AA3;
  --accent: #E5273A;
  --accent-hot: #FF4257;
  --accent-dim: #7E1622;
  --ok: #3DBF6B;
  --radius: 14px;
  --maxw: 1080px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 "Segoe UI", system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--text); }
img { max-width: 100%; height: auto; display: block; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.muted { color: var(--muted); }
.accent { color: var(--accent); }

/* ---------- header ---------- */
.site-head {
  position: sticky; top: 0; z-index: 40;
  background: rgba(10,10,12,.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-head .wrap {
  display: flex; align-items: center; gap: 28px;
  height: 62px;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-weight: 800; letter-spacing: 1.5px; font-size: 15px;
  text-decoration: none; white-space: nowrap;
}
.logo svg { width: 26px; height: 26px; }
.site-nav { display: flex; gap: 6px; flex: 1; }
.site-nav a {
  color: var(--muted); text-decoration: none;
  padding: 7px 13px; border-radius: 8px; font-size: 14px; font-weight: 600;
}
.site-nav a:hover { color: var(--text); background: var(--panel-2); }
@media (max-width: 720px) { .site-nav { display: none; } }

/* ---------- buttons ---------- */
.btn {
  display: inline-block; text-decoration: none; cursor: pointer;
  background: var(--panel-2); color: var(--text);
  border: 1px solid var(--border); border-radius: 10px;
  padding: 12px 26px; font-weight: 700; font-size: 15px;
  font-family: inherit;
}
.btn:hover { border-color: var(--muted); }
.btn.primary {
  background: var(--accent); border-color: var(--accent); color: #fff;
  box-shadow: 0 0 24px rgba(229,39,58,.35), 0 0 64px rgba(229,39,58,.12);
}
.btn.primary:hover { background: var(--accent-hot); border-color: var(--accent-hot); }
.btn.small { padding: 8px 16px; font-size: 13px; }
.btn.disabled, .btn.disabled:hover {
  background: var(--panel-2); border-color: var(--border); color: var(--muted);
  cursor: not-allowed; box-shadow: none; pointer-events: none;
}

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden;
  padding: 92px 0 72px;
  border-bottom: 1px solid var(--border);
}
.hero::before {
  /* red glow bleeding in from the top, like the app's corner glow */
  content: ""; position: absolute; inset: -40% -20% auto -20%; height: 90%;
  background: radial-gradient(ellipse at 50% 0%, rgba(229,39,58,.16), transparent 62%);
  pointer-events: none;
}
.hero .wrap { position: relative; text-align: center; }
.eyebrow {
  display: inline-block; color: var(--accent);
  font-size: 12px; font-weight: 800; letter-spacing: 3px; text-transform: uppercase;
  margin-bottom: 18px;
}
h1.hero-title {
  font-size: clamp(34px, 6vw, 58px); line-height: 1.12;
  font-weight: 800; letter-spacing: -.5px;
  margin-bottom: 18px;
}
/* Narrow screens: the manual line break and the 34px floor overflow a 390px
   viewport - let the title wrap naturally and ease the eyebrow tracking. */
@media (max-width: 640px) {
  h1.hero-title br { display: none; }
  h1.hero-title { font-size: clamp(28px, 8vw, 34px); }
  .eyebrow { letter-spacing: 2px; }
}
h1 .glow { color: var(--accent); text-shadow: 0 0 34px rgba(229,39,58,.55); }
.hero-sub {
  color: var(--muted); font-size: clamp(16px, 2.4vw, 19px);
  max-width: 640px; margin: 0 auto 34px;
}
.hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-bottom: 12px; }
.hero-note { font-size: 13px; color: var(--muted); }
.hero-shot {
  margin: 56px auto 0; max-width: 880px;
  border: 1px solid var(--border-hot); border-radius: var(--radius);
  box-shadow: 0 0 40px rgba(229,39,58,.18), 0 24px 80px rgba(0,0,0,.55);
  overflow: hidden; background: var(--panel);
}

/* embers: pure CSS, tiny red particles drifting up through the hero */
.embers { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.embers span {
  position: absolute; bottom: -8px;
  width: 4px; height: 4px; border-radius: 50%;
  background: var(--accent);
  filter: blur(1px);
  opacity: 0;
  animation: ember-rise 9s linear infinite;
}
.embers span:nth-child(1) { left: 8%;  animation-duration: 11s; animation-delay: 0s;   width: 3px; height: 3px; }
.embers span:nth-child(2) { left: 21%; animation-duration: 14s; animation-delay: 2.5s; }
.embers span:nth-child(3) { left: 34%; animation-duration: 9s;  animation-delay: 1.2s; width: 2px; height: 2px; }
.embers span:nth-child(4) { left: 47%; animation-duration: 13s; animation-delay: 4s; }
.embers span:nth-child(5) { left: 58%; animation-duration: 10s; animation-delay: .6s;  width: 5px; height: 5px; }
.embers span:nth-child(6) { left: 69%; animation-duration: 15s; animation-delay: 3.2s; width: 3px; height: 3px; }
.embers span:nth-child(7) { left: 81%; animation-duration: 12s; animation-delay: 1.8s; }
.embers span:nth-child(8) { left: 91%; animation-duration: 10s; animation-delay: 5s;   width: 3px; height: 3px; }
.embers span:nth-child(9) { left: 15%; animation-duration: 16s; animation-delay: 6.5s; width: 2px; height: 2px; }
@keyframes ember-rise {
  0%   { transform: translateY(0) translateX(0);        opacity: 0; }
  8%   { opacity: .85; }
  60%  { opacity: .45; }
  100% { transform: translateY(-560px) translateX(38px); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .embers span { animation: none; opacity: .18; bottom: auto; top: 30%; }
}

/* ---------- sections ---------- */
section { padding: 78px 0; border-bottom: 1px solid var(--border); }
.sec-head { text-align: center; max-width: 640px; margin: 0 auto 46px; }
.sec-head h2 { font-size: clamp(24px, 3.6vw, 34px); font-weight: 800; margin-bottom: 12px; letter-spacing: -.3px; }
.sec-head p { color: var(--muted); }

.grid { display: grid; gap: 16px; }
.grid.cols3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 860px) { .grid.cols3, .grid.cols2 { grid-template-columns: 1fr; } }

.card {
  background: var(--panel); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px;
}
.card:hover { border-color: var(--border-hot); }
.card h3 { font-size: 17px; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: 14.5px; }
.card .chip {
  display: inline-block; margin-bottom: 14px;
  color: var(--accent); background: rgba(229,39,58,.09);
  border: 1px solid rgba(229,39,58,.25); border-radius: 99px;
  font-size: 11px; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase;
  padding: 4px 12px;
}

/* how it works */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; counter-reset: step; }
@media (max-width: 860px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }
.step { position: relative; background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; }
.step::before {
  counter-increment: step; content: counter(step);
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--accent-dim); color: #fff; font-weight: 800; font-size: 14px;
  margin-bottom: 14px;
  box-shadow: 0 0 18px rgba(229,39,58,.3);
}
.step h3 { font-size: 15.5px; margin-bottom: 6px; }
.step p { color: var(--muted); font-size: 13.5px; }

/* safety */
.safety-quote {
  background: var(--panel); border: 1px solid var(--border-hot); border-left: 3px solid var(--accent);
  border-radius: var(--radius); padding: 26px 30px;
  max-width: 820px; margin: 0 auto 34px;
  color: var(--text); font-size: 16px;
}
.safety-quote small { display: block; margin-top: 12px; color: var(--muted); }
.ticks { max-width: 820px; margin: 0 auto; display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 26px; }
@media (max-width: 720px) { .ticks { grid-template-columns: 1fr; } }
.ticks li { list-style: none; color: var(--muted); font-size: 14.5px; padding-left: 26px; position: relative; }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 800; }
.shot {
  margin: 46px auto 0; max-width: 820px;
  border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden;
  background: var(--panel);
}

/* FAQ */
.faq { max-width: 760px; margin: 0 auto; }
.faq details {
  background: var(--panel); border: 1px solid var(--border);
  border-radius: 12px; margin-bottom: 10px; overflow: hidden;
}
.faq summary {
  cursor: pointer; padding: 17px 22px; font-weight: 700; font-size: 15px;
  list-style: none; position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 20px; color: var(--accent); font-weight: 800; font-size: 18px; }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 0 22px 18px; color: var(--muted); font-size: 14.5px; }

/* pricing */
.price-card {
  max-width: 460px; margin: 0 auto; text-align: center;
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--border-hot); border-radius: 18px; padding: 42px 36px;
  box-shadow: 0 0 46px rgba(229,39,58,.14);
}
.price-card .plan { color: var(--accent); font-size: 12px; font-weight: 800; letter-spacing: 3px; text-transform: uppercase; }
.price-card .amount { font-size: 54px; font-weight: 800; margin: 14px 0 2px; }
.price-card .per { color: var(--muted); font-size: 13.5px; margin-bottom: 26px; }
.price-card ul { list-style: none; text-align: left; margin: 0 auto 30px; max-width: 300px; }
.price-card li { color: var(--muted); font-size: 14px; padding: 6px 0 6px 26px; position: relative; }
.price-card li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 800; }
.price-card .fine { margin-top: 16px; font-size: 12px; color: var(--muted); }
.price-card .fine a { color: var(--muted); }

/* ---------- footer ---------- */
.site-foot { padding: 44px 0 60px; }
.site-foot .wrap { display: flex; flex-wrap: wrap; gap: 18px 34px; align-items: center; justify-content: space-between; }
.site-foot nav { display: flex; gap: 22px; flex-wrap: wrap; }
.site-foot a { color: var(--muted); text-decoration: none; font-size: 13.5px; }
.site-foot a:hover { color: var(--text); }
.site-foot .fineprint { width: 100%; color: var(--muted); font-size: 12px; opacity: .8; }

/* ---------- legal / plain pages ---------- */
.page { max-width: 760px; margin: 0 auto; padding: 70px 24px 90px; }
.page h1 { font-size: 32px; font-weight: 800; margin-bottom: 6px; }
.page .updated { color: var(--muted); font-size: 13px; margin-bottom: 38px; }
.page h2 { font-size: 19px; margin: 34px 0 10px; }
.page p, .page li { color: var(--muted); font-size: 15px; }
.page ul { padding-left: 22px; margin: 10px 0; }
.page li { margin-bottom: 6px; }
.page strong { color: var(--text); }
.page a { color: var(--accent-hot); }
.backlink { display: inline-block; margin-bottom: 30px; color: var(--muted); text-decoration: none; font-size: 14px; }
.backlink:hover { color: var(--text); }

/* 404 */
.err-wrap { min-height: 70vh; display: flex; align-items: center; justify-content: center; text-align: center; padding: 40px 20px; }
.err-code { font-size: 96px; font-weight: 800; color: var(--accent); text-shadow: 0 0 44px rgba(229,39,58,.5); line-height: 1; }
.err-wrap h1 { font-size: 24px; margin: 14px 0 8px; }
.err-wrap p { margin-bottom: 22px; }
