/* ==========================================================================
   Isle Madame Historical Society - imhs.ca
   Maritime palette: navy and blue-grey chrome on a light grey page, with the
   rust accent kept. Per Raylene on the 2026-10-01 call (navy blue / blue grey,
   rust stays as is), replacing the forge-and-parchment look. The token names
   kept their forge-era names (iron, ember, brass) so every rule that uses
   them carries on unchanged; only the values moved.
   Typography: Fraunces for the wordmark and headings, Source Sans 3 for the
   menu and labels, Arial for body copy. Raylene approved these fonts on the
   2026-10-01 call.
   ========================================================================== */

:root {
    --iron: #2f5075;           /* navy, headings, dark surfaces               */
    --iron-deep: #1e3450;      /* deep navy, footer, topbar                   */
    --ember: #5f7856;          /* green accent, board's colour via Raylene 2026-11-09 (was wine #623f4c) */
    --ember-bright: #4d6444;   /* hover state: darker, not lighter; a lighter green fails contrast on the butter background */
    --ember-deep: #3c5035;
    --ember-soft: #e8efe2;     /* pale tint of the accent green, icon tiles   */
    --brass: #64788c;          /* blue-grey, small details, kickers           */
    --brass-soft: #e2e8ee;     /* pale blue-grey, tints and strips            */
    --brass-text: #4d6274;     /* blue-grey dark enough for small text        */
    --parchment: #faf5e4;      /* soft butter page background, dialled back 2026-10-02 (was #f8f1d9, too strong) */
    --paper: #fefdf8;          /* card and raised surfaces, warm white        */
    --ink: #2e3338;
    --muted: #636d77;
    --line: #e6dfcc;           /* warm rule lines to sit on the butter        */
    --serif: "Fraunces", Georgia, "Times New Roman", serif;
    --ui: "Source Sans 3", "Segoe UI", Arial, sans-serif;
    --sans: Arial, Helvetica, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--sans);
    font-size: 17px;
    line-height: 1.7;
    color: var(--ink);
    background: var(--parchment);
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--ember); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--ember-bright); }

h1, h2, h3, h4 {
    font-family: var(--serif);
    font-weight: 700;
    color: var(--iron);
    line-height: 1.25;
    margin: 1.6em 0 .5em;
}
h1 { font-size: 2.4rem; margin-top: 0; }
h2 { font-size: 1.7rem; }
h3 { font-size: 1.25rem; }

/* Short ember rule instead of a full-width grey line, a heritage detail */
hr {
    border: 0;
    width: 64px;
    border-top: 3px solid var(--ember);
    margin: 2.4em 0;
}

.container { max-width: 1100px; margin: 0 auto; padding: 0 22px; }

/* --- Top bar ------------------------------------------------------------- */

.topbar {
    background: var(--iron-deep);
    color: #9fadbb;
    font-size: .9rem;
    letter-spacing: .02em;
    border-bottom: 1px solid rgba(125, 83, 99, .4);
}
.topbar .container {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding-top: 6px;
    padding-bottom: 6px;
    flex-wrap: wrap;
}
.topbar a { color: #dde5ec; text-decoration: none; }
.topbar a:hover { color: #fff; text-decoration: underline; }

/* --- Header / nav -------------------------------------------------------- */

/* The header is sticky, so a jumped-to anchor must land below it, not under
   it (Raylene's review, 2026-11-05: tile links "landed slightly lower" than
   their sections). Applied to every id so in-page links behave everywhere.
   The margins track the header's measured heights: ~225px where the full
   nav wraps to two rows (901 to 1199px), ~165px on wide screens, ~150px
   with the collapsed mobile menu. */
section[id], div[id], article[id], aside[id], h2[id], h3[id] {
    scroll-margin-top: 240px;
}
@media (min-width: 1200px) {
    section[id], div[id], article[id], aside[id], h2[id], h3[id] {
        scroll-margin-top: 185px;
    }
}
@media (max-width: 900px) {
    section[id], div[id], article[id], aside[id], h2[id], h3[id] {
        scroll-margin-top: 165px;
    }
}

#header {
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 50;
    box-shadow: 0 1px 12px rgba(26, 35, 46, .10);
}

/* Two-row header: centered brand above, nav on its own full-width row */
#header .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 16px;
}

.brand { text-decoration: none; line-height: 1.2; text-align: center; display: block; }
.brand .brand-name {
    display: block;
    font-family: var(--serif);
    font-weight: 700;
    font-size: 1.85rem;
    color: var(--iron);
    letter-spacing: .01em;
}
.brand .brand-at {
    display: block;
    font-family: var(--serif);
    font-weight: 600;
    font-size: .95rem;
    color: var(--ember);
    margin-top: 2px;
}
.brand .brand-sub {
    display: block;
    font-family: var(--ui);
    font-size: .72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .22em;
    color: var(--brass-text);
    margin-top: 4px;
}

#access {
    width: 100%;
    border-top: 1px solid var(--line);
    margin-top: 14px;
}

/* Nine tabs on ONE row: larger type, and a long label wraps to two lines
   inside its own tab (max-width forces the wrap) so the row stays compact. */
#access ul {
    list-style: none;
    margin: 0;
    padding: 2px 0 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
}

#access li { display: flex; }
#access li + li { border-left: 1px solid var(--line); }

#access a {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    text-align: center;
    max-width: 9em;
    padding: 8px 14px 9px;
    font-family: var(--ui);
    font-size: .95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    line-height: 1.25;
    color: var(--iron);
    text-decoration: none;
    border-bottom: 3px solid transparent;
}

#access a:hover { border-bottom-color: var(--line); }
#access li.current a { border-bottom-color: var(--iron); }

.nav-toggle, .nav-toggle-label { display: none; }

/* --- Hero (homepage) ----------------------------------------------------- */

.hero {
    position: relative;
    min-height: 62vh;
    display: flex;
    align-items: center;
    background: var(--iron-deep);
    background-size: cover;
    background-position: center;
    color: #fff;
}
/* Warm smoke-and-ember overlay */
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to top, rgba(98, 63, 76, .3), transparent 45%),
        linear-gradient(100deg, rgba(20, 33, 50, .92) 12%, rgba(20, 33, 50, .55) 58%, rgba(20, 33, 50, .28));
}
.hero .container { position: relative; padding-top: 70px; padding-bottom: 70px; }
.hero-kicker {
    font-family: var(--ui);
    font-size: .85rem;
    text-transform: uppercase;
    letter-spacing: .28em;
    color: #d9a441;
    font-weight: 700;
    margin: 0 0 14px;
}
.hero h1 {
    color: #f4f7fa;
    font-size: clamp(2.1rem, 5vw, 3.4rem);
    max-width: 15em;
    margin: 0 0 16px;
}
.hero p { max-width: 34em; font-size: 1.1rem; color: #d9e1e9; margin: 0 0 28px; }

.btn {
    display: inline-block;
    padding: 12px 26px;
    border-radius: 3px;
    font-family: var(--ui);
    font-weight: 700;
    font-size: .95rem;
    letter-spacing: .05em;
    text-transform: uppercase;
    text-decoration: none;
    transition: background .15s ease, color .15s ease;
}
.btn-primary { background: var(--ember); color: #fff; }
.btn-primary:hover { background: var(--ember-bright); color: #fff; }
.btn-ghost { border: 2px solid rgba(244, 247, 250, .65); color: #f4f7fa; margin-left: 10px; }
.btn-ghost:hover { background: rgba(244, 247, 250, .14); color: #fff; }
.btn-navy { background: var(--iron); color: #fff; }
.btn-navy:hover { background: var(--iron-deep); color: #fff; }

/* --- Page title band (interior pages) ------------------------------------ */

.page-band {
    background: var(--iron) linear-gradient(100deg, var(--iron-deep), var(--iron) 65%);
    color: #fff;
    padding: 42px 0 38px;
    border-bottom: 3px solid var(--ember);
}
.page-band h1 { color: #f4f7fa; margin: 0; font-size: clamp(1.8rem, 4vw, 2.6rem); }
.page-band .band-sub { color: #b7c3cf; margin: 8px 0 0; max-width: 46em; font-style: italic; }

/* --- Main content -------------------------------------------------------- */

#content { padding: 48px 0 60px; }
#content > .container > *:first-child { margin-top: 0; }

.lead { font-size: 1.15rem; }

/* Ember list markers everywhere in content */
#content ul:not(.pill-list):not(.newsletter-list) li::marker { color: var(--ember); }

/* Anchor sections inside a tab page */
.section { padding-top: 12px; margin-top: 34px; border-top: 1px solid var(--line); }
.section:first-of-type { border-top: 0; margin-top: 0; }
.section > h2 { margin-top: .6em; }

/* Two-column layouts */
.split {
    display: grid;
    grid-template-columns: 1.15fr .85fr;
    gap: 44px;
    align-items: center;
}
.split-start { align-items: start; }
.split-narrow { grid-template-columns: 1.4fr 1fr; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; align-items: start; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; align-items: stretch; }

/* Raised paper panel */
.panel {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 22px 26px;
}
.panel > :first-child { margin-top: 0; }
.panel > :last-child { margin-bottom: 0; }
.panel h3 {
    font-family: var(--ui);
    font-size: .88rem;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: var(--brass-text);
    margin: 0 0 12px;
}
.panel ul { margin: 0; padding-left: 20px; }
.panel li { margin: 5px 0; }

/* Accented callout panel */
.panel-accent { border-left: 4px solid var(--ember); border-radius: 0 6px 6px 0; }

/* Mission / pull-quote */
blockquote {
    margin: 1.6em 0;
    padding: 6px 0 6px 26px;
    border-left: 4px solid var(--brass);
    font-family: var(--serif);
    font-size: 1.18rem;
    font-style: italic;
    color: #3d4752;
    line-height: 1.6;
}
blockquote footer { font-family: var(--sans); font-size: .9rem; font-style: normal; color: var(--muted); margin-top: 8px; }

/* Role/name pairs (board of directors) */
.role-list { margin: 0; }
.role-list dt {
    font-family: var(--ui);
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: var(--brass-text);
    font-weight: 700;
    margin-top: 12px;
}
.role-list dd { margin: 0; font-family: var(--serif); font-size: 1.1rem; color: var(--iron); }

/* Pill / tag list (partners, volunteer areas) */
.pill-list { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.pill-list li {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px 15px;
    font-size: .92rem;
    color: var(--ink);
}

/* Definition rows (fees, hours) */
.fact-rows { margin: 0; }
.fact-rows > div {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    padding: 9px 0;
    border-bottom: 1px dashed var(--line);
    font-size: .95rem;
}
.fact-rows > div:last-child { border-bottom: 0; }
.fact-rows .fact-label { color: var(--ink); }
/* Values must wrap: nowrap on long capacity lines widened the venue panels
   and pushed the whole grid off the page (Raylene, 2026-11-11). Right-aligned
   so a wrapped value still reads against the right edge. */
.fact-rows .fact-value { color: var(--ember); font-weight: 700; text-align: right; }

/* Wide banner figure */
.banner-figure { margin: 30px 0; }
.banner-figure img {
    width: 100%;
    max-height: 380px;
    object-fit: cover;
    border-radius: 6px;
}

/* --- Cards / highlight tiles --------------------------------------------- */

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 22px;
    margin: 30px 0 10px;
}

.card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 6px;
    overflow: hidden;
    text-decoration: none;
    color: var(--ink);
    display: flex;
    flex-direction: column;
    transition: transform .15s ease, box-shadow .15s ease;
}
.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(26, 35, 46, .16);
    color: var(--ink);
    border-color: #a8b9c9;
}
.card img { width: 100%; height: 165px; object-fit: cover; }
.card-body { padding: 16px 18px 20px; }
.card h2,
.card h3 { margin: 0 0 6px; font-size: 1.1rem; }
.card p { margin: 0; font-size: .95rem; color: var(--muted); }
.card .card-more {
    margin-top: 10px;
    font-family: var(--ui);
    font-size: .85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--ember);
}

/* --- Info strip (hours / address / contact) ------------------------------ */

.info-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 26px;
}
.info-strip h3 {
    margin-top: 0;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: .1em;
    font-family: var(--ui);
    font-weight: 700;
    color: var(--brass-text);
}
.info-strip p { margin: 0; font-size: .95rem; }

/* --- Figures ------------------------------------------------------------- */

figure { margin: 0; }

.img-left, .img-right, .img-center { margin: 6px 0 18px; }
.img-left  { float: left;  margin-right: 26px; max-width: 46%; }
.img-right { float: right; margin-left: 26px; max-width: 46%; }
.img-center { margin: 26px auto; text-align: center; }
.img-center img { margin: 0 auto; }

figure img {
    border-radius: 4px;
    border: 1px solid var(--line);
    box-shadow: 0 4px 14px rgba(26, 35, 46, .16);
}

figcaption {
    font-size: .9rem;
    color: var(--muted);
    text-align: center;
    margin-top: 8px;
    font-style: italic;
}

.clear { clear: both; }

/* Framed photo used in split layouts */
.photo-frame img {
    width: 100%;
    border-radius: 6px;
    border: 4px solid var(--paper);
    box-shadow: 0 14px 34px rgba(26, 35, 46, .26);
}

/* --- Events -------------------------------------------------------------- */

.event-heading {
    display: inline-block;
    color: var(--iron);
    border-bottom: 3px solid var(--ember);
    padding-bottom: 3px;
}

.event-block {
    background: var(--paper);
    border: 1px solid var(--line);
    border-left: 4px solid var(--ember);
    border-radius: 0 6px 6px 0;
    padding: 4px 22px 10px;
    margin: 18px 0;
}

.newsletter-list {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 10px;
}
.newsletter-list li { margin: 0; }
.newsletter-list a {
    display: block;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 5px;
    padding: 10px 14px;
    font-size: .95rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--iron);
}
.newsletter-list a:hover { border-color: var(--ember); color: var(--ember); }
.newsletter-list a::before { content: "\1F4C4"; margin-right: 8px; }

/* --- Photo gallery -------------------------------------------------------- */

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 14px;
    margin: 1.4em 0 2.4em;
}

.gallery a { display: block; text-decoration: none; color: var(--muted); }

.gallery img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid var(--line);
    box-shadow: 0 3px 10px rgba(26, 35, 46, .14);
    transition: transform .15s ease, box-shadow .15s ease;
}
.gallery a:hover img { transform: scale(1.03); box-shadow: 0 8px 20px rgba(26, 35, 46, .26); }
.gallery .caption { display: block; font-size: .88rem; margin-top: 6px; text-align: center; font-style: italic; }

/* Photo credit line, required on every archival image */
.gallery .credit, .photo-credit {
    display: block;
    font-size: .8rem;
    color: var(--muted);
    text-align: center;
    margin-top: 2px;
}

/* --- Photograph viewer ---------------------------------------------------- */

.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(18, 29, 44, .95);
    z-index: 100;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 8px;
    padding: 20px;
}
.lightbox[hidden] { display: none; }
body.has-lightbox { overflow: hidden; }

.lightbox-figure {
    margin: 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    height: 100%;
}
.lightbox-figure img {
    max-width: 100%;
    max-height: 78vh;
    width: auto;
    height: auto;
    border-radius: 4px;
    box-shadow: 0 0 44px rgba(0, 0, 0, .6);
}
.lightbox-figure figcaption {
    text-align: center;
    color: #d9e1e9;
    font-size: .95rem;
    max-width: 44em;
}
.lightbox-credit,
.lightbox-count { display: block; font-size: .85rem; color: #93a0ad; margin-top: 4px; }
.lightbox-credit[hidden] { display: none; }

.lightbox-nav {
    background: rgba(244, 247, 250, .10);
    border: 1px solid rgba(244, 247, 250, .28);
    color: #f4f7fa;
    border-radius: 50%;
    width: 52px;
    height: 52px;
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: background .15s ease, border-color .15s ease;
}
.lightbox-nav:hover { background: rgba(244, 247, 250, .22); border-color: rgba(244, 247, 250, .55); }
.lightbox-nav[hidden] { display: none; }
.lightbox-nav span { display: block; margin-top: -4px; }

.lightbox-close {
    position: absolute;
    top: 14px;
    right: 18px;
    background: none;
    border: 0;
    color: #f4f7fa;
    font-size: 40px;
    line-height: 1;
    cursor: pointer;
    padding: 4px 10px;
    border-radius: 6px;
}
.lightbox-close:hover { background: rgba(244, 247, 250, .14); }

@media (max-width: 620px) {
    .lightbox { grid-template-columns: 1fr; grid-template-rows: 1fr auto; padding: 14px; }
    .lightbox-figure { grid-row: 1; }
    .lightbox-nav { position: absolute; bottom: 18px; }
    .lightbox-prev { left: 18px; }
    .lightbox-next { right: 18px; }
}

/* --- CTA band + footer ---------------------------------------------------- */

.cta-band {
    background: linear-gradient(100deg, var(--ember-deep) 0%, var(--ember) 100%);
    color: #fff;
    padding: 44px 0;
}
.cta-band .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}
.cta-band h2 { color: #fff; margin: 0 0 4px; }
.cta-band p { margin: 0; color: rgba(255, 255, 255, .93); }
.cta-band .btn { background: #f7f9fb; color: var(--ember-deep); }
.cta-band .btn:hover { background: #fff; }

#footer {
    background: var(--iron-deep);
    color: #9aa7b4;
    font-size: .95rem;
    padding: 52px 0 0;
}
#footer h3 {
    color: #e8edf2;
    font-family: var(--ui);
    font-size: .88rem;
    text-transform: uppercase;
    letter-spacing: .14em;
    margin: 0 0 14px;
}
#footer a { color: #c9d4de; text-decoration: none; }
#footer a:hover { color: #fff; text-decoration: underline; }

.footer-cols {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 34px;
    padding-bottom: 30px;
}
.footer-cols ul { list-style: none; margin: 0; padding: 0; }
.footer-cols li { margin: 6px 0; }
.footer-cols p { margin: 0 0 8px; }

.land-ack {
    border-top: 1px solid rgba(255, 255, 255, .12);
    padding-top: 18px;
    margin: 0;
    font-size: .92rem;
    color: #a8b4c0;
    text-align: center;
}
.land-ack p { margin: 0; }

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .10);
    margin-top: 18px;
    padding: 16px 0;
    font-size: .9rem;
    color: #7e8b98;
    text-align: center;
}

/* --- Mobile ---------------------------------------------------------------- */

@media (max-width: 900px) {
    .split, .split-narrow, .grid-2, .grid-3 { grid-template-columns: 1fr; gap: 26px; }

    #header .container { padding-top: 12px; padding-bottom: 8px; }
    .brand .brand-name { font-size: 1.45rem; }
    .brand .brand-at { font-size: .85rem; }

    .nav-toggle-label {
        display: block;
        cursor: pointer;
        user-select: none;
        font-family: var(--ui);
        font-weight: 700;
        font-size: .85rem;
        text-transform: uppercase;
        letter-spacing: .1em;
        color: var(--iron);
        padding: 10px 0 6px;
        text-align: center;
    }
    .nav-toggle-label span {
        display: inline-block;
        width: 22px;
        height: 15px;
        border-top: 3px solid var(--ember);
        box-shadow: 0 6px 0 var(--ember), 0 12px 0 var(--ember);
        margin-right: 9px;
        vertical-align: middle;
    }
    #access { width: 100%; }
    #access ul { display: none; flex-direction: column; padding-bottom: 10px; }
    #access .nav-toggle:checked ~ ul { display: flex; }
    #access li { display: block; }
    #access li + li { border-left: 0; }
    #access a { border-bottom: 0; padding: 10px 0; font-size: .95rem; max-width: none; justify-content: flex-start; text-align: left; }
}

@media (max-width: 620px) {
    body { font-size: 16px; }
    .img-left, .img-right { float: none; max-width: 100%; margin: 18px auto; }
    .img-left img, .img-right img { margin: 0 auto; }
    .hero { min-height: 56vh; }
    .btn-ghost { margin-left: 0; margin-top: 10px; }
    .topbar .container { justify-content: center; }
}

/* ---------- Forms ---------- */
.contact-form { max-width: 560px; }
.form-field { margin-bottom: 16px; }
.form-field label {
    display: block; font-weight: 700; color: var(--iron);
    margin-bottom: 4px; font-size: .95rem; font-family: var(--ui);
}
.form-field input, .form-field textarea, .form-field select {
    width: 100%; padding: 11px 14px; font-size: 1rem;
    font-family: var(--sans); color: var(--ink);
    background: var(--paper); border: 2px solid var(--line);
    border-radius: 6px;
}
.form-field input:focus, .form-field textarea:focus, .form-field select:focus {
    outline: none; border-color: var(--ember);
}
.form-msg { padding: 13px 17px; border-radius: 6px; margin-bottom: 18px; max-width: 560px; }
.form-msg.ok { background: #e8f2e4; border: 1px solid #b5d3ab; color: #2c5424; }
.form-msg.err { background: #f9e7e1; border: 1px solid #e5b5a5; color: #8c3a1c; }
.hp-field { position: absolute; left: -9999px; }

/* Contact form panel treatment */
.form-panel {
    background: var(--paper);
    border: 1px solid var(--line);
    border-top: 3px solid var(--ember);
    border-radius: 8px;
    padding: 26px 28px 28px;
    box-shadow: 0 2px 10px rgba(26, 35, 46, .07);
}
.form-panel h2 { margin-top: 0; }
.form-panel .form-field input,
.form-panel .form-field textarea { background: #fff; }

/* Checkbox groups and field hints (membership, volunteer, genealogy forms) */
.form-checks { border: 1px solid var(--line); border-radius: 6px; padding: 12px 16px 14px; margin-bottom: 16px; }
.form-checks legend {
    font-family: var(--ui); font-weight: 700; font-size: .95rem;
    color: var(--iron); padding: 0 6px;
}
.form-checks .check { display: block; font-weight: 400; margin: 5px 0; font-size: .95rem; cursor: pointer; }
.form-checks .check input { width: auto; margin-right: 8px; }
.form-hint { display: block; font-size: .88rem; color: var(--muted); margin-bottom: 5px; }

/* --- Form accordion (membership, volunteer) ------------------------------- */

.form-accordion {
    background: var(--paper);
    border: 1px solid var(--line);
    border-left: 4px solid var(--ember);
    border-radius: 0 8px 8px 0;
    margin: 22px 0 6px;
}
.form-accordion > summary {
    cursor: pointer;
    list-style: none;
    padding: 16px 22px;
    font-family: var(--ui);
    font-weight: 700;
    font-size: 1rem;
    color: var(--iron);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}
.form-accordion > summary::-webkit-details-marker { display: none; }
.form-accordion > summary:hover { color: var(--ember); }
.form-accordion > summary:focus-visible { outline: 2px solid var(--ember); outline-offset: -2px; }

/* Chevron, rotated when the panel is open */
.form-accordion > summary::after {
    content: "";
    width: 10px;
    height: 10px;
    flex: none;
    border-right: 2px solid var(--ember);
    border-bottom: 2px solid var(--ember);
    transform: rotate(45deg);
    transition: transform .15s ease;
    margin-top: -4px;
}
.form-accordion[open] > summary::after { transform: rotate(-135deg); margin-top: 3px; }
.form-accordion[open] > summary { border-bottom: 1px solid var(--line); }

.form-accordion .accordion-body { padding: 20px 22px 24px; }
.form-accordion .summary-hint {
    font-family: var(--sans);
    font-weight: 400;
    font-size: .92rem;
    color: var(--muted);
    margin-left: auto;
    margin-right: 6px;
}

/* Form fields lay out in columns once there is room; textareas span. */
.form-accordion .contact-form {
    max-width: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 0 22px;
}
.form-accordion .form-field-wide,
.form-accordion .form-checks,
.form-accordion .form-actions,
.form-accordion .hp-field { grid-column: 1 / -1; }
.form-accordion .form-actions { margin-top: 6px; }
.form-accordion .form-msg { grid-column: 1 / -1; max-width: none; }

/* --- Print ---------------------------------------------------------------- */

.print-only { display: none; }

@media print {
    /* Site chrome never prints. */
    .topbar, #header, .page-band, .cta-band, #footer,
    #lightbox, .no-print, .form-actions, .hp-field, .breadcrumb { display: none !important; }

    .print-only { display: block; }

    body { background: #fff; color: #000; font-size: 11pt; }
    #content { padding: 0; }
    .container { max-width: none; padding: 0; }

    /* On a page with a printable form, print only that form. */
    body.has-printable-form .section:not(.printable-form) { display: none !important; }
    body.has-printable-form .section.printable-form > h2,
    body.has-printable-form .section.printable-form > p { display: none; }

    /* The accordion becomes a plain sheet. */
    .form-accordion {
        border: 0;
        margin: 0;
        background: transparent;
    }
    .form-accordion > summary { display: none; }
    .form-accordion > .accordion-body { padding: 0; display: block !important; }
    details.form-accordion > *:not(summary) { display: block !important; }

    .print-head { margin: 0 0 18px; }
    .print-head h2 { margin: 0 0 8px; font-size: 16pt; }
    .print-head p { margin: 0 0 6px; font-size: 10pt; line-height: 1.4; }

    /* Fields become ruled lines to fill in by hand. */
    .contact-form { display: block; max-width: none; }
    .form-field { margin: 0 0 14px; break-inside: avoid; page-break-inside: avoid; }
    .form-field label { font-weight: 700; font-size: 10pt; margin-bottom: 2px; }
    .form-hint { display: none; }
    .form-field input,
    .form-field textarea,
    .form-field select {
        width: 100%;
        border: 0;
        border-bottom: 1px solid #000;
        border-radius: 0;
        background: transparent;
        padding: 3px 0;
        font-size: 11pt;
        min-height: 1.8em;
    }
    .form-field textarea { min-height: 3.4em; }
    .form-checks { border: 0; padding: 0; }
    .form-checks legend { font-size: 10pt; font-weight: 700; padding: 0; }

    a { color: #000; text-decoration: none; }
    a[href^="http"]::after { content: ""; }
}

/* --- Month navigation and event listing ----------------------------------- */

.month-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    padding: 14px 0;
    margin: 10px 0 28px;
}
.month-nav .month-current {
    margin: 0;
    font-size: 1.5rem;
    text-align: center;
    flex: 1 1 auto;
}
.month-nav a {
    font-family: var(--ui);
    font-size: .95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    text-decoration: none;
    white-space: nowrap;
}
.month-nav a:hover { text-decoration: underline; }

/* Category filter on the calendar (2026-11-12). Only categories with an
   upcoming event are offered, so the filter never leads to an empty view. */
.cal-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 18px;
}
.cal-filter a {
    font-family: var(--ui);
    font-size: .8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    text-decoration: none;
    color: var(--ember);
    background: var(--brass-soft);
    border-radius: 999px;
    padding: 6px 14px;
}
.cal-filter a:hover,
.cal-filter a.is-current { background: var(--ember); color: #fff; }

.event-title { margin: 6px 0 4px; font-size: 1.2rem; }
.event-title a { text-decoration: none; color: var(--iron); }
.event-title a:hover { color: var(--ember); }

.event-meta {
    margin: 0 0 8px;
    font-size: .95rem;
    color: var(--muted);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}
.event-tag {
    font-family: var(--ui);
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--ember);
    background: var(--brass-soft);
    border-radius: 999px;
    padding: 2px 10px;
}
.event-date { font-weight: 700; color: var(--iron); }
.event-more { margin: 8px 0 0; font-size: .92rem; }

.month-quiet { color: var(--muted); font-style: italic; margin-bottom: 26px; }

/* A month with no events: the notice IS the content, so it gets presence. */
.month-empty {
    text-align: center;
    padding: 44px 20px 40px;
    max-width: none;
}
.month-empty-note {
    font-family: var(--serif);
    font-size: 1.45rem;
    color: var(--iron);
    margin: 0 0 10px;
}
.month-empty p { margin: 0; }
.month-empty p + p { margin-top: 6px; color: var(--muted); }

.history-entry {
    background: var(--paper);
    border: 1px solid var(--line);
    border-left: 4px solid var(--brass);
    border-radius: 0 8px 8px 0;
    padding: 18px 24px 20px;
    margin: 18px 0;
}
.history-entry h3 { margin-top: 0; }
.history-entry figure { margin: 0 0 14px; }
.history-entry img { border-radius: 6px; }

/* The single historical piece under an empty month: filler, not a feature.
   Narrow, centred, quieter type, image capped so it cannot dominate. */
.history-filler {
    max-width: 560px;
    margin: 10px auto 0;
    font-size: .95rem;
    padding: 16px 22px 18px;
}
.history-filler-kicker {
    font-family: var(--ui);
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .14em;
    color: var(--brass-text);
    margin: 0 0 10px;
}
.history-filler h3 { font-size: 1.05rem; margin-bottom: 6px; }
.history-filler p { margin: 0 0 10px; }
.history-filler p:last-child { margin-bottom: 0; }
.history-filler img {
    max-height: 200px;
    width: auto;
    margin: 0 auto;
}
.history-filler figure { margin-bottom: 12px; }

.newsletter-year {
    font-family: var(--ui);
    font-size: .82rem;
    text-transform: uppercase;
    letter-spacing: .14em;
    color: var(--brass-text);
    margin: 26px 0 10px;
}

/* Category pills that are links */
.pill-links li { padding: 0; }
.pill-links a {
    display: block;
    padding: 4px 15px;
    text-decoration: none;
    color: var(--iron);
    border-radius: 999px;
}
.pill-links a:hover { color: var(--ember); }
.pill-links a.current { background: var(--ember); color: #fff; }
a.event-tag { text-decoration: none; }
a.event-tag:hover { background: var(--ember); color: #fff; }

/* ==========================================================================
   Polish pass, 2026-09-17: accessibility basics, calmer news and archive
   treatments, and utility classes so templates stop carrying inline styles.
   ========================================================================== */

/* --- Keyboard and motion --------------------------------------------------- */

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 200;
    background: var(--ember);
    color: #fff;
    padding: 10px 18px;
    font-family: var(--ui);
    font-weight: 700;
    text-decoration: none;
    border-radius: 0 0 6px 0;
}
.skip-link:focus { left: 0; color: #fff; }

/* A visible focus ring everywhere, without the permanent outline on clicks. */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
    outline: 3px solid var(--ember);
    outline-offset: 2px;
    border-radius: 2px;
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
    .card:hover, a.admin-tile:hover { transform: none; }
}

/* --- Utilities, replacing inline styles ------------------------------------ */

.mt-0  { margin-top: 0; }
.mt-1  { margin-top: 14px; }
.mt-2  { margin-top: 22px; }
.mt-3  { margin-top: 34px; }
.mt-4  { margin-top: 48px; }
.small-print { font-size: .95rem; color: var(--muted); }
.empty-note {
    color: var(--muted);
    background: var(--paper);
    border: 1px dashed var(--line);
    border-radius: 8px;
    padding: 16px 20px;
    margin: 18px 0;
}

/* --- Articles -------------------------------------------------------------- */

.article-list { margin-top: 10px; }

.article-item {
    padding: 22px 0;
    border-bottom: 1px solid var(--line);
}
.article-item:first-child { padding-top: 6px; }
.article-item:last-child { border-bottom: 0; }
.article-item h3 { margin: 4px 0 8px; font-size: 1.35rem; }
.article-item h3 a { color: var(--iron); text-decoration: none; }
.article-item h3 a:hover { color: var(--ember); }
.article-item p { margin: 0 0 6px; }

.article-date {
    font-family: var(--ui);
    font-size: .78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .14em;
    color: var(--brass-text);
    margin: 0;
}
.article-more { font-size: .92rem; }

/* --- Archive lists (newsletters) ------------------------------------------- */

.archive { margin-top: 12px; }

.archive-year {
    display: grid;
    grid-template-columns: 90px 1fr;
    gap: 0 24px;
    padding: 16px 0;
    border-top: 1px solid var(--line);
    align-items: start;
}
.archive-year:last-child { border-bottom: 1px solid var(--line); }
.archive-year h3 {
    margin: 2px 0 0;
    font-family: var(--ui);
    font-size: .88rem;
    font-weight: 700;
    letter-spacing: .12em;
    color: var(--brass-text);
}
.archive-year ul { list-style: none; margin: 0; padding: 0; }
.archive-year li { margin: 0 0 6px; }
.archive-year li:last-child { margin-bottom: 0; }
.archive-year a {
    display: inline-flex;
    align-items: baseline;
    gap: 10px;
    text-decoration: none;
    color: var(--iron);
}
.archive-year a:hover { color: var(--ember); text-decoration: underline; }

.archive-type {
    font-family: var(--ui);
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .12em;
    color: var(--muted);
    border: 1px solid var(--line);
    border-radius: 3px;
    padding: 1px 5px;
    text-decoration: none;
}

@media (max-width: 620px) {
    .archive-year { grid-template-columns: 1fr; gap: 8px; }
}

/* --- Callout --------------------------------------------------------------- */

.callout {
    background: var(--brass-soft);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 24px 26px;
    margin: 36px 0 0;
}
.callout h3 { margin-top: 0; }
.callout p { margin: 0 0 10px; }
.callout p:last-child { margin-bottom: 0; }

/* --- Cards without a photograph -------------------------------------------- */

.card-plain {
    border-left: 4px solid var(--ember);
    border-radius: 0 8px 8px 0;
}
.card-plain .card-body { padding: 20px 22px 22px; }

/* Learning Series panels, evenly spaced without per-element margins */
.program-stack { display: grid; gap: 16px; margin-top: 16px; }

/* Single column variant of the info strip */
.info-strip-stacked { grid-template-columns: 1fr; }

/* Print button and its note, side by side */
.print-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.print-hint { font-size: .9rem; color: var(--muted); }

/* ==========================================================================
   Formatting pass, 2026-09-17: reading measure, heading clarity, rhythm.
   ========================================================================== */

/* --- Layout rule (Andrew, 2026-11-12) ---------------------------------------
   One rule across the board: a block of text with a photo uses .split-fill,
   text on the left and the photo on the right; a block with no photo runs the
   full container width. The old reading-measure caps (68ch body, 62ch panels,
   and friends) are gone: they left a dead right gutter wherever no photo sat.
   Banner-style crops belong to page headers only, never inside content.     */

/* --- Feature panels --------------------------------------------------------
   A .panel is a sidebar fact box and its h3 is a small label. A .panel-feature
   is a content card, so its heading has to read as a heading.                 */

.panel-feature h3 {
    font-family: var(--serif);
    font-size: 1.3rem;
    font-weight: 700;
    text-transform: none;
    letter-spacing: normal;
    color: var(--iron);
    margin: 0 0 10px;
}

/* --- Section rhythm --------------------------------------------------------
   More air between sections and a lighter rule, so a page with five anchor
   sections does not read as a stack of ruled boxes.                           */

.section {
    padding-top: 6px;
    margin-top: 52px;
    border-top: 1px solid rgba(205, 214, 223, .7);
}
.section > h2 { margin-top: .8em; }

/* --- Name lists ------------------------------------------------------------
   Pills suit short tags. Organisation and people names are too long for them,
   so they get a quiet multi-column list instead.                              */

.name-list {
    list-style: none;
    margin: 14px 0 0;
    padding: 0;
    columns: 2;
    column-gap: 34px;
}
.name-list li {
    break-inside: avoid;
    padding: 5px 0 5px 16px;
    position: relative;
    font-size: .95rem;
}
.name-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: .95em;
    width: 6px;
    height: 1px;
    background: var(--brass);
}
@media (max-width: 620px) { .name-list { columns: 1; } }

/* --- Consistent corners ----------------------------------------------------- */

.panel, .card, .form-panel, .callout, .banner-figure img, .photo-frame img { border-radius: 8px; }
.panel-accent { border-radius: 0 8px 8px 0; }

/* --- Footer contrast -------------------------------------------------------
   The old #7e8b98 on the near-black footer was about 4:1, under the 4.5:1
   minimum for small text.                                                     */

.footer-bottom { color: #93a0ad; }

/* Back link at the top of a form page */
.form-back { margin: 0 0 18px; font-size: .95rem; }
.form-back a { text-decoration: none; font-family: var(--ui); font-weight: 600; }
.form-back a:hover { text-decoration: underline; }
@media print { .form-back { display: none; } }

/* --- Long forms ------------------------------------------------------------
   A form with many short fields reads better in columns than as one very long
   single column. Textareas, checkbox groups and messages always span.         */

.form-grid {
    max-width: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 0 22px;
}
.form-grid .form-field-wide,
.form-grid .form-checks,
.form-grid .form-actions,
.form-grid .hp-field,
.form-grid .form-msg { grid-column: 1 / -1; }
.form-grid .form-actions { margin-top: 8px; }

/* The supporting box beside a form should not tower over it */
.form-aside h3 { margin-top: 0; }
.form-aside ul { margin: 0; padding-left: 20px; }
.form-aside li { margin: 5px 0; }

/* The organizational email directory on the contact page */
.email-directory { margin: 0; }
.email-directory dt {
    font-size: .92rem;
    font-weight: 700;
    color: var(--ink);
    margin-top: 12px;
}
.email-directory dt:first-child { margin-top: 0; }
.email-directory dd { margin: 1px 0 0; font-size: .95rem; }

@media print {
    /* The questionnaire prints as a plain sheet: no panel chrome, no aside. */
    .split.printable-form { display: block; }
    .printable-form .form-panel {
        background: transparent;
        border: 0;
        box-shadow: none;
        padding: 0;
    }
    .printable-form .form-aside { display: none !important; }
    .form-grid { display: block; }
}

/* ==========================================================================
   Membership and Donations
   ========================================================================== */

/* The membership price, as a single clear offer rather than a wall of text.
   Light blue with dark blue, matching the Genealogy page's callout (Andrew,
   2026-11-12); the button in the page is .btn-navy like the callout's. The
   old navy card made the green primary button read dark on dark. */
.offer-card {
    background: var(--brass-soft);
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 28px 26px 26px;
    text-align: center;
}
.offer-label {
    margin: 0;
    font-family: var(--ui);
    font-size: .85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .18em;
    color: var(--ember-deep);  /* the darker site green (Andrew, 2026-11-12; was the old gold #d9a441) */
}
.offer-price {
    margin: 6px 0 0;
    font-family: var(--serif);
    font-size: 3.4rem;
    font-weight: 700;
    line-height: 1;
    color: var(--iron);
}
.offer-period {
    margin: 2px 0 20px;
    font-size: .92rem;
    color: var(--brass-text);
}
.offer-card .btn { width: 100%; }
.offer-card .small-print { margin: 16px 0 0; }

/* Ticked list for the volunteer areas */
.tick-list { list-style: none; margin: 0; padding: 0; }
.tick-list li {
    position: relative;
    padding: 5px 0 5px 24px;
    font-size: .95rem;
}
.tick-list li::before {
    content: "";
    position: absolute;
    left: 2px;
    top: .85em;
    width: 10px;
    height: 5px;
    border-left: 2px solid var(--ember);
    border-bottom: 2px solid var(--ember);
    transform: rotate(-45deg);
}

/* Three ways to give, equal height, action pinned to the bottom */
.give-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-top: 16px;
}
.give-card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-top: 4px solid var(--ember);
    border-radius: 10px;
    padding: 22px 24px 24px;
    display: flex;
    flex-direction: column;
}
.give-card h4 {
    margin: 0 0 10px;
    font-family: var(--serif);
    font-size: 1.2rem;
    color: var(--iron);
}
.give-card p { margin: 0 0 14px; font-size: .95rem; }
.give-action { margin-top: auto; margin-bottom: 0; }

/* Special Events standing descriptions on What's On. Same card language as
   the giving cards. Until the Society writes the descriptions the cards carry
   names only, so .special-grid-names tightens them into a row of name tiles. */
.special-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 20px;
    margin-top: 16px;
}
.special-card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-top: 4px solid var(--ember);
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    scroll-margin-top: 90px;
}
.special-card-img {
    display: block;
    width: 100%;
    aspect-ratio: 3 / 2;
    object-fit: cover;
}
.special-card-body { padding: 20px 22px 22px; }
.special-card h3 {
    margin: 0 0 10px;
    font-family: var(--serif);
    font-size: 1.2rem;
    color: var(--iron);
}
.special-card p { margin: 0 0 12px; font-size: .95rem; }
.special-card p:last-child { margin-bottom: 0; }
.special-pending { color: var(--muted); font-style: italic; }
.special-grid-names .special-card-body { padding: 16px 20px; }
.special-grid-names .special-card h3 { margin: 0; }

/* Giving levels as a row of tiers rather than a table */
.tier-row {
    list-style: none;
    margin: 16px 0 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
}
.tier-row li {
    background: var(--brass-soft);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 14px 16px;
    text-align: center;
}
.tier-name {
    display: block;
    font-family: var(--serif);
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--iron);
}
.tier-range {
    display: block;
    font-size: .92rem;
    color: var(--brass-text);
    margin-top: 2px;
}

/* A quiet strip for legal and tax wording */
.note-strip {
    margin: 26px 0 0;
    padding: 14px 18px;
    border-left: 3px solid var(--line);
    font-size: .92rem;
    color: var(--muted);
}

/* The anonymous donor count, given some presence */
.champion-count {
    font-family: var(--serif);
    font-size: 3rem;
    font-weight: 700;
    line-height: 1;
    color: var(--ember);
    margin: 4px 0 2px;
}

@media (max-width: 900px) {
    .offer-card { text-align: left; }
    .offer-card .btn { width: auto; }
}

/* --- Page banner -----------------------------------------------------------
   The banner carries the page title, so one band does the job of two: the
   heading is still the first thing read, and the picture sits behind it. A
   gradient keeps the text legible whatever the photograph is doing.         */

.page-banner {
    position: relative;
    display: flex;
    align-items: flex-end;
    min-height: clamp(220px, 30vw, 340px);
    background: var(--iron-deep);
    overflow: hidden;
}
.page-banner > img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.page-banner::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,
        rgba(18, 29, 44, .92) 0%,
        rgba(18, 29, 44, .70) 38%,
        rgba(18, 29, 44, .34) 70%,
        rgba(18, 29, 44, .22) 100%);
}
.page-banner-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 40px 0 34px;
}
.page-banner h1 {
    color: #fff;
    margin: 0;
    font-size: clamp(1.9rem, 4.4vw, 2.9rem);
    text-shadow: 0 2px 14px rgba(0, 0, 0, .55);
}
.page-banner .band-sub {
    color: #e6dccb;
    margin: 10px 0 0;
    max-width: 46em;
    font-style: italic;
    text-shadow: 0 1px 10px rgba(0, 0, 0, .6);
}
.page-banner-credit {
    position: absolute;
    right: 0;
    bottom: 0;
    z-index: 3;
    margin: 0;
    background: rgba(18, 29, 44, .72);
    color: #becad5;
    font-size: .78rem;
    letter-spacing: .02em;
    padding: 4px 12px;
    border-radius: 6px 0 0 0;
}
@media print { .page-banner { display: none; } }

/* --- Layout pattern ----------------------------------------------------------
   The pattern the Home, Learn, Plan Your Visit and Venue Rentals pages already
   follow, made explicit so every page reads the same way:

     section heading, a short intro, then ONE full-width block below it:
       .pair        two boxes side by side, always equal height
       .split-fill  text beside a photo cropped to the height of the text
       .trio        three equal boxes
       a stack of feature panels, a card grid, or a fact panel

   The rule the older layouts broke: never put a short column beside a tall
   one, because the gap under the short one reads as an empty block.        */

.pair,
.trio {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
    align-items: stretch;
    margin-top: 20px;
}
.trio { grid-template-columns: repeat(3, 1fr); }
.pair > *,
.trio > * { margin: 0; min-width: 0; }  /* a grid child's min-width:auto lets long content widen the track past the page edge */
.pair > .offer-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Text beside a photo. The photo fills whatever height the text needs, so
   the two columns always finish level. */
.split-fill {
    display: grid;
    grid-template-columns: 1.15fr .85fr;
    gap: 40px;
    align-items: stretch;
    margin-top: 6px;
}
.split-fill > div > :first-child { margin-top: 0; }
.split-fill > div > :last-child { margin-bottom: 0; }
/* No photo, no photo column: when the admin empties a split's image the
   text takes the full width (the layout rule of 2026-11-12). */
.split-fill:not(:has(> figure)) { grid-template-columns: 1fr; }
.photo-fill {
    display: flex;
    flex-direction: column;
    margin: 0;
    min-height: 260px;
}
.photo-fill > a,
.photo-fill > .photo-fill-box {
    position: relative;
    flex: 1;
    display: block;
    min-height: 220px;
}
.photo-fill img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
    border: 4px solid var(--paper);
    box-shadow: 0 14px 34px rgba(26, 35, 46, .26);
}
.photo-fill figcaption { flex: none; }

/* --- Program cards (Learn, 2026-11-12) --------------------------------------
   Each program is a card: photo or category icon, title, one line blurb.
   A record with more content expands IN PLACE via native <details>, so a
   visitor browsing what is available never leaves the page. */
.prog-group { margin-top: 34px; }
.prog-group > h3 {
    font-family: var(--serif);
    font-size: 1.3rem;
    color: var(--iron);
    margin: 0 0 6px;
}
.prog-list { display: grid; gap: 14px; margin-top: 16px; }

.prog-card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 8px;
}
.prog-card > summary {
    list-style: none;
    cursor: pointer;
}
.prog-card > summary::-webkit-details-marker { display: none; }
.prog-card > summary,
.prog-card:not(details) {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    padding: 16px 20px;
}
.prog-card > summary:hover .prog-title { color: var(--ember); }

.prog-media {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    overflow: hidden;
}
/* The icon tile matches the photo thumbnail's footprint so titles line up
   down a mixed list; navy on the pale blue-grey, the site's chrome pairing. */
.prog-media-icon,
.prog-media-photo { width: 96px; height: 68px; }
.prog-media-icon {
    background: var(--ember-soft);
    color: var(--ember-deep);
}
.prog-media-icon svg { width: 28px; height: 28px; }
.prog-media-photo img { width: 100%; height: 100%; object-fit: cover; }

.prog-text { flex: 1 1 auto; min-width: 0; }
.prog-title {
    display: block;
    font-family: var(--serif);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--iron);
}
.prog-blurb { display: block; margin-top: 4px; color: var(--muted); }
.prog-actions {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    margin-top: 8px;
    font-family: var(--ui);
    font-size: .9rem;
    font-weight: 700;
}
.prog-toggle { color: var(--ember); }
.prog-toggle::before { content: "+ "; }
details[open] > summary .prog-toggle::before { content: "\00d7 "; }
details[open] > summary .prog-toggle-open { display: none; }
details:not([open]) > summary .prog-toggle-close { display: none; }
.prog-ask { color: var(--ember); }

.prog-body {
    border-top: 1px solid var(--line);
    padding: 18px 20px 20px;
}
.prog-body .split-fill { margin-top: 0; }
.prog-body .photo-fill { min-height: 200px; }
.prog-note { margin-top: 14px; }
.prog-dates { margin-top: 16px; }
.prog-dates h4 {
    font-family: var(--ui);
    font-size: .82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--brass-text);
    margin: 0 0 6px;
}
.prog-dates ul { list-style: none; margin: 0; padding: 0; max-width: none; }
.prog-dates li { padding: 3px 0; }
.prog-dates-when { color: var(--muted); margin-left: 8px; }
.prog-ask-row { margin: 16px 0 0; font-family: var(--ui); font-weight: 700; }

@media (max-width: 620px) {
    .prog-card > summary,
    .prog-card:not(details) { gap: 14px; padding: 14px 16px; }
    .prog-media-icon,
    .prog-media-photo { width: 72px; height: 54px; }
}

/* A section heading that sits inside a panel, for short sections paired up */
.panel-feature h2 {
    font-family: var(--serif);
    font-size: 1.45rem;
    color: var(--iron);
    margin: 0 0 12px;
}

/* A panel whose content is a single figure, centred in the box */
.panel-centred {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Program filter at the top of What's On */
.program-filter {
    margin: 18px 0 8px;
    padding: 14px 18px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 8px;
}
.program-filter .filter-label {
    font-family: var(--ui);
    font-size: .74rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--brass-text);
    margin: 0;
}
.program-filter .pill-list { margin-top: 8px; }
.program-filter .small-print { margin: 8px 0 0; }

/* Photo grid: four across, so the Society's sets of 8 and 16 fill every row */
.gallery { grid-template-columns: repeat(4, 1fr); gap: 18px; }

/* Link cards: three across, so six links make two full rows */
.cards-3 { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 900px) {
    .pair, .trio, .split-fill { grid-template-columns: 1fr; gap: 22px; }
    .gallery { grid-template-columns: repeat(3, 1fr); }
    .cards-3 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 620px) {
    .gallery { grid-template-columns: repeat(2, 1fr); }
    .cards-3 { grid-template-columns: 1fr; }
    .photo-fill { min-height: 230px; }
}

/* Archival photos carry an IMHS.ca watermark across the upper half. When a
   .photo-fill crop would show it, anchor the crop to the bottom instead. */
.photo-fill-bottom img { object-position: center bottom; }

/* Board officers two by two, so the Board box stays close to its photo's shape */
.role-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 24px; }
.role-grid > div > dt { margin-top: 6px; }

/* --- FAQ accordions (venue-faqs.php) ------------------------------------- */

.faq-list { margin-top: 18px; }
.faq-list details {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 6px;
    margin-bottom: 10px;
}
.faq-list summary {
    cursor: pointer;
    list-style: none;
    padding: 14px 46px 14px 18px;
    font-family: var(--ui);
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--iron-deep);
    position: relative;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
    content: "+";
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
    line-height: 1;
    color: var(--brass-text);
}
.faq-list details[open] summary::after { content: "\2212"; }
.faq-list details[open] summary { border-bottom: 1px solid var(--line); }
.faq-list .faq-body { padding: 6px 18px 8px; }

/* --- Richmond Record archive (richmond-record.php) ------------------------ */

.rr-search { display: flex; gap: 10px; flex-wrap: wrap; margin: 10px 0 6px; }
.rr-search input[type="text"] {
    flex: 1 1 260px;
    padding: 10px 14px;
    font-family: var(--ui);
    font-size: 1rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--paper);
    color: var(--ink);
}
.rr-search input[type="text"]:focus { outline: 2px solid var(--brass); }

.rr-decade { margin-top: 26px; }
.rr-years {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
    gap: 10px;
    margin-top: 10px;
}
.rr-years a {
    display: block;
    padding: 10px 12px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 6px;
    text-decoration: none;
    text-align: center;
}
.rr-years a:hover { border-color: var(--brass); }
.rr-year {
    display: block;
    font-family: var(--serif);
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--iron);
}
.rr-count {
    display: block;
    font-family: var(--ui);
    font-size: 0.82rem;
    color: var(--muted);
}

.rr-issues { list-style: none; padding: 0; margin: 14px 0 0; max-width: none; }
.rr-issues li {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    flex-wrap: wrap;
    padding: 10px 14px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 6px;
    margin-bottom: 8px;
}
.rr-issues li a {
    font-family: var(--ui);
    font-weight: 600;
    font-size: 1.02rem;
}
.rr-issues .rr-meta {
    font-family: var(--ui);
    font-size: 0.85rem;
    color: var(--muted);
    white-space: nowrap;
}

.rr-hits { margin-top: 14px; }
.rr-hit {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 14px 18px;
    margin-bottom: 12px;
}
.rr-hit h3 { margin: 0 0 6px; }
.rr-hit h3 .rr-meta {
    font-family: var(--ui);
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--muted);
    margin-left: 10px;
}
.rr-hit ul { list-style: none; padding: 0; margin: 0; max-width: none; }
.rr-hit li { padding: 4px 0; }
.rr-hit li > a { font-family: var(--ui); font-weight: 600; white-space: nowrap; }
.rr-snip {
    font-family: var(--ui);
    font-size: 0.92rem;
    color: var(--ink);
    margin-left: 8px;
}
.rr-snip mark {
    background: var(--brass-soft);
    color: var(--iron-deep);
    padding: 0 2px;
    border-radius: 2px;
}
