/* ===== PÁGINA DE INICIO ===== */
.page-home {
    --home-bg: #f6f8fc;
    --home-ink: #0b1220;
    --home-muted: #5b6475;
    --home-line: #e5e9f2;
    --home-red: #c1121f;
    --home-cyan: #67f7d0;
    --home-ease: cubic-bezier(0.22, 1, 0.36, 1);
    background: var(--home-bg);
}

.page-home .main-content {
    padding: 0;
    overflow-x: clip;
    background: var(--home-bg);
}

.page-home .site-footer {
    margin-top: 0;
}

/* Las animaciones de un bloque se detienen fuera de pantalla (clase puesta por home.js) */
.page-home .is-offscreen,
.page-home .is-offscreen *,
.page-home .is-offscreen *::before,
.page-home .is-offscreen *::after {
    animation-play-state: paused !important;
}

/* Aparición al hacer scroll: usa `translate` para no pisar otros `transform` */
.page-home .reveal {
    opacity: 0;
    translate: 0 28px;
    transition: opacity 0.8s ease, translate 0.8s var(--home-ease);
}

.page-home .reveal.is-in {
    opacity: 1;
    translate: none;
}

/* Encabezados de sección */
.home-heading {
    max-width: 720px;
    margin-bottom: 2.4rem;
}

.home-heading--center {
    margin-inline: auto;
    text-align: center;
}

.home-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 0.8rem;
    color: var(--home-red);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.home-kicker::before {
    content: "";
    width: 22px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
}

.home-heading h2 {
    margin-bottom: 0.8rem;
    color: var(--home-ink);
    font-size: clamp(2rem, 4vw, 3.2rem);
    line-height: 1.05;
    letter-spacing: -0.03em;
    text-wrap: balance;
}

.home-heading p {
    color: var(--home-muted);
    font-size: 1.05rem;
    line-height: 1.7;
}

/* ===== HERO 16:9 ===== */
.page-home .home-hero {
    position: relative;
    aspect-ratio: 16 / 9;
    min-height: 600px;
    overflow: hidden;
    isolation: isolate;
    background: #050b14;
}

.page-home .hero-slider {
    position: absolute;
    inset: 0;
    height: 100%;
}

.page-home .hero-slider::before {
    z-index: 1;
    background:
        linear-gradient(90deg, rgba(3, 7, 16, 0.8) 0%, rgba(3, 7, 16, 0.45) 45%, rgba(3, 7, 16, 0.1) 100%),
        linear-gradient(0deg, rgba(3, 7, 16, 0.55) 0%, transparent 45%);
}

.page-home .hero-image {
    height: 100%;
    object-fit: cover;
    transform: scale(1.08);
    transition: opacity 1.1s ease, transform 7s linear;
}

.page-home .hero-image.active {
    opacity: 1;
    transform: scale(1);
}

.page-home .home-hero-text {
    top: auto;
    right: auto;
    bottom: clamp(9rem, 27%, 16rem);
    left: clamp(1.25rem, 7vw, 7rem);
    width: min(660px, calc(100% - 2.5rem));
    max-width: none;
    text-align: left;
    text-shadow: 0 2px 24px rgba(0, 0, 0, 0.45);
    transform: none;
    z-index: 4;
}

.home-hero-count {
    display: block;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.7);
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    font-size: 0.8rem;
    letter-spacing: 0.18em;
}

.home-hero-count b {
    color: #ffffff;
}

.page-home .home-hero-text h1 {
    margin-bottom: 0.9rem;
    font-size: clamp(2.5rem, 5.4vw, 5rem);
    line-height: 1;
    letter-spacing: -0.035em;
}

.page-home .home-hero-text p {
    max-width: 560px;
    margin-bottom: 1.7rem;
    color: rgba(255, 255, 255, 0.86);
    font-size: clamp(1rem, 1.4vw, 1.22rem);
    line-height: 1.6;
}

.page-home .hero-button {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.85rem 1.5rem;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, #e11d2e, #8f0010);
    box-shadow: 0 14px 34px rgba(193, 18, 31, 0.4);
    font-weight: 700;
    text-shadow: none;
}

.page-home .hero-button span {
    transition: transform 0.25s ease;
}

.page-home .hero-button:hover span {
    transform: translateX(4px);
}

.home-hero-text.is-changing > * {
    animation: home-text-in 0.8s var(--home-ease) both;
}

.home-hero-text.is-changing > :nth-child(2) { animation-delay: 0.06s; }
.home-hero-text.is-changing > :nth-child(3) { animation-delay: 0.12s; }
.home-hero-text.is-changing > :nth-child(4) { animation-delay: 0.18s; }

.home-hero-controls {
    position: absolute;
    left: clamp(1.25rem, 7vw, 7rem);
    bottom: clamp(5.5rem, 17%, 10rem);
    z-index: 4;
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.home-hero-arrow {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: #ffffff;
    background: rgba(5, 10, 20, 0.45);
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.home-hero-arrow:hover {
    border-color: #ffffff;
    background: rgba(255, 255, 255, 0.15);
}

.home-hero-dots {
    display: flex;
    gap: 0.45rem;
}

.home-hero-dots button {
    position: relative;
    width: 38px;
    height: 18px;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
}

.home-hero-dots button::before,
.home-hero-dots i {
    position: absolute;
    left: 0;
    right: 0;
    top: 7px;
    height: 4px;
    border-radius: 4px;
}

.home-hero-dots button::before {
    content: "";
    background: rgba(255, 255, 255, 0.3);
}

.home-hero-dots i {
    background: #ffffff;
    transform: scaleX(0);
    transform-origin: left;
}

.home-hero-dots button.is-done i {
    transform: scaleX(1);
}

.home-hero-dots button.is-active i {
    animation: home-hero-progress var(--hero-duration, 6s) linear forwards;
}

.home-hero.is-paused .home-hero-dots i {
    animation-play-state: paused;
}

.home-hero-arrow:focus-visible,
.home-hero-dots button:focus-visible,
.page-home .hero-button:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 3px;
}

/* Fundido del hero hacia la sección siguiente */
.home-hero-fade {
    position: absolute;
    left: 0;
    right: 0;
    /* -2px: evita una línea fina en el borde inferior con escalados no enteros */
    bottom: -2px;
    z-index: 3;
    height: 24%;
    background: linear-gradient(to bottom, rgba(246, 248, 252, 0) 0%, rgba(246, 248, 252, 0.55) 55%, var(--home-bg) 100%);
    pointer-events: none;
}

/* ===== SERVICIOS ===== */
.services-section {
    position: relative;
    max-width: 1240px;
    margin: 0 auto;
    padding: 3.5rem 2rem 6rem;
}

.services-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.services-filters button {
    padding: 0.6rem 1.1rem;
    border: 1px solid var(--home-line);
    border-radius: 999px;
    color: #334155;
    background: #ffffff;
    font: inherit;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.services-filters button:hover {
    border-color: var(--home-ink);
}

.services-filters button[aria-pressed="true"] {
    border-color: var(--home-ink);
    color: #ffffff;
    background: var(--home-ink);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.2rem;
}

.service-card {
    --mx: 50%;
    --my: 50%;
    --rx: 0deg;
    --ry: 0deg;
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    isolation: isolate;
    border: 1px solid var(--home-line);
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 12px 30px rgba(15, 23, 42, 0.06);
    transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry));
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.3s ease, opacity 0.45s ease, filter 0.45s ease, scale 0.45s ease,
                translate 0.8s var(--home-ease);
}

/* Foco de luz que sigue al cursor */
.service-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: 0;
    background: radial-gradient(circle 240px at var(--mx) var(--my), rgba(193, 18, 31, 0.09), transparent 70%);
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.service-card:hover {
    border-color: rgba(193, 18, 31, 0.28);
    box-shadow: 0 26px 54px rgba(15, 23, 42, 0.14);
}

.service-card:hover::before {
    opacity: 1;
}

.service-media {
    position: relative;
    display: grid;
    place-items: center;
    height: 200px;
    background:
        radial-gradient(circle at 50% 42%, #ffffff 0%, #ffffff 35%, #eef2f8 100%);
}

/* Sombra bajo el producto */
.service-media::after {
    content: "";
    position: absolute;
    left: 30%;
    right: 30%;
    bottom: 16px;
    height: 14px;
    border-radius: 50%;
    background: radial-gradient(ellipse, rgba(15, 23, 42, 0.22), transparent 70%);
    transition: transform 0.5s var(--home-ease), opacity 0.5s ease;
}

.service-media img {
    position: relative;
    z-index: 1;
    max-width: 64%;
    max-height: 160px;
    object-fit: contain;
    mix-blend-mode: multiply;
    transition: transform 0.5s var(--home-ease);
}

.service-card:hover .service-media img {
    transform: translateY(-8px) scale(1.06);
}

.service-card:hover .service-media::after {
    opacity: 0.6;
    transform: scaleX(0.8);
}

.service-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 0.55rem;
    padding: 1.4rem 1.5rem 1.5rem;
}

.service-tag {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--home-red);
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.service-tag b {
    padding: 0.15rem 0.55rem;
    border-radius: 999px;
    color: #ffffff;
    background: var(--home-ink);
    font-size: 0.68rem;
    letter-spacing: 0.04em;
    text-transform: none;
}

.service-body h3 {
    color: var(--home-ink);
    font-size: 1.2rem;
    line-height: 1.25;
}

.service-body p {
    color: var(--home-muted);
    font-size: 0.94rem;
    line-height: 1.65;
}

.service-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: auto;
    padding-top: 0.5rem;
    color: var(--home-ink);
    font-weight: 700;
    text-decoration: none;
}

/* Toda la tarjeta es clicable */
.service-link::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 2;
}

.service-link span {
    color: var(--home-red);
    transition: transform 0.3s ease;
}

.service-card:hover .service-link span {
    transform: translateX(5px);
}

.service-link:focus-visible {
    outline: none;
}

.service-card:has(.service-link:focus-visible) {
    outline: 3px solid var(--home-red);
    outline-offset: 3px;
}

/* Décima tarjeta: ocupa toda la fila en la rejilla de tres columnas */
@media (min-width: 1025px) {
    .service-card--wide {
        grid-column: 1 / -1;
        flex-direction: row;
    }

    .service-card--wide .service-media {
        flex: 0 0 34%;
        height: auto;
        min-height: 220px;
    }

    .service-card--wide .service-body {
        justify-content: center;
        padding: 2rem 2.4rem;
    }

    .service-card--wide .service-body p {
        max-width: 620px;
    }

    .service-card--wide .service-link {
        margin-top: 0.4rem;
    }
}

/* Filtro: las tarjetas que no coinciden se atenúan sin mover la rejilla */
.services-grid.is-filtered .service-card:not(.is-match) {
    opacity: 0.3;
    filter: grayscale(1);
    scale: 0.97;
}

.services-grid.is-filtered .service-card.is-match {
    border-color: rgba(193, 18, 31, 0.35);
}

/* ===== CLIENTES ===== */
.clients-section {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    padding: 5.5rem 0 6rem;
    color: #ffffff;
    background:
        radial-gradient(ellipse 70% 60% at 50% 0%, #1c2d52 0%, transparent 70%),
        #0a1020;
}

.clients-glow {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(circle 360px at 12% 85%, rgba(193, 18, 31, 0.25), transparent 70%),
        radial-gradient(circle 420px at 90% 70%, rgba(79, 70, 229, 0.25), transparent 70%);
    pointer-events: none;
}

.clients-section .home-heading {
    padding: 0 1.5rem;
}

.clients-section .home-kicker {
    color: #ff6b6b;
}

.clients-section .home-heading h2 {
    color: #ffffff;
}

.clients-section .home-heading p {
    color: #9aa6bd;
}

.clients-marquee {
    position: relative;
    display: grid;
    gap: 1.1rem;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}

.clients-row {
    overflow: hidden;
    padding: 0.6rem 0;
}

.clients-track {
    display: flex;
    gap: 1.1rem;
    width: max-content;
    animation: home-marquee 46s linear infinite;
    will-change: transform;
}

.clients-row--reverse .clients-track {
    animation-direction: reverse;
    animation-duration: 54s;
}

.clients-marquee:hover .clients-track {
    animation-play-state: paused;
}

.client-logo {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 190px;
    height: 100px;
    padding: 0.9rem 1.3rem;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: translate 0.35s var(--home-ease), box-shadow 0.35s ease;
}

.client-logo img {
    max-width: 100%;
    max-height: 62px;
    object-fit: contain;
    filter: grayscale(1);
    opacity: 0.75;
    transition: filter 0.3s ease, opacity 0.3s ease;
}

.client-logo:hover {
    translate: 0 -6px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35), 0 0 0 3px rgba(255, 107, 107, 0.6);
}

.client-logo:hover img {
    filter: none;
    opacity: 1;
}

.clients-cta {
    margin-top: 2.6rem;
    text-align: center;
}

.clients-cta a {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.4rem;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 999px;
    color: #ffffff;
    font-weight: 700;
    text-decoration: none;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.clients-cta a:hover {
    border-color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

/* ===== ACERCA DE NOSOTROS ===== */
.about-section {
    position: relative;
    padding: 6rem 2rem 7rem;
    background: #ffffff;
}

.about-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
    gap: clamp(2.5rem, 5vw, 4.5rem);
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.about-title {
    margin-bottom: 1.1rem;
    color: var(--home-ink);
    font-size: clamp(2rem, 4vw, 3.1rem);
    line-height: 1.05;
    letter-spacing: -0.03em;
}

.about-lead {
    margin-bottom: 0.8rem;
    color: var(--home-ink);
    font-size: 1.12rem;
    font-weight: 700;
}

.about-body {
    color: var(--home-muted);
    font-size: 1rem;
    line-height: 1.75;
}

.about-steps {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1.8rem;
    list-style: none;
}

.about-steps li {
    padding: 0.55rem 0.95rem;
    border: 1px solid var(--home-line);
    border-radius: 999px;
    color: var(--home-ink);
    background: var(--home-bg);
    font-size: 0.88rem;
    font-weight: 700;
}

.about-steps b {
    margin-right: 0.35rem;
    color: var(--home-red);
    font-size: 0.74rem;
}

.about-section.is-counting .about-steps li {
    animation: home-step 0.6s var(--home-ease) both;
}

.about-section.is-counting .about-steps li:nth-child(2) { animation-delay: 0.25s; }
.about-section.is-counting .about-steps li:nth-child(3) { animation-delay: 0.5s; }
.about-section.is-counting .about-steps li:nth-child(4) { animation-delay: 0.75s; }

.about-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.1rem;
}

.about-stat {
    --mx: 50%;
    --my: 50%;
    position: relative;
    overflow: hidden;
    isolation: isolate;
    padding: 1.6rem;
    border: 1px solid var(--home-line);
    border-radius: 22px;
    background: var(--home-bg);
    transition: translate 0.8s var(--home-ease), opacity 0.8s ease, background-color 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

/* Rejilla escalonada en escritorio */
.about-stat:nth-child(even) {
    margin-top: 2.2rem;
    margin-bottom: -2.2rem;
}

.about-stat::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: 0;
    background: radial-gradient(circle 200px at var(--mx) var(--my), rgba(79, 70, 229, 0.1), transparent 70%);
    transition: opacity 0.3s ease;
}

.about-stat:hover {
    border-color: rgba(79, 70, 229, 0.25);
    background: #ffffff;
    box-shadow: 0 22px 46px rgba(15, 23, 42, 0.1);
}

.about-stat:hover::before {
    opacity: 1;
}

.about-stat-icon {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    margin-bottom: 1.1rem;
    border-radius: 14px;
    background: linear-gradient(135deg, #4f46e5, #ec4899);
    box-shadow: 0 10px 22px rgba(79, 70, 229, 0.3);
}

.about-stat:nth-child(even) .about-stat-icon {
    background: linear-gradient(135deg, #ec4848, #4f46e5);
}

.about-stat-icon svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: #ffffff;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.about-stat-number {
    margin-bottom: 0.45rem;
    font-size: clamp(2.4rem, 4vw, 3.2rem);
    font-weight: 800;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.about-stat-number--gradient {
    background: linear-gradient(135deg, #4f46e5, #ec4899);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.about-stat-number--blue {
    background: linear-gradient(135deg, #ec4848, #4f46e5);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.about-stat-label {
    color: var(--home-muted);
    font-size: 0.98rem;
}

.about-stat-bar {
    display: block;
    height: 4px;
    margin-top: 1.2rem;
    overflow: hidden;
    border-radius: 4px;
    background: var(--home-line);
}

.about-stat-bar i {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, #4f46e5, #ec4899);
    transform: scaleX(var(--p, 0));
    transform-origin: left;
}

/* ===== AUTOMATIZACIÓN INTELIGENTE ===== */
.home-auto-section {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    padding: clamp(5rem, 9vw, 8rem) 2rem clamp(5rem, 9vw, 8rem);
    color: #e9fbff;
    background:
        radial-gradient(circle at 12% 18%, rgba(27, 191, 174, 0.17), transparent 30%),
        radial-gradient(circle at 88% 82%, rgba(38, 104, 204, 0.18), transparent 34%),
        linear-gradient(150deg, #02070e 0%, #061422 50%, #02060c 100%);
}

.home-auto-bg {
    position: absolute;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    background-image:
        linear-gradient(rgba(103, 247, 208, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(103, 247, 208, 0.05) 1px, transparent 1px);
    background-size: 48px 48px;
    pointer-events: none;
}

.home-auto-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, transparent 30%, #02070e 85%);
}

.home-auto-scan {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 30%;
    background: linear-gradient(to bottom, transparent, rgba(103, 247, 208, 0.03) 85%, rgba(103, 247, 208, 0.1));
    transform: translateY(-100%);
    animation: home-auto-scan 8s linear infinite;
    will-change: transform;
}

.home-auto-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
    gap: clamp(2rem, 5vw, 5rem);
    align-items: center;
    max-width: 1240px;
    margin: 0 auto;
}

.home-auto-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 1rem;
    padding: 0.45rem 0.85rem;
    border: 1px solid rgba(103, 247, 208, 0.22);
    border-radius: 999px;
    color: var(--home-cyan);
    background: rgba(8, 28, 35, 0.6);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.home-auto-live {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--home-cyan);
    box-shadow: 0 0 12px var(--home-cyan);
    animation: home-blink 1.6s steps(1) infinite;
}

.home-auto-copy h2 {
    margin-bottom: 1.1rem;
    color: #f5fdff;
    font-size: clamp(2.2rem, 4.4vw, 3.8rem);
    line-height: 1.02;
    letter-spacing: -0.04em;
    text-wrap: balance;
}

.home-auto-lead {
    max-width: 560px;
    margin-bottom: 1.8rem;
    color: #a7bccb;
    font-size: 1.05rem;
    line-height: 1.75;
}

.home-auto-capabilities {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.home-auto-capabilities button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.9rem 0.5rem 0.6rem;
    border: 1px solid rgba(103, 247, 208, 0.16);
    border-radius: 999px;
    color: #d3ecf1;
    background: rgba(255, 255, 255, 0.03);
    font: inherit;
    font-size: 0.86rem;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.25s ease, background-color 0.25s ease, color 0.25s ease;
}

.home-auto-capabilities img {
    width: 22px;
    height: 22px;
    object-fit: contain;
}

.home-auto-capabilities button:hover,
.home-auto-capabilities button[aria-pressed="true"] {
    border-color: var(--home-cyan);
    color: #ffffff;
    background: rgba(103, 247, 208, 0.12);
}

.home-auto-link {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.9rem 1.4rem;
    border-radius: 14px;
    color: #00130f;
    background: linear-gradient(135deg, #9affdf, #44ddb9);
    box-shadow: 0 14px 36px rgba(49, 232, 190, 0.25);
    font-weight: 800;
    text-decoration: none;
    transition: box-shadow 0.25s ease;
}

.home-auto-link span {
    transition: transform 0.25s ease;
}

.home-auto-link:hover {
    box-shadow: 0 18px 44px rgba(49, 232, 190, 0.4);
}

.home-auto-link:hover span {
    transform: translateX(4px);
}

.home-auto-link:focus-visible,
.home-auto-capabilities button:focus-visible,
.home-auto-node:focus-visible {
    outline: 2px solid var(--home-cyan);
    outline-offset: 3px;
}

/* Centro de control */
.home-auto-hub {
    position: relative;
    width: min(100%, 540px);
    aspect-ratio: 1;
    margin: 0 auto 8.5rem;
}

.home-auto-links {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
}

.home-auto-links path,
.home-auto-links circle {
    fill: none;
    vector-effect: non-scaling-stroke;
}

.home-auto-orbit-line {
    stroke: rgba(103, 247, 208, 0.14);
    stroke-width: 1;
    stroke-dasharray: 3 8;
    transform-box: fill-box;
    transform-origin: center;
    animation: home-spin 60s linear infinite;
}

.home-auto-orbit-line--inner {
    stroke: rgba(86, 168, 255, 0.18);
    animation-direction: reverse;
    animation-duration: 40s;
}

.home-auto-links path[data-link] {
    stroke: rgba(103, 247, 208, 0.2);
    stroke-width: 1.5;
    transition: stroke 0.3s ease, stroke-width 0.3s ease;
}

.home-auto-links path[data-link].is-active {
    stroke: var(--home-cyan);
    stroke-width: 2.5;
}

.home-auto-pulse {
    stroke: var(--home-cyan);
    stroke-width: 3;
    stroke-linecap: round;
    stroke-dasharray: 6 100;
    stroke-dashoffset: 106;
    animation: home-pulse 2.8s linear infinite;
}

.home-auto-pulse:nth-of-type(8) { animation-delay: -0.5s; }
.home-auto-pulse:nth-of-type(9) { animation-delay: -1s; stroke: #56a8ff; }
.home-auto-pulse:nth-of-type(10) { animation-delay: -1.5s; }
.home-auto-pulse:nth-of-type(11) { animation-delay: -2s; stroke: #56a8ff; }
.home-auto-pulse:nth-of-type(12) { animation-delay: -2.4s; }

.home-auto-core {
    position: absolute;
    left: 50%;
    top: 50%;
    display: grid;
    place-items: center;
    width: 26%;
    aspect-ratio: 1;
    border: 1px solid rgba(103, 247, 208, 0.55);
    border-radius: 50%;
    background: radial-gradient(circle, rgba(103, 247, 208, 0.28), rgba(4, 20, 30, 0.95) 70%);
    box-shadow: 0 0 60px rgba(103, 247, 208, 0.25), inset 0 0 30px rgba(103, 247, 208, 0.2);
    translate: -50% -50%;
}

.home-auto-core span {
    position: absolute;
    inset: -16%;
    border: 1px dashed rgba(103, 247, 208, 0.4);
    border-radius: 50%;
    animation: home-spin 14s linear infinite;
}

.home-auto-core span:nth-child(2) {
    inset: -32%;
    border-style: solid;
    border-color: rgba(86, 168, 255, 0.18);
    border-top-color: rgba(86, 168, 255, 0.8);
    animation-duration: 6s;
}

.home-auto-core span:nth-child(3) {
    inset: 0;
    border: 1px solid var(--home-cyan);
    animation: home-ping 2.6s ease-out infinite;
}

.home-auto-core strong {
    color: #eafffb;
    font-size: clamp(0.9rem, 2.2vw, 1.25rem);
    font-weight: 800;
    letter-spacing: 0.22em;
    text-shadow: 0 0 18px var(--home-cyan);
}

.home-auto-node {
    position: absolute;
    left: var(--x);
    top: var(--y);
    display: grid;
    justify-items: center;
    gap: 0.15rem;
    width: 118px;
    padding: 0.7rem 0.4rem 0.65rem;
    border: 1px solid rgba(103, 247, 208, 0.2);
    border-radius: 18px;
    color: #cfe7ee;
    background: rgba(6, 20, 32, 0.94);
    font: inherit;
    cursor: pointer;
    translate: -50% -50%;
    transition: border-color 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease, scale 0.3s var(--home-ease);
    animation: home-node-float 6s ease-in-out infinite;
}

.home-auto-node:nth-of-type(2n) {
    animation-delay: -3s;
}

.home-auto-node img {
    width: 30px;
    height: 30px;
    object-fit: contain;
}

.home-auto-node span {
    font-size: 0.76rem;
    font-weight: 600;
}

.home-auto-node b {
    color: #ffffff;
    font-size: 0.86rem;
    font-variant-numeric: tabular-nums;
}

.home-auto-node:hover,
.home-auto-node.is-active {
    border-color: var(--home-cyan);
    background: rgba(8, 40, 48, 0.97);
    box-shadow: 0 0 0 4px rgba(103, 247, 208, 0.12), 0 0 30px rgba(103, 247, 208, 0.25);
    scale: 1.08;
}

.home-auto-hud {
    position: absolute;
    left: 50%;
    top: calc(100% + 1.6rem);
    width: min(100%, 440px);
    padding: 1rem 1.3rem;
    border: 1px solid rgba(103, 247, 208, 0.22);
    border-radius: 18px;
    background: rgba(4, 16, 26, 0.92);
    text-align: center;
    translate: -50% 0;
}

.home-auto-hud small {
    display: block;
    margin-bottom: 0.2rem;
    color: var(--home-cyan);
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.home-auto-hud strong {
    display: block;
    margin-bottom: 0.3rem;
    color: #ffffff;
    font-size: 1.05rem;
}

.home-auto-hud p {
    color: #9fb6c2;
    font-size: 0.88rem;
    line-height: 1.55;
}

.home-auto-hud.is-switching > * {
    animation: home-text-in 0.5s var(--home-ease) both;
}

/* ===== CASHDRO ===== */
.home-cashdro-section {
    padding: 6rem 2rem 7rem;
    background: linear-gradient(180deg, #ffffff, var(--home-bg));
}

.home-cashdro-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: clamp(2.5rem, 5vw, 5rem);
    align-items: center;
    max-width: 1240px;
    margin: 0 auto;
}

.home-cashdro-visual {
    position: relative;
    padding: 0 2rem 4rem 0;
}

.home-cashdro-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4 / 3.4;
    border-radius: 28px;
    box-shadow: 0 30px 70px rgba(15, 23, 42, 0.18);
}

.home-cashdro-image::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(200deg, transparent 50%, rgba(5, 10, 20, 0.45));
}

.home-cashdro-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 6s ease;
}

.home-cashdro-visual:hover .home-cashdro-image img {
    transform: scale(1.05);
}

/* Simulador de cobro */
.home-cashdro-sim {
    position: absolute;
    right: 0;
    bottom: 0;
    width: min(370px, 82%);
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    color: #f2f6fb;
    background: #0d1420;
    box-shadow: 0 30px 70px rgba(5, 10, 20, 0.45);
}

.home-cashdro-sim-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.8rem;
    font-size: 0.84rem;
    font-weight: 700;
}

.home-cashdro-sim-head span {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.home-cashdro-sim-head i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #75d99b;
    box-shadow: 0 0 10px #75d99b;
}

.home-cashdro-reset {
    padding: 0.35rem 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    color: #dbe5f0;
    background: transparent;
    font: inherit;
    font-size: 0.74rem;
    cursor: pointer;
}

.home-cashdro-reset:hover {
    border-color: #ffffff;
}

.home-cashdro-screen {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem 1rem;
    padding: 0.9rem;
    border-radius: 16px;
    background: linear-gradient(160deg, #13243a, #0a1626);
}

.home-cashdro-screen small {
    display: block;
    color: #8ea3bb;
    font-size: 0.7rem;
}

.home-cashdro-screen strong {
    color: #ffffff;
    font-size: 1.45rem;
    font-variant-numeric: tabular-nums;
}

.home-cashdro-screen.is-bump strong[data-cash-paid] {
    animation: home-bump 0.35s ease;
}

.home-cashdro-progress {
    grid-column: 1 / -1;
    height: 6px;
    overflow: hidden;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
}

.home-cashdro-progress i {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, #75d99b, #c8f7a6);
    transform: scaleX(var(--paid, 0));
    transform-origin: left;
    transition: transform 0.4s var(--home-ease);
}

.home-cashdro-message {
    grid-column: 1 / -1;
    min-height: 1.4em;
    color: #b7c6d6;
    font-size: 0.8rem;
}

.home-cashdro-message.is-done {
    color: #9ff0bd;
    font-weight: 700;
}

.home-cashdro-change {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.home-cashdro-change:empty {
    display: none;
}

.home-cashdro-change li {
    animation: home-change-in 0.45s var(--home-ease) both;
}

.home-cashdro-money {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.45rem;
    margin-top: 0.8rem;
}

.home-cashdro-money button,
.home-cashdro-change li {
    display: grid;
    place-items: center;
    font-size: 0.78rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.home-cashdro-money button {
    height: 40px;
    border: 0;
    font-family: inherit;
    cursor: pointer;
    transition: transform 0.15s ease, filter 0.2s ease, opacity 0.2s ease;
}

.home-cashdro-money button:hover {
    filter: brightness(1.12);
}

.home-cashdro-money button:active {
    transform: scale(0.92);
}

.home-cashdro-money button:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.is-bill {
    border-radius: 8px;
    color: #10331f;
    background: linear-gradient(135deg, #a7e8b9, #6ccf8d);
}

.is-bill[data-cash="50"],
.home-cashdro-change .is-bill[data-value="50"] { color: #3b2408; background: linear-gradient(135deg, #ffc98a, #f59b3d); }
.is-bill[data-cash="20"],
.home-cashdro-change .is-bill[data-value="20"] { color: #10233b; background: linear-gradient(135deg, #a6c8ff, #5e95e8); }
.is-bill[data-cash="10"],
.home-cashdro-change .is-bill[data-value="10"] { color: #3b0f12; background: linear-gradient(135deg, #ffb0b0, #e86a6a); }

.is-coin {
    justify-self: center;
    width: 40px;
    border-radius: 50%;
    color: #3a2c05;
    background: radial-gradient(circle at 35% 30%, #fff1b8, #e0b33c 70%);
    box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.35);
}

.home-cashdro-change .is-bill {
    padding: 0.35rem 0.6rem;
}

.home-cashdro-change .is-coin {
    width: 34px;
    height: 34px;
    font-size: 0.66rem;
}

.home-cashdro-money button:focus-visible,
.home-cashdro-reset:focus-visible,
.home-cashdro-link:focus-visible {
    outline: 2px solid #75d99b;
    outline-offset: 2px;
}

.home-cashdro-logo {
    width: 150px;
    height: auto;
    margin-bottom: 1.2rem;
}

.home-cashdro-kicker {
    margin-bottom: 0.7rem;
    color: var(--home-red);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.home-cashdro-copy h2 {
    margin-bottom: 1rem;
    color: var(--home-ink);
    font-size: clamp(2rem, 3.8vw, 3rem);
    line-height: 1.06;
    letter-spacing: -0.03em;
    text-wrap: balance;
}

.home-cashdro-lead {
    margin-bottom: 1.6rem;
    color: var(--home-muted);
    font-size: 1.02rem;
    line-height: 1.75;
}

.home-cashdro-benefits {
    display: grid;
    gap: 0.6rem;
    margin-bottom: 2rem;
    list-style: none;
}

.home-cashdro-benefits li {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.85rem 1rem;
    border: 1px solid var(--home-line);
    border-radius: 16px;
    background: #ffffff;
    color: var(--home-muted);
    font-size: 0.92rem;
}

.home-cashdro-benefits b {
    min-width: 4.6rem;
    color: var(--home-ink);
    font-size: 1.25rem;
    font-variant-numeric: tabular-nums;
}

.home-cashdro-link {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.9rem 1.4rem;
    border-radius: 14px;
    color: #ffffff;
    background: var(--home-ink);
    font-weight: 700;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.home-cashdro-link span {
    transition: transform 0.25s ease;
}

.home-cashdro-link:hover {
    background: #1d2940;
}

.home-cashdro-link:hover span {
    transform: translateX(4px);
}

/* ===== CONTACTO ===== */
.home-contact {
    position: relative;
    overflow: hidden;
    padding: 6.5rem 2rem;
    color: #ffffff;
    background:
        radial-gradient(circle 520px at 88% 15%, rgba(193, 18, 31, 0.38), transparent 70%),
        radial-gradient(circle 520px at 8% 95%, rgba(79, 70, 229, 0.32), transparent 70%),
        #0b1020;
}

.home-contact-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    gap: clamp(2.5rem, 5vw, 4.5rem);
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.home-contact .home-kicker {
    color: #ff6b6b;
}

.home-contact-copy h2 {
    margin-bottom: 1rem;
    font-size: clamp(2.2rem, 4.4vw, 3.6rem);
    line-height: 1.04;
    letter-spacing: -0.035em;
    text-wrap: balance;
}

.home-contact-copy p {
    max-width: 480px;
    margin-bottom: 1.8rem;
    color: #b5bfd3;
    font-size: 1.05rem;
    line-height: 1.7;
}

.home-contact-quick {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.home-contact-quick a {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.7rem 1.1rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    color: #ffffff;
    font-weight: 700;
    text-decoration: none;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.home-contact-quick a:hover {
    border-color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

.home-contact-options {
    display: grid;
    gap: 0.9rem;
}

.home-contact-card {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 1.1rem;
    padding: 1.2rem 1.3rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.04);
    text-decoration: none;
    transition: background-color 0.3s ease, border-color 0.3s ease, translate 0.35s var(--home-ease), opacity 0.8s ease;
}

.home-contact-card:hover {
    border-color: rgba(255, 107, 107, 0.55);
    background: rgba(255, 255, 255, 0.08);
    translate: 6px 0;
}

.home-contact-card:focus-visible {
    outline: 2px solid #ff6b6b;
    outline-offset: 3px;
}

.home-contact-icon {
    display: grid;
    place-items: center;
    width: 50px;
    height: 50px;
    border-radius: 15px;
    background: linear-gradient(135deg, #e11d2e, #7f0000);
    box-shadow: 0 10px 24px rgba(193, 18, 31, 0.35);
}

.home-contact-icon svg {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: #ffffff;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.home-contact-text strong {
    display: block;
    margin-bottom: 0.15rem;
    font-size: 1.08rem;
}

.home-contact-text small {
    color: #aab4c8;
    font-size: 0.9rem;
    line-height: 1.5;
}

.home-contact-arrow {
    color: #ff6b6b;
    font-size: 1.3rem;
    transition: transform 0.3s ease;
}

.home-contact-card:hover .home-contact-arrow {
    transform: translateX(4px);
}

/* ===== ANIMACIONES ===== */
@keyframes home-text-in {
    from { opacity: 0; transform: translateY(16px); }
}

@keyframes home-hero-progress {
    to { transform: scaleX(1); }
}

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

@keyframes home-step {
    50% { color: #ffffff; background: var(--home-ink); border-color: var(--home-ink); }
}

@keyframes home-auto-scan {
    to { transform: translateY(440%); }
}

@keyframes home-blink {
    50% { opacity: 0.3; }
}

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

@keyframes home-pulse {
    to { stroke-dashoffset: 0; }
}

@keyframes home-ping {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.7); opacity: 0; }
}

@keyframes home-node-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

@keyframes home-bump {
    50% { color: #9ff0bd; }
}

@keyframes home-change-in {
    from { opacity: 0; transform: translateY(-14px) scale(0.8); }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .home-auto-inner,
    .home-cashdro-inner,
    .home-contact-inner,
    .about-inner {
        grid-template-columns: minmax(0, 1fr);
    }

    .home-auto-copy {
        text-align: center;
    }

    .home-auto-lead {
        margin-inline: auto;
    }

    .home-auto-capabilities {
        justify-content: center;
    }

    .home-cashdro-visual {
        max-width: 640px;
        margin: 0 auto;
    }
}

@media (max-width: 700px) {
    .page-home .home-hero {
        min-height: 620px;
    }

    .page-home .hero-image {
        height: 100%;
    }

    .page-home .hero-slider::before {
        background:
            linear-gradient(0deg, rgba(3, 7, 16, 0.85) 0%, rgba(3, 7, 16, 0.35) 60%, rgba(3, 7, 16, 0.45) 100%);
    }

    .page-home .home-hero-text {
        left: 1.25rem;
        bottom: 9.5rem;
    }

    .home-hero-controls {
        left: 1.25rem;
        bottom: 5.5rem;
    }

    .home-hero-dots button {
        width: 26px;
    }

    .home-hero-fade {
        height: 16%;
    }

    .services-section {
        padding: 2.5rem 1.1rem 4.5rem;
    }

    .services-filters {
        flex-wrap: nowrap;
        margin: 0 -1.1rem 1.6rem;
        padding: 0 1.1rem 0.3rem;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .services-filters::-webkit-scrollbar {
        display: none;
    }

    .services-filters button {
        flex: 0 0 auto;
    }

    .client-logo {
        width: 150px;
        height: 84px;
    }

    .about-section,
    .home-cashdro-section,
    .home-contact {
        padding: 4.5rem 1.1rem;
    }

    .home-auto-section {
        padding: 4.5rem 1.1rem;
    }

    .home-auto-hub {
        margin-bottom: 10rem;
    }

    .home-auto-node {
        width: 86px;
        padding: 0.5rem 0.3rem;
        border-radius: 14px;
    }

    .home-auto-node img {
        width: 22px;
        height: 22px;
    }

    .home-auto-node span {
        font-size: 0.66rem;
    }

    .home-auto-node b {
        font-size: 0.74rem;
    }

    .home-cashdro-visual {
        padding: 0;
    }

    .home-cashdro-sim {
        position: relative;
        width: auto;
        margin: -3rem 0.6rem 0;
    }

    .home-contact-card {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .home-contact-arrow {
        display: none;
    }
}

@media (max-width: 600px) {
    .services-grid,
    .about-stats-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .about-stat:nth-child(even) {
        margin: 0;
    }

    .service-media {
        height: 170px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .page-home *,
    .page-home *::before,
    .page-home *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .page-home .reveal {
        opacity: 1;
        translate: none;
    }
}
