/* ============================================================
   ReplyMind PRO — "Atelier"
   Self-contained editorial system. Shares nothing with the
   free landing page. Graphite · Ivory · a single jade accent.
   ============================================================ */

:root {
  --bg: #0d0e10;
  --bg-2: #111316;
  --panel: #16181c;
  --panel-2: #1b1e22;
  --ink: #f3f0ea;
  --ink-2: #aaa49a;
  --ink-3: #6e6a62;
  --ink-4: #4a4740;
  --line: rgba(243, 240, 234, 0.085);
  --line-2: rgba(243, 240, 234, 0.16);
  --bone: #f3f0ea;
  --acc: #d8b878;          /* champagne gold — the only chroma, used sparingly */
  --acc-2: #f6e8c8;        /* highlight */
  --acc-ink: #e6cd94;
  --acc-deep: #b58d4e;
  --acc-soft: rgba(216, 184, 120, 0.12);
  --acc-line: rgba(216, 184, 120, 0.30);
  --acc-grad: linear-gradient(135deg, #f6e8c8 0%, #dcc089 44%, #b58d4e 100%);
  --acc-metal: linear-gradient(100deg, #b58d4e 0%, #d8b878 26%, #f6e8c8 46%, #d8b878 66%, #b58d4e 100%);
  --warn: #d98b6a;         /* muted terracotta for "negative/hold" */
  --radius: 4px;
  --radius-lg: 8px;
  --serif: 'Newsreader', Georgia, 'Times New Roman', serif;
  --sans: 'Geist', -apple-system, system-ui, sans-serif;
  --mono: 'Geist Mono', ui-monospace, monospace;
  --maxw: 1240px;
  --gutter: 40px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: hidden; }
html, body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body { overflow-x: clip; }
::selection { background: var(--acc); color: #2a1d00; }
@keyframes sheen { 0%{ background-position: -160% 0; } 100%{ background-position: 260% 0; } }
.metal { background: var(--acc-metal); background-size: 260% 100%; animation: sheen 7s linear infinite; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* ---- Atmosphere: vignette + drifting light + fine grain ---- */
.atmos { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.atmos .glow {
  position: absolute; width: 90vw; height: 90vw; max-width: 1100px; max-height: 1100px;
  top: -30%; left: 50%; transform: translateX(-50%);
  background: radial-gradient(circle, rgba(216,184,120,0.12) 0%, transparent 62%);
  filter: blur(30px);
  animation: drift 26s ease-in-out infinite alternate;
}
.atmos .glow.b {
  top: auto; bottom: -40%; left: 12%;
  width: 60vw; height: 60vw;
  background: radial-gradient(circle, rgba(181,141,78,0.06) 0%, transparent 60%);
  animation-duration: 32s;
}
@keyframes drift {
  0% { transform: translate(-50%, 0) scale(1); }
  100% { transform: translate(-46%, 4%) scale(1.08); }
}
.atmos .vignette {
  position: absolute; inset: 0;
  background: radial-gradient(120% 80% at 50% 0%, transparent 50%, rgba(0,0,0,0.5) 100%);
}
.atmos .grain {
  position: absolute; inset: -50%;
  opacity: 0.05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  animation: grainShift 8s steps(6) infinite;
}
@keyframes grainShift {
  0%{transform:translate(0,0)} 50%{transform:translate(-4%,3%)} 100%{transform:translate(0,0)}
}

/* ---- Shell / rhythm ---- */
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
@media (max-width: 640px){ :root{ --gutter: 22px; } }

.rule-h { height: 1px; background: var(--line); border: 0; }
.eyebrow {
  font-family: var(--mono);
  font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--ink-3);
  display: inline-flex; align-items: center; gap: 12px;
}
.eyebrow .tick { width: 22px; height: 1px; background: var(--ink-4); display: inline-block; }
.eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--acc);
  box-shadow: 0 0 10px var(--acc); animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:.4} }

/* ============ NAV ============ */
.nav {
  position: sticky; top: 0; z-index: 60;
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  background: rgba(13,14,16,0.66);
  border-bottom: 1px solid var(--line);
}
.nav-in { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand img { width: 34px; height: 34px; border-radius: 8px; }
.brand-tx { display: flex; flex-direction: column; line-height: 1.05; }
.brand .nm { font-size: 16px; letter-spacing: -0.01em; font-weight: 500; display: flex; align-items: baseline; gap: 9px; }
.brand .by { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.08em; color: var(--ink-3); margin-top: 4px; }
.brand .pro {
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--acc); border: 1px solid var(--acc-line); border-radius: 3px;
  padding: 2px 6px; transform: translateY(-1px);
}
.nav-links { display: flex; gap: 30px; font-size: 13.5px; color: var(--ink-2); }
.nav-links a { position: relative; padding: 4px 0; transition: color .2s; }
.nav-links a:hover { color: var(--ink); }
.nav-links a::after {
  content:""; position:absolute; left:0; right:100%; bottom:-2px; height:1px; background: var(--acc); transition: right .25s;
}
.nav-links a:hover::after { right: 0; }
@media (max-width: 820px){ .nav-links{ display:none; } }

.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--sans); font-size: 13.5px; font-weight: 500;
  padding: 11px 18px; border-radius: var(--radius);
  cursor: pointer; border: 1px solid transparent; transition: .2s; white-space: nowrap;
}
.btn svg { width: 15px; height: 15px; }
.btn-bone {
  position: relative; overflow: hidden;
  background: var(--acc-grad); color: #2a1d00; font-weight: 600;
}
.btn-bone::after {
  content:""; position:absolute; top:0; left:-60%; width:40%; height:100%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,0.6), transparent);
  transform: skewX(-18deg); transition: left .55s ease;
}
.btn-bone:hover { transform: translateY(-1px); box-shadow: 0 14px 34px -14px rgba(216,184,120,0.6); }
.btn-bone:hover::after { left: 130%; }
.btn-line { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn-line:hover { border-color: var(--ink-2); background: rgba(243,240,234,0.03); }
.btn-ghost { background: transparent; color: var(--ink-2); padding: 11px 4px; }
.btn-ghost:hover { color: var(--ink); }
.btn.lg { padding: 15px 26px; font-size: 15px; border-radius: var(--radius); }

/* ============ HERO (cover) ============ */
.hero { position: relative; padding: 76px 0 0; }
.hero-grid { display: grid; grid-template-columns: 1fr; gap: 0; }
.hero-top { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.hero-vol { font-family: var(--mono); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-3); }

.hero-h {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(46px, 7.4vw, 112px);
  line-height: 0.98;
  letter-spacing: -0.025em;
  margin: 40px 0 0;
  max-width: 16ch;
}
.hero-h .it { font-style: italic; }
.hero-h .acc { color: var(--acc); font-style: italic; }
.hero-h .ln { display: block; }
.hero-h .ln > span { display: block; }
/* Optional entrance: fade-up only when JS opts in via .reveal-ready; base stays fully visible */
.hero-h.reveal-ready .ln > span { opacity: 0; transform: translateY(28px); animation: heroUp .9s cubic-bezier(0.16,1,0.3,1) forwards; }
.hero-h.reveal-ready .ln:nth-child(2) > span { animation-delay: .07s; }
.hero-h.reveal-ready .ln:nth-child(3) > span { animation-delay: .14s; }
.hero-h.reveal-ready .ln:nth-child(4) > span { animation-delay: .21s; }
@keyframes heroUp { to { opacity: 1; transform: translateY(0); } }

.hero-low {
  margin-top: 44px;
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: end;
}
@media (max-width: 860px){ .hero-low{ grid-template-columns: 1fr; gap: 30px; } }
.hero-sub { font-size: 18px; line-height: 1.6; color: var(--ink-2); max-width: 46ch; }
.hero-sub b { color: var(--ink); font-weight: 500; }
.hero-actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.hero-meta {
  display: flex; gap: 26px; flex-wrap: wrap; justify-content: flex-end;
  font-family: var(--mono); font-size: 11.5px; color: var(--ink-3); letter-spacing: 0.04em;
}
@media (max-width: 860px){ .hero-meta{ justify-content: flex-start; } }
.hero-meta .m { display: flex; align-items: center; gap: 8px; }
.hero-meta .m b { color: var(--ink); font-weight: 500; font-family: var(--sans); }
.hero-meta .m .d { width: 5px; height: 5px; border-radius: 50%; background: var(--acc); }

/* hero ticker */
.ticker {
  margin-top: 64px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  overflow: hidden; padding: 16px 0;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.ticker-track { display: flex; gap: 0; width: max-content; animation: tick 38s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
@keyframes tick { to { transform: translateX(-50%); } }
.ticker .t {
  font-family: var(--serif); font-size: 22px; font-style: italic; color: var(--ink-3);
  padding: 0 30px; white-space: nowrap; display: inline-flex; align-items: center; gap: 30px;
}
.ticker .t::after { content: "—"; color: var(--ink-4); font-style: normal; }

/* ============ Section scaffolding ============ */
.section { padding: 130px 0; position: relative; }
.section.tight { padding: 80px 0; }
.s-head { display: grid; grid-template-columns: auto 1fr; gap: 28px; align-items: baseline; margin-bottom: 64px; }
@media (max-width: 720px){ .s-head{ grid-template-columns: 1fr; gap: 14px; } }
.s-no { font-family: var(--serif); font-style: italic; font-size: 24px; color: var(--ink-3); }
.s-title { font-family: var(--serif); font-weight: 400; font-size: clamp(32px, 4.4vw, 58px); line-height: 1.04; letter-spacing: -0.02em; }
.s-title .it { font-style: italic; }
.s-title .acc { color: var(--acc); font-style: italic; }
.s-sub { margin-top: 18px; font-size: 17px; color: var(--ink-2); line-height: 1.55; max-width: 60ch; }

/* ============ THESIS (two mandates) ============ */
.thesis { display: grid; grid-template-columns: 1fr 1px 1fr; gap: 0; }
@media (max-width: 800px){ .thesis{ grid-template-columns: 1fr; } .thesis .sep{ display:none; } }
.thesis .sep { background: var(--line); }
.mandate { padding: 8px 48px; }
.mandate:first-child { padding-left: 0; }
.mandate:last-child { padding-right: 0; }
@media (max-width: 800px){ .mandate{ padding: 36px 0; border-top: 1px solid var(--line); } .mandate:first-child{ border-top:0; padding-top:0; } }
.mandate .lab { font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 18px; display: flex; align-items: center; gap: 10px; }
.mandate .lab .n { font-family: var(--serif); font-style: italic; font-size: 22px; color: var(--ink-2); }
.mandate.standards .lab { color: var(--acc); }
.mandate h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(26px,3vw,38px); line-height: 1.08; letter-spacing: -0.015em; }
.mandate h3 .it { font-style: italic; }
.mandate.standards h3 .it { color: var(--acc); }
.mandate p { margin-top: 14px; font-size: 15px; color: var(--ink-2); line-height: 1.6; max-width: 40ch; }
.mandate ul { list-style: none; margin-top: 22px; display: flex; flex-direction: column; gap: 11px; }
.mandate li { display: flex; gap: 11px; font-size: 14px; color: var(--ink-2); align-items: baseline; }
.mandate li .b { font-family: var(--mono); font-size: 11px; color: var(--ink-4); min-width: 22px; }
.mandate.standards li .b { color: var(--acc-deep); }

/* ============ INDEX (10 modules) ============ */
.idx { border-top: 1px solid var(--line-2); }
.idx-row {
  display: grid; grid-template-columns: 64px 1.1fr 1.5fr auto;
  gap: 24px; align-items: center;
  padding: 26px 8px; border-bottom: 1px solid var(--line);
  position: relative; cursor: default; transition: background .3s, padding .3s;
}
.idx-row::before {
  content:""; position:absolute; left:0; top:0; bottom:0; width:0; background: var(--acc);
  transition: width .3s;
}
.idx-row:hover { background: linear-gradient(90deg, rgba(216,184,120,0.05), transparent 70%); padding-left: 22px; }
.idx-row:hover::before { width: 2px; }
.idx-no { font-family: var(--serif); font-style: italic; font-size: 26px; color: var(--ink-3); transition: color .3s; }
.idx-row:hover .idx-no { color: var(--acc); }
.idx-name { font-size: 20px; font-weight: 500; letter-spacing: -0.01em; }
.idx-name .meta { display: block; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-3); margin-top: 5px; font-weight: 400; }
.idx-desc { font-size: 14.5px; color: var(--ink-2); line-height: 1.5; }
.idx-arrow { color: var(--ink-4); transition: color .3s, transform .3s; }
.idx-row:hover .idx-arrow { color: var(--acc); transform: translateX(4px); }
.idx-arrow svg { width: 18px; height: 18px; }
@media (max-width: 860px){
  .idx-row{ grid-template-columns: 44px 1fr; gap: 6px 16px; }
  .idx-desc{ grid-column: 2 / -1; }
  .idx-arrow{ display:none; }
}

/* ============ DEEP DIVE (marquee) ============ */
.dive { display: grid; grid-template-columns: 1fr 1.08fr; gap: 56px; align-items: center; padding: 70px 0; border-top: 1px solid var(--line); }
.dive.rev .dive-copy { order: 2; }
.dive.rev .dive-vis { order: 1; }
@media (max-width: 940px){
  .dive, .dive.rev { grid-template-columns: 1fr; gap: 34px; }
  .dive.rev .dive-copy, .dive.rev .dive-vis { order: 0; }
}
.dive-lab { font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--acc); display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.dive-lab .n { font-family: var(--serif); font-style: italic; font-size: 22px; color: var(--ink-3); }
.dive-copy h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(28px,3.2vw,42px); line-height: 1.06; letter-spacing: -0.02em; }
.dive-copy h3 .it { font-style: italic; }
.dive-copy h3 .acc { color: var(--acc); font-style: italic; }
.dive-copy p { margin-top: 18px; font-size: 16px; color: var(--ink-2); line-height: 1.62; max-width: 46ch; }
.dive-points { margin-top: 26px; display: flex; flex-direction: column; gap: 0; border-top: 1px solid var(--line); }
.dive-points .pt { display: flex; gap: 14px; align-items: baseline; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
.dive-points .pt b { color: var(--ink); font-weight: 500; }
.dive-points .pt .mk { color: var(--acc); font-family: var(--mono); font-size: 11px; min-width: 16px; }

/* visual frame */
.frame {
  background: linear-gradient(180deg, var(--panel) 0%, var(--bg-2) 100%);
  border: 1px solid var(--line-2);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: 0 40px 90px -50px rgba(0,0,0,0.9), inset 0 1px 0 rgba(255,255,255,0.03);
  position: relative; overflow: hidden;
}
.frame-bar { display: flex; align-items: center; justify-content: space-between; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); padding-bottom: 15px; margin-bottom: 16px; border-bottom: 1px solid var(--line); }
.frame-bar .live { display: inline-flex; align-items: center; gap: 8px; color: var(--acc); }
.frame-bar .live .d { width: 6px; height: 6px; border-radius: 50%; background: var(--acc); box-shadow: 0 0 8px var(--acc); animation: pulse 2s infinite; }

/* comment line inside frames */
.cmt { display: grid; grid-template-columns: 32px 1fr; gap: 11px; margin-bottom: 18px; }
.cmt .av { width: 32px; height: 32px; border-radius: 50%; background: var(--panel-2); border: 1px solid var(--line-2); display: grid; place-items: center; font-size: 11px; color: var(--ink-2); font-weight: 600; }
.cmt .nm { font-size: 12.5px; font-weight: 500; }
.cmt .nm span { color: var(--ink-3); font-family: var(--mono); font-size: 10.5px; font-weight: 400; }
.cmt .bd { font-size: 13px; color: var(--ink-2); line-height: 1.5; margin-top: 3px; }

/* RULES engine */
.rule { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; padding: 13px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(255,255,255,0.015); margin-bottom: 9px; transition: .35s cubic-bezier(0.2,0.7,0.2,1); }
.rule .ord { font-family: var(--serif); font-style: italic; font-size: 20px; color: var(--ink-3); width: 22px; text-align: center; }
.rule .cond { font-size: 12.5px; color: var(--ink-2); }
.rule .cond code { font-family: var(--mono); font-size: 11px; color: var(--ink); background: rgba(255,255,255,0.06); padding: 1px 6px; border-radius: 3px; }
.rule .act { font-family: var(--mono); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; padding: 4px 9px; border-radius: 3px; border: 1px solid var(--line-2); color: var(--ink-3); white-space: nowrap; }
.rule.matched { border-color: var(--acc-line); background: var(--acc-soft); box-shadow: 0 0 28px -10px rgba(216,184,120,0.5); transform: scale(1.012); }
.rule.matched .ord { color: var(--acc); }
.rule.matched .act { color: var(--acc); border-color: var(--acc-line); }
.rule.dimmed { opacity: .35; }
.rule-out { margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line); font-family: var(--mono); font-size: 11px; color: var(--ink-3); display: flex; align-items: center; gap: 9px; }
.rule-out b { color: var(--acc); font-weight: 500; }

/* SENTIMENT gauge */
.gauge { height: 2px; background: var(--line-2); position: relative; margin: 30px 0 12px; }
.gauge .fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: linear-gradient(90deg, var(--acc), var(--warn)); transition: width 1.2s cubic-bezier(0.2,0.8,0.2,1); }
.gauge .knob { position: absolute; top: 50%; width: 12px; height: 12px; border-radius: 50%; background: var(--warn); transform: translate(-50%,-50%); left: 0; box-shadow: 0 0 14px rgba(217,139,106,0.7); transition: left 1.2s cubic-bezier(0.2,0.8,0.2,1); }
.gauge-scale { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.gauge-read { margin-top: 20px; display: flex; align-items: baseline; gap: 12px; }
.gauge-read .v { font-family: var(--serif); font-style: italic; font-size: 40px; color: var(--warn); line-height: 1; }
.gauge-read .vl { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); }
.acts { margin-top: 22px; display: flex; flex-direction: column; gap: 8px; }
.act-opt { display: flex; align-items: center; gap: 12px; padding: 11px 13px; border: 1px solid var(--line); border-radius: var(--radius); font-size: 13px; color: var(--ink-2); }
.act-opt.on { border-color: rgba(217,139,106,0.4); background: rgba(217,139,106,0.07); color: var(--ink); }
.act-opt .ix { font-family: var(--mono); font-size: 10px; color: var(--ink-4); }
.act-opt.on .ix { color: var(--warn); }

/* EMAIL plate */
.mail { border: 1px solid var(--line-2); border-radius: var(--radius); overflow: hidden; background: var(--bg); }
.mail-h { display: flex; align-items: center; gap: 11px; padding: 14px 15px; border-bottom: 1px solid var(--line); }
.mail-h .ic { width: 32px; height: 32px; border-radius: 6px; background: var(--acc-grad); color: #2a1d00; display: grid; place-items: center; }
.mail-h .ic svg { width: 15px; height: 15px; }
.mail-h strong { font-size: 13px; display: block; }
.mail-h span { font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); }
.mail-b { padding: 16px 15px; }
.mail-b .sj { font-size: 14px; font-weight: 500; margin-bottom: 12px; }
.quote { font-size: 12.5px; color: var(--ink-2); line-height: 1.55; padding: 11px 13px; border-left: 2px solid var(--line-2); background: rgba(255,255,255,0.02); border-radius: 0 var(--radius) var(--radius) 0; margin-bottom: 13px; }
.quote.ai { border-left-color: var(--acc); }
.quote .who { font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 6px; }
.mail-act { display: flex; gap: 9px; margin-top: 4px; }
.mail-btn { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 11px; border-radius: var(--radius); font-size: 12.5px; font-weight: 500; font-family: var(--sans); cursor: pointer; border: 1px solid transparent; transition: .2s; }
.mail-btn.ok { background: var(--acc-grad); color: #2a1d00; }
.mail-btn.ok:hover { filter: brightness(1.08); }
.mail-btn.no { background: transparent; border-color: var(--line-2); color: var(--ink-2); }
.mail-btn.no:hover { border-color: var(--warn); color: var(--warn); }
.mail-btn svg { width: 13px; height: 13px; }
.mail-f { padding: 10px 15px; border-top: 1px solid var(--line); font-family: var(--mono); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); display: flex; align-items: center; gap: 8px; }
.mail-f .c { color: var(--acc); }

/* ANALYTICS */
.an { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.an .kpi { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.an .kpi .n { font-family: var(--serif); font-style: italic; font-size: 38px; line-height: 1; color: var(--ink); }
.an .kpi .n .acc { color: var(--acc); }
.an .kpi .l { margin-top: 6px; font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); }
.an .chart { grid-column: span 2; border: 1px solid var(--line); border-radius: var(--radius); padding: 17px; }
.an .chart .ch { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 16px; }
.bars { display: flex; align-items: flex-end; gap: 7px; height: 96px; }
.bars .bar { flex: 1; height: 0; border-radius: 2px 2px 0 0; background: linear-gradient(180deg, var(--ink-2), var(--ink-4)); transition: height .9s cubic-bezier(0.2,0.8,0.2,1); }
.bars .bar.hot { background: linear-gradient(180deg, var(--acc), var(--acc-deep)); }
.bars-x { display: flex; gap: 7px; margin-top: 7px; }
.bars-x span { flex: 1; text-align: center; font-family: var(--mono); font-size: 9px; color: var(--ink-4); }

/* ============ SCALE trio ============ */
.trio { display: grid; grid-template-columns: repeat(3,1fr); gap: 0; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
@media (max-width: 820px){ .trio{ grid-template-columns: 1fr; } }
.tcard { padding: 34px 30px; border-right: 1px solid var(--line); transition: background .3s; }
.tcard:last-child { border-right: 0; }
@media (max-width: 820px){ .tcard{ border-right: 0; border-bottom: 1px solid var(--line); } .tcard:last-child{ border-bottom:0; } }
.tcard:hover { background: rgba(255,255,255,0.015); }
.tcard .ic { width: 40px; height: 40px; border-radius: 9px; border: 1px solid var(--line-2); display: grid; place-items: center; color: var(--acc); margin-bottom: 22px; }
.tcard .ic svg { width: 19px; height: 19px; }
.tcard h3 { font-family: var(--serif); font-weight: 400; font-size: 23px; letter-spacing: -0.01em; margin-bottom: 10px; }
.tcard p { font-size: 13.5px; color: var(--ink-2); line-height: 1.6; }
.tcard .stars { display: flex; gap: 3px; margin-top: 16px; color: var(--acc); }
.tcard .stars svg { width: 14px; height: 14px; }

/* ============ COMPARE ============ */
.cmp { border: 1px solid var(--line-2); border-radius: var(--radius-lg); overflow: hidden; }
.crow { display: grid; grid-template-columns: 1.7fr 1fr 1fr; align-items: center; }
.crow > div { padding: 15px 22px; }
.chead { position: sticky; top: 70px; z-index: 20; background: rgba(15,17,19,0.95); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line-2); }
.chead .fc { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-3); }
.chead .col { text-align: center; }
.chead .col .t { font-size: 15px; font-weight: 600; }
.chead .col.free .t { color: var(--ink-2); }
.chead .col.pro .t { color: var(--acc); font-family: var(--serif); font-style: italic; font-weight: 400; font-size: 19px; }
.chead .col .p { font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); margin-top: 3px; }
.chead .col.pro { background: var(--acc-soft); position: relative; }
.chead .col.pro::before { content:""; position:absolute; top:0; left:0; right:0; height:2px; background: var(--acc); }
.cbody .crow { border-top: 1px solid var(--line); transition: background .2s; }
.cbody .crow:hover { background: rgba(255,255,255,0.012); }
.cfeat { font-size: 14px; color: var(--ink); }
.cfeat small { display: block; color: var(--ink-3); font-size: 11.5px; margin-top: 2px; }
.ccell { text-align: center; font-size: 12.5px; color: var(--ink-2); }
.ccell.pc { background: rgba(216,184,120,0.04); }
.ccell .ck { color: var(--acc); }
.ccell .ck.bl { color: var(--ink-2); }
.ccell .dash { color: var(--ink-4); font-size: 16px; }
.ccell .tx { font-family: var(--mono); font-size: 11px; color: var(--ink-2); }
@media (max-width: 720px){ .crow{ grid-template-columns: 1.4fr .8fr .8fr; } .crow > div{ padding: 12px 12px; } .cfeat{ font-size: 12.5px; } }

/* ============ PRICING ============ */
.tiers { display: grid; grid-template-columns: repeat(3,1fr); gap: 18px; }
@media (max-width: 880px){ .tiers{ grid-template-columns: 1fr; max-width: 420px; margin: 0 auto; } }
.tier { border: 1px solid var(--line-2); border-radius: var(--radius-lg); padding: 34px 28px; display: flex; flex-direction: column; position: relative; transition: .3s cubic-bezier(0.2,0.7,0.2,1); }
.tier:hover { transform: translateY(-4px); border-color: var(--ink-3); }
.tier.feat { border-color: var(--acc-line); background: linear-gradient(180deg, rgba(216,184,120,0.07), transparent 60%); box-shadow: 0 50px 110px -60px rgba(216,184,120,0.4); }
.tier.feat::before { content:""; position:absolute; top:0; left:0; right:0; height:2px; background: var(--acc); }
.tier .rb { position: absolute; top: 16px; right: 16px; font-family: var(--mono); font-size: 9px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--acc); border: 1px solid var(--acc-line); border-radius: 3px; padding: 3px 8px; }
.tier .tn { font-family: var(--mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-3); }
.tier .tp { margin-top: 18px; display: flex; align-items: baseline; gap: 3px; }
.tier .tp .cur { font-size: 20px; color: var(--ink-2); }
.tier .tp .amt { font-family: var(--serif); font-weight: 400; font-size: 60px; line-height: 1; letter-spacing: -0.02em; }
.tier.feat .tp .amt { color: var(--acc); }
.tier .tp .per { font-size: 13px; color: var(--ink-3); }
.tier .ts { margin-top: 12px; font-size: 13.5px; color: var(--ink-2); }
.tier .ts b { color: var(--ink); }
.tier ul { list-style: none; margin: 24px 0; display: flex; flex-direction: column; gap: 11px; flex: 1; }
.tier li { display: flex; gap: 10px; align-items: baseline; font-size: 13px; color: var(--ink-2); }
.tier li .k { color: var(--acc); font-family: var(--mono); font-size: 11px; min-width: 12px; }
.tier .tcta { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px; border-radius: var(--radius); font-size: 14px; font-weight: 500; font-family: var(--sans); cursor: pointer; transition: .2s; width: 100%; border: 1px solid var(--line-2); background: transparent; color: var(--ink); }
.tier .tcta:hover { border-color: var(--ink-2); background: rgba(255,255,255,0.03); }
.tier.feat .tcta { background: var(--acc-grad); color: #2a1d00; border-color: transparent; font-weight: 600; position: relative; overflow: hidden; }
.tier.feat .tcta::after { content:""; position:absolute; top:0; left:-60%; width:40%; height:100%; background: linear-gradient(100deg, transparent, rgba(255,255,255,0.6), transparent); transform: skewX(-18deg); transition: left .55s; }
.tier.feat .tcta:hover::after { left: 130%; }
.tier .tcta svg { width: 14px; height: 14px; }
.pnote { text-align: center; margin-top: 26px; font-family: var(--mono); font-size: 11px; color: var(--ink-3); letter-spacing: 0.03em; }
.pnote a { color: var(--acc); }

/* ============ FAQ ============ */
.faq { border-top: 1px solid var(--line-2); }
.qa { border-bottom: 1px solid var(--line); padding: 26px 0; cursor: pointer; }
.qa summary { list-style: none; display: flex; justify-content: space-between; align-items: baseline; gap: 20px; }
.qa summary::-webkit-details-marker { display: none; }
.qa .q { font-family: var(--serif); font-weight: 400; font-size: 22px; letter-spacing: -0.01em; }
.qa .pm { font-family: var(--mono); font-size: 18px; color: var(--ink-3); transition: .25s; flex-shrink: 0; }
.qa[open] .pm { transform: rotate(45deg); color: var(--acc); }
.qa p { margin-top: 14px; font-size: 15px; color: var(--ink-2); line-height: 1.62; max-width: 70ch; }
.qa p code { font-family: var(--mono); font-size: 13px; color: var(--ink); background: rgba(255,255,255,0.05); padding: 1px 6px; border-radius: 3px; }

/* ============ CTA ============ */
.cta { position: relative; border: 1px solid var(--line-2); border-radius: var(--radius-lg); padding: 90px 40px; text-align: center; overflow: hidden; background: radial-gradient(70% 130% at 50% 0%, rgba(216,184,120,0.10), transparent 65%); }
.cta::before { content:""; position:absolute; top:0; left:50%; transform: translateX(-50%); width: 38%; height: 1px; background: linear-gradient(90deg, transparent, var(--acc), transparent); }
.cta .eyebrow { justify-content: center; margin-bottom: 24px; }
.cta h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(34px,4.6vw,62px); line-height: 1.04; letter-spacing: -0.02em; }
.cta h2 .acc { color: var(--acc); font-style: italic; }
.cta h2 .it { font-style: italic; }
.cta p { margin-top: 18px; font-size: 17px; color: var(--ink-2); }
.cta-row { margin-top: 34px; display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ============ FOOTER ============ */
.foot { border-top: 1px solid var(--line); padding: 70px 0 44px; margin-top: 40px; position: relative; }
.foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 44px; }
@media (max-width: 760px){ .foot-grid{ grid-template-columns: 1fr 1fr; gap: 32px; } }
.foot-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.foot-brand img { width: 34px; height: 34px; border-radius: 8px; }
.foot-brand b { font-size: 16px; font-weight: 500; display: flex; align-items: baseline; gap: 8px; }
.foot-brand .pro { font-family: var(--mono); font-size: 9px; letter-spacing: 0.2em; color: var(--acc); border: 1px solid var(--acc-line); border-radius: 3px; padding: 2px 6px; }
.foot-tx { display: flex; flex-direction: column; line-height: 1.05; }
.foot-by { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.08em; color: var(--ink-3); margin-top: 4px; }
.foot .tag { font-size: 13.5px; color: var(--ink-2); max-width: 300px; line-height: 1.6; }
.foot h5 { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 16px; }
.foot a.fl { display: flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--ink-2); padding: 6px 0; transition: .18s; }
.foot a.fl:hover { color: var(--ink); }
.foot a.fl .ex { color: var(--ink-4); font-size: 11px; }
.foot-base { margin-top: 50px; padding-top: 24px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 14px; font-family: var(--mono); font-size: 11px; color: var(--ink-3); letter-spacing: 0.04em; }
.foot-base .st { display: inline-flex; align-items: center; gap: 8px; color: var(--acc); }
.foot-base .st .d { width: 6px; height: 6px; border-radius: 50%; background: var(--acc); box-shadow: 0 0 8px var(--acc); animation: pulse 2.4s infinite; }
.foot-base .r { display: flex; align-items: center; gap: 14px; }
.foot-soc { width: 30px; height: 30px; border-radius: 6px; border: 1px solid var(--line-2); display: grid; place-items: center; color: var(--ink-2); transition: .2s; }
.foot-soc:hover { border-color: var(--acc-line); color: var(--ink); }
.foot-soc svg { width: 13px; height: 13px; }

/* giant footer wordmark */
.foot-mark { font-family: var(--serif); font-style: italic; font-size: clamp(120px, 20vw, 280px); line-height: .8; color: rgba(243,240,234,0.02); position: absolute; bottom: -10px; left: 50%; transform: translateX(-50%); pointer-events: none; user-select: none; white-space: nowrap; }

/* ============ reveal ============ */
.rev { opacity: 0; transform: translateY(22px); transition: opacity .9s cubic-bezier(0.16,1,0.3,1), transform .9s cubic-bezier(0.16,1,0.3,1); }
.rev.in { opacity: 1; transform: none; }
.rev[data-d="1"]{ transition-delay: .08s; }
.rev[data-d="2"]{ transition-delay: .16s; }
.rev[data-d="3"]{ transition-delay: .24s; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: rgba(243,240,234,0.08); border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: rgba(243,240,234,0.16); }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .hero-h .ln > span { transform: none; }
  .rev { opacity: 1; transform: none; }
}

/* ============================================================
   THEME TOGGLE control
   ============================================================ */
.nav-right { display: flex; align-items: center; gap: 12px; }
.theme-toggle {
  width: 38px; height: 38px; border-radius: var(--radius);
  border: 1px solid var(--line-2); background: transparent; color: var(--ink-2);
  display: grid; place-items: center; cursor: pointer; transition: .2s; padding: 0;
}
.theme-toggle:hover { border-color: var(--ink-3); color: var(--ink); }
.theme-toggle svg { width: 16px; height: 16px; }
.theme-toggle .sun { display: none; }
.theme-toggle .moon { display: block; }
[data-theme="light"] .theme-toggle .sun { display: block; }
[data-theme="light"] .theme-toggle .moon { display: none; }

/* ============================================================
   LIGHT THEME — warm paper, deep antique-gold accents
   ============================================================ */
[data-theme="light"] {
  --bg: #f4f0e7;
  --bg-2: #ece6d9;
  --panel: #ffffff;
  --panel-2: #f4efe4;
  --ink: #1d1a15;
  --ink-2: #615b51;
  --ink-3: #8f887b;
  --ink-4: #c0b8a8;
  --line: rgba(29, 26, 21, 0.10);
  --line-2: rgba(29, 26, 21, 0.17);
  --acc: #b07d2e;
  --acc-2: #caa25a;
  --acc-ink: #976619;
  --acc-deep: #8a611f;
  --acc-soft: rgba(176, 125, 46, 0.12);
  --acc-line: rgba(176, 125, 46, 0.34);
  --acc-grad: linear-gradient(135deg, #ecd29a 0%, #caa25a 44%, #a9772f 100%);
  --acc-metal: linear-gradient(100deg, #a9772f 0%, #caa25a 26%, #ecd8a6 46%, #caa25a 66%, #a9772f 100%);
  --warn: #bb6443;
}
[data-theme="light"] body, [data-theme="light"] html { background: var(--bg); }

/* atmosphere */
[data-theme="light"] .atmos .glow { background: radial-gradient(circle, rgba(176,125,46,0.10) 0%, transparent 62%); }
[data-theme="light"] .atmos .glow.b { background: radial-gradient(circle, rgba(176,125,46,0.05) 0%, transparent 60%); }
[data-theme="light"] .atmos .vignette { background: radial-gradient(120% 80% at 50% 0%, transparent 58%, rgba(70,52,22,0.06) 100%); }
[data-theme="light"] .atmos .grain { opacity: 0.035; mix-blend-mode: multiply; }

/* nav + sticky surfaces */
[data-theme="light"] .nav { background: rgba(244,240,231,0.74); }
[data-theme="light"] .chead { background: rgba(247,243,235,0.95); }

/* subtle fills (white→ink) */
[data-theme="light"] .rule { background: rgba(29,26,21,0.02); }
[data-theme="light"] .rule .cond code { background: rgba(29,26,21,0.06); color: var(--ink); }
[data-theme="light"] .quote { background: rgba(29,26,21,0.03); }
[data-theme="light"] .btn-line:hover { background: rgba(29,26,21,0.04); }
[data-theme="light"] .tcard:hover { background: rgba(29,26,21,0.02); }
[data-theme="light"] .cbody .crow:hover { background: rgba(29,26,21,0.015); }
[data-theme="light"] .tier .tcta:hover { background: rgba(29,26,21,0.04); }
[data-theme="light"] .idx-row:hover { background: linear-gradient(90deg, rgba(176,125,46,0.07), transparent 70%); }
[data-theme="light"] .ccell.pc { background: rgba(176,125,46,0.06); }
[data-theme="light"] .cmt .av { background: var(--panel-2); }

/* frames + elevation (lighten the heavy dark shadows) */
[data-theme="light"] .frame {
  background: linear-gradient(180deg, #ffffff 0%, #f7f2e8 100%);
  box-shadow: 0 30px 70px -46px rgba(60,42,12,0.28), inset 0 1px 0 rgba(255,255,255,0.7);
}
[data-theme="light"] .mail { background: #ffffff; }
[data-theme="light"] .tier.feat {
  background: linear-gradient(180deg, rgba(176,125,46,0.08), transparent 60%);
  box-shadow: 0 44px 90px -60px rgba(176,125,46,0.5);
}
[data-theme="light"] .cta { background: radial-gradient(70% 130% at 50% 0%, rgba(176,125,46,0.12), transparent 65%); }

/* analytics bars readable on paper */
[data-theme="light"] .bars .bar { background: linear-gradient(180deg, #a79e8d, #cdc6b6); }

/* footer giant wordmark */
[data-theme="light"] .foot-mark { color: rgba(29,26,21,0.035); }

/* scrollbar */
[data-theme="light"] ::-webkit-scrollbar-thumb { background: rgba(29,26,21,0.14); }
[data-theme="light"] ::-webkit-scrollbar-thumb:hover { background: rgba(29,26,21,0.24); }
