:root {
  --header-offset: 88px; /* adjust to your fixed header height */
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-offset);
}

.glossary-wrap {
  margin: 0 auto;
}

.glossary-hero {
  background: linear-gradient(135deg, #f8f9fa 0%, #eef5f9 100%);
  border: 1px solid #e5e7eb;
  border-radius: .75rem;
  padding: 1.25rem 1.25rem;
  margin-bottom: 1rem;
}

.glossary-title {
  letter-spacing: .02em;
}

/* TOC (Table of Contents) */
.toc-col {
  position: relative;
}

.toc-sticky {
  position: sticky;
  top: 1rem;
}

.toc-head {
  font-weight: 600;
  color: #6c757d;
  text-transform: uppercase;
  font-size: .8rem;
  margin-bottom: .5rem;
}

.toc a {
  display: block;
  padding: .4rem .5rem;
  border-radius: .5rem;
  text-decoration: none;
  color: inherit;
}

.toc a:hover,
.toc a:focus {
  background: rgba(13, 110, 253, .08);
}

.toc a.active {
  background: #e9f5fa;
  color: #046B99;
  font-weight: 600;
}

html {
  scroll-behavior: smooth;
}

/* Section cards */
.glossary-section {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: .75rem;
  padding: 1.25rem 1.25rem;
  margin-bottom: 1rem;
}

.glossary-section h2 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: .75rem;
}

.glossary-section h3 {
  font-size: .95rem;
  font-weight: 600;
  margin-top: .75rem;
}

/* Definition list */
dl {
  margin: 0;
}

dt {
  font-weight: 700;
  color: #046B99; /* FEAST brand blue */
}

dd {
  margin: .25rem 0 1rem 0;
  color: #333;
}

/* Search bar */
.search-wrap input {
  width: 100%;
  padding: .6rem .8rem;
  border: 1px solid #d0d7de;
  border-radius: .5rem;
}

.search-help {
  font-size: .9rem;
  color: #6c757d;
}

/* Accordion visuals (match FAQ) */
.accordion-button {
  font-weight: 600;
  font-size: 1.05rem;
}

.accordion-button:not(.collapsed) {
  color: #046B99;
  background-color: #e9f5fa;
}

.accordion-item {
  border-left: 4px solid #046B99;
  border-radius: 6px;
  margin-bottom: .75rem;
}

.accordion-body {
  font-size: .95rem;
  color: #333;
}

/* Utility */
.muted {
  color: #6c757d;
}

/* Anchor scroll offset */
.glossary-section,
#cat-about,
#cat-air,
#cat-fire,
#cat-met,
#cat-data,
#cat-maps,
#cat-time,
#cat-methods {
  scroll-margin-top: var(--header-offset);
}

