/* VARIABLES */
:root {
    --primary: #D34037;
    --primary-dark: #b02a22;
    --text: #333;
    --bg-light: #f4f6f8;
    --serif: 'Playfair Display', serif;
    --sans: 'Lato', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: var(--sans); color: var(--text); background: #fff; padding-top: 100px; }

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* ================= HEADER & LOGO GIGANTE ================= */
.main-header {
    position: fixed;
    top: 0; left: 0; width: 100%;
    background: #fff;
    height: 90px; /* Un poco más alto para equilibrar el logo grande */
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
    z-index: 1000;
    display: flex;
    align-items: center;
}

.header-container {
    width: 95%; max-width: 1400px; margin: 0 auto;
    display: flex; justify-content: space-between; align-items: center;
    position: relative;
}

/* NAVEGACIÓN */
.nav-left ul, .nav-right ul { display: flex; gap: 30px; align-items: center; }
.nav-left a, .nav-right a {
    font-weight: 700; text-transform: uppercase; font-size: 0.85rem; color: #555; letter-spacing: 0.5px;
}
.nav-left a:hover, .nav-right a:hover { color: var(--primary); }

/* --- PESTAÑA CENTRAL DEL LOGO (GIGANTE) --- */
.logo-tab-wrapper {
    position: absolute;
    left: 50%;
    top: 0;
    transform: translateX(-50%);
    z-index: 1001;
}

.logo-tab {
    background-color: var(--primary);
    /* Ajuste de dimensiones para logo de 200px */
    width: 240px; 
    padding: 10px 20px 25px 20px; 
    border-radius: 0 0 40px 40px; /* Curva más pronunciada */
    box-shadow: 0 5px 25px rgba(211, 64, 55, 0.5);
    display: flex; justify-content: center;
    transition: transform 0.3s;
}
.logo-tab:hover { transform: translateY(5px); }

.logo-tab img {
    width: 200px; /* TAMAÑO SOLICITADO */
    height: auto;
    display: block;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
}

/* BOTÓN COMPUCOL */
.btn-compucol {
    background-color: var(--text); color: #fff !important;
    padding: 10px 20px; border-radius: 50px;
    font-size: 0.8rem !important; display: flex; align-items: center; gap: 8px;
}
.btn-compucol:hover { background-color: var(--primary); }

/* MÓVIL */
.menu-toggle { display: none; background: none; border: none; font-size: 1.8rem; cursor: pointer; color: var(--text); }
.mobile-menu {
    display: none; position: absolute; top: 90px; left: 0; width: 100%;
    background: #fff; padding: 30px; box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    flex-direction: column; gap: 20px; text-align: center; border-top: 4px solid var(--primary);
}
.mobile-menu.active { display: flex; }
.mobile-btn { background: var(--primary); color: #fff; padding: 12px; border-radius: 5px; font-weight: 700; display: block; }

/* ================= HERO & SECCIONES ================= */
.hero {
    height: 90vh; min-height: 600px;
    background: url('https://images.unsplash.com/photo-1523050854058-8df90110c9f1?ixlib=rb-1.2.1&auto=format&fit=crop&w=1950&q=80') no-repeat center/cover;
    position: relative; display: flex; align-items: center; justify-content: center; text-align: center;
}
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.6)); }
.hero-content { position: relative; z-index: 2; color: #fff; max-width: 900px; padding: 0 20px; margin-top: 60px; /* Para no chocar con el logo grande */ }

.subtitle { display: block; font-family: var(--sans); letter-spacing: 4px; text-transform: uppercase; margin-bottom: 15px; font-size: 1.2rem; }
.title { font-family: var(--serif); font-size: 4rem; line-height: 1.1; margin-bottom: 25px; font-weight: 700; text-shadow: 0 2px 10px rgba(0,0,0,0.5); }
.description { font-size: 1.3rem; margin-bottom: 40px; opacity: 0.95; font-weight: 300; }

.cta-group { display: flex; gap: 20px; justify-content: center; }
.btn { padding: 15px 40px; border-radius: 50px; font-weight: 700; text-transform: uppercase; font-size: 0.9rem; border: 2px solid transparent; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-outline { border-color: #fff; color: #fff; }
.btn-outline:hover { background: #fff; color: var(--text); }

.section { padding: 100px 0; }
.container { width: 90%; max-width: 1200px; margin: 0 auto; }
.section-header { text-align: center; margin-bottom: 60px; }
.badge { color: var(--primary); font-weight: 700; text-transform: uppercase; letter-spacing: 2px; font-size: 0.9rem; }
.section-header h2 { font-family: var(--serif); font-size: 3rem; margin: 15px 0 25px; color: var(--text); }
.line { width: 80px; height: 4px; background: var(--primary); margin: 0 auto; }

.grid-pei { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 40px; }
.pei-card { background: #fff; padding: 50px 30px; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,0.05); text-align: center; transition: 0.3s; border-top: 5px solid transparent; }
.pei-card:hover { transform: translateY(-10px); border-top-color: var(--primary); }
.pei-card.red-card { background: var(--primary); color: #fff; }
.pei-card.red-card .icon { background: rgba(255,255,255,0.2); color: #fff; }
.icon { width: 80px; height: 80px; margin: 0 auto 25px; background: #fff5f5; color: var(--primary); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 2rem; }
.pei-card h3 { font-family: var(--serif); margin-bottom: 15px; font-size: 1.8rem; }

/* ================= FOOTER RESTAURADO (ESTILO ANTERIOR) ================= */
.site-footer {
    background-color: var(--primary);
    color: #fff;
    padding: 60px 0;
    margin-top: 50px;
    border-top: 5px solid #b02a22;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 30px;
}

/* Izquierda: Redes */
.footer-social { text-align: left; }
.footer-social p { font-weight: 700; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 10px; color: rgba(255,255,255,0.9); }
.social-icons i { font-size: 2.5rem; margin-right: 15px; transition: 0.3s; }
.social-icons a:hover i { transform: scale(1.1); color: #f0f0f0; }

/* Centro: Info */
.footer-credits { text-align: center; opacity: 0.9; font-size: 0.95rem; }
.small-text { font-size: 0.8rem; opacity: 0.8; margin-top: 5px; text-transform: uppercase; }

/* Derecha: Logo Grande */
.footer-logo { text-align: right; }
.hosted { display: block; font-size: 0.8rem; text-transform: uppercase; margin-bottom: 10px; font-weight: 700; color: rgba(255,255,255,0.9); }
.ub-logo {
    max-height: 160px; /* LOGO FOOTER GRANDE */
    width: auto;
    filter: brightness(0) invert(1); /* Blanco puro */
    display: inline-block;
}

/* ================= RESPONSIVE ================= */
@media (max-width: 900px) {
    .nav-left, .nav-right { display: none; }
    .menu-toggle { display: block; }
    
    /* Ajuste Logo Móvil (Más pequeño para que no tape todo) */
    .logo-tab { width: 140px; padding: 10px 10px 15px 10px; border-radius: 0 0 20px 20px; }
    .logo-tab img { width: 120px; }
    
    .title { font-size: 2.5rem; }
    .hero-content { margin-top: 80px; }
    
    /* Footer Stack */
    .footer-content { flex-direction: column; text-align: center; }
    .footer-social, .footer-logo, .footer-credits { text-align: center; }
}