/* ==========================================
   Andrea | Personal Portfolio Design System
   ========================================== */

/* --- CSS VARIABLES & TOKENS --- */
:root {
    --bg-main: #0b0f19;
    --bg-card: rgba(17, 24, 39, 0.75);
    --bg-card-hover: rgba(31, 41, 55, 0.85);
    --border-color: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    
    /* Brand Accent Colors */
    --color-primary: #3b82f6; /* Blue (Sistemistica) */
    --color-primary-glow: rgba(59, 130, 246, 0.35);
    
    --color-green: #10b981; /* Green (Programmazione) */
    --color-green-glow: rgba(16, 185, 129, 0.35);
    
    --color-orange: #f97316; /* Orange (Stampa 3D) */
    --color-orange-glow: rgba(249, 115, 22, 0.35);
    
    --color-purple: #8b5cf6; /* Purple (Gaming) */
    --color-purple-glow: rgba(139, 92, 246, 0.35);
    
    --color-gold: #f59e0b; /* Gold */
    
    /* Fonts */
    --font-heading: 'Outfit', 'Inter', sans-serif;
    --font-body: 'Inter', sans-serif;
    
    /* Transitions */
    --transition-smooth: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-quick: all 0.15s ease;
}

/* --- RESET & BASE STYLES --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Background Overlay & Gradient */
.bg-gradient-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle at 10% 20%, rgba(139, 92, 246, 0.05) 0%, transparent 40%),
                radial-gradient(circle at 90% 80%, rgba(59, 130, 246, 0.05) 0%, transparent 45%),
                radial-gradient(circle at 50% 50%, rgba(16, 185, 129, 0.02) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

#particles-js {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    pointer-events: none;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-quick);
}

ul {
    list-style: none;
}

/* --- TYPOGRAPHY --- */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

/* ==========================================
   LAYOUT & HEADER
   ========================================== */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    background: rgba(11, 15, 25, 0.8);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.25rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.logo-accent {
    color: var(--color-primary);
}

.nav-menu ul {
    display: flex;
    gap: 1.5rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.2rem;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: 9999px;
    border: 1px solid transparent;
}

.nav-link i {
    font-size: 1rem;
}

.nav-link:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.nav-link.active {
    color: var(--text-primary);
    background: rgba(59, 130, 246, 0.12);
    border-color: rgba(59, 130, 246, 0.25);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.08);
}

.mobile-nav-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
}

/* --- MAIN CONTENT AREA --- */
.main-content {
    max-width: 1200px;
    margin: 6.5rem auto 4rem auto;
    padding: 0 2rem;
    min-height: calc(100vh - 15rem);
}

/* Page Section Base */
.page-section {
    display: none; /* Controlled by Router */
    animation: fadeInUp 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.page-section.active {
    display: block;
}

/* ==========================================
   COMPONENTS & UTILITIES
   ========================================== */

/* Glass Card */
.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 2.25rem;
    transition: var(--transition-smooth);
}

.glass-card:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: 0.75rem;
    border: 1px solid transparent;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.btn-primary {
    background: var(--color-primary);
    color: white;
    box-shadow: 0 4px 14px var(--color-primary-glow);
}

.btn-primary:hover {
    background: #2563eb;
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.5);
    transform: translateY(-2px);
}

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

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--border-hover);
    transform: translateY(-2px);
}

.btn-green {
    background: var(--color-green);
    color: white;
    box-shadow: 0 4px 14px var(--color-green-glow);
}

.btn-green:hover {
    background: #059669;
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
    transform: translateY(-2px);
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.85rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 9999px;
    background: rgba(59, 130, 246, 0.1);
    color: var(--color-primary);
    border: 1px solid rgba(59, 130, 246, 0.2);
    margin-bottom: 1rem;
}

.badge.green {
    background: rgba(16, 185, 129, 0.1);
    color: var(--color-green);
    border-color: rgba(16, 185, 129, 0.2);
}

.badge.orange {
    background: rgba(249, 115, 22, 0.1);
    color: var(--color-orange);
    border-color: rgba(249, 115, 22, 0.2);
}

.badge.purple {
    background: rgba(139, 92, 246, 0.1);
    color: var(--color-purple);
    border-color: rgba(139, 92, 246, 0.2);
}

.badge-new {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* Section Header styling */
.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 3.5rem auto;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

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

/* Lists */
.custom-list {
    margin-top: 1.25rem;
}

.custom-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.custom-list li i {
    margin-top: 0.25rem;
    flex-shrink: 0;
}

/* Color classes */
.text-red { color: #ef4444; }
.text-green { color: var(--color-green); }
.text-blue { color: var(--color-primary); }
.text-orange { color: var(--color-orange); }
.text-purple { color: var(--color-purple); }
.text-gold { color: var(--color-gold); }

.margin-top { margin-top: 3.5rem; }
.margin-top-sm { margin-top: 1.75rem; }
.margin-top-xs { margin-top: 0.75rem; }
.margin-bottom-lg { margin-bottom: 3.5rem; }

/* Grid Layouts */
.grid-2-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

@media(max-width: 900px) {
    .grid-2-cols {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

/* ==========================================
   HOME SECTION (HERO & PASSIONS & PROJECTS)
   ========================================== */
.hero-container {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 3rem;
    align-items: center;
    padding: 2rem 0 4rem 0;
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 0.5rem;
    background: linear-gradient(to right, #ffffff, var(--text-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.75rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.typed-text {
    color: var(--color-primary);
    font-weight: 600;
}

.hero-description {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    max-width: 550px;
}

.hero-cta-buttons {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
}

/* Floating Card Stack Visuals */
.hero-visual {
    position: relative;
    height: 350px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.floating-card-stack {
    position: relative;
    width: 260px;
    height: 260px;
}

.floating-card {
    position: absolute;
    padding: 0.85rem 1.35rem;
    background: rgba(17, 24, 39, 0.7);
    border: 1px solid var(--border-color);
    border-radius: 0.85rem;
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1.05rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.floating-card i {
    font-size: 1.15rem;
}

.floating-card.c1 {
    top: 10%;
    left: -10%;
    color: var(--color-primary);
    border-color: rgba(59, 130, 246, 0.25);
    animation: float 6s ease-in-out infinite;
}

.floating-card.c2 {
    top: 45%;
    left: 20%;
    color: var(--color-orange);
    border-color: rgba(249, 115, 22, 0.25);
    animation: float 6s ease-in-out infinite 2s;
}

.floating-card.c3 {
    top: 75%;
    left: -15%;
    color: var(--color-green);
    border-color: rgba(16, 185, 129, 0.25);
    animation: float 6s ease-in-out infinite 4s;
}

/* Section Divider */
.section-divider {
    display: flex;
    align-items: center;
    margin: 4rem 0 3rem 0;
}

.section-divider::before, .section-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-color);
}

.section-divider span {
    padding: 0 1.5rem;
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* Passions Cards Grid */
.passions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.75rem;
    margin-bottom: 2rem;
}

.passion-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 1.25rem;
    overflow: hidden;
    cursor: pointer;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    position: relative;
}

.passion-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 1.25rem;
    border: 1px solid transparent;
    pointer-events: none;
    transition: var(--transition-smooth);
    z-index: 2;
}

.passion-card:hover {
    transform: translateY(-5px);
    background: var(--bg-card-hover);
    box-shadow: 0 15px 35px rgba(0,0,0,0.3);
}

/* Color highlights on hover for passion cards */
.passion-card[data-target="sistemistica"]:hover::before { border-color: rgba(59, 130, 246, 0.4); }
.passion-card[data-target="stampa3d"]:hover::before { border-color: rgba(249, 115, 22, 0.4); }
.passion-card[data-target="programmazione"]:hover::before { border-color: rgba(16, 185, 129, 0.4); }
.passion-card[data-target="gaming"]:hover::before { border-color: rgba(139, 92, 246, 0.4); }

.card-image-placeholder {
    height: 140px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    transition: var(--transition-smooth);
}

.card-bg-icon {
    font-size: 4.5rem;
    opacity: 0.12;
    transition: var(--transition-smooth);
}

.passion-card:hover .card-bg-icon {
    transform: scale(1.2) rotate(5deg);
    opacity: 0.22;
}

/* Gradient themes for placeholders */
.passion-sys { background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(59, 130, 246, 0.25)); color: var(--color-primary); }
.passion-3d { background: linear-gradient(135deg, rgba(249, 115, 22, 0.1), rgba(249, 115, 22, 0.25)); color: var(--color-orange); }
.passion-code { background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(16, 185, 129, 0.25)); color: var(--color-green); }
.passion-game { background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(139, 92, 246, 0.25)); color: var(--color-purple); }

.card-body {
    padding: 1.75rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    position: relative;
}

.card-icon {
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    margin-bottom: 1.25rem;
    color: var(--text-secondary);
    transition: var(--transition-smooth);
}

.passion-card:hover .card-icon {
    transform: scale(1.1);
    color: var(--text-primary);
}

/* Icon hover states */
.passion-card[data-target="sistemistica"]:hover .card-icon { background: rgba(59, 130, 246, 0.12); border-color: var(--color-primary); color: var(--color-primary); }
.passion-card[data-target="stampa3d"]:hover .card-icon { background: rgba(249, 115, 22, 0.12); border-color: var(--color-orange); color: var(--color-orange); }
.passion-card[data-target="programmazione"]:hover .card-icon { background: rgba(16, 185, 129, 0.12); border-color: var(--color-green); color: var(--color-green); }
.passion-card[data-target="gaming"]:hover .card-icon { background: rgba(139, 92, 246, 0.12); border-color: var(--color-purple); color: var(--color-purple); }

.card-body h3 {
    font-size: 1.35rem;
    margin-bottom: 0.5rem;
}

.card-excerpt {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    flex-grow: 1;
    line-height: 1.5;
}

.card-more-link {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition-quick);
}

.passion-card:hover .card-more-link {
    color: var(--text-primary);
}

/* Featured Projects Grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.project-card-static {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 1.25rem;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: var(--transition-smooth);
}

.project-card-static:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.project-image {
    height: 200px;
    background-size: cover;
    background-position: center;
    position: relative;
    padding: 1.25rem;
    display: flex;
    align-items: flex-start;
    background-color: #101524;
}

.project-tag {
    background: rgba(11, 15, 25, 0.85);
    border: 1px solid var(--border-color);
    padding: 0.35rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.project-info {
    padding: 1.75rem;
}

.project-info h3 {
    font-size: 1.35rem;
    margin-bottom: 0.75rem;
}

.project-info p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ==========================================
   SISTEMISTICA & DOMOTICA SECTION
   ========================================== */
.services-status-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 1.5rem;
}

.service-status-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    padding: 1rem 1.25rem;
    border-radius: 0.75rem;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 1rem;
    transition: var(--transition-smooth);
}

.service-status-item:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(59, 130, 246, 0.25);
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-indicator.online {
    background-color: var(--color-green);
    box-shadow: 0 0 8px var(--color-green);
}

.service-name {
    font-weight: 600;
    font-size: 0.95rem;
}

.service-name i {
    margin-right: 0.35rem;
    color: var(--text-secondary);
}

.service-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-align: right;
}

.media-placeholder {
    height: 190px;
    border-radius: 0.75rem;
    border: 1px solid var(--border-color);
    background-size: cover;
    background-position: center;
    background-color: #101524;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition-smooth);
}

.media-placeholder:hover {
    border-color: var(--border-hover);
}

.placeholder-icon {
    font-size: 2.25rem;
    opacity: 0.4;
}

/* Nasconde testo e icona quando l'immagine è caricata */
.media-placeholder.has-image {
    border-color: var(--border-hover);
}
.media-placeholder.has-image .placeholder-icon,
.media-placeholder.has-image span {
    display: none !important;
}

/* ==========================================
   PROGRAMMAZIONE & SCRIPTING SECTION
   ========================================== */
.languages-grid {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.lang-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    padding: 1.25rem;
    border-radius: 0.75rem;
    transition: var(--transition-smooth);
}

.lang-item:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(16, 185, 129, 0.25);
}

.lang-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.lang-name {
    font-weight: 700;
    font-size: 1.05rem;
}

.lang-name i {
    margin-right: 0.35rem;
}

.lang-level {
    font-size: 0.75rem;
    font-weight: 600;
    background: rgba(16, 185, 129, 0.1);
    color: var(--color-green);
    border: 1px solid rgba(16, 185, 129, 0.2);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.lang-item p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.github-cta-box {
    background: rgba(16, 185, 129, 0.04);
    border: 1px solid rgba(16, 185, 129, 0.15);
    padding: 1.5rem;
    border-radius: 0.75rem;
    text-align: center;
}

.github-cta-box p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.automation-showcase {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-top: 1.5rem;
}

.auto-item {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    padding: 1.25rem;
    border-radius: 0.75rem;
    transition: var(--transition-smooth);
}

.auto-item:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(16, 185, 129, 0.25);
}

.auto-icon {
    font-size: 1.35rem;
    color: var(--color-green);
    background: rgba(16, 185, 129, 0.1);
    padding: 0.75rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.auto-details h4 {
    font-size: 1.05rem;
    margin-bottom: 0.35rem;
}

.auto-details p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ==========================================
   STAMPA 3D SECTION
   ========================================== */
.workflow-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-top: 1.75rem;
}

.step-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    border-radius: 0.75rem;
    position: relative;
    transition: var(--transition-smooth);
}

.step-card:hover {
    border-color: var(--color-orange);
    background: rgba(249, 115, 22, 0.04);
    transform: translateY(-2px);
}

.step-num {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--color-orange);
    opacity: 0.15;
    position: absolute;
    top: 1rem;
    right: 1rem;
    line-height: 1;
}

.step-card h4 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.step-card p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.materials-list {
    margin-top: 0.75rem;
    padding-left: 1rem;
    list-style-type: disc;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.materials-list li {
    margin-bottom: 0.35rem;
    display: list-item;
}

.materials-list strong {
    color: var(--text-primary);
}

.gallery-static-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-top: 1.5rem;
}

.gallery-card-static {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    overflow: hidden;
    transition: var(--transition-smooth);
}

.gallery-card-static:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
    transform: translateY(-3px);
}

.gallery-img-wrapper {
    height: 240px;
    background-size: cover;
    background-position: center;
    background-color: #101524;
    position: relative;
    display: flex;
    align-items: flex-end;
    padding: 1.5rem;
}

.gallery-category {
    background: var(--color-orange);
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.3rem 0.75rem;
    border-radius: 4px;
    box-shadow: 0 4px 10px rgba(249, 115, 22, 0.3);
}

.gallery-card-body {
    padding: 1.5rem;
}

.gallery-card-body h4 {
    font-size: 1.15rem;
    margin-bottom: 0.5rem;
}

.gallery-card-body p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* ==========================================
   VIDEOGIOCHI & SETUP SECTION
   ========================================== */
.specs-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1.25rem;
}

.specs-table th, .specs-table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
}

.specs-table th {
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.02);
}

.specs-table td {
    color: var(--text-secondary);
}

.specs-table tr:hover td {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.01);
}

.specs-table strong {
    color: var(--text-primary);
}

/* ==========================================
   FOOTER
   ========================================== */
.main-footer {
    background: #060911;
    border-top: 1px solid var(--border-color);
    padding: 2.5rem 2rem;
    margin-top: 5rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

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

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

/* ==========================================
   ANIMATIONS
   ========================================== */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-15px);
    }
}

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

/* ==========================================
   RESPONSIVE DESIGN (MEDIA QUERIES)
   ========================================== */
@media(max-width: 768px) {
    .main-content {
        margin-top: 5.5rem;
        padding: 0 1.5rem;
    }
    
    .hero-container {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 1rem 0 3rem 0;
        text-align: center;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.4rem;
    }
    
    .hero-description {
        margin: 0 auto 2rem auto;
    }
    
    .hero-cta-buttons {
        justify-content: center;
    }
    
    .hero-visual {
        height: 280px;
        order: -1; /* Place visual above text on mobile */
    }
    
    .floating-card-stack {
        width: 200px;
        height: 200px;
    }
    
    .floating-card {
        padding: 0.65rem 1.15rem;
        font-size: 0.95rem;
    }
    
    .floating-card.c1 { top: 5%; left: 0%; }
    .floating-card.c2 { top: 40%; left: 30%; }
    .floating-card.c3 { top: 70%; left: -5%; }
    
    /* Navigation */
    .mobile-nav-toggle {
        display: block;
    }
    
    .nav-menu {
        position: fixed;
        top: 4.5rem;
        left: -100%;
        width: 100%;
        height: calc(100vh - 4.5rem);
        background: rgba(11, 15, 25, 0.98);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        padding: 3rem 2rem;
        transition: var(--transition-smooth);
        border-top: 1px solid var(--border-color);
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-menu ul {
        flex-direction: column;
        gap: 1.5rem;
        align-items: center;
    }
    
    .nav-link {
        font-size: 1.15rem;
        padding: 0.75rem 2rem;
        width: 100%;
        justify-content: center;
    }
    
    .footer-container {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
        flex-wrap: wrap;
    }
}
