/* ============================================================
   Buildex — página de módulo (historia visual por escenas)
   Autocontenida: no depende de pulso.css ni de styles.css.
   ============================================================ */

:root {
    --ink: #0d1420;
    --ink-2: #141d2c;
    --ink-3: #24324a;
    --text: #1c2533;
    --muted: #5b6676;
    --line: #e3e6ea;
    --soft: #f5f4f0;
    --accent: #f59f00;
    --accent-strong: #e08a00;
    --accent-ink: #a05f00;
    --green: #2f9e44;
    --green-l: #69db7c;
    --red: #e03131;
    --red-l: #ff8787;
    --blue: #5c7cfa;
    --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --display: 'Archivo', 'Inter', system-ui, sans-serif;
    --pad: clamp(4rem, 9vw, 7.5rem);
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 84px;
}

body {
    font-family: var(--font);
    font-size: 1rem;
    line-height: 1.55;
    color: var(--text);
    background: #fff;
    -webkit-font-smoothing: antialiased;
}

img,
svg {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
}

h1,
h2,
h3 {
    font-family: var(--display);
    font-stretch: 112%;
    font-weight: 800;
    line-height: 1.06;
    letter-spacing: -0.02em;
    color: var(--ink);
    text-wrap: balance;
}

h2 {
    font-size: clamp(2rem, 4.8vw, 3.5rem);
}

h3 {
    font-size: 1.125rem;
    font-weight: 700;
    line-height: 1.2;
}

p {
    text-wrap: pretty;
}

:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 3px;
    border-radius: 4px;
}

.wrap {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.wrap--narrow {
    max-width: 800px;
}

.c-red {
    color: var(--red-l);
}

.c-green {
    color: var(--green-l);
}

/* ---------- Botones ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 1.5rem;
    border-radius: 8px;
    font-weight: 650;
    font-size: 0.9375rem;
    text-decoration: none;
    border: 1.5px solid transparent;
    transition: transform 0.15s ease, background 0.15s ease;
    cursor: pointer;
}

.btn svg {
    width: 18px;
    height: 18px;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn--accent {
    background: var(--accent);
    color: var(--ink);
}

.btn--accent:hover {
    background: #ffb01f;
}

.btn--ghost {
    border-color: rgba(255, 255, 255, 0.35);
    color: #fff;
}

.btn--ghost:hover {
    background: rgba(255, 255, 255, 0.08);
}

.btn--sm {
    padding: 0.55rem 1rem;
    font-size: 0.875rem;
}

/* ---------- Capítulo ---------- */
.chapter {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    font-family: var(--display);
    font-stretch: 118%;
    font-weight: 700;
    font-size: 0.8125rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent-ink);
    margin-bottom: 1.1rem;
}

.chapter--dark {
    color: var(--accent);
}

.num {
    display: inline-block;
    background: var(--accent);
    color: var(--ink);
    font-family: var(--display);
    font-weight: 900;
    letter-spacing: 0;
    padding: 0.12rem 0.6rem;
    transform: skewX(-14deg);
}

.pill {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 650;
    background: rgba(245, 159, 0, 0.16);
    color: var(--accent);
    border: 1px solid rgba(245, 159, 0, 0.4);
    padding: 0.1rem 0.6rem;
    border-radius: 100px;
    margin-bottom: 0.7rem;
}

.dot {
    display: inline-block;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    flex-shrink: 0;
}

.dot--green {
    background: var(--green);
}

.dot--amber {
    background: var(--accent);
}

.dot--red {
    background: var(--red);
    box-shadow: 0 0 0 4px rgba(224, 49, 49, 0.18);
}

/* ---------- Navbar ---------- */
.nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
}

.nav__in {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    min-height: 68px;
}

.nav__brand {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    flex-shrink: 0;
}

.nav__bidatex img {
    height: 24px;
    width: auto;
}

.nav__sep {
    width: 1px;
    height: 26px;
    background: var(--line);
}

.nav__buildex {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    text-decoration: none;
}

.nav__iso {
    height: 26px;
    width: auto;
}

.nav__word {
    height: 12px;
    width: auto;
}

.nav__links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav__links a:not(.btn) {
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--muted);
}

.nav__links a:not(.btn):hover {
    color: var(--ink);
}

.nav__toggle {
    display: none;
    background: none;
    border: 0;
    padding: 0.5rem;
    color: var(--ink);
    cursor: pointer;
}

.nav__mobile {
    display: none;
    flex-direction: column;
    padding: 0.5rem 1.5rem 1.25rem;
    border-top: 1px solid var(--line);
    background: #fff;
}

.nav__mobile a:not(.btn) {
    padding: 0.85rem 0;
    text-decoration: none;
    font-weight: 600;
    color: var(--ink);
    border-bottom: 1px solid var(--line);
}

.nav__mobile .btn {
    margin-top: 1rem;
}

.nav.is-open .nav__mobile {
    display: flex;
}

/* ============================================================
   HERO — las tres obras
   ============================================================ */
.hero {
    background-color: var(--ink);
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        radial-gradient(ellipse 70% 60% at 50% 100%, rgba(245, 159, 0, 0.13), transparent 65%);
    background-size: 48px 48px, 48px 48px, 100% 100%;
    color: #fff;
    min-height: calc(100vh - 68px);
    display: flex;
    align-items: center;
    padding: clamp(2rem, 4vw, 2.75rem) 0;
    text-align: center;
    overflow: hidden;
}

.hero__in {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero h1 {
    font-size: clamp(1.75rem, 3.6vw, 3.25rem);
    font-weight: 800;
    margin-bottom: clamp(1rem, 2vw, 1.5rem);
}

.hero h1 span {
    display: block;
    max-width: 24ch;
    margin-inline: auto;
}

.hero__l1 {
    color: #fff;
}

.hero__l2 {
    color: var(--accent);
    margin-top: 0.1em;
}

/* Escena 3D: las tres obras dibujadas con puntos y líneas (js/shape3d.js) */
.hero__scene {
    width: 100%;
    max-width: 720px;
}

.hero__stage {
    position: relative;
    height: clamp(230px, 40vh, 430px);
}

.hero__stage::after {
    content: '';
    position: absolute;
    inset: 20% 5% 0;
    background: radial-gradient(ellipse at 50% 70%, rgba(245, 159, 0, 0.12), transparent 65%);
    pointer-events: none;
}

.hero__stage .shape3d-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    pointer-events: none;
}

.site {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: start;
    width: 100%;
    text-align: center;
}

.obra {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 0;
}

.obra__light {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.3rem 0.75rem 0.3rem 0.55rem;
    border-radius: 100px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.16);
    font-size: 0.8125rem;
    font-weight: 650;
    color: #c3ccd9;
    margin-bottom: 0.35rem;
    white-space: nowrap;
    transition: background 0.5s ease, border-color 0.5s ease, color 0.5s ease, transform 0.5s ease;
}

.obra__light i {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #5b6b85;
    transition: background 0.5s ease, box-shadow 0.5s ease;
}

.obra__light b {
    font-weight: 650;
}

.obra__light .a {
    display: none;
}

.obra.is-lit .obra__light .q {
    display: none;
}

.obra.is-lit .obra__light .a {
    display: inline;
}

.obra.is-lit .obra__light {
    color: #fff;
    transform: scale(1.06);
}

.obra.is-lit[data-state='green'] .obra__light i {
    background: var(--green-l);
    box-shadow: 0 0 14px var(--green-l);
}

.obra.is-lit[data-state='amber'] .obra__light i {
    background: var(--accent);
    box-shadow: 0 0 14px var(--accent);
}

.obra.is-lit[data-state='red'] .obra__light {
    background: rgba(224, 49, 49, 0.2);
    border-color: var(--red-l);
}

.obra.is-lit[data-state='red'] .obra__light i {
    background: var(--red-l);
    box-shadow: 0 0 16px var(--red-l);
    animation: pulse 1.6s ease-in-out infinite;
}

@keyframes pulse {
    50% {
        box-shadow: 0 0 0 7px rgba(255, 135, 135, 0.18), 0 0 18px var(--red-l);
    }
}

.obra__name {
    width: 100%;
    padding: 0 0.3rem 0.45rem;
    font-size: clamp(0.8125rem, 1.5vw, 1rem);
    font-weight: 650;
}

.obra__why {
    min-height: 2.6em;
    padding: 0.15rem 0.3rem 0;
    font-size: clamp(0.72rem, 1.4vw, 0.875rem);
    color: #93a0b2;
    opacity: 0;
    transition: opacity 0.6s ease 0.2s;
}

.obra.is-lit .obra__why {
    opacity: 1;
}

.obra.is-lit[data-state='red'] .obra__why {
    color: var(--red-l);
    font-weight: 600;
}

.hero__sub {
    margin: clamp(0.75rem, 2vw, 1.25rem) 0 1.25rem;
    font-size: clamp(1rem, 1.7vw, 1.1875rem);
    color: #b8c2d0;
    max-width: 32rem;
}

.hero__cta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
}

@media (max-width: 900px) {
    .hero__stage {
        height: clamp(200px, 30vh, 260px);
    }
}

@media (min-width: 901px) {
    .hero {
        text-align: left;
    }

    .hero__in {
        display: grid;
        grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
        grid-template-rows: 1fr auto auto auto 1fr;
        grid-template-areas: '. scene' 'h scene' 'sub scene' 'cta scene' '. scene';
        column-gap: clamp(1.5rem, 3.5vw, 3.5rem);
        align-items: start;
    }

    .hero h1 {
        grid-area: h;
    }

    .hero h1 span {
        max-width: none;
        margin-inline: 0;
    }

    .hero__scene {
        grid-area: scene;
        align-self: center;
        max-width: none;
    }

    .hero__sub {
        grid-area: sub;
        margin-top: 0;
    }

    .hero__cta {
        grid-area: cta;
        justify-content: flex-start;
    }
}

/* ============================================================
   PUENTE
   ============================================================ */
.bridge {
    background: var(--ink-2);
    color: #fff;
    padding: var(--pad) 0;
}

.bridge__big {
    font-family: var(--display);
    font-stretch: 112%;
    font-weight: 800;
    font-size: clamp(1.9rem, 5.6vw, 4.25rem);
    line-height: 1.05;
    letter-spacing: -0.02em;
    max-width: 18ch;
    color: #6d7c93;
    text-wrap: balance;
}

.bridge__big em {
    display: block;
    font-style: normal;
    color: #fff;
}

.bridge__nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: clamp(2rem, 4vw, 3rem);
}

.bridge__nav a {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.7rem 1.1rem 0.7rem 0.8rem;
    border: 1px solid var(--ink-3);
    border-radius: 8px;
    text-decoration: none;
    font-weight: 650;
    transition: border-color 0.2s, background 0.2s;
}

.bridge__nav a:hover {
    border-color: var(--accent);
    background: rgba(245, 159, 0, 0.08);
}

/* ============================================================
   ESCENAS
   ============================================================ */
.scene {
    padding: var(--pad) 0;
    overflow: hidden;
}

.scene--soft {
    background: var(--soft);
}

.scene--dark {
    background: var(--ink);
    color: #c3ccd9;
}

.scene--dark h2,
.scene--dark h3 {
    color: #fff;
}

.scene__grid {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: clamp(2rem, 6vw, 5rem);
    align-items: center;
}

.scene__copy h2 {
    margin-bottom: 1.1rem;
}

.scene__copy p,
.freno__copy p {
    font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
    color: var(--muted);
    max-width: 30rem;
}

.scene__head {
    margin-bottom: clamp(2rem, 5vw, 3.5rem);
}

.scene__head h2 {
    max-width: 20ch;
}

.fix {
    display: flex;
    gap: 0.6rem;
    margin-top: 1.4rem;
    padding-top: 1.4rem;
    border-top: 1px solid var(--line);
    color: var(--ink) !important;
    font-weight: 600;
}

.fix svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    margin-top: 0.2rem;
    color: var(--accent-strong);
}

/* ---------- 01 · camión ---------- */
.split {
    display: grid;
    grid-template-columns: minmax(96px, 250px) minmax(28px, 1fr) minmax(128px, 220px);
    align-items: stretch;
}

.split__truck {
    align-self: center;
    text-align: center;
    font-size: 0.875rem;
    color: var(--muted);
}

.split__truck svg {
    width: 100%;
    height: auto;
    margin-bottom: 0.5rem;
    transform: translateX(-60px);
    opacity: 0;
    transition: transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.6s ease;
}

.is-in .split__truck svg {
    transform: none;
    opacity: 1;
}

.split__truck strong {
    display: block;
    font-family: var(--display);
    font-weight: 800;
    font-size: clamp(1.1rem, 2.2vw, 1.5rem);
    color: var(--ink);
}

.t-bed {
    fill: #dfe3e8;
}

.t-cab {
    fill: var(--ink);
}

.t-win {
    fill: #8fa3c4;
}

.t-bag {
    fill: var(--accent);
}

.t-wheel {
    fill: var(--ink);
}

.t-hub {
    fill: #dfe3e8;
}

.split__flow {
    width: 100%;
    height: 100%;
    min-height: 240px;
    overflow: visible;
}

.split__flow path {
    fill: none;
    stroke: var(--accent-strong);
    stroke-width: 3;
    stroke-linecap: round;
    stroke-dasharray: 3 11;
    vector-effect: non-scaling-stroke;
    opacity: 0;
    transition: opacity 0.5s ease 0.7s;
}

.is-in .split__flow path {
    opacity: 1;
    animation: flow 0.9s linear infinite;
}

@keyframes flow {
    to {
        stroke-dashoffset: -14;
    }
}

.split__to {
    display: grid;
    grid-template-rows: repeat(3, 1fr);
}

.dest {
    margin: 0.45rem 0;
    padding: 0.9rem 1rem;
    background: #fff;
    border: 1px solid var(--line);
    border-left: 4px solid var(--accent);
    border-radius: 10px;
    box-shadow: 0 8px 22px rgba(13, 20, 32, 0.07);
    display: flex;
    flex-direction: column;
    justify-content: center;
    opacity: 0;
    transform: translateX(24px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.is-in .dest {
    opacity: 1;
    transform: none;
}

.is-in .dest:nth-child(1) {
    transition-delay: 0.9s;
}

.is-in .dest:nth-child(2) {
    transition-delay: 1.05s;
}

.is-in .dest:nth-child(3) {
    transition-delay: 1.2s;
}

.dest__qty {
    font-size: 0.8125rem;
    color: var(--muted);
}

.dest__qty b {
    font-family: var(--display);
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--ink);
    margin-right: 0.15rem;
}

.dest strong {
    font-size: 0.9375rem;
    color: var(--ink);
}

.dest__amt {
    font-size: 0.875rem;
    font-weight: 650;
    color: var(--accent-ink);
    font-variant-numeric: tabular-nums;
}

/* ---------- 02 · adelanto ---------- */
.gap {
    margin-bottom: clamp(3rem, 7vw, 5rem);
}

.gap__tag {
    display: block;
    font-size: clamp(0.875rem, 1.6vw, 1.0625rem);
    font-weight: 600;
    text-align: right;
    white-space: nowrap;
}

.gap__tag b {
    font-family: var(--display);
    font-weight: 800;
    font-size: 1.3em;
}

.gap__tag--paid {
    width: 56%;
    color: var(--red-l);
    padding-bottom: 0.5rem;
}

.gap__below {
    display: grid;
    grid-template-columns: 40% minmax(0, 1fr);
    padding-top: 0.5rem;
}

.gap__tag--done {
    color: var(--green-l);
}

.gap__hole {
    padding-left: 0.8rem;
    font-size: clamp(0.8125rem, 1.5vw, 1rem);
    font-weight: 600;
    color: var(--red-l);
    opacity: 0;
    transition: opacity 0.5s ease 1.5s;
}

.is-in .gap__hole {
    opacity: 1;
}

.gap__track {
    position: relative;
    height: clamp(52px, 8vw, 84px);
    border-radius: 12px;
    background: #1b2638;
    overflow: hidden;
}

.gap__paid,
.gap__done {
    position: absolute;
    inset: 0 auto 0 0;
    width: 0;
    transition: width 1.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.gap__paid {
    background: repeating-linear-gradient(-55deg, var(--red) 0 10px, #b02525 10px 20px);
    transition-delay: 0.35s;
}

.gap__done {
    background: var(--green);
}

.is-in .gap__paid {
    width: 56%;
}

.is-in .gap__done {
    width: 40%;
}

.freno {
    display: grid;
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
    gap: clamp(2rem, 6vw, 5rem);
    align-items: center;
}

.freno__copy h3 {
    font-size: clamp(1.5rem, 3.2vw, 2.25rem);
    font-weight: 800;
    line-height: 1.08;
    margin-bottom: 1rem;
}

.freno__copy p {
    color: #b8c2d0;
}

.freno__hint {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.25rem;
    font-size: 0.9375rem !important;
    font-weight: 650;
    color: var(--accent) !important;
}

.freno__hint svg {
    width: 18px;
    height: 18px;
}

.sim {
    background: #fff;
    color: var(--text);
    border-radius: 16px;
    padding: clamp(1.25rem, 3vw, 1.75rem);
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.45);
    font-variant-numeric: tabular-nums;
}

.sim__head {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 1rem;
    margin-bottom: 1.1rem;
    border-bottom: 1px solid var(--line);
}

.sim__head strong {
    display: block;
    color: var(--ink);
    font-size: 1.0625rem;
}

.sim__total {
    text-align: right;
}

.sim__label {
    white-space: nowrap;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--muted);
}

.sim__ctl {
    display: block;
    margin-bottom: 0.9rem;
}

.sim__ctl span {
    display: flex;
    justify-content: space-between;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 0.3rem;
}

.sim__ctl output {
    font-family: var(--display);
    font-weight: 800;
    font-size: 1.1rem;
}

.sim__ctl input[type='range'] {
    width: 100%;
    height: 30px;
    accent-color: var(--accent-strong);
    cursor: pointer;
}

.sim__nums {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.6rem;
    margin: 0.4rem 0 1rem;
}

.sim__nums > div {
    background: var(--soft);
    border-radius: 10px;
    padding: 0.7rem 0.8rem;
}

.sim__nums span {
    display: block;
    font-size: 0.72rem;
    color: var(--muted);
}

.sim__nums strong {
    font-family: var(--display);
    font-weight: 800;
    font-size: clamp(1.05rem, 2.4vw, 1.4rem);
    color: var(--ink);
}

.sim__nums .sim__max {
    background: var(--ink);
}

.sim__nums .sim__max span {
    color: #a9b4c4;
}

.sim__nums .sim__max strong {
    color: var(--accent);
}

.sim__verdict {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    padding: 1rem 1.1rem;
    border-radius: 12px;
    background: #2f9e44;
    color: #fff;
    min-height: 4.6rem;
    transition: background 0.25s ease;
}

.sim__verdict svg {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
}

.sim__verdict strong {
    display: block;
    font-family: var(--display);
    font-weight: 800;
    font-size: 1.125rem;
}

.sim__verdict span {
    font-size: 0.9rem;
    opacity: 0.92;
}

.sim.is-stop .sim__verdict {
    background: var(--red);
}

#simIconStop {
    display: none;
}

.sim.is-stop #simIconStop {
    display: block;
}

.sim.is-stop #simIconOk {
    display: none;
}

.sim__note {
    margin-top: 0.8rem;
    font-size: 0.75rem;
    color: var(--muted);
}

/* ---------- 03 · cuenta ---------- */
.berg svg {
    width: 100%;
    height: auto;
    border-radius: 16px;
    background: #e9eef4;
}

.b-sea {
    fill: #14263f;
}

.b-tip {
    fill: #fff;
    stroke: #c9d3df;
    stroke-width: 2;
}

.b-deep {
    fill: #1d3657;
    stroke: #2c4a72;
    stroke-width: 2;
    transition: fill 1s ease 0.4s;
}

.is-in .b-deep {
    fill: #a33a2c;
    stroke: var(--red-l);
}

.b-wave {
    fill: none;
    stroke: #6f8fb8;
    stroke-width: 3;
}

.b-lbl {
    font-family: var(--display);
    font-weight: 800;
    font-size: 28px;
    fill: var(--ink);
}

.b-sub {
    font-size: 17px;
    fill: var(--muted);
}

.b-lbl--in {
    fill: #fff;
    text-anchor: middle;
    font-size: 32px;
}

.b-item {
    fill: #ffd9d4;
    font-size: 17px;
    font-weight: 600;
    text-anchor: middle;
}

.b-hidden {
    opacity: 0;
    transition: opacity 0.8s ease 1s;
}

.is-in .b-hidden {
    opacity: 1;
}

.sum {
    margin-top: 1.6rem;
    font-variant-numeric: tabular-nums;
}

.sum__bar {
    display: flex;
    border-radius: 10px;
    overflow: hidden;
}

.sum__bar span {
    padding: 0.7rem 0.9rem;
    font-size: 0.8125rem;
    font-weight: 600;
}

.sum__bar b {
    display: block;
    font-family: var(--display);
    font-weight: 800;
    font-size: clamp(1rem, 2vw, 1.25rem);
}

.sum__paid {
    flex: 922 1 0;
    background: var(--ink);
    color: #c3ccd9;
}

.sum__paid b {
    color: #fff;
}

.sum__owed {
    flex: 258 1 0;
    min-width: 6.5rem;
    background: var(--red);
    color: #ffe3e3;
}

.sum__owed b {
    color: #fff;
}

.sum__total {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 0.6rem 0.2rem 0;
    border-top: 0;
    font-weight: 600;
    color: var(--muted);
}

.sum__total::before {
    content: '=';
    font-family: var(--display);
    font-weight: 800;
    color: var(--ink);
    margin-right: 0.5rem;
}

.sum__total span {
    flex: 1;
}

.sum__total b {
    font-family: var(--display);
    font-weight: 800;
    font-size: clamp(1.25rem, 2.6vw, 1.75rem);
    color: var(--ink);
}

/* ============================================================
   CÓMO SE USA — teléfono fijo
   ============================================================ */
.how {
    background: var(--ink);
    color: #c3ccd9;
    padding: var(--pad) 0 0;
}

.how h2,
.how h3 {
    color: #fff;
}

.how__head h2 {
    max-width: 18ch;
}

.how__grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: clamp(2rem, 8vw, 7rem);
    align-items: start;
}

.how__steps {
    list-style: none;
}

.step {
    min-height: 74vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    opacity: 0.28;
    transition: opacity 0.4s ease;
}

.step.is-active {
    opacity: 1;
}

.step__when {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 650;
    font-size: 0.9375rem;
    color: var(--accent);
    margin-bottom: 0.9rem;
}

.step__when svg {
    width: 20px;
    height: 20px;
}

.step h3 {
    font-size: clamp(1.75rem, 4.2vw, 3rem);
    font-weight: 800;
    line-height: 1.05;
    margin-bottom: 0.8rem;
    max-width: 14ch;
}

.step p {
    font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
    color: #b8c2d0;
    max-width: 26rem;
}

.how__sticky {
    position: sticky;
    top: calc(68px + (100vh - 68px - 640px) / 2);
    padding-bottom: 3rem;
}

.how__note {
    margin-top: 0.75rem;
    text-align: center;
    font-size: 0.72rem;
    color: #7c8899;
}

.phone {
    position: relative;
    width: 300px;
    height: 590px;
    margin: 0 auto;
    padding: 12px;
    border-radius: 44px;
    background: #05080d;
    box-shadow: 0 0 0 2px #2a3850, 0 40px 80px rgba(0, 0, 0, 0.55);
}

.phone__notch {
    position: absolute;
    top: 20px;
    left: 50%;
    width: 78px;
    height: 20px;
    border-radius: 12px;
    background: #05080d;
    transform: translateX(-50%);
    z-index: 2;
}

.phone__screens {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 33px;
    overflow: hidden;
    background: #f3f4f6;
}

.scr {
    position: absolute;
    inset: 0;
    padding: 46px 14px 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    color: var(--text);
    font-size: 0.875rem;
    opacity: 0;
    transform: translateY(16px) scale(0.98);
    transition: opacity 0.4s ease, transform 0.4s ease;
    font-variant-numeric: tabular-nums;
}

.scr.is-active {
    opacity: 1;
    transform: none;
}

.scr__bar {
    font-family: var(--display);
    font-weight: 800;
    font-size: 1.125rem;
    color: var(--ink);
    padding: 4px 4px 6px;
}

.scr__photo {
    height: 130px;
    border-radius: 12px;
    background: repeating-linear-gradient(0deg, #fff 0 17px, #e5e9ee 17px 18px);
    border: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: var(--muted);
    font-size: 0.75rem;
}

.scr__photo svg {
    width: 30px;
    height: 30px;
    color: var(--accent-strong);
}

.scr__field,
.scr__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 10px;
}

.scr__field span,
.scr__row span {
    color: var(--muted);
}

.scr__field b,
.scr__row b {
    color: var(--ink);
    font-size: 1rem;
}

.scr__btn {
    padding: 13px;
    border-radius: 10px;
    background: var(--accent);
    color: var(--ink);
    font-weight: 700;
    text-align: center;
}

.scr__toast {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px;
    border-radius: 10px;
    background: #ebfbee;
    color: var(--green);
    font-weight: 650;
    font-size: 0.8125rem;
}

.scr__toast svg {
    width: 16px;
    height: 16px;
}

.scr__max {
    padding: 16px 14px;
    border-radius: 12px;
    background: var(--ink);
    color: #a9b4c4;
}

.scr__max span {
    display: block;
    font-size: 0.75rem;
}

.scr__max b {
    font-family: var(--display);
    font-weight: 800;
    font-size: 2.1rem;
    line-height: 1.1;
    color: var(--accent);
}

.scr__stop {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px;
    border-radius: 12px;
    background: var(--red);
    color: #fff;
}

.scr__stop svg {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
}

.scr__stop b {
    display: block;
    font-family: var(--display);
    font-weight: 800;
    font-size: 1.0625rem;
}

.scr__stop span {
    font-size: 0.8125rem;
    opacity: 0.9;
}

.bub {
    align-self: flex-start;
    max-width: 88%;
    padding: 10px 12px;
    border-radius: 14px 14px 14px 4px;
    background: #fff;
    border: 1px solid var(--line);
    font-size: 0.8125rem;
    line-height: 1.4;
}

.bub svg {
    display: inline-block;
    width: 14px;
    height: 14px;
    vertical-align: -2px;
    color: var(--green);
}

.bub--me {
    align-self: flex-end;
    border-radius: 14px 14px 4px 14px;
    background: var(--ink);
    border-color: var(--ink);
    color: #fff;
}

.bub__img {
    display: flex;
    align-items: center;
    gap: 5px;
    width: fit-content;
    margin-bottom: 6px;
    padding: 4px 8px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.14);
    font-size: 0.72rem;
    font-weight: 600;
}

.bub__img svg {
    color: var(--accent);
}

.scr__obra {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 10px;
}

.scr__obra b {
    display: block;
    color: var(--ink);
}

.scr__obra span {
    font-size: 0.78rem;
    color: var(--muted);
}

.scr__obra--red {
    border-color: var(--red-l);
    background: #fff5f5;
}

.scr__obra--red span {
    color: var(--red);
    font-weight: 600;
}

.scr__due {
    margin-top: auto;
    padding: 12px 14px;
    border-radius: 12px;
    background: var(--ink);
    color: #a9b4c4;
    font-size: 0.75rem;
}

.scr__due b {
    display: block;
    font-family: var(--display);
    font-weight: 800;
    font-size: 1.375rem;
    color: #fff;
}

.scr__bars {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 44px;
    margin-top: 8px;
}

.scr__bars i {
    flex: 1;
    height: max(3px, var(--h));
    border-radius: 2px;
    background: var(--accent);
    opacity: 0.9;
}

/* ============================================================
   BENTO
   ============================================================ */
.bento {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
}

.tile {
    padding: 1rem 1rem 1.25rem;
    border-radius: 16px;
    background: var(--soft);
    min-width: 0;
}

.tile--w2 {
    grid-column: span 2;
}

.tile--w4 {
    grid-column: span 4;
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 1.5rem;
    align-items: center;
    padding: 1.25rem;
}

.tile--dark {
    background: var(--ink);
    color: #b8c2d0;
}

.tile--dark h3 {
    color: #fff;
    font-size: clamp(1.25rem, 2.6vw, 1.75rem);
    margin-bottom: 0.5rem;
}

.tile h3 {
    margin-bottom: 0.25rem;
}

.tile p {
    font-size: 0.9375rem;
    color: var(--muted);
}

.tile--dark p {
    color: #b8c2d0;
}

.tile__viz {
    height: 132px;
    margin-bottom: 1rem;
    padding: 0.9rem;
    border-radius: 12px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-variant-numeric: tabular-nums;
    overflow: hidden;
}

.v-why {
    flex-direction: column;
    align-items: stretch;
    gap: 0.45rem;
}

.v-why div {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.875rem;
}

.v-why b {
    color: var(--ink);
}

.v-why span {
    margin-left: auto;
    padding: 0.15rem 0.6rem;
    border-radius: 100px;
    background: var(--soft);
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--muted);
    white-space: nowrap;
}

.v-quote {
    gap: 0.6rem;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.55rem 0.7rem;
    border: 2px dashed #c9d0d9;
    border-radius: 10px;
    font-family: var(--display);
    font-weight: 800;
    font-size: 1.0625rem;
    color: #9aa4b2;
    text-decoration: line-through;
}

.tag--win {
    border: 2px solid var(--green);
    background: #ebfbee;
    color: var(--green);
    text-decoration: none;
    transform: rotate(-3deg);
}

.tag svg {
    width: 16px;
    height: 16px;
}

.v-phase {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
}

.v-phase__bar {
    display: flex;
    gap: 3px;
    height: 34px;
}

.v-phase__bar i {
    width: var(--w);
    border-radius: 4px;
    background: #c9d0d9;
}

.v-phase__bar i:nth-child(1) {
    background: var(--accent);
}

.v-phase__bar i:nth-child(4) {
    background: var(--ink);
}

.v-phase__lbl {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--muted);
}

.v-phase__lbl span:first-child {
    color: var(--accent-ink);
}

.v-start {
    align-items: stretch;
    flex-direction: column;
    justify-content: center;
}

.v-start__bar {
    position: relative;
    height: 14px;
    border-radius: 7px;
    background: repeating-linear-gradient(-55deg, #e3e6ea 0 6px, #f1f3f5 6px 12px);
}

.v-start__bar i {
    position: absolute;
    inset: 0 0 0 55%;
    border-radius: 0 7px 7px 0;
    background: #dfe3e8;
}

.v-start__bar::after {
    content: '';
    position: absolute;
    left: 55%;
    top: -9px;
    width: 4px;
    height: 32px;
    border-radius: 2px;
    background: var(--accent-strong);
}

.v-start__bar b {
    position: absolute;
    left: 55%;
    top: 30px;
    transform: translateX(-50%);
    font-size: 0.75rem;
    color: var(--accent-ink);
    white-space: nowrap;
}

.v-roles {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
}

.v-roles div {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--muted);
}

.v-roles svg {
    width: 18px;
    height: 18px;
    color: var(--ink);
}

.v-roles b {
    margin-left: auto;
    padding: 0.15rem 0.6rem;
    border-radius: 6px;
    background: var(--soft);
    color: var(--ink);
    font-size: 0.8125rem;
}

.v-roles div:last-child b {
    background: var(--ink);
    color: #fff;
}

.v-log {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.v-log div {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 0.5rem;
    border-bottom: 1px dashed var(--line);
}

.v-log s {
    color: #9aa4b2;
}

.v-log b {
    color: var(--ink);
}

.v-log span {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--muted);
}

.v-log div:first-child span {
    color: var(--red);
}

.v-jornal {
    flex-wrap: wrap;
    gap: 0.4rem;
    font-size: 0.875rem;
    color: var(--muted);
}

.v-jornal svg {
    width: 24px;
    height: 24px;
    color: var(--ink);
}

.v-jornal b {
    font-family: var(--display);
    font-weight: 800;
    font-size: 2rem;
    line-height: 1;
    color: var(--ink);
}

.v-jornal em {
    flex-basis: 100%;
    text-align: center;
    font-style: normal;
    font-weight: 650;
    color: var(--accent-ink);
}

.tile--dark .tile__viz {
    height: auto;
    min-height: 150px;
    margin: 0;
    background: var(--ink-2);
    border: 1px solid var(--ink-3);
    gap: 1.25rem;
    flex-wrap: wrap;
    color: #c3ccd9;
    font-size: 0.875rem;
}

.v-dev__pie {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    flex-shrink: 0;
    background: conic-gradient(var(--accent) 0 52.6%, var(--blue) 52.6% 92.1%, #c3ccd9 92.1% 100%);
    -webkit-mask: radial-gradient(circle, transparent 0 28px, #000 29px);
    mask: radial-gradient(circle, transparent 0 28px, #000 29px);
}

.v-dev ul {
    list-style: none;
    display: grid;
    gap: 0.3rem;
}

.v-dev li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.v-dev li i {
    width: 10px;
    height: 10px;
    border-radius: 2px;
}

.v-dev__chip {
    padding: 0.7rem 0.9rem;
    border-left: 4px solid var(--red-l);
    border-radius: 8px;
    background: rgba(224, 49, 49, 0.14);
    max-width: 14rem;
}

.v-dev__chip span {
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--red-l);
}

.v-dev__chip b {
    color: #fff;
    font-size: 0.875rem;
}

/* ============================================================
   QUÉ NO ES
   ============================================================ */
.isnt {
    background: var(--ink);
    padding: var(--pad) 0;
    font-family: var(--display);
    font-stretch: 112%;
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -0.02em;
}

.isnt p {
    font-size: clamp(1.75rem, 5.4vw, 4rem);
    color: #4b5a72;
    text-wrap: balance;
}

.isnt s {
    text-decoration-color: var(--red-l);
    text-decoration-thickness: 0.07em;
    margin-right: 0.25em;
    white-space: nowrap;
}

.isnt .isnt__is {
    margin-top: 0.5em;
    color: #fff;
    max-width: 17ch;
}

/* ============================================================
   30 DÍAS
   ============================================================ */
.road {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.5rem;
    position: relative;
}

.road::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), var(--ink));
}

.road li {
    position: relative;
    padding-top: 2rem;
}

.road li::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 19px;
    height: 19px;
    background: var(--accent);
    border: 3px solid var(--soft);
    transform: skewX(-14deg);
}

.road__when {
    font-family: var(--display);
    font-stretch: 118%;
    font-weight: 700;
    font-size: 0.78rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent-ink);
}

.road h3 {
    font-size: clamp(1.25rem, 2.4vw, 1.625rem);
    font-weight: 800;
    margin: 0.3rem 0 0.35rem;
}

.road p {
    color: var(--muted);
}

/* ============================================================
   FAQ · CTA · FOOTER
   ============================================================ */
.faq details {
    border-bottom: 1px solid var(--line);
}

.faq summary {
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 0;
    font-weight: 650;
    font-size: 1.0625rem;
    color: var(--ink);
    cursor: pointer;
}

.faq summary::-webkit-details-marker {
    display: none;
}

.faq summary::after {
    content: '+';
    font-size: 1.6rem;
    font-weight: 400;
    line-height: 1;
    color: var(--accent-strong);
    flex-shrink: 0;
}

.faq details[open] summary::after {
    content: '−';
}

.faq details p {
    padding: 0 2rem 1.3rem 0;
    color: var(--muted);
}

.cta {
    background-color: var(--accent);
    background-image:
        linear-gradient(rgba(13, 20, 32, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(13, 20, 32, 0.06) 1px, transparent 1px);
    background-size: 48px 48px;
    color: var(--ink);
    padding: var(--pad) 0;
    text-align: center;
}

.cta__in {
    max-width: 46rem;
}

.cta__iso {
    height: 64px;
    width: auto;
    margin: 0 auto 1.75rem;
    filter: brightness(0);
}

.cta h2 {
    font-size: clamp(2rem, 5.6vw, 4rem);
    margin-bottom: 1rem;
}

.cta p {
    font-size: 1.1875rem;
    font-weight: 550;
    margin-bottom: 2rem;
}

.cta__btns {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
}

.cta .btn--accent {
    background: var(--ink);
    color: #fff;
}

.cta .btn--accent:hover {
    background: var(--ink-3);
}

.cta .btn--ghost {
    border-color: rgba(13, 20, 32, 0.45);
    color: var(--ink);
}

.cta .btn--ghost:hover {
    background: rgba(13, 20, 32, 0.08);
}

.foot {
    padding: 2rem 0;
    font-size: 0.875rem;
    color: var(--muted);
}

.foot__in {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 2rem;
}

.foot__brand {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    text-decoration: none;
}

.foot__brand img {
    height: 13px;
    width: auto;
}

.foot__links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.4rem;
}

.foot__links a {
    text-decoration: none;
}

.foot__links a:hover {
    color: var(--ink);
}

/* ---------- Aparición genérica ---------- */
.rv {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.rv.is-in {
    opacity: 1;
    transform: none;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
    .nav__links {
        display: none;
    }

    .nav__toggle {
        display: inline-flex;
    }

    .scene__grid,
    .freno {
        grid-template-columns: minmax(0, 1fr);
    }

    .scene__grid--rev .berg {
        order: 2;
    }

    /* Cómo se usa: sin teléfono fijo; cada paso lleva su pantalla */
    .how {
        padding-bottom: var(--pad);
    }

    .how__grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .how__sticky {
        display: none;
    }

    .step {
        min-height: 0;
        opacity: 1;
        padding: 2.25rem 0;
        border-top: 1px solid var(--ink-3);
    }

    .step:first-child {
        border-top: 0;
    }

    .step__scr {
        margin-top: 1.5rem;
        max-width: 320px;
        border-radius: 20px;
        background: #f3f4f6;
        overflow: hidden;
    }

    .step__scr .scr {
        position: relative;
        opacity: 1;
        transform: none;
        padding: 16px 14px;
    }

    .bento {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tile--w4 {
        grid-column: span 2;
        grid-template-columns: minmax(0, 1fr);
    }

    .road {
        grid-template-columns: minmax(0, 1fr);
        padding-left: 2rem;
    }

    .road::before {
        top: 0;
        bottom: 0;
        left: 8px;
        right: auto;
        width: 3px;
        height: auto;
        background: linear-gradient(180deg, var(--accent), var(--ink));
    }

    .road li {
        padding-top: 0;
    }

    .road li::before {
        left: -2rem;
        top: 0.15rem;
    }
}

@media (min-width: 901px) {
    .step__scr {
        display: none;
    }
}

@media (max-width: 600px) {
    .wrap {
        padding: 0 1rem;
    }

    .nav__bidatex,
    .nav__sep {
        display: none;
    }

    .hero {
        min-height: 0;
    }

    .obra__light {
        font-size: 0.72rem;
        padding: 0.25rem 0.55rem 0.25rem 0.4rem;
    }

    .hero__cta .btn,
    .cta__btns .btn {
        width: 100%;
    }

    .bento {
        grid-template-columns: minmax(0, 1fr);
    }

    .tile--w2,
    .tile--w4 {
        grid-column: auto;
    }

    .split__flow {
        min-height: 300px;
    }

    .dest {
        padding: 0.7rem 0.8rem;
    }

    .foot__in {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }

    .rv {
        opacity: 1;
        transform: none;
    }
}
