/* ============================================================
   RADOX — Formularios digitales (orden de estudios y consentimiento)
   ------------------------------------------------------------
   Se llenan en pantalla y se descargan en PDF con la impresión del
   navegador. No se envían ni se guardan en ningún lado.

   Hecho a partir de la maqueta que entregó RADOX (radoxFormulario.zip,
   nov 2026), sin nada de su código: HTML estático, esta hoja y
   formularios.js, igual que el resto del sitio.
   ============================================================ */
:root {
  --navy: #041d45; --navy-2: #0a2a5c; --teal: #059498; --teal-glow: #5ccfd2;
  --tinta: #1e293b; --gris: #64748b; --borde: #e2e8f0; --fondo: #f4f8fc; --acento: #e6f6f6;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Plus Jakarta Sans', system-ui, sans-serif; color: var(--tinta); background: var(--fondo); -webkit-text-size-adjust: 100%; }
a { color: inherit; }
button { font: inherit; }

/* ---------- portada de los formularios ---------- */
.fm-hero { background: linear-gradient(120deg, #021230, var(--navy) 60%, #0b3a64); color: white; }
.fm-hero-in { max-width: 1000px; margin: 0 auto; padding: 22px 22px 110px; }
.fm-volver { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; color: rgba(255,255,255,.75); text-decoration: none; }
.fm-volver:hover { color: white; }
.fm-logo { display: block; height: 58px; width: auto; margin-top: 34px; }
.fm-hero h1 { margin-top: 34px; font-size: clamp(34px, 6vw, 52px); font-weight: 800; line-height: 1.08; letter-spacing: -1px; }
.fm-hero h1 span { color: var(--teal-glow); }
.fm-hero p { margin-top: 14px; max-width: 560px; font-size: 16.5px; line-height: 1.65; color: rgba(255,255,255,.78); }
.fm-tarjetas { max-width: 1000px; margin: -72px auto 0; padding: 0 22px 60px; display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.fm-tarjeta { display: block; background: white; border: 1.5px solid var(--borde); border-radius: 22px; padding: 30px 28px; text-decoration: none; box-shadow: 0 10px 34px rgba(4,29,69,.09); transition: transform .2s, box-shadow .2s; }
.fm-tarjeta:hover { transform: translateY(-4px); box-shadow: 0 16px 44px rgba(4,29,69,.14); }
.fm-icono { width: 50px; height: 50px; border-radius: 14px; background: var(--acento); color: var(--teal); display: flex; align-items: center; justify-content: center; }
.fm-quien { margin-top: 20px; font-size: 11.5px; font-weight: 800; letter-spacing: 2px; text-transform: uppercase; color: var(--teal); }
.fm-tarjeta h2 { margin-top: 6px; font-size: 24px; font-weight: 800; color: var(--navy); letter-spacing: -.4px; }
.fm-tarjeta p { margin-top: 8px; font-size: 14.5px; line-height: 1.6; color: var(--gris); }
.fm-abrir { margin-top: 22px; display: inline-flex; align-items: center; gap: 8px; font-size: 14.5px; font-weight: 800; color: var(--teal); }
.fm-nota { max-width: 1000px; margin: 0 auto; padding: 0 22px 50px; font-size: 13px; color: var(--gris); text-align: center; line-height: 1.6; }

/* ---------- barra de herramientas ---------- */
.fm-barra { position: sticky; top: 0; z-index: 10; background: rgba(255,255,255,.94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--borde); }
.fm-barra-in { max-width: 1180px; margin: 0 auto; padding: 10px 16px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.fm-barra a { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; color: var(--gris); text-decoration: none; white-space: nowrap; }
.fm-barra a:hover { color: var(--navy); }
.fm-barra-titulo { font-size: 14px; font-weight: 800; color: var(--navy); }
.fm-botones { display: flex; gap: 8px; }
.fm-btn { display: inline-flex; align-items: center; gap: 7px; border-radius: 10px; padding: 9px 14px; font-size: 14px; font-weight: 700; cursor: pointer; border: 1.5px solid var(--borde); background: white; color: var(--tinta); white-space: nowrap; }
.fm-btn:hover { background: #f1f5f9; }
.fm-btn-pdf { background: var(--teal); border-color: var(--teal); color: white; }
.fm-btn-pdf:hover { background: #047d80; }

/* ---------- la hoja ---------- */
.fm-pagina { padding: 26px 12px 40px; }
.fm-hoja { max-width: 1180px; margin: 0 auto; background: white; border-radius: 20px; box-shadow: 0 8px 30px rgba(4,29,69,.08); overflow: hidden; }
.fm-ayuda { max-width: 1180px; margin: 14px auto 0; text-align: center; font-size: 12.5px; color: var(--gris); line-height: 1.6; }

.fm-cab { background: linear-gradient(120deg, #021230, var(--navy) 60%, #0b3a64); color: white; padding: 18px 24px; display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 22px; }
.fm-cab img { height: 54px; width: auto; display: block; }
.fm-cab-dato { display: flex; align-items: flex-start; gap: 8px; font-size: 13.5px; line-height: 1.45; }
.fm-cab-dato svg { flex-shrink: 0; margin-top: 2px; color: var(--teal-glow); }
.fm-cab-dato b, .fm-cab-horario b { color: var(--teal-glow); font-weight: 700; }
.fm-cab-centro { justify-self: center; }
.fm-cab-horario { text-align: right; font-size: 12.5px; line-height: 1.55; }

.fm-cuerpo { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 18px; }
.fm-campos { display: grid; grid-template-columns: repeat(12, 1fr); gap: 12px 22px; }
.fm-campo { display: flex; flex-direction: column; min-width: 0; }
.fm-campo span { font-size: 11px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; color: var(--gris); }
.fm-linea { width: 100%; border: 0; border-bottom: 1.5px solid #94a3b8; background: transparent; padding: 5px 2px; font: inherit; font-size: 15px; color: var(--tinta); outline: none; border-radius: 0; }
.fm-linea:focus { border-bottom-color: var(--teal); }
.c2 { grid-column: span 2; } .c3 { grid-column: span 3; } .c4 { grid-column: span 4; } .c5 { grid-column: span 5; } .c6 { grid-column: span 6; }

.fm-tres { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; align-items: start; }
.fm-col { display: flex; flex-direction: column; gap: 18px; }
.fm-sec { border: 2px solid rgba(5,148,152,.55); border-radius: 12px; overflow: hidden; background: white; break-inside: avoid; }
.fm-sec h3 { background: var(--navy); color: white; text-align: center; font-size: 11.5px; font-weight: 800; letter-spacing: 1.8px; text-transform: uppercase; padding: 8px 12px; }
.fm-sec-in { padding: 12px 14px; }
.fm-sub { margin: 4px 0 6px; font-size: 11px; font-weight: 800; letter-spacing: 1.6px; text-transform: uppercase; color: var(--teal); }
.fm-dos { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.fm-dos > div + div { border-left: 2px solid rgba(5,148,152,.45); padding-left: 12px; }

.fm-check { display: flex; align-items: center; gap: 10px; padding: 5px 6px; border-radius: 6px; font-size: 14px; cursor: pointer; line-height: 1.3; }
.fm-check:hover { background: var(--acento); }
.fm-check input { width: 18px; height: 18px; flex-shrink: 0; accent-color: var(--teal); }
.fm-otro { display: flex; align-items: center; gap: 4px; }
.fm-otro .fm-linea { font-size: 14px; }

/* odontograma: lo arma formularios.js */
.fm-odonto { border: 1px solid var(--borde); border-radius: 10px; padding: 10px 6px; display: flex; flex-direction: column; gap: 12px; overflow-x: auto; }
.fm-od-bloque { display: flex; flex-direction: column; gap: 4px; min-width: max-content; margin: 0 auto; }
.fm-od-etq { display: flex; justify-content: space-between; font-size: 10px; font-weight: 800; color: var(--gris); }
.fm-od-etq b { color: var(--teal); }
.fm-od-fila { display: flex; align-items: center; justify-content: center; gap: 3px; }
.fm-od-media { display: flex; gap: 1px; }
.fm-od-sep { width: 2px; height: 26px; background: var(--navy); }
.fm-od-linea { height: 2px; background: rgba(4,29,69,.7); }
.fm-diente { width: 17px; height: 26px; border: 0; border-radius: 5px; background: #e2e8f0; color: var(--tinta); font-size: 11px; font-weight: 800; cursor: pointer; padding: 0; }
.fm-diente:hover { background: var(--acento); }
.fm-diente[aria-pressed="true"] { background: var(--teal); color: white; }

.fm-obs { width: 100%; min-height: 84px; resize: vertical; border: 1.5px solid var(--borde); border-radius: 10px; padding: 10px 12px; font: inherit; font-size: 14.5px; outline: none; }
.fm-obs:focus { border-color: var(--teal); }
.fm-pie { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 22px; padding-top: 4px; font-size: 12.5px; color: var(--gris); }
.fm-pie p { font-weight: 600; max-width: 560px; }
.fm-firma { width: 260px; text-align: center; }
.fm-firma div { height: 46px; border-bottom: 2px solid rgba(4,29,69,.6); margin-bottom: 5px; }

/* consentimiento */
.fm-cons-arriba { display: grid; grid-template-columns: 2fr 1fr; gap: 18px; align-items: start; }
.fm-paquetes { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.fm-recos { list-style: none; display: flex; flex-direction: column; gap: 10px; font-size: 13.5px; line-height: 1.5; }
.fm-recos li { display: flex; gap: 9px; }
.fm-recos li::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--teal); flex-shrink: 0; margin-top: 7px; }
.fm-texto { display: grid; grid-template-columns: 1fr auto; gap: 20px; align-items: center; }
.fm-texto p { font-size: 14.5px; line-height: 1.7; }
.fm-texto p + p { margin-top: 10px; }
.fm-llegar { display: flex; align-items: center; gap: 12px; background: var(--acento); color: var(--navy); border-radius: 14px; padding: 16px; width: 250px; font-size: 13.5px; line-height: 1.5; }
.fm-llegar svg { flex-shrink: 0; color: var(--teal); }
.fm-datos { border: 2px solid rgba(5,148,152,.55); border-radius: 12px; padding: 14px 16px; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 22px; }

/* ---------- tableta y celular ---------- */
@media (max-width: 960px) {
  .fm-tres { grid-template-columns: 1fr 1fr; }
  .fm-cab { grid-template-columns: auto 1fr; }
  .fm-cab-centro { justify-self: start; }
  .fm-cab-horario { text-align: left; }
  .fm-cons-arriba { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .fm-tarjetas { grid-template-columns: 1fr; margin-top: -80px; }
  .fm-hero-in { padding-bottom: 104px; }
  .fm-barra-titulo { display: none; }
  .fm-btn { padding: 9px 11px; font-size: 13.5px; }
  .fm-btn .fm-solo-ancho { display: none; }
  .fm-pagina { padding: 14px 8px 30px; }
  .fm-cab { grid-template-columns: 1fr; gap: 12px; padding: 16px 18px; }
  .fm-cab img { height: 46px; }
  .fm-cuerpo { padding: 16px 14px 20px; gap: 14px; }
  .fm-campos { grid-template-columns: 1fr 1fr; }
  .c2, .c3 { grid-column: span 1; } .c4, .c5, .c6 { grid-column: span 2; }
  .fm-tres, .fm-paquetes, .fm-texto, .fm-datos { grid-template-columns: 1fr; }
  .fm-col { gap: 14px; }
  .fm-dos { grid-template-columns: 1fr; }
  .fm-dos > div + div { border-left: 0; padding-left: 0; border-top: 2px solid rgba(5,148,152,.35); padding-top: 8px; }
  .fm-llegar { width: auto; }
  .fm-firma { width: 100%; }
  .fm-diente { width: 17px; }
}

/* ---------- impresión / PDF ---------- */
@media print {
  @page { size: letter landscape; margin: 6mm; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  body { background: white; }
  .fm-barra, .fm-ayuda { display: none !important; }
  .fm-pagina { padding: 0; }
  .fm-hoja { box-shadow: none; border-radius: 0; max-width: none; width: 1180px; zoom: var(--zoom-impresion, .8); }
  .fm-cab { grid-template-columns: auto 1fr auto auto; padding: 10px 18px; }
  .fm-cab-centro { justify-self: center; } .fm-cab-horario { text-align: right; }
  .fm-cuerpo { padding: 12px 16px; gap: 10px; }
  .fm-campos { grid-template-columns: repeat(12, 1fr); gap: 4px 18px; }
  .c2 { grid-column: span 2; } .c3 { grid-column: span 3; } .c4 { grid-column: span 4; } .c5 { grid-column: span 5; } .c6 { grid-column: span 6; }
  .fm-tres { grid-template-columns: repeat(3, 1fr); gap: 10px; }
  .fm-col { gap: 10px; }
  .fm-cons-arriba { grid-template-columns: 2fr 1fr; gap: 10px; }
  .fm-paquetes, .fm-datos, .fm-dos { grid-template-columns: 1fr 1fr; gap: 10px; }
  .fm-texto { grid-template-columns: 1fr auto; }
  .fm-sec-in { padding: 7px 10px; }
  .fm-check { padding: 1px 4px; font-size: 12px; }
  .fm-check input { width: 13px; height: 13px; }
  .fm-obs { min-height: 54px; resize: none; }
  .fm-odonto { overflow: visible; }
}
