/* Centro de Rehabilitación — tema turquesa/blanco (salud y bienestar). */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  --bg: #f3f8f8;
  --surface: #ffffff;
  --surface-2: #f7fbfb;
  --border: #dce6e6;
  --fg: #14282b;
  --muted: #5b7073;
  --accent: #0e8f8a;
  --accent-oscuro: #0b6b68;
  --accent-tint: #dff5f2;
  --coral: #f26b4e;
  --coral-tint: #fdebe6;
  --danger: #b3261e;
  --ambar: #92600a; --ambar-fondo: #fdf1de;
  --azul: #145da0; --azul-fondo: #e3f1fd;
  --verde: #1e7d3c; --verde-fondo: #e5f6ea;
  --gris: #5f6b6d; --gris-fondo: #eaeeee;
  --rojo: #b3261e; --rojo-fondo: #fbe9e7;
  --sombra: 0 1px 2px rgba(10, 40, 40, .05), 0 4px 14px rgba(10, 40, 40, .06);
  --radio: 14px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--fg); background: var(--bg); min-height: 100vh; line-height: 1.5; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { max-width: 100%; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -.01em; }
.muted { color: var(--muted); }
.mt { margin-top: 1rem; } .mb { margin-bottom: 1rem; }
.derecha { text-align: right; }
.oculto { display: none !important; }
.solo-imprimir { display: none; }

/* ---------- Botones y formularios ---------- */
button, .btn { font: inherit; cursor: pointer; border: 1px solid var(--accent); background: var(--accent); color: #fff; padding: .55rem 1.1rem; border-radius: 999px; font-weight: 700; display: inline-flex; align-items: center; gap: .4rem; text-decoration: none; transition: background .15s, transform .05s; }
button:hover, .btn:hover { background: var(--accent-oscuro); text-decoration: none; }
button:active, .btn:active { transform: translateY(1px); }
button.sec, .btn.sec { background: #fff; color: var(--accent-oscuro); border-color: var(--border); }
button.sec:hover, .btn.sec:hover { background: var(--accent-tint); }
button.peligro, .btn.peligro { background: #fff; color: var(--danger); border-color: #efc4c0; }
button.peligro:hover { background: var(--rojo-fondo); }
button.chico, .btn.chico { padding: .3rem .8rem; font-size: .85rem; }
button:disabled { opacity: .55; cursor: not-allowed; }
.btn.coral { background: var(--coral); border-color: var(--coral); }
.btn.coral:hover { background: #d9533a; }
.btn.grande { padding: .8rem 1.6rem; font-size: 1.05rem; }

label { display: block; font-weight: 600; font-size: .88rem; margin-bottom: .25rem; }
input, select, textarea { font: inherit; width: 100%; padding: .55rem .75rem; border: 1px solid var(--border); border-radius: 10px; background: #fff; color: var(--fg); }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent-tint); border-color: var(--accent); }
input[type=checkbox], input[type=radio] { width: auto; }
textarea { min-height: 84px; resize: vertical; }
.campo { margin-bottom: .9rem; }
.fila { display: grid; gap: .9rem; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.check { display: flex; gap: .5rem; align-items: flex-start; font-weight: 500; }
.check input { margin-top: .25rem; }
.ayuda { font-size: .82rem; color: var(--muted); margin-top: .2rem; }
.acciones { display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; margin-top: 1rem; }
.honeypot { position: absolute; left: -9999px; height: 0; overflow: hidden; }

.alerta { padding: .7rem 1rem; border-radius: 10px; margin-bottom: 1rem; font-weight: 500; }
.alerta-exito { background: var(--verde-fondo); color: var(--verde); }
.alerta-error { background: var(--rojo-fondo); color: var(--rojo); }
.alerta-info { background: var(--azul-fondo); color: var(--azul); }

.tarjeta { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radio); padding: 1.25rem; box-shadow: var(--sombra); margin-bottom: 1.25rem; }
.tarjeta > h2:first-child, .tarjeta > h3:first-child { margin-top: 0; }
.tarjeta h2 { font-size: 1.1rem; }

table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: .55rem .6rem; border-bottom: 1px solid var(--border); font-size: .92rem; vertical-align: top; }
th { color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; white-space: nowrap; }
tbody tr:hover { background: var(--surface-2); }
.tabla-scroll { overflow-x: auto; }

.badge { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .76rem; font-weight: 700; white-space: nowrap; }
.badge-pendiente { background: var(--ambar-fondo); color: var(--ambar); }
.badge-confirmada { background: var(--azul-fondo); color: var(--azul); }
.badge-atendida, .badge-activo, .badge-completado, .badge-verde { background: var(--verde-fondo); color: var(--verde); }
.badge-cancelada, .badge-cancelado, .badge-rojo, .badge-inactivo { background: var(--rojo-fondo); color: var(--rojo); }
.badge-no_asistio, .badge-gris { background: var(--gris-fondo); color: var(--gris); }
.badge-ambar { background: var(--ambar-fondo); color: var(--ambar); }
.badge-web { background: var(--coral-tint); color: #b23c22; }

/* ---------- Panel privado ---------- */
.layout { display: flex; min-height: 100vh; }
.sidebar { width: 232px; flex-shrink: 0; background: var(--surface); border-right: 1px solid var(--border); padding: 1.1rem .9rem; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.sidebar .marca { display: flex; align-items: center; gap: .55rem; font-weight: 800; color: var(--accent-oscuro); line-height: 1.15; margin-bottom: 1.2rem; font-size: 1rem; }
.sidebar .marca img { width: 38px; height: 38px; }
.sidebar nav a { display: block; padding: .5rem .75rem; border-radius: 10px; color: var(--fg); font-weight: 600; font-size: .93rem; margin-bottom: .1rem; }
.sidebar nav a:hover { background: var(--surface-2); text-decoration: none; }
.sidebar nav a.activo { background: var(--accent-tint); color: var(--accent-oscuro); }
.sidebar .grupo { font-size: .7rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin: 1rem .75rem .3rem; font-weight: 700; }
.sidebar .usuario { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--border); font-size: .88rem; }
.contenido { flex: 1; padding: 1.5rem 2rem 3rem; min-width: 0; max-width: 1180px; }
.contenido > h1 { margin: 0 0 .25rem; font-size: 1.7rem; }
.contenido > h1::after { content: ""; display: block; width: 52px; height: 4px; background: var(--accent); border-radius: 2px; margin-top: 6px; }
.subtitulo { color: var(--muted); margin: .5rem 0 1.25rem; }
.cabecera-pagina { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.cabecera-pagina h1 { margin: 0; }
.barra-movil { display: none; }

.cifras { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 1rem; margin-bottom: 1.25rem; }
.cifra { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radio); padding: 1rem 1.1rem; box-shadow: var(--sombra); }
.cifra .n { font-size: 1.7rem; font-weight: 800; color: var(--accent-oscuro); }
.cifra .t { font-size: .82rem; color: var(--muted); font-weight: 600; }
.dos-col { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 1.25rem; }
.barra { height: 9px; background: var(--gris-fondo); border-radius: 99px; overflow: hidden; }
.barra > span { display: block; height: 100%; background: var(--accent); }
.item-barra { margin-bottom: .8rem; font-size: .9rem; }
.item-barra .cab { display: flex; justify-content: space-between; margin-bottom: 2px; }

/* Ficha del paciente */
.ficha-cabecera { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; }
.avatar { width: 56px; height: 56px; border-radius: 50%; background: var(--accent-tint); color: var(--accent-oscuro); display: grid; place-items: center; font-weight: 800; font-size: 1.2rem; }
.subnav { display: flex; gap: .3rem; flex-wrap: wrap; margin: 1rem 0 1.25rem; border-bottom: 2px solid var(--border); }
.subnav a { padding: .55rem 1rem; font-weight: 700; color: var(--muted); border-bottom: 3px solid transparent; margin-bottom: -2px; font-size: .92rem; }
.subnav a.activo { color: var(--accent-oscuro); border-color: var(--accent); }
.subnav a:hover { text-decoration: none; color: var(--accent-oscuro); }
.datos { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: .8rem 1.5rem; }
.datos dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 700; }
.datos dd { margin: 0 0 .1rem; font-weight: 500; }
.eva { display: inline-block; min-width: 28px; text-align: center; padding: 1px 8px; border-radius: 8px; font-weight: 800; }
.eva.verde { background: var(--verde-fondo); color: var(--verde); }
.eva.ambar { background: var(--ambar-fondo); color: var(--ambar); }
.eva.rojo { background: var(--rojo-fondo); color: var(--rojo); }
.soap { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: .8rem; }
.soap > div { background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: .6rem .8rem; }
.soap b { color: var(--accent-oscuro); }
.pre { white-space: pre-wrap; }

/* Agenda */
.filtros { display: flex; gap: .6rem; flex-wrap: wrap; align-items: flex-end; margin-bottom: 1rem; }
.filtros > div { min-width: 140px; }
.vistas a { padding: .35rem .9rem; border-radius: 999px; font-weight: 700; font-size: .88rem; color: var(--muted); border: 1px solid var(--border); background: #fff; }
.vistas a.activo { background: var(--accent); color: #fff; border-color: var(--accent); }
.vistas a:hover { text-decoration: none; }
.cal { border: 1px solid var(--border); border-radius: var(--radio); overflow: auto; background: #fff; }
.cal table { table-layout: fixed; min-width: 720px; }
.cal th { text-align: center; background: var(--surface-2); position: sticky; top: 0; }
.cal td { border: 1px solid #eef3f3; padding: 2px 4px; height: 34px; vertical-align: top; font-size: .8rem; }
.cal td.hora { width: 56px; color: var(--muted); font-weight: 700; text-align: right; background: var(--surface-2); }
.cal td.hoy, .cal th.hoy { background: #f0fbf9; }
.chip { display: block; border-left: 4px solid var(--accent); background: var(--accent-tint); border-radius: 6px; padding: 1px 6px; margin: 1px 0; color: var(--fg); font-size: .78rem; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chip:hover { text-decoration: none; filter: brightness(.96); }
.chip.pendiente { background: var(--ambar-fondo); }
.chip.cancelada, .chip.no_asistio { opacity: .5; text-decoration: line-through; }
.chip.atendida { background: var(--verde-fondo); }
.mes { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radio); overflow: hidden; }
.mes .cab { background: var(--surface-2); text-align: center; padding: .4rem; font-weight: 700; font-size: .78rem; color: var(--muted); }
.mes .dia { background: #fff; min-height: 96px; padding: 4px 6px; font-size: .78rem; }
.mes .dia.vacio { background: var(--surface-2); }
.mes .dia.hoy { background: #f0fbf9; }
.mes .dia .num { font-weight: 800; color: var(--muted); display: block; margin-bottom: 2px; }
.mes .dia a.mas { font-size: .74rem; font-weight: 700; }
.horas { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .4rem; }
.horas label { margin: 0; }
.horas input { position: absolute; opacity: 0; width: 0; }
.horas span { display: inline-block; padding: .35rem .8rem; border: 1px solid var(--border); border-radius: 999px; font-weight: 700; cursor: pointer; background: #fff; font-size: .9rem; }
.horas input:checked + span { background: var(--accent); color: #fff; border-color: var(--accent); }
.horas input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.horas span:hover { background: var(--accent-tint); }
.horas input:checked + span:hover { background: var(--accent-oscuro); }

/* Sugerencias de búsqueda */
.sugerencias { position: absolute; z-index: 20; background: #fff; border: 1px solid var(--border); border-radius: 10px; box-shadow: var(--sombra); width: 100%; max-height: 240px; overflow: auto; }
.sugerencias button { display: block; width: 100%; text-align: left; border: 0; border-radius: 0; background: #fff; color: var(--fg); font-weight: 500; padding: .5rem .8rem; }
.sugerencias button:hover { background: var(--accent-tint); }
.rel { position: relative; }

/* ---------- Visor 3D ---------- */
.visor { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(300px, 1fr); gap: 1.25rem; align-items: start; }
.lienzo-3d { position: relative; background: linear-gradient(180deg, #eaf6f5, #d9ecea); border: 1px solid var(--border); border-radius: var(--radio); overflow: hidden; height: min(78vh, 720px); min-height: 460px; touch-action: none; cursor: grab; }
.lienzo-3d:active { cursor: grabbing; }
.lienzo-3d canvas { display: block; width: 100%; height: 100%; }
.lienzo-3d .tip { position: absolute; pointer-events: none; background: rgba(20, 40, 43, .9); color: #fff; padding: 4px 10px; border-radius: 8px; font-size: .8rem; font-weight: 600; transform: translate(12px, 12px); white-space: nowrap; }
.lienzo-3d .vistas-rapidas { position: absolute; top: 10px; left: 10px; display: flex; gap: 4px; flex-wrap: wrap; }
.lienzo-3d .vistas-rapidas button { padding: .25rem .7rem; font-size: .78rem; background: rgba(255,255,255,.92); color: var(--accent-oscuro); border-color: var(--border); }
.lienzo-3d .vistas-rapidas button.activo { background: var(--accent); color: #fff; }
.lienzo-3d .leyenda { position: absolute; bottom: 10px; left: 10px; right: 10px; display: flex; gap: .8rem; align-items: center; font-size: .75rem; font-weight: 700; color: var(--accent-oscuro); flex-wrap: wrap; }
.gradiente-eva { width: 110px; height: 9px; border-radius: 9px; background: linear-gradient(90deg, #37b26c, #f2c94c, #e5484d); border: 1px solid rgba(0,0,0,.1); }
.marca-lado { position: absolute; top: 10px; right: 12px; font-weight: 800; font-size: .8rem; color: var(--accent-oscuro); background: rgba(255,255,255,.9); border-radius: 8px; padding: 2px 8px; }
.modos { display: flex; gap: .4rem; margin-bottom: .8rem; }
.modos button { flex: 1; justify-content: center; }
.modos button.sec.activo-malestar { background: #fdeceb; border-color: var(--rojo); color: var(--rojo); }
.modos button.sec.activo-trat { background: var(--accent-tint); border-color: var(--accent); color: var(--accent-oscuro); }
.zona-item { display: flex; justify-content: space-between; align-items: center; gap: .5rem; padding: .4rem .6rem; border: 1px solid var(--border); border-radius: 10px; margin-bottom: .35rem; font-size: .86rem; background: #fff; }
.zona-item .x { border: 0; background: transparent; color: var(--danger); padding: 0 .3rem; font-size: 1.1rem; }
.zona-item .x:hover { background: var(--rojo-fondo); }
.punto { width: 11px; height: 11px; border-radius: 50%; display: inline-block; margin-right: 4px; }
.comparador { position: relative; max-width: 100%; overflow: hidden; border-radius: 12px; border: 1px solid var(--border); background: #fff; user-select: none; }
.comparador img { display: block; width: 100%; height: auto; }
.comparador .capa { position: absolute; inset: 0; overflow: hidden; }
.comparador .capa img { width: 100%; max-width: none; height: 100%; object-fit: fill; }
.comparador input[type=range] { position: absolute; inset: auto 0 0 0; width: 100%; opacity: .0; height: 100%; cursor: ew-resize; }
.comparador .linea { position: absolute; top: 0; bottom: 0; width: 3px; background: var(--coral); pointer-events: none; }
.comparador .et { position: absolute; top: 8px; background: rgba(255,255,255,.92); padding: 2px 9px; border-radius: 8px; font-weight: 800; font-size: .78rem; }

/* ---------- Login ---------- */
.caja-login { max-width: 400px; margin: 8vh auto; padding: 0 1rem; }
.caja-login .logo { text-align: center; margin-bottom: 1rem; }
.caja-login .logo img { width: 72px; height: 72px; }
.caja-login h1 { text-align: center; font-size: 1.4rem; margin: .4rem 0 1rem; }

/* ---------- Sitio público ---------- */
.pub { background: #fff; }
.pub .contenedor { max-width: 1120px; margin: 0 auto; padding: 0 1.25rem; }
.navbar { position: sticky; top: 0; z-index: 30; background: rgba(255,255,255,.94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--border); }
.navbar .contenedor { display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: 66px; }
.navbar .marca { display: flex; align-items: center; gap: .6rem; font-weight: 800; color: var(--accent-oscuro); font-size: 1.02rem; line-height: 1.1; }
.navbar .marca img { width: 40px; height: 40px; }
.navbar .marca:hover { text-decoration: none; }
.navbar nav { display: flex; align-items: center; gap: 1.2rem; }
.navbar nav a { font-weight: 600; color: var(--fg); font-size: .93rem; }
.navbar nav a.btn { color: #fff; }
.hero { background: radial-gradient(1200px 500px at 85% -10%, #c9efe9 0, transparent 60%), linear-gradient(180deg, #f2fbfa, #fff); padding: 4rem 0 3rem; }
.hero .contenedor { display: grid; grid-template-columns: 1.15fr .85fr; gap: 2rem; align-items: center; }
.hero h1 { font-size: clamp(2rem, 4.2vw, 3.2rem); margin: .3rem 0 1rem; letter-spacing: -.02em; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero p.lead { font-size: 1.12rem; color: var(--muted); max-width: 34rem; }
.etiqueta { display: inline-block; background: var(--accent-tint); color: var(--accent-oscuro); font-weight: 700; padding: 4px 14px; border-radius: 999px; font-size: .82rem; }
.hero .cta { display: flex; gap: .8rem; flex-wrap: wrap; margin-top: 1.5rem; }
.hero .ilustracion { display: grid; place-items: center; }
.hero .ilustracion svg { width: min(100%, 340px); filter: drop-shadow(0 16px 30px rgba(14, 143, 138, .25)); }
.seccion { padding: 4rem 0; }
.seccion.alt { background: var(--surface-2); }
.seccion h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin: 0 0 .5rem; }
.seccion .intro { color: var(--muted); max-width: 40rem; margin-bottom: 2rem; }
.servicios { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1.1rem; }
.servicio { background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 1.3rem; transition: transform .15s, box-shadow .15s; }
.servicio:hover { transform: translateY(-3px); box-shadow: var(--sombra); }
.servicio .ico { width: 46px; height: 46px; border-radius: 14px; background: var(--accent-tint); color: var(--accent-oscuro); display: grid; place-items: center; margin-bottom: .8rem; }
.servicio .ico svg { width: 26px; height: 26px; }
.servicio h3 { margin: 0 0 .3rem; font-size: 1.02rem; }
.servicio p { margin: 0 0 .8rem; color: var(--muted); font-size: .92rem; }
.servicio .dur { font-size: .8rem; font-weight: 700; color: var(--accent-oscuro); }
.pasos { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.2rem; counter-reset: paso; }
.paso { position: relative; padding: 1.2rem 1.2rem 1.2rem 4rem; background: #fff; border: 1px solid var(--border); border-radius: 18px; }
.paso::before { counter-increment: paso; content: counter(paso); position: absolute; left: 1.1rem; top: 1.1rem; width: 2.1rem; height: 2.1rem; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-weight: 800; }
.paso b { display: block; }
.equipo { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1.1rem; }
.miembro { background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 1.3rem; text-align: center; }
.miembro .avatar { margin: 0 auto .7rem; width: 74px; height: 74px; font-size: 1.6rem; }
.contacto-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 1.5rem; align-items: stretch; }
.contacto-grid iframe, .mapa-vacio { width: 100%; height: 100%; min-height: 280px; border: 0; border-radius: 18px; background: var(--accent-tint); display: grid; place-items: center; color: var(--accent-oscuro); font-weight: 600; text-align: center; padding: 1rem; }
.footer { background: #0e3f41; color: #cfe6e4; padding: 2.5rem 0 1.5rem; font-size: .92rem; }
.footer a { color: #9fe3da; }
.footer .cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.5rem; margin-bottom: 1.5rem; }
.footer h4 { color: #fff; margin: 0 0 .5rem; }
.wa-flotante { position: fixed; right: 18px; bottom: 18px; z-index: 40; width: 58px; height: 58px; border-radius: 50%; background: #25d366; display: grid; place-items: center; box-shadow: 0 6px 18px rgba(0,0,0,.25); }
.wa-flotante svg { width: 32px; height: 32px; fill: #fff; }
.wa-flotante:hover { transform: scale(1.06); }

/* Reserva en línea */
.reservar { max-width: 780px; margin: 2rem auto 4rem; padding: 0 1.25rem; }
.reservar h1 { margin: 0 0 .3rem; }
.paso-res { background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 1.25rem; margin-bottom: 1rem; box-shadow: var(--sombra); }
.paso-res > h2 { font-size: 1.05rem; margin: 0 0 .8rem; display: flex; align-items: center; gap: .6rem; }
.paso-res > h2 .n { width: 1.8rem; height: 1.8rem; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-size: .9rem; }
.paso-res.bloqueado { opacity: .5; pointer-events: none; }
.resumen-reserva { background: var(--accent-tint); border-radius: 14px; padding: 1rem 1.2rem; }
.codigo { font-size: 2rem; font-weight: 800; letter-spacing: .18em; color: var(--accent-oscuro); background: #fff; display: inline-block; padding: .3rem 1rem; border-radius: 12px; border: 2px dashed var(--accent); }

/* ---------- Impresión / documentos ---------- */
.doc { background: #fff; max-width: 820px; margin: 1.5rem auto; padding: 2rem 2.4rem; border: 1px solid var(--border); border-radius: 8px; font-size: .95rem; }
.doc .enc { display: flex; justify-content: space-between; align-items: center; border-bottom: 3px solid var(--accent); padding-bottom: .8rem; margin-bottom: 1rem; gap: 1rem; }
.doc .enc img { width: 56px; height: 56px; }
.doc h1 { font-size: 1.35rem; margin: 0; } .doc h1::after { display: none; }
.doc h2 { font-size: 1.05rem; color: var(--accent-oscuro); border-bottom: 1px solid var(--border); padding-bottom: .2rem; margin-top: 1.4rem; }
.doc .mapa-img { max-width: 100%; border: 1px solid var(--border); border-radius: 8px; }
.doc .firma { margin-top: 3.5rem; text-align: center; width: 260px; border-top: 1px solid #000; padding-top: .3rem; font-size: .85rem; }
.barra-doc { max-width: 820px; margin: 1rem auto 0; display: flex; gap: .6rem; }

@media print {
  body { background: #fff; }
  .sidebar, .barra-movil, .barra-doc, .no-imprimir, .navbar, .wa-flotante, .subnav, .alerta { display: none !important; }
  .layout { display: block; }
  .contenido { padding: 0; max-width: none; }
  .doc { border: 0; box-shadow: none; margin: 0; padding: 0; max-width: none; }
  .doc h2 { break-after: avoid; }
  .doc .bloque { break-inside: avoid; }
  .solo-imprimir { display: block; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero .contenedor { grid-template-columns: 1fr; }
  .hero .ilustracion { order: -1; }
  .contacto-grid { grid-template-columns: 1fr; }
  .visor { grid-template-columns: 1fr; }
  .lienzo-3d { height: 62vh; min-height: 380px; }
}
@media (max-width: 820px) {
  .layout { display: block; }
  .barra-movil { display: flex; align-items: center; justify-content: space-between; background: var(--surface); border-bottom: 1px solid var(--border); padding: .6rem 1rem; position: sticky; top: 0; z-index: 30; }
  .barra-movil .marca { display: flex; align-items: center; gap: .5rem; font-weight: 800; color: var(--accent-oscuro); }
  .barra-movil .marca img { width: 32px; height: 32px; }
  .sidebar { display: none; position: fixed; inset: 0; width: 100%; height: 100%; z-index: 50; }
  .sidebar.abierto { display: flex; }
  .contenido { padding: 1rem 1rem 3rem; }
  .navbar nav a:not(.btn) { display: none; }
  .doc { padding: 1.2rem; }
}
