:root {
  --polish-control-size: 2.24rem;
}

.site-header {
  grid-template-columns: minmax(0, 1fr) max-content max-content;
  gap: 0.44rem;
  padding: 0.56rem clamp(0.72rem, 3.5vw, 3.5rem);
}

.brand {
  min-width: 0;
}

.brand-text {
  min-width: 0;
}

.theme-toggle {
  grid-column: 2;
  grid-row: 1;
  justify-self: end;
  gap: 0.3rem;
  min-height: var(--polish-control-size);
  padding: 0.22rem 0.44rem;
  border-radius: 7px;
  font-size: 0.62rem;
  line-height: 1;
  white-space: nowrap;
}

.theme-toggle-icon {
  width: 0.78rem;
  height: 0.78rem;
  box-shadow: 0 0 0 1.5px color-mix(in srgb, var(--yellow) 18%, transparent);
}

:root[data-theme="night"] .theme-toggle-icon::after {
  width: 0.7rem;
  height: 0.7rem;
}

.nav-toggle {
  grid-column: 3;
  grid-row: 1;
  align-content: center;
  gap: 0.28rem;
  width: var(--polish-control-size);
  height: var(--polish-control-size);
  border-color: color-mix(in srgb, var(--line) 88%, var(--yellow) 12%);
  border-radius: 7px;
  background: color-mix(in srgb, var(--panel) 72%, transparent);
  backdrop-filter: blur(16px);
}

.nav-toggle span {
  width: 1rem;
  height: 1.5px;
  border-radius: 999px;
}

.hero {
  min-height: auto;
  align-items: start;
  padding: 4.75rem 1rem 3rem;
}

h1 {
  font-size: clamp(2.65rem, 11.5vw, 7.6rem);
}

.hero-actions {
  margin-top: 1.45rem;
}

.stats-panel {
  gap: 0.75rem;
  width: min(calc(100% - 2rem), var(--max));
  margin: 1rem auto 0;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(145deg, rgba(255, 210, 31, 0.08), transparent 38%),
    color-mix(in srgb, var(--panel) 64%, transparent);
}

.stat-card {
  display: grid;
  align-content: space-between;
  min-height: 7.4rem;
  padding: clamp(1.15rem, 4.5vw, 1.7rem);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card-gradient), var(--stats-card);
}

.stat-card strong {
  font-size: clamp(2.25rem, 7vw, 4.25rem);
  line-height: 1.04;
}

.stat-card:nth-child(3) strong {
  max-width: 11ch;
  font-size: clamp(1.75rem, 6vw, 3.35rem);
}

.stat-card > span {
  margin-top: 0.75rem;
  font-size: clamp(0.78rem, 2.2vw, 0.9rem);
  line-height: 1.15;
}

@media (min-width: 900px) {
  .site-header {
    grid-template-columns: auto 1fr auto auto;
    gap: 1rem;
    padding: 1rem clamp(1rem, 4vw, 3.5rem);
  }

  .main-nav {
    grid-column: 2;
    grid-row: 1;
  }

  .theme-toggle {
    grid-column: 3;
    grid-row: 1;
  }

  .nav-toggle {
    grid-column: auto;
  }

  .header-cta {
    grid-column: 4;
    grid-row: 1;
  }

  .hero {
    min-height: 100svh;
    align-items: center;
    padding-inline: 3rem;
    padding-block: 7.5rem 2rem;
  }

  .stats-panel {
    gap: 0.9rem;
    margin-top: 1.25rem;
    padding: 0.9rem;
  }

  .stat-card {
    min-height: 8.6rem;
    padding: 1.45rem;
  }

  .stat-card strong {
    font-size: clamp(2.45rem, 4.4vw, 3.75rem);
  }

  .stat-card:nth-child(3) strong {
    font-size: clamp(1.75rem, 3.2vw, 2.5rem);
  }
}
