/* SolidGameRun - Common Max Styles */

/* Import Fonts */
@import url('https://fonts.googleapis.com/css2?family=Exo+2:wght@300;400;500;600;700;800;900&family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

/* CSS Variables - Solid Theme */
:root {
    /* Primary Colors - Solid Purple & Orange */
    --primary-solid: #8B5CF6;      /* Solid Purple */
    --primary-energy: #F97316;     /* Energy Orange */
    --primary-success: #10B981;    /* Success Green */
    --primary-warning: #F59E0B;    /* Warning Amber */
    --primary-danger: #EF4444;     /* Danger Red */
    --primary-info: #3B82F6;       /* Info Blue */
    
    /* Background Colors */
    --bg-primary: #0F0F23;         /* Deep Dark Blue */
    --bg-secondary: #1A1A2E;       /* Dark Purple */
    --bg-card: #16213E;            /* Card Background */
    --bg-surface: #0E3460;         /* Surface Background */
    --bg-overlay: rgba(15, 15, 35, 0.95);
    
    /* Text Colors */
    --text-primary: #FFFFFF;
    --text-secondary: #CBD5E1;
    --text-muted: #94A3B8;
    --text-accent: var(--primary-solid);
    
    /* Border & Shadow */
    --border-color: rgba(139, 92, 246, 0.2);
    --border-hover: rgba(139, 92, 246, 0.4);
    --shadow-primary: 0 10px 40px rgba(139, 92, 246, 0.3);
    --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.3);
    
    /* Fonts */
    --font-primary: 'Exo 2', sans-serif;
    --font-secondary: 'Space Grotesk', sans-serif;
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-secondary);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 { font-size: 3rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 2rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

a {
    color: var(--primary-solid);
    text-decoration: none;
    transition: var(--transition-fast);
}

a:hover {
    color: var(--primary-energy);
}

/* Buttons */
.btn-primary-max {
    background: linear-gradient(135deg, var(--primary-solid), var(--primary-energy));
    border: none;
    border-radius: var(--radius-lg);
    color: white;
    padding: 1rem 2rem;
    font-family: var(--font-secondary);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-normal);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: var(--shadow-primary);
    position: relative;
    overflow: hidden;
}

.btn-primary-max::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-primary-max:hover::before {
    left: 100%;
}

.btn-primary-max:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 50px rgba(139, 92, 246, 0.4);
}

.btn-secondary-max {
    background: transparent;
    border: 2px solid var(--primary-solid);
    border-radius: var(--radius-lg);
    color: var(--primary-solid);
    padding: 1rem 2rem;
    font-family: var(--font-secondary);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-normal);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-secondary-max:hover {
    background: var(--primary-solid);
    color: white;
    transform: translateY(-3px);
    box-shadow: var(--shadow-primary);
}

/* Header */
.header-max {
    background: var(--bg-overlay);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 1rem 0;
}

.header-content-max {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.logo-max {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-max img {
    width: 40px;
    height: 40px;
}

.logo-text {
    font-family: var(--font-secondary);
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-solid), var(--primary-energy));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Search */
.search-container-max {
    flex: 1;
    max-width: 500px;
}

.search-form-max {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input-max {
    width: 100%;
    padding: 0.75rem 1rem;
    padding-right: 3rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    font-size: 1rem;
    transition: var(--transition-normal);
}

.search-input-max:focus {
    outline: none;
    border-color: var(--primary-solid);
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.3);
}

.search-btn-max {
    position: absolute;
    right: 0.5rem;
    background: var(--primary-solid);
    border: none;
    border-radius: var(--radius-sm);
    color: white;
    padding: 0.5rem;
    cursor: pointer;
    transition: var(--transition-fast);
}

.search-btn-max:hover {
    background: var(--primary-energy);
    transform: scale(1.05);
}

/* Navigation */
.nav-max {
    display: flex;
    align-items: center;
}

.dropdown-menu-max {
    display: flex;
    list-style: none;
    gap: 1rem;
}

.dropdown-menu-max li a {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    transition: var(--transition-fast);
    font-weight: 500;
}

.dropdown-menu-max li a:hover {
    background: var(--bg-card);
    color: var(--primary-energy);
}

/* Footer */
.footer-max {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.footer-logo img {
    width: 32px;
    height: 32px;
}

.footer-description-max {
    color: var(--text-muted);
    line-height: 1.6;
    max-width: 400px;
}

.footer-links-section h3 {
    color: var(--primary-solid);
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.footer-links-max {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-links-max a {
    color: var(--text-muted);
    transition: var(--transition-fast);
}

.footer-links-max a:hover {
    color: var(--primary-energy);
}

.footer-bottom-max {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
}

/* Back to Top */
.back-to-top-max {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--primary-solid);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    color: white;
    cursor: pointer;
    transition: var(--transition-normal);
    opacity: 0;
    visibility: hidden;
    z-index: 1000;
}

.back-to-top-max.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top-max:hover {
    background: var(--primary-energy);
    transform: translateY(-3px);
    box-shadow: var(--shadow-primary);
}

/* Animations */
@keyframes solidGlow {
    0%, 100% { 
        box-shadow: 0 0 20px rgba(139, 92, 246, 0.3); 
    }
    50% { 
        box-shadow: 0 0 40px rgba(139, 92, 246, 0.6); 
    }
}

@keyframes energyPulse {
    0%, 100% { 
        transform: scale(1); 
        opacity: 1; 
    }
    50% { 
        transform: scale(1.05); 
        opacity: 0.8; 
    }
}

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

/* Utility Classes */
.solid-glow {
    animation: solidGlow 2s ease-in-out infinite;
}

.energy-pulse {
    animation: energyPulse 1.5s ease-in-out infinite;
}

.slide-in-up {
    animation: slideInUp 0.6s ease-out;
}

/* Responsive Design */
/* SolidGameRun Utils */
/* .SolidUtils  {
  
    screenShake: function(duration = 200) {
        document.body.style.animation = `shake 0.5s ease-in-out`;
        setTimeout(() => {
            document.body.style.animation = '';
        }, duration);
    },


    flashEffect: function(color = 'var(--primary-solid)') {
        const flash = document.createElement('div');
        flash.style.cssText = `
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: ${color};
            opacity: 0.3;
            z-index: 9999;
            pointer-events: none;
            animation: flashFade 0.3s ease-out;
        `;
        document.body.appendChild(flash);
        setTimeout(() => flash.remove(), 300);
    },


    randomGlow: function(element) {
        const colors = ['var(--primary-solid)', 'var(--primary-energy)', 'var(--primary-success)'];
        const color = colors[Math.floor(Math.random() * colors.length)];
        element.style.boxShadow = `0 0 30px ${color}`;
        setTimeout(() => {
            element.style.boxShadow = '';
        }, 1000);
    }
}; */

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

@keyframes flashFade {
    0% { opacity: 0.3; }
    50% { opacity: 0.1; }
    100% { opacity: 0; }
}

/* Mobile Navigation Base Styles */
.mobile-menu-btn {
    display: none;
}

.mobile-search-btn {
    display: none;
    background: transparent;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    transition: var(--transition-fast);
    font-size: 1.2rem;
}

.mobile-search-btn:hover {
    background: var(--bg-card);
    color: var(--primary-solid);
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-content-max {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 0.5rem;
        position: relative;
    }

    .header-max{
        position: relative;
    }

    .logo-max {
        flex: 1;
    }

    .logo-max a{
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .search-container-max {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        width: 100%;
        background: var(--bg-primary);
        border-top: 1px solid var(--border-color);
        padding: 1rem;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all var(--transition-normal);
        z-index: 1000;
        box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    }

    .search-container-max.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .search-container-max .search-input-max {
        width: 100%;
        margin-bottom: 0;
    }

    .search-container-max .search-btn-max {
        position: absolute;
        right: 1rem;
        top: 50%;
        transform: translateY(-50%);
        background: var(--primary-solid);
        color: white;
        border: none;
        padding: 0.5rem;
        border-radius: var(--radius-sm);
        cursor: pointer;
        transition: var(--transition-fast);
    }

    .search-container-max .search-btn-max:hover {
        background: var(--primary-energy);
        transform: translateY(-50%) scale(1.05);
    }

    .nav-max {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .mobile-search-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        margin-right: 0.5rem;
        /* display: none; */
    }

    .header-content-max .mobile-search-btn + .mobile-menu-btn {
        margin-left: 0;
    }

    .mobile-menu-btn{
        /* display: none !important; */
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    h3 { font-size: 1.5rem; }
}

@media (max-width: 480px) {
    .container {
        padding: 0 0.75rem;
    }

    .header-content-max {
        flex-wrap: wrap;
        padding: 0rem 0;
    }

    .search-container-max {
        order: 3;
        width: 100%;
        margin-top: 0.75rem;
    }

    .search-input-max {
        font-size: 16px; /* Prevent zoom on iOS */
        padding: 0.75rem 1rem;
    }

    .search-btn-max {
        padding: 0.75rem;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.25rem; }
    h4 { font-size: 1.1rem; }
    h5 { font-size: 1rem; }
    h6 { font-size: 0.9rem; }

    .main-details{
        width: 94vw;
    }
    .main-content-max{
        padding-top: 10px !important;
    }
}

@media (max-width: 360px) {
    .container {
        padding: 0 0.5rem;
    }

    .header-content-max {
        padding: 0.5rem 0;
    }

    .search-container-max {
        margin-top: 0.5rem;
    }

    .search-input-max {
        padding: 0.6rem 0.8rem;
        font-size: 15px;
    }

    .search-btn-max {
        padding: 0.6rem;
    }

    h1 { font-size: 1.8rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.2rem; }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    .btn-primary-max,
    .btn-secondary-max,
    .search-btn-max {
        min-height: 44px;
        min-width: 44px;
    }

    .btn-primary-max:active,
    .btn-secondary-max:active {
        transform: scale(0.98);
    }

    .search-btn-max:active {
        transform: scale(0.95);
    }
}

/* Prevent horizontal scroll */
@media (max-width: 768px) {
    body {
        overflow-x: hidden;
    }

    * {
        max-width: 100%;
    }

    img {
        max-width: 100%;
        height: auto;
    }
    .comment-rating-max{
        display: none !important;
    }

    /* Ensure no elements exceed viewport width */
    .container,
    .header-content-max,
    .search-container-max,
    .footer-content {
        max-width: 100%;
        box-sizing: border-box;
    }
}

/* iOS Safari specific fixes */
@supports (-webkit-touch-callout: none) {
    .header-max {
        padding-bottom: env(safe-area-inset-bottom);
    }

    .main-content-max {
        padding-bottom: env(safe-area-inset-bottom);
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .logo-max img {
        image-rendering: -webkit-optimize-contrast;
    }
}
