a:hover{
    color: #015096;
}

.hover-text-blue:hover{
    color: #015096;
}

.ct-active{
    color: #015096 !important;
}

.badge-pic-number{
    background-color: #015096;
    color: #fff;
    padding: 15px 30px;
    border-radius: 5px;
    display: inline-block;
    margin-bottom: 20px;
}

.badge-pic-number-text{
    font-size: 2.5rem;
    line-height: 2.5rem;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
}


.mobile-margin-top-menu {
    margin-top: 145px;
    border-top: 1px solid #e5e5e5;
    border-bottom: 1px solid #e5e5e5;
    padding: 10px 0;
}

@media (max-width: 991px) {
    .mobile-margin-top-menu {
        margin-top: 8px;
    }
}

/* Logos horizontal scroll */
.logos-scroll-container {
    overflow: visible; /* Cambiato da hidden a visible */
    position: relative;
    cursor: grab;
    padding: 20px 0; /* Aggiungo padding per evitare tagli */
}

.logos-scroll-container:active {
    cursor: grabbing;
}

.logos-scroll-wrapper {
    display: flex;
    gap: 2rem;
    animation: scroll-logos 30s linear infinite;
    width: max-content;
    user-select: none;
    cursor: grab;
    position: relative; /* Aggiunto per il drag */
}

.logos-scroll-wrapper.dragging {
    animation-play-state: paused;
    cursor: grabbing;
}

.logos-scroll-wrapper:hover {
    animation-play-state: paused;
}

.logo-item {
    flex-shrink: 0;
    text-align: center;
    min-width: 150px;
    pointer-events: none; /* Previene click sui loghi durante il drag */
}

.logo-item img {
    transition: transform 0.3s ease;
    pointer-events: auto; /* Riabilita click sulle immagini */
}

.logo-item:hover img {
    transform: scale(1.1);
}

@keyframes scroll-logos {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .logos-scroll-wrapper {
        gap: 1rem;
    }
    
    .logo-item {
        min-width: 120px;
    }
}

/* ============================================================================
   IMAGE ERROR HANDLING STYLES
   ============================================================================ */

.image-error-placeholder {
    background-color: #f8f9fa;
    border: 2px dashed #dee2e6;
    border-radius: 8px;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.image-error-placeholder:hover {
    opacity: 1;
}

/* Placeholder per diverse categorie */
.image-error-placeholder[data-category="gallery"] {
    background-color: #f1f3f4;
    border-color: #dadce0;
}

.image-error-placeholder[data-category="product"] {
    background-color: #fef7e0;
    border-color: #fbcf33;
}

.image-error-placeholder[data-category="blog"] {
    background-color: #e8f0fe;
    border-color: #4285f4;
}

.image-error-placeholder[data-category="category"] {
    background-color: #f3e8ff;
    border-color: #8b5cf6;
}

/* Stile per il container delle immagini con errore */
.image-container-error {
    position: relative;
    display: inline-block;
}

.image-container-error::after {
    content: "⚠️ Immagine non disponibile";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.image-container-error:hover::after {
    opacity: 1;
}

/* Stili responsivi per i placeholder */
@media (max-width: 768px) {
    .image-error-placeholder {
        border-width: 1px;
        border-radius: 4px;
    }
    
    .image-container-error::after {
        font-size: 10px;
        padding: 4px 8px;
    }
}

/* ============================================================================
   HOMEPAGE CATEGORIES STYLES
   ============================================================================ */

/* Layout verticale per le categorie (height > width) */
#categories .category-vertical {
    position: relative !important;
    height: 100%;
    display: block;
    overflow: hidden;
    border-radius: 8px;
    background: #000;
}

#categories .category-vertical .blog-image {
    position: relative !important;
    width: 100% !important;
    padding-bottom: 150% !important; /* Aspect ratio verticale: 2:3 (height > width) */
    overflow: hidden !important;
    margin: 0 !important;
    display: block !important;
    background: #000 !important;
    height: 0 !important;
    /* Sovrascrive le transform del tema che spostano l'immagine */
    transform: translate3d(0, 0, 0) !important;
    -webkit-transform: translate3d(0, 0, 0) !important;
    -moz-transform: translate3d(0, 0, 0) !important;
    -ms-transform: translate3d(0, 0, 0) !important;
}

#categories .category-vertical:hover .blog-image {
    /* Mantiene l'animazione ma senza spostare l'immagine */
    transform: translate3d(0, 0, 0) !important;
    -webkit-transform: translate3d(0, 0, 0) !important;
    -moz-transform: translate3d(0, 0, 0) !important;
    -ms-transform: translate3d(0, 0, 0) !important;
    width: 100% !important;
}

#categories .category-vertical .blog-image img {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center center !important;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform, opacity;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    min-width: 100% !important;
    min-height: 100% !important;
}

/* Overlay che appare al hover */
#categories .category-vertical .blog-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(1, 80, 150, 0.3) 0%, rgba(1, 80, 150, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
    pointer-events: none;
}

#categories .category-vertical:hover .blog-image img {
    transform: translate(-50%, -50%) scale(1.15) !important;
    filter: brightness(1.1);
}

#categories .category-vertical:hover .blog-image::after {
    opacity: 1;
}

#categories .category-vertical .blog-post-details {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    padding: 30px 20px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.75) 50%, rgba(0, 0, 0, 0.3) 80%, transparent 100%);
    z-index: 2;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    transform: translateY(10px);
    opacity: 0.95;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

#categories .category-vertical:hover .blog-post-details {
    transform: translateY(0);
    opacity: 1;
    padding-bottom: 35px;
}

#categories .category-vertical .post-details {
    width: auto;
    max-width: 90%;
    margin: 0;
    text-align: center;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
    transform: translateY(5px);
    opacity: 0.9;
}

#categories .category-vertical:hover .post-details {
    transform: translateY(0);
    opacity: 1;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

/* Responsive adjustments per categorie */
@media (max-width: 1199px) {
    #categories .category-vertical .blog-image {
        padding-bottom: 140%;
    }
}

@media (max-width: 991px) {
    #categories .category-vertical .blog-image {
        padding-bottom: 130%;
    }
}

@media (max-width: 767px) {
    #categories .category-vertical .blog-image {
        padding-bottom: 120%;
    }
    
    #categories .category-vertical .blog-post-details {
        padding: 20px 15px;
    }
    
    #categories .category-vertical .post-details {
        padding: 10px 15px !important;
        font-size: 14px !important;
    }
    
    #categories .category-vertical:hover .blog-image img {
        transform: translate(-50%, -50%) scale(1.08) !important;
    }
}

/* ============================================================================
   HEADER USER DROPDOWN STYLES
   ============================================================================ */

.header-user .dropdown-menu {
    min-width: 280px;
    padding: 0;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    margin-top: 8px;
}

/* Ponte invisibile per mantenere l'hover tra icona e dropdown */
.header-user .dropdown-menu::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 0;
    right: 0;
    height: 8px;
    background: transparent;
}

/* User Info Header - Sezione superiore con avatar */
.header-user .user-info-header {
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px 8px 0 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-user .user-avatar {
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.header-user .user-avatar i {
    font-size: 24px;
    color: white;
}

.header-user .user-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow: hidden;
}

.header-user .user-name {
    color: white;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.3;
    display: block;
}

.header-user .user-email {
    color: rgba(255, 255, 255, 0.85);
    font-size: 12px;
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Menu Links */
.header-user .dropdown-menu li a {
    padding: 12px 20px;
    color: #2d3748;
    text-decoration: none;
    display: flex;
    align-items: center;
    transition: all 0.2s ease;
    font-size: 14px;
}

.header-user .dropdown-menu li a:hover {
    background-color: #f7fafc;
    color: #667eea;
    padding-left: 24px;
}

.header-user .dropdown-menu li a i {
    font-size: 16px;
    opacity: 0.7;
}

/* Logout Item - Stile speciale */
.header-user .logout-item a {
    color: #dc3545;
}

.header-user .logout-item a:hover {
    background-color: #fff5f5;
    color: #c82333;
}

/* Login Prompt - Per utenti non loggati */
.header-user .login-prompt {
    padding: 16px 20px 0;
    text-align: center;
}

.header-user .login-prompt p {
    margin: 0;
    color: #718096;
    font-size: 13px;
}

/* Login Item - Bottone evidenziato */
.header-user .login-item {
    padding: 0 20px 16px;
}

.header-user .login-item a {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white !important;
    text-align: center;
    justify-content: center;
    border-radius: 6px;
    padding: 12px 20px !important;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.header-user .login-item a:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
    padding-left: 20px !important;
}

/* Divider */
.header-user .dropdown-divider {
    margin: 0;
    border-top: 1px solid #e2e8f0;
}

/* ============================================================================
   DASHBOARD STYLES
   ============================================================================ */

.dashboard-container {
    padding: 60px 0;
    min-height: calc(100vh - 200px);
}

.dashboard-sidebar {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    padding: 0;
    position: sticky;
    top: 180px;
}

.dashboard-sidebar .nav-link {
    padding: 16px 24px;
    color: #2d3748;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 12px;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
    font-weight: 500;
}

.dashboard-sidebar .nav-link:hover {
    background-color: #f8f9fa;
    border-left-color: #007bff;
    color: #007bff;
}

.dashboard-sidebar .nav-link.active {
    background-color: #e7f3ff;
    border-left-color: #007bff;
    color: #007bff;
    font-weight: 600;
}

.dashboard-sidebar .nav-link i {
    font-size: 18px;
}

.dashboard-content {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    padding: 40px;
}

.dashboard-welcome h2 {
    font-size: 32px;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 12px;
}

.dashboard-welcome p {
    color: #718096;
    font-size: 16px;
}

.quick-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.quick-link-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    padding: 30px 20px;
    text-align: center;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.quick-link-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 123, 255, 0.2);
    border-color: #007bff;
    text-decoration: none;
}

.quick-link-card i {
    font-size: 40px;
    margin-bottom: 16px;
    display: block;
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.quick-link-card h5 {
    color: #2d3748;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 18px;
}

.quick-link-card p {
    color: #718096;
    font-size: 14px;
    margin: 0;
}

/* Account Type Selector */
.account-type-option {
    position: relative;
}

.account-type-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.account-type-label {
    display: flex;
    align-items: center;
    padding: 20px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    background-color: #ffffff;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    margin-bottom: 0;
}

.account-type-label:hover {
    border-color: #007bff;
    background-color: #f8f9ff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.15);
}

.account-type-option input[type="radio"]:checked + .account-type-label {
    border-color: #007bff;
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    color: white;
    box-shadow: 0 6px 20px rgba(0, 123, 255, 0.3);
    transform: translateY(-2px);
}

.account-type-option input[type="radio"]:checked + .account-type-label .account-type-icon {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
}

.account-type-option input[type="radio"]:checked + .account-type-label .account-type-title {
    color: white;
    font-weight: 600;
}

.account-type-option input[type="radio"]:checked + .account-type-label .account-type-subtitle {
    color: rgba(255, 255, 255, 0.9);
}

.account-type-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 10px;
    background-color: #f8f9fa;
    color: #6c757d;
    margin-right: 16px;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.account-type-icon i {
    font-size: 20px;
}

.account-type-content {
    flex: 1;
}

.account-type-title {
    font-size: 16px;
    font-weight: 500;
    color: #212529;
    margin-bottom: 4px;
    transition: all 0.3s ease;
}

.account-type-subtitle {
    font-size: 14px;
    color: #6c757d;
    line-height: 1.4;
    transition: all 0.3s ease;
}

/* Dashboard Mobile Select */
.dashboard-mobile-select {
    padding: 16px;
}

.dashboard-mobile-select .form-select {
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 12px 16px;
    font-size: 16px;
    font-weight: 500;
    color: #2d3748;
    background-color: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
}

.dashboard-mobile-select .form-select:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.15);
    outline: none;
}

/* Responsive Dashboard */
@media (max-width: 991px) {
    .dashboard-sidebar {
        position: static;
        margin-bottom: 30px;
    }

    .quick-links {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .quick-links {
        grid-template-columns: 1fr;
    }

    .dashboard-content {
        padding: 24px;
    }
}

/* ============================================================================
   HOMEPAGE HERO SECTION STYLES
   ============================================================================ */

.hero-title-wrapper {
    position: relative;
    z-index: 2;
}

.hero-main-title {
    position: relative;
    display: inline-block;
}

.hero-main-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, transparent, #015096, transparent);
    border-radius: 2px;
}

.hero-content-wrapper {
    position: relative;
    z-index: 2;
}

/* Responsive hero section */
@media (max-width: 991px) {
    .hero-main-title {
        font-size: 2.5rem !important;
    }
    
    .hero-main-title::after {
        width: 60px;
        height: 3px;
    }
}

@media (max-width: 767px) {
    .hero-main-title {
        font-size: 2rem !important;
    }
    
    .hero-content-wrapper .text-extra-large {
        font-size: 1.5rem !important;
    }
}

/* ============================================================================
   NAVBAR Z-INDEX FIX - Fix per sovrapposizione sezioni homepage
   ============================================================================ */

/* Aumenta lo z-index della navbar per evitare sovrapposizioni */
.navbar.fixed-top {
    z-index: 1030 !important;
}

/* Assicura che i dropdown menu siano sopra tutto */
.navbar .dropdown-menu {
    z-index: 1040 !important;
}

/* Assicura che il menu mobile (collapse) sia sopra le sezioni */
.navbar-collapse {
    z-index: 1031 !important;
}

/* Fix per i dropdown del header (lingua, user, ecc.) */
.header-language .dropdown-menu,
.header-user .dropdown-menu {
    z-index: 1050 !important;
}

/* Assicura che le sezioni homepage non abbiano z-index che le facciano apparire sopra la navbar */
section.bg-light-blue {
    position: relative;
    z-index: 1;
}

/* Fix specifico per la sezione categorie */
#categories {
    position: relative;
    z-index: 1;
}

/* Assicura che gli elementi interni delle categorie non superino la navbar */
#categories .blog-post-details {
    z-index: 2 !important;
}

