/* E3 v2 — Trial onboarding refinado
 * ============================================================
 * Tokens del design system + componentes:
 *   - Pill navbar countdown
 *   - Hero card con stepper visual de 4 capas
 *   - Chip flotante contextual de capa
 *   - Toast capa-aware (3 variantes)
 *   - Modal "última oportunidad" con jerarquía 2x2
 *   - Admin trial-analytics: KPI cards hero
 *
 * Alineado con landing.css. Usa variables --tipz-* y --capa-* nuevas.
 * Animations respetan prefers-reduced-motion.
 */

:root {
    /* Colores de capa: monocromática verde TIPZ (progresión clara→primaria→oscura)
       + dorado clásico para la 4ª capa (Control · premium/élite).
       Diferenciación principal por intensidad + iconografía + label, no por hue.
       Paleta alineada con landing.css (--tipz-green-primary #00A859). */
    --capa-exploracion: #00C96B;   /* verde TIPZ +18% luminosidad */
    --capa-orientacion: #00A859;   /* verde primario TIPZ canónico */
    --capa-evidencia:   #007A42;   /* verde oscuro TIPZ canónico */
    --capa-control:     #D4AF37;   /* dorado clásico (premium, no cripto) */
    --capa-control-bonus: #D4AF37; /* mismo dorado: bonus = 4ª capa */

    /* Estados del countdown: alineados con identidad TIPZ + WCAG AA ≥4.5:1 */
    --trial-state-informativo: var(--tipz-green-primary, #00A859);
    --trial-state-urgente: #E07A29;   /* ámbar TIPZ-compatible */
    --trial-state-ultimo:  #E63946;   /* rojo saturado (4.24→5.3:1 sobre dark) */

    /* Surfaces específicas — dashboard TIPZ es dark theme,
       por eso card surface por defecto es oscura.
       Toast/Modal mantienen su propio background light/dark explícito. */
    --trial-card-bg: var(--tipz-dark-surface, #0b0f14);
    --trial-card-bg-light: #ffffff;
    --trial-card-bg-dark: var(--tipz-dark-surface, #0b0f14);
    --trial-shadow-card: 0 4px 24px rgba(0, 0, 0, 0.35);
    --trial-shadow-floating: 0 8px 32px rgba(0, 0, 0, 0.18);
    --trial-shadow-toast: 0 12px 40px rgba(0, 0, 0, 0.18);
    --trial-radius-md: 12px;
    --trial-radius-lg: 16px;
}

/* ─── A11y: prefers-reduced-motion ──────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .trial-banner,
    .trial-pill,
    .trial-stepper__step,
    .trial-stepper__connector-fill,
    .trial-chip,
    .trial-toast,
    .trial-lastchance,
    .trial-lastchance__card,
    .trial-kpi-card {
        animation: none !important;
        transition: none !important;
    }
}

/* ─── Pill navbar countdown ─────────────────────────────────── */
.trial-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid transparent;
    transition: background-color 400ms ease-in-out,
                border-color 400ms ease-in-out,
                transform 200ms ease-out;
    cursor: pointer;
    user-select: none;
    font-variant-numeric: tabular-nums;
}

.trial-pill__icon { font-size: 1rem; }
.trial-pill__text { white-space: nowrap; }
.trial-pill__dots {
    display: inline-flex;
    gap: 3px;
    margin-left: 4px;
}

.trial-pill__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
    opacity: 0.3;
    transition: opacity 250ms ease-out, transform 250ms ease-out;
}

.trial-pill__dot--touched {
    opacity: 1;
    transform: scale(1);
}

.trial-pill--informativo {
    background-color: rgba(0, 168, 89, 0.12);
    border-color: rgba(0, 168, 89, 0.4);
    color: var(--trial-state-informativo);
}

.trial-pill--urgente {
    background-color: rgba(255, 152, 0, 0.12);
    border-color: rgba(255, 152, 0, 0.4);
    color: var(--trial-state-urgente);
}

.trial-pill--ultimo {
    background-color: rgba(220, 53, 69, 0.12);
    border-color: rgba(220, 53, 69, 0.4);
    color: var(--trial-state-ultimo);
    animation: trial-pill-pulse 2s ease-in-out infinite;
}

.trial-pill:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

@keyframes trial-pill-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.88; }
}

/* Dropdown del pill */
.trial-pill-dropdown {
    width: 320px;
    background: var(--tipz-dark-surface, #0b0f14);
    border: 1px solid var(--tipz-border-strong, rgba(255, 255, 255, 0.16));
    border-radius: var(--trial-radius-md);
    padding: 16px;
    color: var(--tipz-text-strong, #fff);
}

.trial-pill-dropdown__title { font-size: 1rem; font-weight: 700; margin-bottom: 8px; }
.trial-pill-dropdown__countdown { font-size: 1.5rem; font-weight: 700; color: var(--trial-state-informativo); margin-bottom: 4px; }
.trial-pill-dropdown__progress { color: var(--tipz-text-muted-dark, #8a8f98); font-size: 0.85rem; margin-bottom: 16px; }
.trial-pill-dropdown__capas { list-style: none; padding: 0; margin: 0 0 16px; }
.trial-pill-dropdown__capa { padding: 8px 0; display: flex; align-items: center; gap: 8px; font-size: 0.9rem; }
.trial-pill-dropdown__capa-icon { width: 16px; }
.trial-pill-dropdown__capa--active { color: var(--trial-state-informativo); font-weight: 600; }
.trial-pill-dropdown__capa--done { color: var(--tipz-text-muted-dark); text-decoration: line-through; }
.trial-pill-dropdown__cta {
    display: block;
    text-align: center;
    background: var(--gradient-primary, linear-gradient(135deg, #00A859 0%, #007A42 100%));
    color: #fff;
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    margin-top: 8px;
    border-top: 1px solid var(--tipz-border, rgba(255,255,255,0.08));
}

/* Mobile: pill compacto */
@media (max-width: 767px) {
    .trial-pill__text--full,
    .trial-pill__dots { display: none; }
}

/* ─── Hero stepper card (E3 v4 editorial) ───────────────────────
   Aesthetic alineado con footer V5 "Brutalismo Editorial Refined":
   JetBrains Mono eyebrows + Space Grotesk titles + #2bd97c accent + hairlines.
   Componente serio, denso, financial-terminal premium. */

.ts-card {
    background: #08080c;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: var(--trial-radius-md);
    padding: 20px 24px;
    margin-bottom: 20px;
    color: #FFFFFF;
    position: relative;
    overflow: hidden;
}
.ts-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, #2bd97c 0%, rgba(43, 217, 124, 0.4) 50%, transparent 100%);
}

/* === Header bar === */
.ts-card__bar {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}
.ts-card__brand { min-width: 0; flex: 1; }

.ts-eyebrow {
    display: inline-block;
    font-family: 'JetBrains Mono', 'SF Mono', Consolas, monospace;
    font-size: 0.6875rem;
    font-weight: 500;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #8A8F98;
    margin-bottom: 6px;
}
.ts-eyebrow--accent { color: #2bd97c; }

.ts-card__title {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: clamp(1.05rem, 1.6vw, 1.35rem);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.022em;
    color: #FFFFFF;
    margin: 0;
    max-width: 580px;
}

.ts-card__meta {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    flex-shrink: 0;
}
.ts-card__meta-item {
    display: inline-flex;
    flex-direction: column;
    gap: 2px;
    line-height: 1;
}
.ts-card__meta-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.625rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #8A8F98;
}
.ts-card__meta-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.95rem;
    font-weight: 600;
    color: #FFFFFF;
    font-variant-numeric: tabular-nums;
}
.ts-card__meta-value strong {
    color: #2bd97c;
    font-weight: 700;
}
.ts-card__meta-rule {
    width: 1px;
    height: 24px;
    background: rgba(255, 255, 255, 0.08);
}

/* === Hairline rule === */
.ts-card__rule {
    height: 1px;
    background: rgba(255, 255, 255, 0.06);
    border: none;
    margin: 0 0 18px;
    opacity: 1;
}

/* === Stepper grid === */
.ts-stepper {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    position: relative;
}

.ts-step {
    padding: 14px 16px 4px;
    border-left: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: background 200ms ease-out;
}
.ts-step:first-child { border-left: none; padding-left: 0; }
.ts-step:last-child { padding-right: 0; }

/* === Head: número + state indicator === */
.ts-step__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.ts-step__num {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    color: #8A8F98;
    line-height: 1;
}
.ts-step--done .ts-step__num { color: #2bd97c; }
.ts-step--active .ts-step__num { color: #FFFFFF; }
.ts-step--bonus .ts-step__num { color: var(--capa-control-bonus); }

.ts-step__state {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    color: #2bd97c;
    font-size: 0.95rem;
}
.ts-step--bonus .ts-step__state { color: var(--capa-control-bonus); }

.ts-step__pulse {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #2bd97c;
    box-shadow: 0 0 0 0 rgba(43, 217, 124, 0.4);
    animation: ts-pulse 2s ease-out infinite;
}

@keyframes ts-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(43, 217, 124, 0.5); }
    70%  { box-shadow: 0 0 0 8px rgba(43, 217, 124, 0); }
    100% { box-shadow: 0 0 0 0 rgba(43, 217, 124, 0); }
}

/* === Title row con info icon === */
.ts-step__title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
}
.ts-step__title {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: -0.012em;
    color: #FFFFFF;
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    line-height: 1.2;
}
.ts-step__icon {
    color: #2bd97c;
    font-size: 0.95rem;
}
.ts-step--bonus .ts-step__icon { color: var(--capa-control-bonus); }
.ts-step__bonus {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--capa-control-bonus);
    margin-left: 2px;
}

.ts-step__info {
    background: transparent;
    border: none;
    color: #8A8F98;
    padding: 4px;
    cursor: pointer;
    line-height: 1;
    border-radius: 4px;
    transition: color 150ms ease, background 150ms ease;
    flex-shrink: 0;
}
.ts-step__info:hover {
    color: #2bd97c;
    background: rgba(43, 217, 124, 0.08);
}
.ts-step__info:focus-visible {
    outline: 2px solid #2bd97c;
    outline-offset: 2px;
}
.ts-step__info i { font-size: 0.95rem; }

/* === CTAs === */
.ts-step__ctas {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.ts-step__cta {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 9px 12px;
    min-height: 40px;
    background: transparent;
    border: 1px solid rgba(43, 217, 124, 0.24);
    border-radius: 4px;
    color: #2bd97c;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    line-height: 1.2;
    transition: all 150ms ease-out;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: rgba(43, 217, 124, 0.3);
    position: relative;
}
.ts-step__cta::after {
    content: '';
    position: absolute;
    inset: -4px;
}
.ts-step__cta span,
.ts-step__cta i { position: relative; z-index: 1; }
.ts-step__cta i { font-size: 0.95rem; transition: transform 150ms ease-out; }
.ts-step__cta:hover {
    background: rgba(43, 217, 124, 0.06);
    border-color: rgba(43, 217, 124, 0.5);
    color: #2bd97c;
    text-decoration: none;
}
.ts-step__cta:hover i.bi-arrow-right { transform: translateX(2px); }
.ts-step__cta:focus-visible {
    outline: 2px solid #2bd97c;
    outline-offset: 2px;
}
.ts-step__cta:active { background: rgba(43, 217, 124, 0.12); }

.ts-step--bonus .ts-step__cta {
    border-color: rgba(212, 175, 55, 0.28);
    color: var(--capa-control-bonus);
    -webkit-tap-highlight-color: rgba(212, 175, 55, 0.3);
}
.ts-step--bonus .ts-step__cta:hover {
    background: rgba(212, 175, 55, 0.06);
    border-color: rgba(212, 175, 55, 0.5);
}

.ts-step__cta--done {
    background: transparent;
    border: 1px dashed rgba(43, 217, 124, 0.24);
    color: rgba(43, 217, 124, 0.6);
    cursor: default;
}
.ts-step--bonus .ts-step__cta--done {
    border-color: rgba(212, 175, 55, 0.24);
    color: rgba(212, 175, 55, 0.6);
}

/* === Popover Bootstrap custom === */
.ts-popover.popover {
    --bs-popover-bg: #08080c;
    --bs-popover-border-color: rgba(255, 255, 255, 0.08);
    --bs-popover-header-bg: rgba(43, 217, 124, 0.06);
    --bs-popover-header-color: #FFFFFF;
    --bs-popover-body-color: #8A8F98;
    --bs-popover-max-width: 320px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
}
.ts-popover.popover .popover-header {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: -0.012em;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding: 10px 14px;
}
.ts-popover.popover .popover-body {
    padding: 12px 14px;
    font-size: 0.8125rem;
    line-height: 1.55;
}
.ts-popover.popover .popover-body .ts-popover__q {
    color: #FFFFFF;
    font-style: italic;
    margin: 0 0 8px;
    padding-bottom: 8px;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.08);
    font-size: 0.78rem;
}
.ts-popover.popover .popover-body .ts-popover__a {
    color: #8A8F98;
    margin: 0 0 10px;
}
.ts-popover.popover .popover-body .ts-popover__missions-title {
    font-family: 'JetBrains Mono', 'SF Mono', Consolas, monospace;
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #2bd97c;
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 6px;
}
.ts-popover.popover .popover-body .ts-popover__mission {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.ts-popover.popover .popover-body .ts-popover__mission:last-child { border-bottom: none; }
.ts-popover.popover .popover-body .ts-popover__mission > i {
    color: #8A8F98;
    font-size: 1rem;
    margin-top: 2px;
    flex-shrink: 0;
}
.ts-popover.popover .popover-body .ts-popover__mission-body {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    flex: 1;
}
.ts-popover.popover .popover-body .ts-popover__mission-body strong {
    color: #FFFFFF;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.8rem;
    line-height: 1.3;
    letter-spacing: -0.01em;
}
.ts-popover.popover .popover-body .ts-popover__mission-body span {
    color: #8A8F98;
    font-size: 0.74rem;
    line-height: 1.5;
}
.ts-popover.popover .popover-body .ts-popover__mission--done > i {
    color: #2bd97c;
}
.ts-popover.popover .popover-body .ts-popover__mission--done .ts-popover__mission-body strong {
    color: #8A8F98;
    text-decoration: line-through;
    text-decoration-color: rgba(255, 255, 255, 0.16);
}
.ts-popover.popover .popover-arrow::after {
    border-bottom-color: #08080c;
    border-top-color: #08080c;
}

/* === Estado collapsed/complete editorial === */
.ts-card--collapsed,
.ts-card--complete {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
}
.ts-card--collapsed > div,
.ts-card--complete .ts-card__complete-body {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.ts-card--collapsed strong,
.ts-card--complete strong {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: -0.014em;
    color: #FFFFFF;
}
.ts-card__icon-collapsed { color: #2bd97c; font-size: 1.4rem; }
.ts-card__icon-complete { color: var(--capa-control-bonus); font-size: 1.6rem; }
.ts-card__collapsed-copy,
.ts-card__complete-copy {
    color: #8A8F98;
    font-size: 0.8125rem;
    margin-left: auto;
}
.ts-card--collapsed { border-color: rgba(43, 217, 124, 0.2); }
.ts-card--complete { border-color: rgba(212, 175, 55, 0.24); }

/* Acciones del card completo: CTA "Ver planes" + botón "Reiniciar reto" */
.ts-card__complete-actions {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.ts-card__complete-actions .ts-active-hint__reset {
    /* Variante discreta del reset cuando convive con el CTA primario */
    padding: 8px 12px;
    font-size: 0.68rem;
}
@media (max-width: 600px) {
    .ts-card__complete-actions {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
    }
    .ts-card__complete-actions .ts-cta-primary,
    .ts-card__complete-actions .ts-active-hint__reset {
        justify-content: center;
        text-align: center;
    }
}

.ts-cta-primary {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 16px;
    background: #2bd97c;
    color: #08080c;
    border-radius: 4px;
    text-decoration: none;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    transition: transform 150ms ease-out, background 150ms ease-out;
    margin-left: auto;
}
.ts-cta-primary:hover { background: #00C96B; color: #08080c; transform: translateY(-1px); text-decoration: none; }
.ts-cta-primary i { transition: transform 150ms ease-out; }
.ts-cta-primary:hover i { transform: translateX(2px); }

/* === Responsive === */
@media (max-width: 991px) {
    .ts-card__title { font-size: 1.05rem; }
    .ts-card__bar { gap: 16px; }
}
@media (max-width: 767px) {
    .ts-card { padding: 16px 18px; }
    .ts-stepper { grid-template-columns: 1fr; }
    .ts-step {
        border-left: none;
        border-top: 1px solid rgba(255, 255, 255, 0.06);
        padding: 12px 0;
    }
    .ts-step:first-child { border-top: none; padding-top: 0; }
    .ts-step__ctas { flex-direction: row; flex-wrap: wrap; }
    .ts-step__cta { flex: 1; min-width: 140px; }
    .ts-card__bar { flex-direction: column; align-items: stretch; }
    .ts-card__meta { align-self: flex-start; }
    .ts-card--collapsed,
    .ts-card--complete { flex-wrap: wrap; }
    .ts-card__collapsed-copy,
    .ts-card__complete-copy { margin-left: 0; width: 100%; }
}


/* ─── Chip flotante contextual ──────────────────────────────── */
.trial-chip {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 1050;
    width: 280px;
    background: var(--trial-card-bg-dark);
    backdrop-filter: blur(12px);
    border: 1px solid;
    border-radius: var(--trial-radius-md);
    box-shadow: var(--trial-shadow-floating);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--tipz-text-strong, #fff);
    animation: trial-chip-slide-in 200ms ease-out;
}

.trial-chip--exploracion { border-color: var(--capa-exploracion); }
.trial-chip--orientacion { border-color: var(--capa-orientacion); }
.trial-chip--evidencia { border-color: var(--capa-evidencia); }
.trial-chip--control { border-color: var(--capa-control); }

.trial-chip__icon { font-size: 1.25rem; }
.trial-chip--exploracion .trial-chip__icon { color: var(--capa-exploracion); }
.trial-chip--orientacion .trial-chip__icon { color: var(--capa-orientacion); }
.trial-chip--evidencia .trial-chip__icon { color: var(--capa-evidencia); }
.trial-chip--control .trial-chip__icon { color: var(--capa-control); }

.trial-chip__body { flex: 1; min-width: 0; }
.trial-chip__caption { font-size: 0.72rem; color: var(--tipz-text-muted-dark, #8a8f98); text-transform: uppercase; letter-spacing: 0.05em; }
.trial-chip__label { display: block; font-size: 0.9rem; }
.trial-chip__status { font-size: 0.78rem; margin-top: 4px; display: block; }
.trial-chip__status--touched { color: #00C96B; }
.trial-chip__status--pending { color: #FFA726; text-decoration: none; }
.trial-chip__status--pending:hover { text-decoration: underline; }

.trial-chip__close {
    background: transparent;
    border: none;
    color: var(--tipz-text-muted-dark, #8a8f98);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 4px;
    line-height: 1;
}

@keyframes trial-chip-slide-in {
    from { transform: translateX(20px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

.trial-chip:hover { transform: scale(1.02); }

@media (max-width: 599px) {
    .trial-chip { width: calc(100% - 32px); right: 16px; bottom: 16px; }
    .trial-chip__caption { display: none; }
}

/* ─── Toast capa-aware (dark theme, alineado con alerts.css flash messages) ── */
.trial-toast {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 1080;
    width: 380px;
    background: var(--tipz-dark-surface, #0b0f14);
    border-radius: var(--trial-radius-md);
    border-left: 4px solid var(--toast-accent, var(--capa-exploracion));
    border-top: 1px solid var(--tipz-border, rgba(255, 255, 255, 0.08));
    border-right: 1px solid var(--tipz-border, rgba(255, 255, 255, 0.08));
    border-bottom: 1px solid var(--tipz-border, rgba(255, 255, 255, 0.08));
    box-shadow: var(--trial-shadow-toast);
    padding: 20px;
    color: var(--tipz-text-strong, #fff);
    animation: trial-toast-slide-in 300ms ease-out;
}

.trial-toast__headline {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1rem;
    color: var(--tipz-text-strong, #fff);
    margin-bottom: 8px;
}

.trial-toast__dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--toast-accent);
    flex-shrink: 0;
    animation: trial-toast-dot-pulse 400ms ease-out;
}
.trial-toast__icon { font-size: 1.25rem; flex-shrink: 0; }
.trial-toast__close {
    margin-left: auto;
    background: transparent;
    border: none;
    color: var(--tipz-text-muted-dark, #8a8f98);
    font-size: 1.2rem;
    cursor: pointer;
    line-height: 1;
}
.trial-toast__close:hover { color: var(--tipz-text-strong, #fff); }

.trial-toast__body { color: var(--tipz-text-secondary, #c8ccd4); font-size: 0.9rem; line-height: 1.5; margin-bottom: 12px; }
.trial-toast__body p { margin: 0; }
.trial-toast__cta {
    display: inline-block;
    color: var(--toast-accent);
    font-weight: 600;
    text-decoration: none;
    font-size: 0.9rem;
}
.trial-toast__cta:hover { text-decoration: underline; }

@keyframes trial-toast-slide-in {
    from { transform: translate(20px, -10px); opacity: 0; }
    to { transform: translate(0, 0); opacity: 1; }
}

@keyframes trial-toast-dot-pulse {
    0% { transform: scale(0.9); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@media (max-width: 599px) {
    .trial-toast { width: calc(100vw - 32px); right: 16px; top: 16px; }
}

/* ─── Modal lastchance ──────────────────────────────────────── */
.trial-lastchance {
    position: fixed;
    inset: 0;
    z-index: 1090;
    display: flex;
    align-items: center;
    justify-content: center;
}

.trial-lastchance__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
}

.trial-lastchance__card {
    position: relative;
    background: var(--tipz-dark-surface, #0b0f14);
    border: 1px solid var(--tipz-border, rgba(255, 255, 255, 0.08));
    border-radius: var(--trial-radius-lg);
    max-width: 720px;
    width: calc(100% - 32px);
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
    animation: trial-lastchance-scale-in 300ms ease-out;
    color: var(--tipz-text-strong, #fff);
}

.trial-lastchance__header {
    background: linear-gradient(135deg, var(--trial-state-ultimo) 0%, #f06873 100%);
    color: #fff;
    padding: 24px 32px 32px;
    text-align: center;
    position: relative;
}

.trial-lastchance__icon { font-size: 2rem; }
.trial-lastchance__header h2 { font-size: 1.75rem; font-weight: 700; margin: 8px 0; }
.trial-lastchance__header p { margin: 0; opacity: 0.92; font-size: 0.95rem; }

.trial-lastchance__close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
}

.trial-lastchance__primary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    padding: 24px 32px;
}

.trial-cta-primary {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 24px;
    border-radius: 12px;
    text-decoration: none;
    color: var(--tipz-text-strong, #fff);
    transition: transform 200ms ease-out, box-shadow 200ms ease-out, border-color 200ms ease-out;
    min-height: 180px;
}

.trial-cta-premium {
    background: rgba(0, 168, 89, 0.06);
    border: 2px solid var(--trial-state-informativo);
}
.trial-cta-premium:hover { background: rgba(0, 168, 89, 0.10); }

.trial-cta-elite {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.10), rgba(212, 175, 55, 0.04));
    border: 2px solid var(--capa-control-bonus);
}
.trial-cta-elite:hover { background: linear-gradient(135deg, rgba(212, 175, 55, 0.16), rgba(212, 175, 55, 0.08)); }

.trial-cta-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4); }

.trial-cta-primary strong { font-size: 1.5rem; }
.trial-cta-price { font-size: 2rem; font-weight: 700; color: var(--trial-state-informativo); }
.trial-cta-elite .trial-cta-price { color: var(--capa-control-bonus); }
.trial-cta-price small { font-size: 0.9rem; font-weight: 400; }
.trial-cta-primary p { color: var(--tipz-text-secondary, #c8ccd4); font-size: 0.9rem; margin: 0; flex: 1; }
.trial-cta-action {
    margin-top: 8px;
    padding: 10px 16px;
    background: var(--gradient-primary);
    color: #fff;
    text-align: center;
    border-radius: 8px;
    font-weight: 600;
}
.trial-cta-elite .trial-cta-action {
    background: linear-gradient(135deg, var(--capa-control-bonus), #E6C757);
    color: #1A1A1A;
}

.trial-cta-ribbon {
    position: absolute;
    top: 12px;
    right: -2px;
    background: linear-gradient(135deg, var(--capa-control-bonus), #E6C757);
    color: #1A1A1A;
    padding: 4px 12px;
    border-radius: 6px 0 6px 6px;
    font-size: 0.75rem;
    font-weight: 700;
}

.trial-lastchance__separator {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 32px;
    color: var(--tipz-text-muted-dark, #8a8f98);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.trial-lastchance__separator::before,
.trial-lastchance__separator::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--tipz-border, rgba(255, 255, 255, 0.08));
}

.trial-lastchance__secondary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 16px 32px 24px;
}

.trial-cta-secondary {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--tipz-border, rgba(255, 255, 255, 0.08));
    border-radius: 10px;
    text-decoration: none;
    color: var(--tipz-text-strong, #fff);
    transition: background 200ms ease-out, border-color 200ms ease-out;
}
.trial-cta-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--tipz-border-strong, rgba(255, 255, 255, 0.16));
}
.trial-cta-secondary__icon { font-size: 1.5rem; }
.trial-cta-secondary strong { display: block; font-size: 0.95rem; color: var(--tipz-text-strong, #fff); }
.trial-cta-secondary__sub { font-size: 0.8rem; color: var(--tipz-text-muted-dark, #8a8f98); }
.trial-cta-secondary__action { margin-left: auto; font-size: 0.85rem; color: var(--trial-state-informativo); font-weight: 600; }

.trial-lastchance__footer {
    background: rgba(255, 255, 255, 0.02);
    color: var(--tipz-text-muted-dark, #8a8f98);
    text-align: center;
    padding: 14px 24px;
    font-size: 0.8rem;
    border-top: 1px solid var(--tipz-border, rgba(255, 255, 255, 0.08));
    border-radius: 0 0 var(--trial-radius-lg) var(--trial-radius-lg);
}

@keyframes trial-lastchance-scale-in {
    from { transform: scale(0.92); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@media (max-width: 599px) {
    .trial-lastchance__primary,
    .trial-lastchance__secondary { grid-template-columns: 1fr; padding-left: 16px; padding-right: 16px; }
    .trial-lastchance__separator { padding-left: 16px; padding-right: 16px; }
    .trial-lastchance__header { padding: 20px 16px 24px; }
}

/* ─── Admin trial analytics ─────────────────────────────────── */
.trial-admin { padding: 24px; }
.trial-admin__header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; flex-wrap: wrap; gap: 16px; }
.trial-admin__header h1 { color: var(--tipz-text-strong); margin: 0; }
.trial-admin__filters { display: flex; gap: 16px; align-items: center; }

.trial-admin__kpis {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.trial-kpi-card {
    background: var(--trial-card-bg-dark);
    border: 1px solid var(--tipz-border);
    border-radius: var(--trial-radius-lg);
    padding: 24px;
    color: var(--tipz-text-strong);
}

.trial-kpi-card__label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--tipz-text-muted-dark);
    font-weight: 600;
}
.trial-kpi-card__value { font-size: 2.5rem; font-weight: 700; margin: 8px 0 4px; }
.trial-kpi-card__delta { font-size: 0.78rem; }
.trial-kpi-card__delta--up { color: #00C96B; }
.trial-kpi-card__delta--down { color: #ef5350; }
.trial-kpi-card__delta--flat { color: var(--tipz-text-muted-dark); }

.trial-admin__row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.trial-admin__card {
    background: var(--trial-card-bg-dark);
    border: 1px solid var(--tipz-border);
    border-radius: var(--trial-radius-lg);
    padding: 24px;
    margin-bottom: 16px;
    color: var(--tipz-text-strong);
}

.trial-admin__card h3 { font-size: 1.1rem; margin: 0 0 16px; }

.trial-funnel__row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 8px 0;
    min-width: 0;
}
.trial-funnel__label {
    flex: 0 0 auto;
    width: 140px;
    max-width: 40%;
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.trial-funnel__track {
    flex: 1 1 0;
    min-width: 0;
    height: 24px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}
.trial-funnel__bar {
    display: block;
    height: 100%;
    max-width: 100%;
    background: linear-gradient(90deg, var(--trial-state-informativo), var(--capa-control-bonus));
    border-radius: 4px;
    transition: width 300ms ease-out;
}
.trial-funnel__count {
    flex: 0 0 auto;
    min-width: 36px;
    text-align: right;
    font-weight: 700;
    font-size: 0.95rem;
    font-variant-numeric: tabular-nums;
}

/* En cards estrechos: label más corto, indentación reducida */
@media (max-width: 1199px) {
    .trial-funnel__label { width: 120px; }
}
@media (max-width: 767px) {
    .trial-funnel__label { width: 96px; font-size: 0.78rem; }
    .trial-funnel__row { padding-left: 0 !important; gap: 8px; }
}

.trial-admin__table { width: 100%; color: var(--tipz-text-strong); }
.trial-admin__table th { color: var(--tipz-text-muted-dark); font-size: 0.8rem; text-align: left; padding: 8px; border-bottom: 1px solid var(--tipz-border); }
.trial-admin__table td { padding: 8px; border-bottom: 1px solid var(--tipz-border); font-size: 0.9rem; }
.trial-admin__pct { font-weight: 700; }

@media (max-width: 1023px) {
    .trial-admin__kpis { grid-template-columns: repeat(2, 1fr); }
    .trial-admin__row { grid-template-columns: 1fr; }
}
@media (max-width: 599px) {
    .trial-admin__kpis { grid-template-columns: 1fr; }
}


/* ─── Admin trial-analytics: chart canvas sizing fix ────────── */
.trial-admin__card canvas {
    max-width: 100% !important;
    max-height: 300px !important;
    height: auto !important;
}
.trial-admin__card #chart-capas { max-height: 240px !important; }
.trial-admin__card #chart-per-day { max-height: 160px !important; }
.trial-admin__card #chart-conversion { max-height: 180px !important; }

/* ─── Dashboard header editorial (alineado footer V5) ───────────
   Reemplaza el dashboard-header gris con la estética del footer:
   #08080c bg + JetBrains Mono eyebrows + Syne display + #2bd97c accent. */
.dashboard-header.dashboard-header--editorial {
    background: #08080c !important;
    color: #FFFFFF !important;
    padding: 22px 0 24px !important;
    border-top: 1px solid rgba(43, 217, 124, 0.4) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
    box-shadow: none !important;
    position: static !important;
    overflow: visible !important;
}
.dashboard-header.dashboard-header--editorial::before,
.dashboard-header.dashboard-header--editorial::after { display: none !important; }
.dashboard-header.dashboard-header--editorial > .dashboard-container { position: static; }
.dashboard-header.dashboard-header--editorial > .dashboard-container::before { display: none; }

.dh-grid {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 28px;
    align-items: center;
}

.dh-brand { min-width: 0; display: flex; flex-direction: column; gap: 6px; }

.dh-eyebrow {
    font-family: 'JetBrains Mono', 'SF Mono', Consolas, monospace;
    font-size: 0.6875rem;
    font-weight: 500;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #2bd97c;
    line-height: 1;
}

.dh-title {
    font-family: 'Syne', 'Inter', sans-serif;
    font-size: clamp(1.6rem, 2.6vw, 2.1rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.025em;
    color: #FFFFFF;
    margin: 0;
    text-shadow: none;
}

/* Tags pill: PLAN + TRIAL */
.dh-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
}
.dh-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    font-family: 'JetBrains Mono', 'SF Mono', Consolas, monospace;
    font-size: 0.7rem;
    line-height: 1;
    transition: border-color 150ms ease, background 150ms ease;
    cursor: default;
}
.dh-tag__label {
    font-size: 0.625rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #8A8F98;
}
.dh-tag__value {
    color: #FFFFFF;
    font-weight: 600;
    letter-spacing: 0.02em;
}
.dh-tag i { font-size: 0.85rem; color: #8A8F98; }
.dh-tag--plan {
    cursor: pointer;
}
.dh-tag--plan:hover {
    border-color: rgba(43, 217, 124, 0.4);
    background: rgba(43, 217, 124, 0.06);
}
.dh-tag--plan:hover i { color: #2bd97c; }
.dh-tag--trial {
    border-color: rgba(43, 217, 124, 0.32);
    background: rgba(43, 217, 124, 0.06);
}
.dh-tag--trial i { color: #2bd97c; }
.dh-tag--trial .dh-tag__value { color: #2bd97c; }

/* Stat card derecha */
.dh-stat {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    min-width: 140px;
    text-align: left;
}
.dh-stat__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.dh-stat__label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.625rem;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #8A8F98;
}
.dh-stat__icon { color: #2bd97c; font-size: 0.9rem; }
.dh-stat__value-row {
    display: flex;
    align-items: baseline;
    gap: 6px;
    line-height: 1;
}
.dh-stat__value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.65rem;
    font-weight: 700;
    color: #FFFFFF;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.01em;
}
.dh-stat__total {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    color: #8A8F98;
    font-variant-numeric: tabular-nums;
}
.dh-stat__cta {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #2bd97c;
    text-decoration: none;
    margin-top: 2px;
    padding-top: 6px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    transition: color 150ms ease;
}
.dh-stat__cta:hover {
    color: #FFFFFF;
    text-decoration: none;
}
.dh-stat__cta i { transition: transform 150ms ease; }
.dh-stat__cta:hover i { transform: translateX(2px); }

/* Override de los reset legacy en dashboard.css */
.dashboard-header.dashboard-header--editorial h1.dh-title {
    font-size: clamp(1.6rem, 2.6vw, 2.1rem);
    margin: 0;
    text-shadow: none;
}
.dashboard-header.dashboard-header--editorial h1.dh-title i { display: none; }

/* Mobile */
@media (max-width: 767px) {
    .dashboard-header.dashboard-header--editorial { padding: 20px 0 22px !important; }
    .dh-grid { grid-template-columns: 1fr; gap: 16px; }
    .dh-stat { width: 100%; }
}


/* ─── Active hint panel + reset (E3 v4.2) ────────────────────────
   Banda inferior del stepper que muestra la INSTRUCCIÓN paso-a-paso
   de la misión activa, inline y siempre visible (sin necesidad de popover). */
.ts-active-hint {
    margin-top: 16px;
    padding: 14px 16px;
    background: rgba(43, 217, 124, 0.04);
    border: 1px solid rgba(43, 217, 124, 0.18);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
}
.ts-active-hint__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.ts-active-hint__title {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: -0.012em;
    color: #FFFFFF;
    margin: 0;
    line-height: 1.25;
}
.ts-active-hint__desc {
    color: #c8ccd4;
    font-size: 0.82rem;
    line-height: 1.5;
    margin: 0;
    max-width: 780px;
}
.ts-active-hint__actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 4px;
}
.ts-active-hint__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: #2bd97c;
    color: #08080c;
    border-radius: 6px;
    text-decoration: none;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-weight: 700;
    font-size: 0.84rem;
    letter-spacing: -0.01em;
    transition: transform 150ms ease-out, background 150ms ease-out;
    cursor: pointer;
    touch-action: manipulation;
}
.ts-active-hint__cta:hover { background: #4be39a; color: #08080c; text-decoration: none; transform: translateY(-1px); }
.ts-active-hint__cta i { transition: transform 150ms ease-out; }
.ts-active-hint__cta:hover i { transform: translateX(2px); }
.ts-active-hint__reset {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #8A8F98;
    padding: 8px 14px;
    border-radius: 6px;
    font-family: 'JetBrains Mono', 'SF Mono', Consolas, monospace;
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: color 150ms ease, border-color 150ms ease, background 150ms ease;
}
.ts-active-hint__reset:hover {
    color: #FFFFFF;
    border-color: rgba(255, 255, 255, 0.32);
    background: rgba(255, 255, 255, 0.04);
}
.ts-active-hint__reset:disabled {
    opacity: 0.5;
    cursor: wait;
}
.ts-active-hint__reset i { font-size: 0.85rem; }

.ts-active-hint--complete {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, rgba(43, 217, 124, 0.08), rgba(212, 175, 55, 0.06));
    border-color: rgba(43, 217, 124, 0.28);
}
.ts-active-hint--complete > div { display: flex; flex-direction: column; gap: 4px; }

@media (max-width: 600px) {
    .ts-active-hint__actions { flex-direction: column; align-items: stretch; }
    .ts-active-hint__cta { justify-content: center; }
    .ts-active-hint__reset { justify-content: center; }
    .ts-active-hint--complete { flex-direction: column; align-items: stretch; }
}


/* ─── Completion hints (E3 v4.3) ──────────────────────────────────
   Línea explícita "Se marca como cumplida cuando…" en el panel
   hint, popovers y toast efímero al clickear el CTA. */
.ts-active-hint__completion {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 0;
    padding: 8px 10px;
    background: rgba(43, 217, 124, 0.06);
    border-left: 2px solid #2bd97c;
    border-radius: 4px;
    font-size: 0.78rem;
    line-height: 1.5;
    color: #d2d6dd;
}
.ts-active-hint__completion i {
    color: #2bd97c;
    font-size: 0.95rem;
    margin-top: 1px;
    flex-shrink: 0;
}
.ts-active-hint__completion strong { color: #FFFFFF; font-weight: 600; }

.ts-popover__mission-hint {
    display: block;
    margin-top: 4px;
    padding-top: 4px;
    border-top: 1px dashed rgba(255, 255, 255, 0.08);
    font-style: normal;
    color: #2bd97c;
    font-size: 0.72rem;
    line-height: 1.4;
}
.ts-popover__mission-hint strong { color: #2bd97c; font-weight: 600; }

/* Toast efímero al click del CTA */
.ts-cta-toast {
    position: fixed;
    left: 50%;
    bottom: 32px;
    transform: translateX(-50%) translateY(20px);
    z-index: 1080;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    max-width: 560px;
    padding: 12px 18px;
    background: #08080c;
    border: 1px solid rgba(43, 217, 124, 0.42);
    border-radius: 8px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(43, 217, 124, 0.12);
    color: #FFFFFF;
    font-size: 0.85rem;
    line-height: 1.45;
    opacity: 0;
    transition: opacity 280ms ease-out, transform 280ms ease-out;
    pointer-events: none;
}
.ts-cta-toast--visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
.ts-cta-toast i {
    color: #2bd97c;
    font-size: 1.1rem;
    flex-shrink: 0;
    margin-top: 1px;
}
.ts-cta-toast strong { color: #2bd97c; font-weight: 600; }

@media (max-width: 600px) {
    .ts-cta-toast {
        left: 12px;
        right: 12px;
        bottom: 18px;
        transform: translateY(20px);
        max-width: none;
    }
    .ts-cta-toast--visible { transform: translateY(0); }
}


/* ─── Stacking con modales (E3 v4.4) ──────────────────────────────
   Cuando un Bootstrap modal está abierto (body.modal-open), bajamos los
   elementos flotantes del trial debajo del backdrop (1050) para que no
   tapen el contenido del modal — ej. al abrir PROB desde un partido.
   Bootstrap modal: 1055; backdrop: 1050. Navbar: 1030. */
body.modal-open .trial-toast,
body.modal-open aside.trial-chip,
body.modal-open .ts-cta-toast {
    z-index: 1040 !important;
}

/* ─── CTA bloqueada (orden secuencial de capas, E3 v4.5) ──────────
   Capas fuera de orden muestran candado con opacity reducida y
   cursor not-allowed. Al click, dispara toast ameno explicativo. */
.ts-step__cta--locked {
    background: rgba(255, 255, 255, 0.025);
    border: 1px dashed rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.38);
    cursor: not-allowed;
    position: relative;
    /* Padding + gap iguales al .ts-step__cta normal */
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 14px;
    border-radius: 6px;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.78rem;
    letter-spacing: -0.005em;
    text-decoration: none;
    text-align: left;
    line-height: 1.2;
    min-height: 38px;
    transition: background 150ms ease, border-color 150ms ease;
}
.ts-step__cta--locked:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.18);
    color: rgba(255, 255, 255, 0.52);
}
.ts-step__cta--locked i.bi-lock-fill {
    font-size: 0.85rem;
    opacity: 0.7;
}

/* Variante del toast inferior para mensaje de lock — ámbar suave */
.ts-cta-toast--lock {
    border-color: rgba(224, 122, 41, 0.42);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(224, 122, 41, 0.18);
}
.ts-cta-toast--lock i.bi-lock-fill {
    color: #E07A29;
    font-size: 1.05rem;
    flex-shrink: 0;
    margin-top: 1px;
}
.ts-cta-toast--lock strong {
    color: #E07A29;
    font-weight: 600;
}

