:root {
  color-scheme: dark;
  --bg: #080d18;
  --bg-elevated: #0d1422;
  --panel: rgba(15, 24, 40, .78);
  --panel-solid: #111b2c;
  --text: #eef4ff;
  --muted: #9aa8be;
  --line: rgba(166, 188, 220, .16);
  --line-strong: rgba(166, 188, 220, .28);
  --accent: #7ae7ff;
  --accent-2: #9c8cff;
  --accent-3: #7dffbd;
  --warm: #ffcb7a;
  --danger: #ff8aa5;
  --shadow: 0 24px 70px rgba(0,0,0,.28);
  --radius: 22px;
  --radius-sm: 14px;
  --shell: min(1180px, calc(100vw - 40px));
  --header-h: 74px;
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #f4f7fb;
  --bg-elevated: #ffffff;
  --panel: rgba(255,255,255,.82);
  --panel-solid: #ffffff;
  --text: #132036;
  --muted: #607089;
  --line: rgba(38, 58, 88, .13);
  --line-strong: rgba(38, 58, 88, .22);
  --accent: #007b9f;
  --accent-2: #6657d9;
  --accent-3: #16805b;
  --warm: #b96800;
  --danger: #b83458;
  --shadow: 0 24px 70px rgba(26, 44, 74, .12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 18px); }
body {
  margin: 0;
  min-width: 280px;
  background:
    radial-gradient(circle at 78% -10%, color-mix(in srgb, var(--accent-2) 16%, transparent), transparent 34rem),
    radial-gradient(circle at 4% 22%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 30rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
button { font: inherit; }
img, svg { display: block; max-width: 100%; }

.skip-link {
  position: fixed;
  left: 16px;
  top: -60px;
  z-index: 200;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--text);
  color: var(--bg);
  transition: top .2s ease;
}
.skip-link:focus { top: 12px; }

.section-shell { width: var(--shell); margin-inline: auto; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .76rem;
  font-weight: 750;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
}
.eyebrow::before {
  content: "";
  width: 24px;
  height: 1px;
  background: currentColor;
  opacity: .75;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  min-height: var(--header-h);
  border-bottom: 1px solid transparent;
  background: color-mix(in srgb, var(--bg) 74%, transparent);
  backdrop-filter: blur(18px) saturate(135%);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.site-header.is-scrolled {
  border-color: var(--line);
  box-shadow: 0 8px 30px rgba(0,0,0,.12);
}
.header-shell {
  width: var(--shell);
  min-height: var(--header-h);
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  min-width: max-content;
}
.brand img { width: 38px; height: 38px; }
.brand-copy { display: grid; line-height: 1.15; }
.brand-copy strong { font-size: .98rem; letter-spacing: .01em; }
.brand-copy span { margin-top: 4px; font-size: .68rem; color: var(--muted); letter-spacing: .08em; text-transform: uppercase; }
.desktop-nav a:hover, .desktop-nav a:focus-visible, .mobile-nav a:hover, .mobile-nav a:focus-visible { color: var(--text); }
.header-actions { display: flex; gap: 8px; }
.icon-button {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--text);
  background: var(--panel);
  cursor: pointer;
}
.icon-button:hover { border-color: var(--line-strong); }
.icon-button svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.menu-button { display: grid; }
.site-menu {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg-elevated) 94%, transparent);
  box-shadow: 0 28px 60px rgba(0,0,0,.22);
}
.site-menu:not([hidden]) { display: block; }
.site-menu-inner { padding-block: 22px 26px; }
.site-menu-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}
.site-menu-head > div { display: grid; gap: 5px; }
.site-menu-head strong { font-size: 1.25rem; letter-spacing: -.02em; }
.menu-home,
.site-menu-meta a,
.footer-meta a {
  color: var(--muted);
  text-decoration: none;
}
.menu-home:hover,
.site-menu-meta a:hover,
.footer-meta a:hover,
.menu-home:focus-visible,
.site-menu-meta a:focus-visible,
.footer-meta a:focus-visible { color: var(--text); }

.module-menu-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 8px;
}
.menu-module {
  min-width: 0;
  display: grid;
  grid-template-columns: 52px minmax(0,1fr);
  align-items: center;
  gap: 10px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  text-decoration: none;
}
.menu-module:hover,
.menu-module:focus-visible { border-color: var(--line-strong); background: var(--panel-solid); }
.menu-module span {
  color: var(--accent);
  font-size: .74rem;
  font-weight: 800;
  letter-spacing: .08em;
}
.menu-module strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: .88rem;
}
.site-menu-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: .82rem;
  font-weight: 650;
}
.menu-button { display: grid; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 12px;
  border: 1px solid var(--line);
  text-decoration: none;
  font-weight: 750;
  font-size: .88rem;
}
.button.primary { color: #07131c; background: var(--accent); border-color: transparent; }
.button.secondary { background: var(--panel); }
.button:hover { transform: translateY(-1px); }

.section-heading { max-width: 760px; margin-bottom: 34px; }
.section-heading h2 {
  margin: 10px 0 12px;
  font-size: clamp(2rem, 4vw, 3.35rem);
  line-height: 1.02;
  letter-spacing: -.045em;
}
.section-heading p { margin: 0; color: var(--muted); font-size: 1.02rem; }

.site-footer { border-top: 1px solid var(--line); margin-top: 18px; }
.footer-inner {
  min-height: 120px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  color: var(--muted);
  font-size: .8rem;
}
.footer-inner > div { display: flex; gap: 12px; flex-wrap: wrap; }
.footer-inner strong { color: var(--text); }
.footer-meta { justify-content: flex-end; align-items: center; }
.footer-meta a { font-weight: 700; }

@media (max-width: 840px) {
  :root { --shell: min(100% - 28px, 1180px); --header-h: 68px; }
  .module-menu-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  :root { --shell: min(100% - 22px, 1180px); }
  .brand-copy span { display: none; }
  .brand img { width: 34px; height: 34px; }
  .footer-inner { align-items: flex-start; flex-direction: column; justify-content: center; }
  .footer-meta { justify-content: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

.footer-owner {
  color: var(--text);
  font-weight: 760;
}
.footer-owner:hover,
.footer-owner:focus-visible { color: var(--accent); }
