:root {
    --sb-navy:       #1a3a5c;
    --sb-blue:       #2563a8;
    --sb-green:      #00a651;
    --sb-green-dark: #008040;
    --sb-dark:       #111d2e;
    --sb-gray:       #f5f7fa;
    --shadow-sm:     0 2px 8px rgba(0,0,0,0.07);
    --shadow-md:     0 6px 24px rgba(0,0,0,0.10);
    --radius:        10px;
}

html {
    scroll-behavior: smooth; /* prefers-reduced-motion lo desactiva más abajo */
    overflow-x: hidden;
}
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: #333;
    overflow-x: hidden;
}

/* ── Secciones ── */
.page-section {
    padding: 80px 0;
}
.bg-sb-gray { background: var(--sb-gray); }
.bg-white    { background: #fff; }

/* ── Navbar ── */
.site-nav {
    background: rgba(255,255,255,0.97);
    backdrop-filter: blur(8px);
    box-shadow: 0 1px 12px rgba(0,0,0,0.08);
    padding: 10px 0;
}
.site-nav .navbar-brand img {
    height: 42px;
    width: auto;
}
.site-nav .nav-back {
    font-size: 0.85rem;
    color: #666;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s;
}
.site-nav .nav-back:hover { color: var(--sb-green); }
.site-nav .btn-nav-call {
    background: var(--sb-green);
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s, transform 0.2s;
}
.site-nav .btn-nav-call:hover {
    background: var(--sb-green-dark);
    color: white;
    transform: translateY(-1px);
}

/* ── Hero ── */
.hero {
    min-height: 82vh;
    background:
        linear-gradient(135deg, rgba(17,29,46,0.82) 0%, rgba(26,58,92,0.70) 100%),
        url('../img/lexnet/lexnet_bg1.jpg') center center / cover no-repeat;
    display: flex;
    align-items: center;
    color: white;
    text-align: center;
    padding: 110px 0 70px;
}
.hero h1 {
    font-size: clamp(1.9rem, 4.5vw, 3.2rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.1rem;
}
.hero .lead {
    font-size: clamp(1rem, 2vw, 1.25rem);
    opacity: 0.88;
    max-width: 600px;
    margin: 0 auto 2.2rem;
}
.hero .badge-tag {
    display: inline-block;
    background: rgba(0,166,81,0.25);
    border: 1px solid rgba(0,166,81,0.5);
    color: #a3f0c4;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 5px 14px;
    border-radius: 50px;
    margin-bottom: 1.4rem;
}
.btn-hero {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--sb-green);
    color: white;
    border: none;
    padding: 14px 36px;
    font-size: 1.05rem;
    font-weight: 700;
    border-radius: 50px;
    text-decoration: none;
    transition: background 0.3s, transform 0.3s, box-shadow 0.3s;
    box-shadow: 0 4px 20px rgba(0,166,81,0.35);
}
.btn-hero:hover {
    background: var(--sb-green-dark);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(0,166,81,0.45);
}
.hero-scroll {
    display: inline-block;
    margin-top: 3rem;
    color: rgba(255,255,255,0.5);
    font-size: 1.5rem;
    animation: bounce 2.2s ease-in-out infinite;
}
@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(9px); }
}

/* ── Section titles ── */
.section-eyebrow {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--sb-green-dark); /* #008040 sobre blanco = 4.93:1, cumple WCAG AA */
    margin-bottom: 0.5rem;
}
.section-title {
    font-size: clamp(1.6rem, 3vw, 2.1rem);
    font-weight: 800;
    color: var(--sb-navy);
    margin-bottom: 0.8rem;
}
.section-title-line {
    width: 48px;
    height: 4px;
    background: var(--sb-green);
    border-radius: 2px;
    margin: 0 auto 1.4rem;
}
.section-title-line.left { margin-left: 0; }
.section-sub {
    color: #666;
    font-size: 1.05rem;
    max-width: 640px;
    margin: 0 auto 2.5rem;
}
.section-desc {
    color: #666;
    font-size: 0.97rem;
    line-height: 1.7;
}

/* ── Service cards ── */
.service-card {
    background: white;
    border-radius: var(--radius);
    padding: 2.4rem 2rem;
    box-shadow: var(--shadow-sm);
    height: 100%;
    border-top: 4px solid transparent;
    transition: transform 0.3s, box-shadow 0.3s, border-top-color 0.3s;
}
.service-card:hover {
    transform: translateY(-7px);
    box-shadow: var(--shadow-md);
    border-top-color: var(--sb-green);
}
.service-icon {
    width: 64px;
    height: 64px;
    background: rgba(37,99,168,0.08);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.9rem;
    color: var(--sb-blue);
    margin-bottom: 1.3rem;
}
.service-card h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--sb-navy);
    margin-bottom: 0.8rem;
}
.service-card p {
    color: #555;
    font-size: 0.97rem;
    line-height: 1.65;
    margin: 0;
}

/* ── Periciales list ── */
.pericial-item {
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
    padding: 0.9rem 1.1rem;
    background: white;
    border-radius: 8px;
    margin-bottom: 0.7rem;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.2s;
}
.pericial-item:hover { box-shadow: var(--shadow-md); }
.pericial-item i {
    color: var(--sb-green);
    font-size: 1.15rem;
    flex-shrink: 0;
    margin-top: 2px;
}
.pericial-item span {
    font-size: 0.96rem;
    color: #444;
    line-height: 1.5;
}

/* ── Coverage cards ── */
.island-card {
    background: white;
    border-radius: var(--radius);
    padding: 1.6rem 1.8rem;
    box-shadow: var(--shadow-sm);
    height: 100%;
}
.island-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--sb-navy);
    border-left: 4px solid var(--sb-green);
    padding-left: 0.75rem;
    margin-bottom: 0.6rem;
}
.island-card p {
    font-size: 0.92rem;
    color: #666;
    margin: 0;
    line-height: 1.5;
}

/* ── FAQ Accordion ── */
.accordion-button {
    font-weight: 600;
    color: var(--sb-navy);
    background: white;
}
.accordion-button:not(.collapsed) {
    background: rgba(0,166,81,0.06);
    color: var(--sb-navy);
    box-shadow: none;
}
.accordion-button:focus {
    box-shadow: 0 0 0 0.2rem rgba(0,166,81,0.2);
}
.accordion-button::after {
    filter: invert(40%) sepia(80%) saturate(400%) hue-rotate(100deg);
}
.accordion-item {
    border: 1px solid rgba(0,0,0,0.08);
    margin-bottom: 0.5rem;
    border-radius: var(--radius) !important;
    overflow: hidden;
}
.accordion-body {
    color: #555;
    font-size: 0.97rem;
    line-height: 1.7;
}

/* ── Stats strip ── */
.stats-strip {
    background: var(--sb-navy);
    color: white;
    padding: 50px 0;
}
.stat-item .stat-num {
    font-size: 2.4rem;
    font-weight: 800;
    color: var(--sb-green);
    line-height: 1;
}
.stat-item .stat-label {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.7);
    margin-top: 0.3rem;
}

/* ── CTA ── */
.cta-section {
    background: linear-gradient(135deg, var(--sb-navy) 0%, var(--sb-dark) 100%);
    color: white;
    padding: 90px 0;
    text-align: center;
}
.cta-section h2 {
    font-size: clamp(1.5rem, 3.5vw, 2.3rem);
    font-weight: 800;
    margin-bottom: 1rem;
}
.cta-section p {
    font-size: 1.1rem;
    opacity: 0.8;
    max-width: 520px;
    margin: 0 auto 2.5rem;
}
.btn-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 15px 40px;
    font-size: 1.05rem;
    font-weight: 700;
    border-radius: 50px;
    text-decoration: none;
    transition: background 0.3s, transform 0.3s, border-color 0.3s, color 0.3s;
}
.btn-cta-green {
    background: var(--sb-green);
    color: white;
    box-shadow: 0 4px 20px rgba(0,166,81,0.35);
}
.btn-cta-green:hover {
    background: var(--sb-green-dark);
    color: white;
    transform: translateY(-2px);
}
.btn-cta-outline {
    background: transparent;
    color: white;
    border: 2px solid rgba(255,255,255,0.5);
}
.btn-cta-outline:hover {
    background: white;
    color: var(--sb-navy);
    border-color: white;
}

/* ── Footer ── */
.site-footer {
    background: var(--sb-dark);
    color: rgba(255,255,255,0.75);
    padding: 55px 0 24px;
    font-size: 0.92rem;
}
.site-footer h4 {
    color: var(--sb-green);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1.1rem;
}
.site-footer a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: color 0.2s;
}
.site-footer a:hover { color: var(--sb-green); }
.site-footer li { margin-bottom: 0.4rem; }
.footer-social a {
    display: inline-flex;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
    align-items: center;
    justify-content: center;
    margin-right: 6px;
    transition: background 0.3s;
}
.footer-social a:hover { background: var(--sb-green); color: white; }
.footer-divider { border-color: rgba(255,255,255,0.08); margin: 2rem 0 1.2rem; }
.footer-copy { font-size: 0.82rem; color: rgba(255,255,255,0.4); }
.footer-tagline { font-size: 0.85rem; }

/* ── Cookie banner ── */
.cookie-banner {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: rgba(10,20,35,0.96);
    color: white;
    padding: 18px 24px;
    z-index: 1060;
    backdrop-filter: blur(6px);
}
.cookie-banner.hidden { display: none; }
.cookie-banner-inner { max-width: 1200px; margin: 0 auto; }
.cookie-banner p { margin: 0; font-size: 0.88rem; line-height: 1.5; }
.cookie-banner a { color: var(--sb-green); }
.cookie-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}
.btn-cookie {
    background: var(--sb-green);
    color: white;
    border: none;
    padding: 9px 22px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.2s;
}
.btn-cookie:hover { background: var(--sb-green-dark); }
.btn-cookie-reject {
    background: transparent;
    color: rgba(255,255,255,0.6);
    border: 1px solid rgba(255,255,255,0.25);
    padding: 9px 18px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.2s, border-color 0.2s;
}
.btn-cookie-reject:hover {
    color: white;
    border-color: rgba(255,255,255,0.6);
}

/* ── WhatsApp float ── */
.whatsapp-float {
    position: fixed;
    bottom: 24px; right: 24px;
    width: 58px; height: 58px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(0,0,0,0.25);
    z-index: 1000;
    text-decoration: none;
    transition: transform 0.3s, bottom 0.3s;
}
.whatsapp-float:hover { transform: scale(1.12); }

/* ── Skip link (accesibilidad) ── */
.skip-link {
    position: absolute;
    top: -100%;
    left: 0;
    background: var(--sb-navy);
    color: white;
    padding: 10px 18px;
    font-weight: 600;
    font-size: 0.9rem;
    z-index: 9999;
    text-decoration: none;
    border-radius: 0 0 var(--radius) 0;
    transition: top 0.2s;
}
.skip-link:focus {
    top: 0;
}

/* ── Respeta prefers-reduced-motion (WCAG 2.3.3) ── */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    [data-aos] {
        opacity: 1 !important;
        transform: none !important;
    }
    .hero-scroll {
        animation: none;
    }
}

/* ── Sube el botón cuando el banner de cookies está visible ── */
body.cookie-pending .whatsapp-float {
    bottom: 92px;
}

/* ── Fallback para navegadores sin soporte de backdrop-filter ── */
@supports not (backdrop-filter: blur(1px)) {
    .site-nav     { background: rgba(255,255,255,0.99); }
    .cookie-banner { background: rgba(10,20,35,0.99); }
}
