/* -------------------------------------------------------------
   DESIGN SYSTEM & VARIABLES
   ------------------------------------------------------------- */
:root {
    /* Color Palette */
    --bg-dark: hsl(222, 28%, 7%);
    --bg-darker: hsl(222, 28%, 4%);
    --bg-card: hsla(222, 28%, 12%, 0.55);
    --bg-card-hover: hsla(222, 28%, 16%, 0.75);
    
    --primary: hsl(150, 100%, 40%);        /* Mint/Emerald green */
    --primary-glow: hsla(150, 100%, 40%, 0.15);
    
    --accent: hsl(182, 100%, 45%);         /* Electric cyan */
    --accent-glow: hsla(182, 100%, 45%, 0.25);
    
    --violet: hsl(265, 85%, 64%);         /* Premium violet accent */
    --violet-glow: hsla(265, 85%, 64%, 0.15);
    
    --text-light: hsl(210, 40%, 98%);
    --text-muted: hsl(215, 20%, 75%);
    --text-dim: hsl(215, 12%, 50%);
    
    --border-light: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    
    --shadow-premium: 0 16px 36px -8px rgba(0, 0, 0, 0.5), 0 0 0 1px var(--border-light);
    --shadow-glow: 0 0 30px rgba(0, 255, 150, 0.15);
    
    /* Layout & Fonts */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    
    --nav-height: 80px;
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* -------------------------------------------------------------
   BASE RESET & TYPOGRAPHY
   ------------------------------------------------------------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-light);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

body.modal-open {
    overflow: hidden; /* Blocca lo scorrimento quando un modale è aperto */
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
    color: var(--text-light);
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-fast);
}

/* Scrollbar Customization */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: var(--bg-darker);
}
::-webkit-scrollbar-thumb {
    background: hsla(222, 28%, 20%, 1);
    border: 2px solid var(--bg-darker);
    border-radius: 6px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Utility Containers */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.grid {
    display: grid;
    gap: 30px;
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 991px) {
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 767px) {
    .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

/* Section Common Layouts */
section {
    padding: 100px 0;
    position: relative;
}

.section-header {
    max-width: 700px;
    margin-bottom: 60px;
}

.section-header.align-center {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.section-subtitle {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--primary);
    margin-bottom: 12px;
    padding: 4px 12px;
    border-radius: 30px;
    background: var(--primary-glow);
    border: 1px solid rgba(0, 255, 150, 0.1);
}

.section-title {
    font-size: clamp(2rem, 4vw, 2.75rem);
    margin-bottom: 18px;
    background: linear-gradient(135deg, var(--text-light) 40%, var(--text-muted) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.section-desc {
    font-size: clamp(1rem, 2vw, 1.15rem);
    color: var(--text-muted);
}

/* Glassmorphism Card Style */
.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-light);
    border-radius: 20px;
    padding: 40px;
    box-shadow: var(--shadow-premium);
    transition: var(--transition-smooth);
}

.glass-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-hover);
    transform: translateY(-6px);
}

/* -------------------------------------------------------------
   BUTTON & LINK STYLES
   ------------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    border: none;
    transition: var(--transition-smooth);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: var(--bg-darker);
    box-shadow: 0 4px 20px rgba(0, 255, 180, 0.25);
}

.btn-primary:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 30px rgba(0, 255, 180, 0.45);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-light);
    border: 1px solid var(--border-light);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--border-hover);
    transform: translateY(-2px);
}

.btn-glow {
    position: relative;
}

.btn-glow::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    filter: blur(15px);
    opacity: 0.4;
    z-index: -1;
    transition: var(--transition-smooth);
}

.btn-glow:hover::after {
    opacity: 0.85;
    filter: blur(20px);
}

.btn-full {
    width: 100%;
}

.btn-nav {
    padding: 8px 18px;
    font-size: 0.9rem;
    border-radius: 8px;
    background: var(--primary-glow);
    color: var(--primary);
    border: 1px solid rgba(0, 255, 150, 0.2);
}

.btn-nav:hover {
    background: var(--primary);
    color: var(--bg-darker);
    box-shadow: 0 4px 15px rgba(0, 255, 150, 0.25);
}

/* -------------------------------------------------------------
   HEADER / NAVBAR
   ------------------------------------------------------------- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--nav-height);
    z-index: 1000;
    transition: var(--transition-smooth);
    border-bottom: 1px solid transparent;
}

.navbar.scrolled {
    background: rgba(7, 13, 22, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-light);
    height: 70px;
}

.nav-container {
    max-width: 1240px;
    height: 100%;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Logo Design */
.logo-link {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-icon {
    width: 32px;
    height: 32px;
}

.logo-text {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: 0.05em;
    color: var(--text-light);
}

.logo-text .highlight {
    color: var(--primary);
}

/* Nav Menu */
.nav-menu {
    display: flex;
    align-items: center;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 32px;
}

.nav-item {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-muted);
    position: relative;
    padding: 6px 0;
}

.nav-item::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition-fast);
}

.nav-item:hover {
    color: var(--text-light);
}

.nav-item:hover::after,
.nav-item.active::after {
    width: 100%;
}

.nav-item.active {
    color: var(--primary);
}

/* Hamburger & Drawer Controls */
.nav-cta-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
}

.hamburger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1010;
}

.hamburger .bar {
    display: block;
    width: 24px;
    height: 2px;
    margin: 5px auto;
    background-color: var(--text-light);
    transition: var(--transition-fast);
}

/* -------------------------------------------------------------
   MOBILE DRAWER NAVIGATION
   ------------------------------------------------------------- */
.mobile-drawer {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: var(--bg-darker);
    border-left: 1px solid var(--border-light);
    padding: 100px 30px;
    z-index: 999;
    box-shadow: -10px 0 30px rgba(0,0,0,0.5);
    transition: var(--transition-smooth);
}

.mobile-drawer.open {
    right: 0;
}

.mobile-nav-list {
    display: flex;
    flex-direction: column;
    gap: 24px;
    list-style: none;
}

.mobile-nav-item {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-muted);
    display: block;
}

.mobile-nav-item:hover {
    color: var(--primary);
}

#mobile-cta-btn {
    margin-top: 15px;
}

/* Hamburger Active Animation */
.hamburger.active .bar:nth-child(2) {
    opacity: 0;
}
.hamburger.active .bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.hamburger.active .bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 991px) {
    .nav-menu { display: none; }
    .hamburger { display: block; }
    #cta-nav { display: none; }
}

/* -------------------------------------------------------------
   HERO SECTION
   ------------------------------------------------------------- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: calc(var(--nav-height) + 40px);
    padding-bottom: 60px;
    overflow: hidden;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('assets/hero-bg.png') no-repeat center center;
    background-size: cover;
    opacity: 0.15;
    mix-blend-mode: screen;
    z-index: 0;
    pointer-events: none;
}

/* Glow Background Orbs */
.hero-glow-1 {
    position: absolute;
    top: 10%;
    left: 70%;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
    animation: pulse 12s infinite alternate;
}

.hero-glow-2 {
    position: absolute;
    top: 50%;
    left: -10%;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--violet-glow) 0%, transparent 70%);
    filter: blur(60px);
    pointer-events: none;
    z-index: 0;
    animation: pulse 8s infinite alternate-reverse;
}

.hero-container {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    align-items: center;
    gap: 40px;
}

@media (max-width: 991px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

.hero-content {
    max-width: 650px;
}

@media (max-width: 991px) {
    .hero-content {
        margin: 0 auto;
    }
}

.badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-light);
    color: var(--accent);
    margin-bottom: 24px;
}

.hero-title {
    font-size: clamp(2.3rem, 4.8vw, 3.85rem);
    margin-bottom: 24px;
    font-weight: 800;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 50%, var(--violet) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: flowGrad 6s ease infinite alternate;
}

.hero-lead {
    font-size: clamp(1rem, 2.5vw, 1.15rem);
    color: var(--text-muted);
    margin-bottom: 40px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    margin-bottom: 48px;
}

@media (max-width: 991px) {
    .hero-actions {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .hero-actions {
        flex-direction: column;
    }
}

/* Hero Stats */
.hero-stats {
    display: flex;
    align-items: center;
    gap: 24px;
}

@media (max-width: 991px) {
    .hero-stats {
        justify-content: center;
    }
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-num {
    font-family: var(--font-heading);
    font-size: 1.85rem;
    font-weight: 800;
    color: var(--text-light);
    line-height: 1;
}

.stat-lbl {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 4px;
}

.stat-divider {
    width: 1px;
    height: 35px;
    background: var(--border-light);
}

/* Hero Image Mockup */
.hero-image-wrap {
    position: relative;
    z-index: 1;
}

.hero-screen-mockup {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    background: rgba(20, 30, 48, 0.4);
    border: 1px solid var(--border-hover);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0,0,0,0.6), 0 0 40px var(--primary-glow);
    transform: perspective(1000px) rotateY(-8deg) rotateX(4deg);
    transition: var(--transition-smooth);
}

.hero-screen-mockup:hover {
    transform: perspective(1000px) rotateY(0deg) rotateX(0deg) scale(1.02);
    box-shadow: 0 40px 80px rgba(0,0,0,0.8), 0 0 60px var(--accent-glow);
}

/* MOBILE HERO MOCKUP OPTIMIZATION (No rotate distortion on phones!) */
@media (max-width: 991px) {
    .hero-screen-mockup {
        transform: none !important;
        max-width: 100%;
        margin-top: 40px;
        box-shadow: 0 20px 40px rgba(0,0,0,0.5), 0 0 30px var(--primary-glow);
    }
}

.mockup-bar {
    height: 30px;
    background: rgba(255,255,255,0.03);
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    padding: 0 14px;
    gap: 6px;
}

.mockup-bar .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
}

.mockup-body {
    aspect-ratio: 4/3;
    overflow: hidden;
    position: relative;
}

.hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: left center; /* Sposta a sinistra per mostrare al meglio le particelle luminose */
}

/* -------------------------------------------------------------
   FILOSOFIA / COME FUNZIONA SECTION
   ------------------------------------------------------------- */
.filosofia {
    background: var(--bg-darker);
}

.filosofia-grid {
    margin-top: 40px;
}

.filosofia-card-large {
    display: flex;
    flex-direction: column;
    gap: 20px;
    height: 100%;
}

.card-icon-wrap {
    width: 54px;
    height: 54px;
    background: var(--primary-glow);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    border: 1px solid rgba(0, 255, 150, 0.2);
}

.card-icon-wrap svg {
    width: 28px;
    height: 28px;
}

.filosofia-card-large h3 {
    font-size: 1.5rem;
}

.filosofia-card-large p {
    color: var(--text-muted);
}

.check-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 10px;
}

.check-list li {
    position: relative;
    padding-left: 28px;
    font-size: 0.95rem;
    color: var(--text-light);
    line-height: 1.5;
}

.check-list li::before {
    content: '✓';
    position: absolute;
    left: 4px;
    top: 1px;
    color: var(--primary);
    font-weight: 700;
}

.check-list li.not-included {
    color: var(--text-dim) !important;
    text-decoration: line-through;
    opacity: 0.6;
}

.check-list li.not-included::before {
    content: '✗';
    color: #ff4d4d;
}

/* -------------------------------------------------------------
   SERVIZI SECTION
   ------------------------------------------------------------- */
.servizi-card {
    display: flex;
    flex-direction: column;
    gap: 16px;
    height: 100%;
}

.service-icon {
    width: 48px;
    height: 48px;
    color: var(--accent);
    margin-bottom: 8px;
}

.service-icon svg {
    width: 100%;
    height: 100%;
}

.servizi-card h3 {
    font-size: 1.35rem;
}

.servizi-card p {
    font-size: 0.95rem;
    color: var(--text-muted);
    flex-grow: 1;
}

.card-features {
    list-style: none;
    border-top: 1px solid var(--border-light);
    padding-top: 16px;
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.card-features li {
    font-size: 0.85rem;
    color: var(--text-dim);
    position: relative;
    padding-left: 18px;
}

.card-features li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--accent);
}

.servizi-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
    transition: var(--transition-smooth);
}

/* -------------------------------------------------------------
   PRICING TABLE (LISTINO PREZZI TRASPARENTE)
   ------------------------------------------------------------- */
.pricing-grid {
    margin-top: 40px;
    align-items: stretch;
}

.pricing-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

.pricing-header {
    margin-bottom: 24px;
}

.pricing-header h3 {
    font-size: 1.6rem;
    color: var(--text-light);
    margin-bottom: 8px;
}

.pricing-header p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.pricing-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-top: 16px;
}

.pricing-price .currency {
    font-size: 0.95rem;
    color: var(--text-dim);
    text-transform: uppercase;
}

.pricing-price .price-val {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary);
}

.pricing-body {
    flex-grow: 1;
    margin-bottom: 30px;
    border-top: 1px solid var(--border-light);
    padding-top: 24px;
}

.pricing-body .check-list li {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

/* Featured suggested pricing tier card */
.pricing-card.featured {
    border-color: var(--primary);
    background: hsla(150, 100%, 40%, 0.03);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.6), 0 0 25px rgba(0, 255, 150, 0.05), 0 0 0 1px var(--primary);
}

@media (min-width: 992px) {
    .pricing-card.featured {
        transform: translateY(-10px);
    }
    .pricing-card.featured:hover {
        transform: translateY(-16px);
    }
}

.featured-badge {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: var(--bg-darker);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 6px 16px;
    border-radius: 30px;
    box-shadow: 0 4px 15px rgba(0, 255, 150, 0.3);
    white-space: nowrap;
}

/* -------------------------------------------------------------
   PROCESSO 360° (Timeline)
   ------------------------------------------------------------- */
.processo {
    background: var(--bg-darker);
}

.timeline-interactive {
    max-width: 960px;
    margin: 40px auto 0 auto;
}

.timeline-progress-bar {
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.05);
    border-radius: 4px;
    position: relative;
    margin-bottom: 24px;
}

.progress-fill {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 20%;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    border-radius: 4px;
    transition: var(--transition-smooth);
}

.timeline-steps {
    display: flex;
    justify-content: space-between;
    list-style: none;
    position: relative;
    margin-bottom: 48px;
}

.step-btn {
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    z-index: 2;
    width: 120px;
    transition: var(--transition-smooth);
}

.step-btn .step-num {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-darker);
    border: 2px solid var(--border-light);
    color: var(--text-dim);
    font-weight: 700;
    font-family: var(--font-heading);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}

.step-btn .step-title {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-dim);
    transition: var(--transition-smooth);
}

/* Hover/Active states */
.step-btn:hover .step-num {
    border-color: var(--text-muted);
    color: var(--text-light);
}

.step-btn.active .step-num {
    background: var(--bg-dark);
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
}

.step-btn.active .step-title {
    color: var(--primary);
    font-weight: 700;
}

/* Pane logic */
.timeline-content-wrap {
    min-height: 280px;
}

.timeline-pane {
    display: none;
    animation: fadeIn 0.4s ease forwards;
}

.timeline-pane.active {
    display: block;
}

.pane-content {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 40px;
    align-items: center;
}

@media (max-width: 767px) {
    .pane-content {
        grid-template-columns: 1fr;
    }
    .pane-visual { display: none; }
    .timeline-steps {
        overflow-x: auto;
        justify-content: flex-start;
        gap: 16px;
        padding-bottom: 12px;
    }
    .step-btn {
        flex-shrink: 0;
    }
}

.pane-text h3 {
    font-size: 1.6rem;
    margin-bottom: 16px;
    color: var(--primary);
}

.pane-text p {
    color: var(--text-muted);
    margin-bottom: 24px;
}

.pane-visual {
    display: flex;
    justify-content: center;
}

.visual-placeholder {
    width: 140px;
    height: 140px;
    background: var(--bg-dark);
    border-radius: 50%;
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    box-shadow: inset 0 0 20px rgba(0,0,0,0.6);
}

.visual-placeholder svg {
    width: 60px;
    height: 60px;
}

/* -------------------------------------------------------------
   INTERACTIVE BUDGET ESTIMATOR
   ------------------------------------------------------------- */
.estimator-container {
    max-width: 1040px;
    margin: 0 auto;
}

.estimator-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 40px;
}

@media (max-width: 991px) {
    .estimator-grid {
        grid-template-columns: 1fr;
    }
}

.estimator-options {
    display: flex;
    flex-direction: column;
    gap: 36px;
}

.option-group h4 {
    font-size: 1.05rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 16px;
}

/* Option Cards (Radio style) */
.radio-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

@media (max-width: 575px) {
    .radio-cards {
        grid-template-columns: 1fr;
    }
}

.radio-card {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border-light);
    padding: 16px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: var(--transition-fast);
    position: relative;
}

.radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.radio-card .card-title {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-light);
}

.radio-card .card-desc {
    font-size: 0.8rem;
    color: var(--text-dim);
    line-height: 1.3;
}

.radio-card:hover {
    background: rgba(255,255,255,0.04);
    border-color: var(--border-hover);
}

.radio-card.active {
    background: var(--primary-glow);
    border-color: var(--primary);
    box-shadow: 0 0 15px rgba(0, 255, 150, 0.05);
}

/* Slider custom styles */
.range-wrap {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border-light);
    padding: 24px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 24px;
}

@media (max-width: 575px) {
    .range-wrap {
        flex-direction: column;
        align-items: stretch;
    }
}

.range-slider {
    flex-grow: 1;
    -webkit-appearance: none;
    height: 6px;
    border-radius: 3px;
    background: rgba(255,255,255,0.1);
    outline: none;
}

.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0,255,150,0.5);
    transition: var(--transition-fast);
}

.range-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

.range-val {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--text-light);
    white-space: nowrap;
    text-align: right;
}

.range-val span {
    color: var(--primary);
}

/* Checkbox Cards */
.checkbox-cards {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.checkbox-card {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border-light);
    padding: 16px 20px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: var(--transition-fast);
    position: relative;
}

.checkbox-card input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
    cursor: pointer;
}

.checkbox-card .cb-title {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-light);
}

.checkbox-card .cb-desc {
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-left: auto;
}

@media (max-width: 575px) {
    .checkbox-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    .checkbox-card .cb-desc {
        margin-left: 0;
    }
}

.checkbox-card:hover {
    background: rgba(255,255,255,0.04);
    border-color: var(--border-hover);
}

.checkbox-card.active {
    background: var(--accent-glow);
    border-color: var(--accent);
}

/* Result panel side sticky */
.estimator-result {
    position: relative;
}

.result-sticky {
    position: sticky;
    top: calc(var(--nav-height) + 20px);
    background: rgba(255,255,255,0.015);
    border: 1px solid rgba(255,255,255,0.06);
    box-shadow: inset 0 20px 40px rgba(255,255,255,0.01);
    border-radius: 16px;
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.result-sticky h3 {
    font-size: 1.35rem;
    font-weight: 600;
}

.result-divider {
    height: 1px;
    background: var(--border-light);
}

.price-output {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 4px;
    padding: 10px 0;
}

.price-output .currency {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary);
    margin-top: 4px;
}

.price-output .price-val {
    font-family: var(--font-heading);
    font-size: 4rem;
    font-weight: 800;
    color: var(--text-light);
    line-height: 0.9;
    letter-spacing: -0.03em;
    animation: scaleIn 0.3s ease;
}

.price-note {
    font-size: 0.8rem;
    color: var(--text-dim);
    text-align: center;
}

.result-specs {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 10px 0;
}

.spec-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
}

.spec-lbl {
    color: var(--text-muted);
}

.spec-val {
    font-weight: 600;
    color: var(--text-light);
}

.result-foot {
    font-size: 0.75rem;
    color: var(--text-dim);
    text-align: center;
}

/* -------------------------------------------------------------
   PORTFOLIO SHOWCASE
   ------------------------------------------------------------- */
.portfolio {
    background: var(--bg-darker);
}

.portfolio-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding: 0;
    cursor: pointer; /* Indica che è cliccabile per aprire i modali */
}

.portfolio-img-wrap {
    aspect-ratio: 16/10;
    width: 100%;
    overflow: hidden;
    position: relative;
    border-bottom: 1px solid var(--border-light);
    border-top-left-radius: 20px;
    border-top-right-radius: 20px;
}

.portfolio-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

.portfolio-hover {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(7, 13, 22, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition-smooth);
}

.portfolio-card:hover .portfolio-img {
    transform: scale(1.05);
}

.portfolio-card:hover .portfolio-hover {
    opacity: 1;
}

.portfolio-info {
    padding: 30px;
}

.proj-tag {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.portfolio-info h3 {
    font-size: 1.45rem;
    margin-bottom: 12px;
}

.portfolio-info p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 20px;
    line-height: 1.5;
}

.proj-results {
    display: flex;
    gap: 20px;
    border-top: 1px solid var(--border-light);
    padding-top: 16px;
}

.res-item {
    font-size: 0.85rem;
    color: var(--text-light);
}

.res-item strong {
    color: var(--primary);
    font-family: var(--font-heading);
}

/* -------------------------------------------------------------
   FAQ SECTION (Accordions)
   ------------------------------------------------------------- */
.faq-list {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.faq-item {
    padding: 0;
    overflow: hidden;
}

.faq-trigger {
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    padding: 24px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text-light);
}

.faq-icon {
    position: relative;
    width: 16px;
    height: 16px;
}

.faq-icon::before,
.faq-icon::after {
    content: '';
    position: absolute;
    background: var(--primary);
    transition: var(--transition-fast);
}

/* horizontal bar */
.faq-icon::before {
    top: 7px;
    left: 0;
    width: 100%;
    height: 2px;
}

/* vertical bar */
.faq-icon::after {
    top: 0;
    left: 7px;
    width: 2px;
    height: 100%;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    padding: 0 30px;
}

.faq-answer p {
    color: var(--text-muted);
    font-size: 0.95rem;
    padding-bottom: 24px;
    line-height: 1.6;
}

/* Active FAQ animations */
.faq-item.active .faq-icon::after {
    transform: rotate(90deg);
    opacity: 0;
}

.faq-item.active .faq-icon::before {
    background: var(--accent);
}

.faq-item.active {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
}

/* -------------------------------------------------------------
   CONTACTS SECTION (Form & Direct Mail)
   ------------------------------------------------------------- */
.contatti {
    background: var(--bg-darker);
}

.contatti-grid {
    align-items: flex-start;
}

.info-card {
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.info-card h3 {
    font-size: 1.6rem;
    color: var(--accent);
}

.info-card p {
    color: var(--text-muted);
}

.info-links {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 10px;
}

.info-link-item {
    display: flex;
    align-items: center;
    gap: 16px;
}

.ili-icon {
    width: 44px;
    height: 44px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
}

.ili-icon svg {
    width: 20px;
    height: 20px;
}

.ili-text {
    display: flex;
    flex-direction: column;
}

.ili-text span {
    font-size: 0.8rem;
    color: var(--text-dim);
}

.ili-text strong {
    font-size: 0.95rem;
    color: var(--text-light);
}

/* E-mail Direct Client Button */
.btn-mail-direct {
    background: var(--primary-glow);
    color: var(--primary);
    border: 1px solid rgba(0, 255, 150, 0.25);
    margin-top: 24px;
}

.btn-mail-direct:hover {
    background: var(--primary);
    color: var(--bg-darker);
    box-shadow: 0 8px 25px rgba(0, 255, 150, 0.35);
    transform: translateY(-2px);
}

/* Form Styles */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-row {
    width: 100%;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.form-group label {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

.form-group input,
.form-group textarea {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 12px 16px;
    color: var(--text-light);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: var(--transition-fast);
    outline: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-dim);
}

.form-group input:focus,
.form-group textarea:focus {
    background: rgba(255,255,255,0.04);
    border-color: var(--accent);
    box-shadow: 0 0 15px rgba(0, 220, 255, 0.15);
}

.form-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.form-checkbox input {
    margin-top: 4px;
    accent-color: var(--primary);
}

.form-checkbox label {
    font-size: 0.75rem;
    color: var(--text-dim);
    line-height: 1.4;
    cursor: pointer;
}

/* Success State Styles */
.form-success-message {
    display: none;
    background: rgba(0, 255, 150, 0.08);
    border: 1px solid var(--primary);
    padding: 16px;
    border-radius: 8px;
    align-items: center;
    gap: 12px;
    color: var(--text-light);
    font-size: 0.9rem;
    animation: fadeIn 0.4s ease;
}

.form-success-message svg {
    width: 24px;
    height: 24px;
    color: var(--primary);
    flex-shrink: 0;
}

.contact-form.success-active input,
.contact-form.success-active textarea,
.contact-form.success-active .form-checkbox,
.contact-form.success-active #form-submit-btn,
.contact-form.success-active label {
    display: none;
}

.contact-form.success-active .form-success-message {
    display: flex;
}

/* -------------------------------------------------------------
   FOOTER SECTION
   ------------------------------------------------------------- */
.main-footer {
    background: var(--bg-darker);
    border-top: 1px solid var(--border-light);
    padding-top: 80px;
}

.footer-container {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 60px;
    padding-bottom: 50px;
}

@media (max-width: 991px) {
    .footer-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

.footer-brand {
    max-width: 320px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.footer-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.footer-links-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 767px) {
    .footer-links-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
}
@media (max-width: 480px) {
    .footer-links-grid {
        grid-template-columns: 1fr;
    }
}

.footer-column h4 {
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary);
    margin-bottom: 20px;
}

.footer-column ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-column ul a {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.footer-column ul a:hover {
    color: var(--primary);
    padding-left: 4px;
}

.footer-column p {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.footer-bottom {
    border-top: 1px solid var(--border-light);
    padding: 30px 0;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    font-size: 0.8rem;
    color: var(--text-dim);
}

@media (max-width: 767px) {
    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
    }
}

.footer-legal {
    display: flex;
    gap: 20px;
}

.footer-legal a:hover {
    color: var(--text-light);
}

/* -------------------------------------------------------------
   INTERACTIVE PORTFOLIO MODALS
   ------------------------------------------------------------- */
.portfolio-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    display: none; /* Gestito tramite JS */
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.portfolio-modal.active {
    display: flex;
}

.modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(7, 13, 22, 0.75);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 0;
    animation: modalFadeIn 0.3s ease forwards;
}

.modal-wrapper {
    position: relative;
    width: 100%;
    max-width: 1080px;
    max-height: 90vh;
    z-index: 1;
    overflow-y: auto;
    border-radius: 24px;
    box-shadow: var(--shadow-premium), 0 25px 50px -12px rgba(0,0,0,0.8);
    scrollbar-width: thin;
    animation: modalScaleIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Elegant close button inside glassmorphism card */
.modal-content {
    position: relative;
    padding: 48px;
    background: hsla(222, 28%, 10%, 0.85); /* Slightly darker for modal readability */
}

@media (max-width: 767px) {
    .modal-content {
        padding: 30px 20px;
    }
}

.modal-close {
    position: absolute;
    top: 24px;
    right: 24px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border-light);
    color: var(--text-muted);
    font-size: 2.2rem;
    font-weight: 300;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    line-height: 1;
    transition: var(--transition-fast);
    z-index: 10;
}

.modal-close:hover {
    background: rgba(255,255,255,0.1);
    color: var(--primary);
    border-color: var(--primary);
    transform: rotate(90deg);
}

.modal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

@media (max-width: 991px) {
    .modal-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

.modal-visual {
    width: 100%;
    aspect-ratio: 16/12;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border-light);
    box-shadow: 0 15px 30px rgba(0,0,0,0.4);
}

.modal-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.modal-info h3 {
    font-size: clamp(1.6rem, 3vw, 2rem);
    background: linear-gradient(135deg, var(--text-light) 40%, var(--text-muted) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.modal-lead {
    font-size: 1.05rem;
    color: var(--text-muted);
    line-height: 1.5;
    font-weight: 500;
}

.modal-section h4 {
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary);
    margin-bottom: 8px;
}

.modal-section p {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* Specs Highlight Table */
.modal-specs-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    border-top: 1px solid var(--border-light);
    border-bottom: 1px solid var(--border-light);
    padding: 20px 0;
    margin: 10px 0;
}

@media (max-width: 480px) {
    .modal-specs-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

.modal-spec-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.msi-lbl {
    font-size: 0.75rem;
    color: var(--text-dim);
    text-transform: uppercase;
}

.msi-val {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-light);
    line-height: 1.3;
}

.modal-actions {
    margin-top: 10px;
}

.modal-cta-btn {
    width: 100%;
    padding: 16px;
}

/* Modals Keyframes Animations */
@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes modalScaleIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* -------------------------------------------------------------
   SCROLL REVEAL ANIMATIONS
   ------------------------------------------------------------- */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-on-scroll.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Helper Delays */
.delay-1 { transition-delay: 0.15s; }
.delay-2 { transition-delay: 0.3s; }
.delay-3 { transition-delay: 0.45s; }
.delay-4 { transition-delay: 0.6s; }

/* CSS Keyframes */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.4; }
    100% { transform: scale(1.08); opacity: 0.65; }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes flowGrad {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Initial fade states for Hero on load */
.fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUpAnim 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeInUpAnim {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
