/* -- variables -- */
:root{
    --text: #1a1a1a;
    --primary: #103456;
    --accent: #df6d30;
    --accent-hover: hsl(21, 73%, 49%);
    --abbr-card: #F8F8F8;
    --inactive: #BDBDBD;
    --subtext: #505050;
    --search-icon: #757575;
    --search-background: #EBEBEB;
    --blue-filter: rgba(14, 38, 79, 0.75); 
    --accent-lighter: #F3D199;

}




/* -- typography -- */
h1,h2,h3{
    margin: 0;
}

p{
    line-height: 1.5;
}

.display-1 {
    font-size: 4rem;
    font-weight: bold;
    margin: 0;
    padding: 0;
}

.display-2 {
    font-size: 2.8rem;
    font-weight: bold;
    margin: 0;
    padding:0;
}

.short-underline::before{
    content: ''; 
    display: block; 
    width: 5%; 
    height: 2px; 
    background-color:var(--accent); 
    margin-bottom: 10px;
}

.short-underline::after{
    content: ''; 
    display: block; 
    width: 5%; 
    height: 2px; 
    background-color:var(--accent); 
}



/* -- HTML Elements -- */

html{
    font-size: 20px;
    color: var(--text);
    max-width: 100%;
    overflow-x: hidden;
}

body{
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background-color: var(--background);
    margin: 0;
    width: 100%;
    scroll-behavior: smooth;
}

main{
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

section{
    display: flex;
    flex-direction: column;
    padding: 0 5vw;
    box-sizing: border-box;   
}

input {
    border: none;
    outline: none;
    box-shadow: none;
    background-color: transparent;
}

input:focus,
input:active {
    border: none;
    outline: none;
    box-shadow: none;
    background-color: transparent;
}

i{
    color: var(--text);
    height: fit-content;
}

a{
    color: var(--primary);
}

ol li::marker {
    font-weight: bold;
}


/* -- Global Classes */

.container-half{
    width: 48%;
}

.text-btn{
    background-color: transparent;
    border: none
}

.clear-btn{
    background-color: transparent;
    border: none;
    width: auto;
    height: 100%;
    display: none;
    align-items: center;
    padding: 0 1rem;
}

.clear-btn i{
    font-size: 1rem;
}

.clear-btn:hover i{
    color: var(--text);
}

.select i {
    transition: transform 0.3s ease-in-out;
}

.select.open i{
    transform: rotate(180deg);
    
}

.search{
    display: flex;
    flex-direction: row;
    box-sizing: border-box;
    justify-content: space-between;
    align-items: center;
    background-color: white;
    border: 1px solid var(--inactive);
    box-shadow: 1px 2px 3px rgba(0, 0, 0, 0.25);
    border-radius: 48px;
}

.search-input{
    width: 100%;
}

.search-wrapper{
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
}

.search i{
    color: var(--search-icon);
}

.vertical-seperator{
    width: 1px;
    height: 100%;
    background-color: var(--inactive);
}

.horizontal-seperator{
    height: 0.25px;
    width: 100%;
    background-color: var(--inactive);
}

.dot{
    width: 2px;
    height: 2px;
    background-color: var(--text);
    border-radius: 100%;
}

.visible{
    display: flex; 
}

.hidden {
    display: none;
}

.desktop-only{
    display: flex;
}

.mobile-only{
    display: none;
    align-self: center;
}


/*#region -- header -- */
.header{
    display: flex;
    flex-direction: column;
    gap: 3rem;
    width: 100%;
    padding: 0;
}

.header-background{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: #A9C3DA;
    gap: 0.75rem;
    padding: 4rem 5vw 8rem 5vw;
    background-image:
    linear-gradient(var(--blue-filter), var(--blue-filter)),
    image-set(
      url("/static/header.webp") type("image/webp"),
      url("/static/header.jpg") type("image/jpeg")
    );
    background-blend-mode: multiply;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
}

.header-background .display-2{
    text-align: center;
}

.header-background svg{
    width: 100%;
}

#header-search{
    margin-top: -4.65rem;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    height: 70px;
    width: 80%;
    align-self: center;
    padding: 8px 8px 8px 24px;
    background-color: var(--search-background);
    border-radius: 48px;
    box-sizing: border-box;
}

#header-search input{
    font-size: 1.5rem;
    flex-grow: 1;
}

#header-search #search-btn{
    flex-grow: 0;
    flex-shrink: 0;
    background-color: var(--accent);
    padding: 6px;
    border-radius: 48px;
    aspect-ratio: 1/1;
    height: 100%;
    border: none;
    box-shadow: 1px 2px 3px rgba(0, 0, 0, 0.15);
}

#header-search #search-btn:hover{
    background-color: var(--accent-hover);
}

#header-search #search-btn:active{
    transform: scale(0.98);
}

#header-search .select-wrapper{
    flex-grow: 0;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    height: 100%;
    align-items: center;
    padding-left: 12px;
    padding-right: 12px;
    margin-right: 0.7rem;
    border-right: 1px solid var(--inactive);
    border-left: 1px solid var(--inactive);
    position: relative;
    font-size: 1.5rem;

}

#header-search .select{
    display: flex;
    flex-direction: row;
    align-items: center;
    width: 180px;
    height: 100%;
    justify-content: space-between;
    top: 0;
    gap: 6px;
}

#header-search .select-options{
    position: absolute;
    top: 120%;
    left: 0;
    display: none;
    flex-direction: column;
    justify-content: center;
    background-color: white;
    padding: 1rem;
    width: 160px;
    z-index: 2;
    border-radius: 24px;
    border: 0.25px solid var(--inactive);
}

#header-search .select-option{
    padding: 6px;
    font-size: 1.25rem;
}

#header-search .select-option.active{
    font-weight: bold;
}

#header-search .select-option:active{
    transform: scale(0.98);
}

#header-search .select-option:hover{
    background-color: var(--search-background);
}

#stats-wrapper{
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    padding: 24px 5vw;
    gap: 1rem;
}

#stats-wrapper .vertical-seperator{
    height: 60px;
    width: 0.5px;
}

.stat{
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.stats-number{
    font-size: 3rem;
    font-weight: bold;
    color: var(--accent);
}

.stats-text{
    font-size: 1.5rem;
}




/*#endregion  */


/*#region -- about -- */
section#about .container-wrapper{
    display: flex;
    flex-direction: column;
    gap: 2rem;
}


#exploring{
    width: 100%;
}


#about-organoidmap-wrapper{
    display: flex;
    flex-direction: row;
    width: 100%;
    justify-content: space-between;
}

#about-organoidmap{
    width: 40%;
}

#sunburst-wrapper{
    margin-top: 0.5rem;
    width: 48%;
}

#sunburst-wrapper img{
    width: 100%;
    height: auto;
}

#vision-mission-wrapper{
    display: flex;
    flex-direction: row;
    padding: 2rem 0;
}

#vision-mission-wrapper h1{
    font-size: 1.5em;
}

#vision{
    background-color: var(--accent);
    padding-left:5vw;
    padding-right: 1rem;
    padding-top: 2rem;
    padding-bottom: 2rem;
}

#mission{
    background-color: var(--accent-lighter);
    padding-right: 5vw;
    padding-left: 1rem;
    padding-top: 2rem;
    padding-bottom: 2rem;
}
/*#endregion */

/*#region -- how to --  */
#how-to{
    gap: 2rem;
}

#how-to .container-wrapper{
    display: flex;
    flex-direction: row;
    gap: 1rem;
}
/*#endregion  */

/*#region -- visualizations --  */
#visualizations{
    display: flex;
    flex-direction: column;
}
#charts-wrapper{
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: fit-content;
    gap: 2rem;
}

#visualizations .pie-container{
    width: 100%;
    height: 320px;
}


#visualizations .chart-wrapper{
    flex: 1 1 26%; 
    max-width: 40%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.reset-selection-btn{
    flex-direction: row;
    gap: 0.5rem;
    width: fit-content;
    align-self: flex-end;
    color: var(--primary);
    font-size: 1rem;
}

.reset-selection-btn i{
    color: var(--primary);
}

.reset-selection-btn:hover, .reset-selection-btn:hover i{
    color: var(--accent);
}

.reset-selection-btn:active{
    transform: scale(0.98);
}



/*#region -- datatable -- */
#table-filters{
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-content: stretch;
    background-color: var(--primary);
    padding: 8px;
    gap: 5px;
    border-radius: 10px;
}

#table-filters .select-wrapper{
    flex: 1;
    position: relative;
}

#table-filters .select{
    display: flex;
    flex-direction: row;
    background-color: white;
    border: 1px solid var(--inactive);
    border-radius: 0.25rem;
    width: 100%;
    justify-content: space-between;
    box-sizing: border-box;
    padding: 0.5rem 1rem ;
}

#table-filters .select.active-filter{
    background-color: var(--accent);
    border-color: var(--accent);
}

#table-filters #clear-filter-btn{
    display: none;
    color: var(--accent);
    text-decoration: underline;
    font-size: 1rem;
    align-self: center;

}

#table-filters #clear-filter-btn:active{
    transform: scale(0.95);
}

#table-filters #clear-filter-btn:hover{
    color: var(--accent-hover);
}

#table-filters .filter-options{
    position: absolute;
    display: none;
    flex-direction: column;
    top: 100%;
    left: 0;
    min-width: 100%; 
    width: 300px;
    max-height: 300px;
    z-index: 10;
    background: white;
    gap: 0.875rem;
    border: 1px solid var(--inactive);
    border-radius: 0.25rem;


    overflow-y: auto; 
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: #888 #f0f0f0;
}

#journal-filter .filter-options{
    right: 0;
    left: auto;
}

.filter-options::-webkit-scrollbar {
    width: 4px;             
}

.filter-options::-webkit-scrollbar-thumb {
    background-color: rgba(0,0,0,0.3); 
    border-radius: 10px;               
}

.filter-options::-webkit-scrollbar-track {
    background-color: #f0f0f0; 
    border-radius: 10px;
  }


#table-filters .filter-options .options-container{
    display: flex;
    flex-direction: column;
    font-size: 0.875rem;
    gap: 0.5rem;
}

.options-container .checkbox{
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 0.25rem 0.5rem;
    gap: 0.5rem;
}

.options-container .checkbox:hover{
    background-color: var(--accent);
}


input[type=checkbox] {
    accent-color: var(--accent);
}

.checkbox label{
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    width: 100%;
    gap: 2rem;
}

.checkbox label span{
    color: var(--subtext);
}

#table-filters .search{
    padding: 3%;
    width: 90%;
    align-self: center;
    margin-top: 1rem;
    
}

#table-filters .search i{
    font-size: 0.8rem;
}

.tabulator .tabulator-footer .tabulator-page.active {
    border-color: var(--accent);
    background-color: var(--abbr-card);
    border-width: 1.5px;
}

.tabulator-page:hover {
    border-color: var(--accent-hover)!important;
}



/*#endregion */


/*#region -- abbreviations -- */

#abbreviations-wrapper{
    display: flex;
    flex-direction: column;
    width: 94%;
    gap: 3rem;
    align-self: center;
    padding: 2rem;
    background:
    linear-gradient(to right, var(--primary) 3px, transparent 3px) 0 0,
    linear-gradient(to right, var(--primary) 3px, transparent 3px) 0 100%,
    linear-gradient(to left, var(--primary) 3px, transparent 3px) 100% 0,
    linear-gradient(to left, var(--primary) 3px, transparent 3px) 100% 100%,
    linear-gradient(to bottom, var(--primary) 3px, transparent 3px) 0 0,
    linear-gradient(to bottom, var(--primary) 3px, transparent 3px) 100% 0,
    linear-gradient(to top, var(--primary) 3px, transparent 3px) 0 100%,
    linear-gradient(to top, var(--primary) 3px, transparent 3px) 100% 100%;

    background-repeat: no-repeat;
    background-size: 20px 20px;
}

#abbr-filterbar{
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
}

#abbr-filterbar .vertical-seperator{
    height: 1rem;
}

#abbr-filterbar button{
    font-size: 1.125rem;
}

#abbr-filterbar button.active{
    color:var(--accent);
}

#abbr-filterbar button:not([disabled]):hover{
    color:var(--accent-hover);
}

#abbr-filterbar button:not([disabled]):active{
    transform: scale(0.95);
}

#abbr-search{
    width: 40%;
    height: 40px;
    padding: 8px 16px;
}


#abbr-search:focus-within {
    border-color: var(--accent);
}

#abbr-cards-wrapper{
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
}

.abbr-card{
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    box-sizing: border-box;
    padding: 15px 21px;
    gap: 15px;
    text-align: left;
    background-color: var(--abbr-card);
    border: 1px solid var(--inactive);
    border-radius: 8px;
    box-shadow: 2px 3px 4px rgba(0, 0, 0, 0.25);
}

.abbr-card:hover{
    border: 1px solid var(--accent);
}

.abbr-card .abbr-text{
    font-size: 1rem;
    color: var(--accent);
}

.abbr-card .abbr-description{
    font-size: 0.875rem;
    color: var(--subtext);
}





/*#endregion */


/*#region -- footer --  */
#footer{
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background-color: var(--primary);
    color: #FFF;
    width: 100%;
    margin-top: 8rem;
    padding: 1rem 5vw 0.5rem;
    gap: 0.5rem;
    box-sizing: border-box;
}

#footer a{
    color: white;
}

#footer a:hover{
    color: var(--accent);
}

#footer .about{
    width: 40%;
}

#top-row{
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-around;
    align-items: center;
    
}

#links{
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    width: 100%;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
}

#credit{
    width: fit-content;
    font-size: 0.725rem;
    align-self: center;
    text-align: center;
}

#credit p{
    margin:5px;
}

#dev{
    font-size: 0.7rem;
}



#links a{
    color: white;
}

#links a:hover{
    color: var(--accent);

}

.footer-logo{
    width: 17%;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.footer-logo img{
    width: 100%;
}

.footer-logo#organoid-map-logo{
    width: 45%;
}

/*#endregion  */

/*#region CSS only for legal.html  */
#legal{
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

#legal section#info{
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

#legal .container{
    display: flex;
    flex-direction: column;
    gap:0.5rem;
}

#legal #navigation{
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
}

#legal p{
    margin: 8px;
}

#legal a{
    color: var(--primary);
}

#legal #links a{
    color: white;
}


#legal #back-btn{
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    padding: 1rem 0;
    gap: 1rem;
    font-size: 1.25rem;
    background-color: transparent;
    border: none;
    color: var(--accent);
}

#legal #back-btn i{
    color: var(--accent);
}

#legal #back-btn:hover, #back-btn:hover i{
    color: var(--accent-hover);
}

#legal ol li::marker {
    font-weight: bold;
    font-size: 1.17em;
}


/*#endregion  */

/* -- media -- */
/* @media (max-width: 1536px){
    .container{
        max-width: 1280px;
    }
}

@media (max-width: 1280px){
    .container{
        max-width: 1024px;
    }
}

 */

 @media (max-width: 935px){
    #stats-wrapper{
        justify-content: center;
    }
}


@media (max-width: 425px){
    html{
        font-size: 16px;
    }

    .display-2 {
        font-size: 1.5rem;
        font-weight: bold;
        margin: 0;
        padding:0;
    }

    /* Header */
    .header-background{
        gap: 0.75rem;
        padding: 2.5rem 5vw 4.5rem 5vw;
    }

    #header-search{
        margin-top: -4.5rem;
        height: 48px;
    }
    #header-search i{
        font-size: 0.7rem;
    }

    #header-search .select-wrapper{
        font-size: 0.85rem;
    }
    
    #header-search input{
        font-size: 0.85rem;
    }

    #header-search .select{
        width: 100%;
        justify-content: space-between;
        gap: 6px;
    }

  
    #header-search .select-options{
        padding: 0.5rem;
        width: 120px;
    }

    #header-search .select-option {
        padding: 6px;
        font-size: 0.85rem;
    }

    .stats-number{
        font-size: 2.5rem;
    }
    
    .stats-text{
        font-size: 1rem;
    }

    /*  about */
    #about-organoidmap-wrapper{
        flex-direction: column;
    }

    #about-organoidmap{
        width: 100%;
    }
    
    #sunburst-wrapper{
        margin-top: 0.5rem;
        width: 100%;
    }
    
    /* visualizations */

    #charts-wrapper{
        flex-direction: column;
    }

    #visualizations .chart-wrapper{ 
        max-width: 100%;
        width: 100%;
    }

    #visualizations .pie-container{
        height: 280px;
    }


    .desktop-only{
        display: none;
    }
    
    .mobile-only{
        display: flex;
    }
    
    /* datatable */
    #table-filters{
        flex-wrap: wrap;
    }

    #table-filters .filter-options{
        top: 100%;
        left: 0;
        width: fit-content;
        max-height: 300px;
        
        gap: 0.875rem;
    }

    #table-filters .select-wrapper{
        min-width: 35%;
    }

    #subgroup-filter .filter-options{
        right: 0;
        left: auto;
    }

    

    .tabulator .tabulator-footer .tabulator-footer-contents{
        flex-wrap: wrap;
    }

    .tabulator-footer{
        font-size: 0.875rem;
    }
    
    .tabulator .tabulator-footer .tabulator-page {
        border: 1px solid #dbdbdb;
        font-size: 0.875rem;
        padding: calc(.375em - 1px) .55em;
    }

    /* abbreviations */
    #abbreviations-wrapper{
        width: 92%;
        gap: 1.5rem;
        padding: 1rem;
    }

    #abbr-search{
        width: 100%;
    }

    #abbr-cards-wrapper{
        gap: 20px;
    }
    
    .abbr-card{
        flex: 1;
        padding: 8px 16px;
        gap: 8px;
        hyphens: auto;
    }
    
    /* footer */

    #footer{
        margin-top: 4rem;
    }

    #top-row{
        height: 80px;
    }

    #links{
        gap: 1rem;
        font-size: 0.8rem;
    }
    
    


}


/* -- keyframes -- */
