/* TekHow website. One stylesheet; colours only through the tokens below (light by default, dark from
   prefers-color-scheme). System fonts only: nothing to download. Touch targets are at least 48 px. */

/* Colours follow bits.tekhow.net (the Gitea theme, generated from the logo): the logo gradient #fad961 ->
   #f76b1c, Gitea's greys, and the logo's neutrals for the mark (#6f6f6f light, #aeaeae dark). Text and
   button colours use darker (light) or lighter (dark) steps of the same orange ramp for WCAG AA. */
:root {
  --bg: #f6f7fa;
  --surface: #ffffff;
  --alt: #f1f3f5;
  --ink: #181c21;
  --muted: #5b6167;
  --line: #d0d7de;
  --accent: #bd4907;
  --on-accent: #ffffff;
  --accent-hover: #a43f06;
  --link: #a43f06;
  --status-bg: #fee8dc;
  --status-ink: #732c04;
  --todo-bg: #fef6d8;
  --todo-ink: #5c4400;
  --todo-line: #c9971a;
  --banner-bg: #181c21;
  --banner-ink: #f6f7fa;
  --brand-from: #fad961;
  --brand-to: #f76b1c;
  --mark-grey: #6f6f6f;
  --focus: #1b5fd1;
  --shadow: 0 1px 2px rgba(24, 28, 33, 0.06), 0 6px 18px rgba(24, 28, 33, 0.06);

  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --step--1: 0.9375rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: clamp(1.5rem, 4.5vw, 1.875rem);
  --step-3: clamp(2rem, 8vw, 3.25rem);

  --gutter: 16px;
  --measure: 62ch;
  --radius: 14px;
  --tap: 48px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1e1f20;
    --surface: #18191b;
    --alt: #1b1c1e;
    --ink: #d2d4d8;
    --muted: #969aa1;
    --line: #3f4248;
    --accent: #f76b1c;
    --on-accent: #1d0b01;
    --accent-hover: #f98a4c;
    --link: #fa9a64;
    --status-bg: #401802;
    --status-ink: #fcc9ac;
    --todo-bg: #33290f;
    --todo-ink: #f6dc9a;
    --todo-line: #a9842c;
    --banner-bg: #d2d4d8;
    --banner-ink: #1e1f20;
    --mark-grey: #aeaeae;
    --focus: #8ab4ff;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.6;
}
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 0.6em; }
h1 { font-size: var(--step-3); letter-spacing: -0.02em; }
h2 { font-size: var(--step-2); letter-spacing: -0.01em; }
h3 { font-size: var(--step-1); }
p { margin: 0 0 1em; }
a { color: var(--link); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
main:focus { outline: none; }
[id] { scroll-margin-top: 1rem; }

.wrap { width: 100%; max-width: 68rem; margin-inline: auto; padding-inline: var(--gutter); }
.prose { max-width: var(--measure); }

.skip-link {
  position: absolute; inset-inline-start: var(--gutter); top: -4rem; z-index: 10;
  display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 1rem;
  background: var(--accent); color: var(--on-accent); border-radius: 8px;
}
.skip-link:focus { top: 0.5rem; }

.draft-banner { margin: 0; padding: 0.5rem var(--gutter); background: var(--banner-bg); color: var(--banner-ink); font-size: var(--step--1); text-align: center; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.header-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 1rem; padding-block: 0.25rem; }
/* The mark is about 1.4x the wordmark's font size (34 px beside 24 px text; 30 px beside 21.6 px on phones). */
.brand { display: inline-flex; align-items: center; gap: 0.55rem; min-height: var(--tap); color: var(--ink); text-decoration: none; font-weight: 700; font-size: 1.5rem; letter-spacing: -0.01em; line-height: 1; }
.brand-mark { flex: none; width: 34px; height: 34px; color: var(--mark-grey); }
.site-nav ul { display: flex; flex-wrap: wrap; gap: 0 0.25rem; margin: 0 -0.75rem; padding: 0; list-style: none; }
.site-nav a { display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 0.75rem; color: var(--ink); text-decoration: none; font-weight: 600; }
.site-nav a:hover { color: var(--link); text-decoration: underline; }

/* Buttons */
.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: var(--tap); padding: 0 1.4rem;
  background: var(--accent); color: var(--on-accent); border-radius: 999px; font-weight: 700; text-decoration: none;
}
.button:hover { background: var(--accent-hover); }
.button-quiet { background: transparent; color: var(--link); border: 2px solid currentColor; }
.button-quiet:hover { background: var(--alt); }

/* Hero */
.hero { padding-block: clamp(2.5rem, 9vw, 5.5rem) clamp(2rem, 6vw, 3.5rem); }
.hero h1 { max-width: 20ch; text-wrap: balance; }
.hero h1::after { content: ""; display: block; width: 3.5rem; height: 6px; margin-top: 0.9rem; border-radius: 3px; background: linear-gradient(90deg, var(--brand-from), var(--brand-to)); }
.lead { max-width: 46ch; font-size: var(--step-1); color: var(--muted); }

/* Sections */
.section { padding-block: clamp(2rem, 7vw, 4rem); }
.section-alt { background: var(--alt); border-block: 1px solid var(--line); }

.values { display: grid; gap: 1rem; margin: 1.5rem 0 0; padding: 0; list-style: none; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); }
.value { padding: 1.25rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.value h3 { color: var(--link); }
.value p { margin: 0; color: var(--muted); }

/* Product cards (data/products.json) */
.products { display: grid; gap: 1.25rem; margin: 1.5rem 0 0; padding: 0; list-style: none; grid-template-columns: repeat(auto-fill, minmax(min(100%, 22rem), 1fr)); }
.product {
  display: flex; flex-direction: column; gap: 0.9rem; padding: 1.25rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
}
.product-head { display: flex; align-items: center; gap: 1rem; }
.product-icon { flex: none; width: 72px; height: 72px; border-radius: 16px; }
.product h3 { margin: 0 0 0.3rem; }
.product-status { display: inline-block; margin: 0; padding: 0.15rem 0.65rem; border-radius: 999px; background: var(--status-bg); color: var(--status-ink); font-size: var(--step--1); font-weight: 600; line-height: 1.45; }
.product-summary { margin: 0; color: var(--muted); }
.product .button { align-self: flex-start; margin-top: auto; text-align: center; }

/* Contact placeholder */
.todo-note { max-width: var(--measure); padding: 0.75rem 1rem; background: var(--todo-bg); color: var(--todo-ink); border: 2px dashed var(--todo-line); border-radius: 10px; font-size: var(--step--1); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); background: var(--surface); color: var(--muted); font-size: var(--step--1); }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 1.5rem; padding-block: 0.5rem; }
.footer-inner p { margin: 0; }
.footer-links { display: flex; flex-wrap: wrap; gap: 0 0.5rem; margin: 0 -0.6rem; padding: 0; list-style: none; }
.footer-links a { display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 0.6rem; }

@media (max-width: 30rem) {
  .header-inner { flex-direction: column; align-items: flex-start; }
  .brand { font-size: 1.35rem; }
  .brand-mark { width: 30px; height: 30px; }
}
