/* ==========================================================================
   Get involved: programmes, careers, work with us, support, transparency,
   and their admin screens. Public rules (eg-) use the site tokens from
   site.css; admin rules (egx-) use the admin tokens from admin.css.
   ========================================================================== */

.eg-icon { flex-shrink: 0; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------------------------------------------------------------- Hero */

.eg-hero { padding-bottom: 0; }
.eg-hero > .container { padding-bottom: var(--s-4); }
.eg-title {
  max-width: 22ch;
  font-family: var(--font-serif); font-weight: 500; font-size: clamp(2.3rem, 4.6vw, 3.9rem);
  line-height: 1.04; letter-spacing: -0.015em;
}
.eg-hero .lede { max-width: 62ch; }
.eg-crumbs { display: flex; flex-wrap: wrap; gap: 0.5em; margin-bottom: var(--s-2); font-size: 0.82rem; color: var(--on-ink-muted); }
.eg-crumbs a { color: var(--on-ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(255, 255, 255, 0.35); }
.eg-crumbs a:hover { color: #fff; }
.eg-crumbs [aria-current] { max-width: 40ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.eg-hero-facts { display: flex; flex-wrap: wrap; gap: 0.6rem 1.6rem; margin: var(--s-3) 0 0; padding: 0; list-style: none; font-size: 0.95rem; color: var(--on-ink); }
.eg-hero-facts li { display: flex; align-items: center; gap: 0.5em; }
.eg-hero-facts strong { color: #fff; font-weight: 600; }
.eg-hero-actions { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-top: var(--s-3); }

/* Section navigation along the bottom of the hero. */
.eg-subnav { border-top: 1px solid rgba(255, 255, 255, 0.12); background: rgba(0, 0, 0, 0.12); }
.eg-subnav ul {
  display: flex; gap: var(--s-3); margin: 0; padding: 0; list-style: none;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.eg-subnav ul::-webkit-scrollbar { display: none; }
.eg-subnav a {
  display: block; padding: 0.95rem 0; white-space: nowrap;
  font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--on-ink-muted);
  border-bottom: 2px solid transparent;
}
.eg-subnav a:hover { color: #fff; }
.eg-subnav a[aria-current="page"] { color: #fff; border-bottom-color: var(--accent-soft); }

/* --------------------------------------------------------------- Pills */

.eg-pill, .egx-pill {
  display: inline-flex; align-items: center; gap: 0.4em; padding: 0.22em 0.65em;
  font-size: 0.66rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; white-space: nowrap;
  border: 1px solid currentColor; border-radius: 999px;
}
.eg-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.eg-pill.is-open { color: #fff; background: var(--accent); border-color: var(--accent); }
.eg-pill.is-open::before { background: #fff; animation: eg-pulse 2s ease-in-out infinite; }
.eg-pill.is-soon { color: var(--accent-dark); background: #EFEAF5; border-color: var(--accent-soft); }
.eg-pill.is-ongoing { color: var(--pine); background: #fff; border-color: var(--pine); }
.eg-pill.is-closed { color: var(--muted); background: #fff; border-color: var(--line); }
.eg-hero .eg-pill.is-closed, .eg-hero .eg-pill.is-ongoing { background: transparent; color: var(--on-ink); border-color: var(--line-dark); }
.eg-hero .eg-pill.is-soon { background: transparent; color: var(--accent-soft); border-color: var(--accent-soft); }
@keyframes eg-pulse { 50% { opacity: 0.35; } }

/* ------------------------------------------------------------ Listings */

.eg-section { padding-top: var(--s-5); }
.eg-section.is-paper { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.eg-group + .eg-group { margin-top: var(--s-5); }
.eg-group-head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: var(--s-1) var(--s-2); margin-bottom: var(--s-3); padding-bottom: var(--s-2); border-bottom: 1px solid var(--line); }
.eg-group-head h2 { margin: 0; font-size: clamp(1.35rem, 2vw, 1.7rem); }
.eg-count { margin: 0; font-size: 0.85rem; color: var(--muted); }
.eg-note { display: flex; align-items: center; flex-wrap: wrap; gap: 0.5em; margin: var(--s-3) 0; padding: var(--s-2) var(--s-3); font-size: 0.95rem; color: var(--muted); background: var(--paper); border: 1px solid var(--line); border-left: 3px solid var(--accent); }
.eg-note a, .eg-link, .eg-panel a:not(.btn), .eg-aside-card a:not(.btn), .eg-elsewhere a { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 2px; }
.eg-link { display: inline-flex; align-items: center; gap: 0.35em; font-weight: 500; }

.eg-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-3); }
.eg-cards.is-open { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.eg-card {
  display: flex; flex-direction: column; overflow: hidden; min-width: 0;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}
.eg-card.is-open { border-top: 3px solid var(--accent); }
.eg-card:hover { border-color: var(--accent-soft); box-shadow: 0 10px 24px rgba(42, 27, 69, 0.08); transform: translateY(-2px); }
.eg-card.is-closed { background: transparent; }
.eg-card-media { display: block; aspect-ratio: 16 / 7; overflow: hidden; background: var(--ink); }
.eg-card-media img { width: 100%; height: 100%; object-fit: cover; }
.eg-card-body { display: flex; flex-direction: column; flex: 1; padding: var(--s-3); }
.eg-card-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6em; margin-bottom: 0.8em; }
.eg-kind { font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.eg-card-title { margin: 0 0 0.45em; font-family: var(--font-serif); font-weight: 500; font-size: clamp(1.35rem, 2vw, 1.6rem); line-height: 1.15; letter-spacing: -0.01em; }
.eg-cards.is-open .eg-card-title { font-size: clamp(1.5rem, 2.4vw, 1.95rem); }
.eg-card-title a:hover { color: var(--accent-dark); }
.eg-card-summary { margin: 0 0 0.9em; font-size: 0.95rem; line-height: 1.55; color: var(--muted); }
.eg-facts-inline { display: flex; flex-wrap: wrap; gap: 0.3em 1.1em; margin: 0 0 0.9em; font-size: 0.85rem; color: var(--muted); }
.eg-facts-inline span { display: inline-flex; align-items: center; gap: 0.35em; }
.eg-facts-inline span + span::before { content: ""; width: 3px; height: 3px; margin-right: 0.75em; border-radius: 50%; background: var(--accent-soft); }
.eg-facts-inline span:has(.eg-icon)::before { display: none; }
.eg-closing { display: flex; align-items: center; gap: 0.5em; margin: 0 0 0.9em; font-size: 0.88rem; color: var(--text); }
.eg-closing .eg-icon { color: var(--accent); }
.eg-closing strong { color: var(--accent-dark); font-weight: 600; }
.eg-card-link { display: inline-flex; align-items: center; gap: 0.4em; margin-top: auto; padding-top: var(--s-1); font-size: 0.88rem; font-weight: 600; color: var(--accent-dark); }
.eg-card-link .eg-icon { transition: transform 0.15s ease; }
.eg-card:hover .eg-card-link .eg-icon { transform: translateX(3px); }

/* Roles */
.eg-roles { margin: 0; padding: 0; list-style: none; }
.eg-role { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--s-2) var(--s-4); align-items: center; padding: var(--s-3) 0; border-bottom: 1px solid var(--line); }
.eg-role .eg-card-summary { margin-bottom: 0; max-width: 70ch; }
.eg-role-side { display: flex; flex-direction: column; align-items: flex-end; gap: var(--s-1); }
.eg-role-side .eg-closing { margin: 0; }

/* Empty states */
.eg-empty { max-width: 46rem; margin: 0 auto; padding: var(--s-4) var(--s-3); text-align: center; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.eg-empty-mark { margin: 0; font-family: var(--font-serif); font-size: 4.5rem; font-weight: 300; line-height: 1; color: var(--accent-soft); }
.eg-empty h2 { margin: var(--s-1) 0 var(--s-1); font-family: var(--font-serif); font-weight: 500; font-size: clamp(1.6rem, 2.6vw, 2rem); letter-spacing: -0.01em; }
.eg-empty p { max-width: 52ch; margin: 0 auto var(--s-3); color: var(--muted); }
.eg-empty-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--s-2); }

/* CTA band */
.eg-cta .container { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--s-3); }
.eg-cta h2 { margin-bottom: 0.3em; font-family: var(--font-serif); font-weight: 500; letter-spacing: -0.01em; }
.eg-cta .lede { margin: 0; text-align: left; }

/* ------------------------------------------------------- Detail pages */

.eg-detail { padding-top: var(--s-4); }
.eg-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: var(--s-5); align-items: start; }
.eg-main { min-width: 0; }
.eg-cover { margin: 0 0 var(--s-4); }
.eg-cover img { width: 100%; max-height: 26rem; object-fit: cover; border: 1px solid var(--line); border-radius: var(--radius); }
.eg-block { margin-bottom: var(--s-4); }
.eg-block > h2, .eg-serif-heading, .eg-section-title {
  font-family: var(--font-serif); font-weight: 500; font-size: clamp(1.55rem, 2.3vw, 2rem); letter-spacing: -0.01em;
}
.eg-block > h2 { padding-bottom: 0.45em; border-bottom: 1px solid var(--line); }
.eg-block .prose { max-width: 68ch; }

.eg-faq details { border-bottom: 1px solid var(--line); }
.eg-faq details:first-child { border-top: 1px solid var(--line); }
.eg-faq summary {
  display: flex; justify-content: space-between; gap: var(--s-2); padding: var(--s-2) 0; cursor: pointer; list-style: none;
  font-weight: 600; color: var(--ink);
}
.eg-faq summary::-webkit-details-marker { display: none; }
.eg-faq summary::after { content: "+"; flex: none; font-weight: 400; font-size: 1.3rem; line-height: 1; color: var(--accent); }
.eg-faq details[open] summary::after { content: "−"; }
.eg-faq .prose { padding: 0 0 var(--s-2); color: var(--muted); }

.eg-aside { position: sticky; top: calc(var(--header-h) + var(--s-2)); display: grid; gap: var(--s-3); }
.eg-aside-card { padding: var(--s-3); background: var(--paper); border: 1px solid var(--line); border-top: 3px solid var(--accent); border-radius: var(--radius); }
.eg-aside-card.is-quiet { border-top-color: var(--line); font-size: 0.92rem; color: var(--muted); }
.eg-aside-card.is-quiet p { margin: 0; overflow-wrap: anywhere; }
.eg-aside-title { margin-bottom: var(--s-2); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent-dark); }
.eg-dl { margin: 0; }
.eg-dl div { display: grid; grid-template-columns: 6.5rem 1fr; gap: var(--s-1); padding: 0.6rem 0; border-top: 1px solid var(--line); font-size: 0.92rem; }
.eg-dl div:first-child { border-top: 0; padding-top: 0; }
.eg-dl dt { color: var(--muted); }
.eg-dl dd { margin: 0; color: var(--ink); font-weight: 500; overflow-wrap: anywhere; }
.eg-dd-sub { display: block; font-weight: 400; font-size: 0.85rem; color: var(--muted); }
.eg-aside-cta { width: 100%; margin-top: var(--s-2); text-align: center; }

/* Closed / confirmation panels */
.eg-panel { padding: var(--s-3) var(--s-4); background: var(--paper); border: 1px solid var(--line); border-left: 3px solid var(--accent); }
.eg-panel.is-closed { border-left-color: var(--muted); }
.eg-panel h2 { font-size: 1.3rem; }
.eg-panel p:last-child { margin-bottom: 0; }
.eg-panel-actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2) var(--s-3); }
.eg-confirm { display: grid; grid-template-columns: auto 1fr; gap: var(--s-3); padding: var(--s-4); background: var(--paper); border: 1px solid var(--accent-soft); border-top: 3px solid var(--accent); border-radius: var(--radius); }
.eg-confirm.is-wide { max-width: 50rem; margin: 0 auto var(--s-4); }
.eg-confirm:focus { outline: none; }
.eg-confirm-mark { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; color: #fff; background: var(--accent); }
.eg-confirm-mark .eg-icon { width: 26px; height: 26px; stroke-width: 2.4; }
.eg-confirm h2 { margin-bottom: 0.4em; font-family: var(--font-serif); font-weight: 500; font-size: 1.8rem; }
.eg-confirm p { color: var(--muted); }
.eg-confirm-more { margin: 0; font-size: 0.92rem; }
.eg-confirm-more a { color: var(--accent-dark); text-decoration: underline; }

/* -------------------------------------------------------------- Forms */

.eg-form-wrap { padding: var(--s-4); background: var(--paper); border: 1px solid var(--line); border-top: 3px solid var(--accent); border-radius: var(--radius); }
.eg-form-head h2 { margin-bottom: 0.3em; font-family: var(--font-serif); font-weight: 500; font-size: clamp(1.6rem, 2.4vw, 2.1rem); }
.eg-form-head p { color: var(--muted); }
.eg-form .alert:focus, .alert[data-focus-on-load]:focus { outline: none; }
.eg-fieldset { min-width: 0; margin: 0 0 var(--s-3); padding: var(--s-3) 0 0; border: 0; border-top: 1px solid var(--line); }
.eg-fieldset legend { display: flex; align-items: center; gap: 0.6em; padding: 0 0.6em 0 0; font-weight: 600; font-size: 1.02rem; color: var(--ink); }
.eg-step { display: inline-grid; place-items: center; width: 1.65rem; height: 1.65rem; border-radius: 50%; font-size: 0.78rem; font-weight: 700; color: #fff; background: var(--ink); }
.eg-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 var(--s-3); margin-top: var(--s-2); }
.eg-span-2 { grid-column: 1 / -1; }
.contact-form.eg-form .field { margin-bottom: var(--s-2); }
.contact-form.eg-form label { color: var(--ink); font-weight: 500; }
.contact-form.eg-form textarea { min-height: 7rem; }
.contact-form.eg-form #ap-statement { min-height: 16rem; line-height: 1.6; }
.contact-form.eg-form select {
  -webkit-appearance: none; appearance: none; padding-right: 2.2em;
  background: var(--paper) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%235D5B54'/%3E%3C/svg%3E") no-repeat right 0.9em center;
}
.eg-req { color: var(--accent); font-weight: 700; }
.eg-optional { margin-left: 0.4em; font-size: 0.9em; letter-spacing: 0.04em; text-transform: none; color: var(--muted); font-weight: 400; }
.eg-hint { margin: 0.35em 0 0.6em; font-size: 0.86rem; line-height: 1.5; color: var(--muted); }
.field > .eg-hint:last-child { margin-bottom: 0; }
.eg-count { margin: 0.4em 0 0; font-size: 0.85rem; font-variant-numeric: tabular-nums; color: var(--muted); }
.eg-count.is-bad { color: var(--danger); }
.eg-count.is-good { color: var(--pine); }

.eg-files { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-3); margin-top: var(--s-2); }
.eg-file { position: relative; padding: var(--s-2); background: var(--mist); border: 1px dashed var(--accent-soft); border-radius: var(--radius); }
.eg-file.is-invalid { border-color: var(--danger); }
.eg-file.has-file { border-style: solid; border-color: var(--accent); }
.contact-form .eg-file input[type="file"] { padding: 0.55em; font-size: 0.9rem; background: var(--paper); }
.eg-file-again { display: flex; align-items: center; gap: 0.5em; margin: var(--s-2) 0 0; padding: 0.7em 1em; font-size: 0.9rem; color: var(--ink); background: #EFEAF5; border-radius: var(--radius); }

.eg-consent { margin-top: var(--s-2); padding-top: var(--s-3); border-top: 1px solid var(--line); }
.contact-form.eg-form .eg-check { display: flex; gap: 0.75em; align-items: flex-start; margin: 0; font-size: 0.92rem; letter-spacing: 0; text-transform: none; color: var(--text); font-weight: 400; line-height: 1.5; }
.contact-form.eg-form .eg-check input { flex: none; width: 1.15rem; height: 1.15rem; margin: 0.15em 0 0; accent-color: var(--accent); }
.eg-submit { display: flex; align-items: center; flex-wrap: wrap; gap: var(--s-1) var(--s-3); margin-top: var(--s-3); }
.eg-submit .eg-hint { margin: 0; }
.eg-submit .btn { padding-left: 2em; padding-right: 2em; }

/* Enquiry topics as radio cards */
.eg-enquiry { max-width: 64rem; margin: 0 auto; }
.eg-types-fieldset { border-top: 0; padding-top: 0; }
.eg-types { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 14.5rem), 1fr)); gap: var(--s-2); margin-top: var(--s-2); }
.contact-form.eg-form .eg-type {
  position: relative; display: flex; gap: 0.7em; height: 100%; margin: 0; padding: var(--s-2);
  font-size: 0.95rem; letter-spacing: 0; text-transform: none; color: var(--text); font-weight: 400;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}
.contact-form.eg-form .eg-type:hover { border-color: var(--accent-soft); }
.contact-form.eg-form .eg-type input { flex: none; width: 1.05rem; height: 1.05rem; margin: 0.2em 0 0; accent-color: var(--accent); }
.eg-type-body { display: flex; flex-direction: column; gap: 0.3em; }
.eg-type-label { font-weight: 600; color: var(--ink); line-height: 1.3; }
.eg-type-desc { font-size: 0.85rem; line-height: 1.45; color: var(--muted); }
.contact-form.eg-form .eg-type:has(input:checked) { border-color: var(--accent); background: #F7F4FB; box-shadow: inset 0 0 0 1px var(--accent); }
.contact-form.eg-form .eg-type:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.eg-types-fieldset[aria-invalid="true"] .eg-type { border-color: var(--danger); }
.eg-js .eg-type-fields[hidden] { display: none; }
.eg-js .eg-nojs-only { display: none; }
.eg-type-extras { margin-bottom: var(--s-1); }
.eg-type-extras .eg-type-fields { padding: var(--s-3); margin-bottom: var(--s-2); background: var(--mist); border: 1px solid var(--line); border-radius: var(--radius); }
.eg-type-extras .eg-type-fields legend { float: left; width: 100%; padding: 0; margin-bottom: var(--s-1); }
.eg-type-extras .eg-type-fields legend + * { clear: both; }

.eg-elsewhere { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-3); max-width: 64rem; margin: var(--s-5) auto 0; padding-top: var(--s-4); border-top: 1px solid var(--line); }
.eg-elsewhere h2 { margin-bottom: 0.35em; font-size: 1.05rem; }
.eg-elsewhere p { margin-bottom: 0.5em; font-size: 0.92rem; color: var(--muted); overflow-wrap: anywhere; }

/* ------------------------------------------------------------- Support */

.eg-split { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: var(--s-4); align-items: start; }
.eg-split > h2 { margin: 0; }
.eg-why ul { list-style: none; padding: 0; }
.eg-why li { position: relative; margin: 0 0 var(--s-2); padding: 0 0 var(--s-2) 1.6em; border-bottom: 1px solid var(--line); font-size: 1.05rem; }
.eg-why li:last-child { border-bottom: 0; }
.eg-why li::before { content: ""; position: absolute; left: 0; top: 0.65em; width: 0.7em; height: 1px; background: var(--accent); }
.eg-section-title { margin-bottom: var(--s-3); }
.eg-section-lede { margin-top: calc(var(--s-2) * -1); margin-bottom: var(--s-3); }
.eg-ways { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: var(--s-3); }
.eg-way { padding: var(--s-3); border-top: 2px solid var(--ink); background: var(--mist); }
.eg-way-num { display: block; margin-bottom: var(--s-2); font-family: var(--font-serif); font-size: 2.2rem; font-weight: 300; line-height: 1; color: var(--accent); }
.eg-way h3 { margin-bottom: 0.4em; font-size: 1.12rem; }
.eg-way p { margin: 0; font-size: 0.95rem; color: var(--muted); }
.eg-tiers { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr)); gap: var(--s-3); }
.eg-tier { display: flex; flex-direction: column; padding: var(--s-3); background: var(--paper); border: 1px solid var(--line); border-top: 3px solid var(--accent); border-radius: var(--radius); }
.eg-tier h3 { margin-bottom: 0.2em; font-family: var(--font-serif); font-weight: 500; font-size: 1.5rem; }
.eg-tier-amount { margin-bottom: var(--s-2); font-weight: 600; color: var(--accent-dark); }
.eg-tier ul { flex: 1; margin: 0 0 var(--s-3); padding: 0; list-style: none; }
.eg-tier li { display: flex; gap: 0.55em; margin-bottom: 0.5em; font-size: 0.94rem; }
.eg-tier li .eg-icon { margin-top: 0.25em; color: var(--accent); }
.eg-tier .btn { align-self: flex-start; }
.eg-bank { padding: var(--s-3); background: var(--paper); border: 1px solid var(--line); border-left: 3px solid var(--ink); }
.eg-bank dl, .eg-reg { margin: 0; }
.eg-bank dl div, .eg-reg div { display: grid; grid-template-columns: minmax(8rem, 0.4fr) 1fr; gap: var(--s-2); padding: 0.6rem 0; border-bottom: 1px solid var(--line); }
.eg-bank dt, .eg-reg dt { font-size: 0.85rem; color: var(--muted); }
.eg-bank dd, .eg-reg dd { margin: 0; font-weight: 500; color: var(--ink); overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.eg-bank-note { margin-top: var(--s-2); font-size: 0.92rem; color: var(--muted); }

/* --------------------------------------------------------- Transparency */

.eg-doc { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: var(--s-5); align-items: start; }
.eg-toc { position: sticky; top: calc(var(--header-h) + var(--s-2)); }
.eg-toc-title { margin-bottom: var(--s-1); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent-dark); }
.eg-toc ol { margin: 0; padding: 0; list-style: none; border-left: 1px solid var(--line); }
.eg-toc a { display: block; padding: 0.4em 0 0.4em var(--s-2); margin-left: -1px; font-size: 0.92rem; color: var(--muted); border-left: 2px solid transparent; }
.eg-toc a:hover, .eg-toc a.is-current { color: var(--ink); border-left-color: var(--accent); }
.eg-doc-section { padding-bottom: var(--s-4); margin-bottom: var(--s-4); border-bottom: 1px solid var(--line); }
.eg-doc-section:last-child { border-bottom: 0; }
.eg-doc-section .prose { max-width: 70ch; }
.eg-reports { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.eg-reports li { display: grid; grid-template-columns: 4.5rem 1fr auto; gap: var(--s-2); align-items: center; padding: var(--s-2) 0; border-bottom: 1px solid var(--line); }
.eg-report-year { font-family: var(--font-serif); font-size: 1.5rem; color: var(--accent-dark); }
.eg-report-title { font-weight: 500; color: var(--ink); }
.eg-report-link { display: inline-flex; align-items: center; gap: 0.4em; padding: 0.45em 0.9em; font-size: 0.85rem; color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius); white-space: nowrap; }
.eg-report-link:hover { border-color: var(--accent); color: var(--accent-dark); }

/* ---------------------------------------------------------- Responsive */

@media (max-width: 980px) {
  .eg-layout, .eg-doc { grid-template-columns: 1fr; gap: var(--s-4); }
  .eg-aside, .eg-toc { position: static; }
  .eg-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .eg-elsewhere { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .eg-cards, .eg-cards.is-open, .eg-grid, .eg-files, .eg-split, .eg-elsewhere { grid-template-columns: 1fr; }
  .eg-split { gap: var(--s-2); }
  .eg-role { grid-template-columns: 1fr; }
  .eg-role-side { align-items: flex-start; }
  .eg-form-wrap { padding: var(--s-3) var(--s-2); margin: 0 calc(var(--s-1) * -1); }
  .eg-confirm { grid-template-columns: 1fr; padding: var(--s-3); }
  .eg-reports li { grid-template-columns: 3.5rem 1fr; }
  .eg-report-link { grid-column: 2; justify-self: start; }
  .eg-bank dl div, .eg-reg div { grid-template-columns: 1fr; gap: 0.1rem; }
  .eg-panel { padding: var(--s-3); }
  .eg-cta .btn { width: 100%; text-align: center; }
  .eg-subnav ul { gap: var(--s-3); }
}

/* ===================================================== Admin (egx-) */

.egx-pill { font-size: 0.68rem; letter-spacing: 0.06em; }
.egx-pill.is-open, .egx-pill.is-accepted { color: var(--success); background: var(--success-soft); border-color: #CDE3D5; }
.egx-pill.is-soon, .egx-pill.is-received, .egx-pill.is-new { color: var(--accent-dark); background: var(--accent-soft); border-color: #DCD0EC; }
.egx-pill.is-ongoing, .egx-pill.is-shortlisted, .egx-pill.is-in_progress { color: #8A5A00; background: #FFF4DE; border-color: #F1DDB0; }
.egx-pill.is-interview { color: #1F5A8A; background: #E7F1FA; border-color: #C6DDF0; }
.egx-pill.is-closed, .egx-pill.is-withdrawn, .egx-pill.is-done { color: var(--muted); background: #F1EFF4; border-color: var(--line); }
.egx-pill.is-declined { color: var(--danger); background: var(--danger-soft); border-color: #EBCFCF; }

.egx-error { margin: 6px 0 0; font-size: 0.85rem; color: var(--danger); font-weight: 500; }
.egx-form .card { margin-bottom: 20px; }
.egx-prefix { display: flex; align-items: stretch; min-width: 0; }
.egx-prefix span { display: flex; align-items: center; padding: 0 10px; font-size: 0.85rem; color: var(--muted); background: var(--mist); border: 1px solid var(--line-strong); border-right: 0; border-radius: var(--radius) 0 0 var(--radius); white-space: nowrap; max-width: 55%; overflow: hidden; text-overflow: ellipsis; }
.egx-prefix input { flex: 1; min-width: 0; border-radius: 0 var(--radius) var(--radius) 0 !important; }
.egx-danger { margin-top: 26px; }
.egx-danger h2 { font-size: 1.05rem; margin-top: 0; }

.egx-banner-card { margin-top: 10px; }
.egx-card-actions { margin-top: 16px; }
.egx-banner-status { padding: 10px 14px; background: var(--mist); border-radius: 6px; font-size: 0.92rem; }

.egx-tabs { margin-bottom: 22px; }
.egx-types { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.egx-type, .egx-tier { min-width: 0; margin: 0; padding: 14px 16px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--mist); }
.egx-type legend, .egx-tier legend { padding: 0 6px; font-weight: 700; color: var(--ink); }
.egx-type .form-grid { margin-bottom: 0; align-items: end; }
.egx-check-inline { align-self: center; margin: 0; }
.egx-tiers { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.egx-report-form { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); }

.egx-filters { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.8fr) minmax(0, 1.2fr) auto; gap: 14px; align-items: end; margin-bottom: 18px; }
.egx-filters .field { margin: 0; }
.egx-filter-actions { display: flex; align-items: center; gap: 12px; }

.egx-pipeline { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 0; margin: 0 0 20px; padding: 0; list-style: none; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.egx-pipeline.is-short { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.egx-pipeline li + li { border-left: 1px solid var(--line); }
.egx-stage { display: flex; flex-direction: column; gap: 2px; padding: 12px 16px; text-decoration: none; color: var(--text); border-top: 3px solid transparent; height: 100%; }
.egx-stage:hover { background: var(--mist); color: var(--text); }
.egx-stage.is-current { background: var(--accent-soft); border-top-color: var(--accent); }
.egx-stage-num { font-size: 1.5rem; font-weight: 700; color: var(--ink); line-height: 1.1; font-variant-numeric: tabular-nums; }
.egx-stage-label { font-size: 0.8rem; color: var(--muted); }
.egx-stage.is-accepted .egx-stage-num { color: var(--success); }
.egx-stage.is-declined .egx-stage-num { color: var(--danger); }

.egx-table .cell-sub { display: block; }
.egx-doc { display: inline-block; padding: 2px 8px; font-size: 0.78rem; font-weight: 600; border: 1px solid var(--line-strong); border-radius: 4px; text-decoration: none; }
.egx-doc:hover { border-color: var(--accent); background: var(--accent-soft); }
.egx-snippet { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 0.88rem; color: var(--muted); max-width: 42ch; }
.egx-inline-status { display: flex; gap: 6px; align-items: center; }
.egx-inline-status select { min-width: 8.5rem; }
.ev-js .js-hide-when-auto, .eg-js .js-hide-when-auto { display: none; }
tr.is-unread td:first-child { box-shadow: inset 3px 0 0 var(--accent); }

.egx-app { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 22px; align-items: start; }
.egx-app-main .card, .egx-app-side .card { margin-bottom: 20px; }
.egx-app-main .meta-list { grid-template-columns: max-content minmax(0, 1fr); }
.egx-docs { display: flex; flex-wrap: wrap; gap: 12px; }
.egx-file { display: flex; align-items: center; gap: 12px; padding: 12px 16px; min-width: 15rem; text-decoration: none; color: var(--text); border: 1px solid var(--line-strong); border-radius: var(--radius); }
.egx-file:hover { border-color: var(--accent); background: var(--accent-soft); color: var(--text); }
.egx-file > span:last-child { display: flex; flex-direction: column; }
.egx-file .muted { font-size: 0.82rem; }
.egx-file-icon { display: grid; place-items: center; width: 38px; height: 46px; font-size: 0.68rem; font-weight: 800; letter-spacing: 0.04em; color: #fff; background: var(--danger); border-radius: 4px; }
.egx-words { font-size: 0.82rem; font-weight: 500; margin-left: 6px; }
.egx-statement { margin-top: 0; white-space: normal; }
.egx-statement p { margin: 0 0 1em; }
.egx-statement p:last-child { margin-bottom: 0; }
.egx-status-card .check { margin-bottom: 14px; }
.eg-js .egx-notify[hidden] { display: none; }
.egx-log { margin: 0; padding: 0; list-style: none; }
.egx-log li { position: relative; padding: 0 0 12px 18px; font-size: 0.86rem; border-left: 2px solid var(--line); margin-left: 4px; }
.egx-log li::before { content: ""; position: absolute; left: -6px; top: 4px; width: 10px; height: 10px; border-radius: 50%; background: var(--paper); border: 2px solid var(--accent); }
.egx-log li:last-child { padding-bottom: 0; }
.egx-log time { display: block; font-size: 0.76rem; color: var(--muted); }

@media (max-width: 1100px) {
  .egx-app { grid-template-columns: 1fr; }
  .egx-filters { grid-template-columns: 1fr 1fr; }
  .egx-pipeline { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .egx-pipeline li:nth-child(4) { border-left: 0; }
  .egx-pipeline li:nth-child(n + 4) { border-top: 1px solid var(--line); }
}
@media (max-width: 720px) {
  .egx-types, .egx-filters { grid-template-columns: 1fr; }
  .egx-prefix span { display: none; }
  .egx-prefix input { border-radius: var(--radius) !important; }
  .egx-file { min-width: 0; width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .eg-pill.is-open::before { animation: none; }
  .eg-card, .eg-card:hover { transform: none; }
}
