:root {
    --proteko-dark-bg: #252525;
    --proteko-light-bg: #ffffff;
    --proteko-search-bg: #F4F5FB;
    --proteko-text-light: #ffffff;
    --proteko-text-dark: #707070;
    --proteko-border-light: #e9e9e9;
    --proteko-radius: 17px;
}

.proteko-filters {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--proteko-light-bg);
    border-radius: var(--proteko-radius);
    overflow: hidden;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
}

.proteko-filters.categoria-url-corso {
    grid-template-columns: repeat(3, 1fr);
}

.proteko-filters.categoria-url-corso .filter-header .filter-label:first-child, .proteko-filters.categoria-url-corso .filter-header+.filter-item {
    display: none;
}

.filter-header {
    display: contents;
}

.filter-label {
    background-color: var(--proteko-dark-bg);
    color: var(--proteko-text-light);
    padding: 12px 20px;
    font-size: 1.2rem;
    font-weight: 600;
    text-align: center;
    font-family: 'Gotham Rounded Book';
}

.filter-label:last-child {
    border-right: none;
}

.filter-item {
    background-color: var(--proteko-light-bg);
}

.filter-item:last-of-type {
    border-right: none;
}

.filter-item select {
    width: 100%;
    padding: 16px 20px;
    border: none !important;
    background-color: transparent;
    color: var(--proteko-text-dark);
    font-size: 1rem;
    cursor: pointer;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23555555' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 16px;
    font-family: 'Gotham Rounded Book' !important;
}

.filter-item select:focus {
    outline: none;
}

.filter-item-full,
.filter-item-submit {
    background-color: var(--proteko-search-bg);
    display: flex;
    align-items: center;
}

.filter-item-full input[type="text"] {
    width: 100%;
    height: 100%;
    border: none;
    background: transparent;
    padding: 16px 20px;
    font-size: 15px;
    color: var(--proteko-text-dark);
    font-family: 'Gotham Rounded Book';
}

.filter-item-full input[type="text"]:focus {
    outline: none;
}

.filter-item-submit button {
    width: 100%;
    height: 100%;
    border: none;
    background-color: var(--proteko-dark-bg);
    color: var(--proteko-text-light);
    font-weight: bold;
    font-size: 15px;
    cursor: pointer;
    transition: background-color 0.2s ease-in-out;
    border-radius: 50px 0px 17px 50px;
}

.filter-item-submit button:hover {
    background-color: #444444;
}

.search-bar-wrapper {
    grid-column: 1 / -1;
    display: flex;
    background-color: var(--proteko-search-bg);
}

.filter-item-full {
    flex-grow: 1;
    display: flex;
    align-items: center;
}

.filter-item-submit {
    flex-shrink: 0;
    width: 180px;
}

.filter-item-full input[type="text"]::placeholder {
    font-family: 'Gotham Rounded Book';
    font-size: 1rem;
    color: #707070;
}

@media (max-width: 1024px) {
    .proteko-filters {
        grid-template-columns: repeat(2, 1fr);
    }

    .filter-label {
        font-size: 1.1rem;
    }

    .filter-label:nth-child(2n) {
        border-right: none;
    }

    .filter-item:nth-of-type(2n) {
        border-right: none;
    }

    .filter-label:nth-child(3) {
        border-right: 1px solid #4a4a4a;
    }

    .filter-item:nth-of-type(3) {
        border-right: 1px solid var(--proteko-border-light);
    }

    .filter-item {
        border-bottom: 1px solid var(--proteko-border-light);
    }

    .search-bar-wrapper {
        grid-column: 1 / -1;
    }

    body .corso-card {
        height: 400px;
    }

    body .corsi-correlati-head {
        justify-content: flex-start;
        margin-top: 20px;
        margin-bottom: 30px;
    }
}

@media (max-width: 767px) {
    .proteko-filters, .proteko-filters.categoria-url-corso {
        grid-template-columns: 1fr;
    }

    .filter-header {
        display: none;
    }

    .filter-item {
        border-right: none;
        border-bottom: 1px solid var(--proteko-border-light);
    }

    .filter-item:last-of-type {
        border-bottom: none;
    }

    .search-bar-wrapper {
        flex-direction: column;
    }

    .filter-item-full input[type="text"] {
        text-align: center;
        padding-top: 20px;
        padding-bottom: 20px;
    }

    .filter-item-submit {
        width: 100%;
    }

    .filter-item-submit button {
        padding-top: 16px;
        padding-bottom: 16px;
        border-radius: 0;
    }
}

.corsi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 25px;
    margin-top: 40px;
}

.corsi-grid.no-results-container {
    display: flex;
    flex-direction: column;
}

.corso-card {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    height: 550px;
    text-decoration: none;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    color: #fff;
}

.corso-card:hover {
    color: #fff;
}

.card-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100% !important;
    object-fit: cover;
    z-index: 1;
    transition: transform 0.4s ease;
}

.corso-card:hover .card-bg-image {
    transform: scale(1.05);
}

.corso-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.8) 25%, rgba(0, 0, 0, 0) 70%);
    z-index: 2;
}

.corso-card::before {
    content: '';
    position: absolute;
    height: 8px;
    width: 100%;
    background-color: var(--card-category-color);
    bottom: 0;
    left: 0;
    z-index: 3;
}

.card-overlay-content {
    position: relative;
    padding: 25px;
    z-index: 3;
    width: 100%;
}

.card-date {
    display: inline-block;
    background-color: var(--card-category-color, #27ae60);
    color: #fff;
    padding: 0px 10px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 15px;
}

.card-overlay-content h3 {
    margin: 0 0 20px 0;
    font-size: 1.4rem;
    line-height: 1.3;
    color: #fff;
    font-family: 'Gotham Rounded Book';
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 50px;
}

.card-location {
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: 'Gotham Rounded Book';
    font-weight: 600;
    border-radius: 22px;
    border: 1px solid #ffffff;
    padding: 8px 18px;
    line-height: 1em;
    margin: 0 !important;
}

.card-arrow {
    width: 40px;
    line-height: 1;
    transform: rotate(-45deg);
}

#proteko-no-results-formazione-button a {
    color: inherit;
}

.proteko-load-more-wrapper, .proteko-no-results-formazione-button-wrapper {
    text-align: center;
    margin-top: 50px;
    margin-bottom: 30px;
}

.proteko-no-results-formazione-button-wrapper {
    margin-top: 0;
}

#proteko-load-more.proteko-classic-button, #proteko-no-results-formazione-button {
    display: inline-block;
    background-color: var(--proteko-dark-bg, #252525);
    color: var(--proteko-text-light, #ffffff);
    border: none;
    border-radius: 50px;
    padding: 10px 60px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

#proteko-load-more.proteko-classic-button:hover, #proteko-no-results-formazione-button:hover {
    background-color: #444;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

#proteko-load-more.hidden {
    display: none;
}

.no-results-programmazione {
    color: var(--proteko-dark-bg);
    padding: 12px 20px 0;
    font-size: 1.2rem;
    font-weight: 600;
    text-align: center;
    font-family: 'Gotham Rounded Book';
    margin-bottom: 0;
}

.no-results-programmazione, .text-results-programmazione {
    text-align: center;
}

.text-results-programmazione {
    margin-bottom: 0;
}

/* ---------- CORSO SINGOLO ---------- */
.proteko-dettagli-corso {
    margin-top: 0;
    margin-bottom: 0;
}

.proteko-dettagli-corso table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.proteko-dettagli-corso tr {
    border-bottom: none;
    position: relative;
}

.proteko-dettagli-corso tr+tr td:first-child::before,
.proteko-dettagli-corso tr:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background-image: radial-gradient(circle at center, #AAAAAB 1px, transparent 1px);
    background-size: 6px 4px;
    background-repeat: repeat-x;
}

.proteko-dettagli-corso tr:last-child:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background-image: radial-gradient(circle at center, #AAAAAB 1px, transparent 1px);
    background-size: 6px 4px;
    background-repeat: repeat-x;
}

.proteko-dettagli-corso tr:last-child {
    border-bottom: none;
}

.proteko-dettagli-corso td {
    padding: 25px 10px;
    vertical-align: middle;
    line-height: 1;
}

.proteko-dettagli-corso td:first-child {
    width: 25%;
    min-width: 150px;
    color: #000;
    font-weight: 500;
    font-family: 'Gotham Rounded Book';
}

.proteko-dettagli-corso td:last-child {
    color: #252525;
    font-family: 'Gotham Rounded Book';
    font-weight: bold;
    line-height: 1.6;
}

.categoria-badge {
    display: inline-block;
    font-size: 0.9em;
    border: 1px solid transparent;
    padding: 5px 10px;
    color: #fff;
    font-family: 'Gotham Rounded Book';
    font-weight: 600;
}

.normativa-lista {
    list-style: none !important;
    padding: 0;
    margin: 8px 0 0 0 !important;
    font-size: 0.9em;
    font-weight: normal;
    color: #707070;
}

.normativa-lista li {
    margin-bottom: 4px;
}

@media (max-width: 768px) {
    .proteko-dettagli-corso td {
        display: block;
        width: 100%;
        padding: 10px 0;
    }

    .proteko-dettagli-corso td:first-child {
        font-weight: bold;
        padding-bottom: 5px;
        color: #252525;
    }

    .proteko-dettagli-corso tr {
        display: block;
        border-bottom: none;
    }

    body .corso-card {
        height: 450px;
    }

    body .corsi-correlati-head {
        justify-content: flex-start;
        margin-top: 20px;
        margin-bottom: 30px;
    }

    body .contact-corso {
        background-image: linear-gradient(180deg, var(--card-category-color) 23%, var(--e-global-color-95606af) 0%) !important;
    }
}

.contact-corso {
    background-image: linear-gradient(90deg, var(--card-category-color) 33%, var(--e-global-color-95606af) 0%) !important;
}

.single-corso .proteko-form .elementor-button-icon i,
.single-corso .proteko-form .elementor-button-icon i:hover {
    background-color: var(--card-category-color);
}

.content-corsi {
    font-weight: 400;
    font-family: 'Gotham Rounded Book';
    font-size: 1rem;
    /* white-space: break-spaces; */
}

.content-corsi li::marker {
    color: var(--card-category-color);
}

.content-corsi ul {
    margin-top: 10px;
}

/* GIGIOTTO */
.single-corso {
    .col-full {
        max-width: unset;
        padding-right: 0;
        padding-left: 0;
    }

    .perche-sceglierci {
        .elementor-widget-rebuilto-scroll-timeline .timeline-number {
            font-weight: 600;
            font-size: 18px;
        }

        .elementor-widget-rebuilto-scroll-timeline .scroll-timeline-number {
            z-index: 1;
            margin-right: 25px;
        }

        .elementor-widget-rebuilto-scroll-timeline .scroll-timeline:before {
            z-index: 0;
        }

        .elementor-widget-rebuilto-scroll-timeline .timeline-active .timeline-number,
        .elementor-widget-rebuilto-scroll-timeline .scroll-timeline-item:first-of-type .timeline-number {
            box-shadow: 0 0 0 2px var(--card-category-color);
            color: var(--card-category-color);
        }

        .elementor-widget-rebuilto-scroll-timeline .timeline-line {
            background-color: var(--card-category-color);
            z-index: 0;
        }

        .scroll-timeline-subheading {
            color: #000;
            font-weight: 300;
        }

        .elementor-widget-rebuilto-scroll-timeline .scroll-timeline-image img {
            width: 600px;
        }

        .scroll-timeline-heading {
            font-size: 22px;
        }
    }

    .immagine-perche-sceglierci {
        background-image: var(--immagine-perche-sceglerci-divisione);
        background-size: cover;
        background-position: top;
    }

    .d-grid.servizi-collegati-1-livello-loop {
        grid-template-columns: repeat(3, 1fr);
        grid-gap: 30px;
        align-items: stretch;

        .description {
            color: #000;
        }

        .service-more-link,
        .service-more-link:hover,
        .service-item .service-more-link-wrap.style-link .service-more-link i,
        .service-title a:hover {
            color: var(--card-category-color);
        }

        .service-item .service-more-link-wrap.style-link {
            border-top: 2px dotted var(--border);
        }

        .service-item.service-style-2 .service-content {
            padding: 30px 40px;
            display: flex;
            flex-direction: column;
            min-height: 330px;
        }

        .grid-item,
        .service-item,
        .service-inner {
            height: 100%;
            display: flex;
            flex-direction: column;
        }

        .service-item .service-content .description {
            flex-grow: 1;
        }

        .service-item .service-more-link-wrap {
            margin-top: auto;
        }
    }

    .img-pro-safety {
        text-align: left;

        img {
            width: 50%;
        }
    }

    .immagine-form-divisione {
        img {
            width: 70%;
            margin-left: 100px;
        }
    }

    .elementor-element.elementor-element-8b3d9f3 .wrapper-timeline-main {
        display: none;
    }

    .img-tablet-banner-servizi img {
        margin-left: 200px;
    }

    .img-divisione-banner-servizi {
        background-image: var(--immagine-divisione-banner);
        background-position: center center;
        background-repeat: no-repeat;
        background-size: cover;
    }

    @media (max-width: 767px) {
        .d-grid.servizi-collegati-1-livello-loop {
            grid-template-columns: repeat(1, 1fr);

            .service-item.service-style-2 .service-content {
                padding: 30px 20px;
                min-height: 360px;
            }
        }

        .immagine-form-divisione {
            img {
                margin-left: 120px;
                margin-top: 30px;
                height: 250px;
            }
        }

        .img-pro-safety {
            img {
                width: 75%;
            }
        }

        .servizi-collegati-2-liv-loop {
            .e-con-inner.reverse {
                flex-direction: row;
            }

            .column {
                padding-right: 0px !important;
                padding-left: 0px !important;
            }

            .row {
                padding-left: 15px;
                padding-right: 15px;
                margin-bottom: 50px;
            }

            .e-con-inner,
            .e-con-inner.reverse {
                flex-direction: column-reverse;
            }

            .elementor-heading-title {
                font-size: 20px;
                font-weight: 600;
                padding-top: 15px;
                padding-bottom: 0px;
            }
        }

        .img-tablet-banner-servizi img {
            margin-left: 0px;
            width: 85%;
        }
    }
}

/* GIGIOTTO */
.corsi-correlati-head {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-bottom: 50px;
    color: #fff;
}

.corsi-correlati-arrows {
    display: flex;
    gap: 14px;
    margin-right: 13.3%;
}

.corsi-correlati-arrows button {
    width: 40px;
    border-radius: 50%;
    border: 1px solid #fff;
    background: white;
    color: #000;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    aspect-ratio: 1;
    padding: 0;
}

.corsi-correlati-arrows button:hover {
    background: #fff;
    color: #000;
}

.corsi-correlati-slider .swiper-slide {
    width: auto
}

@media (max-width: 1024px) {
    .proteko-dettagli-corso table {
        display: block;
        border-radius: 12px;
        overflow: hidden;
    }

    .proteko-dettagli-corso tbody,
    .proteko-dettagli-corso tr,
    .proteko-dettagli-corso td {
        display: block;
        width: 100%;
    }

    .proteko-dettagli-corso tr {
        padding: 16px 18px;
    }

    .proteko-dettagli-corso tr:last-child {
        border-bottom: none;
    }

    .proteko-dettagli-corso td:first-child {
        font-size: 0.75rem;
        font-weight: 600;
        color: #999;
        margin-bottom: 4px;
        text-transform: uppercase;
        letter-spacing: 0.3px;
    }

    .proteko-dettagli-corso td:last-child {
        font-size: 1rem;
        font-weight: 700;
        color: #222;
        line-height: 1.4em;
    }

    .proteko-dettagli-corso .categoria-badge {
        display: inline-block;
        padding: 6px 12px;
        font-size: 0.8rem;
        font-weight: 600;
        color: #fff;
        border-radius: 6px;
    }

    .proteko-dettagli-corso .normativa-lista {
        margin-top: 6px;
        font-size: 0.9rem;
        color: #555;
    }

    .corsi-grid {
        grid-template-columns: auto;
    }
}