/* ===== Custom Properties ===== */
:root {
    --primary-color: #00bfff;
    --secondary-color: #00aaff;
    --background-color: #1a1a2e;
    --card-bg: rgba(22, 33, 62, 0.85);
    --font-color: #e0e0e0;
    --muted-color: #8892a4;
    --nav-height: 64px;
    --border-radius: 10px;
    --transition: 0.3s ease;
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Courier New', Courier, monospace;
    color: var(--font-color);
    line-height: 1.6;
    background-color: var(--background-color);
    background-image: url('images/background.webp');
    background-repeat: repeat;
    overflow-x: hidden;
}

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

a:hover {
    color: var(--secondary-color);
}

img {
    max-width: 100%;
    height: auto;
}

/* ===== Navigation ===== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(10, 10, 20, 0.92);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 191, 255, 0.15);
    height: var(--nav-height);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.nav-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.nav-logo-img {
    height: 100px;
    width: auto;
}

.nav-logo-text {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.95rem;
    font-weight: 600;
    color: #9ca3af;
}

.nav-logo-brand {
    color: #00bfff;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    color: var(--font-color);
    font-size: 0.95rem;
    font-weight: 600;
    padding: 0.5rem 0;
    position: relative;
    transition: color var(--transition);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width var(--transition);
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* Mobile nav toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--font-color);
    transition: var(--transition);
}

.nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== Hero Section ===== */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: calc(var(--nav-height) + 2rem) 1.5rem 4rem;
    position: relative;
}

.hero-content {
    max-width: 800px;
    background: rgba(10, 10, 20, 0.65);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(0, 191, 255, 0.12);
    border-radius: 16px;
    padding: 3rem 2.5rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
}

.hero-logo {
    max-width: 300px;
    margin-bottom: 2rem;
    animation: fadeInDown 0.8s ease-out;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--muted-color);
    margin-bottom: 2rem;
    animation: fadeInUp 0.8s ease-out 0.4s both;
}

.hero-scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: var(--muted-color);
    font-size: 0.85rem;
    animation: bounce 2s infinite;
}

.scroll-arrow {
    width: 20px;
    height: 20px;
    border-right: 2px solid var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
    transform: rotate(45deg);
    margin: 0.5rem auto 0;
}

/* ===== Sections ===== */
.section {
    padding: 5rem 1.5rem;
}

.section-alt {
    background: rgba(0, 0, 0, 0.25);
}

.section-title {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.section-subtitle {
    text-align: center;
    color: var(--muted-color);
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    /* Floating panel wrapper for all sections */
    background: rgba(10, 10, 20, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(0, 191, 255, 0.1);
    border-radius: 16px;
    padding: 3rem 2.5rem;
    margin-top: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

/* ===== About ===== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.about-text p {
    margin-bottom: 1.2rem;
    font-size: 1.05rem;
    color: var(--font-color);
}

.about-stats {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.stat-card {
    background: var(--card-bg);
    border: 1px solid rgba(0, 191, 255, 0.15);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    text-align: center;
    transition: transform var(--transition), border-color var(--transition);
}

.stat-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary-color);
}

.stat-number {
    display: block;
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.3rem;
}

.stat-label {
    font-size: 0.95rem;
    color: var(--muted-color);
}

/* ===== Video Grid ===== */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.video-card {
    background: var(--card-bg);
    border: 1px solid rgba(0, 191, 255, 0.1);
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: transform var(--transition), border-color var(--transition);
}

.video-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary-color);
}

.video-placeholder {
    aspect-ratio: 16 / 9;
    background: linear-gradient(135deg, #0a0a2e, #1a1a3e);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.video-placeholder::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(0, 191, 255, 0.1), transparent 70%);
}

.play-icon {
    font-size: 3rem;
    color: var(--primary-color);
    opacity: 0.7;
    transition: opacity var(--transition);
}

.video-card:hover .play-icon {
    opacity: 1;
}

.video-title {
    padding: 1rem 1.2rem 0.3rem;
    font-size: 1.1rem;
    color: var(--font-color);
}

.video-desc {
    padding: 0 1.2rem 1rem;
    font-size: 0.9rem;
    color: var(--muted-color);
}

/* ===== Projects Grid ===== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
}

.project-card {
    background: var(--card-bg);
    border: 1px solid rgba(0, 191, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 2rem;
    text-align: center;
    transition: transform var(--transition), border-color var(--transition);
}

.project-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary-color);
}

.project-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.project-title {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 0.8rem;
}

.project-desc {
    font-size: 0.95rem;
    color: var(--muted-color);
    line-height: 1.5;
}

/* ===== Contact ===== */
.contact-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.contact-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    background: var(--card-bg);
    border: 1px solid rgba(0, 191, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 2rem 1.5rem;
    color: var(--font-color);
    transition: transform var(--transition), border-color var(--transition), color var(--transition);
}

.contact-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.contact-icon {
    font-size: 2rem;
}

.contact-label {
    font-size: 1rem;
    font-weight: 600;
}

.newsletter-placeholder {
    text-align: center;
    background: var(--card-bg);
    border: 1px dashed rgba(0, 191, 255, 0.3);
    border-radius: var(--border-radius);
    padding: 2rem;
}

.newsletter-placeholder h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.newsletter-placeholder p {
    color: var(--muted-color);
    font-size: 0.95rem;
}

/* ===== Buttons ===== */
.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: 6px;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition);
    border: 2px solid transparent;
}

.btn-primary {
    background: var(--primary-color);
    color: #0a0a14;
}

.btn-primary:hover {
    background: var(--secondary-color);
    color: #0a0a14;
    transform: translateY(-2px);
}

.btn-outline {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: #0a0a14;
}

.btn-small {
    display: inline-block;
    padding: 0.5rem 1.2rem;
    font-size: 0.85rem;
    border-color: var(--primary-color);
    color: var(--primary-color);
    border-radius: 6px;
    border: 1px solid;
    margin: 0 1.2rem 1.2rem;
    transition: all var(--transition);
}

.btn-small:hover {
    background: var(--primary-color);
    color: #0a0a14;
}

.section-cta {
    text-align: center;
}

/* ===== Footer ===== */
.footer {
    background: rgba(0, 0, 0, 0.4);
    border-top: 1px solid rgba(0, 191, 255, 0.1);
    padding: 2rem 1.5rem;
    text-align: center;
    color: var(--muted-color);
    font-size: 0.9rem;
}

.footer-disclaimer {
    margin-top: 0.5rem;
    font-size: 0.8rem;
    opacity: 0.6;
}

/* ===== Animations ===== */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-10px);
    }
    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

/* ===== Games Page ===== */
.games-header {
    padding: calc(var(--nav-height) + 3rem) 1.5rem 2rem;
    text-align: center;
    background: rgba(0, 0, 0, 0.3);
}

.games-title {
    font-size: 2.2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.games-subtitle {
    color: var(--muted-color);
    font-size: 1.1rem;
}

.games-section {
    padding: 3rem 1.5rem 5rem;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.game-panel {
    display: block;
    background: var(--card-bg);
    border: 1px solid rgba(0, 191, 255, 0.1);
    border-radius: var(--border-radius);
    overflow: hidden;
    text-decoration: none;
    color: var(--font-color);
    transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.game-panel:hover {
    transform: translateY(-6px) scale(1.02);
    border-color: var(--primary-color);
    box-shadow: 0 8px 30px rgba(0, 191, 255, 0.15);
}

.game-screenshot {
    aspect-ratio: 16 / 9;
    background: linear-gradient(135deg, #0a0a2e, #1a1a3e);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

.game-screenshot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity var(--transition);
}

.screenshot-placeholder {
    color: var(--muted-color);
    font-size: 0.85rem;
    opacity: 0.5;
}

.game-info {
    padding: 1rem;
}

.game-title {
    font-size: 1rem;
    color: var(--primary-color);
    margin-bottom: 0.3rem;
}

.game-desc {
    font-size: 0.85rem;
    color: var(--muted-color);
    line-height: 1.4;
}

/* Games responsive */
@media (max-width: 1024px) {
    .games-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .games-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .games-title {
        font-size: 1.8rem;
    }
}

@media (max-width: 480px) {
    .games-grid {
        grid-template-columns: 1fr;
    }

    .games-title {
        font-size: 1.5rem;
    }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: var(--nav-height);
        left: 0;
        right: 0;
        background: rgba(10, 10, 20, 0.97);
        flex-direction: column;
        align-items: center;
        gap: 0;
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease, padding 0.4s ease;
    }

    .nav-links.active {
        max-height: 300px;
        padding: 1rem 0;
    }

    .nav-links li {
        width: 100%;
        text-align: center;
    }

    .nav-link {
        display: block;
        padding: 1rem 1.5rem;
    }

    .nav-link::after {
        display: none;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .hero-logo {
        max-width: 200px;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }

    .video-grid {
        grid-template-columns: 1fr;
    }

    .section {
        padding: 3rem 1rem;
    }

    .section-title {
        font-size: 1.6rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.5rem;
    }

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

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .contact-links {
        grid-template-columns: 1fr 1fr;
    }
}
