:root {
    color-scheme: dark;
    --bg: #100b08;
    --bg-soft: #19100b;
    --bg-card: rgba(36, 24, 17, 0.82);
    --text: #f5ead8;
    --muted: #bba98f;
    --line: rgba(218, 176, 106, 0.18);
    --gold: #d7a84e;
    --gold-soft: #f0cf87;
    --red: #8b2d20;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.4);
    --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at 20% 5%, rgba(215, 168, 78, 0.17), transparent 30rem),
        radial-gradient(circle at 80% 10%, rgba(139, 45, 32, 0.22), transparent 34rem),
        linear-gradient(180deg, #130d09 0%, #090706 100%);
    line-height: 1.6;
}

a { color: inherit; }
.skip-link {
    position: absolute;
    top: -4rem;
    left: 1rem;
    z-index: 10;
    background: var(--gold);
    color: #130d09;
    padding: .65rem 1rem;
    border-radius: 999px;
}
.skip-link:focus { top: 1rem; }

.site-header,
.site-footer,
.site-main > section {
    width: min(var(--max), calc(100% - 2rem));
    margin-inline: auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 1rem 0;
    backdrop-filter: blur(18px);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: .8rem;
    text-decoration: none;
}
.brand__mark {
    display: grid;
    place-items: center;
    width: 2.7rem;
    height: 2.7rem;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gold), #674018);
    color: #130d09;
    font-family: Georgia, serif;
    font-size: 1.45rem;
    font-weight: 800;
    box-shadow: 0 0 32px rgba(215, 168, 78, .28);
}
.brand strong,
.brand small { display: block; }
.brand small { color: var(--muted); font-size: .78rem; }

.site-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: .28rem;
    max-width: 52rem;
}
.site-nav a {
    color: var(--muted);
    text-decoration: none;
    padding: .48rem .66rem;
    border-radius: 999px;
    font-size: .95rem;
    transition: color .2s ease, background .2s ease;
}
.site-nav a:hover,
.site-nav a.is-active {
    color: var(--text);
    background: rgba(255, 255, 255, .075);
}
.language-switch {
    display: inline-flex;
    align-items: center;
    gap: .15rem;
    margin-left: .25rem;
    padding: .16rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, .035);
}
.language-switch__item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.15rem;
    min-height: 2rem;
    padding: .35rem .55rem !important;
    border-radius: 999px;
    color: var(--muted) !important;
    font-size: .82rem !important;
    font-weight: 900;
    line-height: 1;
    text-decoration: none;
}
.language-switch__item.is-active {
    background: var(--gold);
    color: #130d09 !important;
}
.language-switch__item:not(.is-active):hover {
    background: rgba(255, 255, 255, .075);
    color: var(--text) !important;
}

.site-main { padding: 3rem 0 0; }
.hero {
    min-height: 74vh;
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(18rem, .65fr);
    align-items: center;
    gap: 2rem;
    padding: 5rem 0;
}
.hero-home::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image: linear-gradient(rgba(255,255,255,.018) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.018) 1px, transparent 1px);
    background-size: 72px 72px;
    mask-image: linear-gradient(to bottom, black, transparent 80%);
}
.eyebrow {
    margin: 0 0 .8rem;
    color: var(--gold-soft);
    text-transform: uppercase;
    letter-spacing: .16em;
    font-size: .78rem;
    font-weight: 800;
}
h1, h2, h3, p { margin-top: 0; }
h1 {
    max-width: 12ch;
    margin-bottom: 1rem;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(4rem, 11vw, 9.5rem);
    line-height: .86;
    letter-spacing: -.07em;
}
h2 {
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2rem, 4vw, 4rem);
    line-height: 1;
    letter-spacing: -.045em;
}
h3 { font-size: 1.25rem; }
.hero__lead {
    max-width: 46rem;
    color: #dfd1ba;
    font-size: clamp(1.15rem, 2vw, 1.5rem);
}
.hero__actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 3rem;
    padding: .8rem 1.15rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    text-decoration: none;
    font-weight: 800;
    transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.button:hover { transform: translateY(-2px); }
.button--primary { background: var(--gold); color: #170f08; border-color: var(--gold); }
.button--ghost { background: rgba(255,255,255,.05); color: var(--text); }
.hero__panel,
.card,
.news-placeholder {
    border: 1px solid var(--line);
    border-radius: 1.5rem;
    background: var(--bg-card);
    box-shadow: var(--shadow);
}
.hero__panel { padding: 1.5rem; }
.panel-tag {
    display: inline-flex;
    margin-bottom: 1rem;
    padding: .28rem .6rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--gold-soft);
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .1em;
}
.hero__panel h2 { font-size: 1.7rem; letter-spacing: -.03em; }
.hero__panel ul { padding-left: 1.1rem; color: var(--muted); }

.section { padding: 5rem 0; }
.section--dark {
    width: 100%;
    max-width: none;
    padding-inline: max(1rem, calc((100% - var(--max)) / 2));
    background: rgba(0, 0, 0, .22);
    border-block: 1px solid var(--line);
}
.section__header { max-width: 52rem; margin-bottom: 2rem; }
.section__header p,
.prose,
.page-hero p,
.cta p { color: var(--muted); }
.cards { display: grid; gap: 1rem; }
.cards--three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card { padding: 1.35rem; }
.section--dark .cards--three {
    grid-template-columns: repeat(3, minmax(14rem, 1fr));
    align-items: stretch;
}
.section--dark .card {
    min-height: 100%;
    padding: 1.55rem;
}
.section--dark .card h3 {
    max-width: 12rem;
    margin: .55rem 0 .85rem;
    line-height: 1.25;
}
.section--dark .card p {
    color: #eadcc7;
    line-height: 1.72;
}
.card__number { color: var(--gold); font-weight: 900; }
.split {
    display: grid;
    grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
    gap: 2rem;
    align-items: start;
}
.cta {
    margin-bottom: 4rem;
    padding: 3rem;
    border: 1px solid var(--line);
    border-radius: 2rem;
    background: linear-gradient(135deg, rgba(215,168,78,.16), rgba(139,45,32,.12));
}
.page-hero { padding: 6rem 0 3rem; }
.page-hero h1 { max-width: 14ch; font-size: clamp(3.5rem, 8vw, 7rem); }
.page-hero p { max-width: 46rem; font-size: 1.2rem; }
.media-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.media-card {
    min-height: 16rem;
    display: grid;
    place-items: center;
    border: 1px dashed rgba(215,168,78,.35);
    border-radius: 1.4rem;
    background: rgba(255,255,255,.035);
    color: var(--muted);
    font-weight: 800;
}
.news-placeholder { padding: 2rem; max-width: 48rem; }
.news-list { display: grid; gap: 1rem; }
.news-card,
.article-detail {
    border: 1px solid var(--line);
    border-radius: 1.4rem;
    background: rgba(255,255,255,.035);
    padding: 1.4rem;
}
.news-card time,
.article-detail time { color: var(--gold-soft); font-weight: 800; }
.news-card h2 { margin: .5rem 0; font-size: clamp(1.5rem, 3vw, 2.5rem); }
.news-card h2 a { text-decoration: none; }
.article-detail { max-width: 840px; }
.article-detail h1 { max-width: 14ch; font-size: clamp(3rem, 8vw, 6rem); }
.article-lead { color: #dfd1ba; font-size: 1.25rem; }
.article-content { color: var(--muted); font-size: 1.08rem; white-space: normal; }
.site-footer {
    display: flex;
    justify-content: space-between;
    gap: 2rem;
    padding: 2rem 0 3rem;
    border-top: 1px solid var(--line);
    color: var(--muted);
}
.footer-columns { display: grid; gap: .65rem; justify-items: end; }
.footer-links { display: flex; justify-content: flex-end; gap: 1rem; flex-wrap: wrap; }
.footer-links a { color: var(--gold-soft); text-decoration: none; }
.footer-links--muted a { color: var(--muted); }
.timeline { display: grid; gap: 1rem; }
.timeline-item {
    position: relative;
    padding: 1.4rem 1.4rem 1.4rem 2rem;
    border: 1px solid var(--line);
    border-radius: 1.3rem;
    background: rgba(255,255,255,.035);
}
.timeline-item::before {
    content: "";
    position: absolute;
    left: .8rem;
    top: 1.4rem;
    bottom: 1.4rem;
    width: 3px;
    border-radius: 999px;
    background: linear-gradient(var(--gold), transparent);
}
.timeline-item span {
    display: inline-flex;
    margin-bottom: .5rem;
    color: var(--gold-soft);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .13em;
    text-transform: uppercase;
}
.checklist ul,
.legal-page ul { padding-left: 1.1rem; }
.legal-page {
    max-width: 58rem;
    color: var(--muted);
}
.legal-page h2 {
    margin-top: 2rem;
    color: var(--text);
    font-size: clamp(1.45rem, 3vw, 2.2rem);
}
.page-hero--compact { padding-bottom: 1rem; }
.reveal { animation: rise .7s ease both; }
.reveal--delay { animation-delay: .12s; }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }

@media (max-width: 860px) {
    .site-header { align-items: flex-start; flex-direction: column; }
    .site-nav { justify-content: flex-start; }
    .hero, .split, .cards--three, .media-grid { grid-template-columns: 1fr; }
    .hero { min-height: auto; padding-top: 3rem; }
    .site-footer { flex-direction: column; }
    .footer-columns { justify-items: start; }
    .footer-links { justify-content: flex-start; }
}

@media (max-width: 520px) {
    .site-main { padding-top: 1rem; }
    h1 { font-size: 3.6rem; }
    .cta { padding: 1.5rem; }
    .site-nav a { padding: .45rem .62rem; }
}

/* Hermes phase 2E: public news/devlog polish */
.news-hero {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 1.6rem;
    padding: clamp(2rem, 5vw, 4rem);
    background:
        linear-gradient(135deg, rgba(215,168,78,.12), transparent 45%),
        radial-gradient(circle at 85% 10%, rgba(139,45,32,.22), transparent 22rem),
        rgba(255,255,255,.028);
}
.news-hero h1 { max-width: 13ch; }
.news-hero__meta {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
    margin-top: 1.4rem;
}
.news-hero__meta span,
.news-card__topline span,
.article-meta span {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: .35rem .65rem;
    color: var(--gold-soft);
    background: rgba(255,255,255,.045);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}
.news-list--public { margin-top: 2rem; }
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr));
    gap: 1rem;
}
.news-card--public {
    position: relative;
    display: grid;
    gap: .85rem;
    min-height: 18rem;
    padding: clamp(1.2rem, 3vw, 1.8rem);
    background:
        linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.025)),
        rgba(20, 13, 8, .86);
    box-shadow: 0 20px 70px rgba(0,0,0,.22);
    transition: transform .22s ease, border-color .22s ease, background .22s ease;
}
.news-card--public:hover {
    transform: translateY(-3px);
    border-color: rgba(240,207,135,.42);
    background: rgba(255,255,255,.06);
}
.news-card__topline,
.article-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: .65rem;
    color: var(--muted);
}
.news-card__topline time,
.article-meta time { color: var(--gold-soft); font-weight: 900; }
.news-card--public h2 { margin: 0; max-width: 12ch; }
.news-card--public h2 a { text-decoration: none; }
.news-card--public p { color: #dfd1ba; margin-bottom: 0; }
.news-card__read {
    align-self: end;
    color: var(--gold-soft);
    font-weight: 900;
    text-decoration: none;
}
.news-card__read::after { content: " →"; }
.news-placeholder--polished {
    border: 1px solid var(--line);
    border-radius: 1.4rem;
    background: rgba(255,255,255,.035);
}
.article-detail--public {
    max-width: 920px;
    padding: clamp(1.5rem, 5vw, 4rem);
    background:
        linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.025)),
        rgba(20, 13, 8, .86);
}
.article-header {
    padding-bottom: 1.5rem;
    margin-bottom: 1.6rem;
    border-bottom: 1px solid var(--line);
}
.article-detail--public h1 {
    max-width: 16ch;
    margin-bottom: 1rem;
}
.article-detail--public .article-lead {
    max-width: 46rem;
    margin: 1.25rem 0 0;
}
.article-detail--public .article-content {
    max-width: 72ch;
    color: #dfd1ba;
    font-size: clamp(1.05rem, 2vw, 1.16rem);
    line-height: 1.85;
    overflow-wrap: anywhere;
}
.article-footer {
    margin-top: 2rem;
    padding-top: 1.2rem;
    border-top: 1px solid var(--line);
}
:where(a, button, input, textarea, select):focus-visible {
    outline: 3px solid rgba(240,207,135,.75);
    outline-offset: 3px;
}
@media (max-width: 620px) {
    .news-hero { padding: 1.4rem; }
    .news-card--public { min-height: auto; }
    .article-detail--public { padding: 1.25rem; }
    .article-detail--public h1 { font-size: 3rem; }
}

/* Hermes phase 2F: public news cover images */
.news-card--public.has-cover { padding: 0; overflow: hidden; }
.news-card__media {
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-bottom: 1px solid var(--line);
    background: rgba(255,255,255,.035);
}
.news-card__media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .28s ease;
}
.news-card--public:hover .news-card__media img { transform: scale(1.035); }
.news-card__body { display: grid; gap: .85rem; padding: clamp(1.2rem, 3vw, 1.8rem); height: 100%; }
.article-cover {
    margin: 0 0 2rem;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 1.2rem;
    background: rgba(255,255,255,.035);
}
.article-cover img {
    display: block;
    width: 100%;
    max-height: 32rem;
    object-fit: cover;
}

