/**
 * Oracle Package Tooltip Styles - TeslaServer Theme
 * استایل تولتیپ پکیج اوراکل
 */

/* Oracle Alert Enhancement */
.alert-danger:has(h6:contains("ویژه افراد حساس")),
.alert-danger:has(.fas.fa-crown) {
    position: relative;
    cursor: help;
    transition: all 0.3s ease;
}

.alert-danger:hover {
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.2);
}

/* Oracle Tooltip Container */
.oracle-tooltip {
    position: fixed;
    left: 50%;
    bottom: auto;
    top: auto;
    transform: translateX(-50%) translateY(-10px);
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #2c3e50;
    padding: 1rem 1.25rem;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(255, 215, 0, 0.5);
    min-width: 380px;
    max-width: 480px;
    z-index: 999999 !important;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    pointer-events: none;
    max-height: 80vh;
    overflow-y: auto;
}

/* Tooltip Arrow */
.oracle-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 10px solid transparent;
    border-top-color: #FFA500;
    z-index: 1;
}

/* Show Tooltip on Hover */
.oracle-tooltip.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-5px);
    pointer-events: auto;
}

/* Show below variant */
.oracle-tooltip.show-below {
    transform: translateX(-50%) translateY(10px);
}

.oracle-tooltip.show-below.active {
    transform: translateX(-50%) translateY(5px);
}

.oracle-tooltip.show-below::after {
    top: auto;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border-top-color: transparent;
    border-bottom-color: #FFD700;
    z-index: 1;
}

/* Tooltip Header */
.oracle-tooltip .tooltip-header {
    text-align: center;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid rgba(44, 62, 80, 0.2);
}

.oracle-tooltip .tooltip-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    animation: crownFloat 3s ease-in-out infinite;
}

@keyframes crownFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-5px) rotate(-5deg); }
    50% { transform: translateY(0) rotate(0deg); }
    75% { transform: translateY(-5px) rotate(5deg); }
}

.oracle-tooltip .tooltip-title {
    font-size: 1rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 0.25rem;
}

.oracle-tooltip .tooltip-subtitle {
    font-size: 0.8rem;
    color: #34495e;
    font-weight: 500;
}

/* Tooltip Content Sections */
.oracle-tooltip .tooltip-section {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    padding: 0.75rem;
    margin-bottom: 0.75rem;
}

.oracle-tooltip .section-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: #e67e22;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.oracle-tooltip .section-title i {
    font-size: 1rem;
}

.oracle-tooltip .section-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.oracle-tooltip .section-list li {
    font-size: 0.75rem;
    padding: 0.25rem 0;
    padding-right: 1.2rem;
    position: relative;
    line-height: 1.5;
    color: #2c3e50;
}

.oracle-tooltip .section-list li::before {
    content: '✨';
    position: absolute;
    right: 0;
    font-size: 0.75rem;
}

.oracle-tooltip .section-list li strong {
    color: #c0392b;
    font-weight: 600;
}

/* Commitment Section */
.oracle-tooltip .commitment-box {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    border-radius: 8px;
    padding: 0.75rem;
    text-align: center;
    margin-bottom: 0.75rem;
}

.oracle-tooltip .commitment-box .commitment-title {
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.oracle-tooltip .commitment-box .commitment-list {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.75rem;
}

.oracle-tooltip .commitment-box .commitment-list li {
    padding: 0.2rem 0;
}

/* Final Message */
.oracle-tooltip .final-message {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    padding: 0.6rem;
    text-align: center;
    font-size: 0.8rem;
    color: #27ae60;
    font-weight: 600;
}

.oracle-tooltip .final-message i {
    margin-left: 0.3rem;
    font-size: 0.9rem;
}

/* Scrollbar Styling */
.oracle-tooltip::-webkit-scrollbar {
    width: 6px;
}

.oracle-tooltip::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

.oracle-tooltip::-webkit-scrollbar-thumb {
    background: rgba(255, 165, 0, 0.6);
    border-radius: 3px;
}

.oracle-tooltip::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 165, 0, 0.8);
}

/* Pulse Animation */
@keyframes oraclePulse {
    0%, 100% {
        box-shadow: 0 8px 30px rgba(255, 215, 0, 0.5);
    }
    50% {
        box-shadow: 0 12px 40px rgba(255, 215, 0, 0.7);
    }
}

.oracle-tooltip.active {
    animation: oraclePulse 2s infinite;
}

/* Responsive */
@media (max-width: 768px) {
    .oracle-tooltip {
        min-width: 300px;
        max-width: 90vw;
        padding: 0.85rem 1rem;
        max-height: 70vh;
    }

    .oracle-tooltip .tooltip-icon {
        font-size: 1.5rem;
    }

    .oracle-tooltip .tooltip-title {
        font-size: 0.9rem;
    }

    .oracle-tooltip .section-title {
        font-size: 0.8rem;
    }

    .oracle-tooltip .section-list li {
        font-size: 0.7rem;
    }
}

/* RTL Support */
[dir="rtl"] .oracle-tooltip .section-list li {
    padding-right: 0;
    padding-left: 1.2rem;
}

[dir="rtl"] .oracle-tooltip .section-list li::before {
    right: auto;
    left: 0;
}

[dir="rtl"] .oracle-tooltip .final-message i {
    margin-left: 0;
    margin-right: 0.3rem;
}

/* Smooth transitions */
.oracle-tooltip {
    backdrop-filter: blur(10px);
    transition-delay: 0.2s;
}

.oracle-tooltip.active {
    transition-delay: 0s;
}

