/* ==========================================================================
   MIVB — Public Share Page
   Mobile: viewport-locked (no scroll) — watch-first.
   Desktop (≥ 1100px): scrollable 3-column sales layout.
   ========================================================================== */

/* ── Reset: override theme margins / WP admin bar ───────────────────────── */
html:has(body.mivb-share-page) {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Scrollable on all viewports — clear fixed footer */
body.mivb-share-page {
    background: #f5f3f7;
    margin: 0;
    padding: 0 0 72px; /* space for fixed footer */
    min-height: 100vh;
    overflow-y: auto;
    overflow-x: hidden;
}

/* Hide theme chrome — allow main wrapper and fixed footer through */
body.mivb-share-page > *:not(.mivb-share-page-wrap):not(.mivb-sp-footer) {
    display: none !important;
}

.mivb-share-page-wrap {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 72px);
}

/* ── Header ──────────────────────────────────────────────────────────────── */
.mivb-sp-header {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 56px;
    background: #fff;
    border-bottom: 1px solid #efe9f4;
    flex-shrink: 0;
}

.mivb-sp-logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.mivb-sp-logo-link img {
    height: 28px !important;
    width: auto !important;
    display: block;
}

/* ── Banner ──────────────────────────────────────────────────────────────── */
.mivb-sp-banner {
    width: 100%;
    flex-shrink: 0;
}

.mivb-sp-banner-inner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    flex-wrap: wrap;
}

/* Mobile review banner — dark crimson */
.mivb-sp-banner--review {
    background: linear-gradient(135deg, #7b1041 0%, #9c1249 100%);
    color: #fff;
}

.mivb-sp-banner--review .mivb-sp-banner-inner {
    justify-content: space-between;
}

.mivb-sp-banner--review .mivb-sp-banner-heart {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    flex-shrink: 0;
    color: #fff;
}

.mivb-sp-banner--review .mivb-sp-banner-text {
    flex: 1;
    font-size: 13px;
    line-height: 1.45;
    color: #fff;
    min-width: 0;
}

.mivb-sp-banner-btn {
    display: inline-flex;
    align-items: center;
    padding: 9px 18px;
    background: #fef9ec;
    color: #7b1041;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    transition: background 0.15s;
    letter-spacing: 0.01em;
}

.mivb-sp-banner-btn:hover {
    background: #fff;
    text-decoration: none;
    color: #7b1041;
}

/* Package banner — light pink */
.mivb-sp-banner--package {
    background: #fef0f5;
    color: #7b1041;
}

.mivb-sp-banner--package .mivb-sp-banner-heart {
    display: inline-flex;
    align-items: center;
    color: #e11d48;
    flex-shrink: 0;
}

.mivb-sp-banner--package .mivb-sp-banner-text {
    font-size: 13px;
    line-height: 1.5;
    color: #7b1041;
}

/* Hide entire banner on desktop — order card handles the CTA */
@media (min-width: 1100px) {
    .mivb-sp-banner {
        display: none;
    }
}

/* ── Trust bar (mobile, review only) ─────────────────────────────────────── */
.mivb-sp-trust {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 12px 16px;
    background: #fff;
    border-bottom: 1px solid #efe9f4;
}

.mivb-sp-trust-item {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    font-weight: 500;
    color: #5a3a5a;
    flex: 1;
    justify-content: center;
    text-align: center;
    line-height: 1.3;
}

.mivb-sp-trust-item svg {
    flex-shrink: 0;
    color: #9c6b1e;
}

.mivb-sp-trust-sep {
    width: 1px;
    height: 28px;
    background: #e5d9ee;
    flex-shrink: 0;
}

/* Hide trust bar on desktop — replaced by left column features */
@media (min-width: 1100px) {
    .mivb-sp-trust {
        display: none;
    }
}

/* ── Ornamental divider (mobile, review only) ────────────────────────────── */
.mivb-sp-divider {
    display: flex;
    align-items: center;
    padding: 12px 32px;
    background: #fff;
    gap: 8px;
}

.mivb-sp-divider-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, #d4b8c7, transparent);
}

.mivb-sp-divider-gem {
    flex-shrink: 0;
    display: block;
}

/* Hide divider on desktop */
@media (min-width: 1100px) {
    .mivb-sp-divider {
        display: none;
    }
}

/* ── Main layout ─────────────────────────────────────────────────────────── */
.mivb-sp-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 16px 24px;
}

@media (min-width: 768px) and (max-width: 1099px) {
    .mivb-sp-main {
        padding: 32px 24px 40px;
    }
    .mivb-sp-canvas-col {
        max-width: 440px;
    }
}

@media (min-width: 1100px) {
    .mivb-sp-main--review {
        display: grid;
        grid-template-columns: 1fr minmax(0, 420px) 1fr;
        align-items: start;
        gap: 48px;
        padding: 40px 40px 48px;
        max-width: 1280px;
        width: 100%;
        margin: 0 auto;
        align-self: center;
        box-sizing: border-box;
    }
}

/* ── Left column ─────────────────────────────────────────────────────────── */
.mivb-sp-left {
    display: none;
}

@media (min-width: 1100px) {
    .mivb-sp-left {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        padding-top: 40px;
    }
}

.mivb-sp-left-hearts {
    display: flex;
    align-items: flex-end;
    margin-bottom: 10px;
    line-height: 1;
}

.mivb-sp-perfect-heading {
    font-size: 28px;
    font-weight: 800;
    color: #1a1a2e;
    line-height: 1.25;
    margin: 0 0 12px;
}

.mivb-sp-make-official {
    color: #e11d48;
}

.mivb-sp-sparkle {
    font-size: 22px;
    vertical-align: middle;
}

.mivb-sp-left-desc {
    font-size: 14px;
    color: #6b5878;
    line-height: 1.6;
    margin: 0 0 24px;
    max-width: 260px;
}

.mivb-sp-features {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.mivb-sp-feature {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mivb-sp-feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.mivb-sp-feature-icon--pink   { background: #fce7f3; color: #be185d; }
.mivb-sp-feature-icon--green  { background: #dcfce7; color: #15803d; }
.mivb-sp-feature-icon--purple { background: #ede9fe; color: #7c3aed; }

.mivb-sp-feature > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.mivb-sp-feature strong {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a2e;
    line-height: 1.2;
}

.mivb-sp-feature span {
    font-size: 12px;
    color: #6b5878;
}

/* ── Canvas column ───────────────────────────────────────────────────────── */
.mivb-sp-canvas-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 380px; /* portrait card width */
    box-sizing: border-box;
}

@media (min-width: 1100px) {
    .mivb-sp-canvas-col {
        max-width: none;
        width: 100%;
    }
}

/* Video card — no background, no shadow, design breathes */
.mivb-sp-video-card {
    width: 100%;
    background: transparent;
    line-height: 0;
}

/* Container inside card */
.mivb-sp-video-card .mivb-video-preview-container {
    width: 100%;
    position: relative;
}

/* QuickCraft canvas fills the card width */
.mivb-sp-video-card .mivb-preview-canvas {
    width: 100% !important;
    display: block;
}

/* Loading placeholder — neutral background while video loads */
.mivb-sp-video-card .mivb-preview-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 480px;
    background: #f0e8f4; /* soft neutral, not dark */
    border-radius: 20px;
}

/* ── Watermark ───────────────────────────────────────────────────────────── */
.mivb-share-watermark {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 20;
    pointer-events: none;
}

.mivb-share-watermark-badge {
    display: inline-block;
    background: rgba(0, 0, 0, 0.52);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: 4px;
    font-family: inherit;
}

/* ── Caption ─────────────────────────────────────────────────────────────── */
.mivb-sp-caption {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #6b5878;
    text-align: center;
    line-height: 1.5;
    padding: 14px 8px 4px;
    margin: 0;
    flex-wrap: wrap;
    justify-content: center;
}

.mivb-sp-expiry-notice {
    color: #92400e;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 8px;
    padding: 8px 14px;
    margin-top: 10px;
    font-size: 12px;
    gap: 5px;
}

@media (min-width: 1100px) {
    .mivb-sp-caption {
        font-size: 14px;
        padding: 16px 0 6px;
    }
}

/* ── Fixed footer (Play / Pause / Replay) ────────────────────────────────── */
.mivb-sp-footer {
    position: fixed !important;
    bottom: 0;
    left: 0;
    right: 0;
    height: 72px;
    background: #fff;
    border-top: 1px solid #ede9f4;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Reset builder's .mivb-preview-bottom so it flows in the footer */
.mivb-sp-footer .mivb-preview-bottom {
    position: static !important;
    height: auto !important;
    background: transparent !important;
    border: none !important;
    width: 100%;
    display: flex !important;
    align-items: center;
    justify-content: center;
}

.mivb-sp-footer .mivb-bottom-row {
    justify-content: center !important;
}

.mivb-sp-footer .mivb-preview-controls {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Play/Pause: large pink circle.
   NO display !important here — JS toggles display:none inline, !important would break it. */
.mivb-sp-footer .mivb-sp-play-btn.mivb-control-btn {
    width: 56px !important;
    height: 56px !important;
    border-radius: 50% !important;
    background: #FF7396 !important;
    border: none !important;
    color: #fff !important;
    font-size: 18px !important;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 18px rgba(233, 30, 122, 0.35);
    transition: transform 0.15s, box-shadow 0.15s;
    padding: 0 !important;
    margin: 0 !important;
    /* display is left to the browser default + JS control */
}

.mivb-sp-footer .mivb-sp-play-btn.mivb-control-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 24px rgba(233, 30, 122, 0.45);
}

/* Replay: smaller gray circle */
.mivb-sp-footer .mivb-sp-restart-btn.mivb-control-btn {
    width: 44px !important;
    height: 44px !important;
    border-radius: 50% !important;
    background: #f0eaf5 !important;
    border: none !important;
    color: #6b5878 !important;
    font-size: 15px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer;
    transition: background 0.15s;
    padding: 0 !important;
    margin: 0 !important;
}

.mivb-sp-footer .mivb-sp-restart-btn.mivb-control-btn:hover {
    background: #e4d9f0 !important;
}

/* ── Right column: order card ────────────────────────────────────────────── */
.mivb-sp-right {
    display: none;
}

@media (min-width: 1100px) {
    .mivb-sp-right {
        display: block;
        padding-top: 40px;
    }
}

.mivb-sp-order-card {
    background: #fff;
    border-radius: 20px;
    border: 1.5px solid #efe4f5;
    padding: 24px 22px;
    box-shadow: 0 4px 24px rgba(100, 20, 60, 0.08);
}

.mivb-sp-order-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 20px;
}

.mivb-sp-crown-wrap {
    width: 46px;
    height: 46px;
    background: #fef9ec;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.mivb-sp-order-title {
    font-size: 17px;
    font-weight: 800;
    color: #1a1a2e;
    line-height: 1.2;
}

.mivb-sp-order-subtitle {
    font-size: 13px;
    color: #888;
    margin-top: 3px;
    line-height: 1.3;
}

.mivb-sp-checklist {
    list-style: none;
    margin: 0 0 22px;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mivb-sp-checklist li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: #3a2a3a;
    line-height: 1.4;
}

.mivb-sp-checklist li::before {
    content: '';
    display: inline-block;
    width: 18px;
    height: 18px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%2316a34a' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E") no-repeat center/contain;
    flex-shrink: 0;
}

.mivb-sp-order-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, #c41063, #e91e7a);
    color: #fff;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    transition: opacity 0.15s, transform 0.1s;
    box-shadow: 0 4px 18px rgba(233, 30, 122, 0.3);
    margin-bottom: 14px;
    line-height: 1;
}

.mivb-sp-order-btn:hover {
    opacity: 0.92;
    transform: translateY(-1px);
    text-decoration: none;
    color: #fff;
}

.mivb-sp-order-safe {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f0fdf4;
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 12px;
    color: #166534;
    line-height: 1.45;
}

.mivb-sp-order-safe svg {
    flex-shrink: 0;
}

/* ── Toast (Share Video copy feedback) ───────────────────────────────────── */
.mivb-share-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    background: #1e1e1e;
    color: #fff;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-size: 0.9rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    z-index: 99999;
    white-space: nowrap;
    pointer-events: none;
    border: 1px solid #333;
}

.mivb-share-toast--error {
    border-color: #ef4444;
    color: #ef4444;
}

/* ── Share button in builder header (enqueued on builder pages) ───────────── */
.mivb-header-share {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    background: transparent;
    color: #FF7396;
    border: 1.5px solid #FF7396;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
    white-space: nowrap;
    font-family: inherit;
    flex-shrink: 0;
}

.mivb-header-share:hover  { background: #FF7396; color: #fff; }
.mivb-header-share:active { transform: scale(0.96); }
.mivb-header-share:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }

/* ── Error pages (404 / expired) ─────────────────────────────────────────── */
body.mivb-share-page .mivb-share-error-center {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 2rem;
    flex: 1;
}

.mivb-share-error-inner {
    max-width: 380px;
}

.mivb-share-error-icon {
    font-size: 3rem;
    color: #7c3aed;
    margin-bottom: 1.25rem;
}

.mivb-share-error h1 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 0.6rem;
    line-height: 1.4;
}

.mivb-share-error p {
    font-size: 0.9rem;
    color: #888;
    margin: 0;
    line-height: 1.5;
}
