/* =============================================================
   BAWE — base
   Reset, document defaults, typography, layout containers.
   Depends on tokens.css. Load second.
   ============================================================= */

/* ---------- Reset ---------- */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + var(--space-4));
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--bawe-ink-800);
  background: var(--bawe-paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-synthesis-weight: none;
}

h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd { margin: 0; }
ul, ol { margin: 0; padding: 0; }
li { list-style: none; }

img, svg, video {
  display: block;
  max-width: 100%;
}
img { height: auto; }

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

/* ---------- Document typography ---------- */

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--bawe-ink-900);
  text-wrap: balance;
}

p { text-wrap: pretty; }

a {
  color: var(--bawe-blue-600);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  transition: color var(--dur-fast) var(--ease);
}
a:hover { color: var(--bawe-blue-500); }

strong, b { font-weight: 700; }

/* Never italic — Inter italics do not fit the voice. */
em, i { font-style: normal; }

/* The signature headline device: second phrase in cobalt. */
.accent { color: var(--bawe-blue-600); }
.on-dark .accent,
.section--dark .accent { color: var(--bawe-blue-500); }

/* ---------- Focus ---------- */

:focus-visible {
  outline: 2px solid var(--bawe-blue-600);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}
.section--dark :focus-visible,
.on-dark :focus-visible { outline-color: var(--bawe-blue-400); }

.skip-link {
  position: absolute;
  top: 0;
  left: var(--space-4);
  z-index: 200;
  transform: translateY(-120%);
  padding: var(--space-3) var(--space-4);
  background: var(--bawe-blue-600);
  color: #fff;
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  transition: transform var(--dur-fast) var(--ease);
}
.skip-link:focus-visible {
  transform: translateY(0);
  color: #fff;
}

/* ---------- Layout ---------- */

.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

.container--narrow { max-width: 920px; }

main { display: block; }

.section {
  padding-block: var(--section-y);
}

/* 128px between visually distinct neighbours (dark <-> light). */
.section--tall { padding-block: var(--space-24); }
@media (min-width: 1024px) {
  .section--tall { padding-block: var(--space-32); }
}

.section--dark {
  background: var(--bawe-ink-900);
  color: var(--on-dark-body);
}
.section--dark h1,
.section--dark h2,
.section--dark h3,
.section--dark h4 { color: var(--on-dark-head); }

.section--ink800 { background: var(--bawe-ink-800); }
.section--tint   { background: var(--bawe-paper-2); }

/* ---------- Section header: eyebrow + headline + lead ---------- */

.section-head { max-width: 62ch; }

.section-head .eyebrow { display: block; margin-bottom: var(--space-4); }
.section--dark .section-head .eyebrow { color: var(--bawe-blue-400); }

.section-head .lead {
  margin-top: var(--space-6);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--bawe-steel-600);
  max-width: 58ch;
}
.section--dark .section-head .lead { color: var(--on-dark-body); }

/* ---------- Signature device: blue accent marker ---------- */

.marker::before {
  content: "";
  display: block;
  width: var(--marker-w);
  height: var(--marker-h);
  margin-bottom: var(--space-3);
  background: var(--bawe-blue-600);
}
.section--dark .marker::before { background: var(--bawe-blue-500); }

/* ---------- Signature device: house-glyph bullet ---------- */

.rule-list { display: grid; gap: var(--space-3); }

.rule-list li {
  position: relative;
  padding-left: var(--space-6);
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--bawe-steel-600);
}
.rule-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.7em;
  width: var(--bullet-w);
  height: var(--bullet-h);
  background: var(--bawe-blue-600);
}
.section--dark .rule-list li { color: var(--on-dark-body); }
.section--dark .rule-list li::before { background: var(--bawe-blue-500); }

/* ---------- Signature device: the footer rule ---------- */
/* Bolt+house glyph, then a 2px rule fading cobalt -> steel. */

.footer-rule {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}
.footer-rule__glyph {
  flex: none;
  width: 26px;
  height: 21px;
  color: var(--bawe-blue-600);
}
.section--dark .footer-rule__glyph,
.site-footer .footer-rule__glyph { color: var(--bawe-blue-500); }
.footer-rule__line {
  flex: 1 1 auto;
  height: 2px;
  background: linear-gradient(90deg, var(--bawe-blue-600) 0%, var(--bawe-steel-200) 100%);
}
.section--dark .footer-rule__line,
.site-footer .footer-rule__line {
  background: linear-gradient(90deg, var(--bawe-blue-500) 0%, rgba(255, 255, 255, 0.12) 100%);
}

/* ---------- Dividers ---------- */

.hr {
  height: 1px;
  border: 0;
  background: var(--bawe-steel-200);
}
.section--dark .hr { background: var(--on-dark-rule); }
