@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Outfit:wght@600;700;800&display=swap');

:root {
    --primary: #f59e0b;
    /* Default Orange */
    --primary-dark: #d97706;
    --primary-glow: rgba(245, 158, 11, 0.5);
    --secondary: #6366f1;
    --accent: #0ea5e9;
    --bg-main: #ffffff;
    --bg-alt: #f8fafc;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --text-white: #ffffff;
    --glass: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(255, 255, 255, 0.2);
    --card-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --card-shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body.theme-clima {
    --primary: #0ea5e9;
    /* Blue for Clima */
    --primary-dark: #0284c7;
    --primary-glow: rgba(14, 165, 233, 0.5);
    --accent: #f59e0b;
}

body.theme-repair {
    --primary: #3a9c51;
    /* Green from logo */
    --primary-dark: #2d7a3f;
    --primary-glow: rgba(58, 156, 81, 0.5);
    --accent: #2d7fb9;
    /* Blue from logo */
}

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

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

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0px);
    }
}

.animate-fade-in {
    animation: fadeInUp 0.8s ease forwards;
}

/* Navbar */
.navbar-custom {
    padding: 1.25rem 0;
    transition: var(--transition);
    background: transparent;
}

.navbar-custom.scrolled {
    background: var(--glass);
    backdrop-filter: blur(12px);
    padding: 0.75rem 0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.navbar-brand {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text-main) !important;
    font-family: 'Outfit', sans-serif;
}

.navbar-brand .brand-image-logo {
    display: none;
    height: 65px;
    transition: var(--transition);
}

.navbar-brand .brand-text-logo {
    display: inline-block;
    transition: var(--transition);
}

.navbar-custom.scrolled .navbar-brand .brand-text-logo {
    display: none;
}

.navbar-custom.scrolled .navbar-brand .brand-image-logo {
    display: block;
}

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

.nav-link {
    font-weight: 500;
    color: var(--text-main) !important;
    margin: 0 1rem;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition);
}

.nav-link:hover::after {
    width: 100%;
}

/* Hero Section */
.hero-section {
    position: relative;
    padding: 180px 0 100px;
    background: radial-gradient(circle at top right, rgba(14, 165, 233, 0.1), transparent),
        radial-gradient(circle at bottom left, rgba(99, 102, 241, 0.1), transparent);
    min-height: 90vh;
    display: flex;
    align-items: center;
}

.hero-content h1 {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--text-main) 0%, var(--primary) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;

}

.hero-description {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
    margin-bottom: 2.5rem;
}

.hero-logo-large {
    max-width: 380px;
    height: auto;
    margin-bottom: 1.5rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 991px) {
    .hero-logo-large {
        margin-left: auto;
        margin-right: auto;
        max-width: 300px;
    }
}

.btn-primary-custom {
    background: var(--primary);
    color: white;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    font-weight: 600;
    border: none;
    box-shadow: 0 10px 15px -3px var(--primary-glow);
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
}

.btn-primary-custom:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 25px -5px var(--primary-glow);
    color: white;
}

.hero-image-wrapper {
    position: relative;
}

.hero-image-wrapper img {
    width: 100%;
    border-radius: 30px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/* Services Section */
.services-section {
    padding: 100px 0;
    background: var(--bg-alt);
}

.section-header {
    margin-bottom: 60px;
}

.section-header span {
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 600;
    font-size: 0.875rem;
    display: block;
    margin-bottom: 0.5rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--text-main);
}

.service-card {
    background-color: var(--bg-main);
    background-size: cover;
    background-position: center;
    border-radius: 24px;
    padding: 2.5rem 2rem;
    height: 100%;
    min-height: 320px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    z-index: 1;
}

.service-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.1) 0%, rgba(15, 23, 42, 0.9) 100%);
    z-index: -1;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--card-shadow-hover);
}

.service-card:hover::before {
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.05) 0%, rgba(15, 23, 42, 0.95) 100%);
}

.service-icon {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    transition: var(--transition);
}

.service-card:hover .service-icon {
    background: var(--primary);
    color: white;
    transform: rotate(10deg);
    border-color: var(--primary);
}

.service-card h3 {
    margin-bottom: 1rem;
    font-size: 1.5rem;
    color: white !important;
}

.service-card p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
}

.card-link {
    color: var(--primary) !important;
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.card-link i {
    transition: var(--transition);
}

.service-card:hover .card-link i {
    transform: translateX(5px);
}

/* Features Section */
.features-section {
    padding: 100px 0;
}

.feature-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.feature-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: var(--secondary);
    color: white;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

/* Footer */
.footer-section {
    background: var(--text-main);
    color: #94a3b8;
    padding: 80px 0 40px;
}

.footer-brand {
    font-size: 2rem;
    font-weight: 800;
    color: white;
    margin-bottom: 1.5rem;
    display: block;
    text-decoration: none;
}

.footer-brand span {
    color: var(--primary);
}

.footer-section h4 {
    color: white;
    margin-bottom: 1.5rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: #94a3b8;
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary);
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    text-decoration: none;
}

.social-links a:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

.footer-bottom {
    margin-top: 60px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

/* Navbar Logo Zoom */
.navbar-brand img {
    height: 90px !important;
    transition: var(--transition);
}

.navbar-brand:hover img {
    transform: scale(1.1);
}

/* Mobile Menu Background */
@media (max-width: 991px) {
    .navbar-collapse {
        background: white;
        margin-top: 1rem;
        padding: 1.5rem;
        border-radius: 20px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
        border: 1px solid rgba(0, 0, 0, 0.05);
    }

    body.theme-clima .navbar-collapse {
        border-top: 3px solid var(--primary);
    }

    body.theme-repair .navbar-collapse {
        border-top: 3px solid var(--primary);
    }

    .nav-link {
        margin: 0.5rem 0 !important;
        padding: 0.5rem 1rem !important;
    }

    /* Centering Hero Buttons on Mobile/Tablet */
    .hero-content {
        text-align: center;
    }

    .hero-content .d-flex {
        justify-content: center !important;
    }

    .hero-description {
        margin-left: auto !important;
        margin-right: auto !important;
    }
}

/* High Resolution & General Responsiveness */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
}

@media (min-width: 2000px) {
    .container {
        max-width: 1600px;
    }

    h1 {
        font-size: 5.5rem !important;
    }

    .hero-description {
        font-size: 1.5rem;
        max-width: 800px;
    }
}

/* Spacing and Polish */
.hero-section {
    overflow: hidden;
}

.hero-image-wrapper {
    z-index: 2;
}

/* Brand Slider */
.brands-section {
    padding: 80px 0;
    background: white;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.slider-container {
    width: 100%;
    overflow: hidden;
    position: relative;
}

.slider-container::before,
.slider-container::after {
    content: '';
    position: absolute;
    top: 0;
    width: 150px;
    height: 100%;
    z-index: 2;
}

.slider-container::before {
    left: 0;
    background: linear-gradient(to right, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0) 100%);
}

.slider-container::after {
    right: 0;
    background: linear-gradient(to left, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0) 100%);
}

.slider-track {
    display: flex;
    width: calc(300px * 22);
    /* Width of all duplicated items (11 * 2) */
    animation: scrollSlider 40s linear infinite;
    align-items: center;
}

.slider-track:hover {
    animation-play-state: paused;
}

.brand-item {
    width: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 40px;
}

.brand-item img {
    max-width: 100%;
    max-height: 90px;
    object-fit: contain;
    transition: var(--transition);
}

.brand-item:hover img {
    transform: scale(1.1);
}

@keyframes scrollSlider {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc(-300px * 11));
    }
}

@media (max-width: 768px) {

    .slider-container::before,
    .slider-container::after {
        width: 50px;
    }

    .brand-item {
        width: 250px;
    }

    .slider-track {
        width: calc(250px * 22);
    }

    @keyframes scrollSlider {
        0% {
            transform: translateX(0);
        }

        100% {
            transform: translateX(calc(-250px * 11));
        }
    }
}

/* Float Animation for Badges */
@keyframes floatUp {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-15px);
    }

    100% {
        transform: translateY(0);
    }
}

.animate-float {
    animation: floatUp 4s ease-in-out infinite;
}

/* Contact Us Section */
.contact-us-section {
    padding: 80px 0;
    background: var(--bg-alt);
}

.map-container {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    height: 100%;
    min-height: 400px;
}

.contact-card {
    background: var(--bg-main);
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    border: 1px solid rgba(0, 0, 0, 0.02);
}

.contact-card:hover {
    transform: translateX(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.contact-icon-box {
    width: 60px;
    height: 60px;
    background: var(--primary);
    color: white;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
    box-shadow: 0 10px 20px var(--primary-glow);
}

/* Parallax CTA Section */
.cta-parallax-section {
    position: relative;
    padding: 120px 0;
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    color: white;
    text-align: center;
    margin: 60px 0;
}

.cta-parallax-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.85);
    /* Deep dark overlay matching theme */
    z-index: 1;
}

.cta-parallax-section .container {
    position: relative;
    z-index: 2;
}

.cta-parallax-section .logo-parallax {
    max-width: 380px;
    height: auto;
    margin-bottom: 2rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.cta-parallax-section h2 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: white;
}

.cta-parallax-section p {
    font-size: 1.4rem;
    max-width: 800px;
    margin: 0 auto 2.5rem;
    opacity: 0.9;
    line-height: 1.8;
}

@media (max-width: 768px) {
    .cta-parallax-section {
        padding: 80px 0;
        background-attachment: scroll;
        /* Better performance on mobile */
    }

    .cta-parallax-section h2 {
        font-size: 2rem;
    }

    .cta-parallax-section p {
        font-size: 1.1rem;
    }
}

/* White variation for Clima theme */
body.theme-clima .cta-parallax-section::before {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.5) 100%);
}

body.theme-clima .cta-parallax-section h2 {
    color: var(--text-main);
}

body.theme-clima .cta-parallax-section p {
    color: var(--text-muted);
    opacity: 1;
}

body.theme-clima .cta-parallax-section .btn-primary-custom {
    box-shadow: 0 10px 20px rgba(14, 165, 233, 0.3);
}

/* WhatsApp Floating Button */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 60px;
    height: 60px;
    background-color: #25d366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    box-shadow: 0 10px 25px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    text-decoration: none;
    transition: var(--transition);
    animation: floatUp 4s ease-in-out infinite;
}

.whatsapp-float:hover {
    background-color: #128c7e;
    color: white;
    transform: scale(1.1);
    box-shadow: 0 15px 30px rgba(37, 211, 102, 0.6);
}

@media (max-width: 768px) {
    .whatsapp-float {
        width: 50px;
        height: 50px;
        font-size: 25px;
        bottom: 20px;
        left: 20px;
    }
}