:root {
  color-scheme: dark;
  --bg: #0b151b;
  --panel: #10222b;
  --panel-2: #142c35;
  --text: #eef7f8;
  --muted: #a8bdc3;
  --line: rgba(255, 255, 255, .12);
  --teal: #2fd6b8;
  --amber: #ffc35c;
  --coral: #ff6f61;
  --blue: #54c0e0;
  --shadow: 0 18px 60px rgba(0, 0, 0, .32);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    linear-gradient(180deg, rgba(47, 214, 184, .08), transparent 340px),
    radial-gradient(circle at top left, rgba(255, 195, 92, .12), transparent 330px),
    var(--bg);
  color: var(--text);
  line-height: 1.65;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
p { color: var(--muted); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px max(22px, calc((100vw - 1180px) / 2));
  background: rgba(11, 21, 27, .9);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand { display: flex; align-items: center; gap: 11px; min-width: 220px; }
.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(47, 214, 184, .55);
  background: #10222b;
  color: var(--amber);
  font-weight: 800;
  border-radius: 8px;
}
.brand strong { display: block; line-height: 1.1; }
.brand small { display: block; color: var(--muted); font-size: .78rem; }

.main-nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.main-nav a {
  padding: 8px 10px;
  border-radius: 8px;
  color: var(--muted);
  font-size: .92rem;
}
.main-nav a:hover, .main-nav a.active { background: rgba(47, 214, 184, .12); color: var(--text); }
.menu-toggle { display: none; }

.wrap { width: min(1180px, calc(100% - 36px)); margin: 0 auto; }
.hero {
  min-height: 560px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 520px);
  align-items: center;
  gap: 38px;
  padding: 48px 0 34px;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--amber);
  font-weight: 700;
  margin-bottom: 14px;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--amber); }
h1, h2, h3 { line-height: 1.12; margin: 0; }
h1 { font-size: 3rem; max-width: 820px; }
h2 { font-size: 2rem; margin-top: 54px; }
h3 { font-size: 1.25rem; margin-top: 22px; }
.lead { font-size: 1.15rem; max-width: 760px; }
.hero-actions, .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 17px;
  min-height: 46px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, .16);
  background: var(--teal);
  color: #06231f;
  font-weight: 800;
}
.button.secondary { background: transparent; color: var(--text); }

.hero-media, .feature-image {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--panel);
}
.hero-media img { width: 100%; aspect-ratio: 1.55; object-fit: cover; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 26px; }
.stat {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 34, 43, .72);
}
.stat strong { display: block; color: var(--text); font-size: 1.35rem; }
.stat span { color: var(--muted); font-size: .9rem; }

.section { padding: 34px 0; }
.section.compact { padding-top: 10px; }
.section-head { max-width: 820px; margin-bottom: 20px; }
.section-head p { margin-bottom: 0; }
.grid { display: grid; gap: 18px; }
.grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 34, 43, .72);
  overflow: hidden;
}
.card.pad { padding: 20px; }
.card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-bottom: 1px solid var(--line); }
.card-body { padding: 18px; }
.card h3 { margin-top: 0; }
.card p { margin: 10px 0 0; }
.tag {
  display: inline-flex;
  margin: 0 0 10px;
  padding: 5px 8px;
  border: 1px solid rgba(255, 195, 92, .34);
  border-radius: 8px;
  color: var(--amber);
  font-size: .8rem;
  font-weight: 700;
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 760px) minmax(260px, 1fr);
  gap: 34px;
  align-items: start;
}
.article {
  padding-bottom: 46px;
}
.article .feature-image { margin: 22px 0; }
.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  margin-top: 14px;
  font-size: .92rem;
}
.toc, .sidebar-box {
  position: sticky;
  top: 84px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 34, 43, .78);
  padding: 18px;
}
.toc a { display: block; color: var(--muted); padding: 7px 0; border-bottom: 1px solid rgba(255,255,255,.07); }
.toc a:hover { color: var(--text); }

.checklist, .pros-cons, .source-list {
  display: grid;
  gap: 10px;
  padding: 0;
  list-style: none;
}
.checklist li, .source-list li {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, .035);
}
.checklist li::before { content: "✓ "; color: var(--teal); font-weight: 800; }
.warn { border-left: 4px solid var(--coral); padding: 14px 16px; background: rgba(255,111,97,.08); border-radius: 8px; color: var(--text); }
.note { border-left: 4px solid var(--amber); padding: 14px 16px; background: rgba(255,195,92,.08); border-radius: 8px; color: var(--text); }

table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(16, 34, 43, .66);
  margin: 20px 0;
}
th, td { text-align: left; padding: 13px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--text); background: rgba(47, 214, 184, .11); }
td { color: var(--muted); }

.ad-slot {
  display: grid;
  place-items: center;
  min-height: 132px;
  margin: 28px 0;
  padding: 18px;
  border: 1px dashed rgba(255, 195, 92, .55);
  border-radius: 8px;
  background: rgba(255, 195, 92, .06);
  color: var(--muted);
  text-align: center;
}
.ad-slot span { display: block; color: var(--amber); font-size: .8rem; font-weight: 800; text-transform: uppercase; }
.ad-slot strong { display: block; color: var(--text); }
.ad-slot em { font-style: normal; font-size: .9rem; }

.tool-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16,34,43,.82);
  padding: 22px;
}
.tool-panel label { display: grid; gap: 6px; color: var(--muted); font-weight: 700; }
.tool-panel input, .tool-panel select {
  width: 100%;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #091218;
  color: var(--text);
}
.result {
  padding: 18px;
  border-radius: 8px;
  border: 1px solid rgba(47,214,184,.35);
  background: rgba(47,214,184,.08);
}
.result strong { font-size: 1.6rem; color: var(--teal); }

.site-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  padding: 34px max(22px, calc((100vw - 1180px) / 2));
  border-top: 1px solid var(--line);
  background: #071015;
}
.site-footer p { max-width: 620px; margin-bottom: 0; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 12px; align-content: start; justify-content: flex-end; }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--text); }

@media (max-width: 980px) {
  .hero, .article-layout { grid-template-columns: 1fr; }
  .grid.cols-3, .grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .toc, .sidebar-box { position: static; }
  h1 { font-size: 2.35rem; }
}

@media (max-width: 760px) {
  .site-header { align-items: flex-start; }
  .menu-toggle {
    display: inline-flex;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: var(--panel);
    color: var(--text);
    font-weight: 800;
  }
  .main-nav {
    display: none;
    position: absolute;
    left: 18px;
    right: 18px;
    top: 72px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #081219;
    box-shadow: var(--shadow);
  }
  .main-nav.open { display: grid; grid-template-columns: 1fr 1fr; }
  .hero { min-height: 0; padding-top: 28px; }
  h1 { font-size: 2rem; }
  h2 { font-size: 1.55rem; }
  .grid.cols-2, .grid.cols-3, .grid.cols-4, .stats { grid-template-columns: 1fr; }
  .site-footer { grid-template-columns: 1fr; }
  .site-footer nav { justify-content: flex-start; }
  table { font-size: .92rem; }
  th, td { padding: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
