/* ====================================================================
 * sedi-maps.css
 * Stili per la pagina Contatti / mappa sedi aziendali
 * Layout: mappa sopra, lista sedi sotto divisa per categoria
 * ==================================================================== */

:root {
    --sedi-accent       : #b5a150;
    --sedi-accent-hover : #1558b0;
    --sedi-icon-size    : 18px;
}

.sedi-archive {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px 60px;
    padding-top: 120px;
    width: 100%;
}

.sedi-page-header {
    padding: 40px 0 24px;
    text-align: center;
}

.sedi-title {
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -.02em;
    margin: 0 0 8px;
}

.sedi-title::after {
    content: '';
    display: block;
    width: 48px;
    height: 3px;
    background: currentColor;
    margin: 10px auto 0;
    opacity: .25;
}

/* ----- Layout: colonna flex, mappa sopra sidebar sotto ----- */
.sedi-layout {
    display: flex;
    flex-direction: column;
    gap: 0;
    border: 0;
    border-radius: 12px;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    overflow: hidden;
    height: auto;
}

/* ----- Mappa ----- */
.sedi-map-wrap {
    position: relative;
    height: 480px;
    flex-shrink: 0;
}

#sedi-map {
    width: 100%;
    height: 100%;
}

/* ----- Sidebar (sotto la mappa) ----- */
.sedi-sidebar {
    display: flex;
    flex-direction: column;
    border-top: 0;
    border-right: none;
    background: #fff;
    overflow: visible;
    border: 0;
}

/* ----- Contatore ----- */
.sedi-counter {
    display: flex;
    align-items: baseline;
    gap: 4px;
    padding: 0;
    font-size: 0.85rem;
    color: #888;
    margin-top: 25px;
}

.sedi-counter #sedi-count-current {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--sedi-accent);
    line-height: 1;
}

.sedi-counter-label {
    font-weight: 500;
}

/* ----- Ricerca ----- */
.sedi-search-wrap {
    padding: 0;
    border-bottom: 0;
    background: transparent;
    margin-bottom: 50px;
}

.sedi-search {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 14px;
    border: 1px solid rgba(0,0,0,.15);
    border-radius: 8px;
    font-size: .9rem;
    outline: none;
    transition: border-color .2s;
}

.sedi-search:focus {
    border-color: var(--sedi-accent);
}

/* ----- Gruppi categoria ----- */
.sedi-gruppo {
    margin-bottom: 50px;
}

.sedi-gruppo:last-child {
    margin-bottom: 0;
}

span.label--sede {
    display: flex;
    width: 100%;
    margin-bottom: 5px;
}

.sedi-gruppo-titolo {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: #000000;
    margin: 0 0 0;
    padding: 16px 0 10px;
    border-bottom: 0;
    background: #e4d38c;
    border-radius: 26px;
    padding: 10px;
}

/* ----- Lista sedi: una per riga, no scroll ----- */
.sedi-list {
    list-style: none;
    margin: 0;
    padding: 0;
    overflow: visible;
    height: auto;
    -webkit-mask-image: none;
    mask-image: none;
}

.sedi-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 15px;
    border-bottom: 1px solid #000;
    cursor: pointer;
    transition: background .15s;
    width: 100%;
    box-sizing: border-box;
}

.sedi-item:last-child {
    border-bottom: none;
}

.sedi-item:hover {
    background: #b5a1500d;
}

.sedi-item.is-active {
    background: #b5a1501f;
    /* border-left: 3px solid #b5a150; */
    padding-left: 13px;
}

.sedi-item--no-map {
    cursor: default;
    opacity: .85;
}

.sedi-item-body {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    flex: 1;
    z-index: 0;
}

.sedi-item-nome {
    font-size: 2rem;
    font-weight: 600;
    color: #1a1a1a;
    line-height: 100%;
}

.sedi-item-indirizzo {
    font-size: .85rem;
    color: #282828;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sedi-item-recapiti {
    font-size: .78rem;
    color: #444;
    line-height: 1.5;
    margin-top: 2px;
}

.sedi-item-recapiti a {
    color: #000;
    text-decoration: none;
    position: relative;
    display: inline-block;
}

.sedi-item-recapiti a:hover:before {
    content: '';
    position: absolute;
    bottom: 0;
    left: -2.5%;
    width: 105%;
    height: 100%;
    background: #b5a150;
    opacity: .4;
    z-index: -1;
}

.sedi-item-recapiti a:before {
    content: '';
    position: absolute;
    bottom: 0;
    left: -2.5%;
    width: 105%;
    height: 15%;
    background: #b5a150;
    z-index: -1;
    opacity: .4;
    transition: all ease-in-out .1s;
}

.sedi-item-orari {
    font-size: .75rem;
    color: #666;
    line-height: 1.5;
    margin-top: 2px;
}

.sedi-item-scheda {
    display: inline-block;
    width: fit-content;
    align-self: flex-start;
    margin-top: 4px;
    font-size: .78rem;
    font-weight: 600;
    color: var(--sedi-accent);
    text-decoration: none;
}

.sedi-item-scheda:hover {
    text-decoration: underline;
}

.sedi-empty {
    padding: 24px 16px;
    color: #888;
    font-size: .9rem;
}

/* ----- Marker sulla mappa ----- */
.sedi-map-marker {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2.5px solid #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,.3);
    overflow: hidden;
    cursor: pointer;
    background: #fff;
    transition: transform .15s, box-shadow .15s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sedi-map-marker:hover {
    transform: scale(1.15);
    box-shadow: 0 4px 14px rgba(0,0,0,.35);
}

.sedi-map-marker img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 2px;
}

.sedi-map-marker--fallback {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--sedi-accent);
    background: #e8f0fe;
}

/* ----- InfoWindow ----- */
.sedi-infowindow {
    min-width: 260px;
    max-width: 300px;
    padding: 8px 4px;
    font-family: inherit;
}

.sedi-iw-body {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sedi-iw-nome {
    margin: 0 0 6px;
    font-size: .95rem;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.3;
}

.sedi-iw-row {
    margin: 0;
    font-size: .82rem;
    color: #444;
    line-height: 1.5;
}

.sedi-iw-recapiti a {
    color: var(--sedi-accent);
    text-decoration: none;
}

.sedi-iw-recapiti a:hover {
    text-decoration: underline;
}

.sedi-iw-orari {
    color: #666;
    font-size: .78rem;
    font-style: italic;
}

.sedi-iw-scheda {
    display: inline-block;
    margin-top: 6px;
    font-size: .82rem;
    font-weight: 600;
    color: var(--sedi-accent) !important;
    text-decoration: none;
}

.sedi-iw-scheda:hover {
    text-decoration: underline;
}

.sedi-infowindow p {
    font-size: 13px !important;
}

/* ====================================================================
 * Responsive mobile
 * ==================================================================== */
@media (max-width: 768px) {

    .sedi-map-wrap {
        height: 320px;
    }

    .sedi-search {
        font-size: 1rem; /* impedisce zoom automatico su iOS/Android */
    }

    .sedi-item {
        padding: 12px 14px;
    }

    .sedi-item-nome {
        font-size: 1.4rem;
    }
}

.gm-ui-hover-effect {
    opacity: 1
}

.gm-ui-hover-effect>span {
    background-color: #d04232;
    opacity: 1!important;
    border-radius: 50%;
    mask-image: none!important;
    background: #d04232;
    display: flex!important;
    align-items: center;
    justify-content: center;
    background-image: url('/svg/icon-close-04.svg')!important;
    background-size: 10px;
    background-repeat: no-repeat;
    background-position: center
}

.sedi-item-orari blockquote {
    font-weight: 200;
    font-style: normal!important;
    margin: 0.25em 0;
    padding: 0px;
    line-height: 100% !important;
    position: relative;
    border-left: 0;
    background-image: url('/svg/i-message.svg');
    background-repeat: no-repeat;
    background-position: top left;
    background-size: 30px;
    padding-left: 40px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 30px!important;
}

.sedi-item-orari blockquote p {
    font-size: 1rem!important;
    margin: 0;
    font-weight: bold;
}