/* =================================================================
   Scouq - Glossary Page
   ================================================================= */

/* Anchor scroll padding so the fixed header doesn't obscure jump targets */
html {
  scroll-padding-top: 80px;
}

.glossary-body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: #0a0a0a;
  color: #ffffff;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* -----------------------------------------------------------------
   Page layout
   ----------------------------------------------------------------- */
.glossary-wrap {
  position: relative;
  z-index: 5;
  max-width: 1200px;
  margin: 0 auto;
  padding: 100px 24px 80px;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 48px;
  align-items: start;
}

@media (max-width: 1023px) {
  .glossary-wrap {
    grid-template-columns: 1fr;
    padding-top: 80px;
  }
}

/* -----------------------------------------------------------------
   Page header (above grid)
   ----------------------------------------------------------------- */
.glossary-page-header {
  position: relative;
  z-index: 5;
  max-width: 1200px;
  margin: 0 auto;
  padding: 96px 24px 0;
}

.glossary-page-header h1 {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  letter-spacing: -1.5px;
  color: #ffffff;
  margin-bottom: 12px;
}

.glossary-page-header p {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.6;
  max-width: 600px;
  margin-bottom: 0;
}

/* -----------------------------------------------------------------
   A-Z anchor nav
   ----------------------------------------------------------------- */
.alpha-nav {
  position: relative;
  z-index: 5;
  max-width: 1200px;
  margin: 32px auto 0;
  padding: 0 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

@media (max-width: 639px) {
  .alpha-nav {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
  }
  .alpha-nav::-webkit-scrollbar {
    display: none;
  }
}

.alpha-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  flex-shrink: 0;
  transition: background 150ms ease, color 150ms ease;
}

.alpha-nav a:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.alpha-nav a.disabled,
.alpha-nav span.disabled {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  font-weight: 500;
  flex-shrink: 0;
  padding: 0 6px;
  opacity: 0.25;
  pointer-events: none;
  text-decoration: none;
  cursor: default;
}

/* -----------------------------------------------------------------
   Sidebar TOC (desktop only)
   ----------------------------------------------------------------- */
.glossary-toc {
  position: sticky;
  top: 80px;
}

@media (max-width: 1023px) {
  .glossary-toc {
    display: none;
  }
}

.glossary-toc-inner {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 20px 16px;
}

.glossary-toc-title {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 12px;
}

.glossary-toc-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.glossary-toc-list li {
  margin-bottom: 2px;
}

.glossary-toc-list a {
  display: block;
  padding: 5px 8px;
  border-radius: 6px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  transition: background 120ms ease, color 120ms ease;
  font-weight: 500;
}

.glossary-toc-list a:hover {
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.9);
}

/* -----------------------------------------------------------------
   Main content
   ----------------------------------------------------------------- */
.glossary-content {
  min-width: 0;
}

/* Letter section header */
.glossary-letter {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.3);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 32px;
  margin-top: 40px;
  margin-bottom: 20px;
}

.glossary-letter:first-child {
  margin-top: 0;
  border-top: none;
}

/* Individual term entry */
.glossary-entry {
  padding: 20px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.glossary-entry:last-of-type {
  border-bottom: none;
}

.glossary-entry h3 {
  font-size: 17px;
  font-weight: 650;
  letter-spacing: -0.4px;
  color: #ffffff;
  margin-bottom: 4px;
}

.glossary-entry .term-def {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 10px;
  font-style: italic;
}

.glossary-entry p {
  font-size: 14px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 10px;
}

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

.glossary-example {
  font-size: 13px;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.03);
  border-left: 2px solid rgba(255, 255, 255, 0.1);
  padding: 10px 14px;
  border-radius: 0 6px 6px 0;
  margin-top: 10px;
}

.glossary-see-also {
  margin-top: 10px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.38);
}

.glossary-see-also a {
  color: rgba(255, 255, 255, 0.55);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 150ms ease;
}

.glossary-see-also a:hover {
  color: rgba(255, 255, 255, 0.85);
}

/* -----------------------------------------------------------------
   Dark background (no map for glossary - solid dark)
   ----------------------------------------------------------------- */
.glossary-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: #0a0a0a;
}
