/* --- CSS variables & Design System --- */
:root {
    --bg-color: #02040a; /* Premium dark black-blue */
    --bg-card: rgba(5, 8, 20, 0.75); /* Sleek black-blue glass panel */
    --border-color: rgba(255, 255, 255, 0.08);
    --border-glow: rgba(61, 94, 255, 0.25); /* Electric blue border glow */
    
    /* Neon & Brand Colors (Blue #00116F, White, Black) */
    --neon-cyan: #3d5eff;
    --neon-cyan-rgb: 61, 94, 255;
    --neon-purple-rgb: 0, 17, 111; /* Electric blue for glows and active text readability */
    --neon-purple: #00116F; /* Deep Royal Blue (Main Brand Color) */
    --neon-pink: #ffffff; /* Swapped to Pure White */
    --neon-green: #3DDC84;
    --neon-blue: #00116F; /* Swapped to main deep blue */
    --neon-orange: #ff5555;
    
    /* Text Colors */
    --text-primary: #ffffff;
    --text-secondary: #cbd5e1; /* Slate white secondary */
    --text-muted: #64748b;
    
    /* Fonts */
    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Outfit', sans-serif;
    
    /* Timing & Transitions */
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Base Resets & Global Styles --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent !important;
    -webkit-tap-highlight-color: rgba(0,0,0,0) !important;
}

a:focus, button:focus, input:focus, select:focus, textarea:focus,
a:active, button:active, div:focus, div:active, span:focus, span:active,
.nav-link:focus, .nav-link:active, .social-card:focus, .social-card:active {
    outline: none !important;
    -webkit-tap-highlight-color: transparent !important;
    -webkit-tap-highlight-color: rgba(0,0,0,0) !important;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    word-break: normal;
    overflow-wrap: break-word;
}

/* Modern Text Wrapping & Balancing */
h1, h2, h3, h4, .section-title, .hero-title, .hero-subtitle {
    text-wrap: balance;
}

p, .hero-desc, .project-description, .socials-intro {
    text-wrap: pretty;
}

#typewriter {
    white-space: nowrap;
}

/* Canvas Background styling */
#canvas-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    pointer-events: none;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-color);
}
::-webkit-scrollbar-thumb {
    background: rgba(var(--neon-cyan-rgb), 0.3);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--neon-cyan);
    box-shadow: 0 0 8px var(--neon-cyan);
}

/* --- Glassmorphism Glass Panel helper --- */
.glass-panel {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.35);
    transition: var(--transition-normal);
    position: relative;
    overflow: hidden;
    will-change: transform, opacity;
}

.glass-panel:hover {
    border-color: rgba(var(--neon-cyan-rgb), 0.3);
    box-shadow: 0 12px 40px 0 rgba(var(--neon-cyan-rgb), 0.15);
}

/* Dynamic mouse hover glow */
[data-glow]::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: radial-gradient(
        350px circle at var(--mouse-x, 0px) var(--mouse-y, 0px),
        rgba(var(--neon-cyan-rgb), 0.12),
        transparent 50%
    );
    z-index: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

/* Ensure child content sits above the absolute positioned glow gradient */
.glass-panel > * {
    position: relative;
    z-index: 2;
}

/* --- Layout Header & Nav --- */
.header {
    position: fixed;
    top: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1000px;
    padding: 0.6rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    background: rgba(7, 20, 41, 0.75); /* Dark blue glass card */
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 40px; /* Fully pill-shaped floating dock */
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(var(--neon-cyan-rgb), 0.05);
    transition: var(--transition-normal);
}

.logo a {
    color: var(--text-primary);
    text-decoration: none;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.35rem;
    letter-spacing: -0.5px;
    transition: var(--transition-fast);
}

.logo-accent {
    color: var(--neon-cyan);
    text-shadow: 0 0 10px rgba(var(--neon-cyan-rgb), 0.6);
}

.nav {
    display: flex;
    gap: 0.35rem;
    background: rgba(0, 0, 0, 0.25);
    padding: 0.25rem;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    padding: 0.5rem 1.25rem;
    border-radius: 20px; /* Capsule shape inside nav */
    transition: color var(--transition-fast), background-color var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 0.4rem;
    position: relative;
    z-index: 1;
}

.nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}

.nav-link::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-purple));
    box-shadow: 0 0 12px rgba(var(--neon-cyan-rgb), 0.5);
    opacity: 0;
    z-index: -1;
    transition: opacity var(--transition-normal);
}

.nav-link.active {
    color: #ffffff !important; /* White text contrast against dark blue gradient capsule */
    text-shadow: none;
}

.nav-link.active::before {
    opacity: 1;
}

/* --- Common Components & Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    font-family: var(--font-heading);
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition-normal);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-blue));
    color: #fff;
    box-shadow: 0 4px 15px rgba(var(--neon-cyan-rgb), 0.4);
    border: none;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(var(--neon-cyan-rgb), 0.4), 0 0 15px var(--neon-cyan);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--neon-cyan);
    color: #fff;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(var(--neon-cyan-rgb), 0.2);
}

.btn-outline {
    background: transparent;
    color: var(--neon-cyan);
    border: 1px solid var(--neon-cyan);
    box-shadow: 0 0 8px rgba(var(--neon-cyan-rgb), 0.1);
}

.btn-outline:hover {
    background: var(--neon-cyan);
    color: #0b0813;
    box-shadow: 0 0 18px var(--neon-cyan);
}

/* --- Main Sections & Layout --- */
.main-content {
    margin-top: 80px;
}

.section {
    padding: 5rem 10% 4rem;
    max-width: 1400px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
}

.title-underline {
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
    margin: 0.75rem auto 0;
    border-radius: 2px;
}

/* --- HERO SECTION --- */
.hero-section {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    align-items: center;
    min-height: calc(100vh - 120px);
    padding-top: 2rem;
    padding-bottom: 4rem;
}

.hero-info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.badge-container {
    align-self: flex-start;
}

.badge {
    background: rgba(61, 220, 132, 0.12);
    border: 1px solid var(--neon-green);
    color: var(--neon-green);
    padding: 0.4rem 0.8rem;
    border-radius: 30px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 0 10px rgba(61, 220, 132, 0.2);
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.15;
}

.text-glow {
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 8px rgba(var(--neon-cyan-rgb), 0.4));
}

.hero-subtitle {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 500;
    color: var(--text-secondary);
}

#typewriter {
    color: var(--neon-pink);
    font-weight: 600;
    text-shadow: 0 0 8px rgba(255, 121, 198, 0.4);
}

.cursor {
    color: var(--neon-pink);
    animation: blink 0.8s infinite;
}

.hero-desc {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 540px;
}

.hero-actions {
    display: flex;
    gap: 1.25rem;
    margin-top: 1rem;
}

/* Hero Cyber Frame Visual */
.hero-visual {
    display: flex;
    justify-content: center;
}

.cyber-frame {
    position: relative;
    width: 90%;
    max-width: 450px;
    aspect-ratio: 1;
    border-radius: 20px;
    padding: 8px;
    background: linear-gradient(135deg, rgba(var(--neon-cyan-rgb), 0.2), rgba(var(--neon-cyan-rgb), 0.2));
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 15px 45px rgba(0,0,0,0.5), 0 0 30px rgba(189,147,249,0.1);
    transition: var(--transition-normal);
    will-change: transform;
}

.cyber-frame:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 50px rgba(0,0,0,0.6), 0 0 40px rgba(0,242,254,0.2), 0 0 20px rgba(189,147,249,0.2);
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 16px;
    background: radial-gradient(circle, rgba(14, 27, 53, 0.8) 0%, rgba(2, 8, 19, 0.95) 100%);
    padding: 0.5rem;
}

/* Cyber Frame Tech Bracket Highlights */
.corner-bracket {
    position: absolute;
    width: 20px;
    height: 20px;
    border-color: var(--neon-cyan);
    border-style: solid;
    pointer-events: none;
    transition: var(--transition-normal);
}

.cyber-frame:hover .corner-bracket {
    border-color: var(--neon-pink);
    width: 25px;
    height: 25px;
}

.top-left { top: 0; left: 0; border-width: 4px 0 0 4px; border-top-left-radius: 20px; }
.top-right { top: 0; right: 0; border-width: 4px 4px 0 0; border-top-right-radius: 20px; }
.bottom-left { bottom: 0; left: 0; border-width: 0 0 4px 4px; border-bottom-left-radius: 20px; }
.bottom-right { bottom: 0; right: 0; border-width: 0 4px 4px 0; border-bottom-right-radius: 20px; }

.status-overlay {
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: #0f0c1b;
    border: 1px solid var(--border-glow);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
    z-index: 10;
}

.status-dot {
    width: 8px;
    height: 8px;
    background-color: var(--neon-green);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--neon-green);
}

.status-text {
    font-size: 0.8rem;
    font-family: var(--font-heading);
    color: var(--text-secondary);
}

/* --- ABOUT & SKILLS SECTION --- */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.about-text-card {
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.about-text-card h3 {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    color: var(--neon-cyan);
    position: relative;
    display: inline-block;
}

.interest-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1rem;
}

.tag {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    padding: 0.4rem 0.8rem;
    border-radius: 30px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: var(--transition-fast);
}

.tag:hover {
    border-color: var(--neon-pink);
    color: #fff;
    background: rgba(255, 121, 198, 0.05);
    transform: translateY(-2px);
}

.skills-container {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.skill-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    border-radius: 16px;
    position: relative;
    overflow: hidden;
}

.skill-icon {
    font-size: 2.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 50px;
}

.skill-img-icon {
    width: 38px;
    height: 38px;
}

.skill-info h4 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.skill-info p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Skill card shine hover */
.skill-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.06), transparent);
    transform: skewX(-20deg);
}

.skill-card:hover::after {
    left: 150%;
    transition: 0.8s ease-in-out;
}

/* --- PROJECTS SECTION --- */
.project-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
}

.filter-btn {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 0.6rem 1.25rem;
    border-radius: 30px;
    font-family: var(--font-heading);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.filter-btn:hover, .filter-btn.active {
    color: #fff;
    background: rgba(var(--neon-cyan-rgb), 0.15);
    border-color: var(--neon-purple);
    box-shadow: 0 0 10px rgba(var(--neon-cyan-rgb), 0.3);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2.25rem;
}

.project-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    height: 100%;
}

.project-img-wrapper {
    position: relative;
    height: 190px;
    overflow: hidden;
}

.project-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-normal);
}

.project-card:hover .project-img {
    transform: scale(1.05);
}

.project-placeholder-bg {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-normal);
}

.gradient-android {
    background: linear-gradient(135deg, #112d1c 0%, #17422b 100%);
    border-bottom: 2px solid var(--neon-green);
}
.gradient-anime {
    background: linear-gradient(135deg, #061e38 0%, #0c3866 100%);
    border-bottom: 2px solid var(--neon-cyan);
}
.gradient-steam {
    background: linear-gradient(135deg, #0f1e2d 0%, #1b3852 100%);
    border-bottom: 2px solid var(--neon-cyan);
}

.project-icon-placeholder {
    font-size: 3.5rem;
    color: rgba(255, 255, 255, 0.3);
    transition: var(--transition-normal);
}

.project-card:hover .project-icon-placeholder {
    transform: scale(1.15) rotate(5deg);
    color: rgba(255, 255, 255, 0.7);
}

.project-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-family: var(--font-heading);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.project-badge.playstore {
    background: rgba(61, 220, 132, 0.15);
    border: 1px solid var(--neon-green);
    color: var(--neon-green);
}
.project-badge.github {
    background: rgba(var(--neon-cyan-rgb), 0.15);
    border: 1px solid var(--neon-cyan);
    color: var(--neon-cyan);
}

.project-content {
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.project-name {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    transition: var(--transition-fast);
}

.project-card:hover .project-name {
    color: var(--neon-cyan);
}

.project-description {
    font-size: 0.92rem;
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
    line-height: 1.5;
    flex-grow: 1;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.tech-tag {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    font-size: 0.78rem;
    color: var(--text-secondary);
}

.project-links {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.btn-project {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.55rem 1rem;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    flex-grow: 1;
    transition: var(--transition-fast);
}

.btn-chplay {
    background: var(--neon-green);
    color: #0d1219;
}
.btn-chplay:hover:not(.disabled) {
    background: #46e88f;
    box-shadow: 0 0 12px rgba(61, 220, 132, 0.5);
    transform: translateY(-2px);
}

.btn-chplay.disabled {
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    cursor: not-allowed;
}

.btn-project-icon {
    width: 38px;
    height: 38px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: var(--transition-fast);
}

.btn-project-icon:hover {
    color: #fff;
    background: rgba(var(--neon-cyan-rgb), 0.15);
    border-color: var(--neon-purple);
    transform: translateY(-2px);
}

.btn-source {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.btn-source:hover {
    color: #fff;
    background: rgba(var(--neon-cyan-rgb), 0.15);
    border-color: var(--neon-purple);
    box-shadow: 0 0 12px rgba(var(--neon-cyan-rgb), 0.3);
    transform: translateY(-2px);
}

/* --- SOCIAL CONNECT SECTION --- */
.socials-intro {
    text-align: center;
    color: var(--text-secondary);
    max-width: 600px;
    margin: -2rem auto 3rem;
}

.socials-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
}

.social-card {
    display: flex;
    align-items: center;
    padding: 1rem 1.25rem;
    text-decoration: none;
    color: var(--text-primary);
    position: relative;
    overflow: hidden;
    gap: 1rem;
    flex: 1 1 320px;
    max-width: 400px;
}

.social-card-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    opacity: 0;
    transition: var(--transition-normal);
}

.social-icon-box {
    width: 45px;
    height: 45px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    z-index: 2;
    transition: var(--transition-normal);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
}

.social-info {
    z-index: 2;
    flex-grow: 1;
}

.social-info h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.15rem;
}

.social-info p {
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.social-arrow {
    font-size: 0.9rem;
    color: var(--text-muted);
    z-index: 2;
    transition: var(--transition-fast);
}

.social-card:hover .social-arrow {
    color: #fff;
    transform: translateX(3px);
}

/* Social Card Color Themes */
/* Facebook styling */
.facebook-theme:hover {
    border-color: var(--neon-blue);
    box-shadow: 0 10px 30px rgba(24, 119, 242, 0.2);
}
.facebook-theme:hover .social-icon-box {
    background: var(--neon-blue);
    border-color: var(--neon-blue);
    box-shadow: 0 0 15px var(--neon-blue);
    color: #fff;
}
.facebook-theme .social-card-bg {
    background: linear-gradient(135deg, rgba(24, 119, 242, 0.05), transparent);
    opacity: 1;
}

/* Steam styling */
.steam-theme:hover {
    border-color: var(--neon-cyan);
    box-shadow: 0 10px 30px rgba(var(--neon-cyan-rgb), 0.2);
}
.steam-theme:hover .social-icon-box {
    background: linear-gradient(135deg, #171a21, #2a475e);
    border-color: var(--neon-cyan);
    box-shadow: 0 0 15px rgba(var(--neon-cyan-rgb), 0.4);
    color: var(--neon-cyan);
}
.steam-theme .social-card-bg {
    background: linear-gradient(135deg, rgba(var(--neon-cyan-rgb), 0.05), transparent);
    opacity: 1;
}

/* GitHub styling */
.github-theme:hover {
    border-color: var(--neon-purple);
    box-shadow: 0 10px 30px rgba(var(--neon-cyan-rgb), 0.2);
}
.github-theme:hover .social-icon-box {
    background: #24292e;
    border-color: var(--neon-purple);
    box-shadow: 0 0 15px var(--neon-purple);
    color: #fff;
}
.github-theme .social-card-bg {
    background: linear-gradient(135deg, rgba(var(--neon-cyan-rgb), 0.05), transparent);
    opacity: 1;
}

/* Playstore styling */
.playstore-theme:hover {
    border-color: var(--neon-green);
    box-shadow: 0 10px 30px rgba(61, 220, 132, 0.2);
}
.playstore-theme:hover .social-icon-box {
    background: linear-gradient(135deg, #0f5132, #157347);
    border-color: var(--neon-green);
    box-shadow: 0 0 15px var(--neon-green);
    color: #fff;
}
.playstore-theme .social-card-bg {
    background: linear-gradient(135deg, rgba(61, 220, 132, 0.05), transparent);
    opacity: 1;
}

/* Email styling */
.email-theme:hover {
    border-color: #ffffff;
    box-shadow: 0 10px 30px rgba(255, 255, 255, 0.15);
}
.email-theme:hover .social-icon-box {
    background: #ffffff;
    border-color: #ffffff;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.4);
    color: #02040a;
}
.email-theme .social-card-bg {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), transparent);
    opacity: 1;
}

/* --- FOOTER --- */
.footer {
    border-top: 1px solid var(--border-color);
    padding: 3rem 10% 2.5rem;
    text-align: center;
    background: rgba(5, 8, 20, 0.85);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.text-pink {
    color: var(--neon-pink);
    animation: pulse 1.5s infinite;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    transition: var(--transition-fast);
}

.footer-links a:hover {
    color: var(--neon-cyan);
}

/* --- LOFI MUSIC PLAYER WIDGET --- */
.lofi-player {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 100;
    width: 345px;
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    background: linear-gradient(135deg, rgba(7, 20, 41, 0.85) 0%, rgba(2, 8, 19, 0.95) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(var(--neon-cyan-rgb), 0.20);
    border-radius: 20px;
    box-shadow: 
        0 10px 40px rgba(0, 0, 0, 0.5), 
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 25px rgba(var(--neon-cyan-rgb), 0.08);
    transition: all var(--transition-normal);
    opacity: 0.65; /* Semi-translucent by default on PC to stay harmonious */
}

.lofi-player:hover, .lofi-player.playing {
    border-color: rgba(var(--neon-cyan-rgb), 0.45);
    box-shadow: 
        0 15px 50px rgba(0, 0, 0, 0.6), 
        inset 0 1px 0 rgba(255, 255, 255, 0.15),
        0 0 35px rgba(var(--neon-cyan-rgb), 0.18);
    opacity: 1.0; /* Full opacity on hover or when playing */
}

.player-disc-wrapper {
    position: relative;
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.player-disc {
    width: 66px;
    height: 66px;
    border-radius: 50%;
    background: 
        radial-gradient(circle at center, var(--neon-cyan) 3%, transparent 4%),
        radial-gradient(circle at center, #020813 14%, transparent 15%),
        repeating-radial-gradient(
            circle at center,
            #111726,
            #111726 1px,
            #0a0f1d 2px,
            #111726 3px
        );
    border: 2px solid #1e293b;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 
        0 4px 15px rgba(0, 0, 0, 0.6), 
        inset 0 0 10px rgba(0, 0, 0, 0.9),
        0 0 15px rgba(var(--neon-cyan-rgb), 0.1);
    position: relative;
    animation: rotate 12s linear infinite;
    animation-play-state: paused;
    transition: border-color var(--transition-normal), box-shadow var(--transition-normal);
    will-change: transform;
}

.lofi-player.playing .player-disc {
    animation-play-state: running;
    border-color: rgba(var(--neon-cyan-rgb), 0.5);
    box-shadow: 
        0 4px 20px rgba(0, 0, 0, 0.7), 
        inset 0 0 10px rgba(0, 0, 0, 0.9),
        0 0 25px rgba(var(--neon-cyan-rgb), 0.3);
}

.vinyl-label {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--neon-cyan) 0%, var(--neon-purple) 100%);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 4px rgba(0,0,0,0.5);
}

.vinyl-label-center {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #020813;
    box-shadow: 0 0 3px rgba(var(--neon-cyan-rgb), 0.8);
}

/* Turntable needle */
.player-needle {
    position: absolute;
    top: -5px;
    right: -2px;
    width: 22px;
    height: 40px;
    pointer-events: none;
    z-index: 10;
    transform-origin: 18px 4px;
    transform: rotate(-15deg);
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    will-change: transform;
}

.lofi-player.playing .player-needle {
    transform: rotate(18deg);
}

.needle-hub {
    position: absolute;
    top: 0;
    right: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #475569;
    border: 1px solid #94a3b8;
    box-shadow: 0 1px 3px rgba(0,0,0,0.4);
}

.needle-arm {
    position: absolute;
    top: 6px;
    right: 3px;
    width: 2px;
    height: 28px;
    background: linear-gradient(to bottom, #94a3b8, #475569);
    transform: rotate(10deg);
    transform-origin: top center;
}

.needle-cartridge {
    position: absolute;
    bottom: -2px;
    left: -1px;
    width: 5px;
    height: 8px;
    background: var(--neon-cyan);
    border-radius: 1px;
    box-shadow: 0 0 6px var(--neon-cyan);
}

.player-details {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    min-width: 0;
    position: relative;
    z-index: 5;
    overflow: visible !important;
    gap: 0.35rem;
}

.player-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-family: var(--font-heading);
    font-size: 0.65rem;
    font-weight: 700;
    color: rgba(var(--neon-cyan-rgb), 0.85);
    margin-bottom: 0.1rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    gap: 8px;
}

.deck-model {
    background: rgba(var(--neon-cyan-rgb), 0.08);
    padding: 1px 6px;
    border-radius: 4px;
    border: 1px solid rgba(var(--neon-cyan-rgb), 0.15);
    color: var(--neon-cyan);
    text-shadow: 0 0 5px rgba(var(--neon-cyan-rgb), 0.5);
    white-space: nowrap;
}

.deck-stereo {
    display: flex;
    align-items: center;
    gap: 3px;
    opacity: 0.8;
    white-space: nowrap;
}

.blink-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--neon-cyan);
    box-shadow: 0 0 5px var(--neon-cyan);
    display: inline-block;
}

.lofi-player.playing .blink-dot {
    animation: blink 1s steps(2, start) infinite;
}

.player-title {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    color: var(--text-primary);
    letter-spacing: -0.01em;
}

.player-artist {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 0.15rem;
    font-weight: 500;
}

.player-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.6rem;
    padding-left: 10px;
    position: relative;
    z-index: 10;
    overflow: visible !important;
}

.player-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid transparent;
}

.player-btn:hover {
    color: var(--neon-cyan);
    background: rgba(var(--neon-cyan-rgb), 0.05);
    border-color: rgba(var(--neon-cyan-rgb), 0.15);
    transform: scale(1.1);
}

.play-pause-btn {
    width: 36px;
    height: 36px;
    background: rgba(var(--neon-cyan-rgb), 0.08);
    border: 1px solid rgba(var(--neon-cyan-rgb), 0.4);
    color: var(--neon-cyan);
    font-size: 0.85rem;
    box-shadow: 0 0 10px rgba(var(--neon-cyan-rgb), 0.15);
}

.play-pause-btn:hover {
    background: var(--neon-cyan);
    color: #ffffff;
    box-shadow: 0 0 20px var(--neon-cyan);
    border-color: var(--neon-cyan);
}

.lofi-player.playing .play-pause-btn {
    background: rgba(var(--neon-cyan-rgb), 0.1);
    border-color: rgba(var(--neon-cyan-rgb), 0.5);
    color: var(--neon-cyan);
    box-shadow: 0 0 12px rgba(var(--neon-cyan-rgb), 0.2);
}

.lofi-player.playing .play-pause-btn:hover {
    background: var(--neon-cyan);
    color: #ffffff;
    box-shadow: 0 0 22px var(--neon-cyan);
    border-color: var(--neon-cyan);
}

.player-progress-container {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.player-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--neon-blue) 0%, var(--neon-cyan) 100%);
    border-radius: 3px;
    position: relative;
    box-shadow: 0 0 8px rgba(var(--neon-cyan-rgb), 0.4);
}

.player-progress-bar::after {
    content: '';
    position: absolute;
    right: -5px;
    top: 50%;
    transform: translateY(-50%) scale(0);
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--text-primary);
    border: 2px solid var(--neon-cyan);
    box-shadow: 0 0 10px var(--neon-cyan);
    transition: transform 0.15s ease;
}

.player-progress-container:hover .player-progress-bar::after {
    transform: translateY(-50%) scale(1);
}

/* Lofi Visualizer bars */
.visualizer {
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 14px;
    opacity: 0.65;
    pointer-events: none;
    transition: opacity var(--transition-normal);
}

.lofi-player.playing .visualizer {
    opacity: 1;
}

.visualizer .bar {
    width: 2px;
    height: 2px;
    background: linear-gradient(to top, var(--neon-blue), var(--neon-cyan));
    border-radius: 1px 1px 0 0;
    transition: height 0.1s ease;
    animation: bounce 1s ease-in-out infinite alternate;
    animation-play-state: paused;
}

.visualizer.playing .bar {
    animation-play-state: running;
}

/* Custom bounce speed & max-height per bar for natural visualizer vibe */
.visualizer .bar:nth-child(1) { height: 2px; animation-duration: 0.75s; --max-h: 10px; }
.visualizer .bar:nth-child(2) { height: 2px; animation-duration: 1.05s; animation-delay: 0.1s; --max-h: 13px; }
.visualizer .bar:nth-child(3) { height: 2px; animation-duration: 0.85s; animation-delay: 0.25s; --max-h: 8px; }
.visualizer .bar:nth-child(4) { height: 2px; animation-duration: 1.25s; animation-delay: 0.15s; --max-h: 14px; }
.visualizer .bar:nth-child(5) { height: 2px; animation-duration: 0.95s; animation-delay: 0.05s; --max-h: 11px; }
.visualizer .bar:nth-child(6) { height: 2px; animation-duration: 1.15s; animation-delay: 0.2s; --max-h: 12px; }
.visualizer .bar:nth-child(7) { height: 2px; animation-duration: 0.8s; animation-delay: 0.3s; --max-h: 9px; }
.visualizer .bar:nth-child(8) { height: 2px; animation-duration: 1.0s; animation-delay: 0.12s; --max-h: 11px; }

/* --- KEYFRAME ANIMATIONS --- */
@keyframes blink {
    50% { opacity: 0; }
}

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

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

@keyframes bounce {
    0% { height: 2px; }
    100% { height: var(--max-h, 12px); }
}

/* --- RESPONSIVE MEDIA QUERIES --- */
@media (max-width: 1024px) {
    .section {
        padding: 4rem 5% 3rem;
    }
    
    .hero-section {
        gap: 2.5rem;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .about-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 3.5rem 6% 2.5rem;
    }

    .header {
        top: 1rem;
        width: 95%;
        padding: 0.5rem 1.25rem;
        border-radius: 30px;
        flex-direction: row; /* Keep row so it floats neatly */
        justify-content: space-between;
        gap: 0;
    }
    
    .logo a {
        font-size: 1.15rem;
    }
    
    .nav {
        gap: 0.2rem;
        padding: 0.15rem;
    }
    
    .nav-link {
        padding: 0.4rem 0.75rem;
        font-size: 0.8rem;
        gap: 0.25rem;
    }
    
    .header-action {
        display: none; /* Hide contact button on mobile */
    }
    
    .main-content {
        margin-top: 80px;
    }
    
    .hero-section {
        grid-template-columns: 1fr;
        text-align: center;
        padding-top: 3rem;
        min-height: auto;
    }
    
    .badge-container {
        align-self: center;
    }
    
    .hero-desc {
        margin: 0 auto;
    }
    
    .hero-actions {
        justify-content: center;
        flex-direction: column;
        gap: 0.8rem;
    }
    
    .hero-visual {
        order: -1; /* Place image on top on mobile */
        margin-bottom: 1rem;
    }
    
    .cyber-frame {
        width: 100%;
        max-width: 320px;
    }
    
    .about-grid {
        gap: 2rem;
    }

    .projects-grid {
        gap: 1.75rem;
    }

    .lofi-player {
        left: 50%;
        bottom: 1rem;
        transform: translateX(-50%);
        width: 90%;
        max-width: 360px;
        box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
    }
}

@media (max-width: 480px) {
    .section {
        padding: 3rem 5% 2rem;
    }

    .section-title {
        font-size: 1.8rem;
    }
    
    .hero-title {
        font-size: 2.4rem;
    }
    
    .hero-subtitle {
        font-size: 1.4rem;
    }
    
    .nav-link span {
        display: none; /* Icon-only navigation on narrow viewports */
    }

    .nav-link {
        padding: 0.5rem 0.8rem;
        font-size: 1rem; /* Increase touch target size slightly */
        gap: 0;
    }

    .about-text-card {
        padding: 1.25rem;
    }

    .skill-card {
        padding: 1.25rem;
        gap: 1rem;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .project-content {
        padding: 1.25rem;
    }

    .project-tech {
        margin-bottom: 1rem;
    }

    .socials-grid {
        gap: 1rem;
    }

    .social-card {
        padding: 0.85rem 1rem;
    }

    /* Scale down turntable deck to fit narrow mobile screens neatly */
    .lofi-player {
        padding: 0.6rem 0.85rem;
        gap: 0.6rem;
        border-radius: 16px;
        bottom: 0.75rem;
        width: calc(100% - 1.5rem);
        max-width: 320px;
        opacity: 0.95; /* Keep it mostly opaque on mobile */
    }

    .player-disc-wrapper {
        width: 46px;
        height: 46px;
    }

    .player-disc {
        width: 42px;
        height: 42px;
    }

    .player-needle {
        width: 14px;
        height: 26px;
        top: -3px;
        right: -1px;
        transform-origin: 12px 3px;
        transform: rotate(-15deg);
    }

    .lofi-player.playing .player-needle {
        transform: rotate(18deg);
    }

    .vinyl-label {
        width: 14px;
        height: 14px;
    }

    .vinyl-label-center {
        width: 3px;
        height: 3px;
    }

    .player-title {
        font-size: 0.8rem;
    }

    .player-artist {
        font-size: 0.65rem;
        margin-bottom: 0.2rem;
    }

    .player-controls {
        gap: 0.5rem;
        margin-bottom: 0.25rem;
        padding-left: 2px;
    }

    .player-btn {
        width: 22px;
        height: 22px;
        font-size: 0.75rem;
    }

    .play-pause-btn {
        width: 26px;
        height: 26px;
        font-size: 0.7rem;
    }

    .player-progress-container {
        height: 4px;
    }
}

/* --- Scroll-Reveal Entrance Animations --- */
.scroll-reveal {
    opacity: 0;
    transform: translateY(35px);
    transition: opacity 0.85s cubic-bezier(0.16, 1, 0.3, 1), transform 0.85s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform, opacity;
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered entry delays */
.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }

/* --- RETRO ARCADE MODAL & CARD --- */
.retro-arcade-bg {
    background: radial-gradient(circle at center, #0b113a 0%, #02040a 100%);
    position: relative;
    overflow: hidden;
}
.retro-arcade-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
    background-size: 100% 4px, 6px 100%;
    opacity: 0.8;
}
.arcade-glow-icon {
    color: var(--neon-cyan);
    filter: drop-shadow(0 0 15px var(--neon-cyan));
    animation: floatArcade 4s ease-in-out infinite;
}
@keyframes floatArcade {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-8px) scale(1.05); }
}
.project-badge.arcade {
    background: var(--neon-cyan);
    color: #fff;
    box-shadow: 0 0 10px rgba(var(--neon-cyan-rgb), 0.4);
}
.btn-arcade-play {
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-purple));
    color: #ffffff !important;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(var(--neon-cyan-rgb), 0.3);
}
.btn-arcade-play:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 22px rgba(var(--neon-cyan-rgb), 0.5);
    filter: brightness(1.1);
}

/* Modal wrapper */
.arcade-modal {
    display: none; /* Hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99999; /* Higher than navbar and player */
    background: rgba(2, 4, 10, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.arcade-modal.show {
    display: flex;
    opacity: 1;
}
.arcade-modal-content {
    background: #050814;
    border: 1px solid rgba(61, 94, 255, 0.3);
    border-radius: 16px;
    width: 90%;
    max-width: 850px;
    padding: 1.5rem;
    position: relative;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), 0 0 30px rgba(61, 94, 255, 0.15);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}
.arcade-modal.show .arcade-modal-content {
    transform: scale(1);
}
.arcade-close-btn {
    position: absolute;
    top: 1rem;
    right: 1.25rem;
    font-size: 2rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition-fast);
}
.arcade-close-btn:hover {
    color: #ff5555;
    transform: scale(1.1);
}
.arcade-header {
    margin-bottom: 1rem;
    padding-right: 2.5rem;
}
.arcade-header h3 {
    margin: 0 0 0.25rem 0;
    font-family: var(--font-heading);
    font-size: 1.4rem;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.arcade-header h3 i {
    color: var(--neon-cyan);
    animation: blinkGamer 1.5s infinite;
}
@keyframes blinkGamer {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}
.arcade-controls-tip {
    font-size: 0.8rem;
    color: var(--text-muted);
    display: block;
}
.arcade-game-container {
    position: relative;
    width: 100%;
    padding-top: 75%; /* Retro 4:3 Aspect Ratio */
    overflow: hidden;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: #000;
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.8);
}
.arcade-game-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Dedicated Arcade Section Styles */
.arcade-section {
    position: relative;
    padding: 6rem 0;
}

.arcade-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    box-sizing: border-box;
}

.arcade-intro {
    text-align: center;
    margin-bottom: 3rem;
}

.arcade-title {
    font-size: 2.2rem;
    font-family: var(--font-heading);
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #ffffff 40%, var(--neon-cyan) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.arcade-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.arcade-note-inline {
    display: inline-block;
    margin-left: 0.5rem;
    color: var(--neon-cyan);
    font-weight: 600;
    text-shadow: 0 0 10px rgba(var(--neon-cyan-rgb), 0.3);
}

.arcade-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr));
    gap: 2.5rem;
    justify-content: center;
    width: 100%;
    box-sizing: border-box;
}

.game-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    height: 100%;
    width: 100%;
    max-width: 360px; /* Limit max width so single cards look beautiful and compact */
    margin: 0 auto;
    box-sizing: border-box;
    transition: var(--transition-normal);
}

.game-card:hover {
    transform: translateY(-5px);
    border-color: rgba(61, 94, 255, 0.4);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(61, 94, 255, 0.1);
}

.game-card-visual {
    position: relative;
    height: 160px;
    background: #050814;
    border-bottom: 1px solid var(--border-color);
    overflow: hidden;
}

.game-screen-mockup {
    width: 100%;
    height: 100%;
    background: #000;
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 0 25px rgba(0, 0, 0, 0.9);
}

.game-screen-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(61, 94, 255, 0.15) 0%, rgba(0, 0, 0, 0) 80%);
    pointer-events: none;
    z-index: 2;
}

.retro-arcade-bg {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at center, #0b113a 0%, #02040a 100%);
    position: relative;
}

.retro-arcade-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.04), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.04));
    background-size: 100% 4px, 6px 100%;
    opacity: 0.8;
}

.arcade-glow-icon {
    font-size: 3rem;
    color: var(--neon-cyan);
    filter: drop-shadow(0 0 15px var(--neon-cyan));
    animation: floatArcade 4s ease-in-out infinite;
}

.console-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    font-family: var(--font-heading);
    letter-spacing: 0.5px;
    text-transform: uppercase;
    z-index: 10;
}

.console-badge.nes {
    background: #ff3e3e;
    color: #fff;
    box-shadow: 0 0 8px rgba(255, 62, 62, 0.4);
}

.console-badge.sega {
    background: #0066cc;
    color: #fff;
    box-shadow: 0 0 8px rgba(0, 102, 204, 0.4);
}

.game-card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    box-sizing: border-box;
}

.game-title {
    font-size: 1.25rem;
    font-family: var(--font-heading);
    font-weight: 600;
    color: #fff;
    margin: 0 0 0.5rem 0;
}

.game-desc {
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.5;
    margin: 0 0 1.5rem 0;
    flex-grow: 1;
}

.btn-play-game {
    width: 100%;
    padding: 0.65rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: var(--font-heading);
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: #fff !important;
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-purple));
    box-shadow: 0 4px 10px rgba(var(--neon-cyan-rgb), 0.25);
}

.btn-play-game:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 15px rgba(var(--neon-cyan-rgb), 0.4);
    filter: brightness(1.1);
}

.btn-play-game.outline {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    box-shadow: none;
}

.btn-play-game.outline:hover {
    background: rgba(var(--neon-cyan-rgb), 0.1);
    border-color: var(--neon-cyan);
    box-shadow: 0 0 12px rgba(var(--neon-cyan-rgb), 0.2);
}

/* Subsection layout */
.arcade-subsection {
    margin-top: 3.5rem;
}

.arcade-sub-title {
    font-size: 1.3rem;
    font-family: var(--font-heading);
    color: #fff;
    margin-top: 0;
    margin-bottom: 1.75rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 0.6rem;
}

.arcade-sub-title i {
    color: var(--neon-cyan);
}

/* Custom ROM upload banner */
.custom-rom-section {
    margin-top: 4rem;
}

.custom-rom-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 2rem 2.5rem;
    gap: 2rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.01);
    border: 1px dashed rgba(61, 94, 255, 0.25);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    cursor: pointer;
    transition: var(--transition-normal);
}

.custom-rom-banner:hover {
    border-color: var(--neon-cyan);
    background: rgba(61, 94, 255, 0.02);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5), 0 0 25px rgba(61, 94, 255, 0.08);
}

.custom-rom-icon {
    font-size: 2.8rem;
    color: var(--neon-cyan);
    filter: drop-shadow(0 0 10px var(--neon-cyan));
    display: flex;
    align-items: center;
    justify-content: center;
}

.custom-rom-text {
    flex: 1;
}

.custom-rom-text h3 {
    margin: 0 0 0.5rem 0;
    font-family: var(--font-heading);
    font-size: 1.4rem;
    color: #fff;
}

.custom-rom-text p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
}

.custom-rom-banner .btn-play-game {
    width: auto;
    white-space: nowrap;
    padding: 0.75rem 1.5rem;
}

@keyframes floatArcade {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-6px) scale(1.04); }
}

@media (max-width: 768px) {
    .arcade-section {
        padding: 4rem 0;
    }
    .arcade-container {
        padding: 0 1.25rem;
    }
    .arcade-grid {
        grid-template-columns: 1fr;
        gap: 1.75rem;
    }
    .arcade-title {
        font-size: 1.8rem;
    }
    .arcade-subtitle {
        font-size: 1rem;
    }
    .arcade-note-inline {
        display: block;
        margin-left: 0;
        margin-top: 0.25rem;
    }
    .custom-rom-banner {
        flex-direction: column;
        text-align: center;
        padding: 1.75rem;
        gap: 1.25rem;
    }
    .custom-rom-icon {
        font-size: 2.4rem;
    }
    .custom-rom-banner .btn-play-game {
        width: 100%;
    }
}
