/* Modo oscuro de la inscripción a Labor Educativa (clase "tema-oscuro" en <html>; ver Scripts/ModoOscuro.js).
   Se carga después de InscripcionLaborEducativa.css: redefine las variables --ile-* y corrige los colores fijos. */
html.tema-oscuro { color-scheme: dark; background: #0f1623; }

html.tema-oscuro body.ile {
    --ile-primary: #6b9bff;
    --ile-primary-dark: #4f7cff;
    --ile-primary-soft: #1f2c45;
    --ile-border: #222d41;
    --ile-text: #e5e9f0;
    --ile-muted: #94a0b4;
    --ile-faint: #6b778c;
    --ile-ok: #4ade80;
    --ile-campo-borde: #2a3446;
    --ile-campo-borde-hover: #3c4b66;
    --ile-campo-sombra: none;
    --ile-campo-halo: 0 0 0 3px rgba(79, 124, 255, .25);
    --ile-card-sombra: 0 10px 30px rgba(0, 0, 0, .4);
    background-color: #0f1623 !important;
    background-image: radial-gradient(circle at 8% 45%, rgba(79, 124, 255, .10) 0%, rgba(79, 124, 255, 0) 32%),
                      radial-gradient(circle at 95% 70%, rgba(245, 168, 0, .06) 0%, rgba(245, 168, 0, 0) 30%),
                      radial-gradient(rgba(255, 255, 255, .04) 1px, transparent 1.2px) !important;
    background-size: auto, auto, 22px 22px !important;
}

/* tarjetas y bloques */
html.tema-oscuro .ile .ile-card { background: #151f31; }
html.tema-oscuro .ile .ile-formulario { box-shadow: 0 18px 48px rgba(0, 0, 0, .45); }
html.tema-oscuro .ile .ile-info-icono { color: var(--ile-primary); }
html.tema-oscuro .ile .ile-requisitos li::before { background: rgba(74, 222, 128, .15); }
html.tema-oscuro .ile .ile-requisitos li.ile-requisito-extranjero,
html.tema-oscuro .ile .ile-alerta,
html.tema-oscuro .ile-manual-tip-alerta { background: rgba(251, 191, 36, .14); color: #fcd88a; }
html.tema-oscuro .ile .ile-requisitos li.ile-requisito-extranjero::before,
html.tema-oscuro .ile-manual-tip-alerta i { color: #fbbf24; }
html.tema-oscuro .ile .ile-info-foto { filter: brightness(.85); }

/* formulario */
html.tema-oscuro .ile label { color: #c3cad6; }
html.tema-oscuro .ile .ile-seccion legend { background: linear-gradient(90deg, rgba(245, 168, 0, .22) 0%, rgba(79, 124, 255, .16) 16%, rgba(79, 124, 255, .06) 55%, rgba(79, 124, 255, 0) 100%); color: #e5e9f0; }
html.tema-oscuro .ile .form-control { background-color: #131c2c !important; color: #e5e9f0 !important; }
html.tema-oscuro .ile .form-control::placeholder { color: #6b778c; }
html.tema-oscuro .ile .form-control[readonly] { background-color: #0f1623 !important; }
html.tema-oscuro .ile .text-inverse { color: #fca5a5 !important; }
html.tema-oscuro .ile input:-webkit-autofill,
html.tema-oscuro .ile input:-webkit-autofill:focus { -webkit-box-shadow: 0 0 0 1000px #131c2c inset; -webkit-text-fill-color: #e5e9f0; caret-color: #e5e9f0; }

/* select2 */
html.tema-oscuro .ile .select2-container .select2-selection--single { background: #131c2c; border-color: var(--ile-campo-borde); }
html.tema-oscuro .ile .select2-container .select2-selection--single .select2-selection__rendered { color: #e5e9f0; }
html.tema-oscuro .ile .select2-container .select2-selection--single .select2-selection__arrow b { border-color: #94a0b4 transparent transparent transparent; }
html.tema-oscuro .ile .select2-dropdown { background: #151f31; border-color: #2a3446 !important; box-shadow: 0 16px 40px rgba(0, 0, 0, .5); }
html.tema-oscuro .ile .select2-search--dropdown .select2-search__field { background: #131c2c; color: #e5e9f0; border-color: #2a3446 !important; }
html.tema-oscuro .ile .select2-container--default .select2-results__option--highlighted[aria-selected] { background: #1f2c45; color: #9bbaff; }
html.tema-oscuro .ile .select2-container--default .select2-results__option[aria-selected=true] { background: #2b4aa8; color: #fff; }
html.tema-oscuro .ile .select2-results > .select2-results__options { scrollbar-color: #3c4b66 transparent; }
html.tema-oscuro .ile .select2-results > .select2-results__options::-webkit-scrollbar-thumb { background: #3c4b66; border-color: #151f31; }

/* reCAPTCHA oscuro: el iframe trae un borde blanco de 2px que no se puede tocar desde fuera; se recorta con un marco redondeado */
html.tema-oscuro .ile #divCaptch .g-recaptcha { width: 300px; height: 74px; overflow: hidden; border-radius: 4px; }
html.tema-oscuro .ile #divCaptch .g-recaptcha > div { margin: -2px 0 0 -2px; }

/* privacidad y casilla */
html.tema-oscuro .ile .ile-privacidad .c-checkbox label { background: #131c2c; border-color: #2a3446; }
html.tema-oscuro .ile .ile-privacidad .c-checkbox span { background: #131c2c; border-color: #3c4b66; }

/* botones y caminos */
html.tema-oscuro .ile #aRegistrarme[disabled] { background: #2a3446 !important; color: #6b778c !important; }
html.tema-oscuro .ile .ile-camino { background: #151f31; }
html.tema-oscuro .ile .ile-camino-nuevo .ile-camino-icono { background: rgba(245, 168, 0, .16); color: #fbbf24; }
html.tema-oscuro .ile .ile-camino-nuevo .ile-camino-boton { background: rgba(245, 168, 0, .16) !important; color: #fcd88a !important; border-color: rgba(245, 168, 0, .4); }
html.tema-oscuro .ile .ile-camino-nuevo .ile-camino-boton:hover { background: rgba(245, 168, 0, .26) !important; }
html.tema-oscuro .ile .ile-camino-nuevo .ile-camino-boton-sec { background: transparent !important; color: #9bbaff !important; border-color: #2a3446; }
html.tema-oscuro .ile .ile-camino-nuevo .ile-camino-boton-sec:hover { background: #1f2c45 !important; }

/* ayuda flotante y manual */
html.tema-oscuro .ile .ile-ayuda-num { color: #4ade80 !important; }
html.tema-oscuro .ile .ile-ayuda,
html.tema-oscuro .ile .ile-ayuda-abrir { background: #1f2c45 !important; border-color: #2a3446; color: #e5e9f0; }
html.tema-oscuro .ile .ile-ayuda:hover { background: #26365a !important; }
html.tema-oscuro .ile .ile-ayuda-globo { background: #151f31; }
html.tema-oscuro .ile .ile-ayuda-abrir:hover { background: #26365a !important; }
html.tema-oscuro .ile-manual { background: #151f31; color: #e5e9f0; }
html.tema-oscuro .ile-manual-pasos,
html.tema-oscuro .ile-manual-pie { background: #111a2a; }
html.tema-oscuro .ile-manual-pasos li span { background: #26324a; }
html.tema-oscuro .ile-manual-pasos li.hecho span { background: rgba(74, 222, 128, .18); }
html.tema-oscuro .ile-manual-pasos li.activo { background: #2b4aa8; color: #fff; }
html.tema-oscuro .ile-manual-pasos li.activo span { background: #fff; color: #2b4aa8; }
html.tema-oscuro .ile-manual-btn-sec { background: transparent; color: #9bbaff; border-color: #2a3446; }

/* interruptor claro/oscuro (arriba a la derecha: abajo está la ayuda flotante) */
.tema-toggle-login { position: fixed; right: 8px; top: 12px; width: 36px; height: 36px; border-radius: 50%; border: 0; cursor: pointer;
    background: #4f5bff; color: #fff; display: flex; align-items: center; justify-content: center;
    box-shadow: 0 6px 18px rgba(0,0,0,.3); z-index: 50; transition: transform .2s; }
.tema-toggle-login:hover { transform: scale(1.08); }
.tema-toggle-login .fa { font-size: 16px; }
