/* ============================================================
   Totteta — "Studio-grade capture instrument"
   High-contrast technical-editorial redesign.
   Same content as docs/landing, new visual language.
   ============================================================ */

@font-face {
  font-family: "Totteta Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("assets/fonts/NotoSansJP-wght.ttf") format("truetype");
}

:root {
  /* Neutrals — cool paper + near-black ink */
  --paper: #eef0f4;
  --paper-2: #f7f8fb;
  --card: #ffffff;
  --ink: #0a0c12;
  --ink-2: #2a3142;
  --muted: #6b7385;
  --line: rgba(10, 12, 18, 0.12);
  --line-soft: rgba(10, 12, 18, 0.07);

  /* Signal accent (electric blue) + tiny REC accent (coral) */
  --accent: #1452ff;
  --accent-press: #0c3bd6;
  --accent-soft: rgba(20, 82, 255, 0.10);
  --accent-ink: #0a2a8c;
  --rec: #ff4332;

  /* Night (studio) */
  --night: #0a0c12;
  --night-2: #12151f;

  --font-jp: "Totteta Sans", "Noto Sans JP", -apple-system, BlinkMacSystemFont,
    "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  --font-mono: ui-monospace, "SF Mono", "JetBrains Mono", "Roboto Mono", Menlo, Consolas, monospace;

  --gutter: clamp(20px, 5vw, 64px);
  --maxw: 1200px;
  --radius: 18px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

* { box-sizing: border-box; }

html {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  overscroll-behavior-x: none;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  width: 100%;
  max-width: 100%;
  color: var(--ink-2);
  font-family: var(--font-jp);
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  background: var(--paper);
  background-image:
    radial-gradient(120% 90% at 88% -10%, rgba(20, 82, 255, 0.10), transparent 55%),
    radial-gradient(90% 70% at -5% 0%, rgba(20, 82, 255, 0.06), transparent 50%);
  background-attachment: fixed;
  line-height: 1.75;
  position: relative;
  overflow-x: hidden;
  overscroll-behavior-x: none;
  touch-action: pan-y;
}

.page-top-anchor {
  position: absolute;
  top: 0;
  left: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}

@supports (overflow: clip) {
  html,
  body {
    overflow-x: clip;
  }
}

a { color: inherit; text-decoration: none; }
a, button, summary { cursor: pointer; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

svg {
  width: 24px; height: 24px;
  fill: none; stroke: currentColor;
  stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.7;
}

img { max-width: 100%; height: auto; display: block; }

.shell {
  width: min(100% - calc(var(--gutter) * 2), var(--maxw));
  max-width: 100%;
  margin-inline: auto;
}

/* Faint film-grain / paper texture overlay */
.grain {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image:
    repeating-linear-gradient(0deg, rgba(10,12,18,0.018) 0 1px, transparent 1px 3px);
  mix-blend-mode: multiply;
}

main {
  position: relative;
  z-index: 1;
  max-width: 100%;
  overflow-x: hidden;
}

.topbar,
.section,
.download-banner,
.site-footer {
  max-width: 100%;
  overflow-x: hidden;
}

@supports (overflow: clip) {
  main,
  .topbar,
  .section,
  .download-banner,
  .site-footer {
    overflow-x: clip;
  }
}

/* ---------- Mono technical labels ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 22px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-ink);
}

.rec-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--rec);
  box-shadow: 0 0 0 0 rgba(255, 67, 50, 0.55);
  animation: rec-pulse 2s var(--ease) infinite;
}
@keyframes rec-pulse {
  0% { box-shadow: 0 0 0 0 rgba(255, 67, 50, 0.5); }
  70% { box-shadow: 0 0 0 7px rgba(255, 67, 50, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 67, 50, 0); }
}

/* ============================================================
   TOPBAR
   ============================================================ */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 14px 0;
  background: color-mix(in srgb, var(--paper) 78%, transparent);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line-soft);
}
.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-width: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  font-size: 21px;
  font-weight: 900;
  letter-spacing: -0.02em;
  min-width: 0;
}
.brand-name { line-height: 1; }

.brand-mark {
  display: inline-flex;
  align-items: flex-end;
  justify-content: center;
  gap: 3px;
  width: 30px; height: 30px;
  color: var(--accent);
}
.brand-mark i {
  display: block;
  width: 4px;
  border-radius: 999px;
  background: currentColor;
  transform-origin: bottom;
  animation: eq 1.4s var(--ease) infinite;
}
.brand-mark i:nth-child(1) { height: 14px; animation-delay: -0.1s; }
.brand-mark i:nth-child(2) { height: 26px; animation-delay: -0.5s; }
.brand-mark i:nth-child(3) { height: 20px; animation-delay: -0.2s; }
.brand-mark i:nth-child(4) { height: 29px; animation-delay: -0.7s; }
.brand-mark i:nth-child(5) { height: 12px; animation-delay: -0.35s; }
@keyframes eq {
  0%, 100% { transform: scaleY(0.45); }
  50% { transform: scaleY(1); }
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-inline: auto;
}
.nav-links a {
  position: relative;
  padding: 9px 14px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink-2);
  border-radius: 999px;
  transition: color 0.2s, background 0.2s;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 14px; right: 14px; bottom: 5px;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s var(--ease);
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after,
.nav-links a[aria-current="page"]::after { transform: scaleX(1); }
.nav-links a[aria-current="page"] { color: var(--ink); }

.download-pill {
  flex-shrink: 0;
  padding: 11px 20px;
  font-size: 14.5px;
  font-weight: 800;
  color: #fff;
  background: var(--ink);
  border-radius: 999px;
  letter-spacing: 0.01em;
  transition: transform 0.2s var(--ease), background 0.2s, box-shadow 0.2s;
}
.download-pill:hover {
  transform: translateY(-2px);
  background: var(--accent);
  box-shadow: 0 12px 26px rgba(20, 82, 255, 0.32);
}

.menu-toggle {
  display: none;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  color: var(--ink);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: 0 12px 24px -18px rgba(10, 12, 18, 0.35);
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transition: transform 0.22s var(--ease), opacity 0.22s var(--ease);
}
.menu-toggle:hover {
  border-color: var(--ink);
  box-shadow: 0 16px 28px -20px rgba(10, 12, 18, 0.45);
}
.topbar.is-menu-open .menu-toggle span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.topbar.is-menu-open .menu-toggle span:nth-child(2) {
  opacity: 0;
}
.topbar.is-menu-open .menu-toggle span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
  display: none;
  min-width: 0;
  max-height: 0;
  margin-top: 0;
  padding: 0;
  opacity: 0;
  pointer-events: none;
  overflow: hidden;
  transform: translateY(-6px);
  transition: max-height 0.24s var(--ease), opacity 0.2s var(--ease), transform 0.2s var(--ease), padding 0.2s var(--ease), margin-top 0.2s var(--ease);
}
.mobile-menu a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 13px;
  color: var(--ink-2);
  font-size: 14.5px;
  font-weight: 800;
  border-radius: 12px;
  overflow-wrap: anywhere;
  transition: background 0.2s, color 0.2s;
}
.mobile-menu a:hover,
.mobile-menu a[aria-current="page"] {
  color: var(--accent-ink);
  background: var(--accent-soft);
}
.mobile-menu .mobile-download {
  justify-content: center;
  margin-top: 4px;
  color: #fff;
  background: var(--ink);
}
.mobile-menu .mobile-download:hover {
  color: #fff;
  background: var(--accent);
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 15px 24px;
  border-radius: 14px;
  font-weight: 800;
  font-size: 16px;
  letter-spacing: 0.01em;
  max-width: 100%;
  transition: transform 0.2s var(--ease), box-shadow 0.2s, background 0.2s, border-color 0.2s;
}
.btn svg { width: 22px; height: 22px; }
.btn > span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.btn small {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  opacity: 0.78;
  margin-top: 2px;
}
.btn-primary {
  color: #fff;
  background: linear-gradient(180deg, var(--accent), var(--accent-press));
  box-shadow: 0 14px 30px rgba(20, 82, 255, 0.32), inset 0 1px 0 rgba(255,255,255,0.22);
}
.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 44px rgba(20, 82, 255, 0.4), inset 0 1px 0 rgba(255,255,255,0.22);
}
.btn-ghost {
  color: var(--ink);
  background: transparent;
  border: 1.5px solid var(--line);
}
.btn-ghost:hover {
  transform: translateY(-3px);
  border-color: var(--ink);
  background: var(--card);
}
.btn-lg { padding: 18px 34px; font-size: 17px; border-radius: 16px; }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  padding: clamp(48px, 8vw, 96px) 0 clamp(40px, 6vw, 72px);
}
.hero::before {
  /* hairline grid backdrop */
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(var(--line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-soft) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(120% 80% at 50% 0%, #000 30%, transparent 80%);
  mask-image: radial-gradient(120% 80% at 50% 0%, #000 30%, transparent 80%);
  opacity: 0.7;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}

.hero-copy { max-width: 620px; }

h1#hero-title {
  margin: 0 0 26px;
  font-size: clamp(30px, 8.4vw, 82px);
  font-weight: 900;
  line-height: 1.04;
  letter-spacing: -0.035em;
  color: var(--ink);
}
/* Each line stays on one line — never break "を、" or "に。" onto a new row. */
h1#hero-title .line { display: block; white-space: nowrap; }
.accent-line {
  position: relative;
  width: fit-content;
}
.accent-line::after {
  /* electric underline sweep — sits clearly below the glyphs */
  content: "";
  position: absolute;
  left: 0; bottom: -0.12em;
  width: 100%; height: 4px;
  background: var(--accent);
  border-radius: 4px;
  transform: scaleX(0);
  transform-origin: left;
  animation: sweep 0.9s var(--ease) 0.7s forwards;
}
@keyframes sweep { to { transform: scaleX(1); } }

.lede {
  margin: 0 0 32px;
  font-size: clamp(15.5px, 1.4vw, 17.5px);
  color: var(--ink-2);
  max-width: 56ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
}

.privacy-note {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 14px;
  padding: 8px 14px 8px 11px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--accent-ink);
  background: var(--accent-soft);
  border-radius: 999px;
  width: fit-content;
}
.privacy-note svg { width: 18px; height: 18px; }

.requirements-note {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--muted);
}
.requirements-note span { position: relative; padding-left: 16px; }
.requirements-note span::before {
  content: "";
  position: absolute;
  left: 0; top: 0.62em;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.7;
}

/* ---- hero device ---- */
.hero-visual { perspective: 1600px; }
.device-frame {
  position: relative;
  border-radius: 22px;
  padding: 10px;
  background: linear-gradient(150deg, #ffffff, #e7ebf3);
  border: 1px solid rgba(255,255,255,0.7);
  box-shadow:
    0 2px 4px rgba(10,12,18,0.05),
    0 40px 80px -28px rgba(20, 50, 120, 0.45),
    0 12px 30px -16px rgba(10,12,18,0.3);
  transform: rotateY(-7deg) rotateX(3deg) translateZ(0);
  transition: transform 0.6s var(--ease);
  will-change: transform;
}
.device-frame:hover { transform: rotateY(-2deg) rotateX(1deg) scale(1.012); }
.device-frame .app-shot {
  width: 100%;
  height: auto;
  border-radius: 14px;
  border: 1px solid var(--line-soft);
}
.live-badge {
  position: absolute;
  top: -13px; left: 22px;
  z-index: 2;
  display: inline-flex;
  align-items: flex-end;
  gap: 3px;
  height: 26px;
  padding: 0 13px;
  background: var(--ink);
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(10,12,18,0.28);
}
.live-badge i {
  display: block;
  width: 3px;
  border-radius: 999px;
  background: #6f93ff;
  margin-bottom: 9px;
  transform-origin: bottom;
  animation: eq 1.3s var(--ease) infinite;
}
.live-badge i:nth-child(1){ height: 7px; background: var(--rec); animation-delay: -.1s; }
.live-badge i:nth-child(2){ height: 13px; animation-delay: -.5s; }
.live-badge i:nth-child(3){ height: 9px; animation-delay: -.25s; }
.live-badge i:nth-child(4){ height: 14px; animation-delay: -.7s; }

/* ============================================================
   SPEC STRIP (hero key features)
   ============================================================ */
.spec-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin: clamp(40px, 6vw, 72px) 0 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--card) 86%, transparent);
  overflow: hidden;
  backdrop-filter: blur(6px);
}
.spec {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 26px 24px;
  border-right: 1px solid var(--line-soft);
  transition: background 0.25s;
}
.spec:last-child { border-right: 0; }
.spec:hover { background: var(--accent-soft); }
.spec svg {
  width: 26px; height: 26px;
  color: var(--accent);
  margin-bottom: 8px;
}
.spec strong { font-size: 16.5px; font-weight: 800; color: var(--ink); letter-spacing: -0.01em; }
.spec span { font-size: 13.5px; color: var(--muted); }

/* ============================================================
   SECTION SCAFFOLD
   ============================================================ */
.section { padding: clamp(64px, 9vw, 120px) 0; }

.section-head {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: clamp(34px, 5vw, 56px);
}
.section-head h2,
.faq-aside h2,
.reason-copy h2 {
  margin: 0;
  font-size: clamp(28px, 4.2vw, 46px);
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: -0.03em;
  color: var(--ink);
}

/* waveform divider mark */
.waveline {
  display: inline-flex;
  align-items: flex-end;
  gap: 4px;
  height: 30px;
}
.waveline i {
  display: block;
  width: 5px;
  border-radius: 999px;
  background: var(--accent);
  opacity: 0.85;
  transform-origin: bottom;
  animation: eq 1.6s var(--ease) infinite;
}
.waveline i:nth-child(1) { height: 12px; animation-delay: -0.2s; }
.waveline i:nth-child(2) { height: 26px; animation-delay: -0.6s; }
.waveline i:nth-child(3) { height: 18px; animation-delay: -0.1s; }
.waveline i:nth-child(4) { height: 30px; animation-delay: -0.8s; }
.waveline i:nth-child(5) { height: 16px; animation-delay: -0.35s; }
.waveline i:nth-child(6) { height: 24px; animation-delay: -0.5s; }
.waveline i:nth-child(7) { height: 10px; animation-delay: -0.15s; }

/* ============================================================
   USECASES
   ============================================================ */
.usecases { background: var(--paper-2); border-block: 1px solid var(--line-soft); }
.usecase-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.usecase {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 28px 26px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.3s var(--ease), box-shadow 0.3s, border-color 0.3s;
}
.usecase::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--accent);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.32s var(--ease);
}
.usecase:hover {
  transform: translateY(-5px);
  border-color: transparent;
  box-shadow: 0 22px 48px -22px rgba(20, 50, 120, 0.4);
}
.usecase:hover::before { transform: scaleY(1); }
.usecase svg { width: 30px; height: 30px; color: var(--accent); margin-bottom: 6px; }
.usecase strong { font-size: 17px; font-weight: 800; color: var(--ink); letter-spacing: -0.01em; }
.usecase span { font-size: 14px; color: var(--muted); }

/* ============================================================
   REASON / FEATURES
   ============================================================ */
.reason-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.82fr);
  gap: clamp(36px, 5vw, 76px);
  align-items: start;
}
.reason-copy h2 { margin-bottom: 22px; }
.reason-lede {
  margin: 0 0 34px;
  font-size: 16.5px;
  color: var(--ink-2);
  max-width: 48ch;
}
.reason-points { display: grid; gap: 2px; }
.reason-points article {
  display: grid;
  gap: 5px;
  padding: 20px 0;
  border-top: 1px solid var(--line);
}
.reason-points article:last-child { border-bottom: 1px solid var(--line); }
.reason-points strong {
  position: relative;
  padding-left: 22px;
  font-size: 17px;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.reason-points strong::before {
  content: "";
  position: absolute;
  left: 0; top: 0.52em;
  width: 10px; height: 10px;
  border-radius: 50%;
  border: 3px solid var(--accent);
}
.reason-points span { color: var(--ink-2); font-size: 15px; padding-left: 22px; }

/* workflow signal-chain panel */
.workflow {
  position: sticky;
  top: 92px;
  padding: 28px;
  background: linear-gradient(165deg, #ffffff, var(--paper-2));
  color: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: 0 30px 60px -36px rgba(20, 50, 120, 0.32);
  overflow: hidden;
}
.workflow::after {
  content: "";
  position: absolute;
  right: -50px; top: -50px;
  width: 190px; height: 190px;
  background: radial-gradient(circle, rgba(20,82,255,0.12), transparent 70%);
  filter: blur(6px);
}
.workflow-head {
  position: relative;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 20px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.workflow-head span {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.workflow-head strong { font-size: 18px; font-weight: 800; color: var(--ink); }
.workflow-list { list-style: none; margin: 0; padding: 0; position: relative; }
.workflow-list::before {
  content: "";
  position: absolute;
  left: 23px; top: 26px; bottom: 26px;
  width: 2px;
  background: linear-gradient(var(--accent), var(--accent-soft));
}
.workflow-list li {
  position: relative;
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 18px 0;
}
.step-no {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 46px; height: 46px;
  font-family: var(--font-mono);
  font-size: 15px;
  font-weight: 700;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid rgba(20, 82, 255, 0.3);
  border-radius: 13px;
}
.workflow-list strong { display: block; font-size: 16.5px; font-weight: 800; color: var(--ink); }
.workflow-list p { margin: 3px 0 0; font-size: 14px; color: var(--muted); line-height: 1.6; }

/* ============================================================
   FAQ
   ============================================================ */
.faq { background: var(--paper-2); border-block: 1px solid var(--line-soft); }
.faq-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.5fr) minmax(0, 1fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: start;
}
.faq-aside {
  position: sticky;
  top: 92px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.faq-list { display: grid; gap: 0; }
.faq-list details {
  border-top: 1px solid var(--line);
  padding: 4px 0;
  min-width: 0;
}
.faq-list details:last-child { border-bottom: 1px solid var(--line); }
.faq-list summary {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 4px;
  font-size: 16.5px;
  font-weight: 700;
  color: var(--ink);
  min-width: 0;
  overflow-wrap: anywhere;
  transition: color 0.2s;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::before {
  content: "";
  flex-shrink: 0;
  width: 22px; height: 22px;
  background:
    linear-gradient(var(--accent), var(--accent)) center / 12px 2px no-repeat,
    linear-gradient(var(--accent), var(--accent)) center / 2px 12px no-repeat;
  transition: transform 0.3s var(--ease);
}
.faq-list details[open] summary::before { transform: rotate(135deg); }
.faq-list summary:hover { color: var(--accent); }
.faq-list details p {
  margin: 0;
  padding: 0 4px 24px 38px;
  color: var(--ink-2);
  font-size: 15px;
  line-height: 1.85;
  animation: fade-up 0.4s var(--ease);
}
.faq-list details a { color: var(--accent); font-weight: 700; border-bottom: 1px solid var(--accent-soft); }
.faq-list details a:hover { border-color: var(--accent); }

/* ============================================================
   DOWNLOAD BANNER (studio finale)
   ============================================================ */
.download-banner {
  position: relative;
  padding: clamp(64px, 9vw, 112px) 0;
  background: linear-gradient(165deg, var(--night), #0e1320 60%, #0a0c12);
  color: #fff;
  overflow: hidden;
}
.download-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(100% 100% at 50% 0%, #000, transparent 75%);
  mask-image: radial-gradient(100% 100% at 50% 0%, #000, transparent 75%);
}
.download-banner::after {
  content: "";
  position: absolute;
  left: 50%; bottom: -120px;
  transform: translateX(-50%);
  width: 720px; height: 320px;
  background: radial-gradient(circle, rgba(20,82,255,0.55), transparent 64%);
  filter: blur(20px);
}
.download-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 22px;
  min-width: 0;
  max-width: 100%;
}
.download-mark {
  display: inline-flex;
  align-items: flex-end;
  gap: 5px;
  height: 52px;
  color: #6f93ff;
}
.download-mark i {
  display: block;
  width: 6px;
  border-radius: 999px;
  background: currentColor;
  transform-origin: bottom;
  animation: eq 1.5s var(--ease) infinite;
}
.download-mark i:nth-child(odd) { background: var(--accent); }
.download-mark i:nth-child(1){height:18px;animation-delay:-.1s}
.download-mark i:nth-child(2){height:40px;animation-delay:-.6s}
.download-mark i:nth-child(3){height:28px;animation-delay:-.3s}
.download-mark i:nth-child(4){height:48px;animation-delay:-.9s}
.download-mark i:nth-child(5){height:22px;animation-delay:-.2s}
.download-mark i:nth-child(6){height:44px;animation-delay:-.7s}
.download-mark i:nth-child(7){height:30px;animation-delay:-.45s}
.download-mark i:nth-child(8){height:38px;animation-delay:-.55s}
.download-mark i:nth-child(9){height:16px;animation-delay:-.25s}
.download-banner h2 {
  margin: 0;
  font-size: clamp(28px, 4.6vw, 52px);
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.download-banner p { margin: 0; font-size: 17px; color: #b9c2d8; }
.download-banner .btn-primary { margin-top: 8px; }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { padding: 40px 0; background: var(--paper); }
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  min-width: 0;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.footer-nav { display: flex; flex-wrap: wrap; gap: 4px 8px; }
.footer-nav a {
  padding: 8px 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  border-radius: 999px;
  transition: color 0.2s, background 0.2s;
}
.footer-nav a:hover { color: var(--ink); background: var(--accent-soft); }

/* ============================================================
   REVEAL MOTION
   ============================================================ */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

/* Above-the-fold: animate in on load */
.hero .reveal {
  opacity: 0;
  animation: fade-up 0.7s var(--ease) forwards;
  animation-delay: calc(var(--d, 0) * 90ms + 80ms);
}
.hero .reveal[data-d] { --d: attr(data-d number, 0); }
.hero .reveal[data-d="0"] { animation-delay: 80ms; }
.hero .reveal[data-d="1"] { animation-delay: 170ms; }
.hero .reveal[data-d="2"] { animation-delay: 260ms; }
.hero .reveal[data-d="3"] { animation-delay: 350ms; }
.hero .reveal[data-d="4"] { animation-delay: 440ms; }
.hero .reveal[data-d="5"] { animation-delay: 530ms; }

/* Below-the-fold: reveal on scroll (only when JS active) */
.js .section .reveal,
.js .download-banner .reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
  transition-delay: calc(var(--rd, 0) * 70ms);
}
.js .reveal[data-d="1"] { --rd: 1; }
.js .reveal[data-d="2"] { --rd: 2; }
.js .reveal[data-d="3"] { --rd: 3; }
.js .reveal[data-d="4"] { --rd: 4; }
.js .reveal[data-d="5"] { --rd: 5; }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1000px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { order: -1; max-width: 560px; }
  .device-frame { transform: none; }
  .reason-grid { grid-template-columns: 1fr; }
  .workflow { position: static; }
  .faq-grid { grid-template-columns: 1fr; }
  .faq-aside { position: static; flex-direction: row; align-items: center; }
  .spec-strip { grid-template-columns: 1fr 1fr; }
  .spec:nth-child(2) { border-right: 0; }
  .spec:nth-child(1), .spec:nth-child(2) { border-bottom: 1px solid var(--line-soft); }
}

@media (max-width: 720px) {
  .topbar { padding: 12px 0; }
  .topbar-inner { gap: 10px; }
  .nav-links { display: none; }
  .download-pill {
    margin-left: auto;
    padding: 10px 16px;
    font-size: 13.5px;
  }
  .menu-toggle { display: inline-flex; }
  .mobile-menu {
    display: grid;
    gap: 2px;
  }
  .topbar.is-menu-open .mobile-menu {
    max-height: 360px;
    margin-top: 10px;
    padding: 10px;
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
    background: color-mix(in srgb, var(--paper) 92%, #fff);
    border: 1px solid var(--line-soft);
    border-radius: 18px;
    box-shadow: 0 22px 48px -34px rgba(10, 12, 18, 0.45);
  }
  .usecase-grid { grid-template-columns: 1fr; }
  .requirements-note { flex-direction: column; gap: 6px; }
}

@media (max-width: 460px) {
  .spec-strip { grid-template-columns: 1fr; }
  .spec { border-right: 0; border-bottom: 1px solid var(--line-soft); }
  .spec:last-child { border-bottom: 0; }
  .btn { width: 100%; justify-content: center; }
  .download-pill { padding: 9px 14px; font-size: 13px; }
}

@media (max-width: 360px) {
  .topbar .download-pill { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .js .section .reveal,
  .js .download-banner .reveal,
  .hero .reveal { opacity: 1 !important; transform: none !important; }
}

/* ============================================================
   DOC PAGES (byok / updates)
   ============================================================ */
.doc-body { background-image:
    radial-gradient(110% 60% at 92% -8%, rgba(20, 82, 255, 0.08), transparent 55%); }

.doc { padding: clamp(28px, 5vw, 56px) 0 0; }

.doc-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: start;
  padding-bottom: clamp(48px, 7vw, 96px);
}

/* sidebar TOC */
.doc-sidebar {
  position: sticky;
  top: 92px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-left: 14px;
  border-left: 1px solid var(--line);
}
.doc-toc-label {
  margin: 0 0 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.doc-sidebar a {
  padding: 8px 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  border-radius: 9px;
  transition: color 0.2s, background 0.2s;
}
.doc-sidebar a:hover { color: var(--ink); background: var(--accent-soft); }

.doc-content { min-width: 0; max-width: 800px; }

/* breadcrumb */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 26px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.breadcrumb a { color: var(--accent-ink); font-weight: 600; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span::before { content: "/"; margin-right: 9px; color: var(--line); }

/* doc header */
.doc-header { margin-bottom: clamp(40px, 6vw, 64px); }
.doc-header h1 {
  margin: 0 0 18px;
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: -0.035em;
  color: var(--ink);
}
.doc-intro { margin: 0 0 24px; font-size: 16.5px; color: var(--ink-2); max-width: 60ch; }
.doc-meta { display: flex; flex-wrap: wrap; gap: 10px; }
.doc-meta span {
  padding: 7px 14px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--ink-2);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
}

/* callout */
.doc-callout {
  position: relative;
  display: flex;
  gap: 20px;
  margin-bottom: clamp(40px, 6vw, 64px);
  padding: 26px 28px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 20px 44px -28px rgba(20, 50, 120, 0.4);
}
.callout-bar {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: linear-gradient(var(--accent), var(--accent-press));
}
.doc-callout h2 { margin: 0 0 8px; font-size: 20px; font-weight: 800; color: var(--ink); letter-spacing: -0.01em; }
.doc-callout p { margin: 0; font-size: 15px; color: var(--ink-2); }

/* doc sections */
.doc-section { margin-bottom: clamp(44px, 6vw, 72px); }
.doc-section-head { margin-bottom: 28px; }
.doc-section-head h2 {
  margin: 0 0 10px;
  font-size: clamp(24px, 3.4vw, 34px);
  font-weight: 900;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.doc-section-head > p { margin: 0; font-size: 15.5px; color: var(--ink-2); max-width: 60ch; }

/* provider table */
.provider-table { display: grid; gap: 16px; }
.provider-row {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  padding: 24px 26px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform 0.25s var(--ease), box-shadow 0.25s, border-color 0.25s;
}
.provider-row:hover {
  transform: translateY(-3px);
  border-color: transparent;
  box-shadow: 0 22px 48px -26px rgba(20, 50, 120, 0.42);
}
.provider-name { display: flex; align-items: center; gap: 14px; }
.provider-glyph {
  display: grid;
  place-items: center;
  width: 46px; height: 46px;
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(150deg, var(--ink), #28304a);
  border-radius: 13px;
}
.provider-name h3 { margin: 0; font-size: 18px; font-weight: 800; color: var(--ink); }
.provider-name p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.provider-row ol { margin: 0; padding: 0; list-style: none; counter-reset: step; display: grid; gap: 12px; }
.provider-row ol li {
  position: relative;
  padding-left: 34px;
  font-size: 15px;
  color: var(--ink-2);
  counter-increment: step;
}
.provider-row ol li::before {
  content: counter(step);
  position: absolute;
  left: 0; top: 0;
  width: 22px; height: 22px;
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--accent-ink);
  background: var(--accent-soft);
  border-radius: 7px;
}
.provider-row ol a { color: var(--accent); font-weight: 700; border-bottom: 1px solid var(--accent-soft); }
.provider-row ol a:hover { border-color: var(--accent); }

/* doc card grid */
.doc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.doc-card {
  padding: 24px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform 0.25s var(--ease), box-shadow 0.25s;
}
.doc-card:hover { transform: translateY(-4px); box-shadow: 0 22px 46px -26px rgba(20, 50, 120, 0.4); }
.doc-card h3 {
  margin: 0 0 8px;
  padding-left: 16px;
  position: relative;
  font-size: 16.5px;
  font-weight: 800;
  color: var(--ink);
}
.doc-card h3::before {
  content: "";
  position: absolute;
  left: 0; top: 0.4em;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
}
.doc-card p { margin: 0; font-size: 14px; color: var(--ink-2); line-height: 1.75; }

/* setup panel */
.setup-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: 28px;
  align-items: start;
}
.setup-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; position: relative; }
.setup-steps::before {
  content: "";
  position: absolute;
  left: 22px; top: 30px; bottom: 30px;
  width: 2px;
  background: linear-gradient(var(--accent), var(--accent-soft));
}
.setup-steps li { position: relative; display: flex; gap: 16px; align-items: flex-start; padding: 14px 0; }
.setup-steps .step-no {
  width: 44px; height: 44px;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid rgba(20,82,255,0.3);
  border-radius: 12px;
}
.setup-steps h3 { margin: 0; font-size: 16px; font-weight: 800; color: var(--ink); }
.setup-steps p { margin: 3px 0 0; font-size: 14px; color: var(--ink-2); line-height: 1.65; }

.settings-screenshot-card {
  margin: 0;
  padding: 12px;
  background: linear-gradient(150deg, #ffffff, #e9edf4);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 30px 60px -32px rgba(20, 50, 120, 0.5);
}
.settings-screenshot-card img { width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line-soft); }
.settings-screenshot-card figcaption {
  margin-top: 12px;
  padding: 0 6px 4px;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.6;
}

/* checklist */
.doc-checklist { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.doc-checklist li {
  position: relative;
  padding: 16px 16px 16px 44px;
  font-size: 15px;
  color: var(--ink-2);
  border-top: 1px solid var(--line);
}
.doc-checklist li:last-child { border-bottom: 1px solid var(--line); }
.doc-checklist li::before {
  content: "";
  position: absolute;
  left: 12px; top: 17px;
  width: 18px; height: 18px;
  border-radius: 6px;
  background: var(--accent-soft);
  border: 1px solid rgba(20,82,255,0.35);
}
.doc-checklist li::after {
  content: "";
  position: absolute;
  left: 18px; top: 21px;
  width: 5px; height: 9px;
  border: solid var(--accent);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* doc faq reuses .faq-list; tighten */
.doc-faq { margin-top: 4px; }

/* doc footer cta */
.doc-footer-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: clamp(40px, 6vw, 64px);
  padding: clamp(28px, 4vw, 44px);
  background: linear-gradient(160deg, var(--night), var(--night-2));
  color: #fff;
  border-radius: 22px;
  overflow: hidden;
  position: relative;
}
.doc-footer-cta::after {
  content: "";
  position: absolute;
  right: -60px; bottom: -80px;
  width: 240px; height: 240px;
  background: radial-gradient(circle, rgba(20,82,255,0.5), transparent 66%);
  filter: blur(12px);
}
.doc-footer-cta > div { position: relative; }
.doc-footer-cta h2 { margin: 0 0 8px; font-size: clamp(22px, 3vw, 30px); font-weight: 900; letter-spacing: -0.025em; }
.doc-footer-cta p { margin: 0; color: #b9c2d8; font-size: 15px; }
.doc-footer-cta .btn { position: relative; }

/* release / updates */
.release-hero-card {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: clamp(40px, 6vw, 64px);
  padding: 30px 30px 30px 34px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 26px 54px -30px rgba(20, 50, 120, 0.42);
}
.release-hero-copy h2 { margin: 0 0 8px; font-size: clamp(24px, 3.4vw, 34px); font-weight: 900; letter-spacing: -0.02em; color: var(--ink); }
.release-hero-copy p { margin: 0; font-size: 15.5px; color: var(--ink-2); max-width: 48ch; }

.release-timeline { display: grid; gap: 18px; position: relative; }
.release-entry {
  position: relative;
  padding: 26px 28px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.release-entry::before {
  content: "";
  position: absolute;
  left: 0; top: 26px; bottom: 26px;
  width: 3px;
  border-radius: 999px;
  background: linear-gradient(var(--accent), var(--accent-soft));
}
.release-entry header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line-soft);
}
.release-version {
  margin: 0 0 4px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--accent-ink);
}
.release-entry h3 { margin: 0; font-size: 19px; font-weight: 800; color: var(--ink); letter-spacing: -0.01em; }
.release-entry time { font-family: var(--font-mono); font-size: 12.5px; color: var(--muted); }
.release-list { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.release-list li {
  position: relative;
  padding-left: 22px;
  font-size: 14.5px;
  color: var(--ink-2);
  line-height: 1.7;
}
.release-list li::before {
  content: "";
  position: absolute;
  left: 2px; top: 0.66em;
  width: 7px; height: 7px;
  border-radius: 2px;
  background: var(--accent);
  opacity: 0.8;
}
.release-note-grid { margin-top: 0; }

@media (max-width: 920px) {
  .doc-layout { grid-template-columns: 1fr; }
  .doc-sidebar {
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    border-left: 0;
    border-bottom: 1px solid var(--line);
    padding: 0 0 14px;
    gap: 4px;
  }
  .doc-toc-label { width: 100%; margin-bottom: 6px; }
  .provider-row { grid-template-columns: 1fr; gap: 18px; }
  .doc-grid { grid-template-columns: 1fr; }
  .setup-panel { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .doc-footer-cta, .release-hero-card { flex-direction: column; align-items: stretch; }
  .doc-footer-cta .btn, .release-hero-card .btn { justify-content: center; }
}
