/* base.css: reset, typography, layout helpers, accessibility helpers */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 1rem);
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}

/* Makes the HTML "hidden" attribute reliable even when a class sets display */
[hidden] { display: none !important; }

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

h1,
h2,
h3,
h4 {
  margin: 0 0 0.75rem;
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.02em;
  color: var(--heading);
}
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }

p { margin: 0 0 1rem; }

a { color: var(--link); text-underline-offset: 0.15em; }
a:hover { color: var(--link-hover); }

ul,
ol,
dl { margin: 0; padding: 0; }

address { font-style: normal; }

code {
  padding: 0.1em 0.35em;
  background: var(--bg-tint);
  border-radius: var(--radius-sm);
  font-family: Consolas, 'Courier New', monospace;
  font-size: 0.92em;
}

::selection { background: var(--c-cyan); color: #06121c; }

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

.icon { flex-shrink: 0; width: 1.25em; height: 1.25em; }

/* ---------- Layout helpers ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section-pad); }
.section--tint { background: var(--bg-alt); }

.section__header { max-width: 42rem; margin-bottom: var(--space-5); }
.section__intro { color: var(--text-2); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.7rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
.eyebrow::before { content: ''; width: 1.75rem; height: 2px; background: var(--gold); }

/* ---------- Accessibility helpers ---------- */
.skip-link {
  position: absolute;
  top: -4rem;
  left: 1rem;
  z-index: 100;
  padding: 0.6rem 1rem;
  border-radius: var(--radius);
  background: var(--btn-bg);
  color: var(--btn-text);
}
.skip-link:focus { top: 1rem; color: var(--btn-text); }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Marks content the firm still needs to supply */
.placeholder {
  font-style: italic;
  color: var(--text-muted);
  border-bottom: 1px dashed var(--accent);
}

.error-page { max-width: 36rem; }

/* Visitors who ask their device for less motion get almost no animation */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}