/* ── Shepherd.js Tour Overrides ──────────────────── */
/* Using !important to beat Shepherd's built-in styles */

/* Overlay */
.shepherd-modal-overlay-container {
    fill: rgba(0, 0, 0, 0.5) !important;
}

/* Tooltip container */
.shepherd-element.shepherd-has-title[data-shepherd-step-id] {
    max-width: 400px !important;
    border-radius: 14px !important;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.18) !important;
    border: none !important;
    z-index: 10000 !important;
    overflow: hidden !important;
}

.shepherd-element .shepherd-content {
    border-radius: 14px !important;
    padding: 0 !important;
    background: #fff !important;
}

/* Header — bold blue gradient */
.shepherd-element .shepherd-header {
    background: linear-gradient(135deg, #1558b0, #1a73e8) !important;
    padding: 16px 20px 12px !important;
    border-radius: 0 !important;
    border-bottom: none !important;
}

/* Title — white on blue */
.shepherd-element .shepherd-header .shepherd-title {
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: #fff !important;
    max-width: 100% !important;
}

/* Cancel (X) button */
.shepherd-element .shepherd-header .shepherd-cancel-icon {
    color: rgba(255, 255, 255, 0.6) !important;
    font-size: 1.5rem !important;
}
.shepherd-element .shepherd-header .shepherd-cancel-icon:hover {
    color: #fff !important;
}

/* Body text */
.shepherd-element .shepherd-text {
    padding: 16px 20px !important;
    font-size: 0.88rem !important;
    line-height: 1.6 !important;
    color: #333 !important;
    background: #fff !important;
}
.shepherd-element .shepherd-text p {
    margin: 0 0 8px !important;
}
.shepherd-element .shepherd-text p:last-child {
    margin-bottom: 0 !important;
}

/* Footer / buttons */
.shepherd-element .shepherd-footer {
    padding: 12px 20px 16px !important;
    border-top: 1px solid #eee !important;
    background: #fafbfc !important;
}

.shepherd-element .shepherd-footer .shepherd-button {
    border: none !important;
    border-radius: 8px !important;
    padding: 8px 20px !important;
    font-size: 0.82rem !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: all 0.15s !important;
}

/* Secondary button (Back) */
.shepherd-element .shepherd-footer .shepherd-button.shepherd-button-secondary {
    background: #e9ecef !important;
    color: #495057 !important;
}
.shepherd-element .shepherd-footer .shepherd-button.shepherd-button-secondary:hover {
    background: #dee2e6 !important;
}

/* Primary button (Next, Done, Let's go) */
.shepherd-element .shepherd-footer .shepherd-button:not(.shepherd-button-secondary) {
    background: linear-gradient(135deg, #1558b0, #1a73e8) !important;
    color: #fff !important;
}
.shepherd-element .shepherd-footer .shepherd-button:not(.shepherd-button-secondary):hover {
    background: linear-gradient(135deg, #0e4a96, #1558b0) !important;
}

/* Progress dots */
.tour-progress {
    display: flex;
    gap: 5px;
    justify-content: center;
    padding: 0 20px 6px;
}
.tour-progress-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #dee2e6;
    transition: background 0.2s;
}
.tour-progress-dot.active {
    background: #1a73e8;
}

/* Arrow */
.shepherd-element .shepherd-arrow:before {
    background: #fff !important;
}
.shepherd-element[data-popper-placement^="bottom"] .shepherd-arrow:before {
    background: #1558b0 !important;
}


/* ── Floating Help Button (FAB) ─────────────────── */

.tour-fab {
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 9000;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
    pointer-events: none;
}

/* The round button */
.tour-fab-btn {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #1558b0, #1a73e8);
    color: #fff;
    font-size: 1.25rem;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(26, 115, 232, 0.4);
    transition: transform 0.2s, box-shadow 0.2s;
    pointer-events: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}
.tour-fab-btn:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 24px rgba(26, 115, 232, 0.5);
}
.tour-fab-btn:active {
    transform: scale(0.97);
}

/* Pulse ring on first visit */
.tour-fab-btn.pulsing::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 2px solid #4285f4;
    animation: tour-pulse 2s ease-out infinite;
}

@keyframes tour-pulse {
    0% {
        transform: scale(1);
        opacity: 0.7;
    }
    100% {
        transform: scale(1.6);
        opacity: 0;
    }
}

/* Speech bubble nudge */
.tour-nudge {
    pointer-events: auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.12);
    padding: 14px 18px;
    max-width: 260px;
    position: relative;
    animation: tour-nudge-in 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) both;
    animation-delay: 1s;
    opacity: 0;
}

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

/* Bubble arrow pointing down-right */
.tour-nudge::after {
    content: '';
    position: absolute;
    bottom: -8px;
    right: 22px;
    width: 16px;
    height: 16px;
    background: #fff;
    transform: rotate(45deg);
    box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.06);
}

.tour-nudge-title {
    font-size: 0.88rem;
    font-weight: 600;
    color: #1a73e8;
    margin-bottom: 4px;
}

.tour-nudge-text {
    font-size: 0.8rem;
    color: #555;
    line-height: 1.45;
    margin-bottom: 10px;
}

.tour-nudge-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.tour-nudge-start {
    background: linear-gradient(135deg, #1558b0, #1a73e8);
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 5px 14px;
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s;
}
.tour-nudge-start:hover {
    background: #0e4a96;
}

.tour-nudge-dismiss {
    background: none;
    border: none;
    color: #999;
    font-size: 0.75rem;
    cursor: pointer;
    padding: 4px 8px;
}
.tour-nudge-dismiss:hover {
    color: #555;
}

/* Hide nudge when it's dismissed */
.tour-nudge.hidden {
    display: none;
}
