/* ReFrozen V8 — gallery modal, reading hierarchy and genuine asset clearance.
   Architecture: the illustrated assets remain the visual material; this sheet
   sets legibility and interaction only. No tracking, JavaScript or network fonts. */
:root {
  --reading-face: "Optima", "Trebuchet MS", "Segoe UI", system-ui, sans-serif;
  --chapter-face: "Palatino Linotype", "Book Antiqua", "Iowan Old Style", Palatino, Georgia, serif;
}
body { font-family:var(--reading-face)!important; font-size:16px; line-height:1.6; font-weight:400; }
/* One consistent typographic scale: historical chapter titles, clear modern prose. */
.hero-eyebrow,.frost-kicker,.fine-gold,.context-title,.scope-label,
.gallery-label,.release-state,.footer-signature span {letter-spacing:.08em;}
.stone-card h2,.action-card h2,.below-section h2,.frozen h2,.rail-card h2,
.gallery-visual h2,.navigation nav a,.hero-line,.faq summary {
  font-family:var(--chapter-face)!important;
}
.stone-card h2 { line-height:1.24!important; text-wrap:balance; }
.stone-card p,.stone-card .feature-list small,.action-card p,
.media-context p,.rail-card dd,.rail-card dt,.faq details p,
.below-section>p,.below-section ol li,footer .legal {
  font-family:var(--reading-face)!important;
  font-size:clamp(.875rem,.20vw + .85rem,1rem)!important;
  line-height:1.58!important;
}
.stone-card p {color:#dce0df!important}
.feature-list strong{font-family:var(--chapter-face)!important;font-size:1.075rem!important;letter-spacing:.005em}
.feature-list small{font-size:.89rem!important;color:#cbd7dc!important;line-height:1.49!important}
.intro h2{font-size:clamp(1.55rem,2.15vw,1.98rem)!important;line-height:1.2!important}
.feature-list li{padding-block:10px!important}
.faction-section figcaption{font-family:var(--chapter-face)!important;font-size:.84rem!important;line-height:1.35!important}
.rail-card dt,.rail-card dd{font-size:.76rem!important;line-height:1.45!important}
.rail-card .scope-chips span{font-size:.71rem!important}
.gallery-label{font-family:var(--reading-face);font-size:.70rem!important}
.media-context p{font-size:.79rem!important}
/* Visual breathing room; preserve the user-approved two-column hierarchy. */
.left-content{gap:15px!important}
.two-column{gap:14px!important;padding-top:18px!important}
.intro{padding:10px 16px 15px!important}
.features{padding:8px 16px 12px!important}
.faction-section{padding:7px 12px 12px!important}
.action-grid{gap:14px!important}
.action-card{align-items:center!important;min-width:0}
.action-card h2{font-size:1.48rem!important}
.action-card p{font-size:.85rem!important;line-height:1.48!important}
.action-card>div{min-width:0}
/* The graphic itself has transparent padding: do not constrain/crop its pixel box. */
.action-card#downloads{display:grid!important;grid-template-columns:86px minmax(0,1fr);gap:12px!important;padding:12px 14px!important;min-height:172px!important;overflow:visible!important}
.download-art{width:86px;min-width:0;display:flex;justify-content:center;align-items:center;align-self:center;overflow:visible;padding:5px 0}
.download-art img{display:block!important;width:80px!important;max-width:100%!important;height:auto!important;max-height:none!important;object-fit:contain!important;object-position:center!important;transform:none!important;margin:0!important;clip-path:none!important;filter:drop-shadow(0 2px 7px #0008)!important}
.action-card#downloads>div{min-width:0}
.action-card#downloads .release-state{font-size:.66rem!important;line-height:1.4}
/* Painted button backgrounds have decorative top/bottom; center the actual glyphs. */
.graphic-button,.graphic-button.small,.graphic-button.blue{
 display:inline-flex!important;align-items:center!important;justify-content:center!important;
 vertical-align:middle!important;text-align:center!important;
 font-family:var(--chapter-face)!important;font-weight:700!important;
 min-height:48px!important;padding:10px 24px!important;line-height:1!important;
}
.graphic-button>.button-label{display:flex!important;justify-content:center!important;align-items:center!important;
 line-height:1.12!important;min-height:1.12em;transform:translateY(-2px)!important;
 text-align:center!important;padding:0!important;margin:0!important}
.graphic-button.small>.button-label,.graphic-button.blue>.button-label{transform:translateY(-2px)!important}
/* Interactive cut-outs should be operable and visible above the non-clickable frame. */
.gallery-visual{isolation:isolate}
.gallery-frame,.gallery-visual h2,.gallery-label{pointer-events:none!important}
.gallery-open{appearance:none;-webkit-appearance:none;border:0;padding:0;border-radius:0;
 font:inherit;cursor:zoom-in;z-index:1!important;line-height:0;background:#07121a}
.gallery-open:hover,.gallery-open:focus-visible{z-index:1!important}
.gallery-open:focus-visible{outline:2px solid #d1edf5!important;outline-offset:1px!important}
.gallery-open img{max-width:none;width:100%;height:100%;object-fit:cover}
/* Native Popover API: top-layer browser dialog, Escape and outside click to close. */
.art-lightbox[popover]{position:fixed;inset:0;margin:auto;
 width:min(1100px,calc(100vw - 36px));max-width:none;
 max-height:min(92dvh,850px);overflow:auto;
 padding:clamp(14px,2.6vw,25px);box-sizing:border-box;
 color:#e6e6e0;background:linear-gradient(150deg,#192a33,#08141e 66%);
 border:2px solid #5a7482;border-radius:8px;
 box-shadow:inset 0 0 0 1px #9dc6d02b,0 20px 80px #000b;
}
.art-lightbox::backdrop{background:rgba(3,8,14,.88);backdrop-filter:blur(6px)}
.art-lightbox .lightbox-top{display:flex;align-items:center;justify-content:space-between;gap:15px;padding:0 0 12px;border-bottom:1px solid #4e6871;margin-bottom:14px}
.art-lightbox h2{font:600 clamp(1.16rem,2.8vw,1.75rem)/1.25 var(--chapter-face);color:#f0d69f;margin:0}
.art-lightbox .lightbox-close,.art-lightbox .lightbox-arrow{
 display:inline-flex;align-items:center;justify-content:center;
 color:#e3edf0;background:#19323e;border:1px solid #57717e;
 min-width:44px;min-height:44px;padding:7px 11px;
 font:600 1.15rem/1 var(--reading-face);cursor:pointer;border-radius:3px;
}
.art-lightbox .lightbox-close:hover,.art-lightbox .lightbox-arrow:hover,
.art-lightbox .lightbox-close:focus-visible,.art-lightbox .lightbox-arrow:focus-visible{background:#305463;border-color:#bddde8}
.art-lightbox figure{margin:0}
.art-lightbox figure img{display:block;width:100%;max-height:66dvh;object-fit:contain;background:#060e14;border:1px solid #506873}
.art-lightbox figcaption{color:#ced7d9;margin-top:10px;font:400 .89rem/1.5 var(--reading-face)}
.art-lightbox .lightbox-controls{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:14px}
.art-lightbox .lightbox-controls span{font:600 .8rem/1.3 var(--reading-face);color:#a5b9c3;text-transform:uppercase;letter-spacing:.08em}
/* Responsive reading sizes stay usable instead of shrinking below 12px. */
@media(max-width:900px){
 .action-card#downloads{grid-template-columns:74px minmax(0,1fr);gap:8px!important;padding:10px!important}
 .download-art{width:74px}.download-art img{width:72px!important}
 .intro{padding:7px 11px 10px!important}
 .features{padding:5px 11px 10px!important}
}
@media(max-width:520px){
 body{font-size:15.5px!important}
 .stone-card p,.stone-card .feature-list small,.action-card p{font-size:.94rem!important;line-height:1.55!important}
 .media-context p{font-size:.86rem!important}
 .rail-card dt,.rail-card dd{font-size:.82rem!important}
 .rail-card .scope-chips span{font-size:.75rem!important}
 .action-card#downloads .release-state{font-size:.72rem!important}
 .feature-list li{padding-block:8px!important}
 .intro h2{font-size:1.4rem!important}
 .action-card#downloads{grid-template-columns:68px minmax(0,1fr);gap:9px!important}
 .download-art{width:68px}.download-art img{width:64px!important}
 .action-card .graphic-button.small{min-width:min(180px,100%)!important}
 .art-lightbox[popover]{width:calc(100vw - 16px);max-height:94dvh;padding:12px}
 .art-lightbox figure img{max-height:57dvh}
 .art-lightbox .lightbox-controls span{font-size:.70rem}
}
@media(prefers-reduced-motion:reduce){
 .gallery-open img{transition:none!important}
 .art-lightbox::backdrop{backdrop-filter:none}
}
/* The artist-painted hanging frame always overlays the thumbnail windows;
   its transparent hit area still lets buttons receive clicks. */
.gallery-visual .gallery-frame{z-index:4!important;pointer-events:none!important}
.gallery-visual .gallery-open{z-index:1!important}

/* V8.3 screenshot audit: a flex-stretched status plaque creates a large
   empty slab beneath its real content. Let the artwork frame fit the ledger. */
.media{align-self:start!important;min-height:0!important}
.rail-card{flex:0 0 auto!important;min-height:0!important}
.rail-card dt,.rail-card dd{font-size:.84rem!important;line-height:1.5!important}
.rail-card .scope-chips span{font-size:.76rem!important}
.rail-card .rail-link{font-size:.88rem;line-height:1.5}
@media(max-width:520px){
 .rail-card dt,.rail-card dd{font-size:.86rem!important}
}
