/* ===================================
    Studio Conti - Custom Overrides
    Base color: #003869
====================================== */

/* ---- servizi farmacie: sub-services grid ---- */
.pharma-services-section {
    background-color: #001f40;
}
.pharma-form-section {
    background: linear-gradient(to bottom, #001f40 0%, #0060a8 100%);
}
@media (min-width: 768px) {
    .pharma-form-fields-row {
        margin-left: -0.5rem !important;
        margin-right: -0.5rem !important;
    }
    .pharma-form-fields-row > [class*="col-"] {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
    }
}
.pharma-service-card {
    background-color: #003869;
}
.pharma-service-bg-icon {
    position: absolute;
    bottom: -10px;
    right: -10px;
    font-size: 9rem;
    color: rgba(255, 255, 255, 0.07);
    pointer-events: none;
    line-height: 1;
}
.pharma-service-text,
.pharma-service-text p {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.75;
}
.pharma-service-text ul {
    list-style: none !important;
    padding-left: 1.25rem;
    margin-bottom: 0;
}
.pharma-service-text ul li {
    position: relative;
    padding-left: 1rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.5rem;
    line-height: 1.6;
}
.pharma-service-text ul li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: #ffffff;
    font-size: 1rem;
    line-height: 1.6;
}

/* ---- about team members ---- */
.about-member-card {
    transition: transform .2s, box-shadow .2s;
}
.about-member-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12) !important;
}
.about-member-photo {
    width: 100%;
    aspect-ratio: 3 / 4;
    overflow: hidden;
}
.about-member-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
}

/* ---- about content ---- */
.about-content h3 {
    font-size: 32px;
    line-height: 1.2;
    margin:30px;
}
.about-content ul {
    list-style: none !important;
    padding-left: 0;
    margin: 1rem 0 1rem 0.5rem;
}
.about-content ul li {
    position: relative;
    padding-left: 1.25rem;
    margin: 0.8rem;
    color: black;
    line-height: 1.4;
    font-size: 1.2rem;
}
.about-content ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.65em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #003869;
    -webkit-border-radius: 50%;
    -moz-border-radius: 50%;
    -ms-border-radius: 50%;
    -o-border-radius: 50%;
}

/* ---- service detail content ---- */
.service-detail-subtitle {
    border-left: 3px solid #003869;
    padding-left: 16px;
}
.service-detail-content {
    font-size: 19px;
    line-height: 1.6;
}
.service-detail-content p {
    margin-bottom: 1.2rem;
    color: #444;
}
.service-detail-content h3 {
    font-family: var(--alt-font);
    font-size: 24px;
    font-weight: 600;
    color: #003869;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    letter-spacing: -0.3px;
}
.service-detail-content h4 {
    font-family: var(--alt-font);
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}
.service-detail-content ul {
    list-style: none !important;
    padding-left: 0;
    margin: 0.9rem 1.2rem;
}
.service-detail-content ul li {
    position: relative;
    padding-left: 1.25rem;
    margin-bottom: 0.2rem;
    color: #444;
    line-height: 1.5;
}
.service-detail-content ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #003869;
}

/* ---- services grid card fixed height ---- */
.services-card-box {
    height: 380px;
    margin-bottom: 2rem;
    border-radius: 12px;
}
.services-card-box figure,
.services-card-box figure a,
.services-card-box figure img {
    height: 100%;
    width: 100%;
    object-fit: cover;
    display: block;
}

/* ---- farmacia schema flow ---- */
.pharma-schema-flow {
    display: flex;
    align-items: stretch;
    gap: 0;
    counter-reset: schema-step;
}
.pharma-schema-step {
    counter-increment: schema-step;
    position: relative;
    overflow: hidden;
    flex: 1;
    padding: 32px 20px 28px;
    border-radius: 14px;
    font-weight: 600;
    font-size: 14px;
    line-height: 1.5;
    display: flex;
    align-items: flex-end;
    justify-content: flex-start;
    text-align: left;
    min-height: 150px;
    font-family: var(--alt-font);
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: transform .2s, box-shadow .2s;
}
.pharma-schema-step:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 28px rgba(0,0,0,0.14);
}
.pharma-schema-step::before {
    content: counter(schema-step, decimal-leading-zero);
    position: absolute;
    top: -14px;
    right: 8px;
    font-size: 5.5rem;
    font-weight: 700;
    line-height: 1;
    font-family: var(--alt-font);
    pointer-events: none;
}
.pharma-schema-step--dark {
    background: linear-gradient(135deg, #003869 0%, #00548f 100%);
    color: #fff;
}
.pharma-schema-step--dark::before {
    color: rgba(255,255,255,0.1);
}
.pharma-schema-step--light {
    background-color: #fff;
    color: #003869;
    border-top: 3px solid #003869;
}
.pharma-schema-step--light::before {
    color: rgba(0,56,105,0.07);
}
.pharma-schema-sep {
    display: flex;
    align-items: center;
    padding: 0 8px;
    flex-shrink: 0;
}
.pharma-schema-sep i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1.5px solid #c0cdd8;
    color: #a0b0bc;
    font-size: 10px;
}
@media (max-width: 991px) {
    .pharma-schema-flow {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }
    .pharma-schema-sep { display: none; }
    .pharma-schema-step { min-height: 120px; font-size: 13px; }
}
@media (max-width: 575px) {
    .pharma-schema-flow { grid-template-columns: 1fr; }
}

/* ---- lavora con noi ---- */
.ww-form-box {
    border: 2px solid #003869 !important;
}

/* testo su due colonne */
@media (min-width: 992px) {
    .ww-text-two-cols {
        column-count: 2;
        column-gap: 3rem;
    }
}

:root {
    --base-color: #003869;
    --base-color-dark: #002a50;
    --base-color-light: #1a4f80;
    --medium-gray: #828282;
}

/* previeni scroll orizzontale su mobile */
html, body { overflow-x: hidden !important; max-width: 100%; }

/* testata: riduci letter-spacing titoli su mobile */
@media (max-width: 767px) {
    .page-title-parallax-background h1.ls-minus-2px {
        letter-spacing: -1px !important;
    }
}

/* tutti i bottoni con bordi rotondi, esclusi i btn-link */
.btn:not(.btn-link) { border-radius: 50px !important; }

/* base color text */
.text-base-color,
a.text-base-color,
a.text-base-color:hover { color: #003869 !important; }

/* base color background */
.bg-base-color,
.btn-base-color,
.btn-base-color:hover,
.feature-box-overlay.bg-base-color { background-color: #003869 !important; }

/* base color border */
.border-color-base-color,
.border-base-color { border-color: #003869 !important; }

/* btn-base-color */
.btn.btn-base-color {
    background-color: #003869 !important;
    border-color: #003869 !important;
    color: #fff !important;
}
.btn.btn-base-color:hover {
    background-color: #002a50 !important;
    border-color: #002a50 !important;
}

/* btn-link text-base-color */
.btn-link.text-base-color,
.btn.btn-link.text-base-color { color: #003869 !important; }
.btn-link.text-base-color span.bg-white { background-color: #003869 !important; }

/* pie chart */
.pie-chart-style-01 { --start-color: #003869; --end-color: #003869; }

/* gradient overrides */
.bg-gradient-black-dark-brown {
    background-image: linear-gradient(to right top, #000000, #001a35, #002850, #003869, #003869) !important;
}
.bg-gradient-light-brown-transparent {
    background-image: linear-gradient(to right top, rgba(0, 28, 60, .6), rgba(0, 56, 105, .9)) !important;
}

/* separator / highlight underline */
span.separator-animation,
.text-highlight .separator-animation { background-color: #003869 !important; }

/* tab border */
.tab-style-04 .nav-link .tab-border { background-color: #003869 !important; }

/* scroll progress */
.scroll-progress .scroll-point { background-color: #003869 !important; }

/* blog date color */
.blog-date { color: #003869 !important; }

/* feather icon color */
.feather.icon-feather-mail.text-base-color { color: #003869 !important; }

/* icon */
.icon.feather.text-base-color { color: #003869 !important; }

/* review star */
.review-star-icon i { color: #003869 !important; }

/* check icon color */
.fa-solid.fa-check.text-base-color { color: #003869 !important; }
.fa-solid.fa-check.fs-16.text-base-color { color: #003869 !important; }

/* navbar button (contattaci) */
.header-button .btn-white {
    background-color: #fff;
    color: #003869 !important;
    border-color: #fff;
}

/* mobile nav bg override */
.hamburger-menu-full-screen { background-color: #003869 !important; }

/* footer */
footer.footer-light { border-top: 1px solid #e8e8e8; }

/* ---- home services all link ---- */
.home-services-all-link {
    color: #fff !important;
    width: fit-content !important;
    align-self: flex-start;
    margin-top: auto !important;
}
.home-services-all-link:hover { color: #fff !important; opacity: .8; }
.home-services-all-link span.bg-white { width: 100% !important; }

/* ---- services mobile swiper ---- */
.services-mobile-swiper { overflow: visible; }
.services-mobile-swiper .swiper-wrapper { align-items: stretch; }
.services-mobile-swiper .swiper-slide { height: auto; display: flex; }
.services-mobile-swiper .swiper-slide .home-service-card { width: 100%; }

/* ---- home service cards ---- */
.home-service-card {
    display: flex;
    flex-direction: column;
    transition: border-color .2s, box-shadow .2s;
}
.home-service-card:hover {
    border-color: #003869 !important;
    box-shadow: 0 8px 30px rgba(0,56,105,.1);
}
.home-service-card .btn-link {
    margin-top: auto;
    padding-top: 16px;
    align-self: flex-start;
}
.home-service-text {
    line-height: 1.5 !important;
    margin-bottom: 0 !important;
}
.home-service-num-bg {
    position: absolute;
    bottom: -18px;
    right: 10px;
    font-size: 110px;
    font-weight: 700;
    line-height: 1;
    font-family: var(--alt-font);
    color: rgba(0, 56, 105, 0.06);
    pointer-events: none;
    user-select: none;
    z-index: 0;
}

/* ---- home chi siamo ---- */
.about-img-col { min-height: 520px; }

.about-img-col { min-height: 520px; }
@media (max-width: 991px) { .about-img-col { min-height: 380px; } }

/* la colonna è il punto di riferimento per le frecce */
.about-text-col { position: relative !important; }

.about-text-inner {
    padding: 70px 80px 110px;
    height: 100%;
    box-sizing: border-box;
}
@media (max-width: 1199px) { .about-text-inner { padding: 60px 50px 110px; } }
@media (max-width: 991px)  { .about-text-inner { padding: 50px 40px 100px; } }
@media (max-width: 767px)  { .about-text-inner { padding: 40px 25px 90px; } }

/* frecce ancorate alla colonna, non al testo */
.about-arrows {
    position: absolute;
    bottom: 50px;
    left: 80px;
    display: flex;
    align-items: center;
}
@media (max-width: 1199px) { .about-arrows { left: 50px; bottom: 40px; } }
@media (max-width: 991px)  { .about-arrows { left: 40px; bottom: 30px; } }
@media (max-width: 767px)  { .about-arrows { left: 25px; bottom: 20px; } }

.about-arrow-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid #003869;
    background: transparent;
    color: #003869;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .2s, color .2s;
    font-size: 13px;
    flex-shrink: 0;
}
.about-arrow-btn:hover {
    background: #003869;
    color: #fff;
}

/* ---- rich text con liste raffinate ---- */
.wm6-richtext p {
    margin-bottom: 16px;
    line-height: 1.5;
    color: #333;
}
.wm6-richtext h3,
.wm6-richtext h4 {
    font-weight: 600;
    color: #111;
    margin-top: 28px;
    margin-bottom: 12px;
}
.wm6-richtext h3 { font-size: 28px; line-height: 1.3; font-weight: normal; margin-bottom: 20px; }
.wm6-richtext h4 { font-size: 16px; }

/* ul: lista con chevron brand */
.wm6-richtext ul {
    list-style: none;
    padding-left: 0;
    margin: 30px;
}
.wm6-richtext ul li {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 9px;
    line-height: 1.5;
    color: #333;
}
.wm6-richtext ul li::before {
    content: '›';
    flex-shrink: 0;
    font-size: 26px;
    line-height: 1;
    color: #003869;
    font-weight: 400;
    margin-top: -1px;
}

/* ol: lista numerata con cerchio brand */
.wm6-richtext ol {
    list-style: none;
    padding-left: 0;
    margin: 20px 0 24px;
    counter-reset: wm6-ol;
}
.wm6-richtext ol li {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 12px;
    line-height: 1.65;
    color: #333;
    counter-increment: wm6-ol;
}
.wm6-richtext ol li::before {
    content: counter(wm6-ol);
    flex-shrink: 0;
    margin-top: 1px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #003869;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* ---- home sedi ---- */
.home-sede-box {
    background: #fff;
    border-radius: 8px;
    padding: 28px 20px 22px;
    height: 100%;
    border: 1px solid #e4e9ef;
    transition: border-color .2s, box-shadow .2s, transform .2s;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}
.home-sede-box:hover {
    border-color: #003869;
    box-shadow: 0 6px 24px rgba(0,56,105,.1);
    transform: translateY(-3px);
}
.sede-main {
    border-top: 3px solid #003869;
}
.home-sede-box-icon {
    position: absolute;
    bottom: -5px;
    right: -16px;
    pointer-events: none;
    line-height: 1;
}
.home-sede-box-icon i {
    font-size: 7rem;
    color: rgba(0, 56, 105, 0.06);
    display: block;
}
.home-sede-box-city {
    font-size: 20px;
    font-weight: 700;
    color: #111;
    margin-bottom: 8px;
    letter-spacing: .2px;
}
.home-sede-box-addr {
    font-size: 14px;
    color: #666;
    line-height: 1.55;
    margin-bottom: 8px;
    flex: 1;
}
.home-sede-box-tel {
    font-size: 12.5px;
    margin-bottom: 6px;
}
.home-sede-box-tel a {
    color: #003869;
    text-decoration: none;
    font-weight: 500;
}
.home-sede-box-tel a:hover { text-decoration: underline; }
.home-sede-box-map {
    display: inline-block;
    margin-top: 6px;
    font-size: 12px;
    text-transform: uppercase;
    color: #003869;
    text-decoration: underline;
    text-underline-offset: 2px;
}
.home-sede-box-map:hover { color: #002a50; }

/* ---- home news swiper ---- */
.home-news-swiper { overflow: visible; padding-bottom: 10px; }
.home-news-swiper .swiper-wrapper { align-items: stretch; }
.home-news-swiper .swiper-slide { height: auto; }

/* dots bianchi su sfondo blu */
.home-news-pagination { bottom: 0 !important; }
.home-news-pagination .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    background: rgba(255,255,255,.4);
    opacity: 1;
}
.home-news-pagination .swiper-pagination-bullet-active {
    background: #fff;
    width: 24px;
    border-radius: 4px;
}

/* ---- home news cards ---- */
.home-news-card {
    display: flex;
    flex-direction: column;
    transition: transform .2s;
    height: 100%;
}
.home-news-card:hover { transform: translateY(-4px); }

.home-news-card-inner {
    background: #fff;
    border-radius: 10px;
    padding: 28px 28px 24px;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
    box-shadow: 0 4px 20px rgba(0,0,0,.08);
}

.home-news-pill {
    display: inline-block;
    align-self: flex-start;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #003869;
    background: rgba(0,56,105,.1);
    padding: 0 12px;
    border-radius: 20px;
    margin-bottom: 20px;
}

.home-news-date {
    font-size: 12px;
    color: #999;
    display: block;
}

.home-news-title {
    font-family: var(--alt-font);
    font-size: 28px;
    font-weight: 600;
    color: #111;
    line-height: 1.25;
    text-decoration: none;
    display: block;
    transition: color .2s;
}
.home-news-title:hover { color: #003869; }

.home-news-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    margin: 0;
}
.home-news-card-inner .btn-link {
    margin-top: auto;
    align-self: flex-start;
    padding-left: 0;
    padding-top: 50px;
}

.news-year-filter-btn {
    display: inline-block;
    padding: 8px 20px;
    border: 1.5px solid #003869;
    border-radius: 30px;
    color: #003869;
    background: transparent;
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: background .2s, color .2s;
}
.news-year-filter-btn:hover { background: rgba(0,56,105,.1); color: #003869; }
.news-year-filter-btn.active { background: #003869; color: #fff; }


/* ---- footer ---- */
footer.footer-light { padding-top: 60px; padding-bottom: 40px; }

.footer-col-title {
    display: block;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #003869;
    margin-bottom: 14px;
}

ul.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
    line-height: 1;
}
ul.footer-links li { margin-bottom: 4px; }
ul.footer-links li a {
    font-size: 12.5px;
    color: #555;
    text-decoration: none;
    line-height: 1.2;
    display: inline-block;
}
ul.footer-links li a:hover { color: #003869; }

.footer-sede { font-size: 12.5px; color: #555; line-height: 1.4; }
.footer-sede p { margin-bottom: 5px; }
.footer-sede a { color: #555; text-decoration: none; }
.footer-sede a:hover { color: #003869; }
.footer-sede-name { font-weight: 600; color: #222; margin-bottom: 6px !important; font-size: 13px; }
.footer-label { font-weight: 600; color: #444; }
.footer-map-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 600;
    color: #003869 !important;
    text-decoration: underline;
    text-underline-offset: 2px;
    text-transform: uppercase;
    letter-spacing: .5px;
}
.footer-map-link::after { content: '→'; text-decoration: none; }
.footer-map-link:hover { color: #002a50 !important; }

/* GDPR / deltacommerce footer bottom */
.footer-bottom {
    font-size: 12px;
    overflow-x: hidden;
}
.footer-bottom a { color: rgba(255,255,255,.6); }
.footer-bottom a:hover { color: #fff; }
.footer-bottom .tools-box,
.footer-bottom #cookies-manager-list-of-choices-made,
.footer-bottom #cookies_preferences_wrapper {
    max-width: 100%;
    overflow-x: hidden;
}

/* font nav: compromesso tra leggibilità e spazio disponibile */
.navbar .navbar-nav .nav-link {
    font-size: 16.5px !important;
    letter-spacing: 0 !important;
    padding-left: 9px !important;
    padding-right: 9px !important;
}

/* dropdown menu: più largo, voci più piccole */
.navbar .navbar-nav .simple-dropdown .dropdown-menu {
    min-width: 260px !important;
}
.navbar .navbar-nav .simple-dropdown .dropdown-menu a {
    font-size: 14px !important;
    line-height: 1.4 !important;
    padding-top: 7px !important;
    padding-bottom: 7px !important;
}

/* active nav item: solo sottolineatura, nessun override colore */
.navbar-nav .nav-item.active > .nav-link {
    text-decoration: underline;
    text-underline-offset: 4px;
}

/* page title bg override */
.page-title-parallax-background::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 30, 60, .55);
    z-index: 0;
}

/* services box hover */
.services-box-style-02 .services-box .btn-link { color: #003869 !important; }
.services-box-style-02 .services-box a.d-inline-block:hover { color: #003869 !important; }

/* interactive banner */
.interactive-banner-style-02 .btn-link.text-base-color { color: #003869 !important; }

/* team content overlay */
.team-style-05 .team-content { background-image: linear-gradient(to bottom, rgba(0,28,60,0), rgba(0,56,105,.9)) !important; }

/* accordions active */
.accordion-style-02 .accordion-title { color: #fff !important; }
.accordion-style-02 .active-accordion .accordion-title { color: #fff !important; }

/* feature box overlay */
.icon-with-text-style-05 .feature-box-overlay { background-color: #003869 !important; }

/* custom image placeholder cover */
.cover-placeholder {
    background-color: #e8eff5;
    background-image: linear-gradient(135deg, #003869 0%, #1a4f80 100%);
    min-height: 400px;
}

/* navbar top spacing */
header .navbar { padding-top: 18px !important; padding-bottom: 18px !important; }

/* logo dimensions */
header .navbar-brand {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    line-height: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
}
header .navbar-brand img { height: 52px !important; width: auto !important; max-height: none !important; }
footer .footer-logo img { height: 48px; width: auto; }

/* ---- site-upload widget ---- */

/* nasconde l'input file nativo immediatamente (site-uploader.css è caricato dinamicamente via JS,
   nel frattempo Crafto `input { width:100% }` renderebbe visibile il bottone "Sfoglia" del browser) */
.upload-file-wrapper .form-upload {
    display: none !important;
}

/* layout e sfondo zona upload */
.contact-form-style-03 .upload-file-wrapper {
    margin-bottom: 1rem;
}
.contact-form-style-03 .upload-zone-wrapper {
    background: #f8f9fa !important;
    border-radius: 8px;
}

/* label drag & drop: annulla valori anomali di uploader.css e sovrascrive il bordo grigio
   di site-uploader.css con uno tratteggiato brand */
.contact-form-style-03 .upload-file-wrapper .form-upload + label {
    position: relative !important;
    top: inherit !important;
    height: auto !important;
    min-height: 160px !important;
    border-radius: 8px !important;
    padding: 2rem 1.5rem !important;
    background-color: transparent !important;
    background-image: url("data:image/svg+xml,%3csvg width='100%25' height='100%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' rx='8' ry='8' stroke='%23b0bec5' stroke-width='1.8' stroke-dasharray='7 4' stroke-linecap='round'/%3e%3c/svg%3e") !important;
    transition: background-image .2s;
}
.contact-form-style-03 .upload-file-wrapper .form-upload + label:hover,
.contact-form-style-03 .upload-file-wrapper .form-upload + label.dragover {
    background-image: url("data:image/svg+xml,%3csvg width='100%25' height='100%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' rx='8' ry='8' stroke='%23003869' stroke-width='2' stroke-dasharray='7 4' stroke-linecap='round'/%3e%3c/svg%3e") !important;
    background-color: rgba(0,56,105,.03) !important;
}

/* icona upload: brand color */
.contact-form-style-03 .upload-file-wrapper .upload-label svg {
    color: #003869;
    fill: #003869;
    width: 34px;
    height: 34px;
}

/* testi */
.contact-form-style-03 .upload-file-wrapper .upload-label > span > span:not(.btn) {
    font-size: 14px;
    color: #666;
}
.contact-form-style-03 .upload-file-wrapper .upload-label small {
    font-size: 12px;
    color: #999;
}

/* bottone Sfoglia: brand color */
.contact-form-style-03 .upload-file-wrapper .btn-outline-primary {
    color: #003869 !important;
    border-color: #003869 !important;
    font-size: 13px;
    padding: 5px 20px;
    background: transparent;
    transition: background .2s, color .2s;
}
.contact-form-style-03 .upload-file-wrapper .btn-outline-primary:hover {
    background-color: #003869 !important;
    color: #fff !important;
}

/* checkbox alignment */
.contact-form-style-03 .form-check-input {
    margin-top: 0 !important;
}

/* switch knob bianco quando attivo */
.form-switch .form-check-input:checked {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e") !important;
}

/* link privacy/gdpr */
.contact-form-style-03 .form-check a,
.contact-form-style-03 .form-check a:hover {
    color: #003869 !important;
    text-decoration: underline !important;
}

/* lista file caricati */
.contact-form-style-03 .upload-file-wrapper .media-list {
    background: #fff;
    border-top: 1px solid #ececec;
}

/* ---- contact form: Bootstrap form-floating + form-check fix ---- */

/* Ripristina Bootstrap 5 form-floating: Crafto sovrascrive padding e border su tutti gli input */
.contact-form-style-03 .form-floating {
    position: relative;
    margin-bottom: 1rem;
}
.contact-form-style-03 .form-floating > .form-control,
.contact-form-style-03 .flex-fill.form-floating > .form-control {
    height: calc(3.5rem + 2px);
    min-height: calc(3.5rem + 2px);
    padding: 1rem 0.75rem !important;
    line-height: 1.25;
    border: 1px solid #dfdfdf !important;
}
@media (max-width: 767px) {
    .contact-form-style-03 .form-floating > .form-control,
    .contact-form-style-03 .flex-fill.form-floating > .form-control {
        height: calc(4rem + 2px);
        min-height: calc(4rem + 2px);
    }
}
.contact-form-style-03 .form-floating > .form-control:focus,
.contact-form-style-03 .flex-fill.form-floating > .form-control:focus {
    border: 1px solid #c2c2c2 !important;
}
/* textarea ha bisogno di altezza auto e padding-top maggiore */
.contact-form-style-03 .flex-fill.form-floating > textarea.form-control {
    height: auto !important;
    min-height: 130px;
    padding-top: 1.625rem !important;
    padding-bottom: 0.625rem !important;
}
/* label floating */
.contact-form-style-03 .form-floating > label,
.contact-form-style-03 .flex-fill.form-floating > label {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    padding: 1rem 0.75rem;
    pointer-events: none;
    border: 1px solid transparent;
    transform-origin: 0 0;
    transition: opacity 0.1s ease-in-out, transform 0.1s ease-in-out;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    font-size: 16px;
    color: var(--medium-gray);
}
/* padding-top aumenta quando il campo è attivo/compilato, per fare spazio alla label flottante */
.contact-form-style-03 .form-floating > .form-control:focus,
.contact-form-style-03 .form-floating > .form-control:not(:placeholder-shown),
.contact-form-style-03 .flex-fill.form-floating > .form-control:focus,
.contact-form-style-03 .flex-fill.form-floating > .form-control:not(:placeholder-shown) {
    padding-top: 1.625rem !important;
    padding-bottom: 0.625rem !important;
}
.contact-form-style-03 .form-floating > .form-control:focus ~ label,
.contact-form-style-03 .form-floating > .form-control:not(:placeholder-shown) ~ label,
.contact-form-style-03 .flex-fill.form-floating > .form-control:focus ~ label,
.contact-form-style-03 .flex-fill.form-floating > .form-control:not(:placeholder-shown) ~ label {
    opacity: 0.65;
    transform: scale(0.85) translateY(-0.5rem) translateX(0.15rem);
}
@media (max-width: 767px) {
    .contact-form-style-03 .form-floating > .form-control:focus,
    .contact-form-style-03 .form-floating > .form-control:not(:placeholder-shown),
    .contact-form-style-03 .flex-fill.form-floating > .form-control:focus,
    .contact-form-style-03 .flex-fill.form-floating > .form-control:not(:placeholder-shown) {
        padding-top: 1.875rem !important;
    }
    .contact-form-style-03 .form-floating > .form-control:focus ~ label,
    .contact-form-style-03 .form-floating > .form-control:not(:placeholder-shown) ~ label,
    .contact-form-style-03 .flex-fill.form-floating > .form-control:focus ~ label,
    .contact-form-style-03 .flex-fill.form-floating > .form-control:not(:placeholder-shown) ~ label {
        transform: scale(0.85) translateY(-0.75rem) translateX(0.15rem);
    }
}

/* form-check: Crafto imposta input { width:100%; padding:12px 25px } che rompe checkbox e radio */
.contact-form-style-03 .form-check-input {
    width: 1em !important;
    height: 1em !important;
    padding: 0 !important;
    margin-top: 0.25em;
    margin-left: -1.5em;
    vertical-align: top;
    flex-shrink: 0;
    cursor: pointer;
    border: 1px solid rgba(0, 0, 0, 0.25);
    border-radius: 0.25em;
    appearance: none;
    -webkit-appearance: none;
    background-color: #fff;
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}
.contact-form-style-03 .form-check-input:checked {
    background-color: #003869;
    border-color: #003869;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='3' d='m6 10 3 3 6-6'/%3e%3c/svg%3e");
}
/* Crafto forza placeholder visibile con !important: nascondilo dentro form-floating */
.contact-form-style-03 .form-floating > .form-control::-webkit-input-placeholder,
.contact-form-style-03 .flex-fill.form-floating > .form-control::-webkit-input-placeholder { color: transparent !important; }
.contact-form-style-03 .form-floating > .form-control::placeholder,
.contact-form-style-03 .flex-fill.form-floating > .form-control::placeholder { color: transparent !important; }

.contact-form-style-03 .form-check {
    padding-left: 1.5em;
    margin-bottom: 0.5rem;
    text-align: left !important;
}
.contact-form-style-03 .form-check-label {
    cursor: pointer;
    font-size: 14px;
    line-height: 1.2;
}

/* form-switch: usa flexbox per allinearlo agli altri campi senza il trucco margin negativo */
.contact-form-style-03 .form-switch {
    display: flex !important;
    align-items: center;
    gap: 0.5em;
    padding-left: 0 !important;
    text-align: left !important;
}
.contact-form-style-03 .form-switch .form-check-input {
    width: 2em !important;
    height: 1em !important;
    padding: 0 !important;
    margin-left: 0 !important;
    flex-shrink: 0;
    border-radius: 2em;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='rgba%280%2c0%2c0%2c0.25%29'/%3e%3c/svg%3e");
    background-position: left center;
    transition: background-position 0.15s ease-in-out, background-color 0.15s ease-in-out;
}
.contact-form-style-03 .form-switch .form-check-input:checked {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2020/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e");
    background-position: right center;
    background-color: #003869;
    border-color: #003869;
}

/* messageFeedback: allineamento sx per feedback campi e blocco errore generale */
.contact-form-style-03 .invalid-feedback,
.contact-form-style-03 [errorMsgContainerWrapper] { text-align: left !important; }

/* alert-danger nel form: sfondo rosso, testo e X bianchi, margine superiore, testo allineato sx */
.contact-form-style-03 .alert-danger {
    background-color: #c0392b !important;
    border-color: #c0392b !important;
    color: #fff !important;
    text-align: left !important;
    margin-top: 1rem;
    border-radius: 4px;
}
.contact-form-style-03 .alert-danger .btn-close {
    filter: brightness(0) invert(1);
    opacity: 0.9;
}
.contact-form-style-03 .alert-danger .btn-close:hover { opacity: 1; }

/* contact form style override */
.contact-form-style-03 .btn-base-color { background-color: #003869 !important; }

/* highlight color for text-highlight */
.text-highlight .separator-animation { opacity: .2 !important; }

/* news article date */
.blog-classic .blog-date,
.blog-simple .blog-date { color: #003869 !important; }

/* categories text link */
.categories-text { color: #003869 !important; }

/* btn-dark-gray with hover */
.btn-dark-gray:hover { background-color: #003869 !important; border-color: #003869 !important; }

/* ---- pager ---- */
.pagination-wrapper { gap: 12px; }

.pagination-wrapper .pagination {
    gap: 4px;
    margin: 0;
}
.pagination-wrapper .page-item .page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 8px;
    border-radius: 50px !important;
    border: 1px solid #dfdfdf;
    color: #555;
    font-size: 14px;
    font-weight: 500;
    line-height: 1;
    background-color: #fff;
    transition: background-color .2s, color .2s, border-color .2s;
    text-decoration: none;
}
.pagination-wrapper .page-item .page-link:hover {
    background-color: #003869;
    border-color: #003869;
    color: #fff;
}
.pagination-wrapper .page-item.active .page-link {
    background-color: #003869;
    border-color: #003869;
    color: #fff;
}
.pagination-wrapper .page-item.disabled .page-link {
    opacity: 0.4;
    pointer-events: none;
}
.pagination-wrapper .page-link .feather {
    font-size: 18px;
    line-height: 1;
}
.pagination-wrapper small {
    font-size: 13px;
    color: #888;
}

/* responsive */
@media (max-width: 767px) {
    h1 { font-size: 2.2rem !important; line-height: 2.5rem !important; }
}

/* ---- news detail: slideshow + lightbox ---- */
.news-slideshow {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    background: #000;
    aspect-ratio: 16 / 9;
    cursor: pointer;
}
.news-slideshow-track {
    display: flex;
    height: 100%;
    transition: transform 0.5s ease;
    will-change: transform;
}
.news-slideshow-slide {
    flex: 0 0 100%;
    height: 100%;
}
.news-slideshow-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.news-slideshow-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,.4);
    border: none;
    color: #fff;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s;
    z-index: 5;
}
.news-slideshow-btn:hover { background: rgba(0,0,0,.7); }
.news-slideshow-btn-prev { left: 14px; }
.news-slideshow-btn-next { right: 14px; }
.news-slideshow-expand {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0,0,0,.4);
    border: none;
    color: #fff;
    border-radius: 50%;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s;
    z-index: 5;
}
.news-slideshow-expand:hover { background: rgba(0,0,0,.7); }
.news-slideshow-dots {
    position: absolute;
    bottom: 14px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 5;
}
.news-slideshow-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,.5);
    border: none;
    padding: 0;
    cursor: pointer;
    transition: background .2s, transform .2s;
}
.news-slideshow-dot.active {
    background: #fff;
    transform: scale(1.3);
}
#newsLightbox .modal-dialog { max-width: 90vw; }
#newsLightbox .modal-content { background: #000; border: none; border-radius: 10px; }
#newsLightbox .lightbox-img { max-height: 80vh; width: 100%; object-fit: contain; border-radius: 8px; }
#newsLightbox .lightbox-caption { color: rgba(255,255,255,.7); font-size: 0.875rem; text-align: center; padding: 8px 0 0; }
#newsLightbox .btn-lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,.15);
    border: none;
    color: #fff;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s;
    z-index: 10;
}
#newsLightbox .btn-lightbox-nav:hover { background: rgba(255,255,255,.35); }
#newsLightbox .btn-lightbox-prev { left: -22px; }
#newsLightbox .btn-lightbox-next { right: -22px; }

/* ---- news detail: file download buttons ---- */
.news-file-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 22px;
    border: 1.5px solid #003869;
    border-radius: 8px;
    color: #003869;
    background: transparent;
    text-decoration: none;
    font-size: 18px;
    font-weight: 500;
    transition: background .2s, color .2s;
}
.news-file-btn:hover {
    background: #003869;
    color: #fff;
}
.news-file-btn i { flex-shrink: 0; font-size: 18px; }

/* ---- news-content (testo articolo news) ---- */
.news-content h1,
.news-content h2,
.news-content h3,
.news-content h4,
.news-content h5,
.news-content h6 {
    font-family: var(--alt-font);
    font-weight: 600;
    color: #003869;
    margin: 30px 0 15px;
}
.news-content h1 { font-size: 30px; line-height: 1.3; }
.news-content h2 { font-size: 26px; line-height: 1.3; }
.news-content h3 { font-size: 22px; line-height: 1.35; }
.news-content h4 { font-size: 19px; line-height: 1.4; }
.news-content h5 { font-size: 17px; line-height: 1.4; }
.news-content h6 { font-size: 16px; line-height: 1.4; }
.news-content > h1:first-child,
.news-content > h2:first-child,
.news-content > h3:first-child,
.news-content > h4:first-child,
.news-content > h5:first-child,
.news-content > h6:first-child { margin-top: 0; }

.news-content ul,
.news-content ol {
    margin: 0 0 20px;
    padding-left: 28px;
}
.news-content ul li { list-style: disc; }
.news-content ol li { list-style: decimal; }
.news-content ul ul li,
.news-content ol ul li { list-style: circle; }
.news-content li { margin-bottom: 8px; display: list-item; }
.news-content li:last-child { margin-bottom: 0; }

.news-content table {
    width: 100%;
    margin: 0 0 20px;
    border-collapse: collapse;
    font-size: 16px;
}
.news-content table th,
.news-content table td {
    padding: 12px 16px;
    border: 1px solid #d2d2d7;
    text-align: left;
    vertical-align: top;
}
.news-content table th {
    background-color: #003869;
    color: #fff;
    font-weight: 600;
}
.news-content table tr:nth-child(even) td { background-color: #f5f7f9; }

@media (max-width: 767px) {
    .news-content table {
        display: block;
        width: max-content;
        max-width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

/* ---- sitemap ---- */
.sitemap,
.sitemap ul {
    list-style: none;
    margin: 0;
    padding: 0;
}
.sitemap > li:first-child > a { margin-top: 0; padding-top: 0; border: none; }
.sitemap > li {
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
}
.sitemap > li + li > a { border-top: 1px solid #d2d2d7; padding: 1rem 0.75rem 1rem; margin-top: 3rem; }
.sitemap > li.nochild + li > a { margin-top: 0; }
.sitemap > li > li.nochild > a { padding-top: 1.5rem; }
.sitemap h2,
.sitemap li h3 { font-weight: 600; }
.sitemap li h2 { margin-bottom: 0; font-size: 22px; color: #003869; font-family: var(--alt-font); }
.sitemap li h3 { font-size: 17px; margin-bottom: 0.3rem; color: #222; font-family: var(--alt-font); }
.sitemap a { text-decoration: none; font-size: 15px; display: inline-block; width: 100%; color: #555; transition: color .15s; }
.sitemap a:hover { color: #003869; }
.sitemap > li > ul {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    margin: 0;
    padding: 0;
}
.sitemap > li > ul > li {
    flex: 0 0 auto;
    width: 33.33333%;
    display: flex;
    flex-wrap: wrap;
    flex-direction: column;
    padding: 0 0.75rem;
}
.navbar .btn { letter-spacing: 0; }

.sitemap > li > ul > li.haschild > a { padding-top: 0.75rem; text-decoration: underline; text-underline-offset: 2px; }
.sitemap > li > ul > li > a,
.sitemap > li > ul > li > ul > li > a { padding-bottom: 0.5rem; line-height: 1.4; }
@media (max-width: 768px) {
    .sitemap > li > ul { flex-direction: column; margin-top: 1.5rem; }
    .sitemap > li > ul > li { width: 100%; padding-top: 0; }
    .sitemap > li > ul > li:not(:first-child) > a > h3 { margin-top: 1.5rem; }
    .sitemap > li:not(.nochild) > a { margin-bottom: 0; padding-bottom: 0; }
    .sitemap > li > ul > li.haschild + li:not(.haschild) { margin-top: 1.5rem; }
}
