/* ═══════════════════════════════════════════════════════════════════
   RAM REFRIGERACIÓN — PREMIUM LAYER v1.0
   Micro-interacciones, animaciones 2025/2026, efectos avanzados.
   NO modifica estructura ni contenido — solo capas visuales.
   ═══════════════════════════════════════════════════════════════════ */

/* ── SCROLL PROGRESS BAR ─────────────────────────────────────────── */
#scroll-progress {
    position: fixed;
    top: 0; left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, #00B4D8, #0077B6, #023E8A);
    z-index: 9999;
    transition: width .08s linear;
    border-radius: 0 2px 2px 0;
}
#scroll-progress::after {
    content: '';
    position: absolute;
    right: 0; top: 50%;
    transform: translateY(-50%);
    width: 6px; height: 6px;
    border-radius: 50%;
    background: #00B4D8;
    box-shadow: 0 0 8px #00B4D8;
}

/* ── CUSTOM CURSOR (solo desktop) ────────────────────────────────── */
@media (hover: hover) and (pointer: fine) {
    body { cursor: none !important; }
    a, button, .btn, [role="button"], label, input, select, textarea,
    .service-item, .gallery-item, .nav-link {
        cursor: none !important;
    }
    #ram-cursor {
        width: 10px; height: 10px;
        background: #0077B6;
        border: 2px solid #fff;
        box-shadow: 0 0 0 1px rgba(0,0,0,.35);
        border-radius: 50%;
        position: fixed;
        pointer-events: none;
        z-index: 99999;
        transform: translate(-50%, -50%);
        transition: transform .08s ease, width .2s ease, height .2s ease;
    }
    #ram-cursor-ring {
        width: 34px; height: 34px;
        border: 1.5px solid #0077B6;
        border-radius: 50%;
        position: fixed;
        pointer-events: none;
        z-index: 99998;
        transform: translate(-50%, -50%);
        transition: transform .18s ease, width .25s ease, height .25s ease;
        /* mix-blend-mode difference = siempre visible en cualquier fondo */
        mix-blend-mode: difference;
        background: transparent;
        box-shadow: 0 0 0 1px rgba(255,255,255,.3);
    }
    #ram-cursor.is-hovering {
        width: 6px; height: 6px;
        background: #48CAE4;
    }
    #ram-cursor-ring.is-hovering {
        width: 50px; height: 50px;
    }
    #ram-cursor.is-clicking {
        transform: translate(-50%, -50%) scale(.65);
    }
}

/* ── NAVBAR MEGA UPGRADE ─────────────────────────────────────────── */
.navbar.sticky-top {
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    background: rgba(255,255,255,.94) !important;
    border-bottom: 1px solid rgba(0,119,182,.1);
    transition: all .35s cubic-bezier(.4,0,.2,1) !important;
}
.navbar.sticky-top.scrolled {
    box-shadow: 0 4px 28px rgba(0,119,182,.12) !important;
    background: rgba(255,255,255,.98) !important;
}

/* Nav links — animated underline mejorado */
.navbar .nav-link {
    position: relative;
    padding-bottom: 4px !important;
    font-weight: 600;
    letter-spacing: .2px;
}
.navbar .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0; left: 50%;
    width: 0; height: 2px;
    background: linear-gradient(90deg, #0077B6, #00B4D8);
    border-radius: 2px;
    transition: width .3s cubic-bezier(.4,0,.2,1), left .3s cubic-bezier(.4,0,.2,1);
}
.navbar .nav-link:hover::after,
.navbar .nav-link.active::after {
    width: 80%;
    left: 10%;
}

/* ── BTN OUTLINE-PRIMARY upgrade ─────────────────────────────────── */
.btn-outline-primary {
    position: relative;
    overflow: hidden;
    border-width: 1.5px !important;
    font-weight: 600 !important;
    transition: all .35s cubic-bezier(.4,0,.2,1) !important;
    z-index: 0;
}
.btn-outline-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #0077B6, #023E8A);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform .35s cubic-bezier(.4,0,.2,1);
    z-index: -1;
}
.btn-outline-primary:hover::before { transform: scaleX(1); transform-origin: left; }
.btn-outline-primary:hover { color: #fff !important; border-color: #0077B6 !important; }

/* ── BTN SECONDARY upgrade ───────────────────────────────────────── */
.btn-secondary, .btn-light {
    transition: all .3s cubic-bezier(.4,0,.2,1) !important;
}
.btn-secondary:hover, .btn-light:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(0,0,0,.12) !important;
}

/* ── BTN WHATSAPP / LINK ─────────────────────────────────────────── */
a[href*="wa.me"], a[href*="whatsapp"] {
    transition: all .3s ease !important;
}
a[href*="wa.me"]:hover, a[href*="whatsapp"]:hover {
    transform: translateY(-2px);
    filter: brightness(1.08);
}

/* ── SERVICE CARDS — tilt + glow ─────────────────────────────────── */
.service-item {
    transition: all .4s cubic-bezier(.4,0,.2,1) !important;
    will-change: transform;
}
.service-item:hover {
    transform: translateY(-8px) !important;
    box-shadow: 0 20px 50px rgba(0,119,182,.22) !important;
}
/* Animated border top on hover */
.service-item {
    position: relative;
}
.service-item::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #00B4D8, #0077B6);
    transform: scaleX(0);
    transition: transform .4s cubic-bezier(.4,0,.2,1);
    border-radius: 3px 3px 0 0;
}
.service-item:hover::after { transform: scaleX(1); }

/* ── FEATURE / DETAIL CARDS upgrade ─────────────────────────────── */
.card.border-0 {
    transition: all .38s cubic-bezier(.4,0,.2,1) !important;
}
.card.border-0:hover {
    transform: translateY(-6px) !important;
}

/* ── STAT NUMBERS — glow ─────────────────────────────────────────── */
.stat-card h1,
.facts h1.display-4 {
    transition: text-shadow .3s ease;
}
.stat-card:hover h1 {
    text-shadow: 0 0 30px rgba(0,180,216,.6) !important;
}

/* ── TESTIMONIAL CARDS hover ─────────────────────────────────────── */
.testimonial-item {
    transition: all .38s cubic-bezier(.4,0,.2,1) !important;
}
.testimonial-item:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 18px 48px rgba(0,119,182,.18) !important;
    border-color: rgba(0,119,182,.18) !important;
}

/* ── GALLERY ITEMS upgrade ───────────────────────────────────────── */
.gallery-item {
    overflow: hidden !important;
    border-radius: 10px !important;
    position: relative;
}
.gallery-item img {
    transition: transform .55s cubic-bezier(.4,0,.2,1) !important;
}
.gallery-item:hover img {
    transform: scale(1.07) !important;
}
.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(2,62,138,.55) 0%,
        transparent 55%
    );
    opacity: 0;
    transition: opacity .4s ease;
    pointer-events: none;
}
.gallery-item:hover::after { opacity: 1; }
.gallery-item .btn {
    transition: all .3s ease !important;
    opacity: 0;
    transform: translateY(10px);
}
.gallery-item:hover .btn {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* ── GALLERY FILTER BUTTONS ─────────────────────────────────────── */
.gallery-filter .btn {
    position: relative;
    overflow: hidden;
    transition: all .3s cubic-bezier(.4,0,.2,1) !important;
    border-radius: 50px !important;
    font-weight: 600 !important;
    letter-spacing: .3px;
}
.gallery-filter .btn.active {
    box-shadow: 0 4px 16px rgba(0,119,182,.3) !important;
    transform: translateY(-1px);
}

/* ── TEAM CARDS upgrade ──────────────────────────────────────────── */
.team-item {
    overflow: hidden;
    border-radius: var(--radius-lg, 12px) !important;
    transition: all .4s cubic-bezier(.4,0,.2,1) !important;
}
.team-item:hover {
    transform: translateY(-8px) !important;
    box-shadow: 0 20px 50px rgba(0,119,182,.2) !important;
}
.team-item img {
    transition: transform .5s ease !important;
}
.team-item:hover img { transform: scale(1.05) !important; }
.team-item .team-overlay {
    opacity: 0;
    transition: opacity .3s ease !important;
}
.team-item:hover .team-overlay { opacity: 1 !important; }

/* ── FORM INPUTS — floating label feel ───────────────────────────── */
.form-control,
.form-select {
    border: 1.5px solid rgba(0,119,182,.18) !important;
    border-radius: 10px !important;
    transition: all .3s cubic-bezier(.4,0,.2,1) !important;
    background: #f8fbff !important;
    font-size: .95rem;
}
.form-control:focus,
.form-select:focus {
    border-color: #0077B6 !important;
    background: #fff !important;
    box-shadow: 0 0 0 4px rgba(0,119,182,.1) !important;
    transform: translateY(-1px);
}
.form-control:focus + label,
.form-select:focus + label {
    color: #0077B6 !important;
}

/* ── BREADCRUMB animated ─────────────────────────────────────────── */
.breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255,255,255,.5) !important;
}
.breadcrumb-item a {
    transition: color .2s ease !important;
}
.breadcrumb-item a:hover { color: #00B4D8 !important; }

/* ── PAGE HEADER — animated bg ───────────────────────────────────── */
.page-header {
    background-size: cover !important;
    position: relative;
    overflow: hidden;
}
.page-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(135deg, rgba(1,10,53,.78), rgba(0,119,182,.65));
    z-index: 1;
}
.page-header > * { position: relative; z-index: 2; }
/* Animated wave overlay */
.page-header::after {
    content: '';
    position: absolute;
    bottom: -2px; left: 0; right: 0;
    height: 60px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 60'%3E%3Cpath d='M0,30 C200,60 400,0 600,30 C800,60 1000,0 1200,30 L1200,60 L0,60 Z' fill='%23f8f9fa'/%3E%3C/svg%3E") no-repeat bottom/cover;
    z-index: 3;
}

/* ── WHATSAPP FLOATING BTN pulse ─────────────────────────────────── */
.wa-float {
    position: fixed !important;
    bottom: 28px; right: 28px;
    z-index: 9990;
}
.wa-float::before {
    content: '';
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    background: rgba(37,211,102,.25);
    animation: wa-pulse 2s ease infinite;
}
@keyframes wa-pulse {
    0%, 100% { transform: scale(1); opacity: .8; }
    50%       { transform: scale(1.3); opacity: 0; }
}

/* ── SECTION TITLES — animated underline ─────────────────────────── */
.section-header {
    position: relative;
    display: inline-block;
}
.section-header::after {
    content: '';
    position: absolute;
    bottom: -6px; left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #00B4D8, #0077B6);
    border-radius: 2px;
    transition: width .8s cubic-bezier(.22,1,.36,1) .2s;
}
.anim-in .section-header::after,
.section-header.anim-in::after,
[data-anim].anim-in .section-header::after {
    width: 60px;
}

/* ── BRANDS MARQUEE upgrade ──────────────────────────────────────── */
.brands-section {
    position: relative;
    overflow: hidden;
}
.brands-section::before,
.brands-section::after {
    content: '';
    position: absolute;
    top: 0; bottom: 0;
    width: 80px;
    z-index: 2;
    pointer-events: none;
}
.brands-section::before {
    left: 0;
    background: linear-gradient(90deg, var(--bs-body-bg, #fff), transparent);
}
.brands-section::after {
    right: 0;
    background: linear-gradient(-90deg, var(--bs-body-bg, #fff), transparent);
}

/* ── ACCORDION — upgrade ─────────────────────────────────────────── */
.accordion-button {
    font-weight: 600 !important;
    transition: all .3s ease !important;
    border-radius: 10px !important;
}
.accordion-button:not(.collapsed) {
    background: linear-gradient(135deg, #eaf3ff, #d6eaff) !important;
    color: #023E8A !important;
    box-shadow: none !important;
}
.accordion-button:not(.collapsed)::after {
    filter: invert(20%) sepia(80%) saturate(500%) hue-rotate(200deg) !important;
}
.accordion-item {
    border-radius: 10px !important;
    overflow: hidden;
    margin-bottom: .5rem !important;
    border: 1px solid rgba(0,119,182,.1) !important;
    transition: box-shadow .3s ease !important;
}
.accordion-item:hover {
    box-shadow: 0 4px 16px rgba(0,119,182,.1) !important;
}

/* ── TABS upgrade ────────────────────────────────────────────────── */
.nav-tabs {
    border-bottom: 2px solid rgba(0,119,182,.12) !important;
    gap: .3rem;
}
.nav-tabs .nav-link {
    border: none !important;
    border-radius: 10px 10px 0 0 !important;
    font-weight: 600 !important;
    color: #666 !important;
    padding: .65rem 1.2rem !important;
    transition: all .3s ease !important;
    position: relative;
}
.nav-tabs .nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, #0077B6, #00B4D8);
    transform: scaleX(0);
    transition: transform .3s cubic-bezier(.4,0,.2,1);
}
.nav-tabs .nav-link.active::after { transform: scaleX(1); }
.nav-tabs .nav-link:hover { color: #0077B6 !important; background: rgba(0,119,182,.06) !important; }
.nav-tabs .nav-link.active {
    color: #0077B6 !important;
    background: rgba(0,119,182,.06) !important;
}

/* ── PILLS/TAGS upgrade ──────────────────────────────────────────── */
.badge, .rounded-pill {
    transition: all .25s ease !important;
}
.badge:hover { transform: scale(1.05); }

/* ── FOOTER LINKS enhanced ───────────────────────────────────────── */
.footer a {
    transition: all .25s ease !important;
    position: relative;
}
.footer .btn.btn-link:hover {
    color: #00B4D8 !important;
    padding-left: 10px !important;
    text-decoration: none !important;
}

/* ── BACK TO TOP enhanced ────────────────────────────────────────── */
.back-to-top {
    border-radius: 12px !important;
    transition: all .35s cubic-bezier(.4,0,.2,1) !important;
}
.back-to-top:hover {
    border-radius: 50% !important;
    transform: translateY(-5px) rotate(360deg) !important;
    transition: all .5s cubic-bezier(.4,0,.2,1) !important;
}

/* ── LOADING SKELETON ────────────────────────────────────────────── */
@keyframes skeleton-wave {
    0%   { background-position: -200% 0; }
    100% { background-position:  200% 0; }
}
.skeleton {
    background: linear-gradient(90deg, #f0f4f8 25%, #e0eaf4 50%, #f0f4f8 75%);
    background-size: 200% 100%;
    animation: skeleton-wave 1.4s ease infinite;
    border-radius: 6px;
}

/* ── TOOLTIP upgrade ─────────────────────────────────────────────── */
.tooltip-inner {
    background: linear-gradient(135deg, #023E8A, #0077B6) !important;
    border-radius: 8px !important;
    font-size: .8rem;
    font-weight: 500;
    padding: .4rem .85rem !important;
    box-shadow: 0 4px 14px rgba(0,119,182,.3) !important;
}
.bs-tooltip-auto .tooltip-arrow::before,
.bs-tooltip-top .tooltip-arrow::before {
    border-top-color: #023E8A !important;
}

/* ── IMAGE hover ZOOM subtle ─────────────────────────────────────── */
img.img-fluid {
    transition: transform .4s cubic-bezier(.4,0,.2,1) !important;
}
a:hover img.img-fluid,
.hover-zoom:hover img { transform: scale(1.03); }

/* ── COUNTER numbers animated ────────────────────────────────────── */
[data-count] {
    display: inline-block;
    transition: transform .3s ease;
}
[data-count].counting { animation: countBounce .3s ease; }
@keyframes countBounce {
    0%  { transform: scale(1); }
    50% { transform: scale(1.12); }
    100%{ transform: scale(1); }
}

/* ── SMOOTH ANCHOR SCROLL highlight ─────────────────────────────── */
:target {
    animation: target-flash .6s ease;
}
@keyframes target-flash {
    0%, 100% { background: transparent; }
    30%       { background: rgba(0,119,182,.06); }
}

/* ── SELECTION color ─────────────────────────────────────────────── */
::selection {
    background: rgba(0,119,182,.2);
    color: #023E8A;
}

/* ── FOCUS visible ring ──────────────────────────────────────────── */
:focus-visible {
    outline: 2px solid #0077B6 !important;
    outline-offset: 3px !important;
    border-radius: 4px !important;
}

/* ── REDUCE MOTION ───────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    #ram-cursor, #ram-cursor-ring, #scroll-progress,
    .wa-float::before, .section-header::after,
    .btn-outline-primary::before, .service-item::after,
    .gallery-item::after, .accordion-button, .nav-tabs .nav-link::after {
        animation: none !important;
        transition: none !important;
    }
}

/* ═══════════════════════════════════════════════════════════════════
   BRANDS — Premium Redesign 2025
   ═══════════════════════════════════════════════════════════════════ */
.brands-section-v2 {
    padding: 3.5rem 0 3rem;
    background: #fff;
    border-top: 1px solid rgba(0,119,182,.07);
    border-bottom: 1px solid rgba(0,119,182,.07);
    position: relative;
    overflow: hidden;
}
.brands-section-v2::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 0%, rgba(0,119,182,.04) 0%, transparent 65%);
    pointer-events: none;
}

/* Header row con líneas */
.brands-header-row {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    max-width: 520px;
    margin: 0 auto 2rem;
    padding: 0 1.5rem;
}
.brands-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0,119,182,.25), transparent);
}
.brands-label {
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: 2.5px;
    color: #0077B6;
    text-transform: uppercase;
    white-space: nowrap;
}

/* Marquee outer con fade mask */
.brands-marquee-outer {
    overflow: hidden;
    -webkit-mask-image: linear-gradient(90deg,
        transparent 0%,
        #fff 10%,
        #fff 90%,
        transparent 100%);
    mask-image: linear-gradient(90deg,
        transparent 0%,
        #fff 10%,
        #fff 90%,
        transparent 100%);
}

/* Track — usa la misma animación ya definida */
.brands-marquee-track {
    display: flex;
    width: max-content;
    animation: marquee-scroll 28s linear infinite;
    gap: 16px;
    align-items: center;
    padding: 8px 0 12px;
}
.brands-marquee-track:hover { animation-play-state: paused; }

/* Brand pill — diseño minimalista premium */
.brand-pill {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    background: #fff;
    border: 1px solid rgba(0,119,182,.1);
    border-radius: 16px;
    padding: 1.1rem 1.6rem .9rem;
    min-width: 140px;
    box-shadow: 0 2px 12px rgba(0,0,0,.04), 0 1px 4px rgba(0,0,0,.03);
    transition: all .35s cubic-bezier(.4,0,.2,1);
    position: relative;
    overflow: hidden;
    cursor: default;
}
.brand-pill::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, #00B4D8, #0077B6);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .35s cubic-bezier(.4,0,.2,1);
}
.brand-pill:hover {
    border-color: rgba(0,119,182,.22);
    transform: translateY(-5px);
    box-shadow: 0 12px 32px rgba(0,119,182,.14), 0 4px 12px rgba(0,0,0,.06);
}
.brand-pill:hover::after { transform: scaleX(1); }

.brand-pill-logo {
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.brand-pill-logo img {
    max-height: 40px;
    max-width: 100px;
    width: auto;
    object-fit: contain;
    filter: grayscale(20%);
    transition: filter .3s ease;
}
.brand-pill:hover .brand-pill-logo img {
    filter: grayscale(0%) drop-shadow(0 2px 6px rgba(0,119,182,.2));
}
.brand-pill-name {
    font-size: .67rem;
    font-weight: 700;
    color: #aab4be;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    transition: color .25s ease;
}
.brand-pill:hover .brand-pill-name { color: #0077B6; }

@media (prefers-reduced-motion: reduce) {
    .brands-marquee-track { animation: none; }
}

/* ═══════════════════════════════════════════════════════════════════
   GALLERY — Premium Redesign 2025
   ═══════════════════════════════════════════════════════════════════ */

/* Filter buttons — pill style premium */
.gfilter-wrap {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    background: #f4f8fb;
    border-radius: 50px;
    padding: 6px;
    width: fit-content;
    margin: 0 auto;
    border: 1px solid rgba(0,119,182,.1);
}
.gfilter-btn {
    padding: 9px 20px !important;
    border: none !important;
    background: transparent !important;
    color: #555 !important;
    border-radius: 40px !important;
    font-size: .82rem !important;
    font-weight: 600 !important;
    cursor: pointer;
    white-space: nowrap;
    transition: all .3s cubic-bezier(.4,0,.2,1) !important;
    position: relative;
}
.gfilter-btn:hover {
    background: rgba(0,119,182,.1) !important;
    color: #0077B6 !important;
    transform: none !important;
    box-shadow: none !important;
}
.gfilter-btn.gf-active {
    background: linear-gradient(135deg, #0077B6, #023E8A) !important;
    color: #fff !important;
    box-shadow: 0 4px 14px rgba(0,119,182,.35) !important;
    transform: none !important;
}
.gal-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px; height: 20px;
    border-radius: 50%;
    background: rgba(255,255,255,.22) !important;
    color: inherit;
    font-size: .68rem !important;
    font-weight: 700;
    margin-left: 6px;
}
.gfilter-btn:not(.gf-active) .gal-badge {
    background: rgba(0,119,182,.12) !important;
    color: #0077B6 !important;
}

/* Gallery grid — masonry-like flow */
.gal-grid {
    columns: 3;
    column-gap: 14px;
}
.gal-item {
    break-inside: avoid;
    margin-bottom: 14px;
}
@media (max-width: 991.98px) { .gal-grid { columns: 2; } }
@media (max-width: 575.98px) { .gal-grid { columns: 1; } }

/* Gallery card — enhanced */
.gallery-card,
.gal-card {
    position: relative;
    overflow: hidden;
    border-radius: 14px !important;
    cursor: pointer;
    display: block;
    box-shadow: 0 3px 16px rgba(0,0,0,.09);
    transition: all .4s cubic-bezier(.4,0,.2,1) !important;
}
.gallery-card img,
.gal-card img {
    width: 100%;
    display: block;
    object-fit: cover;
    transition: transform .55s cubic-bezier(.4,0,.2,1) !important;
}
.gallery-card:hover,
.gal-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(0,0,0,.18) !important;
}
.gallery-card:hover img,
.gal-card:hover img {
    transform: scale(1.07) !important;
}

/* Overlay premium — gradient bottom */
.gallery-card::before,
.gal-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(2,10,40,.75) 0%,
        rgba(0,60,130,.2) 40%,
        transparent 65%
    );
    opacity: 0;
    transition: opacity .35s ease;
    z-index: 1;
    pointer-events: none;
}
.gallery-card:hover::before,
.gal-card:hover::before { opacity: 1; }

/* Zoom icon overlay */
.gallery-card::after,
.gal-card::after {
    content: '';
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 52px; height: 52px;
    border-radius: 50%;
    background: rgba(255,255,255,.18);
    border: 2px solid rgba(255,255,255,.7);
    backdrop-filter: blur(4px);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' fill='white' viewBox='0 0 16 16'%3E%3Cpath d='M6.5 12a5.5 5.5 0 1 0 0-11 5.5 5.5 0 0 0 0 11zM13 6.5C13 10.09 10.09 13 6.5 13S0 10.09 0 6.5 2.91 0 6.5 0 13 2.91 13 6.5z'/%3E%3Cpath d='M10.344 11.742c.03.04.062.078.098.115l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85a1.007 1.007 0 0 0-.115-.1 6.538 6.538 0 0 1-1.398 1.4z'/%3E%3Cpath fill-rule='evenodd' d='M6.5 3a.5.5 0 0 1 .5.5V6h2.5a.5.5 0 0 1 0 1H7v2.5a.5.5 0 0 1-1 0V7H3.5a.5.5 0 0 1 0-1H6V3.5a.5.5 0 0 1 .5-.5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 22px;
    opacity: 0;
    transition: transform .35s cubic-bezier(.34,1.56,.64,1), opacity .3s ease;
    z-index: 2;
    pointer-events: none;
}
.gallery-card:hover::after,
.gal-card:hover::after {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

/* Info bar at bottom */
.gal-info {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: .8rem 1rem .7rem;
    background: linear-gradient(to top, rgba(2,10,40,.85), transparent);
    transform: translateY(4px);
    opacity: 0;
    transition: all .3s ease;
    z-index: 3;
}
.gal-card:hover .gal-info,
.gallery-card:hover .gal-info {
    transform: translateY(0);
    opacity: 1;
}
.gal-tag {
    background: rgba(0,119,182,.85) !important;
    border-radius: 20px !important;
    font-size: .63rem !important;
    letter-spacing: .8px !important;
    padding: 2px 10px !important;
}
.gal-cap {
    font-size: .8rem !important;
    margin-top: 3px;
}

/* "Mostrando X trabajos" text upgrade */
#galCount {
    font-size: .78rem;
    color: #888;
    margin-top: .8rem !important;
}
#galCount strong {
    color: #0077B6;
    font-weight: 700;
}

/* Lightbox upgrade */
#gLightbox .lb-btn {
    background: rgba(2,62,138,.7) !important;
    border-radius: 12px !important;
    width: 44px !important; height: 44px !important;
    backdrop-filter: blur(8px);
    transition: all .25s ease !important;
}
#gLightbox .lb-btn:hover {
    background: rgba(0,119,182,.9) !important;
    transform: scale(1.08) !important;
}
#gLightbox .lb-caption {
    font-size: .85rem !important;
    background: rgba(0,15,40,.7) !important;
    border: 1px solid rgba(255,255,255,.08) !important;
}

/* ═══════════════════════════════════════════════════════════════════
   NAVBAR — Premium Upgrade 2025
   ═══════════════════════════════════════════════════════════════════ */

/* Override base navbar with a stronger visual identity */
.navbar.sticky-top {
    background: linear-gradient(135deg, #010A2E 0%, #023E8A 100%) !important;
    border-bottom: none !important;
    box-shadow: 0 2px 20px rgba(0,0,0,.25) !important;
    padding-top: .65rem !important;
    padding-bottom: .65rem !important;
}
.navbar.sticky-top.scrolled {
    background: linear-gradient(135deg, #010A2E 0%, #012d6b 100%) !important;
    box-shadow: 0 4px 28px rgba(0,0,0,.35) !important;
}

/* Brand name — white on dark bg */
.navbar-brand h1,
.navbar-brand span {
    background: none !important;
    -webkit-text-fill-color: #fff !important;
    color: #fff !important;
    font-weight: 800 !important;
}
/* Brand icon — keep orange */
.navbar-brand img { filter: brightness(1.1); }

/* Nav links — white */
.navbar .nav-link {
    color: rgba(255,255,255,.82) !important;
    font-weight: 600 !important;
    padding: .5rem .9rem !important;
    border-radius: 8px;
    transition: all .25s ease !important;
    letter-spacing: .2px;
}
.navbar .nav-link:hover {
    color: #fff !important;
    background: rgba(255,255,255,.12) !important;
}
.navbar .nav-link.active {
    color: #fff !important;
    background: rgba(255,255,255,.15) !important;
}
/* Remove the underline — replaced by bg highlight */
.navbar .nav-link::after { display: none !important; }

/* Social icons on navbar — white outline */
.navbar .btn-square.rounded-circle {
    background: rgba(255,255,255,.12) !important;
    border: 1px solid rgba(255,255,255,.2) !important;
    color: #fff !important;
    transition: all .25s ease !important;
}
.navbar .btn-square.rounded-circle:hover {
    background: rgba(255,255,255,.22) !important;
    transform: translateY(-2px) scale(1.08) !important;
}
.navbar a[href*="instagram"]:hover  { background: #E1306C !important; border-color: #E1306C !important; transform: translateY(-2px) scale(1.08) !important; }
.navbar a[href*="facebook"]:hover   { background: #1877F2 !important; border-color: #1877F2 !important; transform: translateY(-2px) scale(1.08) !important; }
.navbar a[href*="whatsapp"]:hover   { background: #25D366 !important; border-color: #25D366 !important; transform: translateY(-2px) scale(1.08) !important; }

/* Hamburger toggler — white lines */
.navbar-toggler { border-color: rgba(255,255,255,.4) !important; }
.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255,255,255,.85)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}

/* Mobile nav dropdown — dark */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background: linear-gradient(160deg, #010A2E, #023E8A) !important;
        border-radius: 12px !important;
        padding: .8rem 1rem !important;
        margin-top: .5rem !important;
        border: 1px solid rgba(255,255,255,.08) !important;
    }
}

/* ── BRANDS — logo only (no name) ────────────────────────────────── */
.brand-pill {
    min-width: 120px !important;
    padding: 1.2rem 1.5rem !important;
    gap: 0 !important;
}
.brand-pill-logo {
    height: 52px !important;
}
.brand-pill-logo img {
    max-height: 52px !important;
    max-width: 110px !important;
    filter: none !important;
    transition: transform .3s ease, filter .3s ease !important;
}
.brand-pill:hover .brand-pill-logo img {
    transform: scale(1.06) !important;
    filter: drop-shadow(0 3px 8px rgba(0,119,182,.22)) !important;
}

/* ═══════════════════════════════════════════════════════════════════
   HERO IMAGE GRID — Professional 2025
   ═══════════════════════════════════════════════════════════════════ */
.hero-img-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 12px;
    padding: 0 0 0 1rem;
}

.hero-img-card {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 6px 24px rgba(0,0,0,.14);
    transition: transform .4s cubic-bezier(.4,0,.2,1), box-shadow .4s ease;
    cursor: default;
}
.hero-img-card:hover {
    transform: translateY(-5px) scale(1.01);
    box-shadow: 0 16px 40px rgba(0,119,182,.22);
}
.hero-img-tall { grid-row: span 2; }
.hero-img-short { }

/* First tall card — left column */
.hero-img-card:nth-child(1) { grid-column: 1; grid-row: 1 / 3; }
/* Short cards — right column */
.hero-img-card:nth-child(2) { grid-column: 2; grid-row: 1; }
.hero-img-card:nth-child(3) { grid-column: 2; grid-row: 2; }
/* Last tall card spans 2 rows below */
/* Actually use 2x2 layout: tall|short / tall|short */

.hero-img-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .55s cubic-bezier(.4,0,.2,1);
    min-height: 160px;
}
.hero-img-tall img  { min-height: 320px; }
.hero-img-short img { min-height: 155px; }
.hero-img-card:hover img { transform: scale(1.05); }

/* Gradient overlay */
.hero-img-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(2,10,40,.65) 0%,
        rgba(0,50,120,.08) 45%,
        transparent 65%
    );
    opacity: 0;
    transition: opacity .35s ease;
    z-index: 1;
    pointer-events: none;
}
.hero-img-card:hover::before { opacity: 1; }

/* Label bottom */
.hero-img-label {
    position: absolute;
    bottom: 10px; left: 12px;
    font-size: .68rem;
    font-weight: 700;
    color: rgba(255,255,255,.95);
    background: rgba(2,62,138,.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border-radius: 20px;
    padding: 3px 11px;
    transform: translateY(6px);
    opacity: 0;
    transition: all .3s ease;
    z-index: 2;
    letter-spacing: .3px;
}
.hero-img-card:hover .hero-img-label {
    transform: translateY(0);
    opacity: 1;
}

/* Decorative border accent on first card */
.hero-img-card:nth-child(1)::after {
    content: '';
    position: absolute;
    top: -1px; right: -1px;
    width: 40%; height: 40%;
    border-top: 3px solid #00B4D8;
    border-right: 3px solid #00B4D8;
    border-radius: 0 16px 0 0;
    pointer-events: none;
    z-index: 3;
    opacity: .7;
}
.hero-img-card:last-child::after {
    content: '';
    position: absolute;
    bottom: -1px; left: -1px;
    width: 40%; height: 40%;
    border-bottom: 3px solid #0077B6;
    border-left: 3px solid #0077B6;
    border-radius: 0 0 0 16px;
    pointer-events: none;
    z-index: 3;
    opacity: .7;
}

@media (max-width: 767.98px) {
    .hero-img-grid { grid-template-columns: 1fr 1fr; gap: 8px; padding: 0; }
    .hero-img-tall img { min-height: 200px; }
    .hero-img-short img { min-height: 120px; }
}

/* ── NAVBAR: Fix dropdown on dark bg ─────────────────────────────── */
.navbar .dropdown-menu {
    background: linear-gradient(135deg, #010A2E, #023E8A) !important;
    border: 1px solid rgba(255,255,255,.1) !important;
    border-radius: 12px !important;
    padding: .5rem !important;
    box-shadow: 0 8px 28px rgba(0,0,0,.3) !important;
}
.navbar .dropdown-item {
    color: rgba(255,255,255,.85) !important;
    border-radius: 8px !important;
    padding: .45rem .9rem !important;
    font-size: .85rem !important;
    font-weight: 600 !important;
    transition: all .2s ease !important;
}
.navbar .dropdown-item:hover {
    background: rgba(255,255,255,.12) !important;
    color: #fff !important;
}

/* ── BRAND PILL: Force img display ──────────────────────────────── */
.brand-pill-logo img {
    display: block !important;
    width: auto !important;
    height: 44px !important;
    max-width: 110px !important;
    object-fit: contain !important;
}

/* ═══════════════════════════════════════════════════════════════════
   PRO IMAGE GRID — 2x2 limpio (index + about)
   Mismo layout, mismas imágenes, sin espacios en blanco
   ═══════════════════════════════════════════════════════════════════ */
.pro-img-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 10px;
    height: 460px;
}

.pro-img-card {
    position: relative;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 18px rgba(0,0,0,.12);
    transition: transform .4s cubic-bezier(.4,0,.2,1),
                box-shadow .4s ease;
    cursor: default;
}
.pro-img-card:hover {
    transform: translateY(-4px) scale(1.01);
    box-shadow: 0 14px 36px rgba(0,119,182,.2);
}
.pro-img-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .55s cubic-bezier(.4,0,.2,1);
}
.pro-img-card:hover img { transform: scale(1.06); }

/* Overlay on hover */
.pro-img-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(2,10,40,.65) 0%,
        transparent 55%
    );
    opacity: 0;
    transition: opacity .35s ease;
    z-index: 1;
    pointer-events: none;
}
.pro-img-card:hover::before { opacity: 1; }

/* Label */
.pro-img-label {
    position: absolute;
    bottom: 9px; left: 11px;
    font-size: .67rem;
    font-weight: 700;
    color: rgba(255,255,255,.96);
    background: rgba(2,62,138,.7);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border-radius: 20px;
    padding: 3px 10px;
    transform: translateY(6px);
    opacity: 0;
    transition: all .3s ease;
    z-index: 2;
    letter-spacing: .3px;
    white-space: nowrap;
}
.pro-img-card:hover .pro-img-label {
    transform: translateY(0);
    opacity: 1;
}

/* Corner accents — top-right card 1, bottom-left card 3 */
.pro-img-card:nth-child(1)::after {
    content: '';
    position: absolute;
    top: -1px; right: -1px;
    width: 38%; height: 38%;
    border-top: 3px solid #00B4D8;
    border-right: 3px solid #00B4D8;
    border-radius: 0 14px 0 0;
    pointer-events: none;
    z-index: 3;
    opacity: .75;
}
.pro-img-card:nth-child(4)::after {
    content: '';
    position: absolute;
    bottom: -1px; left: -1px;
    width: 38%; height: 38%;
    border-bottom: 3px solid #0077B6;
    border-left: 3px solid #0077B6;
    border-radius: 0 0 0 14px;
    pointer-events: none;
    z-index: 3;
    opacity: .75;
}

/* Remove old hero-img-grid styles (replaced by pro-img-grid) */
.hero-img-grid { display: none !important; }

@media (max-width: 991.98px) {
    .pro-img-grid { height: 340px; gap: 8px; }
}
@media (max-width: 575.98px) {
    .pro-img-grid { height: 260px; gap: 6px; }
}

/* ═══════════════════════════════════════════════════════════════════
   HERO SINGLE IMAGE — Encuadre profesional
   ═══════════════════════════════════════════════════════════════════ */
.hero-single-img {
    position: relative;
    border-radius: 20px;
    overflow: visible;          /* permite que los accents sobresalgan */
    display: inline-block;
    width: 100%;
}

/* Imagen principal */
.hero-single-img img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    object-position: center top;
    border-radius: 20px;
    box-shadow:
        0 20px 60px rgba(0,0,0,.18),
        0 6px 20px rgba(0,119,182,.12);
    transition: transform .5s cubic-bezier(.4,0,.2,1);
}
.hero-single-img:hover img {
    transform: scale(1.02);
}

/* Marco decorativo — esquina superior izquierda */
.hero-single-img::before {
    content: '';
    position: absolute;
    top: -10px; left: -10px;
    width: 52px; height: 52px;
    border-top: 4px solid #00B4D8;
    border-left: 4px solid #00B4D8;
    border-radius: 6px 0 0 0;
    z-index: 2;
    pointer-events: none;
    transition: width .4s ease, height .4s ease;
}
/* Marco decorativo — esquina inferior derecha */
.hero-single-img::after {
    content: '';
    position: absolute;
    bottom: -10px; right: -10px;
    width: 52px; height: 52px;
    border-bottom: 4px solid #0077B6;
    border-right: 4px solid #0077B6;
    border-radius: 0 0 6px 0;
    z-index: 2;
    pointer-events: none;
    transition: width .4s ease, height .4s ease;
}
.hero-single-img:hover::before,
.hero-single-img:hover::after {
    width: 70px; height: 70px;
}

/* Badge "Técnico certificado" — inferior izquierdo */
.hero-single-badge {
    position: absolute;
    bottom: 20px; left: 16px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(2,62,138,.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #fff;
    font-size: .75rem;
    font-weight: 700;
    padding: .5rem .9rem;
    border-radius: 30px;
    border: 1px solid rgba(255,255,255,.15);
    box-shadow: 0 4px 16px rgba(0,0,0,.25);
    z-index: 3;
    transform: translateY(4px);
    opacity: 0;
    transition: all .35s cubic-bezier(.4,0,.2,1);
}
.hero-single-img:hover .hero-single-badge {
    transform: translateY(0);
    opacity: 1;
}

/* Tag "10 años" — esquina superior derecha */
.hero-single-tag {
    position: absolute;
    top: 16px; right: 16px;
    background: #00B4D8;
    color: #fff;
    font-size: .7rem;
    font-weight: 700;
    padding: .35rem .8rem;
    border-radius: 20px;
    box-shadow: 0 4px 14px rgba(0,180,216,.4);
    z-index: 3;
    letter-spacing: .3px;
    animation: tagFloat 3.5s ease-in-out infinite;
}
@keyframes tagFloat {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-5px); }
}

@media (max-width: 991.98px) {
    .hero-single-img img { aspect-ratio: 3 / 2; }
    .hero-single-img::before,
    .hero-single-img::after { width: 36px; height: 36px; top: -7px; left: -7px; }
    .hero-single-img::after { bottom: -7px; right: -7px; top: auto; left: auto; }
}

/* ── FEATURE PAGE — imagen profesional con mismo encuadre ─── */
.feature-single-img {
    position: relative;
    border-radius: 20px;
    overflow: visible;
    display: block;
    max-width: 70%;
    margin: 0 auto;
}
.feature-single-img img {
    display: block;
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    object-position: center top;
    border-radius: 20px;
    box-shadow:
        0 20px 60px rgba(0,0,0,.18),
        0 6px 20px rgba(0,119,182,.12);
    transition: transform .5s cubic-bezier(.4,0,.2,1);
}
.feature-single-img:hover img { transform: scale(1.02); }

/* corner top-left */
.feature-single-img::before {
    content: '';
    position: absolute;
    top: -8px; left: -8px;
    width: 40px; height: 40px;
    border-top: 4px solid #00B4D8;
    border-left: 4px solid #00B4D8;
    border-radius: 6px 0 0 0;
    z-index: 2; pointer-events: none;
    transition: width .4s ease, height .4s ease;
}
/* corner bottom-right */
.feature-single-img::after {
    content: '';
    position: absolute;
    bottom: -8px; right: -8px;
    width: 40px; height: 40px;
    border-bottom: 4px solid #0077B6;
    border-right: 4px solid #0077B6;
    border-radius: 0 0 6px 0;
    z-index: 2; pointer-events: none;
    transition: width .4s ease, height .4s ease;
}
.feature-single-img:hover::before,
.feature-single-img:hover::after { width: 56px !important; height: 56px !important; }

.feature-single-badge {
    position: absolute;
    bottom: 18px; left: 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(2,62,138,.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #fff;
    font-size: .73rem; font-weight: 700;
    padding: .48rem .9rem;
    border-radius: 30px;
    border: 1px solid rgba(255,255,255,.15);
    box-shadow: 0 4px 16px rgba(0,0,0,.25);
    z-index: 3;
    transform: translateY(5px); opacity: 0;
    transition: all .35s cubic-bezier(.4,0,.2,1);
}
.feature-single-img:hover .feature-single-badge {
    transform: translateY(0); opacity: 1;
}
.feature-single-tag {
    position: absolute;
    top: 14px; right: 14px;
    background: #0077B6; color: #fff;
    font-size: .68rem; font-weight: 700;
    padding: .32rem .78rem; border-radius: 20px;
    box-shadow: 0 4px 14px rgba(0,119,182,.4);
    z-index: 3; letter-spacing: .3px;
    animation: tagFloat 3.5s ease-in-out infinite;
}

/* ═══════════════════════════════════════════════════════════════════
   RESPONSIVE AUDIT FIXES
   ═══════════════════════════════════════════════════════════════════ */

/* Hero section: stack on mobile */
@media (max-width: 991.98px) {
    .hero-single-img,
    .feature-single-img {
        max-width: 80% !important;
        margin: 1.5rem auto 0 !important;
    }
}
@media (max-width: 575.98px) {
    .hero-single-img,
    .feature-single-img {
        max-width: 95% !important;
    }
    /* Navbar brand text smaller on mobile */
    .navbar-brand h1 { font-size: .9rem !important; }
    /* Service cards full width */
    .service-item { margin-bottom: .5rem; }
    /* Testimonial cards padding reduced */
    .testimonial-item { padding: 1.5rem 1rem !important; }
    /* Brands pill smaller */
    .brand-pill { min-width: 95px !important; padding: .8rem 1rem !important; }
    /* Gallery filter wrap scroll on mobile */
    .gfilter-wrap {
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        justify-content: flex-start !important;
        padding: 6px 8px !important;
        border-radius: 12px !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .gfilter-wrap::-webkit-scrollbar { display: none; }
    .gfilter-btn { white-space: nowrap !important; font-size: .74rem !important; }
    /* Quote section mobile */
    .quote-text, .quote-form { min-height: 300px !important; }
    /* Stat cards smaller font */
    .facts h1.display-4 { font-size: 2.2rem !important; }
    /* Footer stack */
    .footer .col-lg-4 { margin-bottom: 1rem; }
}

/* Medium screens (tablets) */
@media (min-width: 576px) and (max-width: 991.98px) {
    .hero-single-img img,
    .feature-single-img img { aspect-ratio: 1 / 1 !important; }
    .brand-pill { min-width: 110px !important; }
}

/* Touch device: disable hover effects that don't translate well */
@media (hover: none) {
    .hero-single-img:hover img,
    .feature-single-img:hover img,
    .pro-img-card:hover img,
    .service-item:hover img.img-fluid { transform: none !important; }
    .hero-single-badge { opacity: 1 !important; transform: none !important; }
    .hero-single-tag { animation: none !important; }
    .simg-badge { opacity: 1 !important; transform: none !important; }
}

/* ═══════════════════════════════════════════════════════════════════
   HERO IMAGE SIZER — 30% reducción definitiva
   ═══════════════════════════════════════════════════════════════════ */
.hero-img-sizer {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 0 .5rem;
}
.hero-img-sizer .hero-single-img {
    width: 70% !important;      /* 30% más chico que el col */
    max-width: 70% !important;
}
@media (max-width: 991.98px) {
    .hero-img-sizer .hero-single-img { width: 75% !important; max-width: 75% !important; }
}
@media (max-width: 575.98px) {
    .hero-img-sizer .hero-single-img { width: 90% !important; max-width: 90% !important; }
}

/* ═══════════════════════════════════════════════════════════════════
   SERVICE CARDS — Diseño visual premium 2025
   ═══════════════════════════════════════════════════════════════════ */

/* Reset base card */
.container-xxl .card.border-0.shadow-sm.p-4.h-100 {
    padding: 0 !important;
    border-radius: 16px !important;
    border: none !important;
    overflow: hidden;
    box-shadow: none !important;
    transition: transform .38s cubic-bezier(.4,0,.2,1), box-shadow .38s ease !important;
    background: #fff !important;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 20px 50px rgba(0,119,182,.18) !important;
}

/* Color header band per card position */
.container-xxl .row.g-4 > div:nth-child(1) .card.border-0 { border-top: 4px solid #0077B6 !important; }
.container-xxl .row.g-4 > div:nth-child(2) .card.border-0 { border-top: 4px solid #023E8A !important; }
.container-xxl .row.g-4 > div:nth-child(3) .card.border-0 { border-top: 4px solid #00B4D8 !important; }
.container-xxl .row.g-4 > div:nth-child(4) .card.border-0 { border-top: 4px solid #0096C7 !important; }
.container-xxl .row.g-4 > div:nth-child(5) .card.border-0 { border-top: 4px solid #0077B6 !important; }
.container-xxl .row.g-4 > div:nth-child(6) .card.border-0 { border-top: 4px solid #023E8A !important; }
.container-xxl .row.g-4 > div:nth-child(7) .card.border-0 { border-top: 4px solid #00B4D8 !important; }
.container-xxl .row.g-4 > div:nth-child(8) .card.border-0 { border-top: 4px solid #0096C7 !important; }
.container-xxl .row.g-4 > div:nth-child(9) .card.border-0 { border-top: 4px solid #0077B6 !important; }
.container-xxl .row.g-4 > div:nth-child(10) .card.border-0 { border-top: 4px solid #023E8A !important; }

/* Inner padding wrapper */
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > * {
    padding-left: 1.6rem;
    padding-right: 1.6rem;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > h4 {
    padding: 1.4rem 1.6rem .9rem !important;
    margin: 0 !important;
    font-size: 1rem !important;
    font-weight: 700 !important;
    background: linear-gradient(135deg, #f4f8ff 0%, #eef4ff 100%);
    border-bottom: 1px solid rgba(0,119,182,.09);
    display: flex;
    align-items: center;
    gap: .5rem;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > h4 i {
    width: 36px; height: 36px;
    border-radius: 10px;
    background: linear-gradient(135deg, #0077B6, #023E8A);
    color: #fff !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: .85rem;
    flex-shrink: 0;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > p {
    padding: 1rem 1.6rem .6rem !important;
    margin: 0 !important;
    font-size: .88rem;
    color: #555;
    line-height: 1.7;
    border-bottom: 1px dashed rgba(0,119,182,.1);
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > ul {
    padding: .8rem 1.6rem 1.4rem 2.8rem !important;
    margin: 0 !important;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > ul li {
    font-size: .83rem;
    color: #444;
    padding: .2rem 0;
    position: relative;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > ul li::marker {
    color: #0077B6;
}

/* Shimmer effect on hover */
.container-xxl .card.border-0.shadow-sm.p-4.h-100 {
    position: relative;
    overflow: hidden;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100::after {
    content: '';
    position: absolute;
    top: 0; left: -75%;
    width: 50%;
    height: 100%;
    background: linear-gradient(120deg, transparent 0%, rgba(255,255,255,.15) 50%, transparent 100%);
    transform: skewX(-20deg);
    transition: left .65s ease;
    pointer-events: none;
    z-index: 1;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100:hover::after {
    left: 125%;
}

/* Shadow on the card container */
.container-xxl .row.g-4 > div > .card.border-0 {
    box-shadow: 0 2px 14px rgba(0,0,0,.07) !important;
}

/* ═══════════════════════════════════════════════════════════════════
   PERFORMANCE FIX — Anti-flicker
   ═══════════════════════════════════════════════════════════════════ */
/* Prevent layout shift during font load */
html { font-display: optional; }

/* Reduce paint area for fixed elements */
#ram-cursor, #ram-cursor-ring, #scroll-progress {
    will-change: transform, left, top, width;
}
.whatsapp-float { will-change: transform; }

/* ═══════════════════════════════════════════════════════════════════
   STATS V2 — Uniform equal-sized cards
   ═══════════════════════════════════════════════════════════════════ */
.stat-card-v2 {
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 16px;
    padding: 1.8rem 1.5rem;
    text-align: center;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    height: 130px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    transition: all .35s cubic-bezier(.4,0,.2,1);
    position: relative;
    overflow: hidden;
}
.stat-card-v2::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #00B4D8, #0077B6);
    transform: scaleX(0);
    transition: transform .35s ease;
}
.stat-card-v2:hover {
    background: rgba(255,255,255,.12);
    transform: translateY(-4px);
}
.stat-card-v2:hover::after { transform: scaleX(1); }

.stat-v2-num {
    font-family: 'Roboto Slab', serif;
    font-size: 2.8rem;
    font-weight: 800;
    color: #fff;
    line-height: 1;
    background: linear-gradient(135deg, #fff 40%, #00B4D8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.stat-v2-label {
    font-size: .72rem;
    font-weight: 700;
    color: #00B4D8;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

/* ═══════════════════════════════════════════════════════════════════
   FEATURE PAGE — Refined elegant frame
   ═══════════════════════════════════════════════════════════════════ */
.feature-single-img {
    position: relative;
    max-width: 70% !important;
    margin: 0 auto !important;
}
/* Replace thick corner brackets with thin elegant full border */
.feature-single-img::before,
.feature-single-img::after {
    display: none !important;
}
/* Elegant thin full border frame */
.feature-single-img img {
    border-radius: 12px !important;
    box-shadow:
        0 0 0 1px rgba(0,180,216,.25),
        0 0 0 6px rgba(0,119,182,.08),
        0 20px 60px rgba(0,0,0,.2) !important;
    transition: box-shadow .4s ease, transform .5s cubic-bezier(.4,0,.2,1) !important;
}
.feature-single-img:hover img {
    box-shadow:
        0 0 0 1px rgba(0,180,216,.5),
        0 0 0 8px rgba(0,119,182,.12),
        0 28px 70px rgba(0,0,0,.25) !important;
    transform: scale(1.02) !important;
}
/* Keep badge and tag */
.feature-single-badge { display: inline-flex; }
.feature-single-tag { display: block; }

/* ═══════════════════════════════════════════════════════════════════
   SERVICE CARDS — Images + Premium Typography
   ═══════════════════════════════════════════════════════════════════ */

/* Service image at top of card */
.svc-detail-img {
    position: relative;
    overflow: hidden;
    height: 170px;
    border-radius: 14px 14px 0 0;
}
.svc-detail-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .5s cubic-bezier(.4,0,.2,1);
    filter: brightness(.88) saturate(1.1);
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100:hover .svc-detail-img img {
    transform: scale(1.06);
    filter: brightness(.95) saturate(1.15);
}
/* Gradient over image */
.svc-detail-img::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 60%;
    background: linear-gradient(to top, rgba(2,10,40,.5), transparent);
    pointer-events: none;
}

/* Typography upgrade for service cards */
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > h4 {
    font-family: 'Roboto Slab', serif !important;
    font-size: .95rem !important;
    font-weight: 700 !important;
    letter-spacing: -.2px;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > p {
    font-family: 'Roboto', sans-serif !important;
    font-size: .84rem !important;
    color: #4a5568 !important;
    line-height: 1.75 !important;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > ul li {
    font-family: 'Roboto', sans-serif !important;
    font-size: .8rem !important;
    color: #4a5568 !important;
    padding: .25rem 0 !important;
}
/* Bullet as blue checkmark */
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > ul {
    list-style: none !important;
    padding-left: 1.6rem !important;
}
.container-xxl .card.border-0.shadow-sm.p-4.h-100 > ul li::before {
    content: '✓';
    position: absolute;
    left: -1.2rem;
    color: #0077B6;
    font-weight: 700;
    font-size: .8rem;
}

/* ══════════════════════════════════════════════════════════════════
   SVC-CARD — Tarjetas de servicio unificadas (imagen + contenido)
   Reemplaza la duplicación service-grid + service-detail
   ══════════════════════════════════════════════════════════════════ */

.svc-card {
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 4px 24px rgba(0,119,182,.09);
    transition: transform .38s cubic-bezier(.4,0,.2,1),
                box-shadow .38s cubic-bezier(.4,0,.2,1);
    display: flex;
    flex-direction: column;
}
.svc-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0,119,182,.2);
}

/* Imagen + ícono superpuesto */
.svc-card-img {
    position: relative;
    overflow: hidden;
}
.svc-card-img img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: transform .5s cubic-bezier(.4,0,.2,1);
}
.svc-card:hover .svc-card-img img {
    transform: scale(1.05);
}

/* Línea superior de color al hacer hover */
.svc-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #00B4D8, #0077B6);
    transform: scaleX(0);
    transition: transform .4s cubic-bezier(.4,0,.2,1);
    border-radius: 3px 3px 0 0;
    z-index: 2;
}
.svc-card:hover::before { transform: scaleX(1); }
.svc-card { position: relative; }

/* Badge ícono en la esquina inferior derecha de la imagen */
.svc-card-icon {
    position: absolute;
    bottom: -20px;
    right: 20px;
    width: 48px;
    height: 48px;
    background: #0077B6;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(0,119,182,.4);
    z-index: 3;
    transition: background .3s ease, transform .3s ease;
}
.svc-card:hover .svc-card-icon {
    background: #023E8A;
    transform: scale(1.1) rotate(10deg);
}
.svc-card-icon img {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

/* Cuerpo del contenido */
.svc-card-body {
    padding: 2rem 1.5rem 1.5rem;
    padding-top: 2.4rem; /* espacio para el ícono que sobresale */
    flex: 1;
    display: flex;
    flex-direction: column;
}
.svc-card-body h4 {
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.35;
    margin-bottom: .65rem;
}
.svc-card-body p {
    font-size: .875rem;
    line-height: 1.65;
    color: #5a6a7e;
    flex: 1;
}

/* Lista de beneficios */
.svc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    border-top: 1px solid rgba(0,119,182,.1);
    padding-top: .85rem;
}
.svc-list li {
    position: relative;
    padding-left: 1.4rem;
    font-size: .82rem;
    color: #4a5568;
    line-height: 1.6;
    padding-bottom: .25rem;
}
.svc-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #0077B6;
    font-weight: 700;
    font-size: .8rem;
}

/* Responsive */
@media (max-width: 575.98px) {
    .svc-card-img img { height: 180px; }
    .svc-card-body { padding: 2rem 1.2rem 1.2rem; }
}
