/* ==========================================================================
   RUTO@27 — Movement stylesheet
   Continuity | Progress | Prosperity
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Design tokens
   -------------------------------------------------------------------------- */
:root {
  /* Brand — taken from the RUTO@27 identity sheet */
  --navy:        #0C1A33;
  --navy-700:    #14264A;
  --navy-600:    #1D3461;
  --navy-500:    #2B4879;
  --gold:        #C9A24A;
  --gold-light:  #E0BE6E;
  --gold-dark:   #A8832F;
  --flag-red:    #BE1E2D;
  --flag-green:  #0B7A45;
  --flag-black:  #111111;

  /* Neutrals */
  --ink:         #0C1A33;
  --ink-soft:    #3D4A63;
  --muted:       #6B7688;
  --line:        #E3E7EE;
  --line-soft:   #EFF2F6;
  --paper:       #FFFFFF;
  --paper-alt:   #F6F8FB;
  --paper-warm:  #FBF9F4;

  /* Type — three roles, not two.
     --font-display  Playfair Display. Headlines and the big gold numerals only.
                     Its thick/thin contrast is what gives the navy-and-gold
                     palette its editorial, institutional weight.
     --font-ui       Source Sans 3. Nav, buttons, badges, labels, table heads.
                     A high-contrast serif goes weak and fussy at 12–14px, so
                     none of the interface chrome is set in it.
     --font-body     Source Sans 3. Large x-height and open apertures, which is
                     what long article bodies need. */
  --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-ui:      'Source Sans 3', 'Segoe UI', Arial, sans-serif;
  --font-body:    'Source Sans 3', 'Segoe UI', Arial, sans-serif;

  /* Motion & shape */
  --radius:      14px;
  --radius-lg:   22px;
  --radius-sm:   8px;
  --ease:        cubic-bezier(.22, .61, .36, 1);
  --shadow-sm:   0 2px 10px rgba(12, 26, 51, .06);
  --shadow:      0 12px 34px -12px rgba(12, 26, 51, .20);
  --shadow-lg:   0 28px 70px -24px rgba(12, 26, 51, .34);
  --shadow-gold: 0 20px 50px -20px rgba(201, 162, 74, .48);

  /* The fixed top stack: utility bar + navbar. Pages that need to clear it
     read --header-h, which is the two added together. */
  --topbar-h: 40px;
  --nav-h:    74px;
  --header-h: 114px;
}

@media (max-width: 991.98px) {
  :root { --topbar-h: 0px; --nav-h: 66px; --header-h: 66px; }
}

/* --------------------------------------------------------------------------
   2. Base
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
  font-family: var(--font-body);
  color: var(--ink-soft);
  background: var(--paper);
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Playfair carries plenty of weight on its own, so headings sit at 700 rather
   than 800 — the heaviest cuts thicken the hairlines and go muddy. Tracking
   stays near zero, because a high-contrast serif loses its rhythm when it is
   squeezed the way a geometric sans can be. */
h1, h2, h3, h4, h5, h6, .display-font {
  font-family: var(--font-display);
  color: var(--ink);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -.008em;
}

/* Pages that start with the solid header need to clear the fixed bar, since
   there is no dark hero or banner sitting underneath it. */
body.header-offset main { padding-top: var(--nav-h); }

/* Slightly larger than the sans set: Playfair has a smaller apparent size at
   the same point size, so it needs the extra to hold the same presence. */
h1 { font-size: clamp(2.2rem, 5.2vw, 3.9rem); }
h2 { font-size: clamp(1.85rem, 3.8vw, 2.9rem); }
h3 { font-size: clamp(1.35rem, 2.3vw, 1.85rem); }
h4 { font-size: 1.24rem; line-height: 1.34; }
h5, h6 { font-size: 1.06rem; }

p { margin-bottom: 1.1rem; }

a { color: var(--navy-600); text-decoration: none; transition: color .2s var(--ease); }
a:hover { color: var(--gold-dark); }

::selection { background: var(--gold); color: var(--navy); }

img { max-width: 100%; }

/* Bootstrap's .container pads by only 0.75rem. Overriding max-width without
   also raising the padding meant that on any viewport narrower than the
   max-width the content ran almost flush to the window edge. */
.container {
  max-width: 1300px;
  padding-left: clamp(1.25rem, 4vw, 2.75rem);
  padding-right: clamp(1.25rem, 4vw, 2.75rem);
}

/* Focus ring — visible for keyboards, quiet for mice */
:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Custom scrollbar */
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: var(--paper-alt); }
::-webkit-scrollbar-thumb { background: var(--navy-500); border-radius: 8px; border: 3px solid var(--paper-alt); }
::-webkit-scrollbar-thumb:hover { background: var(--navy); }

/* --------------------------------------------------------------------------
   3. Utility — surfaces, spacing, rules
   -------------------------------------------------------------------------- */
.section        { padding: clamp(4rem, 8vw, 7.5rem) 0; position: relative; }
.section-sm     { padding: clamp(3rem, 5vw, 4.5rem) 0; position: relative; }
.bg-paper       { background: var(--paper); }
.bg-alt         { background: var(--paper-alt); }
.bg-warm        { background: var(--paper-warm); }

.bg-navy {
  background: var(--navy);
  color: rgba(255, 255, 255, .78);
}
.bg-navy h1, .bg-navy h2, .bg-navy h3, .bg-navy h4, .bg-navy h5 { color: #fff; }
.bg-navy a:not(.btn) { color: var(--gold-light); }

/* The one place gradients are allowed: dark immersive bands */
.bg-navy-deep {
  background:
    radial-gradient(1100px 620px at 84% -8%,  rgba(201, 162, 74, .16), transparent 62%),
    radial-gradient(900px 560px at 6% 106%,   rgba(43, 72, 121, .40),  transparent 60%),
    linear-gradient(168deg, #0A1730 0%, #0C1A33 45%, #101F3C 100%);
  color: rgba(255, 255, 255, .78);
}
.bg-navy-deep h1, .bg-navy-deep h2, .bg-navy-deep h3, .bg-navy-deep h4 { color: #fff; }

/* Kenyan flag rule — used to cap sections */
.flag-rule {
  display: flex;
  height: 5px;
  width: 78px;
  border-radius: 99px;
  overflow: hidden;
}
.flag-rule span { flex: 1; }
.flag-rule span:nth-child(1) { background: var(--flag-black); }
.flag-rule span:nth-child(2) { background: var(--flag-red); }
.flag-rule span:nth-child(3) { background: var(--flag-green); }
.flag-rule.center { margin-inline: auto; }

.flag-strip {
  height: 4px;
  display: flex;
  width: 100%;
}
.flag-strip i { flex: 1; display: block; }
.flag-strip i:nth-child(1) { background: var(--flag-black); }
.flag-strip i:nth-child(2) { background: var(--flag-red); }
.flag-strip i:nth-child(3) { background: var(--paper); }
.flag-strip i:nth-child(4) { background: var(--flag-green); }

/* Section eyebrow */
.eyebrow {
  font-family: var(--font-ui);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold-dark);
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  margin-bottom: .9rem;
}
.eyebrow::before {
  content: '';
  width: 26px; height: 2px;
  background: var(--gold);
  display: block;
}
.bg-navy .eyebrow, .bg-navy-deep .eyebrow, .parallax .eyebrow { color: var(--gold-light); }

.lead-text {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 62ch;
}
.bg-navy .lead-text, .bg-navy-deep .lead-text { color: rgba(255, 255, 255, .72); }

/* Big faint watermark numeral behind section headings */
.watermark {
  position: absolute;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(9rem, 22vw, 20rem);
  line-height: .8;
  color: rgba(12, 26, 51, .035);
  pointer-events: none;
  user-select: none;
  z-index: 0;
}
.bg-navy .watermark, .bg-navy-deep .watermark { color: rgba(255, 255, 255, .034); }

/* --------------------------------------------------------------------------
   4. Buttons
   -------------------------------------------------------------------------- */
.btn {
  font-family: var(--font-ui);
  font-weight: 700;
  letter-spacing: .015em;
  border-radius: 99px;
  padding: .78rem 1.75rem;
  border: 2px solid transparent;
  transition: all .28s var(--ease);
  display: inline-flex;
  align-items: center;
  gap: .55rem;
}

.btn-gold {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy);
}
.btn-gold:hover {
  background: var(--gold-light);
  border-color: var(--gold-light);
  color: var(--navy);
  transform: translateY(-3px);
  box-shadow: var(--shadow-gold);
}

.btn-navy {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
}
.btn-navy:hover {
  background: var(--navy-600);
  border-color: var(--navy-600);
  color: #fff;
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.btn-outline-navy { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn-outline-navy:hover { background: var(--navy); color: #fff; transform: translateY(-3px); }

.btn-outline-light { border-color: rgba(255, 255, 255, .55); color: #fff; background: transparent; }
.btn-outline-light:hover { background: #fff; border-color: #fff; color: var(--navy); transform: translateY(-3px); }

.btn-lg { padding: .95rem 2.2rem; font-size: 1.02rem; }
.btn-sm { padding: .48rem 1.1rem; font-size: .86rem; }

/* Arrow that slides on hover */
.btn .bi-arrow-right { transition: transform .28s var(--ease); }
.btn:hover .bi-arrow-right { transform: translateX(5px); }

/* Text link with animated underline */
.link-arrow {
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: .92rem;
  color: var(--navy);
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  position: relative;
}
.link-arrow::after {
  content: '';
  position: absolute;
  left: 0; bottom: -3px;
  height: 2px; width: 0;
  background: var(--gold);
  transition: width .3s var(--ease);
}
.link-arrow:hover { color: var(--gold-dark); }
.link-arrow:hover::after { width: 100%; }
.link-arrow i { transition: transform .28s var(--ease); }
.link-arrow:hover i { transform: translateX(4px); }

/* --------------------------------------------------------------------------
   5. Image frames — borders, dots, shimmer, hover
   -------------------------------------------------------------------------- */
.img-frame {
  position: relative;
  width: 100%;
  aspect-ratio: var(--ratio, 16/9);
  overflow: hidden;
  border-radius: var(--radius);
  background: linear-gradient(100deg, #E9EDF3 25%, #F5F7FA 45%, #E9EDF3 65%);
  background-size: 240% 100%;
  animation: shimmer 1.5s linear infinite;
}
@keyframes shimmer {
  from { background-position: 140% 0; }
  to   { background-position: -40% 0; }
}
.img-frame.loaded { animation: none; background: var(--paper-alt); }

.img-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  opacity: 0;
  transform: scale(1.04);
  transition: opacity .7s var(--ease), transform 1.1s var(--ease);
}
.img-frame img.is-loaded { opacity: 1; transform: scale(1); }

/* Zoom on hover when inside a card or link */
.zoom-parent:hover .img-frame img,
a:hover > .img-frame img { transform: scale(1.07); }

/* --- Frame treatments --- */

/* Gold hairline inset */
.frame-inset::after {
  content: '';
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: calc(var(--radius) - 6px);
  pointer-events: none;
}

/* Dotted outline that offsets behind the image */
.frame-dots { overflow: visible; }
.frame-dots img { border-radius: var(--radius); }
.frame-dots::before {
  content: '';
  position: absolute;
  inset: -16px -16px 16px 16px;
  border: 2px dotted var(--gold);
  border-radius: var(--radius);
  z-index: -1;
  transition: inset .45s var(--ease);
}
.frame-dots:hover::before { inset: -22px -22px 10px 10px; }

/* Solid offset block behind the image */
.frame-block { overflow: visible; }
.frame-block img { border-radius: var(--radius); position: relative; z-index: 1; box-shadow: var(--shadow); }
.frame-block::before {
  content: '';
  position: absolute;
  inset: 22px -22px -22px 22px;
  background: var(--navy);
  border-radius: var(--radius);
  z-index: 0;
  transition: inset .45s var(--ease);
}
.frame-block.block-gold::before { background: var(--gold); }
.frame-block:hover::before { inset: 14px -14px -14px 14px; }

/* Gold corner brackets */
.frame-corners { overflow: visible; }
.frame-corners img { border-radius: var(--radius-sm); }
.frame-corners::before,
.frame-corners::after {
  content: '';
  position: absolute;
  width: 62px; height: 62px;
  border: 3px solid var(--gold);
  transition: all .4s var(--ease);
  pointer-events: none;
}
.frame-corners::before { top: -13px; left: -13px; border-right: 0; border-bottom: 0; border-radius: 6px 0 0 0; }
.frame-corners::after  { bottom: -13px; right: -13px; border-left: 0; border-top: 0; border-radius: 0 0 6px 0; }
.frame-corners:hover::before { top: -19px; left: -19px; width: 78px; height: 78px; }
.frame-corners:hover::after  { bottom: -19px; right: -19px; width: 78px; height: 78px; }

/* Soft shadow lift */
.frame-lift { box-shadow: var(--shadow); transition: box-shadow .4s var(--ease), transform .4s var(--ease); }
.frame-lift:hover { box-shadow: var(--shadow-lg); transform: translateY(-6px); }

/* Tinted navy duotone overlay that clears on hover */
.frame-tint::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(12, 26, 51, .30);
  transition: opacity .45s var(--ease);
  pointer-events: none;
}
.zoom-parent:hover .frame-tint::after,
.frame-tint:hover::after { opacity: 0; }

/* Bottom scrim for text over image */
.frame-scrim::after {
  content: '';
  position: absolute;
  inset: 40% 0 0 0;
  background: linear-gradient(to top, rgba(9, 18, 36, .90), rgba(9, 18, 36, 0));
  pointer-events: none;
}

/* Rounded arch, used on portrait images */
.frame-arch { border-radius: 200px 200px var(--radius) var(--radius); }
.frame-arch img { border-radius: inherit; }

/* The .brandmark / .brandblock rules live in brand.css, which both the public
   site and the admin console load. */

/* --------------------------------------------------------------------------
   6. Header / navigation
   -------------------------------------------------------------------------- */
/* The utility bar and navbar share one fixed wrapper so they stack in order
   instead of the navbar covering the bar underneath it. */
.site-top {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 1040;
}

/* ---- Utility bar ---- */
.topbar {
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  background: var(--navy);
  color: rgba(255, 255, 255, .68);
  font-size: .8rem;
  overflow: hidden;
  transition: height .35s var(--ease), opacity .3s var(--ease);
}
.topbar-tagline {
  font-family: var(--font-ui);
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  font-size: .68rem;
  color: rgba(255, 255, 255, .62);
}
.topbar-cta { font-size: .78rem; color: rgba(255, 255, 255, .5); }
.topbar .social-dot {
  width: 26px; height: 26px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .2);
  color: rgba(255, 255, 255, .78);
  font-size: .75rem;
  transition: all .25s var(--ease);
}
.topbar .social-dot:hover { background: var(--gold); color: var(--navy); border-color: var(--gold); }

/* Once you scroll, the utility bar rolls up and the navbar takes over. */
.site-top.is-stuck .topbar { height: 0; opacity: 0; }

/* ---- Navbar ---- */
.site-header {
  height: var(--nav-h);
  display: flex;
  align-items: center;
  transition: background .35s var(--ease), box-shadow .35s var(--ease), height .35s var(--ease);
}
.site-header .navbar-brand { display: flex; align-items: center; gap: .7rem; --bm-size: 1.9rem; }
.site-top .logo-swap-light { display: block; }
.site-top .logo-swap-dark  { display: none; }

.site-top.is-stuck .site-header,
.site-top.header-solid .site-header {
  background: rgba(255, 255, 255, .97);
  backdrop-filter: blur(14px);
  box-shadow: 0 6px 26px -14px rgba(12, 26, 51, .32);
  border-bottom: 1px solid var(--line-soft);
  height: 66px;
}
.site-top.is-stuck .logo-swap-light,
.site-top.header-solid .logo-swap-light { display: none; }
.site-top.is-stuck .logo-swap-dark,
.site-top.header-solid .logo-swap-dark  { display: block; }

/* Pages with a light banner start solid and never sit over a photo. */
.site-top.header-solid .topbar { height: 0; opacity: 0; }

.main-nav .nav-link {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: .9rem;
  color: rgba(255, 255, 255, .9);
  padding: .5rem .8rem !important;
  position: relative;
  white-space: nowrap;
}
.main-nav .nav-link::after {
  content: '';
  position: absolute;
  left: .8rem; right: .8rem; bottom: .18rem;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s var(--ease);
}
.main-nav .nav-link:hover::after,
.main-nav .nav-link.active::after { transform: scaleX(1); }
.main-nav .nav-link.active { color: #fff; }
.main-nav .btn { white-space: nowrap; }

.site-top.is-stuck .main-nav .nav-link,
.site-top.header-solid .main-nav .nav-link { color: var(--ink); }
.site-top.is-stuck .main-nav .nav-link.active,
.site-top.header-solid .main-nav .nav-link.active { color: var(--navy); }

/* Squeeze the bar between the xl breakpoint and roomier screens. */
@media (min-width: 1200px) and (max-width: 1399.98px) {
  .site-header .navbar-brand { --bm-size: 1.6rem; }
  .main-nav .nav-link { font-size: .82rem; padding: .5rem .58rem !important; }
  .main-nav .nav-link::after { left: .58rem; right: .58rem; }
  .main-nav .btn { padding: .44rem .9rem; font-size: .8rem; }
  .main-nav .ms-xl-3 { margin-left: .6rem !important; }
}

/* ---- "About" dropdown ---- */
.main-nav .dropdown-toggle::after {
  margin-left: .35rem;
  vertical-align: .15em;
  border-top-width: .32em;
}
.nav-dropdown {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: .45rem;
  margin-top: .6rem !important;
  min-width: 232px;
}
.nav-dropdown .dropdown-item {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: .86rem;
  color: var(--ink-soft);
  border-radius: var(--radius-sm);
  padding: .58rem .75rem;
  display: flex;
  align-items: center;
  gap: .6rem;
}
.nav-dropdown .dropdown-item i { color: var(--gold-dark); font-size: .95rem; }
.nav-dropdown .dropdown-item:hover { background: var(--paper-alt); color: var(--navy); }
.nav-dropdown .dropdown-item.active { background: var(--navy); color: #fff; }
.nav-dropdown .dropdown-item.active i { color: var(--gold); }

.navbar-toggler {
  border: 2px solid rgba(255, 255, 255, .5);
  border-radius: 10px;
  padding: .3rem .5rem;
  color: #fff;
}
.site-top.is-stuck .navbar-toggler,
.site-top.header-solid .navbar-toggler { border-color: var(--line); color: var(--navy); }
.navbar-toggler:focus { box-shadow: none; }

/* ---- Mobile / tablet drawer (below the xl breakpoint) ---- */
@media (max-width: 1199.98px) {
  .navbar-collapse {
    background: #fff;
    margin-top: .8rem;
    border-radius: var(--radius);
    padding: .75rem;
    box-shadow: var(--shadow-lg);
    max-height: calc(100svh - var(--header-h) - 2rem);
    overflow-y: auto;
  }
  .main-nav .nav-link { color: var(--ink) !important; padding: .72rem .6rem !important; }
  .main-nav .nav-link::after { display: none; }
  .main-nav > .nav-item + .nav-item { border-top: 1px solid var(--line-soft); }
  .main-nav .nav-link.active { color: var(--gold-dark) !important; }
  .nav-dropdown {
    box-shadow: none;
    border: 0;
    border-top: 1px solid var(--line-soft);
    border-radius: 0;
    margin-top: 0 !important;
    padding: .25rem 0 .5rem .6rem;
    width: 100%;
  }
}

/* --------------------------------------------------------------------------
   7. Hero
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: var(--navy);
}
.hero-slides { position: absolute; inset: 0; }
.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1.4s var(--ease);
}
.hero-slide.active { opacity: 1; }
.hero-slide img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 28%;
  transform: scale(1.08);
  transition: transform 8s linear;
}
.hero-slide.active img { transform: scale(1); }

.hero-veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(100deg, rgba(9, 18, 36, .95) 0%, rgba(9, 18, 36, .78) 42%, rgba(9, 18, 36, .34) 78%),
    linear-gradient(to top, rgba(9, 18, 36, .82), transparent 45%);
}
/* Fine grid texture */
.hero-veil::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .045) 1px, transparent 1px);
  background-size: 74px 74px;
  mask-image: radial-gradient(circle at 30% 50%, #000 0%, transparent 72%);
}

/* padding-block only: .hero-content is also a .container, and the padding
   shorthand would wipe out its horizontal gutters. */
.hero-content {
  position: relative;
  z-index: 3;
  padding-block: calc(var(--header-h) + 3rem) 5rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  background: rgba(201, 162, 74, .14);
  border: 1px solid rgba(201, 162, 74, .42);
  color: var(--gold-light);
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: .76rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  padding: .45rem 1.1rem;
  border-radius: 99px;
  backdrop-filter: blur(6px);
}
.hero-badge .pulse-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--flag-red);
  box-shadow: 0 0 0 0 rgba(190, 30, 45, .8);
  animation: pulse-ring 2.1s infinite;
}
@keyframes pulse-ring {
  70%  { box-shadow: 0 0 0 11px rgba(190, 30, 45, 0); }
  100% { box-shadow: 0 0 0 0 rgba(190, 30, 45, 0); }
}

.hero h1 {
  color: #fff;
  font-size: clamp(2.4rem, 6vw, 4.7rem);
  font-weight: 800;
  letter-spacing: -.01em;
  line-height: 1.1;
  margin: 1.4rem 0 1.3rem;
  text-wrap: balance;
}
.hero h1 .gold { color: var(--gold); }
.hero h1 .outline {
  color: transparent;
  -webkit-text-stroke: 2px var(--gold);
}
.hero-sub {
  color: rgba(255, 255, 255, .8);
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  max-width: 56ch;
  margin-bottom: 2.2rem;
}

/* Hero counters strip */
.hero-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1px;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 3rem;
  backdrop-filter: blur(8px);
}
.hero-stat { background: rgba(9, 18, 36, .55); padding: 1.3rem 1.1rem; }
.hero-stat .n {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.5rem, 2.6vw, 2.1rem);
  color: var(--gold);
  line-height: 1;
}
.hero-stat .l {
  font-size: .76rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .62);
  margin-top: .45rem;
}

/* Slide indicators */
.hero-dots {
  position: absolute;
  right: clamp(1rem, 4vw, 3.5rem);
  top: 50%;
  transform: translateY(-50%);
  z-index: 4;
  display: flex;
  flex-direction: column;
  gap: .8rem;
}
.hero-dots button {
  width: 11px; height: 11px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, .55);
  background: transparent;
  padding: 0;
  transition: all .3s var(--ease);
}
.hero-dots button.active { background: var(--gold); border-color: var(--gold); transform: scale(1.35); }

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 1.8rem;
  transform: translateX(-50%);
  z-index: 4;
  color: rgba(255, 255, 255, .55);
  font-size: .7rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  text-align: center;
}
.scroll-cue span {
  display: block;
  width: 1px; height: 42px;
  margin: .6rem auto 0;
  background: linear-gradient(to bottom, var(--gold), transparent);
  animation: cue 2s var(--ease) infinite;
}
@keyframes cue { 0%,100% { opacity: .25; } 50% { opacity: 1; } }

@media (max-width: 991.98px) {
  .hero-dots { display: none; }
  .hero { min-height: auto; }
  .hero-content { padding-block: calc(var(--header-h) + 2.5rem) 4rem; }
}

/* --------------------------------------------------------------------------
   8. Page banner (interior pages)
   -------------------------------------------------------------------------- */
.page-banner {
  position: relative;
  padding: calc(var(--header-h) + 5rem) 0 4.5rem;
  background: var(--navy);
  overflow: hidden;
}
.page-banner > img {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: .34;
}
.page-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, rgba(9, 18, 36, .94) 12%, rgba(9, 18, 36, .60) 100%);
}
.page-banner .container { position: relative; z-index: 2; }
.page-banner h1 { color: #fff; margin-bottom: .8rem; }
.page-banner p { color: rgba(255, 255, 255, .74); max-width: 62ch; margin-bottom: 0; }

.crumbs {
  font-size: .82rem;
  color: rgba(255, 255, 255, .55);
  margin-bottom: 1.2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .5rem;
}
.crumbs a { color: rgba(255, 255, 255, .78); }
.crumbs a:hover { color: var(--gold-light); }
.crumbs .sep { color: var(--gold); }

/* --------------------------------------------------------------------------
   9. Parallax bands
   -------------------------------------------------------------------------- */
.parallax {
  position: relative;
  overflow: hidden;
  color: rgba(255, 255, 255, .8);
  padding: clamp(5rem, 10vw, 9rem) 0;
  background: var(--navy);
}
.parallax > .px-bg {
  position: absolute;
  inset: -18% 0;
  width: 100%;
  height: 136%;
  object-fit: cover;
  will-change: transform;
  z-index: 0;
}
.parallax::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(900px 500px at 22% 24%, rgba(201, 162, 74, .18), transparent 62%),
    linear-gradient(165deg, rgba(9, 18, 36, .92), rgba(9, 18, 36, .80));
}
.parallax .container { position: relative; z-index: 2; }
.parallax h1, .parallax h2, .parallax h3, .parallax h4 { color: #fff; }

/* Static (non-moving) dark photo band */
.static-band { position: relative; overflow: hidden; }
.static-band > .band-bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.static-band::after {
  content: '';
  position: absolute; inset: 0;
  background: rgba(9, 18, 36, .86);
}
.static-band .container { position: relative; z-index: 2; }

/* --------------------------------------------------------------------------
   10. Sticky split — one column fixed while the other scrolls
   -------------------------------------------------------------------------- */
.sticky-split { position: relative; }
.sticky-col {
  position: sticky;
  top: calc(var(--header-h) + 2.5rem);
  align-self: start;
}
@media (max-width: 991.98px) {
  .sticky-col { position: static; margin-bottom: 2.5rem; }
}

/* Scrolling steps beside the sticky image */
.scroll-step {
  padding: clamp(2.5rem, 6vw, 4.5rem) 0;
  border-bottom: 1px solid var(--line);
}
.scroll-step:last-child { border-bottom: 0; }
.scroll-step .step-no {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 3.2rem;
  line-height: 1;
  color: var(--line);
  transition: color .5s var(--ease);
}
.scroll-step.is-active .step-no { color: var(--gold); }
.bg-navy .scroll-step, .bg-navy-deep .scroll-step { border-color: rgba(255, 255, 255, .1); }
.bg-navy .scroll-step .step-no, .bg-navy-deep .scroll-step .step-no { color: rgba(255, 255, 255, .12); }
.bg-navy .scroll-step.is-active .step-no, .bg-navy-deep .scroll-step.is-active .step-no { color: var(--gold); }

/* --------------------------------------------------------------------------
   11. Cards
   -------------------------------------------------------------------------- */
.card-clean {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  height: 100%;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease), border-color .4s var(--ease);
  display: flex;
  flex-direction: column;
}
.card-clean:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(201, 162, 74, .55);
}
.card-clean .card-body { padding: 1.6rem; flex: 1; display: flex; flex-direction: column; }
.card-clean h3, .card-clean h4 { margin-bottom: .6rem; }
.card-clean h3 a, .card-clean h4 a { color: inherit; }
.card-clean:hover h3 a, .card-clean:hover h4 a { color: var(--navy-600); }
.card-clean p { color: var(--muted); font-size: .95rem; }
.card-clean .card-foot {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px dashed var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
}

/* Achievement card with the big stat */
.achv-card { position: relative; }
.achv-card .achv-stat {
  position: absolute;
  left: 1.25rem;
  bottom: 1.25rem;
  z-index: 3;
  background: rgba(9, 18, 36, .82);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(201, 162, 74, .5);
  border-radius: var(--radius-sm);
  padding: .55rem .95rem;
  color: #fff;
}
.achv-card .achv-stat .v {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.28rem;
  color: var(--gold);
  line-height: 1.1;
}
.achv-card .achv-stat .k {
  font-size: .68rem;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .68);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: .38rem;
  font-family: var(--font-ui);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: .32rem .8rem;
  border-radius: 99px;
  background: var(--paper-alt);
  color: var(--navy-600);
  border: 1px solid var(--line);
}
.pill-gold  { background: rgba(201, 162, 74, .14); color: var(--gold-dark); border-color: rgba(201, 162, 74, .38); }
.pill-navy  { background: var(--navy); color: #fff; border-color: var(--navy); }
.pill-red   { background: rgba(190, 30, 45, .1); color: var(--flag-red); border-color: rgba(190, 30, 45, .3); }
.pill-green { background: rgba(11, 122, 69, .1); color: var(--flag-green); border-color: rgba(11, 122, 69, .3); }

/* Card sitting on a dark band */
.card-dark {
  background: rgba(255, 255, 255, .045);
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: var(--radius-lg);
  padding: 1.8rem;
  height: 100%;
  transition: all .4s var(--ease);
}
.card-dark:hover {
  background: rgba(255, 255, 255, .075);
  border-color: rgba(201, 162, 74, .5);
  transform: translateY(-6px);
}
.card-dark h3, .card-dark h4 { color: #fff; }
.card-dark p { color: rgba(255, 255, 255, .68); margin-bottom: 0; }

/* Icon tile */
.icon-tile {
  width: 58px; height: 58px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  background: rgba(201, 162, 74, .13);
  color: var(--gold-dark);
  border: 1px solid rgba(201, 162, 74, .3);
  flex: 0 0 auto;
  transition: all .35s var(--ease);
}
.card-clean:hover .icon-tile, .card-dark:hover .icon-tile {
  background: var(--gold);
  color: var(--navy);
  transform: rotate(-6deg) scale(1.06);
}
.card-dark .icon-tile { background: rgba(201, 162, 74, .16); color: var(--gold-light); }

/* --------------------------------------------------------------------------
   12. Counters
   -------------------------------------------------------------------------- */
.counter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 1.6rem;
}
.counter {
  text-align: center;
  padding: 1.8rem 1rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, .13);
  background: rgba(255, 255, 255, .04);
  transition: all .4s var(--ease);
}
.counter:hover { border-color: rgba(201, 162, 74, .55); transform: translateY(-5px); }
.counter .num {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--gold);
  line-height: 1;
  letter-spacing: -.03em;
}
.counter .cap {
  margin-top: .7rem;
  font-size: .84rem;
  letter-spacing: .05em;
  color: rgba(255, 255, 255, .68);
}

/* --------------------------------------------------------------------------
   13. Timeline (achievements by year)
   -------------------------------------------------------------------------- */
.timeline { position: relative; padding-left: 2.6rem; }
.timeline::before {
  content: '';
  position: absolute;
  left: 9px; top: .5rem; bottom: .5rem;
  width: 2px;
  background: linear-gradient(to bottom, var(--gold), var(--line) 55%, transparent);
}
.timeline-item { position: relative; padding-bottom: 2.6rem; }
.timeline-item::before {
  content: '';
  position: absolute;
  left: -2.6rem; top: .45rem;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--gold);
  box-shadow: 0 0 0 5px rgba(201, 162, 74, .14);
}
.timeline-year {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--gold-dark);
  letter-spacing: .04em;
}

/* --------------------------------------------------------------------------
   14. Fact check cards
   -------------------------------------------------------------------------- */
.fact-card {
  background: #fff;
  border: 1px solid var(--line);
  border-left: 5px solid var(--flag-red);
  border-radius: var(--radius);
  padding: 1.7rem;
  height: 100%;
  transition: all .35s var(--ease);
}
.fact-card:hover { box-shadow: var(--shadow); transform: translateY(-5px); }
.fact-card.v-false          { border-left-color: var(--flag-red); }
.fact-card.v-misleading     { border-left-color: #D98A1F; }
.fact-card.v-missing-context{ border-left-color: #B08A2E; }
.fact-card.v-outdated       { border-left-color: var(--navy-500); }
.fact-card.v-true           { border-left-color: var(--flag-green); }

.fact-claim {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--ink);
  font-size: 1.05rem;
  line-height: 1.45;
  margin: .85rem 0 1rem;
}
.verdict-tag {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-family: var(--font-ui);
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .13em;
  text-transform: uppercase;
  padding: .32rem .78rem;
  border-radius: 5px;
  color: #fff;
  background: var(--flag-red);
}
.verdict-tag.v-misleading      { background: #D98A1F; }
.verdict-tag.v-missing-context { background: #B08A2E; }
.verdict-tag.v-outdated        { background: var(--navy-500); }
.verdict-tag.v-true            { background: var(--flag-green); }

/* --------------------------------------------------------------------------
   15. Prose (article bodies)
   -------------------------------------------------------------------------- */
.prose { font-size: 1.06rem; color: var(--ink-soft); }
.prose h2, .prose h3, .prose h4 { margin: 2.1rem 0 .9rem; }
.prose h4 { font-size: 1.22rem; color: var(--navy); }
.prose ul, .prose ol { margin: 0 0 1.3rem; padding-left: 1.3rem; }
.prose li { margin-bottom: .55rem; }
.prose ul { list-style: none; padding-left: 0; }
.prose ul li {
  position: relative;
  padding-left: 1.75rem;
}
.prose ul li::before {
  content: '';
  position: absolute;
  left: .25rem; top: .7em;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--gold);
}
.prose strong { color: var(--navy); font-weight: 700; }
.prose blockquote {
  border-left: 4px solid var(--gold);
  background: var(--paper-warm);
  padding: 1.2rem 1.5rem;
  margin: 1.8rem 0;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 1.08rem;
  color: var(--navy);
}
.prose img { border-radius: var(--radius); margin: 1.4rem 0; }
.prose a { color: var(--navy-600); border-bottom: 1px solid rgba(201, 162, 74, .55); }
.prose a:hover { color: var(--gold-dark); }

/* Pull-quote */
.pull-quote {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.2rem, 2.4vw, 1.75rem);
  line-height: 1.42;
  color: var(--navy);
  border-left: 4px solid var(--gold);
  padding-left: 1.6rem;
  margin: 2.5rem 0;
}

/* --------------------------------------------------------------------------
   16. Forms
   -------------------------------------------------------------------------- */
.form-label {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: .86rem;
  color: var(--navy);
  margin-bottom: .38rem;
}
.form-control, .form-select {
  border: 1.5px solid var(--line);
  border-radius: 10px;
  padding: .72rem .95rem;
  font-size: .95rem;
  color: var(--ink);
  transition: border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.form-control:focus, .form-select:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(201, 162, 74, .16);
}
.form-control::placeholder { color: #A6AEBD; }
.form-check-input:checked { background-color: var(--navy); border-color: var(--navy); }
.form-check-input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201, 162, 74, .2); }
.input-group-text { background: var(--paper-alt); border: 1.5px solid var(--line); color: var(--muted); }

/* Password visibility toggle */
.pw-wrap { position: relative; }
.pw-wrap .form-control { padding-right: 3rem; }
.pw-toggle {
  position: absolute;
  right: .3rem; top: 50%;
  transform: translateY(-50%);
  width: 2.4rem; height: 2.4rem;
  display: grid; place-items: center;
  border: 0; background: transparent;
  color: var(--muted);
  border-radius: 8px;
  cursor: pointer;
  transition: color .2s var(--ease), background .2s var(--ease);
}
.pw-toggle:hover { color: var(--navy); background: var(--paper-alt); }

/* --------------------------------------------------------------------------
   17. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  background: var(--navy);
  color: rgba(255, 255, 255, .62);
  padding-top: 4.5rem;
  position: relative;
  overflow: hidden;
}
.site-footer::before {
  content: '';
  position: absolute;
  inset: auto -10% -55% auto;
  width: 620px; height: 620px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 162, 74, .10), transparent 66%);
  pointer-events: none;
}
.site-footer .container { position: relative; z-index: 2; }
.site-footer .brandblock { align-items: flex-start; --bm-size: 2rem; }
.site-footer .brandblock .bm-rule { max-width: 240px; }
.site-footer h5 {
  color: #fff;
  font-size: .84rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  margin-bottom: 1.3rem;
}
.site-footer a { color: rgba(255, 255, 255, .62); font-size: .93rem; }
.site-footer a:hover { color: var(--gold-light); padding-left: 4px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .58rem; }
.site-footer li a { transition: color .2s var(--ease), padding-left .2s var(--ease); display: inline-block; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .1);
  margin-top: 3rem;
  padding: 1.5rem 0;
  font-size: .85rem;
}
.social-round {
  width: 40px; height: 40px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .2);
  color: rgba(255, 255, 255, .8);
  transition: all .3s var(--ease);
}
.social-round:hover {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy) !important;
  transform: translateY(-4px);
  padding-left: 0 !important;
}

/* Newsletter strip */
.newsletter-strip {
  background: var(--gold);
  color: var(--navy);
  padding: 2.4rem 0;
}
.newsletter-strip h3 { color: var(--navy); margin: 0; }
.newsletter-strip .form-control { border-color: rgba(12, 26, 51, .2); }

/* --------------------------------------------------------------------------
   18. AI chat widget
   -------------------------------------------------------------------------- */
.chat-fab {
  position: fixed;
  right: clamp(1rem, 3vw, 1.75rem);
  bottom: clamp(1rem, 3vw, 1.75rem);
  z-index: 1055;
  width: 62px; height: 62px;
  border-radius: 50%;
  border: 0;
  background: var(--gold);
  color: var(--navy);
  font-size: 1.6rem;
  display: grid;
  place-items: center;
  box-shadow: 0 14px 34px -10px rgba(201, 162, 74, .72);
  cursor: pointer;
  transition: transform .3s var(--ease), background .3s var(--ease);
}
.chat-fab:hover { transform: scale(1.08) rotate(-6deg); background: var(--gold-light); }
.chat-fab::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid var(--gold);
  animation: fab-ring 2.4s var(--ease) infinite;
}
@keyframes fab-ring {
  0%   { transform: scale(1);    opacity: .75; }
  100% { transform: scale(1.55); opacity: 0; }
}
.chat-fab .bi-x-lg { display: none; }
.chat-fab.open .bi-chat-dots-fill { display: none; }
.chat-fab.open .bi-x-lg { display: block; }
.chat-fab.open::after { display: none; }

.chat-panel {
  position: fixed;
  right: clamp(1rem, 3vw, 1.75rem);
  bottom: calc(clamp(1rem, 3vw, 1.75rem) + 76px);
  z-index: 1056;
  width: min(392px, calc(100vw - 2rem));
  height: min(578px, calc(100svh - 140px));
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 34px 80px -22px rgba(12, 26, 51, .48);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px) scale(.97);
  transform-origin: bottom right;
  transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
  border: 1px solid var(--line);
}
.chat-panel.open { opacity: 1; visibility: visible; transform: translateY(0) scale(1); }

.chat-head {
  background: var(--navy);
  color: #fff;
  padding: 1rem 1.15rem;
  display: flex;
  align-items: center;
  gap: .8rem;
  position: relative;
}
.chat-head::after {
  content: '';
  position: absolute;
  inset: auto 0 0 0;
  height: 3px;
  display: block;
  background: linear-gradient(90deg, var(--flag-black) 0 25%, var(--flag-red) 25% 50%, #fff 50% 75%, var(--flag-green) 75% 100%);
}
.chat-head .avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .1);
  display: grid; place-items: center;
  flex: 0 0 auto;
  overflow: hidden;
}
.chat-head .avatar img, .chat-head .avatar svg { width: 100%; height: 100%; }
.chat-head .t { font-family: var(--font-ui); font-weight: 700; font-size: .96rem; line-height: 1.2; }
.chat-head .s { font-size: .74rem; color: rgba(255, 255, 255, .62); display: flex; align-items: center; gap: .35rem; }
.chat-head .s .dot { width: 6px; height: 6px; border-radius: 50%; background: #3FCF7F; }

.chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 1.1rem;
  background: var(--paper-alt);
  display: flex;
  flex-direction: column;
  gap: .85rem;
  scroll-behavior: smooth;
}
.chat-msg { max-width: 86%; font-size: .9rem; line-height: 1.62; }
.chat-msg .bubble {
  padding: .72rem .95rem;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink-soft);
  box-shadow: var(--shadow-sm);
}
.chat-msg.bot .bubble  { border-bottom-left-radius: 4px; }
.chat-msg.user { align-self: flex-end; }
.chat-msg.user .bubble {
  background: var(--navy);
  border-color: var(--navy);
  color: rgba(255, 255, 255, .93);
  border-bottom-right-radius: 4px;
}
.chat-msg.error .bubble { background: #FEF2F2; border-color: #FCA5A5; color: #991B1B; }
.chat-msg .bubble p:last-child { margin-bottom: 0; }
.chat-msg .bubble p { margin-bottom: .6rem; }
.chat-msg .bubble ul { margin: .3rem 0 .6rem; padding-left: 1.1rem; }
.chat-msg .bubble li { margin-bottom: .25rem; }
.chat-msg .meta { font-size: .68rem; color: var(--muted); margin-top: .3rem; padding: 0 .3rem; }

.chat-typing { display: flex; gap: 4px; padding: .85rem 1rem; }
.chat-typing i {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--navy-500);
  animation: typing 1.35s var(--ease) infinite;
}
.chat-typing i:nth-child(2) { animation-delay: .18s; }
.chat-typing i:nth-child(3) { animation-delay: .36s; }
@keyframes typing {
  0%, 60%, 100% { transform: translateY(0);    opacity: .4; }
  30%           { transform: translateY(-5px); opacity: 1; }
}

.chat-suggest { display: flex; flex-wrap: wrap; gap: .4rem; padding: 0 1.1rem .8rem; background: var(--paper-alt); }
.chat-suggest button {
  font-size: .77rem;
  padding: .35rem .7rem;
  border-radius: 99px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--navy-600);
  cursor: pointer;
  transition: all .2s var(--ease);
  text-align: left;
}
.chat-suggest button:hover { background: var(--navy); color: #fff; border-color: var(--navy); }

.chat-foot { padding: .8rem; border-top: 1px solid var(--line); background: #fff; }
.chat-foot .input-row { display: flex; gap: .5rem; align-items: flex-end; }
.chat-foot textarea {
  flex: 1;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: .6rem .8rem;
  font-size: .9rem;
  font-family: inherit;
  resize: none;
  max-height: 110px;
  line-height: 1.5;
  transition: border-color .2s var(--ease);
}
.chat-foot textarea:focus { outline: 0; border-color: var(--gold); }
.chat-send {
  width: 42px; height: 42px;
  flex: 0 0 auto;
  border-radius: 12px;
  border: 0;
  background: var(--navy);
  color: #fff;
  display: grid; place-items: center;
  cursor: pointer;
  transition: background .25s var(--ease), transform .25s var(--ease);
}
.chat-send:hover:not(:disabled) { background: var(--gold); color: var(--navy); transform: scale(1.05); }
.chat-send:disabled { opacity: .45; cursor: not-allowed; }
.chat-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .7rem;
  color: var(--muted);
  margin-top: .45rem;
  padding: 0 .2rem;
}
.chat-meta-row .over { color: var(--flag-red); font-weight: 600; }

@media (max-width: 480px) {
  .chat-panel {
    right: .5rem; left: .5rem;
    width: auto;
    bottom: 5.4rem;
    height: min(560px, calc(100svh - 7.5rem));
  }
}

/* --------------------------------------------------------------------------
   19. Scroll reveal
   -------------------------------------------------------------------------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
  will-change: opacity, transform;
}
[data-reveal="left"]  { transform: translateX(-34px); }
[data-reveal="right"] { transform: translateX(34px); }
[data-reveal="zoom"]  { transform: scale(.94); }
[data-reveal="fade"]  { transform: none; }
[data-reveal].revealed { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
  .img-frame { animation: none; }
}

/* --------------------------------------------------------------------------
   20. Misc components
   -------------------------------------------------------------------------- */

/* Marquee ticker */
.ticker {
  background: var(--navy);
  color: rgba(255, 255, 255, .82);
  padding: .7rem 0;
  overflow: hidden;
  white-space: nowrap;
  border-top: 1px solid rgba(255, 255, 255, .08);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.ticker-track { display: inline-flex; gap: 3rem; animation: ticker 46s linear infinite; padding-left: 3rem; }
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-item {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: .88rem;
  display: inline-flex;
  align-items: center;
  gap: .6rem;
}
.ticker-item .v { color: var(--gold); font-weight: 800; }
.ticker-item::before { content: '★'; color: var(--gold); font-size: .7rem; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* Filter chips */
.filter-bar { display: flex; flex-wrap: wrap; gap: .5rem; }
.filter-chip {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: .84rem;
  padding: .45rem 1.05rem;
  border-radius: 99px;
  border: 1.5px solid var(--line);
  background: #fff;
  color: var(--ink-soft);
  transition: all .25s var(--ease);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: .4rem;
}
.filter-chip:hover { border-color: var(--gold); color: var(--navy); }
.filter-chip.active { background: var(--navy); border-color: var(--navy); color: #fff; }
.filter-chip .n {
  font-size: .72rem;
  background: rgba(12, 26, 51, .08);
  border-radius: 99px;
  padding: 0 .42rem;
}
.filter-chip.active .n { background: rgba(255, 255, 255, .18); }

/* Pagination */
.pagination .page-link {
  border: 1.5px solid var(--line);
  color: var(--navy);
  font-family: var(--font-ui);
  font-weight: 600;
  margin: 0 .18rem;
  border-radius: 10px !important;
  min-width: 42px;
  text-align: center;
}
.pagination .page-link:hover { background: var(--paper-alt); border-color: var(--gold); color: var(--navy); }
.pagination .active .page-link { background: var(--navy); border-color: var(--navy); color: #fff; }
.pagination .disabled .page-link { color: #B9C0CC; }

/* Accordion */
.accordion-item { border: 1px solid var(--line); border-radius: var(--radius) !important; margin-bottom: .8rem; overflow: hidden; }
.accordion-button {
  font-family: var(--font-ui);
  font-weight: 700;
  color: var(--navy);
  padding: 1.1rem 1.3rem;
  background: #fff;
}
.accordion-button:not(.collapsed) { background: var(--paper-warm); color: var(--navy); box-shadow: none; }
.accordion-button:focus { box-shadow: none; border-color: var(--gold); }
.accordion-button::after { filter: sepia(1) saturate(3) hue-rotate(3deg); }
.accordion-body { color: var(--muted); padding: 0 1.3rem 1.3rem; }

/* Gallery masonry-ish grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.1rem;
}
.gallery-item { position: relative; overflow: hidden; border-radius: var(--radius); cursor: pointer; }
.gallery-item:nth-child(6n+1) { grid-column: span 2; }
.gallery-item .cap {
  position: absolute;
  inset: auto 0 0 0;
  padding: 2.4rem 1.1rem 1.05rem;
  background: linear-gradient(to top, rgba(9, 18, 36, .92), transparent);
  color: #fff;
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: .9rem;
  transform: translateY(8px);
  opacity: 0;
  transition: all .35s var(--ease);
}
.gallery-item:hover .cap { transform: translateY(0); opacity: 1; }
@media (max-width: 575.98px) {
  .gallery-item:nth-child(6n+1) { grid-column: span 1; }
}

/* Progress meter */
.meter { height: 8px; background: var(--line-soft); border-radius: 99px; overflow: hidden; }
.meter > i {
  display: block;
  height: 100%;
  background: var(--gold);
  border-radius: 99px;
  width: 0;
  transition: width 1.4s var(--ease);
}
.bg-navy .meter, .bg-navy-deep .meter, .parallax .meter { background: rgba(255, 255, 255, .14); }

/* Back to top */
.to-top {
  position: fixed;
  left: clamp(1rem, 3vw, 1.75rem);
  bottom: clamp(1rem, 3vw, 1.75rem);
  z-index: 1050;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--navy);
  display: grid; place-items: center;
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px);
  transition: all .3s var(--ease);
  cursor: pointer;
}
.to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { background: var(--navy); color: #fff; border-color: var(--navy); }

/* Reading progress bar */
.read-progress {
  position: fixed;
  inset: 0 auto auto 0;
  height: 3px;
  width: 0;
  background: var(--gold);
  z-index: 1060;
  transition: width .1s linear;
}

/* Empty state */
.empty-state {
  text-align: center;
  padding: 4rem 1rem;
  color: var(--muted);
}
.empty-state i { font-size: 3rem; color: var(--line); display: block; margin-bottom: 1rem; }

/* Lightbox */
.lb-overlay {
  position: fixed;
  inset: 0;
  z-index: 1080;
  background: rgba(6, 12, 24, .95);
  display: grid;
  place-items: center;
  padding: 2rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s var(--ease), visibility .3s;
}
.lb-overlay.open { opacity: 1; visibility: visible; }
.lb-overlay img { max-width: 100%; max-height: 84vh; border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.lb-overlay .lb-cap { color: rgba(255, 255, 255, .8); text-align: center; margin-top: 1rem; font-size: .92rem; }
.lb-close {
  position: absolute;
  top: 1.5rem; right: 1.5rem;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .3);
  background: transparent;
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  transition: all .25s var(--ease);
}
.lb-close:hover { background: #fff; color: var(--navy); }

/* Share buttons */
.share-row { display: flex; gap: .5rem; flex-wrap: wrap; }
.share-row a {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: grid; place-items: center;
  color: var(--navy);
  transition: all .25s var(--ease);
}
.share-row a:hover { background: var(--navy); color: #fff; border-color: var(--navy); transform: translateY(-3px); }

/* Sources / citation box */
.source-box {
  background: var(--paper-warm);
  border: 1px dashed var(--gold);
  border-radius: var(--radius);
  padding: 1.1rem 1.3rem;
  font-size: .9rem;
  color: var(--muted);
}
.source-box strong { color: var(--navy); }

/* Flash message stack */
.flash-stack {
  position: fixed;
  top: calc(var(--header-h) + 12px);
  right: clamp(.75rem, 3vw, 1.5rem);
  z-index: 1070;
  width: min(420px, calc(100vw - 1.5rem));
  display: flex;
  flex-direction: column;
  gap: .6rem;
  pointer-events: none;
}
.flash-stack .alert {
  pointer-events: auto;
  border: 0;
  border-left: 5px solid currentColor;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  font-size: .93rem;
  margin: 0;
  animation: flash-in .45s var(--ease);
}
.flash-stack .alert > div { color: var(--ink-soft); }
@keyframes flash-in {
  from { opacity: 0; transform: translateX(24px); }
  to   { opacity: 1; transform: none; }
}

/* Skip link */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 2000;
  background: var(--gold);
  color: var(--navy);
  padding: .8rem 1.4rem;
  font-weight: 700;
  border-radius: 0 0 var(--radius-sm) 0;
}
.skip-link:focus { left: 0; }
