/**
 * Find Help Page Template Styles
 */

/* Map marker styling */
/* Removed generic marker styling to prevent conflicts */

/* Map container and related elements */
.disposal-map {
    position: relative;
}

.disposal-map .section-header {
    text-align: center;
    margin-bottom: 30px;
}

.disposal-map .section-header h2 {
    margin: 0;
    font-size: 2rem;
}

/* Map search form */
.map-search {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    gap: 10px;
}

.map-search label {
    font-weight: bold;
    margin-right: 10px;
    color: #fff;
}

.map-search input[type="text"] {
    padding: 8px 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    min-width: 250px;
}

.map-search input[type="submit"] {
    padding: 8px 24px;
    background-color: #d2d500;
    color: #000;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}

.map-search input[type="submit"]:hover {
    background-color: #b8bb00;
}

.map-search a#clear {
    color: #555;
    text-decoration: underline;
    margin-left: 10px;
}

#no-results {
    display: none;
    width: 100%;
    text-align: center;
    color: #d9534f;
    margin-top: 15px;
    font-weight: bold;
}

/* Map and overlay */
#map {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    height: 750px;
}

.map-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    cursor: pointer;
}

.map-intro {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    max-width: 500px;
    background-color: #d2d500; /* Yellow background */
    padding: 30px;
    border-radius: 4px;
    z-index: 1001;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.3);
    text-align: center;
}

.map-intro .close {
    position: absolute;
    top: 10px;
    right: 15px;
    cursor: pointer;
    font-weight: bold;
    font-size: 18px;
    color: #000; /* Black text */
    opacity: 0.7;
    width: 25px;
    height: 25px;
    line-height: 25px;
    text-align: center;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.1);
}

.map-intro .close:hover {
    opacity: 1;
    background-color: rgba(0, 0, 0, 0.2);
}

.map-intro h3 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #000; /* Black text */
    font-size: 24px;
    font-weight: bold;
    text-transform: uppercase;
}

.map-intro p {
    margin-bottom: 0;
    line-height: 1.6;
    font-size: 16px;
    color: #000; /* Black text */
}

/* Map popup styles */
.map-popup {
    padding: 15px !important;
    max-width: 280px;
    background-color: #000 !important;
    border-radius: 4px !important;
    color: #fff !important;
    margin: 0 !important;
}

/* Style the Mapbox popup close button */
.mapboxgl-popup-close-button {
    color: #fff;
    font-size: 18px;
    padding: 5px 10px;
    right: 10px;
    top: 10px;
    border: none;
    background: transparent;
    line-height: 1;
}

.mapboxgl-popup-close-button:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #d2d500;
}

/* Style the popup content */
.map-popup .title {
    font-weight: bold;
    font-size: 16px;
    margin-bottom: 8px;
    color: #fff;
}

.map-popup .address,
.map-popup .phone {
    margin-bottom: 8px;
    font-size: 14px;
    color: #ddd;
}

.map-popup .links {
    margin-top: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.map-popup .links a {
    color: #d2d500; /* Yellow links */
    text-decoration: none;
    font-size: 14px;
    font-weight: bold;
}

.map-popup .links a:hover {
    text-decoration: underline;
    color: #fff;
}

/* Style the popup container */
.mapboxgl-popup-content {
    background-color: #000 !important;
    padding: 0 !important;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.5);
    border-radius: 4px !important;
}

/* Fix popup tip colors for all directions */
.mapboxgl-popup-anchor-top .mapboxgl-popup-tip,
.mapboxgl-popup-anchor-top-left .mapboxgl-popup-tip,
.mapboxgl-popup-anchor-top-right .mapboxgl-popup-tip {
    border-bottom-color: #000 !important;
    border-top-color: transparent !important;
}

.mapboxgl-popup-anchor-bottom .mapboxgl-popup-tip,
.mapboxgl-popup-anchor-bottom-left .mapboxgl-popup-tip,
.mapboxgl-popup-anchor-bottom-right .mapboxgl-popup-tip {
    border-top-color: #000 !important;
    border-bottom-color: transparent !important;
}

.mapboxgl-popup-anchor-left .mapboxgl-popup-tip {
    border-right-color: #000 !important;
    border-left-color: transparent !important;
}

.mapboxgl-popup-anchor-right .mapboxgl-popup-tip {
    border-left-color: #000 !important;
    border-right-color: transparent !important;
}

/* SAMHSA Callout Section */
.callout-content {
    background-color: #000;
    padding: 50px 0;
    position: relative;
}

.callout-content .content {
    position: relative;
    color: #fff;
    text-align: center;
    font-size: 1.3rem;
    margin-bottom: 20px;
}

.callout-content .content-link {
    position: relative;
    text-align: center;
}

/* Contact section with map */
.contact {
    position: relative;
    
    & .contact-wrapper {
        display: flex;
        flex-direction: row;
        width: 100%;
        border-radius: var(--border-radius-secondary);
        overflow: hidden;
        background-color: #000;
    }
    
    & .contact-map-side,
    & .contact-info-side {
        width: 50%;
        min-height: 400px;
        position: relative;
    }
    
    & .contact-info-side {
        background-color: #000;
        color: #fff;
    }
    
    & .contact-info {
        padding: var(--spacing-lg);
        height: 100%;
        display: flex;
        flex-direction: column;
        justify-content: center;
        
        & .contact-title {
            font-size: 1.75rem;
            font-weight: bold;
            text-transform: uppercase;
            margin-bottom: var(--spacing-sm);
            color: #fff;
            font-family: var(--font-heading-primary);
        }
        
        & .contact-subtitle {
            font-size: 1.25rem;
            font-weight: bold;
            text-transform: uppercase;
            margin-top: var(--spacing-md);
            margin-bottom: var(--spacing-sm);
            color: #fff;
            font-family: var(--font-heading-primary);
        }
        
        & .office-address,
        & .mailing-address,
        & .contact-details {
            margin-bottom: var(--spacing-md);
            line-height: 1.6;
            color: #fff;
            
            & p {
                margin: 0;
                font-family: var(--font-body-primary);
            }
        }
        
       
        & .staff-contact-link {
            margin-top: var(--spacing-md);
        }
    }
    
    /* Responsive styles */
    @media (max-width: 768px) {
        & .contact-wrapper {
            flex-direction: column;
        }
        
        & .contact-map-side,
        & .contact-info-side {
            width: 100%;
        }
    }
}

#contact-map {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    min-height: 400px;
    border-radius: var(--border-radius-secondary);
}

/* SAMHSA Callout Section - Button Styles */
.callout-content {
    position: relative;
    background-color: #000;
    color: #fff;
    
    & .content {
        text-align: center;
        font-size: 1.3rem;
        margin-bottom: 20px;
        position: relative;
        z-index: 2;
    }
    
    & .content-link {
        text-align: center;
        position: relative;
        z-index: 2;
    }
    
    & .btn-yellow {
        background-color: #d2d500;
        color: #000;
        padding: 10px 20px;
        text-decoration: none;
        border-radius: 4px;
        display: inline-block;
        font-weight: bold;
        
        &:hover {
            background-color: #bfc200;
            text-decoration: none;
        }
    }
}

/* Screen reader text */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .map-search {
        flex-direction: column;
        align-items: stretch;
    }
    
    .map-search input[type="text"] {
        min-width: auto;
        width: 100%;
    }
    
    .map-intro {
        width: 90%;
    }
    
    .contact-wrapper {
        flex-direction: column;
    }
    
    .contact-map-side,
    .contact-info-side {
        width: 100%;
    }
    
    .contact-info {
        padding: 30px 20px;
    }
}

@media (max-width: 576px) {
    #map {
        height: 750px !important;
    }
    
    #contact-map {
        min-height: 300px !important;
    }
    
    .callout-content .content {
        font-size: 1.1rem;
    }
}
