@import url('https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;600&family=IBM+Plex+Sans:wght@300;400;500;600;700&family=Roboto:wght@400;500&display=swap');
:root {
    /* Paleta de Colores de SCI - Rediseño Corpohosting */
    --primary-color: #2c4f70;
    --secondary-color: #e97230;
    --text-color: #2b2b2b;
    --secondary-text-color: #4a4a4a;
    --light-text-color: #fcfcfc;
    --background-color: #ffffff;
    --secondary-background-color: #f7f9fb;
    --border-color: #d1d9e0;
    --focus-color: #e97230;

    /* Footer Colors */
    --dark-footer-bg: #213d58;
    --footer-text-color: #fcfcfc;
    --footer-secondary-text: #c2d1df;

    /* Tipografía */
    --font-family-base: 'IBM Plex Sans', sans-serif;
    --standard-padding: 100px 0;
    --container-width: 99%;
    /* Ancho del contenido dentro del box */
    --header-height: 80px;
    --standard-spacing: 2rem;
    --font-weight-regular: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
}

/*
@media (prefers-color-scheme: dark) {
    :root {
        --text-color: #f4f4f4;
        --secondary-text-color: #a8a8a8;
        --background-color: #121212;
        --secondary-background-color: #1a1a1a;
        --border-color: #333333;
        --light-text-color: #ffffff;
    }
}
*/
/* ==================== Reset Básico y Estilos Globales ==================== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    /* Base para REMs */
}

body {
    font-family: var(--font-family-base);
    font-weight: var(--font-weight-regular);
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    /* <-- AÑADE ESTA LÍNEA */
}

.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 40px;
    /* Padding generoso */
}

@media (max-width: 1024px) {
    .container {
        max-width: 100%;
        padding: 0 20px;
    }
}

h1,
h2,
h3 {
    color: var(--primary-color);
    font-weight: var(--font-weight-semibold);
    /* Más definición */
    margin-bottom: var(--standard-spacing);
    line-height: 1.3;
}

h1 {
    font-size: 3rem;
    font-weight: var(--font-weight-bold);
}

/* Más grande y bold */
h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
}

h3 {
    font-size: 1.5rem;
    color: var(--text-color);
    font-weight: var(--font-weight-medium);
}

/* H3 en color texto */

p {
    margin-bottom: var(--standard-spacing);
    color: var(--secondary-text-color);
    font-size: 1.1rem;
    /* Párrafos más legibles */
    max-width: 65ch;
    /* Mejor legibilidad de línea */
}

section p {
    /* Párrafos dentro de secciones no necesariamente limitados */
    max-width: none;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--secondary-color);
}

a:focus {
    outline: 2px solid var(--focus-color);
    outline-offset: 2px;
}

/* Accesibilidad */

img {
    display: block;
    max-width: 100%;
    height: auto;
}

ul {
    list-style: none;
}

/* ==================== Cabecera (Estilo IBM - Revisado) ==================== */
.site-header {
    /* CAMBIO: Fondo gris claro para diferenciar */
    background-color: var(--secondary-background-color);
    height: var(--header-height);
    /* CAMBIO: Borde inferior un poco más sutil */
    border-bottom: 1px solid #e0e0e0;
    /* Usando var(--border-color) si prefieres */
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    position: relative;
    gap: 30px;
}

.logo a {
    font-size: 1.8rem;
    font-weight: var(--font-weight-bold);
    /* CAMBIO: Color del logo a texto principal (casi negro) */
    color: var(--text-color);
    letter-spacing: -1px;
    text-decoration: none;
    /* Asegurar que no haya subrayado */
}

/* Opcional: Hover effect para el logo si quieres */
/* .logo a:hover {
    color: var(--primary-color);
} */

.main-navigation {
    display: none;
}

/* Oculto por defecto, mostrar en desktop */
.main-navigation.active {
    display: block;
}

.main-navigation > ul {
    display: flex;
    gap: 35px;
    /* CAMBIO: Un poco más de espacio entre links */
}

.main-navigation a {
    /* Color base de links a texto secundario */
    color: var(--secondary-text-color);
    font-weight: var(--font-weight-medium);
    /* Padding para envolver el texto de forma moderna */
    padding: 6px 12px;
    border-radius: 6px;
    transition: background-color 0.2s ease, color 0.2s ease;
    font-size: 0.95rem;
}

.main-navigation a:hover {
    /* Hover con fondo suave */
    color: var(--primary-color);
    background-color: rgba(44, 79, 112, 0.05); /* Usando primary-color RGB */
}

.main-navigation a.active {
    /* Estado activo con fondo suave */
    color: var(--primary-color);
    font-weight: var(--font-weight-bold);
    background-color: rgba(44, 79, 112, 0.08);
}

/* ... otros estilos ... */

/* Botón Hamburguesa (visible en móvil) */
.menu-toggle {
    display: none;
    /* Oculto por defecto */
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-color);
}

/* Botón/Login Icon (visible en móvil) */
.login-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 0.95rem;
    cursor: pointer;
    color: var(--text-color);
    padding: 8px 0 8px 16px;
}

.login-toggle-label {
    font-weight: var(--font-weight-medium);
}

/* Utilidad para texto solo accesible (screen readers) */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

@media (max-width: 768px) {

    /* O el breakpoint que hayas definido */
    .menu-toggle {
        display: block;
        /* Mostrar en móvil */
    }

    .login-toggle {
        display: block;
    }

    .header-content {
        justify-content: space-between;
        gap: 12px;
    }

    .main-navigation {
        display: none;
        /* Menú oculto por defecto en móvil */
        position: absolute;
        top: var(--header-height);
        /* Debajo de la cabecera */
        left: 0;
        width: 100%;
        background-color: var(--secondary-background-color);
        /* O el color que prefieras */
        border-bottom: 1px solid var(--border-color);
        padding: 0;
        z-index: 999;
        /* Para que esté por encima de otro contenido */
    }

    .main-navigation.active {
        /* Cuando el menú está activo/abierto */
        display: block;
    }

    .main-navigation ul {
        flex-direction: column;
        align-items: stretch;
        border-top: 1px solid var(--border-color);
        margin: 0;
        padding: 0;
        gap: 0; /* Reset desktop gap */
    }

    .main-navigation li {
        margin: 0;
        width: 100%;
    }

    .main-navigation a {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 12px 20px;
        /* altura y padding más cercanos a IBM */
        border-bottom: 1px solid var(--border-color);
        background-color: var(--background-color);
        border-bottom-color: var(--border-color);
        border-top: none;
    }

    /* Estilo de item activo en móvil:
       fondo azul tenue, resaltar jerarquía */
    .main-navigation a.active {
        background-color: rgba(44, 79, 112, 0.08);
        color: var(--primary-color);
        font-weight: var(--font-weight-bold);
        border-bottom-color: transparent;
    }

    /* En el menú móvil no queremos el contorno azul de foco
       alrededor de cada item (solo texto y fondo sutil) */
    .main-navigation a:focus,
    .main-navigation a:focus-visible {
        outline: none;
        box-shadow: none;
    }

    /* Ocultamos completamente el ítem Login del menú en móvil
       (usamos el icono superior en su lugar) */
    .login-menu {
        display: none;
    }
}

@media (min-width: 769px) {

    /* O el breakpoint + 1px */
    .main-navigation {
        display: block !important;
        /* Asegurar que se muestre en desktop */
        position: static;
        /* Resetear posición */
        width: auto;
        background-color: transparent;
        border-bottom: none;
        padding: 0;
        margin-left: auto; /* Justifica el menú hacia la derecha */
    }

    .main-navigation ul {
        flex-direction: row;
    }

    .main-navigation li {
        margin-left: 35px;
        /* O el margen que tenías */
        margin-top: 0;
        margin-bottom: 0;
    }
}

@media (min-width: 1240px) {
    body {
        background-color: #f0f0f0;
        /* Fondo fuera del box */
    }

    .site-header,
    main,
    .site-footer {
        width: 100%;
        /* Boxed Layout al 80% del ancho de pantalla */
        max-width: 1600px;
        /* Opcional: límite para pantallas ultra-anchas */
        margin-left: auto;
        margin-right: auto;
        box-shadow: 0 0 50px rgba(0, 0, 0, 0.1);
        background-color: var(--background-color);
    }

    .site-header {
        left: 50%;
        transform: translateX(-50%);
    }
}

/* ==================== Contenido Principal ==================== */
main {
    padding-top: var(--header-height);
}

section {
    padding: var(--standard-padding);
}

/* ==================== Sección Hero (2 Columnas) ==================== */
.hero-section {
    background-color: var(--background-color);
    /* Fondo blanco */
    padding-top: 100px;
    /* Más espacio arriba */
    padding-bottom: 100px;
}

.hero-container {
    display: flex;
    align-items: center;
    gap: 50px;
    /* Espacio entre texto y visual */
}

.hero-content {
    flex: 1 1 55%;
    /* Ocupa un poco más de la mitad */
}

.hero-content h1 {
    color: var(--primary-color);
}

.hero-content p {
    color: var(--secondary-text-color);
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

.hero-visual {
    flex: 1 1 45%;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.sidebar {
    width: 100%;
}

.visual-placeholder {
    /* Estilo temporal para el visual */
    background-color: var(--secondary-background-color);
    border: 1px dashed var(--border-color);
    height: 350px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--secondary-text-color);
    font-style: italic;
    border-radius: 8px;
}

.visual-placeholder::before {
    content: 'Visual/Imagen Aquí';
}


/* ==================== Botones Reutilizables (Estilo IBM) ==================== */
.button {
    display: inline-block;
    padding: 14px 30px;
    border-radius: 8px; /* Bordes redondeados y amigables */
    font-weight: var(--font-weight-semibold);
    text-align: center;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.1s ease, box-shadow 0.2s ease;
    border: 1.5px solid transparent;
    font-size: 1rem;
}

.button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(44, 79, 112, 0.15); /* Sombra genérica */
}

.button:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(44, 79, 112, 0.1);
}

.button-primary {
    background-color: var(--primary-color);
    color: var(--light-text-color);
    border-color: var(--primary-color);
}

.button-primary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
    box-shadow: 0 6px 16px rgba(233, 114, 48, 0.3); /* Resplandor naranja */
}

.button-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 1.5px solid var(--primary-color);
}

.button-secondary:hover {
    background-color: var(--primary-color);
    color: var(--light-text-color);
    border-color: var(--primary-color);
    box-shadow: 0 6px 16px rgba(44, 79, 112, 0.2);
}

/* ==================== Sección Resumen de Servicios ==================== */
.services-overview-section {
    background-color: var(--secondary-background-color);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
    /* Más espacio */
    margin-top: 3rem;
}

.service-box {
    background-color: var(--background-color);
    padding: 40px;
    border: 1px solid var(--border-color);
    border-radius: 12px; /* Redondeo tipo carta */
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03); /* Sombra base suave */
}

.service-box:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(44, 79, 112, 0.08); /* Sombra estilo blue hue */
    border-color: rgba(44, 79, 112, 0.15);
}

.service-icon {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

.service-icon svg {
    width: 48px;
    height: 48px;
}

/* Tamaño de iconos SVG */

.service-box h3 {
    margin-bottom: 1rem;
    font-size: 1.3rem;
    /* Ajuste tamaño H3 */
    /*text-align: left;*/
}

.service-box p {
    font-size: 1rem;
    /* Ajuste tamaño P */
    color: var(--secondary-text-color);
    margin-bottom: auto;
    /* Empuja el enlace hacia abajo */
    padding-bottom: 1.5rem;
    /* Espacio antes del enlace */
    /*text-align: justify;*/
}

.learn-more {
    font-weight: var(--font-weight-semibold);
    color: var(--primary-color);
    display: inline-block;
    /* Para que no ocupe toda la línea */
    margin-top: auto;
    /* Asegura que esté al final */
}

.learn-more:hover {
    color: var(--secondary-color);
}

/* ==================== Sección Confianza / Partner ==================== */
.trust-section {
    text-align: center;
    padding: 60px 0;
    /* Menos padding vertical que otras secciones */
}

.trust-section p {
    max-width: 750px;
    margin: 0 auto var(--standard-spacing) auto;
    font-size: 1.1rem;
    color: var(--secondary-text-color);
}

.partner-logos {
    margin-top: 2rem;
    display: flex;
    justify-content: center;
    gap: 40px;
    align-items: center;
}

.partner-logo {
    max-height: 50px;
    /* Ajustar según logos */
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.partner-logo:hover {
    opacity: 1;
}

/* ==================== Sección CTA Secundaria ==================== */
.secondary-cta-section {
    background-color: var(--primary-color);
    color: var(--light-text-color);
    text-align: center;
    padding: var(--standard-padding);
}

.secondary-cta-section h2 {
    color: var(--light-text-color);
}

.secondary-cta-section p {
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin: 0 auto 2rem auto;
}

/* Hereda estilo de button-secondary, pero invertido para fondo oscuro */
.secondary-cta-section .button-secondary {
    background-color: transparent;
    color: var(--light-text-color);
    border-color: var(--light-text-color);
}

.secondary-cta-section .button-secondary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
    color: var(--light-text-color);
}

/* ==================== Pie de Página ==================== */
.site-footer {
    color: var(--secondary-text-color);
    text-align: center;
    font-size: 0.9rem;
}

.site-footer p {
    margin-bottom: 0.5rem;
    color: var(--secondary-text-color);
}

.footer-nav {
    margin-top: 1rem;
}

.footer-nav ul {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.footer-nav a {
    color: var(--secondary-text-color);
    font-weight: var(--font-weight-medium);
}

.footer-nav a:hover {
    color: var(--primary-color);
}

/* ==================== Media Queries (Responsividad Mejorada) ==================== */
@media (min-width: 769px) {

    /* Estilos para Desktop */
    .menu-toggle {
        display: none;
    }

    /* Ocultar botón hamburguesa */
    .main-navigation {
        display: block;
    }

    /* Mostrar navegación normal */
}

@media (max-width: 768px) {
    h1 {
        font-size: 2.4rem;
    }

    h2 {
        font-size: 2rem;
    }

    section {
        padding: 60px 0;
    }

    .hero-container {
        flex-direction: column;
        /* Apilar texto y visual */
        text-align: center;
    }

    .hero-content {
        order: 2;
    }

    /* Texto debajo del visual */
    .hero-visual {
        order: 1;
        margin-bottom: 2rem;
    }

    .visual-placeholder {
        height: 250px;
    }

    .hero-content p {
        margin-left: auto;
        margin-right: auto;
    }

    /* Centrar párrafo */

    .services-grid {
        grid-template-columns: 1fr;
    }

    /* Estilos básicos para menú móvil (requiere JS) */
    .main-navigation {
        display: none;
        /* Oculto hasta que JS lo muestre */
        position: absolute;
        top: var(--header-height);
        left: 0;
        width: 100%;
        background-color: var(--background-color);
        border-bottom: 1px solid var(--border-color);
        padding: 20px 0;
    }

    .main-navigation.active {
        display: block;
    }

    .main-navigation ul {
        flex-direction: column;
        align-items: center;
    }

    .main-navigation li {
        margin: 0;
    }
}

/* ==================== Pie de Página (Estilo IBM - Fondo Oscuro) ==================== */
:root {
    /* ... (tus otras variables) ... */
    --dark-footer-bg: #262626;
    /* Nuevo: Gris oscuro para fondo footer */
    --footer-text-color: #f4f4f4;
    /* Nuevo: Texto claro principal para footer */
    --footer-link-hover: #ffffff;
    /* Nuevo: Blanco para hover de links en footer */
    --footer-secondary-text: #c6c6c6;
    /* Nuevo: Gris claro para texto secundario/copyright */
    --footer-border-color: #393939;
    /* Nuevo: Borde sutil para el fondo oscuro */
}


/* ===================================================================
 * 4. FOOTER (CORREGIDO Y ALINEADO A LA IZQUIERDA)
 * ===================================================================
 */

.site-footer {
    color: var(--footer-secondary-text);
    font-size: 0.95rem;
}

.footer-main {
    margin-bottom: 40px;
}

.footer-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
}

/* ESTA ES LA REGLA NUEVA/MODIFICADA */
.footer-column {
    text-align: left;
    /* 1. Alinear todo el contenido de la columna a la izquierda */
}

/* Esta regla ya no es necesaria si usas <p class="footer-column-title">
.footer-column h4 {
    ...
}
*/

/* ESTA ES LA REGLA A MODIFICAR */
.footer-column-title {
    font-size: 1rem;
    font-weight: var(--font-weight-semibold);
    color: var(--footer-link-hover);
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 0.9;
}

.footer-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-column li {
    margin-bottom: 0.8rem;
}

.footer-column a {
    color: var(--footer-secondary-text);
    font-weight: var(--font-weight-regular);
    transition: color 0.2s ease;
}

.footer-column a:hover {
    color: var(--footer-link-hover);
    text-decoration: underline;
}

/* --- Barra Inferior del Footer --- */
.footer-bottom {
    border-top: 1px solid var(--footer-border-color);
    padding-top: 30px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.footer-bottom-nav ul {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-bottom-nav a {
    color: var(--footer-secondary-text);
    font-size: 0.9rem;
    font-weight: var(--font-weight-medium);
}

.footer-bottom-nav a:hover {
    color: var(--footer-link-hover);
}

.footer-copyright {
    font-size: 0.85rem;
    color: var(--footer-secondary-text);
    text-align: right;
    margin: 0;
    flex-grow: 1;
}

/* --- Responsividad del Footer --- */
@media (max-width: 768px) {
    .footer-columns {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        gap: 30px;
    }

    .footer-bottom {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .footer-bottom-nav {
        order: 2;
        margin-top: 15px;
    }

    .footer-bottom-nav ul {
        justify-content: center;
        gap: 20px;
    }

    .footer-copyright {
        order: 1;
        text-align: center;
        width: 100%;
    }
}

/* Mantenemos el centrado para pantallas muy pequeñas, ya que se ve mejor */
@media (max-width: 480px) {
    .footer-columns {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .footer-column {
        text-align: center;
        /* Aquí sí centramos */
    }

    .footer-column ul {
        margin-top: 1rem;
    }
}

/* ==================== Estilos Páginas Internas (Revisado) ==================== */

/* --- Hero de Página Interna --- */
.page-hero-section {
    padding: 60px 0;
    /* Menos padding que el hero principal */
    /* background-color: var(--secondary-background-color); */
    /* Fondo claro opcional */
}

.breadcrumb {
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.breadcrumb ol {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 0.5rem;
    color: var(--secondary-text-color);
}

.breadcrumb li:not(:last-child)::after {
    content: '/';
    margin-left: 0.5rem;
    color: #c6c6c6;
}

.breadcrumb a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb li[aria-current="page"] {
    font-weight: var(--font-weight-medium);
    color: var(--text-color);
}

.hero-layout-split {
    /* Layout para Hero de 2 columnas */
    display: flex;
    align-items: center;
    gap: 50px;
}

.hero-layout-split .hero-content {
    flex: 1 1 55%;
}

/* Reset margin si viene de breadcrumb */



/* --- Secciones de Contenido con Layout Grid --- */
.content-section {
    padding: var(--standard-padding);
}

.content-section h2 {
    text-align: left;
    /* Alinear H2 a la izquierda */
    margin-bottom: 2.5rem;
}

.content-layout-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* Dos columnas iguales */
    gap: 60px;
    /* Espacio entre columnas */
    align-items: center;
    /* Alinear verticalmente */
}



.content-layout-grid.reverse .visual-content {
    order: 1;
}

.content-layout-grid.reverse .text-content {
    order: 2;
}


.text-content h3,
.text-content h4 {
    /* Estilo para subtítulos dentro del texto */
    color: var(--text-color);
    font-weight: var(--font-weight-semibold);
    margin-top: 1.5rem;
    /* Espacio antes de subtítulos */
    margin-bottom: 1rem;
}

/* --- Listas de Características --- */
.feature-list {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.feature-list li {
    margin-bottom: 0.7rem;
    padding-left: 2rem;
    /* Más espacio para icono */
    position: relative;
    font-size: 1rem;
    color: var(--secondary-text-color);
}

.feature-list li::before {
    content: '';
    /* Vacío por defecto, usar background-image */
    display: inline-block;
    width: 16px;
    height: 16px;
    background-color: var(--primary-color);
    /* Color del icono */
    -webkit-mask-image: url('data:image/svg+xml,%3Csvg xmlns="http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg" viewBox="0 0 24 24" fill="%23ffffff"%3E%3Cpath d="M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41L9 16.17z"%2F%3E%3C%2Fsvg%3E');
    /* Check SVG como máscara */
    mask-image: url('data:image/svg+xml,%3Csvg xmlns="http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg" viewBox="0 0 24 24" fill="%23ffffff"%3E%3Cpath d="M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41L9 16.17z"%2F%3E%3C%2Fsvg%3E');
    background-size: contain;
    background-repeat: no-repeat;
    position: absolute;
    left: 0;
    top: 4px;
    /* Ajustar verticalmente */
}

/* --- Sección de Beneficios "¿Por Qué?" (Estilo Condensado) --- */
.why-section {
    padding: var(--standard-padding);
}

.why-section h2 {
    text-align: center;
    margin-bottom: 3rem;
}

.benefits-grid-condensed {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    /* Columnas más pequeñas */
    gap: 30px;
}

.benefit-item {
    text-align: center;
    /* Centrar contenido */
    /* Quitar borde/fondo si se prefiere más simple */
    background: none;
    border: none;
    padding: 15px;
}

.benefit-icon {
    font-size: 2.5rem;
    /* Icono/Emoji más grande */
    margin-bottom: 1rem;
    line-height: 1;
}

.benefit-item h4 {
    /* Título del beneficio */
    font-size: 1.1rem;
    font-weight: var(--font-weight-semibold);
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.benefit-item p {
    font-size: 0.95rem;
    color: var(--secondary-text-color);
    line-height: 1.5;
}

/* --- Responsividad para Layouts de Contenido --- */
@media (max-width: 992px) {

    /* Tablets y móviles grandes */
    .content-layout-grid {
        grid-template-columns: 1fr;
        /* Apilar columnas */
        gap: 40px;
    }

    .content-layout-grid.reverse .visual-content {
        order: 1;
    }

    /* Visual siempre primero al apilar */
    .content-layout-grid.reverse .text-content {
        order: 2;
    }

    .text-content,
    .visual-content {
        text-align: center;
    }

    /* Centrar contenido al apilar */
    .text-content .button {
        margin-left: auto;
        margin-right: auto;
        display: table;
    }

    /* Centrar botón */
    .feature-list {
        text-align: left;
        display: inline-block;
    }

    /* Alinear lista a la izq pero centrar bloque */
}

@media (max-width: 768px) {
    .hero-layout-split {
        flex-direction: column;
    }

    /* Apilar hero */
    .hero-layout-split .hero-visual {
        margin-top: 2rem;
    }

    .why-section h2 {
        font-size: 2rem;
    }

    .benefits-grid-condensed {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }

    /* Ajustar en móvil */
}

/* ==================== Estilos Página Servicios A2 ==================== */

/* --- Sección Soluciones A2 --- */
.a2-solutions-section {
    padding: var(--standard-padding);
}

.a2-solutions-section h2 {
    text-align: center;
    /* Centrar título principal */
    margin-bottom: 1rem;
}

.a2-solutions-section>.container>p {
    /* Estilo para el párrafo introductorio */
    text-align: center;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 3rem;
    color: var(--secondary-text-color);
    font-size: 1.1rem;
}

.solutions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    /* 2 o 3 columnas */
    gap: 30px;
}

.solution-box {
    background-color: var(--background-color);
    padding: 30px;
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    text-align: center;
    /* Centrar contenido de la caja */
    transition: box-shadow 0.3s ease;
}

.solution-box:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.solution-icon {
    font-size: 2.5rem;
    /* Tamaño icono/emoji */
    margin-bottom: 1rem;
    line-height: 1;
    color: var(--primary-color);
    /* Opcional: color para icono */
}

.solution-box h3 {
    font-size: 1.2rem;
    font-weight: var(--font-weight-semibold);
    color: var(--text-color);
    margin-bottom: 0.8rem;
}

.solution-box p {
    font-size: 0.95rem;
    color: var(--secondary-text-color);
    margin-bottom: auto;
    /* Empuja el enlace abajo */
    padding-bottom: 1.5rem;
    flex-grow: 1;
    /* Asegura que el párrafo ocupe espacio */
}

/* ==================== Animaciones Premium ==================== */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.fade-in-up.appear {
    opacity: 1;
    transform: translateY(0);
}

/* ==================== Back to Top Button ==================== */
#back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    z-index: 9999;
}

#back-to-top.show {
    opacity: 1;
    visibility: visible;
}

#back-to-top:hover {
    background-color: var(--secondary-color);
    transform: translateY(-5px);
}

/* ==================== Skeleton Loading ==================== */
.skeleton-item {
    height: 1.2rem;
    background: linear-gradient(90deg, var(--border-color) 25%, var(--secondary-background-color) 50%, var(--border-color) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite linear;
    margin-bottom: 10px;
    border-radius: 4px;
}

@keyframes skeleton-loading {
    from {
        background-position: 200% 0;
    }

    to {
        background-position: -200% 0;
    }
}

/* ==================== Dark Mode Overrides (General) ==================== */
/*
[data-theme="dark"] .service-box,
@media (prefers-color-scheme: dark) {
    .service-box {
        background-color: #1a1a1a;
        border-color: #333;
    }

    .secondary-background-color {
        background-color: #000;
    }
}
*/


/* --- Sección Cumplimiento SNAT --- */
.snat-section {
    padding: 60px 0;
    /* Padding específico */
}

/* Hereda estilo de .button-secondary pero necesita ajustes para fondo oscuro */
.snat-section .button-secondary {
    background-color: transparent;
    color: var(--light-text-color);
    border-color: var(--light-text-color);
}

.snat-section .button-secondary:hover {
    background-color: var(--light-text-color);
    color: var(--primary-color);
}

/* Ajustes responsivos específicos si son necesarios para A2 */
@media (max-width: 768px) {
    .a2-solutions-section>.container>p {
        font-size: 1rem;
    }

    .solutions-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

/* ==================== Estilos Página Conectividad ==================== */

/* --- Estilos para cajas de texto en sección "Para Quién" --- */
.text-content-box {
    background-color: var(--background-color);
    /* Fondo blanco si la sección es gris */
    padding: 30px;
    border: 1px solid var(--border-color);
    /* Podría añadir un icono arriba si se desea */
}

.box-icon {
    /* Estilo para el icono dentro de la caja */
    font-size: 2rem;
    margin-bottom: 1rem;
    line-height: 1;
    color: var(--primary-color);
    /* text-align: center; si se prefiere centrado */
}

.text-content-box h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.text-content-box p {
    font-size: 1rem;
    margin-bottom: 1.5rem;
}

.feature-list.simple li {
    /* Estilo alternativo para listas más simples */
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.feature-list.simple li::before {
    width: 14px;
    /* Icono check un poco más pequeño */
    height: 14px;
    top: 3px;
}

.text-content-box .learn-more {
    margin-top: 1.5rem;
    display: inline-block;
}


/* Ajustes responsivos específicos para Conectividad si son necesarios */
@media (max-width: 768px) {

    /* La grid .content-layout-grid ya se apila a 1 columna */
    .text-content-box {
        margin-bottom: 20px;
        /* Espacio extra entre cajas si se apilan */
    }

    .text-content-box:last-child {
        margin-bottom: 0;
    }
}

/* ==================== Estilos Página de Contacto ==================== */

/* --- Layout General Contacto --- */
.contact-layout-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    /* Columna de info un poco más pequeña */
    gap: 60px;
    /* Espacio entre columnas */
    align-items: flex-start;
    /* Alinear al inicio */
}

/* --- Columna Información de Contacto --- */
.contact-info h3 {
    font-size: 1.5rem;
    color: var(--text-color);
    margin-bottom: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.8rem;
    gap: 15px;
}

.contact-icon {
    font-size: 1.5rem;
    /* Tamaño del icono/emoji */
    color: var(--primary-color);
    margin-top: 2px;
    /* Ajuste vertical ligero */
    flex-shrink: 0;
    /* Evita que el icono se encoja */
}

.contact-item div {
    line-height: 1.7;
}

.contact-item strong {
    font-weight: var(--font-weight-semibold);
    color: var(--text-color);
}

.contact-item a {
    color: var(--primary-color);
    word-break: break-word;
    /* Evitar desbordamiento de emails/links largos */
}

.contact-item a:hover {
    text-decoration: underline;
}

/* --- Mapa Opcional --- */
.map-container {
    margin-top: 2.5rem;
    border: 1px solid var(--border-color);
}

.map-container h4 {
    font-size: 1.1rem;
    padding: 15px;
    margin: 0;
    background-color: var(--secondary-background-color);
    border-bottom: 1px solid var(--border-color);
    color: var(--text-color);
}

.map-container iframe {
    display: block;
    /* Evita espacio extra debajo del iframe */
}


/* --- Columna Formulario de Contacto --- */
.contact-form-container h3 {
    font-size: 1.5rem;
    color: var(--text-color);
    margin-bottom: 1rem;
    /* Menos espacio si hay un párrafo debajo */
}

.contact-form-container p {
    margin-bottom: 2rem;
    font-size: 1rem;
}

.contact-form .form-group {
    margin-bottom: 1.5rem;
}

.contact-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: var(--font-weight-medium);
    font-size: 0.9rem;
    color: var(--text-color);
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"],
.contact-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    background-color: var(--background-color);
    /* Fondo blanco */
    font-family: var(--font-family-base);
    font-size: 1rem;
    line-height: 1.5;
    color: var(--text-color);
    transition: border-color 0.2s ease;
    border-radius: 0;
    /* Sin bordes redondeados */
    appearance: none;
    /* Quitar estilos por defecto del navegador */
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 1px var(--primary-color);
    /* Efecto de foco sutil */
}

.contact-form textarea {
    resize: vertical;
    /* Permitir redimensionar solo verticalmente */
    min-height: 120px;
}

.contact-form .required {
    color: #d72c16;
    /* Rojo para asterisco */
    font-weight: bold;
    margin-left: 2px;
}

.contact-form .form-submit {
    margin-top: 2rem;
}

.contact-form .form-notice {
    margin-top: 1rem;
    font-size: 0.85rem;
    color: var(--secondary-text-color);
}

.contact-form .form-notice .required {
    font-weight: normal;
}

/* Estilo para mensajes de estado (éxito/error) */
#form-status {
    margin-top: 1.5rem;
    padding: 15px;
    border-radius: 4px;
    display: none;
    /* Oculto por defecto */
    font-weight: var(--font-weight-medium);
}

#form-status.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    display: block;
}

#form-status.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    display: block;
}


/* --- Responsividad para Contacto --- */
@media (max-width: 992px) {

    /* Tablets */
    .contact-layout-grid {
        grid-template-columns: 1fr;
        /* Apilar columnas */
        gap: 50px;
    }

    .contact-info {
        order: 2;
    }

    /* Formulario primero en móvil */
    .contact-form-container {
        order: 1;
    }
}

@media (max-width: 768px) {
    /* Ajustar paddings o tamaños si es necesario */
}

/* ==================== Estilos Página de Clientes ==================== */

/* --- Sección Logos Clientes --- */
.client-logos-section {
    padding: var(--standard-padding);
    background-color: var(--background-color);
    /* Fondo blanco */
}

.logos-grid {
    display: grid;
    /* Ajusta minmax para controlar tamaño y número de logos por fila */
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 40px;
    /* Espacio entre logos */
    align-items: center;
    /* Centrar verticalmente */
    justify-items: center;
    /* Centrar horizontalmente */
}

.logo-item {
    /* max-width: 160px; */
    /* Limitar ancho máximo si es necesario */
    filter: grayscale(100%);
    /* Logos en escala de grises */
    opacity: 0.7;
    transition: filter 0.3s ease, opacity 0.3s ease;
}

.logo-item:hover {
    filter: grayscale(0%);
    /* Color al pasar el mouse */
    opacity: 1;
}

.logo-item img {
    max-height: 60px;
    /* Limitar altura máxima */
    width: auto;
    /* Ancho automático para mantener proporción */
}

/* --- Sección Casos de Éxito --- */
.case-study-item {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* Layout 2 columnas por defecto */
    gap: 50px;
    align-items: center;
    margin-bottom: 4rem;
    /* Espacio entre casos de éxito */
    padding-bottom: 4rem;
    border-bottom: 1px solid var(--border-color);
}

.case-study-item:last-of-type {
    /* Quitar borde inferior al último */
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.case-study-item.reverse .case-study-visual {
    order: 1;
}

.case-study-item.reverse .case-study-content {
    order: 2;
}

.case-study-content h3 {
    font-size: 1.6rem;
    color: var(--text-color);
    margin-bottom: 1rem;
}

.case-study-content p {
    font-size: 1rem;
    color: var(--secondary-text-color);
    margin-bottom: 1rem;
}

.case-study-content strong {
    font-weight: var(--font-weight-semibold);
    color: var(--text-color);
}

.case-study-tags {
    display: block;
    margin-top: 1.5rem;
    font-size: 0.85rem;
    color: var(--primary-color);
    font-weight: var(--font-weight-medium);
}

.case-study-visual .visual-placeholder {
    /* Hereda estilo si usas placeholder */
    /* Ajusta altura o estilo específico si es necesario */
    height: 300px;
}

/* --- Testimonios --- */
.testimonial-item {
    background-color: var(--background-color);
    /* Fondo blanco si la sección es gris */
    padding: 30px 40px;
    margin-top: 3rem;
    /* Espacio arriba */
    border-left: 4px solid var(--primary-color);
    /* Borde izquierdo distintivo */
    text-align: center;
}

.testimonial-item blockquote {
    font-size: 1.2rem;
    font-style: italic;
    color: var(--secondary-text-color);
    margin: 0 0 1rem 0;
    border: none;
    padding: 0;
}

.testimonial-item cite {
    font-style: normal;
    font-weight: var(--font-weight-semibold);
    color: var(--text-color);
}

/* --- Responsividad Clientes --- */
@media (max-width: 992px) {
    .logos-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 30px;
    }

    .case-study-item {
        grid-template-columns: 1fr;
        /* Apilar columnas */
        gap: 30px;
        padding-bottom: 3rem;
        margin-bottom: 3rem;
    }

    .case-study-item.reverse .case-study-visual {
        order: 1;
    }

    .case-study-item.reverse .case-study-content {
        order: 2;
    }

    .case-study-visual {
        margin-bottom: 1rem;
    }
}

@media (max-width: 768px) {
    .logos-grid {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    }
}

/* ==================== Estilos Páginas Legales y FAQ ==================== */

.legal-content-section,
.faq-content-section {
    padding: var(--standard-padding);
}

/* Estilo común para páginas legales */
.legal-content-section .container {
    max-width: 800px;
    /* Limitar ancho para mejor legibilidad */
}

.legal-content-section h1 {
    text-align: center;
    margin-bottom: 1rem;
}

.last-updated {
    text-align: center;
    color: var(--secondary-text-color);
    margin-bottom: 3rem;
    font-size: 0.9rem;
}

.legal-content-section article h2 {
    font-size: 1.6rem;
    color: var(--text-color);
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    /* Separador sutil */
}

.legal-content-section article h2:first-of-type {
    margin-top: 0;
    /* Sin margen superior para el primer H2 */
}

.legal-content-section article p {
    margin-bottom: 1.2rem;
    line-height: 1.7;
    font-size: 1rem;
}

.legal-content-section article ul {
    list-style: disc;
    /* Estilo de lista estándar */
    margin-left: 25px;
    margin-bottom: 1.2rem;
}

.legal-content-section article li {
    margin-bottom: 0.5rem;
    line-height: 1.7;
}

/* --- Estilos para FAQ --- */
.faq-category-title {
    font-size: 1.8rem;
    color: var(--text-color);
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    text-align: center;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.8rem;
    display: inline-block;
    /* Para que el borde no ocupe todo */
}

/* Centrar el título h2 */
.faq-content-section .container>h2 {
    display: table;
    margin-left: auto;
    margin-right: auto;
}

.faq-category-title:first-of-type {
    margin-top: 0;
}

.faq-list {
    max-width: 900px;
    /* Limitar ancho de la lista de FAQs */
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 3rem;
}

.faq-item {
    border: 1px solid var(--border-color);
    margin-bottom: 1rem;
    border-radius: 4px;
    /* Bordes redondeados suaves */
    background-color: var(--background-color);
}

.faq-item[open] {
    /* Estilo cuando está abierto */
    background-color: #f9f9f9;
}

.faq-question {
    /* El <summary> */
    padding: 18px 25px;
    font-size: 1.1rem;
    font-weight: var(--font-weight-medium);
    color: var(--text-color);
    cursor: pointer;
    list-style: none;
    /* Ocultar marcador por defecto */
    position: relative;
    /* Para posicionar pseudo-elemento */
    transition: background-color 0.2s ease;
}

.faq-question:hover {
    background-color: var(--secondary-background-color);
}

.faq-question::-webkit-details-marker {
    display: none;
}

/* Ocultar marcador en Webkit */

/* Añadir un icono +/- (opcional) */
.faq-question::after {
    content: '+';
    position: absolute;
    right: 25px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
    color: var(--primary-color);
    transition: transform 0.2s ease;
}

.faq-item[open]>.faq-question::after {
    content: '−';
    transform: translateY(-50%);
}

.faq-answer {
    padding: 0px 25px 20px 25px;
    /* Padding para la respuesta */
    line-height: 1.7;
    font-size: 1rem;
    color: var(--secondary-text-color);
    border-top: 1px dashed var(--border-color);
    /* Separador sutil */
    margin-top: 10px;
    /* Espacio entre pregunta y respuesta */
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

.faq-footer {
    text-align: center;
    margin-top: 3rem;
    padding: 30px;
    background-color: var(--secondary-background-color);
    border-radius: 4px;
}

.faq-footer p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

/* --- Responsividad Legales/FAQ --- */
@media (max-width: 768px) {

    .legal-content-section .container,
    .faq-list {
        max-width: 100%;
        /* Usar ancho completo en móvil */
    }

    .faq-question {
        padding-right: 50px;
        /* Más espacio para icono en móvil */
    }

    .faq-question::after {
        right: 20px;
    }
}

/* Ajustes para secciones dentro de .main-content */
.main-content>section {
    /* Usar '>' para seleccionar solo hijos directos */
    padding: 0;
    margin-bottom: var(--standard-padding);
    /* Añadir esto para asegurar que no se desborden */
    max-width: 100%;
    overflow: hidden;
    /* Prevenir desbordamientos inesperados */
}

.main-content>section:last-child {
    margin-bottom: 0;
}

/* Mantener la regla para contenedores anidados (por si acaso) */
.main-content .container {
    max-width: none;
    padding: 0;
    margin: 0;
}

/* Asegurar que los H2 dentro de las secciones no causen problemas */


/* Asegurar que los grids internos se comporten */
.main-content .services-grid,
.main-content .benefits-grid-condensed,
.main-content .partner-logos {
    /* Podrían necesitar max-width: 100% si están dentro de otro elemento */
    box-sizing: border-box;
    /* Buena práctica */
}

/* Asegurar que el hero interno no se desborde */
.main-content .hero-container {
    max-width: 100%;
    box-sizing: border-box;
}

/* ==================== Mega Menú (Diseño Premium Moderno) ==================== */

.menu-item-has-children {
    position: static;
}

/* El panel emergente flotante */
.mega-menu-panel {
    position: absolute;
    top: var(--header-height);
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    width: 900px;
    max-width: 95vw;
    background-color: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(12, 24, 36, 0.15); /* Sombra elegante */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
    z-index: 999;
}

html.dark-mode .mega-menu-panel {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.menu-item-has-children.mega-menu-open > .mega-menu-panel {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Red de categorías 3x3 */
.modern-mega-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    padding: 30px;
}

.modern-menu-category {
    display: flex;
    flex-direction: column;
}

.category-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    text-decoration: none;
    margin-bottom: 12px;
}

.category-header .category-icon {
    font-size: 1.8rem;
    line-height: 1;
}

.category-header div h4 {
    margin: 0 0 4px 0;
    font-size: 1.05rem;
    color: var(--text-color);
    transition: color 0.2s;
}

.category-header:hover div h4 {
    color: var(--primary-color);
}

.category-header div p {
    margin: 0;
    font-size: 0.8rem;
    color: var(--secondary-text-color);
    line-height: 1.2;
}

.mega-menu-panel .category-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
    padding-left: 42px; /* Alinear con el texto, saltando el icono */
}

.mega-menu-panel .category-links li {
    display: block !important;
    width: 100%;
    margin: 0;
    padding: 0;
}

.category-links li a {
    text-decoration: none;
    color: var(--secondary-text-color);
    font-size: 0.9rem;
    transition: color 0.2s;
    /* Evitar conflictos con reglas globales */
    border: none;
    padding: 0;
    background: transparent;
}

.category-links li a:hover {
    color: var(--primary-color);
    background: transparent;
}

/* Responsividad general del layout flotante */
@media (max-width: 992px) {
    .modern-mega-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .mega-menu-panel {
        display: none !important;
    }
}

/* ==================== Soporte Móvil para Submenú (ESTILO IBM DRILL-DOWN) ==================== */

/* Ocultar submenú móvil por defecto */
.menu-item-has-children .sub-menu {
    display: none;
}

@media (max-width: 768px) {
    .main-navigation {
        overflow-x: hidden;
        /* Para el efecto de deslizamiento */
        background-color: var(--background-color) !important;
    }

    /* Contenedor principal del menú */
    .main-navigation ul {
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
        gap: 0 !important; /* Ensure gap is removed */
    }

    /* Estilo Base de los enlaces (IBM Style) */
    .main-navigation a {
        font-size: 1rem !important;
        padding: 16px 20px !important;
        border-bottom: 1px solid #efefef !important;
        color: #161616 !important;
        background-color: #fff !important;
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
    }

    /* Flecha Chevron estilo IBM */
    .menu-item-has-children>a::after {
        content: '';
        display: inline-block;
        width: 8px;
        height: 8px;
        border-right: 2px solid #525252;
        border-bottom: 2px solid #525252;
        transform: rotate(-45deg);
        margin-left: 10px;
        transition: transform 0.3s ease;
    }

    /* Cuando el submenú está abierto, el padre se oculta o cambia */
    .menu-item-has-children.submenu-open>a {
        display: none;
        /* En IBM el padre desaparece para mostrar el sub-menu */
    }

    /* Estilo del Sub-menú como NIVEL NUEVO */
    .sub-menu {
        display: none;
        list-style: none;
        padding: 0;
        margin: 0;
        width: 100%;
        background-color: #fff;
    }

    .menu-item-has-children.submenu-open>.sub-menu {
        display: block;
        max-height: none !important;
        opacity: 1 !important;
    }

    /* Botón VOLVER (IBM Style) */
    .mobile-back {
        background-color: #f4f4f4 !important;
    }

    .mobile-back a {
        color: #0f62fe !important;
        /* Azul IBM */
        font-weight: 600 !important;
        border-bottom: 1px solid var(--border-color) !important;
        justify-content: flex-start !important;
        background-color: #f4f4f4 !important;
    }

    /* Ocultar otros hermanos SOLO cuando uno está abierto (Efecto Drill-down) */
    .main-navigation.active:has(.submenu-open)>ul>li:not(.submenu-open) {
        display: none;
    }

    .menu-item-has-children.submenu-open {
        width: 100%;
    }

    /* Ajuste para los links dentro del sub-menu */
    .sub-menu li a {
        padding-left: 30px !important;
        /* Un poco de indentación pero limpia */
        border-bottom: 1px solid #efefef !important;
    }
}

/* --- Estilos específicos para la vista ESCRITORIO (RETEQUE) --- */
@media (min-width: 769px) {
    .mobile-back {
        display: none !important;
    }

    /* Estilo del botón "Login" en el menú principal */
    .login-main-link {
        border: 1.5px solid var(--primary-color) !important;
        padding: 8px 20px !important;
        border-radius: 4px;
        margin-left: 15px;
        color: var(--primary-color) !important;
        transition: all 0.3s ease !important;
        font-weight: 600 !important;
    }

    .login-main-link:hover {
        background-color: var(--primary-color);
        color: #fff !important;
    }

    .login-menu {
        position: relative;
    }

    /* El panel desplegable rediseñado - Ahora activado por click (.is-open) */
    .login-menu.is-open>.sub-menu.login-desktop-panel {
        display: block !important;
        position: absolute;
        right: 0;
        top: calc(100% + 10px);
        background: #ffffff;
        border: 1px solid var(--border-color);
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.12);
        min-width: 320px;
        z-index: 2100;
        padding: 20px 0 0 0;
        border-radius: 8px;
        animation: slideDown 0.3s ease-out;
    }

    .login-panel-header {
        padding: 0 24px 15px 24px;
        font-size: 0.75rem;
        font-weight: 700;
        color: var(--secondary-text-color);
        text-transform: uppercase;
        letter-spacing: 1px;
        border-bottom: 1px solid #f0f0f0;
        margin-bottom: 5px;
    }

    .login-item a {
        display: flex !important;
        align-items: flex-start !important;
        padding: 16px 24px !important;
        border-bottom: none !important;
        background: transparent !important;
        transition: background 0.2s ease;
    }

    .login-item a:hover {
        background-color: #f8faff !important;
    }

    .login-item-icon {
        background: #eef4ff;
        color: var(--primary-color);
        width: 40px;
        height: 40px;
        border-radius: 6px;
        display: flex;
        align-items: center;
        justify-content: center;
        margin-right: 16px;
        flex-shrink: 0;
    }

    .login-item-content {
        display: flex;
        flex-direction: column;
    }

    .login-item-content strong {
        color: #161616;
        font-size: 0.95rem;
        margin-bottom: 2px;
    }

    .login-item-content span {
        color: #525252;
        font-size: 0.8rem;
        line-height: 1.4;
    }

    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}

/* ==================== News Feed Widget ==================== */
.news-feed-widget {
    margin-top: 3rem;
    padding: 2rem;
    background: var(--secondary-background-color);
    border-left: 4px solid var(--primary-color);
}

.news-feed-widget h4 {
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
    color: var(--text-color);
    text-transform: uppercase;
    letter-spacing: 1px;
}

#news-list {
    list-style: none;
    padding: 0;
}

#news-list li {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

#news-list li:last-child {
    border-bottom: none;
}

#news-list a {
    color: var(--text-color);
    font-size: 1rem;
    transition: color 0.2s ease;
}

#news-list a:hover {
    color: var(--primary-color);
}

.loading-news {
    font-style: italic;
    color: var(--secondary-text-color);
}

#rotator {
    transition: opacity 0.5s ease-in-out;
}

/* --- REFUERZO PARA SUB-MENÚ LOGIN (LIMPIEZA) --- */
@media (min-width: 769px) {
    /* La lógica principal ya está en el bloque superior */
}

/* En Móvil: Asegurar que se expanda al hacer clic */
@media (max-width: 768px) {

    /* No forzamos max-height para dejar que el Drill-down maneje el espacio */
    .menu-item-has-children.submenu-open>.sub-menu {
        display: block !important;
        max-height: none !important;
        opacity: 1 !important;
        background-color: #ffffff;
    }

    .sub-menu li a {
        padding-left: 20px !important;
    }

    /* Ajuste para los nuevos items con icono en móvil */
    .login-item a {
        display: flex !important;
        align-items: center !important;
        gap: 15px;
    }

    .login-item-icon {
        width: 32px;
        height: 32px;
        flex-shrink: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        color: var(--primary-color);
    }

    .login-item-icon svg {
        width: 20px;
        height: 20px;
    }

    .login-item-content strong {
        display: block;
        font-size: 0.95rem;
    }

    .login-item-content span {
        display: block;
        font-size: 0.75rem;
        color: var(--secondary-text-color);
    }
}

.login-dropdown {
    position: relative;
    display: inline-block;
}

/* Ocultar el menú de login en móvil por defecto */
#loginSubMenu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    min-width: 180px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    z-index: 10000;
    list-style: none;
    padding: 10px 0;
    border-radius: 8px;
    margin-top: 15px;
    border: 1px solid var(--border-color);
}

/* Flechita superior para el dropdown */
#loginSubMenu::before {
    content: '';
    position: absolute;
    top: -6px;
    right: 15px;
    width: 12px;
    height: 12px;
    background: #fff;
    transform: rotate(45deg);
    border-top: 1px solid var(--border-color);
    border-left: 1px solid var(--border-color);
}

/* Clase que activaremos con JS */
#loginSubMenu.is-open {
    display: block !important;
    max-height: none !important;
    overflow: visible !important;
    opacity: 1 !important;
    visibility: visible !important;
    animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Estilo de los enlaces internos */
#loginSubMenu li a {
    padding: 12px 20px;
    display: block;
    color: #333;
    text-decoration: none;
    font-size: 14px;
}

#loginSubMenu li a:hover {
    background-color: #f8f9fa;
}

/* ==================== Dark Mode ==================== */
html.dark-mode {
    --text-color: #f4f4f4;
    --secondary-text-color: #b0c4d6;
    --background-color: #0c1824; /* Azul oscuro logo */
    --secondary-background-color: #122436;
    --border-color: #1b354d;
    --light-text-color: #ffffff;
    --dark-footer-bg: #0a131c;
}

html.dark-mode body {
    background-color: #050a0f; /* Color para los márgenes fuera del contenedor principal */
}

html.dark-mode .moon-icon { display: none !important; }
html.dark-mode .sun-icon { display: block !important; }

.theme-toggle-btn:hover {
    background-color: rgba(44, 79, 112, 0.3) !important;
    color: var(--secondary-color) !important;
}
/* === CORPOHOSTING INJECTED CSS === */
/* ==========================================================================
   CORPOHOSTING - ENTERPRISE DESIGN SYSTEM
   ========================================================================== */

:root {
    /* Paleta de Colores */
    --bg-white: #FFFFFF;
    --bg-cloud-gray: #F4F6F8;
    --bg-authority-gray: #EAECEF;
    --corp-navy: #001B3A;
    --corp-navy-light: #002B5E;
    --accent-red: #0F62FE; /* Rojo ladrillo institucional */
    --accent-blue: #0052FF; /* Azul eléctrico para alertas/enlaces */
    --text-primary: #111827;
    --text-secondary: #4B5563;
    --border-color: #D1D5DB;

    /* Tipografía */
    --font-display: 'IBM Plex Sans', sans-serif;
    --font-body: 'Roboto', sans-serif;
    --font-mono: 'Fira Code', monospace;

    /* Estructura */
    --max-width: 1440px;
    --radius-strict: 2px;
}

/* ==========================================================================
   RESET & BASE
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: var(--font-body);
    color: var(--text-primary);
    background-color: var(--bg-cloud-gray);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

a {
    text-decoration: none;
    color: inherit;
}

.code-font {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Botones (Utilitarios, sin sombras difusas) */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: var(--radius-strict);
    transition: all 0.2s ease-in-out;
    cursor: pointer;
    text-align: center;
    border: 1px solid transparent;
}

.btn-primary-accent {
    background-color: var(--accent-blue);
    color: var(--bg-white);
}

.btn-primary-accent:hover {
    background-color: #0040D0;
}

.btn-accent {
    background-color: var(--accent-blue);
    color: var(--bg-white);
}

.btn-accent:hover {
    background-color: #0043ce;
}

.btn-ghost {
    background-color: transparent;
    color: var(--corp-navy);
    border: 1px solid var(--corp-navy);
}

.btn-ghost:hover {
    background-color: var(--corp-navy);
    color: var(--bg-white);
}

/* ==========================================================================
   HEADER & NAVEGACIÓN
   ========================================================================== */
.corp-header {
    background-color: var(--corp-navy);
    color: var(--bg-white);
    border-bottom: 2px solid var(--accent-blue);
}

.header-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 2rem;
    height: 70px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    align-self: stretch;
    gap: 0.5rem;
    text-decoration: none;
}

.logo-text {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 2.2rem;
    letter-spacing: 1.5px;
    line-height: 1;
}

.sci-bg {
    background-color: #ffffff;
    color: #000000 !important;
    padding: 0 1.5rem;
    display: flex;
    align-items: center;
    align-self: stretch;
    margin: 2px 0; /* <-- AGREGAR ESTA LÍNEA */
}

.logo-badge {
    background-color: var(--accent-blue);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    padding: 0.15rem 0.4rem;
    border-radius: var(--radius-strict);
    position: relative;
    top: -14px;
    margin-left: 2px;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.main-nav a {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.9rem;
    color: #A9B3C1;
    transition: color 0.2s;
}

.main-nav a:hover {
    color: var(--bg-white);
}

/* ==========================================================================
   MEGA MENÚ CORPORATIVO
   ========================================================================== */

/* Hacemos que la barra de navegación sea el punto de referencia */
.main-nav {
    position: relative; 
}

/* El estado base del Mega Menú (Oculto) */
.mega-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(15px);
    width: 100vw;
    max-width: 900px;
    background-color: var(--bg-white, #ffffff);
    box-shadow: 0 10px 40px rgba(0, 27, 58, 0.1);
    border-radius: 4px;
    border: 1px solid #e2e8f0;
    padding: 2.5rem;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    z-index: 1000;
}

.main-nav ul li.has-mega-menu:hover .mega-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.mega-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

.mega-column h4 {
    font-family: 'IBM Plex Sans', sans-serif;
    font-size: 0.85rem;
    color: #001b3a;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.2rem;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 0.5rem;
}

.mega-column ul {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.mega-column ul li a {
    color: #475569;
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s ease;
    display: block;
}

.mega-column ul li a:hover {
    color: #0052ff;
}

.mega-column.promo-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-left: 1px solid #e2e8f0;
    padding-left: 3rem !important;
}

.mega-column.promo-card h4 {
    border-bottom: none;
    margin-bottom: 0.5rem;
    text-transform: none;
    font-size: 1.1rem;
    letter-spacing: normal;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero-section {
    background-color: var(--bg-white);
    padding: 6rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.hero-grid {
    max-width: var(--max-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 60% 40%;
    gap: 4rem;
    align-items: center;
}

.tech-label {
    font-family: var(--font-mono);
    color: var(--accent-blue);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1rem;
    letter-spacing: 0.05em;
}

.display-title {
    font-size: 3.5rem;
    color: var(--corp-navy);
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    max-width: 90%;
}

.hero-ctas {
    display: flex;
    gap: 1rem;
}

.hero-diagram {
    background-color: var(--bg-cloud-gray);
    border: 1px solid var(--border-color);
    height: 350px;
    width: 92%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    position: relative;
    overflow: hidden;
}

.hero-diagram img {
    width: 100%;
    height: auto;
    object-fit: contain;
    mix-blend-mode: multiply;
}

.architecture-carousel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: calc(100% - 35px);
    z-index: 1;
}

.arch-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    mix-blend-mode: multiply;
}

.arch-slide.active {
    opacity: 1;
    z-index: 2;
}

.diagram-caption {
    background-color: var(--bg-cloud-gray);
    border-top: 1px solid var(--border-color);
    padding: 0.5rem 1rem;
    text-align: right;
    position: relative;
    z-index: 3;
}

/* ==========================================================================
   TRUST SIGNALS & CORE SERVICES
   ========================================================================== */
.trust-signals {
    background-color: var(--bg-white);
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.trust-container {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 2rem;
}

.trust-label {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-secondary);
    white-space: nowrap;
}

.logos-grid {
    display: flex;
    gap: 3rem;
    flex-wrap: wrap;
    opacity: 0.6;
    filter: grayscale(100%);
}

.tech-logo {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.1rem;
}

.core-services {
    padding: 6rem 2rem;
}

.services-container {
    max-width: var(--max-width);
    margin: 0 auto;
}

.section-header {
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: 2.5rem;
    color: var(--corp-navy);
}

.section-header p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.service-card {
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-strict);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    transition: border-color 0.2s;
}

.service-card:hover {
    border-color: var(--corp-navy);
}

.card-header {
    margin-bottom: 1rem;
}

.card-id {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--accent-blue);
    display: block;
    margin-bottom: 0.5rem;
}

.card-header h3 {
    font-size: 1.5rem;
    color: var(--corp-navy);
}

.card-body p {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 2rem;
    flex-grow: 1;
}

.card-footer {
    border-top: 1px solid var(--bg-cloud-gray);
    padding-top: 1rem;
    margin-top: auto;
}

.link-technical {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--accent-blue);
}

.link-technical:hover {
    text-decoration: underline;
}

/* ==========================================================================
   TECHNICAL AUTHORITY & FOOTER
   ========================================================================== */
.technical-authority {
    background-color: var(--bg-authority-gray);
    padding: 6rem 2rem;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.authority-container {
    max-width: var(--max-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr;
}

.authority-content {
    max-width: 800px;
}

.authority-content h2 {
    font-size: 2.5rem;
    color: var(--corp-navy);
    margin-bottom: 1.5rem;
}

.authority-content p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.tech-list {
    list-style: none;
    margin-top: 2rem;
}

.tech-list li {
    font-family: var(--font-display);
    font-size: 1.05rem;
    color: var(--corp-navy);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tech-list .code-font {
    color: var(--accent-blue);
    font-weight: bold;
}

.global-footer {
    background-color: var(--corp-navy);
    color: #A9B3C1;
    padding: 4rem 2rem 2rem;
}

.footer-container {
    max-width: var(--max-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 3rem;
}

.footer-column h4 {
    color: var(--bg-white);
    font-size: 1rem;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin-bottom: 0.75rem;
}

.footer-column a {
    font-size: 0.9rem;
    transition: color 0.2s;
}

.footer-column a:hover {
    color: var(--bg-white);
    text-decoration: underline;
}

.branding .logo-text {
    color: var(--bg-white);
}

.copyright {
    font-size: 0.8rem;
    border-top: 1px solid var(--corp-navy-light);
    padding-top: 1rem;
    margin-top: 2rem;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }

.status-indicator {
    display: inline-block;
    margin-top: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: #10B981;
}

.status-indicator::before {
    content: '●';
    margin-right: 0.5rem;
}

/* ==========================================================================
   NAVEGACIÓN MÓVIL (DOBLE CAJÓN - ESTILO B2B)
   ========================================================================== */
.mobile-triggers {
    display: none;
}

.mobile-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: var(--bg-white);
    z-index: 9999;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

#mobile-user-drawer {
    transform: translateX(100%);
}

.mobile-drawer.is-open {
    transform: translateX(0) !important;
}

.mobile-drawer-header {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding: 0 2rem;
    height: 70px;
    background-color: var(--corp-navy);
    color: var(--bg-white);
    border-bottom: 2px solid var(--accent-blue);
}

.btn-close-drawer {
    margin-left: auto; /* Empuja el botón al borde derecho */
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-secondary);
    cursor: pointer;
    line-height: 1;
}

.mobile-accordion {
    padding: 1rem 2rem;
}

.accordion-item {
    border-bottom: 1px solid var(--border-color);
}

.accordion-header {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 1.2rem 0;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--corp-navy);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.accordion-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.accordion-body ul {
    list-style: none;
    padding: 0 0 1.5rem 0;
    margin: 0;
}

.accordion-body ul li a {
    display: block;
    padding: 0.8rem 0;
    color: var(--text-secondary);
    font-size: 0.95rem;
    border-radius: 4px;
}

/* ==========================================================================
   MEDIA QUERIES UNIFICADAS
   ========================================================================== */

/* 1. Ajustes para Tablets y transición a móvil (max-width: 1024px) */
@media (max-width: 1024px) {
    /* 1. Gestión de Desbordamientos (Overflow) para Diagramas y Tablas */
    .mermaid, 
    .authority-visual,
    .hero-diagram {
        max-width: 100vw;
        overflow-x: auto;
        overflow-y: hidden;
    }
    
    table {
        display: block;
        max-width: 100vw;
        overflow-x: auto;
        white-space: nowrap;
    }

    /* 2. Reducción Proporcional de Paddings Masivos Inline */
    [style*="padding: 6rem"] {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
    }

    /* 3. Colapso Inteligente (Stacking) de Grillas en Línea */
    [style*="grid-template-columns:"],
    .authority-container, 
    .services-grid, 
    .blueprint-grid,
    .zig-zag-row {
        grid-template-columns: 1fr !important;
    }

    /* 4. Colapso de Flexbox en Línea (Múltiples columnas a 1 columna) */
    [style*="display: flex"].feature-row,
    [style*="display: flex"].zig-zag-row,
    [style*="flex-direction: row"],
    section > div > [style*="display: flex"] {
        flex-direction: column !important;
        align-items: flex-start !important;
    }
    
    /* Prevenir inversión de lectura en móviles */
    .reverse {
        flex-direction: column !important;
    }

    /* Ajustes de Grid Básicos */
    .hero-grid { grid-template-columns: 1fr; }
    .services-grid { grid-template-columns: 1fr; }
    .footer-container { grid-template-columns: 1fr 1fr; }
    
    /* Utilidad para ocultar elementos en pantallas móviles */
    .hide-on-mobile { display: none !important; }

    /* Apagar Mega Menú y Botón de Escritorio */
    .main-nav, .header-actions { display: none !important; }

    /* Encender Botones Estilo Red Hat */
    .mobile-triggers {
        display: flex;
        gap: 0.5rem;
    }

    .btn-mobile {
        background: transparent;
        border: 1px solid var(--bg-white); /* Borde blanco */
        border-radius: 50px;
        padding: 0.4rem 1rem;
        font-family: var(--font-body);
        font-size: 0.85rem;
        color: var(--bg-white); /* Texto e icono blancos */
        cursor: pointer;
        display: flex;
        align-items: center;
        gap: 0.4rem;
        transition: background-color 0.2s, color 0.2s; /* Transición suave */
    }

    /* Efecto hover opcional para cuando lo toquen */
    .btn-mobile:active, .btn-mobile:hover {
        background-color: var(--bg-white);
        color: var(--corp-navy);
    }
}

/* 2. Ajustes específicos para Teléfonos Inteligentes (max-width: 768px) */
@media (max-width: 768px) {
    /* Ajuste de tipografía para evitar desbordamiento de palabras largas */
    .display-title {
        font-size: 2.2rem;
        line-height: 1.1;
        word-wrap: break-word;
    }
    
    /* Reducimos el padding lateral del Hero para ganar más espacio */
    .hero-section {
        padding: 3rem 1.5rem;
    }
    
    /* Ajustar el footer para que sea de 1 columna en teléfonos pequeños */
    .footer-container { 
        grid-template-columns: 1fr; 
    }
}

/* ==========================================================================
   FIXES ESTRUCTURALES RESPONSIVE (SOBREESCRITURA DE INLINE STYLES)
   ========================================================================== */
@media (max-width: 1024px) {
    /* 1. Gestión de Desbordamientos (Overflow) para Diagramas y Tablas */
    .mermaid, 
    .authority-visual,
    .hero-diagram {
        max-width: 100vw;
        overflow-x: auto;
        overflow-y: hidden;
    }
    
    table {
        display: block;
        max-width: 100vw;
        overflow-x: auto;
        white-space: nowrap;
    }

    /* 2. Reducción Proporcional de Paddings Masivos Inline */
    [style*="padding: 6rem"],
    [style*="padding: 7rem"],
    [style*="padding: 5rem"] {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
        padding-left: 1.5rem !important;
        padding-right: 1.5rem !important;
    }

    /* 3. Colapso Inteligente (Stacking) de Grillas en Línea */
    [style*="grid-template-columns:"],
    .authority-container, 
    .services-grid, 
    .blueprint-grid,
    .zig-zag-row {
        grid-template-columns: 1fr !important;
    }

    /* 4. Colapso de Flexbox en Línea (Múltiples columnas a 1 columna) */
    [style*="display: flex"].feature-row,
    [style*="display: flex"].zig-zag-row,
    [style*="flex-direction: row"],
    section > div > [style*="display: flex"] {
        flex-direction: column !important;
        align-items: flex-start !important;
    }
    
    /* Prevenir inversión de lectura en móviles */
    .reverse {
        flex-direction: column !important;
    }
}
/* Overrides para Mega Menus alineados a la derecha */
.mega-menu.right-align {
    left: auto !important;
    right: 0 !important;
    transform: translateY(15px) !important;
}
.main-nav ul li.has-mega-menu:hover .mega-menu.right-align {
    transform: translateY(0) !important;
}

