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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    line-height: 1.6;
    color: #EDEDED;
    background: linear-gradient(135deg, #1B1D2F 0%, #5F4B8B 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(27, 29, 47, 0.3);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #5F4B8B, #00FFD1);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #00FFD1, #5F4B8B);
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Syne', sans-serif;
    font-weight: 700;
    line-height: 1.2;
}

.gradient-text {
    background: linear-gradient(135deg, #00FFD1, #5F4B8B);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===== CONTAINER & LAYOUT ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 80px 0;
}

/* ===== PARTICLE BACKGROUND ===== */
.particle-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.particle {
    position: absolute;
    background: radial-gradient(circle, rgba(0, 255, 209, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.particle:nth-child(1) {
    width: 4px;
    height: 4px;
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.particle:nth-child(2) {
    width: 6px;
    height: 6px;
    top: 60%;
    left: 80%;
    animation-delay: -2s;
}

.particle:nth-child(3) {
    width: 3px;
    height: 3px;
    top: 40%;
    left: 20%;
    animation-delay: -4s;
}

.particle:nth-child(4) {
    width: 5px;
    height: 5px;
    top: 80%;
    left: 60%;
    animation-delay: -1s;
}

.particle:nth-child(5) {
    width: 2px;
    height: 2px;
    top: 15%;
    left: 70%;
    animation-delay: -3s;
}

.particle:nth-child(6) {
    width: 4px;
    height: 4px;
    top: 70%;
    left: 15%;
    animation-delay: -5s;
}

.particle:nth-child(7) {
    width: 3px;
    height: 3px;
    top: 35%;
    left: 85%;
    animation-delay: -2.5s;
}

.particle:nth-child(8) {
    width: 5px;
    height: 5px;
    top: 90%;
    left: 40%;
    animation-delay: -1.5s;
}

.particle:nth-child(9) {
    width: 2px;
    height: 2px;
    top: 25%;
    left: 50%;
    animation-delay: -3.5s;
}

.particle:nth-child(10) {
    width: 4px;
    height: 4px;
    top: 55%;
    left: 90%;
    animation-delay: -4.5s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.7;
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 1;
    }
}

/* ===== HEADER STYLES ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(27, 29, 47, 0.15);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 255, 209, 0.1);
    z-index: 1000;
    transition: all 0.3s ease;
}

.header.scrolled {
    background: rgba(27, 29, 47, 0.25);
    border-bottom: 1px solid rgba(0, 255, 209, 0.2);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo {
    font-family: 'Syne', sans-serif;
    font-size: 1.8rem;
    font-weight: 800;
    color: #00FFD1;
    text-decoration: none;
    text-shadow: 0 0 20px rgba(0, 255, 209, 0.5);
}

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

.nav-links a {
    color: #EDEDED;
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: all 0.3s ease;
}

.nav-links a:hover {
    color: #00FFD1;
    text-shadow: 0 0 10px rgba(0, 255, 209, 0.5);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #00FFD1, #5F4B8B);
    transition: width 0.3s ease;
}

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

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #EDEDED;
    font-size: 1.5rem;
    cursor: pointer;
}

/* ===== GLASS MORPHISM CARDS ===== */
.glass-card {
    background: rgba(27, 29, 47, 0.25);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
    transition: all 0.4s ease;
}

.glass-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 255, 209, 0.3);
    box-shadow: 0 35px 70px rgba(0, 0, 0, 0.3), 0 0 30px rgba(0, 255, 209, 0.1);
}

/* ===== HERO SECTION ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 80px;
    background: linear-gradient(to right, rgba(0, 0, 0, 0.9), rgba(0, 0, 0, 0.6)),
                url('/images/mainbg.webp') center/cover no-repeat;
     /* optional: ensures text is visible over background */
}


.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 20px;
    text-shadow: 0 0 30px rgba(0, 255, 209, 0.3);
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.9;
    max-width: 500px;
}

.cta-button {
    display: inline-block;
    background: linear-gradient(135deg, #5F4B8B, #00FFD1);
    color: #EDEDED;
    padding: 18px 40px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    position: relative;
    overflow: hidden;
    transition: all 0.4s ease;
    box-shadow: 0 10px 30px rgba(95, 75, 139, 0.4);
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 40px rgba(95, 75, 139, 0.6);
}

.button-shine {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s ease;
}

.cta-button:hover .button-shine {
    left: 100%;
}

.glow-effect {
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from {
        box-shadow: 0 10px 30px rgba(95, 75, 139, 0.4), 0 0 20px rgba(0, 255, 209, 0.2);
    }
    to {
        box-shadow: 0 20px 40px rgba(95, 75, 139, 0.6), 0 0 30px rgba(0, 255, 209, 0.4);
    }
}

.hero-visual {
    position: relative;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cosmic-orb {
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(0, 255, 209, 0.8), rgba(95, 75, 139, 0.6), transparent);
    border-radius: 50%;
    animation: pulse 3s ease-in-out infinite;
    position: relative;
}

.cosmic-rings {
    position: absolute;
    width: 300px;
    height: 300px;
    border: 2px solid rgba(0, 255, 209, 0.3);
    border-radius: 50%;
    animation: rotate 10s linear infinite;
    background-image: url("/images/StoryOfLove_AphroditesSpel.webp");
    background-size: cover;
}

.cosmic-rings::before,
.cosmic-rings::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(95, 75, 139, 0.3);
}

.cosmic-rings::before {
    width: 150%;
    height: 150%;
    top: -25%;
    left: -25%;
    animation: rotate 15s linear infinite reverse;
}

.cosmic-rings::after {
    width: 80%;
    height: 80%;
    top: 10%;
    left: 10%;
    animation: rotate 8s linear infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.1);
        opacity: 1;
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* ===== SECTION TITLES ===== */
.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #00FFD1, #5F4B8B);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-description {
    text-align: center;
    font-size: 1.1rem;
    margin-bottom: 60px;
    opacity: 0.9;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ===== ABOUT SECTION ===== */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-item {
    text-align: center;
    padding: 20px;
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 15px;
    filter: drop-shadow(0 0 10px rgba(0, 255, 209, 0.5));
}

.feature-item h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: #00FFD1;
}

.feature-item p {
    opacity: 0.8;
}

/* ===== GAMES SECTION ===== */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.game-card {
    background: rgba(27, 29, 47, 0.3);
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s ease;
    position: relative;
}

.game-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: rgba(0, 255, 209, 0.5);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4), 0 0 40px rgba(0, 255, 209, 0.2);
}

.game-image {
    position: relative;
    height: 280px;
    overflow: hidden;
}

.game-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.game-card:hover .game-image img {
    transform: scale(1.1);
}

.game-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(95, 75, 139, 0.7), rgba(0, 255, 209, 0.3));
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.4s ease;
}

.game-card:hover .game-overlay {
    opacity: 1;
}

.play-icon {
    font-size: 3rem;
    color: #EDEDED;
    text-shadow: 0 0 20px rgba(0, 255, 209, 0.8);
}

.game-info {
    padding: 25px;
}

.game-info h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: #00FFD1;
}

.game-info p {
    opacity: 0.8;
    margin-bottom: 15px;
}

.game-tags {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.tag {
    background: rgba(0, 255, 209, 0.2);
    color: #00FFD1;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid rgba(0, 255, 209, 0.3);
}

/* ===== UNIVERSES SECTION ===== */
.universes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.universe-card {
    overflow: hidden;
    text-align: center;
}

.universe-image {
    height: 200px;
    overflow: hidden;
    border-radius: 15px;
    margin-bottom: 20px;
}

.universe-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.universe-card:hover .universe-image img {
    transform: scale(1.1);
}

.universe-content h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: #00FFD1;
}

.universe-content p {
    opacity: 0.8;
}

/* ===== COMMUNITY SECTION ===== */
.community-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.stat-item {
    text-align: center;
    padding: 20px;
    background: rgba(0, 255, 209, 0.1);
    border-radius: 15px;
    border: 1px solid rgba(0, 255, 209, 0.2);
}

.stat-number {
    font-family: 'Syne', sans-serif;
    font-size: 2.5rem;
    font-weight: 800;
    color: #00FFD1;
    text-shadow: 0 0 15px rgba(0, 255, 209, 0.5);
}

.stat-label {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-top: 5px;
}

/* ===== DISCLAIMER SECTION ===== */
.disclaimer {
    padding: 60px 0;
}

.disclaimer-card {
    text-align: center;
    background: rgba(95, 75, 139, 0.2);
    border: 1px solid rgba(95, 75, 139, 0.3);
}

.disclaimer-card h3 {
    font-size: 1.6rem;
    margin-bottom: 20px;
    color: #00FFD1;
}

.disclaimer-card p {
    font-size: 1rem;
    opacity: 0.9;
    max-width: 800px;
    margin: 0 auto 30px;
}

.disclaimer-icons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.disclaimer-icons .icon {
    font-size: 2rem;
    filter: drop-shadow(0 0 10px rgba(0, 255, 209, 0.3));
}

/* ===== FOOTER STYLES ===== */
.footer {
    background: rgba(27, 29, 47, 0.8);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(0, 255, 209, 0.1);
    padding: 40px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 30px;
}

.footer-section h3 {
    font-size: 1.4rem;
    margin-bottom: 20px;
    color: #00FFD1;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: #EDEDED;
    text-decoration: none;
    opacity: 0.8;
    transition: all 0.3s ease;
}

.footer-section ul li a:hover {
    color: #00FFD1;
    opacity: 1;
    text-shadow: 0 0 10px rgba(0, 255, 209, 0.3);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    opacity: 0.7;
    font-size: 0.9rem;
}

/* ===== GAME PAGE STYLES ===== */
.game-page {
    min-height: 100vh;
    padding-top: 80px;
}

.game-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

.game-header {
    text-align: center;
    margin-bottom: 30px;
}

.game-title {
    font-size: 2.5rem;
    margin-bottom: 10px;
    background: linear-gradient(135deg, #00FFD1, #5F4B8B);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.game-description {
    font-size: 1.1rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto 20px;
}

.back-button {
    display: inline-block;
    background: rgba(27, 29, 47, 0.5);
    color: #00FFD1;
    padding: 12px 25px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    border: 1px solid rgba(0, 255, 209, 0.3);
    transition: all 0.3s ease;
    margin-bottom: 30px;
}

.back-button:hover {
    background: rgba(0, 255, 209, 0.1);
    border-color: rgba(0, 255, 209, 0.5);
    transform: translateY(-2px);
}

.game-frame {
    width: 100%;
    height: 80vh;
    min-height: 600px;
    border: none;
    border-radius: 15px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    background: #000;
}

/* ===== ANIMATIONS ===== */
.fade-in {
    animation: fadeIn 1s ease-out;
}

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

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1024px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .games-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
    
    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .games-grid {
        grid-template-columns: 1fr;
    }
    
    .glass-card {
        padding: 25px;
    }
    
    section {
        padding: 60px 0;
    }
    
    .feature-grid {
        grid-template-columns: 1fr;
    }
    
    .community-stats {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .glass-card {
        padding: 20px;
    }
    
    .cta-button {
        padding: 15px 30px;
        font-size: 1rem;
    }
    
    .cosmic-orb {
        width: 150px;
        height: 150px;
    }
    
    .cosmic-rings {
        width: 200px;
        height: 200px;
    }
}

/* ===== LOADING ANIMATIONS ===== */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0, 255, 209, 0.3);
    border-radius: 50%;
    border-top-color: #00FFD1;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus styles for keyboard navigation */
a:focus,
button:focus {
    outline: 2px solid #00FFD1;
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .glass-card {
        border-color: #00FFD1;
        background: rgba(27, 29, 47, 0.9);
    }
    
    .nav-links a {
        color: #FFFFFF;
    }
    
    .nav-links a:hover {
        color: #00FFD1;
    }
}