/* =============================================================================
   Urania · styles.css — Cachola Tech house aesthetic, self-hosted fonts.
   Fonts: EB Garamond (display/serif, on-theme for a chart), Inter (UI),
   JetBrains Mono (data). All woff2 under /fonts — NO Google Fonts CDN.
   ============================================================================= */

@font-face {
  font-family: "EB Garamond"; font-style: normal; font-weight: 400 700;
  font-display: swap; src: url("/fonts/eb-garamond-latin.woff2") format("woff2");
}
@font-face {
  font-family: "EB Garamond"; font-style: normal; font-weight: 400 700;
  font-display: swap; src: url("/fonts/eb-garamond-latin-ext.woff2") format("woff2");
}
@font-face {
  font-family: "EB Garamond"; font-style: italic; font-weight: 400 700;
  font-display: swap; src: url("/fonts/eb-garamond-italic-latin.woff2") format("woff2");
}
@font-face {
  font-family: "Inter"; font-style: normal; font-weight: 400 700;
  font-display: swap; src: url("/fonts/inter-latin.woff2") format("woff2");
}
@font-face {
  font-family: "Inter"; font-style: normal; font-weight: 400 700;
  font-display: swap; src: url("/fonts/inter-latin-ext.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono"; font-style: normal; font-weight: 400 600;
  font-display: swap; src: url("/fonts/jetbrains-mono-latin.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono"; font-style: normal; font-weight: 400 600;
  font-display: swap; src: url("/fonts/jetbrains-mono-latin-ext.woff2") format("woff2");
}

:root {
  --cream: #FBF8F1;
  --cream-2: #F4EFE3;
  --ink: #1F2B3D;
  --ink-soft: #2A2B30;
  --line: #D8D2C4;
  --line-2: #E6E0D2;
  --gold: #9A7B1E;
  --gold-soft: #C9A84B;
  --faint: #6B665A;
  --green: #2F7D5B;
  --red: #B23A48;
  --violet: #7A6FB0;
  --amber: #B08A2E;
  --serif: "EB Garamond", Georgia, serif;
  --sans: "Inter", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --radius: 14px;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--sans);
  color: var(--ink-soft);
  background:
    radial-gradient(1200px 600px at 50% -10%, #FFFDF8 0%, var(--cream) 55%, var(--cream) 100%);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
}
.hidden { display: none !important; }
.mono { font-family: var(--mono); }

/* ---- house chrome ---- */
.ct-chrome { font-family: var(--sans); }
.ct-topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px 14px; padding: 10px 18px; background: var(--ink); color: #FAF6ED; font-size: 13px;
  flex-wrap: wrap;
}
.ct-topbar .brand { display: flex; align-items: center; gap: 8px; font-weight: 600; letter-spacing: .02em; min-width: 0; }
.ct-topbar .brand .sub { font-weight: 400; opacity: .7; font-size: 11px; }
.ct-topbar .brand .glyph { width: 14px; height: 14px; border-radius: 50%; background: var(--gold-soft); display: inline-block; }
.ct-top-right { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px; min-width: 0; }
.ct-topbar .rec { display: flex; align-items: center; gap: 7px; font-family: var(--mono); font-size: 11px; opacity: .82; }
.ct-topbar .rec .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--gold-soft); }
.lang { display: flex; align-items: center; gap: 4px; font-size: 12px; }
.lang button {
  background: none; border: none; color: #FAF6ED; opacity: .55; cursor: pointer;
  font: inherit; padding: 2px 4px; border-radius: 4px;
}
.lang button[aria-current="true"] { opacity: 1; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.lang .sep { opacity: .3; }

/* Conta opcional — único link de navegação à área do cliente (/sala/eu/). */
.ct-account {
  display: flex; align-items: center; gap: 7px;
  color: inherit; text-decoration: none;
  font-family: var(--mono); font-size: 11px; opacity: .9;
  border: 1px solid rgba(201,168,75,.4); border-radius: 999px;
  padding: 4px 11px; transition: opacity .15s, border-color .15s, background .15s;
}
.ct-account .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--gold-soft); }
.ct-account:hover, .ct-account:focus-visible { opacity: 1; border-color: var(--gold-soft); background: rgba(201,168,75,.1); }
.ct-account--foot { font-size: 11px; opacity: .75; }
.ct-account--foot:hover, .ct-account--foot:focus-visible { opacity: 1; }

/* Narrow phones (≤480px): the top bar can't fit brand + account + lang + rec on
   one line. Root fix (not overflow:hidden): tighten the bar, drop the two purely
   decorative bits that eat width — the "· Cachola Tech" suffix (still in footer)
   and the "mapa astral · grátis" rec pill (the hero free-pill already says it).
   Account + 4-language switcher stay — they're navigation. Bar wraps if needed. */
@media (max-width: 480px) {
  .ct-topbar { padding: 9px 14px; gap: 10px 12px; }
  .ct-topbar .brand .sub { display: none; }
  .ct-topbar .rec { display: none; }
  .ct-top-right { gap: 8px 12px; }
  .ct-account { padding: 4px 9px; }
  .lang { gap: 3px; }
  .lang button { padding: 2px 3px; }
}

.ct-footer {
  background: #121418; color: #D8D2C4; padding: 18px 22px; font-size: 12px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 40px;
}
.ct-footer .made { display: flex; align-items: center; gap: 8px; }
.ct-footer .made .glyph { width: 12px; height: 12px; border-radius: 50%; background: var(--gold-soft); display: inline-block; }
.ct-footer .meta { font-family: var(--mono); opacity: .65; font-size: 11px; }

/* ---- layout ---- */
main { max-width: 1060px; margin: 0 auto; padding: 0 22px; }

.hero { text-align: center; padding: 54px 0 26px; }
.eyebrow {
  font-family: var(--mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--gold); margin: 0 0 14px;
}
.display {
  font-family: var(--serif); font-weight: 600; font-size: clamp(30px, 5vw, 50px);
  line-height: 1.08; color: var(--ink); margin: 0 auto 18px; max-width: 16ch;
}
.lede { font-size: clamp(15px, 2vw, 18px); color: var(--faint); max-width: 60ch; margin: 0 auto 18px; }
.free-pill {
  display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--green);
  background: #EAF3EE; border: 1px solid #CFE5D9; border-radius: 999px; padding: 6px 14px; margin: 6px auto 0;
}
.free-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); }

/* ---- C0 · faixa de capacidades NA ENTRADA (above-the-fold) ----
   Comunica a AMPLITUDE do que é grátis sem rolar até a #caps. Chips compactos,
   centrados, que envolvem em telas estreitas. Só features que rodam. */
.hero-caps {
  list-style: none; margin: 18px auto 4px; padding: 0; max-width: 760px;
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px;
}
.hero-caps li { margin: 0; }
.hero-cap {
  display: inline-flex; align-items: center; gap: 7px; cursor: pointer;
  font-family: var(--serif); font-size: 14.5px; font-weight: 500; color: var(--ink);
  background: #FFFFFF; border: 1px solid var(--line); border-radius: 999px;
  padding: 7px 14px; line-height: 1; white-space: nowrap;
  transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.hero-cap .hc-glyph { font-size: 15px; color: var(--gold); line-height: 1; }
.hero-cap:hover { border-color: var(--gold-soft); transform: translateY(-2px); box-shadow: 0 12px 28px -22px rgba(31,43,61,.5); }
.hero-cap:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: 2px; }
/* o chip viral em destaque sutil */
.hero-cap.hc-share { background: var(--ink); border-color: var(--ink); color: #FBF8F1; }
.hero-cap.hc-share .hc-glyph { color: var(--gold-soft); }
.hero-cap.hc-share:hover { border-color: var(--gold-soft); }
@media (max-width: 560px) {
  .hero-caps { gap: 7px; margin-top: 14px; }
  .hero-cap { font-size: 13px; padding: 6px 11px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-cap { transition: none; }
  .hero-cap:hover { transform: none; }
}
@media print { .hero-caps { display: none !important; } }

.card {
  background: #FFFFFF; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: 0 1px 0 rgba(31,43,61,.02), 0 14px 40px -28px rgba(31,43,61,.25);
  margin: 0 auto 22px;
}
.card-title { font-family: var(--serif); font-size: 24px; font-weight: 600; color: var(--ink); margin: 0 0 6px; }
.sub-title { font-family: var(--serif); font-size: 19px; font-weight: 600; color: var(--ink); margin: 0 0 12px; }
.card-note { color: var(--faint); font-size: 14px; margin: 0 0 18px; }

.form-card { max-width: 620px; }

.field { margin-bottom: 16px; }
.field > label { display: block; font-size: 13px; font-weight: 600; color: var(--ink); margin-bottom: 6px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
input[type="text"], input[type="date"], input[type="time"], input[type="email"], select {
  width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 9px;
  font: inherit; font-size: 15px; color: var(--ink-soft); background: var(--cream);
  transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus {
  outline: none; border-color: var(--gold-soft); box-shadow: 0 0 0 3px rgba(201,168,75,.18); background: #fff;
}
.check { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--faint); margin-top: 8px; font-weight: 400; }
.check input { width: auto; }
.hint { font-size: 12.5px; color: var(--faint); margin: 6px 0 0; }
.err { color: var(--red); font-size: 14px; margin: 10px 0 0; }

.place-wrap { position: relative; }
.place-results {
  position: absolute; z-index: 30; top: calc(100% + 4px); left: 0; right: 0;
  list-style: none; margin: 0; padding: 4px; background: #fff; border: 1px solid var(--line);
  border-radius: 10px; box-shadow: 0 18px 50px -24px rgba(31,43,61,.5); max-height: 260px; overflow-y: auto;
}
.place-opt { padding: 9px 11px; border-radius: 7px; cursor: pointer; font-size: 13.5px; color: var(--ink-soft); }
.place-opt:hover { background: var(--cream-2); }

.btn {
  font: inherit; font-weight: 600; font-size: 15px; border-radius: 10px; padding: 12px 20px;
  cursor: pointer; border: 1px solid transparent; transition: transform .06s, box-shadow .15s, background .15s;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--ink); color: #FAF6ED; width: 100%; }
.btn-primary:hover { box-shadow: 0 10px 28px -14px rgba(31,43,61,.7); }
.btn-primary:disabled { opacity: .6; cursor: default; }
.btn-ghost { background: #fff; color: var(--ink); border-color: var(--line); width: auto; padding: 9px 16px; font-size: 14px; }
.btn-ghost:hover { background: var(--cream-2); }

/* ---- result ---- */
.result-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 18px 0; }
.result-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* convite de conta (some até clicar "Salvar este mapa" sem estar logado) */
/* "Salvar este mapa" → convite de conta. Cartão-lembrança quente (não barra de
   sistema): regra dourada à esquerda, chamada serifada que lidera pelo ganho,
   subtexto honesto (free preservado) e "Agora não" rebaixado a link. Não compete
   com as cartas escuras Sol/Lua/Asc logo abaixo. */
.save-invite {
  position: relative; overflow: hidden; display: block;
  margin: 4px 0 20px; padding: 18px 20px 18px 22px;
  border: 1px solid var(--line-2); border-left: 4px solid var(--gold-soft);
  border-radius: 14px;
  background:
    radial-gradient(420px 120px at 0% 0%, rgba(201,168,75,.10), transparent 70%),
    linear-gradient(180deg, #FFFDF8, var(--cream-2));
}
.save-invite::before {
  content: "✦"; position: absolute; right: 18px; top: 14px;
  font-size: 18px; color: var(--gold-soft); opacity: .5;
}
.save-invite-lead {
  margin: 0 0 4px; font-family: var(--serif); font-weight: 600;
  font-size: 21px; line-height: 1.2; color: var(--ink);
}
.save-invite-text { margin: 0 0 14px; font-size: 13.5px; color: var(--faint); max-width: 56ch; }
.save-invite-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.save-invite-actions #saveDismiss {
  border: 0; background: none; color: var(--faint);
  text-decoration: underline; padding: 8px 4px; font-size: 13px;
}
@media (max-width: 560px) { .save-invite-actions .btn-primary { flex: 1; } }
.result-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; align-items: start; }
@media (max-width: 900px) { .result-grid { grid-template-columns: 1fr; } .row { grid-template-columns: 1fr; } }

.wheel-pane { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 18px; }
.wheel-mount { width: 100%; display: flex; justify-content: center; }
.wheel-mount svg { max-width: 100%; height: auto; }
.wheel-meta { font-size: 11px; color: var(--faint); text-align: center; line-height: 1.6; }

/* wheel typography (classes emitted by natal-wheel.js) */
.urania-wheel .sel-sign { font-family: var(--serif); }
.urania-wheel .sel-planet { font-family: var(--serif); font-weight: 600; }
.urania-wheel .sel-pdeg, .urania-wheel .sel-housenum { font-family: var(--mono); }
.urania-wheel .sel-axis { font-family: var(--mono); letter-spacing: .04em; }
.urania-wheel .sel-caption { font-family: var(--serif); }
.urania-wheel .sel-caption--name { font-weight: 700; }
.urania-wheel .sel-retro { font-family: var(--serif); }

/* ---- positions table ---- */
.tables-pane { display: flex; flex-direction: column; gap: 22px; }
.table-scroll { overflow-x: auto; }
.pos-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.pos-table th {
  text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .06em;
  color: var(--faint); font-weight: 600; padding: 6px 8px; border-bottom: 1.5px solid var(--line);
}
.pos-table td { padding: 8px; border-bottom: 1px solid var(--line-2); color: var(--ink-soft); }
.pos-table tr:last-child td { border-bottom: none; }
.pt-name { font-weight: 600; color: var(--ink); white-space: nowrap; }
.pt-glyph, .pt-sign-glyph { font-family: var(--serif); font-size: 17px; }
.pt-retro { color: var(--red); font-family: var(--serif); }

/* ---- aspect grid ---- */
.urania-aspgrid { border-collapse: collapse; font-family: var(--serif); }
.urania-aspgrid td, .urania-aspgrid th { width: 30px; height: 30px; text-align: center; border: 1px solid var(--line-2); padding: 0; }
.urania-aspgrid .sel-ag-h { background: var(--cream-2); font-size: 16px; color: var(--ink); }
.urania-aspgrid .sel-ag-diag { background: var(--cream); font-size: 16px; color: var(--ink); }
.urania-aspgrid .sel-ag-c { font-size: 13px; vertical-align: middle; }
.urania-aspgrid .sel-ag-empty { background: #fff; }
.urania-aspgrid .sel-ag-glyph { display: block; font-size: 13px; line-height: 1; }
.urania-aspgrid .sel-ag-orb { display: block; font-family: var(--mono); font-size: 7.5px; opacity: .75; line-height: 1; }
.urania-aspgrid .sel-ag--harmonious { color: var(--green); }
.urania-aspgrid .sel-ag--dynamic { color: var(--red); }
.urania-aspgrid .sel-ag--neutral { color: var(--violet); }
.urania-aspgrid .sel-ag--minor { color: var(--amber); }

/* ---- Ray funnel (free hobby -> human reading) ---- */
.ray-card {
  max-width: 100%;
  background: linear-gradient(180deg, #FFFDF6 0%, var(--cream) 100%);
  border-color: var(--gold-soft);
}
.ray-eyebrow {
  font-family: var(--mono); font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--gold); margin: 0 0 8px;
}
.ray-title { font-family: var(--serif); font-size: 21px; font-weight: 600; color: var(--ink); margin: 0 0 8px; }
.ray-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.ray-actions .btn { width: auto; flex: 0 0 auto; text-decoration: none; display: inline-flex; align-items: center; }

/* ---- passo de checkout do Ray (consentimento + contato opcional) ---- */
.ray-book-form { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.ray-book-form .field { max-width: 360px; }
.ray-book-form .btn { width: auto; }
.ray-consent { display: flex; align-items: flex-start; gap: 8px; margin: 4px 0 14px; }
.ray-consent input { margin-top: 3px; }

/* ---- lead + disclosure ---- */
.lead-card, .disc-card { max-width: 100%; }
.lead-form { display: flex; gap: 10px; flex-wrap: wrap; }
.lead-form input { flex: 1 1 240px; }
.lead-form .btn { width: auto; flex: 0 0 auto; }
.lead-msg { font-size: 14px; margin: 12px 0 0; }
.lead-msg.ok { color: var(--green); }
.lead-msg.err { color: var(--red); }

/* ---- print ---- */
@media print {
  .ct-topbar, .ct-footer, .hero, .form-card, .ray-card, .lead-card, .disc-card, .result-actions, .save-invite { display: none !important; }
  body { background: #fff; }
  .card { box-shadow: none; border: 1px solid #ccc; break-inside: avoid; }
  .result-grid { grid-template-columns: 1fr; }
}

/* ===== sinastria ===== */
#synForm { margin-top: 14px; }
#synForm .field { margin-top: 12px; }
.syn-wheels { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 18px; }
@media (max-width: 720px) { .syn-wheels { grid-template-columns: 1fr; } }
.syn-fig { margin: 0; text-align: center; }
.syn-cap { font-size: 0.85rem; opacity: 0.75; margin-bottom: 6px; }
.urania-syngrid { overflow-x: auto; display: block; }

/* =============================================================================
   Urania · result layer — "observatório noturno" finish (tournament final)
   Night-observatory atmosphere over the existing cream/ink/gold palette.
   Navy depths derive from --ink (#1F2B3D); the only accent is the house gold.
   Append-only block: overrides are deliberate and scoped to the result UI.
   ============================================================================= */

/* ---- 1 · tabs — instrument rail ---- */
.tabs {
  display: flex; gap: 2px; align-items: stretch;
  overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none;
  border-bottom: 1px solid var(--line);
  margin: 0 0 22px;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
  flex: 0 0 auto; white-space: nowrap;
  background: none; border: none; border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  font-family: var(--mono); font-size: 12px; letter-spacing: .09em; text-transform: uppercase;
  color: var(--faint); padding: 11px 14px 12px; cursor: pointer;
  transition: color .25s, border-color .25s;
}
/* star marker always rendered → no width reflow on tab switch */
.tab::before {
  content: "✦ "; color: var(--gold-soft);
  opacity: 0; transition: opacity .18s ease;
}
.tab:hover { color: var(--ink); }
.tab:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: -2px; border-radius: 6px 6px 0 0; }
.tab[aria-selected="true"] { color: var(--gold); border-bottom-color: var(--gold-soft); font-weight: 600; }
.tab[aria-selected="true"]::before { opacity: 1; }
.tabpane { animation: u-pane-in .45s ease both; }
@keyframes u-pane-in { from { opacity: 0; transform: translateY(6px); } }

/* ---- 2 · the Three Greats — night cards ---- */
.big3 { display: grid; grid-template-columns: 1fr; gap: 16px; margin: 0 0 22px; }
@media (min-width: 720px) { .big3 { grid-template-columns: repeat(3, 1fr); } }

.b3-card {
  position: relative; overflow: hidden; text-align: center;
  border-radius: var(--radius); padding: 30px 22px 26px;
  border: 1px solid #2C3A52;
  background: radial-gradient(140% 110% at 50% -20%, #24385A 0%, #16243C 48%, #0B1322 100%);
  box-shadow: 0 22px 48px -32px rgba(11, 19, 34, .9);
  transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
  animation: u-rise .8s cubic-bezier(.22, 1, .36, 1) both;
}
.b3-card:nth-child(2) { animation-delay: .12s; }
.b3-card:nth-child(3) { animation-delay: .24s; }
@keyframes u-rise { from { opacity: 0; transform: translateY(14px); } }
.b3-card:hover {
  transform: translateY(-3px);
  border-color: var(--gold-soft);
  box-shadow: 0 26px 54px -30px rgba(11, 19, 34, .95), 0 0 0 1px rgba(154, 123, 30, .45);
}

/* semantic aurora per astro — Sol alvorada / Lua prata / Asc horizonte */
.b3-card:nth-child(1) {
  background:
    radial-gradient(120% 60% at 50% 0%, rgba(201, 168, 75, .20) 0%, transparent 62%),
    radial-gradient(140% 110% at 50% -20%, #24385A 0%, #16243C 48%, #0B1322 100%);
}
.b3-card:nth-child(2) {
  background:
    radial-gradient(120% 60% at 50% 0%, rgba(244, 239, 227, .13) 0%, transparent 62%),
    radial-gradient(140% 110% at 50% -20%, #24385A 0%, #16243C 48%, #0B1322 100%);
}
.b3-card:nth-child(3) {
  background:
    radial-gradient(110% 55% at 28% 0%, rgba(47, 125, 91, .15) 0%, transparent 60%),
    radial-gradient(110% 55% at 76% 0%, rgba(178, 58, 72, .12) 0%, transparent 60%),
    radial-gradient(140% 110% at 50% -20%, #24385A 0%, #16243C 48%, #0B1322 100%);
}

/* shared starfield — pure layered radial-gradients, no images */
.b3-card::before, .wheel-pane::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    radial-gradient(1px 1px at 22% 28%, rgba(244,239,227,.85) 49%, transparent 51%),
    radial-gradient(1.5px 1.5px at 68% 12%, rgba(201,168,75,.8) 49%, transparent 51%),
    radial-gradient(1px 1px at 84% 56%, rgba(244,239,227,.7) 49%, transparent 51%),
    radial-gradient(1.2px 1.2px at 38% 76%, rgba(244,239,227,.6) 49%, transparent 51%),
    radial-gradient(1px 1px at 10% 64%, rgba(201,168,75,.55) 49%, transparent 51%),
    radial-gradient(1.3px 1.3px at 56% 42%, rgba(244,239,227,.75) 49%, transparent 51%),
    radial-gradient(1px 1px at 92% 86%, rgba(244,239,227,.5) 49%, transparent 51%);
  background-size: 220px 220px, 300px 300px, 260px 260px, 340px 340px, 280px 280px, 240px 240px, 320px 320px;
  animation: u-twinkle 9s ease-in-out infinite alternate;
}
/* second, desynced layer on the wheel pane — cheap parallax depth */
.wheel-pane::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    radial-gradient(1px 1px at 14% 18%, rgba(244,239,227,.6) 49%, transparent 51%),
    radial-gradient(1.4px 1.4px at 76% 34%, rgba(201,168,75,.6) 49%, transparent 51%),
    radial-gradient(1px 1px at 46% 88%, rgba(244,239,227,.55) 49%, transparent 51%),
    radial-gradient(1.1px 1.1px at 88% 70%, rgba(244,239,227,.5) 49%, transparent 51%);
  background-size: 260px 260px, 340px 340px, 260px 260px, 340px 340px;
  animation: u-twinkle 7s ease-in-out .8s infinite alternate-reverse;
}
@keyframes u-twinkle {
  from { opacity: .45; }
  50%  { opacity: .95; }
  to   { opacity: .6; }
}
/* positioned children paint above the absolutely-positioned ::before/::after */
.b3-card > *, .wheel-pane > * { position: relative; }

.b3-glyph {
  font-family: var(--serif); font-size: 46px; line-height: 1;
  color: var(--gold-soft); margin-bottom: 14px;
  text-shadow: 0 0 22px rgba(201, 168, 75, .55), 0 0 4px rgba(201, 168, 75, .4);
}
.b3-label {
  font-family: var(--mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
  color: rgba(237, 231, 216, .58); margin-bottom: 6px;
}
.b3-sign {
  font-family: var(--serif); font-size: clamp(24px, 3vw, 28px); font-weight: 600;
  color: #F4EFE3; letter-spacing: .01em; margin-bottom: 10px;
}
.b3-desc {
  font-family: var(--serif); font-style: italic; font-size: 15px; line-height: 1.62;
  color: rgba(237, 231, 216, .78); max-width: 32ch; margin: 0 auto;
}
/* typographic fleuron — survives print, keeps the mystique on paper */
.b3-desc::after { content: " ❧"; color: var(--gold-soft); }

/* ---- 3 · wheel pane — the jewel in the dark ---- */
.wheel-pane {
  position: relative; overflow: hidden;
  border-color: #2C3A52;
  background: radial-gradient(150% 120% at 50% -25%, #24385A 0%, #15233B 45%, #0A111F 100%);
  box-shadow: 0 26px 60px -36px rgba(11, 19, 34, .95);
}
.wheel-mount { position: relative; }
.wheel-mount svg {
  border-radius: 18px;
  box-shadow:
    0 0 0 1px rgba(201, 168, 75, .35),
    0 0 70px -12px rgba(201, 168, 75, .3),
    0 34px 80px -44px rgba(0, 0, 0, .85);
  animation: u-wheel-in 1.1s cubic-bezier(.22, 1, .36, 1) both;
}
@keyframes u-wheel-in {
  from { opacity: 0; transform: rotate(-7deg) scale(.96); }
  to   { opacity: 1; transform: none; }
}
.wheel-meta { color: #A8A294; }
.wheel-meta::before {
  content: "☉ · ☾ · ✦"; display: block;
  color: var(--gold-soft); letter-spacing: .35em; margin-bottom: 6px;
}

/* interactive wheel: focus dims all aspect lines, .on relights one */
svg.focus .sel-asp { opacity: .08; }
.urania-wheel .sel-asp { transition: opacity .3s ease, filter .3s ease; }
svg.focus .sel-asp.on {
  opacity: 1;
  filter: drop-shadow(0 0 3px rgba(201, 168, 75, .9)) drop-shadow(0 0 8px rgba(201, 168, 75, .45));
}
.urania-wheel .sel-pg { cursor: pointer; transition: filter .25s ease; }
.urania-wheel .sel-pg:hover,
.urania-wheel .sel-pg.on { filter: drop-shadow(0 0 5px rgba(201, 168, 75, .85)); }

/* floating tooltip (appended to the mount by app.js) */
.wheel-tip {
  position: absolute; z-index: 40; pointer-events: none;
  background: rgba(10, 16, 29, .95); color: #EDE7D8;
  border: 1px solid rgba(201, 168, 75, .45); border-radius: 8px;
  font-family: var(--mono); font-size: 11px; line-height: 1.55;
  padding: 7px 10px; max-width: 240px;
  box-shadow: 0 14px 34px -14px rgba(0, 0, 0, .75);
}

/* sinastria wheels inherit the glow discreetly */
.syn-fig svg { border-radius: 14px; box-shadow: 0 0 0 1px rgba(201, 168, 75, .25), 0 16px 40px -28px rgba(31, 43, 61, .6); }
.syn-cap { font-family: var(--serif); font-style: italic; font-size: 15px; color: var(--faint); opacity: 1; }

/* ---- 4 · advanced options — quiet drawer ---- */
.adv-opts { margin: 2px 0 20px; border-top: 1px dashed var(--line-2); padding-top: 12px; }
.adv-opts summary {
  cursor: pointer; font-size: 13px; color: var(--faint);
  transition: color .2s; width: fit-content;
}
.adv-opts summary::marker { color: var(--gold-soft); }
.adv-opts summary:hover { color: var(--gold); }
.adv-opts summary:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: 2px; border-radius: 4px; }
.adv-opts[open] summary { color: var(--ink); margin-bottom: 14px; }

/* ---- 5 · motion respect ---- */
@media (prefers-reduced-motion: reduce) {
  .tabpane, .b3-card, .wheel-mount svg { animation: none; }
  .b3-card::before, .wheel-pane::before, .wheel-pane::after { animation: none; opacity: .6; }
  .b3-card { transition: none; }
  .b3-card:hover { transform: none; }
  .tab, .tab::before, .adv-opts summary,
  .urania-wheel .sel-asp, .urania-wheel .sel-pg { transition: none; }
}

/* ---- 6 · print — daylight version, all panes visible ---- */
@media print {
  .tabs { display: none; }
  /* the runtime toggles panes with .hidden{display:none!important} — print must win */
  .tabpane.hidden { display: block !important; }
  .tabpane { break-inside: avoid; margin-bottom: 18px; animation: none; }
  .b3-card, .b3-card:nth-child(1), .b3-card:nth-child(2), .b3-card:nth-child(3),
  .wheel-pane {
    background: #fff; border-color: #ccc; box-shadow: none;
  }
  .b3-card::before, .wheel-pane::before, .wheel-pane::after { display: none; }
  .b3-glyph { color: var(--gold); text-shadow: none; }
  .b3-label { color: var(--faint); }
  .b3-sign { color: var(--ink); }
  .b3-desc { color: var(--ink-soft); }
  /* the gold threads that keep the mystique on paper */
  .b3-desc::after, .wheel-meta::before { color: var(--gold); }
  .wheel-meta { color: var(--faint); }
  .wheel-mount svg { box-shadow: none; animation: none; }
  .wheel-tip { display: none; }
}

/* =============================================================================
   Urania · C1/C4/C5 layer — hero-form fusion, mobile affordances, feature shelf
   Append-only. Mobile-first; thumb-zone form above the fold; the WASM only fires
   on the explicit 'Gerar mapa' button (never on keystroke).
   ============================================================================= */

/* ---- C1 · hero + form fused above the fold ---- */
.hero-form { position: relative; padding: 40px 0 24px; }
.hero-form .hero-card {
  background: #FFFFFF; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: 0 1px 0 rgba(31,43,61,.02), 0 14px 40px -28px rgba(31,43,61,.25);
  max-width: 560px; margin: 22px auto 0; text-align: left;
}
/* beta seal — visible at the top of the hero (doutrina: beta em toda superfície) */
.beta-seal {
  position: absolute; top: 14px; right: 4px;
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold); background: #FFFDF6; border: 1px solid var(--gold-soft);
  border-radius: 999px; padding: 3px 10px;
}
@media (max-width: 560px) {
  .hero-form { padding: 22px 0 18px; }
  .hero-form .display { font-size: clamp(26px, 8vw, 34px); margin-bottom: 12px; }
  .hero-form .lede { font-size: 14px; margin-bottom: 12px; }
  .hero-form .hero-card { padding: 18px; margin-top: 16px; }
  /* thumb-zone: the 3 core fields and the submit are reachable one-handed */
  .hero-form .hero-card .row { grid-template-columns: 1fr 1fr; gap: 12px; }
  .beta-seal { top: 8px; right: 0; }
}

/* C4 · compact wheel — fatter PLANET-glyph stroke for phone legibility. Scoped
   to the planet glyph groups only (the lib emits .urania-wheel--compact and
   already handles spacing, ticks and degree-label suppression in the SVG). We
   deliberately do NOT touch aspect lines / ticks / leaders — their per-element
   stroke-width carries meaning (orb strength, tick weight). */
.urania-wheel--compact .sel-pg path,
.urania-wheel--compact .sel-pg circle:not(.sel-hit) { stroke-width: 1.9; }

/* ---- C4 · planet-chip carousel (compact wheels only) ---- */
.planet-chips {
  display: flex; gap: 8px; width: 100%; margin-top: 14px;
  overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none;
  padding-bottom: 4px; scroll-snap-type: x proximity;
}
.planet-chips::-webkit-scrollbar { display: none; }
.planet-chip {
  flex: 0 0 auto; scroll-snap-align: start;
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  min-width: 96px; min-height: 56px; /* ≥44px touch target */
  background: rgba(10,16,29,.55); border: 1px solid rgba(201,168,75,.35);
  border-radius: 12px; padding: 8px 12px; cursor: pointer; color: #EDE7D8;
  transition: border-color .2s, background .2s, transform .06s;
}
.planet-chip:active { transform: translateY(1px); }
.planet-chip.on { border-color: var(--gold-soft); background: rgba(201,168,75,.18); }
.planet-chip:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: 2px; }
.planet-chip .pc-glyph { font-family: var(--serif); font-size: 20px; color: var(--gold-soft); line-height: 1; }
.planet-chip .pc-body { font-family: var(--mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: rgba(237,231,216,.6); }
.planet-chip .pc-pos { font-family: var(--serif); font-size: 14px; color: #F4EFE3; white-space: nowrap; }

/* ---- C4 · expand button + full-screen overlay (native browser zoom) ---- */
.btn-expand { display: none; } /* only meaningful on compact wheels */
@media (max-width: 419px) { .btn-expand { display: inline-flex; } }
.wheel-overlay {
  position: fixed; inset: 0; z-index: 1000;
  background: radial-gradient(150% 120% at 50% -10%, #15233B 0%, #0A111F 70%, #060A12 100%);
  display: flex; align-items: center; justify-content: center;
  overflow: auto; -webkit-overflow-scrolling: touch; padding: 24px;
}
.wheel-overlay-stage { touch-action: pinch-zoom; } /* native pinch/scroll zoom */
.wheel-overlay-stage svg { display: block; max-width: none; height: auto; }
.wheel-overlay-close {
  position: fixed; top: 14px; right: 14px; z-index: 1001;
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(10,16,29,.9); color: #EDE7D8; border: 1px solid rgba(201,168,75,.45);
  font-size: 20px; line-height: 1; cursor: pointer;
}
.wheel-overlay-close:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: 2px; }

/* share button gets a touch of gold to read as the primary "delight" action */
.btn-share { width: auto; }

/* ---- C5 · feature shelf — honest invitations to the hidden engines ---- */
.feature-shelf { margin: 26px 0 4px; }
.shelf-title {
  font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--gold); margin: 0 0 14px;
}
.shelf-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 680px) { .shelf-grid { grid-template-columns: repeat(3, 1fr); } }
.shelf-card {
  text-align: left; display: flex; flex-direction: column; gap: 8px;
  background: linear-gradient(180deg, #FFFDF6 0%, var(--cream) 100%);
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 18px 16px; cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.shelf-card:hover { transform: translateY(-3px); border-color: var(--gold-soft); box-shadow: 0 18px 40px -28px rgba(31,43,61,.45); }
.shelf-card:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: 2px; }
.shelf-glyph { font-family: var(--serif); font-size: 28px; color: var(--gold); line-height: 1; }
.shelf-name { font-family: var(--serif); font-size: 19px; font-weight: 600; color: var(--ink); }
.shelf-desc { font-size: 13.5px; color: var(--faint); line-height: 1.5; }
.shelf-cta { font-family: var(--mono); font-size: 12px; letter-spacing: .06em; color: var(--gold); margin-top: 2px; }

/* ===== Capabilities (landing, antes de gerar) — mostra TODA a oferta grátis,
   com o card compartilhável (motor viral) em destaque. Mesmo design das cards
   do shelf, em grade responsiva. ===== */
.caps { margin: 30px 0 8px; }
.caps-head { text-align: center; margin: 0 auto 22px; max-width: 64ch; }
.caps-title { font-family: var(--serif); font-size: clamp(22px, 3vw, 30px); font-weight: 600; color: var(--ink); margin: 0 0 10px; }
.caps-sub { font-size: clamp(14px, 1.7vw, 16px); color: var(--faint); line-height: 1.55; margin: 0; }
.caps-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 560px) { .caps-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 880px) { .caps-grid { grid-template-columns: repeat(3, 1fr); } }
.caps-card {
  position: relative; text-align: left; display: flex; flex-direction: column; gap: 8px;
  background: linear-gradient(180deg, #FFFDF6 0%, var(--cream) 100%);
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 18px 18px; cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.caps-card:hover { transform: translateY(-3px); border-color: var(--gold-soft); box-shadow: 0 18px 40px -28px rgba(31,43,61,.45); }
.caps-card:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: 2px; }
.caps-glyph { font-family: var(--serif); font-size: 30px; color: var(--gold); line-height: 1; }
.caps-name { font-family: var(--serif); font-size: 20px; font-weight: 600; color: var(--ink); }
.caps-desc { font-size: 13.5px; color: var(--faint); line-height: 1.5; }
/* O card do compartilhamento é o herói viral: navy fundo, ocupa a 1ª célula em
   largura total no topo da grade, com selo "compartilhável". */
.caps-hero {
  background: linear-gradient(160deg, var(--ink) 0%, #16202F 100%);
  border-color: var(--ink);
}
@media (min-width: 560px) { .caps-hero { grid-column: 1 / -1; } }
.caps-hero .caps-name { color: #FBF8F1; }
.caps-hero .caps-desc { color: #D9D2C2; }
.caps-hero .caps-glyph { color: var(--gold-soft); }
.caps-hero:hover { border-color: var(--gold-soft); }
.caps-badge {
  position: absolute; top: 14px; right: 14px;
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink); background: var(--gold-soft); border-radius: 999px; padding: 3px 9px;
}
.caps-cta { display: block; width: auto; min-width: 240px; margin: 22px auto 0; }

@media print {
  .planet-chips, .btn-expand, .btn-share, .wheel-overlay, .feature-shelf, .caps, .beta-seal { display: none !important; }
}

@media (prefers-reduced-motion: reduce) {
  .shelf-card, .planet-chip, .caps-card { transition: none; }
  .shelf-card:hover, .caps-card:hover { transform: none; }
}

/* ── Toast · feedback efêmero (share-card e ações futuras) ─────────────────
   Pílula fixa no rodapé central; navy da casa + filete de ouro do tom certo.
   Criada on-demand pelo app.js (role="status" aria-live); sem markup no HTML. */
.u-toast {
  position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 14px);
  z-index: 1000; max-width: min(90vw, 420px);
  font-family: var(--sans, "Inter", system-ui, sans-serif); font-size: 14px; font-weight: 500;
  color: var(--cream); background: var(--ink);
  padding: 12px 18px; border-radius: 999px;
  border: 1px solid rgba(201, 168, 75, .55);
  box-shadow: 0 18px 40px -20px rgba(31, 43, 61, .8);
  opacity: 0; pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
}
.u-toast.is-shown { opacity: 1; transform: translate(-50%, 0); }
.u-toast[data-kind="err"]  { border-color: rgba(122, 46, 46, .8); }
.u-toast[data-kind="busy"] { border-color: rgba(201, 168, 75, .35); opacity: .96; }
@media (prefers-reduced-motion: reduce) {
  .u-toast { transition: opacity .12s ease; transform: translate(-50%, 0); }
}
