/* 1. VARIABLES GLOBALES */
:root {
    --color-bg-light: #E5E5E5;
    --color-bg-medium: #BDBDBD;
    --color-bg-dark: #1F2937;
    --color-bg-darker: #111827;
    --color-bg-footer: #030712;
    --color-text-light: #FFFFFF;
    --color-text-gray-100: #F3F4F6;
    --color-text-gray-200: #E5E7EB;
    --color-text-medium: #9CA3AF;
    --color-text-dark: #111827;
    --color-accent: #FBBF24;
    --color-accent-hover: #CA8A04;
    --font-family: system-ui, -apple-system, sans-serif;
}

/* 2. RESET UNIVERSAL */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; width: 100%; height: 100%; overflow-x: hidden; background-color: var(--color-bg-footer); }
body {
    font-family: var(--font-family); background-color: var(--color-bg-light);
    color: var(--color-text-dark); font-weight: 300; line-height: 1.6;
    width: 100%; max-width: 100vw; overflow-x: hidden !important; position: relative; min-height: 100vh;
}

/* 3. ESTILOS GENERALES Y CENTRADO */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family); text-transform: uppercase; color: var(--color-text-dark);
    font-weight: 900; letter-spacing: -0.025em; margin-bottom: 1rem;
}
h2 { font-size: 60px; color: var(--color-text-dark); }
@media (min-width: 768px) { h2 { font-size: 72px; } }
p { margin-bottom: 1rem; }

/* --- CONTENEDOR MAESTRO (CENTRA TODA LA PÁGINA) --- */
.container {
    max-width: 1200px !important; 
    margin-left: auto !important; 
    margin-right: auto !important; 
    padding-left: 20px;
    padding-right: 20px;
    width: 100%;
}
.line-divider { width: 100px; height: 3px; background-color: var(--color-accent); margin: 0 auto 2rem auto; }

/* 4. BOTONES */
.btn {
    display: inline-flex; align-items: center; justify-content: center; padding: 0.8rem 1.5rem;
    text-decoration: none; text-transform: uppercase; font-family: var(--font-family); font-weight: 700; letter-spacing: 0.05em;
    border-radius: 5px; transition: background-color 0.3s ease;
}
.btn-primary { background-color: var(--color-accent); color: var(--color-text-dark); }
.btn-primary:hover { background-color: var(--color-accent-hover); }

/* 5. NAVEGACIÓN  */
nav {
    position: fixed; top: 0; left: 0; width: 100%; z-index: 1000;
    background-color: transparent; border-bottom: 1px solid transparent; padding: 1rem 0;
    transition: background-color 0.3s ease, border-bottom 0.3s ease, padding 0.3s ease;
}
nav.nav-scrolled {
    background-color: rgba(17, 24, 39, 0.95); border-bottom: 1px solid var(--color-bg-dark);
    padding: 0.8rem 0; backdrop-filter: blur(10px); box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.nav-container { 
    display: flex; 
    justify-content: space-between; /* Mantiene Logo a la izq y Botón a la der */
    align-items: center; 
}

/* --- AQUÍ ESTÁ EL CAMBIO PARA CENTRAR "INICIO Y LOS DEMÁS" --- */
.nav-links { 
    display: flex; 
    list-style: none; 
    align-items: center; 
    
    /* Estas 2 líneas hacen la magia de moverlos al centro */
    flex-grow: 1;           /* Ocupan todo el espacio libre en medio */
    justify-content: center; /* Centran los textos en ese espacio */
    margin: 0;              /* Quitamos márgenes viejos */
}

.nav-links li { 
    margin: 0 1.5rem; /* Espacio parejo entre cada palabra */
}

.nav-links a {
    color: var(--color-text-light); text-decoration: none; text-transform: uppercase; font-weight: 500; letter-spacing: 0.05em;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}
.nav-links a:hover { color: var(--color-accent); }
.nav-btn-item a { text-shadow: none; }
.nav-toggle { display: none; background: none; border: none; color: var(--color-text-light); font-size: 2rem; }

/* Ajuste para que el Logo no se estire */
.logo {
    flex-shrink: 0; /* Evita que el logo se aplaste */
    margin-right: 20px;
}

/* 6. HERO (PORTADA) - ARREGLADO Y CENTRADO */
.hero {
    position: relative; min-height: 90vh; display: flex; align-items: center; justify-content: center; text-align: center; overflow: hidden;
    width: 100%; /* Asegura ancho completo */
}
.hero-bg-image {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to top, rgb(10, 47, 87) 0%, rgba(0, 86, 179, 0.1) 100%),
    url('imagenes/imgbarber.jpg') no-repeat center center/cover;
}
.hero-gradient-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to top, #111827 10%, rgba(17,24,39,0.6) 50%, rgba(17,24,39,0.3) 100%);
    z-index: -1;
}

/* --- CENTRADO DEFINITIVO DEL CONTENIDO HERO --- */
.hero-content {
    /* Centrado Absoluto */
    width: 100% !important;
    max-width: 1200px !important;
    padding-top: 4rem;
    position: relative;
    z-index: 1;
    margin-left: auto !important;
    margin-right: auto !important;

    /* Flexbox para alinear hijos */
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important; 
    justify-content: center !important;
    text-align: center !important;
}

.hero-logo { max-width: 300px; margin-bottom: 2rem; }
.hero-title-wrapper {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    line-height: 1; margin-bottom: 1rem; width: 100%;
}
.typography-script {
    font-family: "Times New Roman", serif; font-style: italic; font-weight: 300; font-size: 2.5rem; color: #FFF; margin-bottom: 0.5rem;
}
.typography-block {
    font-family: var(--font-family); font-weight: 900; font-size: 4.5rem;
    text-transform: uppercase; letter-spacing: -0.02em; color: var(--color-accent); line-height: 0.9;
}
.hero-subtitle-industrial { font-size: 1.5rem; color: #FFF; letter-spacing: 0.2em; font-weight: 700; margin-top: 2rem; }
.hero-desc { font-size: 1.2rem; color: #CCC; font-weight: 300; margin-top: 1rem; }

/* 7. SECCIONES */
section, footer { padding: 5rem 0; text-align: center; }
#nosotros, #galeria { background-color: var(--color-bg-medium); }
#servicios, #equipo { background-color: var(--color-bg-light); }
section h3, section p { color: var(--color-text-dark); }
.section-subtitle { font-size: 1.1rem; max-width: 600px; margin: 0 auto 2.5rem auto; font-weight: 300; }

/* 8. SOBRE NOSOTROS */
.about-card {
    background-color: var(--color-bg-darker); color: var(--color-text-light);
    padding: 3rem; border-radius: 5px; margin: 0 auto 3rem auto;
    max-width: 800px; text-align: left; border-left: 5px solid var(--color-accent);
}
.about-text-large { color: var(--color-text-gray-100); font-size: 24px; font-weight: 300; margin-bottom: 1.5rem; }
.about-text-medium { color: var(--color-text-gray-200); font-size: 20px; font-weight: 300; margin-bottom: 1.5rem; }
.about-signature { color: var(--color-accent); font-size: 24px; font-weight: 700; font-style: italic; text-align: left; margin-top: 2rem; margin-bottom: 0; }
.card-divider { width: 100%; height: 3px; background-color: var(--color-accent); margin-top: 1rem; margin-left: 0; margin-right: auto; }
@media (min-width: 768px) { .about-text-large, .about-signature { font-size: 30px; } .about-text-medium { font-size: 24px; } }

.values-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; margin-top: 3rem; }
.value-card { background-color: var(--color-bg-darker); color: var(--color-text-light); padding: 2rem; border-radius: 5px; }
.value-card h4 { font-weight: 900; text-transform: uppercase; color: var(--color-text-light); }
.value-card p { font-weight: 300; color: var(--color-text-medium); }
.value-card svg { color: var(--color-accent); width: 48px; height: 48px; margin-bottom: 1rem; }
@media (max-width: 768px) { .values-grid { grid-template-columns: 1fr; } }

/* 9. SERVICIOS */
.services-grid { display: grid; grid-template-columns: repeat(1, 1fr); gap: 2rem; text-align: left; }
@media (min-width: 768px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }

.service-card {
    background-color: var(--color-bg-medium); padding: 2rem; border-radius: 5px;
    border: 2px solid #D1D5DB; transition: all 0.3s ease; display: flex; flex-direction: column; gap: 1rem;
}
.service-card:hover {
    border-color: var(--color-accent);
    box-shadow: 0 10px 25px -5px rgba(251, 191, 36, 0.1), 0 8px 10px -6px rgba(251, 191, 36, 0.1);
    transform: translateY(-5px);
}
.service-icon-box {
    width: 50px; height: 50px; display: flex; align-items: center; justify-content: center;
    border-radius: 8px; background-color: var(--color-bg-darker); color: var(--color-accent);
    transition: all 0.3s ease;
}
.service-card:hover .service-icon-box { background-color: var(--color-accent); color: var(--color-bg-darker); }
.service-card h4 { font-weight: 900; color: var(--color-bg-darker); margin-bottom: 0.5rem; text-transform: uppercase; }

.service-list { list-style: none; padding: 0; margin: 0; width: 100%; }
.service-list li { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 1rem; border-bottom: 1px solid #D1D5DB; padding-bottom: 0.5rem; }
.service-list li:last-child { border-bottom: none; margin-bottom: 0; }
.service-list strong { color: var(--color-bg-darker); font-weight: 800; display: block; }
.service-list small { color: #002169 !important; font-size: 0.95rem; font-weight: 600 !important; font-style: italic; }
.service-list span { color: var(--color-bg-darker); font-weight: 900; font-family: var(--font-family); font-size: 1.2rem; margin-left: 1rem; }

/* Tarjeta Especial (VIP) */
.special-card {
    background: linear-gradient(145deg, #0c3564, #1374a1) !important;
    border: 2px solid #FBBF24 !important;
    box-shadow: 0 0 25px rgba(255, 183, 0, 0.15) !important;
    position: relative; overflow: hidden; transform: scale(1.02);
}
.vip-badge {
    position: absolute; top: 15px; right: -30px; background-color: #FBBF24; color: hsl(0, 0%, 100%);
    font-weight: 900; font-size: 0.8rem; padding: 5px 35px; transform: rotate(45deg); box-shadow: 0 2px 5px rgb(255, 255, 255);
}
.special-card .service-list span { color: #fcb400 !important; text-shadow: 0 0 10px rgba(243, 243, 243, 0.596); font-size: 1.4rem; }
.special-card .service-icon-box { background-color: rgba(255, 255, 255, 0.1) !important; color: #FBBF24 !important; }
.special-card h4 { color: #06131f !important; text-shadow: 0 0 10px rgb(250, 250, 250); }
.special-card .service-list strong { color: #FFFFFF !important; }
.special-card .service-list li { border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important; }
.special-card:hover { box-shadow: 0 0 40px rgba(255, 183, 1, 0.507) !important; border-color: #ffffff !important; transform: scale(1.05) translateY(-5px); }

/* 10. GALERÍA */
.image-gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1rem; }
.image-gallery img { width: 100%; height: 300px; object-fit: cover; border-radius: 5px; }

/* 11. EQUIPO */
.team-grid-dos { display: grid; grid-template-columns: 1fr; gap: 2rem; max-width: 900px; margin: 0 auto; }
@media (min-width: 768px) { .team-grid-dos { grid-template-columns: repeat(2, 1fr); } }
.team-card { background-color: var(--color-bg-darker); border-radius: 5px; overflow: hidden; padding: 0; }
.team-photo-box { width: 100%; height: auto; aspect-ratio: 3 / 4; overflow: hidden; }
.team-photo { width: 100%; height: 100%; object-fit: cover; object-position: top center; filter: grayscale(100%); transition: transform 0.5s ease, filter 0.5s ease; }
.team-card:hover .team-photo { filter: grayscale(0%); transform: scale(1.1); }
@media (max-width: 768px) { .team-photo { filter: grayscale(0%) !important; transform: scale(1) !important; } .team-card:hover .team-photo { transform: none; } }
.team-info { padding: 2rem; }
.team-info h4 { color: var(--color-accent); font-weight: 900; }
.team-info span { display: block; margin-bottom: 1rem; color: var(--color-text-medium); font-weight: 500; }
.team-info p { font-weight: 300; color: var(--color-text-light); }

/* 12. CONTACTO Y FOOTER */
.contact-section { background-color: var(--color-bg-darker); padding: 5rem 0; text-align: center; }
.contact-section h2 { color: var(--color-text-light); }
.contact-grid { display: grid; grid-template-columns: 1fr; gap: 2rem; margin: 3rem 0; }
@media (min-width: 768px) { .contact-grid { grid-template-columns: repeat(3, 1fr); } }
.contact-card {
    background-color: #1F2937; padding: 2rem; border-radius: 0 5px 5px 0;
    border-left: 4px solid var(--color-accent); text-align: left; display: flex; flex-direction: column; gap: 0.5rem;
}
.contact-icon { color: var(--color-accent); margin-bottom: 1rem; }
.contact-icon svg { width: 32px; height: 32px; }
.contact-card h4 { color: var(--color-text-light); font-weight: 700; margin-bottom: 0.5rem; }
.contact-card p { color: #9CA3AF; font-weight: 300; margin-bottom: 0.5rem; }
.contact-link { color: var(--color-accent); text-decoration: none; font-weight: 500; transition: color 0.3s ease; }
.contact-link:hover { color: var(--color-accent-hover); }
.cta-container { margin-top: 4rem; }
.btn-large { padding: 1rem 2.5rem; font-size: 1.2rem; }
footer { margin-bottom: 0 !important; padding-bottom: 0 !important; }
.footer-copyright { background-color: #030712; padding: 2rem 0; text-align: center; border-top: 1px solid #1F2937; }
.footer-copyright p { color: #6B7280; font-size: 0.9rem; margin: 0; }

/* 13. CONFIGURACIÓN MÓVIL (MENÚ TOGGLE Y BOTONES) */

/* Botón grande de Hero: OCULTO EN PC POR DEFECTO */
.btn-hero-mobile { display: none; }

@media (max-width: 768px) {
    /* MENÚ HAMBURGUESA */
    .nav-toggle { display: block; cursor: pointer; color: var(--color-text-light); background: transparent; border: none; font-size: 1.8rem; }
    
    .nav-links {
        position: absolute; top: 100%; left: 0; width: 100%;
        background-color: rgba(17, 24, 39, 0.95) !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        display: flex; flex-direction: column; align-items: center;
        padding: 0; gap: 1.5rem; box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.5);
        max-height: 0; overflow: hidden; opacity: 0; transform: translateY(-10px);
        transition: max-height 340ms cubic-bezier(.2,.8,.2,1), opacity 240ms ease, transform 300ms cubic-bezier(.2,.8,.2,1);
        pointer-events: none;
    }
    
    /* Estado Abierto */
    .nav-links.active { padding: 2rem 0; max-height: 800px; opacity: 1; transform: translateY(0); pointer-events: auto; }
    
    /* Estado Cerrando */
    .nav-links.closing { opacity: 0; transform: translateY(-10px); max-height: 0; pointer-events: none; }

    .nav-links li { margin-left: 0; width: 100%; text-align: center; }
    .nav-links a { font-size: 1.2rem; display: block; padding: 0.5rem 0; }

    /* --- AQUÍ ESTÁ EL CAMBIO PARA EL BOTÓN EN EL TOGGLE --- */
    /* Nos aseguramos de que el botón dentro del menú SEA VISIBLE */
    .nav-btn-item { display: block !important; margin-top: 1rem; width: 100%; }
    
    /* Le damos estilo al botón dentro del menú */
    .nav-btn-item a {
        background-color: var(--color-accent) !important; /* Fondo amarillo */
        color: var(--color-bg-darker) !important; /* Letra oscura */
        display: inline-block;
        width: 80%; /* Ancho bonito */
        padding: 10px;
        border-radius: 5px;
        font-weight: 800;
    }

    /* SI QUIERES EL BOTÓN GRANDE EN EL HERO TAMBIÉN, DÉJALO ASÍ. */
    .btn-hero-mobile {
        display: inline-flex;
        align-items: center; justify-content: center;
        margin-top: 2rem; width: 100%; padding: 15px;
        box-shadow: 0 4px 15px rgba(255, 183, 0, 0.521); font-size: 0.95rem;
    }
    
    /* Ajustes Texto Hero Móvil */
    .hero-logo { max-width: 60%; margin-bottom: 1rem; }
    .typography-script { font-size: 1.8rem; }
    .typography-block { font-size: 3rem; }
    .hero-subtitle-industrial { font-size: 1rem; margin-top: 1rem; }
    .hero-desc { font-size: 1rem; padding: 0 1rem; }
    
    /* Corrección de alineación izquierda en Hero */
    .hero-content { align-items: center; text-align: center; padding: 4rem 20px 0 20px; }
}

/* 14. ANIMACIONES */
@keyframes popIn { 0% { transform: scale(0.9); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
@keyframes slideUpFade { 0% { transform: translateY(30px); opacity: 0; } 100% { transform: translateY(0); opacity: 1; } }
.anim-pop { animation: popIn 0.8s cubic-bezier(0.25, 1, 0.5, 1) forwards; opacity: 0; }
.anim-slide-up { animation: slideUpFade 0.8s cubic-bezier(0.25, 1, 0.5, 1) forwards; opacity: 0; }
.reveal-up { opacity: 0; transform: translateY(30px); transition: all 0.8s cubic-bezier(0.5, 0, 0, 1); }
.reveal-scale { opacity: 0; transform: scale(0.9); transition: all 0.8s cubic-bezier(0.5, 0, 0, 1); }
.is-visible { opacity: 1 !important; transform: translateY(0) scale(1) !important; }
.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }
.delay-3 { animation-delay: 0.6s; }
.delay-4 { animation-delay: 0.8s; }
.delay-5 { animation-delay: 1s; }
.delay-100 { transition-delay: 0.1s; }
.delay-200 { transition-delay: 0.2s; }
.delay-300 { transition-delay: 0.3s; }
.delay-400 { transition-delay: 0.4s; }
.delay-500 { transition-delay: 0.5s; }