/* ===== HERO (oscuro, animado) ===== */
.services-hero {
    --h-bg: #082a49;
    --h-green: #5dad19;
    --h-teal: #46accc;
    --h-amber: #fde046;
    position: relative;
    overflow: hidden;
    background: var(--h-bg);
    color: #F3F5EF;
    padding: 96px 0 0;
    isolation: isolate
}

.mono {
    font-family: 'IBM Plex Mono', ui-monospace, monospace
}

/* fondo */
.hero-photo {
    position: absolute;
    inset: 0;
    z-index: -4;
    background: linear-gradient(180deg, #082a49, #08100df5), url('../../assets/img/hero.jpg') center/cover no-repeat
}

.hero-blob {
    position: absolute;
    z-index: -3;
    border-radius: 50%;
    filter: blur(90px);
    opacity: .55;
    transition: transform .3s ease-out;
    will-change: transform
}

.blob-a {
    width: 520px;
    height: 520px;
    background: var(--h-bg);
    top: -160px;
    right: -80px;
    animation: drift 16s ease-in-out infinite
}

.blob-b {
    width: 460px;
    height: 460px;
    background: var(--h-bg);
    bottom: -120px;
    left: -140px;
    opacity: .4;
    animation: drift 20s ease-in-out infinite reverse
}

.blob-c {
    width: 320px;
    height: 320px;
    background: var(--h-bg);
    top: 38%;
    left: 42%;
    opacity: .22;
    animation: drift 24s ease-in-out infinite
}

@keyframes drift {
    50% {
        translate: 40px -30px
    }
}

.hero-grid-bg {
    position: absolute;
    inset: 0;
    z-index: -2;
    background-image: linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px), linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px);
    background-size: 48px 48px;
    -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 30%, transparent 85%);
    mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 30%, transparent 85%);
    animation: grid-move 12s linear infinite
}

@keyframes grid-move {
    to {
        background-position: 48px 48px
    }
}

.hero-layout {
    position: relative;
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    gap: 56px;
    align-items: center;
    margin-bottom: 40px
}

/* texto */
.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 11.5px;
    letter-spacing: .1em;
    text-transform: uppercase;
    padding: 8px 14px;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 999px;
    background: rgba(255, 255, 255, .05);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    margin-bottom: 26px;
    animation: fade-up .8s both
}

.pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--h-green);
    box-shadow: 0 0 0 0 #5dad19;
    animation: ping 1.8s infinite
}

@keyframes ping {
    to {
        box-shadow: 0 0 0 12px rgba(95, 208, 138, 0)
    }
}

.hero-title {
    font-family: 'Fraunces', Georgia, serif;
    color: #fff;
    font-size: clamp(38px, 5.4vw, 50px);
    line-height: 1.04;
    font-weight: 500;
    letter-spacing: -.02em;
    margin-bottom: 24px
}

.hero-title .line {
    display: block;
    overflow: hidden;
    padding-bottom: .08em
}

.hero-title .line>span {
    display: block;
    transform: translateY(110%);
    animation: line-up .9s cubic-bezier(.2, .8, .2, 1) forwards
}

.hero-title .line:nth-child(2)>span {
    animation-delay: .12s
}

.hero-title .line:nth-child(3)>span {
    animation-delay: .24s
}

@keyframes line-up {
    to {
        transform: none
    }
}

.hero-title em {
    font-style: italic;
    background: linear-gradient(100deg, var(--h-green), var(--h-teal) 50%, var(--h-amber));
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    animation: shine 6s linear infinite
}

@keyframes shine {
    to {
        background-position: 200% center
    }
}

.hero-description {
    font-size: 17px;
    color: #B9C4BB;
    max-width: 540px;
    margin-bottom: 36px;
    animation: fade-up .9s .45s both
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    animation: fade-up .9s .6s both
}

@keyframes fade-up {
    from {
        opacity: 0;
        transform: translateY(18px)
    }

    to {
        opacity: 1;
        transform: none
    }
}

.btn-glow {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 14.5px;
    padding: 15px 26px;
    border-radius: 10px;
    color: #1A1204;
    background: linear-gradient(120deg, #FFC061, #FFB547 50%, #FF9F2E);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .2) inset, 0 10px 30px -8px rgba(255, 181, 71, .65);
    transition: transform .2s, box-shadow .2s
}

.btn-glow span {
    transition: transform .2s
}

.btn-glow:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .3) inset, 0 16px 40px -8px rgba(255, 181, 71, .85)
}

.btn-glow:hover span {
    transform: translateX(4px)
}

.btn-outline-light {
    display: inline-flex;
    align-items: center;
    font-size: 14.5px;
    font-weight: 500;
    padding: 15px 26px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, .24);
    color: #fff;
    background: rgba(255, 255, 255, .04);
    transition: background .2s, border-color .2s
}

.btn-outline-light:hover {
    background: rgba(255, 255, 255, .1);
    border-color: rgba(255, 255, 255, .5)
}

/* escena */
.hero-visual {
    position: relative;
    animation: fade-up 1s .3s both
}

.scene-card {
    position: relative;
    border-radius: 22px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .18);
    box-shadow: 0 40px 80px -30px rgba(0, 0, 0, .7), 0 0 60px -10px rgba(44, 198, 217, .35);
    transform: perspective(1200px) rotateY(-6deg) rotateX(2deg);
    transition: transform .5s ease
}

.hero-visual:hover .scene-card {
    transform: perspective(1200px) rotateY(0) rotateX(0)
}

.scene-svg {
    width: 100%;
    height: auto
}

.scene-shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(115deg, transparent 40%, rgba(255, 255, 255, .14) 50%, transparent 60%);
    background-size: 250% 100%;
    animation: sweep 6s ease-in-out infinite;
    pointer-events: none
}

@keyframes sweep {
    from {
        background-position: 150% 0
    }

    to {
        background-position: -50% 0
    }
}

.pulse path {
    stroke-dasharray: 8 60;
    animation: flow 2.2s linear infinite
}

.pulse .p2 {
    animation-duration: 3s;
    animation-direction: reverse
}

@keyframes flow {
    to {
        stroke-dashoffset: -68
    }
}

.rotor {
    transform-origin: 452px 262px;
    animation: spin 6s linear infinite
}

@keyframes spin {
    to {
        transform: rotate(360deg)
    }
}

.sun {
    transform-origin: 360px 300px;
    animation: breathe 5s ease-in-out infinite
}

@keyframes breathe {
    50% {
        transform: scale(1.12);
        opacity: .85
    }
}

.star {
    animation: twinkle 3s ease-in-out infinite
}

.star.s2 {
    animation-delay: 1s
}

.star.s3 {
    animation-delay: 2s
}

@keyframes twinkle {
    50% {
        opacity: .15
    }
}

.panel {
    animation: panel-glint 4s ease-in-out infinite
}

@keyframes panel-glint {
    50% {
        fill: #7FE9F5
    }
}

.chip {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 500;
    padding: 9px 14px;
    border-radius: 12px;
    color: #fff;
    background: rgba(12, 22, 18, .66);
    border: 1px solid rgba(255, 255, 255, .18);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    box-shadow: 0 12px 30px -10px rgba(0, 0, 0, .6);
    animation: float 6s ease-in-out infinite
}

.chip i {
    color: var(--h-amber)
}

.chip-a {
    top: -16px;
    left: -24px
}

.chip-b {
    bottom: 36px;
    right: -20px;
    animation-delay: 1.5s
}

.chip-b i {
    color: var(--h-teal)
}

.chip-c {
    bottom: -18px;
    left: 12%;
    animation-delay: 3s
}

.chip-c i {
    color: var(--h-green)
}

@keyframes float {
    50% {
        transform: translateY(-10px)
    }
}

/* métricas */
.hero-metrics {
    display: grid;
    margin-top: 56px;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    animation: fade-up .9s .8s both
}

.metric-card {
    padding: 24px 26px;
    border-radius: 16px;
    background: linear-gradient(160deg, #373636, #373636);
    border: 1px solid rgba(255, 255, 255, .12);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    transition: transform .25s, border-color .25s
}

.metric-card:hover {
    transform: translateY(-4px);
    border-color: rgba(95, 208, 138, .5)
}

.metric-value {
    display: block;
    font-size: 36px;
    font-weight: 500;
    margin-bottom: 6px;
    background: linear-gradient(100deg, var(--h-green), var(--h-teal));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent
}

.metric-value b {
    font-weight: 500
}

.metric-value small {
    font-size: 18px;
    font-weight: 400;
    -webkit-text-fill-color: #9FB0A5
}

.metric-label {
    font-size: 11px;
    letter-spacing: .08em;
    color: #9FB0A5
}

/* marquee */
.hero-marquee {
    margin-top: 56px;
    border-top: 1px solid rgba(255, 255, 255, .1);
    background: rgba(255, 255, 255, .03);
    overflow: hidden;
    padding: 16px 0
}

.marquee-track {
    display: flex;
    width: max-content;
    animation: marquee 32s linear infinite
}

.marquee-track span {
    font-size: 12px;
    letter-spacing: .18em;
    color: #8FA095;
    padding: 0 28px;
    position: relative;
    white-space: nowrap
}

.marquee-track span::after {
    content: "⚡";
    position: absolute;
    right: -6px;
    color: var(--h-amber);
    font-size: 10px
}

@keyframes marquee {
    to {
        transform: translateX(-50%)
    }
}

@media (max-width:900px) {
    .hero-layout {
        grid-template-columns: 1fr;
        gap: 48px
    }

    .chip-a {
        left: -6px
    }

    .chip-b {
        right: -6px
    }

    .scene-card {
        transform: none
    }
}

@media (max-width:700px) {
    .services-hero {
        padding-top: 64px
    }

    .hero-metrics {
        grid-template-columns: 1fr
    }
}

@media (prefers-reduced-motion:reduce) {

    .services-hero *,
    .services-hero *::before {
        animation: none !important;
        transition: none !important
    }

    .hero-title .line>span {
        transform: none
    }
}