@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap");

:root {
    --primary: #c72f2f;
    --dark: #111827;
    --light: #f9fafb;
    --gray: #6b7280;

    --body-font: 'Poppins', sans-serif;
    --biggest-font-size: 2.5rem;
    --h1-font-size: 1.5rem;
    --h2-font-size: 1.25rem;
    --h3-font-size: 1.125rem;
    --normal-font-size: .938rem;
    --small-font-size: .813rem;
    --smaller-font-size: .75rem;

    --font-medium: 500;
    --font-semi-bold: 600;
    --font-bold: 700;
}

@media screen and (min-width: 768px) {
    :root {
        --biggest-font-size: 4.5rem;
        --h1-font-size: 3rem;
        --h2-font-size: 1.5rem;
        --h3-font-size: 1.25rem;
        --normal-font-size: 1rem;
        --small-font-size: .875rem;
        --smaller-font-size: .813rem;
    }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

html, body {
    overflow-x: hidden;
}

body {
    font-family: var(--body-font);
    font-size: var(--normal-font-size);
    font-weight: var(--font-medium);
}

section {
    padding: 120px 10%;
    position: relative;
}

h2 {
    text-align: center;
    margin-bottom: 20px;
    font-size: var(--h2-font-size);
    font-weight: var(--font-semi-bold);
}

body.no-scroll {
    overflow: hidden;
}

.no-scroll .whatsapp-float {
    display: none;
}

/* NAVBAR */
.navbar {
    position: fixed;
    width: 100%;
    top: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 10%;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    border-bottom: 1px solid rgba(0,0,0,0.04);
    z-index: 1000;
    transition: all 0.3s ease;
}

.nav-links a {
    position: relative;
    text-decoration: none;
    color: var(--dark);
    margin-left: 40px;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:not(.menu-toggle)::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -6px;
    width: 0%;
    height: 2px;
    background: var(--primary);
    transition: width 0.35s ease;
}

.nav-links a:hover {
    color: var(--primary);
}

.nav-links a:hover::after {
    width: 100%;
}

.logo {
    height: 40px;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    z-index: 1100;
}

.menu-toggle span {
    width: 26px;
    height: 2px;
    background: var(--dark);
    transition: all 0.3s ease;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* HERO */
.hero {
    height: 100vh;
    padding: 0;
    position: relative;
}

.hero-grid {
    height: 100%;
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-rows: 1fr 1fr;
}

.hero-main {
    grid-row: 1 / 3;
}

.hero-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    
    background: rgba(0, 0, 0, 0.795);
    padding: 40px;
    border-radius: 10px;

    text-align: center;
    color: white;
    z-index: 2;
}

.mobile-break {
    display: none;
}

.hero h1 {
    font-size: var(--h1-font-size);
    margin-bottom: 20px;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.btn {
    padding: 12px 25px;
    text-decoration: none;
    font-weight: 600;
    border-radius: 5px;
    transition: 0.3s;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: #861717;
}

.btn-outline {
    border: 2px solid white;
    color: white;
}

.btn-outline:hover {
    background: white;
    color: var(--dark);
}

/* NOSOTROS */
.about-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.about-container img {
    width: 100%;
    height: 520px;
    object-fit: cover;
    border-radius: 14px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.about-container img:hover {
    transform: scale(1.03);
    box-shadow: 0 25px 50px rgba(0,0,0,0.12);
}

.about-text {
    width: 100%;
    padding-left: 25px;
    border-left: 3px solid var(--primary);
}

.about-text p {
    margin-bottom: 30px;
    line-height: 1.8;
}

.metrics {
    display: flex;
    gap: 35px;
    margin-top: 30px;
}

.metric {
    position: relative;
    padding-top: 10px;
}

.metric h3 {
    color: var(--primary);
    font-size: 2.6rem;
    font-weight: var(--font-bold);
    line-height: 1;
}

.metric p {
    color: var(--gray);
    font-size: var(--small-font-size);
    margin-top: 8px;
    letter-spacing: 0.3px;
}

.client-types{
    margin-top:40px;
}

.client-types h3{
    font-size:1rem;
    margin-bottom:15px;
    font-weight:var(--font-semi-bold);
}

.client-tags{
    display:flex;
    flex-wrap:wrap;
    gap:10px;
}

.client-tags span{
    background:#f3f4f6;
    padding:6px 14px;
    border-radius:20px;
    font-size:0.8rem;
    color:var(--dark);
    border:1px solid #e5e7eb;
}

/* SERVICIOS */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 30px;
}

.service-card {
    background: white;
    padding: 25px;
    text-align: center;
    border-radius: 10px;
    border: 1px solid rgba(0,0,0,0.05);
    box-shadow: 0 6px 16px rgba(0,0,0,0.05);
    transition: all .3s ease;
}

.service-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(0,0,0,0.12);
}

.service-card i {
    font-size: 42px;
    color: var(--dark);
    margin-bottom: 18px;
    transition: 0.3s ease;
}

.service-card:hover i {
    color: var(--primary);
}

.service-card h3 {
    font-size: 1rem;
    font-weight: var(--font-semi-bold);
    margin-bottom: 12px;
}

.service-card p {
    font-size: 0.82rem;
    color: var(--gray);
    line-height: 1.6;
}

/* CONTACTO */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
}

.contact-card {
    background: var(--primary);
    color: white;
    padding: 18px 16px;
    width: 100%;
    text-align: center;
    border-radius: 10px;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 10px 24px rgba(0,0,0,0.12);
    position: relative;
}

.contact-card p {
    font-weight: var(--font-semi-bold);
    font-size: 0.85rem;
    margin: 0;
    word-break: break-word;
    text-align: center;
}

.contact-card i {
    font-size: 30px;
    color: rgba(255, 255, 255, 0.85);
    transition: color 0.25s ease, transform 0.25s ease;
}

.link-card {
    cursor: pointer;
}

.link-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 42px rgba(0,0,0,0.18);
}

.contact-card:hover > i:not(.link-arrow),
.contact-card:hover .phone-icons i {
    color: #ffffff;
    transform: scale(1.08);
}

.contact-card .link-arrow {
    font-size: 18px;
    position: absolute;
    right: 14px;
    bottom: 14px;
    color: rgba(255,255,255,0.65);
    opacity: 0;
    transform: translateY(6px);
    transition: all 0.3s ease;
    pointer-events: none;
}

.contact-card:hover .link-arrow {
    opacity: 1;
    transform: translateY(0);
    color: #ffffff;
}

.phone-icons {
    display: flex;
    gap: 10px;
}

.phone-label {
    font-size: 0.65rem;
    opacity: 0.85;
    margin-top: -4px;
    letter-spacing: 0.3px;
}

.contact-footer {
    margin-top: 40px;
    display: flex;
    justify-content: center;
}

.contact-location {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    border-radius: 999px;
    background: rgba(0,0,0,0.04);
    border: 1px solid rgba(0,0,0,0.06);
    transition: all 0.3s ease;
    box-shadow: 0 6px 16px rgba(0,0,0,0.08);
}

.contact-location i {
    font-size: 20px;
    color: var(--primary);
    transition: transform 0.3s ease;
}

.location-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.location-title {
    font-size: 0.7rem;
    color: var(--gray);
    letter-spacing: 0.5px;
}

.location-sub {
    font-size: 0.85rem;
    font-weight: var(--font-semi-bold);
    color: var(--dark);
}

.contact-location:hover {
    transform: translateY(-2px);
    background: rgba(0,0,0,0.06);
}

.contact-location:hover i {
    transform: scale(1.1);
}

/* Separador de secciones */
.section-alt {
    background: #f3f4f6;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-subtitle {
    font-size: var(--small-font-size);
    color: var(--gray);
    margin-top: 10px;
}

.section-header h2::after {
    content: "";
    display: block;
    width: 60px;
    height: 3px;
    background: var(--primary);
    margin: 15px auto 0;
}

/* Boton flotante de WhatsApp */
.whatsapp-float {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 65px;
    height: 65px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    z-index: 9999;
    transition: 0.3s ease;
    text-decoration: none;
}

.whatsapp-float:link,
.whatsapp-float:visited {
    color: white;
}

.whatsapp-float i {
    font-size: 34px;
    color: white;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 25px rgba(0,0,0,0.35);
}

.whatsapp-float:hover i {
    transform: scale(1.05);
}

/* FOOTER */
.footer {
    background: var(--dark);
    color: white;
    text-align: center;
    padding: 30px 10%;
}

/*RESPONSIVE*/
@media (max-width: 480px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1024px) {
    .contact-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {

    section {
        padding: 100px 6%;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        grid-template-rows: 1fr 200px 200px;
    }

    .hero-main {
        grid-row: auto;
    }

    .hero-content {
        width: calc(100% - 30px);
        max-width: none;
        padding: 30px 20px;
        left: 50%;
        transform: translate(-50%, -50%);
    }

    .mobile-break {
        display: block;
    }

    .navbar {
        padding: 16px 6%;
    }

    .nav-top {
        width: 100%;
        display: flex;
        justify-content: space-between;
        align-items: center;
        position: relative;
        z-index: 1100;
    }

    .menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        left: 0;

        width: 100vw;
        height: 100vh;

        background: white;

        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;

        gap: 40px;

        transform: translateY(-100%);
        transition: transform 0.4s ease;
        background: rgba(255,255,255,0.98);
        backdrop-filter: blur(10px);
    }

    .nav-links a {
        font-size: 1.4rem;
        margin-left: 0;
    }

    .nav-links.active {
        transform: translateY(0);
    }


    .hero-buttons {
        flex-direction: column;
    }

    .about-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }

    .about-container img {
        height: 400px;
    }

    .about-text {
        padding-left: 0;
        border-left: none;
    }

    .metrics {
        justify-content: center;
        flex-wrap: wrap;
        gap: 30px;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 1024px) {
    .about-container {
        grid-template-columns: 1fr 1fr;
        gap: 70px;
    }
}

/* Animaciones de scroll */
.hero-content {
    opacity: 0;
    transform: translate(-50%, calc(-50% + 40px)) scale(0.96);

    transition:
        opacity 1s ease,
        transform 1s ease;
}

.hero-content.visible {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.hero-buttons {
    opacity: 0;
    transform: translateY(20px);

    transition:
        opacity .9s ease .4s,
        transform .9s ease .4s;
}

.hero-content.visible .hero-buttons {
    opacity: 1;
    transform: translateY(0);
}

.hero-content h1 {
    opacity: 0;
    transform: translateY(20px);

    transition:
        opacity .9s ease .2s,
        transform .9s ease .2s;
}

.hero-content.visible h1 {
    opacity: 1;
    transform: translateY(0);
}

.services-grid > .reveal,
.contact-grid > .reveal {
    height: 100%;
}

.services-grid > .reveal > .service-card,
.contact-grid > .reveal > .contact-card {
    height: 100%;
}

.service-card,
.contact-card,
.contact-location,
.about-container img {
    transform-origin: center;
}

.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all .8s ease;
}

.reveal.visible {
    opacity: 1;
    transform: none;
}

.reveal-left {
    --reveal-transform: translateX(-60px);
}

.reveal-right {
    --reveal-transform: translateX(60px);
}

.reveal-up {
    --reveal-transform: translateY(40px);
}

.reveal-scale {
    --reveal-transform: scale(0.9);
}

.service-card:nth-child(1) { transition-delay: .1s; }
.service-card:nth-child(2) { transition-delay: .2s; }
.service-card:nth-child(3) { transition-delay: .3s; }
.service-card:nth-child(4) { transition-delay: .4s; }

.contact-card:nth-child(1) { transition-delay: .1s; }
.contact-card:nth-child(2) { transition-delay: .2s; }
.contact-card:nth-child(3) { transition-delay: .3s; }
.contact-card:nth-child(4) { transition-delay: .4s; }

.metric:nth-child(1) { transition-delay: .1s; }
.metric:nth-child(2) { transition-delay: .2s; }
.metric:nth-child(3) { transition-delay: .3s; }

@media (hover: hover) {
    .contact-card:hover .link-arrow {
        opacity: 1;
        transform: translateY(0);
        color: #ffffff;
    }
}

@media (hover: none) {
    .contact-card .link-arrow {
        opacity: 1;
        transform: translateY(0);
        color: #ffffff;
    }
}
