/* Ashen Covenant website — the game's Pyre look (UI.md § Pyre): stage, rail, sheet, one ember. */

@font-face { font-family: "Cormorant Garamond"; src: url(fonts/cormorant.woff2) format("woff2"); font-weight: 300 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url(fonts/cormorant-italic.woff2) format("woff2"); font-weight: 300 700; font-style: italic; font-display: swap; }
@font-face { font-family: "EB Garamond"; src: url(fonts/eb.woff2) format("woff2"); font-weight: 400 800; font-style: normal; font-display: swap; }
@font-face { font-family: "EB Garamond"; src: url(fonts/eb-italic.woff2) format("woff2"); font-weight: 400 800; font-style: italic; font-display: swap; }

:root {
  --stage: #1B1714; --rail: #0E0C0B; --stage-lit: #241F1B;
  --bone: #EAE0CF; --ash: #B7AA97; --ash2: #978B79;
  --ember: #CF5A2E; --ember-hi: #E5916E; --ember-deep: #7C361B;
  --ink: #1C130D; --ink-soft: #4A3A2E;
  --rule: rgba(234, 224, 207, .10);
  --display: "Cormorant Garamond", Georgia, serif;
  --text: "EB Garamond", Georgia, serif;
}

* { box-sizing: border-box; }
html { background: var(--stage); }
body { margin: 0; background: var(--stage); color: var(--bone); font: 19px/1.5 var(--text); font-variant-numeric: lining-nums; overflow-x: clip; }
a { color: var(--ember-hi); }
a:hover { color: var(--bone); }
img { display: block; }
.caps { text-transform: uppercase; letter-spacing: .2em; }
.italic { font-style: italic; }
/* a link is a small control: small caps in ash, bone on hover, no frame and no underline (the game's PyreButton LINK, 2026-10-26) */
.link { display: inline-flex; align-items: center; min-height: 44px; padding: 0; background: none; border: 0; cursor: pointer; font: 500 14px var(--text); letter-spacing: .16em; text-transform: uppercase; color: var(--ash); text-decoration: none; transition: color .2s ease; }
.link:hover { color: var(--bone); }
.sheet .link { color: #3A3027; }
.sheet .link:hover { color: var(--ink); }
.link.quiet { color: var(--ash2); }
[hidden] { display: none !important; }

/* ---- the bar: the game's top bar, its black half see-through ---- */
.bar { position: sticky; top: 0; z-index: 50; background: rgba(14, 12, 11, .5); border-bottom: 1px solid rgba(234, 224, 207, .08); }
.bar-in { padding: 0 40px; min-height: 72px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 32px; }
.wordmark { color: var(--bone); text-decoration: none; font: 600 30px/1 var(--display); white-space: nowrap; }
.wordmark .italic { font-weight: 500; }
.wordmark:hover { color: var(--bone); }
.bar-right { display: flex; align-items: center; gap: 28px; }
.bar-link { font-size: 15px; color: var(--ash); text-decoration: none; }
.plate { display: inline-flex; align-items: baseline; gap: 10px; min-height: 44px; padding: 9px 16px; background: var(--stage-lit); border: 1px solid rgba(207, 90, 46, .55); border-radius: 3px; text-decoration: none; color: var(--bone); }
.plate:hover { border-color: var(--ember-hi); color: var(--bone); }
.plate .caps { font-size: 15px; }
.plate .italic { font-size: 16px; color: var(--ember-hi); }
.avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; object-position: 50% 22%; box-shadow: 0 0 0 1.5px var(--bone), 0 4px 12px rgba(8, 6, 5, .5); }

/* ---- buttons: PyreButton WHITE / BLACK ---- */
.btn { position: relative; overflow: hidden; display: inline-flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 72px; padding: 0 38px; border: 0; border-radius: 3px; text-decoration: none; font: 600 18px var(--text); letter-spacing: .2em; text-transform: uppercase; cursor: pointer; transition: transform .25s ease; }
.btn::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--ember); transform: scaleX(0); transform-origin: left; transition: transform .5s ease; }
.btn:hover { transform: translateY(-3px); }
.btn:hover::before { transform: scaleX(1); }
.btn svg { transition: transform .3s ease; flex: none; }
.btn:hover svg { transform: translateX(5px); }
/* WHITE is the slab (2026-10-26): a paper face on one 4 px lit edge with one soft shadow; a hover
   lifts the face 2 px off its edge, a press sinks it 3 px onto it. The edge stays where it is. */
.btn.white { background: linear-gradient(180deg, #EEE6D5, #DFD5C1); color: var(--ink); text-shadow: 0 1px rgba(255, 255, 255, .5); box-shadow: inset 0 1px rgba(255, 255, 255, .55), 0 4px 0 #A4957C, 0 12px 20px rgba(0, 0, 0, .45); transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), box-shadow .3s cubic-bezier(.34, 1.56, .64, 1); }
.btn.white:hover { transform: translateY(-2px); box-shadow: inset 0 1px rgba(255, 255, 255, .55), 0 6px 0 #A4957C, 0 14px 20px rgba(0, 0, 0, .45); }
.btn.white:active { transform: translateY(3px); box-shadow: inset 0 1px rgba(255, 255, 255, .55), 0 1px 0 #A4957C, 0 9px 20px rgba(0, 0, 0, .45); transition-duration: .08s; }
.btn.black { background: var(--ink); color: var(--bone); }
.btn.small { min-height: 52px; padding: 0 22px; font-size: 15px; }
.btn[disabled] { cursor: default; transform: none; }
.btn[disabled]::before { transform: scaleX(0); }
.btn.black[disabled] span { opacity: .45; }

/* ---- type ---- */
.kicker { font-size: 13px; color: var(--ember-hi); }
.kicker .dot { color: var(--ash2); }
.h2 { margin: 0; font: 500 clamp(44px, 4.6vw, 64px)/1 var(--display); }
.label { font-size: 12px; color: var(--ash2); }
.footer { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; padding: 40px 36px; }
.footer nav { display: flex; gap: 28px; }
.footer a { font-size: 11px; color: var(--ash2); text-decoration: none; }
.footer a:hover { color: var(--bone); }
.footer .mark { font: 22px var(--display); color: var(--ash2); }

/* ---- entrance ---- */
.rise { opacity: 0; animation: rise 1.1s cubic-bezier(.2, .7, .2, 1) forwards; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* ---- hero ---- */
.hero { position: relative; overflow: hidden; margin-top: -1px; padding-bottom: 8px; background: linear-gradient(to bottom, rgba(27, 23, 20, 0) 75%, var(--stage) 100%), radial-gradient(ellipse 75% 38% at 50% 58%, var(--stage-lit) 0%, var(--stage) 100%); }
.hero-text { position: relative; z-index: 2; padding: 56px 24px 0; display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero h1 { margin: 18px 0 0; font: 500 clamp(64px, 8vw, 124px)/.92 var(--display); letter-spacing: -.01em; }
.hero .sub { max-width: 760px; margin: 22px auto 0; font-size: 21px; color: var(--ash); }
.hero .ctas { margin-top: 32px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 16px 28px; }
.hero .ctas .or { font-style: italic; font-size: 19px; color: var(--ash2); }
.mote { position: absolute; bottom: -10px; border-radius: 50%; opacity: 0; animation: mote linear infinite; }
@keyframes mote { 0% { opacity: 0; transform: translate(0, 0); } 15% { opacity: .8; } 80% { opacity: .35; } 100% { opacity: 0; transform: translate(40px, -760px); } }

/* ---- drifting rows of real cards ---- */
.edge { overflow: hidden; -webkit-mask-image: linear-gradient(to right, transparent 0, #000 12%, #000 88%, transparent 100%); mask-image: linear-gradient(to right, transparent 0, #000 12%, #000 88%, transparent 100%); }
.drift { display: flex; width: max-content; will-change: transform; backface-visibility: hidden; touch-action: pan-y; }   /* moved by site.js; a sideways swipe drags the row, an upright one scrolls the page */
.cd { position: relative; z-index: 1; width: 200px; flex: none; margin-right: 36px; transition: transform .4s ease, z-index 0s .12s; }   /* stays on top until its slip has faded */
.cd img { width: 248px; height: auto; max-width: none; margin: -24px; }   /* the shadow is baked into the image's 24 px margin */
.cd:nth-child(3n) { transform: rotate(-2deg) translateY(10px); }
.cd:nth-child(3n+1) { transform: rotate(1.5deg); }
.cd:nth-child(3n+2) { transform: rotate(-.5deg) translateY(-8px); }
@media (hover: hover) {   /* a phone's tap leaves :hover stuck on the card; there the row only swipes */
  .cd:hover { transform: translateY(-10px); z-index: 5; transition: transform .4s ease, z-index 0s; }
  .drift:has(.cd:hover) .cd:not(:hover) { z-index: 1; transition: transform .4s ease, z-index 0s; }   /* the newly hovered card always wins over the one still fading */
}

/* the card's paper slip, as the game's CardInfoTip */
.tip { position: absolute; top: 0; left: calc(100% + 14px); width: 280px; padding: 16px 20px 18px; background: linear-gradient(180deg, #EAE1CF, #DDD2BD); color: var(--ink); border-radius: 4px; box-shadow: 0 0 0 1px var(--rail), 0 22px 50px rgba(8, 6, 5, .65); text-align: left; opacity: 0; pointer-events: none; transform: translateY(6px); transition: opacity .12s ease, transform .3s ease; z-index: 30; }   /* fades out fast */
@media (hover: hover) { .cd:hover .tip { opacity: 1; transform: none; transition: opacity .25s ease, transform .3s ease; } }   /* fades in gently */
.tip .head { font-size: 12px; color: var(--ember-deep); }
.tip .name { margin-top: 2px; font: italic 600 26px/1.05 var(--display); }
.tip .kw { margin-top: 8px; font-size: 13px; font-weight: 600; }
.tip p { margin: 8px 0 0; font-size: 16px; line-height: 1.4; }
.tip b { font-weight: 600; }

/* ---- how it plays ---- */
.how { padding: 72px 60px 128px; }
.rule-head { display: flex; align-items: center; gap: 20px; }
.rule-head h2 { margin: 0; font-size: 13px; font-weight: 500; color: var(--ash); white-space: nowrap; }
.rule-head span { flex: 1; height: 1px; background: var(--rule); }
.cells { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-top: 8px; border-bottom: 1px solid var(--rule); }
.cell { padding: 28px 28px 32px; border-right: 1px solid var(--rule); }
.cell:first-child { padding-left: 0; }
.cell:last-child { border-right: 0; padding-right: 0; }
.cell .label { font-size: 12px; }
.cell .big { margin-top: 10px; font: 500 34px/1.1 var(--display); }
.cell p { margin: 10px 0 0; font-style: italic; font-size: 18px; color: var(--ash2); }
.creed .cells { margin-top: 32px; }

/* ---- the table ---- */
.table { padding: 0 60px 160px; }
.table .center { text-align: center; }
.stage3d { perspective: 1800px; margin: 72px auto 0; max-width: 1240px; }
.shot { width: 100%; height: auto; border-radius: 6px; box-shadow: 0 0 0 1px var(--rule), 0 60px 120px rgba(8, 6, 5, .7); }
.pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 56px; max-width: 1240px; margin: 160px auto 0; align-items: start; }
.pair figure { margin: 0; }
.pair figcaption { margin-top: 22px; }
.pair figcaption .big { font: 500 30px var(--display); }
.laid { transition: transform .6s cubic-bezier(.2, .8, .2, 1); }
.laid.l { transform: rotate(-.8deg); }
.laid.r { transform: rotate(.6deg) translateY(24px); }
.laid:hover { transform: none; }
.pair .r-cap { margin-top: 46px; }

.closing { border-top: 1px solid rgba(234, 224, 207, .08); padding: 128px 24px 0; text-align: center; }
.closing h2 { margin: 0; font: 500 clamp(56px, 6vw, 96px)/.95 var(--display); }
.closing p { margin: 22px 0 0; font-size: 21px; color: var(--ash); }

@supports (animation-timeline: view()) {
  .reveal { animation: reveal linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
  @keyframes reveal { from { opacity: 0; transform: translateY(48px); } to { opacity: 1; transform: none; } }
  .tableshot { transform-origin: 50% 100%; animation: tablerise linear both; animation-timeline: view(); animation-range: entry 0% entry 100%; }
  @keyframes tablerise { from { transform: rotateX(10deg) scale(.96) translateY(24px); opacity: .5; } to { transform: none; opacity: 1; } }
  .slide { animation: slide linear both; animation-timeline: view(); animation-range: entry 0% entry 100%; }
  @keyframes slide { from { opacity: 0; transform: translateY(32px); } to { opacity: 1; transform: none; } }
}

/* ---- pages: sign in, account, download ---- */
.page { padding: 40px 60px 96px; }
.sheet { background: linear-gradient(180deg, #EAE1CF, #DDD2BD); color: var(--ink); border-radius: 8px; box-shadow: 0 0 0 1px var(--rail), 0 40px 90px rgba(8, 6, 5, .7); }
.sheet a { color: var(--ember-deep); }
.sheet a:hover { color: var(--ink); }
.field-l { display: flex; flex-direction: column; gap: 2px; }
.field-l .caps { font-size: 13px; color: var(--ember-deep); }
.field { width: 100%; border: 0; border-bottom: 1px solid rgba(28, 19, 13, .3); background: transparent; padding: 4px 0 10px; font: italic 21px var(--text); color: var(--ink); outline: none; transition: border-color .2s; border-radius: 0; }
.field::placeholder { color: #8A7A69; }
.field:focus { border-bottom-color: var(--ember); }
/* a choice between words: italic, the chosen word inked over a 2 px ember underline (IndexFilter's words form) */
.chip { border: 0; background: transparent; min-height: 44px; padding: 0 8px; font: italic 20px var(--text); color: var(--ink-soft); cursor: pointer; text-decoration: underline 2px transparent; text-underline-offset: 8px; transition: color .2s ease, text-decoration-color .2s ease; }
.chip:hover { color: var(--ink); }
.chip[aria-pressed="true"] { color: var(--ink); text-decoration-color: var(--ember); }
.say { min-height: 1.5em; margin: 18px 0 0; font-style: italic; font-size: 18px; color: var(--ink-soft); }
.say.bad { color: var(--ember-deep); }

.signin-main { flex: 1; position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; padding: 64px 16px; min-height: calc(100vh - 72px); }
.signin-main .backdrop { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: blur(18px) brightness(.45); transform: scale(1.1); }
.leaf { position: relative; width: 100%; max-width: 600px; padding: 52px 64px 48px; }
.leaf h1 { margin: 28px 0 0; font: italic 500 46px/1.05 var(--display); }
.leaf form { display: flex; flex-direction: column; gap: 26px; margin-top: 32px; }
.leaf .btn { margin-top: 10px; }
.leaf .foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; margin-top: 24px; font-size: 18px; font-style: italic; color: var(--ink-soft); }
.leaf .legal { margin-top: 18px; font-size: 16px; color: var(--ink-soft); }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.stats .cell .big { font-size: 40px; margin-top: 6px; }
.stats .cell .sub { font-style: italic; font-size: 17px; color: var(--ash2); }
.stats .num { font-variant-numeric: lining-nums tabular-nums; }
.cols { display: flex; flex-wrap: wrap; gap: 48px 72px; margin-top: 48px; }
.cols > section { flex: 1 1 400px; min-width: 0; }
.cols h2 { margin: 0; font-size: 13px; font-weight: 500; color: var(--ash); }
.ledger { margin-top: 14px; border-top: 1px solid var(--rule); }
.ledger .row { display: flex; align-items: baseline; gap: 16px; padding: 16px 0; border-bottom: 1px solid rgba(234, 224, 207, .07); }
.ledger .row > span:first-child { width: 120px; flex: none; color: var(--ash2); }
.ledger .row .val { flex: 1; min-width: 0; font-size: 22px; overflow-wrap: anywhere; }
.inline-form { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: center; margin-top: 16px; }
.inline-form input { flex: 1 1 220px; border: 0; border-bottom: 1px solid rgba(234, 224, 207, .3); background: transparent; color: var(--bone); font: italic 20px var(--text); padding: 4px 0 8px; outline: none; }
.inline-form input:focus { border-bottom-color: var(--ember); }
.page-say { min-height: 1.5em; margin: 14px 0 0; font-style: italic; font-size: 17px; color: var(--ash2); }
.page-say.bad { color: var(--ember-hi); }
.links { display: flex; flex-wrap: wrap; gap: 8px 32px; margin-top: 24px; font-size: 18px; }


.dl-hero { max-width: 620px; padding: 96px 0 72px; }
.dl-hero h1 { margin: 18px 0 0; font: 500 clamp(64px, 7vw, 104px)/.95 var(--display); }
.dl-hero p { margin: 24px 0 0; font-size: 21px; color: var(--ash); }
.dl-cards { position: absolute; right: max(40px, 8vw); top: 150px; width: 460px; height: 470px; }
.dl-cards img { position: absolute; width: 248px; height: auto; }   /* the cards' own shadows are baked in */
@media (max-width: 1200px) { .dl-cards { display: none; } }
.dl-table { max-width: 920px; }
.dl-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1.3fr) minmax(0, 1.6fr); gap: 16px; align-items: center; min-height: 84px; padding: 14px 0; border-bottom: 1px solid rgba(234, 224, 207, .07); }
.dl-row.head { min-height: 0; padding: 0 0 10px; border-bottom-color: rgba(234, 224, 207, .12); }
.dl-row .sys { font: 500 32px/1.1 var(--display); }
.dl-row .note { font-style: italic; font-size: 16px; color: var(--ash2); }
.dl-row .act { display: flex; justify-content: flex-end; font-style: italic; color: var(--ash2); }

@media (max-width: 900px) {
  .bar-in { padding: 0 16px; }
  .how, .table, .page { padding-left: 16px; padding-right: 16px; }
  .tip { display: none; }
  .laid.r { transform: rotate(.6deg); }
  .cell { padding-left: 0 !important; border-right: 0; border-bottom: 1px solid var(--rule); }
  .leaf { padding: 40px 24px 36px; }
  .dl-cards { display: none; }
}
@media (max-width: 600px) {   /* a phone held upright: the bar stays one row */
  .bar-in { min-height: 56px; flex-wrap: nowrap; gap: 12px; }
  .bar { background: var(--rail); }   /* half see-through, the text scrolling under it read as clutter */
  .wordmark { font-size: 22px; }
  .bar-right { gap: 16px; }
  .bar-link { font-size: 12px; letter-spacing: .14em; }
  .plate { min-height: 40px; padding: 8px 12px; }
  .plate .caps { font-size: 13px; letter-spacing: .16em; }
  .plate .italic { display: none; }
  .avatar { width: 36px; height: 36px; }
  .cd { width: 150px; margin-right: 24px; }
  .cd img { width: 186px; margin: -18px; }
}
@media (prefers-reduced-motion: reduce) {
  .mote { animation: none; }
  .rise { animation: none; opacity: 1; }
}
