/* ------------------------------------------------------------------ *
 * Theme 01 — editorial / flat / light
 * ------------------------------------------------------------------ */

:root {
  --zfg-select-bg: #dccca0;
  --zfg-accent: #5a3e1c;
  --zfg-ink: #1e1a12;
  --zfg-rule: #e0d7b8;
  --zfg-max-w: 1180px;
  --zfg-rule-soft: #ebe2c8;
  --zfg-accent-hover: #422c12;
  --zfg-logo-w: 240px;
  --zfg-surface: #ffffff;
  --zfg-bg: #f9f6ed;
  --zfg-ink-muted: #7d766a;
  --zfg-ink-soft: #464038;
  --zfg-font-body: "Karla", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --zfg-button-radius: 12px;
  --zfg-header-bg: #ede7d2;
  --zfg-font-display: "Spectral", Georgia, serif;
  --zfg-wide-w: 1180px;
}

/* ---------- reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; padding: 0; }
img { max-width: 100%; height: auto; display: block; }
::selection { background: var(--zfg-select-bg); color: var(--zfg-ink); }

body {
  background: var(--zfg-bg);
  color: var(--zfg-ink);
  font-family: var(--zfg-font-body);
  font-size: 17px;
  line-height: 1.61;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

a {
  color: var(--zfg-accent);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  transition: text-decoration-thickness .12s ease, color .12s ease;
}
a:hover {
  color: var(--zfg-accent-hover);
  text-decoration-thickness: 2px;
}

/* ---------- header ---------- */
.site-masthead {
  background: var(--zfg-header-bg);
  border-bottom: 1px solid var(--zfg-rule);
  position: relative;
  z-index: 50;
}
.masthead__row {
  max-width: var(--zfg-wide-w);
  margin: 0 auto;
  padding: 0.96rem 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

/* Mobile nav toggle: button driven by JS via data-nav-toggle.
   Two icons inside (burger + close); JS toggles .is-open class to swap them. */
.nav-open-btn {
  display: none;
  width: 40px;
  height: 40px;
  cursor: pointer;
  border: 1px solid var(--zfg-rule);
  border-radius: 8px;
  background: transparent;
  color: var(--zfg-ink);
  align-items: center;
  justify-content: center;
  padding: 0;
  position: relative;
  transition: border-color .15s ease;
}
.nav-open-btn:hover { border-color: var(--zfg-ink); }
.nav-open-btn:focus-visible {
  outline: 2px solid var(--zfg-accent);
  outline-offset: 2px;
}
.toggle-icon,
.nav-toggle__close {
  position: absolute;
  inset: 0;
  margin: auto;
  transition: opacity .15s ease, transform .2s ease;
}
.nav-toggle__close { opacity: 0; transform: rotate(-90deg); }
.nav-open-btn.is-open .toggle-icon { opacity: 0; transform: rotate(90deg); }
.nav-open-btn.is-open .nav-toggle__close  { opacity: 1; transform: rotate(0); }
.header-logo {
  font-family: var(--zfg-font-display);
  font-weight: 600;
  font-size: 22px;
  letter-spacing: -0.015em;
  color: var(--zfg-ink);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.header-logo:hover { color: var(--zfg-ink); text-decoration: none; }
.site-name__dot { color: var(--zfg-accent); }
/* Image logo: scale up visually while keeping the header from growing
   via negative vertical margins. */
.brand--image img {
  display: block;
  height: 48px;
  width: auto;
  margin: -10px 0;
}
@media (max-width: 720px) {
  .brand--image img {
    height: 40px;
    margin: -8px 0;
  }
}

.menu-main ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 28px;
}
.menu-main a {
  display: inline-block;
  vertical-align: middle;
  white-space: nowrap;
  color: var(--zfg-ink);
  font-size: 15px;
  text-decoration: none;
  padding: 4px 0;
  /* No default hover/active styles — the per-site menu variant
     (data/menu-styles.ts) owns those entirely. Base rules used to add a
     border-bottom underline which double-stacked with variant styles. */
}

/* ---------- article ---------- */
.doc-body {
  max-width: var(--zfg-max-w);
  margin: 0 auto;
  padding: 56px 24px 80px;
}

.main-article__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-size: 12px;
  color: var(--zfg-ink-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 18px;
}
.main-article__meta span + span::before {
  content: "·";
  margin-right: 16px;
  color: var(--zfg-ink-muted);
}

.doc-body h1 {
  font-family: var(--zfg-font-display);
  font-weight: 500;
  font-size: 44px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 22px;
  color: var(--zfg-ink);
}
.doc-body .lead {
  font-size: 19px;
  line-height: 1.55;
  color: var(--zfg-ink-soft);
  margin: 0 0 28px;
}

.doc-body h2 {
  font-family: var(--zfg-font-display);
  font-weight: 500;
  font-size: 28px;
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin: 48px 0 16px;
  color: var(--zfg-ink);
  scroll-margin-top: 24px;
}
.doc-body h3 {
  font-family: var(--zfg-font-display);
  font-weight: 600;
  font-size: 20px;
  line-height: 1.3;
  margin: 32px 0 10px;
  color: var(--zfg-ink);
}

.doc-body p { margin: 0 0 18px; }
.doc-body ul, .doc-body ol {
  margin: 0 0 20px;
  padding-left: 22px;
}
.doc-body li { margin-bottom: 6px; }
.doc-body li::marker { color: var(--zfg-ink-muted); }

.doc-body hr {
  border: none;
  border-top: 1px solid var(--zfg-rule);
  margin: 40px 0;
}

.doc-body figure {
  margin: 36px 0;
}
.doc-body figure img {
  width: 100%;
  border: 1px solid var(--zfg-rule-soft);
}
.doc-body figcaption {
  margin-top: 10px;
  font-size: 13px;
  font-style: italic;
  color: var(--zfg-ink-muted);
  text-align: center;
}

.doc-body strong { font-weight: 600; color: var(--zfg-ink); }

/* ---------- FAQ accordion ---------- */
.doc-body .faq {
  margin: 28px 0 40px;
  border-top: 1px solid var(--zfg-rule);
}
.doc-body .faq__item {
  border-bottom: 1px solid var(--zfg-rule);
}
.doc-body .faq__item > summary {
  list-style: none;
  cursor: pointer;
  padding: 20px 44px 20px 0;
  position: relative;
  font-family: var(--zfg-font-display);
  font-weight: 500;
  font-size: 19px;
  line-height: 1.35;
  color: var(--zfg-ink);
  letter-spacing: -0.005em;
  user-select: none;
}
.doc-body .faq__item > summary::-webkit-details-marker { display: none; }
.doc-body .faq__item > summary::after {
  content: '';
  position: absolute;
  right: 6px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-right: 1.5px solid var(--zfg-ink);
  border-bottom: 1.5px solid var(--zfg-ink);
  transform: translateY(-75%) rotate(45deg);
  transition: transform .2s ease;
}
.doc-body .faq__item[open] > summary::after {
  transform: translateY(-25%) rotate(-135deg);
}
.doc-body .faq__item > summary:hover {
  color: var(--zfg-accent);
}
.doc-body .faq__answer {
  padding: 0 0 22px;
  color: var(--zfg-ink-soft);
  font-size: 16px;
  line-height: 1.7;
}
.doc-body .faq__answer > div > p { margin: 0 0 12px; }
.doc-body .faq__answer > div > p:last-child { margin-bottom: 0; }
.doc-body .faq__answer > div > ul,
.doc-body .faq__answer > div > ol {
  margin: 0 0 12px;
  padding-left: 20px;
}
@media (max-width: 720px) {
  .doc-body .faq__item > summary {
    font-size: 17px;
    padding: 16px 36px 16px 0;
  }
  .doc-body .faq__answer { font-size: 15px; padding-bottom: 18px; }
}

/* ---------- Brand shortlist table (casino style) ---------- */
.neat-note {
  margin: 36px 0 44px;
}
.neat-note h2 { scroll-margin-top: 24px; }

.neat-note__list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Three-column row: white logo cell with SLANTED right edge | beige body
   with bonus + stars | blue CTA. Rank tag is a dark navy chip positioned
   right where the slant meets the row top, slightly overhanging both. */
.editorial-list {
  --zfg-logo-w: 240px;
  position: relative;
  display: grid;
  grid-template-columns: var(--zfg-logo-w) 1fr auto;
  align-items: stretch;
  background: var(--zfg-surface);
  border: 1px solid var(--zfg-rule);
  border-radius: 6px;
  overflow: hidden;
  min-height: 116px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: box-shadow .15s ease, border-color .15s ease;
}
.editorial-list:hover {
  box-shadow: 0 4px 16px -10px rgba(0, 0, 0, 0.18);
}
.editorial-list[hidden] { display: none; }

/* Left cell: themed soft background */
.editorial-list__logo-cell {
  background: var(--zfg-rule-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 18px;
}
.editorial-list__logo {
  background: #111111;
  border-radius: 4px;
  width: 100%;
  max-width: 140px;
  min-height: 60px;
  padding: 14px 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  line-height: 1.1;
}
.editorial-list__logo-name {
  font-family: var(--zfg-font-display);
  font-weight: 700;
  font-size: 18px;
  color: #f5d042;
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.editorial-list__logo-tag {
  font-family: var(--zfg-font-body);
  font-weight: 700;
  font-size: 9px;
  letter-spacing: 0.06em;
  color: #ffffff;
}
.editorial-list__logo-tag span { color: #e53935; }

/* Middle cell: bonus headline + gold stars, vertically centred */
.editorial-list .editorial-list__info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  padding: 18px 32px;
  min-width: 0;
}
.editorial-list .editorial-list__bonus {
  font-family: var(--zfg-font-body);
  font-weight: 500;
  font-size: 22px;
  line-height: 1.25;
  color: #1a1a1a;
  margin: 0;
  letter-spacing: -0.005em;
}
.editorial-list__stars {
  color: #f5b800;
  font-size: 18px;
  letter-spacing: 3px;
  line-height: 1;
}

/* Right cell: themed accent "Play Now" button, vertically centred */
.editorial-list__cta {
  align-self: center;
  justify-self: end;
  margin-right: 22px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--zfg-accent);
  color: #ffffff;
  font-family: var(--zfg-font-body);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  padding: 12px 26px;
  border-radius: var(--zfg-button-radius);
  white-space: nowrap;
  transition: background-color .15s ease;
}
.editorial-list__cta:hover {
  background: var(--zfg-accent-hover);
  color: #ffffff;
  text-decoration: none;
}
.editorial-list__cta-arrow { font-size: 10px; }

/* "Show more" button */
.neat-note__more {
  display: block;
  margin: 18px auto 0;
  background: transparent;
  border: 1px solid var(--zfg-rule);
  border-radius: var(--zfg-button-radius);
  padding: 12px 28px;
  font-family: var(--zfg-font-body);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--zfg-ink);
  cursor: pointer;
  transition: border-color .15s ease, background-color .15s ease, color .15s ease;
}
.neat-note__more:hover {
  border-color: var(--zfg-ink);
  background: var(--zfg-ink);
  color: #fff;
}

/* Mobile: stack into one column, drop the slant */
@media (max-width: 720px) {
  .editorial-list {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
    min-height: 0;
    padding-bottom: 16px;
  }
  .editorial-list__logo-cell {
    padding: 22px 16px;
  }
  .editorial-list__logo { max-width: 220px; }
  .editorial-list__info {
    padding: 8px 18px 4px;
    gap: 6px;
    align-items: center;
    text-align: center;
  }
  .editorial-list__bonus { font-size: 18px; }
  .editorial-list__cta {
    align-self: stretch;
    justify-self: stretch;
    justify-content: center;
    margin: 6px 16px 0;
    padding: 14px;
    font-size: 16px;
  }
}

/* ---------- Interactive widgets ---------- */
.widget {
  margin: 44px 0;
  padding: 32px;
  background: var(--zfg-surface);
  border: 1px solid var(--zfg-rule);
  border-radius: 14px;
}
.widget__eyebrow {
  display: inline-block;
  font-family: var(--zfg-font-body);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--zfg-accent);
  font-weight: 600;
  margin-bottom: 10px;
}
.widget__title {
  font-family: var(--zfg-font-display);
  font-weight: 500;
  font-size: 24px;
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin: 0 0 8px;
  color: var(--zfg-ink);
}
.widget__sub {
  margin: 0 0 22px;
  font-size: 15px;
  color: var(--zfg-ink-soft);
  line-height: 1.55;
}
.widget__action {
  font-family: var(--zfg-font-body);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: var(--zfg-ink);
  color: #fff;
  border: 1px solid var(--zfg-ink);
  border-radius: 8px;
  padding: 12px 22px;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease;
}
.widget__action:hover:not(:disabled) {
  background: var(--zfg-accent);
  border-color: var(--zfg-accent);
}
.widget__action:disabled { opacity: 0.5; cursor: default; }
.widget__cta {
  display: inline-block;
  margin-top: 6px;
  font-family: var(--zfg-font-body);
  font-size: 14px;
  font-weight: 600;
  background: var(--zfg-accent);
  color: #fff;
  text-decoration: none;
  border-radius: 8px;
  padding: 11px 20px;
  transition: background-color .15s ease;
}
.widget__cta:hover { background: var(--zfg-accent-hover); color: #fff; text-decoration: none; }
.widget__result { margin-top: 22px; }
/* `hidden` attribute must win over per-variant display: flex below. */
.widget__result[hidden] { display: none !important; }
.widget__result-lead { margin: 0 0 14px; font-size: 16px; color: var(--zfg-ink); }
.widget__result-name { font-family: var(--zfg-font-display); font-weight: 600; }

/* Quiz */
.widget__options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}
.widget__option {
  font-family: var(--zfg-font-body);
  font-size: 15px;
  font-weight: 500;
  color: var(--zfg-ink);
  background: transparent;
  border: 1px solid var(--zfg-rule);
  border-radius: 8px;
  padding: 14px 18px;
  text-align: left;
  cursor: pointer;
  transition: border-color .15s ease, background-color .15s ease;
}
.widget__option:hover { border-color: var(--zfg-ink); }
.widget__option.is-selected { border-color: var(--zfg-accent); background: var(--zfg-rule-soft); }

/* Calculator */
.widget__fields {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.widget__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.widget__field > span {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--zfg-ink);
  text-transform: uppercase;
}
.widget__field input {
  font-family: var(--zfg-font-body);
  font-size: 16px;
  color: var(--zfg-ink);
  background: var(--zfg-bg);
  border: 1px solid var(--zfg-rule);
  border-radius: 8px;
  padding: 10px 12px;
  outline: none;
  transition: border-color .15s ease;
}
.widget__field input:focus { border-color: var(--zfg-accent); }
.widget__field small { font-size: 11px; color: var(--zfg-ink-muted); }
.widget--calc .widget__result {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.widget__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--zfg-rule);
  border: 1px solid var(--zfg-rule);
  border-radius: 10px;
  overflow: hidden;
}
.widget__stat {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 18px 20px;
  background: var(--zfg-rule-soft);
}
.widget__stat--net { background: var(--zfg-surface); }
.widget__stat-label {
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--zfg-ink-muted);
  font-weight: 600;
}
.widget__stat-value {
  font-family: var(--zfg-font-display);
  font-weight: 600;
  font-size: 24px;
  color: var(--zfg-ink);
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.widget__stat--net .widget__stat-value { color: var(--zfg-accent); font-size: 28px; }
@media (max-width: 720px) {
  .widget__stats { grid-template-columns: 1fr; }
  .widget__stat-value { font-size: 22px; }
  .widget__stat--net .widget__stat-value { font-size: 24px; }
}


@media (max-width: 720px) {
  .widget { padding: 22px; margin: 36px 0; }
  .widget__title { font-size: 20px; }
}

/* ---------- TOC (collapsible) ---------- */
.page-toc {
  margin: 24px 0 32px;
  border-top: 1px solid var(--zfg-rule);
  border-bottom: 1px solid var(--zfg-rule);
}
.page-toc summary {
  list-style: none;
  cursor: pointer;
  padding: 12px 0;
  display: flex;
  align-items: center;
  gap: 12px;
  user-select: none;
}
.page-toc summary::-webkit-details-marker { display: none; }
.contents-title {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--zfg-ink);
  font-weight: 600;
}
.toc-block__count {
  font-size: 12px;
  color: var(--zfg-ink-muted);
}
.toc-indicator {
  margin-left: auto;
  color: var(--zfg-ink-muted);
  transition: transform .2s ease;
}
.page-toc[open] .toc-indicator { transform: rotate(180deg); }

.page-toc ol {
  list-style: none;
  margin: 0;
  padding: 4px 0 16px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0 28px;
  counter-reset: toc;
}
.page-toc li {
  counter-increment: toc;
  position: relative;
  padding-left: 28px;
}
.page-toc li::before {
  content: counter(toc, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 6px;
  font-family: var(--zfg-font-body);
  font-feature-settings: "tnum";
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--zfg-ink-muted);
}
.page-toc a {
  display: block;
  padding: 4px 0;
  color: var(--zfg-ink);
  text-decoration: none;
  font-family: var(--zfg-font-body);
  font-size: 13.5px;
  line-height: 1.4;
  border-bottom: 1px solid transparent;
  transition: color .15s ease, border-color .15s ease;
}
.page-toc a:hover {
  color: var(--zfg-accent);
  border-bottom-color: var(--zfg-accent);
}
@media (max-width: 720px) {
  .page-toc ol { grid-template-columns: 1fr; }
}

/* ---------- tables ---------- */
.doc-body table {
  width: 100%;
  margin: 36px 0;
  border-collapse: separate;
  border-spacing: 0;
  font-family: var(--zfg-font-body);
  font-size: 15px;
  line-height: 1.55;
  color: var(--zfg-ink);
  background: var(--zfg-surface);
  border: 1px solid var(--zfg-rule);
  border-radius: 12px;
  overflow: hidden;
}
.doc-body thead th {
  background: var(--zfg-rule-soft);
  padding: 16px 20px;
  text-align: left;
  vertical-align: middle;
  font-weight: 600;
  font-size: 14px;
  color: var(--zfg-ink);
  border-bottom: 1px solid var(--zfg-rule);
}
.doc-body tbody td {
  padding: 18px 20px;
  text-align: left;
  vertical-align: top;
  color: var(--zfg-ink-soft);
  border-bottom: 1px solid var(--zfg-rule-soft);
}
.doc-body tbody tr:last-child td {
  border-bottom: none;
}
.doc-body tbody td:first-child {
  font-weight: 600;
  color: var(--zfg-ink);
}
@media (max-width: 720px) {
  .doc-body table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 8px;
  }
  .doc-body thead th { padding: 12px 14px; font-size: 13px; }
  .doc-body tbody td { padding: 14px; }
}

/* ---------- footer ---------- */
.foot-bar {
  background: var(--zfg-header-bg);
  border-top: 1px solid var(--zfg-rule);
  margin-top: 40px;
}
.foot-strip__inner {
  max-width: var(--zfg-wide-w);
  margin: 0 auto;
  padding: 36px 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.tail-nav {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}
.tail-nav a {
  font-size: 14px;
  color: var(--zfg-ink);
  text-decoration: none;
}
.tail-nav a:hover {
  color: var(--zfg-accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.site-footer__disclaimer {
  font-size: 13px;
  line-height: 1.6;
  color: var(--zfg-ink-muted);
  max-width: 760px;
  margin: 0;
}
.site-footer__copy {
  font-size: 13px;
  color: var(--zfg-ink-muted);
  border-top: 1px solid var(--zfg-rule);
  padding-top: 14px;
  margin: 0;
}

/* ---------- responsive ---------- */
@media (max-width: 720px) {
  body { font-size: 16px; }
  .masthead__row {
    padding: 14px 20px;
    gap: 12px;
  }
  .nav-open-btn {
    display: inline-flex;
  }
  .menu-main {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--zfg-header-bg);
    border-bottom: 1px solid var(--zfg-rule);
    box-shadow: 0 8px 20px -12px rgba(0, 0, 0, 0.15);
    padding: 8px 20px 16px;
    z-index: 50;
  }
  .menu-main.is-open {
    display: block;
  }
  .menu-main ul {
    flex-direction: column;
    gap: 0;
  }
  .menu-main li {
    border-bottom: 1px solid var(--zfg-rule-soft);
  }
  .menu-main li:last-child { border-bottom: none; }
  .menu-main a {
    display: block;
    padding: 12px 4px;
    border-bottom: none;
    font-size: 16px;
  }
  .menu-main a:hover { border-bottom: none; }
  .menu-main a.active-link { border-bottom: none; }

  .doc-body {
    padding: 36px 20px 60px;
  }
  .doc-body h1 { font-size: 32px; }
  .doc-body .lead { font-size: 17px; }
  .doc-body h2 { font-size: 24px; }
  .doc-body h3 { font-size: 18px; }
}

/* ---- wave-2 variant CSS ---- */

.masthead__row { padding-block: 0.965rem; }

.site-masthead { position: sticky; top: 0; z-index: 10; }

/* hdr v3: two rows, both centered — single background, no dividers */
.xep-hdr-v3 .masthead__row {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.xep-hdr-v3 .header-logo { order: 1; }
.xep-hdr-v3 .nav-open-btn { display: none; }
.xep-hdr-v3 .menu-main {
  order: 2;
  margin-left: 0;
}
.xep-hdr-v3 .menu-main ul {
  justify-content: center;
}
@media (max-width: 720px) {
  .xep-hdr-v3 .masthead__row { flex-direction: row; flex-wrap: wrap; justify-content: space-between; }
  .xep-hdr-v3 .nav-open-btn { display: flex; order: 3; }
  .xep-hdr-v3 .menu-main { order: 4; width: 100%; }
}

/* content card: flush */
.xep-cc {
  padding: 0;
  margin: 40px 0 0;
}
.xep-cc__inner {
  padding: 0;
  border-radius: 4px;
}

.xep-cc {
  max-width: var(--zfg-wide-w);
  margin: 40px auto 0;
}
.xep-cc__inner {
  background: var(--zfg-surface);
  
  border-radius: 4px;
}

body { background-image: repeating-linear-gradient(0deg, rgba(0,0,0,.03) 0px, rgba(0,0,0,.03) 1px, transparent 1px, transparent 24px); }

@media (max-width: 720px) {
  .menu-main a {
    display: flex !important;
    align-items: center;
    gap: 6px;
  }
  .menu-main a::before {
    content: '→';
    color: currentColor;
    opacity: .6;
    flex-shrink: 0;
  }
}

@media (min-width: 721px) {
.xep-menu-text-underline nav a {
  color: var(--zfg-ink);
  text-decoration: none;
  text-underline-offset: 5px;
  text-decoration-thickness: 1px;
  padding: 4px 2px;
  transition: color .15s ease;
}
.xep-menu-text-underline nav a:hover {
  color: var(--zfg-accent-hover);
  text-decoration: underline;
  text-decoration-color: var(--zfg-accent-hover);
}
.xep-menu-text-underline nav a.active-link {
  color: var(--zfg-accent);
  text-decoration: underline;
  text-decoration-color: var(--zfg-accent);
}
}


/* geometry supplement */
:root { --zfg-content-width: 1180px; }

/* content typography variability */
.doc-body p { text-align: left; }
.doc-body h1,
.doc-body h2 { text-align: center; }
.doc-body h3,
.doc-body h4,
.doc-body h5,
.doc-body h6 { text-align: left; }

/* footer layout: centered */
.foot-strip__inner {
  flex-direction: row;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.site-footer__copy {
  border-top: none;
  padding-top: 0;
  margin: 0;
}
.tail-nav {
  margin: 0;
}
@media (max-width: 720px) {
  .foot-strip__inner { flex-direction: column; align-items: center; text-align: center; }
}
.foot-strip__inner { justify-content: center; flex-direction: column; text-align: center; }
.tail-nav { justify-content: center; }
