﻿/**
 * ACTIVITY MAPS STYLESHEET
 * Based on originalhtml.html design
 * Washington Gas Activity Maps - Razor Pages Implementation
 */

/* ===================================
   RESET & BASE STYLES
   =================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Roboto, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #333;
    overflow: hidden;
}

/* ===================================
   MAIN LAYOUT
   =================================== */
#app {
    display: flex;
    height: 100vh;
    width: 100%;
    position: relative;
}

#controlBox {
    width: 350px;
    height: 100vh;
    background: #fff;
    border-right: 1px solid #ddd;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    z-index: 1000;
}

#map-container {
    flex: 1;
    position: relative;
    height: 100vh;
}

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

/* ===================================
   TOP HEADER LINE
   =================================== */
.top-header-line {
    height: 4px;
    background: linear-gradient(to right, #0066cc 0%, #1876d1 50%, #0066cc 100%);
    width: 100%;
}

.top-header-line-simple {
    height: 4px;
    background: #0066cc;
    width: 100%;
}

.region {
    font-size: 12px !important;
}

/* ===================================
   TABS NAVIGATION
   =================================== */
.tabs-nav {
    display: flex;
    list-style: none;
    background: #f5f5f5;
    border-bottom: 1px solid #ddd;
    margin: 0;
    padding: 0;
}

    .tabs-nav li {
        flex: 1;
        text-align: center;
        padding: 12px 10px;
        cursor: pointer;
        font-weight: 500;
        font-size: 13px;
        color: #0066cc;
        border-right: 1px solid #ddd;
        transition: all 0.3s ease;
    }

        .tabs-nav li:last-child {
            border-right: none;
        }

        .tabs-nav li:hover {
            background: #e8e8e8;
        }

        .tabs-nav li.active {
            background: #fff;
            color: #333;
            border-bottom: 2px solid #1876d1;
        }

        .tabs-nav li span {
            text-transform: uppercase;
            letter-spacing: 0.5px;
        }

        .tabs-nav li:not([data-key="map"]).active ~ .map-controls .filters.control-row {
            display: none;
        }

/* ===================================
   MAP CONTROLS
   =================================== */
.map-controls {
    padding: 15px;
    background: #fff;
    border-bottom: 1px solid #e5e5e5;
    display: block; /* Visible by default for Map tab */
}

/* Hide map controls when not on Map tab */
body:has(.tabs-nav li:not([data-key="mapTab"]).active) .map-controls {
    display: none;
}

.map-controls-wrapper {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Filter Buttons */
.filters.control-row {
    display: flex;
    gap: 10px;
}

.btn {
    padding: 10px 20px;
    border: 1px solid #e0e0e0;
    background: #fff;
    color: #666;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    border-radius: 25px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
}

    .btn:hover {
        background: #f5f5f5;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }

    .btn.active {
        border-color: #d0d0d0;
        box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    }

.btn-sm {
    padding: 10px 18px;
    font-size: 14px;
}

/* Projects Button */
.projects-btn {
    background: #fff;
    border-color: #d0c5e8;
    color: #5a3d8a;
}

    .projects-btn:hover {
        background: #ddd0f0;
    }

    .projects-btn.active {
        background: #dde8f7;
        border-color: #c5b5e0;
        box-shadow: 0 2px 8px rgba(90, 61, 138, 0.2);
    }

/* Outages Button */
.outages-btn {
    background: #fff;
    border-color: #e0e0e0;
    color: #666;
}

    .outages-btn:hover {
        background: #fff5f0;
    }

    .outages-btn.active {
        background: #dde8f7;
        border-color: #ff9800;
        color: #e65100;
        box-shadow: 0 2px 8px rgba(255, 152, 0, 0.3);
    }

/* Filter button icons */
.btn img.filter-icon {
    width: 20px;
    height: 20px;
    margin-right: 8px;
    object-fit: contain;
}

.projects-btn img.filter-icon {
    width: 22px;
    height: 22px;
}

.outages-btn img.filter-icon {
    width: 20px;
    height: 20px;
}

/* Search Box */
.control-row {
    position: relative;
}

.search-box {
    display: flex;
    align-items: center;
    border: 1px solid #e0e0e0;
    border-radius: 25px;
    background: #fff;
    padding: 0 15px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

    .search-box .fa {
        color: #1876d1;
        font-size: 16px;
    }

    .search-box .fa-search::before {
        content: "🔍";
        font-style: normal;
        color: #1876d1;
    }

.search-address {
    flex: 1;
    border: none;
    padding: 12px 10px;
    font-size: 14px;
    outline: none;
}

    .search-address::placeholder {
        color: #999;
    }

.search-box .fa-long-arrow-right {
    cursor: pointer;
    padding: 0;
    margin-left: 16px;
    color: #fff;
    background: #4caf50;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
    border: none;
}

    .search-box .fa-long-arrow-right:hover {
        background: #45a049;
        transform: scale(1.08);
        box-shadow: 0 2px 6px rgba(76, 175, 80, 0.4);
    }

    .search-box .fa-long-arrow-right:active {
        transform: scale(0.95);
    }

    .search-box .fa-long-arrow-right::before {
        content: "→";
        font-style: normal;
        font-size: 18px;
        font-weight: bold;
        line-height: 1;
    }

.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ddd;
    border-top: none;
    list-style: none;
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

    .search-results li {
        padding: 10px;
        cursor: pointer;
        border-bottom: 1px solid #f0f0f0;
    }

        .search-results li:hover {
            background: #f5f5f5;
        }

/* ===================================
   TABS CONTAINER & SECTIONS
   =================================== */
.tabs-container {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    background: #fff;
}
/*
.tabs-wrapper {
    min-height: 47%;
}*/

    .tabs-wrapper section {
        display: none;
        padding: 5px;
    }

        .tabs-wrapper section.active {
            display: block;
        }

/* ===================================
   ACCORDION (MAP TAB)
   =================================== */
.accordion-header {
    display: flex;
    justify-content: space-between;
    padding: 12px 15px;
    background: #0066cc;
    border-bottom: none;
    font-size: 11px;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.accordion {
    list-style: none;
    margin: 0;
    padding: 0;
}

    .accordion > li {
        border-bottom: 1px solid #e5e5e5;
    }

.acc-item-wrapper {
    cursor: pointer;
    padding: 14px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s ease;
}

    .acc-item-wrapper:hover {
        background: #f9f9f9;
    }

.acc-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    font-weight: 600;
    color: #0066cc;
    font-size: 14px;
    text-transform: uppercase;
}

.projects-num {
    font-weight: 500;
    color: white;
    font-size: 12px;
}

.projects-count {
    font-weight: 700;
    color: #4caf50;
    font-size: 14px;
}

.activities-count {
    font-weight: 500;
    color: #4caf50;
    font-size: 13px;
}


/* Sub Navigation */
.sub-nav {
    list-style: none;
    background: #fafafa;
    margin: 0;
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

    .sub-nav:not(.invisible) {
        max-height: 1000px;
    }

    .sub-nav li {
        border-top: 1px solid #e5e5e5;
    }

    .sub-nav .acc-item-wrapper {
        padding-left: 30px;
    }

.sub-acc-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    font-size: 13px;
    color: #0066cc;
    font-weight: 500;
}

/* ===================================
   SAFETY & RESOURCES TABS
   =================================== */
.map-tab-group {
    margin-bottom: 25px;
}

.map-tab-headline {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
}

.map-tab-list {
    list-style: none;
    padding: 0;
}

.map-tab-list-item {
    margin-bottom: 10px;
}

.map-tab-list-link {
    color: #1876d1;
    text-decoration: none;
    font-size: 14px;
}

    .map-tab-list-link:hover {
        text-decoration: underline;
    }

.map-tab-text {
    font-size: 14px;
    color: #555;
    line-height: 1.6;
    margin-bottom: 10px;
}

.map-tab-border {
    height: 1px;
    background: #e5e5e5;
    margin: 20px 0;
}

.map-tab-link {
    color: #1876d1;
    text-decoration: none;
    font-weight: 500;
}

    .map-tab-link:hover {
        text-decoration: underline;
    }

/* ===================================
   FOOTER
   =================================== */
footer {
    background: url('../images/washgas-logo.png') no-repeat #1d519a; /* logo */
    height: 1000px;
    padding-top: 84px;
}


.footer-wrapper {
    padding: 0 15px;
}

.footer-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-group {
    flex: 1;
    min-width: 150px;
}

.footer-headline {
    font-size: 19px;
    font-weight: 100;
    color: #b4cff0;
}

.footer-subhead {
    font-size: 14px;
    font-weight: 100;
    color: #b4cff0;
}

.footer-telephone {
    color: #fff;
    text-decoration: none;
}

.footer-email {
    font-size: 13px;
    color: #fff;
    text-decoration: none;
}

    .footer-email:hover,
    .footer-telephone:hover {
        text-decoration: underline;
        opacity: 0.9;
    }

/* ===================================
   TOGGLE MENU BUTTON (Mobile)
   =================================== */
#toggleMenu {
    display: none;
    position: fixed;
    top: 60px;
    left: 10px;
    z-index: 2000;
    padding: 10px 20px;
    background: #1876d1;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

    #toggleMenu:hover {
        background: #1565c0;
    }

/* ===================================
   RESPONSIVE DESIGN
   =================================== */
@media (max-width: 768px) {
    #toggleMenu {
        display: block;
    }

    #controlBox {
        position: fixed;
        left: -350px;
        z-index: 1500;
        transition: left 0.3s ease;
        box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    }

        #controlBox.open {
            left: 0;
        }

    #map-container {
        width: 100%;
    }

    .footer-container {
        flex-direction: column;
    }

    .footer-group {
        width: 100%;
    }
}

/* ===================================
   UTILITY CLASSES
   =================================== */
.invisible {
    display: none !important;
}

.hidden {
    visibility: hidden;
}

/* Loading States */
.loading-content {
    padding: 20px;
    text-align: center;
    color: #999;
    font-style: italic;
}

/* Google Maps Autocomplete Styling */
.pac-container {
    z-index: 10000;
    border-radius: 3px;
    border-top: 1px solid #d9d9d9;
    font-family: Roboto, Arial, sans-serif;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.pac-item {
    padding: 8px 12px;
    font-size: 13px;
    cursor: pointer;
}

    .pac-item:hover {
        background: #f5f5f5;
    }

/* Scrollbar Styling */
.tabs-container::-webkit-scrollbar {
    width: 6px;
}

.tabs-container::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.tabs-container::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
}

    .tabs-container::-webkit-scrollbar-thumb:hover {
        background: #999;
    }

/* ===================================
   LOADING & ERROR STATES
   =================================== */
.loading {
    padding: 20px;
    text-align: center;
    color: #999;
    font-style: italic;
}

.error {
    padding: 20px;
    text-align: center;
    color: #dc2626;
    background: #fee;
    border-radius: 4px;
    margin: 10px;
}

.no-data {
    padding: 20px;
    text-align: center;
    color: #666;
    font-style: italic;
}

/* Mobile Menu Open State */
#controlBox.open {
    left: 0 !important;
}

/* Search box within Map tab */
.map-tab-search {
    padding: 15px;
    border-bottom: 1px solid #e5e5e5;
    background: #fff;
}

    .map-tab-search .control-row {
        position: relative;
    }
/* ===================================
   GOOGLE MAPS INFO WINDOW
   =================================== */
.gm-style .gm-style-iw-c {
    padding: 0 !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
}

.gm-style .gm-style-iw-d {
    overflow: auto !important;
    max-height: 400px !important;
}

.gm-style .gm-style-iw-t::after {
    display: none !important;
}

/* Hide default close button */
.gm-style-iw button {
    display: none !important;
}

/* Show only our custom close button */
.gm-style-iw-d button {
    display: block !important;
}
