/* ============================================================
   Caldera — reset + base typography
   ============================================================ */

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

* { margin: 0; }

html, body { height: 100%; }

body {
  font-family: var(--font-ui);
  color: var(--text);
  background:
    radial-gradient(1200px 800px at 50% -10%, var(--bg) 0%, var(--bg-deep) 100%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.45;
  overflow-x: hidden;
  transition: background-color var(--dur-base) ease, color var(--dur-base) ease;
  touch-action: manipulation;
}

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

button { cursor: pointer; border: none; background: none; }

h1, h2 { font-weight: 650; letter-spacing: -0.01em; }

kbd {
  font-family: var(--font-mono);
  font-size: 0.78em;
  padding: 0.1em 0.4em;
  border-radius: 6px;
  background: var(--glass);
  border: 1px solid var(--hairline);
}

:focus-visible {
  outline: 2.5px solid var(--focus);
  outline-offset: 2px;
  border-radius: 6px;
}

.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;
}

.skip-link {
  position: absolute;
  left: 50%;
  top: -60px;
  transform: translateX(-50%);
  background: var(--accent);
  color: #fff;
  padding: 8px 16px;
  border-radius: 0 0 10px 10px;
  z-index: 100;
  transition: top var(--dur-base) ease;
  text-decoration: none;
  font-weight: 600;
}
.skip-link:focus { top: 0; }

.glass {
  background: var(--glass);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  backdrop-filter: blur(16px) saturate(1.4);
  border: 1px solid var(--glass-border);
  box-shadow: var(--card-shadow);
}

.hidden { display: none !important; }

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