/* TownCompute landing page — one stylesheet, no framework. */

:root {
  color-scheme: light dark;
  --bg: #f5f7fb;
  --bg-alt: #eef2f8;
  --surface: #ffffff;
  --ink: #121b2c;
  --muted: #48536a;
  --faint: #576077;
  --line: #dbe2ed;
  --accent: #1a4ed1;
  --accent-strong: #143fae;
  --accent-soft: #e8efff;
  --navy: #0f1b33;
  --on-navy: #f2f6ff;
  --on-navy-muted: #c3cfe6;
  --shadow: 0 18px 40px -18px rgba(15, 27, 51, .28);
  --radius: 14px;
  --wrap: 1160px;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1220;
    --bg-alt: #0f1729;
    --surface: #121b2c;
    --ink: #e9eef7;
    --muted: #b3bdd0;
    --faint: #93a0b8;
    --line: #263248;
    --accent: #9cc0ff;
    --accent-strong: #bcd4ff;
    --accent-soft: #1b2a47;
    --navy: #060c17;
    --on-navy: #eef3fc;
    --on-navy-muted: #b8c5de;
    --shadow: 0 18px 40px -18px rgba(0, 0, 0, .7);
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; display: block; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3 { line-height: 1.18; letter-spacing: -.018em; margin: 0; font-weight: 700; }
p { margin: 0; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-strong); }

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

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

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 20;
  background: var(--surface);
  color: var(--ink);
  padding: 10px 16px;
  border-radius: 8px;
  border: 1px solid var(--line);
}
.skip:focus { top: 12px; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 66px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -.01em;
  flex: 0 0 auto;
}
.brand-mark { width: 30px; height: 30px; color: var(--ink); }
.brand-name { font-size: 1.06rem; }
.site-nav {
  display: flex;
  gap: 22px;
  margin-left: auto;
  flex-wrap: wrap;
}
.site-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: .95rem;
  font-weight: 500;
  padding: 6px 2px;
}
.site-nav a:hover { color: var(--ink); }
.header-cta { margin-left: 8px; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 22px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background-color .15s ease, border-color .15s ease, transform .15s ease;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-strong); color: #fff; }
@media (prefers-color-scheme: dark) {
  .btn-primary { color: #0a1220; }
  .btn-primary:hover { color: #0a1220; }
}
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--ink); }
.btn-sm { padding: 9px 16px; font-size: .92rem; border-radius: 9px; }
.btn-light { background: #fff; color: #0f1b33; }
.btn-light:hover { background: #e9efff; color: #0f1b33; }

/* ---------- Hero ---------- */

.hero {
  padding: 72px 0 92px;
  background:
    radial-gradient(900px 420px at 82% -10%, color-mix(in srgb, var(--accent) 12%, transparent), transparent 70%),
    var(--bg);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.02fr .98fr;
  gap: 52px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .86rem;
  font-weight: 600;
  letter-spacing: .02em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 18px;
}
.dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 18%, transparent);
}
.hero h1 {
  font-size: clamp(2.1rem, 4.4vw, 3.5rem);
  max-width: 15ch;
}
.lede {
  margin-top: 20px;
  font-size: clamp(1.02rem, 1.35vw, 1.16rem);
  color: var(--muted);
  max-width: 46ch;
}
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}
.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin-top: 28px;
  color: var(--muted);
  font-size: .92rem;
}
.hero-points li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.hero-points li::before {
  content: "";
  width: 16px; height: 16px;
  flex: 0 0 auto;
  background-color: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 1.8a8.2 8.2 0 1 0 0 16.4 8.2 8.2 0 0 0 0-16.4zm3.7 6.1-4.4 5a.9.9 0 0 1-1.36.03L5.5 10.3l1.28-1.28 1.7 1.7 3.72-4.2z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 1.8a8.2 8.2 0 1 0 0 16.4 8.2 8.2 0 0 0 0-16.4zm3.7 6.1-4.4 5a.9.9 0 0 1-1.36.03L5.5 10.3l1.28-1.28 1.7 1.7 3.72-4.2z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.device {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.device-bar {
  display: flex;
  gap: 7px;
  align-items: center;
  padding: 10px 14px;
  background: var(--bg-alt);
  border-bottom: 1px solid var(--line);
}
.device-bar span {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--line);
}
.device img { width: 100%; height: auto; }

/* ---------- Sections ---------- */

.section { padding: 96px 0; }
.section.alt { background: var(--bg-alt); }

.section-head {
  max-width: 720px;
  margin: 0 auto 46px;
  text-align: center;
}
.section-head.left { margin-inline: 0; text-align: left; }
.section-head h2 {
  font-size: clamp(1.6rem, 2.6vw, 2.15rem);
}
.section-sub {
  margin-top: 14px;
  color: var(--muted);
  font-size: 1.04rem;
}
.narrow { max-width: 820px; }

/* ---------- Cards ---------- */

.cards {
  display: grid;
  gap: 20px;
}
.cards.four { grid-template-columns: repeat(4, 1fr); }
.cards.three { grid-template-columns: repeat(3, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 24px;
}
.card h3 { font-size: 1.06rem; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: .95rem; }

.icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  border-radius: 11px;
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: 16px;
}
.icon svg { width: 24px; height: 24px; }

/* ---------- How it works ---------- */

.how-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.steps {
  display: grid;
  gap: 26px;
  counter-reset: step;
}
.steps li { display: flex; gap: 18px; align-items: flex-start; }
.step-n {
  flex: 0 0 auto;
  width: 34px; height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: .95rem;
  font-variant-numeric: tabular-nums;
}
@media (prefers-color-scheme: dark) {
  .step-n { color: #0a1220; }
}
.steps h3 { font-size: 1.05rem; margin-bottom: 4px; }
.steps p { color: var(--muted); font-size: .95rem; }

.diagram {
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
}
.diagram svg { width: 100%; height: auto; }
.d-box { fill: var(--surface); stroke: var(--line); stroke-width: 1.5; }
.d-box.d-accent { fill: var(--accent-soft); stroke: var(--accent); }
.d-box.d-muted { stroke-dasharray: 5 4; }
.d-title { fill: var(--ink); font-size: 15px; font-weight: 650; font-family: inherit; }
.d-sub { fill: var(--muted); font-size: 12.5px; font-family: inherit; }
.d-line { stroke: var(--faint); stroke-width: 1.6; }
.d-line.d-dashed { stroke-dasharray: 5 5; }
.d-arrow { fill: var(--faint); }

/* ---------- Trust ---------- */

.trust-grid {
  display: grid;
  grid-template-columns: 1.55fr .85fr;
  gap: 56px;
  align-items: start;
}
.checklist {
  display: grid;
  gap: 16px;
  color: var(--muted);
  font-size: .98rem;
}
.checklist li {
  position: relative;
  padding-left: 30px;
}
.checklist li::before {
  content: "";
  position: absolute;
  left: 0; top: .35em;
  width: 18px; height: 18px;
  background-color: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 1.8a8.2 8.2 0 1 0 0 16.4 8.2 8.2 0 0 0 0-16.4zm3.7 6.1-4.4 5a.9.9 0 0 1-1.36.03L5.5 10.3l1.28-1.28 1.7 1.7 3.72-4.2z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 1.8a8.2 8.2 0 1 0 0 16.4 8.2 8.2 0 0 0 0-16.4zm3.7 6.1-4.4 5a.9.9 0 0 1-1.36.03L5.5 10.3l1.28-1.28 1.7 1.7 3.72-4.2z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.checklist strong { color: var(--ink); }

/* ---------- Readiness ---------- */

.readiness {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.readiness-col {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 28px;
}
.readiness-col h3 { font-size: 1.12rem; margin-bottom: 18px; }
.next-list {
  display: grid;
  gap: 16px;
  color: var(--muted);
  font-size: .98rem;
}
.next-list li {
  position: relative;
  padding-left: 30px;
}
.next-list li::before {
  content: "";
  position: absolute;
  left: 2px; top: .72em;
  width: 14px; height: 2px;
  background: var(--faint);
  border-radius: 1px;
}

.quote-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 28px;
  position: sticky;
  top: 90px;
}
.quote-mark { width: 34px; height: 34px; color: var(--accent); opacity: .8; margin-bottom: 14px; }
.quote-card p { font-size: 1.06rem; color: var(--ink); line-height: 1.5; }
.quote-attr { margin-top: 14px; font-size: .86rem !important; color: var(--faint) !important; }

/* ---------- Gallery ---------- */

.gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px 24px;
}
.gallery figure { margin: 0; }
.gallery img {
  border-radius: 12px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  width: 100%;
}
.gallery figcaption {
  margin-top: 12px;
  color: var(--muted);
  font-size: .93rem;
}

/* ---------- FAQ ---------- */

.faq { display: grid; gap: 0; border-top: 1px solid var(--line); }
.faq details {
  border-bottom: 1px solid var(--line);
  padding: 4px 0;
}
.faq summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 20px 2px;
  font-weight: 600;
  font-size: 1.03rem;
  color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  flex: 0 0 auto;
  font-size: 1.4rem;
  line-height: 1;
  color: var(--accent);
  transition: transform .18s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p {
  color: var(--muted);
  font-size: .98rem;
  padding: 0 2px 22px;
  max-width: 68ch;
}

/* ---------- CTA band ---------- */

.cta-band {
  background: var(--navy);
  color: var(--on-navy);
  padding: 72px 0;
}
.cta-band-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 36px;
  flex-wrap: wrap;
}
.cta-band h2 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
.cta-band p { color: var(--on-navy-muted); margin-top: 10px; max-width: 52ch; }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  padding: 56px 0 28px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
}
.site-footer .brand { color: var(--ink); }
.footer-note {
  margin-top: 14px;
  color: var(--muted);
  font-size: .94rem;
  max-width: 44ch;
}
.footer-h {
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--faint);
  font-weight: 650;
  margin-bottom: 14px;
}
.footer-grid ul { display: grid; gap: 9px; }
.footer-grid ul a {
  color: var(--muted);
  text-decoration: none;
  font-size: .95rem;
}
.footer-grid ul a:hover { color: var(--ink); text-decoration: underline; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 44px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: .88rem;
}

/* ---------- Responsive ---------- */

@media (max-width: 1020px) {
  .cards.four { grid-template-columns: repeat(2, 1fr); }
  .cards.three { grid-template-columns: repeat(2, 1fr); }
  .hero-grid { gap: 36px; }
  .how-grid, .trust-grid { gap: 36px; }
}

@media (max-width: 900px) {
  .site-nav { display: none; }
  .header-cta { margin-left: auto; }
  .hero { padding: 56px 0 72px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-copy { max-width: 640px; }
  .how-grid, .trust-grid { grid-template-columns: 1fr; }
  .readiness { grid-template-columns: 1fr; }
  .quote-card { position: static; }
  .diagram { max-width: 620px; }
}

@media (max-width: 720px) {
  body { font-size: 16px; }
  .wrap { padding-inline: 20px; }
  .section { padding: 68px 0; }
  .section-head { margin-bottom: 34px; }
  .cards.four, .cards.three { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > div:first-child { grid-column: 1 / -1; }
  .cta-band { padding: 56px 0; }
}

@media (max-width: 400px) {
  .wrap { padding-inline: 16px; }
  .header-inner { min-height: 60px; gap: 12px; }
  .btn { padding: 12px 18px; }
  .card { padding: 22px 18px; }
  .gallery figcaption { font-size: .88rem; }
}
