        /* ==========================================================================
           1. VARIABLES DE TEMA (PALETA CLÁSICA EDITORIAL AZUL UAS)
           ========================================================================== */
        :root,
        [data-theme="light"] {
            --bg-body: #F4F8FF;
            /* Blanco hielo azulado muy limpio */
            --bg-surface: #FFFFFF;
            /* Blanco puro para tarjetas y bloques */
            --bg-subtle: #E6F0FF;
            /* Azul hielo suave para fondos secundarios */
            --bg-header: #FFFFFF;

            --uas-navy: #003366;
            /* Azul Marino Institucional UAS */
            --uas-royal: #0055A5;
            /* Azul Real Académico */
            --uas-sky: #0284C7;
            /* Azul Cielo para acentos interactivos */
            --uas-gold: #C59B27;
            /* Dorado Institucional UAS */
            --uas-gold-light: #FEF9E7;

            --text-main: #0F172A;
            /* Azul pizarra oscuro para lectura nítida */
            --text-secondary: #334155;
            --text-muted: #64748B;

            --border-color: #CBD5E1;
            --border-blue: #BFDBFE;
            /* Borde azul celeste característico */

            --shadow-sm: 0 2px 6px rgba(0, 51, 102, 0.05);
            --shadow-md: 0 8px 24px rgba(0, 51, 102, 0.08);

            --font-serif: 'Merriweather', Georgia, serif;
            --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
            --radius: 8px;
        }

        /* MODO OSCURO: DEEP NAVY INSTITUCIONAL */
        [data-theme="dark"] {
            --bg-body: #071326;
            /* Azul nocturno profundo */
            --bg-surface: #0D213F;
            /* Azul marino para tarjetas */
            --bg-subtle: #132C52;
            /* Azul intermedio para bloques secundarios */
            --bg-header: #0A192F;

            --uas-navy: #38BDF8;
            /* Azul celeste luminoso para títulos en oscuro */
            --uas-royal: #60A5FA;
            /* Azul brillante para botones/enlaces */
            --uas-sky: #7DD3FC;
            --uas-gold: #E5C158;
            /* Dorado luminoso de alto contraste */
            --uas-gold-light: rgba(229, 193, 88, 0.12);

            --text-main: #F1F5F9;
            --text-secondary: #CBD5E1;
            --text-muted: #94A3B8;

            --border-color: #1E3A5F;
            --border-blue: #1E40AF;

            --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.35);
            --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.5);
        }

        /* ==========================================================================
           2. RESET Y ESTILOS BASE
           ========================================================================== */
        * {
            box-sizing: border-box;
            margin: 0;
            padding: 0;
        }

        body {
            font-family: var(--font-sans);
            background-color: var(--bg-body);
            color: var(--text-main);
            line-height: 1.65;
            transition: background-color 0.25s ease, color 0.25s ease;
        }

        h1,
        h2,
        h3,
        h4,
        .serif-title {
            font-family: var(--font-serif);
            color: var(--uas-navy);
            line-height: 1.3;
        }

        a {
            color: var(--uas-royal);
            text-decoration: none;
            transition: color 0.2s ease;
        }

        a:hover {
            color: var(--uas-sky);
        }

        .container {
            max-width: 1200px;
            margin: 0 auto;
            padding: 0 1.25rem;
        }

        /* ==========================================================================
           3. ENCABEZADO INSTITUCIONAL (HEADER.PHP)
           ========================================================================== */
        .top-bar {
            background-color: #002244;
            color: #E2E8F0;
            font-size: 0.82rem;
            padding: 0.45rem 0;
            border-bottom: 2px solid var(--uas-gold);
        }

        .top-bar-inner {
            display: flex;
            justify-content: space-between;
            align-items: center;
            flex-wrap: wrap;
            gap: 0.5rem;
        }

        .top-bar a {
            color: #93C5FD;
            margin-left: 1rem;
        }

        .top-bar a:hover {
            color: #FFFFFF;
        }

        .site-header {
            background-color: var(--bg-header);
            padding: 1.35rem 0;
            border-bottom: 1px solid var(--border-blue);
            box-shadow: var(--shadow-sm);
        }

        .header-brand {
            display: flex;
            align-items: center;
            justify-content: space-between;
            flex-wrap: wrap;
            gap: 1.25rem;
        }

        .brand-left {
            display: flex;
            align-items: center;
            gap: 1.15rem;
        }

        .uas-emblem {
            width: 64px;
            height: 64px;
            background: linear-gradient(135deg, #003366 0%, #0055A5 100%);
            border: 2.5px solid var(--uas-gold);
            border-radius: 50%;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            color: #FFFFFF;
            font-weight: 700;
            font-size: 0.85rem;
            flex-shrink: 0;
            box-shadow: 0 4px 10px rgba(0, 51, 102, 0.2);
        }

        .uas-emblem span {
            font-size: 0.65rem;
            color: #FDE047;
            letter-spacing: 1px;
        }

        .brand-titles .ca-badge {
            display: inline-block;
            background-color: var(--bg-subtle);
            color: var(--uas-royal);
            border: 1px solid var(--border-blue);
            font-size: 0.75rem;
            font-weight: 700;
            padding: 0.15rem 0.65rem;
            border-radius: 4px;
            margin-bottom: 0.3rem;
            letter-spacing: 0.5px;
        }

        .brand-titles h1 {
            font-size: 1.45rem;
            margin-bottom: 0.2rem;
        }

        .brand-titles p {
            font-size: 0.88rem;
            color: var(--text-secondary);
            font-weight: 500;
        }

        /* BARRA DE NAVEGACIÓN AZUL EDITORIAL */
        .main-nav {
            background: linear-gradient(90deg, #003366 0%, #004E98 100%);
            position: sticky;
            top: 0;
            z-index: 100;
            box-shadow: 0 4px 12px rgba(0, 51, 102, 0.18);
        }

        .nav-container {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 0.5rem;
        }

        .nav-links {
            display: flex;
            list-style: none;
            overflow-x: auto;
            flex: 1;
            min-width: 0;
            scrollbar-width: none;
        }

        .nav-links::-webkit-scrollbar {
            display: none;
        }

        .nav-btn {
            background: transparent;
            border: none;
            color: rgba(255, 255, 255, 0.88);
            font-family: var(--font-sans);
            font-size: 0.92rem;
            font-weight: 500;
            padding: 0.9rem 1.25rem;
            cursor: pointer;
            display: flex;
            align-items: center;
            gap: 0.5rem;
            border-bottom: 3px solid transparent;
            transition: all 0.2s ease;
            white-space: nowrap;
        }

        .nav-btn:hover {
            color: #FFFFFF;
            background-color: rgba(255, 255, 255, 0.08);
        }

        .nav-btn.active {
            color: #FFFFFF;
            font-weight: 600;
            background-color: rgba(255, 255, 255, 0.14);
            border-bottom-color: #FACC15;
        }

        .nav-actions {
            display: flex;
            align-items: center;
            gap: 0.75rem;
            flex-shrink: 0;
        }

        .theme-toggle {
            background-color: rgba(255, 255, 255, 0.12);
            color: #FFFFFF;
            border: 1px solid rgba(255, 255, 255, 0.25);
            padding: 0.45rem 0.85rem;
            border-radius: 6px;
            cursor: pointer;
            font-size: 0.85rem;
            font-weight: 500;
            display: flex;
            align-items: center;
            gap: 0.45rem;
            white-space: nowrap;
            transition: background 0.2s ease;
        }

        .theme-toggle:hover {
            background-color: rgba(255, 255, 255, 0.22);
        }

        /* ==========================================================================
           4. SISTEMA DE VISTAS Y COMPONENTES GENERALES
           ========================================================================== */
        .view-section {
            display: none;
            padding: 2.25rem 0 3.5rem;
            animation: fadeIn 0.25s ease;
        }

        .view-section.active {
            display: block;
        }

        @keyframes fadeIn {
            from {
                opacity: 0;
                transform: translateY(6px);
            }

            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .section-header {
            display: flex;
            justify-content: space-between;
            align-items: flex-end;
            margin-bottom: 1.75rem;
            padding-bottom: 0.75rem;
            border-bottom: 2px solid var(--border-blue);
            flex-wrap: wrap;
            gap: 1rem;
        }

        .section-header h2 {
            font-size: 1.55rem;
            position: relative;
        }

        .section-header h2::after {
            content: '';
            position: absolute;
            left: 0;
            bottom: -0.85rem;
            width: 70px;
            height: 3px;
            background-color: var(--uas-gold);
        }

        /* TARJETAS CLÁSICAS EDITORIALES AZULES */
        .card {
            background-color: var(--bg-surface);
            border: 1px solid var(--border-blue);
            border-top: 4px solid var(--uas-royal);
            border-radius: var(--radius);
            padding: 1.5rem;
            box-shadow: var(--shadow-sm);
            transition: transform 0.2s ease, box-shadow 0.2s ease;
        }

        .card:hover {
            transform: translateY(-2px);
            box-shadow: var(--shadow-md);
        }

        .card-gold-top {
            border-top-color: var(--uas-gold);
        }

        /* BOTONES */
        .btn {
            display: inline-flex;
            align-items: center;
            gap: 0.45rem;
            padding: 0.6rem 1.15rem;
            border-radius: 6px;
            font-size: 0.9rem;
            font-weight: 600;
            cursor: pointer;
            border: 1px solid transparent;
            transition: all 0.2s ease;
        }

        .btn-primary {
            background-color: var(--uas-royal);
            color: #FFFFFF;
        }

        .btn-primary:hover {
            background-color: #003E7E;
            color: #FFFFFF;
        }

        .btn-outline {
            background-color: transparent;
            border-color: var(--uas-royal);
            color: var(--uas-royal);
        }

        .btn-outline:hover {
            background-color: var(--bg-subtle);
        }

        .btn-sm {
            padding: 0.35rem 0.75rem;
            font-size: 0.8rem;
        }

        /* ==========================================================================
           5. VISTA 1: INICIO (HERO, LGAC Y NOTICIAS)
           ========================================================================== */
        .hero-box {
            background: linear-gradient(135deg, var(--bg-surface) 0%, var(--bg-subtle) 100%);
            border: 1px solid var(--border-blue);
            border-left: 6px solid var(--uas-navy);
            border-radius: var(--radius);
            padding: 2.25rem;
            margin-bottom: 2.5rem;
            display: grid;
            grid-template-columns: 1.6fr 1fr;
            gap: 2rem;
            align-items: center;
            box-shadow: var(--shadow-sm);
        }

        .hero-content h2 {
            font-size: 1.85rem;
            margin-bottom: 0.85rem;
        }

        .hero-content p {
            color: var(--text-secondary);
            margin-bottom: 1.35rem;
            font-size: 1.02rem;
        }

        .prodep-card {
            background-color: var(--bg-surface);
            border: 1px solid var(--border-blue);
            border-top: 4px solid var(--uas-gold);
            border-radius: var(--radius);
            padding: 1.35rem;
        }

        .prodep-card h3 {
            font-size: 1rem;
            margin-bottom: 0.85rem;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        .meta-list {
            list-style: none;
            font-size: 0.88rem;
        }

        .meta-list li {
            display: flex;
            justify-content: space-between;
            padding: 0.45rem 0;
            border-bottom: 1px dashed var(--border-color);
        }

        .meta-list li:last-child {
            border-bottom: none;
        }

        .grid-3 {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(310px, 1fr));
            gap: 1.5rem;
            margin-bottom: 2.5rem;
        }

        .grid-2 {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
            gap: 1.5rem;
        }

        .badge-tag {
            display: inline-block;
            padding: 0.2rem 0.6rem;
            font-size: 0.75rem;
            font-weight: 600;
            border-radius: 4px;
            background-color: var(--bg-subtle);
            color: var(--uas-royal);
            border: 1px solid var(--border-blue);
        }

        .badge-gold {
            background-color: var(--uas-gold-light);
            color: #9A7B1C;
            border-color: var(--uas-gold);
        }

        .p-hero {
            text-align: justify;
            font-size: 1.2rem;
        }

        [data-theme="dark"] .badge-gold {
            color: var(--uas-gold);
        }

        /* ==========================================================================
           6. VISTA 2: MIEMBROS DEL CUERPO ACADÉMICO
           ========================================================================== */
        .member-header {
            display: flex;
            align-items: center;
            gap: 1rem;
            margin-bottom: 1rem;
        }

        .avatar-circle {
            width: 58px;
            height: 58px;
            border-radius: 50%;
            background: linear-gradient(135deg, #003366, #0284C7);
            color: #FFFFFF;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: 700;
            font-size: 1.15rem;
            border: 2px solid var(--uas-gold);
            flex-shrink: 0;
        }

        /* ==========================================================================
           7. VISTA 3: PUBLICACIONES Y FILTROS
           ========================================================================== */
        .filter-bar {
            background-color: var(--bg-surface);
            border: 1px solid var(--border-blue);
            padding: 1rem 1.25rem;
            border-radius: var(--radius);
            margin-bottom: 1.5rem;
            display: flex;
            gap: 1rem;
            flex-wrap: wrap;
            align-items: center;
        }

        .form-control,
        .form-select {
            padding: 0.55rem 0.85rem;
            border: 1px solid var(--border-color);
            border-radius: 6px;
            background-color: var(--bg-body);
            color: var(--text-main);
            font-family: var(--font-sans);
            font-size: 0.9rem;
        }

        .pub-item {
            background-color: var(--bg-surface);
            border: 1px solid var(--border-blue);
            border-left: 4px solid var(--uas-royal);
            border-radius: var(--radius);
            padding: 1.25rem 1.5rem;
            margin-bottom: 1rem;
            display: flex;
            justify-content: space-between;
            align-items: flex-start;
            gap: 1.25rem;
            flex-wrap: wrap;
        }

        /* ==========================================================================
           8. VISTA 4: PÁGINA EN BLANCO / UI KIT REUTILIZABLE
           ========================================================================== */
        .ui-block {
            margin-bottom: 2.25rem;
        }

        .ui-block-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            background-color: var(--bg-subtle);
            border: 1px solid var(--border-blue);
            padding: 0.6rem 1rem;
            border-radius: 6px 6px 0 0;
            font-size: 0.85rem;
            font-weight: 600;
            color: var(--uas-navy);
        }

        .ui-block-preview {
            background-color: var(--bg-surface);
            border: 1px solid var(--border-blue);
            border-top: none;
            padding: 1.5rem;
            border-radius: 0 0 6px 6px;
        }

        .alert-institutional {
            background-color: var(--bg-subtle);
            border-left: 4px solid var(--uas-royal);
            padding: 1rem 1.25rem;
            border-radius: 4px;
            margin-bottom: 1rem;
        }

        .table-uas {
            width: 100%;
            border-collapse: collapse;
            font-size: 0.9rem;
        }

        .table-uas th {
            background-color: #003366;
            color: #FFFFFF;
            text-align: left;
            padding: 0.75rem 1rem;
        }

        .table-uas td {
            padding: 0.75rem 1rem;
            border-bottom: 1px solid var(--border-color);
        }

        details.accordion-uas {
            border: 1px solid var(--border-blue);
            border-radius: 6px;
            margin-bottom: 0.65rem;
            background-color: var(--bg-surface);
        }

        details.accordion-uas summary {
            padding: 0.85rem 1.15rem;
            font-weight: 600;
            cursor: pointer;
            color: var(--uas-navy);
        }

        details.accordion-uas .acc-body {
            padding: 0 1.15rem 1rem;
            color: var(--text-secondary);
            font-size: 0.92rem;
        }

        /* ==========================================================================
           9. PIE DE PÁGINA INSTITUCIONAL (FOOTER.PHP)
           ========================================================================== */
        .site-footer {
            background-color: #002244;
            color: #CBD5E1;
            padding: 3rem 0 1.5rem;
            border-top: 4px solid var(--uas-gold);
            margin-top: 3rem;
        }

        .footer-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
            gap: 2rem;
            margin-bottom: 2rem;
        }

        .site-footer h4 {
            color: #FFFFFF;
            font-size: 1.05rem;
            margin-bottom: 1rem;
        }

        .footer-bottom {
            text-align: center;
            padding-top: 1.25rem;
            border-top: 1px solid rgba(255, 255, 255, 0.12);
            font-size: 0.82rem;
        }

        @media (max-width: 768px) {
            .nav-container {
                padding: 0 0.75rem;
                gap: 0.4rem;
            }

            .nav-btn {
                padding: 0.75rem 0.85rem;
                font-size: 0.84rem;
            }

            .theme-toggle {
                padding: 0.45rem 0.65rem;
            }

            .theme-toggle #themeText {
                display: none;
            }

            .hero-box {
                grid-template-columns: 1fr;
                padding: 1.5rem;
            }

            .grid-2 {
                grid-template-columns: 1fr;
            }
        }