
:root {
    --primary: #0f172a; /* Navy */
    --primary-light: #1e293b;
    --accent: #fb923c; /* Safety Orange */
    --accent-hover: #f97316;
    --text-main: #f8fafc;
    --text-muted: #cbd5e1; /* Increased contrast for accessibility */
    --bg-main: #0f172a;
    --bg-secondary: #1e293b;
    --bg-neutral: #e2e8f0; /* Bone White/Gray */
    --glass: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-heading: 'Roboto', sans-serif;
    --font-body: 'Roboto', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

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

body {
    font-family: var(--font-body);
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

.mono {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

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

section {
    padding: 100px 0;
}

/* --- Navigation --- */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    transition: var(--transition);
}

nav.scrolled {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    border-bottom: 1px solid var(--glass-border);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    z-index: 1001;
}

.logo span {
    color: var(--accent);
}

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

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

.nav-cta {
    display: flex;
    align-items: center;
    gap: 1rem;
    z-index: 1001;
}

.phone-link {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    transition: var(--transition);
}

.phone-link:hover {
    background: var(--accent);
    color: var(--primary);
    transform: scale(1.1);
}

/* Hamburger Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    z-index: 1001;
    padding: 5px;
}

.menu-toggle span {
    width: 25px;
    height: 2px;
    background: var(--text-main);
    transition: var(--transition);
}

/* Mobile Overlay Menu */
.nav-menu-mobile {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background: var(--primary);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2.5rem;
    transition: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
}

.nav-menu-mobile.active {
    right: 0;
}

.nav-menu-mobile a {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-main);
}

/* --- Hero Section --- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, var(--bg-main) 40%, transparent 100%);
    z-index: 1;
}

.hero-video {
    position: absolute;
    right: 0;
    top: 0;
    width: 60%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 700px;
}

.badge {
    display: inline-block;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.hero h1 {
    font-size: clamp(2.2rem, 8vw, 4rem);
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero p {
    font-size: clamp(1rem, 4vw, 1.25rem);
    color: var(--text-muted);
    margin-bottom: 2.5rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    transition: var(--transition);
    cursor: pointer;
}

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

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

/* --- Services --- */
.section-title {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.section-title p {
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

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

.service-card {
    background: var(--bg-secondary);
    padding: 2.5rem;
    border-radius: 16px;
    border: 1px solid var(--glass-border);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--accent);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--accent);
    margin-bottom: 1.5rem;
}

.service-card h3 {
    margin-bottom: 1rem;
}

.service-card p {
    color: var(--text-muted);
}

/* --- Authority Section --- */
.authority {
    background: var(--bg-secondary);
}

.authority-content {
    display: flex;
    align-items: center;
    gap: 4rem;
}

.authority-text {
    flex: 1;
}

.authority-image {
    flex: 1;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--glass-border);
}

.authority-image img {
    width: 100%;
    display: block;
}

.check-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.check-icon {
    color: var(--accent);
    flex-shrink: 0;
}

/* --- Footer --- */
footer {
    padding: 80px 0 40px;
    border-top: 1px solid var(--glass-border);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-info h4 {
    margin-bottom: 1.5rem;
}

.footer-info p {
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--glass-border);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* --- WhatsApp Button --- */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #25d366;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transition: var(--transition);
    overflow: hidden; /* Corta excesos si el logo es cuadrado */
}

.whatsapp-float img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Cambiado a cover para que llene el círculo si es el logo redondo */
}

.whatsapp-float:hover {
    transform: scale(1.1);
}

/* --- Pain Point Section --- */
.pain-point {
    background: #450a0a; /* Dark Red/Deep Safety */
    padding: 80px 0;
}

.pain-point h2 {
    color: #fecaca;
    margin-bottom: 2rem;
}

.pain-point p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.pain-point .warning-box {
    border-left: 4px solid var(--accent);
    padding: 1.5rem;
    background: rgba(251, 146, 60, 0.1);
    margin: 2rem 0;
}

/* --- Form Styles --- */
.contact-form {
    background: var(--bg-secondary);
    padding: 3rem;
    border-radius: 16px;
    border: 1px solid var(--glass-border);
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--primary);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: var(--text-main);
    font-family: var(--font-body);
}

.form-control:focus {
    outline: none;
    border-color: var(--accent);
}

/* --- Footer Identity --- */
.footer-logo {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-logo span {
    color: var(--accent);
}

.validations {
    display: flex;
    gap: 2rem;
    align-items: center;
    margin-top: 2rem;
    opacity: 0.7;
}

.validations img {
    height: 35px;
    width: auto;
    transition: var(--transition);
}

.validations img:hover {
    transform: scale(1.1);
}

/* --- Animations --- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* --- Emergency Modal --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--bg-secondary);
    padding: 3rem;
    border-radius: 20px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    position: relative;
    border: 1px solid var(--accent);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    transition: var(--transition);
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1.5rem;
}

.emergency-icon {
    font-size: 3rem;
    color: #ef4444; /* Emergency Red */
    margin-bottom: 1rem;
}

.modal-body h2 {
    margin-bottom: 1rem;
}

.modal-body p {
    color: var(--text-muted);
    margin-bottom: 2rem;
}

/* --- Responsiveness --- */
@media (max-width: 1024px) {
    .nav-links {
        display: none;
    }
    
    .menu-toggle {
        display: flex;
    }
    
    .hero::after {
        background: radial-gradient(circle at 30% 30%, rgba(15, 23, 42, 0.8) 0%, rgba(15, 23, 42, 0.4) 100%);
    }
    
    .hero-video {
        width: 100%;
        opacity: 0.8;
    }
    
    .hero-content {
        text-align: center;
        margin: 0 auto;
        padding: 0 1rem;
    }

    .hero h1 {
        text-shadow: 0 4px 20px rgba(0, 0, 0, 0.9);
    }
    
    .hero-btns {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    section {
        padding: 60px 0;
    }
    
    .container {
        padding: 0 1.5rem;
    }

    .logo {
        display: flex;
        flex-direction: column;
        line-height: 1;
        font-size: 1rem;
    }

    .logo span {
        font-size: 1.1rem;
        margin-top: 1px;
    }

    .nav-cta {
        gap: 0.5rem;
    }

    .nav-cta .btn-primary {
        padding: 0.4rem 0.6rem !important;
        font-size: 0.65rem !important;
    }

    .phone-link {
        width: 32px;
        height: 32px;
    }
    
    .section-title h2 {
        font-size: 2rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .authority-content {
        flex-direction: column;
        gap: 2rem;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        text-align: center;
    }
    
    .validations {
        justify-content: center;
    }
    
    .contact-form {
        padding: 2rem 1.5rem;
    }

    .menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 6px);
    }
    
    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -6px);
    }
    
    .modal-content {
        padding: 2rem 1.5rem;
    }
}
