/* ==========================================================================
   AuraBily — Base Typography, Accessibility & Surface Defaults (Layer 03)
   ========================================================================== */

html {
  overscroll-behavior-y: none;
}

html,
body {
  min-height: 100vh;
  min-height: 100dvh;
  max-width: 100vw;
  overflow-x: clip;
  background-color: var(--surface-base);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Editorial Display Headings */
h1,
h2,
h3,
.serif-heading {
  font-family: var(--font-serif);
  letter-spacing: 0.02em;
  color: var(--text-primary);
}

/* Keyboard Focus Visibility (WCAG AA) */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* iOS Anti-Zoom Floor: Inputs stay >= 16px */
input,
select,
textarea {
  font-size: var(--text-base);
  background-color: var(--surface-input);
  color: var(--text-primary);
}

input::placeholder,
textarea::placeholder {
  color: var(--text-muted);
}

/* Subtle Thin Scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--border-structural);
  border-radius: var(--radius-pill);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-border);
}

/* Screen Reader Utility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.is-hidden {
  display: none;
}

/* Interactive Touch Tactility (GPU Composited <16ms feedback) */
.ui-interactive {
  transition:
    transform var(--motion-fast) var(--ease-standard),
    opacity var(--motion-fast) var(--ease-standard),
    background-color var(--motion-fast) var(--ease-standard),
    border-color var(--motion-fast) var(--ease-standard);
}

.ui-interactive:active {
  transform: scale(0.97);
}
