/* --- Base & Variables --- */
:root {
    --bg-color: #050508;
    --bg-color-alt: #0a0a0f;
    --text-main: #f8f9fa;
    --text-muted: #a1a1aa;

    /* Striking Red derived from logo */
    --accent-red: #ff3c2d;
    --accent-red-hover: #ff574a;
    --accent-red-glow: rgba(255, 60, 45, 0.4);

    /* Subtle Gradients */
    --gradient-primary: linear-gradient(135deg, #ff3c2d, #ff822d);

    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);

    --font-heading: 'Chakra Petch', sans-serif;
    --font-body: 'Montserrat', sans-serif;

    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

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

body {
    font-family: var(--font-body);
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    /* To ensure content is above the canvas */
    z-index: 1;
}

/* --- Interactive Background Canvas --- */
#starCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    /* Place behind all content */
    pointer-events: none;
    /* Let clicks pass through */
}

/* --- Typography & Utilities --- */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: 8rem 0;
    position: relative;
    scroll-margin-top: 100px;
    /* Offset for fixed navigation header */
}

.accent-text {
    color: var(--accent-red);
}

.gradient-text {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.glass-panel {
    background: rgba(255, 255, 255, 0.01);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 12px;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
    border: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--accent-red);
    color: white;
    box-shadow: 0 4px 15px var(--accent-red-glow);
}

.btn-primary:hover {
    background: var(--accent-red-hover);
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 6px 20px rgba(255, 60, 45, 0.6);
}

.btn-secondary {
    background: var(--glass-bg);
    color: var(--text-main);
    border: 1px solid var(--glass-border);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--glass-border);
}

.btn-outline:hover {
    border-color: var(--accent-red);
    color: var(--accent-red);
}

/* --- Navigation --- */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 100;
    padding: 0.5rem 0;
    transition: var(--transition-smooth);
    background: transparent;
}

.navbar.scrolled {
    background: rgba(5, 5, 8, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
    padding: 1rem 0;
}

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

.logo-img {
    height: 144px;
    width: auto;
    border-radius: 8px;
    display: block;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-links a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: var(--transition-smooth);
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0%;
    height: 2px;
    background: var(--accent-red);
    transition: var(--transition-smooth);
}

.nav-links a:hover {
    color: var(--text-main);
}

.nav-links a:hover::after {
    width: 100%;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--text-main);
    transition: var(--transition-smooth);
}

/* --- Hero Section --- */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 6rem;
    background: radial-gradient(circle at 50% 30%, rgba(255, 60, 45, 0.08) 0%, transparent 50%);
}

.hero-content {
    max-width: 800px;
}

.hero-badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: rgba(255, 60, 45, 0.1);
    border: 1px solid rgba(255, 60, 45, 0.2);
    border-radius: 50px;
    color: var(--accent-red);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 0.1rem;
}

.hero-title {
    font-size: clamp(3rem, 6vw, 5rem);
    letter-spacing: -1.5px;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
    color: var(--text-muted);
    margin-bottom: 3rem;
    max-width: 650px;
    margin-inline: auto;
}

.hero-cta {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
}

/* --- Section Headers --- */
.section-header {
    text-align: center;
    margin-bottom: 5rem;
}

.section-title {
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    margin-bottom: 1rem;
}

.section-description {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

/* --- Games Section (Cygnus) --- */
.games-section {
    border-top: 1px solid var(--glass-border);
    border-bottom: 1px solid var(--glass-border);
    scroll-margin-top: 60px;
}

.game-showcase {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.game-content {
    padding-right: 2rem;
}

.game-tag {
    font-family: var(--font-heading);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.game-title {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, #fff, #a1a1aa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.game-desc {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.game-features {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.game-features li {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-main);
    font-weight: 500;
}

.accent-dot {
    width: 8px;
    height: 8px;
    background-color: var(--accent-red);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-red);
}

.game-art-container {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    aspect-ratio: 4/3;
    background: radial-gradient(circle at center, rgba(255, 60, 45, 0.08), transparent 70%);
}

.game-art-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    color: rgba(255, 255, 255, 0.4);
    font-family: var(--font-heading);
    letter-spacing: 2px;
}

/* --- Plugins Section --- */
.plugins-section {
    position: relative;
}

.plugin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.plugin-card {
    padding: 2rem 1.5rem;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
    overflow: hidden;
    border-radius: 16px;
}

.plugin-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(400px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(255, 255, 255, 0.04), transparent 50%);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.plugin-card:hover::before {
    opacity: 1;
}

.plugin-card:hover {
    transform: translateY(-4px);
}

.plugin-card:hover .plugin-icon {
    box-shadow: 0 0 20px rgba(255, 60, 45, 0.4);
    border-color: rgba(255, 60, 45, 0.4);
}

.plugin-icon-wrapper {
    margin-bottom: 2rem;
}

.plugin-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--accent-red);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.plugin-name {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.plugin-desc {
    color: var(--text-muted);
    margin-bottom: 2rem;
    flex-grow: 1;
}

.plugin-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--text-main);
    transition: var(--transition-smooth);
}

.plugin-link span {
    transition: transform 0.3s ease;
}

.plugin-link:hover {
    color: var(--accent-red);
}

.plugin-link:hover span {
    transform: translateX(5px);
}

/* --- Team Section --- */
.team-section {
    border-top: 1px solid var(--glass-border);
    margin-bottom: 4rem;
    /* Extra breathing room at absolute bottom */
}

.team-grid {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
    max-width: 900px;
    margin: 0 auto;
}

.team-member {
    text-align: center;
    padding: 0.5rem;
    transition: var(--transition-smooth);
    min-width: 220px;
}

.member-avatar {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    margin: 0 auto 0.75rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    border: 2px solid var(--glass-border);
    transition: var(--transition-smooth);
}

.team-member:hover {
    transform: translateY(-4px);
}

.team-member:hover .member-avatar {
    border-color: rgba(255, 255, 255, 0.25);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
}

.member-name {
    font-size: 1.15rem;
    margin-bottom: 0.25rem;
}

.member-role {
    color: var(--accent-red);
    font-size: 0.85rem;
    font-weight: 500;
}

/* --- Footer --- */
.footer {
    padding: 6rem 0 2rem;
    border-top: 1px solid var(--glass-border);
    background: linear-gradient(to bottom, transparent, rgba(255, 60, 45, 0.03));
}

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

.footer-brand p {
    color: var(--text-muted);
    margin-top: 1rem;
    max-width: 250px;
}

.footer-logo {
    height: 128px;
    width: auto;
    border-radius: 12px;
    display: block;
}

.footer-links-group h4 {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.footer-links-group a {
    display: block;
    color: var(--text-muted);
    margin-bottom: 0.8rem;
    transition: var(--transition-smooth);
}

.footer-links-group a:hover {
    color: var(--accent-red);
}

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

/* --- Utilities & Animations --- */
.reveal-up {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-up.active {
    opacity: 1;
    transform: translateY(0);
}


/* Responsive Design */
@media (max-width: 768px) {

    .nav-links {
        display: none;
    }

    .nav-links.active {
        display: flex;
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: rgba(5, 5, 8, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 3rem;
        z-index: 101;
    }

    .nav-links.active a {
        font-size: 1.5rem;
        color: var(--text-main);
    }

    .navbar .btn {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
        z-index: 100;
        position: relative;
    }

    .mobile-menu-btn.active span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }

    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-btn.active span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }

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

    .game-showcase {
        grid-template-columns: 1fr;
    }

    .game-content {
        padding-right: 0;
    }

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

    .team-grid {
        gap: 1.5rem;
    }

    .team-member {
        min-width: 140px;
    }
}