/*
 * Onboarding Styles - Mobile Optimized
 * Touch-friendly onboarding experience
 */

.onboarding-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(10px);
    z-index: 5000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    -webkit-tap-highlight-color: transparent;
}

.onboarding-card {
    background: linear-gradient(145deg, rgba(30, 30, 45, 0.95), rgba(15, 15, 24, 0.98));
    border: 1px solid rgba(0, 255, 163, 0.2);
    border-radius: var(--radius-xl);
    padding: 32px 24px;
    max-width: 360px;
    width: 100%;
    text-align: center;
    animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 40px rgba(0, 255, 163, 0.1);
}

.onboarding-icon {
    font-size: 56px;
    margin-bottom: 20px;
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.onboarding-title {
    font-size: 22px;
    font-weight: 800;
    margin-bottom: 12px;
    background: var(--grad-premium);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.onboarding-content {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
    margin-bottom: 28px;
}

/* Swipe Dots Indicator */
.onboarding-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 28px;
}

.onboarding-dots .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transition: all var(--duration-normal) ease;
}

.onboarding-dots .dot.active {
    background: var(--accent-primary);
    width: 24px;
    border-radius: 4px;
    box-shadow: 0 0 10px rgba(0, 255, 163, 0.5);
}

/* Touch-Optimized Buttons */
.onboarding-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    justify-content: center;
}

.onboarding-actions .btn-primary {
    background: var(--grad-premium);
    color: var(--bg-base);
    border: none;
    padding: 16px 32px;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 16px;
    min-height: var(--touch-target-min);
    cursor: pointer;
    transition: var(--transition-fast);
    -webkit-tap-highlight-color: transparent;
    box-shadow: 0 4px 12px rgba(0, 255, 163, 0.3);
}

/* Remove hover - mobile-only active state */
.onboarding-actions .btn-primary:active {
    transform: scale(var(--touch-scale-active));
    box-shadow: 0 2px 8px rgba(0, 255, 163, 0.2);
}

.onboarding-actions .btn-secondary {
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 16px 24px;
    border-radius: var(--radius-md);
    font-weight: 600;
    min-height: var(--touch-target-min);
    cursor: pointer;
    transition: var(--transition-fast);
    -webkit-tap-highlight-color: transparent;
}

.onboarding-actions .btn-secondary:active {
    transform: scale(var(--touch-scale-active));
    background: rgba(255, 255, 255, 0.05);
}

.skip-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.4);
    font-size: 13px;
    margin-top: 16px;
    cursor: pointer;
    min-height: var(--touch-target-min);
    padding: 12px;
    transition: var(--transition-fast);
    -webkit-tap-highlight-color: transparent;
}

.skip-btn:active {
    color: rgba(255, 255, 255, 0.7);
    transform: scale(0.95);
}

/* Confetti Animation - Optimized for Mobile */
@keyframes confetti-fall {
    0% {
        transform: translateY(-100vh) rotate(0deg);
        opacity: 1;
    }

    100% {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}

.confetti {
    position: fixed;
    width: 8px;
    height: 8px;
    z-index: 6000;
    animation: confetti-fall 2.5s ease-out forwards;
    will-change: transform, opacity;
}

/* Skeleton Loaders - Mobile Optimized */
.skeleton {
    background: linear-gradient(90deg,
            rgba(255, 255, 255, 0.05) 25%,
            rgba(255, 255, 255, 0.1) 50%,
            rgba(255, 255, 255, 0.05) 75%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s ease-in-out infinite;
    border-radius: var(--radius-sm);
}

@keyframes skeleton-shimmer {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

.skeleton-text {
    height: 14px;
    margin-bottom: 8px;
}

.skeleton-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

/* Achievement Toast - Mobile Optimized */
.achievement-toast {
    position: fixed;
    bottom: calc(70px + var(--safe-area-bottom) + 20px);
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, rgba(30, 30, 45, 0.95), rgba(15, 15, 24, 0.98));
    border: 1px solid rgba(0, 255, 163, 0.3);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 5000;
    max-width: calc(100% - 40px);
    animation: slideUp 0.4s ease-out, fadeOut 0.4s ease-in 3s forwards;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), 0 0 20px rgba(0, 255, 163, 0.2);
    -webkit-tap-highlight-color: transparent;
}

.achievement-toast .icon {
    font-size: 28px;
    line-height: 1;
}

.achievement-toast .text {
    flex: 1;
    text-align: left;
}

.achievement-toast .text h4 {
    color: var(--accent-primary);
    font-size: 14px;
    font-weight: 700;
    margin: 0;
}

.achievement-toast .text p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 12px;
    margin: 4px 0 0;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateX(-50%) translateY(-20px);
    }
}

/* Mobile-Specific Adjustments */
@media (max-width: 374px) {
    .onboarding-card {
        padding: 28px 20px;
    }

    .onboarding-title {
        font-size: 20px;
    }

    .onboarding-content {
        font-size: 14px;
    }

    .onboarding-icon {
        font-size: 48px;
    }

    .onboarding-actions .btn-primary,
    .onboarding-actions .btn-secondary {
        padding: 14px 24px;
        font-size: 15px;
    }
}

/* Landscape Mode */
@media (max-height: 500px) and (orientation: landscape) {
    .onboarding-card {
        padding: 20px;
        max-height: 90vh;
        overflow-y: auto;
    }

    .onboarding-icon {
        font-size: 40px;
        margin-bottom: 12px;
    }

    .onboarding-title {
        font-size: 18px;
    }

    .onboarding-content {
        font-size: 13px;
        margin-bottom: 16px;
    }

    .onboarding-dots {
        margin-bottom: 16px;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .onboarding-icon {
        animation: none;
    }

    .confetti {
        animation-duration: 1s;
    }
}