/* ═══════════════════════════════════════════════════════════════
   KHAPIA Landing — Premium (Stripe / Linear / Vercel style)
   ═══════════════════════════════════════════════════════════════ */
.kh-page {
    --kh-brand: #635bff;
    --kh-brand-2: #7c3aed;
    --kh-accent: #22d3ee;
    --kh-ink: #0a0a12;
    --kh-muted: #64748b;
    --kh-line: rgba(15, 23, 42, .08);
    --kh-bg: #fafbfc;
    --kh-soft: #f1f5f9;
    --kh-glass: rgba(255, 255, 255, .72);
    --kh-glass-border: rgba(255, 255, 255, .85);
    --kh-shadow: 0 24px 80px rgba(99, 91, 255, .12);
    --kh-radius: 20px;
    color: var(--kh-ink);
    background: var(--kh-bg);
    overflow-x: hidden;
}

html.dark .kh-page {
    --kh-ink: #f8fafc;
    --kh-muted: #94a3b8;
    --kh-line: rgba(255, 255, 255, .08);
    --kh-bg: #050508;
    --kh-soft: #0c0c14;
    --kh-glass: rgba(12, 12, 22, .65);
    --kh-glass-border: rgba(255, 255, 255, .08);
    --kh-shadow: 0 32px 90px rgba(0, 0, 0, .45);
}

.kh-wrap {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding-left: clamp(16px, 4vw, 24px);
    padding-right: clamp(16px, 4vw, 24px);
    box-sizing: border-box;
}
.kh-section { padding: clamp(64px, 10vw, 112px) 0; position: relative; }
.kh-label {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 7px 14px; border-radius: 999px; font-size: 11px; font-weight: 800;
    letter-spacing: .08em; text-transform: uppercase;
    background: linear-gradient(135deg, rgba(99,91,255,.12), rgba(124,58,237,.08));
    color: var(--kh-brand); border: 1px solid rgba(99,91,255,.18);
}
.kh-title {
    font-size: clamp(1.85rem, 4.2vw, 3.15rem); font-weight: 800; line-height: 1.08;
    letter-spacing: -.035em; margin: 18px 0 14px;
    max-width: 100%;
    overflow-wrap: break-word;
    word-wrap: break-word;
}
.kh-subtitle { font-size: 1.05rem; line-height: 1.75; color: var(--kh-muted); max-width: 620px; }
.kh-gradient-text {
    background: linear-gradient(135deg, #635bff 0%, #a78bfa 50%, #22d3ee 100%);
    -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.kh-alt { background: var(--kh-soft); }

/* Glass */
.kh-glass {
    background: var(--kh-glass);
    backdrop-filter: blur(20px) saturate(160%);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    border: 1px solid var(--kh-glass-border);
    box-shadow: var(--kh-shadow);
}

/* Buttons */
.kh-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 14px 22px; border-radius: 12px; font-size: 14px; font-weight: 700;
    text-decoration: none; border: none; cursor: pointer;
    transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
}
.kh-btn:hover { transform: translateY(-2px); }
.kh-btn-primary {
    background: linear-gradient(135deg, #635bff, #7c3aed);
    color: #fff; box-shadow: 0 16px 40px rgba(99, 91, 255, .35);
}
.kh-btn-secondary {
    background: var(--kh-glass); color: var(--kh-ink);
    border: 1px solid var(--kh-line);
}
.kh-btn-whatsapp { background: #25d366; color: #fff; box-shadow: 0 16px 40px rgba(37, 211, 102, .25); }
.kh-btn-ghost { background: transparent; border: 1px dashed rgba(99, 91, 255, .35); color: var(--kh-brand); }
.kh-btn-sm { padding: 10px 16px; font-size: 13px; }
.kh-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* Hero */
.kh-hero {
    padding: clamp(24px, 4vw, 40px) 0 clamp(56px, 8vw, 96px);
    background:
        radial-gradient(ellipse 90% 70% at 10% -10%, rgba(99, 91, 255, .18), transparent 55%),
        radial-gradient(ellipse 60% 50% at 90% 10%, rgba(34, 211, 238, .08), transparent 50%),
        var(--kh-bg);
    overflow-x: clip;
}
.kh-hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
    gap: clamp(28px, 4vw, 48px);
    align-items: center;
    width: 100%;
}
.kh-hero-grid > * { min-width: 0; max-width: 100%; }
.kh-hero-copy { max-width: 100%; }
.kh-hero .kh-title,
.kh-hero h1.kh-title {
    font-size: 38px;
    line-height: 1.05;
    letter-spacing: -0.035em;
    margin: 16px 0 12px;
    max-width: 100%;
    overflow-wrap: break-word;
    hyphens: auto;
}
.kh-hero-lead {
    font-size: clamp(1rem, 2.2vw, 1.125rem);
    line-height: 1.75;
    color: var(--kh-muted);
    margin: 12px 0 0;
    max-width: 100%;
}
.kh-hero-lines { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 8px; }
.kh-pill {
    padding: 7px 12px; border-radius: 999px; font-size: 12px; font-weight: 700;
    background: var(--kh-glass); border: 1px solid var(--kh-line); color: var(--kh-ink);
}
.kh-hero .kh-actions { margin-top: 24px; }
.kh-hero .kh-market { max-width: 100%; min-width: 0; }

@media (min-width: 768px) {
    .kh-hero .kh-title,
    .kh-hero h1.kh-title { font-size: 48px; }
}
@media (min-width: 1024px) {
    .kh-hero .kh-title,
    .kh-hero h1.kh-title { font-size: clamp(48px, 4.2vw, 64px); }
}
@media (max-width: 767px) {
    .kh-hero .kh-actions { flex-direction: column; align-items: stretch; }
    .kh-hero .kh-actions .kh-btn { width: 100%; justify-content: center; }
}

/* Ad marketplace */
.kh-market { position: relative; max-width: 100%; overflow: hidden; }
.kh-market-glow {
    position: absolute; inset: -12% -8%; z-index: 0;
    background: radial-gradient(circle at 50% 40%, rgba(99, 91, 255, .25), transparent 65%);
    filter: blur(48px); pointer-events: none;
}
.kh-market-hero-wrap { position: relative; z-index: 1; min-height: 220px; border-radius: 24px; overflow: hidden; }
.kh-market-hero {
    position: absolute; inset: 0; opacity: 0; transform: scale(1.02);
    transition: opacity .55s ease, transform .55s ease; border-radius: 24px; overflow: hidden;
}
.kh-market-hero.is-active { opacity: 1; transform: scale(1); position: relative; }
.kh-market-img { width: 100%; height: 100%; object-fit: cover; display: block; min-height: 220px; }
.kh-market-overlay {
    position: absolute; inset: auto 0 0 0; padding: 24px;
    background: linear-gradient(to top, rgba(5, 5, 8, .88), transparent);
    color: #fff;
}
.kh-market-overlay h3 { font-size: 1.25rem; font-weight: 800; margin: 6px 0; }
.kh-market-overlay p { font-size: .875rem; opacity: .85; margin-bottom: 12px; }
.kh-market-tag { font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; opacity: .7; }
.kh-market-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; position: relative; z-index: 1; }
.kh-market-tile { border-radius: 16px; overflow: hidden; min-height: 120px; transition: transform .3s ease; }
.kh-market-tile:hover { transform: translateY(-4px); }
.kh-market-tile .kh-market-img { min-height: 120px; }
.kh-market-tile-foot {
    display: flex; justify-content: space-between; align-items: center; gap: 8px;
    padding: 12px 14px; font-size: 12px; font-weight: 700;
    border-top: 1px solid var(--kh-line);
}
.kh-market-tile-foot a { color: var(--kh-brand); text-decoration: none; white-space: nowrap; }
.kh-market-wide { margin-top: 12px; border-radius: 16px; overflow: hidden; min-height: 100px; position: relative; z-index: 1; }
.kh-market-wide .kh-market-img { min-height: 100px; }
.kh-market-ph {
    display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
    gap: 8px; padding: 24px; color: var(--kh-ink); position: relative;
    background: linear-gradient(135deg, rgba(99,91,255,.12), rgba(34,211,238,.06));
    border: 1px dashed rgba(99, 91, 255, .25);
}
/* Mockups de negocio ficticio — nunca deben confundirse con un anuncio real */
.kh-market-ph.is-demo { border-style: solid; }
.kh-market-ph-demo-tag {
    position: absolute; top: 10px; right: 10px;
    font-size: 9px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
    padding: 3px 8px; border-radius: 999px;
    background: rgba(0, 0, 0, .55); color: #fff;
}
.kh-market-ph-xl { min-height: 220px; }
.kh-market-ph-md { min-height: 120px; }
.kh-market-ph-wide { min-height: 100px; flex-direction: row; flex-wrap: wrap; }
.kh-market-ph-label { font-size: 10px; font-weight: 800; letter-spacing: .08em; opacity: .55; text-transform: uppercase; }
.kh-market-ph strong { font-size: 1rem; font-weight: 800; }
.kh-market-dots { display: flex; justify-content: center; gap: 8px; margin-top: 16px; position: relative; z-index: 1; }
.kh-market-dot {
    width: 8px; height: 8px; border-radius: 999px; border: none; padding: 0;
    background: var(--kh-line); cursor: pointer; transition: width .3s ease, background .3s ease;
}
.kh-market-dot.is-active { width: 24px; background: var(--kh-brand); }
.kh-market-note { text-align: center; font-size: 12px; color: var(--kh-muted); margin-top: 12px; font-weight: 600; }

/* Posiciones independientes */
.kh-ad-slot { position: relative; overflow: hidden; }
.kh-ad-slot.is-placeholder { border: 1px dashed rgba(99, 91, 255, .25); }
.kh-ad-slot-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.kh-ad-slot-ph { width: 100%; }
.kh-market-ph-footer { min-height: 140px; }
.kh-ad-slot-caption {
    position: absolute; inset: auto 0 0 0; padding: 16px 20px;
    background: linear-gradient(transparent, rgba(9, 9, 20, .82));
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.kh-ad-slot-caption strong { font-size: .95rem; font-weight: 800; color: #fff; }
.kh-ad-slot-section, .kh-ad-slot-footer { border-radius: 20px; min-height: 180px; }
.kh-ad-slot-footer { min-height: 200px; }
.kh-ad-section-carousel { position: relative; }
.kh-ad-section-track { position: relative; min-height: 180px; }
.kh-ad-section-slide {
    opacity: 0; transform: translateY(8px); transition: opacity .45s ease, transform .45s ease;
    position: absolute; inset: 0; pointer-events: none;
}
.kh-ad-section-slide.is-active { opacity: 1; transform: none; position: relative; pointer-events: auto; }
.kh-section-banner-footer { padding-top: 0; padding-bottom: 48px; }

/* Service cards */
.kh-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.kh-grid-6 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.kh-svc {
    padding: 24px; border-radius: var(--kh-radius); transition: transform .35s ease, box-shadow .35s ease;
}
.kh-svc:hover { transform: translateY(-6px); box-shadow: 0 28px 60px rgba(99, 91, 255, .15); }
.kh-svc-icon {
    width: 56px; height: 56px; margin-bottom: 18px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 16px;
    background: rgba(0, 210, 106, .12);
    color: #00d26a;
}
.kh-svc-icon svg { width: 28px; height: 28px; }
.kh-svc h3 { font-size: 1.05rem; font-weight: 800; margin: 0 0 8px; }
.kh-svc p { font-size: .9rem; line-height: 1.6; color: var(--kh-muted); margin: 0; }

/* Espacios publicitarios — vitrina comercial */
.kh-section-spaces {
    background:
        radial-gradient(ellipse 80% 50% at 50% 0%, rgba(99, 91, 255, .06), transparent 60%),
        var(--kh-bg);
}
.kh-spaces-intro {
    margin: 20px 0 28px;
    padding: 12px 16px;
    border-radius: 12px;
    border: 1px solid var(--kh-line);
    background: var(--kh-glass);
    font-size: 13px;
    font-weight: 600;
    color: var(--kh-muted);
    text-align: center;
}
.kh-spaces-layout {
    --kh-space-card-h: 540px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.kh-spaces-row {
    display: grid;
    gap: 18px;
    align-items: stretch;
    grid-auto-rows: var(--kh-space-card-h);
}
.kh-spaces-row-full { grid-template-columns: minmax(0, 1fr); }
.kh-spaces-row-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kh-spaces-row-center > .kh-space-card { grid-column: 2; }
.kh-space-card {
    position: relative;
    border-radius: 22px;
    overflow: hidden;
    height: var(--kh-space-card-h);
    min-height: var(--kh-space-card-h);
    max-height: var(--kh-space-card-h);
    width: 100%;
    transition: transform 300ms cubic-bezier(.22, 1, .36, 1), box-shadow 300ms ease, border-color 300ms ease;
    border: 1px solid rgba(255, 255, 255, .14);
    background: rgba(255, 255, 255, .05);
    backdrop-filter: blur(20px) saturate(160%);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .12),
        0 20px 50px rgba(0, 0, 0, .18);
}
html:not(.dark) .kh-space-card {
    background: rgba(255, 255, 255, .82);
    border-color: rgba(15, 23, 42, .08);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, .95),
        0 18px 50px rgba(15, 23, 42, .07);
}
.kh-space-card-border {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(145deg, color-mix(in srgb, var(--space-a, #635bff) 55%, transparent), transparent 45%, color-mix(in srgb, var(--space-b, #7c3aed) 40%, transparent));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: .65;
    pointer-events: none;
    transition: opacity 300ms ease;
}
.kh-space-card:hover {
    transform: translateY(-8px);
    box-shadow:
        0 32px 80px color-mix(in srgb, var(--space-a, #635bff) 32%, transparent),
        0 0 0 1px color-mix(in srgb, var(--space-a, #635bff) 25%, transparent),
        inset 0 1px 0 rgba(255, 255, 255, .16);
}
.kh-space-card:hover .kh-space-card-border { opacity: 1; }
.kh-space-card-glow {
    position: absolute;
    inset: 0;
    opacity: .7;
    pointer-events: none;
    transition: opacity 300ms ease, filter 300ms ease;
}
.kh-space-card:hover .kh-space-card-glow {
    opacity: 1;
    filter: brightness(1.15);
}
.kh-space-card-inner {
    position: relative;
    z-index: 1;
    padding: 20px 18px 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    height: 100%;
    overflow: hidden;
}
.kh-space-occupancy {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .02em;
    background: rgba(0, 0, 0, .35);
    border: 1px solid rgba(255, 255, 255, .12);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
html:not(.dark) .kh-space-occupancy {
    background: rgba(255, 255, 255, .92);
    border-color: rgba(15, 23, 42, .08);
}
.kh-space-occupancy.is-available { color: #34d399; }
.kh-space-occupancy.is-limited { color: #fbbf24; }
.kh-space-occupancy.is-soldout { color: #f87171; }
html:not(.dark) .kh-space-occupancy.is-soldout { color: #dc2626; }
.kh-space-slots-left {
    opacity: .85;
    font-size: 9px;
    font-weight: 700;
    margin-left: 2px;
}
.kh-space-card.is-sold-out {
    opacity: .92;
}
.kh-space-card.is-sold-out .kh-space-card-glow { opacity: .45; }
.kh-space-cta--disabled {
    cursor: not-allowed;
    opacity: .55;
    background: linear-gradient(135deg, #64748b, #475569);
    box-shadow: none;
}
.kh-spaces-empty {
    color: var(--kh-muted);
    padding: 2rem 0;
}
.kh-space-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-height: 24px;
    padding-right: 96px;
}
.kh-space-badge {
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    background: rgba(255, 255, 255, .12);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, .16);
}
html:not(.dark) .kh-space-badge {
    background: rgba(15, 23, 42, .06);
    color: #334155;
    border-color: rgba(15, 23, 42, .08);
}
.kh-space-badge.is-web { background: rgba(99, 91, 255, .16); color: #c4b5fd; border-color: rgba(99, 91, 255, .28); }
.kh-space-badge.is-premium { background: rgba(167, 139, 250, .22); color: #c4b5fd; border-color: rgba(167, 139, 250, .35); }
.kh-space-badge.is-popular { background: rgba(52, 211, 153, .18); color: #6ee7b7; border-color: rgba(52, 211, 153, .35); }
.kh-space-badge.is-app { background: rgba(34, 211, 238, .18); color: #67e8f9; border-color: rgba(34, 211, 238, .35); }
html:not(.dark) .kh-space-badge.is-web { color: #4f46e5; }
html:not(.dark) .kh-space-badge.is-premium { color: #6d28d9; }
html:not(.dark) .kh-space-badge.is-popular { color: #059669; }
html:not(.dark) .kh-space-badge.is-app { color: #0891b2; }

/* Mockups vectoriales */
.kh-space-mockup {
    flex-shrink: 0;
    height: 118px;
    border-radius: 14px;
    padding: 10px 12px;
    background: rgba(0, 0, 0, .22);
    border: 1px solid rgba(255, 255, 255, .1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--space-a, #635bff);
}
html:not(.dark) .kh-space-mockup {
    background: rgba(15, 23, 42, .04);
    border-color: rgba(15, 23, 42, .08);
    color: var(--space-a, #635bff);
}
.kh-mock-svg {
    width: 100%;
    height: 100%;
    max-height: 98px;
    display: block;
}
.kh-mock-svg-phone {
    width: auto;
    max-width: 56px;
    max-height: 98px;
}
.kh-mock-highlight {
    fill: color-mix(in srgb, var(--space-a, #635bff) 60%, var(--space-b, #7c3aed));
    fill-opacity: .5;
    stroke: color-mix(in srgb, var(--space-a, #635bff) 75%, #fff);
    stroke-width: 1;
    stroke-opacity: .55;
}

.kh-space-card-title {
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: -.02em;
    margin: 0;
    color: var(--kh-ink);
    line-height: 1.25;
}
.kh-space-ideal {
    padding: 8px 10px;
    border-radius: 10px;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .08);
}
html:not(.dark) .kh-space-ideal {
    background: rgba(15, 23, 42, .03);
    border-color: rgba(15, 23, 42, .06);
}
.kh-space-ideal-label {
    display: block;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--kh-muted);
    margin-bottom: 4px;
}
.kh-space-ideal-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 4px 10px;
}
.kh-space-ideal-list li {
    font-size: 11px;
    font-weight: 600;
    color: var(--kh-ink);
    line-height: 1.3;
}
.kh-space-ideal-list li::before {
    content: "•";
    margin-right: 4px;
    color: var(--space-a, #635bff);
    opacity: .8;
}
.kh-space-card-meta {
    margin: 0;
    display: grid;
    gap: 8px;
    flex: 1;
    min-height: 0;
}
.kh-space-meta-row { display: grid; gap: 2px; }
.kh-space-meta-row dt {
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--kh-muted);
}
.kh-space-meta-row dd {
    margin: 0;
    font-size: 12px;
    line-height: 1.45;
    font-weight: 600;
    color: var(--kh-ink);
}
.kh-space-meta-clamp {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.kh-space-meta-price dd {
    font-size: 1rem;
    font-weight: 800;
    color: var(--kh-brand);
}
.kh-space-meta-views dd {
    font-size: 11px;
    font-weight: 700;
    color: var(--kh-muted);
    padding-top: 2px;
}
.kh-space-card-foot {
    flex-shrink: 0;
    padding-top: 10px;
    border-top: 1px solid var(--kh-line);
    margin-top: auto;
}
.kh-space-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 11px 16px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    color: #fff;
    background: linear-gradient(135deg, var(--space-a, #635bff), var(--space-b, #7c3aed));
    box-shadow: 0 10px 28px color-mix(in srgb, var(--space-a, #635bff) 35%, transparent);
    transition: transform 300ms ease, box-shadow 300ms ease, opacity 300ms ease;
}
.kh-space-cta:hover { transform: translateY(-2px); opacity: .95; }

/* Temas por tipo de espacio */
.kh-space-card--principal { --space-a: #635bff; --space-b: #7c3aed; }
.kh-space-card--principal .kh-space-card-glow { background: linear-gradient(145deg, rgba(99,91,255,.32), rgba(124,58,237,.14)); }
.kh-space-card--destacado { --space-a: #10b981; --space-b: #059669; }
.kh-space-card--destacado .kh-space-card-glow { background: linear-gradient(145deg, rgba(16,185,129,.28), rgba(5,150,105,.12)); }
.kh-space-card--lateral { --space-a: #f97316; --space-b: #fb923c; }
.kh-space-card--lateral .kh-space-card-glow { background: linear-gradient(145deg, rgba(249,115,22,.28), rgba(251,146,60,.12)); }
.kh-space-card--negocio { --space-a: #ec4899; --space-b: #d946ef; }
.kh-space-card--negocio .kh-space-card-glow { background: linear-gradient(145deg, rgba(236,72,153,.26), rgba(217,70,239,.12)); }
.kh-space-card--app-inicio { --space-a: #06b6d4; --space-b: #38bdf8; }
.kh-space-card--app-inicio .kh-space-card-glow { background: linear-gradient(145deg, rgba(6,182,212,.28), rgba(56,189,248,.12)); }
.kh-space-card--splash { --space-a: #f59e0b; --space-b: #fbbf24; }
.kh-space-card--splash .kh-space-card-glow { background: linear-gradient(145deg, rgba(245,158,11,.3), rgba(251,191,36,.14)); }
.kh-space-card--inferior { --space-a: #1e3a8a; --space-b: #172554; }
.kh-space-card--inferior .kh-space-card-glow { background: linear-gradient(145deg, rgba(30,58,138,.36), rgba(23,37,84,.2)); }

/* Banda campaña personalizada */
.kh-campaign-band {
    position: relative;
    margin: 48px 0 0;
    padding: clamp(28px, 4vw, 40px) clamp(24px, 4vw, 48px);
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .12);
}
html:not(.dark) .kh-campaign-band {
    border-color: rgba(99, 91, 255, .18);
    background: rgba(255, 255, 255, .75);
}
.kh-campaign-band-glow {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 70% 120% at 0% 50%, rgba(99, 91, 255, .22), transparent 55%),
        radial-gradient(ellipse 60% 100% at 100% 50%, rgba(124, 58, 237, .18), transparent 50%);
    pointer-events: none;
}
.kh-campaign-band-inner {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}
.kh-campaign-band-title {
    font-size: clamp(1.15rem, 2.2vw, 1.45rem);
    font-weight: 800;
    letter-spacing: -.02em;
    margin: 0 0 8px;
    color: var(--kh-ink);
}
.kh-campaign-band-text {
    margin: 0;
    max-width: 640px;
    font-size: .95rem;
    line-height: 1.65;
    color: var(--kh-muted);
    font-weight: 500;
}
.kh-campaign-band-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    color: #fff;
    white-space: nowrap;
    background: linear-gradient(135deg, #635bff, #7c3aed);
    box-shadow: 0 14px 36px rgba(99, 91, 255, .35);
    transition: transform .25s ease, box-shadow .25s ease;
}
.kh-campaign-band-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 44px rgba(99, 91, 255, .42);
}

/* Planes premium */
.kh-section-plans {
    background:
        radial-gradient(ellipse 70% 45% at 50% 0%, rgba(124, 58, 237, .06), transparent 60%),
        var(--kh-bg);
}
.kh-plans-showcase {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    align-items: stretch;
    margin-top: 40px;
}
.kh-plan-card {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    height: 100%;
    min-height: 100%;
    border: 1px solid rgba(255, 255, 255, .12);
    background: rgba(255, 255, 255, .04);
    backdrop-filter: blur(18px) saturate(150%);
    -webkit-backdrop-filter: blur(18px) saturate(150%);
    transition: transform .4s cubic-bezier(.22, 1, .36, 1), box-shadow .4s ease;
}
html:not(.dark) .kh-plan-card {
    background: rgba(255, 255, 255, .82);
    border-color: rgba(15, 23, 42, .08);
    box-shadow: 0 18px 50px rgba(15, 23, 42, .06);
}
.kh-plan-card-glow {
    position: absolute;
    inset: 0;
    opacity: .5;
    pointer-events: none;
    background: linear-gradient(160deg, rgba(99, 91, 255, .12), transparent 55%);
}
.kh-plan-card-border {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(145deg, rgba(255, 255, 255, .22), transparent 50%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: .5;
    pointer-events: none;
}
.kh-plan-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 28px 70px rgba(99, 91, 255, .16);
}
.kh-plan-card-inner {
    position: relative;
    z-index: 1;
    padding: 32px 28px 28px;
    display: flex;
    flex-direction: column;
    height: 100%;
    text-align: left;
}
.kh-plan-card-badge {
    align-self: flex-start;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
    margin-bottom: 16px;
    background: rgba(52, 211, 153, .18);
    color: #6ee7b7;
    border: 1px solid rgba(52, 211, 153, .35);
}
html:not(.dark) .kh-plan-card-badge { color: #059669; }
.kh-plan-card-name {
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    margin: 0 0 10px;
    color: var(--kh-ink);
}
.kh-plan-card-price {
    font-size: clamp(2.25rem, 4vw, 2.75rem);
    font-weight: 900;
    letter-spacing: -.03em;
    line-height: 1;
    color: var(--kh-ink);
}
.kh-plan-currency {
    font-size: 1rem;
    font-weight: 700;
    opacity: .55;
    margin-right: 2px;
}
.kh-plan-card-period {
    margin: 8px 0 0;
    font-size: 12px;
    color: var(--kh-muted);
    font-weight: 600;
}
.kh-plan-card-divider {
    height: 1px;
    margin: 22px 0 18px;
    background: var(--kh-line);
}
.kh-plan-includes-label {
    margin: 0 0 12px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--kh-muted);
}
.kh-plan-features {
    list-style: none;
    margin: 0 0 24px;
    padding: 0;
    display: grid;
    gap: 10px;
    flex: 1;
}
.kh-plan-features li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: .875rem;
    font-weight: 600;
    line-height: 1.4;
    color: var(--kh-ink);
}
.kh-plan-feature-text {
    display: flex;
    flex-direction: column;
    gap: 1px;
}
.kh-plan-feature-text strong {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: var(--kh-muted);
}
.kh-plan-feature-text span {
    font-size: .875rem;
    font-weight: 600;
    color: var(--kh-ink);
}
.kh-plan-check {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .65rem;
    font-weight: 800;
    color: #34d399;
    background: rgba(52, 211, 153, .15);
    margin-top: 1px;
}
.kh-plan-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 13px 18px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    color: #fff;
    background: linear-gradient(135deg, #635bff, #7c3aed);
    box-shadow: 0 12px 32px rgba(99, 91, 255, .28);
    transition: transform .25s ease, box-shadow .25s ease;
    margin-top: auto;
}
.kh-plan-cta:hover { transform: translateY(-2px); }

/* Plan Destacado */
.kh-plan-card.is-featured {
    border-color: rgba(99, 91, 255, .38);
    box-shadow: 0 24px 64px rgba(99, 91, 255, .18);
    transform: scale(1.02);
}
.kh-plan-card.is-featured:hover { transform: scale(1.02) translateY(-8px); }
.kh-plan-card--featured .kh-plan-card-glow {
    background: linear-gradient(160deg, rgba(99, 91, 255, .22), rgba(124, 58, 237, .1) 55%, transparent);
}
.kh-plan-card--featured .kh-plan-card-border {
    background: linear-gradient(145deg, rgba(99, 91, 255, .55), rgba(124, 58, 237, .25));
    opacity: .85;
}

/* Plan Premium — brillo, glass y sello */
.kh-plan-card--premium {
    border-color: rgba(251, 191, 36, .45);
    background: linear-gradient(165deg, rgba(251, 191, 36, .1) 0%, rgba(124, 58, 237, .12) 45%, rgba(255, 255, 255, .06) 100%);
    box-shadow:
        0 0 40px rgba(251, 191, 36, .12),
        0 0 80px rgba(124, 58, 237, .08),
        inset 0 1px 0 rgba(255, 255, 255, .12);
}
html:not(.dark) .kh-plan-card--premium {
    background: linear-gradient(165deg, rgba(251, 191, 36, .14) 0%, rgba(124, 58, 237, .1) 45%, rgba(255, 255, 255, .94) 100%);
}
.kh-plan-card--premium .kh-plan-card-glow {
    opacity: .9;
    background:
        radial-gradient(circle at 20% 0%, rgba(251, 191, 36, .4), transparent 45%),
        radial-gradient(circle at 80% 100%, rgba(124, 58, 237, .32), transparent 50%),
        linear-gradient(160deg, rgba(245, 158, 11, .18), transparent 60%);
}
.kh-plan-card--premium .kh-plan-card-border {
    opacity: 1;
    background: linear-gradient(135deg, rgba(251, 191, 36, .85), rgba(124, 58, 237, .65), rgba(99, 91, 255, .55));
    animation: kh-premium-border 4s ease-in-out infinite;
    box-shadow: 0 0 20px rgba(251, 191, 36, .25);
}
.kh-plan-seal {
    position: absolute;
    top: 16px;
    right: -32px;
    z-index: 3;
    transform: rotate(35deg);
    padding: 6px 40px;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: #1a1a2e;
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    box-shadow: 0 4px 16px rgba(245, 158, 11, .4);
    pointer-events: none;
}
.kh-plan-card--premium .kh-plan-card-badge {
    background: linear-gradient(135deg, rgba(251, 191, 36, .32), rgba(124, 58, 237, .24));
    color: #fde68a;
    border-color: rgba(251, 191, 36, .5);
}
html:not(.dark) .kh-plan-card--premium .kh-plan-card-badge { color: #b45309; }
.kh-plan-card--premium .kh-plan-cta {
    background: linear-gradient(135deg, #f59e0b, #7c3aed 55%, #635bff);
    box-shadow: 0 14px 40px rgba(245, 158, 11, .28);
}
.kh-plan-card--premium::after {
    content: "";
    position: absolute;
    top: -50%;
    left: -60%;
    width: 45%;
    height: 200%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .16), transparent);
    transform: rotate(18deg);
    animation: kh-premium-shine 5s ease-in-out infinite;
    pointer-events: none;
}

/* Tabla comparación planes */
.kh-plans-compare {
    margin-top: 32px;
    padding: 24px;
    border-radius: 20px;
    border: 1px solid var(--kh-line);
    overflow: hidden;
}
.kh-plans-compare-title {
    margin: 0 0 16px;
    font-size: .95rem;
    font-weight: 800;
    letter-spacing: -.01em;
    color: var(--kh-ink);
    text-align: center;
}
.kh-plans-compare-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.kh-plans-compare-table {
    width: 100%;
    min-width: 480px;
    border-collapse: collapse;
    font-size: 13px;
}
.kh-plans-compare-table th,
.kh-plans-compare-table td {
    padding: 12px 14px;
    text-align: center;
    border-bottom: 1px solid var(--kh-line);
    font-weight: 600;
    color: var(--kh-ink);
}
.kh-plans-compare-table thead th {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--kh-muted);
    background: rgba(255, 255, 255, .04);
}
html:not(.dark) .kh-plans-compare-table thead th {
    background: rgba(15, 23, 42, .03);
}
.kh-plans-compare-table tbody th {
    text-align: left;
    font-size: 12px;
    font-weight: 700;
    color: var(--kh-muted);
}
.kh-plans-compare-table tbody tr:last-child th,
.kh-plans-compare-table tbody tr:last-child td {
    border-bottom: none;
}
.kh-plans-compare-table .is-premium-col {
    background: rgba(251, 191, 36, .06);
    font-weight: 700;
    color: var(--kh-ink);
}
html:not(.dark) .kh-plans-compare-table .is-premium-col {
    background: rgba(251, 191, 36, .1);
}
@keyframes kh-premium-shine {
    0%, 72% { transform: translateX(-120%) rotate(18deg); opacity: 0; }
    78% { opacity: 1; }
    100% { transform: translateX(320%) rotate(18deg); opacity: 0; }
}
@keyframes kh-premium-border {
    0%, 100% { filter: hue-rotate(0deg); }
    50% { filter: hue-rotate(12deg); }
}

/* Legacy plan classes (compat) */
.kh-plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; }
.kh-plan {
    padding: 32px 28px; border-radius: 24px; text-align: center; position: relative;
    transition: transform .35s ease, box-shadow .35s ease;
}
.kh-plan:hover { transform: translateY(-8px); }
.kh-plan-featured {
    border-color: rgba(99, 91, 255, .45);
    box-shadow: 0 32px 80px rgba(99, 91, 255, .2);
    transform: scale(1.03);
}
.kh-plan-featured:hover { transform: scale(1.03) translateY(-8px); }
.kh-plan-badge {
    position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
    padding: 5px 14px; border-radius: 999px; font-size: 10px; font-weight: 800;
    background: linear-gradient(135deg, #635bff, #7c3aed); color: #fff; letter-spacing: .06em; text-transform: uppercase;
}
.kh-plan-name { font-size: 1rem; font-weight: 800; margin-bottom: 8px; }
.kh-plan-price { font-size: 2.75rem; font-weight: 900; letter-spacing: -.03em; line-height: 1; }
.kh-plan-price small { font-size: 1rem; font-weight: 700; opacity: .6; }
.kh-plan-period { font-size: 12px; color: var(--kh-muted); margin: 8px 0 20px; }

/* Impact (qualitative — replaces the old animated-number stats) */
.kh-impact-headline { font-size: 1.25rem; font-weight: 800; letter-spacing: -.02em; margin-bottom: 8px; }
.kh-impact-slots { display: inline-flex; margin-top: 16px; color: var(--kh-brand); border-color: rgba(99, 91, 255, .25); }

/* Steps flow */
.kh-flow { display: flex; align-items: flex-start; justify-content: center; flex-wrap: wrap; gap: 8px; }
.kh-flow-step {
    flex: 1; min-width: 160px; max-width: 220px; padding: 24px 20px; border-radius: 18px; text-align: center;
}
.kh-flow-num {
    width: 40px; height: 40px; margin: 0 auto 14px; border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #635bff, #7c3aed); color: #fff; font-weight: 900; font-size: 15px;
}
.kh-flow-step h4 { font-size: .95rem; font-weight: 800; margin-bottom: 6px; }
.kh-flow-step p { font-size: .8rem; color: var(--kh-muted); margin: 0; line-height: 1.55; }
.kh-flow-arrow { align-self: center; color: var(--kh-muted); font-size: 1.25rem; padding: 0 4px; opacity: .5; }

/* CTA */
.kh-cta {
    padding: clamp(40px, 6vw, 64px); border-radius: 28px; text-align: center; overflow: hidden; position: relative;
    background: linear-gradient(135deg, #1a1a2e 0%, #2d1b69 50%, #1a1a2e 100%);
    color: #fff;
}
html:not(.dark) .kh-cta {
    background: linear-gradient(135deg, #635bff 0%, #7c3aed 55%, #4f46e5 100%);
}
.kh-cta h2 { font-size: clamp(1.75rem, 3vw, 2.35rem); font-weight: 900; margin-bottom: 12px; position: relative; z-index: 1; }
.kh-cta p { opacity: .9; max-width: 520px; margin: 0 auto 28px; line-height: 1.7; position: relative; z-index: 1; }
.kh-cta .kh-actions { justify-content: center; position: relative; z-index: 1; }
.kh-cta .kh-btn-secondary { background: #fff; color: #1a1a2e; border: none; }

/* Reveal */
.kh-reveal { opacity: 0; transform: translateY(28px); transition: opacity .75s ease, transform .75s ease; }
.kh-reveal.is-visible { opacity: 1; transform: none; }

.kh-landing-body { overflow-x: hidden; max-width: 100%; }

@media (max-width: 1024px) {
    .kh-hero-grid { grid-template-columns: minmax(0, 1fr); }
    .kh-spaces-layout { --kh-space-card-h: 520px; }
    .kh-spaces-row-full,
    .kh-spaces-row-3 { grid-template-columns: 1fr; }
    .kh-spaces-row-center > .kh-space-card { grid-column: auto; }
    .kh-grid-6 { grid-template-columns: repeat(2, 1fr); }
    .kh-plans-showcase,
    .kh-plans { grid-template-columns: 1fr; }
    .kh-plan-card.is-featured { transform: none; }
    .kh-plan-card.is-featured:hover { transform: translateY(-8px); }
    .kh-plan-featured { transform: none; }
    .kh-campaign-band-inner { flex-direction: column; align-items: flex-start; }
    .kh-campaign-band-cta { width: 100%; }
}
@media (max-width: 640px) {
    .kh-spaces-layout { --kh-space-card-h: auto; gap: 16px; }
    .kh-spaces-row { gap: 16px; grid-auto-rows: auto; }
    .kh-space-card {
        height: auto;
        min-height: 480px;
        max-height: none;
    }
    .kh-market-grid, .kh-grid-3, .kh-grid-6 { grid-template-columns: 1fr; }
    .kh-flow-arrow { display: none; }
    .kh-flow-step { max-width: 100%; }
    .kh-market-overlay h3 { font-size: 1.05rem; }
    .kh-market-ph strong { font-size: .9rem; }
    .kh-space-cta { width: 100%; }
    .kh-campaign-band { margin-top: 32px; border-radius: 18px; }
    .kh-plans-compare { padding: 18px 14px; border-radius: 16px; }
    .kh-plan-seal { right: -28px; font-size: 8px; padding: 5px 36px; }
}
