/* Base Styles */
:root {
    --primary-color: #8a2be2;
    --secondary-color: #4b0082;
    --accent-color: #00bfff;
    --text-color: #ffffff;
    --bg-color: #0a0a0a;
    --card-bg: rgba(30, 30, 40, 0.5);
    --glass-border: rgba(255, 255, 255, 0.1);
}

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

html, body {
    height: 100%;
    overflow: hidden;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    position: relative;
}

#canvas-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.content-wrapper {
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
}

/* Glassmorphism Styles */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.36);
}

/* Header Styles */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    z-index: 100;
    background: rgba(10, 10, 10, 0.8);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--accent-color);
    text-shadow: 0 0 10px rgba(0, 191, 255, 0.5);
}

.contact {
    display: flex;
    align-items: center;
    gap: 20px;
}

.contact-link {
    color: var(--text-color);
    text-decoration: none;
    font-size: 1rem;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
}

.contact-link:first-child::after {
    content: "";
    position: absolute;
    right: -10px;
    top: 50%;
    transform: translateY(-50%);
    height: 16px;
    width: 1px;
    background: rgba(255, 255, 255, 0.3);
}

.contact-link i {
    font-size: 1.2rem;
}

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

/* Main Content Styles */
main {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 0 5%;
    overflow: hidden;
}

.hero {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem 0;
}

.hero-card {
    max-width: 800px;
    width: 100%;
}

.hero h1 {
    font-size: 2.8rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero p {
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Games Section */
.games {
    flex: 1;
    overflow: visible;
    padding: 1rem 0;
    position: relative;
    z-index: 1;
}

.games h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--accent-color);
}

.games-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2.5rem;
    height: calc(100% - 4rem);
    overflow: visible;
    padding: 1.5rem;
}

.game-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 15px;
    overflow: visible;
    display: flex;
    flex-direction: column;
    height: 75%;
    max-width: 280px;
    width: 100%;
    transform-style: preserve-3d;
    perspective: 1000px;
    transition: transform 0.1s ease;
    margin: 15px;
    cursor: pointer;
}

.game-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
}

.game-image {
    height: 120px;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

.game-card h3 {
    padding: 1rem 1rem 0.5rem;
    font-size: 1.2rem;
    color: var(--primary-color);
}

.game-card p {
    padding: 0 1rem;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    flex-grow: 1;
}

.btn {
    display: inline-block;
    margin: 0.8rem 1rem;
    padding: 0.6rem 1.2rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    align-self: flex-start;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(138, 43, 226, 0.4);
}

/* Tilt effect glare styles */
.js-tilt-glare {
    border-radius: 15px;
    pointer-events: none;
    z-index: 10;
}

.js-tilt-glare-inner {
    border-radius: 15px;
    transition: opacity 0.2s ease-out;
}

/* Card click animation */
@keyframes card-pulse {
    0% {
        transform: perspective(1000px) rotateX(0) rotateY(0) scale3d(1, 1, 1);
        box-shadow: 0 15px 30px rgba(0, 0, 0, 0.5);
    }
    50% {
        transform: perspective(1000px) rotateX(0) rotateY(0) scale3d(0.95, 0.95, 0.95);
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    }
    100% {
        transform: perspective(1000px) rotateX(0) rotateY(0) scale3d(1.05, 1.05, 1.05);
        box-shadow: 0 25px 40px rgba(0, 0, 0, 0.7);
    }
}

.card-click-animation {
    animation: card-pulse 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.card-click-animation .game-card-inner {
    transition: all 0.6s ease;
    filter: brightness(1.2);
}

.card-click-animation .js-tilt-glare-inner {
    opacity: 0.5 !important;
    transition: opacity 0.6s ease !important;
}

/* Footer Styles */
footer {
    background: rgba(10, 10, 10, 0.8);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    padding: 1rem 5%;
    text-align: center;
    z-index: 100;
}

.footer-content p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* Responsive Styles */
@media (max-width: 1200px) {
    .games-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .games-grid {
        grid-template-columns: 1fr;
    }
}
