/* ==========================================================
   TOUR DE ONBOARDING — apresenta novidades pós-atualização
   ==========================================================
   Renderiza um overlay escuro com um "buraco" recortado em volta
   do elemento alvo (spotlight) + tooltip animada + mãozinha
   apontando. Tudo em CSS puro, sem dependência externa.
*/

/* ---------- Overlay base + spotlight ---------- */
#inprout-tour-overlay {
    position: fixed;
    inset: 0;
    z-index: 1080;            /* navbar=1030, modal-bs=1055, swal=1060 */
    pointer-events: none;
    animation: inprout-tour-fadein 0.35s ease;
}

@keyframes inprout-tour-fadein {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* O "buraco" é um div posicionado sobre o alvo com um box-shadow gigante
   que escurece todo o resto da tela. Sem clip-path, máxima compatibilidade. */
.inprout-tour-spotlight {
    position: fixed;
    border-radius: 12px;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.72);
    pointer-events: none;
    transition: top 0.45s cubic-bezier(0.4, 0, 0.2, 1),
                left 0.45s cubic-bezier(0.4, 0, 0.2, 1),
                width 0.45s cubic-bezier(0.4, 0, 0.2, 1),
                height 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Halo verde pulsante em volta do alvo */
.inprout-tour-spotlight::after {
    content: "";
    position: absolute;
    inset: -4px;
    border: 3px solid rgba(125, 167, 138, 0.95);
    border-radius: 14px;
    animation: inprout-tour-pulse 1.6s ease-in-out infinite;
    pointer-events: none;
}

@keyframes inprout-tour-pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.95;
    }
    50% {
        transform: scale(1.06);
        opacity: 0.4;
    }
}

/* ---------- Mãozinha apontando ---------- */
.inprout-tour-pointer {
    position: fixed;
    z-index: 1082;
    pointer-events: none;
    font-size: 2rem;
    color: #ffd54f;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.55));
    animation: inprout-tour-bounce 1.1s ease-in-out infinite;
    transition: top 0.45s cubic-bezier(0.4, 0, 0.2, 1),
                left 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes inprout-tour-bounce {
    0%, 100% { transform: translateY(0)   rotate(-8deg); }
    50%      { transform: translateY(-8px) rotate(0deg); }
}

/* ---------- Tooltip card ---------- */
.inprout-tour-tooltip {
    position: fixed;
    z-index: 1083;
    background: #ffffff;
    color: #1f2937;
    border-radius: 14px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
    padding: 18px 20px;
    width: 340px;
    max-width: calc(100vw - 24px);
    pointer-events: auto;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    border: 1px solid #e5e7eb;
    font-family: 'Inter', sans-serif;
}

.inprout-tour-tooltip.visible {
    opacity: 1;
    transform: translateY(0);
}

.inprout-tour-tooltip .ttitle {
    margin: 0 0 8px;
    font-size: 1rem;
    font-weight: 600;
    color: #4a665a;
    display: flex;
    align-items: center;
    gap: 8px;
}

.inprout-tour-tooltip .ttitle i {
    color: #7da78a;
    font-size: 1.15rem;
}

.inprout-tour-tooltip .tbody {
    margin: 0 0 14px;
    font-size: 0.9rem;
    line-height: 1.5;
    color: #4b5563;
}

.inprout-tour-tooltip .tbody strong {
    color: #1f2937;
}

.inprout-tour-tooltip .tactions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.inprout-tour-tooltip .step-label {
    font-size: 0.74rem;
    color: #9ca3af;
    flex: 1;
    text-align: center;
}

.inprout-tour-tooltip .btn-skip {
    background: transparent;
    border: none;
    color: #6b7280;
    font-size: 0.82rem;
    padding: 6px 8px;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.15s, color 0.15s;
}
.inprout-tour-tooltip .btn-skip:hover {
    background: #f3f4f6;
    color: #1f2937;
}

.inprout-tour-tooltip .btn-next {
    background: #198754;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 8px 16px;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.inprout-tour-tooltip .btn-next:hover {
    background: #157347;
}
.inprout-tour-tooltip .btn-next:active {
    transform: scale(0.97);
}

/* Setinha do tooltip (tipo balão) */
.inprout-tour-tooltip .arrow {
    position: absolute;
    width: 14px;
    height: 14px;
    background: inherit;
    transform: rotate(45deg);
    border: 1px solid #e5e7eb;
}
.inprout-tour-tooltip[data-pos="bottom"] .arrow {
    top: -8px;
    left: 28px;
    border-right: none;
    border-bottom: none;
}
.inprout-tour-tooltip[data-pos="top"] .arrow {
    bottom: -8px;
    left: 28px;
    border-left: none;
    border-top: none;
}
.inprout-tour-tooltip[data-pos="left"] .arrow {
    right: -8px;
    top: 24px;
    border-left: none;
    border-bottom: none;
}
.inprout-tour-tooltip[data-pos="right"] .arrow {
    left: -8px;
    top: 24px;
    border-right: none;
    border-top: none;
}

/* ---------- Modo escuro ---------- */
[data-theme="dark"] .inprout-tour-tooltip {
    background: #1f2937;
    color: #e5e7eb;
    border-color: #374151;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.7);
}
[data-theme="dark"] .inprout-tour-tooltip .ttitle {
    color: #a3bfa8;
}
[data-theme="dark"] .inprout-tour-tooltip .ttitle i {
    color: #cce3d3;
}
[data-theme="dark"] .inprout-tour-tooltip .tbody {
    color: #cbd5e1;
}
[data-theme="dark"] .inprout-tour-tooltip .tbody strong {
    color: #f3f4f6;
}
[data-theme="dark"] .inprout-tour-tooltip .step-label {
    color: #6b7280;
}
[data-theme="dark"] .inprout-tour-tooltip .btn-skip {
    color: #9ca3af;
}
[data-theme="dark"] .inprout-tour-tooltip .btn-skip:hover {
    background: #374151;
    color: #f3f4f6;
}
[data-theme="dark"] .inprout-tour-tooltip .arrow {
    background: #1f2937;
    border-color: #374151;
}

/* ---------- Mobile ---------- */
@media (max-width: 540px) {
    .inprout-tour-tooltip {
        width: calc(100vw - 24px);
    }
    .inprout-tour-pointer {
        font-size: 1.6rem;
    }
}
