/* ============================================================
   VR TOUR — ENHANCED STYLES  v3
   Ikhayalami Private Seller Journey
   Namespace: .vrt-  (no collisions with .s5- or .sj-)

   New in v3:
   ─ Confidence warning banner
   ─ Method badge (phase correlation / OpenCV)
   ─ Manual seam adjustment UI
   ─ 5-stage stitch pipeline indicator
   ─ Improved viewer rail + room cards
   ============================================================ */

/* ─── PANEL ─────────────────────────────────────────────── */
.vrt-panel {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.vrt-intel-tip {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 11px 13px;
    background: rgba(86, 196, 248, 0.07);
    border: 1.5px solid rgba(86, 196, 248, 0.22);
    border-radius: 10px;
    font-size: 0.67rem;
    color: #374151;
    line-height: 1.5;
    flex-shrink: 0;
}

    .vrt-intel-tip > i {
        color: #56C4F8;
        font-size: 1rem;
        flex-shrink: 0;
        margin-top: 1px;
    }

/* ─── ROOMS GRID ─────────────────────────────────────────── */
.vrt-rooms-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.vrt-empty {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 28px 16px;
    text-align: center;
    color: rgba(107, 114, 128, 0.7);
    font-size: 0.7rem;
}

    .vrt-empty i {
        font-size: 2rem;
        color: rgba(107, 114, 128, 0.35);
    }

.vrt-room-card {
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
    border: 1.5px solid rgba(0, 0, 0, 0.07);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

    .vrt-room-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
        border-color: rgba(245, 130, 32, 0.35);
    }

.vrt-room-thumb {
    height: 80px;
    background: #1e2025 center / cover no-repeat;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vrt-room-thumb-emoji {
    font-size: 1.8rem;
    opacity: 0.7;
}

.vrt-room-thumb-badge {
    position: absolute;
    top: 6px;
    left: 6px;
    background: rgba(0, 0, 0, 0.52);
    backdrop-filter: blur(4px);
    color: #fff;
    font-size: 0.55rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 4px;
}

    .vrt-room-thumb-badge i {
        color: #F58220;
    }

.vrt-room-thumb-play {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0);
    transition: background 0.18s;
}

.vrt-room-card:hover .vrt-room-thumb-play {
    background: rgba(0, 0, 0, 0.3);
}

.vrt-room-thumb-play-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    color: #1a1d20;
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.18s, transform 0.18s;
}

.vrt-room-card:hover .vrt-room-thumb-play-btn {
    opacity: 1;
    transform: scale(1);
}

.vrt-room-delete {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: none;
    background: rgba(0, 0, 0, 0.45);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.72rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.15s, background 0.15s;
}

.vrt-room-card:hover .vrt-room-delete {
    opacity: 1;
}

.vrt-room-delete:hover {
    background: rgba(239, 68, 68, 0.75);
    color: #fff;
}

.vrt-room-meta {
    padding: 7px 9px 8px;
}

.vrt-room-name {
    font-size: 0.72rem;
    font-weight: 800;
    color: #1a1d20;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.vrt-room-sub {
    font-size: 0.59rem;
    color: #9ca3af;
    margin-top: 2px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.vrt-dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: currentColor;
    display: inline-block;
}

/* ─── ADD BUTTON ─────────────────────────────────────────── */
.vrt-add-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 11px;
    border-radius: 12px;
    border: 2px dashed rgba(245, 130, 32, 0.35);
    background: rgba(245, 130, 32, 0.04);
    color: #F58220;
    font-size: 0.74rem;
    font-weight: 800;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
    flex-shrink: 0;
}

    .vrt-add-btn:hover {
        border-style: solid;
        background: rgba(245, 130, 32, 0.08);
        box-shadow: 0 4px 14px rgba(245, 130, 32, 0.18);
    }

/* ─── WIZARD MODAL ───────────────────────────────────────── */
.vrt-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.72);
    display: none; /* hidden by default — toggled by .open */
    align-items: center;
    justify-content: center;
    padding: 12px;
    backdrop-filter: blur(8px);
    -webkit-tap-highlight-color: transparent;
}

    .vrt-modal.open {
        display: flex; /* show when .open is added by JS */
    }

.vrt-modal-inner {
    background: #fff;
    border-radius: 20px;
    width: 640px;
    max-width: 95vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.35);
    overflow: hidden;
    transform: scale(0.92) translateY(20px);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.vrt-modal.open .vrt-modal-inner {
    transform: scale(1) translateY(0);
}

.vrt-modal-header {
    padding: 16px 20px 12px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    flex-shrink: 0;
}

.vrt-step-row {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 10px;
}

.vrt-step-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.1);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

    .vrt-step-dot.active {
        background: #F58220;
        width: 20px;
        border-radius: 4px;
    }

    .vrt-step-dot.done {
        background: #34d399;
    }

.vrt-step-label {
    font-size: 0.6rem;
    font-weight: 800;
    color: #9ca3af;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-left: auto;
}

.vrt-close-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1.5px solid rgba(0, 0, 0, 0.1);
    background: #f5f6f7;
    color: #374151;
    font-size: 0.95rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
    flex-shrink: 0;
}

    .vrt-close-btn:hover {
        background: #1a1d20;
        color: #fff;
    }

.vrt-modal-title {
    font-size: 1rem;
    font-weight: 900;
    color: #1a1d20;
    letter-spacing: -0.02em;
}

.vrt-modal-sub {
    font-size: 0.67rem;
    color: #9ca3af;
    margin-top: 3px;
}

.vrt-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 18px 20px;
    scrollbar-width: thin;
    scrollbar-color: #F58220 transparent;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.vrt-step {
    display: none;
    flex-direction: column;
    gap: 14px;
}

    .vrt-step.active {
        display: flex;
    }

/* ─── MODAL BODY COMPONENTS ──────────────────────────────── */
.vrt-section-label {
    font-size: 0.6rem;
    font-weight: 800;
    color: #9ca3af;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 7px;
}

.vrt-context-pill {
    background: rgba(245, 130, 32, 0.09);
    color: #F58220;
    border-radius: 50px;
    padding: 2px 8px;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.vrt-room-chip-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 7px;
}

.vrt-room-chip {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 9px 5px;
    border-radius: 10px;
    border: 1.5px solid rgba(0, 0, 0, 0.08);
    background: #fafbfc;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.18s;
}

    .vrt-room-chip:hover {
        border-color: #F58220;
    }

    .vrt-room-chip.active {
        background: rgba(245, 130, 32, 0.07);
        border-color: #F58220;
    }

.vrt-room-chip-emoji {
    font-size: 1.3rem;
    line-height: 1;
}

.vrt-room-chip-label {
    font-size: 0.58rem;
    font-weight: 700;
    color: #9ca3af;
    text-align: center;
}

.vrt-room-chip.active .vrt-room-chip-label {
    color: #F58220;
}

.vrt-input-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border: 1.5px solid rgba(0, 0, 0, 0.09);
    border-radius: 10px;
    background: #fafbfc;
    transition: border-color 0.18s;
}

    .vrt-input-wrap:focus-within {
        border-color: #F58220;
    }

    .vrt-input-wrap > i {
        color: #9ca3af;
        font-size: 0.85rem;
    }

.vrt-input {
    flex: 1;
    border: none;
    background: transparent;
    font-size: 0.78rem;
    font-weight: 600;
    color: #1a1d20;
    outline: none;
    font-family: inherit;
}

    .vrt-input::placeholder {
        color: #d1d5db;
    }

/* Shot guide */
.vrt-shot-guide {
    background: #fafbfc;
    border: 1.5px solid rgba(0, 0, 0, 0.06);
    border-radius: 12px;
    padding: 14px;
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.vrt-shot-diagram {
    width: 90px;
    height: 90px;
    flex-shrink: 0;
}

.vrt-check-mark {
    display: none;
}

.vrt-corner-circle.done .vrt-check-mark {
    display: block;
}

.vrt-corner-circle.done text {
    display: none;
}

.vrt-corner-circle.done circle {
    fill: #34d399;
}

.vrt-shot-tips {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.vrt-shot-tip {
    display: flex;
    align-items: flex-start;
    gap: 7px;
    font-size: 0.65rem;
    color: #6b7280;
    line-height: 1.45;
}

.vrt-shot-tip-num {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #F58220;
    color: #fff;
    font-size: 0.55rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 1px;
}

.vrt-shot-tip strong {
    color: #1a1d20;
}

/* Shot upload grid */
.vrt-shots-grid {
    display: grid;
    gap: 8px;
}

    .vrt-shots-grid.cols-2 {
        grid-template-columns: repeat(2, 1fr);
    }

    .vrt-shots-grid.cols-1 {
        grid-template-columns: 1fr;
    }

.vrt-shot-slot {
    aspect-ratio: 1.2;
    border-radius: 10px;
    border: 2px dashed rgba(0, 0, 0, 0.1);
    background: #fafbfc;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    transition: all 0.18s;
    position: relative;
    overflow: hidden;
}

    .vrt-shot-slot input[type="file"] {
        position: absolute;
        inset: 0;
        opacity: 0;
        cursor: pointer;
    }

    .vrt-shot-slot:hover {
        border-color: #F58220;
        background: rgba(245, 130, 32, 0.04);
    }

    .vrt-shot-slot.filled {
        border-style: solid;
        border-color: #34d399;
    }

    .vrt-shot-slot.error {
        border-color: #ef4444;
        background: rgba(239, 68, 68, 0.04);
    }

.vrt-shot-slot-icon {
    font-size: 1.1rem;
    color: #d1d5db;
}

.vrt-shot-slot.filled .vrt-shot-slot-icon {
    display: none;
}

.vrt-shot-slot.error .vrt-shot-slot-icon {
    color: #ef4444;
}

.vrt-shot-slot-label {
    font-size: 0.58rem;
    font-weight: 700;
    color: #9ca3af;
    text-align: center;
    pointer-events: none;
}

.vrt-shot-slot.filled .vrt-shot-slot-label {
    display: none;
}

.vrt-shot-slot-corner-num {
    position: absolute;
    top: 5px;
    left: 5px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #F58220;
    color: #fff;
    font-size: 0.6rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    pointer-events: none;
}

.vrt-slot-preview {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: inherit;
}

.vrt-error-msg {
    display: none;
    align-items: center;
    gap: 6px;
    padding: 7px 11px;
    background: rgba(239, 68, 68, 0.07);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 8px;
    font-size: 0.65rem;
    color: #ef4444;
    font-weight: 600;
}

    .vrt-error-msg.show {
        display: flex;
    }

    .vrt-error-msg i {
        font-size: 0.78rem;
        flex-shrink: 0;
    }

/* ─── PREVIEW WRAP ───────────────────────────────────────── */
.vrt-preview-wrap {
    border-radius: 14px;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: #0d0e11;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: grab;
    box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.4);
}

    .vrt-preview-wrap:active {
        cursor: grabbing;
    }

.vrt-preview-hint {
    position: absolute;
    bottom: 44px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(6px);
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.62rem;
    font-weight: 600;
    padding: 5px 14px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 5px;
    pointer-events: none;
    z-index: 4;
    animation: vrtHintFade 1s ease 3s forwards;
}

@keyframes vrtHintFade {
    to {
        opacity: 0;
    }
}

.vrt-preview-label {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.10);
    backdrop-filter: blur(8px);
    color: #fff;
    font-size: 0.63rem;
    font-weight: 700;
    padding: 5px 14px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 6px;
    pointer-events: none;
    z-index: 3;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

    .vrt-preview-label i {
        color: #F58220;
    }

.vrt-preview-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, transparent 55%, rgba(0,0,0,0.38) 100%);
    pointer-events: none;
    z-index: 2;
}

/* ─── STITCHING OVERLAY ──────────────────────────────────── */
.vrt-stitching {
    position: absolute;
    inset: 0;
    background: rgba(13, 14, 17, 0.93);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    z-index: 10;
    backdrop-filter: blur(4px);
    border-radius: inherit;
}

    .vrt-stitching.hidden {
        display: none;
    }

.vrt-stitch-ring {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 3px solid rgba(245, 130, 32, 0.18);
    border-top-color: #F58220;
    animation: vrtSpin 0.85s linear infinite;
    flex-shrink: 0;
}

@keyframes vrtSpin {
    to {
        transform: rotate(360deg);
    }
}

.vrt-stitch-label {
    font-size: 0.72rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.82);
    text-align: center;
    min-height: 1.1em;
    transition: all 0.25s;
}

/* 5-stage pipeline indicator */
.vrt-stitch-stages {
    display: flex;
    align-items: center;
    gap: 0;
    flex-wrap: wrap;
    justify-content: center;
    margin: 2px 0 4px;
    max-width: 320px;
}

.vrt-stitch-stage {
    font-size: 0.57rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.2);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 4px 9px;
    border-radius: 50px;
    position: relative;
    transition: color 0.3s, background 0.3s;
    white-space: nowrap;
}

    .vrt-stitch-stage + .vrt-stitch-stage::before {
        content: '›';
        position: absolute;
        left: -1px;
        top: 50%;
        transform: translateY(-50%);
        color: rgba(255, 255, 255, 0.13);
        font-size: 0.72rem;
    }

    .vrt-stitch-stage.active {
        color: #F58220;
        background: rgba(245, 130, 32, 0.12);
    }

        .vrt-stitch-stage.active::after {
            content: '';
            display: inline-block;
            width: 5px;
            height: 5px;
            border-radius: 50%;
            background: #F58220;
            margin-left: 5px;
            vertical-align: middle;
            animation: vrtPulse 1s ease-in-out infinite alternate;
        }

@keyframes vrtPulse {
    from {
        opacity: 0.5;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1.2);
    }
}

.vrt-stitch-stage.done {
    color: rgba(52, 211, 153, 0.85);
}

    .vrt-stitch-stage.done::after {
        content: ' ✓';
        font-size: 0.6rem;
    }

/* Progress bar */
.vrt-stitch-progress {
    width: 200px;
    height: 3px;
    background: rgba(255, 255, 255, 0.10);
    border-radius: 50px;
    overflow: hidden;
    flex-shrink: 0;
}

.vrt-stitch-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #F58220, #ffb060);
    border-radius: 50px;
    width: 0%;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 0 8px rgba(245, 130, 32, 0.5);
}

/* ─── CONFIDENCE WARNING ─────────────────────────────────── */
.vrt-confidence-warn {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 11px 13px;
    background: rgba(251, 191, 36, 0.09);
    border: 1.5px solid rgba(251, 191, 36, 0.35);
    border-radius: 10px;
    font-size: 0.67rem;
    color: #374151;
    line-height: 1.5;
    animation: vrtSlideIn 0.3s var(--sj-ease-out, ease) both;
}

@keyframes vrtSlideIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.vrt-confidence-warn.hidden {
    display: none;
}

.vrt-confidence-warn > i {
    color: #f59e0b;
    font-size: 1rem;
    flex-shrink: 0;
    margin-top: 1px;
}

.vrt-confidence-warn > div {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.vrt-confidence-warn strong {
    color: #1a1d20;
}

.vrt-seam-adjust-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    border-radius: 50px;
    border: 1.5px solid rgba(245, 130, 32, 0.4);
    background: rgba(245, 130, 32, 0.07);
    color: #F58220;
    font-size: 0.65rem;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.18s;
    width: fit-content;
}

    .vrt-seam-adjust-btn:hover {
        background: rgba(245, 130, 32, 0.14);
        border-color: #F58220;
    }

/* ─── METHOD BADGE ───────────────────────────────────────── */
.vrt-method-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: 50px;
    background: rgba(52, 211, 153, 0.08);
    border: 1px solid rgba(52, 211, 153, 0.25);
    color: #059669;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    align-self: flex-start;
}

    .vrt-method-badge.hidden {
        display: none;
    }

    .vrt-method-badge i {
        font-size: 0.7rem;
    }

/* ─── MANUAL SEAM ADJUSTMENT UI ─────────────────────────── */
.vrt-seam-adjust {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 14px;
    background: #fafbfc;
    border: 1.5px solid rgba(0, 0, 0, 0.07);
    border-radius: 12px;
    animation: vrtSlideIn 0.3s ease both;
}

.vrt-seam-header {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.67rem;
    color: #374151;
    line-height: 1.5;
}

    .vrt-seam-header i {
        color: #F58220;
        font-size: 0.9rem;
        margin-top: 1px;
        flex-shrink: 0;
    }

    .vrt-seam-header strong {
        color: #1a1d20;
    }

.vrt-seam-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.vrt-seam-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.vrt-seam-label {
    font-size: 0.58rem;
    font-weight: 700;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.vrt-seam-canvas-wrap {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    border: 1.5px solid rgba(0, 0, 0, 0.09);
    background: #1a1d20;
}

.vrt-seam-canvas {
    display: block;
    width: 100%;
    height: auto;
    cursor: grab;
    transition: opacity 0.15s;
}

    .vrt-seam-canvas:active {
        cursor: grabbing;
        opacity: 0.9;
    }

.vrt-seam-drag-hint {
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.55);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.52rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 50px;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 3px;
    pointer-events: none;
}

.vrt-seam-offset-display {
    font-size: 0.6rem;
    font-weight: 700;
    color: #F58220;
    text-align: center;
    font-variant-numeric: tabular-nums;
    min-height: 1em;
}

.vrt-seam-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

/* ─── SUCCESS TIP ────────────────────────────────────────── */
.vrt-success-tip {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    padding: 10px 13px;
    background: rgba(52, 211, 153, 0.08);
    border: 1.5px solid rgba(52, 211, 153, 0.25);
    border-radius: 10px;
    font-size: 0.67rem;
    color: #374151;
    line-height: 1.5;
}

    .vrt-success-tip i {
        color: #34d399;
        font-size: 0.95rem;
        flex-shrink: 0;
        margin-top: 1px;
    }

/* ─── FOOTER BUTTONS ─────────────────────────────────────── */
.vrt-modal-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    flex-shrink: 0;
}

.vrt-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    border-radius: 50px;
    border: none;
    font-size: 0.74rem;
    font-weight: 800;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
}

    .vrt-btn:disabled {
        opacity: 0.45;
        cursor: not-allowed;
    }

.vrt-btn-secondary {
    background: #f1f3f5;
    color: #6b7280;
}

    .vrt-btn-secondary:hover:not(:disabled) {
        background: #e5e7eb;
        color: #374151;
    }

.vrt-btn-primary {
    background: linear-gradient(135deg, #F58220, #e06a00);
    color: #fff;
    margin-left: auto;
    box-shadow: 0 4px 14px rgba(245, 130, 32, 0.3);
}

    .vrt-btn-primary:hover:not(:disabled) {
        transform: translateY(-1px);
        box-shadow: 0 8px 22px rgba(245, 130, 32, 0.4);
    }

.vrt-spinner {
    width: 13px;
    height: 13px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    animation: vrtSpin 0.7s linear infinite;
    flex-shrink: 0;
}

/* ─── FULLSCREEN VIEWER ──────────────────────────────────── */
.vrt-viewer-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: #0a0b0d;
    display: none;
    flex-direction: column;
}

    .vrt-viewer-modal.open {
        display: flex;
    }

.vrt-viewer-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.72), transparent);
    pointer-events: none;
}

.vrt-viewer-close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.2);
    background: rgba(0,0,0,0.4);
    color: #fff;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(6px);
    pointer-events: auto;
    transition: background 0.15s, border-color 0.15s;
    flex-shrink: 0;
}

    .vrt-viewer-close:hover {
        background: rgba(255,255,255,0.15);
        border-color: rgba(255,255,255,0.4);
    }

.vrt-viewer-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: rgba(255,255,255,0.85);
    display: flex;
    align-items: center;
    gap: 7px;
}

    .vrt-viewer-title i {
        color: #F58220;
    }

.vrt-viewer-stage {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.vrt-viewer-modal > .vrt-viewer-hint {
    position: absolute;
    bottom: 90px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.52);
    backdrop-filter: blur(8px);
    color: rgba(255,255,255,0.7);
    font-size: 0.63rem;
    font-weight: 600;
    padding: 5px 14px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 6px;
    pointer-events: none;
    z-index: 10;
    animation: vrtHintFade 1s ease 3s forwards;
}

.vrt-viewer-rail {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 15;
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, transparent 100%);
    overflow-x: auto;
    scrollbar-width: none;
}

    .vrt-viewer-rail::-webkit-scrollbar {
        display: none;
    }

.vrt-viewer-rail-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    flex-shrink: 0;
    opacity: 0.7;
    transition: opacity 0.18s, transform 0.18s;
}

    .vrt-viewer-rail-item:hover {
        opacity: 1;
        transform: translateY(-2px);
    }

    .vrt-viewer-rail-item.active {
        opacity: 1;
    }

.vrt-viewer-rail-thumb {
    width: 52px;
    height: 34px;
    border-radius: 7px;
    background: #2a2d32 center / cover no-repeat;
    border: 2px solid transparent;
    transition: border-color 0.18s;
}

.vrt-viewer-rail-item.active .vrt-viewer-rail-thumb {
    border-color: #F58220;
    box-shadow: 0 0 0 2px rgba(245, 130, 32, 0.3);
}

.vrt-viewer-rail-name {
    font-size: 0.56rem;
    font-weight: 700;
    color: rgba(255,255,255,0.7);
    max-width: 60px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ─── UTILITY ────────────────────────────────────────────── */
.hidden {
    display: none !important;
}
/* ============================================================
   VR TOUR — v5 ADDITIONS  (append to vr-tour.css)
   New in v5: quality badges, slider value labels, re-detect
   button, ghost overlay canvas, .vrt-btn-sm
   ============================================================ */

/* ─── QUALITY BADGE (seam selector buttons) ─────────────── */
.vrt-quality-badge {
    display: inline-block;
    font-size: 0.52rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 1px 6px;
    border-radius: 50px;
    margin-left: 4px;
    vertical-align: middle;
    text-transform: uppercase;
    background: rgba(156,163,175,0.15);
    color: #9ca3af;
    border: 1px solid rgba(156,163,175,0.25);
    transition: background 0.2s, color 0.2s;
}

    .vrt-quality-badge.vrt-q-good {
        background: rgba(52,211,153,0.12);
        color: #059669;
        border-color: rgba(52,211,153,0.3);
    }

    .vrt-quality-badge.vrt-q-fair {
        background: rgba(251,191,36,0.12);
        color: #d97706;
        border-color: rgba(251,191,36,0.3);
    }

    .vrt-quality-badge.vrt-q-poor {
        background: rgba(239,68,68,0.10);
        color: #dc2626;
        border-color: rgba(239,68,68,0.25);
    }

/* ─── SLIDER VALUE LABEL ─────────────────────────────────── */
.vrt-slider-val {
    font-size: 0.6rem;
    font-weight: 700;
    color: #F58220;
    min-width: 44px;
    text-align: right;
    font-variant-numeric: tabular-nums;
    display: inline-block;
}

/* ─── SMALL UTILITY BUTTON ───────────────────────────────── */
.vrt-btn-sm {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    border-radius: 8px;
    border: 1.5px solid rgba(0,0,0,0.12);
    background: #fff;
    color: #374151;
    font-size: 0.64rem;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
    white-space: nowrap;
}

    .vrt-btn-sm:hover {
        background: #f3f4f6;
        border-color: rgba(245,130,32,0.35);
        color: #F58220;
    }

    .vrt-btn-sm:disabled {
        opacity: 0.5;
        cursor: not-allowed;
    }

/* ─── ALIGN CANVAS WRAP ──────────────────────────────────── */
.vrt-align-canvas-wrap {
    border-radius: 10px;
    overflow: hidden;
    background: #111;
    border: 1.5px solid rgba(0,0,0,0.12);
    box-shadow: 0 2px 10px rgba(0,0,0,0.09);
}

#vrtAlignCanvas {
    display: block;
    width: 100%;
    border-radius: 8px;
}

/* ─── ALIGN SLIDERS (enhance existing) ───────────────────── */
.vrt-align-sliders label {
    display: grid;
    grid-template-columns: 80px 1fr 52px;
    align-items: center;
    gap: 8px;
    font-size: 0.65rem;
    font-weight: 600;
    color: #374151;
}

.vrt-align-sliders input[type="range"] {
    accent-color: #F58220;
}

/* ─── ALIGN MESSAGE ──────────────────────────────────────── */
.vrt-align-msg {
    padding: 5px 0 0;
    font-size: 0.67rem;
    line-height: 1.5;
}

/* ─── SEAM LINE INDICATOR ────────────────────────────────── */
#vrtSeamLine {
    transform: translateX(-50%);
    transition: left 0.1s;
}