/* =========================================================
   Presidential Portal — shared stylesheet
   Palette grounded in Kenya's national colours.
   Ported from the single-file template into a Laravel asset.
   ========================================================= */

:root {
  --green:        #0f6b40;
  --green-dark:   #0d5c37;
  --green-deep:   #0c3325;
  --red:          #b3261e;
  --ink:          #16180f;
  --cream:        #f7f5ef;
  --cream-2:      #efebe1;
  --sand:         #f3ecd8;
  --paper:        #ffffff;
  --gold:         #ba9e4b;
  --gold-ink:     #6f5a22;
  --gold-soft:    #d2b866;
  --grey:         #676767;
  --grey-soft:    #bbbbbb;
  --muted:        #575a4f;
  --line:         #e0dacb;
  --line-strong:  #8f8a7a;
  --red-dark:     #6d1a1f;

  /* Text, rules and overlays on dark surfaces (greens, photos, scrims) */
  --on-dark:       #ffffff;
  --on-dark-soft:  #f2eee4;
  --on-dark-muted: #e4dfd2;
  --on-gold:       #241b00;
  --scrim:         #0c0a07;
  --scrim-warm:    #1c150e;

  /* Status (tenders, alerts, admin badges) */
  --success-bg:    var(--sand);
  --success-line:  #ddc98f;
  --error-bg:      #f3e3e1;
  --error-line:    #e6c3bf;

  --shadow:       0 1px 2px color-mix(in srgb, var(--ink) 5%, transparent);

  --font-display: "Newsreader", Georgia, "Times New Roman", serif;
  --font-body:    "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono:    "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;

  --wrap: 1180px;
  --gap: clamp(1rem, 2.5vw, 2rem);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 6rem; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--green); }
::placeholder { color: var(--muted); opacity: 1; }

.wrap { width: min(var(--wrap), 92%); margin-inline: auto; }

.skip {
  position: absolute; left: -999px; top: 0; background: var(--ink);
  color: var(--on-dark); padding: .6rem 1rem; z-index: 200;
}
.skip:focus { left: 0; }

/* ---------- national ribbon ---------- */
.ribbon { height: 4px; display: flex; }
.ribbon i { flex: 1; }
.ribbon i:nth-child(1){ background: var(--ink); flex: 1.65; }
.ribbon i:nth-child(2){ background: var(--red); }
.ribbon i:nth-child(3){ background: var(--green); flex: 1.65; }

/* ---------- masthead ---------- */
.masthead {
  background: var(--paper); border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 100;
}
.masthead > .wrap { display: flex; align-items: center; gap: 1.5rem; min-height: 76px; }
.crest { width: 58px; height: 58px; flex: none; object-fit: contain; }
.brand { display: flex; align-items: center; gap: .85rem; flex: none; color: var(--ink); text-decoration: none; }
.brand .crest { width: 46px; height: 46px; }
.brand-text { display: grid; gap: .2rem; padding-left: .85rem; border-left: 1px solid var(--line); line-height: 1.1; }
.brand .name { font-family: var(--font-display); font-size: 1.32rem; font-weight: 500; }
.brand .kicker { font-size: .66rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }

.tools { display: flex; align-items: center; gap: .6rem; }
.tools .btn { padding: .6rem 1rem; }
.searchtoggle {
  display: grid; place-items: center; width: 40px; height: 40px;
  background: none; border: 0; border-radius: 4px; color: var(--ink); cursor: pointer;
}
.searchtoggle:hover, .searchtoggle[aria-expanded="true"] { background: var(--cream-2); }
.searchtoggle .ic { width: 20px; height: 20px; }

.sitesearch { border-top: 1px solid var(--line); padding: .9rem 0; }
.sitesearch[hidden] { display: none; }
.sitesearch .wrap { display: flex; gap: .6rem; }
.sitesearch input {
  flex: 1; min-width: 0; font: inherit; font-size: .95rem; color: var(--ink);
  padding: .6rem .9rem; border: 1px solid var(--line-strong); border-radius: 4px; background: var(--paper);
}

/* ---------- primary nav ---------- */
.mainnav { margin-inline: auto; }
.navlist { list-style: none; display: flex; margin: 0; padding: 0; }
.navlist > li { position: relative; }
.navlist > li > a {
  display: flex; align-items: center; padding: .9rem .75rem;
  color: var(--ink); text-decoration: none; font-weight: 500; font-size: .95rem;
  text-underline-offset: .7rem; text-decoration-thickness: 2px;
}
.navlist > li > a:hover { color: var(--green-dark); text-decoration-line: underline; text-decoration-color: var(--line); }
.navlist > li.current > a { text-decoration-line: underline; text-decoration-color: var(--gold-ink); }

/* The caret sits out of flow so the current-page underline stops at the label. */
.navlist > .has-sub > a { position: relative; padding-right: 1.55rem; }
.has-sub > a::after {
  content: "\25be"; position: absolute; right: .75rem; top: 50%; transform: translateY(-50%);
  font-size: .7rem; color: var(--muted);
}
.submenu {
  position: absolute; left: 0; top: 100%; min-width: 250px;
  background: var(--paper); border: 1px solid var(--line); border-radius: 6px;
  box-shadow: 0 12px 32px color-mix(in srgb, var(--ink) 12%, transparent); list-style: none; margin: 0; padding: .35rem;
  opacity: 0; visibility: hidden; transform: translateY(6px);
  transition: .16s ease; z-index: 120;
}
.has-sub:hover .submenu,
.has-sub:focus-within .submenu { opacity: 1; visibility: visible; transform: none; }
.has-sub.dismissed .submenu { opacity: 0; visibility: hidden; }
.submenu a {
  display: block; padding: .6rem .8rem; color: var(--ink);
  text-decoration: none; font-size: .9rem; border-radius: 4px;
}
.submenu a:hover { background: var(--cream-2); color: var(--green-dark); }

.navtoggle { display: none; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .8rem 1.4rem; border-radius: 4px; font-family: inherit; font-weight: 600; font-size: .92rem;
  text-decoration: none; border: 1px solid transparent; cursor: pointer;
}
.btn .ic { width: 1rem; height: 1rem; }
.btn-gold { background: var(--gold); color: var(--on-gold); }
.btn-gold:hover { background: var(--gold-soft); }
.btn-ghost { border-color: color-mix(in srgb, var(--on-dark) 50%, transparent); color: var(--on-dark); }
.btn-ghost:hover { background: color-mix(in srgb, var(--on-dark) 12%, transparent); }
.btn-green { background: var(--green); color: var(--on-dark); }
.btn-green:hover { background: var(--green-dark); }
.btn-cream { background: var(--cream); color: var(--ink); }
.btn-cream:hover { background: var(--paper); }

/* ---------- generic page header (inner pages) ---------- */
.pagehead {
  background: linear-gradient(120deg, var(--green-dark), var(--green-deep));
  color: var(--on-dark); padding: clamp(2.4rem, 6vw, 4rem) 0;
}
.pagehead .crumbs { font-size: .56rem; font-weight: 300; color: var(--on-dark-muted); letter-spacing: .04em; margin-bottom: .8rem; }
.pagehead .crumbs a { color: var(--on-dark-muted); text-decoration: none; }
.pagehead .crumbs a:hover { text-decoration: underline; }
.pagehead h1 {
  font-family: var(--font-display); font-weight: 600; margin: 0;
  font-size: clamp(1.8rem, 4.5vw, 3rem); line-height: 1.08;
}
.pagehead p { color: var(--on-dark-muted); max-width: 60ch; margin: .8rem 0 0; }

/* ---------- sections ---------- */
section { padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.section-alt { background: var(--cream-2); }

.eyebrow {
  font-size: .76rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold-ink); font-weight: 600;
}
h2.title {
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(1.75rem, 3.6vw, 2.6rem); line-height: 1.1;
  margin: .4rem 0 0;
}
.lead { color: var(--muted); max-width: 62ch; font-size: 1.05rem; }

.head-row { display: flex; align-items: end; justify-content: space-between; gap: 1rem 2rem; margin-bottom: 2rem; flex-wrap: wrap; }
.head-row > :first-child { flex: 1 1 20rem; }
.head-note { flex: 0 1 24rem; margin: 0; color: var(--muted); font-size: .98rem; }
.head-links { display: flex; gap: .5rem 1.5rem; flex-wrap: wrap; }
.arrow-link {
  display: inline-flex; align-items: center; gap: .35rem;
  font-weight: 600; font-size: .92rem; color: var(--green-dark); text-decoration: none;
}
.arrow-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.arrow-link .ic { width: 1rem; height: 1rem; }

/* ---------- news / card grid ---------- */
.grid { display: grid; gap: 1.4rem; }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: 8px;
  overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column;
  transition: transform .18s ease, box-shadow .18s ease;
}
.card:hover { transform: translateY(-2px); box-shadow: 0 10px 28px color-mix(in srgb, var(--ink) 8%, transparent); }
.card .thumb {
  aspect-ratio: 3 / 2; background: linear-gradient(135deg, var(--green-dark), var(--green-deep));
  position: relative; display: grid; place-items: center; color: var(--on-dark); overflow: hidden;
}
.card .thumb > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card .thumb .ic { width: 44px; height: 44px; opacity: .8; }
.card .thumb .crest { width: 46px; height: 46px; opacity: .8; }
.card .body { padding: 1.4rem 1.5rem 1.5rem; display: flex; flex-direction: column; gap: .55rem; flex: 1; }
.card .date { font-family: var(--font-mono); font-size: .74rem; color: var(--muted); letter-spacing: .02em; text-transform: uppercase; }
.card .body > .date:last-child { margin-top: auto; padding-top: .35rem; }
.card h3 { font-family: var(--font-display); font-weight: 400; font-size: 1.3rem; line-height: 1.25; margin: 0; }
.card h3 a { color: var(--ink); text-decoration: none; }
.card h3 a:hover { color: var(--green-dark); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.card p { margin: 0; color: var(--muted); font-size: .93rem; }
.card .more { margin-top: auto; font-weight: 600; font-size: .85rem; color: var(--green); text-decoration: none; }
.card .more:hover { text-decoration: underline; }

/* ---------- photo gallery ---------- */
.gallery-jump {
  display: flex; flex-wrap: wrap; gap: .5rem; padding: 1.4rem 0;
  border-bottom: 1px solid var(--line); margin-bottom: 0;
}
.gallery-jump a {
  display: inline-flex; align-items: center; gap: .4rem; padding: .4rem .85rem;
  border-radius: 999px; border: 1px solid var(--line); color: var(--muted);
  text-decoration: none; font-size: .82rem; font-weight: 600; transition: all .15s ease;
}
.gallery-jump a:hover { border-color: var(--gold); color: var(--ink); }
.gallery-jump a span {
  background: var(--cream-2); color: var(--muted); font-size: .7rem; font-weight: 700;
  padding: .05rem .45rem; border-radius: 999px;
}
.gallery-group { padding-top: 2.8rem; margin-bottom: .5rem; scroll-margin-top: 90px; }
.gallery-group-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem;
  margin-bottom: 1.3rem; padding-bottom: 1rem; border-bottom: 1px solid var(--line);
}
.gallery-total { font-size: .8rem; color: var(--muted); white-space: nowrap; }
.gallery-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 190px; gap: 1rem;
}
.gallery-item {
  margin: 0; position: relative; border-radius: 8px; overflow: hidden; box-shadow: var(--shadow);
  background: var(--green-deep); cursor: pointer; grid-column: span 1; grid-row: span 1;
  opacity: 0; transform: translateY(14px); transition: opacity .5s ease, transform .5s ease;
}
.gallery-item.revealed { opacity: 1; transform: none; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease, filter .3s ease; }
.gallery-item:hover img { transform: scale(1.07); filter: brightness(.82); }
.gallery-item:focus-visible { outline: 3px solid var(--green-dark); outline-offset: 2px; }
.gallery-item .gallery-view {
  position: absolute; inset: 0; z-index: 2; display: grid; place-items: center;
  color: var(--on-dark); opacity: 0; transition: opacity .25s ease; pointer-events: none;
}
.gallery-item .gallery-view svg {
  width: 40px; height: 40px; padding: 10px; border: 1.5px solid color-mix(in srgb, var(--on-dark) 75%, transparent); border-radius: 50%;
}
.gallery-item:hover .gallery-view { opacity: 1; }
.gallery-item .gallery-count {
  position: absolute; top: .6rem; right: .6rem; z-index: 3;
  background: color-mix(in srgb, var(--scrim) 78%, transparent); color: var(--on-dark); font-size: .68rem; font-weight: 700;
  letter-spacing: .03em; padding: .3rem .55rem; border-radius: 999px;
}
.gallery-item figcaption {
  position: absolute; inset: auto 0 0 0; z-index: 2; padding: 1.4rem .9rem .8rem;
  background: linear-gradient(0deg, color-mix(in srgb, var(--scrim) 90%, transparent), color-mix(in srgb, var(--scrim) 35%, transparent) 60%, color-mix(in srgb, var(--scrim) 0%, transparent));
  color: var(--on-dark); font-size: .82rem; line-height: 1.3; font-weight: 500;
}
.gallery-cap-rule { display: block; width: 26px; height: 2px; background: var(--gold); margin-bottom: .5rem; }
@media (max-width: 900px) {
  .gallery-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 170px; }
}
@media (prefers-reduced-motion: reduce) {
  .gallery-item { opacity: 1; transform: none; transition: none; }
}

/* ---------- lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 500; display: none;
  align-items: center; justify-content: center; padding: 4vh 4vw;
  background: color-mix(in srgb, var(--scrim) 94%, transparent);
}
.lightbox.open { display: flex; animation: lbFade .2s ease; }
@keyframes lbFade { from { opacity: 0; } to { opacity: 1; } }
.lightbox-inner { position: relative; width: 100%; max-width: 1100px; text-align: center; }
.lightbox-frame { display: grid; place-items: center; }
.lightbox-img { max-width: 100%; max-height: 74vh; border-radius: 6px; box-shadow: 0 20px 60px color-mix(in srgb, var(--scrim) 50%, transparent); transition: opacity .18s ease; }
.lightbox-meta {
  display: flex; align-items: baseline; justify-content: center; gap: .7rem;
  margin-top: 1.1rem; color: var(--on-dark-soft);
}
.lightbox-caption { font-size: .95rem; }
.lightbox-count { font-size: .8rem; color: var(--gold-soft); font-variant-numeric: tabular-nums; }
.lightbox-close {
  position: absolute; top: -2.6rem; right: 0; background: none; border: 0; color: var(--on-dark);
  font-size: 2.2rem; line-height: 1; cursor: pointer; padding: .2rem .5rem;
}
.lightbox-nav {
  position: absolute; top: 37vh; transform: translateY(-50%); background: color-mix(in srgb, var(--on-dark) 12%, transparent);
  border: 0; color: var(--on-dark); width: 46px; height: 46px; border-radius: 50%; font-size: 1.8rem;
  cursor: pointer; display: grid; place-items: center; transition: background .15s ease;
}
.lightbox-nav:hover { background: color-mix(in srgb, var(--on-dark) 28%, transparent); }
.lightbox-nav.prev { left: -1rem; }
.lightbox-nav.next { right: -1rem; }
.lightbox-strip { display: none; gap: .5rem; justify-content: center; margin-top: 1.1rem; flex-wrap: wrap; }
.lightbox-thumb {
  width: 56px; height: 42px; border-radius: 4px; background-size: cover; background-position: center;
  border: 2px solid transparent; opacity: .55; cursor: pointer; padding: 0; transition: all .15s ease;
}
.lightbox-thumb:hover { opacity: .85; }
.lightbox-thumb.active { opacity: 1; border-color: var(--gold); }
@media (max-width: 700px) {
  .lightbox-nav.prev { left: .2rem; }
  .lightbox-nav.next { right: .2rem; }
  .lightbox-close { top: -2.2rem; right: .2rem; }
}

/* ---------- feature / split ---------- */
.split { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(1.5rem, 4vw, 3rem); align-items: center; }
.portrait {
  border-radius: 10px; aspect-ratio: 4/5; box-shadow: var(--shadow);
  background: linear-gradient(160deg, var(--green-dark), var(--green-deep));
  display: grid; place-items: center; color: var(--gold-soft); position: relative; overflow: hidden;
}
.portrait .frame { position: absolute; inset: 12px; border: 1px solid color-mix(in srgb, var(--gold-soft) 40%, transparent); border-radius: 6px; pointer-events: none; z-index: 2; }
.portrait .crest { width: 96px; height: 96px; opacity: .55; }
.portrait .photo { width: 100%; height: 100%; object-fit: cover; }
.portrait .tag {
  position: absolute; top: 1.4rem; left: 1.4rem; z-index: 2;
  background: var(--red); color: var(--on-dark); font-size: .7rem; letter-spacing: .08em;
  text-transform: uppercase; font-weight: 700; padding: .35rem .7rem; border-radius: 3px;
  box-shadow: 0 4px 14px color-mix(in srgb, var(--scrim) 25%, transparent);
}
.portrait::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(200deg, color-mix(in srgb, var(--scrim) 0%, transparent) 45%, color-mix(in srgb, var(--scrim) 55%, transparent) 100%);
}

/* ---------- stat strip ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--line); }
.stats .stat { padding: 1.6rem 1.5rem 1.7rem 0; }
.stat .num { font-family: var(--font-display); font-size: 2.3rem; color: var(--green-dark); line-height: 1; }
.stat .lbl { font-family: var(--font-mono); font-size: .74rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin-top: .5rem; }

/* ---------- filter pills ---------- */
.pill {
  display: inline-flex; align-items: center; padding: .45rem 1rem; border-radius: 999px;
  border: 1px solid var(--line); background: var(--paper); color: var(--muted);
  font-size: .84rem; font-weight: 600; text-decoration: none; transition: all .15s ease;
}
.pill:hover { border-color: var(--gold); color: var(--ink); }
.pill.active { background: var(--green); border-color: var(--green); color: var(--on-dark); }

/* ---------- pill quicklinks ---------- */
.quicklinks { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }

/* ---------- article layout ---------- */
.article { display: grid; grid-template-columns: minmax(0,1fr) 300px; gap: clamp(1.5rem,4vw,3rem); align-items: start; }
.prose { max-width: 70ch; }
.prose h2 { font-family: var(--font-display); font-size: 1.6rem; margin: 2rem 0 .6rem; color: var(--green-dark); }
.prose h3 { font-family: var(--font-display); font-size: 1.25rem; margin: 1.6rem 0 .5rem; }
.prose p { margin: 0 0 1.1rem; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: .5rem; }
.prose blockquote {
  margin: 1.6rem 0; padding: 1rem 1.4rem; border-left: 4px solid var(--gold);
  background: var(--cream-2); font-family: var(--font-display); font-style: italic; font-size: 1.15rem; color: var(--green-dark);
}
.aside { position: sticky; top: 90px; display: grid; gap: 1.2rem; }
.aside .box { background: var(--paper); border: 1px solid var(--line); border-radius: 8px; padding: 1.2rem; box-shadow: var(--shadow); }
.aside h4 { margin: 0 0 .8rem; font-family: var(--font-display); font-size: 1.05rem; color: var(--green-dark); }
.aside ul { list-style: none; margin: 0; padding: 0; }
.aside li { padding: .5rem 0; border-bottom: 1px solid var(--line); font-size: .9rem; }
.aside li:last-child { border-bottom: 0; }
.aside a:not(.btn) { text-decoration: none; color: var(--ink); }
.aside a:not(.btn):hover { color: var(--green); }

/* ---------- list rows (tenders, speeches, briefs) ---------- */
.rows { display: grid; gap: .8rem; }
.row {
  display: grid; grid-template-columns: 96px 1fr auto; gap: 1.1rem; align-items: center;
  background: var(--paper); border: 1px solid var(--line); border-radius: 8px; padding: 1rem 1.2rem;
  box-shadow: var(--shadow);
}
.row .cal { text-align: center; background: var(--cream-2); border-radius: 6px; padding: .5rem; }
.row .cal .d { font-family: var(--font-display); font-size: 1.5rem; font-weight: 600; color: var(--green-dark); line-height: 1; }
.row .cal .m { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--red); }
.row h3 { margin: 0 0 .25rem; font-size: 1.05rem; font-family: var(--font-display); }
.row h3 a { color: var(--ink); text-decoration: none; }
.row h3 a:hover { color: var(--green); }
.row .meta { font-size: .82rem; color: var(--muted); display: flex; gap: 1rem; flex-wrap: wrap; }
.status { display: inline-block; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding: .3rem .6rem; border-radius: 999px; }
.status.open { background: var(--success-bg); color: var(--green-dark); }
.status.closed { background: var(--error-bg); color: var(--red); }

/* ---------- video grid ---------- */
.video { position: relative; }
.video .thumb { aspect-ratio: 16/9; }
.video .play {
  position: absolute; inset: 0; display: grid; place-items: center;
}
.video .play span {
  width: 56px; height: 56px; border-radius: 50%; background: color-mix(in srgb, var(--red) 92%, transparent);
  display: grid; place-items: center; color: var(--on-dark);
}
.video .play span::before { content: ""; border-left: 16px solid var(--on-dark); border-top: 10px solid transparent; border-bottom: 10px solid transparent; margin-left: 4px; }
.video h3 a::after { content: ""; position: absolute; inset: 0; }

/* ---------- table ---------- */
table.data { width: 100%; border-collapse: collapse; background: var(--paper); box-shadow: var(--shadow); border-radius: 8px; overflow: hidden; }
table.data th, table.data td { text-align: left; padding: .85rem 1rem; border-bottom: 1px solid var(--line); font-size: .92rem; }
table.data th { background: var(--green-dark); color: var(--on-dark); font-weight: 600; letter-spacing: .02em; }
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover td { background: var(--cream); }

/* ---------- contact / form ---------- */
.formgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field { display: grid; gap: .35rem; }
.field.full { grid-column: 1 / -1; }
.field label, .field > span { font-size: .82rem; font-weight: 600; color: var(--green-dark); }
.field input, .field select, .field textarea {
  font: inherit; padding: .7rem .8rem; border: 1px solid var(--line-strong); border-radius: 6px;
  background: var(--paper); color: var(--ink);
}
.field textarea { min-height: 130px; resize: vertical; }

/* ---------- alerts ---------- */
.alert { padding: .9rem 1.1rem; border-radius: 6px; margin-bottom: 1.4rem; font-size: .92rem; }
.alert-success { background: var(--success-bg); color: var(--green-dark); border: 1px solid var(--success-line); }
.alert-error { background: var(--error-bg); color: var(--red); border: 1px solid var(--error-line); }
.alert ul { margin: .4rem 0 0; padding-left: 1.1rem; }

/* ---------- pagination ---------- */
.pagination { display: flex; gap: .4rem; list-style: none; padding: 0; margin: 2rem 0 0; justify-content: center; flex-wrap: wrap; }
.pagination li { }
.pagination a, .pagination span {
  display: inline-flex; align-items: center; padding: .5rem .8rem; border-radius: 6px;
  border: 1px solid var(--line); background: var(--paper); color: var(--ink);
  text-decoration: none; font-size: .88rem;
}
.pagination .active span { background: var(--green); color: var(--on-dark); border-color: var(--green); }
.pagination .disabled span { opacity: .5; }

/* ---------- footer ---------- */
.footer { background: var(--green-deep); color: var(--on-dark-soft); padding: clamp(3rem, 6vw, 4.5rem) 0 0; }
.footer .cols { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.1fr; gap: 2.5rem; }
.footer h4 {
  margin: .5rem 0 1.2rem; font-size: .76rem; font-weight: 600; letter-spacing: .14em;
  text-transform: uppercase; color: var(--gold-soft);
}
.footer a { color: var(--on-dark-soft); text-decoration: none; }
.footer a:hover { color: var(--on-dark); text-decoration: underline; text-underline-offset: 3px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .7rem; font-size: .95rem; }
.footer .brandcol { display: grid; gap: 1.1rem; align-content: start; }
.footer .brandcol p { margin: 0; font-size: .95rem; max-width: 34ch; }
.footer .brand { color: var(--on-dark-soft); }
.footer .brand .crest { width: 64px; height: 64px; }
.footer .brand-text { border-left-color: color-mix(in srgb, var(--on-dark-soft) 25%, transparent); }
.footer .brand .name { font-size: 1.6rem; font-weight: 400; }
.footer .brand .kicker { color: var(--gold-soft); }
.footer .note { color: var(--gold-soft); }
.subscribe { display: flex; gap: .5rem; max-width: 26rem; }
.subscribe input {
  flex: 1 1 0; width: 0; min-width: 0; font: inherit; font-size: .9rem; color: var(--ink);
  padding: .65rem .8rem; border: 1px solid var(--paper); border-radius: 4px; background: var(--paper);
}
.legal { margin-top: clamp(2.5rem, 5vw, 3.5rem); border-top: 1px solid color-mix(in srgb, var(--on-dark-soft) 16%, transparent); font-size: .85rem; color: var(--on-dark-muted); }
.legal .wrap { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: 1.3rem 0; }
.legal a { color: var(--on-dark-muted); }

/* ---------- homepage ---------- */
.hero {
  position: relative; color: var(--on-dark); overflow: hidden;
  background: linear-gradient(115deg, var(--green-deep), var(--green-dark) 60%, var(--scrim-warm));
}
.hero-slider { position: absolute; inset: 0; z-index: 0; }
.hero-slider .slide {
  position: absolute; inset: 0; background-size: cover; background-position: center;
  opacity: 0; filter: saturate(1.08) brightness(.96); transform-origin: center;
  animation: heroSlide 25s infinite;
}
.hero-slider .slide:nth-child(2) { animation-delay: 5s; }
.hero-slider .slide:nth-child(3) { animation-delay: 10s; }
.hero-slider .slide:nth-child(4) { animation-delay: 15s; }
.hero-slider .slide:nth-child(5) { animation-delay: 20s; }
.hero-slider::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, color-mix(in srgb, var(--scrim) 82%, transparent) 0%, color-mix(in srgb, var(--scrim-warm) 50%, transparent) 32%, color-mix(in srgb, var(--scrim-warm) 14%, transparent) 62%, color-mix(in srgb, var(--scrim) 32%, transparent) 100%);
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: 1; opacity: .08; pointer-events: none;
  background: repeating-linear-gradient(135deg, var(--on-dark) 0 2px, transparent 2px 26px);
}
.hero .wrap {
  position: relative; z-index: 2; padding: clamp(3rem, 8vw, 6.5rem) 0;
  display: grid; gap: 1.4rem; justify-items: start;
}
.hero .wrap > * { max-width: 62ch; }
.hero .eyebrow { font-size: .78rem; letter-spacing: .24em; color: var(--gold-soft); font-weight: 600; }
.hero h1 {
  font-family: var(--font-display); font-weight: 600; margin: 0;
  font-size: clamp(2rem, 5.2vw, 3.6rem); line-height: 1.05;
}
.hero p { font-size: 1.1rem; color: var(--on-dark-muted); margin: 0; max-width: 52ch; }
.hero .cite { font-style: italic; color: var(--gold-soft); font-size: .95rem; }
.hero .btns { display: flex; gap: .8rem; flex-wrap: wrap; margin-top: .4rem; }
.hero :focus-visible { outline-color: var(--gold-soft); }
@keyframes heroSlide {
  0%   { opacity: 0; transform: scale(1.02); }
  4%   { opacity: 1; }
  20%  { opacity: 1; }
  24%  { opacity: 0; }
  100% { opacity: 0; transform: scale(1.1); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-slider .slide { animation: none; transform: none; }
  .hero-slider .slide:first-child { opacity: 1; }
}

.dateline .wrap {
  display: flex; justify-content: space-between; align-items: center; gap: .4rem 1.5rem; flex-wrap: wrap;
  padding: 1.05rem 0; border-bottom: 1px solid var(--line); font-size: .82rem; color: var(--muted);
}
.dateline time { font-family: var(--font-mono); font-size: .8rem; letter-spacing: .04em; text-transform: uppercase; color: var(--ink); }

.frontpage { padding-top: clamp(2rem, 4vw, 3rem); }
.lead-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: clamp(2rem, 4vw, 3rem); align-items: start; }
.lead-story > img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 6px; margin-bottom: 1.3rem; }
.lead-story h2 {
  font-family: var(--font-display); font-weight: 400; font-size: clamp(2.1rem, 4.4vw, 3.7rem);
  line-height: 1.06; letter-spacing: -.012em; margin: .7rem 0 0;
}
.lead-story h2 a { color: var(--ink); text-decoration: none; }
.lead-story h2 a:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: .1em; }
.lead-story p { font-size: 1.2rem; line-height: 1.55; color: var(--muted); margin: 1.2rem 0 1.3rem; max-width: 58ch; }

.latest-head { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: .9rem; border-bottom: 2px solid var(--ink); }
.latest-head h2 { margin: 0; font-size: .8rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.latest-head a, .desk-head a { font-size: .9rem; font-weight: 500; color: var(--green-dark); text-decoration: none; }
.latest-head a:hover, .desk-head a:hover { text-decoration: underline; text-underline-offset: 3px; }
.latest ol { list-style: none; margin: 0; padding: 0; }
.latest li { display: grid; grid-template-columns: 2.4rem 1fr; padding: 1.25rem 0; border-bottom: 1px solid var(--line); }
.latest li:last-child { border-bottom: 0; }
.latest .num { font-family: var(--font-mono); font-size: .8rem; color: var(--gold-ink); padding-top: .1rem; }
.latest h3 { margin: .3rem 0 0; font-family: var(--font-display); font-weight: 400; font-size: 1.28rem; line-height: 1.3; }
.latest h3 a, .doclist a, .ministry h4 a, .media-feature h3 a, .media-item h3 a { color: var(--ink); text-decoration: none; }
.latest h3 a:hover, .doclist a:hover, .ministry h4 a:hover, .media-feature:hover h3 a, .media-item:hover h3 a {
  color: var(--green-dark); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px;
}

.more-news { margin-top: clamp(2.5rem, 5vw, 3.5rem); padding-top: clamp(2rem, 4vw, 2.5rem); border-top: 1px solid var(--line); }

.quote-band { padding: 0; display: grid; grid-template-columns: 7fr 5fr; background: var(--green-deep); color: var(--on-dark-soft); }
.quote-panel {
  position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: flex-start;
  justify-content: center; gap: 1.6rem; padding: clamp(3rem, 7vw, 6rem) clamp(1.5rem, 4.5vw, 4rem);
}
.quote-panel::before, .quote-panel::after {
  content: ""; position: absolute; border: 1px solid color-mix(in srgb, var(--gold-soft) 32%, transparent); border-radius: 50%; pointer-events: none;
}
.quote-panel::before { width: 480px; height: 480px; right: -240px; top: -182px; }
.quote-panel::after { width: 400px; height: 400px; right: -200px; top: -142px; }
.quote-panel .eyebrow { margin: 0; color: var(--gold-soft); }
.quote-panel figure { margin: 0; max-width: 30rem; }
.quote-panel blockquote { margin: 0; }
.quote-panel blockquote p {
  margin: 0; font-family: var(--font-display); font-style: italic; font-weight: 400;
  font-size: clamp(1.6rem, 2.6vw, 2.15rem); line-height: 1.3;
}
.quote-panel figcaption { display: flex; align-items: center; gap: .9rem; margin-top: 1.6rem; color: var(--gold-soft); font-size: .95rem; font-weight: 500; }
.quote-panel figcaption::before { content: ""; width: 2.5rem; height: 1px; background: var(--gold-soft); }
.quote-photo { width: 100%; height: 100%; min-height: 22rem; object-fit: cover; }

.desk { gap: 1.5rem; }
.desk-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin-bottom: 1rem; }
.desk-head h3 { margin: 0; font-family: var(--font-display); font-weight: 400; font-size: 1.5rem; }
.doclist { list-style: none; margin: 0; padding: 0; background: var(--paper); border: 1px solid var(--line); border-radius: 8px; }
.doclist li { display: grid; grid-template-columns: 40px 1fr; gap: 1rem; align-items: center; padding: 1.4rem 1.5rem; }
.doclist li + li { border-top: 1px solid var(--line); }
.doc-ic { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 4px; background: var(--sand); color: var(--gold-ink); }
.doc-ic .ic { width: 20px; height: 20px; }
.doclist a { font-family: var(--font-display); font-size: 1.12rem; line-height: 1.35; }
.doc-meta { display: block; margin-top: .4rem; font-family: var(--font-mono); font-size: .76rem; letter-spacing: .02em; text-transform: uppercase; color: var(--muted); }
.doclist .status { margin-top: .6rem; padding: .25rem .55rem; border-radius: 3px; font-size: .75rem; font-weight: 600; letter-spacing: 0; text-transform: none; }

/* Coat of Arms watermark, centred and scaled to fit behind the Administration intro. */
.executive { position: relative; isolation: isolate; }
.executive::before {
  content: ""; position: absolute; z-index: -1; inset: 2rem 0;
  background: url("../images/coat-of-arms.png") center / contain no-repeat;
  filter: grayscale(1); opacity: .055; pointer-events: none;
}
.leaders { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 1.5rem; }
.leaders article { padding: clamp(2rem, 4vw, 3rem) 2rem clamp(2rem, 4vw, 3rem) 0; }
.leaders article + article { padding-left: 2rem; border-left: 1px solid var(--line); }
.numeral { font-family: var(--font-mono); font-size: .8rem; color: var(--gold-ink); }
.leaders h3 { margin: .9rem 0 .8rem; font-family: var(--font-display); font-weight: 400; font-size: clamp(1.5rem, 2.4vw, 1.95rem); line-height: 1.15; }
.leaders p { margin: 0 0 1.1rem; color: var(--muted); font-size: .98rem; max-width: 36ch; }

.ministries-head { margin: clamp(2.5rem, 5vw, 3.5rem) 0 1.5rem; align-items: baseline; }
.subtitle { margin: 0; font-family: var(--font-display); font-weight: 400; font-size: clamp(1.5rem, 2.4vw, 1.95rem); }
.ministry .thumb { aspect-ratio: 16 / 10; border-bottom: 3px solid var(--gold); }
.ministry .thumb > img { object-position: center 30%; }
.ministry .thumb > img.emblem { position: static; width: auto; height: 62%; object-fit: contain; }
.ministry-entry { scroll-margin-top: 7rem; }
.ministry-entry address {
  margin-top: auto; padding-top: .8rem; border-top: 1px solid var(--line);
  font-style: normal; font-size: .86rem; line-height: 1.55; color: var(--muted);
}
.ministry .body { display: grid; grid-template-columns: auto 1fr auto; gap: 0 .7rem; align-content: start; padding: 1.3rem 1.2rem 1.5rem; }
.ministry .num { font-family: var(--font-mono); font-size: .8rem; color: var(--gold-ink); padding-top: .2rem; }
.ministry h4 { margin: 0; font-family: var(--font-display); font-weight: 400; font-size: 1.15rem; line-height: 1.3; }
.ministry .body > .ic { width: 15px; height: 15px; margin-top: .25rem; color: var(--muted); }
.ministry p { grid-column: 2; margin: .35rem 0 0; font-size: .86rem; color: var(--muted); }

.media-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 1.5rem; align-items: start; }
.media-side { display: grid; gap: 2rem; }
.media-feature, .media-item { position: relative; }
.media-thumb { position: relative; aspect-ratio: 16 / 9; margin-bottom: 1.1rem; border-radius: 6px; overflow: hidden; background: var(--green-deep); }
.media-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.media-feature:hover .media-thumb img, .media-item:hover .media-thumb img { transform: scale(1.03); }
.media-feature h3, .media-item h3 { margin: .45rem 0 0; font-family: var(--font-display); font-weight: 400; line-height: 1.3; }
.media-feature h3 { font-size: clamp(1.35rem, 2.2vw, 1.7rem); }
.media-item h3 { font-size: 1.22rem; }
.media-feature h3 a::after, .media-item h3 a::after { content: ""; position: absolute; inset: 0; }
.media-thumb .play {
  position: absolute; left: 1.4rem; bottom: 1.4rem; display: grid; place-items: center;
  width: 64px; height: 64px; border-radius: 50%; background: var(--cream); box-shadow: 0 2px 12px color-mix(in srgb, var(--scrim) 30%, transparent);
}
.media-thumb .play::before { content: ""; margin-left: 4px; border-left: 15px solid var(--ink); border-top: 9px solid transparent; border-bottom: 9px solid transparent; }

.fl-section { padding-top: 0; }
.fl-band {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.1fr); gap: 2rem; align-items: center;
  padding: clamp(2rem, 4vw, 3.5rem) clamp(1.5rem, 3.5vw, 3rem); background: var(--sand); border-radius: 8px;
}
.fl-intro h2 { margin: .55rem 0 .9rem; font-family: var(--font-display); font-weight: 400; font-size: clamp(1.6rem, 2.6vw, 2rem); line-height: 1.15; }
.fl-intro p { margin: 0 0 1.1rem; color: var(--muted); font-size: .98rem; }
.fl-services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.service {
  display: grid; gap: .45rem; align-content: start; padding: 1.5rem; background: var(--paper);
  border: 1px solid transparent; border-radius: 8px; color: var(--ink); text-decoration: none; transition: border-color .16s ease;
}
.service:hover { border-color: var(--gold); }
.service .ic { width: 22px; height: 22px; color: var(--gold-ink); }
.service h3 { margin: .45rem 0 0; font-size: 1rem; font-weight: 600; }
.service p { margin: 0; font-size: .88rem; color: var(--muted); }

/* ---------- notice banner ---------- */
/* ---------- misc ---------- */
.center { text-align: center; }
.mt2 { margin-top: 2rem; }
.muted { color: var(--muted); }
hr.rule { border: 0; border-top: 1px solid var(--line); margin: 2.5rem 0; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ---------- responsive ---------- */
/* The single-row masthead needs ~1100px; below that the nav folds behind the menu button. */
@media (max-width: 1100px) {
  html { scroll-padding-top: 0; }
  .masthead { position: relative; }
  .masthead > .wrap { flex-wrap: wrap; gap: .5rem 1rem; min-height: 0; padding: .7rem 0; }
  .tools { margin-left: auto; }
  .navtoggle {
    display: inline-flex; align-items: center; gap: .45rem; padding: .55rem .8rem;
    background: none; border: 1px solid var(--line); border-radius: 4px;
    color: var(--ink); font: inherit; font-size: .9rem; font-weight: 600; cursor: pointer;
  }
  .mainnav { order: 3; width: 100%; margin: 0; }
  .navlist { display: none; flex-direction: column; padding-bottom: .6rem; }
  .navlist.open { display: flex; }
  .navlist > li > a { padding: .8rem .2rem; border-top: 1px solid var(--line); text-underline-offset: .35rem; }
  .has-sub > a::after { display: none; }
  .submenu {
    position: static; opacity: 1; visibility: visible; transform: none; min-width: 0;
    box-shadow: none; border: 0; border-radius: 0; background: none; padding: 0 0 .5rem 1rem;
  }
  .has-sub.dismissed .submenu { opacity: 1; visibility: visible; }
}
@media (max-width: 960px) {
  .grid.cols-3, .grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; }
  .article { grid-template-columns: 1fr; }
  .aside { position: static; }
  .footer .cols { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .quicklinks { grid-template-columns: 1fr; }
  .lead-grid, .quote-band, .media-grid, .fl-band { grid-template-columns: 1fr; }
  .quote-photo { min-height: 0; aspect-ratio: 16 / 9; }
  .leaders { grid-template-columns: 1fr; }
  .leaders article { padding-right: 0; }
  .leaders article + article { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
  .media-side { grid-template-columns: 1fr 1fr; gap: 1.5rem; }
  .more-news .grid.cols-3 { grid-template-columns: repeat(3, 1fr); gap: 1rem; }
  .grid.desk { grid-template-columns: 1fr; gap: 2rem; }
}
@media (max-width: 720px) {
  .tools .btn { display: none; }
  .brand { gap: .6rem; }
  .brand .crest { width: 40px; height: 40px; }
  .brand-text { padding-left: .6rem; }
  .brand .name { font-size: 1.1rem; }
  .grid.cols-3, .grid.cols-4, .grid.cols-2 { grid-template-columns: 1fr; }
  .footer .cols { grid-template-columns: minmax(0, 1fr); }
  .row { grid-template-columns: 70px 1fr; }
  .row .status { grid-column: 2; justify-self: start; }
  .formgrid { grid-template-columns: 1fr; }
  .media-side, .fl-services { grid-template-columns: 1fr; }
  .more-news .grid.cols-3 { grid-template-columns: 1fr; }
}

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

:focus-visible { outline: 3px solid var(--green-dark); outline-offset: 2px; }
.footer :focus-visible, .quote-band :focus-visible { outline-color: var(--gold-soft); }
