/* =====================================================================
   INSPECTIA · Sistema visual v1.2 (sobre Bootstrap 5.3)
   Línea gráfica de ingeniería: grafito y acero como base, amarillo de
   seguridad como acento principal, naranja como acento secundario.
   Contraste verificado (WCAG 2.1 AA): textos >= 4.5:1, bordes de campos >= 3:1.
   ===================================================================== */

@font-face {
    font-family: "Inter";
    src: url("../fonts/InterVariable.woff2") format("woff2");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

:root {
    /* Grafito y acero */
    --g-950: #0B0E12;
    --g-900: #12161C;
    --g-850: #171C23;
    --g-800: #1E242C;
    --g-700: #2A313B;
    --g-600: #3A4350;
    --acero-500: #5B6675;
    --acero-400: #7D8A9A;
    --gris-600: #4B5563;
    --gris-500: #6B7280;
    --gris-400: #8A929D;
    --gris-300: #C9CFD6;
    --gris-200: #E2E5E9;
    --gris-100: #EEF0F3;
    --fondo: #F4F5F7;
    /* Acentos */
    --amarillo: #F5B014;
    --amarillo-hover: #E3A20C;
    --amarillo-suave: #FDF3DA;
    --naranja: #E8730C;
    --naranja-hover: #D4660A;
    --naranja-texto: #B45309;
    --verde: #166534;
    --verde-claro: #2FB36B;
    --verde-suave: #E3F5EA;
    --rojo: #B42318;
    --rojo-suave: #FDE8E6;
    /* Forma */
    --radio: 4px;
    --radio-md: 6px;
    --sombra: 0 1px 2px rgba(18, 22, 28, .05);
    --sombra-lg: 0 12px 32px rgba(18, 22, 28, .12);
    --mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, "DejaVu Sans Mono", monospace;

    --bs-body-font-family: "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --bs-body-color: #12161C;
    --bs-body-bg: #FFFFFF;
    --bs-secondary-color: #4B5563;
    --bs-border-color: #E2E5E9;
    --bs-link-color: #B45309;
    --bs-link-color-rgb: 180, 83, 9;
    --bs-link-hover-color: #12161C;
    --bs-link-hover-color-rgb: 18, 22, 28;
    --bs-border-radius: 4px;
    --bs-border-radius-sm: 3px;
    --bs-border-radius-lg: 6px;
}

body { font-optical-sizing: auto; -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4, .titulo-seccion { letter-spacing: -.015em; }
.text-secondary { color: var(--gris-600) !important; }
.text-naranja { color: var(--naranja-texto) !important; }
a { text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--amarillo); outline-offset: 2px; }
.mono { font-family: var(--mono); }

/* ---------------------------------------------------------------- Botones */
.btn { font-weight: 600; border-radius: var(--radio); padding: .62rem 1.2rem; letter-spacing: -.005em; }
.btn-lg { padding: .85rem 1.6rem; font-size: 1rem; border-radius: var(--radio); }
.btn-sm { padding: .38rem .8rem; border-radius: 3px; }
.btn-insp {
    --bs-btn-color: #12161C; --bs-btn-bg: #F5B014; --bs-btn-border-color: #F5B014;
    --bs-btn-hover-color: #12161C; --bs-btn-hover-bg: #E3A20C; --bs-btn-hover-border-color: #E3A20C;
    --bs-btn-active-color: #12161C; --bs-btn-active-bg: #CF9208; --bs-btn-active-border-color: #CF9208;
    --bs-btn-disabled-color: #12161C; --bs-btn-disabled-bg: #F8CD6A; --bs-btn-disabled-border-color: #F8CD6A;
    --bs-btn-focus-shadow-rgb: 245, 176, 20;
}
.btn-insp-naranja {
    --bs-btn-color: #12161C; --bs-btn-bg: #E8730C; --bs-btn-border-color: #E8730C;
    --bs-btn-hover-color: #12161C; --bs-btn-hover-bg: #D4660A; --bs-btn-hover-border-color: #D4660A;
    --bs-btn-active-color: #12161C; --bs-btn-active-bg: #BF5B08;
}
.btn-insp-oscuro {
    --bs-btn-color: #fff; --bs-btn-bg: #12161C; --bs-btn-border-color: #12161C;
    --bs-btn-hover-color: #fff; --bs-btn-hover-bg: #2A313B; --bs-btn-hover-border-color: #2A313B;
    --bs-btn-active-color: #fff; --bs-btn-active-bg: #000;
}
.btn-outline-dark { --bs-btn-border-color: #8A929D; --bs-btn-color: #12161C; --bs-btn-hover-bg: #12161C; --bs-btn-hover-border-color: #12161C; }
.btn-linea-clara { --bs-btn-color: #fff; --bs-btn-bg: transparent; --bs-btn-border-color: rgba(255, 255, 255, .55);
    --bs-btn-hover-color: #12161C; --bs-btn-hover-bg: #fff; --bs-btn-hover-border-color: #fff; --bs-btn-active-color: #12161C; --bs-btn-active-bg: #E2E5E9; }
.btn-claro { --bs-btn-color: #12161C; --bs-btn-bg: #fff; --bs-btn-border-color: #fff; --bs-btn-hover-bg: #EEF0F3; --bs-btn-hover-border-color: #EEF0F3; }
.btn .bi-arrow-right { transition: transform .15s; }
.btn:hover .bi-arrow-right { transform: translateX(3px); }

/* ---------------------------------------------------------------- Formularios
   Etiquetas oscuras en semibold; campos blancos con borde gris visible (3.2:1);
   al enfocar, borde grafito y halo amarillo. */
.form-label, .etiqueta-campo { font-weight: 600; color: var(--g-900); font-size: .93rem; margin-bottom: .4rem; }
.form-label .opcional { font-weight: 400; color: var(--gris-600); }
.form-label .obligatorio { color: var(--naranja-texto); font-weight: 700; margin-left: 2px; }
.form-control, .form-select {
    background-color: #fff;
    border: 1.5px solid var(--gris-400);
    border-radius: var(--radio);
    min-height: 48px;
    padding: .65rem .9rem;
    color: var(--g-900);
    font-size: 1rem;
    transition: border-color .15s, box-shadow .15s;
}
.form-control-sm, .form-select-sm { min-height: 38px; padding: .35rem .7rem; font-size: .9rem; }
.form-control::placeholder { color: var(--gris-500); opacity: 1; }
.form-control:hover, .form-select:hover { border-color: var(--g-600); }
.form-control:focus, .form-select:focus { border-color: var(--g-900); box-shadow: 0 0 0 3px rgba(245, 176, 20, .45); }
.form-control:disabled { background: var(--gris-100); border-style: dashed; color: var(--gris-600); }
.form-text { color: var(--gris-600); font-size: .85rem; }
.input-group-text { background: var(--gris-100); border: 1.5px solid var(--gris-400); color: var(--g-700); font-weight: 600; border-radius: var(--radio); }
.input-group .btn-ver-clave { border: 1.5px solid var(--gris-400); border-left: 0; background: #fff; color: var(--g-700); border-radius: 0 var(--radio) var(--radio) 0; min-width: 52px; }
.input-group .btn-ver-clave:hover { background: var(--gris-100); color: var(--g-900); }
.input-group:focus-within .btn-ver-clave, .input-group:focus-within .input-group-text { border-color: var(--g-900); }
.form-control.is-invalid, .form-select.is-invalid, .was-validated .form-control:invalid { border-color: var(--rojo); background-image: none; padding-right: .9rem; }
.form-control.is-invalid:focus { box-shadow: 0 0 0 3px rgba(180, 35, 24, .2); }
.invalid-feedback { color: var(--rojo); font-weight: 500; font-size: .87rem; }
.invalid-feedback::before { content: "\F332"; font-family: "bootstrap-icons"; margin-right: .35rem; }
.form-check-input { width: 1.2em; height: 1.2em; border: 1.5px solid var(--gris-400); margin-top: .17em; border-radius: 3px; }
.form-check-input:checked { background-color: var(--g-900); border-color: var(--g-900); }
.form-check-input:focus { border-color: var(--g-900); box-shadow: 0 0 0 3px rgba(245, 176, 20, .45); }
.form-check-label { color: var(--g-700); }
.form-switch .form-check-input { width: 2.6em; border-radius: 2em; }
.form-switch .form-check-input:checked { background-color: var(--verde); border-color: var(--verde); }
.grupo-form { background: #fff; border: 1px solid var(--gris-200); border-radius: var(--radio-md); padding: 1.25rem; }
.leyenda-obligatorio { font-size: .85rem; color: var(--gris-600); }

/* ---------------------------------------------------------------- Alertas y etiquetas */
.alert { border-radius: var(--radio); border-width: 1px; border-left-width: 4px; font-weight: 500; }
.alert-success { background: var(--verde-suave); border-color: #9FD8B3; border-left-color: var(--verde); color: #14532D; }
.alert-danger { background: var(--rojo-suave); border-color: #F3B4AD; border-left-color: var(--rojo); color: #7A1A12; }
.alert-warning { background: var(--amarillo-suave); border-color: #F1D489; border-left-color: var(--amarillo); color: #5C3A00; }
.alert-info { background: #EAF1F8; border-color: #BCD2E8; border-left-color: #2F6CA8; color: #163E66; }
.etiqueta { display: inline-flex; align-items: center; gap: .55rem; color: var(--amarillo); font-family: var(--mono);
    font-weight: 600; font-size: .76rem; letter-spacing: .14em; text-transform: uppercase; padding-left: .85rem; border-left: 3px solid var(--amarillo); }
.etiqueta i { display: none; }
.insignia { display: inline-flex; align-items: center; gap: .35rem; font-weight: 600; font-size: .76rem; padding: .28rem .6rem; border-radius: 3px; }
.insignia-verde { background: var(--verde-suave); color: var(--verde); }
.insignia-roja { background: var(--rojo-suave); color: var(--rojo); }
.insignia-gris { background: var(--gris-100); color: var(--g-700); }
.insignia-rol, .insignia-amarilla { background: var(--amarillo-suave); color: #6B4500; border: 1px solid #F1D489; }
.badge.text-bg-success { background: var(--verde-suave) !important; color: var(--verde) !important; }
.badge.text-bg-danger { background: var(--rojo-suave) !important; color: var(--rojo) !important; }
.badge.text-bg-secondary { background: var(--gris-100) !important; color: var(--g-700) !important; }
.badge.text-bg-dark { background: var(--g-900) !important; color: var(--amarillo) !important; }
.badge { font-weight: 600; padding: .4em .65em; border-radius: 3px; }

/* ---------------------------------------------------------------- Barra de navegación pública */
.barra-publica { background: var(--g-900); border-bottom: 1px solid #262D36; }
.barra-publica .navbar-brand img { height: 34px; width: auto; }
.barra-publica .nav-link { font-weight: 500; font-size: .95rem; color: #C9CFD6; padding: .5rem .8rem !important; position: relative; }
.barra-publica .nav-link:hover, .barra-publica .nav-link:focus { color: #fff; }
.barra-publica .nav-link.active { color: var(--amarillo); }
@media (min-width: 992px) {
    .barra-publica { padding-top: .8rem !important; padding-bottom: .8rem !important; }
    .barra-publica .nav-link.active::after { content: ""; position: absolute; left: .8rem; right: .8rem; bottom: -.82rem; height: 2px; background: var(--amarillo); }
}
.barra-publica .navbar-toggler { border: 1px solid #4A5360; color: #fff; padding: .4rem .6rem; }
.barra-publica .navbar-toggler-icon { filter: invert(1); }
.barra-publica .btn-linea-clara { --bs-btn-border-color: #4A5360; }

/* ---------------------------------------------------------------- Portada (hero)
   La imagen de fondo se puede reemplazar por una fotografía real con el mismo nombre:
   el degradado oscuro garantiza la lectura del texto. */
.portada { position: relative; background: var(--g-900) url("../img/fotos/portada.jpg") right center / cover no-repeat; color: #fff; overflow: hidden; }
.portada::before { content: ""; position: absolute; inset: 0;
    background: linear-gradient(90deg, rgba(11, 14, 18, .97) 0%, rgba(11, 14, 18, .9) 34%, rgba(11, 14, 18, .45) 62%, rgba(11, 14, 18, .15) 100%); }
.portada .container { position: relative; padding-top: 6.5rem; padding-bottom: 6rem; }
.portada h1 { font-weight: 800; font-size: clamp(2.3rem, 5vw, 4rem); line-height: 1.04; color: #fff; max-width: 15ch; letter-spacing: -.022em; }
.portada h1 .resaltado { color: var(--amarillo); }
.portada .lead { color: #C9CFD6; font-size: 1.15rem; max-width: 36rem; line-height: 1.6; }
.confianza { display: flex; flex-wrap: wrap; gap: .6rem 1.8rem; margin-top: 2.2rem; color: #C9CFD6; font-weight: 500; font-size: .92rem; }
.confianza i { color: var(--amarillo); margin-right: .45rem; }

/* Franja de garantías bajo la portada */
.franja-datos { background: var(--g-850); border-top: 1px solid #262D36; border-bottom: 1px solid #262D36; color: #C9CFD6; }
.franja-datos .dato { padding: 1.6rem 1.25rem; height: 100%; display: flex; gap: .9rem; align-items: flex-start; }
.franja-datos .dato i { font-size: 1.5rem; color: var(--amarillo); line-height: 1; }
.franja-datos .dato strong { color: #fff; display: block; font-size: .98rem; margin-bottom: .15rem; }
.franja-datos .dato span { font-size: .86rem; color: #A9B3BF; }
@media (min-width: 992px) { .franja-datos .col-lg-3 + .col-lg-3 .dato { border-left: 1px solid #262D36; } }

/* ---------------------------------------------------------------- Secciones */
.seccion { padding: 5.5rem 0; }
.seccion-gris { background: var(--fondo); }
.seccion-oscura { background: var(--g-900); color: #C9CFD6; }
.seccion-oscura.con-rejilla { background-image: linear-gradient(#1C222A 1px, transparent 1px), linear-gradient(90deg, #1C222A 1px, transparent 1px); background-size: 40px 40px; }
.titulo-seccion { font-weight: 800; font-size: clamp(1.75rem, 3.2vw, 2.6rem); color: var(--g-900); line-height: 1.12; }
.seccion-oscura .titulo-seccion { color: #fff; }
.subtitulo-seccion { color: var(--gris-600); font-size: 1.08rem; max-width: 40rem; margin: .75rem 0 0; line-height: 1.6; }
.text-center .subtitulo-seccion, .subtitulo-seccion.mx-auto { margin-left: auto; margin-right: auto; }
.seccion-oscura .subtitulo-seccion { color: #A9B3BF; }
.sobretitulo { display: inline-flex; align-items: center; gap: .6rem; font-family: var(--mono); font-size: .76rem; font-weight: 600; letter-spacing: .16em;
    text-transform: uppercase; color: var(--naranja-texto); margin-bottom: .9rem; }
.sobretitulo::before { content: ""; width: 22px; height: 2px; background: currentColor; }
.seccion-oscura .sobretitulo { color: var(--amarillo); }

/* Tarjetas de servicio */
.tarjeta-servicio { background: #fff; border: 1px solid var(--gris-200); border-radius: var(--radio-md); overflow: hidden; height: 100%;
    display: flex; flex-direction: column; transition: border-color .2s, box-shadow .2s; }
.tarjeta-servicio:hover { border-color: var(--gris-300); box-shadow: var(--sombra-lg); }
.tarjeta-servicio .foto { position: relative; aspect-ratio: 16 / 9; background: var(--g-900); overflow: hidden; }
.tarjeta-servicio .foto img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s; }
.tarjeta-servicio:hover .foto img { transform: scale(1.03); }
.tarjeta-servicio .foto .codigo { position: absolute; left: 1rem; top: 1rem; background: rgba(11, 14, 18, .85); color: var(--amarillo);
    font-family: var(--mono); font-size: .72rem; letter-spacing: .12em; padding: .35rem .6rem; border-left: 3px solid var(--amarillo); }
.tarjeta-servicio .cuerpo { padding: 1.75rem; display: flex; flex-direction: column; flex: 1; }
.tarjeta-servicio .para { font-size: .82rem; font-weight: 600; color: var(--gris-600); text-transform: uppercase; letter-spacing: .08em; margin-bottom: .4rem; }
.tarjeta-servicio h3 { font-weight: 750; letter-spacing: -.02em; }
.tarjeta-servicio .no-incluye { background: var(--fondo); border-left: 3px solid var(--gris-300); padding: .7rem .9rem; font-size: .88rem; color: var(--gris-600); }
.precio-desde { font-weight: 800; font-size: 1.7rem; color: var(--g-900); line-height: 1; letter-spacing: -.02em; }
.lista-check { list-style: none; padding: 0; margin: 0; }
.lista-check li { position: relative; padding-left: 1.65rem; margin-bottom: .5rem; color: var(--g-700); }
.lista-check li::before { content: "\F633"; font-family: "bootstrap-icons"; position: absolute; left: 0; top: 0; color: var(--verde); font-weight: 700; }
.seccion-oscura .lista-check li, .acceso-lado .lista-check li { color: #D5DAE0; }
.seccion-oscura .lista-check li::before, .acceso-lado .lista-check li::before { color: var(--amarillo); }
.lista-x li::before { content: "\F659"; color: var(--gris-400); }

/* Qué revisamos */
.revision { border: 1px solid var(--gris-200); border-radius: var(--radio-md); padding: 1.5rem; height: 100%; background: #fff; transition: border-color .2s; }
.revision:hover { border-color: var(--g-900); }
.revision .num { font-family: var(--mono); font-size: .75rem; color: var(--gris-500); letter-spacing: .1em; }
.revision i { font-size: 1.6rem; color: var(--g-900); display: block; margin: .6rem 0 .8rem; }
.revision h3 { font-size: 1.02rem; font-weight: 700; margin-bottom: .35rem; }
.revision p { font-size: .9rem; color: var(--gris-600); margin: 0; }
.nota-tecnica { display: flex; gap: .75rem; align-items: flex-start; font-size: .92rem; color: var(--gris-600); border-top: 1px solid var(--gris-200); padding-top: 1.25rem; }
.nota-tecnica i { color: var(--naranja-texto); font-size: 1.1rem; }

/* Pasos */
.paso { position: relative; padding: 1.75rem 1.5rem; height: 100%; border: 1px solid #2A313B; border-radius: var(--radio-md); background: rgba(23, 28, 35, .85); }
.paso .paso-num { font-family: var(--mono); font-size: 2.2rem; font-weight: 600; color: var(--amarillo); line-height: 1; display: block; margin-bottom: 1.1rem; }
.paso i { position: absolute; right: 1.5rem; top: 1.75rem; font-size: 1.5rem; color: #5B6675; }
.paso h3 { color: #fff; font-size: 1.12rem; font-weight: 700; }
.paso p { color: #A9B3BF; font-size: .93rem; margin: 0; }
.paso-barra { height: 3px; background: #2A313B; margin-top: 1.25rem; position: relative; }
.paso-barra span { position: absolute; left: 0; top: 0; bottom: 0; background: var(--amarillo); }
.paso-barra .p1 { width: 25%; } .paso-barra .p2 { width: 50%; } .paso-barra .p3 { width: 75%; } .paso-barra .p4 { width: 100%; }

/* Ejemplo de informe */
.informe { background: #fff; border: 1px solid var(--gris-200); border-radius: var(--radio-md); box-shadow: var(--sombra-lg); overflow: hidden; }
.informe-cabecera { background: var(--g-900); color: #fff; padding: 1.1rem 1.4rem; display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.informe-cabecera small { font-family: var(--mono); color: var(--amarillo); letter-spacing: .12em; font-size: .7rem; }
.informe-cabecera strong { display: block; font-size: 1rem; }
.informe-resumen { display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--gris-200); }
.informe-resumen div { padding: 1rem 1.25rem; }
.informe-resumen div + div { border-left: 1px solid var(--gris-200); }
.informe-resumen b { display: block; font-size: 1.5rem; line-height: 1.1; }
.informe-resumen span { font-size: .78rem; color: var(--gris-600); font-weight: 600; }
.hallazgo { display: grid; grid-template-columns: auto 1fr auto; gap: .9rem; align-items: center; padding: .95rem 1.4rem; border-bottom: 1px solid var(--gris-100); }
.hallazgo:last-child { border-bottom: 0; }
.hallazgo .n { font-family: var(--mono); font-size: .78rem; color: var(--gris-500); }
.hallazgo strong { display: block; font-size: .95rem; }
.hallazgo small { color: var(--gris-600); }
.semaforo { display: inline-flex; align-items: center; gap: .4rem; font-size: .76rem; font-weight: 700; padding: .3rem .6rem; border-radius: 3px; white-space: nowrap; }
.semaforo::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.semaforo.rojo { background: var(--rojo-suave); color: var(--rojo); }
.semaforo.amarillo { background: var(--amarillo-suave); color: #8A5A00; }
.semaforo.verde { background: var(--verde-suave); color: var(--verde); }
.cifra-rojo { color: var(--rojo); } .cifra-amarillo { color: #8A5A00; } .cifra-verde { color: var(--verde); }
.explica { display: flex; gap: 1rem; margin-bottom: 1.4rem; }
.explica .icono { width: 44px; height: 44px; flex-shrink: 0; border-radius: var(--radio); background: var(--g-900); color: var(--amarillo); display: flex; align-items: center; justify-content: center; font-size: 1.2rem; }
.explica h3 { font-size: 1.02rem; font-weight: 700; margin-bottom: .2rem; }
.explica p { margin: 0; color: var(--gris-600); font-size: .94rem; }

/* Quiénes somos */
.imagen-marco { position: relative; border-radius: var(--radio-md); overflow: hidden; border: 1px solid var(--gris-200); }
.imagen-marco img { width: 100%; height: auto; display: block; }
.imagen-marco .pie-imagen { position: absolute; left: 0; right: 0; bottom: 0; padding: 1rem 1.25rem; background: linear-gradient(0deg, rgba(11, 14, 18, .92), rgba(11, 14, 18, 0));
    color: #fff; font-size: .88rem; }
.valor-marca { border-top: 2px solid var(--g-900); padding-top: 1rem; height: 100%; }
.valor-marca h3 { font-size: 1rem; font-weight: 700; margin-bottom: .3rem; }
.valor-marca p { font-size: .9rem; color: var(--gris-600); margin: 0; }

/* Empresas */
.empresas-imagen { border-radius: var(--radio-md); border: 1px solid #2A313B; width: 100%; height: auto; display: block; }
.icono-caja { width: 48px; height: 48px; border-radius: var(--radio); background: var(--g-900); color: var(--amarillo);
    display: inline-flex; align-items: center; justify-content: center; font-size: 1.35rem; }

/* Preguntas */
.accordion { --bs-accordion-border-color: var(--gris-200); --bs-accordion-active-bg: #fff; --bs-accordion-active-color: var(--g-900);
    --bs-accordion-btn-focus-box-shadow: 0 0 0 3px rgba(245, 176, 20, .45); --bs-accordion-border-radius: 6px; --bs-accordion-inner-border-radius: 6px;
    --bs-accordion-btn-padding-y: 1.15rem; }
.accordion-button { font-weight: 650; font-size: 1.02rem; }
.accordion-button:not(.collapsed) { box-shadow: inset 3px 0 0 var(--amarillo); }
.accordion-body { padding-top: 0; }

/* Contacto */
.contacto { background: var(--amarillo); color: var(--g-900); }
.contacto .titulo-seccion { color: var(--g-900); }
.contacto p { color: #3B2C05; }
.canal { display: flex; gap: .9rem; align-items: center; background: rgba(255, 255, 255, .55); border: 1px solid rgba(18, 22, 28, .12); border-radius: var(--radio-md);
    padding: 1rem 1.1rem; color: var(--g-900); text-decoration: none; height: 100%; transition: background .2s; }
.canal:hover { background: #fff; color: var(--g-900); }
.canal i { font-size: 1.4rem; width: 44px; height: 44px; border-radius: var(--radio); background: var(--g-900); color: var(--amarillo); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.canal strong { display: block; }
.canal span { font-size: .87rem; color: #3B2C05; overflow-wrap: anywhere; }
.franja-cta { background: var(--g-900); color: #C9CFD6; border-radius: var(--radio-md); padding: 2.5rem; }
.franja-cta h2 { color: #fff; font-weight: 800; }

/* Pie */
.pie { background: var(--g-950); color: #A9B3BF; border-top: 3px solid var(--amarillo); }
.pie h2 { color: #fff; font-size: .78rem; font-weight: 600; margin-bottom: 1rem; font-family: var(--mono); letter-spacing: .14em; text-transform: uppercase; }
.pie a { color: #D5DAE0; text-decoration: none; }
.pie a:hover { color: var(--amarillo); text-decoration: underline; }
.pie .logo-pie { height: 36px; width: auto; }
.pie hr { border-color: #262D36; opacity: 1; }

.boton-whatsapp { position: fixed; right: 20px; bottom: 20px; z-index: 1030; width: 56px; height: 56px; border-radius: 50%;
    background: #1EA952; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 1.7rem;
    box-shadow: 0 10px 24px rgba(0, 0, 0, .3); text-decoration: none; transition: transform .2s; }
.boton-whatsapp:hover { color: #fff; transform: scale(1.06); }

/* ---------------------------------------------------------------- Páginas legales */
.contenido-legal h1 { font-weight: 800; }
.contenido-legal h2 { font-size: 1.2rem; font-weight: 700; margin-top: 2rem; }

/* ---------------------------------------------------------------- Pantallas de acceso */
.acceso { min-height: calc(100vh - 66px); display: flex; align-items: stretch; background: var(--fondo); }
.acceso-lado { position: relative; color: #D5DAE0; padding: 3.5rem; display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden;
    background: var(--g-900) url("../img/fotos/acceso.jpg") center / cover no-repeat; }
.acceso-lado::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(11, 14, 18, .35) 0%, rgba(11, 14, 18, .82) 55%, rgba(11, 14, 18, .97) 100%); }
.acceso-lado > * { position: relative; }
.acceso-lado h2 { color: #fff; font-weight: 800; font-size: 1.85rem; line-height: 1.15; }
.acceso-form { display: flex; align-items: center; justify-content: center; padding: 2.5rem 1.25rem; }
.caja-acceso { width: 100%; max-width: 560px; background: #fff; border: 1px solid var(--gris-200); border-top: 3px solid var(--amarillo); border-radius: var(--radio-md);
    padding: 2.25rem; box-shadow: var(--sombra-lg); }
.caja-acceso h1 { font-weight: 800; font-size: 1.7rem; }
.caja-acceso.angosta { max-width: 460px; }
.texto-legal { font-size: .88rem; color: var(--g-700); }
.separador-texto { display: flex; align-items: center; gap: .75rem; color: var(--gris-600); font-size: .85rem; }
.separador-texto::before, .separador-texto::after { content: ""; flex: 1; border-top: 1px solid var(--gris-200); }
.caja-centrada { max-width: 560px; margin: 3rem auto; }

.barra-instalador { background: var(--g-900); border-bottom: 3px solid var(--amarillo); padding: .9rem 0; }

/* ---------------------------------------------------------------- Panel (cliente, especialista, administración) */
body.panel { background: var(--fondo); }
.panel-lateral { width: 260px; --bs-offcanvas-bg: #12161C; --bs-offcanvas-color: #C9CFD6; background-color: var(--g-900) !important; color: #C9CFD6; border-right: 1px solid #222932; }
@media (min-width: 992px) {
    .panel-lateral { position: fixed; top: 0; bottom: 0; left: 0; overflow-y: auto; z-index: 1030; display: flex; flex-direction: column; }
    .panel-principal { margin-left: 260px; }
}
.panel-lateral .offcanvas-header, .panel-lateral .marca-lateral { padding: 1.3rem 1.25rem 1rem; border-bottom: 1px solid #222932; }
.panel-lateral .marca-lateral img { height: 30px; width: auto; }
.panel-lateral .btn-close { filter: invert(1); }
.menu-lateral { padding: .5rem .75rem 1.5rem; }
.menu-lateral .grupo { font-family: var(--mono); font-size: .68rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: #8A95A3; margin: 1.2rem .75rem .45rem; }
.menu-lateral .nav-link { color: #C9CFD6; font-weight: 500; font-size: .93rem; border-radius: var(--radio); padding: .55rem .75rem; display: flex; align-items: center; gap: .75rem; border-left: 3px solid transparent; }
.menu-lateral .nav-link i { font-size: 1.05rem; width: 1.25rem; text-align: center; color: #8A95A3; }
.menu-lateral .nav-link:hover { background: #1C222A; color: #fff; }
.menu-lateral .nav-link:hover i { color: var(--amarillo); }
.menu-lateral .nav-link.active { background: #1F262F; color: #fff; font-weight: 600; border-left-color: var(--amarillo); border-radius: 0 var(--radio) var(--radio) 0; }
.menu-lateral .nav-link.active i { color: var(--amarillo); }
.menu-lateral .nav-link.disabled { color: #8A95A3; }
.menu-lateral .nav-link.disabled i { color: #5B6675; }
.menu-lateral .pronto { margin-left: auto; font-family: var(--mono); font-size: .6rem; letter-spacing: .08em; text-transform: uppercase; color: #A9B3BF; border: 1px solid #3A4350; border-radius: 3px; padding: .1rem .4rem; }
.tarjeta-lateral { margin: auto .9rem 1.25rem; background: #171C23; border: 1px solid #2A313B; border-radius: var(--radio-md); padding: 1rem; color: #C9CFD6; }
.tarjeta-lateral strong { color: #fff; }

.barra-superior { background: #fff; border-bottom: 1px solid var(--gris-200); padding: .7rem 1.75rem; position: sticky; top: 0; z-index: 1020; min-height: 64px; }
.barra-superior .buscador { max-width: 440px; }
.barra-superior .buscador .form-control { min-height: 40px; border-radius: var(--radio); padding-left: 2.5rem; background: var(--fondo); border: 1px solid var(--gris-200); font-size: .93rem; }
.barra-superior .buscador .form-control:focus { background: #fff; border-color: var(--g-900); }
.barra-superior .buscador i { position: absolute; left: .95rem; top: 50%; transform: translateY(-50%); color: var(--gris-600); }
.avatar { width: 40px; height: 40px; border-radius: var(--radio); background: var(--amarillo); color: var(--g-900); font-weight: 700; font-size: .85rem;
    display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; letter-spacing: .02em; }
.avatar.oscuro { background: var(--g-800); color: #fff; }
.avatar.sm { width: 34px; height: 34px; font-size: .75rem; }
.boton-usuario { border: 1px solid var(--gris-200); border-radius: var(--radio); padding: .25rem .8rem .25rem .25rem; background: #fff; display: flex; align-items: center; gap: .6rem; }
.boton-usuario:hover { background: var(--fondo); }
.dropdown-menu { border: 1px solid var(--gris-200); border-radius: var(--radio-md); box-shadow: var(--sombra-lg); padding: .4rem; }
.dropdown-item { border-radius: 3px; padding: .55rem .8rem; font-weight: 500; }
.dropdown-item:active { background: var(--g-900); color: #fff; }

.contenido-panel { padding: 1.75rem; max-width: 1440px; }
.contenido-panel > h1, .encabezado-pagina h1 { font-weight: 800; font-size: 1.6rem; letter-spacing: -.025em; }
.encabezado-pagina { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--gris-200); }
.encabezado-pagina p { margin: .25rem 0 0; color: var(--gris-600); }
.miga { font-size: .85rem; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: .3rem; margin-bottom: .5rem; }

.tarjeta { background: #fff; border: 1px solid var(--gris-200); border-radius: var(--radio-md); padding: 1.35rem; box-shadow: var(--sombra); }
.row > [class*="col"] > .tarjeta:only-child { height: 100%; }
.tarjeta-titulo { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-bottom: 1.1rem; }
.tarjeta-titulo h2 { font-size: .98rem; font-weight: 700; margin: 0; }
.kpi { display: flex; gap: 1rem; align-items: flex-start; }
.kpi-icono { width: 46px; height: 46px; border-radius: var(--radio); display: inline-flex; align-items: center; justify-content: center; font-size: 1.25rem; flex-shrink: 0; }
.kpi-icono.amarillo { background: var(--amarillo-suave); color: #8A5A00; }
.kpi-icono.verde { background: var(--verde-suave); color: var(--verde); }
.kpi-icono.oscuro { background: var(--g-900); color: var(--amarillo); }
.kpi-icono.naranja { background: #FDEBDD; color: #A3480A; }
.kpi-etiqueta { font-size: .8rem; font-weight: 600; color: var(--gris-600); }
.kpi-valor { font-size: 1.95rem; font-weight: 800; color: var(--g-900); line-height: 1.1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.kpi-nota { font-size: .8rem; color: var(--gris-600); }
.tarjeta.kpi-tarjeta { border-top: 3px solid var(--g-900); }
.tarjeta.kpi-tarjeta.acento { border-top-color: var(--amarillo); }

.grafico { width: 100%; height: auto; display: block; }
.grafico text { font-family: "Inter", sans-serif; }
.dona-centro { font-size: 19px; font-weight: 800; fill: #12161C; }
.dona-sub { font-size: 9px; fill: #4B5563; font-weight: 600; }
.leyenda { display: flex; flex-wrap: wrap; gap: .4rem 1rem; font-size: .82rem; color: var(--g-700); }
.punto { width: 10px; height: 10px; border-radius: 2px; display: inline-block; margin-right: .35rem; }
.punto.amarillo { background: var(--amarillo); } .punto.naranja { background: var(--naranja); } .punto.gris { background: var(--gris-200); } .punto.verde { background: var(--verde-claro); }

.barra-h { display: grid; grid-template-columns: 1fr auto; gap: .3rem .75rem; align-items: center; margin-bottom: .9rem; }
.barra-h .nombre { font-weight: 600; font-size: .9rem; }
.barra-h .valor { font-weight: 700; font-size: .9rem; font-variant-numeric: tabular-nums; }
progress.avance { grid-column: 1 / -1; width: 100%; height: 8px; border: 0; border-radius: 2px; overflow: hidden; background: var(--gris-100); appearance: none; }
progress.avance::-webkit-progress-bar { background: var(--gris-100); border-radius: 2px; }
progress.avance::-webkit-progress-value { background: var(--amarillo); border-radius: 2px; }
progress.avance::-moz-progress-bar { background: var(--amarillo); border-radius: 2px; }

.table { --bs-table-hover-bg: #F7F8FA; margin-bottom: 0; }
.table > :not(caption) > * > * { padding: .85rem .9rem; border-bottom-color: var(--gris-200); }
.table thead th { font-family: var(--mono); font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--gris-600); background: var(--fondo); font-weight: 600; border-bottom: 1px solid var(--gris-200); }
.persona { display: flex; align-items: center; gap: .75rem; }
.persona .nombre { font-weight: 600; color: var(--g-900); }
.persona .detalle { font-size: .82rem; color: var(--gris-600); }
.pagination { --bs-pagination-color: #12161C; --bs-pagination-active-bg: #12161C; --bs-pagination-active-border-color: #12161C; --bs-pagination-active-color: #fff;
    --bs-pagination-focus-box-shadow: 0 0 0 3px rgba(245, 176, 20, .45); --bs-pagination-border-color: var(--gris-200); --bs-pagination-border-radius: 4px; }
.vacio { text-align: center; padding: 2rem 1rem; color: var(--gris-600); }
.vacio i { font-size: 2rem; color: var(--gris-400); display: block; margin-bottom: .5rem; }

.bienvenida { background: var(--g-900); color: #C9CFD6; border-radius: var(--radio-md); padding: 1.9rem 2rem; position: relative; overflow: hidden; border-left: 4px solid var(--amarillo);
    background-image: linear-gradient(#1C222A 1px, transparent 1px), linear-gradient(90deg, #1C222A 1px, transparent 1px); background-size: 32px 32px; }
.bienvenida h1 { color: #fff; font-weight: 800; font-size: 1.65rem; }
.bienvenida .etiqueta { margin-bottom: .4rem; }
.bienvenida .dato-bienvenida { border: 1px solid #2A313B; background: rgba(11, 14, 18, .6); border-radius: var(--radio); padding: .9rem 1.1rem; display: inline-block; text-align: left; }
.bienvenida .dato-bienvenida small { display: block; font-family: var(--mono); font-size: .68rem; letter-spacing: .12em; color: #A9B3BF; text-transform: uppercase; }
.bienvenida .dato-bienvenida b { color: #fff; font-size: 1.35rem; }
.codigo-referido { font-family: var(--mono); font-weight: 700; font-size: 1.05rem; background: var(--fondo); color: var(--g-900);
    border: 1.5px dashed var(--gris-400); border-radius: var(--radio); padding: .45rem .9rem; letter-spacing: .06em; }
.pie-panel { color: var(--gris-600); font-size: .8rem; font-family: var(--mono); }

@media (max-width: 991.98px) {
    .panel-lateral { width: 280px; }
    .contenido-panel { padding: 1.25rem 1rem; }
    .barra-superior { padding: .6rem 1rem; }
    .acceso-lado { display: none; }
    .portada::before { background: linear-gradient(180deg, rgba(11, 14, 18, .88) 0%, rgba(11, 14, 18, .93) 60%, rgba(11, 14, 18, .97) 100%); }
    .portada .container { padding-top: 4rem; padding-bottom: 4rem; }
    .barra-publica .navbar-collapse { border-top: 1px solid #262D36; margin-top: .6rem; }
}
@media (max-width: 575.98px) {
    .caja-acceso { padding: 1.5rem 1.15rem; }
    .franja-cta { padding: 1.75rem; }
    .seccion { padding: 3.75rem 0; }
    .tarjeta-servicio .cuerpo { padding: 1.35rem; }
    .informe-resumen b { font-size: 1.2rem; }
    .hallazgo { grid-template-columns: 1fr auto; padding: .9rem 1rem; }
    .hallazgo .n { display: none; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Textos largos (correos, códigos, detalles) no deben desbordar la pantalla en celular */
.contenido-panel code { overflow-wrap: anywhere; }
.persona .nombre { white-space: nowrap; }
@media (max-width: 575.98px) {
    .contenido-panel .table td { overflow-wrap: anywhere; }
    .persona .nombre { white-space: normal; }
    .contenido-panel .table > :not(caption) > * > * { padding: .6rem .5rem; }
}
