/* ============================================================================
   LAUNCH CARD REDESIGN — Scene 7 (#psScene7 / #psPackages)
   ----------------------------------------------------------------------------
   Premium "receipt" treatment for the R199 launch card PLUS the scene-level
   layout fixes so this scene matches every other scene in the multiform:

       ┌──────────────────────────────┬──────────────────┐
       │ Heading (progress, eyebrow,  │                  │
       │ h2, subtitle)                │  Digital Twin    │
       │                              │  Readiness       │
       │ ── BODY ─────────────────    │  Launch Intel    │
       │ Launch card (receipt)        │  ( #psRight7 )   │
       │                              │                  │
       │ ── FOOTER (sticky) ──────    │                  │
       │ Back  |  Launch — R199       │                  │
       └──────────────────────────────┴──────────────────┘

   Pair with launch-card-redesign.js (which only rewrites the card body).

   Load AFTER private-seller-bb344727.css in _Layout.cshtml:

     <link rel="stylesheet" href="~/css/private-seller-bb344727.css" asp-append-version="true" />
     <link rel="stylesheet" href="~/css/launch-card-redesign.css"    asp-append-version="true" />

   Brand tokens (orange, dark, muted, success, radius, shadow) inherit from
   the existing :root in private-seller-bb344727.css.
   ============================================================================ */


/* ============================================================================
   SCENE-LEVEL LAYOUT  (psScene7)
   ----------------------------------------------------------------------------
   Forces the scene back into the standard two-column [left | right] shell
   used everywhere else in the multiform. Without this, the launch card
   was bleeding across both columns and the digital twin dropped underneath.
   ============================================================================ */

/* ── 1. Scene = horizontal flex row ─────────────────────────── */
.ps-scene#psScene7 {
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch !important;
    min-width: 100% !important;
    width: 100% !important;
    height: 100% !important;
}

    /* ── 2. LEFT column — heading + body + sticky footer ────────── */
    .ps-scene#psScene7 > .ps-left {
        flex: 1 1 60% !important;
        min-width: 0 !important;
        display: flex !important;
        flex-direction: column !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        padding: 20px 28px 0 !important; /* nav owns the bottom padding */
        gap: 0 !important;
        position: relative !important;
    }

        /* Heading group sits at the top, naturally sized */
        .ps-scene#psScene7 > .ps-left > .ps-progress,
        .ps-scene#psScene7 > .ps-left > .ps-scene-label,
        .ps-scene#psScene7 > .ps-left > .ps-question,
        .ps-scene#psScene7 > .ps-left > .ps-subtitle {
            flex: 0 0 auto !important;
        }

        /* BODY — the launch card. Grows to fill the gap between
       heading and the sticky nav. Uses `safe center` so the card
       anchors to the top when it's taller than the available body
       region (common on ≤700px-tall laptops) instead of bleeding
       upward into the heading or past the sticky footer. The
       .ps-left's `overflow-y:auto` handles the scroll. */
        .ps-scene#psScene7 > .ps-left > #psPackages.ps-packages {
            flex: 1 1 auto !important;
            min-height: 0 !important;
            display: flex !important;
            flex-direction: column !important;
            align-items: center !important;
            justify-content: safe center !important;
            margin: 6px 0 8px !important;
            padding: 4px 0 12px !important;
        }

    /* ── 3. The card itself — body-sized, never overflows column ── */
    .ps-scene#psScene7 .ps-pkg-single.lcr-card {
        width: 100% !important;
        max-width: 440px !important;
        margin: 0 auto !important;
        flex: 0 0 auto !important;
    }

    /* ── 4. FOOTER — Back + Launch sticky at bottom of .ps-left ─── */
    .ps-scene#psScene7 > .ps-left > .ps-nav {
        position: sticky !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        flex: 0 0 auto !important;
        margin-top: auto !important;
        padding: 12px 0 14px !important;
        padding-bottom: max(14px, env(safe-area-inset-bottom)) !important;
        background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, #ffffff 38%, #ffffff 100%) !important;
        border-top: 1px solid rgba(15, 23, 42, 0.05) !important;
        z-index: 30 !important;
        display: flex !important;
        align-items: center !important;
        gap: 12px !important;
    }

        /* Back button — fixed comfortable width */
        .ps-scene#psScene7 > .ps-left > .ps-nav .ps-btn-back {
            flex: 0 0 auto !important;
            min-width: 110px !important;
        }

        /* Launch button — fills remaining width of footer */
        .ps-scene#psScene7 > .ps-left > .ps-nav .ps-btn-launch {
            flex: 1 1 auto !important;
            min-width: 0 !important;
        }

    /* ── 5. RIGHT column — Digital Twin rail ────────────────────── */
    .ps-scene#psScene7 > #psRight7.ps-right {
        flex: 0 0 38% !important;
        min-width: 280px !important;
        max-width: 360px !important;
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        padding: 22px 20px !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        background: linear-gradient(160deg, #FAFBFC 0%, #F3F4F6 100%) !important;
        border-left: 1px solid rgba(0, 0, 0, 0.06) !important;
    }


/* ============================================================================
   RESPONSIVE — narrower laptops
   ============================================================================ */
@media (max-width: 1180px) {
    .ps-scene#psScene7 > #psRight7.ps-right {
        flex-basis: 34% !important;
        min-width: 260px !important;
        max-width: 320px !important;
        padding: 18px 16px !important;
    }

    .ps-scene#psScene7 > .ps-left {
        padding: 18px 22px 0 !important;
    }
}

@media (max-width: 1024px) {
    .ps-scene#psScene7 > #psRight7.ps-right {
        flex-basis: 32% !important;
        min-width: 240px !important;
    }
}


/* ============================================================================
   RESPONSIVE — tablet & mobile (stacked, compacted)
   ============================================================================ */
@media (max-width: 900px) {
    .ps-scene#psScene7 {
        flex-direction: column !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
    }

        /* On mobile the SCENE scrolls, not .ps-left. Both columns flow inline. */
        .ps-scene#psScene7 > .ps-left {
            order: 1 !important;
            flex: 0 0 auto !important;
            width: 100% !important;
            max-width: 100% !important;
            overflow: visible !important;
            padding: 14px 16px 0 !important;
            display: block !important; /* unwind desktop flex column */
        }

            .ps-scene#psScene7 > .ps-left > #psPackages.ps-packages {
                display: block !important; /* unwind desktop flex behaviour */
                margin: 4px 0 10px !important;
                padding: 0 !important;
                min-height: 0 !important;
            }

            /* Nav flows naturally at the end of .ps-left — NOT sticky on
           mobile (the scene scrolls). Sticky+bottom:0 was overlapping
           the card. */
            .ps-scene#psScene7 > .ps-left > .ps-nav {
                position: static !important;
                margin-top: 0 !important;
                padding: 8px 0 12px !important;
                border-top: none !important;
                background: transparent !important;
            }

        /* Right rail (Digital Twin) sits BELOW .ps-left on mobile. */
        .ps-scene#psScene7 > #psRight7.ps-right {
            order: 2 !important;
            flex: 0 0 auto !important;
            width: 100% !important;
            max-width: 100% !important;
            min-width: 0 !important;
            padding: 12px 16px 18px !important;
            border-left: none !important;
            border-top: 1px solid rgba(0, 0, 0, 0.06) !important;
            background: linear-gradient(180deg, #FAFBFC 0%, #F3F4F6 100%) !important;
            overflow: visible !important;
        }
}

@media (max-width: 600px) {
    .ps-scene#psScene7 > .ps-left {
        padding: 14px 14px 0 !important;
    }

    .ps-scene#psScene7 .ps-pkg-single.lcr-card {
        max-width: 100% !important;
    }

    .ps-scene#psScene7 > .ps-left > .ps-nav {
        padding: 10px 0 12px !important;
        padding-bottom: max(12px, env(safe-area-inset-bottom)) !important;
        gap: 8px !important;
    }

        .ps-scene#psScene7 > .ps-left > .ps-nav .ps-btn-back {
            min-width: 0 !important;
            flex: 0 0 96px !important;
            padding: 10px 12px !important;
        }
}


/* ============================================================================
   LAUNCH CARD — receipt design (unchanged from v1)
   ============================================================================ */

/* ─── KILL legacy chrome ──────────────────────────────────────────────── */
.ps-pkg-single.lcr-card .ps-pkg-single-ribbon,
.ps-pkg-single.lcr-card .ps-pkg-single-head,
.ps-pkg-single.lcr-card .ps-pkg-single-price-row,
.ps-pkg-single.lcr-card .ps-pkg-single-features,
.ps-pkg-single.lcr-card > *:not(.lcr-card-inner) {
    display: none !important;
}

/* ─── CARD SHELL ──────────────────────────────────────────────────────── */
.ps-pkg-single.lcr-card {
    position: relative;
    border-radius: 22px !important;
    padding: 0 !important;
    border: 1px solid rgba(15, 23, 42, 0.06) !important;
    background: linear-gradient(180deg, #FFFFFF 0%, #FBFAF7 100%) !important;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.9) inset, 0 22px 50px -28px rgba(15, 23, 42, 0.28), 0 10px 22px -18px rgba(245, 130, 32, 0.18) !important;
    overflow: hidden !important;
    isolation: isolate;
}

    .ps-pkg-single.lcr-card::before,
    .ps-pkg-single.lcr-card::after {
        display: none !important;
    }

.lcr-card-inner {
    position: relative;
    padding: 16px 18px 14px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 1;
}

/* Soft brand glow in the top-right corner */
.lcr-glow {
    position: absolute;
    top: -60px;
    right: -60px;
    width: 220px;
    height: 220px;
    background: radial-gradient(closest-side, rgba(245, 130, 32, 0.18) 0%, rgba(245, 130, 32, 0) 70%);
    pointer-events: none;
    z-index: 0;
}

/* ─── HEAD ────────────────────────────────────────────────────────────── */
.lcr-head {
    display: flex;
    align-items: center;
    gap: 14px;
    position: relative;
    z-index: 1;
}

.lcr-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--sj-orange, #F58220) 0%, var(--sj-orange-dark, #D8691A) 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    box-shadow: 0 8px 20px rgba(245, 130, 32, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.4) inset;
    flex-shrink: 0;
}

.lcr-head-text {
    flex: 1;
    min-width: 0;
}

.lcr-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.66rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--sj-success, #16A34A);
    background: rgba(22, 163, 74, 0.08);
    border-radius: 999px;
    padding: 3px 9px 3px 7px;
    margin-bottom: 6px;
}

.lcr-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--sj-success, #16A34A);
    box-shadow: 0 0 0 4px rgba(22, 163, 74, 0.18);
    animation: lcrPulse 2s ease-in-out infinite;
}

@keyframes lcrPulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.35);
    }

    50% {
        box-shadow: 0 0 0 6px rgba(22, 163, 74, 0);
    }
}

.lcr-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--sj-dark, #0F172A);
    line-height: 1.15;
    letter-spacing: -0.01em;
}

/* ─── SAVINGS STORY (the hero block) ──────────────────────────────────── */
.lcr-savings {
    position: relative;
    z-index: 1;
    background: linear-gradient(180deg, rgba(255, 247, 237, 0.6) 0%, rgba(255, 247, 237, 0.2) 100%);
    border: 1px solid rgba(245, 130, 32, 0.18);
    border-radius: 14px;
    padding: 10px 14px 12px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

/* Strike-through "typical commission" line */
.lcr-savings-strike {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.78rem;
    color: var(--sj-muted, #64748B);
    font-weight: 500;
}

.lcr-strike-label {
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 0.65rem;
    font-weight: 700;
}

.lcr-strike-amt {
    font-size: 1.05rem;
    font-weight: 700;
    color: rgba(15, 23, 42, 0.5);
    text-decoration: line-through;
    text-decoration-color: rgba(220, 38, 38, 0.55);
    text-decoration-thickness: 1.5px;
    font-variant-numeric: tabular-nums;
}

    .lcr-strike-amt sup {
        font-size: 0.6em;
        font-weight: 800;
        color: rgba(220, 38, 38, 0.7);
        text-decoration: none;
        margin-left: 1px;
    }

/* Arrow divider */
.lcr-savings-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(245, 130, 32, 0.55);
    font-size: 0.95rem;
    margin: -2px 0;
    line-height: 1;
}

/* The actual hero price */
.lcr-price-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.lcr-price-line {
    display: inline-flex;
    align-items: baseline;
    color: var(--sj-dark, #0F172A);
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.lcr-currency {
    font-size: 1.35rem;
    font-weight: 700;
    margin-right: 2px;
    transform: translateY(-0.45em);
    color: var(--sj-orange, #F58220);
}

.lcr-amount {
    font-size: 2.6rem;
    font-weight: 900;
    letter-spacing: -0.04em;
    background: linear-gradient(180deg, #1F2937 0%, #0F172A 70%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.lcr-price-meta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--sj-muted, #64748B);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.lcr-meta-dot {
    opacity: 0.5;
}

/* "Keep R44,801 in your pocket" — the win statement */
.lcr-savings-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    align-self: center;
    padding: 7px 14px;
    margin-top: 2px;
    background: linear-gradient(135deg, var(--sj-success, #16A34A) 0%, #0E8540 100%);
    color: #fff;
    border-radius: 999px;
    font-size: 0.74rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    box-shadow: 0 6px 16px rgba(22, 163, 74, 0.32), 0 0 0 1px rgba(255, 255, 255, 0.25) inset;
}

    .lcr-savings-tag strong {
        font-weight: 800;
        font-variant-numeric: tabular-nums;
    }

    .lcr-savings-tag i {
        font-size: 0.88rem;
    }

/* ─── PROMISE line ────────────────────────────────────────────────────── */
.lcr-promise {
    margin: 0;
    text-align: center;
    font-size: 0.84rem;
    line-height: 1.4;
    color: var(--sj-dark, #0F172A);
    font-weight: 500;
    text-wrap: pretty;
    padding: 0 4px;
}

    .lcr-promise strong {
        font-weight: 700;
        color: var(--sj-orange-dark, #C45A14);
    }

/* ─── TRUST STRIP ─────────────────────────────────────────────────────── */
.lcr-trust {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    padding-top: 10px;
    border-top: 1px dashed rgba(15, 23, 42, 0.1);
}

.lcr-trust-pill {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 4px 2px;
    font-size: 0.68rem;
    font-weight: 600;
    color: var(--sj-muted, #64748B);
    text-align: center;
    line-height: 1.2;
}

    .lcr-trust-pill i {
        font-size: 1rem;
        color: var(--sj-orange, #F58220);
        opacity: 0.85;
    }

/* ============================================================================
   CARD — compacted variants for narrow / short viewports
   ============================================================================ */
@media (max-width: 900px) {
    .lcr-card-inner {
        padding: 18px 18px 16px;
        gap: 14px;
    }

    .lcr-savings {
        padding: 12px 14px 14px;
        gap: 6px;
    }

    .lcr-amount {
        font-size: 3rem;
    }
}

@media (max-width: 600px) {
    .lcr-card-inner {
        padding: 16px 14px 14px;
        gap: 12px;
    }

    .lcr-icon {
        width: 40px;
        height: 40px;
        border-radius: 12px;
        font-size: 1.1rem;
    }

    .lcr-title {
        font-size: 1.02rem;
    }

    .lcr-savings {
        padding: 11px 13px 12px;
        gap: 5px;
    }

    .lcr-strike-label {
        font-size: 0.58rem;
    }

    .lcr-strike-amt {
        font-size: 0.9rem;
    }

    .lcr-amount {
        font-size: 2.7rem;
    }

    .lcr-currency {
        font-size: 1.3rem;
    }

    .lcr-price-meta {
        font-size: 0.64rem;
    }

    .lcr-savings-tag {
        font-size: 0.68rem;
        padding: 6px 12px;
    }

    .lcr-promise {
        font-size: 0.82rem;
        padding: 0;
    }

    .lcr-trust {
        padding-top: 12px;
        gap: 4px;
    }

    .lcr-trust-pill {
        font-size: 0.6rem;
    }

        .lcr-trust-pill i {
            font-size: 0.88rem;
        }
}

@media (max-width: 360px) {
    .lcr-amount {
        font-size: 2.4rem;
    }

    .lcr-trust {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .lcr-trust-pill {
        flex-direction: row;
        justify-content: center;
        gap: 8px;
    }
}
