/* =========================================
   1. CONFIGURACIÓN GENERAL Y BASE
   ========================================= */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 0;
    background-color: #f9f9f9;
}

/* Navegación */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    padding: 15px 10%;
    border-bottom: 2px solid #004a87;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo {
    display: flex;
    align-items: center;
    font-weight: bold;
    font-size: 1.5rem;
    color: #004a87;
}

.logo-img {
    height: 50px;
    width: auto;
    display: block;
}

nav ul {
    list-style: none;
    display: flex;
    margin: 0;
}

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    text-decoration: none;
    color: #004a87;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
}

nav ul li a:hover {
    color: #00a8e1;
}

/* =========================================
   2. BANNER PRINCIPAL (ESCRITORIO)
   ========================================= */
.full-screen-banner {
    position: relative;
    width: 100%;
    height: 60vh; 
    background-image: url('banner_principal.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.banner-overlay {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(0, 74, 135, 0.8) 0%, rgba(0, 0, 0, 0.4) 100%);
    z-index: 1;
}

.logo-container {
    position: relative;
    z-index: 2;
    color: white;
    text-align: center;
    max-width: 1200px;
    padding: 0 20px;
}

.logo-container h1 {
    font-size: 3.5rem;
    font-weight: bold;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.5);
    margin-bottom: 10px;
    line-height: 1.1;
}

.logo-container p {
    font-size: 1.4rem;
    text-shadow: 1px 1px 5px rgba(0,0,0,0.3);
}

/* =========================================
   3. SECCIÓN SERVICIOS Y CONTENIDO
   ========================================= */
.servicios-container {
    padding: 80px 10%;
    background-color: #fcfdfe;
    text-align: center;
}

.servicios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); 
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.servicio-card-premium {
    background: #ffffff;
    border-radius: 15px;
    padding: 45px 35px;
    border: 1px solid #eef2f6;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.servicio-card-premium:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0,74,135,0.12);
}

.icon-wrapper {
    width: 90px;
    height: 90px;
    background: #f0f7ff;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 25px;
}

.accent-line {
    width: 40px;
    height: 3px;
    background: #8cc63f;
    margin-bottom: 25px;
}

.feature-list {
    list-style: none;
    padding: 0;
    width: 100%;
}

.feature-list li {
    text-align: left;
    padding: 8px 0;
    padding-left: 25px;
    position: relative;
    color: #444;
    font-size: 0.95rem;
    border-bottom: 1px solid #f4f4f4;
}

.feature-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #8cc63f;
    font-weight: bold;
}

/* =========================================
   4. TABLAS Y GRÁFICOS (EncuestasMVC)
   ========================================= */
.chart-container {
    width: 100%;
    margin-top: 30px;
}

table {
    width: 100%;
    border-collapse: collapse;
}

td {
    padding: 12px;
    border-bottom: 1px solid #eee;
}

.bar-background {
    background: #e9ecef;
    border-radius: 4px;
    width: 100%;
    height: 18px;
    position: relative;
}

.bar-fill { height: 100%; border-radius: 4px; }
.pan { background-color: #004795; }
.morena { background-color: #b3252e; }
.pri { background-color: #00a551; }
.prd { background-color: #ffcd00; }
.mc { background-color: #ff8200; }

/* =========================================
   5. MEDIA QUERIES (AJUSTE PARA IPHONE)
   ========================================= */
@media (max-width: 768px) {
    /* Ajuste crítico del texto que se cortaba */
    .logo-container h1 {
        font-size: 1.8rem !important;
        padding: 0 10px;
        line-height: 1.2;
    }

    .logo-container p {
        font-size: 1rem !important;
        padding: 0 15px;
    }

    .full-screen-banner {
        height: 40vh !important;
        background-attachment: scroll; /* Mejora rendimiento en iOS */
    }

    nav {
        flex-direction: column !important;
        padding: 10px !