/* Página de reservas de Glirena: colores del tema Mora de la app (ui/tema/Colores.kt), claro y oscuro. */
@font-face { font-family: "Bricolage Grotesque"; src: url("/fuentes/bricolage_bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("/fuentes/figtree_regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("/fuentes/figtree_semibold.ttf") format("truetype"); font-weight: 600; font-display: swap; }

:root {
  --paper: #FEF9FB; --card: #FFFFFF; --sunk: #F9EFF2; --line: #E8DEE2; --line2: #C9BDC1;
  --ink: #2B1D22; --ink2: #615056; --ink3: #726569; --acc: #931E5A; --acc-soft: #FEE3EC; --on-acc: #FFFFFF;
  --barra: #931E5A; --barra-texto: #FFFFFF; --barra-texto2: #FFDDE9;
  --ok: #17663F; --ok-soft: #E1F1E7; --warn: #8A5A00; --warn-soft: #FBEFD5; --bad: #B3261E; --bad-soft: #FBE4E1;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #130C0F; --card: #1D1619; --sunk: #251E21; --line: #332B2E; --line2: #4D4548;
    --ink: #F6EEF0; --ink2: #CEC4C8; --ink3: #A59B9F; --acc: #EE95B8; --acc-soft: #462432; --on-acc: #34041C;
    --barra: #531C35; --barra-texto: #F6EEF0; --barra-texto2: #DCC8CE;
    --ok: #7AD8A8; --ok-soft: #163227; --warn: #F2C46B; --warn-soft: #3A2D12; --bad: #FF9A8F; --bad-soft: #401B18;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: "Figtree", system-ui, sans-serif; font-size: 16px; line-height: 1.45;
}
h1, h2, .cifra { font-family: "Bricolage Grotesque", "Figtree", system-ui, sans-serif; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: 26px; margin: 0; line-height: 1.15; }
h2 { font-size: 20px; margin: 0 0 8px; }
p { margin: 0; }
a { color: var(--acc); }
.columna { max-width: 640px; margin: 0 auto; padding: 0 16px; }

.barra { background: var(--barra); color: var(--barra-texto); padding: 24px 0 24px; }
.barra .eyebrow { color: var(--barra-texto2); font-size: 14px; font-weight: 600; margin-bottom: 4px; }
main { padding: 16px 0 32px; }
.seccion { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px; margin-bottom: 16px; }
.ayuda { color: var(--ink2); font-size: 14px; }
.chico { font-size: 14px; }
.separado { margin-top: 16px; }
.oculto { display: none !important; }

/* Servicios */
.opcion {
  display: flex; align-items: center; gap: 16px; min-height: 56px; padding: 8px 0; border-top: 1px solid var(--line); cursor: pointer;
}
.opcion:first-of-type { border-top: 0; }
.opcion input { width: 24px; height: 24px; accent-color: var(--acc); flex: none; margin: 0; }
.opcion .nombre { font-weight: 600; }
.opcion .detalle { color: var(--ink2); font-size: 14px; }
.opcion .precio { margin-left: auto; text-align: right; font-weight: 600; white-space: nowrap; }
.categoria { color: var(--ink2); font-size: 13px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; margin: 16px 0 0; }
.categoria:first-of-type { margin-top: 0; }

/* Días y horas */
.dias { display: flex; gap: 8px; overflow-x: auto; padding: 4px 2px 8px; scroll-snap-type: x proximity; }
.dia, .hora {
  border: 1px solid var(--line2); background: var(--card); color: var(--ink); border-radius: 24px; min-height: 48px;
  font: inherit; font-weight: 600; cursor: pointer; padding: 8px 16px;
}
.dia { flex: none; scroll-snap-align: start; display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 72px; line-height: 1.2; }
.dia small { font-weight: 400; color: var(--ink2); font-size: 13px; }
.horas { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; margin-top: 8px; }
.dia[aria-pressed="true"], .hora[aria-pressed="true"] { background: var(--acc); border-color: var(--acc); color: var(--on-acc); }
.dia[aria-pressed="true"] small { color: var(--on-acc); }
.dia:focus-visible, .hora:focus-visible, .boton:focus-visible, input:focus-visible, textarea:focus-visible { outline: 3px solid var(--acc); outline-offset: 2px; }

/* Formulario */
label.campo { display: block; font-weight: 600; margin: 16px 0 8px; }
label.campo .opcional { font-weight: 400; color: var(--ink2); }
input[type="text"], input[type="tel"], textarea {
  width: 100%; min-height: 48px; padding: 12px 16px; font: inherit; color: var(--ink);
  background: var(--card); border: 1px solid var(--line2); border-radius: 16px;
}
textarea { min-height: 96px; resize: vertical; }
.casilla { display: flex; gap: 12px; align-items: flex-start; margin-top: 16px; cursor: pointer; }
.casilla input { width: 24px; height: 24px; accent-color: var(--acc); flex: none; margin: 0; }

.boton {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px;
  border-radius: 999px; border: 0; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none;
  background: var(--acc); color: var(--on-acc);
}
.boton.completo { width: 100%; }
.boton.secundario { background: var(--card); color: var(--ink); border: 1px solid var(--line2); }
.boton.peligro { background: var(--bad); color: var(--card); }
.boton[disabled] { opacity: 0.45; cursor: default; }
.botones { display: flex; flex-direction: column; gap: 8px; margin-top: 16px; }

.aviso { border-radius: 16px; padding: 16px; margin-bottom: 16px; }
.aviso.error { background: var(--bad-soft); color: var(--ink); border-left: 4px solid var(--bad); }
.aviso.atencion { background: var(--warn-soft); }
.aviso.listo { background: var(--ok-soft); }
.resumen { display: grid; gap: 4px; margin-top: 8px; }
.resumen .cifra { font-size: 22px; }
.total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line); font-weight: 600; }

/* Textos legales (generados por docs/herramientas/generar_legales.mjs) */
.barra .eyebrow a { color: inherit; text-decoration: none; }
.legal .seccion p + p, .legal .seccion p + ul, .legal .seccion p + ol, .legal .seccion ul + p, .legal .seccion ol + p { margin-top: 8px; }
.legal h2 { font-size: 18px; margin: 24px 0 8px; }
.legal .seccion > h2:first-child { margin-top: 0; }
.legal .titulo-legal { font-size: 22px; margin: 0 0 8px; }
.legal ul, .legal ol { margin: 8px 0 0; padding-left: 24px; }
.legal li + li { margin-top: 8px; }
.legal a { overflow-wrap: anywhere; }
.inicio { display: flex; flex-direction: column; gap: 8px; margin-top: 24px; }

footer { text-align: center; color: var(--ink3); font-size: 13px; padding: 24px 16px 40px; }
footer a { color: var(--ink2); }

@media (max-width: 360px) {
  .columna { padding: 0 12px; }
  .horas { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
}
