/* ADRGP v1 — pan-African institutional design system
   Palette: deep navy, Atlantic teal, brass gold, warm cream.
   Accessibility modes are driven by data attributes on <html>. */

:root {
  --navy: #08243d;
  --deep: #051b2b;
  --teal: #0b827d;
  --teal-dark: #06605c;
  --aqua: #42c4b8;
  --cream: #faf8f1;
  --paper: #ffffff;
  --sand: #f1ecdf;
  --gold: #c8a24a;
  --gold-soft: #efdfb6;
  --terracotta: #b4552d;
  --ink: #12232e;
  --muted: #5b6b75;
  --line: #dbe4e6;
  --danger: #a3271f;
  --success: #17603f;
  --info: #0b5377;
  --focus: #ffd45a;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 18px 50px rgba(5, 27, 43, 0.10);
  --shadow-sm: 0 6px 18px rgba(5, 27, 43, 0.07);
  --font-body: "Atkinson Hyperlegible", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --max: 1180px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; }
a { color: var(--teal-dark); text-underline-offset: 3px; }
a:hover { color: var(--navy); }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.15; color: var(--navy); margin: 0 0 .6rem; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.1rem, 4.6vw, 3.6rem); }
h2 { font-size: clamp(1.45rem, 2.6vw, 2.1rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1rem; }
ul, ol { padding-left: 1.3rem; }
code { background: var(--sand); padding: .1rem .35rem; border-radius: 4px; font-size: .92em; word-break: break-word; }
hr { border: 0; border-top: 1px solid var(--line); margin: 1.4rem 0; }

.shell { width: min(var(--max), calc(100% - 2.5rem)); margin-inline: auto; }
.muted { color: var(--muted); }
.small { font-size: .86rem; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  box-shadow: 0 0 0 6px rgba(8, 36, 61, .35);
}

.skip-link {
  position: absolute; left: 1rem; top: -100px; z-index: 1000;
  background: var(--navy); color: #fff; padding: .75rem 1.1rem; border-radius: 0 0 8px 8px;
  font-weight: 700; text-decoration: none;
}
.skip-link:focus { top: 0; color: #fff; }

/* ------------------------------------------------------------- header */

.flag-strip { display: grid; grid-template-columns: repeat(4, 1fr); height: 6px; }
.flag-strip span:nth-child(1) { background: var(--gold); }
.flag-strip span:nth-child(2) { background: var(--teal); }
.flag-strip span:nth-child(3) { background: var(--terracotta); }
.flag-strip span:nth-child(4) { background: var(--navy); }

.site-header { background: rgba(250, 248, 241, .96); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 60; backdrop-filter: saturate(140%) blur(8px); }
.header-bar { display: flex; align-items: center; gap: 1.25rem; min-height: 76px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: .75rem; text-decoration: none; color: var(--navy); }
.brand-mark {
  width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px;
  background: linear-gradient(145deg, var(--navy), var(--teal));
  color: #fff; font-family: var(--font-display); font-size: 1.5rem; font-weight: 700;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.18);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 1.12rem; letter-spacing: .08em; }
.brand-text small { color: var(--muted); font-size: .72rem; letter-spacing: .02em; }
.header-tools { margin-left: auto; display: flex; align-items: center; gap: .5rem; }
.primary-nav { display: flex; align-items: center; gap: .15rem; flex-wrap: wrap; order: 3; width: 100%; }
.primary-nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: .92rem; padding: .55rem .62rem; border-radius: 8px; }
.primary-nav a:hover { background: var(--sand); color: var(--navy); }
.primary-nav .nav-join { background: var(--navy); color: #fff; margin-left: auto; padding-inline: 1rem; }
.primary-nav .nav-join:hover { background: var(--teal-dark); color: #fff; }

.a11y-open, .menu-toggle {
  display: inline-flex; align-items: center; gap: .4rem; background: transparent;
  border: 1px solid var(--line); color: var(--navy); border-radius: 8px; padding: .5rem .7rem;
  font: inherit; font-size: .86rem; font-weight: 700; cursor: pointer;
}
.a11y-open:hover, .menu-toggle:hover { background: var(--sand); }
.menu-toggle { display: none; }
.menu-bars { width: 16px; height: 2px; background: var(--navy); position: relative; display: inline-block; }
.menu-bars::before, .menu-bars::after { content: ""; position: absolute; left: 0; width: 16px; height: 2px; background: var(--navy); }
.menu-bars::before { top: -5px; }
.menu-bars::after { top: 5px; }

.a11y-panel { background: var(--deep); color: #eef4f4; border-bottom: 1px solid rgba(255,255,255,.1); }
.a11y-panel .shell { padding-block: 1.1rem 1.3rem; }
.a11y-panel .eyebrow { color: var(--gold-soft); }
.a11y-groups { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.a11y-groups fieldset { border: 1px solid rgba(255,255,255,.18); border-radius: var(--radius-sm); padding: .7rem; margin: 0; }
.a11y-groups legend { padding: 0 .35rem; font-size: .8rem; letter-spacing: .04em; text-transform: uppercase; color: #cfe2e2; }
.a11y-groups button {
  background: rgba(255,255,255,.06); color: #fff; border: 1px solid rgba(255,255,255,.2);
  border-radius: 6px; padding: .4rem .55rem; margin: .15rem .15rem 0 0; font: inherit; font-size: .82rem; cursor: pointer;
}
.a11y-groups button[aria-pressed="true"] { background: var(--gold); color: var(--deep); border-color: var(--gold); font-weight: 700; }
.a11y-help { margin: .9rem 0 0; font-size: .86rem; color: #cfe2e2; }
.a11y-help a { color: #fff; }

/* ---------------------------------------------------------------- common */

.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: .74rem; font-weight: 800; color: var(--teal-dark); margin: 0 0 .7rem; }
.lead { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: #2c4250; max-width: 62ch; }
.actions { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: 1.4rem; }
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  background: var(--navy); color: #fff; border: 2px solid var(--navy); border-radius: 10px;
  padding: .78rem 1.25rem; font: inherit; font-weight: 700; text-decoration: none; cursor: pointer;
  transition: transform .15s ease, background .15s ease, color .15s ease;
}
.button:hover { background: var(--teal-dark); border-color: var(--teal-dark); color: #fff; transform: translateY(-1px); }
.button.ghost { background: transparent; color: var(--navy); border-color: var(--navy); }
.button.ghost:hover { background: var(--sand); color: var(--navy); }
.button.ghost-light { background: rgba(255,255,255,.08); color: #fff; border-color: rgba(255,255,255,.55); }
.button.ghost-light:hover { background: rgba(255,255,255,.18); color: #fff; }
.text-link { font-weight: 700; text-decoration: none; border-bottom: 2px solid var(--gold); padding-bottom: 2px; }
.text-link:hover { border-color: var(--teal); }
.inline-button { background: none; border: 0; padding: 0; font: inherit; color: var(--teal-dark); text-decoration: underline; cursor: pointer; }
.link-button { background: none; border: 0; padding: 0; font: inherit; color: var(--teal-dark); text-decoration: underline; cursor: pointer; font-weight: 600; }
.inline-form-sm { display: inline; margin: 0; }

.alert { border-radius: var(--radius-sm); padding: .95rem 1.1rem; margin: 1rem 0; border: 1px solid; }
.alert p:last-child, .alert ul:last-child { margin-bottom: 0; }
.alert-error { background: #fdeceb; border-color: #e7b4ae; color: var(--danger); }
.alert-success { background: #e8f5ee; border-color: #a9d5bc; color: var(--success); }
.alert-info { background: #eaf3f7; border-color: #b7d3e0; color: var(--info); }
.alert ul { margin: .4rem 0 0; }

.hero { background: radial-gradient(1200px 500px at 85% 0%, rgba(66,196,184,.22), transparent 60%), linear-gradient(135deg, var(--deep), var(--navy) 55%, #0a3a4a); color: #eaf2f2; padding: clamp(3rem, 7vw, 5.5rem) 0; position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: auto -10% -45% 55%; height: 380px; border-radius: 50%; background: radial-gradient(circle, rgba(200,162,74,.20), transparent 65%); pointer-events: none; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr); gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; }
.hero h1 { color: #fff; }
.hero .lead { color: #cfe3e6; }
.hero .eyebrow { color: var(--gold-soft); }
.hero-stats { display: flex; gap: 2rem; flex-wrap: wrap; margin: 2rem 0 0; padding: 0; border-top: 1px solid rgba(255,255,255,.18); padding-top: 1.3rem; }
.hero-stats div { display: flex; flex-direction: column-reverse; gap: .15rem; }
.hero-stats dt { font-size: .8rem; color: #b9d2d6; }
.hero-stats dd { margin: 0; font-family: var(--font-display); font-size: 2rem; color: var(--gold-soft); }
.hero-panel { background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.18); border-radius: var(--radius); padding: clamp(1.4rem, 3vw, 2rem); backdrop-filter: blur(6px); }
.hero-panel h2 { color: #fff; font-size: 1.35rem; }
.hero-note { font-size: .86rem; color: #b9d2d6; margin-top: 1rem; }
.check-list { list-style: none; padding: 0; margin: 0; }
.check-list li { position: relative; padding-left: 1.6rem; margin-bottom: .55rem; }
.check-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--teal); font-weight: 800; }
.hero-panel .check-list li::before { color: var(--gold); }

.section { padding-block: clamp(2.5rem, 6vw, 4.5rem); }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; margin-bottom: 1.6rem; flex-wrap: wrap; }
.section-head h2 { margin-bottom: 0; }
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.1rem; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.2rem, 2.4vw, 1.7rem); box-shadow: var(--shadow-sm); }
.card h2, .card h3 { margin-top: 0; }
.card p:last-child { margin-bottom: 0; }
.card-icon { display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 10px; background: var(--sand); color: var(--teal-dark); font-size: 1.2rem; margin-bottom: .8rem; }
.article-card .eyebrow { margin-bottom: .4rem; }
.article-card h3 a, .event-card h3 a { text-decoration: none; color: inherit; }
.article-card h3 a:hover, .event-card h3 a:hover { color: var(--teal-dark); text-decoration: underline; }

.search-band { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; }
.inline-form { display: flex; gap: .6rem; flex-wrap: wrap; }
.inline-form input { flex: 1 1 260px; }
.join-band { display: flex; justify-content: space-between; align-items: center; gap: 2rem; background: linear-gradient(120deg, var(--navy), var(--teal-dark)); border-radius: var(--radius); padding: clamp(1.6rem, 4vw, 2.6rem); color: #eaf2f2; flex-wrap: wrap; }
.join-band h2 { color: #fff; }
.join-band .eyebrow { color: var(--gold-soft); }
.join-band p { color: #cfe3e6; margin-bottom: 0; }

.page-head { background: linear-gradient(135deg, var(--deep), var(--navy)); color: #eaf2f2; padding: clamp(2.4rem, 6vw, 4.2rem) 0 clamp(2rem, 5vw, 3.2rem); position: relative; }
.page-head::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: linear-gradient(90deg, var(--gold), var(--teal), var(--terracotta), var(--gold)); }
.page-head h1 { color: #fff; }
.page-head .lead { color: #cfe3e6; }
.page-head .eyebrow { color: var(--gold-soft); }
.page-head.compact { padding-block: 2.2rem; }
.page-body { padding-block: clamp(2rem, 4vw, 3.2rem); }
.prose { max-width: 78ch; }
.prose h2 { margin-top: 1.8rem; }
.prose h2:first-child { margin-top: 0; }
.prose li { margin-bottom: .4rem; }
.prose table { width: 100%; border-collapse: collapse; margin: 1rem 0; }
.prose th, .prose td { text-align: left; padding: .6rem .5rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { color: var(--navy); font-size: .85rem; text-transform: uppercase; letter-spacing: .04em; }
.callout { background: var(--sand); border-left: 5px solid var(--gold); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; padding: 1.2rem 1.4rem; margin: 1.6rem 0; }
.callout h2 { font-size: 1.2rem; margin-top: 0; }
.callout p:last-child { margin-bottom: 0; }
.easy-read p, .easy-read li { font-size: 1.08rem; line-height: 1.85; }

/* ------------------------------------------------------------------ forms */

.form-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(280px, .7fr); gap: 1.6rem; padding-block: clamp(2rem, 4vw, 3rem); align-items: start; }
.form-card { display: flex; flex-direction: column; gap: .9rem; }
.form-card fieldset { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 1rem 1.1rem 1.2rem; margin: 0; }
.form-card legend { padding: 0 .4rem; font-weight: 800; color: var(--navy); }
.form-card fieldset.nested { margin-top: .6rem; }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: .9rem; }
label { display: block; font-weight: 700; font-size: .92rem; color: var(--navy); }
input, select, textarea {
  width: 100%; margin-top: .3rem; padding: .7rem .8rem; border: 1px solid #b9c9cc; border-radius: 8px;
  font: inherit; color: var(--ink); background: #fff;
}
input:focus, select:focus, textarea:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(11,130,125,.18); outline: none; }
textarea { resize: vertical; }
.check { display: flex; align-items: flex-start; gap: .55rem; font-weight: 500; color: var(--ink); line-height: 1.5; }
.check input { width: auto; margin: .28rem 0 0; flex: 0 0 auto; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: .35rem .9rem; margin-top: .4rem; }
.req { color: var(--danger); font-weight: 800; font-size: .78rem; }
.form-note { color: var(--muted); font-size: .86rem; margin: 0; }
.help-card { background: var(--paper); border: 1px solid var(--line); border-top: 6px solid var(--gold); border-radius: var(--radius); padding: 1.4rem; box-shadow: var(--shadow-sm); position: sticky; top: 96px; }
.help-card h2 { font-size: 1.2rem; }
.pathway-note { font-size: .84rem; color: var(--muted); border-top: 1px solid var(--line); padding-top: .8rem; margin-top: 1rem; }
.success-card { border-top: 6px solid var(--teal); }

.filter-bar { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)) auto; gap: .8rem; align-items: end; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.2rem; margin-bottom: 1.5rem; }
.filter-bar .button { align-self: end; }
.result-count { grid-column: 1 / -1; margin: 0; color: var(--muted); font-size: .9rem; }

/* ------------------------------------------------------------- directory */

.person-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; margin-bottom: 2rem; }
.person-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.2rem; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: .7rem; }
.person-head { display: flex; gap: .85rem; align-items: center; }
.person-head h2 { font-size: 1.15rem; margin: 0; }
.person-head h2 a { text-decoration: none; color: var(--navy); }
.person-head p { margin: .1rem 0 0; font-size: .9rem; }
.avatar { flex: 0 0 48px; width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(145deg, var(--teal), var(--navy)); color: #fff; font-family: var(--font-display); font-size: 1.3rem; }
.tag-list { list-style: none; display: flex; flex-wrap: wrap; gap: .35rem; padding: 0; margin: 0; }
.tag-list li { background: var(--sand); border-radius: 999px; padding: .2rem .65rem; font-size: .8rem; color: #3b4f59; }
.verified { margin: auto 0 0; font-size: .84rem; color: var(--success); font-weight: 700; }
.empty-state { background: var(--paper); border: 1px dashed #b9c9cc; border-radius: var(--radius); padding: 2rem; text-align: center; }
.profile-meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: .8rem; margin: 1.4rem 0 2rem; }
.profile-meta div { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: .8rem 1rem; }
.profile-meta span { display: block; font-size: .76rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }
.profile-meta strong { color: var(--navy); }

/* ----------------------------------------------------------------- events */

.event-list { display: grid; gap: .9rem; margin-bottom: 2rem; }
.event-row { display: flex; gap: 1.1rem; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.3rem; box-shadow: var(--shadow-sm); align-items: flex-start; }
.event-date { flex: 0 0 64px; text-align: center; background: var(--navy); color: #fff; border-radius: 10px; padding: .55rem .3rem; }
.event-date span { display: block; text-transform: uppercase; font-size: .72rem; letter-spacing: .1em; color: var(--gold-soft); }
.event-date strong { display: block; font-family: var(--font-display); font-size: 1.6rem; line-height: 1.1; }
.event-row h3, .event-card h3 { margin: .1rem 0 .35rem; }
.event-row .eyebrow, .event-card .eyebrow { margin-bottom: .2rem; }
.event-layout, .article-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(280px, .7fr); gap: 2rem; padding-block: clamp(2rem, 4vw, 3rem); align-items: start; }
.event-facts { background: var(--paper); border: 1px solid var(--line); border-top: 6px solid var(--teal); border-radius: var(--radius); padding: 1.4rem; box-shadow: var(--shadow-sm); position: sticky; top: 96px; }
.event-facts dl { margin: 0 0 1.1rem; }
.event-facts dl div { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--line); }
.event-facts dt { font-weight: 700; color: var(--muted); font-size: .88rem; }
.event-facts dd { margin: 0; text-align: right; font-weight: 600; }
.byline { color: var(--muted); font-size: .9rem; }
.article-head .byline { color: #cfe3e6; }
.easy-read-box { background: #eef7f5; border-left: 5px solid var(--teal); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; padding: 1.1rem 1.3rem; margin-bottom: 1.8rem; }
.easy-read-box h2 { margin-top: 0; font-size: 1.15rem; }
.article-actions { margin-top: 2rem; }
.pager { display: flex; gap: .4rem; margin-top: 2rem; flex-wrap: wrap; }
.pager a { display: inline-block; min-width: 42px; text-align: center; padding: .5rem .7rem; border: 1px solid var(--line); border-radius: 8px; text-decoration: none; color: var(--navy); background: var(--paper); }
.pager a[aria-current="page"] { background: var(--navy); color: #fff; border-color: var(--navy); }

/* ------------------------------------------------------------------ pricing */

.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 1.1rem; margin: 1.6rem 0 2.4rem; align-items: stretch; }
.price-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; position: relative; }
.price-card.featured { border: 2px solid var(--gold); box-shadow: var(--shadow); }
.price-card h2 { font-size: 1.3rem; }
.ribbon { position: absolute; top: -13px; left: 1.4rem; background: var(--gold); color: var(--deep); font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; padding: .25rem .7rem; border-radius: 999px; margin: 0; }
.price { margin: .4rem 0 0; display: flex; align-items: baseline; gap: .4rem; }
.price span { font-family: var(--font-display); font-size: 1.9rem; color: var(--navy); font-weight: 700; }
.price small { color: var(--muted); }
.price-alt { color: var(--muted); font-size: .88rem; margin-bottom: .8rem; }
.price-card .check-list { font-size: .92rem; margin: .6rem 0 1.2rem; }
.price-card .button { margin-top: auto; }
.narrow { max-width: 620px; padding-block: 2.4rem 3.4rem; }

/* ------------------------------------------------------------------- admin */

.admin-shell { background: #f3f6f6; min-height: 100vh; }
.admin-shell.light { background: var(--cream); }
.admin-bar { background: var(--deep); color: #dbe7e7; }
.admin-bar-inner { display: flex; align-items: center; gap: 1.4rem; flex-wrap: wrap; padding-block: .8rem; }
.admin-brand { color: #fff; text-decoration: none; font-weight: 800; letter-spacing: .08em; }
.admin-brand span { color: var(--gold-soft); font-weight: 500; letter-spacing: .02em; }
.admin-bar nav { display: flex; gap: .2rem; flex-wrap: wrap; }
.admin-bar nav a { color: #cfe0e0; text-decoration: none; font-size: .88rem; padding: .45rem .6rem; border-radius: 6px; }
.admin-bar nav a:hover, .admin-bar nav a[aria-current="page"] { background: rgba(255,255,255,.12); color: #fff; }
.admin-user { margin-left: auto; display: flex; gap: .9rem; align-items: center; font-size: .84rem; flex-wrap: wrap; }
.admin-user a { color: var(--gold-soft); }
.admin-body { padding-block: 1.6rem 3rem; }
.admin-title { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-bottom: 1.2rem; flex-wrap: wrap; }
.admin-title h1 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin: 0; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; margin-bottom: 1.4rem; }
.stat { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.2rem; border-top: 5px solid var(--teal); }
.stat span { display: block; color: var(--muted); font-size: .84rem; text-transform: uppercase; letter-spacing: .05em; }
.stat strong { display: block; font-family: var(--font-display); font-size: 2.2rem; color: var(--navy); line-height: 1.2; }
.stat a { font-size: .88rem; font-weight: 700; }
.admin-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.admin-table caption { text-align: left; }
.admin-table th, .admin-table td { text-align: left; padding: .65rem .55rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.admin-table th { font-size: .76rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.admin-table tr:hover td { background: #f8faf9; }
.status { display: inline-block; padding: .12rem .55rem; border-radius: 999px; font-size: .76rem; font-weight: 700; background: var(--sand); color: #40535d; }
.status-approved, .status-active, .status-published, .status-handled { background: #e2f2e9; color: var(--success); }
.status-submitted, .status-under_review, .status-received { background: #fff3d8; color: #7a5a13; }
.status-rejected, .status-suspended { background: #fbe6e4; color: var(--danger); }
.status-draft, .status-pending { background: #e8eef1; color: #40535d; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(280px, .7fr); gap: 1.2rem; align-items: start; }
.detail-list { margin: 0 0 1.4rem; }
.detail-list div { display: grid; grid-template-columns: 150px 1fr; gap: 1rem; padding: .5rem 0; border-bottom: 1px solid var(--line); }
.detail-list dt { font-weight: 700; color: var(--muted); font-size: .86rem; }
.detail-list dd { margin: 0; }
.admin-body .card + .card { margin-top: 1.2rem; }

/* ------------------------------------------------------------------ footer */

.site-footer { background: var(--deep); color: #b9cdd2; margin-top: 3rem; border-top: 5px solid var(--gold); }
.footer-grid { display: grid; grid-template-columns: 1.5fr repeat(4, 1fr); gap: 2rem; padding-block: 3rem 2rem; }
.footer-grid h2 { color: #fff; font-size: .95rem; text-transform: uppercase; letter-spacing: .08em; font-family: var(--font-body); }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: .4rem; }
.footer-grid a { color: #d5e3e5; text-decoration: none; font-size: .9rem; }
.footer-grid a:hover { color: #fff; text-decoration: underline; }
.footer-brand { font-family: var(--font-display); font-size: 1.6rem; color: #fff; letter-spacing: .08em; margin-bottom: .5rem; }
.footer-legal { font-size: .82rem; color: #8fa9ae; }
.subscribe-form { display: flex; gap: .4rem; margin: .6rem 0 1rem; }
.subscribe-form input { margin: 0; padding: .55rem .65rem; font-size: .86rem; }
.subscribe-form .button { padding: .55rem .8rem; font-size: .86rem; }
.footer-bottom { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; border-top: 1px solid rgba(255,255,255,.12); padding-block: 1.2rem; font-size: .8rem; color: #8fa9ae; }
.footer-bottom p { margin: 0; }
.staff-links a { color: #cfe0e0; }

.cookie-banner { position: fixed; inset: auto 1rem 1rem 1rem; z-index: 200; background: var(--paper); border: 1px solid var(--line); border-left: 6px solid var(--gold); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1rem 1.2rem; display: flex; gap: 1rem; align-items: center; justify-content: space-between; flex-wrap: wrap; max-width: 920px; margin-inline: auto; }
.cookie-banner p { margin: .2rem 0 0; font-size: .86rem; color: var(--muted); }
.cookie-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.cookie-actions .button { padding: .6rem .9rem; font-size: .88rem; }

/* ------------------------------------------------- accessibility preferences */

html[data-a11y-size="large"] { font-size: 112.5%; }
html[data-a11y-size="x-large"] { font-size: 125%; }

html[data-a11y-font="dyslexia"] body,
html[data-a11y-font="dyslexia"] input,
html[data-a11y-font="dyslexia"] select,
html[data-a11y-font="dyslexia"] textarea,
html[data-a11y-font="dyslexia"] button {
  font-family: Verdana, Tahoma, "Trebuchet MS", sans-serif !important;
  letter-spacing: .035em;
  word-spacing: .14em;
  line-height: 1.9;
}
html[data-a11y-font="dyslexia"] h1,
html[data-a11y-font="dyslexia"] h2,
html[data-a11y-font="dyslexia"] h3 { font-family: Verdana, Tahoma, "Trebuchet MS", sans-serif; letter-spacing: 0; }

html[data-a11y-contrast="high"] { --cream: #ffffff; --paper: #ffffff; --ink: #000000; --muted: #1f1f1f; --line: #000000; --navy: #000000; --deep: #000000; --teal-dark: #004b47; --teal: #00645f; --gold: #ffcc00; --gold-soft: #ffcc00; --sand: #f4f4f4; --focus: #ffcc00; }
html[data-a11y-contrast="high"] body { background: #fff; color: #000; }
html[data-a11y-contrast="high"] a { color: #004b8d; text-decoration: underline; }
html[data-a11y-contrast="high"] .hero,
html[data-a11y-contrast="high"] .page-head { background: #000; }
html[data-a11y-contrast="high"] .page-head::after,
html[data-a11y-contrast="high"] .flag-strip { display: none; }
html[data-a11y-contrast="high"] .button { border-width: 2px; }
html[data-a11y-contrast="high"] .card,
html[data-a11y-contrast="high"] .person-card,
html[data-a11y-contrast="high"] .event-row { border-width: 2px; }

html[data-a11y-motion="reduced"] { scroll-behavior: auto; }
html[data-a11y-motion="reduced"] *,
html[data-a11y-motion="reduced"] *::before,
html[data-a11y-motion="reduced"] *::after { animation: none !important; transition: none !important; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

@media print {
  .site-header, .site-footer, .cookie-banner, .a11y-panel, .skip-link, .article-actions, .help-card, .event-facts { display: none !important; }
  body { background: #fff; color: #000; font-size: 12pt; }
  .page-head, .hero { background: #fff !important; color: #000 !important; padding: 0 0 1rem; }
  .page-head h1, .hero h1, .page-head .lead, .hero .lead { color: #000 !important; }
  .page-head::after, .hero::after, .flag-strip { display: none; }
  a { color: #000; text-decoration: underline; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 9pt; }
}

/* -------------------------------------------------------------- responsive */

@media (max-width: 1000px) {
  .hero-grid, .form-layout, .event-layout, .article-layout, .detail-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .help-card, .event-facts { position: static; }
  .a11y-groups { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  .menu-toggle { display: inline-flex; }
  .primary-nav { display: none; flex-direction: column; align-items: stretch; gap: .15rem; padding-bottom: .9rem; }
  .primary-nav.open { display: flex; }
  .primary-nav a { padding: .75rem .8rem; border-bottom: 1px solid var(--line); border-radius: 0; }
  .primary-nav .nav-join { margin: .5rem 0 0; text-align: center; border-radius: 8px; }
  .header-bar { min-height: 66px; }
  .brand-text small { display: none; }
  .filter-bar { grid-template-columns: 1fr; }
  .prose table { font-size: .86rem; }
  .detail-list div { grid-template-columns: 1fr; gap: .1rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
}

@media (max-width: 560px) {
  .shell { width: calc(100% - 1.6rem); }
  .hero-stats { gap: 1.2rem; }
  .event-row { flex-direction: column; }
  .event-date { align-self: flex-start; }
  .footer-grid { grid-template-columns: 1fr; }
  .a11y-groups { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; }
  .cookie-banner { inset: auto .5rem .5rem .5rem; }
  .admin-bar-inner { gap: .6rem; }
  .admin-user { margin-left: 0; }
}
