/* ==================== STILI VECCHI (mantenuti per compatibilità) ==================== */

.welcome-container {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
    padding: 1rem;
}

.welcome-container h2 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.welcome-container p {
    font-size: 1rem;
    line-height: 1.5;
    color: #444;
}

.welcome-container p b {
    background-color: var(--arancio, #ffc107);
    color: #fff;
    padding: 4px 6px;
    border-radius: 4px;
}

.category-container-personalizzato {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

.category-link-personalizzato {
    text-decoration: none;
    color: inherit;
}

.pill-button-personalizzato {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 140px;
    height: 48px;
    border-radius: 24px;
    padding: 0 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: none;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: background 0.3s ease, transform 0.2s ease;
    cursor: pointer;
    color: #fff;
}

.pill-button-personalizzato:hover {
    transform: translateY(-2px) scale(1.02);
}

.pill-button-personalizzato:active {
    transform: translateY(1px) scale(0.98);
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.pill-button-personalizzato.blue {
    background: linear-gradient(135deg, #2196f3 0%, #64b5f6 100%);
}

.pill-button-personalizzato.yellow {
    background: linear-gradient(135deg, #ffeb3b 0%, #ffc107 100%);
    color: #333;
}

.pill-button-personalizzato.red {
    background: linear-gradient(135deg, #f44336 0%, #e53935 100%);
}

.pill-button-personalizzato.green {
    background: linear-gradient(135deg, #4caf50 0%, #43a047 100%);
}

.pill-button-personalizzato.purple {
    background: linear-gradient(135deg, #9c27b0 0%, #7b1fa2 100%);
}

/* ==================== NUOVO DESIGN GESTIONE LEAD ==================== */

.lead-selection-container {
    min-height: calc(100vh - 8rem);
    padding: 3rem 2rem;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8f0 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
}

.lead-welcome-section {
    text-align: center;
    max-width: 700px;
    animation: fadeInDown 0.8s ease-out;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.welcome-icon {
    font-size: 4rem;
    color: var(--blu);
    margin-bottom: 1rem;
    animation: pulse 2s ease-in-out infinite;
}

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

.lead-title {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--blu) 0%, var(--arancio) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.lead-subtitle {
    font-size: 1.2rem;
    color: #555;
    margin-bottom: 0.5rem;
}

.user-badge {
    background: linear-gradient(135deg, var(--arancio) 0%, var(--rosso) 100%);
    color: white;
    padding: 0.3rem 1rem;
    border-radius: 20px;
    font-weight: 700;
    display: inline-block;
    box-shadow: 0 4px 15px rgba(255, 191, 81, 0.4);
}

.lead-description {
    font-size: 1rem;
    color: #777;
    margin-top: 1rem;
}

.lead-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1000px;
    width: 100%;
    animation: fadeInUp 0.8s ease-out 0.3s backwards;
}

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

.lead-card {
    position: relative;
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
    min-height: 320px;
}

.lead-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    transition: height 0.4s ease;
}

.lead-card-appointments::before {
    background: linear-gradient(90deg, var(--blu) 0%, #44badc 100%);
}

.lead-card-nexi::before {
    background: linear-gradient(90deg, var(--arancio) 0%, var(--rosso) 100%);
}

.lead-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

.lead-card:hover::before {
    height: 100%;
    opacity: 0.05;
}

.lead-card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.lead-card-appointments .lead-card-overlay {
    background: radial-gradient(circle at center, rgba(0, 107, 166, 0.1) 0%, transparent 70%);
}

.lead-card-nexi .lead-card-overlay {
    background: radial-gradient(circle at center, rgba(255, 191, 81, 0.1) 0%, transparent 70%);
}

.lead-card:hover .lead-card-overlay {
    opacity: 1;
}

.lead-card-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    transition: all 0.4s ease;
}

.lead-card-appointments .lead-card-icon {
    color: var(--blu);
}

.lead-card-nexi .lead-card-icon {
    color: var(--arancio);
}

.lead-card:hover .lead-card-icon {
    transform: scale(1.1) rotate(5deg);
}

.lead-card-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    transition: color 0.3s ease;
}

.lead-card-appointments:hover .lead-card-title {
    color: var(--blu);
}

.lead-card-nexi:hover .lead-card-title {
    color: var(--arancio);
}

.lead-card-description {
    font-size: 1rem;
    color: #666;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.lead-card-arrow {
    font-size: 2rem;
    opacity: 0;
    transform: translateX(-20px);
    transition: all 0.4s ease;
    margin-top: auto;
}

.lead-card-appointments .lead-card-arrow {
    color: var(--blu);
}

.lead-card-nexi .lead-card-arrow {
    color: var(--arancio);
}

.lead-card:hover .lead-card-arrow {
    opacity: 1;
    transform: translateX(0);
}

.lead-stats-section {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: center;
    animation: fadeInUp 0.8s ease-out 0.6s backwards;
}

.stat-box {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    background: white;
    border-radius: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    font-size: 0.9rem;
    color: #555;
    font-weight: 600;
    transition: all 0.3s ease;
}

.stat-box i {
    font-size: 1.5rem;
    color: var(--blu);
}

.stat-box:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

/* Responsive */
@media (max-width: 768px) {
    .lead-selection-container {
        padding: 1.5rem 1rem 8rem 1rem;
        gap: 1.5rem;
        min-height: calc(100vh - 12rem);
    }

    .lead-welcome-section {
        max-width: 100%;
        padding: 0 0.5rem;
    }

    .lead-title {
        font-size: 1.8rem;
        line-height: 1.2;
    }

    .welcome-icon {
        font-size: 2.5rem;
        margin-bottom: 0.8rem;
    }

    .lead-subtitle {
        font-size: 1rem;
    }

    .lead-description {
        font-size: 0.9rem;
        margin-top: 0.8rem;
    }

    .lead-cards-grid {
        grid-template-columns: 1fr;
        gap: 1.2rem;
        padding: 0;
    }

    .lead-card {
        padding: 1.8rem 1.5rem;
        min-height: 240px;
        width: 100%;
        max-width: 100%;
    }

    .lead-card-icon {
        font-size: 2.8rem;
        margin-bottom: 1rem;
    }

    .lead-card-title {
        font-size: 1.4rem;
    }

    .lead-card-description {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }

    .lead-stats-section {
        gap: 0.8rem;
        padding: 0 1rem;
    }

    .stat-box {
        font-size: 0.75rem;
        padding: 0.5rem 1rem;
    }

    .stat-box i {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .lead-selection-container {
        padding: 1rem 0.8rem 8rem 0.8rem;
        gap: 1.2rem;
    }

    .lead-title {
        font-size: 1.5rem;
    }

    .welcome-icon {
        font-size: 2rem;
    }

    .lead-subtitle {
        font-size: 0.9rem;
    }

    .user-badge {
        display: inline-block;
        margin: 0.3rem 0;
        padding: 0.25rem 0.8rem;
        font-size: 0.9rem;
    }

    .lead-description {
        font-size: 0.85rem;
    }

    .lead-card {
        padding: 1.5rem 1.2rem;
        min-height: 200px;
        border-radius: 15px;
    }

    .lead-card-icon {
        font-size: 2.5rem;
    }

    .lead-card-title {
        font-size: 1.3rem;
    }

    .lead-card-description {
        font-size: 0.85rem;
    }

    .lead-card-arrow {
        font-size: 1.5rem;
    }

    .lead-stats-section {
        flex-direction: column;
        gap: 0.6rem;
        width: 100%;
        padding: 0 0.5rem;
    }

    .stat-box {
        width: 100%;
        justify-content: center;
        padding: 0.6rem;
    }
}