/* Твой таролог — стили сайта */
@font-face { font-family: "Cormorant"; src: url("fonts/cormorantgaramond.woff2") format("woff2"); font-weight: 300 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant"; src: url("fonts/cormorantgaramond-italic.woff2") format("woff2"); font-weight: 300 700; font-style: italic; font-display: swap; }
@font-face { font-family: "Onest"; src: url("fonts/onest.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }

:root {
  --ink: #140c31;
  --ink-2: #1b1140;
  --dusk: #2a1c63;
  --dusk-2: #352478;
  --lilac: #aa97fb;
  --lilac-soft: #c9bcff;
  --lilac-ink: #1a0f3f;
  --mist: #efe9ff;
  --haze: #a79dd4;
  --gold: #e8cc8a;
  --line: rgba(190, 172, 255, 0.2);
  --line-strong: rgba(190, 172, 255, 0.38);
  --serif: "Cormorant", "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --frame: min(1240px, 100% - 32px);
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--ink); color: var(--mist);
  font: 400 17px/1.62 var(--sans); letter-spacing: 0.005em;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
p { margin: 0 0 1em; }
h1, h2, h3 { font-family: var(--serif); font-weight: 500; margin: 0; letter-spacing: -0.01em; }
h1 { font-size: clamp(3rem, 8.4vw, 6.9rem); line-height: 0.92; }
h2 { font-size: clamp(2.2rem, 4.8vw, 3.7rem); line-height: 1.02; }
h3 { font-size: 1.62rem; line-height: 1.12; font-weight: 600; }
:focus-visible { outline: 2px solid var(--lilac-soft); outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--lilac); color: var(--lilac-ink); padding: 10px 16px; border-radius: 8px; z-index: 100; }
.skip:focus { top: 12px; }

/* ---------- frame: the page is one hairlined sheet ---------- */
.frame { width: var(--frame); margin: 0 auto; border-left: 1px solid var(--line); border-right: 1px solid var(--line); position: relative; }
.rule { border-top: 1px solid var(--line); }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 40; background: rgba(20, 12, 49, 0.82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.site-header .frame { display: flex; align-items: center; gap: 28px; padding: 14px 24px; border: 0; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--serif); font-size: 1.42rem; font-weight: 600; letter-spacing: 0; white-space: nowrap; }
.logo svg { width: 22px; height: 22px; color: var(--lilac); }
.nav { display: flex; gap: 22px; margin-left: auto; }
.nav a { text-decoration: none; font-size: 0.93rem; color: var(--haze); transition: color 0.2s; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--mist); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; text-decoration: none; font: 500 1rem/1 var(--sans); border-radius: 999px; padding: 16px 28px; transition: transform 0.2s var(--ease), background 0.2s, box-shadow 0.3s; cursor: pointer; border: 0; }
.btn-primary { background: var(--lilac); color: var(--lilac-ink); box-shadow: 0 0 0 0 rgba(170, 151, 251, 0.4); }
.btn-primary:hover { background: var(--lilac-soft); transform: translateY(-1px); box-shadow: 0 10px 40px -8px rgba(170, 151, 251, 0.55); }
.btn-ghost { background: transparent; color: var(--mist); box-shadow: inset 0 0 0 1px var(--line-strong); }
.btn-ghost:hover { box-shadow: inset 0 0 0 1px var(--lilac); }
.btn-sm { padding: 11px 18px; font-size: 0.92rem; }
.btn svg { width: 18px; height: 18px; flex: none; }
.site-header .btn { margin-left: 4px; }

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; background:
  radial-gradient(60% 50% at 50% 38%, rgba(106, 76, 214, 0.35), transparent 70%),
  radial-gradient(40% 40% at 80% 90%, rgba(170, 151, 251, 0.12), transparent 70%), var(--ink); }
.starfield { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.hero .frame { padding: clamp(56px, 9vw, 110px) 24px 0; text-align: center; }
.hero h1 { max-width: 13ch; margin: 0 auto; }
.hero h1 .l { display: block; }
.hero h1.sm { font-size: clamp(2.7rem, 6.2vw, 5.3rem); max-width: 17ch; }
.hero h1 .l2 { font-style: italic; font-weight: 400; color: var(--lilac-soft); }
.hero .lead { max-width: 58ch; margin: 26px auto 0; color: var(--haze); font-size: 1.1rem; }
.hero .actions { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 14px 22px; margin-top: 32px; }
.hero .hint { color: var(--haze); font-size: 0.95rem; text-decoration: none; border-bottom: 1px solid var(--line-strong); padding-bottom: 2px; }
.hero .hint:hover { color: var(--mist); }
.crumbs { font-size: 0.88rem; color: var(--haze); margin-bottom: 26px; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--mist); }

/* ---------- deck ---------- */
.reading { position: relative; padding: 56px 0 64px; }
.reading .prompt { font-family: var(--serif); font-style: italic; font-size: 1.45rem; color: var(--lilac-soft); margin: 0 auto 22px; max-width: 34ch; }
.deck { position: relative; height: clamp(300px, 36vw, 380px); display: flex; justify-content: center; align-items: flex-start; perspective: 1600px; }
.card { position: absolute; top: 14px; width: clamp(150px, 15.5vw, 190px); aspect-ratio: 120 / 206; border: 0; padding: 0; background: none; cursor: pointer; transform-style: preserve-3d; transition: transform 0.9s var(--ease), opacity 0.5s, filter 0.4s; will-change: transform; }
.card .side { position: absolute; inset: 0; border-radius: 12px; backface-visibility: hidden; -webkit-backface-visibility: hidden; overflow: hidden; }
.card .back { background: linear-gradient(160deg, #3a2887, #22155a); box-shadow: 0 24px 50px -18px rgba(5, 2, 20, 0.9), inset 0 0 0 1px rgba(201, 188, 255, 0.35); }
.card .face { transform: rotateY(180deg); background: radial-gradient(90% 60% at 50% 35%, #3d2a8e, #1f1452 75%); box-shadow: 0 30px 70px -20px rgba(5, 2, 20, 0.95), inset 0 0 0 1px rgba(232, 204, 138, 0.5), 0 0 60px -10px rgba(170, 151, 251, 0.45); }
.card-art { width: 100%; height: 100%; }
.b-frame, .c-frame { fill: none; stroke: rgba(201, 188, 255, 0.55); stroke-width: 1.2; }
.b-frame.thin, .c-frame.thin { stroke-width: 0.6; opacity: 0.7; }
.b-ray { stroke: rgba(201, 188, 255, 0.55); stroke-width: 0.9; stroke-dasharray: 2.5 2.5; }
.b-star path, .b-dots path { fill: none; stroke: var(--lilac-soft); stroke-width: 1; }
.face .c-frame { stroke: rgba(232, 204, 138, 0.7); }
.c-motif { fill: none; stroke: var(--gold); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.c-num { fill: var(--gold); font: 600 9.5px var(--serif); text-anchor: middle; letter-spacing: 0.06em; }
.c-scene { fill: none; stroke: var(--gold); stroke-width: 0.9; opacity: 0.45; stroke-linecap: round; stroke-linejoin: round; }
.c-orn path, .c-orn { fill: none; stroke: rgba(232, 204, 138, 0.75); stroke-width: 0.8; }
.c-cart { fill: rgba(20, 12, 49, 0.55); stroke: rgba(232, 204, 138, 0.7); stroke-width: 0.8; }
.c-ribbon { fill: rgba(20, 12, 49, 0.7); stroke: rgba(232, 204, 138, 0.8); stroke-width: 0.8; stroke-linejoin: round; }
.c-ribbon.tail { fill: rgba(42, 28, 99, 0.9); }
.c-dot { fill: var(--gold); }
.c-name { fill: var(--gold); font: 600 10.5px var(--serif); text-anchor: middle; }

.card[data-i="0"] { transform: translateX(-72%) translateY(26px) rotate(-11deg); }
.card[data-i="1"] { transform: translateX(0) rotate(0); z-index: 2; }
.card[data-i="2"] { transform: translateX(72%) translateY(26px) rotate(11deg); }
@media (hover: hover) {
  .deck:not(.revealed) .card[data-i="0"]:hover { transform: translateX(-76%) translateY(6px) rotate(-8deg); }
  .deck:not(.revealed) .card[data-i="1"]:hover { transform: translateY(-18px); }
  .deck:not(.revealed) .card[data-i="2"]:hover { transform: translateX(76%) translateY(6px) rotate(8deg); }
  .deck:not(.revealed) .card:hover .back { box-shadow: 0 30px 60px -18px rgba(5, 2, 20, 0.9), inset 0 0 0 1px var(--lilac-soft), 0 0 40px -6px rgba(170, 151, 251, 0.5); }
}
.deck.revealed .card { cursor: default; }
.deck.revealed .card.chosen { transform: translateY(-4px) rotateY(180deg) scale(1.06); z-index: 5; }
.deck.revealed .card:not(.chosen) { opacity: 0; pointer-events: none; }
.deck.revealed .card[data-i="0"]:not(.chosen) { transform: translateX(-120%) translateY(90px) rotate(-24deg); }
.deck.revealed .card[data-i="1"]:not(.chosen) { transform: translateY(120px); }
.deck.revealed .card[data-i="2"]:not(.chosen) { transform: translateX(120%) translateY(90px) rotate(24deg); }

.result { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.7s var(--ease); }
.result > div { overflow: hidden; }
.result.open { grid-template-rows: 1fr; }
.result-inner { max-width: 620px; margin: 0 auto; padding-top: 30px; opacity: 0; transform: translateY(12px); transition: opacity 0.6s 0.35s, transform 0.6s 0.35s var(--ease); }
.result.open .result-inner { opacity: 1; transform: none; }
.result .r-label { color: var(--haze); font-size: 0.95rem; margin-bottom: 6px; }
.result .r-title { font-family: var(--serif); font-size: clamp(2.2rem, 5vw, 3rem); line-height: 1; font-weight: 600; margin-bottom: 8px; }
.result .r-kw { color: var(--lilac-soft); font-family: var(--serif); font-style: italic; font-size: 1.25rem; margin-bottom: 16px; }
.result .r-answer { display: inline-block; font-family: var(--serif); font-size: 1.9rem; font-weight: 600; color: var(--ink); background: var(--gold); border-radius: 999px; padding: 4px 22px 6px; margin-bottom: 18px; }
.result .r-text { font-size: 1.08rem; color: var(--mist); max-width: 52ch; margin: 0 auto 26px; }
.result .r-cta { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.result .r-note { font-size: 0.9rem; color: var(--haze); max-width: 46ch; }
.result .r-again { background: none; border: 0; color: var(--haze); font: inherit; font-size: 0.93rem; cursor: pointer; text-decoration: underline; text-underline-offset: 4px; padding: 6px; }
.result .r-again:hover { color: var(--mist); }

/* ---------- page load: one orchestrated sequence ---------- */
.js .hero h1 .l, .js .hero .lead, .js .hero .actions, .js .hero .crumbs { opacity: 0; transform: translateY(18px); filter: blur(6px); }
.js .deck:not(.dealt) .card { opacity: 0; }
.loaded .hero h1 .l, .loaded .hero .lead, .loaded .hero .actions, .loaded .hero .crumbs { animation: rise 1.1s var(--ease) forwards; }
.loaded .hero h1 .l2 { animation-delay: 0.14s; }
.loaded .hero .lead { animation-delay: 0.32s; }
.loaded .hero .actions { animation-delay: 0.46s; }
@keyframes rise { to { opacity: 1; transform: none; filter: none; } }
.deck.dealing .card { animation: deal 1s var(--ease) both; }
.deck.dealing .card[data-i="1"] { animation-delay: 0.12s; }
.deck.dealing .card[data-i="2"] { animation-delay: 0.24s; }
@keyframes deal { from { opacity: 0; translate: 0 70px; rotate: 0deg; } to { opacity: 1; translate: 0 0; } }

/* ---------- sections ---------- */
section .frame { padding: clamp(64px, 8vw, 104px) 24px; }
.section-head { max-width: 760px; margin-bottom: 44px; }
.section-head p { color: var(--haze); font-size: 1.08rem; margin-top: 18px; max-width: 60ch; }

/* steps — the lilac band */
.band { background: var(--lilac); color: var(--lilac-ink); }
.band .frame { border-color: rgba(26, 15, 63, 0.16); }
.band h2 { color: var(--lilac-ink); }
.band .section-head p { color: rgba(26, 15, 63, 0.72); }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid rgba(26, 15, 63, 0.2); }
.step { padding: 30px 30px 8px 0; }
.step + .step { padding-left: 30px; border-left: 1px solid rgba(26, 15, 63, 0.2); }
.step .num { font-family: var(--serif); font-size: 3.4rem; line-height: 1; font-weight: 500; font-style: italic; margin-bottom: 18px; }
.step h3 { margin-bottom: 10px; }
.step p { color: rgba(26, 15, 63, 0.78); }
.band-note { margin-top: 34px; font-family: var(--serif); font-size: 1.35rem; font-style: italic; }

/* topics — panel grid */
.topics { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.topic { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 30px 28px 34px; text-decoration: none; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); transition: background 0.3s; min-height: 250px; }
.topic:hover { background: rgba(170, 151, 251, 0.06); }
.topic .glyph { width: 64px; height: 64px; color: var(--lilac); margin-bottom: 10px; transition: transform 0.6s var(--ease); }
.topic:hover .glyph { transform: rotate(-8deg) scale(1.06); }
.topic .glyph g { fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.topic p { color: var(--haze); margin: 0; }
.topic .more { margin-top: auto; padding-top: 12px; font-size: 0.92rem; color: var(--lilac-soft); }

/* example reading — a letter from Misty */
.example { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); border: 1px solid var(--line); }
.example .ex-cards { padding: 38px; border-right: 1px solid var(--line); background: radial-gradient(80% 60% at 50% 40%, rgba(106, 76, 214, 0.22), transparent); }
.example .ex-q { font-family: var(--serif); font-style: italic; font-size: 1.5rem; line-height: 1.25; margin-bottom: 28px; }
.mini-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.mini-card { margin: 0; }
.mini-card .side { border-radius: 8px; overflow: hidden; background: radial-gradient(90% 60% at 50% 35%, #3d2a8e, #1f1452 75%); box-shadow: inset 0 0 0 1px rgba(232, 204, 138, 0.5); aspect-ratio: 120 / 206; }
.mini-card figcaption { font-size: 0.85rem; color: var(--haze); text-align: center; margin-top: 8px; }
.example .ex-text { padding: 38px 42px; font-family: var(--serif); font-size: 1.28rem; line-height: 1.55; }
.example .ex-text p:last-child { margin-bottom: 0; }
.example .ex-tag { font-family: var(--sans); font-size: 0.88rem; color: var(--haze); margin-bottom: 18px; }

/* misty — honesty */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border-top: 1px solid var(--line); }
.split > div { padding: 34px 34px 10px 0; }
.split > div + div { padding-left: 34px; border-left: 1px solid var(--line); }
.split p { color: var(--haze); }
.split strong { color: var(--mist); font-weight: 500; }
.perks { list-style: none; margin: 0; padding: 0; }
.perks li { padding: 16px 0; border-bottom: 1px solid var(--line); }
.perks li:first-child { padding-top: 0; }
.perks b { display: block; font-family: var(--serif); font-size: 1.35rem; font-weight: 600; margin-bottom: 4px; color: var(--mist); }
.perks span { color: var(--haze); }

/* article (cluster pages) */
.article { max-width: 720px; }
.article h2 { font-size: clamp(1.9rem, 3.6vw, 2.6rem); margin: 56px 0 18px; }
.article h2:first-child { margin-top: 0; }
.article p, .article li { color: #d9d1f5; font-size: 1.06rem; }
.article ul { padding-left: 1.1em; margin: 0 0 1em; }
.article li { margin-bottom: 0.5em; }
.article li::marker { color: var(--lilac); }
.article .aside { border-left: 2px solid var(--lilac); padding: 4px 0 4px 20px; font-family: var(--serif); font-style: italic; font-size: 1.3rem; color: var(--mist); margin: 28px 0; }
.two-col { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 56px; align-items: start; }
.side-cta { position: sticky; top: 96px; border: 1px solid var(--line); padding: 30px; background: radial-gradient(100% 70% at 50% 0%, rgba(106, 76, 214, 0.25), transparent); }
.side-cta h3 { margin-bottom: 10px; }
.side-cta p { color: var(--haze); font-size: 0.98rem; }
.side-cta .btn { width: 100%; margin-top: 8px; }

/* faq */
.faq { max-width: 860px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 24px 0; font-family: var(--serif); font-size: 1.5rem; font-weight: 600; line-height: 1.2; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .pm { position: relative; flex: none; width: 18px; height: 18px; }
.faq summary .pm::before, .faq summary .pm::after { content: ""; position: absolute; left: 0; top: 8px; width: 18px; height: 1.5px; background: var(--lilac); transition: transform 0.35s var(--ease); }
.faq summary .pm::after { transform: rotate(90deg); }
.faq details[open] summary .pm::after { transform: rotate(0); }
.faq .answer { padding: 0 48px 24px 0; color: var(--haze); max-width: 70ch; }

/* related links */
.related { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); margin-top: 8px; }
.related a { padding: 22px 24px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); text-decoration: none; font-family: var(--serif); font-size: 1.35rem; font-weight: 600; transition: background 0.3s; }
.related a span { display: block; font-family: var(--sans); font-size: 0.9rem; font-weight: 400; color: var(--haze); margin-top: 4px; }
.related a:hover { background: rgba(170, 151, 251, 0.06); }

/* final cta */
.final { position: relative; overflow: hidden; background: radial-gradient(60% 80% at 50% 100%, rgba(106, 76, 214, 0.4), transparent 70%), var(--ink); }
.final .frame { text-align: center; }
.final h2 { max-width: 16ch; margin: 0 auto 18px; }
.final p { color: var(--haze); max-width: 50ch; margin: 0 auto 30px; }
.final-card { width: 92px; margin: 0 auto 28px; aspect-ratio: 120 / 206; border-radius: 9px; overflow: hidden; background: linear-gradient(160deg, #3a2887, #22155a); box-shadow: inset 0 0 0 1px rgba(201, 188, 255, 0.35), 0 0 60px -6px rgba(170, 151, 251, 0.5); animation: float 7s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-10px) rotate(2deg); } }

/* footer */
.site-footer { border-top: 1px solid var(--line); font-size: 0.93rem; color: var(--haze); }
.site-footer .frame { padding: 48px 24px 36px; display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px; }
.site-footer h4 { font-family: var(--serif); font-size: 1.2rem; font-weight: 600; color: var(--mist); margin: 0 0 12px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--mist); }
.site-footer .legal { grid-column: 1 / -1; border-top: 1px solid var(--line); padding-top: 22px; font-size: 0.84rem; line-height: 1.55; }
.age { display: inline-block; border: 1px solid var(--line-strong); border-radius: 6px; padding: 0 6px; margin-right: 8px; color: var(--mist); }

/* sticky mobile cta */
.dock { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 50; display: none; transform: translateY(140%); transition: transform 0.5s var(--ease); }
.dock .btn { width: 100%; box-shadow: 0 16px 40px -10px rgba(5, 2, 20, 0.9); }
.dock.show { transform: none; }

/* cookie */
.cookie { position: fixed; left: 16px; bottom: 16px; z-index: 60; max-width: 360px; background: var(--ink-2); border: 1px solid var(--line-strong); border-radius: 12px; padding: 10px 10px 10px 16px; font-size: 0.82rem; line-height: 1.4; color: var(--haze); display: flex; gap: 14px; align-items: center; box-shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.8); }
.cookie a { color: var(--lilac-soft); }
.cookie button { flex: none; }

/* ---------- result extras ---------- */
.result .r-more { display: inline-block; margin: -10px 0 26px; color: var(--lilac-soft); font-size: 0.95rem; text-underline-offset: 4px; }
.result .r-more:hover { color: var(--mist); }
.result .r-after { margin: 14px auto 0; text-align: center; }

/* three-card spread */
.deck.three .card { width: clamp(100px, 13vw, 168px); }
.deck.three.revealed .card.chosen { opacity: 1; pointer-events: none; }
.deck.three.revealed .card.chosen[data-i="0"] { transform: translateX(-112%) rotateY(180deg); }
.deck.three.revealed .card.chosen[data-i="1"] { transform: translateY(-4px) rotateY(180deg); transition-delay: 0.15s; }
.deck.three.revealed .card.chosen[data-i="2"] { transform: translateX(112%) rotateY(180deg); transition-delay: 0.3s; }
.three-list { list-style: none; margin: 8px auto 30px; padding: 0; max-width: 620px; text-align: left; border-top: 1px solid var(--line); }
.three-list li { display: grid; grid-template-columns: 120px 1fr; column-gap: 20px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.three-list .t-pos { grid-row: span 3; color: var(--haze); font-size: 0.92rem; padding-top: 6px; }
.three-list .t-name { font-family: var(--serif); font-size: 1.6rem; font-weight: 600; text-decoration: none; line-height: 1.1; }
.three-list .t-name:hover { color: var(--lilac-soft); }
.three-list .t-kw { font-family: var(--serif); font-style: italic; color: var(--lilac-soft); font-size: 1.1rem; }
.three-list .t-text { color: var(--mist); margin-top: 4px; }

/* birth-date arcana tool */
.arkan-tool { max-width: 640px; margin: 44px auto 70px; text-align: left; }
.arkan-tool label { display: block; font-family: var(--serif); font-size: 1.4rem; font-style: italic; color: var(--lilac-soft); margin-bottom: 12px; text-align: center; }
.arkan-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.arkan-row input { font: 500 1.05rem var(--sans); color: var(--mist); background: rgba(20, 12, 49, 0.7); border: 1px solid var(--line-strong); border-radius: 999px; padding: 14px 22px; min-width: 230px; color-scheme: dark; }
.arkan-row input:focus { outline: none; border-color: var(--lilac); box-shadow: 0 0 0 3px rgba(170, 151, 251, 0.25); }
.ak-err { text-align: center; color: #ffb4b4; margin-top: 12px; }
.ak-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin-top: 40px; border: 1px solid var(--line); }
.ak-card { display: grid; grid-template-columns: 96px 1fr; gap: 20px; padding: 26px; background: rgba(20, 12, 49, 0.55); }
.ak-card + .ak-card { border-left: 1px solid var(--line); }
.ak-face { border-radius: 8px; overflow: hidden; aspect-ratio: 120 / 206; background: radial-gradient(90% 60% at 50% 35%, #3d2a8e, #1f1452 75%); box-shadow: inset 0 0 0 1px rgba(232, 204, 138, 0.5); }
.ak-card .r-label { color: var(--haze); font-size: 0.9rem; margin: 0 0 4px; }
.ak-card .r-title { font-family: var(--serif); font-size: 2rem; font-weight: 600; line-height: 1; margin: 0 0 6px; }
.ak-card .r-kw { font-family: var(--serif); font-style: italic; color: var(--lilac-soft); margin-bottom: 10px; }
.ak-why { font-size: 0.88rem; color: var(--haze); margin-bottom: 8px; }
.ak-adv { margin-bottom: 10px; }
.ak-card .r-more { color: var(--lilac-soft); font-size: 0.93rem; text-underline-offset: 4px; }
.arkan-tool .r-cta { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-top: 30px; text-align: center; }
.arkan-tool .r-note { font-size: 0.9rem; color: var(--haze); max-width: 46ch; }

/* arcana page hero */
.arc-hero .frame { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 56px; align-items: center; text-align: left; padding-bottom: clamp(56px, 8vw, 96px); }
.arc-hero h1 { margin: 0; max-width: none; }
.arc-hero .lead { margin-left: 0; margin-right: 0; }
.arc-card { width: min(280px, 100%); margin: 0 auto; aspect-ratio: 120 / 206; border-radius: 16px; overflow: hidden; background: radial-gradient(90% 60% at 50% 35%, #3d2a8e, #1f1452 75%); box-shadow: inset 0 0 0 1px rgba(232, 204, 138, 0.55), 0 0 90px -10px rgba(170, 151, 251, 0.55), 0 40px 80px -30px #000; animation: float 8s ease-in-out infinite; }
.facts { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: 0; margin: 30px 0 0; border-top: 1px solid var(--line); }
.facts div { padding: 14px 28px 0 0; }
.facts div + div { padding-left: 28px; border-left: 1px solid var(--line); }
.facts dt { color: var(--haze); font-size: 0.86rem; margin-bottom: 4px; }
.facts dd { margin: 0; font-family: var(--serif); font-size: 1.35rem; font-weight: 600; }
.arc-hero .actions { justify-content: flex-start; }

/* arcana grids (hub and home strip) */
.arc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 26px 18px; }
.arc-grid a { text-decoration: none; text-align: center; }
.arc-grid .side { display: block; border-radius: 9px; overflow: hidden; aspect-ratio: 120 / 206; background: radial-gradient(90% 60% at 50% 35%, #3d2a8e, #1f1452 75%); box-shadow: inset 0 0 0 1px rgba(232, 204, 138, 0.45); transition: transform 0.4s var(--ease), box-shadow 0.4s; }
.arc-grid a:hover .side { transform: translateY(-6px); box-shadow: inset 0 0 0 1px rgba(232, 204, 138, 0.8), 0 18px 40px -16px rgba(170, 151, 251, 0.6); }
.arc-grid span.nm { display: block; margin-top: 10px; font-family: var(--serif); font-size: 1.12rem; font-weight: 600; line-height: 1.15; }
.arc-grid span.yn { display: block; font-size: 0.82rem; color: var(--haze); }
.section-more { margin-top: 34px; }
.pager { display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; align-items: center; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 22px 0; }
.pager a { text-decoration: none; font-family: var(--serif); font-size: 1.3rem; font-weight: 600; }
.pager a span { display: block; font-family: var(--sans); font-size: 0.85rem; font-weight: 400; color: var(--haze); }
.pager .nx { text-align: right; }
.pager .all { font-family: var(--sans); font-size: 0.95rem; font-weight: 500; color: var(--lilac-soft); }
.yn-table { width: 100%; border-collapse: collapse; margin: 8px 0 20px; font-size: 1rem; }
.yn-table th, .yn-table td { text-align: left; padding: 12px 14px 12px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.yn-table th { font-family: var(--serif); font-size: 1.15rem; font-weight: 600; white-space: nowrap; }
.yn-table td a { color: #d9d1f5; }

/* articles */
.read-time { color: var(--haze); font-size: 0.92rem; margin-top: 14px; }
.hero .read-time { margin-left: auto; margin-right: auto; }
.article .note { margin-top: 40px; font-size: 0.92rem; color: var(--haze); border-top: 1px solid var(--line); padding-top: 16px; }
.art-list { display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.art-item { display: flex; flex-direction: column; gap: 10px; padding: 30px 30px 26px; text-decoration: none; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); transition: background 0.3s; }
.art-item:hover { background: rgba(170, 151, 251, 0.06); }
.art-item h3 { font-size: 1.8rem; }
.art-item p { color: var(--haze); margin: 0; }
.art-item .read-time { margin-top: auto; padding-top: 8px; font-size: 0.86rem; color: var(--lilac-soft); }

/* ---------- responsive ---------- */
@media (max-width: 980px) {
  .site-header .frame { flex-wrap: wrap; row-gap: 0; }
  .site-header .btn { margin-left: auto; }
  .nav { order: 3; width: calc(100% + 32px); margin: 10px -16px -12px; padding: 10px 16px 12px; overflow-x: auto; gap: 20px; border-top: 1px solid var(--line); scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { white-space: nowrap; }
  .arc-hero .frame { grid-template-columns: 1fr; gap: 36px; }
  .arc-card { width: 190px; }
  .ak-grid { grid-template-columns: 1fr; }
  .ak-card + .ak-card { border-left: 0; border-top: 1px solid var(--line); }
  .steps, .topics, .related, .art-list { grid-template-columns: 1fr; }
  .step, .step + .step { padding: 26px 0 8px; border-left: 0; }
  .step + .step { border-top: 1px solid rgba(26, 15, 63, 0.2); }
  .topic { min-height: 0; }
  .example, .split, .two-col { grid-template-columns: 1fr; }
  .example .ex-cards { border-right: 0; border-bottom: 1px solid var(--line); }
  .split > div, .split > div + div { padding: 28px 0 6px; border-left: 0; }
  .split > div + div { border-top: 1px solid var(--line); }
  .side-cta { position: static; }
  .site-footer .frame { grid-template-columns: 1fr 1fr; }
  .site-footer .frame > div:first-child { grid-column: 1 / -1; }
  .dock { display: block; }
  body.has-dock { padding-bottom: 84px; }
  .cookie { left: 12px; right: 12px; bottom: 12px; max-width: none; }
  body.has-dock .cookie { bottom: 84px; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .frame { width: 100%; border-left: 0; border-right: 0; }
  .site-header .frame { padding: 12px 16px; }
  .logo { font-size: 1.22rem; }
  section .frame { padding-left: 18px; padding-right: 18px; }
  .hero .frame { padding: 34px 18px 0; }
  .hero .lead { font-size: 1rem; margin-top: 20px; }
  .hero .actions { margin-top: 24px; }
  .reading { padding-top: 40px; }
  .reading .prompt { font-size: 1.25rem; }
  .card { width: 128px; }
  .card[data-i="0"] { transform: translateX(-62%) translateY(20px) rotate(-10deg); }
  .card[data-i="2"] { transform: translateX(62%) translateY(20px) rotate(10deg); }
  .deck { height: 290px; }
  .deck.three .card { width: 100px; }
  .deck.three.revealed .card.chosen[data-i="0"] { transform: translateX(-108%) rotateY(180deg); }
  .deck.three.revealed .card.chosen[data-i="2"] { transform: translateX(108%) rotateY(180deg); }
  .three-list li { grid-template-columns: 1fr; }
  .three-list .t-pos { grid-row: auto; padding: 0; }
  .facts { grid-template-columns: 1fr 1fr 1fr; }
  .facts div, .facts div + div { padding: 12px 10px 0 0; }
  .facts div + div { padding-left: 10px; }
  .facts dd { font-size: 1.1rem; }
  .arc-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px 12px; }
  .arc-grid.strip { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 14px; margin: 0 -18px; padding: 4px 18px 10px; scrollbar-width: none; }
  .arc-grid.strip::-webkit-scrollbar { display: none; }
  .arc-grid.strip a { flex: 0 0 108px; scroll-snap-align: start; }
  .ak-card { grid-template-columns: 72px 1fr; padding: 20px 16px; }
  .pager { grid-template-columns: 1fr 1fr; }
  .pager .all { grid-column: 1 / -1; grid-row: 2; text-align: center; }
  .example .ex-cards, .example .ex-text { padding: 26px 20px; }
  .faq summary { font-size: 1.3rem; }
  .faq .answer { padding-right: 0; }
  .site-footer .frame { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0ms !important; transition-duration: 0.01ms !important; transition-delay: 0ms !important; scroll-behavior: auto !important; }
  .js .hero h1 .l, .js .hero .lead, .js .hero .actions, .js .hero .crumbs, .js .deck:not(.dealt) .card { opacity: 1; transform: none; filter: none; }
}
.cookie[hidden] { display: none; }
