/* Cerberus · base: fuentes, elementos HTML y accesibilidad. */

@font-face { font-family: "Inter"; font-style: normal; font-weight: 300; font-display: swap; src: url("../fonts/inter-300.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/inter-400.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/inter-500.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/inter-600.woff2") format("woff2"); }
@font-face { font-family: "Cascadia Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/cascadia-mono-400.woff2") format("woff2"); }
@font-face { font-family: "Cascadia Mono"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/cascadia-mono-500.woff2") format("woff2"); }

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: var(--size-body);
  font-weight: var(--weight-body);
  line-height: var(--leading);
  font-feature-settings: "cv11" 1, "tnum" 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd {
  margin: 0;
}

ul[role="list"] {
  padding: 0;
  list-style: none;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--accent-hover);
}

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

[hidden] {
  display: none !important;
}

.mono {
  font-family: var(--font-mono);
  font-size: var(--size-mono);
}

.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;
  top: var(--space-s);
  left: var(--space-s);
  z-index: 20;
  padding: var(--space-s) var(--space-sm);
  border-radius: var(--radius-m);
  background: var(--surface);
  color: var(--text);
  transform: translateY(-200%);
}

.skip-link:focus-visible {
  transform: none;
}

.icon {
  flex: none;
  width: var(--icon);
  height: var(--icon);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0ms !important;
  }
}
