/* ============================================================
   Open Knowledge Development Initiative
   Main Stylesheet
   ============================================================ */


/* ============================================================
   DESIGN TOKENS
   ============================================================ */

:root {

  --navy-900: #0A1F3D;
  --navy-800: #0F2E5C;
  --navy-700: #16407c;

  --blue-400: #4FC3E8;
  --blue-300: #9FE0F5;

  --pink-500: #FF4C86;
  --pink-300: #FFB3CB;

  --paper: #FFF8F0;
  --paper-dim: #F3ECE1;

  --ink: #0A1F3D;
  --ink-soft: rgba(10,31,61,0.68);

  --white: #FFFFFF;

  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, monospace;

  --gap-xs: 0.5rem;
  --gap-sm: 1rem;
  --gap-md: 2rem;
  --gap-lg: 4rem;
  --gap-xl: 7rem;

  --radius: 14px;
  --max-width: 1200px;

  --transition-fast: .15s ease;
  --transition: .2s ease;
}


/* ============================================================
   RESET
   ============================================================ */

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

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

ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  line-height: 1.1;
  margin: 0 0 var(--gap-sm);
  font-weight: 600;
}

p {
  margin: 0 0 var(--gap-sm);
}


/* ============================================================
   CONTAINER
   ============================================================ */

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: clamp(1.25rem, 4vw, 3rem);
  padding-right: clamp(1.25rem, 4vw, 3rem);
}


/* ============================================================
   ACCESSIBILITY
   ============================================================ */

:focus-visible {
  outline: 3px solid var(--pink-500);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  left: -9999px;
  top: 1rem;
  z-index: 9999;

  background: var(--pink-500);
  color: var(--white);

  padding: .75rem 1rem;
  border-radius: 8px;
}

.skip-link:focus {
  left: 1rem;
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }

}


/* ============================================================
   TYPOGRAPHY / LABELS
   ============================================================ */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .5em;

  margin-bottom: var(--gap-sm);

  font-family: var(--font-mono);
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;

  color: var(--pink-500);
}

.eyebrow::before {
  content: "";

  width: 22px;
  height: 1px;

  background: var(--pink-500);

  flex-shrink: 0;
}

.on-dark .eyebrow {
  color: var(--blue-300);
}

.on-dark .eyebrow::before {
  background: var(--blue-300);
}


/* ============================================================
   LOGOS
   ============================================================ */

.brand-logo {
  display: block;
  width: auto;
  height: 60px;
}

.brand-logo-full {
  display: block;
  width: auto;
  height: 64px;
}


/* ============================================================
   BUTTONS
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .6em;

  padding: .85em 1.5em;

  border: 1.5px solid transparent;
  border-radius: 999px;

  font-family: var(--font-mono);
  font-size: .82rem;
  line-height: 1.2;
  letter-spacing: .03em;

  cursor: pointer;
  white-space: nowrap;
  box-sizing: border-box;

  transition:
    transform var(--transition),
    background var(--transition),
    color var(--transition),
    border-color var(--transition);
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--pink-500);
  color: var(--white);
}

.btn-primary:hover {
  background: #ff689a;
}

.btn-outline {
  border-color: currentColor;
  background: transparent;
  color: var(--navy-900);
}

.on-dark .btn-outline {
  color: var(--white);
}

.btn-outline:hover {
  background: rgba(255,255,255,.08);
}

.btn-alert {
  border-color: var(--pink-500);
  color: var(--pink-500);
}

.on-dark .btn-alert {
  color: var(--pink-300);
  border-color: var(--pink-300);
}

.btn-alert:hover {
  background: rgba(255,76,134,.1);
}

.btn-ghost {
  color: var(--navy-900);
  padding: .8em .2em;
}

.btn-ghost::after {
  content: "→";
  transition: transform var(--transition);
}

.btn-ghost:hover::after {
  transform: translateX(4px);
}


/* ============================================================
   NAVIGATION
   ============================================================ */

.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;

  background: rgba(10,31,61,.94);

  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);

  border-bottom: 1px solid rgba(255,255,255,.08);
}

.navbar-inner {
  min-height: 78px;

  display: flex;
  align-items: center;
  justify-content: space-between;

  gap: 1.5rem;
}

.brand {
  display: flex;
  align-items: center;

  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.6rem;
}

.nav-links a {
  display: inline-block;

  color: rgba(255,255,255,.78);

  font-size: .88rem;

  padding: .4em 0;

  border-bottom: 2px solid transparent;

  transition:
    color var(--transition-fast),
    border-color var(--transition-fast);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--white);
  border-color: var(--pink-500);
}


/* ============================================================
   NAVIGATION ACTION BUTTONS
   ============================================================ */

.nav-actions {
  display: flex;
  align-items: center;
  gap: .8rem;

  flex-shrink: 0;
}

.nav-actions .btn {
  min-width: 150px;
  min-height: 44px;

  padding: .75em 1.3em;

  font-size: .90rem;
  line-height: 1.2;

  white-space: nowrap;
  box-sizing: border-box;
}

/* ==========================================================
   RESOURCES NAVIGATION
========================================================== */

.resources-nav {
  position: relative;
}


/* ----------------------------------------------------------
   TRIGGER
---------------------------------------------------------- */

.resources-trigger {

  display: inline-flex;

  align-items: center;

  justify-content: center;

  gap: .4rem;

  padding: 0;

  margin: 0;

  border: 0;

  background: transparent;

  color:  #FF4C86;

  font-family: inherit;

  font-size: inherit;

  font-weight: inherit;

  line-height: inherit;

  cursor: pointer;

  white-space: nowrap;

}


/* Arrow */

.resources-arrow {

  display: inline-block;

  font-size: .72em;

  line-height: 1;

  transition:
    transform .2s ease;

}


/* Rotate arrow when open */

.resources-nav.open
.resources-arrow {

  transform:
    rotate(180deg);

}


/* ----------------------------------------------------------
   DROPDOWN
---------------------------------------------------------- */

.resources-menu {

  position: absolute;

  top: calc(100% + 16px);

  left: 50%;

  z-index: 2000;

  width: 170px;

  padding: 5px;

  border: 1px solid rgba(0, 0, 0, .08);

  border-radius: 10px;

  background: #ffffff;

  box-shadow:
    0 18px 45px rgba(0, 0, 0, .16);

  opacity: 0;

  visibility: hidden;

  pointer-events: none;

  transform:
    translate(-50%, -8px);

  transition:
    opacity .2s ease,
    visibility .2s ease,
    transform .2s ease;

}


/* Visible */

.resources-nav.open
.resources-menu {

  opacity: 1;

  visibility: visible;

  pointer-events: auto;

  transform:
    translate(-50%, 0);

}


/* ----------------------------------------------------------
   DROPDOWN ITEMS
---------------------------------------------------------- */

.resources-item {

  display: flex;

  align-items: center;
  
  flex-direction: row;

  gap: 5px;

  width: 100%;

  padding: 6px;

  border-radius: 7px;

  color: #17231d;

  text-decoration: none;

  transition:
    background .2s ease;

}


.resources-item:hover {

  background:
    #f1f5f2;

}


/* ----------------------------------------------------------
   ICON
---------------------------------------------------------- */

.resources-icon {

  display: flex;

  align-items: center;

  justify-content: center;

  flex-shrink: 0;

  width: 32px;

  height: 32px;

  border-radius: 8px;

  background:
    #0F2E5C;

  color:
    #FF4C86;

  font-size: 14px;

  transition:
    background .2s ease,
    color .2s ease;

}


.resources-item:hover
.resources-icon {

  background:
    #FF4C86;

  color:
  #ffffff;

}


/* ----------------------------------------------------------
   TEXT
---------------------------------------------------------- */

.resources-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.resources-text strong {

  display: flex;

  margin-bottom: 3px;

  color:
    #17231d;

  font-size: 13px;

  font-weight: 700;

  line-height: 1.3;

}


.resources-text small {

  display: block;

  color:
    #6a756f;

  font-size: 10.5px;

  line-height: 1.45;

}


/* ==========================================================
   MOBILE
========================================================== */

@media (max-width: 900px) {

  .resources-menu {

    left: auto;

    right: 0;

    transform:
      translateY(-8px);

  }


  .resources-nav.open
  .resources-menu {

    transform:
      translateY(0);

  }

}


@media (max-width: 700px) {

  .resources-menu {

    width:
      min(320px, calc(100vw - 30px));

    right: -10px;

  }

}

/* ============================================================
   NAVIGATION TOGGLE
   ============================================================ */

.nav-toggle {
  display: none;

  width: 34px;
  height: 28px;

  position: relative;

  background: none;
  border: 0;

  cursor: pointer;
}

.nav-toggle span {
  position: absolute;
  left: 0;

  width: 100%;
  height: 2px;

  background: var(--white);

  transition:
    transform .2s ease,
    opacity .2s ease;
}

.nav-toggle span:nth-child(1) {
  top: 1px;
}

.nav-toggle span:nth-child(2) {
  top: 13px;
}

.nav-toggle span:nth-child(3) {
  top: 25px;
}

.nav-toggle.open span:nth-child(1) {
  transform: translateY(12px) rotate(45deg);
}

.nav-toggle.open span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.open span:nth-child(3) {
  transform: translateY(-12px) rotate(-45deg);
}


/* ============================================================
   HERO
   ============================================================ */

.hero,
.page-hero {
  position: relative;

  background: var(--navy-900);
  color: var(--white);

  overflow: hidden;

  display: flex;
  align-items: center;
}

.hero {
  min-height: 400px;
  padding: clamp(4rem, 8vw, 7rem) 0 5rem;
}

.page-hero {
  min-height: 370px;
  padding: clamp(4rem, 7vw, 6rem) 0 4rem;
}

.hero canvas,
.page-hero canvas {
  position: absolute;
  inset: 0;

  width: 100%;
  height: 100%;

  opacity: .55;
}

.hero .container,
.page-hero .container {
  position: relative;
  z-index: 2;
}

.hero-content,
.page-hero-content {
  max-width: 800px;
}

.hero h1,
.page-hero h1 {
  color: var(--white);

  font-size: clamp(2.5rem, 5.5vw, 4.4rem);

  letter-spacing: -.025em;

  margin-bottom: 1rem;
}

.hero-sub,
.page-hero p.lead {
  max-width: 600px;

  color: rgba(255,255,255,.78);

  font-size: clamp(1rem, 1.6vw, 1.18rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;

  gap: .8rem;

  margin-top: 1.5rem;
  margin-bottom: 2.5rem;
}

.hero-stats {
  display: grid;

  grid-template-columns: repeat(4, minmax(0,1fr));

  gap: 1rem;

  margin-top: 2rem;

  padding-top: 1.5rem;

  border-top: 1px solid rgba(255,255,255,.15);
}

.hero-stat .num {
  display: block;

  font-family: var(--font-display);

  font-size: clamp(1.6rem, 3vw, 2.4rem);

  color: var(--blue-300);
}

.hero-stat .label {
  display: block;

  max-width: 220px;

  font-family: var(--font-mono);
  font-size: .7rem;

  line-height: 1.45;

  letter-spacing: .05em;
  text-transform: uppercase;

  color: rgba(255,255,255,.58);
}

.about-hero-stat {
  grid-template-columns: minmax(0,220px);
  border-top: 0;
  padding-top: 0;
  margin-top: 1.5rem;
}


/* ============================================================
   HERO ROTATING WORD
   ============================================================ */

.rotating-word-wrap {
  position: relative;
  display: inline-block;
  min-width: 10ch;
  min-height: 1.1em;
  vertical-align: baseline;
  color: #FF4C86;
}

.rotating-word {
  position: absolute;
  left: 0;
  top: 0;
  opacity: 0;
  transform: translateY(12px);

  transition:
    opacity 0.5s ease,
    transform 0.5s ease;

  white-space: nowrap;
  pointer-events: none;
  color: #FF4C86;
  font-weight: 600;
}

.rotating-word.is-active {
  position: relative;
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  color: #FF4C86;
}


/* ============================================================
   SECTIONS
   ============================================================ */

section {
  padding: clamp(4rem, 7vw, 7rem) 0;
}

.section-paper {
  background: var(--paper);
}

.section-dim {
  background: var(--paper-dim);
}

.section-navy {
  background: var(--navy-900);
  color: var(--white);
}

.section-panel {
  background: var(--navy-800);
  color: var(--white);
}


/* ============================================================
   SECTION HEADINGS
   ============================================================ */

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;

  gap: 2rem;

  margin-bottom: 4rem;

  flex-wrap: wrap;
}

.section-head h2 {
  max-width: 620px;

  font-size: clamp(1.8rem, 3.6vw, 2.6rem);

  margin: 0;
}

.section-head p {
  max-width: 420px;

  margin: 0;

  color: var(--ink-soft);
}

.on-dark .section-head p {
  color: rgba(255,255,255,.7);
}


/* ============================================================
   GRIDS
   ============================================================ */

.grid {
  display: grid;
  gap: 1.5rem;
}

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

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

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


/* ============================================================
   CARDS
   ============================================================ */

.card {
  min-width: 0;

  background: var(--white);

  border: 1px solid rgba(10,31,61,.08);

  border-radius: var(--radius);

  padding: 2rem;

  transition:
    transform var(--transition),
    box-shadow var(--transition);
}

.card:hover {
  transform: translateY(-3px);

  box-shadow:
    0 18px 40px -20px rgba(10,31,61,.35);
}

.card h3 {
  font-size: 1.25rem;
  margin-bottom: .5rem;
}

.card p {
  color: var(--ink-soft);
  font-size: .95rem;
}

.card p:last-child {
  margin-bottom: 0;
}

.card-dark {
  background: var(--navy-800);
  border-color: rgba(255,255,255,.08);
}

.card-dark h3 {
  color: var(--white);
}

.card-dark p {
  color: rgba(255,255,255,.72);
}

/* ============================================================
   POST-CARDS
   ============================================================ */
.post-card .thumb {
  overflow: hidden;
  border-radius: 12px;
}

.post-card .thumb img {
  display: block;

  width: 100%;
  height: 100%;
  min-height: 210px;

  object-fit: cover;

  transition: transform .35s ease;
}

.post-card:hover .thumb img {
  transform: scale(1.04);
}

/* ============================================================
   PILLS
   ============================================================ */

.pill {
  display: inline-block;

  padding: .35em .8em;

  margin-bottom: .75rem;

  border-radius: 999px;

  background: rgba(255,76,134,.12);

  color: var(--pink-500);

  font-family: var(--font-mono);
  font-size: .68rem;

  letter-spacing: .06em;
  text-transform: uppercase;
}

.on-dark .pill {
  background: rgba(79,195,232,.16);
  color: var(--blue-300);
}


/* ============================================================
   ABOUT PAGE
   ============================================================ */

.about-intro {
  max-width: 900px;
}

.about-intro h2 {
  max-width: 800px;

  font-size: clamp(2rem, 4vw, 3rem);

  letter-spacing: -.02em;

  margin-bottom: 1.5rem;
}

.about-intro p {
  max-width: 820px;

  color: var(--ink-soft);

  font-size: 1rem;
}

.about-intro p:last-of-type {
  margin-bottom: 1.25rem;
}

.about-history-btn {
  margin-top: .25rem;
}

.about-section-title {
  max-width: 760px;

  margin-bottom: 2.5rem;
}

.about-section-title h2 {
  margin-bottom: .75rem;

  font-size: clamp(2rem, 3.8vw, 2.8rem);
}

.about-section-title p {
  max-width: 720px;

  color: var(--ink-soft);
}

.about-card {
  min-width: 0;
}

.about-card h3 {
  line-height: 1.2;
}

.thematic-list {
  display: grid;

  gap: .7rem;

  margin-top: 1.25rem;
}

.thematic-item {
  padding: 1rem;

  background: rgba(255,255,255,.55);

  border: 1px solid rgba(10,31,61,.07);

  border-radius: 10px;
}

.thematic-item strong {
  display: block;

  margin-bottom: .3rem;

  font-size: .9rem;
}

.thematic-item p {
  margin: 0;

  font-size: .85rem;

  line-height: 1.55;
}

.partner-card {
  display: flex;
  flex-direction: column;

  height: 100%;
}

.partner-card .read-more {
  display: inline-flex;
  align-items: center;
  gap: .4rem;

  margin-top: auto;
  padding-top: 1rem;

  font-family: var(--font-mono);
  font-size: .78rem;

  color: var(--pink-500);
}

.partner-card .read-more::after {
  content: "→";

  transition: transform var(--transition);
}

.partner-card .read-more:hover::after {
  transform: translateX(3px);
}

.about-cta-section {
  padding-top: 5rem;
  padding-bottom: 5rem;
}

.about-cta {
  max-width: 700px;
}

.about-cta h2 {
  font-size: clamp(2rem, 4vw, 3rem);

  color: var(--white);
}

.about-cta .hero-sub {
  max-width: 650px;

  margin-left: auto;
  margin-right: auto;
}



/* ============================================================
   FOOTER
   ============================================================ */

.site-footer {
  display: block;

  width: 100%;

  background: var(--navy-900);

  color: rgba(255,255,255,.65);

  padding: 22px 0 0;

  overflow: hidden;
}


/* ---------- Footer grid ---------- */

.site-footer .footer-grid {
  display: grid;

  grid-template-columns:
    minmax(230px, 1.5fr)
    minmax(120px, 1fr)
    minmax(130px, 1fr)
    minmax(160px, 1fr);

  gap: 1.5rem;

  align-items: start;

  padding: 0 0 16px;

  margin: 0;

  border-bottom: 1px solid rgba(255,255,255,.09);
}


/* ---------- Footer brand ---------- */

.site-footer .footer-brand {
  min-width: 0;

  margin: 0;
  padding: 0;
}

.site-footer .footer-logo {
  display: inline-flex;

  margin: 0 0 7px;

  line-height: 0;
}

.site-footer .footer-logo img {
  display: block;

  width: auto;
  height: 30px;
  max-width: 105px;

  object-fit: contain;
}

.site-footer .footer-brand p {
  max-width: 260px;

  margin: 0 0 9px;

  color: rgba(255,255,255,.56);

  font-size: .72rem;
  line-height: 1.4;
}


/* ---------- Footer columns ---------- */

.site-footer .footer-column {
  min-width: 0;

  margin: 0;
  padding: 0;
}

.site-footer .footer-column h5 {
  margin: 1px 0 7px;

  color: var(--blue-300);

  font-family: var(--font-mono);
  font-size: .62rem;
  line-height: 1.2;

  font-weight: 500;

  letter-spacing: .08em;

  text-transform: uppercase;
}

.site-footer .footer-column ul {
  margin: 0;
  padding: 0;

  list-style: none;
}

.site-footer .footer-column li {
  margin: 0 0 4px;
  padding: 0;

  color: rgba(255,255,255,.62);

  font-size: .72rem;
  line-height: 1.35;
  font-weight: 400;
}

.site-footer .footer-column li:last-child {
  margin-bottom: 0;
}

.site-footer .footer-column a {
  display: inline-block;

  color: inherit;

  font-size: inherit;
  line-height: inherit;
  font-weight: inherit;

  transition:
    color var(--transition-fast),
    transform var(--transition-fast);
}

.site-footer .footer-column a:hover {
  color: var(--white);

  transform: translateX(2px);
}


/* ---------- Social links ---------- */

.site-footer .social-links {
  display: flex;

  align-items: center;

  gap: 5px;

  margin: 0;
  padding: 0;
}

.site-footer .social-links a {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 25px;
  height: 25px;

  margin: 0;
  padding: 0;

  border: 1px solid rgba(255,255,255,.16);
  border-radius: 50%;

  color: rgba(255,255,255,.7);

  font-family: var(--font-body);
  font-size: .62rem;
  font-weight: 600;

  line-height: 1;

  transition:
    background var(--transition-fast),
    border-color var(--transition-fast),
    color var(--transition-fast),
    transform var(--transition-fast);
}

.site-footer .social-links a:hover {
  background: var(--pink-500);

  border-color: var(--pink-500);

  color: var(--white);

  transform: translateY(-1px);
}


/* ---------- Footer bottom ---------- */

.site-footer .footer-bottom {
  display: flex;

  align-items: center;
  justify-content: space-between;

  gap: 1rem;

  min-height: 36px;

  margin: 0;
  padding: 8px 0;

  color: rgba(255,255,255,.42);

  font-size: .62rem;
  line-height: 1.3;
}

.site-footer .footer-bottom p {
  margin: 0;

  color: inherit;

  font-size: inherit;
  line-height: inherit;
}

/* ============================================================
   RESPONSIVE NAVIGATION
   ============================================================ */

@media (max-width: 1000px) {

  .nav-links {
    gap: 1rem;
  }

  .nav-links a {
    font-size: .82rem;
  }

  .nav-actions {
    gap: .6rem;
  }

  .nav-actions .btn {
    min-width: 140px;
    min-height: 42px;

    padding: .7em 1.1rem;

    font-size: .78rem;
    line-height: 1.2;
  }

}


@media (max-width: 880px) {

  /* Blur creates a containing block that breaks position:fixed children.
     Remove it on mobile so the menu is fixed to the screen. */
  .navbar {
    background: var(--navy-900);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .navbar-inner {
    min-height: 70px;
  }

  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: fixed;
    inset: 70px 0 0 0;
    z-index: 999;

    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: .35rem;

    padding: 1.5rem;
    background: var(--navy-900);
    overflow-y: auto;

    transform: translateX(100%);
    visibility: hidden;
    transition: transform .25s ease, visibility 0s linear .25s;
  }

  .nav-links.open {
    transform: translateX(0);
    visibility: visible;
    transition: transform .25s ease, visibility 0s;
  }

  .nav-links a {
    width: 100%;
    padding: .7rem 0;
    font-size: 1rem;
  }

  .nav-actions {
    display: block;
    width: 100%;
    margin-top: .25rem;
  }

  .nav-actions .btn {
    width: 100%;
    min-width: 0;
    min-height: 42px;

    justify-content: center;
    padding: .8rem 1rem;

    font-size: .78rem;
    line-height: 1.2;
  }

  .nav-actions .btn + .btn {
    margin-top: .6rem;
  }

  /* ---- Resources dropdown becomes an inline list inside the menu ---- */

  .nav-links .resources-nav {
    width: 100%;
  }

  .nav-links .resources-trigger {
    width: 100%;
    justify-content: space-between;
    padding: .7rem 0;
    font-size: 1rem;
  }

  .nav-links .resources-menu {
    position: static;
    width: 100%;
    margin-top: .25rem;
    padding: 4px;

    background: rgba(255,255,255,.06);
    border: 0;
    box-shadow: none;

    display: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none !important;
  }

  .nav-links .resources-nav.open .resources-menu {
    display: block;
  }

  .nav-links .resources-item {
    padding: 8px;
    border-bottom: 0;
  }

  .nav-links .resources-item:hover {
    background: rgba(255,255,255,.1);
  }

  .nav-links .resources-text strong {
    color: var(--white);
  }

}


/* ============================================================
   RESPONSIVE GRIDS
   ============================================================ */

@media (max-width: 980px) {

  .grid-3,
  .grid-4 {
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .site-footer .footer-grid {
    grid-template-columns:
      minmax(200px, 1.5fr)
      repeat(3, minmax(100px, 1fr));
  }

}


@media (max-width: 700px) {

  .hero-stats {
    grid-template-columns: repeat(2, minmax(0,1fr));

    row-gap: 1.5rem;
  }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  .section-head {
    margin-bottom: 2.5rem;
  }

  .page-hero {
    min-height: auto;

    padding-top: 4rem;
    padding-bottom: 3.5rem;
  }

  .page-hero h1 {
    font-size: clamp(2.2rem, 9vw, 3.5rem);
  }

  .about-intro h2 {
    font-size: clamp(1.9rem, 8vw, 2.6rem);
  }

  .card {
    padding: 1.5rem;
  }

}


/* ============================================================
   MOBILE FOOTER
   ============================================================ */

@media (max-width: 700px) {

  .site-footer {
    padding-top: 18px;
  }

  .site-footer .footer-grid {
    grid-template-columns: repeat(2, minmax(0,1fr));

    gap: 1rem 1.25rem;

    padding-bottom: 13px;
  }

  .site-footer .footer-brand {
    grid-column: 1 / -1;

    margin-bottom: 2px;
  }

  .site-footer .footer-logo img {
    height: 27px;
    max-width: 95px;
  }

  .site-footer .footer-brand p {
    max-width: 330px;

    margin-bottom: 7px;

    font-size: .7rem;
  }

  .site-footer .footer-column h5 {
    margin-bottom: 6px;

    font-size: .6rem;
  }

  .site-footer .footer-column li {
    margin-bottom: 3px;
  }

  .site-footer .footer-column a {
    font-size: .7rem;
  }

  .site-footer .footer-bottom {
    min-height: auto;

    align-items: flex-start;

    flex-direction: column;

    gap: 3px;

    padding: 7px 0;

    font-size: .59rem;
  }

}


/* ============================================================
   VERY SMALL SCREENS
   ============================================================ */

@media (max-width: 420px) {

  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .page-hero h1 {
    font-size: 2rem;
  }

  .hero-actions {
    flex-direction: column;

    width: 100%;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .site-footer {
    padding-top: 16px;
  }

  .site-footer .footer-grid {
    gap: .9rem 1rem;
  }

  .site-footer .footer-logo img {
    height: 25px;
  }

  .site-footer .footer-brand p {
    font-size: .68rem;
  }

  .site-footer .footer-column a {
    font-size: .68rem;
  }

}

/* ============================================================
   PROJECT DETAIL IMAGES
   ============================================================ */

.project-detail-image {
  border-radius: 24px;
  overflow: hidden;
}

.project-detail-image img {
  display: block;
  width: 100%;
  height: auto;
}
.project-detail-image {
  margin-bottom: 1rem;
}

/* ============================================================
   PROGRAM ROWS
   ============================================================ */

.program-row {
  display: grid;

  grid-template-columns: 90px minmax(0,1fr) auto;

  gap: 2rem;

  align-items: center;

  padding: 2rem 0;

  border-bottom: 1px solid rgba(10,31,61,.1);
}

.on-dark .program-row {
  border-color: rgba(255,255,255,.12);
}

.program-row .idx {
  color: var(--pink-500);

  font-family: var(--font-mono);
  font-size: .85rem;
}

.program-row h3 {
  margin: 0 0 .3em;

  font-size: 1.35rem;
}

.program-row p {
  max-width: 520px;

  margin: 0;

  color: var(--ink-soft);
}

.on-dark .program-row p {
  color: rgba(255,255,255,.72);
}


/* ============================================================
   STAT BAND
   ============================================================ */

.stat-band {
  display: grid;

  grid-template-columns: repeat(4, minmax(0,1fr));

  gap: 2rem;

  text-align: center;
}

.stat-band .num {
  color: var(--pink-500);

  font-family: var(--font-display);

  font-size: clamp(2rem,4vw,3rem);
}

.stat-band .label {
  color: var(--ink-soft);

  font-family: var(--font-mono);
  font-size: .75rem;

  letter-spacing: .05em;

  text-transform: uppercase;
}


/* ============================================================
   QUOTES
   ============================================================ */

blockquote.pull {
  max-width: 820px;

  margin: 0;

  font-family: var(--font-display);

  font-size: clamp(1.4rem,2.6vw,2rem);

  line-height: 1.4;
}

blockquote.pull cite {
  display: block;

  margin-top: 1rem;

  color: var(--blue-300);

  font-family: var(--font-mono);

  font-size: .8rem;

  font-style: normal;

  letter-spacing: .05em;

  text-transform: uppercase;
}


/* ============================================================
   TESTIMONIAL
   ============================================================ */

.testimonial-photo {
  display: block;

  width: 96px;
  height: 96px;

  margin: 0 auto 1.5rem;

  border: 3px solid var(--paper);

  border-radius: 50%;

  object-fit: cover;

  box-shadow: 0 10px 28px -10px rgba(10,31,61,.4);
}

.testimonial-quote {
  max-width: 680px;

  margin: 0 auto 1.5rem;

  color: var(--ink-soft);

  font-size: 1.05rem;

  font-style: italic;

  line-height: 1.7;
}

.testimonial-name {
  margin: 0 0 .2rem;

  color: var(--ink);

  font-family: var(--font-body);

  font-size: 1.15rem;

  font-weight: 700;
}

.testimonial-role {
  margin: 0;

  color: var(--ink-soft);

  font-size: .92rem;
}


/* ============================================================
   TIMELINE
   ============================================================ */

.timeline {
  position: relative;

  padding-left: 2rem;
}

.timeline::before {
  content: "";

  position: absolute;

  left: 6px;
  top: 6px;
  bottom: 6px;

  width: 2px;

  background:
    linear-gradient(
      var(--pink-500),
      var(--blue-400)
    );
}

.timeline-item {
  position: relative;

  padding-bottom: 4rem;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-item::before {
  content: "";

  position: absolute;

  left: -2rem;
  top: 4px;

  width: 14px;
  height: 14px;

  background: var(--paper);

  border: 3px solid var(--pink-500);

  border-radius: 50%;
}

.timeline-item .year {
  display: block;

  margin-bottom: .3em;

  color: var(--pink-500);

  font-family: var(--font-mono);

  font-size: .85rem;
}

.timeline-item h3 {
  margin-bottom: .3em;

  font-size: 1.3rem;
}

.timeline-item p {
  max-width: 560px;

  color: var(--ink-soft);
}


/* ============================================================
   FORMS
   ============================================================ */

.form-grid {
  display: grid;

  grid-template-columns: repeat(2,minmax(0,1fr));

  gap: 1rem;
}

.form-grid .full {
  grid-column: 1 / -1;
}

.field label {
  display: block;

  margin-bottom: .5em;

  color: var(--ink-soft);

  font-family: var(--font-mono);

  font-size: .75rem;

  letter-spacing: .05em;

  text-transform: uppercase;
}

.field input,
.field select,
.field textarea {
  width: 100%;

  padding: .85em 1em;

  border: 1.5px solid rgba(10,31,61,.18);

  border-radius: 10px;

  background: var(--white);

  color: var(--ink);

  font-family: var(--font-body);

  font-size: .98rem;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;

  border-color: var(--pink-500);

  box-shadow: 0 0 0 4px rgba(255,76,134,.12);
}

.form-note {
  color: var(--ink-soft);

  font-size: .85rem;
}


/* ============================================================
   NEWSLETTER
   ============================================================ */

.newsletter {
  display: flex;

  justify-content: space-between;
  align-items: center;

  gap: 2rem;

  flex-wrap: wrap;

  padding: clamp(2rem,5vw,3.2rem);

  background: var(--pink-500);

  border-radius: 20px;

  color: var(--white);
}

.newsletter h2 {
  max-width: 480px;

  margin: 0;

  color: var(--white);

  font-size: clamp(1.5rem,3vw,2.1rem);
}


/* ============================================================
   BLOG
   ============================================================ */

.post-featured {
  display: grid;

  grid-template-columns: 1.1fr 1fr;

  gap: 3rem;

  align-items: center;

  padding: clamp(1.5rem,4vw,3rem);

  background: var(--navy-900);

  border-radius: 20px;

  color: var(--white);

  overflow: hidden;
}

.post-featured .thumb,
.post-card .thumb {
  position: relative;

  aspect-ratio: 16 / 10;

  border-radius: 14px;

  overflow: hidden;
}

.post-featured .thumb {
  order: 2;
}

.thumb::before {
  content: "";

  position: absolute;
  inset: 0;

  background-image:
    radial-gradient(
      circle at 22px 22px,
      rgba(255,255,255,.22) 2px,
      transparent 2.5px
    );

  background-size: 26px 26px;

  opacity: .5;
}

.thumb-a {
  background: linear-gradient(135deg,var(--pink-500),var(--navy-800));
}

.thumb-b {
  background: linear-gradient(135deg,var(--blue-400),var(--navy-900));
}

.thumb-c {
  background: linear-gradient(135deg,var(--navy-800),var(--pink-300));
}

.thumb-d {
  background: linear-gradient(135deg,var(--blue-300),var(--navy-800));
}

.thumb-e {
  background: linear-gradient(135deg,var(--pink-500),var(--blue-400));
}

.thumb-f {
  background: linear-gradient(135deg,var(--navy-900),var(--blue-400));
}

.post-featured h2 {
  color: var(--white);

  font-size: clamp(1.6rem,3vw,2.2rem);
}

.post-featured p {
  color: rgba(255,255,255,.75);
}

.post-meta {
  display: flex;

  gap: .9em;

  flex-wrap: wrap;

  margin: .6em 0 0;

  color: var(--ink-soft);

  font-family: var(--font-mono);

  font-size: .75rem;

  letter-spacing: .04em;

  text-transform: uppercase;
}

.post-featured .post-meta {
  color: rgba(255,255,255,.6);
}

.tag {
  display: inline-block;

  padding: .3em .7em;

  border-radius: 999px;

  background: rgba(255,76,134,.12);

  color: var(--pink-500);

  font-family: var(--font-mono);

  font-size: .68rem;

  letter-spacing: .06em;

  text-transform: uppercase;
}

.post-featured .tag {
  background: rgba(79,195,232,.18);

  color: var(--blue-300);
}

.post-card {
  display: flex;

  flex-direction: column;
}

.post-card .thumb {
  margin-bottom: 1rem;
}

.post-card h3 {
  margin-bottom: .35em;

  font-size: 1.15rem;
}

.post-card p {
  font-size: .92rem;
}

.post-card .read-more {
  display: inline-flex;
  align-items: center;
  gap: .4em;

  margin-top: .8em;

  color: var(--pink-500);

  font-family: var(--font-mono);

  font-size: .8rem;
}

.post-card .read-more::after {
  content: "→";
}


/* ============================================================
   ARTICLE
   ============================================================ */

.article-body {
  max-width: 720px;

  margin: 0 auto;
}

.article-body h2 {
  margin-top: 2em;

  font-size: 1.6rem;
}

.article-body p {
  color: var(--ink-soft);

  font-size: 1.05rem;
}

.article-body blockquote {
  margin: 1.6em 0;

  padding: .2em 0 .2em 1.4em;

  border-left: 3px solid var(--pink-500);

  color: var(--ink);

  font-family: var(--font-display);

  font-size: 1.25rem;
}


/* ============================================================
   IMPACT MAP
   ============================================================ */

#impact-leaflet-map {
  width: 100%;
  height: 540px;

  border: 1px solid rgba(10,31,61,.1);

  border-radius: 18px;

  z-index: 0;
}

.map-legend {
  display: flex;

  flex-wrap: wrap;

  gap: 1.4em;

  margin-top: 1rem;

  color: var(--ink-soft);

  font-family: var(--font-mono);

  font-size: .78rem;
}

.map-legend span {
  display: inline-flex;

  align-items: center;

  gap: .5em;
}

.map-legend .dot {
  width: 10px;
  height: 10px;

  display: inline-block;

  border-radius: 50%;
}


/* ============================================================
   UTILITY
   ============================================================ */

.mt-lg {
  margin-top: var(--gap-lg);
}

.text-center {
  text-align: center;
}

.center-col {
  max-width: 720px;

  margin-left: auto;
  margin-right: auto;

  text-align: center;
}

.divider {
  height: 1px;

  margin: var(--gap-lg) 0;

  background: rgba(10,31,61,.1);
}

.on-dark .divider {
  background: rgba(255,255,255,.12);
}

.visually-hidden {
  position: absolute;

  width: 1px;
  height: 1px;

  margin: -1px;
  padding: 0;

  overflow: hidden;

  clip: rect(0,0,0,0);

  white-space: nowrap;

  border: 0;
}


/* ============================================================
   SMALL SCREEN ADJUSTMENTS
   ============================================================ */

@media (max-width: 640px) {

  .form-grid {
    grid-template-columns: 1fr;
  }

  .form-grid .full {
    grid-column: auto;
  }

  .program-row {
    grid-template-columns: 1fr;

    gap: 1rem;
  }

  .program-row .btn {
    justify-self: flex-start;
  }

  .stat-band {
    grid-template-columns: repeat(2,minmax(0,1fr));

    row-gap: 2rem;
  }

  .post-featured {
    grid-template-columns: 1fr;
  }

  .post-featured .thumb {
    order: 0;
  }

}


/* ============================================================
   FOOTER — EXTRA SMALL DEVICES
   ============================================================ */

@media (max-width: 380px) {

  .site-footer .footer-grid {
    gap: .8rem;
  }

  .site-footer .footer-column a {
    font-size: .66rem;
  }

  .site-footer .footer-brand p {
    font-size: .66rem;
  }
  

}
/* =====================================================
   OKDI REPORT CARDS
===================================================== */

.reports-grid {

    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 28px;

    width:
        min(1200px, calc(100% - 40px));

    margin:
        50px auto;

}


.report-card {

    display: grid;

    grid-template-columns:
        220px minmax(0, 1fr);

    overflow: hidden;

    background: #ffffff;

    border:
        1px solid #dfe5e1;

    border-radius: 18px;

    box-shadow:
        0 15px 45px rgba(0, 0, 0, .06);

    transition:
        transform .25s ease,
        box-shadow .25s ease;

}


.report-card:hover {

    transform:
        translateY(-4px);

    box-shadow:
        0 22px 55px rgba(0, 0, 0, .10);

}


.report-cover {

    min-height: 320px;

    background:
        #edf1ee;

    overflow: hidden;

}


.report-cover img {

    width: 100%;

    height: 100%;

    min-height: 320px;

    display: block;

    object-fit: cover;

    transition:
        transform .4s ease;

}


.report-card:hover
.report-cover img {

    transform:
        scale(1.025);

}


.report-content {

    display: flex;

    flex-direction: column;

    justify-content: center;

    padding: 30px;

}


.report-year {

    display: inline-flex;

    width: fit-content;

    padding: 6px 10px;

    border-radius: 999px;

    background: #e9f3ed;

    color: #0b5d3b;

    font-size: 11px;

    font-weight: 750;

    letter-spacing: .08em;

}


.report-content h2 {

    margin:
        14px 0 10px;

    color: #17231d;

    font-size: 25px;

    line-height: 1.15;

    letter-spacing: -.035em;

}


.report-content p {

    margin: 0;

    color: #66736c;

    font-size: 14px;

    line-height: 1.7;

}


.report-actions {

    display: flex;

    flex-wrap: wrap;

    gap: 10px;

    margin-top: 24px;

}


.report-btn {

    display: inline-flex;

    align-items: center;

    justify-content: center;

    gap: 8px;

    min-height: 42px;

    padding:
        10px 16px;

    border-radius: 999px;

    font-size: 12px;

    font-weight: 700;

    text-decoration: none;

    transition:
        transform .2s ease,
        background .2s ease,
        color .2s ease,
        border-color .2s ease;

}


.report-btn:hover {

    transform:
        translateY(-1px);

}


.report-btn-primary {

    background:
        #0b5d3b;

    border:
        1px solid #0b5d3b;

    color:
        #ffffff;

}


.report-btn-primary:hover {

    background:
        #08482e;

    border-color:
        #08482e;

}


.report-btn-secondary {

    background:
        #ffffff;

    border:
        1px solid #d5ded9;

    color:
        #0b5d3b;

}


.report-btn-secondary:hover {

    background:
        #f0f5f2;

}


/* =====================================================
   TABLET
===================================================== */

@media (max-width: 1050px) {

    .reports-grid {

        grid-template-columns:
            1fr;

        max-width:
            800px;

    }

}


/* =====================================================
   MOBILE
===================================================== */

@media (max-width: 650px) {

    .reports-grid {

        width:
            calc(100% - 24px);

        margin:
            35px auto;

    }


    .report-card {

        grid-template-columns:
            1fr;

    }


    .report-cover {

        height:
            330px;

        min-height:
            0;

    }


    .report-cover img {

        min-height:
            0;

        height:
            330px;

    }


    .report-content {

        padding:
            24px;

    }


    .report-content h2 {

        font-size:
            22px;

    }


    .report-actions {

        flex-direction:
            column;

        align-items:
            stretch;

    }


    .report-btn {

        width:
            100%;

    }

}
.resources-item {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 8px;
  box-sizing: border-box;
}

.resources-icon {
  flex: 0 0 32px;
}

.resources-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
/* ==========================================================
   RESOURCE PAGES
========================================================== */

.resource-hero {
  padding: 120px 0 80px;
  background: #0A1F3D;
  color: #ffffff;
}

.resource-hero .eyebrow {
  color: #9FE0F5;
}

.resource-hero h1 {
  max-width: 850px;
  margin: 15px 0 20px;
  font-family: "Fraunces", serif;
  font-size: clamp(2.7rem, 6vw, 5rem);
  line-height: 1.05;
  letter-spacing: -.04em;
}

.resource-hero p {
  max-width: 680px;
  color: rgba(255,255,255,.78);
  line-height: 1.8;
  font-size: 1.05rem;
}

.resource-section {
  padding: 85px 0;
  background: #FFF8F0;
}

.resource-heading {
  margin-bottom: 40px;
}

.resource-heading h2 {
  margin-bottom: 12px;
}

.resource-heading p {
  max-width: 620px;
  color: #66716b;
  line-height: 1.7;
}

.resource-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.resource-card {
  display: flex;
  flex-direction: column;
  padding: 28px;
  border: 1px solid #e2e8e2;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 10px 30px rgba(10,31,61,.05);
  transition: transform .2s ease, box-shadow .2s ease;
}

.resource-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(10,31,61,.1);
}

.resource-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 22px;
  border-radius: 13px;
  background: #e9f3ed;
  color: #0b5d3b;
  font-size: 22px;
}

.resource-meta {
  margin-bottom: 12px;
  color: #0b5d3b;
  font-family: "IBM Plex Mono", monospace;
  font-size: .7rem;
  text-transform: uppercase;
}

.resource-card h3 {
  margin-bottom: 12px;
  color: #17231d;
  font-size: 1.25rem;
  line-height: 1.3;
}

.resource-card p {
  margin-bottom: 25px;
  color: #66716b;
  line-height: 1.7;
  font-size: .94rem;
}

.resource-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: auto;
}

.resource-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 15px;
  border: 1px solid #0b5d3b;
  border-radius: 999px;
  color: #0b5d3b;
  font-family: "IBM Plex Mono", monospace;
  font-size: .72rem;
  text-decoration: none;
}

.resource-link.primary {
  background: #0b5d3b;
  color: #ffffff;
}

.resource-link:hover {
  background: #08482e;
  color: #ffffff;
}

.resource-note {
  margin-top: 40px;
  padding: 20px;
  border-left: 4px solid #0b5d3b;
  border-radius: 10px;
  background: #e9f3ed;
  color: #315044;
  line-height: 1.7;
}

@media (max-width: 980px) {
  .resource-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .resource-hero {
    padding: 90px 0 60px;
  }

  .resource-section {
    padding: 55px 0;
  }

  .resource-grid {
    grid-template-columns: 1fr;
  }

  .resource-card {
    padding: 23px;
  }

  .resource-actions {
    flex-direction: column;
  }

  .resource-link {
    width: 100%;
  }
}
/* ============================================================
   OKDI AI ASSISTANT
============================================================ */

.okdi-chatbot {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 3000;
  font-family: var(--font-body);
}

/* ---------- Floating Button ---------- */

.okdi-chatbot-toggle {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 58px;
  height: 58px;

  border: 0;
  border-radius: 50%;

  background: var(--pink-500);
  color: var(--white);

  font-size: 25px;
  cursor: pointer;

  box-shadow: 0 10px 30px rgba(10, 31, 61, .25);

  transition:
    transform var(--transition),
    background var(--transition);
}

.okdi-chatbot-toggle:hover {
  transform: translateY(-3px);
  background: #ff689a;
}

.okdi-chatbot-toggle-icon {
  width: 70%;
  height: 70%;
  object-fit: contain;
  display: block;
  pointer-events: none;
}

/* ---------- Chat Window ---------- */

.okdi-chatbot-window {
  position: absolute;
  right: 0;
  bottom: 74px;

  display: flex;
  flex-direction: column;

  width: min(390px, calc(100vw - 30px));
  height: min(620px, calc(100vh - 120px));

  overflow: hidden;

  background: var(--paper);

  border: 1px solid rgba(10, 31, 61, .12);
  border-radius: 20px;

  box-shadow: 0 20px 70px rgba(10, 31, 61, .25);
}

/* ---------- Header ---------- */

.okdi-chatbot-header {
  display: flex;
  align-items: center;
  justify-content: space-between;

  padding: 18px 20px;

  background: var(--navy-900);
  color: var(--white);
}

.okdi-chatbot-heading {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.okdi-chatbot-title {
  margin: 0;

  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.2;
}

.okdi-chatbot-subtitle {
  color: var(--blue-300);

  font-family: var(--font-mono);
  font-size: .62rem;
  letter-spacing: .04em;
}

.okdi-chatbot-close {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 30px;
  height: 30px;

  border: 1px solid rgba(255, 255, 255, .25);
  border-radius: 50%;

  background: transparent;
  color: var(--white);

  cursor: pointer;
  font-size: 1rem;
}

/* ---------- Messages ---------- */

.okdi-chatbot-messages {
  flex: 1;

  display: flex;
  flex-direction: column;
  gap: 14px;

  padding: 20px;

  overflow-y: auto;
}

.okdi-chatbot-message {
  max-width: 88%;

  padding: 12px 14px;

  border-radius: 14px;

  font-size: .86rem;
  line-height: 1.6;

  overflow-wrap: anywhere;
}

.okdi-chatbot-message.assistant {
  align-self: flex-start;

  background: var(--white);
  color: var(--ink);

  border: 1px solid rgba(10, 31, 61, .08);
  border-bottom-left-radius: 4px;
}

.okdi-chatbot-message.user {
  align-self: flex-end;

  background: var(--navy-900);
  color: var(--white);

  border-bottom-right-radius: 4px;
}

/* ---------- Suggested Questions ---------- */

.okdi-chatbot-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;

  padding: 0 20px 14px;
}

.okdi-chatbot-suggestion {
  padding: 8px 11px;

  border: 1px solid rgba(10, 31, 61, .18);
  border-radius: 999px;

  background: transparent;
  color: var(--navy-900);

  font-family: var(--font-mono);
  font-size: .65rem;

  cursor: pointer;

  transition:
    background var(--transition),
    color var(--transition);
}

.okdi-chatbot-suggestion:hover {
  background: var(--pink-500);
  border-color: var(--pink-500);
  color: var(--white);
}

/* ---------- Input Area ---------- */

.okdi-chatbot-input-area {
  display: flex;
  align-items: flex-end;
  gap: 8px;

  padding: 14px;

  background: var(--white);
  border-top: 1px solid rgba(10, 31, 61, .1);
}

.okdi-chatbot-input {
  flex: 1;

  min-width: 0;
  max-height: 100px;

  padding: 11px 13px;

  border: 1px solid rgba(10, 31, 61, .2);
  border-radius: 12px;

  background: var(--paper);
  color: var(--ink);

  font-size: .85rem;
  line-height: 1.4;

  resize: none;
}

.okdi-chatbot-input:focus {
  outline: none;

  border-color: var(--pink-500);
  box-shadow: 0 0 0 3px rgba(255, 76, 134, .12);
}

.okdi-chatbot-send {
  display: flex;
  align-items: center;
  justify-content: center;

  width: 42px;
  height: 42px;

  flex-shrink: 0;

  border: 0;
  border-radius: 50%;

  background: var(--pink-500);
  color: var(--white);

  cursor: pointer;

  transition:
    transform var(--transition),
    background var(--transition);
}

.okdi-chatbot-send:hover {
  transform: translateY(-2px);
  background: #ff689a;
}

.okdi-chatbot-send:disabled {
  opacity: .5;
  cursor: not-allowed;
  transform: none;
}

/* ---------- Loading Indicator ---------- */

.okdi-chatbot-loading {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.okdi-chatbot-loading span {
  width: 6px;
  height: 6px;

  border-radius: 50%;
  background: var(--pink-500);

  animation: okdi-chatbot-pulse 1.2s infinite ease-in-out;
}

.okdi-chatbot-loading span:nth-child(2) {
  animation-delay: .15s;
}

.okdi-chatbot-loading span:nth-child(3) {
  animation-delay: .3s;
}

@keyframes okdi-chatbot-pulse {
  0%, 80%, 100% {
    opacity: .3;
    transform: scale(.8);
  }

  40% {
    opacity: 1;
    transform: scale(1);
  }
}

/* ---------- Mobile ---------- */

@media (max-width: 600px) {

  .okdi-chatbot {
    right: 15px;
    bottom: calc(15px + env(safe-area-inset-bottom, 0px));
  }

  .okdi-chatbot-window {
    right: 0;
    bottom: 70px;

    width: min(390px, calc(100vw - 30px));
    height: min(600px, calc(100vh - 100px));
    height: min(600px, calc(100dvh - 100px));

    border-radius: 16px;
  }

  .okdi-chatbot-header {
    padding: 15px 16px;
  }

  .okdi-chatbot-messages {
    padding: 16px;
  }

  .okdi-chatbot-message {
    max-width: 94%;
    font-size: .82rem;
    white-space: pre-wrap;
    line-height: 1.6;
  }

  .okdi-chatbot-message.assistant {
    line-height: 1.5;
  }

  .okdi-chatbot-suggestions {
    padding: 0 16px 12px;
  }

  .okdi-chatbot-list-item {
    gap: .4rem;
    margin: .25rem 0;
    line-height: 1.45;
  }

  .okdi-chatbot-list-number,
  .okdi-chatbot-list-bullet {
    line-height: 1.45;
  }

}

/* Hide the AI button while the mobile menu is open, so it doesn't cover it.
   Uses :has(), so no JS change is needed. */
@media (max-width: 880px) {
  body:has(.nav-links.open) .okdi-chatbot {
    display: none;
  }
}
/* Keep chatbot closed until the toggle is clicked */
.okdi-chatbot-window[hidden] {
  display: none !important;
}


/* ==========================================================
   OKDI AI CHATBOT — RESPONSE FORMATTING
========================================================== */

.okdi-chatbot-message.assistant {
  line-height: 1.55;
  overflow-wrap: anywhere;
}


/* ==========================================================
   BOLD / ITALIC
========================================================== */

.okdi-chatbot-message.assistant strong {
  font-weight: 700;
}

.okdi-chatbot-message.assistant em {
  font-style: italic;
}


/* ==========================================================
   NUMBERED AND BULLET LISTS
========================================================== */

.okdi-chatbot-list-item {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;

  /* Reduced vertical spacing */
  margin: 0.3rem 0;

  line-height: 1.5;
}

.okdi-chatbot-list-number,
.okdi-chatbot-list-bullet {
  flex: 0 0 auto;
  font-weight: 700;
  line-height: 1.5;
}

.okdi-chatbot-list-content {
  flex: 1;
  min-width: 0;

  /* Prevent inherited margins from creating gaps */
  margin: 0;
  padding: 0;
}


/* ==========================================================
   HEADINGS
========================================================== */

.okdi-chatbot-heading-1,
.okdi-chatbot-heading-2,
.okdi-chatbot-heading-3 {
  font-weight: 700;
  line-height: 1.35;
  margin: 0.7rem 0 0.35rem;
}

.okdi-chatbot-heading-1 {
  font-size: 1.15rem;
}

.okdi-chatbot-heading-2 {
  font-size: 1.08rem;
}

.okdi-chatbot-heading-3 {
  font-size: 1rem;
}


/* ==========================================================
   LINKS
========================================================== */

.okdi-chatbot-message.assistant a {
  text-decoration: underline;
  text-underline-offset: 2px;
  word-break: break-word;
}


/* ==========================================================
   LIST LINE BREAKS
========================================================== */

.okdi-chatbot-list-item {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  margin: 0.3rem 0;
  line-height: 1.5;
}

.okdi-chatbot-list-number,
.okdi-chatbot-list-bullet {
  flex: 0 0 auto;
  font-weight: 700;
}

.okdi-chatbot-list-content {
  flex: 1;
  min-width: 0;
}


/* ==========================================================
   REDUCE EXCESSIVE BR SPACING
========================================================== */



/* ==========================================================
   MOBILE
========================================================== */

@media (max-width: 600px) {

  .okdi-chatbot-message.assistant {
    line-height: 1.5;
  }

  .okdi-chatbot-list-item {
    gap: 0.4rem;
    margin: 0.25rem 0;
    line-height: 1.45;
  }

  .okdi-chatbot-list-number,
  .okdi-chatbot-list-bullet {
    line-height: 1.45;
  }
}


