/************************************************************
 * ARCHIVO DE ESTILOS PRINCIPAL - PRESTIGIOCAR
 * SECCIÓN ACTUALIZADA: CLIENTES Y NAVEGACIÓN
 ************************************************************/

/* ==========================================================
   1. RESET Y CONFIGURACIÓN BASE
   ========================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    /* Degradado de fondo de gris claro a azul muy oscuro */
    background: linear-gradient(to bottom, #f0f0f0 0%, #bdc3c7 20%, #2c3e50 60%, #1a1a2e 100%);
    color: #fff;
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* ==========================================================
   2. HEADER (ENCABEZADO)
   ========================================================== */
.main-header {
    position: relative;
    padding: 20px 10px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    min-height: 150px;
}

/* Capa de fondo con desenfoque para el Header */
.main-header::before {
    content: "";
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-size: cover;
    background-position: center;
    z-index: -1;
    filter: blur(2px);
    background-image: 
        radial-gradient(circle, rgba(255,255,255,0.2) 0%, rgba(0,0,0,0.5) 100%), 
        url('/recursos/fondo.jpeg');
    opacity: 0.7;
}

/* Identificación Fiscal */
.rif {
    text-align: right;
    font-size: 0.85rem;
    color: #1a1a2e;
    font-weight: bold;
    margin-bottom: 10px;
    width: 100%;
}

/* Logo con efectos de iluminación y profundidad */
.main-logo {
    max-width: 90%;
    height: auto;
    max-height: 180px;
    filter: drop-shadow(0px 0px 10px rgba(255, 255, 255, 0.6)) 
            drop-shadow(2px 4px 8px rgba(0, 0, 0, 0.5));
    transition: transform 0.3s ease, filter 0.3s ease;
}

/* ==========================================================
   3. NAVEGACIÓN (MENÚ PRINCIPAL Y SUBMENÚ)
   ========================================================== */
.main-nav ul {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    background: #2a2a72;
    border-top: 2px solid #1a1a2e;
    padding: 5px;
}

.main-nav li {
    flex: 1;
    min-width: 120px;
    position: relative; /* Clave para el submenú */
}

.main-nav a {
    display: block;
    padding: 15px;
    text-align: center;
    color: #ffffff;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.4s ease;
}

.main-nav a:hover, 
.main-nav a.active {
    background: #4a69bd; 
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

/* --- ESTILOS DEL SUBMENÚ (CORREGIDO) --- */
.main-nav ul .submenu {
    display: none;           /* Se oculta por defecto */
    flex-direction: column;  /* Fuerza la lista vertical */
    position: absolute;
    top: 100%;
    left: 0;
    background: #2a2a72;
    min-width: 200px;
    z-index: 1000;
    padding: 0;
    border-top: none;
    border-bottom: 3px solid #4a69bd;
    box-shadow: 0 8px 16px rgba(0,0,0,0.4);
}

.main-nav .submenu li {
    width: 100%;
    min-width: 100%;
}

.main-nav .submenu a {
    text-align: left;
    padding: 12px 20px;
    font-size: 0.9rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    border-radius: 10; /* Evita bordes redondeados en la lista */
}

.main-nav .submenu a:hover {
    transform: none; /* Evita el salto visual en el submenú */
    background: #4a69bd;
}

/* Mostrar submenú al pasar el mouse */
.main-nav li:hover > .submenu {
    display: flex;
}

/* ==========================================================
   4. SECCIÓN CLIENTES (PÁGINA CLIENTES)
   ========================================================== */
.clientes-page {
    padding: 60px 0;
}

.section-title {
    padding-left: 50px;
    text-shadow: 2px 2px 0px #1a1a2e;
}

.intro-text {
    text-align: center;
    margin-bottom: 40px;
    color: #bdc3c7;
}

/* Cuadrícula adaptable para los logos */
.clientes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    max-width: 80%;
    margin: 0 auto;
}

.cliente-item {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* El globo circular contenedor del logo */
.cliente-globe {
    width: 200px;
    height: 200px;
    background: #ffffff;
    border: 6px solid #2a2a72;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: all 0.4s ease;
    box-shadow: 0 8px 15px rgba(0,0,0,0.3);
    margin-bottom: 15px;
}

.cliente-globe img {
    width: 100%;
    height: auto;
    transition: all 0.4s ease;
}

/* --- Efectos Hover para Clientes --- */
.cliente-item:hover .cliente-globe {
    transform: scale(1.1); /* Expansión del círculo */
    border-color: #4a69bd;
    box-shadow: 0 12px 25px rgba(74, 105, 189, 0.5);
}

.cliente-item:hover .cliente-globe img {
    filter: grayscale(0%); /* El logo recupera su color */
    transform: scale(1.05);
}

.cliente-item h4 {
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: bold;
    letter-spacing: 1px;
    text-shadow: 2px 2px 0px #1a1a2e;
}

/* Estilos para cuando el cliente es un enlace (href) */
.cliente-link {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.cliente-link:hover h4 {
    color: #4a69bd;
    transition: color 0.3s ease;
}

/* ==========================================================
   5. FOOTER (PIE DE PÁGINA)
   ========================================================== */
.main-footer {
    background-color: #333333;
    color: #ffffff;
    padding: 10px 20px;
    text-align: center;
    border-top: 3px solid #4a69bd;
    margin-top: 10px;
}

.footer-content p {
    margin: 5px 0;
    font-size: 0.95rem;
}

/* ==========================================================
   6. RESPONSIVIDAD (MÓVIL)
   ========================================================== */
@media (max-width: 768px) {
    .contact-grid {
        flex-direction: column;
        padding: 20px;
    }
    
    .main-nav ul {
        flex-direction: column; /* Apila el menú en vertical */
    }
}