/* Tarot keeps one progress rail above every step, outside the form. */
.tarot-flow-header{margin:0 0 16px}
/* Overlapping chevrons form one continuous track. Earlier steps sit above
   later ones so their arrow tips remain visible without gaps. */
.tarot-flow-steps{--step-tip:22px;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:0;max-width:760px;margin:0 auto;padding:0;list-style:none;font:14px/1.4 var(--ui);color:#e0d1ec;border:1px solid #d5b475;border-radius:8px;background:#170f25cc;overflow:hidden;isolation:isolate}
.tarot-flow-steps li{position:relative;min-width:0;isolation:isolate;z-index:3}
.tarot-flow-steps li:nth-child(2){z-index:2}
.tarot-flow-steps li:nth-child(3){z-index:1}
.tarot-flow-steps li::before,.tarot-flow-steps li:not(:last-child)::after{content:"";position:absolute;inset:0 calc(-1 * var(--step-tip)) 0 0;pointer-events:none;clip-path:polygon(0 0,calc(100% - var(--step-tip)) 0,100% 50%,calc(100% - var(--step-tip)) 100%,0 100%);z-index:-1}
.tarot-flow-steps li::before{background:#21162f}
.tarot-flow-steps li:last-child::before{right:0;clip-path:none}
.tarot-flow-steps li:not(:last-child)::after{background:#d5b475;clip-path:polygon(calc(100% - var(--step-tip) - 2px) 0,calc(100% - var(--step-tip)) 0,100% 50%,calc(100% - var(--step-tip)) 100%,calc(100% - var(--step-tip) - 2px) 100%,calc(100% - 2px) 50%);z-index:1}
.tarot-flow-steps :is(a,.tarot-step-label){display:flex;gap:12px;align-items:center;justify-content:center;min-height:36px;padding:3px 12px 10px calc(var(--step-tip) + 12px);color:inherit;text-decoration:none}
.tarot-flow-steps li:first-child :is(a,.tarot-step-label){padding-left:12px}
.tarot-step-number{font:19px/1 var(--reading);flex:none;font-variant-numeric:tabular-nums}
.tarot-flow-steps small{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.tarot-flow-steps [aria-current=step],.tarot-flow-steps .is-complete{color:#291c2b}
.tarot-flow-steps [aria-current=step]::before{background:linear-gradient(110deg,#f1dbab,#c69a4d)}
.tarot-flow-steps .is-complete::before{background:#c7a263}
.tarot-flow-steps :is([aria-current=step],.is-complete) small{color:#47314a}
.tarot-flow-steps .is-complete::after{background:#846537!important}
.tarot-flow-steps a:hover{color:#291c2b}
.tarot-flow-steps .is-complete:has(a:hover)::before,.tarot-flow-steps .is-complete:has(a:focus-visible)::before{background:#e6c58b}
.tarot-flow-steps a:hover small{text-decoration:underline;text-underline-offset:3px}
.internal-page .tarot-flow-steps a:focus-visible{outline:2px solid #291c2b;outline-offset:-6px;border-radius:6px}
.tarot-entry-layout{display:grid;grid-template-columns:minmax(0,.95fr) minmax(0,1.05fr);gap:64px;align-items:start}
.internal-page .tarot-entry-intro{padding:0}
.internal-page .tarot-entry-intro h1{margin:0 0 18px}
:root body .internal-page .tarot-entry-intro>.tarot-entry-lead{font-size:23px;line-height:1.45;margin:0 0 12px;max-width:36ch;color:#f1e8f6}
.internal-page .tarot-entry-about{margin:0;border:0;padding:0}
.internal-page .tarot-entry-about summary{font:13px/1.5 var(--ui);color:#eed099;cursor:pointer;min-height:36px;padding:6px 0;width:fit-content}
:root body .internal-page .tarot-entry-about p{font:19px/1.5 var(--reading);margin:10px 0}
.tarot-entry-guide{margin-top:26px;max-width:42ch}
.internal-page .tarot-entry-guide h2{font-size:26px;margin:0 0 12px}
:root body .internal-page .tarot-entry-guide p{font:20px/1.5 var(--reading);margin:0 0 12px}
.tarot-entry-deck{margin-top:24px;padding-top:18px;border-top:1px solid var(--page-line)}
.tarot-entry-deck .deck-info{padding:0;border:0;background:none;gap:16px}
.tarot-entry-deck .deck-info img{width:36px;height:60px;border-radius:5px}
.tarot-entry-deck .deck-info strong{font:22px/1.4 var(--reading)}
.tarot-entry-deck .deck-info span span{font:12px/1.5 var(--ui);margin-top:4px}
.internal-page .tarot-entry-form{padding:32px}
.internal-page .tarot-entry-form h2{font-size:30px;margin:0 0 10px}
:root body .internal-page .tarot-question-hint{font:20px/1.5 var(--reading);margin:0 0 28px}
.internal-page .tarot-entry-form .question-field textarea{height:208px;min-height:160px}
.tarot-question-meta{display:flex;justify-content:space-between;gap:16px;margin:12px 0 16px;font:12px/1.5 var(--ui);color:#d0c1dc}
.tarot-question-meta>span:first-child{color:#eed099}
#question-limit{white-space:nowrap;font-variant-numeric:tabular-nums}
:root body .internal-page .tarot-entry-form>.form-help{font-size:16px!important;line-height:1.5;margin:16px 0 0}
/* Keep the existing balance and account controls together; the menu is separate. */
.header-tools{display:flex;align-items:center;gap:24px;min-width:0}
.site-menu{position:relative;flex:none;font:14px/1.5 var(--ui);color:#f1e8f6}
.site-menu summary{cursor:pointer;padding:12px 0;min-height:44px;list-style:none}
.site-menu summary::-webkit-details-marker{display:none}
.site-menu summary::after{content:'⌄';margin-left:8px;color:#e8c788}
.site-menu[open] summary{color:#f1d6a1}
.site-menu nav{position:absolute;right:0;top:100%;min-width:236px;padding:10px;border:1px solid #d7be8b50;border-radius:12px;background:#1b1229;box-shadow:0 16px 40px #08041066;z-index:30}
.site-menu nav a{display:flex;align-items:center;min-height:44px;padding:10px 12px;color:#eee2f6;border-radius:6px;white-space:nowrap}
.site-menu nav a:hover{background:#d7be8b16;color:#f1d6a1}
.site-menu :is(summary,a):focus-visible{outline:2px solid #f0d19a;outline-offset:3px}
@media(max-width:1000px){.tarot-entry-layout{gap:32px}.internal-page .tarot-entry-form{padding:24px}}
@media(max-width:700px){
 /* Mobile already has persistent bottom navigation; keep its header compact. */
 .header-tools{gap:12px}.site-menu{display:none}
 .tarot-flow-header{margin-bottom:16px}
 .tarot-flow-steps{--step-tip:12px;font-size:11px}
 .tarot-flow-steps :is(a,.tarot-step-label){gap:6px;min-height:36px;padding:3px 4px 8px calc(var(--step-tip) + 4px)}
 .tarot-flow-steps li:first-child :is(a,.tarot-step-label){padding-left:4px}
 .tarot-step-number{font-size:20px}
 .tarot-flow-steps small{font-size:10px}
 .tarot-entry-layout{grid-template-columns:minmax(0,1fr);gap:28px}
 :root body .internal-page .tarot-entry-intro>.tarot-entry-lead{font-size:22px}
 .tarot-entry-guide{margin-top:20px;max-width:none}
 .internal-page .tarot-entry-form{padding:22px}
 .internal-page .tarot-entry-form h2{font-size:28px}
 .internal-page .tarot-entry-form .question-field textarea{height:180px}
 .tarot-question-meta{font-size:11px}
}
@media(max-width:380px){.header-tools{gap:8px}.site-menu summary::after{margin-left:3px}.tarot-flow-steps :is(a,.tarot-step-label){gap:4px;font-size:10px}.tarot-flow-steps small{font-size:9px}}

/* Reading surfaces: display lettering is reserved for the main title. */
:root[data-palette][data-theme] body #main :is(h2,h3,h4,h5,h6){font-family:var(--reading);font-weight:400;background:none;filter:none;color:#ecd7ae;-webkit-text-fill-color:currentColor;line-height:1.35}
:root body .internal-page .review-panel,:root body .internal-page .reading-wait{margin:0 auto;max-width:650px}
.reading-wait{text-align:center;min-height:340px;display:flex;flex-direction:column;align-items:center;justify-content:center}
.reading-wait-orbit{display:grid;place-items:center;width:84px;height:84px;margin:28px auto;border:1px solid #d7be8b44;border-top-color:#f0d19a;border-radius:50%;animation:reading-orbit 3s linear infinite;color:#f0d19a}
.reading-wait-orbit span{font-size:32px;animation:reading-orbit 3s linear infinite reverse}
@keyframes reading-orbit{to{transform:rotate(360deg)}}
:root body .internal-page .reflection{padding:24px 0 0;margin-top:24px;border:0;border-top:1px solid var(--page-line);border-radius:0;background:none;box-shadow:none;backdrop-filter:none}
.reading-role{display:block;text-align:center;margin-bottom:8px;font:13px/1.4 var(--ui);color:#eddbb7}
.internal-page .reading-symbols:has(.reading-card) figcaption strong{display:block;font:24px/1.25 'AstroMagic Display',var(--reading);color:#eddcb7;overflow-wrap:normal}
.internal-page .interpretation>.eyebrow{display:block;margin:22px 0 6px}
.internal-page .interpretation>.eyebrow+p{margin-top:0}
.reading-card{display:block;width:100%;padding:0;border:0;border-radius:12px;background:none;cursor:zoom-in}
.reading-card img{display:block;width:100%;border-radius:12px;transition:filter .2s}
.reading-card:hover img{filter:brightness(1.12)}
.reading-card:focus-visible{outline:2px solid #f0d19a;outline-offset:4px}
.visually-hidden{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip-path:inset(50%)!important;white-space:nowrap!important;border:0!important}
.tarot-choice .tarot-table-head{display:block;text-align:center;margin-bottom:8px}
.tarot-choice .tarot-table-head>div:first-child{display:block}
.tarot-choice .tarot-scroll-help{display:block;max-width:650px;margin:0 auto;font:18px/1.45 var(--reading);color:#dfd2e7}
.tarot-choice .tarot-picked{max-width:680px;margin-bottom:20px}
.tarot-choice .tarot-position{justify-content:center;border:0;gap:16px}
.tarot-choice .tarot-position-number{position:relative;width:48px;height:80px;flex:none;border-radius:6px;overflow:visible;background:#170d23;border:1px solid #c3a77055;transition:box-shadow .3s,border-color .3s}
.tarot-position-number img{display:block;width:100%;height:100%;border-radius:5px;opacity:.28;transition:opacity .3s}
.tarot-position-number>span{position:absolute;inset:0;display:grid;place-items:center;text-shadow:0 2px 4px #000;font:22px/1 var(--reading);color:#ffe6b4}
.tarot-choice .is-filled .tarot-position-number{border-color:#edcd8c;box-shadow:0 0 18px #e4bc655c,0 0 5px #f7dfa488;animation:card-slot-glow .45s ease-out}
.tarot-choice .is-filled .tarot-position-number img{opacity:1}
@keyframes card-slot-glow{from{box-shadow:0 0 0 #e4bc6500}to{box-shadow:0 0 18px #e4bc655c,0 0 5px #f7dfa488}}
.tarot-choice-bottom{justify-content:flex-end}
body[data-page=choose] .internal-page .tarot-choose-header{margin-bottom:12px}
@media(max-width:700px){
 .tarot-entry-page{display:flex;flex-direction:column}
 .tarot-entry-page>.tarot-entry-layout{display:contents}
 .tarot-entry-page .tarot-entry-intro{order:0;margin-bottom:28px}
 .tarot-entry-page>.tarot-flow-header{order:1;margin-bottom:12px}
 .tarot-entry-page .tarot-entry-form{order:2}
 .tarot-flow-steps{font-size:11px;--step-tip:10px}
 .tarot-choice .tarot-position{gap:8px;align-items:center;text-align:center}
 .tarot-choice .tarot-position-number{width:42px;height:70px}
 .tarot-choice .tarot-scroll-help{font-size:17px}
 .tarot-position small{min-height:0}
 .reading-role{font-size:11px;min-height:2.8em;margin-bottom:6px}
 .internal-page .reading-symbols:has(.reading-card) figcaption strong{font-size:21px}
}
@media(prefers-reduced-motion:reduce){.reading-wait-orbit,.reading-wait-orbit span,.tarot-choice .is-filled .tarot-position-number{animation:none}.tarot-position-number,.tarot-position-number img{transition:none}}
[data-motion=off] .reading-wait-orbit,[data-motion=off] .reading-wait-orbit span,[data-motion=off] .tarot-choice .is-filled .tarot-position-number{animation:none}

.internal-page .tarot-fan-title{text-align:center;font-size:34px;margin:12px 0}
@media(max-width:700px){.internal-page .tarot-fan-title{font-size:27px}}
