/* ============================================================
   acrepair.nyc — base.css
   Reset + typography defaults + accessibility. Mobile-first.
   ============================================================ */

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

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

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

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 var(--space-3);
  line-height: var(--leading-tight);
  font-weight: var(--weight-bold);
  letter-spacing: -0.015em;
  text-wrap: balance;
}

h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-2xl); margin-top: var(--space-7); }
h3 { font-size: var(--text-xl); margin-top: var(--space-5); }
h4 { font-size: var(--text-lg); }

p, ul, ol, dl, table, figure { margin: 0 0 var(--space-4); }
ul, ol { padding-left: var(--space-5); }
li { margin-bottom: var(--space-2); }

a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 0.16em;
  text-decoration-thickness: 1px;
}
a:hover { color: var(--color-accent-strong); }

/* Navigation-style links opt out of underline */
nav a, .btn, .card a.card__link, .footer a { text-decoration: none; }
nav a:hover, .footer a:hover { text-decoration: underline; }

strong, b { font-weight: var(--weight-semi); }

small { font-size: var(--text-sm); }

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

hr {
  border: 0;
  border-top: 1px solid var(--color-border);
  margin: var(--space-7) 0;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-sm);
}
th, td {
  text-align: left;
  padding: var(--space-3);
  border-bottom: 1px solid var(--color-border);
  vertical-align: top;
}
th { font-weight: var(--weight-semi); color: var(--color-text); }

blockquote {
  margin: 0 0 var(--space-4);
  padding-left: var(--space-4);
  border-left: 3px solid var(--color-accent);
  color: var(--color-text-muted);
}

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

/* ---- Forms ---- */
input, select, textarea, button {
  font: inherit;
  color: inherit;
}
input, select, textarea {
  width: 100%;
  padding: var(--space-3);
  min-height: 44px;
  background: var(--color-surface);
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-md);
}
textarea { min-height: 110px; resize: vertical; }
label { display: block; font-size: var(--text-sm); font-weight: var(--weight-medium); margin-bottom: var(--space-1); }
button { cursor: pointer; }

/* ---- Accessibility ---- */
:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 999;
  background: var(--color-primary);
  color: var(--color-text-invert);
  padding: var(--space-3) var(--space-4);
  border-radius: 0 0 var(--radius-md) 0;
}
.skip-link:focus {
  left: 0;
}

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

/* Minimum tap target for every interactive element */
a[href^="tel:"], .btn, button, [role="button"] { min-height: 44px; }

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

@media print {
  .site-header, .mobile-cta, .quote-form, .site-footer nav { display: none !important; }
  body { background: #fff; color: #000; }
}
