/* Inner pages: gallery, news, download, guide, status, policies, and the account screens. Openers are in chapters.css. */

/* ---------- Call to action band (chapter pages, Our story) ---------- */

.cta-band { padding: 0 0 clamp(80px, 10vw, 120px); }
.cta-band-inner { display: flex; flex-wrap: wrap; gap: 24px 48px; align-items: center; justify-content: space-between; padding: clamp(28px, 4vw, 48px); border-radius: 20px; border: 1px solid rgb(183 163 240 / 0.3); background: radial-gradient(120% 140% at 0% 0%, rgb(183 163 240 / 0.18), rgb(27 21 51 / 0.8) 60%); }
.cta-band-inner > div:first-child { display: grid; gap: 10px; max-width: 620px; }
.cta-band-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Gallery ---------- */

.gallery-section { padding: 24px 0 clamp(80px, 10vw, 120px); }
.gallery { columns: 3 320px; column-gap: 18px; }
.gallery-item { break-inside: avoid; margin: 0 0 18px; display: grid; gap: 10px; scroll-margin-top: 96px; }
.gallery-item figcaption, .gallery-pair figcaption { color: var(--ash); font-size: 0.875rem; line-height: 1.45; }
.gallery-open { position: relative; display: block; width: 100%; padding: 0; border: 1px solid var(--ash-20); border-radius: 14px; overflow: hidden; background: #000; cursor: zoom-in; }
.gallery-open img { width: 100%; transition: scale 900ms var(--ease-out), opacity 300ms; }
.gallery-open:hover img { scale: 1.03; }
.gallery-pairs-head { margin-top: clamp(56px, 8vw, 96px); }
.gallery-pairs { display: grid; gap: 40px; }
.gallery-pair { margin: 0; display: grid; gap: 12px; scroll-margin-top: 96px; }
.gallery-pair-shots { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pair-tag { position: absolute; left: 12px; top: 12px; padding: 5px 10px; border-radius: 999px; background: rgb(15 11 30 / 0.75); font: 600 0.6875rem/1 var(--font-ui); letter-spacing: 0.2em; text-transform: uppercase; color: var(--ash); }
.pair-tag-now { color: var(--crystal); }
@media (max-width: 700px) { .gallery-pair-shots { grid-template-columns: 1fr; } }

.lightbox { width: min(96vw, 1600px); max-height: 94svh; padding: 0; border: 1px solid var(--ash-20); border-radius: 16px; background: var(--night-deep); color: var(--mist); overflow: hidden; }
.lightbox::backdrop { background: rgb(8 6 15 / 0.88); backdrop-filter: blur(6px); }
.lightbox img { width: 100%; max-height: calc(94svh - 120px); object-fit: contain; background: #000; }
.lightbox-caption { padding: 14px 20px 0; color: var(--mist-80); font-size: 0.9375rem; }
.lightbox-controls { display: flex; justify-content: flex-end; gap: 10px; padding: 12px 16px 16px; }

/* ---------- Road page ---------- */

.road-page { padding-top: 24px; }
.road-chapter { color: var(--lilac); text-decoration: none; margin-top: 4px; justify-self: start; }
.road-note { margin-top: 40px; }

/* ---------- News ---------- */

.news-list-section { padding: 24px 0 clamp(80px, 10vw, 120px); }
.news-list { list-style: none; margin: 0; padding: 0; display: grid; }
.news-row { display: grid; gap: 10px; padding: 28px 0; border-bottom: 1px solid var(--ash-15); }
.news-row h2 a { color: var(--mist); text-decoration: none; }
.news-row h2 a:hover { color: var(--lilac); }
.news-pin { color: var(--crystal); font-weight: 600; }
.news-meta a { color: var(--lilac); text-decoration: none; font-weight: 600; }

.post-head { padding: 160px 0 32px; background: radial-gradient(70% 100% at 30% 0%, rgb(183 163 240 / 0.12), transparent 70%); }
.post-head .wrap-narrow { display: grid; gap: 16px; }
.post-foot { padding: 32px 0 96px; }

.prose { font-size: 1.0625rem; line-height: 1.75; color: rgb(238 234 248 / 0.88); }
.prose > * + * { margin-top: 1.1em; }
.prose h1, .prose h2 { font-family: var(--font-inscription); font-size: 1.75rem; line-height: 1.2; color: var(--mist); margin-top: 1.8em; }
.prose h3 { font: 600 1.15rem/1.3 var(--font-ui); color: var(--mist); margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: 0.45em; }
.prose li::marker { color: var(--petal); }
.prose blockquote { margin: 1.4em 0; padding: 14px 20px; border-left: 2px solid var(--lilac); background: rgb(37 29 69 / 0.45); border-radius: 0 12px 12px 0; color: var(--mist); }
.prose code, .prose pre { font-family: var(--font-mono); font-size: 0.9em; }
.prose pre { padding: 16px 18px; border-radius: 12px; background: var(--night-deep); border: 1px solid var(--ash-20); overflow-x: auto; white-space: pre-wrap; }
.prose hr { border: 0; height: 1px; background: linear-gradient(90deg, rgb(243 199 106 / 0), rgb(243 199 106 / 0.45), rgb(243 199 106 / 0)); margin: 2em 0; }
.prose strong { color: var(--mist); }
.prose a { color: var(--lilac); }

/* ---------- Download ---------- */

.download { padding: 24px 0 clamp(80px, 10vw, 120px); }
.download-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
.download-card { padding: clamp(28px, 4vw, 44px); display: grid; gap: 16px; justify-items: start; }
.download-crest { width: 96px; height: 96px; filter: drop-shadow(0 0 30px rgb(183 163 240 / 0.5)); }
.download-facts { display: grid; gap: 20px; }
.facts { margin: 0; display: grid; gap: 0; }
.facts > div { display: grid; grid-template-columns: 120px 1fr; gap: 16px; padding: 14px 0; border-top: 1px solid var(--ash-15); }
.facts dt { font-weight: 600; color: var(--mist); }
.facts dd { margin: 0; color: var(--mist-80); font-size: 0.9375rem; }
@media (max-width: 860px) { .download-grid { grid-template-columns: 1fr; } }
@media (max-width: 480px) { .facts > div { grid-template-columns: 1fr; gap: 4px; } }

/* ---------- Guide ---------- */

.guide { padding: 24px 0 clamp(80px, 10vw, 120px); }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: step; display: grid; gap: 0; }
.step { counter-increment: step; position: relative; padding: 0 0 40px 76px; display: grid; gap: 10px; }
.step::before {
  content: counter(step); position: absolute; left: 0; top: -4px; width: 48px; height: 48px; border-radius: 999px;
  display: grid; place-items: center; font-family: var(--font-inscription); font-size: 1.4rem; color: var(--night);
  background: linear-gradient(135deg, var(--crystal-light), var(--crystal)); box-shadow: 0 0 24px rgb(243 199 106 / 0.45);
}
.step::after { content: ""; position: absolute; left: 23.5px; top: 52px; bottom: 6px; width: 1px; background: linear-gradient(rgb(243 199 106 / 0.5), rgb(243 199 106 / 0)); }
.step:last-child::after { display: none; }
.step p { color: var(--mist-80); }
.guide-tips { margin-top: 32px; padding: 28px; border-radius: 18px; border: 1px solid var(--ash-20); background: rgb(27 21 51 / 0.55); display: grid; gap: 16px; }
.tips { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.tips li { color: var(--mist-80); }
.tips strong { color: var(--mist); margin-right: 6px; }

/* ---------- Status ---------- */

.status-page { padding: 160px 0 clamp(80px, 10vw, 120px); }
.status-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.status-card { padding: 26px; display: grid; gap: 10px; align-content: start; }
.status-big { display: flex; align-items: center; gap: 14px; font-size: clamp(2rem, 4vw, 3rem); line-height: 1.1; font-weight: 600; }
.status-big .dot { width: 14px; height: 14px; }
@media (max-width: 760px) { .status-grid { grid-template-columns: 1fr; } }

/* ---------- Policies ---------- */

.legal { padding: 160px 0 clamp(80px, 10vw, 120px); }
.legal-head { display: grid; gap: 16px; margin-bottom: 40px; }

.empty { padding: 28px; display: grid; gap: 8px; text-align: center; justify-items: center; color: var(--mist-80); }

/* =========================================================================================
   Account screens (markup contract in docs/spec.md and the accounts pages)
   ========================================================================================= */

.auth { position: relative; isolation: isolate; min-height: 100svh; display: grid; place-items: center; padding: 112px var(--gutter) 64px; overflow: hidden; }
.auth-art { position: absolute; inset: 0; z-index: -2; }
.auth-art img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; filter: blur(10px) saturate(1.25); scale: 1.08; }
.auth::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(70% 80% at 50% 45%, rgb(15 11 30 / 0.35), rgb(15 11 30 / 0.88) 85%); }
.auth-panel { width: min(100%, 480px); padding: clamp(26px, 4vw, 40px); display: grid; gap: 14px; }
.auth-panel > .lead { font-size: 1rem; }
.auth-panel .title-2 { margin-top: 2px; }
.form { display: grid; gap: 0; margin-top: 8px; }
.form > .btn { margin-top: 24px; width: 100%; }
.form > .check { margin-top: 18px; }
.form > .notice { margin-bottom: 14px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-row .field + .field { margin-top: 0; }
.auth-alt { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 18px; padding-top: 14px; margin-top: 4px; border-top: 1px solid var(--ash-15); color: var(--ash); }
.auth-alt a { font-weight: 600; text-decoration: none; }
.auth-alt a:hover { text-decoration: underline; }
@media (max-width: 480px) { .form-row { grid-template-columns: 1fr; } .form-row .field + .field { margin-top: 18px; } }

.dash { padding: 136px 0 clamp(80px, 10vw, 120px); background: radial-gradient(70% 50% at 20% 0%, rgb(183 163 240 / 0.12), transparent 70%); min-height: 80svh; }
.dash-head { display: grid; gap: 12px; margin-bottom: 36px; max-width: 760px; }
.dash-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; align-items: start; }
.card { padding: 24px; display: grid; gap: 14px; align-content: start; }
.card h2 { font-family: var(--font-inscription); font-size: 1.45rem; line-height: 1.2; }
.card .form > .btn { width: auto; justify-self: start; }
.card-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 0; border-top: 1px solid var(--ash-15); }
.card-list { list-style: none; margin: 0; padding: 0; display: grid; }
.card-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--ash-15); font-size: 0.9375rem; }

.char-card { position: relative; overflow: hidden; padding: 22px 22px 20px; display: grid; gap: 6px; }
.char-card::before { content: ""; position: absolute; inset: 0 0 auto; height: 3px; background: linear-gradient(90deg, var(--lilac), var(--petal)); opacity: 0.8; }
.char-card[data-nation="sandoria"]::before { background: linear-gradient(90deg, #b8324b, #e39ac4); }
.char-card[data-nation="bastok"]::before { background: linear-gradient(90deg, #3d6fb6, #b7a3f0); }
.char-card[data-nation="windurst"]::before { background: linear-gradient(90deg, #2f8a5b, #f3c76a); }
.char-name { font-size: 1.6rem; line-height: 1.15; color: var(--mist); }
.char-job { font-family: var(--font-mono); color: var(--crystal); font-size: 0.9375rem; }
.char-facts { margin: 10px 0 0; display: grid; gap: 0; }
.char-facts > div { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid var(--ash-15); font-size: 0.875rem; }
.char-facts dt { color: var(--ash); }
.char-facts dd { margin: 0; color: var(--mist); text-align: right; }
