@font-face {
  font-family: "DejaVu Sans Mono";
  src: url("fonts/DejaVuSansMono.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "DejaVu Sans Mono";
  src: url("fonts/DejaVuSansMono-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  /* rat-dark (default) */
  --bg: #16161d;
  --surface: #1f1f28;
  --border: #323244;
  --text: #dcd7ba;
  --muted: #a6a28c;
  --accent: #7e9cd8;
  --accent-hover: #9ab3e4;
  --accent-ink: #16161d;
  --code-bg: #111117;
  --shot-border: #38384c;
  --shot-shadow: 0 20px 54px rgba(0, 0, 0, 0.45);
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: "DejaVu Sans Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f4f1ea;
    --surface: #ebe6dc;
    --border: #cfc8ba;
    --text: #111111;
    --muted: #4b473f;
    --accent: #275394;
    --accent-hover: #1d4175;
    --accent-ink: #f4f1ea;
    --code-bg: #e2dcd0;
    --shot-border: #bfb8a9;
    --shot-shadow: 0 14px 36px rgba(22, 22, 29, 0.16);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

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

a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}

a:hover,
a:focus-visible {
  color: var(--accent-hover);
}

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

code,
kbd {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 0.1em 0.4em;
  white-space: nowrap;
}

kbd {
  font-weight: 700;
  color: var(--accent);
}

.page {
  max-width: 1040px;
  margin: 0 auto;
  padding: 3.5rem 1.5rem 4rem;
}

/* Hero */
.hero {
  text-align: center;
  margin-bottom: 4.5rem;
}

.hero-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.hero-icon {
  width: 76px;
  height: 76px;
  border-radius: 18px;
  border: 1px solid var(--border);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.3);
  display: block;
}

h1 {
  margin: 0;
  font-family: var(--font-mono);
  font-size: clamp(2.1rem, 4.5vw, 3.1rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.hero-lead {
  max-width: 40rem;
  margin: 0 auto 0.9rem;
  font-size: clamp(1.15rem, 2.2vw, 1.38rem);
  font-weight: 600;
  line-height: 1.4;
}

.hero-sub {
  max-width: 42rem;
  margin: 0 auto 2rem;
  color: var(--muted);
  font-size: 1.03rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  margin-bottom: 2.5rem;
}

.btn {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.72rem 1.3rem;
  border-radius: 9px;
  font-weight: 600;
  font-size: 0.98rem;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background-color 120ms ease, border-color 120ms ease, color 120ms ease;
}

.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: var(--accent-ink);
}

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}

.btn-secondary:hover,
.btn-secondary:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-note {
  font-size: 0.82rem;
  font-weight: 400;
  color: var(--muted);
}

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

.btn-ghost:hover,
.btn-ghost:focus-visible {
  border-color: var(--accent);
  background: var(--surface);
}

.hero-shot {
  margin: 0 auto 1.1rem;
  max-width: 924px;
}

.hero-shot img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid var(--shot-border);
  box-shadow: var(--shot-shadow);
}

.hero-meta {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.84rem;
  color: var(--muted);
}

/* Sections */
.section {
  margin-bottom: 4rem;
}

h2 {
  margin: 0 0 1.4rem;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

h3 {
  margin: 0 0 0.5rem;
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1.35;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.35rem 1.45rem;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.97rem;
}

/* Three ways */
.cards-three {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.15rem;
}

/* Six feature tiles */
.features-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.15rem;
}

.card-wide {
  grid-column: 1 / -1;
}

.card-showcase {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.6fr);
  gap: 1.5rem;
  align-items: center;
}

.showcase-copy h3 {
  font-size: 1.16rem;
}

.showcase-media {
  margin: 0;
}

.showcase-media img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 8px;
  border: 1px solid var(--shot-border);
}

.showcase-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

/* Install */
.install-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.15rem;
}

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  padding-top: 1.75rem;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
}

.footer p {
  margin: 0 0 0.5rem;
}

.footer-note {
  font-size: 0.83rem;
  opacity: 0.85;
}

/* Responsive */
@media (max-width: 820px) {
  .cards-three,
  .features-grid,
  .install-grid,
  .card-showcase {
    grid-template-columns: 1fr;
  }

  .card-wide,
  .card-showcase {
    grid-column: auto;
  }
}

@media (max-width: 520px) {
  .page {
    padding: 2.25rem 1rem 3rem;
  }

  .hero-brand {
    flex-direction: column;
    gap: 0.65rem;
  }

  .btn {
    width: 100%;
  }

  .showcase-pair {
    gap: 0.5rem;
  }
}
