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

:root {
    --bg-deep: #020205;
    --accent-blue: #00d4ff;
    --accent-purple: #9d50bb;
    --discord-blurple: #5865F2;
    --glass: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.1);
}

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

body {
    background-color: var(--bg-deep);
    color: #ffffff;
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Base Void Layer */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, #080812 0%, var(--bg-deep) 100%);
    z-index: -2;
}

/* --- THE REVEAL WRAPPER --- */
#main-site-content {
    opacity: 0;
    visibility: hidden;
    transition: opacity 3s ease-in-out;
}

#main-site-content.is-visible {
    opacity: 1;
    visibility: visible;
}

/* Glass Navbar */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(5, 5, 10, 0.8);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--glass-border);
    padding: 1rem 5%;
}

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

.logo-link {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.logo-icon,
.logo-text {
    transition: filter 0.3s;
    filter: invert(1);
}

.logo-icon {
    height: 55px;
}

.logo-text {
    height: 26px;
}

.logo-link:hover .logo-icon,
.logo-link:hover .logo-text {
    filter: invert(1) drop-shadow(0 0 10px var(--accent-blue));
}

nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

nav ul a {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.85rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: 0.3s;
    opacity: 0.6;
}

nav ul a:hover,
nav ul a.active {
    opacity: 1;
    color: var(--accent-blue);
    text-shadow: 0 0 10px var(--accent-blue);
}

/* STARFIELD CONTAINER - ELEVATED DURING INTRO */
.top-bg-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 200vh;
    z-index: 5;
    /* Initially above content so stars show through splash */
    pointer-events: none;
    -webkit-mask-image: linear-gradient(to bottom, black 50%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 50%, transparent 100%);
}

#starfield {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.nebula-glow {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(157, 80, 187, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 80% 40%, rgba(0, 212, 255, 0.12) 0%, transparent 40%);
    filter: blur(80px);
    animation: nebulaShift 20s ease-in-out infinite alternate;
}

@keyframes nebulaShift {
    0% {
        transform: scale(1) translate(0, 0);
    }

    100% {
        transform: scale(1.1) translate(30px, -30px);
    }
}

/* --- HERO SECTION --- */
.hero {
    position: relative;
    width: 100%;
    min-height: 60vh;
    margin: 100px auto 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 40px 20px;
    z-index: 2;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.hero-icon {
    height: 400px;
    margin-bottom: -75px;
    filter: invert(1) drop-shadow(0 0 40px rgba(0, 212, 255, 0.5));
    animation: floatIcon 6s ease-in-out infinite;
}

@keyframes floatIcon {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-30px);
    }
}

.hero-logo {
    height: 90px;
    margin-bottom: 100px;
    filter: invert(1) drop-shadow(0 0 25px var(--accent-blue));
}

.hero-headline {
    font-size: clamp(0.85rem, 2.5vw, 1.5rem);
    font-weight: 400;
    letter-spacing: 2px;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.8);
    max-width: 100vw;
    width: 1000px;
    margin: 0 auto;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 1);
    text-wrap: balance;
    /* 2-LINE LIMIT AS REQUESTED */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* MOBILE OPTIMIZATION */
@media (max-width: 768px) {
    .hero {
        margin-top: 80px;
    }

    .hero-icon {
        height: 300px;
        margin-bottom: -60px;
    }

    .hero-logo {
        height: 65px;
        margin-bottom: 80px;
    }

    .hero-headline {
        width: 100%;
        line-height: 1.5;
        letter-spacing: 1px;
    }
}

.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 20px;
}

/* --- Balanced Ribbon Spacing --- */
.logo-ribbon {
    width: 100%;
    /* Increased to 60px on top/bottom to allow for 1.2x expansion room */
    padding: 60px 0;
    overflow: hidden;
    position: relative;
    -webkit-mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
    mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
}

.ribbon-track {
    display: flex;
    width: max-content;
    animation: scroll-ribbon 40s linear infinite;
    /* Forces the GPU to handle rendering, preventing "merging" glitches */
    transform: translateZ(0);
    will-change: transform;
}

/* Removed hover pause to keep the energy constant */

.ribbon-set {
    display: flex;
    gap: 40px;
    padding-right: 40px;
}

.ribbon-window {
    position: relative;
    height: 240px;
    width: auto;
    flex-shrink: 0;
    /* Ensures capsules never squash or touch neighbors */
    padding: 4px;
    border-radius: 24px;
    background: linear-gradient(var(--bg-deep), var(--bg-deep)) padding-box,
        linear-gradient(45deg, var(--accent-purple), var(--accent-blue)) border-box;
    border: 2px solid transparent;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s;
    z-index: 1;
}

/* Hover expansion effect */
.ribbon-window:hover {
    transform: scale(1.2);
    /* Stronger expansion as requested */
    z-index: 50;
    /* Ensure expanded item stays on top of neighbors */
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.4);
    background: linear-gradient(var(--bg-deep), var(--bg-deep)) padding-box,
        linear-gradient(45deg, var(--accent-blue), #fff) border-box;
}

.ribbon-window img {
    height: 100%;
    width: auto;
    object-fit: contain;
    border-radius: 18px;
    /* Slightly tighter radius than the window */
    display: block;
}

@keyframes scroll-ribbon {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* --- Balanced Discord Hub Spacing --- */
.discord-hub {
    position: relative;
    text-align: center;
    background: transparent;
    border-radius: 100px;
    padding: 20px 40px 50px;
    /* Margin increased to 40px for a clean gap between sections */
    margin: 40px auto 60px;
    max-width: 900px;
    width: 90%;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9);
    z-index: 10;
    clip-path: inset(0 round 100px);
    isolation: isolate;
    will-change: transform;
    transition: transform 0.2s ease-out;
    transform-style: preserve-3d;
}

/* LAYER 1: The Rotating Border Beam */
.discord-hub::before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(transparent,
            var(--accent-blue),
            var(--accent-purple),
            transparent 40%);
    animation: rotateBeam 4s linear infinite;
    z-index: -3;
}

/* LAYER 2: The Solid Shield - Lightened from #05050a to #0d0d1a */
.discord-hub::after {
    content: "";
    position: absolute;
    inset: 2px;
    background: #0d0d1a;
    /* Ever so slightly lighter and more "Adept Purple" tinted */
    border-radius: 98px;
    z-index: -2;
}

/* LAYER 3: The Bubble Layer */
.bubble-container {
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: 100px;
    overflow: hidden;
    filter: blur(25px);
}

.bubble {
    position: absolute;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    opacity: 0.8;
    animation: floatBubbles 15s infinite ease-in-out;
}

/* Vibrant Bubble Colors */
.bubble:nth-child(1) {
    top: -10%;
    left: 5%;
    background: radial-gradient(circle, var(--accent-purple) 0%, transparent 70%);
}

.bubble:nth-child(2) {
    bottom: -10%;
    right: 5%;
    background: radial-gradient(circle, var(--accent-blue) 0%, transparent 70%);
    animation-delay: -5s;
}

.bubble:nth-child(3) {
    top: 30%;
    left: 40%;
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, var(--accent-purple) 0%, transparent 70%);
    animation-delay: -2s;
}

.bubble:nth-child(4) {
    bottom: 10%;
    left: 10%;
    background: radial-gradient(circle, var(--accent-blue) 0%, transparent 70%);
    animation-delay: -10s;
}

/* --- ANIMATIONS --- */
@keyframes rotateBeam {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes floatBubbles {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(50px, -70px) scale(1.15);
    }

    66% {
        transform: translate(-40px, 40px) scale(0.85);
    }
}

/* Adjusted Icon Spacing - Closer to text */
.discord-icon {
    width: 110px;
    /* Slightly smaller to fit the tighter gap */
    margin-top: 5px;
    margin-bottom: -15px;
    /* Pulls the headline even closer */
    filter: drop-shadow(0 0 15px var(--discord-blurple));
    animation: discordBob 3s ease-in-out infinite;
    position: relative;
    z-index: 2;
}

/* Discord Live Members Grid */
.discord-members {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-top: 25px;
    margin-bottom: 10px;
    max-height: 140px;
    /* Keeps the capsule from getting too tall */
    overflow-y: auto;
    /* Adds a scrollbar if needed */
    padding: 10px;
    scrollbar-width: thin;
    scrollbar-color: var(--discord-blurple) transparent;
}

/* Custom Scrollbar for the Members Area */
.discord-members::-webkit-scrollbar {
    width: 6px;
}

.discord-members::-webkit-scrollbar-thumb {
    background: var(--discord-blurple);
    border-radius: 10px;
}

/* Avatar Containers and Hover Animation */
.discord-avatar-container {
    position: relative;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    transition: transform 0.2s ease, filter 0.2s ease;
    cursor: pointer;
}

.discord-avatar-container:hover {
    transform: scale(1.15);
    z-index: 2;
    filter: drop-shadow(0 0 8px rgba(88, 101, 242, 0.8));
}

.discord-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid var(--bg-deep);
    background-color: #36393f;
    /* Discord's dark gray fallback */
    object-fit: cover;
}

/* Online/Idle/DND Status Dots */
.discord-status {
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 3px solid var(--bg-deep);
    /* Creates a cutout effect */
}

.status-online {
    background-color: #23a559;
}

.status-idle {
    background-color: #f0b232;
}

.status-dnd {
    background-color: #f23f43;
}



@keyframes discordBob {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

h2 {
    font-size: 2.5rem;
    font-weight: 900;
    margin-bottom: 20px;
    text-align: center;
    background: linear-gradient(to right, #fff, var(--accent-blue));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Cards */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.card {
    background: var(--glass);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    padding: 40px;
    border-radius: 24px;
    transition: 0.4s ease;
    display: flex;
    flex-direction: column;
}

.card:hover {
    border-color: var(--accent-blue);
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.06);
}

/* New CSS to align logos in the top right */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
}

.project-logo {
    height: 60px;
    max-width: 120px;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.card p {
    flex-grow: 1;
    margin-bottom: 25px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 16px 36px;
    /* Increased padding for a larger button */
    background: linear-gradient(45deg, var(--accent-purple), var(--accent-blue));
    color: #fff;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
    /* Increased font size */
    letter-spacing: 1.5px;
    transition: 0.3s;
    border: none;
    text-align: center;
    align-self: center;
    /* Centers the button inside the card */
}

.btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.4);
}

.discord-btn {
    background: var(--discord-blurple);
}

.discord-btn:hover {
    box-shadow: 0 0 20px rgba(88, 101, 242, 0.4);
}

.btn-group {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: nowrap;
    /* Keeps them side-by-side */
    justify-content: center;
    /* Centers the group of buttons inside the card */
    width: 100%;
    /* Ensures the container spans full width to center properly */
}

/* Store Badges */
.store-badge-link {
    display: inline-block;
    transition: transform 0.3s ease, filter 0.3s ease;
    align-self: center;
    /* Centers the standalone Steam badge */
}

.store-badge {
    height: 52px;
    /* Increased from 44px to make the badges larger */
    width: auto;
    max-width: 100%;
    object-fit: contain;
    display: block;
}

.store-badge-link:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 0 15px rgba(0, 212, 255, 0.6));
}

/* Footer */
footer {
    padding: 60px 5%;
    background: #020205;
    text-align: center;
    border-top: 1px solid var(--glass-border);
}

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

.socials a {
    color: #aaa;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 2px;
    transition: 0.3s;
}

.socials a:hover {
    color: var(--accent-blue);
}

.copy {
    color: #666;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

/* Hamburger Menu & Mobile Navigation */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 6px;
    z-index: 1001;
}

.hamburger span {
    width: 30px;
    height: 3px;
    background-color: #fff;
    border-radius: 3px;
    transition: all 0.3s ease;
}

@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    nav ul {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(5, 5, 10, 0.95);
        backdrop-filter: blur(15px);
        flex-direction: column;
        align-items: center;
        gap: 0;
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: all 0.3s ease-in-out;
    }

    nav ul.show {
        max-height: 300px;
        /* Expands the menu smoothly */
        padding: 20px 0;
        border-bottom: 1px solid var(--glass-border);
    }

    nav ul li {
        margin: 15px 0;
    }

    /* Animate Hamburger into an X */
    .hamburger.toggle span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }

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

    .hamburger.toggle span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }
}

/* --- SMOKED GLASS SPLASH SCREEN --- */
#splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    /* Smoked Glass lets stars peek through but not site content */
    background-color: rgba(2, 2, 5, 0.85);
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 4s ease-out, visibility 4s ease-out;
}

#splash-screen.fade-out {
    opacity: 0;
    visibility: hidden;
}

#intro-media {
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.3s ease-in;
}

#intro-media.is-playing {
    opacity: 1;
}

#enter-site-btn {
    position: absolute;
    z-index: 10000;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 20px;
    font-size: 0.9rem;
    font-weight: 300;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
    background: transparent;
    border: none;
    cursor: pointer;
    transition: color 0.2s ease;
}

#enter-site-btn .play-icon {
    width: 14px;
    height: 14px;
    fill: rgba(255, 255, 255, 0.5);
}

#enter-site-btn:hover {
    color: rgba(255, 255, 255, 0.9);
}

#enter-site-btn:hover .play-icon {
    fill: var(--accent-blue);
    transform: scale(1.1);
}