/* ==========================================================================
   Base — reset and default element styling. No component classes here.
   ========================================================================== */

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

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

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    /* Duration alone isn't enough: staggered entrance sequences (like the
       hero) use animation-delay to sequence themselves, and an unzeroed
       delay still makes a reduced-motion visitor wait through the full
       original real-time stagger before an (now-instant) animation fires —
       arguably worse than the motion they asked to avoid. */
    animation-duration: 0.001ms !important;
    animation-delay: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    transition-delay: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  /* Regular, not medium: at display sizes Fraunces already has enough
     presence — medium weight was reading heavy paired with Inter body
     text at the same time. */
  font-weight: var(--weight-regular);
  line-height: var(--line-height-tight);
  margin: 0 0 var(--space-4);
  color: var(--color-text);
  /* Safety net for long unbreakable tokens (proper names, URLs) at narrow
     widths — verified needed: "Mrs. Santhakumari" overflowed the mobile
     viewport at a fixed --font-size-4xl before this and the clamp() below. */
  overflow-wrap: break-word;
}

h1 {
  /* Fluid instead of a fixed size + breakpoint overrides: scales smoothly
     from mobile to desktop. Trimmed from the original 36px–56px range —
     read as slightly oversized next to body copy. */
  font-size: clamp(2rem, 1.25rem + 3vw, 3.25rem);
}

h2 {
  font-size: 2rem;
}

h3 {
  font-size: var(--font-size-xl);
}

h4 {
  font-size: var(--font-size-lg);
}

p {
  margin: 0 0 var(--space-5);
  max-width: 66ch;
}

a {
  color: inherit;
  text-decoration-color: var(--color-accent);
  text-underline-offset: 0.15em;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

button {
  font-family: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

/* Consistent, visible, on-brand focus state for every interactive element */
:focus-visible {
  outline: 3px solid var(--color-focus-ring);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

::selection {
  /* The branded selection color: lemon-gold fill, deep-green text —
     verified 6.3:1 contrast, easily readable, and unmistakably part of
     the same palette as the rest of the site rather than a generic
     browser default. */
  background: var(--gold);
  color: var(--green-deep);
}

.skip-link {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  z-index: var(--z-skip-link);
  transform: translateY(-150%);
  background: var(--green-deep);
  color: var(--white);
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-md);
  font-weight: var(--weight-medium);
  transition: transform var(--duration-base) var(--ease-standard);
}

.skip-link:focus {
  transform: translateY(0);
}
