/*
Theme Name: World of Lumoria
Description: An author website for M. Newman and The Shards of Lumoria.
Author: M. Newman
Version: 1.0.8
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: world-of-lumoria
*/

:root {
    --night: #101a24;
    --deep: #142432;
    --gold: #e8bc75;
    --paper: #f6efe2;
    --ink: #172735;
    --soft: #c6d0d4;
    --serif: Georgia, 'Times New Roman', serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--night); color: var(--paper); font: 1rem/1.65 system-ui, sans-serif; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
a:focus-visible { outline: 3px solid #4abed5; outline-offset: 5px; }
h1, h2, h3 { margin: 0; font: 400 1em/1.04 var(--serif); }
h2 { font-size: clamp(2.45rem, 5vw, 4.1rem); }
h3 { font-size: clamp(1.8rem, 2.65vw, 2.65rem); }
p { margin: 0 0 1.1rem; }
figure { margin: 0; }
.shell { width: min(1160px, calc(100% - 3rem)); margin-inline: auto; }
.skip-link { position: absolute; z-index: 10; left: 1rem; top: 1rem; padding: .5rem 1rem; background: var(--paper); color: var(--ink); transform: translateY(-200%); }
.skip-link:focus { transform: none; }
.masthead { border-bottom: 1px solid #e8bc753d; }
.masthead-inner, .footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 1rem 2rem; min-height: 76px; }
.brand { font: 1.35rem var(--serif); text-decoration: none; }
.brand-mark { color: var(--gold); margin-right: .4rem; }
nav { display: flex; flex-wrap: wrap; gap: .55rem 1.5rem; }
nav a { color: var(--soft); font-size: .9rem; text-decoration: none; }
nav a:hover { color: var(--gold); text-decoration: underline; }
.hero { padding: clamp(2.75rem, 7vw, 6rem) 0; background: radial-gradient(ellipse at 78% 45%, #294252, var(--night) 70%); }
.hero-grid, .world-grid { display: grid; grid-template-columns: .85fr 1.15fr; align-items: center; gap: clamp(1.75rem, 5vw, 5.5rem); }
.eyebrow { font-size: .72rem; font-weight: 750; letter-spacing: .19em; text-transform: uppercase; color: var(--gold); margin-bottom: .8rem; }
.hero h1 { font-size: clamp(3.65rem, 8vw, 7.25rem); letter-spacing: -.055em; }
.hero h1 em { font-weight: 400; color: var(--gold); }
.hero-copy > p:not(.eyebrow), .world-section p:not(.eyebrow) { max-width: 38ch; color: var(--soft); margin-top: 1.35rem; }
.hero-art { padding: .55rem; border: 1px solid #e8bc7569; }
.hero-art img { width: 100%; aspect-ratio: 1.15; object-fit: cover; object-position: center 47%; }
.hero-art figcaption { padding: .55rem .35rem 0; color: var(--soft); font-size: .75rem; }
.button { display: inline-flex; align-items: center; gap: .6em; padding: .65rem .9rem; text-decoration: none; font-weight: 700; font-size: .85rem; }
.button:hover { text-decoration: underline; text-underline-offset: .22em; }
.button-gold { background: var(--gold); color: var(--night); }
.button-ink { background: var(--ink); color: var(--paper); }
.books-section, .world-section, .author-section { padding: clamp(3.4rem, 7vw, 6rem) 0; }
.books-section, .author-section { background: var(--paper); color: var(--ink); }
.books-section .eyebrow, .author-section .eyebrow { color: #775019; }
.book-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem; margin-top: 2rem; }
.book-card { display: grid; grid-template-columns: minmax(115px, .9fr) minmax(0, 1fr); align-items: start; gap: clamp(1rem, 2.2vw, 1.65rem); border: 1px solid #d4c6af; background: #fff9ef; padding: clamp(.9rem, 2.25vw, 1.5rem); }
.cover { width: 100%; box-shadow: 0 .45rem .9rem #35281924; }
.book-copy > p:not(.eyebrow) { margin: .8rem 0 1rem; font-size: .9rem; }
.world-section { background: var(--deep); }
.world-grid img { width: 100%; border: 1px solid #e8bc7569; }
.author-section p:not(.eyebrow) { max-width: 58ch; margin: 1rem 0 0; }
.site-footer { color: var(--soft); }
.footer-inner > span { font: 1.15rem var(--serif); }
.reading { padding-block: 3rem; min-height: 50vh; }
.reading article { max-width: 72ch; margin-bottom: 2rem; overflow-wrap: anywhere; }
.reading h1 { font-size: clamp(2.5rem, 7vw, 5rem); margin-bottom: 1rem; }
.reading h2 { font-size: 2.2rem; margin-bottom: 1rem; }
@media (max-width: 900px) {
    .book-grid { grid-template-columns: 1fr; }
    .book-card { grid-template-columns: minmax(95px, 185px) minmax(0, 1fr); }
}
@media (max-width: 640px) {
    .shell { width: calc(100% - 2rem); }
    .masthead-inner { align-items: flex-start; flex-direction: column; justify-content: center; gap: .65rem; padding: .9rem 0; }
    .hero-grid, .world-grid { grid-template-columns: 1fr; }
    .book-card { grid-template-columns: minmax(95px, .65fr) minmax(0, 1fr); }
    .book-copy h3 { font-size: 1.55rem; }
    .book-copy > p:not(.eyebrow) { font-size: .85rem; }
}
@media (max-width: 350px) {
    .book-card { grid-template-columns: 1fr; }
    .cover { max-width: 180px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

.atlas-section { padding: clamp(3rem, 7vw, 6rem) 0; background: #182a33; }
.atlas-section [hidden] { display: none !important; }
.atlas-intro { margin-top: 1rem; color: var(--soft); }
.atlas-controls, .atlas-button-row, .atlas-place-links { display: flex; flex-wrap: wrap; gap: .5rem; }
.atlas-controls { justify-content: space-between; margin: 1.25rem 0 .75rem; }
.atlas-controls button, .atlas-place-links a {
    background: #263d47; color: var(--paper); border: 1px solid #b7a382;
    border-radius: .2rem; padding: .45rem .75rem; cursor: pointer; font: inherit;
    font-size: .84rem; text-decoration: none;
}
.atlas-controls button:focus-visible { outline: 3px solid #4abed5; outline-offset: 3px; }
.atlas-controls button[aria-pressed="true"], .atlas-place-links a[aria-current] { background: var(--gold); color: var(--ink); border-color: var(--gold); }
.atlas-controls button:disabled { opacity: .58; cursor: default; }
.atlas-layer-note { color: var(--gold); font-size: .86rem; }
.atlas-map { display: block; width: 100%; height: auto; max-width: 760px; aspect-ratio: 610 / 660; border: 1px solid #c9b48b; background: #b4c3b4; }
.atlas-pin { cursor: pointer; }
.atlas-pin circle { fill: #183c45; stroke: #f0d18e; stroke-width: 2.5; }
.atlas-pin path, .atlas-pin circle.atlas-wheel { fill: none; stroke: #fff2ce; stroke-width: 2; }
.atlas-pin:hover circle, .atlas-pin:focus-visible circle { fill: #6c421b; stroke: white; }
.atlas-pin:hover circle.atlas-wheel, .atlas-pin:focus-visible circle.atlas-wheel { fill: none; }
.atlas-place-links { margin-top: .9rem; }
.atlas-place-detail { display: grid; grid-template-columns: 1fr; gap: 1.25rem; margin: 1rem 0; padding: 1.25rem; border: 1px solid #ad9771; background: #213742; }
.atlas-place-detail:has(img) { grid-template-columns: 1fr 1fr; align-items: center; }
.atlas-place-detail p:not(.eyebrow) { margin: .8rem 0; color: var(--soft); }
.atlas-place-detail img { border: 1px solid #ad9771; }
.atlas-footnote { margin: 1rem 0 .4rem; font-size: .82rem; color: var(--soft); }
.atlas-static { color: var(--gold); font-size: .9rem; }
@media (max-width: 640px) {
    .atlas-place-detail:has(img) { grid-template-columns: 1fr; }
    .atlas-controls button, .atlas-place-links a { min-height: 42px; }
}

.author-grid { display: grid; grid-template-columns: minmax(120px, 185px) minmax(0, 1fr); align-items: center; gap: clamp(1.5rem, 4vw, 3.5rem); }
.author-photo { width: 100%; border: 1px solid #b6a083; }
@media (max-width: 520px) {
    .author-grid { grid-template-columns: 1fr; }
    .author-photo { width: min(155px, 100%); }
}

.atlas-series { margin: 1rem 0 1.25rem; }
.atlas-series a, .atlas-series button, .atlas-spoiler-confirm button {
    padding: .45rem .75rem; font: inherit; font-size: .84rem; border: 1px solid #b7a382; border-radius: .2rem;
}
.atlas-series a { background: var(--gold); color: var(--ink); text-decoration: none; }
.atlas-series button { background: #263d47; color: var(--soft); }
.atlas-series small { display: block; font-size: .72rem; color: var(--gold); }
.atlas-spoiler-confirm { max-width: 760px; margin: 1rem 0; padding: .9rem; border: 1px solid var(--gold); }
.atlas-spoiler-confirm button { cursor: pointer; background: var(--paper); color: var(--ink); }
