/*
Theme Name: AmaNtambo Royal
Theme URI: https://example.org/amantambo-royal
Author: AmaNtambo Royal Family website team
Description: A modern, readable and sophisticated royal theme for the official AmaNtambo Royal Family website. Burgundy, charcoal, gold and ivory; Cormorant Garamond and Public Sans; light and dark appearance; per-page hero banners; accessible navigation. Use together with the "AmaNtambo Royal Core" plugin, which provides lineage, projects, events, gallery, forms and settings.
Version: 1.2.0
Requires at least: 6.2
Tested up to: 6.6
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: amantambo-royal
Tags: custom-menu, featured-images, accessibility-ready, translation-ready, two-columns
*/

/* AmaNtambo Royal Family: shared design system.
   Layout concept: ivory reading pages framed by a burgundy/charcoal header, a cinematic hero slot per page and a charcoal footer.
   Gold is used for rules, borders and buttons; reading text uses ink or burgundy for contrast. */
:root {
  --burgundy: #7D101C;
  --charcoal: #171717;
  --gold: #C49A43;
  --ivory: #F8F4EA;
  --white: #FFFFFF;
  --grey: #E9E5DE;

  --bg: var(--ivory);
  --surface: var(--white);
  --surface-2: #F1ECE0;
  --ink: #1F1B17;
  --ink-soft: #4F473E;
  --line: #DDD4C2;
  --accent: var(--burgundy);
  --gold-text: #7A5614;
  --focus: #7D101C;
  --btn-gold-ink: #171717;
  --chip-bg: #F1E7CF;

  --serif: "Cormorant Garamond", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans: "Public Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
  --pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='14' viewBox='0 0 28 14'%3E%3Cpath d='M0 14 L7 2 L14 14 L21 2 L28 14' fill='none' stroke='%23C49A43' stroke-width='1.4'/%3E%3C/svg%3E");
  --pattern-faint: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='28' viewBox='0 0 56 28'%3E%3Cpath d='M0 28 L14 4 L28 28 L42 4 L56 28' fill='none' stroke='%23C49A43' stroke-opacity='.16' stroke-width='1.2'/%3E%3C/svg%3E");
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #14110F; --surface: #1D1915; --surface-2: #262019; --ink: #F3ECDD; --ink-soft: #CFC5B1;
    --line: #3A3329; --accent: #E58E97; --gold-text: #D9B35F; --focus: #F2D07F; --chip-bg: #2E2616; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #14110F; --surface: #1D1915; --surface-2: #262019; --ink: #F3ECDD; --ink-soft: #CFC5B1;
  --line: #3A3329; --accent: #E58E97; --gold-text: #D9B35F; --focus: #F2D07F; --chip-bg: #2E2616; color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.0625rem/1.7 var(--sans); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 2px; }
.skip { position: absolute; left: 1rem; top: -4rem; background: var(--gold); color: #171717; padding: .6rem 1rem; z-index: 100; font-weight: 600; }
.skip:focus { top: .5rem; }
.wrap { width: min(1160px, 100% - 2rem); margin-inline: auto; }
.narrow { width: min(760px, 100% - 2rem); margin-inline: auto; }

h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.12; letter-spacing: .005em; text-wrap: balance; margin: 0; }
h2 { font-size: clamp(2rem, 4.2vw, 2.9rem); color: var(--ink); }
h3 { font-size: 1.55rem; }
h4 { font-size: 1.2rem; }
p { margin: 0; max-width: 68ch; }
.lead { font-size: 1.22rem; line-height: 1.65; color: var(--ink-soft); }
.eyebrow { font: 600 .78rem/1 var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--gold-text); }
.stack > * + * { margin-top: 1rem; }
.stack-lg > * + * { margin-top: 1.75rem; }

section.block { padding-block: clamp(3rem, 7vw, 5.5rem); }
section.alt { background: var(--surface-2); background-image: var(--pattern-faint); }
.sec-head { display: grid; gap: .8rem; margin-bottom: 2.4rem; }
.sec-head p { color: var(--ink-soft); }
.rule { display: flex; align-items: center; gap: .9rem; margin-block: 1.1rem; color: var(--gold); }
.rule::before, .rule::after { content: ""; height: 1px; flex: 1; background: linear-gradient(90deg, transparent, var(--gold)); }
.rule::after { background: linear-gradient(270deg, transparent, var(--gold)); }
.rule i { width: 9px; height: 9px; transform: rotate(45deg); border: 1.5px solid var(--gold); }
.band { height: 14px; background: var(--pattern) repeat-x center; }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: .55rem; min-height: 46px; padding: .7rem 1.35rem; font: 600 .95rem/1 var(--sans); letter-spacing: .02em; text-decoration: none; border: 1.5px solid var(--gold); border-radius: 3px; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.btn-gold { background: var(--gold); color: var(--btn-gold-ink); }
.btn-gold:hover { background: #D6AE5C; }
.btn-burg { background: var(--burgundy); color: #fff; border-color: var(--burgundy); }
.btn-burg:hover { background: #961425; border-color: #961425; }
.btn-line { background: transparent; color: var(--ink); border-color: var(--gold); }
.btn-line:hover { background: var(--chip-bg); }
.on-dark .btn-line, .hero .btn-line, .site-footer .btn-line { color: #fff; }
.on-dark .btn-line:hover, .hero .btn-line:hover { background: rgba(255,255,255,.1); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
.btn-row { display: flex; flex-wrap: wrap; gap: .8rem; }

/* Header */
.announce { background: var(--burgundy); color: #fff; font-size: .9rem; text-align: center; padding: .55rem 1rem; }
.announce a { color: #F2D9A0; }
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50; background: #171717; color: #fff; border-bottom: 2px solid var(--gold); }
.hdr { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 72px; }
.brand { display: flex; align-items: center; gap: .8rem; color: #fff; text-decoration: none; }
.brand img { width: 54px; height: 54px; border-radius: 50%; background: #fff; object-fit: cover; border: 1.5px solid var(--gold); }
.brand span { font: 600 1.15rem/1.1 var(--serif); letter-spacing: .04em; }
.brand small { display: block; font: 500 .62rem/1.3 var(--sans); letter-spacing: .2em; text-transform: uppercase; color: #D9B35F; margin-top: .15rem; }
.nav { display: flex; align-items: center; gap: .15rem; }
.nav a, .nav button.dd-btn { color: #F3ECDD; font: 500 .88rem/1 var(--sans); text-decoration: none; padding: .8rem .5rem; border: 0; background: none; cursor: pointer; border-bottom: 2px solid transparent; white-space: nowrap; }
.nav a:hover, .nav button.dd-btn:hover { color: #F2D07F; }
.nav a[aria-current="page"], .nav .dd.active > button { color: #F2D07F; border-bottom-color: var(--gold); }
.dd { position: relative; }
.dd-menu { position: absolute; top: 100%; left: 0; min-width: 190px; background: #171717; border: 1px solid var(--gold); padding: .4rem; display: none; }
.dd.open .dd-menu { display: grid; }
.dd-menu a { padding: .65rem .8rem; }
.nav .nav-contact { margin-left: .5rem; background: var(--gold); color: #171717; border-radius: 3px; padding: .7rem 1rem; font-weight: 600; }
.nav .nav-contact:hover { color: #171717; background: #D6AE5C; }
.nav .nav-contact[aria-current="page"] { border-bottom-color: transparent; color: #171717; }
.menu-btn { display: none; background: none; border: 1.5px solid var(--gold); color: #fff; border-radius: 3px; min-height: 44px; padding: 0 .9rem; font: 600 .9rem var(--sans); cursor: pointer; }
.theme-btn { background: none; border: 0; color: #D9B35F; cursor: pointer; font: 500 .8rem var(--sans); padding: .5rem; }
@media (max-width: 1440px) {
  .menu-btn { display: inline-flex; align-items: center; }
  .nav { position: absolute; left: 0; right: 0; top: 100%; background: #171717; border-bottom: 2px solid var(--gold); flex-direction: column; align-items: stretch; padding: .5rem 1rem 1rem; display: none; max-height: calc(100vh - 80px); overflow: auto; }
  .nav.open { display: flex; }
  .nav a, .nav button.dd-btn { padding: .95rem .4rem; border-bottom: 1px solid #2c2c2c; text-align: left; font-size: 1rem; }
  .dd-menu { position: static; display: grid; border: 0; padding: 0 0 0 1rem; }
  .dd-btn::after { content: none; }
  .nav .nav-contact { margin: .8rem 0 0; text-align: center; }
}

/* Hero */
.hero { position: relative; isolation: isolate; color: #fff; background: #1b1412; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -3; background: radial-gradient(120% 90% at 85% 10%, #5b0e18 0%, #2a1013 45%, #151211 100%); }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(15,12,10,.82) 0%, rgba(15,12,10,.55) 55%, rgba(15,12,10,.25) 100%); }
.hero-bg { position: absolute; inset: 0; z-index: -2; background-size: cover; background-position: center; }
.hero-pat { position: absolute; inset: 0; z-index: -2; background: var(--pattern-faint); opacity: .9; }
.hero-in { min-height: clamp(380px, 38vw, 480px); display: flex; flex-direction: column; justify-content: flex-end; gap: 1rem; padding-block: 3rem 3.2rem; }
.hero-in > * { max-width: 820px; }
.home-hero .hero-in > * { max-width: none; }
.hero h1 { font-size: clamp(2.2rem, 5.4vw, 3.9rem); color: #fff; }
.hero p.sub { font-size: clamp(1.05rem, 2vw, 1.3rem); color: #F0E6D0; max-width: 56ch; line-height: 1.55; }
.crumbs { display: flex; gap: .5rem; font-size: .85rem; color: #E7D9B8; letter-spacing: .04em; }
.crumbs a { color: #F2D9A0; }
.crumbs span[aria-hidden] { opacity: .6; }
.slot-tag { position: absolute; right: 1rem; bottom: .8rem; font: 500 .7rem var(--sans); letter-spacing: .08em; color: #E7D9B8; background: rgba(0,0,0,.45); padding: .3rem .6rem; border: 1px dashed rgba(196,154,67,.7); }
.hero.has-img .slot-tag { display: none; }
.hero .gold-edge { position: absolute; left: 0; right: 0; bottom: 0; height: 14px; background: var(--pattern) repeat-x center; }

/* Cards and grids */
.grid { display: grid; gap: 1.5rem; }
.g2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); }
.g3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.g4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); padding: 1.6rem; display: grid; align-content: start; gap: .7rem; min-width: 0; }
.card.gold { border-color: var(--gold); }
.card h3, .card h4 { color: var(--ink); }
.card p { color: var(--ink-soft); font-size: 1rem; }
.card .more { font-weight: 600; text-decoration: none; margin-top: .3rem; }
.card .more::after { content: " \2192"; }
.split { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.split.flip > :first-child { order: 2; }
@media (max-width: 820px) { .split { grid-template-columns: 1fr; } .split.flip > :first-child { order: 0; } }
.frame { position: relative; padding: 10px; border: 1px solid var(--gold); background: var(--surface); }
.frame::after { content: ""; position: absolute; inset: 4px; border: 1px solid rgba(196,154,67,.45); pointer-events: none; }
.frame img { width: 100%; height: 100%; object-fit: cover; }
.frame.sm { max-width: 340px; }
.pair { display: flex; flex-wrap: wrap; gap: 1.5rem; }
.pair figure { margin: 0; flex: 1 1 220px; max-width: 300px; }
.pair figcaption { font: 600 .8rem var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--gold-text); margin-top: .7rem; text-align: center; }
.cap { font-size: .85rem; color: var(--ink-soft); margin-top: .6rem; }
.quote { margin-inline: 0; font: italic 500 clamp(1.5rem, 3vw, 2.1rem)/1.3 var(--serif); color: var(--ink); border-left: 3px solid var(--gold); padding-left: 1.3rem; max-width: 34ch; }
.quote cite { display: block; font: 600 .78rem var(--sans); font-style: normal; letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); margin-top: .9rem; }

/* Status chips */
.chip { display: inline-flex; align-items: center; font: 600 .72rem/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; padding: .4rem .65rem; background: var(--chip-bg); color: var(--gold-text); border: 1px solid var(--gold); }
.chip.fam { color: var(--ink); }
.note { border: 1px solid var(--gold); background: var(--chip-bg); padding: 1rem 1.2rem; font-size: .95rem; color: var(--ink); max-width: none; }
.note strong { color: var(--accent); }

/* Pillars */
.pillar { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 1.6rem; padding-block: 2.2rem; border-top: 1px solid var(--line); }
.pillar:first-of-type { border-top: 0; }
.pillar .ico { width: 72px; height: 72px; border: 1.5px solid var(--gold); display: grid; place-items: center; background: var(--surface); color: var(--accent); }
.pillar .ico svg { width: 38px; height: 38px; }
.pillar ul { margin: .6rem 0 0; padding-left: 1.2rem; color: var(--ink-soft); }
.pillar li + li { margin-top: .35rem; }
.pillar .tag { font: 600 .75rem var(--sans); letter-spacing: .18em; text-transform: uppercase; color: var(--gold-text); margin-bottom: .4rem; }
@media (max-width: 600px) { .pillar { grid-template-columns: 1fr; gap: 1rem; } }
.mini-pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.mini-pillars a { background: var(--surface); padding: 1.4rem; text-decoration: none; color: var(--ink); display: grid; gap: .5rem; }
.mini-pillars a:hover { background: var(--chip-bg); }
.mini-pillars svg { width: 34px; height: 34px; color: var(--accent); }
.mini-pillars b { font: 600 1.25rem/1.15 var(--serif); }
.mini-pillars span { font-size: .92rem; color: var(--ink-soft); }

/* Facts, timeline */
.facts { display: grid; grid-template-columns: minmax(130px, 220px) minmax(0, 1fr); border: 1px solid var(--line); background: var(--surface); }
.facts dt, .facts dd { margin: 0; padding: .95rem 1.1rem; border-bottom: 1px solid var(--line); }
.facts dt { font: 600 .75rem/1.5 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); background: var(--surface-2); }
.facts dt:last-of-type, .facts dd:last-of-type { border-bottom: 0; }
@media (max-width: 560px) { .facts { grid-template-columns: 1fr; } .facts dd { border-bottom: 1px solid var(--line); } }
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 11px; top: 8px; bottom: 8px; width: 1px; background: var(--gold); }
.timeline li { position: relative; padding: 0 0 2rem 3rem; }
.timeline li::before { content: ""; position: absolute; left: 4px; top: 7px; width: 15px; height: 15px; background: var(--bg); border: 2px solid var(--gold); transform: rotate(45deg); }
.timeline h4 { color: var(--ink); }
.timeline .when { font: 600 .75rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); }

/* Lineage tree */
.tree-tools { display: flex; flex-wrap: wrap; gap: .7rem; margin-bottom: 1.4rem; }
.seg { margin-bottom: 1rem; border: 1px solid var(--line); background: var(--surface); }
.seg > button { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 1rem; background: var(--surface-2); border: 0; padding: 1rem 1.2rem; cursor: pointer; font: 600 1.25rem var(--serif); color: var(--ink); text-align: left; }
.seg > button small { font: 500 .85rem var(--sans); color: var(--ink-soft); }
.seg > button::after { content: "+"; font: 400 1.6rem var(--sans); color: var(--accent); margin-left: auto; }
.seg > button[aria-expanded="true"]::after { content: "\2212"; }
.seg-body { padding: 1.4rem 1.2rem 1rem; }
.seg-body[hidden] { display: none; }
.chain { list-style: none; margin: 0 auto; padding: 0; display: grid; justify-items: center; max-width: 440px; }
.chain li { width: 100%; display: grid; justify-items: center; }
.chain li + li::before { content: ""; width: 1px; height: 28px; background: var(--gold); margin: 0; }
.node { width: 100%; background: var(--surface); border: 1px solid var(--gold); padding: .85rem 1rem; text-align: center; cursor: pointer; font: 600 1.35rem/1.2 var(--serif); color: var(--ink); position: relative; }
.node:hover, .node[aria-expanded="true"] { background: var(--chip-bg); }
.node small { display: block; font: 500 .74rem var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--gold-text); margin-bottom: .25rem; }
.node.praise::after { content: ""; position: absolute; right: 8px; top: 8px; width: 7px; height: 7px; background: var(--gold); transform: rotate(45deg); }
.node.final { background: var(--burgundy); border-color: var(--burgundy); color: #fff; }
.node.final small { color: #F2D9A0; }
.node.final:hover, .node.final[aria-expanded="true"] { background: #961425; }
.panel { width: 100%; background: var(--surface-2); border: 1px solid var(--line); border-top: 0; padding: 1rem 1.1rem; text-align: left; font-size: .95rem; display: grid; gap: .5rem; }
.panel[hidden] { display: none; }
.panel dl { margin: 0; display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: .3rem .8rem; }
.panel dt { font: 600 .72rem var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--gold-text); padding-top: .15rem; }
.panel dd { margin: 0; color: var(--ink-soft); }
.legend { display: flex; flex-wrap: wrap; gap: 1rem 1.6rem; font-size: .9rem; color: var(--ink-soft); }
.legend i { display: inline-block; width: 9px; height: 9px; background: var(--gold); transform: rotate(45deg); margin-right: .5rem; }
.names { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: .6rem; }
.names li { background: var(--surface); border: 1px solid var(--line); padding: .7rem .9rem; display: grid; gap: .1rem; }
.names li b { font: 600 1.15rem var(--serif); color: var(--ink); }
.names li span { font-size: .8rem; color: var(--ink-soft); }
.names li.self { border-color: var(--burgundy); background: var(--chip-bg); }
@media print { .site-header, .site-footer, .hero, .tree-tools, .announce, .totop { display: none !important; } .seg-body[hidden] { display: block !important; } body { background: #fff; color: #000; } }

/* Filters, lists, gallery */
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.4rem; }
.pill { border: 1px solid var(--gold); background: var(--surface); color: var(--ink); padding: .55rem .95rem; min-height: 40px; font: 500 .9rem var(--sans); cursor: pointer; border-radius: 999px; }
.pill:hover { background: var(--chip-bg); }
.pill[aria-pressed="true"] { background: var(--burgundy); border-color: var(--burgundy); color: #fff; }
.search { display: flex; gap: .6rem; flex-wrap: wrap; margin-bottom: 1.2rem; }
.search input { flex: 1 1 260px; }
.empty { border: 1px dashed var(--gold); background: var(--surface); padding: 2.4rem 1.5rem; text-align: center; display: grid; justify-items: center; gap: .6rem; }
.empty h3 { color: var(--ink); }
.empty p { color: var(--ink-soft); }
.empty svg { width: 44px; height: 44px; color: var(--gold); }
.gal { columns: 3 260px; column-gap: 1rem; }
.gal button { display: block; width: 100%; margin: 0 0 1rem; padding: 6px; background: var(--surface); border: 1px solid var(--gold); cursor: zoom-in; break-inside: avoid; text-align: left; }
.gal img { width: 100%; height: auto; }
.gal figcaption { padding: .6rem .3rem .2rem; font-size: .88rem; color: var(--ink-soft); }
.lb { position: fixed; inset: 0; z-index: 200; background: rgba(10,8,6,.93); display: grid; grid-template-rows: 1fr auto; padding: 1rem; color: #fff; }
.lb[hidden] { display: none; }
.lb-img { min-height: 0; display: grid; place-items: center; }
.lb-img img { max-height: 100%; max-width: 100%; object-fit: contain; border: 1px solid var(--gold); }
.lb-cap { text-align: center; padding: .8rem 3.5rem; font-size: .95rem; color: #E7D9B8; }
.lb button { position: absolute; background: rgba(23,23,23,.8); border: 1px solid var(--gold); color: #fff; width: 48px; height: 48px; font-size: 1.4rem; cursor: pointer; }
.lb .x { top: 1rem; right: 1rem; } .lb .p { left: 1rem; top: 50%; } .lb .n { right: 1rem; top: 50%; }
.evt { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 1.2rem; background: var(--surface); border: 1px solid var(--line); padding: 1.2rem; }
.evt .d { border: 1px solid var(--gold); text-align: center; padding: .6rem .2rem; font: 600 1.9rem/1 var(--serif); color: var(--accent); }
.evt .d small { display: block; font: 600 .72rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-text); margin-top: .3rem; }
.cal { background: var(--surface); border: 1px solid var(--line); padding: 1.2rem; }
.cal-h { display: flex; justify-content: space-between; align-items: center; margin-bottom: .8rem; }
.cal-h b { font: 600 1.4rem var(--serif); }
.cal-g { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; font-size: .9rem; }
.cal-g span { padding: .55rem 0; }
.cal-g .dow { font: 600 .7rem var(--sans); letter-spacing: .1em; color: var(--gold-text); }
.cal-g .today { background: var(--burgundy); color: #fff; }
.pager { display: flex; gap: .6rem; align-items: center; justify-content: center; margin-top: 1.5rem; }

/* Forms */
.form { display: grid; gap: 1.1rem; background: var(--surface); border: 1px solid var(--gold); padding: clamp(1.2rem, 3vw, 2rem); }
.row2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 1.1rem; }
.field { display: grid; gap: .4rem; min-width: 0; }
label, .lbl { font: 600 .9rem var(--sans); color: var(--ink); }
.opt { font-weight: 400; color: var(--ink-soft); }
input, select, textarea { width: 100%; font: 400 1rem var(--sans); color: var(--ink); background: var(--bg); border: 1px solid #9C927E; padding: .75rem .85rem; min-height: 46px; border-radius: 2px; }
textarea { min-height: 150px; resize: vertical; }
input[aria-invalid="true"], select[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: #B3261E; border-width: 2px; }
.err { color: #B3261E; font-size: .88rem; min-height: 1.1em; }
:root[data-theme="dark"] .err { color: #FF9A92; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .err { color: #FF9A92; } }
.check { display: flex; gap: .7rem; align-items: flex-start; font-weight: 400; }
.check input { width: 22px; min-height: 22px; margin-top: .2rem; flex: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.status { border: 1px solid var(--gold); background: var(--chip-bg); padding: 1.1rem 1.2rem; display: grid; gap: .7rem; }
.status[hidden] { display: none; }
.status pre { white-space: pre-wrap; font: .9rem/1.6 var(--sans); margin: 0; background: var(--bg); border: 1px solid var(--line); padding: .8rem; }

/* Footer */
.site-footer { background: #171717; color: #D9D0BE; border-top: 2px solid var(--gold); }
.ft { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 2.5rem; padding-block: 3.2rem 2.4rem; }
@media (max-width: 900px) { .ft { grid-template-columns: 1fr 1fr; } .ft > :first-child { grid-column: 1 / -1; } }
@media (max-width: 520px) { .ft { grid-template-columns: 1fr; } }
.site-footer h4 { font: 600 .78rem var(--sans); letter-spacing: .18em; text-transform: uppercase; color: #E2BE6B; margin-bottom: 1rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; }
.site-footer a { color: #E6DCC7; text-decoration: none; }
.site-footer a:hover { color: #F2D07F; text-decoration: underline; }
.ft-brand { display: grid; gap: 1rem; align-content: start; }
.ft-brand img.logo { width: 92px; height: 92px; border-radius: 50%; background: #fff; border: 2px solid var(--gold); }
.ft-brand p { font-size: .98rem; color: #CFC5B1; }
.ft-base { border-top: 1px solid #3a3329; padding-block: 1.3rem 1.8rem; display: flex; flex-wrap: wrap; gap: .6rem 2rem; justify-content: space-between; font-size: .88rem; color: #B7AD99; }
.totop { position: fixed; right: 1rem; bottom: calc(1rem + env(safe-area-inset-bottom, 0px)); z-index: 40; width: 46px; height: 46px; background: var(--burgundy); color: #fff; border: 1px solid var(--gold); cursor: pointer; font-size: 1.2rem; display: none; }
.totop.show { display: block; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

/* Home specifics */
.home-hero .hero-in { max-width: none; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(240px, .55fr); gap: 3rem; align-items: end; padding-block: 3.5rem; min-height: 0; }
.home-hero .intro { display: grid; gap: 1.1rem; align-content: end; }
.home-hero .kicker { display: flex; align-items: center; gap: 1rem; }
.home-hero .kicker img { width: 84px; height: 84px; border-radius: 50%; background: #fff; border: 2px solid var(--gold); }
.home-hero h1 { font-size: clamp(2.6rem, 7vw, 5.2rem); }
.home-hero h1 em { display: block; font-style: normal; font-size: .46em; letter-spacing: .38em; font-weight: 500; color: #F2D07F; margin-bottom: .3rem; text-transform: uppercase; }
.home-hero .under { font: 500 .8rem var(--sans); letter-spacing: .2em; text-transform: uppercase; color: #F2D9A0; }
.home-hero .under b { display: block; font: 600 1.5rem var(--serif); letter-spacing: .06em; color: #fff; margin: .2rem 0; }
.portrait-card { justify-self: end; width: min(100%, 340px); }
.portrait-card .frame { background: #171717; }
.portrait-card img { aspect-ratio: 3 / 4; object-position: top; }
@media (max-width: 860px) { .home-hero .hero-in { grid-template-columns: 1fr; } .portrait-card { justify-self: start; width: min(100%, 300px); } }
.statband { background: var(--burgundy); color: #fff; padding-block: 2.4rem; text-align: center; background-image: var(--pattern-faint); }
.statband p { margin-inline: auto; font: italic 500 clamp(1.3rem, 2.8vw, 1.9rem)/1.4 var(--serif); max-width: 40ch; }
.transition { position: relative; display: grid; grid-template-columns: 1fr 1fr; min-height: 280px; background: #171717; }
.transition figure { margin: 0; position: relative; overflow: hidden; }
.transition img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }
.transition figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 1.4rem; background: linear-gradient(0deg, rgba(0,0,0,.8), transparent); color: #fff; font: 600 1.3rem var(--serif); letter-spacing: .08em; text-transform: uppercase; }
@media (max-width: 600px) { .transition { grid-template-columns: 1fr; } .transition figure { min-height: 220px; } }
.legal h2 { font-size: 1.7rem; margin-top: 2.6rem; }
.legal h2:first-child { margin-top: 0; }
.legal p, .legal li { color: var(--ink-soft); }
.legal ul { padding-left: 1.2rem; display: grid; gap: .4rem; }
details.acc { background: var(--surface); border: 1px solid var(--line); }
details.acc + details.acc { margin-top: .6rem; }
details.acc summary { cursor: pointer; padding: 1rem 1.2rem; font: 600 1.2rem var(--serif); color: var(--ink); }
details.acc > div { padding: 0 1.2rem 1.2rem; color: var(--ink-soft); display: grid; gap: .7rem; }
.theme-note { font-size: .8rem; }


/* ---------- WordPress additions ---------- */
.screen-reader-text { border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute !important; width: 1px; word-wrap: normal !important; }
.screen-reader-text:focus { background: var(--gold); clip: auto !important; clip-path: none; color: #171717; display: block; height: auto; left: 1rem; padding: .8rem 1.2rem; top: 1rem; width: auto; z-index: 100000; }
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .site-header { top: 0; } }
.brand img { object-fit: contain; }
.hero h1 { overflow-wrap: anywhere; }
.slot-tag { z-index: 2; }
.events-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 2.5rem; align-items: start; }
@media (max-width: 860px) { .events-grid { grid-template-columns: 1fr; } }
a.pill { text-decoration: none; display: inline-flex; align-items: center; }
a.pill[aria-pressed="true"] { background: var(--burgundy); border-color: var(--burgundy); color: #fff; }
.cal-g a, .cal-g .has-ev { background: var(--chip-bg); color: var(--ink); font-weight: 600; text-decoration: none; border: 1px solid var(--gold); }
.cal-g .has-ev:hover { background: var(--gold); color: #171717; }
.cta-band { background: var(--burgundy); color: #fff; background-image: var(--pattern-faint); }
.cta-band .wrap { text-align: center; display: grid; justify-items: center; gap: 1.4rem; }
.cta-band h2 { color: #fff; max-width: 20ch; }
.cta-band p { color: #F0E6D0; text-align: center; }
.cta-band .btn-row { justify-content: center; }
.status.ok { border-color: #1E6B3A; background: #E7F3EB; color: #12361F; }
.status.bad { border-color: #B3261E; background: #FBEAE8; color: #5B1410; }
:root[data-theme="dark"] .status.ok { background: #13281B; color: #CFEAD7; }
:root[data-theme="dark"] .status.bad { background: #301412; color: #FFD3CF; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .status.ok { background: #13281B; color: #CFEAD7; } :root:not([data-theme="light"]) .status.bad { background: #301412; color: #FFD3CF; } }
.status:focus { outline: 3px solid var(--focus); outline-offset: 3px; }
.proj .chips { display: flex; gap: .5rem; flex-wrap: wrap; }
.proj[hidden], .gal-item[hidden] { display: none; }
.facts-mini { margin: .4rem 0 0; display: grid; grid-template-columns: 120px minmax(0, 1fr); border: 1px solid var(--line); }
.facts-mini dt, .facts-mini dd { margin: 0; padding: .55rem .8rem; border-bottom: 1px solid var(--line); font-size: .92rem; }
.facts-mini dt { font: 600 .7rem/1.6 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--gold-text); background: var(--surface-2); }
.news-card .news-img img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; }
.news-card h3 a { color: var(--ink); text-decoration: none; }
.news-card h3 a:hover { color: var(--accent); text-decoration: underline; }
.gal figure { margin: 0; }
.entry { display: grid; gap: 1.2rem; }
.entry > * { max-width: 68ch; }
.entry img { height: auto; }
.entry .wp-block-image, .entry figure { margin: 0; }
.entry h2, .entry h3 { margin-top: 1.4rem; }
.entry ul, .entry ol { padding-left: 1.3rem; display: grid; gap: .4rem; }
.entry-meta { color: var(--ink-soft); font-size: .92rem; }
.attach { display: inline-flex; gap: .6rem; align-items: center; }
.pagination, .nav-links { display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; margin-top: 2rem; }
.page-numbers { border: 1px solid var(--gold); padding: .55rem .9rem; text-decoration: none; background: var(--surface); color: var(--ink); min-width: 44px; text-align: center; }
.page-numbers.current { background: var(--burgundy); color: #fff; border-color: var(--burgundy); }
.search-form { display: flex; gap: .6rem; flex-wrap: wrap; margin-bottom: 1.4rem; }
.search-form input[type="search"] { flex: 1 1 260px; }
.hero.has-img .hero-pat { opacity: .35; }
.not-found { text-align: center; display: grid; justify-items: center; gap: 1.2rem; }
.sr-only-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.social { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: .4rem; }
.site-footer .social a { text-decoration: underline; }
.proj-ph { margin: 0; }
.wp-block-html { max-width: none; }
.entry-content > .wp-block-html { display: block; }

/* ======================================================================
   Version 1.1: modern, simple and calm.
   Fewer ornaments, more white space, softer surfaces. Royal colours stay.
   ====================================================================== */
:root {
  --radius: 10px;
  --shadow: 0 1px 2px rgba(23, 23, 23, .05), 0 8px 24px rgba(23, 23, 23, .06);
  --shadow-hover: 0 2px 4px rgba(23, 23, 23, .06), 0 14px 32px rgba(23, 23, 23, .10);
  --line: #E6DFD0;
}
:root[data-theme="dark"] { --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35); --line: #332D24; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35); --line: #332D24; } }

body { font-size: 1.0625rem; line-height: 1.75; }
h1, h2, h3, h4 { letter-spacing: 0; }
h2 { font-weight: 600; font-size: clamp(1.9rem, 3.6vw, 2.6rem); }
.eyebrow { font-size: .72rem; letter-spacing: .22em; color: var(--accent); }
.lead { font-size: 1.2rem; }
section.block { padding-block: clamp(3.5rem, 8vw, 6.5rem); }
.sec-head { margin-bottom: 2.8rem; gap: .9rem; }
.sec-head p { max-width: 62ch; }

/* remove ornament */
section.alt, .statband, .cta-band { background-image: none; }
section.alt { background: var(--surface-2); }
.hero-pat, .hero .gold-edge, .band, .rule { display: none; }
.node.praise::after { display: none; }
.frame::after { display: none; }

/* header: flat and quiet */
.site-header { background: #171717; border-bottom: 1px solid rgba(196, 154, 67, .55); }
.hdr { min-height: 68px; }
.brand span { font-size: 1.1rem; letter-spacing: .03em; }
.brand img { border: 0; width: 46px; height: 46px; }
.nav a, .nav button.dd-btn { font-size: .86rem; border-bottom-width: 1px; }
.nav .nav-contact { border-radius: 999px; padding: .65rem 1.15rem; }
.dd-menu { border: 1px solid #2d2d2d; border-radius: var(--radius); box-shadow: var(--shadow-hover); padding: .5rem; }

/* hero: one calm gradient, less height */
.hero::before { background: linear-gradient(120deg, #4d0c15 0%, #7D101C 55%, #5b0e18 100%); }
.hero::after { background: linear-gradient(90deg, rgba(15,12,10,.55) 0%, rgba(15,12,10,.25) 70%, rgba(15,12,10,.1) 100%); }
.hero-in { min-height: clamp(300px, 30vw, 380px); padding-block: 3rem 3rem; }
.hero h1 { font-weight: 600; font-size: clamp(2rem, 4.6vw, 3.4rem); }
.hero p.sub { font-size: clamp(1.02rem, 1.8vw, 1.2rem); opacity: .92; }
.home-hero .hero-in { padding-block: 4rem; }
.home-hero h1 { font-size: clamp(2.6rem, 6.4vw, 4.6rem); }
.crumbs { font-size: .8rem; opacity: .85; }
.slot-tag { border-style: solid; border-color: rgba(255,255,255,.25); border-radius: 999px; }

/* buttons: pill, no heavy outlines */
.btn { border-radius: 999px; border-width: 1px; padding: .75rem 1.5rem; min-height: 46px; font-size: .92rem; letter-spacing: .01em; }
.btn-line { border-color: var(--line); }
.hero .btn-line, .on-dark .btn-line { border-color: rgba(255,255,255,.5); }
.btn-line:hover { border-color: var(--gold); }

/* cards and panels: white tiles, soft shadow, no gold boxes */
.card, .card.gold, .names li, .seg, details.acc, .cal, .evt, .status, .form, .empty { border: 1px solid var(--line); border-radius: var(--radius); }
.card, .card.gold { box-shadow: none; padding: 1.75rem; background: var(--surface); }
a.card, .card:hover { box-shadow: var(--shadow); }
.card.gold { border-color: var(--line); }
.empty { border-style: solid; box-shadow: none; }
.form { box-shadow: var(--shadow); border-color: var(--line); }
input, select, textarea { border-radius: 8px; border-color: #CFC6B2; }
.note { border: 0; border-left: 3px solid var(--gold); border-radius: 0 var(--radius) var(--radius) 0; background: var(--chip-bg); }
.chip { border: 0; border-radius: 999px; padding: .4rem .75rem; }

/* images: clean rounded, no double frame */
.frame { padding: 0; border: 0; background: none; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.frame img { display: block; }
.portrait-card .frame { background: #171717; }
.gal button { border: 0; border-radius: var(--radius); padding: 0; overflow: hidden; background: var(--surface); box-shadow: var(--shadow); }
.gal img { border-radius: 0; }

/* pillars and mini-pillars */
.pillar { border-top: 1px solid var(--line); padding-block: 2.4rem; }
.pillar .ico { border: 0; border-radius: 50%; background: var(--chip-bg); width: 68px; height: 68px; color: var(--accent); }
.mini-pillars { gap: 1rem; background: none; border: 0; }
.mini-pillars a { border: 1px solid var(--line); border-radius: var(--radius); }
.mini-pillars a:hover { box-shadow: var(--shadow); background: var(--surface); }

/* lists, timeline, facts */
.facts { border-radius: var(--radius); overflow: hidden; border-color: var(--line); }
.facts dt { background: var(--surface-2); }
.timeline::before { background: var(--line); }
.timeline li::before { border-radius: 50%; transform: none; width: 13px; height: 13px; left: 5px; background: var(--gold); border: 0; }
.names li { background: var(--surface); }
.node { border-radius: var(--radius); border-color: var(--line); }
.node:hover, .node[aria-expanded="true"] { border-color: var(--gold); }
.node.final { border-radius: var(--radius); }
.chain li + li::before { background: var(--line); }
.seg > button { background: var(--surface); border-radius: var(--radius); }
.panel { border-radius: 0 0 var(--radius) var(--radius); }
.pill { border-color: var(--line); background: var(--surface); }
.pill[aria-pressed="true"] { background: var(--burgundy); border-color: var(--burgundy); }
.statband { padding-block: 3.2rem; }
.cta-band { background: var(--charcoal); }
.cta-band h2 { max-width: 22ch; }
.cal-g .today { border-radius: 50%; }
.evt .d { border: 0; background: var(--chip-bg); border-radius: var(--radius); }

/* footer: simple, logo only */
.site-footer { border-top: 1px solid rgba(196, 154, 67, .45); }
.ft { padding-block: 3.5rem 2.2rem; }
.ft-brand img.logo { border: 0; width: 72px; height: 72px; }
.totop { border-radius: 50%; border: 0; box-shadow: var(--shadow-hover); }

/* contact details and salutation */
.salutation { font: italic 600 1.35rem/1.3 var(--serif); color: var(--accent); margin-top: 1rem; max-width: none; }
.site-footer .salutation { color: #E2BE6B; margin-top: 1.1rem; }
.facts a { font-weight: 500; }
.site-footer li a[href^="tel:"], .site-footer li a[href^="mailto:"] { color: #F3ECDD; }
