/**
 * Landing Page Styles
 * English 12 Smart - Custom CSS
 */

/* ============================================
   1. CUSTOM SCROLLBAR
   ============================================ */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* ============================================
   2. ANIMATIONS
   ============================================ */

/* Fade In Up Animation */
/* IMPORTANT: Không set opacity: 0 mặc định để tránh content bị ẩn khi JS chưa load */
.fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

/* Chỉ ẩn content khi đã có class ready (được thêm bởi JS) */
.fade-in-up.ready {
    opacity: 0;
    transform: translateY(20px);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Pulse Animation for Badge */
@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Toast Slide In Animation */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(400px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-slide-in {
    animation: slideIn 0.3s ease-out forwards;
}

/* ============================================
   3. GLASS MORPHISM EFFECTS
   ============================================ */

/* Glass Navigation Bar */
.glass-nav {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* Glass Card */
.glass-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* ============================================
   4. GRADIENT BACKGROUNDS
   ============================================ */

/* Hero Gradient */
.bg-hero-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* Alternative Gradients */
.bg-gradient-blue {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
}

.bg-gradient-purple {
    background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%);
}

.bg-gradient-pink {
    background: linear-gradient(135deg, #ec4899 0%, #be185d 100%);
}

/* ============================================
   5. CUSTOM UTILITIES
   ============================================ */

/* Smooth Scroll */
html {
    scroll-behavior: smooth;
}

/* Text Selection */
::selection {
    background-color: #dbeafe;
    color: #1d4ed8;
}

::-moz-selection {
    background-color: #dbeafe;
    color: #1d4ed8;
}

/* ============================================
   6. HOVER EFFECTS
   ============================================ */

/* Card Hover Effect */
.card-hover {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1),
        0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Button Hover Glow */
.btn-glow:hover {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.5);
}

/* ============================================
   7. CUSTOM COMPONENTS
   ============================================ */

/* Feature Card Icon Transition */
.feature-card .icon-wrapper {
    transition: all 0.3s ease;
}

.feature-card:hover .icon-wrapper {
    transform: scale(1.1) rotate(5deg);
}

/* Testimonial Quote Icon */
.testimonial-quote {
    opacity: 0.1;
    transition: opacity 0.3s ease;
}

.testimonial-card:hover .testimonial-quote {
    opacity: 0.2;
}

/* ============================================
   8. RESPONSIVE UTILITIES
   ============================================ */

/* Mobile Menu Slide Animation */
#mobile-menu {
    transition: all 0.3s ease-in-out;
    max-height: 0;
    overflow: hidden;
}

#mobile-menu.active {
    max-height: 500px;
}

/* ============================================
   9. LOADING STATES
   ============================================ */

/* Skeleton Loading */
.skeleton {
    background: linear-gradient(90deg,
            #f0f0f0 25%,
            #e0e0e0 50%,
            #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* ============================================
   10. ACCESSIBILITY
   ============================================ */

/* Focus Visible for Keyboard Navigation */
*:focus-visible {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* Skip to Main Content Link */
.skip-to-main {
    position: absolute;
    top: -40px;
    left: 0;
    background: #3b82f6;
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    z-index: 100;
}

.skip-to-main:focus {
    top: 0;
}

/* ============================================
   11. PRINT STYLES
   ============================================ */

@media print {
    .no-print {
        display: none !important;
    }

    body {
        background: white;
        color: black;
    }
}

/* ============================================
   12. DARK MODE SUPPORT (Future)
   ============================================ */

@media (prefers-color-scheme: dark) {
    /* Dark mode styles can be added here in the future */
}

/* ============================================
   13. CUSTOM TAILWIND EXTENSIONS
   ============================================ */

/* Custom Slate 850 Color */
.bg-slate-850 {
    background-color: #151f2e;
}

.text-slate-850 {
    color: #151f2e;
}

.border-slate-850 {
    border-color: #151f2e;
}

/* ============================================
   14. PERFORMANCE OPTIMIZATIONS
   ============================================ */

/* GPU Acceleration for Animations */
.gpu-accelerated {
    transform: translateZ(0);
    will-change: transform;
}

/* Reduce Motion for Accessibility */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}