/* Reset + shared primitives */

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

/* attribute must beat any component display rule */
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

/* keep sub-pixel rounding from producing a scrollbar */
html { overflow-x: clip; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -.02em;
}

a { color: inherit; text-decoration: none; }
img, svg, video { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; }

/* --- focus: always visible, never clipped --- */
:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
  border-radius: 2px;
}
.on-red :focus-visible { outline-color: var(--ink); }

/* --- shared layout --- */
.shell {
  width: 100%;
  max-width: var(--page);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { width: 100%; }
.section--dark { background: var(--ink); }
.section--bone { background: var(--bone); color: var(--ink-soft); }
.section--red { background: var(--red); color: var(--ink); }
.section--surface { background: var(--surface); }

.eyebrow {
  font-family: var(--font-display);
  font-size: 11px;
  line-height: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--red-text);
}

.rule { height: 1px; margin: 0; background: var(--line-dark); border: 0; flex: none; }
.section--bone .rule { background: var(--line-light); }

/* --- buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-8);
  padding: 12px 24px;
  border-radius: var(--r-8);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 800;
  line-height: 18.2px;
  white-space: nowrap;
  cursor: pointer;
  transition: background var(--t), color var(--t), transform var(--t-fast), box-shadow var(--t);
}
.btn--primary { background: var(--red); color: var(--white); }
.btn--primary:hover { background: var(--red-dark); box-shadow: var(--shadow-red); }
.btn--primary:active { transform: translateY(1px); }
.btn--ghost { background: transparent; color: var(--white); box-shadow: inset 0 0 0 1px var(--line-dark); }
.btn--ghost:hover { box-shadow: inset 0 0 0 1px var(--red); color: var(--red); }
.btn--ink { background: var(--ink); color: var(--white); }
.btn--white { background: var(--white); color: var(--ink); }
.btn--outline { background: transparent; color: var(--ink-soft); box-shadow: inset 0 0 0 1px var(--line-light); }
.btn--outline-ink { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.btn--white:hover, .btn--outline:hover, .btn--outline-ink:hover { background: var(--bone); }
.btn--ink:hover { background: var(--surface); }
.btn--block { width: 100%; }

/* --- link with arrow --- */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 800;
  line-height: 17px;
  color: var(--red-text);
  transition: gap var(--t-fast), color var(--t);
}
.link-arrow:hover { gap: 10px; }
.link-arrow::after { content: '→'; }

/* --- tap targets (WCAG 2.2 AA 2.5.8) --- */
.tap::after {
  content: '';
  position: absolute;
  inset: 50% 50% 50% 50%;
  width: 44px;
  height: 44px;
  transform: translate(-50%, -50%);
}

/* --- utilities --- */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip-link {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translate(-50%, -120%);
  z-index: 200;
  padding: 12px 24px;
  background: var(--red);
  color: var(--white);
  font-weight: 800;
  border-radius: 0 0 var(--r-8) var(--r-8);
  transition: transform var(--t);
}
.skip-link:focus { transform: translate(-50%, 0); }

.no-scroll { overflow: hidden; }

/* --- scroll reveal: only when scripting is on, so no-JS never hides content --- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .5s ease, transform .5s ease;
}
.js [data-reveal].is-in { opacity: 1; transform: none; }

/* touch height for buttons */
@media (max-width: 1199px) {
  .btn { min-height: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
}
