/* ═══════════════════════════════════════════════════════════
   solicitudes.css — Diseño propio para páginas de solicitud
   Basado en el sistema de diseño YouForgetMe (sin Radzen)
   ═══════════════════════════════════════════════════════════ */

/* ── Variables ────────────────────────────────────────────── */
:root {
    --yfm-primary:         #332B98;
    --yfm-secondary:       #AAE552;
    --yfm-tertiary:        #FF6B35;
    --yfm-button:       #AAE552;
    --yfm-button-hover: #BBEE66;
    --sl-text:          #333333;
    --sl-bg:            #f0f4fb;
    --sl-border:        #e3e4e5;
}

/* ── Layout ───────────────────────────────────────────────── */
.sl-layout {
    display: flex !important;
    flex-direction: column !important;
    min-height: 100vh;
    width: 100% !important;
    background-color: var(--sl-bg);
    font-family: 'Poppins', sans-serif;
    box-sizing: border-box;
}

.sl-layout .sl-main {
    flex: 1 0 auto;        /* crece pero nunca se comprime         */
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center;
    padding: 2rem 1.25rem;
    width: 100% !important;
    box-sizing: border-box;
}

/* ── Footer ───────────────────────────────────────────────── */
.sl-layout .sl-footer {
    flex-shrink: 0;
    position: static !important; /* neutraliza footer{position:fixed} de site.css */
    text-align: center;
    padding: 1rem 1.25rem 1.75rem;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 0.35rem;
    width: 100% !important;
    background-color: var(--sl-bg);
    box-sizing: border-box;
}

.sl-layout .sl-footer-lang {
    display: flex;
    gap: 4px;
    margin-bottom: 0.25rem;
}

.sl-layout .sl-lang-btn {
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    color: var(--sl-text);
    border: 1px solid rgba(14, 53, 111, 0.3);
    transition: all 0.2s;
    cursor: pointer;
}

.sl-layout .sl-lang-btn:hover {
    color: var(--yfm-primary);
    border-color: var(--yfm-primary);
    text-decoration: none;
}

.sl-layout .sl-lang-btn.active {
    color: #fff;
    background-color: var(--yfm-primary);
    border-color: var(--yfm-primary);
}

.sl-layout .sl-footer-subtexto {
    font-size: 0.75rem;
    margin: 0;
    color: var(--sl-text);
    opacity: 0.6;
}

.sl-layout .sl-footer-texto {
    font-size: 0.75rem;
    margin: 0;
    color: var(--sl-text);
}

.sl-layout .sl-footer-links {
    display: flex;
    gap: 6px;
    align-items: center;
    font-size: 0.75rem;
}

.sl-layout .sl-footer-link {
    font-size: 0.75rem;
    color: var(--yfm-primary);
    text-decoration: none;
}

.sl-layout .sl-footer-link:hover {
    text-decoration: underline;
    color: var(--yfm-primary);
}

.sl-layout .sl-footer-sep {
    color: var(--sl-text);
    opacity: 0.4;
}

/* ── Animación de entrada ─────────────────────────────────── */
@keyframes slFadeUp {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Card central ─────────────────────────────────────────── */
.sl-card {
    background-color: #fff;
    border-radius: 20px;
    padding: 2rem 1.5rem 1.75rem;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    animation: slFadeUp 0.35s ease both;
}

.sl-card-logo {
    margin-bottom: 1.25rem;
    display: flex;
    justify-content: center;
    width: 100%;
}

.sl-card-logo img {
    max-width: 220px;
    max-height: 80px;
    object-fit: contain;
    display: block;
}

/* ── Tipografía del card ──────────────────────────────────── */
.sl-titulo {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--yfm-primary);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.sl-texto {
    font-size: 0.92rem;
    color: var(--sl-text);
    line-height: 1.5;
    margin-bottom: 0.75rem;
}

.sl-texto-expl {
    font-size: 0.88rem;
    color: var(--sl-text);
    line-height: 1.5;
    margin-bottom: 0.75rem;
}

.sl-texto-expl a {
    color: var(--yfm-primary);
}

.sl-estado-ok {
    font-size: 0.95rem;
    color: #2E9E6B;
    font-weight: 600;
    margin: 0;
}

.sl-estado-error {
    font-size: 0.92rem;
    color: var(--yfm-tertiary);
    margin: 0;
}

/* ── Formulario ───────────────────────────────────────────── */
.sl-form-group {
    width: 100%;
    margin-bottom: 1rem;
    text-align: left;
}

.sl-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--yfm-primary);
    margin-bottom: 0.35rem;
    display: block;
}

.sl-input {
    width: 100%;
    padding: 0.65rem 0.9rem;
    border: 1.5px solid var(--sl-border);
    border-radius: 10px;
    font-size: 0.9rem;
    color: var(--sl-text);
    background-color: #fff;
    transition: border-color 0.15s ease;
    font-family: 'Poppins', sans-serif;
    box-sizing: border-box;
}

.sl-input:focus {
    outline: none;
    border-color: var(--yfm-primary);
    box-shadow: 0 0 0 3px rgba(14, 53, 111, 0.08);
}

/* ── Subida de fichero ────────────────────────────────────── */
.sl-file-label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.7rem 1rem;
    border: 1.5px dashed var(--yfm-primary);
    border-radius: 10px;
    background-color: rgba(14, 53, 111, 0.03);
    color: var(--yfm-primary);
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s ease;
    box-sizing: border-box;
}

.sl-file-label:hover {
    background-color: rgba(14, 53, 111, 0.07);
}

.sl-file-input {
    display: none;
}

.sl-file-info {
    font-size: 0.82rem;
    color: #666;
    margin-top: 0.4rem;
    text-align: center;
    margin-bottom: 0;
}

/* ── Botón principal ──────────────────────────────────────── */
.sl-btn-primary {
    display: block;
    width: 100%;
    padding: 0.85rem 1rem;
    border: none;
    border-radius: 14px;
    background-color: var(--yfm-button);
    color: #000;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s ease;
    font-family: 'Poppins', sans-serif;
    margin-top: 0.5rem;
}

.sl-btn-primary:hover {
    background-color: var(--yfm-button-hover);
}

.sl-btn-primary:disabled {
    opacity: 0.4;
    cursor: default;
}

/* ── Pasos numerados ─────────────────────────────────────── */
.sl-paso {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    background-color: rgba(14, 53, 111, 0.05);
    border-radius: 12px;
    padding: 0.7rem 1rem;
    text-align: left;
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 0.5rem;
}

.sl-paso-num {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background-color: var(--yfm-secondary);
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sl-paso-texto {
    font-size: 0.88rem;
    color: var(--sl-text);
    margin: 0;
    line-height: 1.4;
}

.sl-paso-texto a {
    color: var(--yfm-primary);
}

.sl-paso-texto strong {
    color: var(--yfm-tertiary);
    font-weight: 700;
}

/* ── Pincode input ────────────────────────────────────────── */
.sl-card .pincode-input-container {
    gap: 5px;
}

.sl-card .pincode-input-container .pincode-input-text {
    border-radius: 8px !important;
    border-left-width: 1px !important;
    border-color: var(--sl-border) !important;
    min-width: 0;
    max-width: 42px;
    padding: 0.4rem 0 !important;
}

.sl-card .pincode-input-container input.first {
    border-top-right-radius: 8px !important;
    border-bottom-right-radius: 8px !important;
}

.sl-card .pincode-input-container input.last {
    border-top-left-radius: 8px !important;
    border-bottom-left-radius: 8px !important;
}

.sl-card .pincode-input-container .pincode-input-text:focus {
    border-color: var(--yfm-primary) !important;
    box-shadow: 0 0 0 2px rgba(14, 53, 111, 0.08) !important;
    outline: none !important;
}

/* ── Switch personalizado ─────────────────────────────────── */
.sl-switch {
    padding-left: 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-height: 0;
}

.sl-switch .form-check-input {
    position: static !important;
    float: none !important;
    margin-left: 0 !important;
    margin-top: 0 !important;
    width: 3rem !important;
    height: 1.6rem !important;
    flex-shrink: 0;
    cursor: pointer;
}

.sl-switch .form-check-input:checked {
    background-color: var(--yfm-secondary);
    border-color: var(--yfm-secondary);
}

.sl-switch .form-check-input:focus {
    border-color: var(--yfm-secondary);
    box-shadow: 0 0 0 3px rgba(170, 229, 82, 0.25);
}

/* ── Link estándar dentro de sl-card ─────────────────────── */
.sl-link {
    color: var(--yfm-primary);
    text-decoration: none;
}

.sl-link:hover {
    color: var(--yfm-primary);
    text-decoration: underline;
}

/* ── Utilidad de escala para checkboxes ──────────────────── */
.scale2-5 {
    width: 1.5rem !important;
    height: 1.5rem !important;
    flex-shrink: 0;
    cursor: pointer;
}

/* ── Botón peligro ───────────────────────────────────────── */
.sl-btn-danger {
    display: block;
    width: 100%;
    padding: 0.85rem 1rem;
    border: none;
    border-radius: 14px;
    background-color: #dc3545;
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s ease;
    font-family: 'Poppins', sans-serif;
    margin-top: 0.5rem;
}

.sl-btn-danger:hover {
    background-color: #bb2d3b;
}

.sl-btn-danger:disabled {
    opacity: 0.4;
    cursor: default;
}

/* ── Botón secundario ────────────────────────────────────── */
.sl-btn-secondary {
    display: block;
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1.5px solid var(--sl-border);
    border-radius: 14px;
    background-color: transparent;
    color: var(--sl-text);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
    font-family: 'Poppins', sans-serif;
    margin-top: 0.5rem;
}

.sl-btn-secondary:hover {
    background-color: rgba(0, 0, 0, 0.04);
    border-color: #bbb;
}

/* ── Consentimientos: info del titular ───────────────────── */
.sl-consent-info {
    width: 100%;
    background-color: rgba(14, 53, 111, 0.04);
    border-radius: 12px;
    padding: 0.85rem 1rem;
    margin-bottom: 1rem;
    text-align: left;
}

.sl-consent-nombre {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--yfm-primary);
    margin: 0 0 0.3rem 0;
}

.sl-consent-fechas {
    font-size: 0.82rem;
    color: #666;
    margin: 0 0 0.5rem 0;
}

/* ── Badges de estado ────────────────────────────────────── */
.sl-badge {
    display: inline-block;
    padding: 0.2rem 0.65rem;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
}

.sl-badge-ok      { background-color: #d1f0e0; color: #1a7a4a; }
.sl-badge-danger  { background-color: #fde8ea; color: #b02a37; }
.sl-badge-info    { background-color: #dce8fb; color: #2456a4; }

/* ── Consentimientos: área de texto con scroll ───────────── */
.sl-consent-texto {
    width: 100%;
    max-height: 40vh;
    overflow-y: auto;
    background-color: #fff;
    border: 1.5px solid var(--sl-border);
    border-radius: 10px;
    padding: 0.85rem 1rem;
    font-size: 0.88rem;
    color: var(--sl-text);
    line-height: 1.6;
    text-align: left;
    box-sizing: border-box;
    margin-bottom: 0.75rem;
}

/* ── Consentimientos: fila de chequeo ────────────────────── */
.sl-consent-chequeo {
    width: 100%;
    border-bottom: 1px solid var(--sl-border);
    padding: 0.6rem 0;
    text-align: left;
    margin-bottom: 0.25rem;
}

.sl-consent-radio-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.88rem;
    color: var(--sl-text);
    cursor: pointer;
    margin-bottom: 0.25rem;
}

.sl-consent-radio-label input[type="radio"] {
    flex-shrink: 0;
    cursor: pointer;
}

/* ── Consentimientos: carrusel ───────────────────────────── */
.sl-consent-carousel {
    width: 100%;
    margin: 0.75rem 0;
    border-radius: 10px;
    overflow: hidden;
}

/* ── Consentimientos: firma inline ───────────────────────── */
.sl-consent-firma {
    width: 100%;
    border: 1.5px solid var(--sl-border);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 0.75rem;
}

/* ── Consentimientos: hint de scroll ─────────────────────── */
.sl-consent-scroll-hint {
    font-size: 0.75rem;
    color: #888;
    font-style: italic;
    margin-top: 0.25rem;
    margin-bottom: 0.5rem;
    text-align: left;
    width: 100%;
}
