.md-footer {
  background-color: #213981;
}

/* HOMEPAGE */
.mag-hero-h1 {
  text-align: center;
  font-size: clamp(2rem, 3.8vw, 3rem);
  margin: 0 0 0.5rem;
  letter-spacing: -0.02em;
}

.center {
  text-align: center;
}

.mag-hero {
  padding: 4.5rem 0 2rem;
  text-align: center;
}
.mag-hero h1 {
  font-size: clamp(2rem, 3.8vw, 3rem);
  margin: 0 0 0.5rem;
  letter-spacing: -0.02em;
}
.mag-tagline {
  opacity: 0.9;
  margin: 0 auto 1rem;
  max-width: 60ch;
}
.mag-cta {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 1rem;
}
.mag-btn {
  text-align: center;
  border-radius: 999px;
  padding: 0.65rem 1rem;
  border: 1px solid var(--md-default-fg-color--lighter);
  /*background: var(--md-primary-fg-color);*/
  /*color: var(--md-primary-bg-color);*/
  color: white;
  text-decoration: none;
  font-weight: 600;
}
.mag-btn--ghost {
  background: transparent;
  color: var(--md-default-fg-color);
}

.mag-grid-container {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.mag-grid {
  display: grid;
  grid-template-columns: 1em 9em;
  gap: 18px;
  margin: 2rem auto 4rem;
  max-width: 300px;
  padding: 0 16px;
}

.mag-grid span span {
  font-size: 1.5em;
}

.mag-grid span:first-child {
  font-size: 28px; /* adjust to taste */
  line-height: 1;
  /* Ensure a color-emoji font is available; falls back gracefully */
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", Inter,
    system-ui, sans-serif;
  transform: translateY(1px); /* subtle baseline nudge */
}

.mag-card {
  grid-column: span 6; /* 2-up desktop */
  display: grid;
  grid-template-columns: 64px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-radius: 16px;
  text-decoration: none;
  border: 1px solid var(--md-default-fg-color--lighter);
  background: color-mix(in srgb, var(--md-surface), transparent 10%);
  backdrop-filter: blur(8px);
  transition: transform 0.08s ease, background 0.2s ease, border-color 0.2s ease;
}
.mag-card:hover {
  transform: translateY(-2px);
  border-color: var(--md-default-fg-color--lighter);
}
.mag-card__icon {
  font-size: 28px; /* adjust to taste */
  line-height: 1;
  /* Ensure a color-emoji font is available; falls back gracefully */
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", Inter,
    system-ui, sans-serif;
  transform: translateY(1px); /* subtle baseline nudge */
}

.mag-card__icon .md-icon {
  font-size: 28px;
}
.mag-card__body h3 {
  margin: 0 0 4px;
}
.mag-card__body p {
  margin: 0 0 4px;
  opacity: 0.9;
}
.mag-card__bullets {
  margin: 6px 0 0;
  padding: 0 0 0 1rem;
  opacity: 0.8;
}
.mag-card__chev {
  font-weight: 700;
  opacity: 0.6;
}
@media (max-width: 900px) {
  .mag-card {
    grid-column: span 12;
  }
}

/* SECTION BAR */
.mag-sectionbar {
  position: sticky;
  top: var(--md-header-height, 64px);
  z-index: 3;
  background: var(--md-surface);
  border-bottom: 1px solid var(--md-default-fg-color--lightest);
  margin-bottom: 8px;
}
.mag-sectionbar__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 8px 16px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
}
.mag-sectionbar__sdk {
  font-weight: 800;
  letter-spacing: 0.02em;
  opacity: 0.85;
}
.mag-sectionbar__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0 8px;
}
.mag-sectionbar__links a {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 999px;
  text-decoration: none;
  border: 1px solid var(--md-default-fg-color--lightest);
  opacity: 0.9;
}
.mag-sectionbar__links a.is-active {
  background: var(--md-primary-fg-color);
  color: var(--md-primary-bg-color);
  border-color: transparent;
}
.mag-sectionbar__actions {
  display: flex;
  gap: 10px;
}
.mag-mini {
  font-size: 0.85rem;
  opacity: 0.9;
}

/* READER COMFORT TWEAKS */
.md-typeset h1 {
  letter-spacing: -0.01em;
}
.md-content__inner {
  max-width: 960px;
}

/* Make right TOC feel like a subtle reading rail */
@media (min-width: 1100px) {
  .md-sidebar--secondary {
    border-left: 1px solid var(--md-default-fg-color--lightest);
  }
}
