/* ============================================================================
   Utilidades de layout — subconjunto de Tailwind usado por index.html y
   dashboard.html, servido desde el propio sitio.

   Por qué existe este archivo: ambas páginas cargaban Tailwind desde
   `cdn.tailwindcss.com`. Ese CDN compila en el navegador, así que si tarda,
   lo bloquea una red corporativa o falla el DNS, la página se sirve SIN
   layout: todo pegado al borde izquierdo, sin anchos ni espaciado. Le pasó
   al jefe el 2026-07-31 con el sitio ya en producción.

   Acá solo van utilidades de estructura (ancho, flex/grid, espaciado,
   tipografía). El COLOR sigue viniendo de las variables :root de cada
   archivo — este CSS no define paleta.

   Si agregas una clase `sm:`/`md:`/`lg:` nueva en el HTML, agrégala también
   acá: no hay compilador que la genere.
   ========================================================================= */

*, ::before, ::after { box-sizing: border-box; border-width: 0; border-style: solid; }
html { -webkit-text-size-adjust: 100%; font-family: 'Inter', system-ui, sans-serif; line-height: 1.5; }
body { margin: 0; line-height: inherit; }
h1,h2,h3,h4,h5,h6 { font-size: inherit; font-weight: inherit; margin: 0; }
p, figure { margin: 0; }
button, input, select, textarea { font-family: inherit; font-size: 100%; font-weight: inherit; line-height: inherit; color: inherit; margin: 0; padding: 0; }
button { background-color: transparent; background-image: none; cursor: pointer; }
button, [type='button'], [type='submit'] { -webkit-appearance: button; }
ul, ol { list-style: none; margin: 0; padding: 0; }
img, svg, video, canvas { display: block; vertical-align: middle; max-width: 100%; height: auto; }
svg { height: initial; }
input::placeholder, textarea::placeholder { opacity: 1; }
:disabled { cursor: default; }

/* posición */
.fixed { position: fixed; }
.absolute { position: absolute; }
.relative { position: relative; }
.inset-0 { inset: 0; }
.z-50 { z-index: 50; }

/* display */
.block { display: block; }
.inline-block { display: inline-block; }
.flex { display: flex; }
.grid { display: grid; }
.hidden { display: none; }

/* flex / grid */
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.flex-1 { flex: 1 1 0%; }
.shrink-0 { flex-shrink: 0; }
.items-start { align-items: flex-start; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* gap */
.gap-1\.5 { gap: 0.375rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }

/* separación entre hermanos */
.space-y-1\.5 > * + * { margin-top: 0.375rem; }
.space-y-2   > * + * { margin-top: 0.5rem; }
.space-y-3   > * + * { margin-top: 0.75rem; }
.space-y-4   > * + * { margin-top: 1rem; }
.space-y-5   > * + * { margin-top: 1.25rem; }

/* ancho / alto */
.w-2 { width: 0.5rem; }  .h-2 { height: 0.5rem; }
.w-3\.5 { width: 0.875rem; } .h-3\.5 { height: 0.875rem; }
.w-8 { width: 2rem; }    .h-8 { height: 2rem; }
.w-full { width: 100%; }
.min-h-screen { min-height: 100vh; }
.max-w-2xl { max-width: 42rem; }
.max-w-\[130px\] { max-width: 130px; }

/* márgenes */
.mx-auto { margin-left: auto; margin-right: auto; }
.ml-auto { margin-left: auto; }
.ml-2 { margin-left: 0.5rem; }
.mt-0\.5 { margin-top: 0.125rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-8 { margin-top: 2rem; }
.mb-3 { margin-bottom: 0.75rem; }

/* padding */
.p-4 { padding: 1rem; }
.p-6 { padding: 1.5rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.py-0\.5 { padding-top: 0.125rem; padding-bottom: 0.125rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-10 { padding-top: 2.5rem; padding-bottom: 2.5rem; }
.pt-2 { padding-top: 0.5rem; }
.pt-3 { padding-top: 0.75rem; }
.pt-6 { padding-top: 1.5rem; }
.pb-2 { padding-bottom: 0.5rem; }
.pb-24 { padding-bottom: 6rem; }

/* tipografía */
.text-xs   { font-size: 0.75rem;  line-height: 1rem; }
.text-sm   { font-size: 0.875rem; line-height: 1.25rem; }
.text-base { font-size: 1rem;     line-height: 1.5rem; }
.font-mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.uppercase { text-transform: uppercase; }
.tracking-wider { letter-spacing: 0.05em; }
.leading-none { line-height: 1; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* bordes */
.rounded-lg { border-radius: 0.5rem; }
.rounded-xl { border-radius: 0.75rem; }
.rounded-full { border-radius: 9999px; }
.border   { border-width: 1px; }
.border-t { border-top-width: 1px; }
.border-b { border-bottom-width: 1px; }
.border-dashed { border-style: dashed; }

/* cursor */
.cursor-default { cursor: default; }
.cursor-pointer { cursor: pointer; }

/* ── COLOR ────────────────────────────────────────────────────────────────
   Apuntan a las variables :root del archivo que las use. Cambiar el tema
   sigue siendo cambiar SOLO ese bloque.                                   */
.bg-card  { background-color: var(--surface); }
.bg-dark  { background-color: var(--bg); }
.bg-white { background-color: var(--accent-hover); }
.text-txt   { color: var(--text); }
.text-sub   { color: var(--text-2); }
.text-muted { color: var(--text-3); }
.text-dark  { color: var(--on-accent); }
.border-border { border-color: var(--border, var(--border-c)); }

/* ── RESPONSIVE ──────────────────────────────────────────────────────── */
@media (min-width: 640px) {
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sm\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 768px) {
  .md\:grid-cols-\[2fr_1fr\] { grid-template-columns: 2fr 1fr; }
}
@media (min-width: 1024px) {
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lg\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .lg\:max-w-4xl { max-width: 56rem; }
}
