:root {
    --bg-primary: #111827;
    --bg-secondary: #1f2937;
    --bg-tertiary: #374151;
    --text-primary: #f9fafb;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    --accent-emerald: #34d399;
    --accent-cyan: #22d3ee;
    --accent-gradient: linear-gradient(135deg, #34d399 0%, #22d3ee 100%);
    --border-color: rgba(255, 255, 255, 0.08);
    --glow-emerald: rgba(52, 211, 153, 0.15);
    --glow-cyan: rgba(34, 211, 238, 0.15);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Container */
.container-wide {
    width: 100%;
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 2rem;
}

@media (min-width: 2000px) {
    .container-wide {
        max-width: 1740px;
    }
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(17, 24, 39, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
}

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    width: 100%;
    padding: 0 2rem;
}

.navbar-brand {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--text-primary);
    flex-shrink: 0;
}

.navbar-brand img {
    max-width: 180px;
    border-radius: 10px;
}

.navbar-title {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    font-weight: 600;
    font-size: 1.125rem;
    color: var(--text-primary);
    white-space: nowrap;
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navbar-nav {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.nav-link:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.nav-cta {
    background: var(--accent-gradient);
    color: var(--bg-primary) !important;
    font-weight: 600;
    padding: 0.625rem 1.25rem;
    border-radius: 50px;
    margin-left: 0.5rem;
}

.nav-cta:hover {
    opacity: 0.9;
    background: var(--accent-gradient);
}

.mobile-only {
    display: none;
}

.navbar-toggler {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero - Design alternativo centrato con visual più grande */
.hero {
    min-height: 72vh;
    padding: 10rem 0 0;
    display: flex;
    align-items: flex-end;
    position: relative;
    overflow: hidden;
}

/* Background decorativo (moved to .hero-parallax-bg for parallax effect) */

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: end;
}

.hero-text {
    max-width: 750px;
    padding-bottom: 2rem;
}

.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.5rem 1rem;
    background: rgba(52, 211, 153, 0.1);
    border: 1px solid rgba(52, 211, 153, 0.2);
    border-radius: 50px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--accent-emerald);
    margin-bottom: 1.75rem;
}

.hero-eyebrow::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--accent-emerald);
    border-radius: 50%;
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }
}

.hero-title {
    font-size: clamp(2.75rem, 4.5vw, 4.5rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
}

.hero-title .gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-description {
    font-size: 1.125rem;
    line-height: 1.75;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    max-width: 700px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2.5rem;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    padding: 1rem 2rem;
    background: var(--accent-gradient);
    color: var(--bg-primary);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(52, 211, 153, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(52, 211, 153, 0.4);
    color: var(--bg-primary);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.75rem;
    background: transparent;
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: 50px;
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    border-color: rgba(255, 255, 255, 0.15);
}

.hero-note {
    font-size: 0.9375rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.hero-visual {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-end;
}

.hero-image-container {
    position: relative;
    max-width: 560px;
    width: 100%;
}

.hero-image-glow {
    position: absolute;
    inset: -20%;
    background: radial-gradient(ellipse at center, var(--glow-emerald) 0%, transparent 70%);
    filter: blur(40px);
    opacity: 0.6;
}

.hero-image {
    position: relative;
}

.hero-image img {
    display: block;
    width: 100%;
    height: auto;
}

/* Section base */
section {
    padding: 7rem 0;
    position: relative;
}

.section-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--accent-emerald);
    margin-bottom: 1rem;
}

.section-title {
    font-size: clamp(2rem, 3.5vw, 3rem);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: 1.25rem;
}

.section-description {
    font-size: 1.0625rem;
    line-height: 1.75;
    color: var(--text-secondary);
    max-width: 640px;
}

/* Come funziona */
.section-alt {
    background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
}

.step-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 2rem;
    transition: all 0.3s ease;
}

.step-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.12);
    transform: translateY(-4px);
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: var(--accent-gradient);
    color: var(--bg-primary);
    font-size: 1.125rem;
    font-weight: 700;
    border-radius: 14px;
    margin-bottom: 1.25rem;
}

.step-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.step-text {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Aree professionali */
.areas-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-end;
    gap: 2rem;
    margin-bottom: 3rem;
}

.areas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.area-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 2rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.area-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-gradient);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.area-card:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.12);
    transform: translateY(-4px);
}

.area-card:hover::before {
    opacity: 1;
}

.area-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    margin-bottom: 1.5rem;
}

.area-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.875rem;
    color: var(--text-primary);
}

.area-text {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.area-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.area-tag {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 0.375rem 0.875rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50px;
    color: var(--text-secondary);
}

/* Perche */
.perche-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.benefits-list {
    list-style: none;
    padding: 0;
    margin: 2rem 0 0;
}

.benefits-list li {
    display: flex;
    gap: 1rem;
    padding: 1rem 0;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-color);
    line-height: 1.65;
}

.benefits-list li:last-child {
    border-bottom: none;
}

.benefits-list .check-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    background: var(--accent-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 2px;
}

.benefits-list .check-icon svg {
    width: 14px;
    height: 14px;
    color: var(--bg-primary);
}

.benefits-list .highlight {
    color: var(--accent-emerald);
}

.highlight-card {
    background: linear-gradient(135deg, rgba(52, 211, 153, 0.08) 0%, rgba(34, 211, 238, 0.05) 100%);
    border: 1px solid rgba(52, 211, 153, 0.2);
    border-radius: 24px;
    padding: 2.5rem;
}

.highlight-card h4 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.highlight-card p {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.75;
    margin-bottom: 1rem;
}

.highlight-card .btn-primary {
    margin-top: 1rem;
}

/* Footer */
footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.footer-copy {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-link {
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-link:hover {
    color: var(--accent-emerald);
}

/* Scroll Reveal Animations */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-right.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Staggered delays for grid children */
.reveal-stagger>.reveal:nth-child(1) {
    transition-delay: 0s;
}

.reveal-stagger>.reveal:nth-child(2) {
    transition-delay: 0.12s;
}

.reveal-stagger>.reveal:nth-child(3) {
    transition-delay: 0.24s;
}

.reveal-stagger>.reveal:nth-child(4) {
    transition-delay: 0.36s;
}

/* Hero parallax background */
.hero-parallax-bg {
    position: absolute;
    top: -15%;
    left: 50%;
    transform: translateX(-50%);
    width: 160%;
    height: 150%;
    background: radial-gradient(ellipse 80% 60% at center top, rgba(52, 211, 153, 0.25) 0%, transparent 55%),
        radial-gradient(ellipse 70% 50% at 65% 75%, rgba(34, 211, 238, 0.2) 0%, transparent 45%),
        radial-gradient(circle at 30% 40%, rgba(52, 211, 153, 0.1) 0%, transparent 35%);
    pointer-events: none;
    will-change: transform;
}

/* Hero entrance animations */
.hero .hero-eyebrow,
.hero .hero-title,
.hero .hero-description,
.hero .hero-actions,
.hero .hero-note {
    opacity: 0;
    transform: translateY(30px);
    animation: heroFadeIn 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero .hero-eyebrow {
    animation-delay: 0.1s;
}

.hero .hero-title {
    animation-delay: 0.25s;
}

.hero .hero-description {
    animation-delay: 0.4s;
}

.hero .hero-actions {
    animation-delay: 0.55s;
}

.hero .hero-note {
    animation-delay: 0.7s;
}

.hero .hero-visual {
    opacity: 0;
    transform: translateY(40px) scale(0.95);
    animation: heroImageIn 1s cubic-bezier(0.16, 1, 0.3, 1) 0.3s forwards;
}

@keyframes heroFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes heroImageIn {
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@media (prefers-reduced-motion: reduce) {

    .reveal,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .hero .hero-eyebrow,
    .hero .hero-title,
    .hero .hero-description,
    .hero .hero-actions,
    .hero .hero-note,
    .hero .hero-visual {
        opacity: 1;
        transform: none;
        animation: none;
    }
}

/* Responsive */
@media (max-width: 1200px) {
    .hero-grid {
        gap: 3rem;
    }
}

@media (max-width: 991px) {
    .navbar-toggler {
        display: block;
    }

    .navbar-title {
        display: none;
    }

    .navbar-nav {
        display: none;
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: rgba(17, 24, 39, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 1rem;
        border-bottom: 1px solid var(--border-color);
    }

    .navbar-nav.show {
        display: flex;
    }

    .desktop-only {
        display: none;
    }

    .mobile-only {
        display: list-item;
    }

    .nav-cta {
        margin-left: 0;
        margin-top: 0.5rem;
        text-align: center;
    }

    .hero {
        padding: 8rem 0 4rem;
        align-items: center;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
        align-items: center;
    }

    .hero-text {
        max-width: 100%;
        padding-bottom: 0;
    }

    .hero-description {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-visual {
        order: -1;
        /*  margin-bottom: 2rem;*/
    }

    .hero-image-container {
        max-width: 400px;
    }

    .perche-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

@media (max-width: 575px) {
    .container-wide {
        padding: 0 1.25rem;
    }

    section {
        padding: 5rem 0;
    }

    .hero-title {
        font-size: 2.25rem;
    }

    .hero-actions {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }

    .steps-grid,
    .areas-grid {
        grid-template-columns: 1fr;
    }

    .areas-header {
        flex-direction: column;
        align-items: flex-start;
    }
}