@font-face {
  font-family: "TahomaLocal";
  src: url("../assets/fonts/tahoma.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* ==========================================================================
   base.css — Reset mínimo, tokens de tema y ajustes de plataforma.
   Alcance: SOLO base y tokens. Nada de layout del shell (eso es shell.css).
   Los temas (theme-xp.css, theme-7.css) sobrescriben los tokens de :root.
   ========================================================================== */

/* 1. Reset mínimo --------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

img {
  display: block;
  max-width: 100%;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
}

ul {
  list-style: none;
}

[hidden] {
  display: none !important;
}

/* 2. Tokens de tema (valores XP por defecto) ------------------------------ */
:root {
  /* Tipografía (system-ui, sin webfonts) */
  --font-ui: "TahomaLocal", Tahoma, sans-serif;
  --font-size: 12px;

  /* Texto */
  --text: #1a1a1a;
  --text-inverse: #fff;

  /* Escritorio */
  --bg-desktop: #3a6ea5;

  /* Ventana */
  --window-bg: #ece9d8;
  --window-text: #1a1a1a;
  --window-border: #0831d9;

  /* Barra de título */
  --titlebar-bg: linear-gradient(180deg, #0058e6, #3a93ff);
  --titlebar-text: #fff;
  --titlebar-active-bg: linear-gradient(180deg, #0058e6, #3a93ff);
  --titlebar-inactive-bg: linear-gradient(180deg, #7f97c9, #aebfdd);

  /* Barra de tareas */
  --taskbar-bg: linear-gradient(180deg, #245edb, #1941a5);
  --taskbar-border: #0e2f8f;
  --taskbar-text: #fff;

  /* Botón de inicio */
  --start-bg: linear-gradient(180deg, #3c9d3c, #2f7d2f);
  --start-text: #fff;

  /* Acento */
  --accent: #316ac5;
  --accent-text: #fff;

  /* Menús y selección */
  --menu-bg: #fff;
  --menu-border: #aca899;
  --selection-bg: rgba(49, 106, 197, .55);

  /* Biseles */
  --bevel-light: #fff;
  --bevel-dark: #9a9a8e;

  /* Sombras */
  --shadow-window: 4px 4px 12px rgba(0, 0, 0, .4);
  --icon-label-shadow: 1px 1px 1px rgba(0, 0, 0, .75);

  /* Métricas */
  --radius: 3px;
  --control-h: 22px;
  --taskbar-h: 32px;
}

/* 3. Tipografía base ------------------------------------------------------- */
html,
body {
  height: 100%;
}

body {
  font: var(--font-size)/1.35 var(--font-ui);
  color: var(--text);
  background: var(--bg-desktop) url("../assets/wall-pradera.webp") center / cover no-repeat;
  overflow: hidden; /* Escritorio; el modo compacto lo ajusta shell.css */
}

::selection {
  background: var(--selection-bg);
}

/* 4. Scrollbars clásicas --------------------------------------------------- */
::-webkit-scrollbar {
  width: 16px;
  height: 16px;
}

::-webkit-scrollbar-track {
  background: var(--window-bg); /* gris clásico */
}

::-webkit-scrollbar-thumb {
  background: #d4d0c8;
  border: 1px solid;
  /* bisel saliente: claro arriba/izquierda, oscuro abajo/derecha */
  border-color: var(--bevel-light) var(--bevel-dark) var(--bevel-dark) var(--bevel-light);
}

::-webkit-scrollbar-corner {
  background: var(--window-bg);
}

/* 5. Foco visible ---------------------------------------------------------- */
:focus-visible {
  outline: 2px dotted #000;
  outline-offset: 1px;
}

/* Contraste claro sobre fondos oscuros (barra de tareas, barra de título) */
.taskbar :focus-visible,
.titlebar :focus-visible {
  outline-color: #fff;
}

/* 6. Movimiento reducido --------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}
