.jam-tour-root[hidden],
.jam-help-popover[hidden] {
    display: none !important;
}

.jam-tour-root {
    position: fixed;
    inset: 0;
    z-index: 12000;
    pointer-events: auto;
    background: transparent;
}

.jam-tour-dialog {
    position: fixed;
    left: 50%;
    bottom: 24px;
    width: min(380px, calc(100vw - 32px));
    transform: translateX(-50%);
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 16px;
    background: #1c1815;
    color: #ffffff;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
}

.jam-tour-target {
    outline: 3px solid var(--accent, #e86c24);
    outline-offset: 5px;
    border-radius: 12px;
    box-shadow: 0 0 0 8px rgba(232, 108, 36, 0.16);
    transition: outline-color 160ms ease, box-shadow 160ms ease;
}

.jam-tour-step {
    margin: 0 0 8px;
    color: #c7bdb7;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.jam-tour-title {
    margin: 0;
    color: #ffffff;
    font-size: 1.1rem;
    line-height: 1.3;
}

.jam-tour-body {
    margin: 10px 0 18px;
    color: #ddd5d0;
    font-size: 0.9rem;
    line-height: 1.55;
}

.jam-tour-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.jam-tour-button {
    min-height: 42px;
    padding: 0 14px;
    border-radius: 10px;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 750;
    cursor: pointer;
}

.jam-tour-button:focus-visible,
.jam-help-button:focus-visible,
.jam-help-popover__close:focus-visible {
    outline: 3px solid #ffb27f;
    outline-offset: 3px;
}

.jam-tour-button:disabled {
    opacity: 0.38;
    cursor: default;
}

.jam-tour-button--ghost {
    border: 1px solid rgba(255, 255, 255, 0.13);
    background: rgba(255, 255, 255, 0.04);
    color: #ffffff;
}

.jam-tour-button--primary {
    margin-left: auto;
    border: 1px solid var(--accent, #e86c24);
    background: var(--accent, #e86c24);
    color: #ffffff;
}

.jam-help-button {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    color: #d7cec8;
    font-size: 0.78rem;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
}

.jam-help-button:hover {
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.28);
}

.jam-help-popover {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 11500;
    width: min(340px, calc(100vw - 32px));
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    background: #1c1815;
    color: #ffffff;
    box-shadow: 0 20px 56px rgba(0, 0, 0, 0.42);
}

.jam-help-popover__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.jam-help-popover__title {
    margin: 0;
    color: #ffffff;
    font-size: 0.94rem;
    line-height: 1.35;
}

.jam-help-popover__body {
    margin: 9px 0 0;
    color: #d9d1cc;
    font-size: 0.82rem;
    line-height: 1.55;
}

.jam-help-popover__close {
    width: 32px;
    height: 32px;
    flex: 0 0 auto;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.04);
    color: #ffffff;
    font: inherit;
    cursor: pointer;
}

@media (max-width: 640px) {
    .jam-tour-dialog {
        bottom: 92px;
    }

    .jam-help-popover {
        left: 16px;
        right: 16px;
        bottom: 16px;
        width: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    .jam-tour-target {
        transition: none;
    }
}
