/* Reset + base typography */
*, *::before, *::after { box-sizing: border-box; }

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

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

body {
  margin: 0;
  background: var(--paper-bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.5;
  font-feature-settings: "kern" 1, "liga" 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0 0 var(--sp-3);
}

h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); letter-spacing: -0.015em; }
h3 { font-size: var(--fs-h3); }

p { margin: 0 0 var(--sp-3); color: var(--ink-sec); }
p:last-child { margin-bottom: 0; }

a {
  color: var(--accent);
  text-decoration: none;
  transition: color var(--t-fast) var(--ease-out);
}
a:hover { color: var(--accent-pressed); }
a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

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

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

::selection { background: var(--accent); color: var(--paper-elev); }

/* Numerics */
.tnum { font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1; }

/* Display heading */
.display {
  font-family: var(--font-display);
  font-size: var(--fs-display);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1.02;
  color: var(--ink);
  margin-block-end: var(--sp-4);
}

/* Caps label */
.eyebrow {
  display: inline-block;
  font-size: var(--fs-caps);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-block-end: var(--sp-3);
}
:lang(ar) .eyebrow { text-transform: none; letter-spacing: 0; }

/* Lead paragraph */
.lead {
  font-size: var(--fs-body-lg);
  line-height: 1.6;
  color: var(--ink-sec);
}

/* Skip link */
.skip-link {
  position: absolute;
  inset-block-start: -40px;
  inset-inline-start: var(--sp-3);
  background: var(--ink);
  color: var(--paper-elev);
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--radius-button);
  z-index: 1000;
  transition: inset-block-start var(--t-fast) var(--ease-out);
}
.skip-link:focus { inset-block-start: var(--sp-3); color: var(--paper-elev); }

/* Container */
.container {
  inline-size: 100%;
  max-inline-size: var(--max-w-content);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Visually hidden but accessible */
.sr-only {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Force light scheme — Warm Paper is the brand */
html { color-scheme: light only; }
