:root {
--verde: #1FA971;
--verde-oscuro: #17875a;
--texto: #1c2621;
--texto-suave: #5b6a63;
--fondo: #ffffff;
--fondo-suave: #f4f8f6;
--borde: #dfe9e4;
--error: #c0392b;
--radio: 14px;
--fuente: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
font-family: var(--fuente);
color: var(--texto);
background: var(--fondo);
margin: 0;
}

.btn-pill {
display: inline-flex;
align-items: center;
justify-content: center;
gap: 10px;
background: var(--verde);
color: #fff;
font-weight: 700;
border: none;
border-radius: 10px !important;
padding: 16px 40px !important;
font-size: 1rem;
cursor: pointer;
transition: background 0.15s ease, transform 0.1s ease;
}
.btn-pill:hover { background: var(--verde-oscuro); }
.btn-pill:active { transform: scale(0.98); }
.btn-pill:disabled { background: #b7c4bd; cursor: not-allowed; }

.btn-pill.secundario {
background: transparent;
color: var(--verde-oscuro);
border: 2px solid var(--verde);
}
.btn-pill.secundario:hover { background: var(--fondo-suave); }

/* ---------- Admin ---------- */
.admin-body { background: var(--fondo-suave); }
.admin-login-box {
max-width: 360px;
margin: 12vh auto;
background: #fff;
padding: 32px;
border-radius: var(--radio);
border: 1px solid var(--borde);
}
.admin-login-box h1 { font-size: 1.3rem; margin-top: 0; }
.admin-login-box form { display: flex; flex-direction: column; gap: 12px; }
.admin-login-box input { padding: 12px; border-radius: 10px; border: 1px solid var(--borde); font-size: 1rem; }
.admin-error { color: var(--error); font-size: 0.9rem; }

.admin-panel { max-width: 720px; margin: 40px auto; padding: 0 20px 60px; }
.admin-tabs {
display: flex;
align-items: center;
gap: 4px;
border-bottom: 1px solid var(--borde);
margin-bottom: 24px;
position: sticky;
top: 0;
background: var(--fondo-suave);
padding-top: 12px;
z-index: 5;
}
.admin-tab {
color: var(--texto-suave);
text-decoration: none;
font-size: 0.9rem;
font-weight: 600;
padding: 10px 16px;
border-radius: 8px 8px 0 0;
border-bottom: 2px solid transparent;
}
.admin-tab:hover { background: #fff; color: var(--texto); }
.admin-tab.activa { color: var(--verde-oscuro); border-bottom: 2px solid var(--verde); background: #fff; }
.admin-tab.salir { margin-left: auto; color: var(--error); }
.admin-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; }
.link-salir { color: var(--texto-suave); text-decoration: none; font-size: 0.9rem; }
.admin-msg { background: var(--fondo-suave); border: 1px solid var(--borde); padding: 10px 14px; border-radius: 10px; }

fieldset { border: 1px solid var(--borde); border-radius: var(--radio); padding: 16px 20px; margin-bottom: 20px; }
legend { font-weight: 700; padding: 0 8px; }
fieldset label { display: block; margin: 8px 0; font-size: 0.9rem; color: var(--texto-suave); }
fieldset input, fieldset select { padding: 8px 10px; border-radius: 8px; border: 1px solid var(--borde); font-size: 0.95rem; margin-top: 4px; }
label.chk { display: inline-flex; align-items: center; gap: 6px; margin-right: 14px; width: auto; }

.fila-doble, .fila-excepcion { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; }
.btn-quitar { background: none; border: none; color: var(--error); cursor: pointer; font-size: 0.85rem; }
.btn-agregar { background: none; border: 1px dashed var(--verde); color: var(--verde-oscuro); border-radius: 10px; padding: 8px 14px; cursor: pointer; margin-top: 6px; }
.btn-guardar { margin-top: 10px; }

.tabla-campos { width: 100%; border-collapse: collapse; margin-top: 16px; }
.tabla-campos th, .tabla-campos td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--borde); font-size: 0.9rem; }

/* ---------- Selector público ---------- */
.selector-wrap { max-width: 560px; margin: 0 auto; padding: 24px 16px 60px; }
.selector-paso { display: none; }
.selector-paso.activo { display: block; }

.selector-titulo { font-size: 1.4rem; margin-bottom: 4px; }
.selector-subtitulo { color: var(--texto-suave); margin-bottom: 24px; }

.mes-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.mes-nav button { background: var(--fondo-suave); border: none; border-radius: 8px; width: 36px; height: 36px; cursor: pointer; font-size: 1.1rem; }
.mes-nav span { font-weight: 700; text-transform: capitalize; }

.grilla-dias { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin-bottom: 24px; }
.grilla-dias .etiqueta-dia { text-align: center; font-size: 0.75rem; color: var(--texto-suave); padding-bottom: 4px; }
.dia-celda {
aspect-ratio: 1;
display: flex;
align-items: center;
justify-content: center;
border-radius: 10px;
font-size: 0.9rem;
cursor: pointer;
border: 1px solid transparent;
background: var(--fondo-suave);
}
.dia-celda.vacio { background: none; cursor: default; }
.dia-celda.deshabilitado { color: #c3cdc7; cursor: not-allowed; background: none; }
.dia-celda.disponible:hover { border-color: var(--verde); }
.dia-celda.seleccionado { background: var(--verde); color: #fff; font-weight: 700; }

.grilla-horarios { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 24px; }
.horario-btn {
position: relative;
padding: 12px 6px;
border-radius: 10px;
border: 1px solid var(--borde);
background: #fff;
cursor: pointer;
font-size: 0.95rem;
}
.horario-btn:hover { border-color: var(--verde); }
.horario-btn.seleccionado { background: var(--verde); color: #fff; border-color: var(--verde); font-weight: 700; }
.horario-nota {
display: block;
font-size: 0.65rem;
font-weight: 400;
color: var(--texto-suave);
margin-top: 2px;
}
.horario-btn.seleccionado .horario-nota { color: rgba(255,255,255,0.85); }

.campo-huso { margin-bottom: 20px; }
.campo-huso select { max-width: 100%; }

.campo { margin-bottom: 16px; }
.campo label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 0.9rem; }
.campo input, .campo select, .campo textarea {
width: 100%;
padding: 12px 14px;
border-radius: 10px;
border: 1px solid var(--borde);
font-size: 1rem;
font-family: var(--fuente);
}
.campo textarea { resize: vertical; }

.campo-mitad-grupo { display: flex; gap: 12px; }
.campo-mitad { flex: 1; margin-bottom: 0; }

.radio-grupo { display: flex; flex-direction: column; gap: 8px; }
.radio-opcion {
display: flex;
align-items: center;
gap: 10px;
padding: 10px 14px;
border: 1px solid var(--borde);
border-radius: 10px;
font-weight: 400;
font-size: 0.95rem;
cursor: pointer;
}
.radio-opcion:has(input:checked) { border-color: var(--verde); background: var(--fondo-suave); }
.radio-opcion input { margin: 0; width: auto; }

.acuerdo-box {
background: var(--fondo-suave);
border: 1px solid var(--borde);
border-radius: var(--radio);
padding: 16px;
max-height: 260px;
overflow-y: auto;
font-size: 0.85rem;
line-height: 1.5;
margin-bottom: 14px;
}

.acuerdo-check { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 20px; font-size: 0.9rem; }
.acuerdo-check input { margin-top: 3px; }

.resumen-turno {
background: var(--fondo-suave);
border-radius: var(--radio);
padding: 16px;
margin-bottom: 20px;
font-size: 0.95rem;
}

.mensaje-error { color: var(--error); font-size: 0.9rem; margin-bottom: 12px; }

.acciones-paso { display: flex; gap: 12px; margin-top: 8px; }

.confirmacion { text-align: center; padding: 40px 0; }
.confirmacion .icono-ok { width: 56px; height: 56px; margin: 0 auto 16px; }

/* ==========================================================================
INTEGRACIÓN CON LA MARCA DEL SITIO (jplbio.com) — SOLO FORMULARIO PÚBLICO
========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@500;600&family=Inter:wght@400;500&display=swap');

/*
Estas variables se reescriben ÚNICAMENTE dentro de .selector-wrap.
Como todas las reglas de arriba (.btn-pill, .campo, .radio-opcion,
.horario-btn, .acuerdo-box, etc.) ya usan var(--verde), var(--fondo-suave),
etc., heredan estos valores nuevos automáticamente acá adentro — sin
reescribir ninguna regla, y sin afectar nada de .admin-*, que sigue usando
las variables originales de arriba tal como estaban.
*/
.selector-wrap {
--verde: #1FA971;
--verde-oscuro: #178a5b;
--texto: #2C2C2A;
--texto-suave: #5F5E5A;
--fondo-suave: #E8DCC2;
--borde: rgba(166, 135, 79, 0.35);
--fuente: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

background: #F7F3EA; /* blanco hueso — igual que el fondo de la página, sin recuadro relleno */
border: 1px solid #A6874F;
border-radius: 4px;
max-width: 620px;
margin: 48px auto 40px;
padding: 40px 36px 56px;
}

.selector-wrap .selector-titulo {
font-family: 'Cormorant Garamond', Georgia, serif;
font-weight: 600;
color: #1C2373; /* --color-azul-noche */
}

.selector-wrap .mensaje-error {
color: #B33A2E; /* tono cálido, coherente con la paleta, en vez del rojo genérico */
}

@media (max-width: 768px) {
.selector-wrap {
margin: 24px auto 32px;
padding: 28px 20px 40px;
border-radius: 0;
}
}
