/* ============================================================
   ai-coustics · Base element styling + utilities
   ------------------------------------------------------------
   Lightweight foundation that maps the tokens onto real
   elements. Consumers can rely on these or compose their own.
   ============================================================ */

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

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  color: var(--text-primary);
  background: var(--surface-page);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* headings use the brand display face */
h1, h2, h3, .aic-display {
  font-family: var(--font-display);
  font-weight: var(--weight-regular);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-tight);
  color: var(--text-primary);
  margin: 0;
}
h1 { font-size: var(--text-display-l); line-height: var(--leading-tight); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-2xl); }

h4, h5, h6 {
  font-family: var(--font-sans);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-snug);
  margin: 0;
}
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }
h6 { font-size: var(--text-md); }

p { margin: 0 0 1em; }

a { color: var(--text-link); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }

code, kbd, samp, pre {
  font-family: var(--font-mono);
  font-size: 0.92em;
}

/* ---- utility classes ---- */
.aic-eyebrow {
  font-family: var(--font-mono);
  font-size: var(--role-eyebrow-size);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-caps);
  text-transform: uppercase;
  color: var(--text-secondary);
}

.aic-display-xl { font-family: var(--font-display); font-size: var(--text-display-xl); line-height: var(--leading-tight); letter-spacing: var(--tracking-tight); font-weight: var(--weight-regular); }
.aic-mono { font-family: var(--font-mono); }
.aic-muted { color: var(--text-secondary); }

.aic-container { max-width: var(--container-max); margin-inline: auto; padding-inline: var(--space-5); }

/* focus ring */
:where(a, button, input, select, textarea, [tabindex]):focus-visible {
  outline: none;
  box-shadow: var(--shadow-focus);
  border-radius: var(--radius-xs);
}

/* inlined icon SVGs fill their square wrapper */
.aic-icon > svg { width: 100%; height: 100%; display: block; }
