/* Additional Custom Styles for AoTearoaFun Theme */

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Additional Animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Animated Elements */
.feature-icon {
    animation: float 3s ease-in-out infinite;
}

.crypto-icon {
    animation: pulse 4s ease-in-out infinite;
}

/* Button Hover Effects */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

/* Loading Animation for Game */
.game-iframe-wrapper {
    position: relative;
}

.game-iframe-wrapper::before {
    content: 'Loading Game...';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 24px;
    color: var(--primary-color);
    font-weight: 700;
    z-index: 1;
    animation: pulse 1.5s ease-in-out infinite;
}

.game-iframe {
    position: relative;
    z-index: 2;
    background: var(--dark-bg);
}

/* Responsive Navigation Toggle */
.menu-toggle {
    display: none;
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--text-light);
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 18px;
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .main-navigation ul {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--dark-bg);
        padding: 20px;
        border-top: 1px solid var(--border-color);
    }

    .main-navigation.active ul {
        display: flex;
    }

    .main-navigation ul li {
        width: 100%;
        text-align: center;
    }
}

/* Enhanced Card Hover Effects */
.feature-card {
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.feature-card:hover .feature-icon {
    transform: scale(1.2) rotate(5deg);
    transition: transform 0.3s ease;
}

/* Gradient Text Effect */
.gradient-text {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--darker-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* Glowing Effect for Important Elements */
.glow {
    box-shadow: 0 0 20px rgba(255, 140, 0, 0.5);
}

.glow:hover {
    box-shadow: 0 0 30px rgba(255, 140, 0, 0.8);
}

/* Particle Background Effect */
.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(circle, rgba(255, 140, 0, 0.1) 1px, transparent 1px),
        radial-gradient(circle, rgba(255, 165, 0, 0.1) 1px, transparent 1px);
    background-size: 50px 50px, 80px 80px;
    background-position: 0 0, 40px 40px;
    animation: particleAnimation 20s linear infinite;
    z-index: 1;
}

@keyframes particleAnimation {
    0% {
        background-position: 0 0, 40px 40px;
    }
    100% {
        background-position: 50px 50px, 90px 90px;
    }
}

/* Print Styles */
@media print {
    .warning-banner,
    .site-header,
    .site-footer,
    .cta-buttons,
    .back-button {
        display: none;
    }

    body {
        background: white;
        color: black;
    }
}

/* Accessibility Improvements */
.skip-to-content {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    z-index: 100;
}

.skip-to-content:focus {
    top: 0;
}

/* Focus Styles for Keyboard Navigation */
a:focus,
button:focus,
input:focus,
textarea:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Loading States */
.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    border: 3px solid var(--primary-color);
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    transform: translate(-50%, -50%);
}

@keyframes spin {
    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

/* Additional Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-lg {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.rounded {
    border-radius: 8px;
}

.rounded-lg {
    border-radius: 16px;
}

/* Mobile Optimizations */
@media (max-width: 480px) {
    .hero-title {
        font-size: 32px;
    }

    .section-title {
        font-size: 28px;
    }

    .page-title {
        font-size: 32px;
    }

    .btn {
        padding: 12px 24px;
        font-size: 14px;
    }

    .content-section {
        padding: 20px;
    }
}

/* High DPI Display Optimizations */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero-background {
        image-rendering: -webkit-optimize-contrast;
    }
}

/* Dark Mode Support (if browser supports) */
@media (prefers-color-scheme: dark) {
    /* Already dark by default, but we can enhance it */
    :root {
        --dark-bg: #050810;
        --darker-bg: #000000;
    }
}

/* Reduced 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;
    }
}
