/* =========================================================
   agendar.css — Sistema de turnos Doc Vaquero
   ========================================================= */

/* ── Variables (igual que el resto del sitio) ── */
:root {
  --bg: #f7f0e6; --ink: #1a1008; --muted: #686460;
  --sand: #e8d9c4; --line: #d4c5b0; --terra1: #f3e7dd; --terra2: #ecdacd;
  --accent: #9b6b4b; --accent-dark: #7d5339; --accent-glow: rgba(155,107,75,.28);
  --radius: 14px;
  --ease: cubic-bezier(0.25,0.46,0.45,0.94);
}

/* ── Reset base ── */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
html { background: var(--bg); }
body {
  margin: 0; background: transparent; color: var(--ink);
  font-family: "Manrope", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  line-height: 1.7; -webkit-font-smoothing: antialiased;
  position: relative; z-index: 0;
}
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image: url('fondo.jpg'); background-repeat: repeat;
  background-position: center; background-size: 1000px; opacity: .06;
}
img { max-width: 100%; height: auto; display: block; }

/* ── Tipografía ── */
h1, h2, h3 { margin: 0 0 12px; line-height: 1.14; font-weight: 800; color: var(--ink); }
h1 { font-size: clamp(32px, 5.5vw, 52px); }
h2 { font-size: clamp(22px, 3.5vw, 32px); }
.eyebrow { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); margin: 0 0 6px; }
.lead { color: var(--muted); max-width: 56ch; margin: 0 0 8px; }
.lead-sm { color: var(--muted); font-size: 14px; }
.text-center { text-align: center; }

/* ── Botones ── */
.btn {
  display: inline-block; padding: 10px 18px; border-radius: 999px;
  text-decoration: none; font-weight: 800; letter-spacing: .04em;
  color: #111; background: transparent; border: 1px solid var(--ink);
  transition: transform .22s var(--ease), background .22s var(--ease), color .22s var(--ease), box-shadow .22s var(--ease);
  cursor: pointer; will-change: transform;
}
.btn:hover { background: #111; color: #fff; transform: translateY(-3px); box-shadow: 0 8px 22px rgba(0,0,0,.18); }
.btn:active { transform: translateY(-1px); }
.btn-solid { background: transparent; color: var(--ink); border: 1px solid var(--ink); }
.btn-primary { background: var(--accent); color: #fff; border-color: var(--accent); box-shadow: 0 4px 20px var(--accent-glow); padding: 13px 26px; }
.btn-primary:hover { background: var(--accent-dark); color: #fff; border-color: var(--accent-dark); box-shadow: 0 10px 32px var(--accent-glow); transform: translateY(-4px); }
.btn-primary:active { transform: translateY(-1px); }
.btn-full { width: 100%; text-align: center; display: block; }

/* ── Nav ── */
.nav {
  position: sticky; top: 0; z-index: 30;
  background: rgba(247,240,230,.94); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav .wrap { display: flex; justify-content: space-between; align-items: center; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 16px 24px; }
.brand { text-decoration: none; color: var(--ink); letter-spacing: .18em; font-weight: 900; font-size: 20px; }
.links { display: none; gap: 12px; align-items: center; }
.links a { color: var(--ink); text-decoration: none; font-weight: 800; letter-spacing: .09em; font-size: 11.5px; position: relative; transition: color .2s ease; }
.links a::after { content: ''; position: absolute; bottom: -3px; left: 0; width: 0; height: 1.5px; background: var(--accent); border-radius: 2px; transition: width .25s var(--ease); }
.links a:hover { color: var(--accent); }
.links a:hover::after { width: 100%; }
.menu { background: none; border: 0; font-size: 22px; color: var(--ink); cursor: pointer; }
@media (min-width: 900px) { .links { display: flex; } .menu { display: none; } }

/* Nav overlay móvil */
.links.open {
  display: flex; flex-direction: column; align-items: flex-start;
  position: fixed; inset: 0; background: #111; padding: 80px 32px 32px;
  z-index: 20; gap: 20px;
}
.links.open a { color: #fff; font-size: 18px; }
.links.open .btn-solid { color: #fff; border-color: #fff; }
.nav.is-open .menu { color: #fff; position: relative; z-index: 21; }
.nav.is-open .brand { position: relative; z-index: 21; color: #fff; }
body.no-scroll { overflow: hidden; }

.mobile-social { display: none; }
.links.open .mobile-social { display: flex; gap: 16px; margin-top: 8px; }
.mobile-social img { width: 28px; height: 28px; }

/* ── Layout principal ── */
.section { padding: 56px 0; }
.wrap-narrow { max-width: 680px; }
.wrap-booking { max-width: 640px; }

/* ── Header de la página ── */
.booking-header { margin-bottom: 40px; }
.booking-header h1 { margin-bottom: 8px; }

/* ── Indicador de pasos ── */
.steps {
  display: flex; gap: 0; list-style: none; padding: 0; margin: 0 0 40px;
  border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden;
}
.step {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  padding: 12px 8px; gap: 4px; border-right: 1px solid var(--line);
  background: var(--bg); transition: background .2s;
}
.step:last-child { border-right: 0; }
.step-num {
  width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 800; color: var(--muted); transition: all .2s;
}
.step-label { font-size: 11px; font-weight: 600; color: var(--muted); text-align: center; transition: color .2s; }
.step.active { background: var(--sand); }
.step.active .step-num { border-color: var(--accent); background: var(--accent); color: #fff; }
.step.active .step-label { color: var(--accent); }
.step.done .step-num { border-color: #2a7a3b; background: #2a7a3b; color: #fff; }
.step.done .step-label { color: #2a7a3b; }
@media (max-width: 480px) { .step-label { display: none; } .step { padding: 10px 4px; } }

/* ── Pasos ── */
.paso-title { margin-bottom: 4px; }
.paso-subtitle { color: var(--muted); font-size: 14px; margin: 0 0 24px; }
.back-btn {
  background: none; border: 0; padding: 0; cursor: pointer;
  color: var(--muted); font-size: 13px; font-weight: 700; margin-bottom: 16px;
  display: flex; align-items: center; gap: 4px;
}
.back-btn:hover { color: var(--ink); }

/* ── Calendario ── */
.calendar-nav {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px; gap: 8px;
}
.cal-nav-btn {
  background: none; border: 1px solid var(--line); border-radius: 8px;
  width: 36px; height: 36px; cursor: pointer; font-size: 18px;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink); transition: background .15s;
}
.cal-nav-btn:hover { background: var(--sand); }
.cal-month-label { font-weight: 800; font-size: 16px; text-transform: capitalize; }
.calendar-grid { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.cal-weekdays {
  display: grid; grid-template-columns: repeat(7, 1fr);
  background: var(--sand); border-bottom: 1px solid var(--line);
}
.cal-weekdays span {
  text-align: center; font-size: 11px; font-weight: 800; letter-spacing: .08em;
  padding: 8px 2px; color: var(--muted);
}
.cal-days {
  display: grid; grid-template-columns: repeat(7, 1fr);
  background: #fff;
}
.cal-day {
  text-align: center; padding: 10px 2px; font-size: 14px; font-weight: 600;
  border-right: 1px solid var(--line); border-bottom: 1px solid var(--line);
  min-height: 44px; display: flex; align-items: center; justify-content: center;
}
.cal-day:nth-child(7n) { border-right: 0; }
.cal-day--empty { background: #fafafa; }
.cal-day--past, .cal-day--weekend { color: var(--muted); opacity: .4; }
.cal-day--available {
  cursor: pointer; background: #fff; transition: background .15s, color .15s;
  border-radius: 0;
}
.cal-day--available:hover { background: var(--sand); color: var(--ink); }
.cal-day--selected { background: var(--accent) !important; color: #fff !important; font-weight: 800; }
.cal-day--today { font-weight: 800; position: relative; }
.cal-day--today::after {
  content: ''; position: absolute; bottom: 4px; left: 50%; transform: translateX(-50%);
  width: 4px; height: 4px; border-radius: 50%; background: currentColor;
}

/* ── Slots de horario ── */
.slots-loading {
  display: flex; align-items: center; gap: 10px; color: var(--muted);
  font-size: 14px; padding: 24px 0;
}
.spinner {
  width: 18px; height: 18px; border: 2px solid var(--line);
  border-top-color: var(--ink); border-radius: 50%;
  animation: spin .7s linear infinite; flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }
.slots-empty { color: var(--muted); font-size: 14px; padding: 16px 0; }
.slots-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 10px;
}
.slot-btn {
  padding: 14px 8px; border: 1.5px solid var(--line); border-radius: var(--radius);
  background: #fff; font-family: inherit; font-size: 16px; font-weight: 700;
  cursor: pointer; text-align: center; transition: all .15s; color: var(--ink);
}
.slot-btn:hover { border-color: var(--accent); background: var(--sand); transform: translateY(-2px); }
.slot-btn.selected { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ── Formulario ── */
.form-datos { display: flex; flex-direction: column; gap: 16px; }
.campo { display: flex; flex-direction: column; gap: 6px; }
.campo label { font-size: 13px; font-weight: 700; color: var(--ink); }
.campo input, .campo select, .campo textarea {
  padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--radius);
  font-family: inherit; font-size: 15px; color: var(--ink); background: #fff;
  transition: border-color .15s; outline: none; width: 100%;
}
.campo input:focus, .campo select:focus, .campo textarea:focus { border-color: var(--ink); }
.campo textarea { resize: vertical; min-height: 96px; font-family: inherit; }
.form-error {
  color: #c0392b; font-size: 13px; font-weight: 600; padding: 10px 14px;
  background: #fef0ef; border-radius: 8px; border: 1px solid #f5c6c0;
}

/* ── Pago ── */
.pago-opciones { display: flex; flex-direction: column; gap: 20px; }
.pago-precio {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-size: 14px; color: var(--muted);
}
.pago-precio-ars, .pago-precio-usd { font-weight: 800; color: var(--ink); font-size: 16px; }
.pago-precio-label { width: 100%; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; }

.btn-pago-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
  padding: 20px 24px; border-radius: var(--radius); text-decoration: none;
  border: 2px solid transparent; transition: transform .18s, box-shadow .18s;
  cursor: pointer;
}
.btn-pago-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,.14); }

.btn-pago-mp {
  background: #00b1ea; color: #fff;
}
.logo-mp { font-size: 20px; font-weight: 800; letter-spacing: -.02em; color: #fff; }
.logo-mp span { font-weight: 300; }

.btn-pago-pp {
  background: #003087; color: #fff;
}
.logo-pp { font-size: 20px; font-weight: 400; color: #fff; }
.logo-pp b { font-weight: 800; color: #009cde; }

.pago-monto { font-size: 26px; font-weight: 800; color: #fff; line-height: 1.1; margin-top: 4px; }
.pago-region { font-size: 12px; font-weight: 600; opacity: .8; color: #fff; }

/* ── Estados (ok / error / etc.) ── */
.estado-section { min-height: 60vh; display: flex; align-items: center; }
.estado-icon { font-size: 56px; margin-bottom: 16px; }

/* ── Footer ── */
.footer { padding: 32px 0; border-top: 1px solid var(--line); background: var(--sand); }
.tiny { display: flex; flex-direction: column; gap: 8px; align-items: center; text-align: center; font-size: 13px; color: var(--muted); }
.tiny nav a { color: var(--muted); text-decoration: none; font-weight: 700; font-size: 11px; letter-spacing: .1em; }
.tiny nav a:hover { color: var(--ink); }

/* ── Responsive ── */
@media (max-width: 600px) {
  .section { padding: 40px 0; }
  .steps { flex-wrap: nowrap; }
  .btn-pago-card { padding: 16px; }
  .pago-monto { font-size: 22px; }
}
