/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #8B5CF6;
    --primary-dark: #7C3AED;
    --primary-light: #A78BFA;
    --secondary-color: #EC4899;
    --accent-color: #3B82F6;
    --bg-dark: #0A0A0F;
    --bg-darker: #050508;
    --bg-card: #111118;
    --text-primary: #FFFFFF;
    --text-secondary: #A0A0B0;
    --text-muted: #6B6B7A;
    --border-color: #1F1F2E;
    --gradient-1: linear-gradient(135deg, #8B5CF6 0%, #EC4899 100%);
    --gradient-2: linear-gradient(135deg, #3B82F6 0%, #8B5CF6 100%);
    --gradient-hero: linear-gradient(135deg, rgba(139, 92, 246, 0.1) 0%, rgba(236, 72, 153, 0.1) 100%);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

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

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    padding: 12px 0;
    transition: all 0.3s ease;
}

.navbar.scrolled {
    background: rgba(10, 10, 15, 0.95);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

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

.logo-img {
    height: 40px;
    width: auto;
    display: block;
}

.logo-text {
    font-size: 24px;
    font-weight: 800;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    transition: color 0.3s ease;
    position: relative;
}

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

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-1);
    transition: width 0.3s ease;
}

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

.community-link {
    padding: 8px 20px;
    background: var(--gradient-1);
    border-radius: 8px;
    color: white !important;
}

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

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 0 20px;
    overflow: hidden;
}

.hero .container {
    position: relative;
    z-index: 2;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-hero);
    opacity: 0.5;
    z-index: -1;
}

.hero-background::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.1) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
}

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

.hero-content {
    text-align: center;
    z-index: 2;
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: clamp(48px, 8vw, 96px);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.title-line {
    display: block;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: fadeInUp 0.8s ease-out;
}

.title-line:nth-child(2) {
    animation-delay: 0.2s;
    animation-fill-mode: both;
}

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

.hero-subtitle {
    font-size: clamp(18px, 2.5vw, 24px);
    color: var(--text-secondary);
    margin-bottom: 48px;
    font-weight: 400;
    animation: fadeInUp 0.8s ease-out 0.4s both;
}

.hero-cta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 64px;
    animation: fadeInUp 0.8s ease-out 0.6s both;
}

.hero-cta-icon {
    font-size: 22px;
}

/* Generic home/exit button used on game pages */
.exit-home-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 8px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.exit-home-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.exit-home-btn svg {
    width: 100%;
    height: 100%;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 32px;
    font-size: 18px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-family: inherit;
}

.btn-primary {
    background: var(--gradient-1);
    color: white;
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(139, 92, 246, 0.5);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #F59E0B;
    border: 2px solid rgba(245, 158, 11, 0.3);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(245, 158, 11, 0.5);
    color: #FBBF24;
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
}

.btn-large {
    padding: 20px 48px;
    font-size: 20px;
}

.btn svg {
    transition: transform 0.3s ease;
}

.btn:hover svg {
    transform: translateX(4px);
}

/* Casino page */

.casino-page {
    background: var(--bg-dark);
    color: var(--text-primary);
}

.casino-main {
    padding-top: 0;
    padding-bottom: 0;
}

.casino-hero {
    position: relative;
    padding: 80px 0 40px;
    overflow: hidden;
    background-image: url('/images/casino-bg2.jpg');
    background-size: cover;
    background-position: center top;
    min-height: 100vh;
}

.casino-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 15, 0.72);
    z-index: -1;
}

.casino-hero-inner {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.casino-title {
    font-size: clamp(52px, 7vw, 72px);
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 20px;
    display: inline-flex;
    align-items: center;
    gap: 26px;
    font-family: 'Cinzel Decorative', 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

.casino-title-icon-wrap {
    display: inline-flex;
    align-items: center;
}

.casino-title-icon {
    height: 1em;
    width: auto;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.6));
}

.casino-title-text {
    display: inline-block;
}

.casino-subtitle {
    font-size: 20px;
    color: var(--text-secondary);
    margin-bottom: 56px;
}

.casino-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
    max-width: 760px;
    margin: 0 auto;
}

.casino-game-btn {
    justify-content: flex-start;
    text-align: left;
    padding: 28px 28px;
    font-size: 24px;
    gap: 26px;
}

.casino-game-icon {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

.casino-game-icon-xl {
    width: 120px;
    height: 120px;
}

.casino-game-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.casino-game-name {
    font-size: 24px;
    font-weight: 700;
}

.casino-game-desc {
    font-size: 18px;
    color: var(--text-secondary);
}

.casino-game-btn-disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@media (max-width: 600px) {
    .casino-hero {
        background-position: left top;
    }
    .casino-title {
        font-size: 28px;
    }
    .casino-title-icon {
        height: 1.5em;
    }
    .casino-grid {
        grid-template-columns: 1fr;
    }
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 48px;
    flex-wrap: wrap;
}

.stat-item {
    text-align: center;
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.stat-label {
    font-size: 14px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.hero-banner {
    width: 100%;
    margin-top: 48px;
    margin-bottom: 20px;
    position: relative;
    z-index: 0;
    pointer-events: none;
}

.banner-img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    object-position: top center;
    max-height: min(70vh, 700px);
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--text-muted);
    animation: bounce 2s infinite;
}

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

/* Section Styles */
section {
    padding: 100px 0;
    position: relative;
}

section:not(.hero) {
    z-index: 1;
}

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

.section-title {
    font-size: clamp(36px, 5vw, 48px);
    font-weight: 800;
    margin-bottom: 16px;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.5));
}

.title-underline {
    width: 80px;
    height: 4px;
    background: var(--gradient-1);
    margin: 0 auto;
    border-radius: 2px;
}

.section-description {
    font-size: 18px;
    color: var(--text-secondary);
    margin-top: 16px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

/* About Section */
.about {
    background: transparent;
    position: relative;
    z-index: 1;
}

.about .container {
    position: relative;
    z-index: 2;
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.about-text .lead {
    font-size: 24px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 24px;
    line-height: 1.5;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.about-text p {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.8;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.tagline {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin-top: 32px;
    padding: 16px 24px;
    background: rgba(17, 17, 24, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.tagline-icon {
    font-size: 24px;
}

/* Marketplace Section */
.marketplace-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    max-width: 800px;
    margin: 0 auto;
}

.marketplace-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 32px;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.marketplace-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-1);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.marketplace-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary-color);
    box-shadow: 0 12px 32px rgba(139, 92, 246, 0.2);
}

.marketplace-card:hover::before {
    transform: scaleX(1);
}

.marketplace-icon {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 60px;
}

.marketplace-logo-img {
    width: 100%;
    height: auto;
    object-fit: contain;
    max-height: 80px;
}

.marketplace-card h3 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
}

.marketplace-card p {
    color: var(--text-secondary);
    font-size: 16px;
    margin-bottom: 0;
    text-align: center;
}

/* Utilities Section */
.utilities {
    background: var(--bg-darker);
}

.utilities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
}

.utility-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 32px 24px;
    text-decoration: none;
    color: var(--text-primary);
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.utility-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-hero);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.utility-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary-color);
    box-shadow: 0 12px 32px rgba(139, 92, 246, 0.2);
}

.utility-card:hover::before {
    opacity: 0.1;
}

.utility-icon {
    font-size: 48px;
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
}

.utility-card h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
    position: relative;
    z-index: 1;
}

.utility-card p {
    color: var(--text-secondary);
    font-size: 14px;
    position: relative;
    z-index: 1;
}

/* Community Section */
.community-links {
    display: flex;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
}

.community-link-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 32px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 600;
    transition: all 0.3s ease;
}

.community-link-card:hover {
    background: var(--gradient-1);
    border-color: transparent;
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.3);
}

.community-link-card.discord-link {
    background: rgba(88, 101, 242, 0.1);
    border-color: rgba(88, 101, 242, 0.3);
    color: #5865F2;
}

.community-link-card.discord-link:hover {
    background: #5865F2;
    border-color: #5865F2;
    color: white;
    box-shadow: 0 8px 24px rgba(88, 101, 242, 0.4);
}

.community-link-card svg {
    width: 24px;
    height: 24px;
}

/* Footer */
.footer {
    background: var(--bg-darker);
    border-top: 1px solid var(--border-color);
    padding: 48px 0;
    text-align: center;
}

.footer-logo {
    margin-bottom: 16px;
}

.footer-logo-img {
    height: 32px;
    margin: 0 auto;
}

.footer-text {
    color: var(--text-secondary);
    font-size: 16px;
    margin-bottom: 8px;
}

.footer-tagline {
    color: var(--text-muted);
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-links {
        gap: 20px;
    }

    .nav-links a {
        font-size: 14px;
    }

    .hero {
        padding: 100px 0 60px;
    }

    .hero-stats {
        gap: 32px;
    }

    section {
        padding: 60px 0;
    }

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

    .utilities-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }

    .container {
        padding: 0 16px;
    }
}

@media (max-width: 480px) {
    .nav-links {
        gap: 16px;
    }

    .nav-links a {
        font-size: 13px;
    }

    .community-link {
        padding: 6px 16px;
        font-size: 13px;
    }

    .btn-large {
        padding: 16px 32px;
        font-size: 18px;
    }

    .hero-cta {
        flex-direction: column;
        align-items: center;
    }

    .hero-cta .btn {
        width: auto;
        max-width: 85%;
        justify-content: center;
    }

    .hero-cta-icon {
        font-size: 32px;
    }

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