/* TETROFIT site styles. Shared by index.html and products.html.
   Look: clean and minimal, full-width dark hero, light product section, pill buttons. */
:root {
  --bg: #0b0c0e;
  --bg-soft: #f4f4f4;
  --ink: #171a20;
  --ink-soft: #5c5e62;
  --ink-on-dark: #f4f4f4;
  --muted-on-dark: #a3a6ab;
  --line: #d0d1d2;
  --accent: #3e6ae1;
  --display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Barlow", system-ui, -apple-system, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--ink-on-dark);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img { max-width: 100%; display: block; }

/* ---------- Top nav ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: calc(env(safe-area-inset-top, 0px) + 14px) 20px 14px;
  background: rgba(11, 12, 14, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.nav-logo { width: 150px; height: auto; }
.nav-links { display: flex; align-items: center; gap: 22px; font-size: 14px; font-weight: 500; }
.nav-links a { text-decoration: none; opacity: 0.9; }
.nav-links a:hover { opacity: 1; text-decoration: underline; text-underline-offset: 4px; }
.nav-links a[aria-current="page"] { text-decoration: underline; text-underline-offset: 4px; }

/* ---------- Pill buttons ---------- */
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 22px;
  border-radius: 999px;
  font: 500 14px/1 var(--body);
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}
.pill-light { background: #fff; color: #171a20; }
.pill-light:hover { background: #e8e8e8; }
.pill-dark { background: #171a20; color: #fff; }
.pill-dark:hover { background: #393c41; }
.pill-outline-light { background: transparent; color: #fff; border-color: #fff; }
.pill-outline-light:hover { background: rgba(255, 255, 255, 0.08); }
.pill-outline { background: transparent; color: var(--ink); border-color: var(--ink); }
.pill-outline:hover { background: rgba(23, 26, 32, 0.06); }
.pill:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ---------- Hero (home) ---------- */
.hero {
  position: relative;
  min-height: 62vh;
  min-height: 62svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 120px 20px 72px;
  background: radial-gradient(ellipse at 50% 30%, #1d2026 0%, var(--bg) 70%);
}
.hero-logo { width: min(520px, 80vw); height: auto; }
.hero-copy { display: flex; flex-direction: column; align-items: center; gap: 14px; margin-top: 28px; }
.hero-eyebrow {
  margin: 0;
  font: 500 13px/1 var(--mono);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted-on-dark);
}
.hero-headline {
  margin: 0;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(34px, 6vw, 56px);
  line-height: 1;
  text-wrap: balance;
}
.hero-sub { margin: 0; color: var(--muted-on-dark); font-size: 17px; max-width: 44ch; }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 8px; }

/* ---------- Page header (products page) ---------- */
.page-head {
  padding: 140px 20px 48px;
  background: radial-gradient(ellipse at 50% 0%, #1d2026 0%, var(--bg) 75%);
}

/* ---------- Sections ---------- */
section.block { padding: 88px 20px; }
.inner { max-width: 1100px; margin: 0 auto; }
.light { background: var(--bg-soft); color: var(--ink); }
.light .eyebrow { color: var(--ink-soft); }
.eyebrow {
  margin: 0 0 12px;
  font: 500 12px/1.2 var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted-on-dark);
}
.section-title {
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.02;
  text-wrap: balance;
}
.section-lede { margin: 16px 0 0; max-width: 56ch; color: var(--ink-soft); font-size: 17px; }

/* ---------- Product cards ---------- */
.cards {
  margin-top: 48px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr));
  gap: 20px;
}
.card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: #fff;
  padding: 32px;
  min-width: 0;
}
.card-thumb {
  aspect-ratio: 16 / 10;
  background: linear-gradient(160deg, #e9eaec, #d5d7da);
  display: grid;
  place-items: center;
  color: #6b6e74;
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.card h3 {
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: 30px;
  line-height: 1.05;
  text-wrap: balance;
}
.card p { margin: 0; color: var(--ink-soft); }
.card-foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 8px;
}
.status-tag {
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 12px;
}

/* Option rows inside the PCB card */
.options { list-style: none; margin: 4px 0 0; padding: 0; border-top: 1px solid var(--line); }
.options li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.options .opt-name { font-weight: 600; color: var(--ink); }
.options .opt-desc { display: block; font-size: 14px; color: var(--ink-soft); font-weight: 400; }
.options .pill { min-height: 36px; padding: 0 16px; font-size: 13px; flex: 0 0 auto; }

/* ---------- Signup ---------- */
.signup { background: #111317; }
.signup .eyebrow { color: var(--muted-on-dark); }
.signup .section-lede { color: var(--muted-on-dark); }
form.signup-form { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px; max-width: 620px; }
.signup-form label.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.signup-form input[type="email"] {
  flex: 1 1 260px;
  min-width: 0;
  min-height: 48px;
  font: inherit;
  color: var(--ink-on-dark);
  background: #1c1f25;
  border: 1px solid #2c3038;
  border-radius: 999px;
  padding: 0 20px;
}
.signup-form input[type="email"]::placeholder { color: #7d8189; }
.signup-form input[type="email"]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.signup-form button { min-height: 48px; padding: 0 28px; }
.signup-form button:disabled { opacity: 0.6; cursor: default; }
.form-msg { margin: 14px 0 0; min-height: 1.5em; font-size: 14px; color: var(--muted-on-dark); }
.form-msg.ok { color: #8fd19e; }
.form-msg.err { color: #ff8a8a; }
.fine { margin: 16px 0 0; font-size: 12px; color: #7d8189; max-width: 60ch; }

footer { background: var(--bg); padding: 32px 20px 40px; color: var(--muted-on-dark); font-size: 12px; }
footer .inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid #22252b;
  padding-top: 20px;
}

@media (max-width: 640px) {
  .nav-links a.hide-sm { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

/* ---------- Product extras (build output) ---------- */
.price { margin: 0; font-family: var(--display); font-weight: 800; font-size: 26px; color: var(--ink); }
.opt-price { margin-left: 8px; font-family: var(--display); font-weight: 600; font-size: 18px; color: var(--ink); }
.card-photo { aspect-ratio: 16 / 10; width: 100%; object-fit: cover; background: #e9eaec; }
.muted { color: var(--ink-soft); }

/* ---------- Progress page ---------- */
.updated-note { margin: 12px 0 0; font: 500 12px/1.4 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted-on-dark); }
.progress-list { display: grid; gap: 20px; }
.progress-card { background: #fff; padding: 32px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.progress-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.progress-head h2 { margin: 0; font-family: var(--display); font-weight: 600; font-size: 30px; line-height: 1.05; text-wrap: balance; }
.progress-pct { font-family: var(--display); font-weight: 800; font-size: 34px; color: var(--ink); }
.progress-bar { height: 12px; background: #e3e4e6; border-radius: 999px; overflow: hidden; }
.progress-fill { height: 100%; background: var(--accent); border-radius: 999px; }
.milestones { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.milestones li { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink); }
.ms-status { flex: 0 0 auto; min-width: 96px; font: 500 11px/1 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; padding: 6px 8px; border-radius: 999px; text-align: center; border: 1px solid var(--line); color: var(--ink-soft); }
.ms-done { background: var(--ink); color: #fff; border-color: var(--ink); }
.ms-in_progress { color: var(--accent); border-color: var(--accent); }

/* ---------- Firmware (filled in by progress.html from the public Tetrofit repo) ---------- */
.firmware { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; background: var(--bg-soft); border-left: 3px solid var(--accent); }
.firmware-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 14px; }
.firmware-badge { font: 600 14px/1.2 var(--body); color: var(--ink); }
.firmware-date, .firmware-status { font: 400 13px/1.4 var(--mono); color: var(--ink-soft); }
.changelog summary { cursor: pointer; font: 500 13px/1.4 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink); }
.changelog-release { margin-top: 12px; }
.changelog-version { margin: 0; font: 600 13px/1.4 var(--mono); color: var(--ink-soft); }
.changelog-notes { margin: 6px 0 0; padding-left: 20px; color: var(--ink); font-size: 15px; }
.changelog-notes li { margin: 4px 0; }

/* ---------- Kit contents, ship dates, and progress sections ---------- */
.block-title { margin: 0 0 8px; font: 500 12px/1.2 var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-soft); }
.includes { border-top: 1px solid var(--line); padding-top: 12px; }
.includes ul { margin: 0; padding-left: 18px; color: var(--ink); }
.includes li { margin: 2px 0; }
.ship-date { margin: 0; font: 500 13px/1.4 var(--mono); color: var(--ink); }
.progress-section { display: flex; flex-direction: column; gap: 4px; }
.progress-section ul { margin: 0; padding-left: 18px; color: var(--ink); }
.progress-section li { margin: 4px 0; }
.progress-section.waiting { background: #fff7ee; border-left: 3px solid var(--accent); padding: 12px 14px; }
.progress-section.waiting ul { color: var(--ink); }
