html {
  color-scheme: dark;
}

[data-theme="light"] {
  color-scheme: light;
}

body {
  min-width: 320px;
  overflow-x: hidden;
  font-size: var(--text-base);
  padding-left: env(safe-area-inset-left, 0px);
  padding-right: env(safe-area-inset-right, 0px);
}

body.admin-page,
body.admin-auth-page {
  background: var(--bg-base);
}

h1,
h2,
h3 {
  line-height: 1.1;
  letter-spacing: -0.02em;
}

h1,
h2 {
  font-family: var(--font-display);
  font-weight: 400;
}

h3 {
  font-family: var(--font-body);
  font-weight: 600;
}

p {
  color: var(--texto-sec);
}

strong {
  font-weight: 600;
}

svg {
  display: block;
}

label {
  display: grid;
  gap: var(--space-2);
  color: var(--texto-sec);
  font-size: var(--text-sm);
  font-weight: 500;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--borde);
  border-radius: var(--radius);
  padding: 13px 14px;
  background: var(--bg-base);
  color: var(--texto);
  font-size: var(--text-sm);
  outline: none;
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast), background var(--dur-fast);
}

input:focus,
textarea:focus,
select:focus {
  border-color: var(--rojo);
  box-shadow: 0 0 0 4px var(--rojo-suave);
}

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb {
  background: var(--rojo-oscuro);
  border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover { background: var(--rojo); }

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 1.15em;
  height: 1.15em;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.center-page {
  min-height: 70svh;
  display: grid;
  place-items: center;
  padding: var(--space-20) var(--space-4);
}
