@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Space+Grotesk:wght@400;500;700&display=swap');

:root {
    /* Background Palette */
    --bg-primary: #030712;
    --bg-secondary: #0f172a;
    --bg-surface: #111827;
    --bg-deep: #071019;

    /* Accent Gradients */
    --grad-orange: linear-gradient(135deg, #f97316, #fb923c);
    --grad-cyan: linear-gradient(135deg, #06b6d4, #67e8f9);
    --grad-purple: linear-gradient(135deg, #7c3aed, #a78bfa);
    --grad-lime: linear-gradient(135deg, #84cc16, #bef264);
    --grad-premium: linear-gradient(135deg, #f97316, #06b6d4, #7c3aed);
    
    /* Solid Accents for borders/shadows */
    --acc-orange: #f97316;
    --acc-cyan: #06b6d4;
    --acc-purple: #7c3aed;

    /* Glow System */
    --glow-orange: rgba(249, 115, 22, 0.45);
    --glow-cyan: rgba(6, 182, 212, 0.45);
    --glow-purple: rgba(124, 58, 237, 0.40);
    --glow-lime: rgba(132, 204, 22, 0.35);

    /* Glassmorphism */
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-blur: 22px;

    /* Typography */
    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Inter', sans-serif;
    
    --text-primary: #ffffff;
    --text-secondary: #dbeafe;
    --text-muted: #94a3b8;

    /* Layout */
    --max-width: 1360px;
    --radius-sm: 12px;
    --radius-md: 20px;
    --radius-lg: 30px;
    --radius-xl: 34px;
    
    /* Spacing */
    --space-desk: 120px;
    --space-tab: 80px;
    --space-mob: 60px;

    /* Header height for offsets */
    --header-height: 90px;
}

/* =========================================
   RESET & BASE
   ========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(6, 182, 212, 0.05), transparent 25%),
        radial-gradient(circle at 85% 30%, rgba(124, 58, 237, 0.05), transparent 25%);
    background-attachment: fixed;
}

/* Typography Utilities */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.text-gradient-orange { background: var(--grad-orange); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.text-gradient-cyan { background: var(--grad-cyan); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.text-gradient-premium { background: var(--grad-premium); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

p { color: var(--text-secondary); margin-bottom: 1rem; }
a { color: var(--text-primary); text-decoration: none; transition: 0.3s ease; }
ul { list-style: none; }

/* Layout Utilities */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: var(--space-desk) 0;
    position: relative;
}

/* Glassmorphism Core Class */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

/* =========================================
   HEADER: FLOATING COMMAND BAR
   ========================================= */
.site-header {
    position: fixed;
    top: 20px;
    left: 0;
    width: 100%;
    z-index: 1000;
    display: flex;
    justify-content: center;
    padding: 0 24px;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-capsule {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1200px;
    height: 70px;
    padding: 0 24px;
    background: rgba(11, 16, 33, 0.6);
    backdrop-filter: blur(24px);
    border: 1px solid rgba(6, 182, 212, 0.2);
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), inset 0 0 0 1px rgba(255,255,255,0.05);
    position: relative;
    overflow: hidden;
}

/* Animated edge for nav capsule */
.nav-capsule::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; width: 100%; height: 1px;
    background: linear-gradient(90deg, transparent, var(--acc-cyan), transparent);
    animation: scanline 4s linear infinite;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.25rem;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.logo-icon {
    position: relative;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon .cube {
    width: 16px; height: 16px;
    background: var(--grad-cyan);
    transform: rotate(45deg);
    box-shadow: 0 0 15px var(--glow-cyan);
}

.logo-icon .ring {
    position: absolute;
    width: 32px; height: 32px;
    border: 1px dashed var(--acc-orange);
    border-radius: 50%;
    animation: rotate 10s linear infinite;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    padding: 8px 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; width: 0; height: 2px;
    background: var(--grad-cyan);
    transition: width 0.3s ease;
    box-shadow: 0 0 10px var(--glow-cyan);
}

.nav-links a:hover { color: #fff; }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }

.nav-actions {
    display: flex;
    gap: 16px;
    align-items: center;
}

/* Mobile Menu Toggle (Hidden on Desktop) */
.mobile-toggle {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    z-index: 1001;
}

.mobile-toggle span {
    display: block;
    width: 24px; height: 2px;
    background: var(--acc-cyan);
    transition: 0.3s;
}

/* =========================================
   BUTTON SYSTEM
   ========================================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: none;
}

.btn-primary {
    background: var(--grad-orange);
    color: #fff;
    box-shadow: 0 4px 15px var(--glow-orange);
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px var(--glow-orange);
}

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

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--acc-cyan);
    border: 1px solid var(--acc-cyan);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(6, 182, 212, 0.1);
    box-shadow: 0 0 15px var(--glow-cyan);
}

/* =========================================
   HERO SECTION: DIGITAL QUARRY
   ========================================= */
.hero-quarry {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding-top: var(--header-height);
    overflow: hidden;
}

/* Cinematic Background Layers */
.hero-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -2;
    background-image: url('images/photo-1614729939124-032f0b56c9ce.png');
    background-size: cover;
    background-position: center;
    filter: brightness(0.3) contrast(1.2);
}

/* Industrial abstract overlay */
.hero-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -1;
    background: linear-gradient(180deg, rgba(3,7,18,0.8) 0%, rgba(3,7,18,0.2) 50%, var(--bg-primary) 100%);
}

.grid-lines {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: 
        linear-gradient(rgba(6, 182, 212, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(6, 182, 212, 0.05) 1px, transparent 1px);
    background-size: 50px 50px;
    transform: perspective(500px) rotateX(60deg) translateY(-100px) scale(2);
    opacity: 0.5;
    z-index: -1;
    animation: gridMove 20s linear infinite;
}

.hero-content {
    text-align: center;
    max-width: 900px;
    position: relative;
    z-index: 1;
    padding: 40px;
}

.hero-tag {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(6, 182, 212, 0.1);
    border: 1px solid rgba(6, 182, 212, 0.3);
    border-radius: 30px;
    color: var(--acc-cyan);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 24px;
    box-shadow: 0 0 20px var(--glow-cyan);
}

.hero-title {
    font-size: clamp(3rem, 5vw, 5rem);
    margin-bottom: 24px;
    text-shadow: 0 0 30px rgba(255,255,255,0.1);
}

.hero-desc {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto 40px;
}

.hero-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 50px;
}

.legal-disclaimer-hero {
    background: rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.1);
    padding: 15px 30px;
    border-radius: var(--radius-sm);
    display: inline-block;
    backdrop-filter: blur(10px);
}

.legal-disclaimer-hero p {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.legal-disclaimer-hero span { color: var(--acc-orange); font-weight: bold; }

/* =========================================
   MAIN GAME SECTION (game-box-slot)
   ========================================= */
.game-section {
    padding: var(--space-desk) 0;
    position: relative;
    background: radial-gradient(circle at center, var(--bg-secondary) 0%, var(--bg-primary) 100%);
}

.game-terminal-wrapper {
    max-width: 1240px;
    margin: 0 auto;
    position: relative;
}

.game-terminal {
    background: #000;
    border-radius: var(--radius-xl);
    padding: 4px; /* Space for the glowing border */
    position: relative;
    box-shadow: 0 20px 60px rgba(0,0,0,0.8), 0 0 40px var(--glow-cyan);
    transition: transform 0.3s ease;
}

.game-terminal:hover {
    transform: scale(1.01);
    box-shadow: 0 30px 80px rgba(0,0,0,0.9), 0 0 60px var(--glow-orange);
}

/* Animated Industrial Neon Border */
.game-terminal::before {
    content: '';
    position: absolute;
    top: -2px; left: -2px; right: -2px; bottom: -2px;
    background: linear-gradient(45deg, var(--acc-cyan), transparent, var(--acc-orange), transparent);
    background-size: 400%;
    z-index: -1;
    border-radius: calc(var(--radius-xl) + 2px);
    animation: gradientBG 10s ease infinite;
    opacity: 0.8;
}

.game-screen {
    background: var(--bg-deep);
    border-radius: calc(var(--radius-xl) - 4px);
    overflow: hidden;
    position: relative;
    aspect-ratio: 16/9;
    border: 1px solid rgba(255,255,255,0.05);
}

.game-screen iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

/* Game Interface Details */
.game-hud-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px 20px;
}

.game-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.game-title::before {
    content: '';
    display: block;
    width: 12px; height: 12px;
    background: var(--acc-lime);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--glow-lime);
    animation: pulse 2s infinite;
}

.game-badges span {
    background: rgba(124, 58, 237, 0.15);
    border: 1px solid rgba(124, 58, 237, 0.3);
    color: #a78bfa;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.75rem;
    text-transform: uppercase;
    margin-left: 10px;
}

/* =========================================
   FEATURES: BENTO GRID
   ========================================= */
.features-section {
    padding: var(--space-desk) 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(2, 300px);
    gap: 24px;
}

.bento-item {
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.bento-item:hover {
    transform: translateY(-5px);
    border-color: rgba(255,255,255,0.2);
}

/* Asymmetrical Spanning */
.bento-item:nth-child(1) { grid-column: span 2; grid-row: span 2; background: linear-gradient(135deg, rgba(3,7,18,0.9), rgba(15,23,42,0.9)); }
.bento-item:nth-child(2) { grid-column: span 2; }
.bento-item:nth-child(3) { grid-column: span 1; }
.bento-item:nth-child(4) { grid-column: span 1; }

.bento-icon {
    width: 50px; height: 50px;
    background: rgba(255,255,255,0.05);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px;
    margin-bottom: 20px;
    border: 1px solid rgba(255,255,255,0.1);
}

.bento-item h3 { font-size: 1.5rem; margin-bottom: 10px; }
.bento-item p { font-size: 0.95rem; color: var(--text-muted); }

/* Bento Image Overlay */
.bento-img-bg {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover;
    z-index: -1;
    opacity: 0.15;
    transition: opacity 0.3s ease;
}
.bento-item:hover .bento-img-bg { opacity: 0.3; filter: grayscale(0) contrast(1.2); }

/* =========================================
   STATS DASHBOARD
   ========================================= */
.stats-dashboard {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    margin-top: 60px;
}

.stat-widget {
    background: rgba(11, 16, 33, 0.4);
    border: 1px solid rgba(6, 182, 212, 0.15);
    padding: 24px 40px;
    border-radius: var(--radius-md);
    text-align: center;
    min-width: 200px;
    position: relative;
    overflow: hidden;
}

.stat-widget::before {
    content: ''; position: absolute; top: 0; left: 0; width: 4px; height: 100%;
    background: var(--grad-cyan);
}
.stat-widget:nth-child(2)::before { background: var(--grad-orange); }
.stat-widget:nth-child(3)::before { background: var(--grad-purple); }

.stat-value {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
}

/* =========================================
   PAGES (Legal, About, Contact)
   ========================================= */
.page-header {
    padding: 180px 0 80px;
    text-align: center;
    background: linear-gradient(180deg, rgba(6,182,212,0.05) 0%, transparent 100%);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.page-header h1 { font-size: 3.5rem; margin-bottom: 16px; }

.content-container {
    max-width: 800px;
    margin: 0 auto;
}

.legal-content, .generic-content {
    padding: var(--space-desk) 0;
}

.legal-content h2 {
    font-size: 1.8rem;
    margin: 40px 0 20px;
    color: var(--acc-cyan);
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 10px;
}

.legal-content h3 { font-size: 1.3rem; margin: 20px 0 10px; color: #fff; }
.legal-content p, .legal-content ul { margin-bottom: 20px; color: var(--text-muted); }
.legal-content ul { list-style: disc inside; }
.legal-content li { margin-bottom: 8px; }

/* Contact Specific */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.contact-info-card { padding: 40px; }
.contact-info-card h3 { margin-bottom: 20px; font-size: 1.5rem; }
.info-item { margin-bottom: 20px; }
.info-item span { display: block; font-size: 0.8rem; color: var(--text-muted); text-transform: uppercase; margin-bottom: 4px;}
.info-item p { color: #fff; font-weight: 500; font-size: 1.1rem; margin:0;}

.contact-form { display: flex; flex-direction: column; gap: 20px; }
.form-group input, .form-group textarea {
    width: 100%; padding: 16px;
    background: rgba(0,0,0,0.3); border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px; color: #fff; font-family: var(--font-body);
}
.form-group input:focus, .form-group textarea:focus {
    outline: none; border-color: var(--acc-cyan); box-shadow: 0 0 10px var(--glow-cyan);
}

/* =========================================
   FOOTER
   ========================================= */
.site-footer {
    background: var(--bg-surface);
    border-top: 1px solid rgba(255,255,255,0.05);
    padding: 80px 0 40px;
    margin-top: 80px;
    position: relative;
    overflow: hidden;
}

.site-footer::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
}

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

.footer-brand p { color: var(--text-muted); margin-top: 20px; max-width: 300px; font-size: 0.95rem; }

.footer-col h4 {
    color: #fff; font-size: 1.1rem; margin-bottom: 24px; text-transform: uppercase; letter-spacing: 1px;
}

.footer-col ul li { margin-bottom: 12px; }
.footer-col ul li a { color: var(--text-muted); font-size: 0.95rem; }
.footer-col ul li a:hover { color: var(--acc-cyan); padding-left: 5px; }

.footer-disclaimer {
    background: rgba(0,0,0,0.4);
    padding: 24px;
    border-radius: var(--radius-sm);
    border: 1px dashed rgba(255,255,255,0.1);
    text-align: center;
    margin-bottom: 40px;
}

.footer-disclaimer p { margin: 0; font-size: 0.85rem; color: #94a3b8; }
.footer-disclaimer strong { color: var(--acc-orange); }

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.05);
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* =========================================
   ANIMATIONS
   ========================================= */
@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes scanline {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

@keyframes rotate {
    100% { transform: rotate(360deg); }
}

@keyframes pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(132, 204, 22, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(132, 204, 22, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(132, 204, 22, 0); }
}

@keyframes gridMove {
    0% { background-position: 0 0; }
    100% { background-position: 0 50px; }
}

/* =========================================
   RESPONSIVE DESIGN (MOBILE FIRST)
   ========================================= */
@media (max-width: 1024px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: auto;
    }
    .bento-item:nth-child(1) { grid-column: span 2; }
    .bento-item:nth-child(2) { grid-column: span 2; }
    .bento-item:nth-child(3), .bento-item:nth-child(4) { grid-column: span 1; }
    
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    :root {
        --space-desk: var(--space-mob);
    }
    
    /* Mobile Header */
    .nav-links, .nav-actions { display: none; }
    .mobile-toggle { display: flex; }
    .nav-capsule { border-radius: 0; top: 0; width: 100%; height: 60px; border-left: none; border-right:none;}
    .site-header { top: 0; padding: 0;}
    
    .hero-title { font-size: 2.5rem; }
    .hero-actions { flex-direction: column; }
    
    .bento-grid { grid-template-columns: 1fr; }
    .bento-item:nth-child(1), .bento-item:nth-child(2), .bento-item:nth-child(3), .bento-item:nth-child(4) { grid-column: span 1; }
    
    .contact-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; gap: 40px;}
    .footer-bottom { flex-direction: column; gap: 20px; text-align: center; }

    .game-terminal-wrapper { padding: 0 10px; }
    .game-hud-top { flex-direction: column; align-items: flex-start; gap: 10px; }
}