/* Reset & Base Styles */
:root {
    --primary-dark: #101B2C;
    --secondary-dark: #1E2E4A;
    --accent-blue: #006397;
    --light-gray: #BEC5D5;
    --bg-light: #E8E6E5;
    --text-dark: #0f172a;
    --text-light: #f8fafc;
    --font-heading: 'Barlow', sans-serif;
    --font-body: 'Inter', sans-serif;
    --transition-speed: 0.3s;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-light);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: var(--accent-blue);
    transition: color var(--transition-speed) ease;
}

p {
    margin-bottom: 1rem;
}

.text-accent {
    color: var(--accent-blue);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.text-center {
    text-align: center;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1.1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    border: 2px solid transparent;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-primary {
    background-color: var(--accent-blue);
    color: var(--text-light);
}

.btn-primary:hover:not(:disabled) {
    background-color: #004d7a;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 99, 151, 0.3);
}

.btn-outline {
    background-color: transparent;
    color: var(--text-light);
    border-color: var(--text-light);
}

.btn-outline:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.btn-sm {
    padding: 0.4rem 1rem;
    font-size: 1rem;
}

.btn-block {
    display: flex;
    width: 100%;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(16, 27, 44, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all var(--transition-speed) ease;
}

.navbar.scrolled {
    background-color: rgba(16, 27, 44, 0.85); /* Se vuelve un poco más transparente */
    backdrop-filter: blur(15px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
    border-bottom-color: transparent;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 150px; /* Gigante en escritorio */
    transition: height var(--transition-speed) ease;
}

.navbar.scrolled .nav-container {
    height: 80px; /* Se achica rápidamente al scrollear para dar espacio a la lectura */
}

.logo a {
    display: flex;
    align-items: center;
}

.nav-logo {
    max-height: 130px; /* Logo muchísimo más grande en escritorio */
    width: auto;
    max-width: 450px; /* Ancho máximo extendido */
    filter: brightness(0) invert(1);
    transition: max-height var(--transition-speed) ease;
}

.navbar.scrolled .nav-logo {
    max-height: 55px; /* Se escala hacia abajo armónicamente */
}

.logo-text {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--accent-blue);
    letter-spacing: -0.5px;
}

.logo-text span {
    color: var(--text-light);
    font-weight: 600;
    font-size: 1.2rem;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-light);
    font-weight: 600;
    font-size: 1.1rem;
}

.nav-links a:hover {
    color: var(--accent-blue);
}

.nav-contact {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-phone {
    color: var(--text-light);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 2rem;
    cursor: pointer;
}

/* Hero Section */
@keyframes pulseGlow {
    0% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 0.8; }
    100% { transform: scale(1); opacity: 0.5; }
}

@keyframes floatElement {
    0% { transform: translateY(0) translateX(0); }
    33% { transform: translateY(-15px) translateX(10px); }
    66% { transform: translateY(10px) translateX(-10px); }
    100% { transform: translateY(0) translateX(0); }
}

.hero {
    position: relative;
    min-height: 90vh; /* changed slightly to balance content */
    display: flex;
    align-items: center;
    background-color: var(--primary-dark);
    background-image: radial-gradient(circle at 80% 50%, rgba(0, 99, 151, 0.4) 0%, transparent 60%);
    color: var(--text-light);
    padding-top: 150px;
    padding-bottom: 50px;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: url('data:image/svg+xml;utf8,<svg width="60" height="60" xmlns="http://www.w3.org/2000/svg"><circle cx="4" cy="4" r="3.5" fill="rgba(255,255,255,0.08)"/></svg>') repeat;
    animation: floatElement 20s infinite ease-in-out;
    pointer-events: none;
}

/* Pseudo element for additional glow/dynamic feel */
.hero::after {
    content: '';
    position: absolute;
    top: 10%; right: 10%;
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(0,99,151,0.6) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulseGlow 8s infinite alternate ease-in-out;
    pointer-events: none;
    z-index: 1;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr; /* Mucho más protagonismo visual a la foto */
    gap: 3rem;
    align-items: center;
    position: relative;
    z-index: 2;
    width: 100%;
}

.hero-content {
    position: relative;
}

.hero-image-wrapper {
    position: relative;
    width: 100%;
}

.hero-image {
    width: 100%;
    min-height: 450px; /* Asegura un tamaño de gran escala en escritorio */
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    object-fit: cover;
    display: block;
}

.pre-header {
    display: inline-block;
    color: var(--accent-blue);
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    border-left: 3px solid var(--accent-blue);
    padding-left: 10px;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.25rem;
    color: var(--light-gray);
    margin-bottom: 2.5rem;
    max-width: 700px;
}

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

/* Propuesta de Valor */
.propuesta {
    padding: 6rem 0;
    background-color: var(--bg-light);
    text-align: center;
}

.propuesta-content {
    max-width: 900px;
    margin: 0 auto;
}

.propuesta h2 {
    font-size: 2.5rem;
    color: var(--primary-dark);
    margin-bottom: 2rem;
}

.lead-text {
    font-size: 1.25rem;
    color: var(--primary-dark);
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.propuesta p:not(.lead-text) {
    font-size: 1.1rem;
    color: #475569;
    margin-bottom: 3rem;
}

.quote-block {
    background-color: var(--primary-dark);
    padding: 2rem;
    border-radius: 8px;
    border-left: 6px solid var(--accent-blue);
    box-shadow: 0 10px 30px rgba(16, 27, 44, 0.1);
}

.quote-block blockquote {
    color: var(--text-light);
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-style: italic;
    font-weight: 600;
}

/* Servicios List Grid */
.servicios {
    padding: 6rem 0;
    background-color: #ffffff;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

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

.section-header p {
    font-size: 1.2rem;
    color: #64748b;
}

.services-list-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

.service-item {
    display: flex;
    align-items: center;
    background: var(--bg-light);
    padding: 1.25rem;
    border-radius: 6px;
    border-left: 4px solid var(--accent-blue);
    transition: all var(--transition-speed) ease;
}

.service-item:hover {
    transform: translateX(10px);
    background-color: #f1f5f9;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.service-item i {
    font-size: 2rem;
    margin-right: 1.5rem;
    min-width: 40px;
    text-align: center;
}

.service-item span {
    font-size: 1.05rem;
    color: var(--primary-dark);
    font-weight: 500;
}

/* Metodología */
.metodologia {
    padding: 6rem 0;
    background-color: var(--bg-light);
    background-image: url('circuito.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    overflow: hidden;
}

.metodologia::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(232, 230, 229, 0.7); /* Superpone el color de fondo para que el texto siga siendo legible */
    z-index: 0;
}

.metodologia .container {
    position: relative;
    z-index: 1;
}

.timeline {
    display: flex;
    justify-content: space-between;
    position: relative;
    max-width: 1000px;
    margin: 4rem auto 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 25px;
    left: 50px;
    right: 50px;
    height: 2px;
    background-color: var(--light-gray);
    z-index: 1;
}

.timeline-step {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 22%;
}

.step-marker {
    width: 50px;
    height: 50px;
    background-color: var(--primary-dark);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0 auto 1.5rem auto;
    border: 4px solid var(--bg-light);
    box-shadow: 0 0 0 2px var(--accent-blue);
    transition: transform 0.3s ease;
}

.timeline-step:hover .step-marker {
    transform: scale(1.1);
    background-color: var(--accent-blue);
}

.timeline-step h4 {
    color: var(--primary-dark);
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.timeline-step p {
    color: #64748b;
    font-size: 0.9rem;
}

/* Por Qué ISC / Quiénes Somos */
.empresa {
    padding: 6rem 0;
    background-color: var(--primary-dark);
    background-image: url('fibra-hq.png');
    background-size: cover;
    background-position: center bottom;
    background-repeat: no-repeat;
    color: var(--text-light);
    position: relative;
    z-index: 1;
}

.empresa::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(180deg, rgba(16, 27, 44, 0.95) 0%, rgba(16, 27, 44, 0.7) 100%);
    z-index: -1;
}

.empresa .container.empresa-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.empresa-text h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.empresa-text p {
    color: var(--light-gray);
    font-size: 1.15rem;
}

.empresa-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.stat-item {
    background-color: rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--accent-blue);
    transition: background-color var(--transition-speed);
}

.stat-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.stat-item i {
    font-size: 2.5rem;
    color: var(--accent-blue);
    margin-bottom: 1rem;
    display: block;
}

.stat-content strong {
    display: block;
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.stat-content span {
    font-size: 0.9rem;
    color: var(--light-gray);
    display: block;
}

/* Contacto */
.contacto {
    padding: 6rem 0;
    background-color: #fff;
    overflow: hidden;
}

.contacto-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contacto-info h2 {
    font-size: 2.5rem;
    color: var(--primary-dark);
    margin-bottom: 1.5rem;
}

.contacto-info p {
    color: #475569;
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-link, .contact-link.static {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1.1rem;
    color: var(--primary-dark);
    font-weight: 600;
}

.contact-link i, .contact-link.static i {
    font-size: 1.5rem;
    color: var(--accent-blue);
}

.contact-link:hover {
    color: var(--accent-blue);
}

/* Contact Form */
.contacto-form-wrapper {
    background-color: var(--bg-light);
    padding: 3rem;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.05);
}

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

.b2b-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.b2b-form label {
    display: block;
    font-weight: 600;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.b2b-form input,
.b2b-form select,
.b2b-form textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--text-dark);
    background-color: #fff;
    transition: border-color var(--transition-speed);
}

.b2b-form input:focus,
.b2b-form select:focus,
.b2b-form textarea:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 3px rgba(0, 99, 151, 0.1);
}

.form-legal {
    display: block;
    text-align: center;
    margin-top: 1rem;
    color: #64748b;
    font-size: 0.85rem;
}

.form-legal i {
    vertical-align: middle;
}

/* Footer */
.site-footer {
    background-color: var(--primary-dark);
    color: var(--light-gray);
    padding: 4rem 0 2rem 0;
    border-top: 4px solid var(--accent-blue);
}

.footer-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1.5fr;
    gap: 3rem;
    margin-bottom: 4rem;
}

.footer-brand p {
    margin-top: 1rem;
    font-size: 0.95rem;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-links a {
    color: var(--light-gray);
}

.footer-links a:hover {
    color: #fff;
}

.footer-contact p {
    margin-bottom: 0.5rem;
}

.footer-contact a {
    color: var(--light-gray);
}

.footer-contact a:hover {
    color: #fff;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
}

/* WhatsApp Float Button */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 30px;
    right: 30px;
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
    color: #FFF;
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0px 6px 18px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    text-decoration: none;
}

.whatsapp-float:hover {
    transform: scale(1.1) translateY(-5px);
    box-shadow: 0px 8px 25px rgba(37, 211, 102, 0.6);
}

/* Responsive */
@media (max-width: 992px) {
    .empresa .container.empresa-grid,
    .contacto-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .timeline {
        flex-direction: column;
        gap: 2rem;
        max-width: 300px;
        margin: 0 auto;
    }
    
    .timeline::before {
        top: 0;
        bottom: 0;
        left: 25px;
        width: 2px;
        height: auto;
    }
    
    .timeline-step {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
        padding-left: 70px;
        background: transparent;
    }
    
    .step-marker {
        position: absolute;
        left: 0;
        top: 0;
        margin: 0;
    }
}

@media (max-width: 768px) {
    .nav-container {
        height: 100px;
    }
    
    .nav-logo {
        max-height: 75px; 
        max-width: 250px;
    }
    
    .hero {
        padding-top: 100px;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .hero-image-wrapper {
        display: none;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    
    .hero-actions {
        flex-direction: column;
    }
    
    .nav-links, .nav-contact {
        display: none;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .b2b-form .form-row {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .propuesta h2 {
        font-size: 2rem;
    }
    
    .services-list-grid {
        grid-template-columns: 1fr;
    }

    .whatsapp-float {
        width: 55px;
        height: 55px;
        bottom: 20px;
        right: 20px;
    }
}

/* ============================================================
   GATE DE CONSTRUCCIÓN — ELIMINAR ESTE BLOQUE COMPLETO
   CUANDO LA PÁGINA ESTÉ LISTA PARA PRODUCCIÓN.
   ============================================================ */

/* Contenedor principal del gate - cubre toda la pantalla */
.construction-gate {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

/* Cuando se autentica, ocultamos con esta clase */
.construction-gate.gate-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Fondo oscuro con blur */
.construction-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(16, 27, 44, 0.97) 0%, rgba(30, 46, 74, 0.95) 100%);
    backdrop-filter: blur(20px);
}

/* Contenido central del gate */
.construction-content {
    position: relative;
    z-index: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 3rem 2.5rem;
    max-width: 440px;
    width: 90%;
    text-align: center;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
    animation: gateSlideIn 0.6s ease-out;
}

@keyframes gateSlideIn {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Logo dentro del gate */
.construction-logo {
    margin-bottom: 1.5rem;
}

.construction-logo-img {
    max-height: 60px;
    width: auto;
    filter: brightness(0) invert(1);
}

/* Icono de construcción animado */
.construction-icon {
    margin-bottom: 1rem;
}

.construction-icon i {
    font-size: 3.5rem;
    color: var(--accent-blue);
    animation: constructionPulse 2s infinite ease-in-out;
}

@keyframes constructionPulse {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.1); opacity: 1; }
}

/* Título y subtítulo */
.construction-title {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: #fff;
    margin-bottom: 0.75rem;
}

.construction-subtitle {
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--light-gray);
    margin-bottom: 2rem;
    line-height: 1.5;
}

/* Formulario de login del gate */
.gate-form {
    text-align: left;
}

.gate-form-group {
    margin-bottom: 1.25rem;
}

.gate-form-group label {
    display: block;
    color: var(--light-gray);
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.4rem;
}

.gate-form-group label i {
    color: var(--accent-blue);
    margin-right: 0.3rem;
}

.gate-form-group input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.gate-form-group input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.gate-form-group input:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 3px rgba(0, 99, 151, 0.25);
}

/* Mensaje de error */
.gate-error {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
    padding: 0.6rem 1rem;
    border-radius: 6px;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    text-align: center;
    animation: gateShake 0.4s ease;
}

@keyframes gateShake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-8px); }
    75% { transform: translateX(8px); }
}

/* Botón de acceso */
.gate-btn {
    margin-top: 0.5rem;
    padding: 0.85rem 1.5rem;
    font-size: 1.05rem;
    border-radius: 6px;
}

/* Info de contacto al pie del gate */
.construction-contact {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.construction-contact p {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.85rem;
    margin: 0;
}

.construction-contact i {
    color: var(--accent-blue);
    vertical-align: middle;
}

/* FIN GATE DE CONSTRUCCIÓN */
