:root {
    --ds-bg:      #08111e;
    --ds-navy:    #0f2240;
    --ds-blue:    #2563eb;
    --ds-blue-d:  #1d4ed8;
    --ds-cyan:    #06b6d4;
    --ds-green:   #00a651;
    --ds-green-d: #008040;
    --ds-gray:    #f5f7fa;
    --ds-dark:    #0a0f1a;
    --shadow-sm:  0 2px 8px rgba(0,0,0,0.07);
    --shadow-md:  0 8px 32px rgba(0,0,0,0.12);
    --radius:     12px;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: #1e293b;
    overflow-x: hidden;
}

/* ── Skip link ── */
.skip-link {
    position: absolute;
    top: -100%;
    left: 0;
    background: var(--ds-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; }

/* ── 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(--ds-blue); }
.site-nav .btn-nav-call {
    background: var(--ds-blue);
    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(--ds-blue-d);
    color: white;
    transform: translateY(-1px);
}

/* ── Hero ── */
.hero {
    min-height: 90vh;
    background:
        linear-gradient(140deg, rgba(8,17,30,0.94) 0%, rgba(15,34,64,0.88) 55%, rgba(37,99,235,0.78) 100%),
        url('../img/portfolio/desarrollo-software.jpeg') center center / cover no-repeat;
    display: flex;
    align-items: center;
    color: white;
    text-align: center;
    padding: 110px 0 80px;
    position: relative;
    overflow: hidden;
}
/* Subtle grid overlay — efecto tech */
.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
}
/* Blob de luz derecha */
.hero::before {
    content: '';
    position: absolute;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(37,99,235,0.22) 0%, transparent 65%);
    top: -120px;
    right: -150px;
    pointer-events: none;
}
.hero .container { position: relative; z-index: 1; }
.hero h1 {
    font-size: clamp(2rem, 5vw, 3.6rem);
    font-weight: 900;
    line-height: 1.15;
    margin-bottom: 1.2rem;
    letter-spacing: -0.02em;
}
.hero-highlight {
    background: linear-gradient(90deg, #4ade80, #38bdf8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero .lead {
    font-size: clamp(1rem, 2vw, 1.22rem);
    opacity: 0.85;
    max-width: 600px;
    margin: 0 auto 2.4rem;
    line-height: 1.65;
}
.hero .badge-tag {
    display: inline-block;
    background: rgba(37,99,235,0.22);
    border: 1px solid rgba(56,189,248,0.4);
    color: #7dd3fc;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 5px 16px;
    border-radius: 50px;
    margin-bottom: 1.5rem;
}
.hero-pills {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 2.5rem;
}
.hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    color: rgba(255,255,255,0.8);
    font-size: 0.85rem;
    font-weight: 500;
    padding: 5px 14px;
    border-radius: 50px;
}
.btn-hero {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--ds-blue);
    color: white;
    border: none;
    padding: 15px 38px;
    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 24px rgba(37,99,235,0.45);
}
.btn-hero:hover {
    background: var(--ds-blue-d);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(37,99,235,0.55);
}
.btn-hero-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    color: white;
    border: 2px solid rgba(255,255,255,0.45);
    padding: 13px 36px;
    font-size: 1.05rem;
    font-weight: 600;
    border-radius: 50px;
    text-decoration: none;
    transition: background 0.3s, border-color 0.3s, color 0.3s, transform 0.3s;
}
.btn-hero-outline:hover {
    background: white;
    color: var(--ds-navy);
    border-color: white;
    transform: translateY(-2px);
}

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

/* ── Section titles ── */
.section-eyebrow {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.11em;
    color: var(--ds-blue);      /* #2563eb sobre blanco = 5.34:1, cumple WCAG AA */
    margin-bottom: 0.5rem;
}
.bg-dark-section .section-eyebrow { color: #7dd3fc; }
.section-title {
    font-size: clamp(1.7rem, 3.2vw, 2.3rem);
    font-weight: 900;
    color: var(--ds-navy);
    margin-bottom: 0.8rem;
    letter-spacing: -0.02em;
}
.bg-dark-section .section-title { color: white; }
.section-title-line {
    width: 52px;
    height: 4px;
    background: var(--ds-blue);
    border-radius: 2px;
    margin: 0 auto 1.5rem;
}
.section-title-line.left { margin-left: 0; }
.section-sub {
    color: #64748b;
    font-size: 1.05rem;
    max-width: 650px;
    margin: 0 auto 2.8rem;
    line-height: 1.7;
}
.bg-dark-section .section-sub { color: rgba(255,255,255,0.65); }

/* ── 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(-8px);
    box-shadow: 0 16px 48px rgba(37,99,235,0.14);
    border-top-color: var(--ds-blue);
}
.service-icon {
    width: 60px;
    height: 60px;
    background: rgba(37,99,235,0.08);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.7rem;
    color: var(--ds-blue);
    margin-bottom: 1.3rem;
    transition: background 0.3s, color 0.3s;
}
.service-card:hover .service-icon {
    background: var(--ds-blue);
    color: white;
}
.service-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ds-navy);
    margin-bottom: 0.8rem;
}
.service-card p {
    color: #64748b;
    font-size: 0.96rem;
    line-height: 1.65;
    margin: 0;
}

/* ── Proceso / Steps ── */
.process-step {
    position: relative;
    padding-left: 90px;
    margin-bottom: 3rem;
}
.process-step:last-child { margin-bottom: 0; }
.step-badge {
    position: absolute;
    left: 0;
    top: 0;
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--ds-blue) 0%, var(--ds-cyan) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 900;
    color: white;
    flex-shrink: 0;
    box-shadow: 0 4px 16px rgba(37,99,235,0.35);
}
.process-step h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--ds-navy);
    margin-bottom: 0.5rem;
    margin-top: 0.6rem;
}
.process-step p {
    color: #64748b;
    font-size: 0.97rem;
    line-height: 1.7;
    margin: 0;
}

/* ── Tech stack ── */
.stack-group {
    margin-bottom: 2rem;
}
.stack-group-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #94a3b8;
    margin-bottom: 0.75rem;
}
.stack-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.stack-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 16px;
    border-radius: 8px;
    font-size: 0.88rem;
    font-weight: 600;
    border: 1px solid transparent;
}
.stack-badge--frontend {
    background: rgba(6,182,212,0.08);
    color: #0891b2;
    border-color: rgba(6,182,212,0.2);
}
.stack-badge--backend {
    background: rgba(37,99,235,0.08);
    color: #2563eb;
    border-color: rgba(37,99,235,0.2);
}
.stack-badge--data {
    background: rgba(0,166,81,0.08);
    color: #008040;
    border-color: rgba(0,166,81,0.2);
}
.stack-badge--infra {
    background: rgba(124,58,237,0.08);
    color: #7c3aed;
    border-color: rgba(124,58,237,0.2);
}
.stack-badge--iot {
    background: rgba(234,88,12,0.08);
    color: #c2410c;
    border-color: rgba(234,88,12,0.2);
}

/* ── Por qué Smartbytes ── */
.why-card {
    background: white;
    border-radius: var(--radius);
    padding: 2.4rem 2rem;
    box-shadow: var(--shadow-sm);
    height: 100%;
    border-left: 5px solid var(--ds-blue);
    transition: transform 0.3s, box-shadow 0.3s;
}
.why-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}
.why-icon {
    font-size: 2.2rem;
    color: var(--ds-blue);
    margin-bottom: 1.1rem;
    display: block;
}
.why-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ds-navy);
    margin-bottom: 0.75rem;
}
.why-card p {
    color: #64748b;
    font-size: 0.96rem;
    line-height: 1.7;
    margin: 0;
}

/* ── FAQ Accordion ── */
.accordion-button {
    font-weight: 600;
    color: var(--ds-navy);
    background: white;
    font-size: 1rem;
}
.accordion-button:not(.collapsed) {
    background: rgba(37,99,235,0.05);
    color: var(--ds-navy);
    box-shadow: none;
}
.accordion-button:focus {
    box-shadow: 0 0 0 0.2rem rgba(37,99,235,0.2);
}
.accordion-button::after {
    filter: invert(25%) sepia(80%) saturate(700%) hue-rotate(200deg);
}
.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: #64748b;
    font-size: 0.97rem;
    line-height: 1.75;
}

/* ── CTA ── */
.cta-section {
    background: linear-gradient(135deg, var(--ds-navy) 0%, var(--ds-dark) 100%);
    color: white;
    padding: 100px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.cta-section::before {
    content: '';
    position: absolute;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(37,99,235,0.18) 0%, transparent 65%);
    bottom: -200px;
    left: 50%;
    transform: translateX(-50%);
    pointer-events: none;
}
.cta-section h2 {
    font-size: clamp(1.6rem, 3.5vw, 2.6rem);
    font-weight: 900;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
    position: relative;
}
.cta-section p {
    font-size: 1.1rem;
    opacity: 0.75;
    max-width: 520px;
    margin: 0 auto 2.8rem;
    position: relative;
}
.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;
    position: relative;
}
.btn-cta-primary {
    background: var(--ds-blue);
    color: white;
    box-shadow: 0 4px 20px rgba(37,99,235,0.45);
}
.btn-cta-primary:hover {
    background: #60a5fa;
    color: white;
    transform: translateY(-2px);
}
.btn-cta-outline {
    background: transparent;
    color: white;
    border: 2px solid rgba(255,255,255,0.45);
}
.btn-cta-outline:hover {
    background: white;
    color: var(--ds-navy);
    border-color: white;
    transform: translateY(-2px);
}

/* ── Footer ── */
.site-footer {
    background: var(--ds-dark);
    color: rgba(255,255,255,0.72);
    padding: 60px 0 24px;
    font-size: 0.92rem;
}
.site-footer h4 {
    color: #7dd3fc;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1.1rem;
}
.site-footer a {
    color: rgba(255,255,255,0.68);
    text-decoration: none;
    transition: color 0.2s;
}
.site-footer a:hover { color: #7dd3fc; }
.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.07);
    align-items: center;
    justify-content: center;
    margin-right: 6px;
    transition: background 0.3s;
}
.footer-social a:hover { background: var(--ds-blue); color: white; }
.footer-divider { border-color: rgba(255,255,255,0.07); margin: 2rem 0 1.2rem; }
.footer-copy { font-size: 0.82rem; color: rgba(255,255,255,0.38); }
.footer-tagline { font-size: 0.85rem; }

/* ── Cookie banner ── */
.cookie-banner {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: rgba(8,17,30,0.97);
    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: #7dd3fc; }
.cookie-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}
.btn-cookie {
    background: var(--ds-blue);
    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(--ds-blue-d); }
.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); }
body.cookie-pending .whatsapp-float { bottom: 92px; }

/* ── 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;
    }
}

/* ── Fallback backdrop-filter ── */
@supports not (backdrop-filter: blur(1px)) {
    .site-nav     { background: rgba(255,255,255,0.99); }
    .cookie-banner { background: rgba(8,17,30,0.99); }
}
