/* Base styles and variables */
:root {
    --bg-color: #050709; /* Much darker background */
    --bg-light: #080c14; /* Darker secondary background */
    --bg-card: rgba(8, 12, 20, 0.8); /* Darker card background */
    --text-color: #f0f0f0;
    --text-secondary: #b0b0b0;
    --highlight-red: #ff3a3a;
    --highlight-blue: #3a85ff;
    --highlight-cyan: #4aecff;
    --highlight-orange: #ff9d33;
    --red-glow: 0 0 10px rgba(255, 58, 58, 0.5);
    --blue-glow: 0 0 10px rgba(58, 133, 255, 0.5);
    --transition: all 0.3s ease;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    --border-radius: 12px;
    --container-width: 1200px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    background-image:
        radial-gradient(circle at 10% 10%, rgba(255, 58, 58, 0.02), transparent 30%),
        radial-gradient(circle at 90% 90%, rgba(58, 133, 255, 0.02), transparent 30%);
    color: var(--text-color);
    font-family: 'Press Start 2P', cursive;
    line-height: 1.5;
    overflow-x: hidden;
}

.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
}

/* Typography */
h1,
h2,
h3 {
    font-family: 'Press Start 2P', cursive;
    margin-bottom: 1.5rem;
    line-height: 1.3;
}

h1 {
    font-size: clamp(1.5rem, 5vw, 2.5rem);
    text-shadow: var(--red-glow), var(--blue-glow);
}

h2 {
    font-size: clamp(1.2rem, 4vw, 2rem);
}

h3 {
    font-size: clamp(1rem, 3vw, 1.5rem);
    background: linear-gradient(90deg, var(--highlight-red), var(--highlight-blue));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

p {
    margin-bottom: 1.5rem;
    font-size: clamp(0.9rem, 2vw, 1.1rem);
}

/* Highlight colors with text shadow for glow effect */
.highlight-red {
    color: var(--highlight-red);
    font-weight: bold;
    text-shadow: var(--red-glow);
}

.highlight-blue {
    color: var(--highlight-blue);
    font-weight: bold;
    text-shadow: var(--blue-glow);
}

.highlight-cyan {
    color: var(--highlight-cyan);
    font-weight: bold;
    text-shadow: 0 0 10px rgba(74, 236, 255, 0.5);
}

.highlight-orange {
    color: var(--highlight-orange);
    font-weight: bold;
    text-shadow: 0 0 10px rgba(255, 157, 51, 0.5);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(5, 7, 9, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(58, 133, 255, 0.1);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-family: 'Press Start 2P', cursive;
    font-size: 1.2rem;
    text-decoration: none;
    color: var(--text-color);
    text-shadow: var(--red-glow), var(--blue-glow);
    transition: var(--transition);
}

.nav-logo:hover {
    transform: scale(1.05);
}

.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-color);
    transition: var(--transition);
    position: relative;
    padding: 0.5rem 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--highlight-red), var(--highlight-blue));
    transition: var(--transition);
}

.nav-link:hover {
    text-shadow: var(--red-glow), var(--blue-glow);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* Hero section */
.hero {
    display: flex;
    align-items: center;
    padding: 10rem 0 5rem;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        linear-gradient(135deg, rgba(255, 58, 58, 0.03) 0%, transparent 50%),
        linear-gradient(225deg, rgba(58, 133, 255, 0.03) 0%, transparent 50%);
    z-index: -1;
}

.hero .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.hero-content {
    margin-bottom: 3rem;
}

.hero-content p {
    max-width: 600px;
    margin: 0 auto;
    color: var(--text-secondary);
}

.hero-image img {
    max-width: 100%;
    height: auto;
    max-height: 300px;
    filter: drop-shadow(var(--red-glow)) drop-shadow(var(--blue-glow));
}

/* Floating animation with glowing effect */
.floating {
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0% {
        transform: translateY(0);
        filter: drop-shadow(var(--red-glow)) drop-shadow(var(--blue-glow));
    }

    50% {
        transform: translateY(-20px);
        filter: drop-shadow(0 0 15px rgba(255, 58, 58, 0.6)) drop-shadow(0 0 15px rgba(58, 133, 255, 0.6));
    }

    100% {
        transform: translateY(0);
        filter: drop-shadow(var(--red-glow)) drop-shadow(var(--blue-glow));
    }
}

/* Card style */
.card {
    background-color: var(--bg-card);
    backdrop-filter: blur(5px);
    border-radius: var(--border-radius);
    padding: 2rem;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--highlight-red), var(--highlight-blue));
    opacity: 0.8;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
    border-color: rgba(255, 255, 255, 0.1);
}

/* Section styling */
section {
    padding: 5rem 0;
    position: relative;
}

section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

.about::before {
    background: radial-gradient(circle at bottom right, rgba(58, 133, 255, 0.02), transparent 70%);
}

.screenshots::before {
    background: radial-gradient(circle at top left, rgba(255, 58, 58, 0.02), transparent 70%);
}

/* Screenshots section */
.screenshot-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.screenshot-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.screenshot-item img {
    width: 100%;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: var(--transition);
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.screenshot-item:first-child img {
    box-shadow: var(--shadow), var(--red-glow);
}

.screenshot-item:last-child img {
    box-shadow: var(--shadow), var(--blue-glow);
}

.screenshot-item img:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4), 0 0 15px rgba(255, 58, 58, 0.3), 0 0 15px rgba(58, 133, 255, 0.3);
}

.caption {
    margin-top: 1rem;
    text-align: center;
    color: var(--text-secondary);
}

/* Video section */
.video-section {
    background-color: var(--bg-color); /* Changed to main bg color for consistency */
    text-align: center;
    position: relative;
    z-index: 1;
}

.video-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        linear-gradient(135deg, rgba(255, 58, 58, 0.03) 0%, transparent 70%),
        linear-gradient(225deg, rgba(58, 133, 255, 0.03) 0%, transparent 70%);
    z-index: -1;
}

.video-section h3 {
    margin-bottom: 1rem;
}

.video-section p {
    max-width: 700px;
    margin: 0 auto 2rem;
}

.video-container {
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    overflow: hidden;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow), var(--red-glow), var(--blue-glow);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.video-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--highlight-red), var(--highlight-blue));
    z-index: 1;
}

.video-container video {
    width: 100%;
    display: block;
}

/* Footer */
footer {
    background-color: var(--bg-color); /* Changed to main bg color for consistency */
    padding: 2rem 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, var(--highlight-red), var(--highlight-blue));
    opacity: 0.5;
}

footer .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

footer p {
    margin-bottom: 0;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    color: var(--text-color);
    text-decoration: none;
    transition: var(--transition);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    background-color: rgba(0, 0, 0, 0.2); /* Darker background */
}

.social-link:hover {
    background: linear-gradient(90deg, rgba(255, 58, 58, 0.2), rgba(58, 133, 255, 0.2));
    transform: translateY(-3px);
    box-shadow: var(--red-glow), var(--blue-glow);
}

/* Image overlay */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.98); /* Nearly black overlay */
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.overlay.active {
    opacity: 1;
    pointer-events: all;
}

.fullscreen-img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 8px;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    box-shadow: var(--shadow), var(--red-glow), var(--blue-glow);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.overlay.active .fullscreen-img {
    transform: scale(1);
}

.close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 30px;
    cursor: pointer;
    opacity: 0.7;
    transition: var(--transition);
    text-shadow: var(--red-glow), var(--blue-glow);
}

.close:hover {
    opacity: 1;
    transform: rotate(90deg);
}

/* Responsive styles */
@media (min-width: 768px) {
    .hero .container {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }

    .hero-content {
        margin-bottom: 0;
        margin-right: 2rem;
    }

    .hero-content p {
        margin: 0;
    }
}

@media (max-width: 767px) {
    section {
        padding: 3rem 0;
    }

    .card {
        padding: 1.5rem;
    }
}