* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #000000 0%, #1a1a1a 50%, #000000 100%);
    color: white;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    overflow-x: hidden;
}

/* Simplified background for better performance */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.02) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

/* Optimized Navigation with Liquid Glass Effect */
.navbar {
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1rem 0;
    position: relative;
    transition: all 0.3s ease;
}

/* Simplified liquid glass effect */
.navbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.02) 100%);
    z-index: -1;
}

/* Mobile hamburger menu styles */
.navbar-toggler {
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 0.25rem 0.5rem;
    border-radius: 0.375rem;
    background: transparent;
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.25rem rgba(255, 255, 255, 0.25);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.85%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
    width: 1.5em;
    height: 1.5em;
}

/* Mobile menu background */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background: rgba(0, 0, 0, 0.95);
        backdrop-filter: blur(10px);
        border-radius: 0.5rem;
        margin-top: 1rem;
        padding: 1rem;
        border: 1px solid rgba(255, 255, 255, 0.1);
    }
}

/* Syntax highlighting colors for black/white theme */
.hljs-keyword { color: #ffffff; }
.hljs-string { color: #cccccc; }
.hljs-number { color: #ffffff; }
.hljs-comment { color: #666666; }
.hljs-built_in { color: #ffffff; }

.navbar-brand {
    font-size: 1.5rem;
    font-weight: bold;
    color: white !important;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navbar-logo {
    width: 30px;
    height: 30px;
    object-fit: contain;
}

.footer-logo {
    width: 24px;
    height: 24px;
    object-fit: contain;
    display: inline-block;
    margin-right: 0.5rem;
}

.nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    margin: 0 1rem;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link::before {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 2px;
    background: white;
    transition: width 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover {
    color: white !important;
}

.nav-link:hover::before {
    width: 100%;
}

.btn-primary {
    background-color: transparent;
    border: 2px solid white;
    padding: 0.5rem 1.5rem;
    border-radius: 0.5rem;
    font-weight: 500;
    transition: all 0.3s ease;
    color: white;
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.2);
    background: linear-gradient(135deg, #333333 0%, #555555 50%, #333333 100%);
    color: white;
    border-color: white;
}

.btn-outline-primary {
    border: 2px solid white;
    color: white;
    background: transparent;
    padding: 0.5rem 1.5rem;
    border-radius: 0.5rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-outline-primary:hover {
    background: white;
    color: black;
    transform: translateY(-2px);
    border-color: white;
}

/* Optimized Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    text-align: center;
    position: relative;
    background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.03) 0%, transparent 50%);
}

.hero h1 {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #ffffff 0%, #cccccc 50%, #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: float 6s ease-in-out infinite;
}

.hero p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Optimized Feature Cards */
.feature-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    height: 100%;
    backdrop-filter: blur(5px);
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.feature-card i {
    font-size: 3rem;
    color: white;
    margin-bottom: 1rem;
}

.feature-card h5 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: white;
}

.feature-card p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

/* Optimized Statistics Cards */
.stat-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.stat-card i {
    font-size: 2.5rem;
    color: white;
    margin-bottom: 1rem;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
    margin-bottom: 0.5rem;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.stat-label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
}

/* Game Cards */
.game-card {
    max-width: 400px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s ease;
    height: 100%;
}

.game-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 255, 255, 0.3);
}

.game-card h6 {
    color: white;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.game-thumbnail {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    filter: grayscale(30%);
}

.game-thumbnail:hover {
    border-color: rgba(255, 255, 255, 0.4);
    filter: grayscale(0%);
}

.game-executions {
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
}

/* Chart Container */
.chart-container {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 2rem;
    backdrop-filter: blur(5px);
}

.chart-container canvas {
    width: 100% !important;
    height: 400px !important;
}

/* Request Form */
.request-form {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 2rem;
    backdrop-filter: blur(5px);
}

.form-control {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
    color: white;
    box-shadow: 0 0 0 0.25rem rgba(255, 255, 255, 0.1);
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.form-label {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

/* Footer */
.footer {
    background: rgba(0, 0, 0, 0.8);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 3rem 0 1rem 0;
    margin-top: 5rem;
}

.footer h5 {
    color: white;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.footer p {
    color: rgba(255, 255, 255, 0.7);
}

.footer .text-muted {
    color: rgba(255, 255, 255, 0.6) !important;
}

.footer a {
    color: rgba(255, 255, 255, 0.6);
    transition: all 0.3s ease;
    font-size: 1.2rem;
}

.footer a:hover {
    color: white;
    transform: scale(1.1);
}

.footer hr {
    border-color: rgba(255, 255, 255, 0.2) !important;
}

/* Modal */
.modal-content {
    background: #000000;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 1rem;
    backdrop-filter: blur(10px);
}

.modal-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.code-container {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    padding: 1rem;
    font-family: 'Fira Code', monospace;
    font-size: 0.85rem;
    height: 300px;
    overflow-y: auto;
    color: white;
}

/* Section spacing */
.section {
    padding: 5rem 0;
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: white;
}

.section-title p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.1rem;
}

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

.floating {
    animation: float 6s ease-in-out infinite;
}

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

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Responsive optimizations */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .feature-card {
        margin-bottom: 2rem;
    }

    .chart-container {
        padding: 1.5rem 1rem;
    }

    .chart-container canvas {
        height: 300px !important;
    }

    .nav-link {
        margin: 0.5rem 0;
    }

    .navbar-nav {
        text-align: center;
    }

    .d-flex.gap-2 {
        flex-direction: column;
        gap: 0.5rem !important;
        align-items: center;
        margin-top: 1rem;
    }
}

@media (max-width: 480px) {
    .chart-container {
        padding: 1rem 0.5rem;
    }

    .chart-container canvas {
        height: 250px !important;
    }

    .section-title h2 {
        font-size: 2rem;
    }

    .section-title p {
        font-size: 1rem;
    }
}

/* Performance optimizations */
* {
    will-change: auto;
}

.feature-card, .stat-card, .game-card {
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    .floating,
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
