/* ============================================================
   C++AntiVirus — site theme
   Tokens pulled directly from the app itself:
     window bg      rgb(20,20,23)   -> --bg
     panel / child  rgb(28,28,32)   -> --panel
     accent title   rgb(102,191,255)-> --blue   (0.4, 0.75, 1.0 in ImGui)
     malicious      rgb(230,64,64)  -> --red    (0.9, 0.25, 0.25)
     suspicious     rgb(242,166,38) -> --orange (0.95, 0.65, 0.15)
     clean/harmless rgb(102,217,102)-> --green  (0.4, 0.85, 0.4)
     WindowRounding 6px, FrameRounding 4px carried over as --r-lg/--r-sm
   ============================================================ */

:root {
  --bg: #141417;
  --bg-raised: #1a1a1e;
  --panel: #1c1c20;
  --panel-2: #202024;
  --border: #2c2c33;
  --border-soft: #232328;

  --text: #e8e8ea;
  --text-dim: #8b8b93;
  --text-faint: #5c5c64;

  --blue: #66bfff;
  --blue-dim: #3d7ba6;
  --red: #e64040;
  --red-dim: #7a2d2d;
  --orange: #f2a626;
  --green: #66d966;

  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --sans: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --r-lg: 8px;
  --r-sm: 5px;

  --wrap: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 28px;
}

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
  border-radius: 3px;
}

/* faint CRT-style scanline overlay, purely atmospheric */
.scanline {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.012) 0px,
    rgba(255, 255, 255, 0.012) 1px,
    transparent 1px,
    transparent 3px
  );
  opacity: 0.5;
}

/* ===================== HEADER ===================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(20, 20, 23, 0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border-soft);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  color: var(--text);
  letter-spacing: 0.01em;
}

.brand-mark {
  color: var(--blue);
  font-weight: 700;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14px;
}

.site-nav a {
  text-decoration: none;
  color: var(--text-dim);
  transition: color 0.15s ease;
}

.site-nav a:hover { color: var(--text); }

.nav-cta {
  color: var(--blue) !important;
  font-weight: 500;
}

/* ===================== BUTTONS ===================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: var(--r-sm);
  font-family: var(--sans);
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, border-color 0.15s ease, background 0.15s ease;
}

.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--blue);
  color: #0c1720;
}

.btn-primary:hover { background: #7ecaff; }

.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}

.btn-ghost:hover { border-color: var(--blue-dim); color: var(--blue); }

.btn-lg {
  padding: 14px 26px;
  font-size: 15.5px;
}

/* ===================== HERO ===================== */

.hero {
  padding: 76px 0 84px;
  border-bottom: 1px solid var(--border-soft);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.eyebrow {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--blue-dim);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 18px;
}

.hero-copy h1 {
  font-family: var(--mono);
  font-size: 42px;
  line-height: 1.18;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 20px;
}

.hero-copy h1 .accent { color: var(--blue); }

.hero-sub {
  color: var(--text-dim);
  font-size: 16.5px;
  max-width: 46ch;
  margin: 0 0 30px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.hero-note {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--text-faint);
  margin: 0;
}

/* ---- hero panel: a live recreation of the app's own results table ---- */

.hero-panel { min-width: 0; }

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.6);
}

.panel-titlebar {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px 16px;
  background: var(--bg-raised);
  border-bottom: 1px solid var(--border);
}

.panel-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 8px rgba(102, 191, 255, 0.5);
}

.panel-title-text {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--blue);
}

.panel-title-dim {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--text-faint);
}

.panel-body { padding: 14px 16px 18px; }

.scan-row-header,
.scan-row {
  display: grid;
  grid-template-columns: 1.6fr 0.6fr 0.8fr 0.7fr;
  gap: 10px;
  align-items: center;
}

.scan-row-header {
  font-family: var(--mono);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-faint);
  padding: 0 8px 8px;
  border-bottom: 1px solid var(--border-soft);
  margin-bottom: 4px;
}

.scan-rows { min-height: 176px; }

.scan-row {
  padding: 7px 8px;
  border-radius: var(--r-sm);
  font-family: var(--mono);
  font-size: 12px;
  opacity: 0;
  transform: translateY(4px);
  animation: rowIn 0.35s ease forwards;
}

.scan-row:nth-child(odd) { background: rgba(255, 255, 255, 0.015); }

@keyframes rowIn {
  to { opacity: 1; transform: translateY(0); }
}

.scan-row .col-file {
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scan-row .col-size { color: var(--text-dim); }

.scan-row .col-status { font-weight: 600; }
.status-malicious { color: var(--red); }
.status-suspicious { color: var(--orange); }
.status-clean { color: var(--green); }
.status-waiting { color: var(--text-faint); }

.col-det { color: var(--text-dim); }

.progress-track {
  height: 5px;
  border-radius: 3px;
  background: var(--panel-2);
  overflow: hidden;
  margin-top: 14px;
}

.progress-fill {
  height: 100%;
  width: 8%;
  background: var(--blue);
  border-radius: 3px;
  transition: width 0.5s ease;
}

.progress-label {
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--text-faint);
  margin: 8px 0 0;
}

/* ===================== SECTIONS ===================== */

.section { padding: 84px 0; }

.section-alt { background: var(--bg-raised); border-top: 1px solid var(--border-soft); border-bottom: 1px solid var(--border-soft); }

.section-title {
  display: flex;
  align-items: baseline;
  gap: 12px;
  font-family: var(--mono);
  font-size: 26px;
  font-weight: 700;
  margin: 0 0 12px;
}

.tag {
  font-size: 13px;
  color: var(--blue-dim);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  padding: 2px 7px;
  font-weight: 600;
}

.section-lead {
  color: var(--text-dim);
  font-size: 15.5px;
  max-width: 60ch;
  margin: 0 0 40px;
}

.section#features .feature-grid { margin-top: 40px; }

/* ===================== FEATURE CARDS ===================== */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.feature-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 22px 22px 24px;
  transition: border-color 0.15s ease;
}

.feature-card:hover { border-color: var(--blue-dim); }

.feature-card h3 {
  font-family: var(--mono);
  font-size: 15.5px;
  margin: 0 0 10px;
  color: var(--text);
}

.feature-card p {
  color: var(--text-dim);
  font-size: 14.5px;
  margin: 0;
}

/* ===================== SOURCE CARDS ===================== */

.source-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.source-card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px;
}

.source-badge {
  display: inline-block;
  font-family: var(--mono);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 20px;
  margin-bottom: 12px;
}

.badge-red { background: rgba(230, 64, 64, 0.14); color: var(--red); }
.badge-orange { background: rgba(242, 166, 38, 0.14); color: var(--orange); }
.badge-green { background: rgba(102, 217, 102, 0.14); color: var(--green); }

.source-card h3 {
  font-family: var(--mono);
  font-size: 16px;
  margin: 0 0 8px;
}

.source-card p {
  color: var(--text-dim);
  font-size: 14px;
  margin: 0;
}

/* ===================== DOWNLOAD ===================== */

.download-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 26px 28px;
  margin-top: 36px;
}

.download-main {
  display: flex;
  align-items: center;
  gap: 16px;
}

.download-icon {
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-sm);
  background: var(--bg-raised);
  border: 1px solid var(--border);
  color: var(--blue);
  font-family: var(--mono);
  font-weight: 700;
  font-size: 15px;
  flex-shrink: 0;
}

.download-filename {
  font-family: var(--mono);
  font-size: 16.5px;
  margin: 0 0 4px;
}

.download-meta {
  color: var(--text-dim);
  font-size: 13.5px;
  margin: 0;
}

.download-details {
  margin-top: 22px;
  padding: 16px 20px;
  background: var(--bg-raised);
  border: 1px solid var(--border-soft);
  border-radius: var(--r-lg);
}

.hash-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.hash-label {
  font-family: var(--mono);
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-faint);
  flex-shrink: 0;
}

.hash-value {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--text);
  word-break: break-all;
  background: none;
}

.hash-hint {
  margin: 10px 0 0;
  color: var(--text-faint);
  font-size: 12.5px;
}

.install-steps {
  margin-top: 28px;
  padding: 22px 24px;
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
}

.install-steps-label {
  font-family: var(--mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--blue-dim);
  margin: 0 0 14px;
}

.install-steps ol {
  margin: 0 0 18px;
  padding-left: 20px;
  color: var(--text-dim);
  font-size: 14.5px;
}

.install-steps li { margin-bottom: 8px; }
.install-steps li::marker { color: var(--text-faint); font-family: var(--mono); }

.install-note {
  margin: 0;
  color: var(--text-faint);
  font-size: 13.5px;
  border-top: 1px solid var(--border-soft);
  padding-top: 16px;
}

.install-note em { color: var(--text-dim); font-style: normal; }

/* ===================== FOOTER ===================== */

.site-footer {
  border-top: 1px solid var(--border-soft);
  padding: 46px 0 56px;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  flex-wrap: wrap;
}

.footer-credit-label {
  font-family: var(--mono);
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-faint);
  margin: 0 0 6px;
}

.footer-credit-name {
  font-family: var(--mono);
  font-size: 20px;
  font-weight: 700;
  color: var(--blue);
  margin: 0;
}

.footer-fine {
  max-width: 46ch;
  color: var(--text-faint);
  font-size: 12.5px;
}

.footer-fine p { margin: 0 0 8px; }
.footer-fine p:last-child { margin-bottom: 0; }

/* ===================== RESPONSIVE ===================== */

@media (max-width: 880px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-copy h1 { font-size: 34px; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .source-grid { grid-template-columns: repeat(2, 1fr); }
  .site-nav { gap: 18px; }
}

@media (max-width: 560px) {
  .wrap { padding: 0 18px; }
  .hero { padding: 52px 0 60px; }
  .hero-copy h1 { font-size: 28px; }
  .feature-grid { grid-template-columns: 1fr; }
  .source-grid { grid-template-columns: 1fr; }
  .scan-row-header span:nth-child(3),
  .scan-row .col-status { display: none; }
  .scan-row-header,
  .scan-row { grid-template-columns: 1.6fr 0.6fr 0.7fr; }
  .download-card { flex-direction: column; align-items: flex-start; }
  .footer-inner { flex-direction: column; }
}
