/* ==========================================================================
   ARKENSTONE REGISTRY — ONBOARDING TOUR
   Spotlight step-tour: overlay + spotlight ring + floating tooltip card
   ========================================================================== */

/* ── OVERLAY (blocks interaction with the app) ───────────────────────────── */
.tour-overlay {
    position: fixed;
    inset: 0;
    z-index: 9000;
    background: transparent;
    pointer-events: all;
}

/* ── SPOTLIGHT RING ──────────────────────────────────────────────────────── */
/* The large box-shadow fills the overlay area, leaving a transparent "hole"  */
.tour-spotlight {
    position: fixed;
    z-index: 9001;
    border-radius: 12px;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.68);
    pointer-events: none;
    transition:
        top    0.35s cubic-bezier(0.34, 1.2, 0.64, 1),
        left   0.35s cubic-bezier(0.34, 1.2, 0.64, 1),
        width  0.35s cubic-bezier(0.34, 1.2, 0.64, 1),
        height 0.35s cubic-bezier(0.34, 1.2, 0.64, 1),
        opacity 0.2s ease;
    outline: 2px solid rgba(200, 160, 60, 0.5);
    outline-offset: 2px;
}

/* ── TOOLTIP CARD ────────────────────────────────────────────────────────── */
.tour-card {
    position: fixed;
    z-index: 9002;
    background: var(--color-surface-card);
    border: 1px solid rgba(200, 160, 60, 0.2);
    border-radius: 18px;
    padding: 22px 24px 18px;
    width: 340px;
    box-shadow:
        0 24px 64px rgba(0, 0, 0, 0.32),
        0 0 0 1px rgba(200, 160, 60, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    animation: tour-card-in 0.3s cubic-bezier(0.34, 1.4, 0.64, 1);
}
[data-theme="dark"] .tour-card {
    box-shadow:
        0 24px 64px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(200, 160, 60, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

@keyframes tour-card-in {
    from { opacity: 0; transform: translateY(10px) scale(0.95); }
    to   { opacity: 1; transform: translateY(0)    scale(1);    }
}

/* Centered welcome / done card */
.tour-card.tour-centered {
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    width: 460px;
    text-align: center;
    padding: 36px 40px 28px;
}

/* ── CARD CONTENT ────────────────────────────────────────────────────────── */
.tour-icon {
    font-size: 42px;
    color: var(--gold);
    margin-bottom: 14px;
    display: block;
}

.tour-card-title {
    font-family: var(--font-display);
    font-size: 19px;
    font-weight: 700;
    color: var(--color-ink-primary);
    line-height: 1.2;
    margin-bottom: 10px;
}
.tour-centered .tour-card-title { font-size: 22px; }

.tour-card-body {
    font-size: 13.5px;
    line-height: 1.7;
    color: var(--color-ink-secondary);
    margin-bottom: 20px;
}
.tour-card-body kbd {
    display: inline-flex;
    align-items: center;
    padding: 1px 6px;
    background: var(--color-surface-page);
    border: 1px solid var(--color-border-rule);
    border-radius: 5px;
    font-size: 11px;
    font-family: 'DM Mono', 'Fira Code', monospace;
    color: var(--color-ink-primary);
    box-shadow: 0 1px 0 var(--color-border-rule);
}
.tour-card-body strong { color: var(--color-ink-primary); font-weight: 600; }

/* ── PROGRESS DOTS ───────────────────────────────────────────────────────── */
.tour-dots {
    display: flex;
    align-items: center;
    gap: 4px;
    justify-content: center;
}
.tour-dot-step {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--color-border-rule);
    transition: background 0.2s, transform 0.2s, width 0.2s;
    flex-shrink: 0;
}
.tour-dot-step.active {
    background: var(--gold);
    transform: scale(1.35);
    width: 18px;
    border-radius: 3px;
}
.tour-dot-step.done { background: rgba(200, 160, 60, 0.38); }

/* ── FOOTER ──────────────────────────────────────────────────────────────── */
.tour-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

/* Dots span the full width as their own top row */
.tour-dots {
    order: -1;
    width: 100%;
    margin-bottom: 2px;
}

.tour-btn-skip {
    font-size: 11px;
    color: var(--color-ink-muted);
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px 2px;
    font-family: var(--font-body);
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.12s;
    flex: 1;  /* pushes Back + Next to the right */
}
.tour-btn-skip:hover { color: var(--color-ink-primary); }

.tour-btn-back {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 12px;
    border-radius: 9px;
    font-size: 12.5px;
    font-weight: 500;
    font-family: var(--font-body);
    cursor: pointer;
    background: var(--color-surface-page);
    border: 1px solid var(--color-border-rule);
    color: var(--color-ink-primary);
    transition: filter 0.12s;
    flex-shrink: 0;
}
.tour-btn-back:hover { filter: brightness(0.94); }

.tour-btn-next {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 9px;
    font-size: 13px;
    font-weight: 600;
    font-family: var(--font-body);
    cursor: pointer;
    border: none;
    background: linear-gradient(135deg, #c9a227 0%, #8b6914 100%);
    color: #fff8e8;
    box-shadow: 0 2px 10px rgba(180, 130, 30, 0.32);
    transition: filter 0.12s, transform 0.1s;
    flex-shrink: 0;
}
.tour-btn-next:hover  { filter: brightness(1.1); }
.tour-btn-next:active { transform: scale(0.96); }

/* ── TOOLTIP ARROW ───────────────────────────────────────────────────────── */
.tour-arrow {
    position: absolute;
    width: 12px;
    height: 12px;
    background: var(--color-surface-card);
    border: 1px solid rgba(200, 160, 60, 0.2);
    transform: rotate(45deg);
}
.tour-arrow-top    { top: -7px;  left: 28px; border-bottom: none; border-right: none; }
.tour-arrow-bottom { bottom: -7px; left: 28px; border-top: none; border-left: none; }
.tour-arrow-left   { left: -7px;  top: 26px; border-right: none; border-top: none; }
.tour-arrow-right  { right: -7px; top: 26px; border-left: none; border-bottom: none; }

/* ── TOUR LAUNCH BUTTON (in shortcuts overlay + settings) ────────────────── */
.tour-launch-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 11px 14px;
    margin-top: 14px;
    background: var(--gold-faint);
    border: 1px solid var(--gold-pale);
    border-radius: 10px;
    color: var(--color-ink-primary);
    font-size: 13px;
    font-weight: 500;
    font-family: var(--font-body);
    cursor: pointer;
    text-align: left;
    transition: background 0.12s, border-color 0.12s;
}
.tour-launch-btn:hover { background: var(--gold-pale); border-color: var(--gold); }
.tour-launch-btn i { color: var(--gold); font-size: 17px; flex-shrink: 0; }
.tour-launch-btn-sub {
    font-size: 10.5px;
    color: var(--color-ink-muted);
    display: block;
    margin-top: 1px;
}

/* ── RESPONSIVE ──────────────────────────────────────────────────────────── */
@media (max-width: 600px) {
    .tour-card, .tour-card.tour-centered {
        width: calc(100vw - 32px);
        left: 16px !important;
        right: 16px !important;
        transform: none !important;
        top: auto !important;
        bottom: 16px !important;
    }
}
