
/* =====================================
Remove TOC gap but keep readable padding 
   ===================================== */


/* Hide TOC completely */
#quarto-sidebar, .toc-actions, .page-toc {
  display: none !important;
  width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Expand main content area and keep nice side margins */
main.content {
  max-width: 1600px;        /* ✅ Prevent overly wide lines */
  margin: 0 auto;            /* ✅ Center the main content */
  padding: 2rem 3rem;        /* ✅ Add top/bottom + side padding */
}

@media (max-width: 600px) {
  main.content {
    padding: 1.5rem 1rem;
    max-width: 100vw;
    width: 100%;
    box-sizing: border-box;
  }
}

/* Adjust grid if Quarto layout leaves a TOC column.
   Do NOT set overflow on #quarto-content or main — it breaks position:sticky for the scrolly plot. */
#quarto-content {
  grid-template-columns: 1fr !important;
  max-width: 100vw;
}

@media (max-width: 600px) {
  #quarto-content {
    width: 100%;
  }
}

/* Prevent horizontal overflow on mobile */
html, body {
  overflow-x: hidden;
  max-width: 100vw;
}

/* Use clip where supported so sticky is not broken by scroll containment (desktop scrolly) */
@supports (overflow-x: clip) {
  html, body {
    overflow-x: clip;
  }
}

/* Page background image */
body {
  background-image: url('Assets/Stable/background2.png');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-attachment: fixed;
}






/* logo sizing (for nav bar) */
.navbar-brand img {
  height: 100px;      /* adjust to your preference */
  width: auto;
  margin-right: 1rem;
}

/* =====================================
   HERO SECTION (landing pages)
   ===================================== */

.hero {
  min-height: 30vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem;
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.2rem);
  font-weight: 800;
  margin-bottom: 1rem;
}

.hero-logo {
  width: clamp(200px, 40vw, 500px);
  height: auto;
  margin-bottom: 1.5rem;
}

.hero p {
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  max-width: 800px;
  margin: 0;
}

/* Scroll down banner */
.scroll-down-banner {
  text-align: center;
  padding: 0.5rem 0;  /* Reduced padding */
  margin: 0 auto;
  max-width: 1000px;
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.scroll-down-text {
  font-size: 0.9rem;
  color: #666;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}


.scroll-down-banner.hidden {
  opacity: 0;
  transform: translateY(-20px);
  pointer-events: none;
}

@media (max-width: 600px) {
  .hero {
    padding: 1.5rem;
  }
}
/* =====================================
   GLOBAL SUMMARY CALLOUT (landing pages)
   ===================================== */
.global-summary-callout {
  background: #f7faf9;
  border: 1px solid rgba(31, 111, 99, 0.2);
  padding: 0.8rem 1.2rem;
  border-radius: 999px;
  margin: 1rem auto 2rem;
  max-width: fit-content;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #13443c;
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.global-summary-label {
  opacity: 0.8;
}

.global-summary-date {
  font-size: 1.1rem;
  letter-spacing: 0.04em;
}

/* =====================================
   LANDING PAGE WORLD MAP WITH REGIONS
   ===================================== */

.world-map-container {
  position: relative;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto 2rem;
  display: block;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 1.5rem;
  overflow: hidden;
}

.world-map-container img.map-bg {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
}

/* clickable region plots */
.region-plot {
  position: absolute;
  transform: translate(-50%, -50%);
  width: clamp(120px, 14vw, 280px);
  aspect-ratio: 1 / 1;
  z-index: 10;
}

.region-plot img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

.region-plot-label {
  position: absolute;
  top: -1.4rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: clamp(0.6rem, 1.2vw, 0.75rem);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #13443c;
  text-align: center;
  background: rgba(255, 255, 255, 0.95);
  padding: 0.12rem 0.5rem;
  border-radius: 999px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  pointer-events: none;
  white-space: nowrap;
  max-width: 90%;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* RESPONSIVE ADJUSTMENTS */

/* For tablets / medium widths */
@media (max-width: 800px) {
  .world-map-container {
    padding: 1rem;
    border-radius: 12px;
  }
  .region-plot {
    width: clamp(90px, 14vw, 180px);
  }
  .region-plot-label {
    font-size: clamp(0.55rem, 1.5vw, 0.7rem);
    padding: 0.1rem 0.4rem;
    top: -1.2rem;
  }
}

/* For small mobile screens */
@media (max-width: 500px) {
  .world-map-container {
    padding: 0.75rem;
    border-radius: 10px;
  }
  .region-plot {
    width: clamp(80px, 18vw, 140px);
  }
  .region-plot-label {
    font-size: clamp(0.5rem, 2vw, 0.65rem);
    padding: 0.08rem 0.35rem;
    top: -1rem;
    letter-spacing: 0.03em;
  }
  /* Replace region plots with colored label banners at very small screens */
  .region-plot img {
    display: none;
  }
  .region-plot {
    width: auto !important;
    height: auto;
    aspect-ratio: auto;
    border-radius: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    /* Use mobile-specific positioning */
    left: var(--mobile-left) !important;
    top: var(--mobile-top) !important;
  }
  .region-plot:hover,
  .region-plot:focus {
    text-decoration: none;
  }
  .region-plot-label {
    display: block;
    position: relative;
    top: 0;
    left: 0;
    transform: none;
    background: var(--ring-color, #f9a825);
    color: white;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    max-width: 120px;
    font-size: clamp(0.45rem, 1.8vw, 0.55rem);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
  }
}





/* ==========================================
   ENHANCED RESPONSIVE COUNTRY GRID LAYOUT
   ========================================== */

/* --- Grid container for all country rows --- */
.country-plot-text-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(600px, 1fr));
  gap: 1.5rem;
  justify-content: center;   /* centers grid as a whole */
  justify-items: center;     /* centers individual grid items */
  margin: 0 auto;
  max-width: 1600px;         /* keeps grid centered on very wide screens */
  box-sizing: border-box;
  width: 100%;
}

@media (max-width: 650px) {
  .country-plot-text-container {
    grid-template-columns: 1fr;
    min-width: 0;
  }
}

/* --- Each row = one plot + text pair --- */
.country-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 0.8rem;
  width: 100%;
  border-bottom: 1px solid #eee;
  padding-bottom: 1rem;
}

/* --- Plot column --- */
.country-plot {
  flex: 0 1 60%;
  min-width: 280px;
}

/* --- Text column --- */
.country-text {
  flex: 0 1 35%;
  max-width: 350px;
  text-align: left;
  line-height: 1.3;
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
}

/* --- Country name styling --- */
.country-text h6 {
  margin-top: 0;
  font-weight: 700;
  font-size: 1.5rem;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

/* --- RESPONSIVE BREAKPOINTS --- */

/* 1️⃣ Extra wide: 4-column layout (p-t-p-t) */
@media (min-width: 1600px) {
  .country-plot-text-container {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* 2️⃣ Large screens: two plots per row (text below each plot) */
@media (max-width: 1300px) and (min-width: 1000px) {
  .country-plot-text-container {
    grid-template-columns: repeat(2, 1fr);
  }
  .country-row {
    flex-direction: column; /* stack text below plot */
    align-items: center;
  }
}

/* 3️⃣ Medium screens: single plot-text pair side-by-side */
@media (max-width: 1000px) and (min-width: 650px) {
  .country-plot-text-container {
    grid-template-columns: 1fr;
  }
  .country-row {
    flex-direction: row; /* side-by-side */
    align-items: center;
  }
}

/* 4️⃣ Small screens: plot above text */
@media (max-width: 800px) {
  .country-plot-text-container {
    grid-template-columns: 1fr;
  }
  .country-row {
    flex-direction: column;
    align-items: center;
  }
  .country-plot,
  .country-text {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
}

@media (max-width: 600px) {
  .country-plot-text-container {
    padding: 0 0.5rem;
  }
}

/* --- Header styling --- */
.region-title {
  text-align: center;
  font-size: 1.3rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-top: 2rem;
  margin-bottom: 1.5rem;
  color: #333;
}



/* ==============================================
   REGION HERO (Map + Summary Plot)
   ============================================== */

.region-hero-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 2rem auto 3rem auto;
  width: 100%;
  max-width: 1400px;
  padding: 0 1rem;
  box-sizing: border-box;
}

.region-hero-panel {
  background: #fff;
  border-radius: 18px;
  border: 1px solid #e3e5eb;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
  padding: 1.5rem;
  box-sizing: border-box;
  max-width: 100%;
  overflow: hidden;
}

@media (max-width: 600px) {
  .region-hero-panel {
    padding: 1rem;
  }
}

.region-hero-map {
  display: flex;
  align-items: center;
  justify-content: center;
}

.region-hero-map-image {
  width: 100%;
  max-width: 100%;
  height: auto;
  border-radius: 14px;
  border: 1px solid #d7dae4;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.4);
  box-sizing: border-box;
}

.region-hero-map-placeholder {
  width: 100%;
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: repeating-linear-gradient(
    -45deg,
    rgba(230, 235, 245, 0.6),
    rgba(230, 235, 245, 0.6) 10px,
    rgba(248, 250, 252, 0.9) 10px,
    rgba(248, 250, 252, 0.9) 20px
  );
  color: #56647a;
  font-weight: 600;
}
.region-hero-heading-block {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 1rem;
  align-items: center;
  text-align: center;
}

.region-hero-heading {
  font-size: clamp(1.8rem, 2.5vw, 2.4rem);
  font-weight: 700;
  margin: 0;
}

.region-hero-text-block {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-top: 1.25rem;
}

.region-hero-text-body {
  font-size: 1rem;
  line-height: 1.5;
  color: #1f2a37;
  margin-bottom: 0;
}

.region-hero-updated {
  color: #5f6d7a;
  font-style: italic;
}

.region-hero-plot .region-summary-container {
  margin: 0;
  padding: 0;
}

.season-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.35rem 1.1rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  width: fit-content;
}

.season-badge.is-above {
  background: rgba(255, 95, 109, 0.18);
  color: #a6232f;
}

.season-badge.is-below {
  background: rgba(57, 138, 255, 0.18);
  color: #14509b;
}

.season-badge.is-neutral {
  background: rgba(67, 214, 152, 0.18);
  color: #0d5c48;
}

@media (max-width: 900px) {
  .region-hero-grid {
    grid-template-columns: 1fr;
    max-width: 100%;
    padding: 0 0.5rem;
  }
}

@media (max-width: 500px) {
  .region-hero-grid {
    padding: 0 0.5rem;
    margin: 1rem auto 2rem auto;
  }
}


/* ==============================================
   REGION SUMMARY PLOT (Top of Page)
   ============================================== */

/* --- Container wrapping title + plot --- */
.region-summary-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin: 2rem auto 3rem auto;  /* spacing above/below */
  width: 100%;
  max-width: 1200px;            /* prevent from stretching too wide */
  padding: 0 1rem;
  box-sizing: border-box;
}

/* --- Title styling --- */
.region-summary-title {
  font-size: 2rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #333;
  margin-bottom: 1rem;
  letter-spacing: 0.03em;
}

/* --- Plot wrapper --- */
.region-summary-plot {
  width: clamp(400px, 70vw, 1100px);  /* responsive scaling */
  max-width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

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

/* Medium screens */
@media (max-width: 1000px) {
  .region-summary-title {
    font-size: 1.7rem;
  }
  .region-summary-plot {
    width: clamp(300px, 80vw, 900px);
  }
}

/* Small screens (phones) */
@media (max-width: 600px) {
  .region-summary-title {
    font-size: 1.4rem;
    margin-bottom: 0.8rem;
  }
  .region-summary-plot {
    width: 100%;
    max-width: 100%;
  }
  .region-summary-container {
    padding: 0 0.5rem;
    margin: 1rem auto 2rem auto;
  }
}




/* ==============================================
   download buttons
   ============================================== */



.download-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1.5rem;
}

.download-buttons .btn {
  font-size: 1rem;
  padding: 0.6rem 1rem;
  border-radius: 0.4rem;
  text-transform: none;
}

.download-buttons .btn-success {
  background-color: #1f6f63;
  border-color: #1f6f63;
}

.download-buttons .btn-outline-primary {
  color: #1f6f63;
  border-color: #1f6f63;
}

.download-buttons .btn-outline-primary:hover {
  background-color: #1f6f63;
  color: #fff;
}

.last-updated {
  font-size: 0.9rem;
  color: #555;
  margin-left: 1rem;
  font-style: italic;
}




/* =====================================================
   SCROLL NARRATIVE WITH STICKY RIGHT VISUAL
   ===================================================== */


.scrolly-container {
  display: flex;
  gap: 4rem;
  max-width: 1600px;
  margin: 6rem auto;
  padding: 0 2rem;
  position: relative;
  /* Height from left column (steps + margins); no extra min-height to avoid empty scroll */
}

.scrolly-steps {
  flex: 1;
  display: flex;
  flex-direction: column;
  max-width: 50%;
  box-sizing: border-box;
  padding-top: 2rem;  /* Add top padding to align with map */
}

.scrolly-step {
  margin-bottom: 80vh;
  font-size: 1.4rem;
  line-height: 1.7;
  font-weight: 400;
  color: #222;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease, transform 0.8s ease;
  position: relative;
  padding-left: 0;
}

/* Extra space after deep dive so it can scroll up further before the plot releases */
.scrolly-step:last-of-type {
  margin-bottom: 70vh;
}

.scrolly-step.revealed {
  opacity: 1;
  transform: translateY(0);
}

.scrolly-step-replacement {
  margin-bottom: 80vh;
  font-size: 1.4rem;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.scrolly-step-replacement.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Bullet points removed - steps stack cleanly without bullets */

.scrolly-step-title {
  font-size: 1.6rem;  /* Reduced from 2rem */
  font-weight: 700;
  margin-bottom: 1rem;
  text-transform: none;
}

.scrolly-step-body {
  font-size: 1.3rem;  /* Reduced from 1.6rem */
  line-height: 1.6;
  margin: 0 0 1.5rem 0;
}

.scrolly-step-body:last-child {
  margin-bottom: 0;
}

/* Removed duplicate - using the one above */

/* Right column: sticky viewport-height panel so plot is visible from first step through last */
.scrolly-visual {
  flex: 1;
  max-width: 50%;
  box-sizing: border-box;
  align-self: flex-start;
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 2rem;  /* match .scrolly-steps so plot top aligns with summary top */
}

/* Plot aligned to top of column, same as summary */
#global-plot-wrapper {
  max-width: 100%;
}

/* world plot wrapper */
#global-plot-wrapper img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
}

.global-plot-title {
  text-align: center;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.5rem;
  margin-top: 3rem;
  font-size: 1.3rem;
  max-width: 1600px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 2rem;
}

/* Small scroll banner below section header */
.section-scroll-banner {
  text-align: center;
  padding: 0.25rem 0;
  margin: 0 auto 1.5rem;
  max-width: 1600px;
  padding-left: 2rem;
  padding-right: 2rem;
}

.section-scroll-text {
  font-size: 0.75rem;
  color: #888;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

/* how-to card */
#howto-card {
  display: none; /* initially hidden */
  text-align: center;
  width: 100%;
}

#howto-card.visible {
  display: block;
}

/* small screen behavior — unchanged: single column, plot above text, no sticky */
@media(max-width: 900px) {
  .scrolly-container {
    flex-direction: column;
    min-height: auto;
    gap: 2rem;
    margin: 2rem auto;
  }
  .scrolly-steps {
    max-width: 100%;
    padding-top: 0;
  }
  .scrolly-visual {
    position: relative;
    top: 0;
    height: auto;
    max-width: 100%;
    order: -1; /* Move plot ABOVE the text on mobile */
  }
  #global-plot-wrapper {
    position: relative;
    transform: none;
  }
  .scrolly-step {
    margin-bottom: 2rem;
    opacity: 1;
    transform: none;
  }
}

/* Bold numbers in scrolly steps */
.scrolly-step-number {
  font-size: 1.4em;
  font-weight: 700;
  color: #13443c;
}

/* Colored modifiers */
.scrolly-modifier.above {
  color: #a6232f;
  font-weight: 700;
}

.scrolly-modifier.below {
  color: #0d5c48;
  font-weight: 700;
}

.scrolly-modifier.near {
  color: #b8860b;
  font-weight: 700;
}

.scrolly-modifier.increase {
  color: #a6232f;
  font-weight: 700;
}

.scrolly-modifier.decrease {
  color: #0d5c48;
  font-weight: 700;
}

/* How-to image styling */
.howto-image {
  max-width: 90%;
  border: none;
  padding: 1rem;
  margin-top: 1rem;
  border-radius: 4px;
}

@media(max-width: 900px) {
  .howto-image {
    max-width: 100%;
    width: 100%;
  }
  #global-plot-wrapper img {
    width: 100%;
  }
}

/* =====================================
   MAP OVERLAY TRANSITION
   ===================================== */
.map-overlay {
  margin-top: 4rem;
  padding-top: 2rem;
}

/* Section after scrolly container */
.scrolly-container + section,
.scrolly-container + * > section {
  margin-top: 6rem;
  padding-top: 4rem;
}

/* ==============================================
   HIGH SEVERITY COUNTRY GRID
   ============================================== */

.severity-grid {
  display: grid;
  gap: 1.5rem;
  align-items: stretch;
}

@media (min-width: 1200px) {
  .severity-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (max-width: 1199px) and (min-width: 900px) {
  .severity-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 899px) and (min-width: 640px) {
  .severity-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
}

@media (max-width: 639px) {
  .severity-grid {
    grid-template-columns: 1fr;
  }
}

.severity-card {
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 12px 30px rgba(13, 92, 72, 0.08);
  padding: 1.5rem 1.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.85rem;
  height: 100%;
}

.severity-card h4 {
  font-size: 1.1rem;
  margin-bottom: 0;
}

.severity-plot {
  width: 100%;
  max-width: 220px;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.severity-plot > * {
  width: 100% !important;
  height: 100% !important;
}

.severity-blurb {
  font-size: 0.95rem;
  line-height: 1.4;
  margin-bottom: 0;
}

.severity-footnote {
  font-size: 0.85rem;
}

.plot-placeholder {
  font-size: 0.9rem;
  color: #5f6d7a;
}

.severity-region-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.2rem 0.65rem;
  margin-left: 0.25rem;
  border-radius: 999px;
  background: rgba(31, 111, 99, 0.12);
  color: #0d5c48;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid rgba(31, 111, 99, 0.2);
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.severity-region-link:hover,
.severity-region-link:focus {
  background: #1f6f63;
  color: #fff;
  box-shadow: 0 6px 16px rgba(31, 111, 99, 0.25);
  text-decoration: none;
}

.country-region-link:hover,
.country-region-link:focus {
  color: #1f6f63;
  text-decoration: underline;
}

/* ==============================================
   FAQ PAGE STYLING
   ============================================== */

/* Force centering of FAQ page content by targeting parent containers */
/* Use :has() selector for modern browsers */
body:has(.faq-container) main.content,
body:has(.faq-container) #quarto-content {
  display: flex !important;
  justify-content: center !important;
  align-items: flex-start !important;
  width: 100% !important;
  max-width: 100vw !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

body:has(.faq-container) main.content {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* Fallback for browsers without :has() support - target when FAQ container exists */
main.content:has(.faq-container) {
  display: flex !important;
  justify-content: center !important;
  align-items: flex-start !important;
  width: 100% !important;
  max-width: 100vw !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.faq-container {
  max-width: 900px;
  width: 100%;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: 2rem 1.5rem;
  text-align: center;
  box-sizing: border-box;
  flex: 0 1 auto;
}

/* ==============================================
   HOME AND DATA PAGES — center content on wide screens
   ============================================== */

/* Home: only center the main block (flex on container only). Do NOT set
   main.content to flex or the scrolly/map layout breaks. */
body:has(.hero) #quarto-content {
  display: flex !important;
  justify-content: center !important;
  align-items: flex-start !important;
  width: 100% !important;
  max-width: 100vw !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

/* Data (and FAQ-style): center by making both container and main flex */
body:has(.data-page-content) #quarto-content,
body:has(.data-page-content) main.content {
  display: flex !important;
  justify-content: center !important;
  align-items: flex-start !important;
  width: 100% !important;
  max-width: 100vw !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

body:has(.data-page-content) main.content {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.data-page-content {
  max-width: 1600px;
  width: 100%;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: 0 2rem;
  box-sizing: border-box;
  flex: 0 1 auto;
}

.faq-logo {
  width: clamp(200px, 40vw, 500px);
  height: auto;
  margin-bottom: 1.5rem;
}

.faq-intro {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: #444;
  margin-bottom: 2rem;
}

.faq-container h2 {
  text-align: center;
  margin-top: 2.5rem;
  margin-bottom: 1.25rem;
}

.faq-item {
  text-align: left;
  margin-bottom: 0.75rem;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #78c2ad;
}

.faq-item summary {
  background: #78c2ad;
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  padding: 0.85rem 1.25rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 1.3rem;
  font-weight: 700;
  flex-shrink: 0;
  margin-left: 1rem;
  transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
  content: "\2212";
}

.faq-item summary:hover {
  background: #5fb49c;
}

.faq-answer {
  background: #ffe0d6;
  padding: 1rem 1.25rem;
  border-top: 1px solid #ffd6c7;
  color: #1f2a37;
  font-size: 0.95rem;
  line-height: 1.6;
  text-align: justify;
}

.faq-answer p {
  margin: 0 0 0.75rem 0;
}

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

.faq-answer ul {
  margin: 0.5rem 0 0.75rem 1.25rem;
  padding: 0;
}

.faq-answer li {
  margin-bottom: 0.35rem;
}

.faq-answer a {
  color: #1f6f63;
  text-decoration: underline;
}

.faq-answer a:hover {
  color: #13443c;
}

/* ==============================================
   METHODS PAGE -- EQUATION AND LINK OVERFLOW
   ============================================== */

.faq-answer {
  overflow-wrap: break-word;
  word-break: break-word;
}

.faq-answer .MathJax,
.faq-answer mjx-container {
  overflow-x: auto;
  max-width: 100%;
  display: block !important;
}
