/* ==========================================================================
   UCE BURGOS - HOJA DE ESTILOS MAESTRA (V10 - FINAL REFINED)
   ========================================================================== */

/* --- 1. VARIABLES Y CONFIGURACIÓN --- */
:root {
    /* Colores Corporativos */
    --uce-dark: #043F1F;    /* Verde botella */
    --uce-accent: #9fc100;  /* Verde pistacho */
    --uce-light: #E8EFD2;   /* Verde pálido fondo */
    
    /* Colores Neutros */
    --white: #ffffff;
    --gray-50: #fcfcfc;
    --gray-100: #f8f9fa;
    --gray-200: #e9ecef;
    --text-main: #333333;
    --text-light: #555555;
    
    /* Configuración */
    --header-height: 90px;
    --container-width: 1200px;
    --radius: 8px;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
    --shadow-md: 0 5px 15px rgba(0,0,0,0.1);
    --shadow-card: 0 10px 30px -5px rgba(0, 0, 0, 0.08);
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* --- 2. RESET Y TIPOGRAFÍA GLOBAL --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }

body {
    font-family: 'Open Sans', 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--white);
    color: var(--text-main);
    line-height: 1.6;
    margin: 0;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 { 
    font-family: 'Montserrat', sans-serif; 
    color: var(--uce-dark); 
    font-weight: 700; 
    margin-bottom: 1rem; 
}

p { margin-bottom: 1.5rem; font-size: 1rem; }
a { text-decoration: none; color: inherit; transition: var(--transition); }
ul { list-style: none; padding: 0; margin: 0; }
img { max-width: 100%; height: auto; display: block; }

/* --- 3. UTILIDADES --- */
.container {
    width: 100%; max-width: var(--container-width);
    margin: 0 auto !important; padding: 0 20px; position: relative;
}
.container-narrow { max-width: 850px; margin: 0 auto !important; }

.text-center { text-align: center !important; }
.text-justify { text-align: justify !important; }
.mt-30 { margin-top: 30px; }
.mb-30 { margin-bottom: 30px; }
.bg-light { background-color: var(--gray-50); }
.section-padding { padding: 60px 0; }
.section-padding.pb-0 { padding-top: 40px; padding-bottom: 0 !important; }

/* Títulos Generales (Reducidos ligeramente) */
.section-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 2rem; /* ANTES 2.5rem */
    color: var(--uce-dark); 
    font-weight: 800;
    text-transform: uppercase; 
    margin-bottom: 1rem; 
    letter-spacing: -0.5px;
    text-align: center; 
    width: 100%;
}
.section-subtitle {
    display: block; width: 60px; height: 4px; 
    background: var(--uce-accent);
    margin: 0 auto 40px auto; 
    border-radius: 3px;
}


/* ==========================================================================
   4. HEADER Y NAVEGACIÓN
   ========================================================================== */
#site-header {
    position: fixed; top: 0; left: 0; width: 100%; height: var(--header-height);
    background: var(--white); box-shadow: 0 2px 10px rgba(0,0,0,0.1); z-index: 9999;
}
.header-spacer { height: var(--header-height); }
.header-inner {
    display: flex; justify-content: space-between; align-items: center;
    height: 100%; position: relative;
}
.header-logo img { max-height: 60px; width: auto; display: block; }
.arrow-icon {
    font-size: 0.75rem; margin-left: 6px; 
    color: var(--uce-accent); transition: transform 0.3s;
}

/* Escritorio */
@media (min-width: 993px) {
    #menu-toggle { display: none; }
    .menu-items { display: flex; align-items: center; gap: 20px; list-style: none; margin: 0; padding: 0; }
    .menu-link {
        font-family: 'Montserrat', sans-serif; font-weight: 600; font-size: 0.85rem;
        text-transform: uppercase; color: var(--text-main); padding: 10px 5px; 
        position: relative; display: flex; align-items: center;
    }
    .menu-link:hover { color: var(--uce-dark); }
    .has-submenu { position: relative; height: var(--header-height); display: flex; align-items: center; }
    .has-submenu:hover .arrow-icon { transform: rotate(180deg); }
    
    .submenu {
        position: absolute; top: 100%; left: 0; min-width: 220px;
        background: var(--white); box-shadow: 0 5px 20px rgba(0,0,0,0.1);
        border-top: 3px solid var(--uce-accent); visibility: hidden; opacity: 0;
        transform: translateY(10px); transition: all 0.3s ease; padding: 0;
        border-radius: 0 0 4px 4px;
    }
    .has-submenu:hover .submenu { visibility: visible; opacity: 1; transform: translateY(0); }
    .submenu li { border-bottom: 1px solid var(--gray-100); }
    .submenu a { display: block; padding: 10px 20px; font-size: 0.85rem; font-weight: 600; color: var(--text-light); }
    .submenu a:hover { background: var(--gray-50); color: var(--uce-dark); padding-left: 25px; }

    .btn-socio {
        background: var(--uce-light); color: var(--uce-dark); padding: 8px 20px;
        border-radius: 50px; font-weight: 700; text-transform: uppercase;
        font-size: 0.8rem; transition: 0.3s; border: 2px solid transparent;
    }
    .btn-socio:hover { background: var(--uce-dark); color: var(--white); }
}

/* Móvil */
@media (max-width: 992px) {
    :root { --header-height: 70px; }
    #menu-toggle {
        display: block; background: none; border: none; cursor: pointer; padding: 10px; 
        z-index: 10001; position: relative;
    }
    #menu-toggle span {
        display: block; width: 25px; height: 2px; background: var(--uce-dark);
        margin: 5px 0; transition: 0.3s; border-radius: 3px;
    }
    #menu-toggle.is-active span:nth-child(1) { transform: rotate(-45deg) translate(-5px, 5px); background: var(--uce-accent); }
    #menu-toggle.is-active span:nth-child(2) { opacity: 0; }
    #menu-toggle.is-active span:nth-child(3) { transform: rotate(45deg) translate(-5px, -5px); background: var(--uce-accent); }

    #site-navigation {
        position: fixed; top: 0; right: -100%; width: 85%; max-width: 320px;
        height: 100vh; background: var(--white); padding: 80px 20px 40px;
        box-shadow: -5px 0 20px rgba(0,0,0,0.1); transition: right 0.4s cubic-bezier(0.77, 0, 0.175, 1);
        z-index: 10000; overflow-y: auto;
    }
    #site-navigation.is-open { right: 0; }
    #site-navigation.is-open::before {
        content: ''; position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
        background: rgba(0,0,0,0.5); z-index: -1; transform: translateX(-100%);
    }

    .menu-items { display: flex; flex-direction: column; width: 100%; }
    .menu-items li { width: 100%; border-bottom: 1px solid var(--gray-100); }
    .menu-link {
        display: flex; justify-content: space-between; align-items: center; padding: 12px 0;
        font-size: 1rem; color: var(--text-main); font-weight: 700;
        text-transform: uppercase; font-family: 'Montserrat', sans-serif;
    }
    .submenu {
        display: none !important; background: var(--gray-50) !important; padding-left: 15px;
        border-left: 3px solid var(--uce-accent); margin-bottom: 10px; position: static !important;
        opacity: 1 !important; visibility: visible !important; transform: none !important; box-shadow: none !important;
    }
    .has-submenu.submenu-open .submenu { display: block !important; }
    .has-submenu.submenu-open .arrow-icon { transform: rotate(180deg); }
    .submenu a { padding: 10px 0; font-size: 0.9rem; display: block; color: var(--text-light); border-bottom: 1px dashed var(--gray-200); }
    
    .cta-item { border: none !important; margin-top: 20px; text-align: center; }
    .btn-socio {
        display: block; width: 100%; background: var(--uce-dark); color: var(--white);
        padding: 12px; border-radius: 8px; font-size: 1rem; text-transform: uppercase; font-weight: 700;
    }
}


/* ==========================================================================
   5. HOME (PORTADA)
   ========================================================================== */
.hero {
    position: relative; height: 75vh; min-height: 400px;
    background: linear-gradient(to right, rgba(4,63,31,0.9), rgba(4,63,31,0.6)), url('../../images/slideshow/large/slider-4_2.png');
    background-size: cover; background-position: center;
    display: flex; align-items: center; justify-content: center; text-align: center;
    color: var(--white);
}
.hero-content { width: 100%; max-width: 900px; }
/* TEXTO BLANCO FORZADO */
.hero-content h1 { 
    font-size: 2.8rem; margin-bottom: 20px; line-height: 1.2; color: #ffffff !important; 
}
.hero-content p { 
    font-size: 1.1rem; opacity: 0.95; color: #ffffff !important; max-width: 700px; margin: 0 auto 30px; 
}
.hero-buttons { display: flex; gap: 15px; justify-content: center; }
.btn {
    display: inline-block; padding: 12px 30px; border-radius: 50px;
    font-weight: 700; text-transform: uppercase; transition: 0.3s;
    text-align: center; cursor: pointer; font-size: 0.9rem; letter-spacing: 0.5px;
}
.btn-primary { background: var(--uce-accent); color: var(--uce-dark); }
.btn-primary:hover { background: var(--white); transform: translateY(-2px); }
.btn-outline { border: 2px solid var(--white); color: var(--white); }
.btn-outline:hover { background: var(--white); color: var(--uce-dark); }

@media (max-width: 768px) {
    .hero { height: auto; padding: 120px 0 60px 0; }
    .hero-content h1 { font-size: 2rem; }
    .hero-buttons { flex-direction: column; width: 100%; gap: 10px; }
    .btn { width: 100%; }
}

/* Servicios Grid */
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 25px; }
.service-card {
    background: var(--white); padding: 30px 20px; border-radius: var(--radius); text-align: center;
    border: 1px solid var(--gray-100); transition: var(--transition);
}
.service-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: var(--uce-light); }
.icon-circle {
    width: 70px; height: 70px; margin: 0 auto 20px;
    background: var(--uce-light); color: var(--uce-dark); border-radius: 50%;
    display: flex; align-items: center; justify-content: center; font-size: 2rem;
}
.service-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 10px; color: var(--uce-dark); }

/* Noticias Grid */
.news-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 30px; }
.news-card {
    background: var(--white); border-radius: var(--radius); overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05); border-top: 3px solid var(--uce-dark);
    display: flex; flex-direction: column; transition: var(--transition);
}
.news-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-card); }
.news-body { padding: 20px; display: flex; flex-direction: column; flex-grow: 1; }
.news-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 12px; line-height: 1.4; }
.news-link { color: var(--uce-dark); font-weight: 700; font-size: 0.85rem; text-transform: uppercase; }

/* CTA Banner */
.cta-section {
    background: var(--uce-dark); color: var(--white); padding: 70px 0; text-align: center;
    background-image: linear-gradient(rgba(4,63,31,0.9), rgba(4,63,31,0.9)), url('../../images/slideshow/large/slider-3_2.png');
    background-size: cover;
}
.cta-section h2 { color: var(--white); font-size: 2.2rem; margin-bottom: 15px; }
.btn-white {
    background: var(--uce-accent); color: var(--uce-dark); padding: 15px 35px;
    border-radius: 50px; font-weight: 800; text-transform: uppercase;
    display: inline-block; transition: var(--transition);
}
.btn-white:hover { background: var(--white); transform: translateY(-3px); }


/* ==========================================================================
   6. PÁGINAS INTERNAS (General, Legal, Cookies, Socios)
   ========================================================================== */
.internal-hero { 
    margin-top: var(--header-height); background-color: var(--white); 
    padding: 40px 0 20px; text-align: center; border-bottom: 1px solid var(--gray-100); 
}
.internal-hero h1 { 
    font-size: 2.2rem; text-transform: uppercase; color: var(--uce-dark); 
    margin-bottom: 10px; letter-spacing: -0.5px; 
}
.internal-hero::after { 
    content: ''; display: block; width: 60px; height: 4px; 
    background: var(--uce-accent); margin: 15px auto 0; 
}
.lead-text { font-size: 1.1rem; color: var(--text-light); max-width: 800px; margin: 0 auto; }

.text-block p { font-size: 1rem; color: var(--text-main); margin-bottom: 1.5rem; text-align: justify; }
.text-block h2 { font-size: 1.6rem; margin-top: 2rem; color: var(--uce-dark); border-bottom: 2px solid var(--uce-light); padding-bottom: 8px; }
.text-block h3 { font-size: 1.4rem; margin-top: 1.5rem; color: var(--uce-dark); font-weight: 700; }
.text-block h4 { font-size: 1.1rem; margin-top: 1.5rem; color: var(--text-main); font-weight: 700; }
.text-block ul { list-style: disc; padding-left: 20px; margin-bottom: 20px; }
.text-block li { margin-bottom: 10px; color: var(--text-main); }

/* Tablas (Cookies) */
.cookie-table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 0.95rem; }
.cookie-table th, .cookie-table td { border: 1px solid #e9ecef; padding: 12px 15px; text-align: left; }
.cookie-table th { background-color: #f8f9fa; font-weight: 700; color: var(--uce-dark); }
.cookie-table tr:nth-child(even) { background-color: #fcfcfc; }

/* Cajas destacadas (Legal / UceBurgos) */
.highlight-box {
    background: #f4fcf0; border-left: 4px solid var(--uce-accent);
    padding: 20px; margin: 30px 0; font-size: 1rem; color: var(--text-main);
    border-radius: 0 8px 8px 0;
}

/* Estilos Listados (Consejos, Noticias) */
.news-grid-internal { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 30px; }
.news-card-internal {
    background: var(--white); border-radius: var(--radius); overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05); border: 1px solid var(--gray-200);
    border-bottom: 3px solid var(--uce-dark); display: flex; flex-direction: column;
    height: 100%; transition: var(--transition);
}
.news-card-internal:hover { transform: translateY(-5px); box-shadow: var(--shadow-card); border-bottom-color: var(--uce-accent); }
.news-card-internal .news-body { padding: 20px; display: flex; flex-direction: column; flex-grow: 1; }
.news-card-internal h5 { font-family: 'Montserrat', sans-serif; font-size: 1.05rem; font-weight: 700; margin-bottom: 10px; }
.news-card-internal .date-badge {
    display: inline-block; padding: 3px 8px; border-radius: 4px; 
    font-size: 0.7rem; font-weight: 700; margin-bottom: 12px; 
    background: var(--uce-light); color: var(--uce-dark);
}
.btn-text { color: var(--uce-dark); font-weight: 700; text-transform: uppercase; font-size: 0.9rem; margin-top: auto; }

/* --- PESTAÑAS Y VALORES (RECUPERADO) --- */
.modern-tabs { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow-md); overflow: hidden; border: 1px solid var(--gray-100); margin-top: 20px; }
.tabs-nav-wrapper { background: var(--gray-50); border-bottom: 1px solid var(--gray-200); padding: 0 20px; }
.tabs-nav { display: flex; gap: 20px; overflow-x: auto; }
.tab-link { padding: 15px 5px; background: none; border: none; font-family: 'Montserrat', sans-serif; font-size: 0.95rem; font-weight: 600; color: var(--text-light); cursor: pointer; position: relative; transition: var(--transition); white-space: nowrap; }
.tab-link:hover { color: var(--uce-dark); }
.tab-link.active { color: var(--uce-dark); font-weight: 800; border-bottom: 3px solid var(--uce-accent); }
.tabs-body { padding: 40px; }
.tab-panel { display: none; animation: fadeIn 0.4s ease; }
.tab-panel.active { display: block; }
.grid-2-col { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.feature-item h4 { color: var(--uce-dark); font-weight: 700; margin-bottom: 10px; font-size: 1.05rem; display: flex; align-items: center; gap: 10px; }
.icon-circle-small { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; background: var(--uce-light); color: var(--uce-dark); border-radius: 50%; flex-shrink: 0; }
.modern-list { list-style: none; padding: 0; }
.modern-list li { position: relative; padding-left: 30px; margin-bottom: 15px; }
.modern-list li::before { content: ''; position: absolute; left: 0; top: 8px; width: 6px; height: 6px; background: var(--uce-accent); border-radius: 50%; }

.values-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 30px; margin-top: 20px; }
.value-card { background: var(--white); padding: 30px 20px; border-radius: var(--radius); text-align: center; border: 1px solid var(--gray-100); box-shadow: 0 5px 15px rgba(0,0,0,0.03); transition: var(--transition); }
.value-card:hover { transform: translateY(-10px); box-shadow: var(--shadow-card); border-color: var(--uce-light); }
.value-card.highlight { border: 2px solid var(--uce-accent); background: #fafdf5; }
.value-icon { width: 60px; height: 60px; margin: 0 auto 20px; background: var(--uce-light); color: var(--uce-dark); border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: var(--transition); }
.value-card:hover .value-icon { background: var(--uce-dark); color: var(--uce-accent); }
.value-card h3 { font-family: 'Montserrat', sans-serif; font-size: 1.2rem; color: var(--uce-dark); font-weight: 700; margin-bottom: 10px; }

/* ==========================================================================
   7. CONTACTO Y SOCIOS
   ========================================================================== */
.contact-grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: 40px; }
.contact-info-card { background: var(--white); border: 1px solid var(--gray-200); padding: 30px; border-radius: var(--radius); box-shadow: var(--shadow-md); }
.info-item { margin-bottom: 25px; padding-left: 40px; position: relative; }
.info-item h4 { font-size: 1rem; font-weight: 700; color: var(--uce-dark); text-transform: uppercase; }
.info-icon { position: absolute; left: 0; top: 0; width: 30px; height: 30px; background: var(--uce-light); color: var(--uce-dark); border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.contact-form-wrapper { background: var(--white); padding: 40px; border-radius: var(--radius); box-shadow: var(--shadow-md); border-top: 4px solid var(--uce-dark); }
.form-control { width: 100%; padding: 12px; border: 2px solid var(--gray-200); border-radius: 6px; margin-bottom: 20px; font-family: inherit; }
.btn-submit { width: 100%; padding: 15px; background: var(--uce-dark); color: var(--white); border: none; border-radius: 50px; font-weight: 700; cursor: pointer; text-transform: uppercase; transition: 0.3s; }
.btn-submit:hover { background: var(--uce-accent); color: var(--uce-dark); }
.map-container { margin-top: 30px; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }

.benefits-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 25px; margin-bottom: 40px; }
.benefit-card { background: var(--white); padding: 25px; text-align: center; border: 1px solid var(--gray-200); border-radius: var(--radius); transition: 0.3s; }
.benefit-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: var(--uce-light); }
.benefit-icon { font-size: 1.8rem; color: var(--uce-dark); margin-bottom: 15px; }
.pricing-card { background: var(--uce-dark); color: var(--white); padding: 35px; border-radius: var(--radius); text-align: center; max-width: 700px; margin: 0 auto 50px; }
.pricing-amount { font-size: 3rem; font-weight: 800; color: var(--uce-accent); margin: 15px 0; }
.pricing-header h3 { color: var(--white); }
.socios-form-wrapper { background: var(--white); padding: 40px; border-radius: var(--radius); box-shadow: var(--shadow-card); border-top: 4px solid var(--uce-accent); }
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 25px; }
.form-section-title { grid-column: 1 / -1; font-size: 1.1rem; font-weight: 700; color: var(--uce-dark); border-bottom: 2px solid var(--gray-200); padding-bottom: 10px; margin: 15px 0; }
.full-width { grid-column: 1 / -1; }
.btn-submit-big { width: 100%; padding: 18px; background: var(--uce-dark); color: var(--white); font-size: 1rem; font-weight: 800; border: none; border-radius: 8px; cursor: pointer; }


/* ==========================================================================
   8. FOOTER (V10 - RESPONSIVE ARREGLADO)
   ========================================================================== */
#main-footer { background: var(--uce-light); border-top: 5px solid var(--uce-dark); padding-top: 50px; color: var(--text-main); position: relative; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1.5fr; gap: 40px; margin-bottom: 30px; align-items: start; }

.footer-logo { max-width: 160px; margin-bottom: 15px; }
.footer-col h4 { font-size: 1rem; font-weight: 700; text-transform: uppercase; color: var(--uce-dark); margin-bottom: 20px; }
.modern-socials { display: flex; gap: 20px; justify-content: flex-start; margin-top: 20px; align-items: center; }
/* Iconos del Footer: Tamaño reducido */
.social-link { display: flex; align-items: center; justify-content: center; color: var(--uce-dark); font-size: 1.5rem; transition: 0.3s; text-decoration: none; }
.social-link:hover { transform: translateY(-3px); color: var(--uce-accent); }
.footer-links li { margin-bottom: 8px; }
.footer-links a { font-weight: 600; color: var(--text-light); font-size: 0.9rem; }
.footer-links a:hover { color: var(--uce-dark); padding-left: 5px; }
.footer-right { text-align: right; display: flex; flex-direction: column; align-items: flex-end; }
.institutional-block { display: flex; flex-direction: column; align-items: flex-end; text-align: left; max-width: 280px; }
.junta-logo { max-width: 200px; height: auto; margin-bottom: 15px; align-self: flex-start; }
.footer-right .institutional-block { align-items: flex-start; }
.legal-note { font-size: 0.8rem; line-height: 1.4; color: #555; }
.footer-bottom { background: var(--uce-dark); color: var(--white); padding: 15px 0; text-align: center; font-size: 0.8rem; }
#back-to-top { position: fixed; bottom: 30px; right: 30px; width: 45px; height: 45px; background: var(--uce-accent); color: var(--uce-dark); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; opacity: 0; visibility: hidden; transition: all 0.3s; z-index: 9990; box-shadow: 0 4px 10px rgba(0,0,0,0.2); }
#back-to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
#back-to-top:hover { background: var(--uce-dark); color: var(--white); }

/* --- BREAKPOINT CRÍTICO PARA TABLET/MÓVIL (< 992px) --- 
   Todo el footer se pone en 1 sola columna para evitar desbordamiento */
@media (max-width: 992px) {
    .footer-grid { grid-template-columns: 1fr; text-align: center; gap: 40px; }
    .footer-left, .footer-right { align-items: center; display: flex; flex-direction: column; }
    .footer-right { grid-column: auto; }
    .institutional-block { align-items: center; text-align: center; }
    .junta-logo { align-self: center; }
    .modern-socials { justify-content: center; }
    .contact-grid, .grid-2-col, .form-grid-2 { grid-template-columns: 1fr; }
}


/* ==========================================================================
   9. GDPR (COOKIES - ESTILIZADO Y MEJORADO)
   ========================================================================== */
.cookie-banner { 
    position: fixed; bottom: -100%; left: 0; width: 100%; 
    background: var(--white); border-top: 4px solid var(--uce-accent); 
    padding: 30px; z-index: 100000; display: flex; justify-content: center; 
    transition: bottom 0.5s ease-in-out; box-shadow: 0 -5px 20px rgba(0,0,0,0.15); 
}
.cookie-banner.show { bottom: 0; }
.cookie-content { width: 100%; max-width: 1100px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 25px; }
.cookie-text { flex: 1; font-size: 0.95rem; color: var(--text-main); line-height: 1.5; }
.cookie-text a { color: var(--uce-dark); font-weight: 700; text-decoration: underline; }
.cookie-buttons { display: flex; gap: 12px; }

/* Botones Cookies */
.btn-cookie { padding: 10px 25px; border-radius: 6px; font-weight: 700; font-size: 0.85rem; cursor: pointer; border: 2px solid transparent; transition: 0.3s; font-family: 'Montserrat', sans-serif; }
.btn-accept { background: var(--uce-dark); color: var(--white); }
.btn-accept:hover { background: var(--uce-accent); color: var(--uce-dark); }
.btn-reject { background: transparent; border-color: var(--gray-200); color: var(--text-light); }
.btn-reject:hover { border-color: var(--text-main); color: var(--text-main); }
.btn-manage { background: transparent; color: var(--uce-dark); text-decoration: underline; font-weight: 600; padding: 10px; }
.btn-manage:hover { color: var(--uce-accent); }

/* Modal Cookies */
.cookie-modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.6); z-index: 100001; justify-content: center; align-items: center; backdrop-filter: blur(3px); }
.cookie-modal.open { display: flex; animation: fadeIn 0.3s; }
.cookie-modal-content { background: #fff; padding: 30px; border-radius: 12px; max-width: 550px; width: 90%; box-shadow: 0 15px 40px rgba(0,0,0,0.2); }
.cookie-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 25px; border-bottom: 1px solid #eee; padding-bottom: 15px; }
.cookie-header h3 { font-size: 1.4rem; font-weight: 800; color: var(--uce-dark); margin: 0; }
.close-modal { background: #f0f0f0; border: none; font-size: 1.5rem; cursor: pointer; color: #666; width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: 0.3s; }
.close-modal:hover { background: var(--uce-dark); color: white; }

.cookie-option { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; padding: 15px; background: #f9f9f9; border-radius: 8px; border: 1px solid #eee; }
.cookie-label p { font-weight: 700; font-size: 1rem; margin-bottom: 4px; color: var(--text-main); }
.cookie-label span { font-size: 0.85rem; color: #666; }

/* Switch */
.switch { position: relative; display: inline-block; width: 46px; height: 24px; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: #ccc; transition: .4s; border-radius: 34px; }
.slider:before { position: absolute; content: ""; height: 18px; width: 18px; left: 3px; bottom: 3px; background-color: white; transition: .4s; border-radius: 50%; }
input:checked + .slider { background-color: var(--uce-dark); }
input:checked + .slider:before { transform: translateX(22px); }
input:disabled + .slider { opacity: 0.5; cursor: not-allowed; }

.save-prefs { width: 100%; padding: 14px; background: var(--uce-dark); color: #fff; border: none; border-radius: 8px; margin-top: 20px; cursor: pointer; font-weight: 700; text-transform: uppercase; transition: 0.3s; }
.save-prefs:hover { background: var(--uce-accent); color: var(--uce-dark); }

@media (max-width: 768px) {
    .cookie-content { flex-direction: column; text-align: center; }
    .cookie-buttons { width: 100%; justify-content: center; }
}

/* ==========================================================================
   10. ERROR 404 & FICHA SEGURIDAD
   ========================================================================== */
.error-container { text-align: center; padding: 80px 20px; max-width: 600px; margin: 0 auto; }
.error-code { font-family: 'Montserrat', sans-serif; font-size: 8rem; font-weight: 900; color: var(--uce-dark); line-height: 1; margin-bottom: 20px; text-shadow: 4px 4px 0px var(--uce-light); }
.error-title { font-size: 1.5rem; font-weight: 700; margin-bottom: 20px; color: var(--text-main); }
.error-text { font-size: 1.1rem; color: var(--text-light); margin-bottom: 40px; }
.btn-home { display: inline-block; background-color: var(--uce-accent); color: var(--uce-dark); padding: 15px 30px; border-radius: 50px; text-decoration: none; font-weight: bold; text-transform: uppercase; transition: all 0.3s; }
.btn-home:hover { background-color: var(--uce-dark); color: var(--white); transform: translateY(-3px); }
.search-links { margin-top: 40px; border-top: 1px solid #eee; padding-top: 30px; }
.search-links a { color: var(--uce-dark); margin: 0 10px; font-weight: 600; }
.search-links a:hover { text-decoration: underline; }

.security-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: #f0fdf4; display: flex; justify-content: center; align-items: center; z-index: 10000; padding: 20px; }
.security-card { background: var(--white); padding: 50px 40px; border-radius: var(--radius); box-shadow: 0 20px 50px rgba(4, 63, 31, 0.15); width: 100%; max-width: 480px; text-align: center; border-top: 5px solid var(--uce-dark); animation: slideUp 0.5s ease-out; }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.security-card h2 { font-family: 'Montserrat', sans-serif; font-size: 1.8rem; color: var(--uce-dark); margin-bottom: 15px; font-weight: 800; }
.input-pin-large { width: 100%; padding: 15px; font-size: 2rem; letter-spacing: 10px; text-align: center; border: 2px solid var(--gray-200); border-radius: 8px; margin-bottom: 25px; font-weight: 700; color: var(--uce-dark); transition: var(--transition); }
.input-pin-large:focus { border-color: var(--uce-accent); outline: none; box-shadow: 0 0 0 4px rgba(159, 193, 0, 0.2); }
.btn-verify-large { width: 100%; padding: 18px; background: var(--uce-dark); color: var(--white); border: none; border-radius: 50px; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; cursor: pointer; transition: var(--transition); font-size: 1rem; }
.btn-verify-large:hover { background: var(--uce-accent); color: var(--uce-dark); transform: translateY(-2px); box-shadow: 0 10px 20px rgba(0,0,0,0.1); }
.msg-box { padding: 15px; border-radius: 6px; font-size: 0.9rem; margin-bottom: 20px; text-align: left; }
.msg-box.success { background: #f0fdf4; border: 1px solid #bbf7d0; color: #166534; }
.msg-box.error { background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; }