:root {
  --fv-bg: #f7f8f7;
  --fv-surface: #ffffff;
  --fv-text: #171717;
  --fv-muted: #626b66;
  --fv-line: #d8ddd8;
  --fv-accent: #0f766e;
  --fv-gold: #b7791f;
  --fv-burgundy: #7f1d1d;
}

body {
  background: var(--fv-bg);
  color: var(--fv-text);
}

.gh-navigation {
  background: rgba(247, 248, 247, 0.94);
  border-bottom: 1px solid var(--fv-line);
  backdrop-filter: blur(12px);
}

.gh-navigation-logo,
.gh-footer-logo {
  font-weight: 850;
}

.gh-navigation-menu a,
.gh-navigation-actions a {
  font-weight: 650;
}

.gh-navigation-menu .nav-current a {
  color: var(--fv-accent);
}

.gh-navigation-menu .nav-telegram a {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid rgba(15, 118, 110, 0.24);
  border-radius: 6px;
  color: #ffffff;
  background: #0f766e;
  text-decoration: none;
}

.gh-navigation-menu .nav-telegram a::before {
  content: "TG";
  margin-right: 7px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 1rem;
  font-weight: 850;
}

.gh-navigation-menu .nav-telegram a:hover {
  background: #0b5f58;
}

.gh-navigation-members {
  display: none;
}

/* Ghost theme hides nav until JS adds is-dropdown-loaded — override for static site */
#gh-navigation .gh-navigation-menu,
#gh-navigation .gh-navigation-actions {
  opacity: 1 !important;
  position: static !important;
  visibility: visible !important;
}

#gh-navigation .gh-navigation-menu .nav > li {
  opacity: 1 !important;
}

/* Mobile nav */
@media (max-width: 991px) {
  .gh-navigation-menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--fv-bg);
    border-bottom: 1px solid var(--fv-line);
    padding: 12px 0;
    z-index: 1000;
  }
  .gh-navigation-menu.is-open {
    display: flex;
  }
  .gh-navigation-menu .nav {
    flex-direction: column;
    gap: 0;
    padding: 0 clamp(24px, 4vw, 56px);
  }
  .gh-navigation-menu .nav li a {
    display: block;
    padding: 10px 0;
    border-bottom: 1px solid var(--fv-line);
  }
  #gh-navigation {
    position: relative;
  }
}

.gh-button {
  border-radius: 6px;
  background: var(--fv-accent);
}

.fv-home-intro {
  padding: clamp(44px, 7vw, 84px) 0 clamp(24px, 4vw, 46px);
  border-bottom: 1px solid var(--fv-line);
}

.fv-home-intro-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: clamp(24px, 5vw, 72px);
  align-items: end;
  box-sizing: border-box;
  width: min(100%, 1280px);
  margin: 0 auto;
  padding-inline: clamp(24px, 4vw, 56px);
}

.fv-eyebrow,
.gh-card-tag,
.gh-article-tag {
  color: var(--fv-accent);
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.fv-home-intro h1 {
  max-width: 780px;
  margin: 12px 0 16px;
  font-size: clamp(4.8rem, 7vw, 8.2rem);
  line-height: 0.92;
}

.fv-home-intro p {
  max-width: 720px;
  color: var(--fv-muted);
  font-size: clamp(1.8rem, 2vw, 2.2rem);
  line-height: 1.45;
}

.fv-home-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(92px, 1fr));
  gap: 1px;
  min-width: min(420px, 100%);
  border: 1px solid var(--fv-line);
  background: var(--fv-line);
}

.fv-home-metric {
  padding: 18px 20px;
  background: var(--fv-surface);
}

.fv-home-metric strong {
  display: block;
  color: var(--fv-text);
  font-size: clamp(2.2rem, 3vw, 3.4rem);
  line-height: 1;
}

.fv-home-metric span {
  display: block;
  margin-top: 8px;
  color: var(--fv-muted);
  font-size: 1.2rem;
  font-weight: 700;
  text-transform: uppercase;
}

.home-template .gh-header {
  padding-top: clamp(28px, 4vw, 52px);
}

.gh-card {
  transition: background-color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.gh-card:hover {
  transform: translateY(-2px);
}

.gh-card-link {
  border-color: var(--fv-line);
}

.gh-card-title {
  font-weight: 820;
}

.gh-card-excerpt,
.gh-article-excerpt,
.gh-card-date,
.gh-article-meta-content {
  color: var(--fv-muted);
}

.gh-card-image {
  filter: saturate(0.92) contrast(1.04);
}

.gh-content h2 {
  margin-top: 1.55em;
  padding-top: 0.9em;
  border-top: 1px solid var(--fv-line);
  font-size: 2.4rem;
}

.gh-content p,
.gh-content li {
  font-size: 1.85rem;
  line-height: 1.8;
}

.gh-content a {
  color: var(--fv-accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.gh-content table,
.kg-html-card table {
  width: 100%;
  table-layout: auto;
  border-collapse: collapse;
  white-space: normal;
  border-top: 2px solid var(--fv-text);
}

.gh-content table th,
.gh-content table td,
.kg-html-card table th,
.kg-html-card table td {
  white-space: normal;
  word-break: break-word;
  vertical-align: top;
  padding: 9px 12px;
  border-bottom: 1px solid var(--fv-line);
  font-size: 1.45rem;
  line-height: 1.5;
}

.gh-content table th,
.kg-html-card table th {
  color: var(--fv-muted);
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.kg-html-card table td:first-child,
.gh-content table td:first-child {
  font-weight: 700;
}

.gh-footer {
  border-top: 1px solid var(--fv-line);
  background: #101413;
  color: #f3f7f5;
}

.gh-footer a,
.gh-footer-signup-subhead {
  color: rgba(243, 247, 245, 0.76);
}

.gh-footer-signup {
  display: none;
}

.gh-footer-copyright {
  display: none;
}

@media (max-width: 900px) {
  .fv-home-intro-inner {
    grid-template-columns: 1fr;
  }

  .fv-home-metrics {
    min-width: 0;
  }
}

/* ── Кнопка «наверх» ───────────────────────────────── */
#fv-back-top {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--fv-accent);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.18);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.2s, transform 0.2s;
  z-index: 200;
  pointer-events: none;
}

#fv-back-top.is-visible {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

#fv-back-top:hover {
  background: #0b5f58;
}

@media (max-width: 600px) {
  .fv-home-intro {
    padding-top: 34px;
  }

  .fv-home-metrics {
    grid-template-columns: 1fr;
  }

  .gh-content table,
  .kg-html-card table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .gh-content table th,
  .gh-content table td,
  .kg-html-card table th,
  .kg-html-card table td {
    font-size: 1.2rem;
    padding: 6px 8px;
  }
}

/* ── Analytics articles ─────────────────────────────── */

.fva-match-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  margin: 1.5rem 0 0.5rem;
  flex-wrap: wrap;
}
.fva-team {
  font-weight: 700;
  font-size: 1.1rem;
  text-align: center;
  flex: 1;
  min-width: 100px;
}
.fva-vs {
  font-size: 1.5rem;
  font-weight: 800;
  color: #64748b;
  flex-shrink: 0;
}
.fva-meta {
  text-align: center;
  font-size: 0.85rem;
  color: #64748b;
  margin: 0.25rem 0 1.5rem !important;
}

.fva-standings {
  width: 100%;
  border-collapse: collapse;
  margin: 1.25rem 0;
  font-size: 0.9rem;
}
.fva-standings th {
  background: var(--fv-accent);
  color: #fff;
  padding: 0.45rem 0.7rem;
  text-align: left;
  font-weight: 600;
}
.fva-standings td {
  padding: 0.45rem 0.7rem;
  border-bottom: 1px solid #e2e8f0;
}
.fva-standings tr:nth-child(even) td { background: #f8fafc; }
.fva-standings .hl td { font-weight: 700; color: var(--fv-accent); }

.fva-formation-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: 1.5rem 0;
}
@media (max-width: 580px) { .fva-formation-wrap { grid-template-columns: 1fr; } }

.fva-formation {
  background: #064e3b;
  border-radius: 10px;
  padding: 1rem;
  color: #fff;
}
.fva-formation-title {
  text-align: center;
  font-weight: 700;
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
  opacity: 0.8;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.fva-row {
  display: flex;
  justify-content: center;
  gap: 0.35rem;
  margin-bottom: 0.5rem;
}
.fva-p {
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 5px;
  padding: 0.25rem 0.4rem;
  font-size: 0.7rem;
  font-weight: 600;
  white-space: nowrap;
  min-width: 52px;
  text-align: center;
}
.fva-p.k { background: rgba(251,191,36,0.3); border-color: rgba(251,191,36,0.6); }

.fva-battle {
  border-left: 3px solid var(--fv-accent);
  padding: 0.7rem 1rem;
  background: #f0fdf4;
  border-radius: 0 8px 8px 0;
  margin: 0.75rem 0;
}
.fva-battle strong { color: var(--fv-accent); display: block; margin-bottom: 0.3rem; }

.fva-quote {
  border-left: 4px solid var(--fv-accent);
  padding: 0.9rem 1.25rem;
  font-size: 1.05rem;
  font-style: italic;
  color: #1e293b;
  margin: 1.25rem 0;
  background: #f0fdf4;
  border-radius: 0 8px 8px 0;
}

/* Winline banner in analytics articles */
.fva-partner {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  margin: 2rem 0 1rem;
  text-align: center;
}
.fva-partner-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0 0 0.6rem !important;
}
.fva-partner-cta {
  display: inline-block;
  background: #1d4ed8;
  color: #fff !important;
  padding: 0.7rem 1.4rem;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none !important;
  font-size: 0.95rem;
}
.fva-partner-cta:hover { background: #1e40af; }
.fva-partner-disclaimer {
  font-size: 0.72rem;
  color: #94a3b8;
  margin: 0.6rem 0 0 !important;
}
