/* ==========================================================================
   Reservador online — misma identidad que el sitio (css/styles.css)
   ========================================================================== */

@font-face { font-family: 'AE Text'; src: url(/assets/fonts/bricolage-text.woff2) format('woff2'); font-weight: 400 750; font-display: swap; }
@font-face { font-family: 'AE Display'; src: url(/assets/fonts/bricolage-display.woff2) format('woff2'); font-weight: 700 800; font-stretch: 75% 85%; font-display: swap; }
@font-face { font-family: 'AE Serif'; src: url(/assets/fonts/serif-italic.woff2) format('woff2'); font-style: italic; font-weight: 400; font-display: swap; }
@font-face { font-family: 'AE Mono'; src: url(/assets/fonts/mono.woff2) format('woff2'); font-weight: 400 700; font-display: swap; }

:root {
  color-scheme: light;
  --paper: #F2EDE4;
  --paper-2: #E7DFD1;
  --card: #FAF7F1;
  --ink: #15110F;
  --ink-3: #3A322D;
  --red: #D52B1E;
  --red-dark: #9C1A11;
  --gold: #E7B63F;
  --green: #1F8A4C;
  --muted: #6B625A;
  --line: rgba(21, 17, 15, .12);
  --line-2: rgba(21, 17, 15, .22);
  --f-text: 'AE Text', system-ui, sans-serif;
  --f-head: 'AE Display', 'Arial Narrow', system-ui, sans-serif;
  --f-serif: 'AE Serif', Georgia, serif;
  --f-mono: 'AE Mono', ui-monospace, monospace;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --gutter: clamp(16px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; background: var(--paper); color: var(--ink); font: 16px/1.5 var(--f-text); font-variation-settings: 'opsz' 16; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--red); color: var(--paper); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
em { font-family: var(--f-serif); font-style: italic; font-weight: 400; font-variation-settings: normal; letter-spacing: -.01em; }
.muted { color: var(--muted); }

/* ---------- Barra ---------- */
.bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; max-width: 1080px; margin: 0 auto; padding: 18px var(--gutter); }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.logo__text { line-height: 1; }
.logo__text span { display: block; margin-bottom: 3px; font: 400 10px var(--f-mono); letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
.logo__text b { font: 800 19px var(--f-head); letter-spacing: -.03em; font-variation-settings: 'opsz' 48, 'wdth' 80; }
.bar__back { text-decoration: none; font-weight: 600; font-size: 14px; color: var(--ink-3); }
.bar__back:hover { color: var(--red); }

.wrap { max-width: 760px; margin: 0 auto; padding: 8px var(--gutter) 80px; }

/* ---------- Progreso ---------- */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 8px 0 34px; padding: 0; }
.steps li { font: 400 10.5px var(--f-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.steps li::before { content: ''; display: block; height: 5px; margin-bottom: 9px; border-radius: 3px; background: var(--paper-2); transition: background .4s; }
.steps li.done::before, .steps li.on::before { background: var(--red); }
.steps li.on { color: var(--ink); font-weight: 700; }

/* ---------- Títulos ---------- */
h1 { margin: 0; font: 780 clamp(40px, 7vw, 68px)/.92 var(--f-head); letter-spacing: -.028em; font-variation-settings: 'opsz' 96, 'wdth' 78; }
.lead { margin: 12px 0 28px; color: var(--muted); font-size: 17px; }
.label { display: block; margin: 26px 0 12px; font: 400 11px var(--f-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--red); }

/* ---------- Opciones (radio como tarjetas) ---------- */
.opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.opt { position: relative; display: grid; gap: 4px; padding: 16px 18px; border-radius: 20px; border: 1.5px solid var(--line); background: var(--card); cursor: pointer; transition: border-color .2s, transform .35s var(--ease-out), box-shadow .3s; }
.opt:hover { border-color: var(--ink); transform: translateY(-2px); }
.opt input { position: absolute; opacity: 0; pointer-events: none; }
.opt b { font: 780 22px/1 var(--f-head); letter-spacing: -.02em; font-variation-settings: 'opsz' 96, 'wdth' 80; }
.opt small { color: var(--muted); font-size: 13.5px; }
.opt .opt__price { margin-top: 6px; font-weight: 700; font-size: 18px; }
.opt:has(:checked) { border-color: var(--ink); background: var(--ink); color: var(--paper); box-shadow: 0 20px 34px -24px rgba(21, 17, 15, .8); }
.opt:has(:checked) small { color: rgba(242, 237, 228, .7); }
.opt:has(:focus-visible) { outline: 3px solid var(--gold); outline-offset: 2px; }
.opt__tag { position: absolute; top: -10px; right: 14px; padding: 3px 9px; border-radius: 999px; background: var(--green); color: #fff; font: 700 11px var(--f-mono); }

.rooms { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.rooms label { display: grid; place-items: center; gap: 2px; aspect-ratio: 1 / 1.05; border-radius: 18px; border: 1.5px solid var(--line); background: var(--card); cursor: pointer; transition: transform .35s var(--ease-out), border-color .2s; }
.rooms label:hover { transform: translateY(-3px); border-color: var(--ink); }
.rooms input { position: absolute; opacity: 0; pointer-events: none; }
.rooms b { font: 780 clamp(26px, 5vw, 40px)/.9 var(--f-head); font-variation-settings: 'opsz' 96, 'wdth' 80; }
.rooms small { font: 400 10px var(--f-mono); text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.rooms label:has(:checked) { background: var(--red); border-color: var(--red); color: var(--paper); transform: translateY(-3px) rotate(-3deg); }
.rooms label:has(:checked) small { color: rgba(242, 237, 228, .8); }
.rooms label:has(:focus-visible) { outline: 3px solid var(--gold); outline-offset: 2px; }

.seg { display: inline-flex; padding: 5px; border-radius: 999px; background: var(--paper-2); }
.seg label { padding: 10px 18px; border-radius: 999px; font-weight: 600; cursor: pointer; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(:checked) { background: var(--ink); color: var(--paper); }
.km { display: grid; gap: 8px; margin-top: 14px; }
.km input[type='range'] { width: 100%; accent-color: var(--red); }
.km output { font-weight: 700; }

/* ---------- Resumen de precio ---------- */
.total {
  margin-top: 30px; padding: 22px 24px; border-radius: 26px; color: var(--paper);
  background: radial-gradient(80% 70% at 100% 0%, rgba(213, 43, 30, .4), transparent 60%), var(--ink);
  display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.total__k { font: 400 11px var(--f-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--gold); }
.total__v { font: 780 clamp(34px, 6vw, 48px)/1 var(--f-head); letter-spacing: -.02em; font-variation-settings: 'opsz' 96, 'wdth' 80; }
.total__note { width: 100%; margin: 0; font-size: 13px; color: rgba(242, 237, 228, .7); }

/* ---------- Calendario ---------- */
.cal { padding: 16px; border-radius: 26px; border: 1px solid var(--line); background: var(--card); }
.cal__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.cal__head strong { font: 780 24px/1 var(--f-head); font-variation-settings: 'opsz' 96, 'wdth' 80; }
.cal__dow, .cal__grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.cal__dow { margin-bottom: 6px; text-align: center; font: 400 10.5px var(--f-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.d { aspect-ratio: 1; display: grid; place-items: center; border-radius: 14px; border: 1.5px solid transparent; background: var(--paper); font: 780 18px var(--f-head); font-variation-settings: 'opsz' 96, 'wdth' 80; cursor: pointer; position: relative; transition: transform .3s var(--ease-out), border-color .2s; }
.d::after { content: ''; position: absolute; bottom: 7px; width: 5px; height: 5px; border-radius: 50%; background: var(--green); }
.d:hover:not(:disabled) { transform: translateY(-2px); border-color: var(--ink); }
.d:disabled { background: none; color: rgba(21, 17, 15, .25); cursor: default; }
.d:disabled::after { display: none; }
.d--full:disabled { text-decoration: line-through; }
.d--sel, .d--sel:hover:not(:disabled) { background: var(--red); border-color: var(--red); color: var(--paper); }
.d--sel::after { background: var(--paper); }
.d--blank { visibility: hidden; }

.turnos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.turno { padding: 16px 18px; border-radius: 20px; border: 1.5px solid var(--line); background: var(--card); text-align: left; cursor: pointer; display: grid; gap: 2px; transition: border-color .2s; }
.turno b { font: 780 22px/1 var(--f-head); font-variation-settings: 'opsz' 96, 'wdth' 80; }
.turno small { color: var(--muted); }
.turno:hover:not(:disabled) { border-color: var(--ink); }
.turno:disabled { opacity: .45; cursor: not-allowed; }
.turno[aria-pressed='true'] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.turno[aria-pressed='true'] small { color: rgba(242, 237, 228, .7); }

/* ---------- Formularios ---------- */
.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.fields .full { grid-column: 1 / -1; }
.f { display: grid; gap: 6px; font-weight: 600; font-size: 14px; }
.inp { width: 100%; padding: 13px 16px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card); font-weight: 500; transition: border-color .2s, background .2s; }
.inp:hover { border-color: var(--line-2); }
.inp:focus { outline: none; border-color: var(--ink); background: #fff; }
textarea.inp { min-height: 90px; resize: vertical; }
.parada { display: flex; gap: 8px; }
.link { background: none; border: 0; padding: 0; color: var(--red); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.x { flex: none; width: 46px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card); cursor: pointer; font-size: 20px; }

.check { display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; border-radius: 20px; border: 1.5px solid var(--line); background: var(--card); cursor: pointer; }
.check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--red); flex: none; }
.check small { display: block; color: var(--muted); }
.notice { margin: 0 0 16px; padding: 12px 16px; border-radius: 14px; background: rgba(231, 182, 63, .22); color: #6E4E00; font-size: 14px; }
.notice b { font-family: var(--f-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; margin-right: 6px; }
.notice--test { background: rgba(213, 43, 30, .1); color: var(--red-dark); }

.resumen { margin: 0; padding: 18px 20px; border-radius: 20px; border: 1px solid var(--line); background: var(--card); display: grid; gap: 8px; }
.resumen div { display: flex; justify-content: space-between; gap: 16px; }
.resumen dt { color: var(--muted); }
.resumen dd { margin: 0; text-align: right; font-weight: 600; }
.resumen .big dd { font: 780 24px/1 var(--f-head); font-variation-settings: 'opsz' 96, 'wdth' 80; color: var(--red); }

/* ---------- Botones ---------- */
.nav { display: flex; justify-content: space-between; gap: 10px; margin-top: 34px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 15px 26px; border-radius: 999px; border: 1.5px solid var(--ink); background: transparent; font-weight: 650; cursor: pointer; text-decoration: none; transition: background .2s, color .2s, transform .3s var(--ease-out); }
.btn:hover { background: var(--ink); color: var(--paper); }
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.btn:disabled:hover { background: transparent; color: inherit; }
.btn--red { background: var(--red); border-color: var(--red); color: var(--paper); margin-left: auto; }
.btn--red:hover { background: var(--ink); border-color: var(--ink); }
.btn--red:disabled:hover { background: var(--red); color: var(--paper); }

/* ---------- Resultado ---------- */
.result { text-align: center; padding: 30px 0; }
.result__icon { width: 84px; height: 84px; margin: 0 auto 22px; border-radius: 50%; display: grid; place-items: center; font-size: 40px; color: var(--paper); background: var(--green); }
.result__icon--bad { background: var(--red); }
.result__icon--wait { background: var(--ink); animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(.92); opacity: .7; } }
.result .resumen { text-align: left; margin: 26px auto 0; max-width: 460px; }
.result .nav { justify-content: center; flex-wrap: wrap; }
.result .btn--red { margin-left: 0; }

.toast { position: fixed; left: 50%; bottom: 20px; z-index: 50; transform: translate(-50%, 24px); opacity: 0; visibility: hidden; max-width: calc(100vw - 32px); padding: 13px 20px; border-radius: 999px; background: var(--red); color: var(--paper); font-weight: 600; transition: transform .3s var(--ease-out), opacity .2s, visibility .2s; }
.toast.show { transform: translate(-50%, 0); opacity: 1; visibility: visible; }

@media (max-width: 600px) {
  .opts, .fields { grid-template-columns: 1fr; }
  .rooms { grid-template-columns: repeat(3, 1fr); }
  .steps li { font-size: 0; }
  .steps li.on { font-size: 10px; }
  .cal { padding: 10px; }
  .cal__dow, .cal__grid { gap: 3px; }
  .d { border-radius: 10px; font-size: 15px; }
  .d::after { bottom: 4px; width: 4px; height: 4px; }
  .bar__back { font-size: 13px; }
  .nav .btn { padding: 14px 20px; }
}
