:root {
  --ink: #0a0a12;
  --ink-2: #10101d;
  --panel: #16162a;
  --panel-2: #1d1d35;
  --line: #2a2a46;
  --text: #ece9f7;
  --muted: #a09dc0;
  --dim: #6f6c8f;
  --accent: #b9a6ff;
  --accent-2: #7c6cff;
  --gold: #f0dfb6;
  --serif: "Fraunces", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --r: 14px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(1000px 600px at 50% -10%, #241f4d 0%, transparent 60%),
    radial-gradient(700px 500px at 85% 10%, #1a2a4a 0%, transparent 55%),
    var(--ink);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16.5px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

.stars {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    radial-gradient(1.4px 1.4px at 12% 18%, #fff8 0, transparent 60%),
    radial-gradient(1.2px 1.2px at 28% 62%, #fff6 0, transparent 60%),
    radial-gradient(1.6px 1.6px at 47% 12%, #fff7 0, transparent 60%),
    radial-gradient(1.1px 1.1px at 63% 44%, #fff5 0, transparent 60%),
    radial-gradient(1.5px 1.5px at 78% 22%, #fff8 0, transparent 60%),
    radial-gradient(1.2px 1.2px at 88% 68%, #fff5 0, transparent 60%),
    radial-gradient(1.3px 1.3px at 36% 84%, #fff5 0, transparent 60%),
    radial-gradient(1.1px 1.1px at 71% 88%, #fff4 0, transparent 60%);
  opacity: .55;
}

main, .nav, .foot { position: relative; z-index: 1; }

/* ---------- nav ---------- */
.nav {
  max-width: 1080px;
  margin: 0 auto;
  padding: 26px 24px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--text);
  text-decoration: none;
  font-family: var(--serif);
  font-size: 21px;
  letter-spacing: .3px;
}
.brand svg { color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a { color: var(--muted); text-decoration: none; font-size: 14.5px; }
.nav-links a:hover { color: var(--text); }
.quota-pill {
  border: 1px solid var(--line);
  background: #ffffff08;
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 12.5px !important;
  color: var(--accent) !important;
}

/* ---------- hero ---------- */
.hero {
  max-width: 820px;
  margin: 0 auto;
  padding: 64px 24px 20px;
  text-align: center;
}
.eyebrow {
  font-size: 12.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 18px;
}
h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(38px, 6.4vw, 64px);
  line-height: 1.06;
  letter-spacing: -.02em;
  margin: 0 0 20px;
}
h1 em { font-style: italic; color: var(--gold); }
.lede {
  color: var(--muted);
  font-size: 17.5px;
  max-width: 600px;
  margin: 0 auto 34px;
}
.lede.small { font-size: 15.5px; margin: 0 0 22px; text-align: left; max-width: none; }
.lede strong { color: var(--text); font-weight: 600; }

/* ---------- decoder form ---------- */
.decoder {
  background: linear-gradient(180deg, #ffffff0d, #ffffff05);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px;
  text-align: left;
  box-shadow: 0 24px 60px -30px #000c;
  backdrop-filter: blur(8px);
}
.decoder textarea {
  width: 100%;
  background: #0b0b16;
  border: 1px solid #23233c;
  border-radius: 12px;
  color: var(--text);
  font-family: var(--sans);
  font-size: 15.5px;
  line-height: 1.6;
  padding: 14px 16px;
  resize: vertical;
  min-height: 118px;
  outline: none;
}
.decoder textarea:focus { border-color: var(--accent-2); box-shadow: 0 0 0 3px #7c6cff22; }
.decoder textarea::placeholder { color: #55536f; }
.decoder-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 14px;
  flex-wrap: wrap;
}
.lenses { display: flex; gap: 6px; background: #0b0b16; padding: 4px; border-radius: 10px; border: 1px solid #23233c; }
.lens {
  border: 0;
  background: transparent;
  color: var(--dim);
  font-family: var(--sans);
  font-size: 13px;
  padding: 7px 13px;
  border-radius: 7px;
  cursor: pointer;
  transition: .18s;
}
.lens:hover { color: var(--text); }
.lens.is-on { background: #ffffff12; color: var(--text); }

.btn-primary {
  border: 0;
  cursor: pointer;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  color: #14101f;
  background: linear-gradient(180deg, #d3c6ff, var(--accent));
  border-radius: 11px;
  padding: 12px 22px;
  transition: .18s;
  box-shadow: 0 10px 30px -12px #7c6cff88;
}
.btn-primary:hover { transform: translateY(-1px); filter: brightness(1.06); }
.btn-primary:disabled { opacity: .55; cursor: default; transform: none; }
.btn-primary.wide, .btn-ghost.wide { width: 100%; margin-top: 14px; }
.btn-ghost {
  border: 1px solid var(--line);
  background: #ffffff08;
  color: var(--text);
  font-family: var(--sans);
  font-size: 14.5px;
  border-radius: 11px;
  padding: 10px 18px;
  cursor: pointer;
}
.btn-ghost:hover { background: #ffffff12; }
.fineprint { color: var(--dim); font-size: 12.5px; margin: 12px 2px 0; }
.fineprint.center { text-align: center; margin-top: 26px; }

/* ---------- result ---------- */
.result { margin-top: 26px; }
.reading {
  text-align: left;
  background: linear-gradient(180deg, #1a1730, #12121f);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 30px 30px 22px;
  animation: rise .5s ease both;
}
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.reading-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.archetype { font-family: var(--serif); font-size: 22px; color: var(--gold); }
.mood {
  font-size: 12px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid #7c6cff44;
  background: #7c6cff14;
  border-radius: 999px;
  padding: 4px 11px;
  white-space: nowrap;
}
.signature {
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.45;
  color: #fff;
  margin: 0 0 16px;
  padding-left: 16px;
  border-left: 2px solid var(--accent-2);
  font-style: italic;
}
.summary { color: var(--muted); margin: 0 0 22px; }
.symbols { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.sym-chip {
  border: 1px solid var(--line);
  background: #ffffff06;
  border-radius: 10px;
  padding: 7px 12px;
  font-size: 13px;
  color: var(--muted);
}
.sym-chip b { color: var(--text); font-weight: 600; }
.prose p { margin: 0 0 15px; color: #d9d6ec; }
/* legal pages: one narrow column, readable, no flourish */
.symbol-body.legal { max-width: 760px; }
.symbol-body.legal h2 { font-family: var(--serif); font-size: 21px; margin: 34px 0 10px; letter-spacing: -.01em; }
.symbol-body.legal h2:first-child { margin-top: 0; }
.symbol-body.legal a { color: var(--accent); text-decoration: none; border-bottom: 1px solid #7c6cff55; }
.questions { margin: 22px 0 6px; padding: 18px 20px; background: #7c6cff10; border-radius: 12px; border: 1px solid #7c6cff30; }
.questions h4 { margin: 0 0 10px; font-size: 12.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); font-weight: 600; }
.questions ol { margin: 0; padding-left: 20px; color: #cfcbe6; }
.questions li { margin-bottom: 7px; }
.reading-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
.stamp { font-size: 12px; color: var(--dim); }
.paywall {
  text-align: left;
  border: 1px dashed #7c6cff55;
  background: #7c6cff0d;
  border-radius: 16px;
  padding: 26px;
}
.paywall h3 { font-family: var(--serif); font-size: 24px; margin: 0 0 8px; }
.paywall p { color: var(--muted); margin: 0 0 18px; }
.err-box { border: 1px solid #ff8b7a44; background: #ff8b7a10; color: #ffc4ba; border-radius: 12px; padding: 14px 18px; }

/* ---------- sections ---------- */
.how, .index-preview, .faq, .cta-band, .symbol-body { max-width: 1040px; margin: 0 auto; padding: 66px 24px 0; }
.how h2, .index-preview h2, .faq h2, .cta-band h2, .symbol-body h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 30px;
  letter-spacing: -.01em;
  margin: 0 0 26px;
}
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; list-style: none; padding: 0; margin: 0; }
.steps li { border-top: 1px solid var(--line); padding-top: 18px; }
.steps .num { font-family: var(--serif); font-size: 13px; color: var(--accent); letter-spacing: .1em; }
.steps h3 { font-size: 17px; margin: 8px 0 8px; font-weight: 600; }
.steps p { color: var(--muted); font-size: 15px; margin: 0; }

.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.link-more { color: var(--accent); text-decoration: none; font-size: 14.5px; }
.link-more:hover { text-decoration: underline; }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.card {
  display: block;
  text-decoration: none;
  color: inherit;
  background: #16162a99;
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 18px 18px 20px;
  transition: .18s;
}
.card:hover { border-color: #6d5fd0; background: #1c1c34; transform: translateY(-2px); }
.card .emoji { font-size: 22px; }
.card h3 { font-size: 16px; margin: 10px 0 6px; font-weight: 600; }
.card p { color: var(--muted); font-size: 13.5px; line-height: 1.5; margin: 0; }

.faq details { border-bottom: 1px solid var(--line); padding: 16px 0; }
.faq summary { cursor: pointer; font-weight: 500; font-size: 16.5px; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "+"; color: var(--accent); margin-right: 12px; }
.faq details[open] summary::before { content: "−"; }
.faq p { color: var(--muted); margin: 12px 0 0; font-size: 15.5px; }

.cta-band { text-align: center; padding-bottom: 78px; }
.cta-band p { color: var(--muted); margin: 0 0 22px; }

/* ---------- symbol page ---------- */
.crumbs { max-width: 1040px; margin: 0 auto; padding: 22px 24px 0; font-size: 13px; color: var(--dim); }
.crumbs a { color: var(--dim); text-decoration: none; }
.crumbs a:hover { color: var(--text); }
.crumbs span { margin: 0 6px; }
.symbol-hero { max-width: 780px; margin: 0 auto; padding: 34px 24px 0; text-align: center; }
.symbol-hero.narrow { max-width: 600px; }
.big-emoji { font-size: 46px; display: block; margin-bottom: 12px; }
.symbol-hero h1 { font-size: clamp(32px, 5vw, 48px); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; padding-bottom: 20px; }
.two-col h2 { font-size: 22px; margin-bottom: 10px; }
.two-col p { color: #cfcbe6; margin: 0; }
.inline-tool { margin: 50px 0; padding: 34px; background: #141428; border: 1px solid var(--line); border-radius: 20px; }
.inline-tool h2 { margin-bottom: 12px; }
.cat-block { margin-bottom: 44px; }
.cat-block h2 { font-size: 21px; color: var(--accent); }

/* ---------- pricing ---------- */
.tiers { display: grid; grid-template-columns: repeat(auto-fit, minmax(255px, 1fr)); gap: 18px; align-items: start; }
.tier { background: #16162a99; border: 1px solid var(--line); border-radius: 18px; padding: 26px; }
.tier.featured { border-color: #6d5fd0; background: linear-gradient(180deg, #221d45, #171528); box-shadow: 0 30px 60px -40px #7c6cff; }
.tier .badge { display: inline-block; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); border: 1px solid #f0dfb644; border-radius: 999px; padding: 3px 10px; margin-bottom: 12px; }
.tier h3 { font-size: 15px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin: 0 0 10px; font-weight: 600; }
.tier .price { font-family: var(--serif); font-size: 40px; margin: 0; line-height: 1; }
.tier .price span { font-size: 16px; color: var(--muted); font-family: var(--sans); }
.tier .price-alt { color: var(--dim); font-size: 13.5px; margin: 8px 0 0; }
.tier ul { list-style: none; padding: 0; margin: 20px 0 0; }
.tier li { color: #cfcbe6; font-size: 14.5px; padding: 7px 0 7px 24px; position: relative; }
.tier li::before { content: "◦"; position: absolute; left: 6px; color: var(--accent); }

/* ---------- unlock ---------- */
.unlock { display: flex; gap: 10px; margin-top: 22px; }
.unlock input { flex: 1; background: #0b0b16; border: 1px solid #23233c; border-radius: 11px; padding: 12px 15px; color: var(--text); font-family: var(--sans); font-size: 15px; }
.unlock input:focus { outline: none; border-color: var(--accent-2); }
.notice { margin-top: 16px; padding: 12px 16px; border-radius: 11px; font-size: 14px; }
.notice.err { background: #ff8b7a12; border: 1px solid #ff8b7a40; color: #ffc4ba; }
.notice.ok { background: #7cffb312; border: 1px solid #7cffb340; color: #b6ffd4; }

/* ---------- variations ---------- */
.variations { margin: 46px 0 0; }
.var-list { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 32px; margin-top: 8px; }
.var { padding: 18px 0 18px 16px; border-left: 2px solid #ffffff14; }
.var:hover { border-left-color: var(--accent-2); }
.var h3 { font-size: 16.5px; margin: 0 0 6px; font-weight: 600; color: var(--text); }
.var p { color: var(--muted); font-size: 15px; line-height: 1.6; margin: 0; }

/* ---------- category chips ---------- */
.cat-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.cat-chips.center { justify-content: center; }
.cat-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  background: #ffffff08;
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 13.5px;
  color: var(--muted);
  text-decoration: none;
  transition: .18s;
}
.cat-chip:hover { border-color: #6d5fd0; color: var(--text); background: #ffffff10; }
.cat-chip span { color: var(--dim); font-size: 11.5px; }
.cat-others { margin-top: 56px; }
.cat-others h2 { font-size: 22px; margin-bottom: 4px; }

/* ---------- journal ---------- */
.journal-wrap { max-width: 900px; margin: 0 auto; padding: 40px 24px 90px; }
#journalApp.is-locked { display: none; }
.journal-lock { margin-bottom: 8px; }
.journal-lock .fineprint { margin-top: 14px; }
.lock-list { list-style: none; padding: 0; margin: 4px 0 22px; }
.lock-list li { color: #cfcbe6; font-size: 14.5px; padding: 6px 0 6px 20px; position: relative; }
.lock-list li::before { content: "◦"; position: absolute; left: 2px; color: var(--accent); }
.lock-list b { color: var(--text); font-weight: 600; }

.jstats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 34px; }
.stat { background: #16162a99; border: 1px solid var(--line); border-radius: 13px; padding: 16px 18px; }
.stat-label { display: block; font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); margin-bottom: 6px; }
.stat-value { font-family: var(--serif); font-size: 25px; color: var(--text); line-height: 1.1; }

.pattern-panel { background: linear-gradient(180deg, #221d45, #15132699); border: 1px solid #4a3f8f; border-radius: 18px; padding: 24px 26px; margin-bottom: 36px; }
.pattern-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.pattern-head h2 { margin: 0 0 4px; font-size: 24px; }
.pattern-head .fineprint { margin: 0; }
.pattern-card { margin-top: 22px; padding-top: 20px; border-top: 1px solid #4a3f8f66; }
.pattern-card h3 { font-family: var(--serif); font-size: 22px; margin: 0 0 14px; color: var(--gold); }
.jpattern { color: #d5d1ea; margin: 16px 0 0; }

.jlist { display: flex; flex-direction: column; gap: 10px; }
.jrow { background: #16162a99; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.jrow[open] { border-color: #4a3f8f; background: #1a1a30; }
.jrow summary { cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 16px 20px; }
.jrow summary::-webkit-details-marker { display: none; }
.jrow summary::after { content: "+"; color: var(--dim); font-size: 16px; line-height: 1; margin-left: 4px; }
.jrow[open] summary::after { content: "−"; }
.jrow-main { display: flex; align-items: baseline; gap: 14px; min-width: 0; }
.jdate { font-size: 12.5px; color: var(--dim); white-space: nowrap; }
.jarche { font-family: var(--serif); font-size: 17.5px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.jmood { font-size: 11.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--accent); border: 1px solid #7c6cff33; background: #7c6cff0f; border-radius: 999px; padding: 3px 10px; white-space: nowrap; }
.jrow-body { padding: 4px 20px 20px; border-top: 1px solid #ffffff0d; }
.jdream { font-family: var(--serif); font-style: italic; color: var(--muted); margin: 16px 0 14px; padding-left: 14px; border-left: 2px solid #ffffff1a; }
.jsig { color: var(--text); font-weight: 500; margin: 0 0 14px; }
.jrow-body p { color: #cfcbe6; font-size: 15px; }
.jrow-actions { margin-top: 16px; display: flex; gap: 10px; }
.btn-ghost.tiny { font-size: 12.5px; padding: 7px 13px; }
.clear-all { align-self: center; margin-top: 22px; color: #ffb4a8; border-color: #ff8b7a33; }
.empty { text-align: center; padding: 50px 20px; border: 1px dashed var(--line); border-radius: 16px; }
.empty p { color: var(--muted); margin: 0 0 8px; }
.empty .btn-primary { margin-top: 14px; display: inline-block; text-decoration: none; }
.journal-link { font-size: 12px; color: var(--accent); text-decoration: none; margin-right: 12px; }
.journal-link:hover { text-decoration: underline; }

@media (max-width: 760px) {
  .jstats { grid-template-columns: repeat(2, 1fr); }
  .pattern-head { flex-direction: column; align-items: flex-start; }
}

/* ---------- footer ---------- */
.foot { max-width: 1040px; margin: 0 auto; padding: 60px 24px 60px; border-top: 1px solid #ffffff10; }
.foot-art { font-family: var(--serif); color: var(--muted); font-size: 15px; margin: 0 0 14px; }
.disclaimer { color: var(--dim); font-size: 12.5px; max-width: 720px; line-height: 1.65; }
.foot-links { color: var(--dim); font-size: 13px; margin-top: 18px; }
.foot-links a { color: var(--dim); }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

@media (max-width: 760px) {
  body { font-size: 16px; }
  .two-col, .steps, .var-list { grid-template-columns: 1fr; gap: 24px; }
  .hero { padding-top: 40px; }
  .decoder-row { flex-direction: column; align-items: stretch; }
  .lenses { justify-content: space-between; }
  .inline-tool { padding: 22px; }
  .reading { padding: 22px; }
  .nav-links { gap: 14px; }
  .nav-links a:not(.quota-pill) { font-size: 13.5px; }
}

/* ---------- sample / fallback notice ---------- */
.sample-warn {
  border: 1px solid #7a5a2a;
  background: #2a2118;
  color: #e8c88c;
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 18px;
}
.sample-warn b { color: #f4dcae; }
