/* ==========================================================================
   PRESSBUREAU — 2026 design system
   --------------------------------------------------------------------------
   Single stylesheet, no framework, no webfont requests (so LCP stays fast and
   the site works offline/under a slow connection).

   Colour language: deep government navy as the authority base, saffron as a
   sparing accent for emphasis, and a neutral slate ramp for text and surfaces.

   Contents
     1.  Tokens
     2.  Reset & base
     3.  Accessibility helpers
     4.  Layout primitives
     5.  Header / masthead / navigation
     6.  Breaking ticker
     7.  Cards
     8.  Home page sections
     9.  Article page
     10. Listing pages (category / search / archive / tag)
     11. Sidebar
     12. Forms & buttons
     13. Pagination
     14. Footer
     15. Utilities
     16. Motion
     17. Responsive
   ========================================================================== */

/* ==========================================================================
   1. Tokens
   ========================================================================== */
:root {
  /* Navy — brand and authority */
  --navy-950: #04101f;
  --navy-900: #071a33;
  --navy-800: #0b2545;
  --navy-700: #13315c;
  --navy-600: #1b4079;
  --navy-500: #2b5490;
  --navy-100: #e8eef7;

  /* Saffron — accent, used sparingly */
  --saffron-700: #a8550a;
  --saffron-600: #c2610a;
  --saffron-500: #e8871e;
  --saffron-400: #ff9933;
  --saffron-100: #fff3e3;

  /* Supporting tones for category accents */
  --teal-600: #0f6b6b;
  --teal-100: #e2f3f2;
  --indigo-600: #3b4a8f;
  --indigo-100: #eaedf9;
  --green-600: #146c43;
  --green-100: #e4f4ea;
  --red-600: #a52a2a;

  /* Neutrals */
  --ink: #16202e;
  --ink-soft: #33415a;
  --slate-700: #3f4f66;
  --slate-600: #4a5a6e;
  --slate-500: #64748b;
  --slate-400: #94a3b8;
  --slate-300: #cbd5e1;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --canvas: #f5f7fa;
  --surface: #ffffff;

  /* Typography */
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", "Noto Sans", Arial, sans-serif;
  --font-serif: Georgia, "Iowan Old Style", "Source Serif Pro", "Noto Serif",
    "Times New Roman", serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* Spacing scale */
  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.5rem;
  --sp-6: 2rem;
  --sp-7: 2.5rem;
  --sp-8: 3rem;
  --sp-9: 4rem;

  /* Radius */
  --r-sm: 4px;
  --r-md: 8px;
  --r-lg: 12px;
  --r-xl: 16px;
  --r-pill: 999px;

  /* Elevation */
  --shadow-xs: 0 1px 2px rgba(7, 26, 51, 0.06);
  --shadow-sm: 0 1px 3px rgba(7, 26, 51, 0.08), 0 1px 2px rgba(7, 26, 51, 0.04);
  --shadow-md: 0 4px 12px rgba(7, 26, 51, 0.08), 0 2px 4px rgba(7, 26, 51, 0.04);
  --shadow-lg: 0 12px 28px rgba(7, 26, 51, 0.10), 0 4px 10px rgba(7, 26, 51, 0.05);
  --shadow-xl: 0 24px 48px rgba(7, 26, 51, 0.14);

  /* Motion */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 120ms;
  --dur: 220ms;
  --dur-slow: 380ms;

  /* Layout */
  --container: 1240px;
  --container-narrow: 780px;
  --gutter: 1.25rem;
  --header-h: 64px;
}

/* ==========================================================================
   2. Reset & base
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem);
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink-soft);
  background: var(--canvas);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0 0 var(--sp-3);
  font-family: var(--font-serif);
  color: var(--navy-900);
  line-height: 1.22;
  font-weight: 700;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(1.85rem, 1.3rem + 2.1vw, 2.85rem); }
h2 { font-size: clamp(1.45rem, 1.15rem + 1.2vw, 1.95rem); }
h3 { font-size: clamp(1.15rem, 1.02rem + 0.55vw, 1.4rem); }
h4 { font-size: 1.05rem; }

p { margin: 0 0 var(--sp-4); }

a {
  color: var(--navy-700);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease);
}

a:hover { color: var(--saffron-600); }

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

ul, ol { margin: 0 0 var(--sp-4); padding-left: 1.15rem; }

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

hr {
  border: 0;
  border-top: 1px solid var(--slate-200);
  margin: var(--sp-6) 0;
}

/* ==========================================================================
   3. Accessibility helpers
   ========================================================================== */
:focus-visible {
  outline: 3px solid var(--saffron-500);
  outline-offset: 2px;
  border-radius: var(--r-sm);
}

.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: var(--sp-4);
  z-index: 2000;
  padding: var(--sp-3) var(--sp-5);
  background: var(--navy-800);
  color: #fff;
  font-weight: 600;
  border-radius: 0 0 var(--r-md) var(--r-md);
  transition: top var(--dur) var(--ease);
}

.skip-link:focus {
  top: 0;
  color: #fff;
}

/* ==========================================================================
   4. Layout primitives
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--narrow { max-width: var(--container-narrow); }

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: var(--sp-7);
  align-items: start;
  padding-block: var(--sp-7);
}

.layout--wide {
  grid-template-columns: minmax(0, 1fr);
}

.layout__main { min-width: 0; }

/* Section heading with the saffron rule used across the site. */
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-4);
  margin-bottom: var(--sp-5);
  padding-bottom: var(--sp-3);
  border-bottom: 2px solid var(--slate-200);
}

.section-head__title {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin: 0;
  font-size: clamp(1.2rem, 1.05rem + 0.6vw, 1.5rem);
}

.section-head__title::before {
  content: "";
  width: 4px;
  height: 1.35em;
  background: linear-gradient(180deg, var(--saffron-400), var(--saffron-600));
  border-radius: 2px;
}

.section-head__link {
  flex-shrink: 0;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--navy-600);
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  white-space: nowrap;
}

.section-head__link:hover { color: var(--saffron-600); }

.section-head__link svg { transition: transform var(--dur) var(--ease); }
.section-head__link:hover svg { transform: translateX(3px); }

/* ==========================================================================
   5. Header / masthead / navigation
   ========================================================================== */

/* --- Announcement bar --------------------------------------------------- */
.announce {
  background: var(--navy-950);
  color: #dce6f3;
  font-size: 0.8125rem;
}

.announce__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  min-height: 38px;
  padding-block: 0.375rem;
}

.announce__label {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--saffron-400);
  white-space: nowrap;
}

.announce__text {
  margin: 0;
  color: #cbd8ea;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.announce__meta {
  display: none;
  align-items: center;
  gap: var(--sp-4);
  color: #94a9c4;
  white-space: nowrap;
}

.announce__meta a { color: #cbd8ea; }
.announce__meta a:hover { color: var(--saffron-400); }

/* --- Masthead ----------------------------------------------------------- */
.masthead {
  background: var(--surface);
  border-bottom: 1px solid var(--slate-200);
}

.masthead__inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--sp-5);
  padding-block: var(--sp-5);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-3);
  color: var(--navy-900);
  flex-shrink: 0;
}

.brand:hover { color: var(--navy-900); }

.brand__mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: linear-gradient(145deg, var(--navy-700), var(--navy-900));
  color: var(--saffron-400);
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
}

.brand__mark svg { width: 26px; height: 26px; }

.brand__text { display: flex; flex-direction: column; }

.brand__name {
  font-family: var(--font-serif);
  font-size: 1.65rem;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.brand__name em {
  font-style: normal;
  color: var(--saffron-600);
}

.brand__tagline {
  font-size: 0.6875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--slate-500);
  font-weight: 600;
  margin-top: 0.1875rem;
}

/* Small official badge, e.g. "Government of India" style strip. */
.masthead__badges {
  display: flex;
  justify-content: center;
  gap: var(--sp-2);
  flex-wrap: wrap;
}

.badge-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 0.3125rem var(--sp-3);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-pill);
  background: var(--slate-100);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--navy-700);
}

.badge-chip__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--saffron-500);
}

.badge-chip--live .badge-chip__dot {
  background: #16a34a;
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.16);
  animation: pulse-dot 2.4s var(--ease) infinite;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.16); }
  50%      { box-shadow: 0 0 0 6px rgba(22, 163, 74, 0.05); }
}

.masthead__actions {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
}

/* --- Header search ------------------------------------------------------ */
.header-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 0.375rem 0.375rem 0.375rem var(--sp-3);
  background: var(--slate-100);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-pill);
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
  width: 210px;
}

.header-search:focus-within {
  background: var(--surface);
  border-color: var(--navy-500);
}

.header-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  font-size: 0.875rem;
  padding: 0.25rem 0;
}

.header-search input:focus { outline: none; }
.header-search input::placeholder { color: var(--slate-400); }

.header-search button {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: var(--navy-800);
  color: #fff;
  cursor: pointer;
  transition: background var(--dur) var(--ease);
  flex-shrink: 0;
}

.header-search button:hover { background: var(--saffron-600); }

/* Suggestions float below the search field instead of stretching its row. */
.search-suggest {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 1000;
  width: min(420px, calc(100vw - 32px));
  max-height: min(360px, 50vh);
  overflow-y: auto;
  overscroll-behavior: contain;
  margin: 0;
  padding: var(--sp-2);
  list-style: none;
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-lg);
}
.search-suggest[hidden] { display: none; }
.search-suggest li { border-radius: var(--r-sm); }
.search-suggest li + li { border-top: 1px solid var(--slate-200); }
.search-suggest a { display: block; padding: var(--sp-3); color: var(--navy-800); }
.search-suggest__title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.5;
}
.search-suggest__meta { display: block; margin-top: var(--sp-1); color: var(--slate-500); font-size: 0.75rem; }
.search-suggest li:hover, .search-suggest .is-active { background: var(--slate-100); }
.search-suggest a:focus-visible { outline: 2px solid var(--navy-500); outline-offset: -2px; }
.search-suggest__all a { color: var(--navy-600); font-size: 0.8125rem; font-weight: 700; }
.mobile-quick-links { display: none; }

/* --- Primary navigation ------------------------------------------------- */
.nav {
  background: var(--navy-800);
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 0;
  z-index: 900;
  border-bottom: 3px solid var(--saffron-500);
}

.nav__inner {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  min-height: var(--header-h);
}

.nav__toggle {
  display: none;
  align-items: center;
  gap: var(--sp-2);
  padding: 0.5rem var(--sp-3);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--r-md);
  background: transparent;
  color: #fff;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
}

.nav__list {
  display: flex;
  align-items: stretch;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
  min-width: 0;
}

.nav__item { position: relative; }

.nav__link {
  display: flex;
  align-items: center;
  gap: var(--sp-1);
  padding: 0 var(--sp-4);
  min-height: var(--header-h);
  color: #d3dfef;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  transition: color var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease),
    border-color var(--dur-fast) var(--ease);
}

.nav__link:hover,
.nav__link:focus-visible {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
  border-bottom-color: var(--saffron-400);
}

.nav__link svg {
  width: 10px;
  height: 10px;
  transition: transform var(--dur) var(--ease);
  opacity: 0.75;
}

.nav__item--open .nav__link { color: #fff; background: rgba(255, 255, 255, 0.06); }
.nav__item--open .nav__link svg { transform: rotate(180deg); }

/* Dropdown */
.nav__dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 250px;
  padding: var(--sp-2) 0;
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-top: 3px solid var(--saffron-500);
  border-radius: 0 0 var(--r-md) var(--r-md);
  box-shadow: var(--shadow-lg);
  list-style: none;
  margin: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease-out),
    visibility var(--dur) var(--ease);
  max-height: 70vh;
  overflow-y: auto;
  z-index: 10;
}

.nav__item:hover .nav__dropdown,
.nav__item:focus-within .nav__dropdown,
.nav__item--open .nav__dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav__dropdown a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  padding: 0.5625rem var(--sp-4);
  color: var(--ink-soft);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: normal;
  text-transform: none;
  border-left: 3px solid transparent;
  transition: background var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}

.nav__dropdown a:hover,
.nav__dropdown a:focus-visible {
  background: var(--slate-100);
  color: var(--navy-800);
  border-left-color: var(--saffron-500);
}

.nav__dropdown .nav__count {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--slate-400);
  background: var(--slate-100);
  padding: 0.0625rem var(--sp-2);
  border-radius: var(--r-pill);
}

.nav__cta {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  flex-shrink: 0;
}

.nav__cta-link {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 0.5rem var(--sp-4);
  border-radius: var(--r-pill);
  background: var(--saffron-500);
  color: var(--navy-950);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  white-space: nowrap;
  transition: background var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.nav__cta-link:hover {
  background: var(--saffron-400);
  color: var(--navy-950);
  transform: translateY(-1px);
}

/* Breadcrumb */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-2);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.8125rem;
  color: var(--slate-500);
}

.breadcrumb li { display: flex; align-items: center; gap: var(--sp-2); }

.breadcrumb li + li::before {
  content: "/";
  color: var(--slate-300);
}

.breadcrumb a { color: var(--slate-600); font-weight: 500; }
.breadcrumb a:hover { color: var(--saffron-600); }
.breadcrumb [aria-current="page"] { color: var(--navy-800); font-weight: 600; }

/* Page masthead block used by listing pages */
.page-head {
  background: linear-gradient(135deg, var(--navy-800), var(--navy-950));
  color: #fff;
  padding-block: var(--sp-6);
}

.page-head h1 {
  color: #fff;
  margin-bottom: var(--sp-2);
}

.page-head__lede {
  color: #b9c9de;
  margin: 0;
  max-width: 70ch;
  font-size: 0.9375rem;
}

.page-head .breadcrumb,
.page-head .breadcrumb a { color: #9fb3cd; }
.page-head .breadcrumb a:hover { color: var(--saffron-400); }
.page-head .breadcrumb li + li::before { color: #4a6280; }
.page-head .breadcrumb [aria-current="page"] { color: #fff; }

/* ==========================================================================
   6. Breaking ticker
   ========================================================================== */
.ticker {
  background: var(--surface);
  border-bottom: 1px solid var(--slate-200);
  overflow: hidden;
}

.ticker__inner {
  display: flex;
  align-items: center;
  gap: 0;
  min-height: 44px;
}

.ticker__flag {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  flex-shrink: 0;
  height: 44px;
  padding-inline: var(--sp-4);
  background: linear-gradient(135deg, var(--saffron-500), var(--saffron-600));
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.ticker__flag svg { animation: flash 2s var(--ease) infinite; }

@keyframes flash {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.35; }
}

.ticker__viewport {
  position: relative;
  flex: 1;
  min-width: 0;
  height: 44px;
  overflow: hidden;
}

.ticker__track {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  gap: var(--sp-7);
  padding-left: var(--sp-4);
  will-change: transform;
  animation: ticker-scroll 46s linear infinite;
}

.ticker:hover .ticker__track,
.ticker__track:focus-within {
  animation-play-state: paused;
}

@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

.ticker__item {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  color: var(--ink-soft);
  font-size: 0.875rem;
  font-weight: 500;
  white-space: nowrap;
}

.ticker__item:hover { color: var(--saffron-600); }

.ticker__item::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--saffron-500);
  flex-shrink: 0;
}

.ticker__time {
  color: var(--slate-400);
  font-size: 0.75rem;
  font-weight: 600;
  flex-shrink: 0;
}

.ticker__item:hover .ticker__time { color: var(--slate-500); }

@media (prefers-reduced-motion: reduce) {
  .ticker__track { animation: none; }
  .ticker__viewport { overflow-x: auto; }
}

/* ==========================================================================
   7. Cards
   ========================================================================== */
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow-xs);
  transition: transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease),
    border-color var(--dur) var(--ease);
  height: 100%;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  border-color: var(--slate-300);
}

/* Whole-card click target without nesting interactive elements. */
.card__link::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}

.card__media {
  position: relative;
  aspect-ratio: 16 / 10;
  background: var(--slate-100);
  overflow: hidden;
}

.card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--dur-slow) var(--ease-out), opacity var(--dur) var(--ease);
}

.card:hover .card__media img { transform: scale(1.045); }

.card--original-image .card__media { background: var(--slate-100); }
.card--original-image .card__media img { object-fit: contain; }
.card--original-image:hover .card__media img { transform: none; }

.card__media img.is-placeholder {
  transform: none;
  opacity: 1;
}

.card__media::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 40%;
  background: linear-gradient(to top, rgba(4, 16, 31, 0.28), transparent);
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--dur) var(--ease);
}

.card:hover .card__media::after { opacity: 1; }

.card__flag {
  position: absolute;
  top: var(--sp-3);
  left: var(--sp-3);
  z-index: 2;
  padding: 0.25rem var(--sp-3);
  border-radius: var(--r-pill);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--navy-800);
  color: #fff;
  box-shadow: var(--shadow-sm);
}

.card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: var(--sp-2);
  padding: var(--sp-4) var(--sp-4) var(--sp-4);
}

.card__title {
  margin: 0;
  font-size: 1.0625rem;
  line-height: 1.34;
  font-weight: 700;
  color: var(--navy-900);
  /* clamp to 3 lines so cards in a row stay the same height */
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card__title a { color: inherit; }

.card:hover .card__title {
  color: var(--navy-700);
}

.card__excerpt {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--slate-600);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin-top: auto;
  padding-top: var(--sp-3);
  border-top: 1px solid var(--slate-100);
  font-size: 0.75rem;
  color: var(--slate-500);
}

.card__meta-item {
  display: inline-flex;
  align-items: center;
  gap: 0.3125rem;
}

.card__meta-item svg { width: 12px; height: 12px; opacity: 0.7; }
.card__meta-dot { color: var(--slate-300); }

.card__tag {
  display: inline-flex;
  align-items: center;
  padding: 0.125rem var(--sp-2);
  border-radius: var(--r-sm);
  background: var(--slate-100);
  color: var(--slate-600);
  font-size: 0.6875rem;
  font-weight: 600;
  transition: background var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}

.card:hover .card__tag { background: var(--navy-100); color: var(--navy-700); }

/* --- Grid --------------------------------------------------------------- */
.grid {
  display: grid;
  gap: var(--sp-5);
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
}

.grid--tight { gap: var(--sp-4); }

/* --- Compact list row ---------------------------------------------------- */
.post-row {
  position: relative;
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: var(--sp-4);
  padding: var(--sp-4);
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-md);
  transition: transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease),
    border-color var(--dur) var(--ease);
}

.post-row:hover {
  transform: translateX(3px);
  box-shadow: var(--shadow-md);
  border-color: var(--slate-300);
}

.post-row__media {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: var(--r-sm);
  overflow: hidden;
  background: var(--slate-100);
}

.post-row__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--dur-slow) var(--ease-out);
}

.post-row:hover .post-row__media img { transform: scale(1.05); }

.post-row__body {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  min-width: 0;
}

.post-row__title {
  margin: 0;
  font-size: 1rem;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-row__title a { color: var(--navy-900); }
.post-row:hover .post-row__title a { color: var(--navy-700); }

/* --- Hero / featured ----------------------------------------------------- */
.hero {
  position: relative;
  margin-bottom: var(--sp-6);
}

.hero__card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  background: var(--navy-950);
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
}

.hero__media {
  position: relative;
  min-height: 380px;
  background: var(--navy-900);
  overflow: hidden;
}

.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.92;
}

.hero__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 45%, var(--navy-950) 100%);
}

.hero__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: var(--sp-4);
  padding: var(--sp-7);
  color: #d7e2f0;
}

.hero__flag {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  align-self: flex-start;
  padding: 0.3125rem var(--sp-3);
  border-radius: var(--r-pill);
  background: rgba(255, 153, 51, 0.16);
  border: 1px solid rgba(255, 153, 51, 0.4);
  color: var(--saffron-400);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero__title {
  margin: 0;
  font-size: clamp(1.5rem, 1.1rem + 1.9vw, 2.35rem);
  line-height: 1.18;
  color: #fff;
}

.hero__title a { color: #fff; }
.hero__title a:hover { color: var(--saffron-400); }

.hero__excerpt {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.65;
  color: #a8bcd6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-3);
  font-size: 0.8125rem;
  color: #8ba3c2;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
  margin-top: var(--sp-1);
}

/* --- Secondary feature (2-up) ------------------------------------------- */
.hero-pair {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--sp-5);
  margin-bottom: var(--sp-7);
}

/* Category tone accents */
.tone-saffron .card__flag,
.hero__flag.tone-saffron { background: var(--saffron-600); }
.card__flag.tone-teal   { background: var(--teal-600); }
.card__flag.tone-navy   { background: var(--navy-700); }
.card__flag.tone-indigo { background: var(--indigo-600); }
.card__flag.tone-slate  { background: var(--slate-600); }

.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  padding: 0.25rem var(--sp-3);
  border-radius: var(--r-pill);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.chip--teal   { background: var(--teal-100); color: var(--teal-600); }
.chip--saffron{ background: var(--saffron-100); color: var(--saffron-700); }
.chip--navy   { background: var(--navy-100); color: var(--navy-700); }
.chip--indigo { background: var(--indigo-100); color: var(--indigo-600); }
.chip--slate  { background: var(--slate-100); color: var(--slate-600); }
.chip--green  { background: var(--green-100); color: var(--green-600); }
.chip--red    { background: #fde8e8; color: var(--red-600); }

/* ==========================================================================
   8. Home page sections
   ========================================================================== */
.section { margin-bottom: var(--sp-8); }
.section--tight { margin-bottom: var(--sp-6); }

.section--ruled {
  padding-top: var(--sp-6);
  border-top: 1px solid var(--slate-200);
}

.stack { display: grid; gap: var(--sp-4); }
.stack--tight { gap: var(--sp-3); }

.cols-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--sp-5);
}

/* Compact numbered list used for trending / most read */
.rank-list {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: rank;
}

.rank-list li { counter-increment: rank; }

.rank-list__item {
  position: relative;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: var(--sp-3);
  align-items: start;
  padding: var(--sp-4) 0;
  border-bottom: 1px solid var(--slate-100);
}

.rank-list__item:last-child { border-bottom: 0; }

.rank-list__item::before {
  content: counter(rank, decimal-leading-zero);
  font-family: var(--font-serif);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--slate-300);
  line-height: 1.2;
  transition: color var(--dur) var(--ease);
}

.rank-list__item:hover::before { color: var(--saffron-500); }

.rank-list__title {
  margin: 0 0 var(--sp-1);
  font-size: 0.9375rem;
  line-height: 1.38;
  font-weight: 600;
}

.rank-list__title a { color: var(--navy-900); }
.rank-list__item:hover .rank-list__title a { color: var(--navy-700); }

.rank-list__meta {
  font-size: 0.6875rem;
  color: var(--slate-400);
  display: flex;
  align-items: center;
  gap: var(--sp-2);
}

/* Latest updates timeline */
.timeline { list-style: none; margin: 0; padding: 0; }

.timeline li {
  position: relative;
  padding: var(--sp-4) 0 var(--sp-4) var(--sp-6);
  border-bottom: 1px dashed var(--slate-200);
}

.timeline li:last-child { border-bottom: 0; }

.timeline li::before {
  content: "";
  position: absolute;
  left: 0;
  top: calc(var(--sp-4) + 0.4em);
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--saffron-500);
}

.timeline li::after {
  content: "";
  position: absolute;
  left: 4px;
  top: calc(var(--sp-4) + 1.35em);
  bottom: -0.25rem;
  width: 1px;
  background: var(--slate-200);
}

.timeline li:last-child::after { display: none; }

.timeline__title {
  margin: 0 0 var(--sp-1);
  font-size: 0.9375rem;
  line-height: 1.4;
  font-weight: 600;
}

.timeline__title a { color: var(--navy-900); }
.timeline li:hover .timeline__title a { color: var(--navy-700); }

.timeline__time {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--saffron-600);
}

/* Topic tiles */
.topic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: var(--sp-3);
}

.topic {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
  padding: var(--sp-4);
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-md);
  transition: transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease),
    border-color var(--dur) var(--ease);
  overflow: hidden;
}

.topic::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: var(--saffron-500);
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform var(--dur) var(--ease-out);
}

.topic:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--slate-300);
}

.topic:hover::before { transform: scaleY(1); }

.topic__name {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--navy-900);
  letter-spacing: -0.01em;
}

.topic__count {
  font-size: 0.75rem;
  color: var(--slate-500);
}

/* CTA band */
.cta-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--sp-5);
  padding: var(--sp-6);
  border-radius: var(--r-xl);
  background: linear-gradient(135deg, var(--navy-800), var(--navy-950));
  color: #cddaea;
  overflow: hidden;
  position: relative;
}

.cta-band::after {
  content: "";
  position: absolute;
  right: -40px;
  top: -40px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 153, 51, 0.18), transparent 68%);
}

.cta-band h3 { color: #fff; margin-bottom: var(--sp-1); }
.cta-band p { margin: 0; font-size: 0.9375rem; color: #a8bcd6; }

/* ==========================================================================
   9. Article page
   ========================================================================== */
.article {
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.article__header {
  padding: var(--sp-6) var(--sp-6) var(--sp-5);
  border-bottom: 1px solid var(--slate-100);
}

.article__flags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-2);
  margin-bottom: var(--sp-3);
}

.article__title {
  margin: 0 0 var(--sp-4);
  font-size: clamp(1.7rem, 1.2rem + 2.3vw, 2.6rem);
  line-height: 1.18;
}

.article__lede {
  margin: 0 0 var(--sp-4);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--slate-600);
  font-family: var(--font-serif);
  font-style: italic;
}

.article__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-2) var(--sp-4);
  font-size: 0.8125rem;
  color: var(--slate-500);
}

.article__meta-item {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
}

.article__meta-item svg { width: 14px; height: 14px; color: var(--slate-400); }

.article__byline {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-weight: 600;
  color: var(--navy-700);
}

.article__avatar {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--navy-800);
  color: #fff;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  flex-shrink: 0;
}

.article__figure {
  margin: 0;
  background: var(--slate-100);
}

.article__figure img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
}

.article__caption {
  padding: var(--sp-2) var(--sp-6) 0;
  margin: 0;
  font-size: 0.75rem;
  color: var(--slate-500);
  background: var(--surface);
}

/* Reading progress indicator */
.read-progress {
  position: fixed;
  top: calc(var(--header-h) + 3px);
  left: 0;
  z-index: 950;
  height: 3px;
  width: 0;
  background: linear-gradient(90deg, var(--saffron-400), var(--saffron-600));
  transition: width 80ms linear;
}

/* Share rail */
.share {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-4) var(--sp-6);
  background: var(--slate-100);
  border-block: 1px solid var(--slate-200);
}

.share__label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--slate-500);
  margin-right: var(--sp-2);
}

.share__btn {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: var(--r-md);
  background: var(--surface);
  border: 1px solid var(--slate-200);
  color: var(--slate-600);
  transition: transform var(--dur) var(--ease), background var(--dur) var(--ease),
    color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}

.share__btn:hover {
  transform: translateY(-2px);
  color: #fff;
  border-color: transparent;
}

.share__btn svg { width: 15px; height: 15px; }

.share__btn--wa:hover   { background: #25d366; }
.share__btn--fb:hover   { background: #1877f2; }
.share__btn--x:hover    { background: #0f1419; }
.share__btn--in:hover   { background: #0a66c2; }
.share__btn--tg:hover   { background: #229ed9; }
.share__btn--mail:hover { background: var(--navy-700); }
.share__btn--copy:hover { background: var(--saffron-600); }

.share__btn.is-copied {
  background: var(--green-600);
  border-color: transparent;
  color: #fff;
}

/* Body typography */
.article__body {
  padding: var(--sp-6);
  font-size: 1.0625rem;
  line-height: 1.8;
  color: #263449;
  max-width: 72ch;
}

.article__body > *:first-child { margin-top: 0; }

.article__body h2,
.article__body h3,
.article__body h4 {
  margin-top: var(--sp-6);
  margin-bottom: var(--sp-3);
}

.article__body h2 { font-size: 1.5rem; }
.article__body h3 { font-size: 1.25rem; }
.article__body h4 { font-size: 1.0625rem; }

.article__body p { margin: 0 0 var(--sp-5); }

.article__body a {
  color: var(--navy-600);
  text-decoration: underline;
  text-decoration-color: var(--slate-300);
  text-underline-offset: 3px;
  transition: color var(--dur-fast) var(--ease),
    text-decoration-color var(--dur-fast) var(--ease);
}

.article__body a:hover {
  color: var(--saffron-600);
  text-decoration-color: var(--saffron-500);
}

.article__body strong { color: var(--navy-900); font-weight: 700; }
.article__body em { font-style: italic; }

.article__body ul,
.article__body ol { margin: 0 0 var(--sp-5); padding-left: 1.4rem; }

.article__body li { margin-bottom: var(--sp-2); }
.article__body li::marker { color: var(--saffron-500); }

.article__body blockquote {
  margin: var(--sp-5) 0;
  padding: var(--sp-4) var(--sp-5);
  background: var(--navy-100);
  border-left: 4px solid var(--saffron-500);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  font-style: italic;
  color: var(--navy-800);
}

.article__body img {
  width: 100%;
  height: auto;
  border-radius: var(--r-md);
  margin: var(--sp-5) 0;
  box-shadow: var(--shadow-sm);
}

.article__body figure { margin: var(--sp-5) 0; }
.article__body figcaption {
  margin-top: var(--sp-2);
  font-size: 0.8125rem;
  color: var(--slate-500);
  text-align: center;
}

.article__body table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--sp-5) 0;
  font-size: 0.9375rem;
}

.article__body th,
.article__body td {
  padding: var(--sp-3);
  border: 1px solid var(--slate-200);
  text-align: left;
}

.article__body th { background: var(--slate-100); color: var(--navy-800); font-weight: 700; }

.article__body pre {
  background: var(--navy-950);
  color: #d7e2f0;
  padding: var(--sp-4);
  border-radius: var(--r-md);
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  line-height: 1.6;
}

.article__body code {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: var(--slate-100);
  padding: 0.1em 0.35em;
  border-radius: var(--r-sm);
}

/* Tags + article footer */
.article__footer {
  padding: 0 var(--sp-6) var(--sp-6);
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-2);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  padding: 0.3125rem var(--sp-3);
  border-radius: var(--r-pill);
  background: var(--slate-100);
  color: var(--slate-600);
  font-size: 0.8125rem;
  font-weight: 600;
  transition: background var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}

.tag:hover { background: var(--navy-800); color: #fff; }

.article__disclaimer {
  margin-top: var(--sp-5);
  padding: var(--sp-4);
  background: var(--slate-100);
  border-left: 3px solid var(--slate-300);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--slate-600);
}

.article__disclaimer strong { color: var(--navy-800); }

/* ==========================================================================
   10. Listing pages
   ========================================================================== */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-4);
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-md);
  margin-bottom: var(--sp-5);
}

.filter-bar__label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--slate-500);
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 0.3125rem var(--sp-3);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-pill);
  background: var(--surface);
  color: var(--slate-600);
  font-size: 0.8125rem;
  font-weight: 600;
  transition: background var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease),
    border-color var(--dur-fast) var(--ease);
}

.pill:hover {
  background: var(--navy-100);
  color: var(--navy-700);
  border-color: var(--navy-500);
}

.pill.is-active {
  background: var(--navy-800);
  border-color: var(--navy-800);
  color: #fff;
}

.pill__count {
  font-size: 0.6875rem;
  opacity: 0.7;
  font-weight: 700;
}

.result-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
  font-size: 0.875rem;
  color: var(--slate-600);
}

.result-summary strong { color: var(--navy-900); }

.empty-state {
  display: grid;
  place-items: center;
  gap: var(--sp-3);
  padding: var(--sp-9) var(--sp-5);
  text-align: center;
  background: var(--surface);
  border: 1px dashed var(--slate-300);
  border-radius: var(--r-lg);
}

.empty-state__icon {
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--slate-100);
  color: var(--slate-400);
}

.empty-state h3 { margin: 0; }
.empty-state p { margin: 0; color: var(--slate-500); max-width: 46ch; }

/* Archive table */
.archive-list {
  display: grid;
  gap: var(--sp-2);
}

.archive-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  padding: var(--sp-4);
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-md);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease);
}

.archive-item:hover {
  transform: translateX(3px);
  border-color: var(--slate-300);
  box-shadow: var(--shadow-sm);
}

.archive-item__label { font-weight: 600; color: var(--navy-900); }
.archive-item__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  padding: 0.1875rem var(--sp-2);
  border-radius: var(--r-pill);
  background: var(--navy-100);
  color: var(--navy-700);
  font-size: 0.75rem;
  font-weight: 700;
}

/* Prose pages (about / privacy / terms) */
.prose {
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-lg);
  padding: var(--sp-7);
  max-width: 78ch;
}

.prose > *:first-child { margin-top: 0; }
.prose h2 { margin-top: var(--sp-6); font-size: 1.375rem; }
.prose h3 { margin-top: var(--sp-5); font-size: 1.125rem; }
.prose p, .prose li { line-height: 1.75; color: var(--ink-soft); }
.prose ul, .prose ol { margin-bottom: var(--sp-5); }
.prose li { margin-bottom: var(--sp-2); }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.prose hr { margin: var(--sp-6) 0; }
.prose table { width: 100%; border-collapse: collapse; margin: var(--sp-5) 0; font-size: 0.9375rem; }
.prose th, .prose td { padding: var(--sp-3); border: 1px solid var(--slate-200); text-align: left; }
.prose th { background: var(--slate-100); }
.prose blockquote {
  margin: var(--sp-5) 0;
  padding: var(--sp-4);
  border-left: 4px solid var(--saffron-500);
  background: var(--slate-100);
  border-radius: 0 var(--r-md) var(--r-md) 0;
}

.prose__updated {
  margin-top: var(--sp-6);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--slate-200);
  font-size: 0.8125rem;
  color: var(--slate-500);
}

/* ==========================================================================
   11. Sidebar
   ========================================================================== */
.sidebar {
  display: grid;
  gap: var(--sp-5);
  position: sticky;
  top: calc(var(--header-h) + var(--sp-4));
}

.widget {
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow-xs);
}

.widget__head {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-4);
  background: linear-gradient(135deg, var(--navy-800), var(--navy-900));
  color: #fff;
}

.widget__head h2,
.widget__head h3 {
  margin: 0;
  color: #fff;
  font-size: 0.9375rem;
  font-family: var(--font-sans);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.widget__head svg { color: var(--saffron-400); flex-shrink: 0; }

.widget__body { padding: var(--sp-4); }
.widget__body--flush { padding: 0; }

/* Toppers */
.topper {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-3) var(--sp-4);
  border-bottom: 1px solid var(--slate-100);
  transition: background var(--dur) var(--ease);
}

.topper:last-child { border-bottom: 0; }
.topper:hover { background: var(--slate-100); }

.topper__photo {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--slate-200);
  flex-shrink: 0;
  background: var(--slate-100);
}

.topper__body { min-width: 0; }

.topper__name {
  margin: 0 0 2px;
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--navy-900);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.topper__rank {
  margin: 0;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--saffron-600);
}

.topper__badge {
  display: inline-block;
  margin-left: var(--sp-1);
  padding: 0 0.375rem;
  border-radius: var(--r-sm);
  background: var(--saffron-500);
  color: #fff;
  font-size: 0.625rem;
  letter-spacing: 0.05em;
}

/* Newsletter / contact CTA */
.widget--cta {
  background: linear-gradient(135deg, var(--navy-800), var(--navy-950));
  border: 0;
  color: #cddaea;
}

.widget--cta .widget__body { padding: var(--sp-5); }
.widget--cta h3 { color: #fff; font-size: 1.0625rem; }
.widget--cta p { font-size: 0.875rem; color: #a8bcd6; margin-bottom: var(--sp-4); }

.widget--cta .contact-line {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-3);
  font-size: 0.875rem;
}

.widget--cta .contact-line svg { color: var(--saffron-400); flex-shrink: 0; }
.widget--cta .contact-line a { color: #fff; font-weight: 600; }
.widget--cta .contact-line a:hover { color: var(--saffron-400); }

/* ==========================================================================
   12. Forms & buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: 0.6875rem var(--sp-5);
  border: 1px solid transparent;
  border-radius: var(--r-md);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  text-align: center;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease),
    border-color var(--dur) var(--ease), transform var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease);
  white-space: nowrap;
}

.btn:active { transform: translateY(1px); }
.btn svg { width: 15px; height: 15px; flex-shrink: 0; }

.btn--primary {
  background: var(--navy-800);
  color: #fff;
  box-shadow: var(--shadow-sm);
}

.btn--primary:hover {
  background: var(--navy-700);
  color: #fff;
  box-shadow: var(--shadow-md);
}

.btn--accent {
  background: var(--saffron-500);
  color: var(--navy-950);
}

.btn--accent:hover { background: var(--saffron-400); color: var(--navy-950); }

.btn--ghost {
  background: transparent;
  border-color: var(--slate-300);
  color: var(--navy-700);
}

.btn--ghost:hover {
  background: var(--navy-100);
  border-color: var(--navy-500);
  color: var(--navy-800);
}

.btn--light {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.25);
  color: #fff;
}

.btn--light:hover { background: rgba(255, 255, 255, 0.18); color: #fff; }

.btn--sm { padding: 0.4375rem var(--sp-3); font-size: 0.8125rem; }
.btn--block { width: 100%; }

.btn[disabled],
.btn.is-loading {
  opacity: 0.6;
  pointer-events: none;
}

/* Form controls */
.field { min-width: 0; margin-bottom: var(--sp-4); }

.field__label {
  display: block;
  margin-bottom: var(--sp-2);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--navy-800);
}

.field__label .req { color: var(--red-600); }

.field__hint {
  margin-top: var(--sp-1);
  font-size: 0.75rem;
  color: var(--slate-500);
}

.field__error {
  margin-top: var(--sp-1);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--red-600);
}

.input,
.textarea,
.select {
  width: 100%;
  padding: 0.6875rem var(--sp-4);
  background: var(--surface);
  border: 1px solid var(--slate-300);
  border-radius: var(--r-md);
  font-size: 1rem;
  color: var(--ink);
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}

.input::placeholder,
.textarea::placeholder { color: var(--slate-400); }

.input:focus,
.textarea:focus,
.select:focus {
  outline: none;
  border-color: var(--navy-500);
  box-shadow: 0 0 0 3px rgba(27, 64, 121, 0.12);
}

.input.is-invalid,
.textarea.is-invalid { border-color: var(--red-600); }

.textarea { min-height: 120px; resize: vertical; line-height: 1.6; }

.select {
  appearance: none;
  padding-right: var(--sp-6);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%234a5a6e' stroke-width='2'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right var(--sp-4) center;
  background-size: 15px;
}

.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-3);
  margin-bottom: var(--sp-3);
}

.checkbox-row input[type="checkbox"],
.checkbox-row input[type="radio"] {
  width: 17px;
  height: 17px;
  margin-top: 2px;
  accent-color: var(--navy-700);
  flex-shrink: 0;
}

.checkbox-row label { font-size: 0.875rem; cursor: pointer; }

/* Alerts */
.alert {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-3);
  padding: var(--sp-4);
  border-radius: var(--r-md);
  font-size: 0.875rem;
  line-height: 1.55;
  margin-bottom: var(--sp-5);
  border: 1px solid transparent;
}

.alert svg { flex-shrink: 0; margin-top: 2px; }
.alert__title { font-weight: 700; display: block; margin-bottom: 2px; }

.alert--error {
  background: #fdf2f2;
  border-color: #f5c2c2;
  color: #8f2222;
}

.alert--success {
  background: var(--green-100);
  border-color: #b6e0c8;
  color: var(--green-600);
}

.alert--info {
  background: var(--navy-100);
  border-color: #c3d4ea;
  color: var(--navy-700);
}

.alert--warn {
  background: var(--saffron-100);
  border-color: #f6d9ae;
  color: var(--saffron-700);
}

/* Honeypot — hidden from humans, tempting to bots. */
.hp-field {
  position: absolute !important;
  left: -9999px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

/* ==========================================================================
   13. Pagination
   ========================================================================== */
.pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  margin-top: var(--sp-7);
  padding-top: var(--sp-5);
  border-top: 1px solid var(--slate-200);
}

.pagination__btn {
  display: inline-grid;
  place-items: center;
  min-width: 40px;
  height: 40px;
  padding-inline: var(--sp-3);
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-md);
  color: var(--navy-700);
  font-size: 0.875rem;
  font-weight: 600;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease),
    border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.pagination__btn:hover {
  background: var(--navy-800);
  border-color: var(--navy-800);
  color: #fff;
  transform: translateY(-1px);
}

.pagination__btn[aria-current="page"] {
  background: var(--navy-800);
  border-color: var(--navy-800);
  color: #fff;
  box-shadow: var(--shadow-sm);
}

.pagination__btn[aria-disabled="true"] {
  opacity: 0.4;
  pointer-events: none;
}

.pagination__gap {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 40px;
  color: var(--slate-400);
  font-weight: 700;
}

/* ==========================================================================
   14. Footer
   ========================================================================== */
.footer {
  background: var(--navy-950);
  color: #93a8c4;
  margin-top: var(--sp-9);
}

.footer__top {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--sp-7);
  padding-block: var(--sp-8);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer__brand {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
  color: #fff;
}

.footer__brand:hover { color: #fff; }

.footer__brand .brand__mark {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.footer__about {
  font-size: 0.875rem;
  line-height: 1.75;
  margin-bottom: var(--sp-5);
  max-width: 42ch;
}

.footer__contact {
  display: grid;
  gap: var(--sp-3);
  margin-bottom: var(--sp-5);
  font-size: 0.875rem;
}

.footer__contact-item {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-3);
}

.footer__contact-item svg {
  color: var(--saffron-400);
  flex-shrink: 0;
  margin-top: 3px;
}

.footer__contact-item a { color: #c3d3e6; }
.footer__contact-item a:hover { color: var(--saffron-400); }

.footer__col h3 {
  margin: 0 0 var(--sp-4);
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer__col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--sp-3);
}

.footer__col a {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  color: #93a8c4;
  font-size: 0.875rem;
}

.footer__col a:hover { color: var(--saffron-400); }

.footer__socials {
  display: flex;
  gap: var(--sp-2);
  flex-wrap: wrap;
}

.footer__social {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #b7c8dd;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease),
    transform var(--dur) var(--ease), border-color var(--dur) var(--ease);
}

.footer__social svg { width: 16px; height: 16px; }

.footer__social:hover {
  background: var(--saffron-500);
  border-color: var(--saffron-500);
  color: var(--navy-950);
  transform: translateY(-2px);
}

.footer__topics {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
}

.footer__topic {
  padding: 0.25rem var(--sp-3);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.05);
  color: #93a8c4;
  font-size: 0.75rem;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease);
}

.footer__topic:hover {
  background: rgba(255, 153, 51, 0.16);
  color: var(--saffron-400);
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  padding-block: var(--sp-5);
  font-size: 0.8125rem;
  color: #6f839e;
}

.footer__legal {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
}

.footer__legal a { color: #6f839e; }
.footer__legal a:hover { color: var(--saffron-400); }

.footer__disclaimer {
  padding: var(--sp-4) var(--gutter);
  background: rgba(0, 0, 0, 0.25);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.75rem;
  line-height: 1.7;
  color: #6f839e;
}

.footer__disclaimer strong { color: #93a8c4; }

/* Back to top */
.to-top {
  position: fixed;
  right: var(--sp-5);
  bottom: var(--sp-5);
  z-index: 880;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--navy-800);
  color: #fff;
  border: 0;
  box-shadow: var(--shadow-lg);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease),
    visibility var(--dur) var(--ease), background var(--dur) var(--ease);
}

.to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { background: var(--saffron-600); }

/* ==========================================================================
   15. Utilities
   ========================================================================== */
.text-center { text-align: center; }
.text-muted { color: var(--slate-500); }
.text-sm { font-size: 0.875rem; }
.text-xs { font-size: 0.75rem; }
.mt-0 { margin-top: 0 !important; }
.mb-0 { margin-bottom: 0 !important; }
.mt-4 { margin-top: var(--sp-4); }
.mt-5 { margin-top: var(--sp-5); }
.mb-4 { margin-bottom: var(--sp-4); }
.mb-5 { margin-bottom: var(--sp-5); }
.d-none { display: none !important; }
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.gap-2 { gap: var(--sp-2); }
.gap-3 { gap: var(--sp-3); }
.justify-between { justify-content: space-between; }
.w-full { width: 100%; }

.divider {
  height: 1px;
  background: var(--slate-200);
  margin-block: var(--sp-5);
}

.visually-hidden-mobile {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

/* ==========================================================================
   16. Motion & polish
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .card:hover,
  .post-row:hover,
  .topic:hover,
  .archive-item:hover { transform: none; }
}

/* Entry animation, applied only once and disabled under reduced motion. */
[data-reveal] {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out);
}

[data-reveal].is-revealed {
  opacity: 1;
  transform: none;
}

/* Skeleton loader for images that arrive late */
.skeleton {
  position: relative;
  overflow: hidden;
  background: var(--slate-100);
}

.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
  animation: shimmer 1.4s infinite;
}

@keyframes shimmer {
  100% { transform: translateX(100%); }
}

@media print {
  .nav, .masthead, .footer, .announce, .ticker, .sidebar, .share, .to-top, .pagination {
    display: none !important;
  }

  body { background: #fff; }
  .article { border: 0; box-shadow: none; }
  .article__body { max-width: none; padding: 0; }
}

/* ==========================================================================
   17. Responsive
   ========================================================================== */

/* --- Large desktop ------------------------------------------------------- */
@media (min-width: 1440px) {
  :root { --container: 1320px; }
}

/* --- Tablet -------------------------------------------------------------- */
@media (max-width: 1100px) {
  .layout {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--sp-6);
  }

  .sidebar {
    position: static;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }

  .masthead__badges { display: none; }
  .masthead__inner { grid-template-columns: auto 1fr; }
  .masthead__actions { grid-column: 1 / -1; justify-content: space-between; }
  .header-search { width: 100%; }

  .hero__card { grid-template-columns: 1fr; }
  .hero__media { min-height: 260px; }
  .hero__media::after {
    background: linear-gradient(180deg, transparent 55%, var(--navy-950) 100%);
  }
  .hero__body { padding: var(--sp-5); }
}

/* --- Mobile nav ---------------------------------------------------------- */
@media (max-width: 1100px) {
  .nav__toggle { display: inline-flex; }

  .nav__inner {
    flex-wrap: wrap;
    padding-block: var(--sp-2);
  }

  .nav__list {
    display: none;
    order: 3;
    width: 100%;
    flex-direction: column;
    gap: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: var(--sp-2);
    padding-bottom: var(--sp-2);
  }

  .nav__list.is-open { display: flex; }

  .nav__link {
    padding: var(--sp-3) var(--sp-4);
    min-height: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    border-left: 3px solid transparent;
    justify-content: space-between;
  }

  .nav__link:hover,
  .nav__link:focus-visible {
    border-bottom-color: rgba(255, 255, 255, 0.06);
    border-left-color: var(--saffron-400);
  }

  /* Accordion dropdowns */
  .nav__dropdown {
    position: static;
    min-width: 0;
    opacity: 1;
    visibility: visible;
    transform: none;
    max-height: 0;
    overflow: hidden;
    padding: 0;
    border: 0;
    border-left: 3px solid rgba(255, 153, 51, 0.3);
    border-radius: 0;
    box-shadow: none;
    background: rgba(0, 0, 0, 0.2);
    transition: max-height var(--dur) var(--ease);
  }

  .nav__item--open .nav__dropdown { max-height: 460px; }

  .nav__dropdown a {
    color: #b6c6da;
    padding: var(--sp-3) var(--sp-4);
    border-left: 0;
  }

  .nav__dropdown a:hover { background: rgba(255, 255, 255, 0.05); color: #fff; }
  .nav__dropdown .nav__count { display: none; }

  .nav__cta { margin-left: auto; order: 2; }
  .nav__cta-link { justify-content: center; }
}

/* --- Mobile -------------------------------------------------------------- */
@media (max-width: 640px) {
  :root {
    --gutter: 1rem;
    --sp-7: 1.75rem;
    --sp-8: 2.25rem;
  }

  .announce__meta { display: none; }

  .masthead__inner {
    grid-template-columns: 1fr;
    gap: var(--sp-3);
    padding-block: var(--sp-4);
  }

  .brand { justify-content: center; }
  .brand__name { font-size: 1.4rem; }
  .brand__mark { width: 42px; height: 42px; }
  .masthead__actions { justify-content: center; }

  .ticker__flag {
    font-size: 0.625rem;
    padding-inline: var(--sp-3);
    letter-spacing: 0.06em;
  }

  .grid { grid-template-columns: 1fr; }
  .hero-pair { grid-template-columns: 1fr; }
  .cols-2 { grid-template-columns: 1fr; }

  .post-row { grid-template-columns: 96px minmax(0, 1fr); gap: var(--sp-3); padding: var(--sp-3); }

  .article__header,
  .article__body,
  .article__footer { padding: var(--sp-4); }
  .share { padding: var(--sp-3) var(--sp-4); }
  .article__caption { padding-inline: var(--sp-4); }
  .article__body { font-size: 1rem; line-height: 1.75; }

  .prose { padding: var(--sp-5) var(--sp-4); }

  .cta-band { grid-template-columns: 1fr; text-align: left; padding: var(--sp-5); }

  .footer__top { grid-template-columns: 1fr; gap: var(--sp-6); padding-block: var(--sp-6); }
  .footer__bottom { flex-direction: column; align-items: flex-start; text-align: left; }

  .topic-grid { grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); }

  .to-top { right: var(--sp-3); bottom: var(--sp-3); width: 40px; height: 40px; }
}

/* --- Very small ---------------------------------------------------------- */
@media (max-width: 380px) {
  .brand__name { font-size: 1.2rem; }
  .brand__tagline { font-size: 0.5625rem; letter-spacing: 0.1em; }
  .btn { padding-inline: var(--sp-4); }
  .pagination__btn { min-width: 36px; height: 36px; }
}

/* --- Print --------------------------------------------------------------- */
@media print {
  .announce__inner { padding: 0; }
}

/* ======================================================================
   Additions for the rewritten pages
   Only genuinely new selectors live here; nothing above is overridden.
   ===================================================================== */

/* --- Form layout ------------------------------------------------------- */
.form { margin: 0; }

.form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 var(--sp-4);
}

.form__actions {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  flex-wrap: wrap;
  margin-top: var(--sp-2);
  padding-top: var(--sp-2);
  border-top: 1px solid var(--slate-200);
}

.form__note {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--slate-500);
}

.form__note a { color: var(--navy-600); }

/* Contact page */
.contact-head h1 { margin-top: var(--sp-4); }
.contact-layout { padding-block: var(--sp-6); }
.contact-panel { margin-bottom: var(--sp-6); }
.contact-panel__intro { margin-bottom: var(--sp-5); }
.contact-panel__intro h2 { margin: 0 0 var(--sp-2); font-size: 1.375rem; }
.contact-panel__intro p { margin: 0; color: var(--slate-600); font-size: 0.875rem; }
.contact-panel .form__actions { padding-top: var(--sp-4); }
.contact-panel .form__note { flex: 1 1 240px; }

/* Required marker used inside .field__label. */
.field__req { color: var(--red-600); margin-left: 2px; }

/* Inline validation state. */
.input[aria-invalid="true"],
.textarea[aria-invalid="true"],
.select[aria-invalid="true"] {
  border-color: var(--red-600);
  box-shadow: 0 0 0 3px rgba(165, 42, 42, 0.1);
}

/* --- Panel ------------------------------------------------------------- */
.panel {
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-lg);
  padding: var(--sp-6);
  box-shadow: var(--shadow-xs);
}

.panel--center {
  max-width: 640px;
  margin-inline: auto;
}

.panel--center .field { text-align: left; }

/* --- Info card --------------------------------------------------------- */
.info-card {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  padding: var(--sp-5);
  background: var(--surface);
  border: 1px solid var(--slate-200);
  border-radius: var(--r-lg);
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease),
              transform var(--dur) var(--ease);
}

.info-card__icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  margin-bottom: var(--sp-1);
  border-radius: var(--r-md);
  background: var(--navy-100);
  color: var(--navy-700);
}

.info-card h3 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.35;
  color: var(--navy-800);
}

.info-card__body {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--slate-600);
}

.info-card__body a { color: var(--navy-600); word-break: break-word; }

.info-card--link { color: inherit; }

.info-card--link:hover {
  transform: translateY(-2px);
  border-color: var(--slate-300);
  box-shadow: var(--shadow-md);
}

.info-card--link:hover h3 { color: var(--navy-600); }

/* --- Alert internals ---------------------------------------------------- */
.alert__icon {
  display: inline-flex;
  flex-shrink: 0;
  color: currentColor;
}

.alert__body { min-width: 0; }

/* --- Footer brand column ------------------------------------------------ */
.footer__col--brand { grid-column: span 2; min-width: 0; }

/* --- Authentication screen ---------------------------------------------- */
.auth-body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: var(--sp-6) var(--sp-4);
  background: radial-gradient(
    1100px 520px at 50% -10%,
    var(--navy-800) 0%,
    var(--navy-900) 55%,
    var(--navy-950) 100%
  );
}

.auth-wrap {
  width: 100%;
  max-width: 460px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-4);
}

.auth-card {
  width: 100%;
  padding: var(--sp-7) var(--sp-6) var(--sp-6);
  background: var(--surface);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-xl);
}

.auth-card__brand {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding-bottom: var(--sp-5);
  margin-bottom: var(--sp-5);
  border-bottom: 1px solid var(--slate-200);
}

.auth-card__mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  overflow: hidden;
  border-radius: var(--r-md);
  background: var(--navy-800);
  color: #fff;
}

.auth-card__mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
}

.auth-card__name {
  margin: 0;
  font-size: 1.0625rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--navy-800);
  overflow-wrap: anywhere;
}

.auth-card__tagline {
  margin: 2px 0 0;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--slate-500);
}

.auth-card__title {
  margin: 0 0 var(--sp-2);
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  color: var(--navy-900);
}

.auth-card__lede {
  margin: 0 0 var(--sp-5);
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--slate-600);
}

.auth-form .field:last-of-type { margin-bottom: var(--sp-5); }
.auth-form .btn--block { width: 100%; }

.auth-card__foot {
  margin: var(--sp-5) 0 0;
  padding-top: var(--sp-4);
  border-top: 1px solid var(--slate-200);
  font-size: 0.8125rem;
  text-align: center;
}

.auth-note {
  margin: 0;
  font-size: 0.75rem;
  text-align: center;
  color: rgba(255, 255, 255, 0.62);
  max-width: 36ch;
}

/* Password field with a show/hide button. */
.field__affix { position: relative; }

.field__affix .input { padding-right: 56px; min-height: 50px; }

.field__affix-btn {
  position: absolute;
  top: 50%;
  right: 6px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: var(--r-sm);
  background: none;
  color: var(--slate-500);
  cursor: pointer;
  transform: translateY(-50%);
  transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
}

.field__affix-btn:hover { color: var(--navy-700); background: var(--slate-100); }

.field__affix-btn:focus-visible {
  outline: 2px solid var(--navy-500);
  outline-offset: 1px;
}

.field__affix-btn[aria-pressed="true"] { color: var(--navy-700); }

/* --- Chevron rotation for "previous" pagination links -------------------- */
.flip-x { transform: scaleX(-1); }

/* --- Legacy admin compatibility ----------------------------------------- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-5);
  background: var(--navy-800);
  color: #fff;
}

.topbar a { color: #fff; }

.main { padding: var(--sp-6) var(--sp-5); }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: 0.8125rem;
  color: var(--navy-600);
}

.edit-container { max-width: 880px; margin-inline: auto; }

.error-banner,
.success-banner {
  padding: var(--sp-4);
  margin-bottom: var(--sp-5);
  border-radius: var(--r-md);
  font-size: 0.875rem;
}

.error-banner { background: #fdf2f2; border: 1px solid #f5c2c2; color: #8f2222; }
.success-banner { background: var(--green-100); border: 1px solid #b6e0c8; color: var(--green-600); }

.error-msg {
  padding: var(--sp-3) var(--sp-4);
  margin-bottom: var(--sp-4);
  border-radius: var(--r-md);
  background: #fdf2f2;
  border: 1px solid #f5c2c2;
  color: #8f2222;
  font-size: 0.875rem;
}

.btn-main { background: var(--navy-800); color: #fff; }
.btn-edit { background: var(--navy-600); color: #fff; }
.btn-delete { background: var(--red-600); color: #fff; }

.btn-main:hover { background: var(--navy-700); }
.btn-edit:hover { background: var(--navy-500); }
.btn-delete:hover { filter: brightness(1.08); }

/* The old admin markup referenced Font Awesome class names. Map them onto
   inline SVG masks so no webfont or external stylesheet is required. */
.fa {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1em;
  height: 1em;
  flex-shrink: 0;
  background-color: currentColor;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
}

.fa-newspaper {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M4 4h13v16H4z'/%3E%3Cpath d='M7 7h7v3H7zm0 5h7v3H7zm0 5h4v2H7z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M4 4h13v16H4z'/%3E%3Cpath d='M7 7h7v3H7zm0 5h7v3H7zm0 5h4v2H7z'/%3E%3C/svg%3E");
}

.fa-plus-circle {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3C/svg%3E");
}

.fa-edit {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M4 16h4l10-10-4-4L4 12z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M4 16h4l10-10-4-4L4 12z'/%3E%3C/svg%3E");
}

.fa-trash {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M9 3h6v2h4v2H5V5h4zM7 8h10l-1 13H8z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M9 3h6v2h4v2H5V5h4zM7 8h10l-1 13H8z'/%3E%3C/svg%3E");
}

.fa-sign-out-alt {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M10 4h-6v16h6v-2H6V6h4zM14 8l4 4-4 4v-3H9v-2h5z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M10 4h-6v16h6v-2H6V6h4zM14 8l4 4-4 4v-3H9v-2h5z'/%3E%3C/svg%3E");
}

.fa-user-graduate {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M12 3l10 5-10 5L2 8z'/%3E%3Cpath d='M6 11v4c0 2 3 3 6 3s6-1 6-3v-4l-6 3z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M12 3l10 5-10 5L2 8z'/%3E%3Cpath d='M6 11v4c0 2 3 3 6 3s6-1 6-3v-4l-6 3z'/%3E%3C/svg%3E");
}

.fa-users-cog {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Ccircle cx='9' cy='8' r='4'/%3E%3Cpath d='M2 21c0-4 3-6 7-6 1 0 2 .1 3 .4A5 5 0 0 1 15 21z'/%3E%3Ccircle cx='18' cy='9' r='2.5'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Ccircle cx='9' cy='8' r='4'/%3E%3Cpath d='M2 21c0-4 3-6 7-6 1 0 2 .1 3 .4A5 5 0 0 1 15 21z'/%3E%3Ccircle cx='18' cy='9' r='2.5'/%3E%3C/svg%3E");
}

.fa-external-link-alt {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M14 3h7v7h-2V6.4l-8.3 8.3-1.4-1.4L17.6 5H14z'/%3E%3Cpath d='M5 5h5v2H7v10h10v-3h2v5H5z'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Cpath d='M14 3h7v7h-2V6.4l-8.3 8.3-1.4-1.4L17.6 5H14z'/%3E%3Cpath d='M5 5h5v2H7v10h10v-3h2v5H5z'/%3E%3C/svg%3E");
}

/* --- Responsive --------------------------------------------------------- */
@media (max-width: 760px) {
  .form__grid { grid-template-columns: minmax(0, 1fr); }
  .panel { padding: var(--sp-5); }
  .footer__col--brand { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  .d-none-sm { display: none !important; }
  .header-search input { font-size: 1rem; }
  .search-suggest { width: 100%; }
  .nav__cta-link { min-height: 40px; padding-inline: var(--sp-3); }
  .mobile-quick-links { display: block; background: var(--surface); border-bottom: 1px solid var(--slate-200); }
  .mobile-quick-links__inner { display: flex; gap: var(--sp-2); overflow-x: auto; padding-block: var(--sp-3); }
  .mobile-quick-links a { flex-shrink: 0; padding: var(--sp-2) var(--sp-3); border: 1px solid var(--slate-200); border-radius: var(--r-pill); color: var(--navy-800); background: var(--slate-100); font-size: 0.75rem; font-weight: 600; }
  .mobile-quick-links a:focus-visible { outline: 2px solid var(--navy-500); outline-offset: 2px; }
  .auth-body { padding: var(--sp-5) var(--sp-4); }
  .auth-card { padding: var(--sp-5); }
  .contact-panel .form__actions { align-items: stretch; flex-direction: column; }
  .contact-panel .form__note { flex: auto; }
}
