/* Smashing Bits — the one stylesheet (ADR-0006).
   Palette is the monochrome ramp extracted from the logo illustration.
   Any hex not in the ramp is a bug. Dark mode is prefers-color-scheme only. */

:root {
  --paper: #FCFCFC;
  --ink: #2C2E25;
  --muted: #67675B;
  --border: #C7C5B8;
  --panel: #F8F7F6;
  --keycap-side: #878679;
  --keycap-face: #C7C5B8;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #212319;
    --ink: #F8F7F6;
    --muted: #A7A69C;
    --border: #67675B;
    --panel: #2C2E25;
    --keycap-side: #67675B;
    --keycap-face: #2C2E25;
  }
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
}

a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

/* ---- Homepage: one screen (ADR-0002) ---- */

.screen {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  max-width: 64rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.hero {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  padding: 2rem 0;
}

.hero h1 {
  font-size: clamp(2.25rem, 5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.hero .tagline {
  font-size: 1.3rem;
  color: var(--muted);
  margin-top: 0.75rem;
}

.hero .services {
  margin-top: 1.5rem;
  font-size: 1.05rem;
  max-width: 32rem;
}

.hero-art img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
}

/* The illustration has a light background baked in; in dark mode it sits on
   a light panel, framed as artwork rather than re-drawn (ADR-0006). */
@media (prefers-color-scheme: dark) {
  .hero-art img {
    background: #FCFCFC;
    border: 1px solid var(--border);
  }
}

.app-card {
  margin-top: 2.5rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  max-width: 28rem;
  background: var(--panel);
}

.app-icon {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
}

/* Inline keycap icons theme through the cascade; favicon.svg alone carries
   its own copy of these colors because it is fetched as a standalone document. */
.app-icon .k-side { fill: var(--keycap-side); }
.app-icon .k-face { fill: var(--keycap-face); }
.app-icon .k-label { fill: var(--ink); }

.app-card p { color: var(--muted); font-size: 0.95rem; }

.app-links { font-size: 0.9rem; margin-top: 0.25rem; }
.app-links .dot { color: var(--border); margin: 0 0.4rem; }

/* ---- Footer (homepage and policy pages share it) ---- */

footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0 2rem;
  font-size: 0.85rem;
  color: var(--muted);
}

footer .legal { margin-bottom: 0.35rem; }
footer a { margin-right: 1rem; }

/* ---- Policy pages and 404: minimal chrome ---- */

.page {
  max-width: 42rem;
  margin: 0 auto;
  padding: 0 1.5rem;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}

.page main { flex: 1; }

.mark {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1.5rem 0;
  text-decoration: none;
  font-weight: 700;
}

.mark img { width: 28px; height: 28px; }

.page h1 { font-size: 1.75rem; letter-spacing: -0.02em; margin: 1.5rem 0 0.5rem; }
.page h2 { font-size: 1.15rem; margin: 2rem 0 0.5rem; }
.page p, .page ul { margin-bottom: 1rem; }
.page ul { padding-left: 1.25rem; }
.page .updated { color: var(--muted); font-size: 0.9rem; }

/* 404 */
.smashed { text-align: center; padding: 5rem 0; }
.smashed h1 { font-size: 2rem; margin-bottom: 0.5rem; }
.smashed p { color: var(--muted); }

/* ---- Small screens: hero stacks, art shrinks ---- */

@media (max-width: 700px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 3rem 0 2rem;
  }
  .hero-art { order: -1; }
  .hero-art img { max-width: 260px; margin: 0 auto; }
}
