:root {
    /* Paleta de marca: azules del logo + verde corporativo */
    --blue-brand-900: #0f2942;
    --blue-brand-700: #0053a5;
    --blue-brand-500: #1b6fc9;
    --blue-brand-300: #345681;
    --blue-brand-100: #eaf2fb;
    --green-brand-600: #76b82a;
    --green-brand-500: #8ac53f;
    --green-brand-100: #edf7e1;
    --text-main: #24364a;
    --text-soft: #566478;
    --white: #ffffff;
    --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);
    --site-header-height: 78px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--site-header-height);
    overflow-x: hidden;
}

body {
    margin: 0;
    padding-top: var(--site-header-height);
    font-family: "Montserrat", Arial, sans-serif;
    color: var(--text-main);
    background-color: #f4f6f8;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.container {
    width: min(1160px, calc(100% - 40px));
    margin-inline: auto;
}

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 30;
    background-color: var(--white);
    border-bottom: 1px solid #e5ebf1;
}

.nav-wrapper {
    min-height: 78px;
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: flex;
    align-items: center;
}

.brand img {
    width: 160px;
    height: auto;
}

.main-nav {
    position: relative;
    display: flex;
    align-items: stretch;
}

.main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: stretch;
    gap: 30px;
    min-height: 100%;
}

.main-nav .nav-item {
    position: relative;
    display: flex;
    align-items: center;
}

.main-nav .nav-item.is-active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background-color: var(--green-brand-500);
}

.main-nav .nav-item a {
    position: relative;
    display: inline-block;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: var(--blue-brand-900);
}

.main-nav .nav-item a:hover {
    color: var(--blue-brand-700);
}

.main-nav .nav-item.is-active a {
    color: var(--blue-brand-700);
}

.menu-toggle {
    display: none;
    border: 0;
    background: transparent;
    width: 44px;
    height: 44px;
    padding: 0;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.menu-close-item {
    display: none;
}

.menu-close-button {
    border: 0;
    background: transparent;
    color: var(--blue-brand-900);
    font-size: 22px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    padding: 6px 8px;
}

.menu-toggle-icon {
    position: relative;
    width: 22px;
    height: 2px;
    border-radius: 3px;
    background-color: var(--blue-brand-900);
    transition: background-color 0.2s var(--ease-smooth);
}

.menu-toggle-icon::before,
.menu-toggle-icon::after {
    content: "";
    position: absolute;
    left: 0;
    width: 22px;
    height: 2px;
    border-radius: 3px;
    background-color: var(--blue-brand-900);
    transition: transform 0.2s var(--ease-smooth), top 0.2s var(--ease-smooth);
}

.menu-toggle-icon::before {
    top: -7px;
}

.menu-toggle-icon::after {
    top: 7px;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-icon {
    background-color: transparent;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-icon::before {
    top: 0;
    transform: rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-toggle-icon::after {
    top: 0;
    transform: rotate(-45deg);
}

.hero {
    position: relative;
    overflow: hidden;
    background-color: #e8eef4;
    min-height: clamp(400px, 64vh, 700px);
}

.hero-bg {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 100%;
    background-color: #e8eef4;
    background-image: url("../images/fondo_temporal.webp");
    background-position: 88% center;
    background-repeat: no-repeat;
    background-size: cover;
    will-change: transform;
    transform: translate3d(0, 0, 0);
}

@media (prefers-reduced-motion: reduce) {
    .hero-bg {
        will-change: auto;
    }
}

.hero-content {
    position: relative;
    z-index: 1;
    padding-top: clamp(44px, 7.5vh, 80px);
    padding-bottom: clamp(40px, 6.5vh, 72px);
    text-align: left;
    display: flex;
    justify-content: flex-start;
}

.hero-copy {
    width: min(560px, 100%);
    max-width: 52%;
}

.hero h1 {
    margin: 0;
    color: var(--white);
    font-size: clamp(25px, 3.5vw, 42px);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: 0.7px;
    text-shadow:
        0 1px 2px rgba(0, 0, 0, 0.35),
        0 2px 18px rgba(0, 0, 0, 0.22);
    opacity: 0;
    transform: translate3d(0, 0, 0);
    animation: hero-h1-slide-in-left 900ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

@media (prefers-reduced-motion: no-preference) {
    .hero h1 {
        will-change: transform;
    }
}

@keyframes hero-h1-slide-in-left {
    from {
        opacity: 0;
        transform: translate3d(-120px, 0, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero h1 {
        animation: none !important;
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

.hero p {
    margin: 14px 0 0;
    max-width: none;
    color: var(--white);
    font-size: clamp(14px, 1.4vw, 19px);
    font-weight: 500;
    line-height: 1.35;
    text-shadow:
        0 1px 2px rgba(0, 0, 0, 0.35),
        0 2px 14px rgba(0, 0, 0, 0.2);
}

.hero-typed-text {
    min-height: 2.8em;
}

.hero-typed-text.is-typing::after {
    content: "";
    display: inline-block;
    width: 2px;
    height: 1em;
    margin-left: 4px;
    transform: translateY(2px);
    background-color: var(--white);
    box-shadow: 0 0 6px rgba(0, 0, 0, 0.35);
    animation: hero-caret-blink 0.9s steps(1) infinite;
}

@keyframes hero-caret-blink {
    50% {
        opacity: 0;
    }
}

.hero-actions {
    margin-top: 24px;
    display: flex;
    justify-content: flex-start;
    gap: 14px;
    flex-wrap: wrap;
}

.btn {
    min-width: 194px;
    /*min-height: 54px;*/
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 18px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.35px;
    border: 1px solid transparent;
    transition: all 0.2s var(--ease-smooth);
}

.btn-primary {
    background-color: var(--green-brand-600);
    color: var(--white);
}

.btn-primary:hover {
    background-color: #6aa326;
}

.btn-outline {
    background-color: var(--white);
    border-color: var(--blue-brand-500);
    color: var(--blue-brand-500);
}

.btn-outline:hover {
    background-color: var(--blue-brand-500);
    color: var(--white);
}

.hero-certifications {
    margin: 22px 0 0;
    padding-bottom: 8px;
    width: 100%;
    max-width: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: clamp(10px, 1.6vw, 22px);
    flex-wrap: wrap;
}

.hero-certifications img {
    width: clamp(48px, 5.5vw, 72px);
    height: auto;
}

.section {
    padding: 72px 0;
}

body.scroll-animate .section {
    opacity: 0;
    transform: translateY(26px);
    transition:
        opacity 700ms var(--ease-smooth),
        transform 700ms var(--ease-smooth);
}

body.scroll-animate .section.is-visible {
    opacity: 1;
    transform: translateY(0);
}

body.scroll-animate .reveal-item {
    opacity: 0;
    transform: translateY(18px) scale(0.99);
    transition:
        opacity 560ms var(--ease-smooth),
        transform 560ms var(--ease-smooth);
    transition-delay: var(--reveal-delay, 0ms);
    will-change: opacity, transform;
}

body.scroll-animate .reveal-item.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.section-light {
    background-color: var(--blue-brand-100);
}

.section-white {
    background-color: var(--white);
}

#servicios {
    background-color: var(--blue-brand-300);
    --carousel-gutter: clamp(56px, 7vw, 88px);
}

#servicios h2 {
    color: var(--white);
}

.section:not(.service-page) h2 {
    margin: 0 0 35px;
    font-size: clamp(28px, 2.4vw, 36px);
    color: var(--blue-brand-900);
}

.section p {
    margin: 0 0 14px;
    color: var(--text-soft);
    line-height: 1.7;
}

/* Migas de pan (páginas de servicio) */
.breadcrumb {
    margin-bottom: clamp(18px, 2.5vw, 26px);
}

.breadcrumb-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-soft);
    line-height: 1.4;
}

.breadcrumb-list li {
    display: inline-flex;
    align-items: center;
}

.breadcrumb-list li + li::before {
    content: "/";
    margin: 0 10px;
    color: #9bb3c9;
    font-weight: 500;
}

.breadcrumb-list a {
    color: var(--blue-brand-600);
    text-decoration: none;
}

.breadcrumb-list a:hover {
    text-decoration: underline;
}

.breadcrumb-list [aria-current="page"] {
    color: var(--blue-brand-900);
    font-weight: 700;
}

/* Páginas de servicio: imagen (home) + texto; h1 siempre mayor que h2 */
.service-page-layout {
    display: grid;
    grid-template-columns: minmax(200px, 320px) minmax(0, 1fr);
    gap: clamp(28px, 5vw, 56px);
    align-items: start;
}

.service-page-media {
    margin: 0;
}

.service-page-media img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 14px;
    border: 1px solid #d8e6f5;
    box-shadow: 0 12px 28px rgba(15, 41, 66, 0.08);
}

.service-page-main {
    min-width: 0;
}

.service-page h1 {
    margin: 0 0 18px;
    font-size: clamp(38px, 3.5vw, 52px);
    line-height: 1.12;
    color: var(--blue-brand-900);
    font-weight: 800;
}

.service-page h2 {
    font-size: clamp(22px, 1.85vw, 28px);
    margin: 26px 0 16px;
    line-height: 1.25;
}

.service-page h3 {
    font-size: clamp(17px, 1.35vw, 21px);
    margin: 18px 0 10px;
    color: var(--blue-brand-800);
}

.service-page .service-page-contact-btn {
    margin: 28px 0 0;
}

.service-page .contact-benefits {
    margin-top: 12px;
}

@media (max-width: 900px) {
    .service-page-layout {
        grid-template-columns: 1fr;
    }

    .service-page-media {
        order: -1;
        max-width: min(360px, 100%);
        margin-inline: auto;
    }

    .service-page h1 {
        font-size: clamp(32px, 6vw, 42px);
    }
}

#nosotros {
    background-color: var(--white);
    padding: 0;
}

.nosotros-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
}

.nosotros-content {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    isolation: isolate;
    background-color: var(--white);
    padding: clamp(42px, 5vw, 72px) clamp(18px, 4vw, 46px);
}

.nosotros-content::before {
    content: "";
    position: absolute;
    inset: -4%;
    z-index: 0;
    background-image: url("../images/isotipo.webp");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 100% auto;
    opacity: 0.22;
    filter: blur(1.25px);
    transform: scale(1.02);
    pointer-events: none;
}

.nosotros-content-inner {
    position: relative;
    z-index: 1;
    width: min(560px, 100%);
}

#nosotros h2,
#nosotros p {
    color: var(--text-main);
}

#nosotros h3 {
    margin: 22px 0 14px;
    color: var(--blue-brand-700);
    font-size: clamp(21px, 2vw, 28px);
}

.nosotros-values {
    margin: 0;
    padding-left: 0;
    list-style: none;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.section-title-center {
    text-align: center;
    margin-bottom: 30px;
}

.section-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 28px;
}

.info-card {
    border-radius: 14px;
    background-color: var(--white);
    border: 1px solid #d8e3ef;
    padding: 26px;
    transition: transform 280ms var(--ease-smooth), box-shadow 280ms var(--ease-smooth), border-color 280ms var(--ease-smooth);
}

.info-card:hover {
    transform: translateY(-6px);
    border-color: #bdd5ec;
    box-shadow: 0 14px 30px rgba(15, 41, 66, 0.12);
}

.info-card h3 {
    margin-top: 0;
    color: var(--blue-brand-700);
}

.info-card ul {
    margin: 0;
    padding-left: 18px;
    color: var(--text-soft);
    line-height: 1.7;
}

.nosotros-values li {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
    color: var(--text-main);
    line-height: 1.7;
}

.nosotros-values .value-icon {
    margin-top: 0;
}

.value-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    flex-shrink: 0;
    border: 1px solid #b8d6f3;
    background-color: #eaf2fb;
    margin-top: 2px;
}

.value-icon svg {
    width: 16px;
    height: 16px;
    fill: var(--blue-brand-700);
}

.nosotros-media {
    width: 100%;
    aspect-ratio: 1 / 1;
    background-color: #f3f7fc;
}

.nosotros-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.services-carousel-wrap {
    position: relative;
    width: 100%;
}

.services-carousel-gutter--start,
.services-carousel-gutter--end {
    display: none;
}

.services-carousel-nav {
    position: absolute;
    top: 50%;
    z-index: 45;
    margin: 0;
    padding: 6px;
    min-width: 44px;
    min-height: 44px;
    border: none;
    border-radius: 0;
    background: transparent;
    color: #ffffff;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.55));
    transition:
        opacity 0.2s var(--ease-smooth),
        visibility 0.2s var(--ease-smooth);
}

.services-carousel-prev {
    left: max(16px, env(safe-area-inset-left, 0px));
    transform: translateY(-50%);
}

.services-carousel-next {
    right: max(16px, env(safe-area-inset-right, 0px));
    transform: translateY(-50%);
}

.services-carousel-nav:hover:not(:disabled) {
    opacity: 0.88;
}

.services-carousel-nav:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 3px;
}

.services-carousel-nav.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.services-carousel-nav:disabled {
    cursor: default;
    opacity: 0.38;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.45));
}

.services-carousel {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: clamp(16px, 4vw, 28px);
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    cursor: grab;
    padding-bottom: 4px;
    padding-inline: clamp(16px, 4vw, 28px);
    box-sizing: border-box;
    touch-action: pan-x;
    overscroll-behavior-x: contain;
    container-type: inline-size;
    container-name: services;
}

.services-carousel::-webkit-scrollbar {
    display: none;
    width: 0;
    height: 0;
}

.services-carousel.is-dragging {
    cursor: grabbing;
    user-select: none;
    scroll-snap-type: none;
}

.services-carousel.is-dragging a {
    pointer-events: none;
}

.services-carousel.is-dragging .service-card {
    scroll-snap-align: none;
    transition: none;
}

.services-carousel .services-grid {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    grid-template-columns: unset;
    padding-inline-end: clamp(24px, 7vw, 56px);
    box-sizing: border-box;
}

@media (min-width: 981px) {
    .services-carousel-wrap {
        display: grid;
        grid-template-columns: var(--carousel-gutter) minmax(0, 1fr) var(--carousel-gutter);
        grid-template-rows: auto;
        align-items: stretch;
    }

    .services-carousel-gutter--start,
    .services-carousel-gutter--end {
        display: block;
        pointer-events: none;
        min-height: 1px;
    }

    .services-carousel-gutter--start {
        grid-column: 1;
        grid-row: 1;
    }

    .services-carousel {
        grid-column: 2;
        grid-row: 1;
        min-width: 0;
        padding-inline: 0;
        scroll-padding-inline: 0;
    }

    .services-carousel-gutter--end {
        grid-column: 3;
        grid-row: 1;
    }

    .services-carousel .services-grid {
        padding-inline-end: clamp(40px, 6vw, 72px);
    }

    .services-carousel-prev {
        left: calc(var(--carousel-gutter) / 2);
        right: auto;
        transform: translate(-50%, -50%);
    }

    .services-carousel-next {
        right: calc(var(--carousel-gutter) / 2);
        left: auto;
        transform: translate(50%, -50%);
    }
}

@media (max-width: 980px) {
    .services-carousel-nav {
        /* Visibles en móvil: desplazan el carrusel como en escritorio */
        padding: 4px;
        min-width: 40px;
        min-height: 40px;
    }

    .services-carousel-nav svg {
        width: 30px;
        height: 30px;
    }
}

.services-carousel .service-card {
    flex: 0 0 min(260px, 72vw);
    scroll-snap-align: start;
    min-width: 0;
    align-self: stretch;
}

@supports (container-type: inline-size) {
    .services-carousel .service-card {
        flex: 0 0 calc((100cqi - 54px) / 3.5);
    }
}

.management-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.management-card {
    background: linear-gradient(145deg, #ffffff 0%, #f8fbff 100%);
    border: 1px solid #d8e6f5;
    border-radius: 14px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform 280ms var(--ease-smooth), box-shadow 280ms var(--ease-smooth), border-color 280ms var(--ease-smooth);
}

.management-card-main {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 16px;
    flex: 1 1 auto;
}

.management-card-icon {
    flex-shrink: 0;
    width: clamp(48px, 5vw, 64px);
}

.management-card-icon img {
    width: 100%;
    height: auto;
    display: block;
}

.management-card-content {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.management-card:hover {
    transform: translateY(-6px);
    border-color: #b8d6f3;
    box-shadow: 0 14px 30px rgba(15, 41, 66, 0.14);
}

.management-card h3 {
    margin: 0;
    font-size: 20px;
    color: var(--blue-brand-700);
}

.management-card p {
    margin: 0;
}

.management-link {
    margin-top: auto;
    align-self: flex-start;
    color: var(--green-brand-600);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.4px;
}

.management-link:hover {
    color: #5f9621;
}

.service-card {
    background: linear-gradient(145deg, #ffffff 0%, #f7fbff 100%);
    border: 1px solid #d8e6f5;
    border-radius: 14px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: border-color 280ms var(--ease-smooth);
}

.service-card:hover {
    border-color: #b8d6f3;
}

.service-card img {
    width: 100%;
    max-width: 240px;
    height: auto;
    margin: 0 auto 4px;
}

.service-card h3 {
    margin: 0 0 12px;
    font-size: 20px;
    color: var(--blue-brand-700);
}

.service-card p {
    margin: 0;
}

.service-card .service-card-desc {
    font-size: 13px;
    line-height: 1.55;
    color: var(--text-soft);
    margin: 0 0 12px;
    flex-grow: 1;
}

/* TEMPORAL: ocultar “Llamado a la Acción Permanente”. Eliminar este bloque para volver a mostrarla. */
#cta.cta-section {
    display: none !important;
}

.cta-section {
    background-color: var(--blue-brand-700);
}

.cta-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    color: var(--white);
}

.cta-box h2 {
    color: var(--white);
    margin-bottom: 8px;
}

.cta-box p {
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
}

.contact-page h1 {
    margin: 0 0 16px;
    color: var(--blue-brand-900);
    font-size: clamp(30px, 3vw, 42px);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 34px;
}

.contact-benefits {
    margin: 20px 0 0;
    padding-left: 20px;
    color: var(--text-soft);
    line-height: 1.8;
}

.contact-form {
    background-color: #f8fbff;
    border: 1px solid #d9e6f2;
    border-radius: 14px;
    padding: 24px;
    display: grid;
    gap: 10px;
}

.contact-form label {
    font-size: 13px;
    font-weight: 600;
    color: var(--blue-brand-900);
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    border: 1px solid #c9d8e8;
    border-radius: 8px;
    padding: 12px;
    font-family: inherit;
    font-size: 14px;
    color: var(--text-main);
    background: var(--white);
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: 2px solid rgba(0, 83, 165, 0.18);
    border-color: var(--blue-brand-500);
}

.contact-form .btn {
    margin-top: 8px;
    width: 100%;
}

.site-footer {
    padding: 48px 0 34px;
    background-color: #0a1e34;
    color: rgba(255, 255, 255, 0.86);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr 1fr;
    gap: 22px;
}

.footer-logo {
    width: 160px;
    margin-bottom: 14px;
}

.footer-copy {
    margin: 0;
    max-width: 300px;
    line-height: 1.7;
    font-size: 14px;
}

.site-footer h3 {
    margin: 0 0 14px;
    color: var(--white);
    font-size: 17px;
}

.footer-links,
.footer-contact {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 10px;
    font-size: 14px;
}

.footer-links a:hover,
.social-links a:hover,
.footer-contact a:hover {
    color: #a7cbff;
}

.footer-contact a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.whatsapp-float {
    position: fixed;
    bottom: max(20px, env(safe-area-inset-bottom, 0px));
    right: max(20px, env(safe-area-inset-right, 0px));
    z-index: 130;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #25d366;
    color: #ffffff;
    box-shadow: 0 14px 28px rgba(0, 0, 0, 0.22);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition:
        transform 0.2s var(--ease-smooth),
        box-shadow 0.2s var(--ease-smooth);
}

.whatsapp-float:hover {
    transform: scale(1.06);
    box-shadow: 0 18px 34px rgba(0, 0, 0, 0.26);
}

.whatsapp-float:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 3px;
}

.social-links {
    display: grid;
    gap: 10px;
    font-size: 14px;
}

@media (max-width: 980px) {
    .main-nav .nav-item a {
        font-size: 11px;
    }

    .menu-toggle {
        display: inline-flex;
        position: relative;
        z-index: 120;
    }

    .main-nav ul {
        position: fixed;
        left: 50%;
        top: 50%;
        width: 95vw;
        height: 95dvh;
        max-width: 700px;
        padding: 20px;
        background-color: var(--white);
        border: 1px solid #e3ebf2;
        border-radius: 12px;
        box-shadow: 0 18px 38px rgba(14, 47, 78, 0.18);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 18px;
        text-align: center;
        overflow-y: auto;
        opacity: 0;
        pointer-events: none;
        transform: translate(-50%, -50%) scale(0.98);
        transition: all 0.2s var(--ease-smooth);
        z-index: 110;
    }

    .main-nav ul.is-open {
        opacity: 1;
        pointer-events: auto;
        transform: translate(-50%, -50%) scale(1);
    }

    .menu-close-item {
        width: 100%;
        display: flex;
        justify-content: flex-end;
        position: sticky;
        top: 0;
        background-color: var(--white);
        padding-bottom: 6px;
        margin-bottom: 4px;
    }

    .menu-close-button {
        font-size: 26px;
    }

    .main-nav ul .nav-item a {
        font-size: 16px;
        font-weight: 700;
        letter-spacing: 0.7px;
    }

    .hero-content {
        padding-top: clamp(40px, 6.5vh, 64px);
        padding-bottom: clamp(36px, 5.5vh, 56px);
    }

    .hero-copy {
        max-width: min(100%, 480px);
    }

    .hero-bg {
        background-position: 78% center;
    }

    .hero h1 {
        margin-top: 8px;
        font-size: clamp(20px, 4vw, 30px);
    }

    .hero p {
        font-size: clamp(13px, 2.1vw, 16px);
    }

    .hero-actions {
        margin-top: 24px;
        gap: 10px;
    }

    .section:not(.service-page) h2 {
        font-size: clamp(24px, 3vw, 30px);
    }

    #nosotros h3 {
        font-size: clamp(19px, 2.6vw, 24px);
    }

    .section:not(.service-page) p {
        font-size: 15px;
        line-height: 1.62;
    }

    .service-page p {
        font-size: 15px;
        line-height: 1.62;
    }

    .service-card h3,
    .management-card h3 {
        font-size: 18px;
    }

    .management-link {
        font-size: 11px;
    }

    .footer-copy,
    .footer-links,
    .footer-contact,
    .social-links {
        font-size: 13px;
    }

    .site-footer h3 {
        font-size: 16px;
    }

    .hero-certifications {
        margin-top: 18px;
        padding-bottom: 14px;
    }

    .hero-certifications img {
        width: clamp(50px, 6vw, 68px);
    }

    .nosotros-layout {
        grid-template-columns: 1fr;
    }

    .nosotros-content {
        justify-content: flex-start;
        padding: 48px 24px 40px;
    }

    #nosotros h2 {
        margin-top: 10px;
        margin-bottom: 20px;
    }

    #nosotros p {
        margin-top: 0;
        margin-bottom: 20px;
    }

    #nosotros h3 {
        margin-top: 28px;
        margin-bottom: 18px;
    }

    .nosotros-values {
        margin-top: 6px;
        margin-bottom: 10px;
        grid-template-columns: 1fr;
    }

    .nosotros-media {
        max-width: 100%;
    }

    .section-grid,
    .management-grid,
    .contact-wrapper {
        grid-template-columns: 1fr;
    }

    .services-carousel .service-card {
        flex: 0 0 min(220px, 58vw);
    }

    @supports (container-type: inline-size) {
        .services-carousel .service-card {
            flex: 0 0 calc((100cqi - 36px) / 2.5);
        }
    }

    .cta-box {
        flex-direction: column;
        align-items: flex-start;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        row-gap: 28px;
    }
}

@media (max-width: 640px) {
    .container {
        width: min(100%, calc(100% - 24px));
    }

    .brand img {
        width: 136px;
    }

    .nav-wrapper {
        min-height: 66px;
    }

    :root {
        --site-header-height: 66px;
    }

    .hero {
        min-height: auto;
    }

    .hero-bg {
        background-position: 70% center;
    }

    .hero-content {
        padding-top: clamp(36px, 6vh, 52px);
        padding-bottom: clamp(32px, 5vh, 48px);
    }

    .hero-copy {
        max-width: 100%;
    }

    .hero h1 {
        margin-top: 6px;
        font-size: clamp(18px, 6.2vw, 24px);
        line-height: 1.12;
    }

    .hero p {
        margin-top: 10px;
        font-size: clamp(13px, 4.1vw, 16px);
        line-height: 1.45;
    }

    .btn {
        min-width: 154px;
        min-height: 44px;
        font-size: 11px;
    }

    .hero-certifications {
        margin-top: 12px;
        padding-bottom: 10px;
    }

    .hero-certifications img {
        width: clamp(36px, 10.5vw, 46px);
    }

    .nosotros-content {
        padding: 42px 16px 34px;
    }

    #nosotros h2 {
        margin-top: 8px;
        margin-bottom: 16px;
    }

    #nosotros p {
        margin-top: 0;
        margin-bottom: 16px;
    }

    #nosotros h3 {
        margin-top: 24px;
        margin-bottom: 14px;
    }

    .nosotros-values {
        margin-top: 4px;
        margin-bottom: 8px;
    }

    .nosotros-values {
        gap: 10px;
    }

    .nosotros-values li {
        font-size: 13px;
        line-height: 1.6;
    }

    .value-icon {
        width: 26px;
        height: 26px;
    }

    .value-icon svg {
        width: 14px;
        height: 14px;
    }

    .section {
        padding: 56px 0;
    }

    .section:not(.service-page) h2 {
        font-size: clamp(21px, 6.2vw, 25px);
    }

    #nosotros h3 {
        font-size: clamp(17px, 4.8vw, 21px);
    }

    .section:not(.service-page) p {
        font-size: 13px;
        line-height: 1.55;
    }

    .service-page p {
        font-size: 13px;
        line-height: 1.55;
    }

    .service-card h3,
    .management-card h3 {
        font-size: 16px;
    }

    .management-link {
        font-size: 10px;
    }

    .main-nav .nav-item a {
        font-size: 10px;
    }

    .main-nav ul .nav-item a {
        font-size: 14px;
    }

    .contact-page h1 {
        font-size: clamp(23px, 6.2vw, 28px);
    }

    .footer-copy,
    .footer-links,
    .footer-contact,
    .social-links {
        font-size: 12px;
    }

    .site-footer h3 {
        font-size: 15px;
    }

    .services-carousel .services-grid {
        gap: 14px;
    }

    .services-carousel .service-card {
        flex: 0 0 min(220px, 78vw);
    }

    @supports (container-type: inline-size) {
        .services-carousel .service-card {
            flex: 0 0 calc((100cqi - 18px) / 1.35);
        }
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .whatsapp-float {
        width: 52px;
        height: 52px;
        bottom: max(16px, env(safe-area-inset-bottom, 0px));
        right: max(16px, env(safe-area-inset-right, 0px));
    }

    .whatsapp-float svg {
        width: 26px;
        height: 26px;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition-duration: 1ms !important;
        scroll-behavior: auto !important;
    }

    body.scroll-animate .section,
    body.scroll-animate .reveal-item {
        opacity: 1;
        transform: none;
        will-change: auto;
    }
}
