/*================================*/
/*   INDEX.CSS                    */
/*   KGARMIRE, 2025-01-30         */
/*================================*/

:root {
    --dcny-blue-dark: #273b5f;
    --dcny-blue-med:#5c7095;
    --dcny-blue-light:#dfe6f1;
    
    --nav-height:55px;
    --sidebar-width:390px;

    --c-waterbody: #8CB9E6;
    --c-pwb: #22daa9;
}

html, body{
    padding: 0;
    margin: 0;
    height: 100%;
    width: 100%;
    font-family:'Roboto', sans-serif;
}

body{
    overflow:hidden;
}

/*================================*/
/*         COMMON STYLES          */
/*================================*/

*{
    /*Keep it inside 100%*/
    -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
    -moz-box-sizing: border-box;    /* Firefox, other Gecko */
    box-sizing: border-box;         /* Opera/IE 8+ */
}
*:focus{outline:0; }

h1,h2,h3,h4,h5, .montserrat{font-family: 'Montserrat', sans-serif;}

fieldset{
    border-color: var(--dcny-blue-med);
    border-radius: 4px;
}

fieldset legend{
    color : var(--dcny-blue-med);
    font-weight: 600;
    font-family: "Montserrat", sans-serif;
}

button.primary{
    height:32px;
    width:100%;
    background-color: var(--dcny-blue-dark);
    color:white;
    cursor: pointer;
    border-radius: 4px;
    border: none;
}


/*================================*/
/*         ESRI OVERWRITE         */
/*================================*/
.esri-view-surface--inset-outline::after {
    /* Remove box around map in ESRI JS API 4.X*/
    outline: none !important;
    padding: 0px !important;
}

#csx{
    border:none;
    border-radius: 0;
}
#csx svg.icon{
    fill:black;
}

._qs{width: 300px;}
#quick-search-cont{
    z-index: 9;
}

#sidebar .cmt .output{padding: 12px 0; }
#sidebar .cmt button.reset{margin: 16px 0 0 0; width: 100%;}
#sidebar .cmt .polyline .grid, 
#sidebar .cmt .polygon .grid {margin: 8px 0; }
#sidebar .cmt h4 {margin: 8px 0; }

.tippy-link{
    color:var(--c-pwb);
    text-decoration: none;
}

/*================================*/
/*         MAIN STRUCTURE         */
/*================================*/
main{
    height:calc(100% - var(--nav-height));
    width:100%;

    display: grid;
    grid-template-columns: 1fr auto;
}

/*------------- MAP  -------------*/
#map-cont{
    position: relative;
    height:100%;
    width:100%;
}

#map-div{   
    padding: 0;
    margin: 0;
    height: 100%;
    width: 100%;
    z-index: 0;
}


/*--- SIDEBAR --------------------*/
#sidebar{
    width:var(--sidebar-width);
    border-left:4px solid var(--dcny-blue-med);

    display: flex;
    flex-direction: column;
}

#sidebar.closed{
    width:0;
}

#sidebar .contents{
    padding:8px;
}

#sidebar fieldset span{
    font-size: 0.8rem;
}

#sidebar .box{
    border: 1px solid var(--dcny-gray-med);
    border-radius: 4px;
    padding: 18px 12px;
}
#sidebar .legend{
    padding: 18px 12px 24px 12px;
}

#sidebar .legend-grid{
    display: grid;
    grid-template-columns: 24px 1fr 24px;
    gap: 16px;
}

#sidebar .legend img.src{
    height: 16px;
    width: 16px;
    cursor: pointer;
    margin: auto;
}

#sidebar .legend img.symbol{
    filter: drop-shadow(0px 2px 1px rgba(34,34,34,0.5));
}

#sidebar .disclaimer{
    margin-top:auto;
}

#measure-pane{
    display: none;
}

#show-map{
    margin:12px;
    width:auto;
}

/*====================================*/
/*               MODAL                */
/*====================================*/
/*#intro-modal{display:none}*/

#intro-modal h3{
    margin: 0;
    font-size: 1.6rem;
    text-align: center;
    color: black;
    font-weight: 600;
    margin: 0 0 18px 0;
}
#intro-modal h4{
    font-size: 1.1rem;
    font-weight: 600;
    margin:12px 0 0 0;
    color: var(--dcny-blue-dark);
}

#intro-modal p{
    margin-bottom: 18px;
}


/*================================*/
/*         MEDIA QUERIES          */
/*================================*/
.mobile-only{display: none}

/*------------ HOVER  ------------*/
@media (hover: hover) and (pointer: fine) {
    /*Protect against click-hover on touch devices;*/

    button.primary:hover{background-color: var(--hover-blue-dark);}
}

/* - MOBILE: PORTRAIT; (less than 576px) - */
@media (max-width: 576px) {
    header .title h1 {font-size: 12pt !important;}
    header .title h2 {display:none; }
    header .title {    
        padding: 0 12px;
        margin-left: 0 !important;
    }

    #sidebar{
        width:100%;
        border-left:none;
    }
}

/* - MOBILE: LANDSCAPE; (less than 768px) - */
@media (max-width: 768px) {
    .desktop-only{display: none}
    .mobile-only{display: block}
    #intro-modal .btn-grid{display: block}
    #intro-modal h3{font-size: 1.2rem};
    #intro-modal h4{font-size: 1.3rem};

    
}