/* Import local fonts */

@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;400;500&display=swap');

@font-face {
    font-family: 'FontHeader';
    src: url("fonts/Montserrat-ExtraLight.otf") format("opentype");
}

@font-face {
    font-family: 'FontNormal';
    src: url("fonts/Montserrat-Light.otf") format("opentype");
}

@font-face {
    font-family: 'FontBold';
    font-weight: bold;
    src: url("fonts/Montserrat-Regular.otf") format("opentype");
}

*,
*:before,
*:after {
  box-sizing: border-box;
}

/* Headers and body styling */

p {
    margin-block-start: 0em;
    margin-block-end: 0em;
}

b {
    font-weight: 500;
}

body {
    font-family: 'Roboto';
    font-weight: 300;
    padding: 0 0 0 0;
    margin: 0 0 0 0;
}
h1 {
    font-family: 'Roboto';
    font-weight: 300;
    color: #000000;
    font-size: 34pt;
    word-wrap: break-word;
    line-height: 3.2rem;
}

h2 {
    font-family: Roboto;
    font-size: 34pt;
    font-weight: 300;
    line-height: 30pt;
    margin: 12pt 0 0;
} 

h3, h4 {
    font-family: 'Roboto';
    font-weight: 400;
    color: #383838
}

h5 {
    font-family: Roboto;
    font-size: 12pt;
    font-weight: 400;
    line-height: 16pt;
    margin: 6pt 0 12pt;
} 

h6 {
    font-family: 'Roboto';
    font-weight: 400;
    color: #ffffff;
    margin-block-start: 0em;
    margin-block-end: 2em;
}

a {
    text-decoration: underline;
    position: relative;
    color: inherit;
}

a:visited {
    color:rgb(0, 0, 0);
}

a:hover {
    color: #8E8E8E;
}

/* Utility spacers — replaces inline style="padding-bottom:..." */
.spacer-sm { padding-bottom: 0.5cm; }
.spacer-lg { padding-bottom: 2cm; }

/* License line — color only; layout inherited from parent credits block */
.license_text {
    color: #AEAEAE;
    font-weight: 500;
    font-size: 9pt;
}

/* License line in the dark home-page context */
.credits_home .license_text {
    color: rgba(255, 255, 255, 0.35);
}

/* Glossary theme colors */
.summary_ai { color: #9C2457; }
.summary_in { color: #1852A4; }
.summary_sd { color: #026027; }

/* Credits shown on home page before any category is selected (dark gradient bg) */
.credits_home {
    font-family: Roboto;
    font-weight: 500;
    font-size: 9pt;
    color: rgba(255,255,255,0.55);
    line-height: 1.4em;
    padding: 1cm 0 0.5cm 1cm;
    padding-left: 350px;
    z-index: 2;
    position: sticky;
    top: 100vh;
}

.credits_home a {
    color: rgba(255,255,255,0.55);
    text-decoration: underline;
}

.credits_home a:hover {
    color: rgba(255,255,255,0.85);
}

.credits_home a:visited {
    color: rgba(255,255,255,0.55);
}

/* Override Plotly's default Open Sans with Roboto 300 inside the sunburst */
#sunburst svg text,
#sunburst .slicetext {
    font-family: 'Roboto', sans-serif !important;
    font-weight: 300 !important;
}

/* Details and summary styling */

@keyframes slideDown {
    0% {
      opacity: 0;
    }
    100% {
      opacity: 1;
    }
  }

summary {
    list-style: none;
    cursor: pointer;
    display: block;
    outline: 0;
    font-size: 2.5rem;
    line-height: 2.5rem;
    font-family: Roboto;
    font-weight: 300;
    padding-left: 50px;
    padding-bottom: 0.5rem;
}

.summary_theme {
    font-size: 60pt;
    font-family: Roboto;
    font-weight: 300;
    padding-top: 2rem;
    padding-bottom: 2rem;
}

.summary_category {
font-size: 40pt;
font-family: Roboto;
font-weight: 300;
padding-top: 1rem;
padding-bottom: 1rem;     
}

details {
    font-family: Roboto;
    font-weight: 400;
    line-height: 1.5rem;
    padding-top: 0.5rem;  
    max-width: 750px;
}

details[open] > summary::before {
    font-family: Roboto;
    transform: rotate(45deg);
}

details[open] summary ~ * {
    animation: slideDown .5s ease-in-out;
    padding-left: 2.5rem;
}

details > summary::before {
    position: relative;
    will-change: transform;
    transition: transform 300ms ease;
    font-family: Roboto;
    font-size: 3.1rem;
    content: "+";
    left: -1rem;
    display: inline-block;
    width: 1.6rem;
    text-align: center;
    color: rgb(34, 34, 34);
}
  
summary::-webkit-details-marker {
    display: none;
}

/* Credits block used on list/network/glossary pages (dark text on light bg).
   Mirrors .credits_home structure: padding on the outer div, inner elements inherit. */
.credits_block {
    font-family: Roboto;
    font-weight: 500;
    font-size: 9pt;
    color: #313131;
    line-height: 1.4em;
    padding: 0.5cm 0 0.5cm 1cm;
    position: sticky;
    top: 100vh;
    z-index: 2;
}

.link_credits {
    text-decoration: underline;
    position: relative;
    color: #313131;
}

.link_credits:visited {
    color: #313131;
}

.link_credits:hover {
    color: #8E8E8E;
}

/* Banner properties */
.banner {
    height: 100%; 
    position: fixed;
    z-index: 3;
    left: 0;
    width: 300px;
    top: 0;
    padding: 0px 10px 50px 30px;
    background-color: #FFFFFF;
}

/* Banner link */
.banner_link {
    font-family: 'Roboto';
    font-weight: 500;
    font-size: 10pt;
    color: #8E8E8E;
    letter-spacing: 0.15em;
    line-height: 2.6em;
    text-decoration: None;
    position: relative;
    transition: color 0.2s;
    }

.banner_link_fixed {
    font-family: 'Roboto';
    font-weight: 500;
    font-size: 10pt;
    color: #8E8E8E;
    letter-spacing: 0.15em;
    line-height: 2.6em;
    text-decoration: None;
    position: relative;
    border-bottom: 2px solid #8E8E8E;
}

.banner_link_fixed:hover,
.banner_link_fixed:focus,
.banner_link_fixed:visited {
color: #8E8E8E;
}


/* Underline animation */

.banner_link:hover,
.banner_link:focus,
.banner_link:visited {
color: #8E8E8E;
}

.banner_link::after,
.banner_link::before {
transform: scale3d(1, 1, 1);
}

.banner_link:hover::before,
.banner_link:focus::before {
transform: scale3d(1, 1, 1);
transition-delay: 0s;
}

.banner_link::before,
.banner_link::after {
content: '';
position: absolute;
top: 1.25em;
left: 0;
width: 100%;
height: 2px;
transform: scale3d(0, 1, 1);
transform-origin: center left;
transition: transform 0.2s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.banner_link::before {
background: #8E8E8E;
transition-delay: 0.2s;
}

/* Banner button */
.banner_button {
    font-family: 'Roboto';
    font-weight: 500;
    font-size: 10pt;
    color: #ffffff;
    letter-spacing: 0.15em;
    line-height: 2.6em;
    text-decoration: None;
    position: absolute;
    bottom: 40px;
    left: 40px;
    padding: 10px 20px 10px 20px;
    background-color: #2A313B;
    }

.banner_button:hover {
    color: #ffffff;
    background-color: #545d68;
    }

.banner_button:active {
    color: #ffffff;
    background-color: #18191b;
    }

/* Main page content wrapper */
#page_content {
    position: relative;
    min-height: 100vh;
    z-index: 1;
}

/* Pages layout */
div.page_columns{
    display: flex;
    padding-top: 100px;
    padding-right: 40px; 
    padding-left: 300px;
}

div.page_left {
    width: 70%;
    background-color: rgba(0, 0, 0, 0);
}

div.page_lists {
    position: absolute;
    background: linear-gradient(0deg, #f6f6f6 0%, #dadada 100%);
    padding-top: 40px;
    width: 100%;
    padding-left: 300px;
    top: -2vh;
}

div.page_glossary {
    display: flex;
    flex-direction: column;
    background: linear-gradient(0deg, #f6f6f6 0%, #dadada 100%);
    width: 100%;
    padding-top: 20px;
    padding-right: 40px;
    padding-left: 300px;
    min-height: 100vh;
}

div.page_about {
    display: flex;
    flex-direction: column;
    background: linear-gradient(0deg, #f6f6f6 0%, #dadada 100%);
    width: 100%;
    padding-top: 20px;
    padding-right: 40px;
    padding-left: 350px;
    min-height: 100vh;
}

/* Push credits to the bottom of the glossary page */
.page_glossary #credits-container {
    margin-top: auto;
}

/* Extra top gap between the installations table and credits on list.html */
.page_lists #credits-container {
    padding-top: 0.5cm;
}

/* Radio buttons styling */

div.radio_buttons {
    background-color: rgba(0, 0, 0, 0);
    font-family: Roboto;
    font-weight: 500;
    font-size: 10pt;
    letter-spacing: 10%;
    text-align: center;
    text-transform: uppercase;
    padding-left: 40px;
    padding-top: 3vh;
    margin-bottom: 20px; 
}

.radiobutton-group .label-text {
  position: relative;
  display: inline-block;
}

.radiobutton-group .label-text::before {
  content: '';
  position: absolute;
  bottom: 0.6em;
  left: 0;
  width: 100%;
  height: 2px;
  background: rgba(255, 255, 255, 0.5);
  transform: scale3d(0, 1, 1);
  transform-origin: center left;
  transition: transform 0.2s cubic-bezier(0.22, 0.61, 0.36, 1);
  transition-delay: 0.2s;
}

.radiobutton-group .label-text::after {
  content: '';
  position: absolute;
  bottom: 0.6em;
  left: 0;
  width: 100%;
  height: 2px;
  background: rgba(255, 255, 255, 1);
  transform: scale3d(0, 1, 1);
  transform-origin: center left;
  transition: transform 0.2s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.radiobutton-group > label:hover .label-text::before {
  transform: scale3d(1, 1, 1);
  transition-delay: 0s;
}

.radiobutton-group > label:has(input:checked) {
  color: white;
}

.radiobutton-group > label:has(input:checked) .label-text::after {
  transform: scale3d(1, 1, 1);
}

.radiobutton-group > label {
    cursor: pointer;
    display: inline-block;
    align-items: center;
    margin-right: 15px;
    line-height: 40px;
    color: rgb(255, 255, 255);
    font-size: 10pt;
}

.radiobutton-group input {
    cursor: pointer;
}

input[type="radio"] {
    appearance: none;
    background-color: inherit;
    margin: 0 5px 0 0;
    font: inherit;
    color: currentColor;
    width: 0.8em;
    height: 0.8em;
    border: 0.15em solid white;
    border-radius: 50%;
    display: inline-block;
    transform: translateY(1.2em);
}

input[type="radio"]::before {
    content: "";
    width: 0.65em;
    height: 0.65em;
    border-radius: 50%; 
    transform: scale(0) translate(-0.075em, -1.275em);
    transition: 200ms transform ease-in-out;
    box-shadow: inset 1em 1em white;
    display: inherit;
    transform-origin: 0.275em -0.9em 0em;
  }

input[type="radio"]:checked::before {
    transform: scale(1)  translate(-0.075em, -1.275em);
    display: inherit;   
}

.form-control + .form-control {
    margin-top: 1em;
}

div.page_right {
    width: 40%;
    background-color: rgba(0, 0, 0, 0);
}

/* .choose_text {
    padding-left: 70px;
    position: absolute;
    bottom: 100px;
} */

/* Dropdown styling — Tom Select overrides */

.dropdown_container {
    padding-left : 70px;
    height: 100px;
}

.dropdown_container .ts-wrapper {
    min-width: 0;
}

.dropdown_container .ts-control {
    background-color: rgba(0, 0, 0, 0);
    border-radius: 0;
    border: 0.6mm solid #ccc;
    min-height: 50px;
    padding: 15px 8px;
    box-shadow: none;
    color: white;
    display: flex;
    flex-wrap: wrap;
    align-content: flex-start;
}

.dropdown_container .ts-control input {
    color: white;
    font-family: Roboto;
    font-weight: 500;
    font-size: 10pt;
    flex-basis: 100%;
    min-width: 200px;
}

.dropdown_container .ts-control input::placeholder {
  color: #fff;
  opacity: 1;
}

.dropdown_container .ts-wrapper.multi .ts-control > div.item,
.dropdown_container .ts-control .item {
    background-color: rgba(0, 0, 0, 0) !important;
    background-image: none !important;
    box-shadow: none !important;
    color: rgb(255, 255, 255) !important;
    border: 1px solid white !important;
    border-radius: 2px !important;
    height: auto;
    min-height: 30px;
    line-height: 1.4;
    padding: 6px 8px;
    font-weight: 500;
    font-size: 10pt;
    letter-spacing: 10%;
    text-transform: uppercase;
    margin: 2px 3px 2px 0;
    white-space: normal;
    word-wrap: break-word;
}

.dropdown_container .ts-control .item .remove,
.dropdown_container .ts-wrapper.multi .ts-control > div.item .remove {
    color: rgba(255,255,255,0.7) !important;
    border-left: 1px solid rgba(255,255,255,0.35) !important;
    padding: 0 5px;
    margin-left: 4px;
    background: none !important;
}

.dropdown_container .ts-control .item .remove:hover {
    background-color: rgba(255,255,255,0.15) !important;
    color: white !important;
}

.dropdown_container .ts-dropdown {
    background-color: rgba(42, 49, 59, 0.1);
    border: 1px solid #ffffffaf;
    color: rgb(255, 255, 255);
    font-size: 10pt;
    font-weight: 500;
}

.dropdown_container .ts-dropdown .option {
    color: white;
    padding: 8px 12px;
}

.dropdown_container .ts-dropdown .option.active,
.dropdown_container .ts-dropdown .option:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.dropdown_container .ts-dropdown .option.selected {
    background-color: rgba(255,255,255,0.1);
}

/* Results styling */

.list_inst{
    position: relative;
    z-index: 2;
    top: 0px;
    left: 300px;
    background-color: #F6F6F6;
    width: calc(100% - 300px);
    min-height: 40vh;
    box-sizing: border-box;
    overflow-x: hidden;
}

.n_results {
    font-size: 92pt;
    font-family: Roboto;
    font-weight: 100;
    padding-bottom: 40px;
    padding-left: 40px;
    padding-right: 40px;
}

.n_results_page {
    font-size: 92pt;
    font-family: Roboto;
    font-weight: 100;
    padding-bottom: 40px;
    padding-left: 40px;
    padding-right: 40px;
    padding-top: 40px;
}

/* Table */

table {
    width: 100%;
    table-layout: auto;
    border-spacing: 0px;
    border-collapse: collapse;
    font-size: 9pt;
}

th {
    height: 30px;
    font-weight: 500;
    font-style: normal;
    color:rgb(77, 77, 77);
    padding-top: 15px;
    padding-bottom: 15px;
    padding-left: 40px;
    padding-right: 0;
    text-align: left;
    border: None;
}

th:last-child {
    padding-right: 40px;
}

td, tr {
    text-transform: uppercase;
    font-weight: 500;
}

td {
    height: auto;
    padding-top: 15px;
    padding-bottom: 15px;
    padding-left: 40px;
    padding-right: 0;
    text-align: left;
    border: None;
    min-height: 50px;
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
}

td:last-child {
    padding-right: 40px;
}

tr:nth-child(even) {
    background-color: #F6F6F6;
}

tr:nth-child(odd) {
    background-color: #EBEBEB;
}

tr:hover {
    background-color: #585858;
    color: #FFFFFF;
}

.link_list {
    text-decoration: None;
    position: relative;
    color: inherit;
}

.link_list:visited {
    color:rgb(0, 0, 0);
}

.link_list:hover,
.link_list:focus {
    color: inherit;
}

.link_list::after,
.link_list::before {
transform: scale3d(1, 1, 1);
}

.link_list:hover::before,
.link_list:focus::before {
transform: scale3d(1, 1, 1);
transition-delay: 0s;
}

.link_list::before,
.link_list::after {
content: '';
position: absolute;
bottom: -2pt;
left: 0;
width: 100%;
height: 2px;
transform: scale3d(0, 1, 1);
transform-origin: center left;
transition: transform 0.2s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.link_list::before {
background: rgb(255, 255, 255);
transition-delay: 0.2s;
}

.footer {
    margin: 0 0 0 0px;
    padding: 0px 10px;
    background-color: darkgoldenrod;
}

/* ── Chart view switcher ─────────────────────────────────────────────────── */

.chart-view-switcher {
  position: relative;
  z-index: 2;
  /* Mirrors .page_columns: same padding so the inner col aligns with .page_left */
  display: flex;
  padding-left: 300px;
  padding-right: 40px;
  padding-top: 40px;
}

/* Mirrors .page_left + .radio_buttons: 60% wide, centered content */
.chart-view-switcher-col {
  width: 60%;
  padding-left: 40px;
  display: flex;
  justify-content: center;
  gap: 30px;
}

.chart-view-switcher input[type="radio"] {
  display: none;
}

.chart-view-switcher label {
  cursor: pointer;
  font-family: Roboto;
  font-weight: 500;
  font-size: 10pt;
  letter-spacing: 10%;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  transition: color 0.2s;
  /* Lay out icon + text side by side, bottoms aligned */
  display: inline-flex;
  align-items: flex-end;
  gap: 8px;
}

/* Text-only span: carries the animated underline */
.chart-view-switcher .label-text {
  position: relative;
  padding-bottom: 5px;
  display: inline-block;
}

/* Hover underline — same animation technique as .banner_link */
.chart-view-switcher .label-text::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: rgba(255, 255, 255, 0.5);
  transform: scale3d(0, 1, 1);
  transform-origin: center left;
  transition: transform 0.2s cubic-bezier(0.22, 0.61, 0.36, 1);
  transition-delay: 0.2s;
}

.chart-view-switcher label:hover .label-text::before {
  transform: scale3d(1, 1, 1);
  transition-delay: 0s;
}

/* Always-visible underline for the active tab */
.chart-view-switcher .label-text::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: rgba(255, 255, 255, 1);
  transform: scale3d(0, 1, 1);
  transform-origin: center left;
  transition: transform 0.2s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.chart-view-switcher input[type="radio"]:checked + label {
  color: rgba(255, 255, 255, 1);
}

.chart-view-switcher input[type="radio"]:checked + label .label-text::after {
  transform: scale3d(1, 1, 1);
}

/* When network view is active, page background is light */
#page_content.network-active .chart-view-switcher label {
  color: rgba(0, 0, 0, 0.4);
}

#page_content.network-active .chart-view-switcher .label-text::before {
  background: rgba(0, 0, 0, 0.4);
}

#page_content.network-active .chart-view-switcher .label-text::after {
  background: rgba(0, 0, 0, 0.85);
}

#page_content.network-active .chart-view-switcher input[type="radio"]:checked + label {
  color: rgba(0, 0, 0, 0.85);
}

/* Reduce top padding on home page sections to account for the switcher */
#sunburst-section {
  padding-top: 60px;
}

#network-section {
  padding-top: 20px;
  padding-left: 300px;
  min-height: 93vh;
  display: flex;
  flex-direction: column;
}

#network-section #credits-container {
  margin-top: auto;
}

/* ── Chart view icons ────────────────────────────────────────────────────── */

/* Fixed-size container that overlays selected/unselected icons.
   No margin — gap is handled by the parent label's gap: 8px.
   flex-shrink: 0 prevents the icon from squeezing when label is narrow. */
.view-icon-wrap {
  display: inline-block;
  position: relative;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.view-icon {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transition: opacity 0.2s;
}

/* Default: unselected visible, selected hidden */
.view-icon-selected { opacity: 0; }
.view-icon-unselect { opacity: 1; }

/* When this tab is active */
.chart-view-switcher input[type="radio"]:checked + label .view-icon-selected { opacity: 1; }
.chart-view-switcher input[type="radio"]:checked + label .view-icon-unselect { opacity: 0; }

/* Invert white SVGs to dark when on the light network background */
#page_content.network-active .chart-view-switcher .view-icon {
  filter: invert(1);
}

/* ── Network page ─────────────────────────────────────────────────────────── */

.page_network_bg {
    background: linear-gradient(0deg, #f6f6f6 0%, #dadada 100%);
    min-height: 100vh;
    position: relative;
    padding-top: 20px;
    padding-bottom: 0.5cm;
    padding-right: 80px;
    padding-left: 60px;
}

.cy-container {
    position: relative;
}

#cy {
    width: 100%;
    height: 70vh;
    background-color: transparent;
    border-radius: 2px;
}

.cy-zoom-controls {
    position: absolute;
    bottom: 16px;
    right: 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cy-zoom-btn {
    width: 32px;
    height: 32px;
    background: #ffffff;
    border: 1px solid #cccccc;
    border-radius: 3px;
    font-family: Roboto, sans-serif;
    font-size: 18px;
    font-weight: 300;
    color: #444444;
    cursor: pointer;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.12);
    transition: background 0.15s, color 0.15s;
}

.cy-zoom-btn:hover {
    background: #f0f0f0;
    color: #111111;
}

.network-message {
    color: #272727;
    font-family: Roboto;
    font-weight: 400;
    font-size: 12pt;
    padding: 0 0 20px 35px;
    min-height: 30px;
}

.network-bottom {
    width: 60%;
    margin-top: 20px;
    padding-left: 1cm;
}

#node-detail {
    background: #ffffff;
    border: 1px solid #cccccc;
    border-radius: 3px;
    padding: 12px 16px 14px;
    margin: 24px 0 0 0;
    width: 100%;
    display: none;
}

.detail-header {
    color: #888888;
    font-size: 9pt;
    font-family: Roboto;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 10px;
    display: block;
}

.detail-name {
    font-family: Roboto;
    font-weight: 500;
    font-size: 10pt;
    color: #222222;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 8px;
}

.detail-field {
    font-family: Roboto;
    font-size: 9pt;
    color: #555555;
    margin-bottom: 4px;
    line-height: 1.5em;
}

#network-legend {
    padding: 14px 0 10px 0;
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.legend-item {
    display: flex;
    align-items: center;
    color: #444444;
    font-family: Roboto;
    font-size: 9pt;
    font-weight: 400;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Dot used only in the legend title (next to theme name) */
.legend-dot-title {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 4px;
    flex-shrink: 0;
    vertical-align: middle;
}

/* Horizontal bar for legend items — distinguishable from the title dot */
.legend-bar {
    display: inline-block;
    width: 22px;
    height: 6px;
    border-radius: 3px;
    margin-right: 7px;
    flex-shrink: 0;
}

/* ── Network page main section ─────────────────────────────────────────────── */

.network-main-section {
    position: relative;
    padding-left: 300px;
    padding-right: 40px;
    padding-top: 100px;
}

/* Two-column layout mirroring the sunburst page: graph left, controls right.
   Left padding (300px) is provided by #network-section. */
.network-columns {
    display: flex;
    padding-top: 40px;
}

/* Indent the right-column content like the sunburst page_right (70px) while
   keeping the column at 40% total width. */
.network-columns .page_right {
    box-sizing: border-box;
    padding-left: 40px;
}

.network-legend-title {
    font-size: 12pt;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding-left: 0;
    padding-right: 0;
    padding-top: 20px;
    padding-bottom: 0px;
    margin: 0;
    font-family: 'Roboto';
    font-weight: 500;
}

.network-instructions {
    color: #333333;
}

.network-instructions h6 {
  display: none;
}

/* ── Mobile nav stubs (elements injected by initMobileNav in app.js) ─────────
  On desktop the wrapper disappears from the box model so existing banner
  layout is unchanged; the toggle button is simply hidden.                    */

.banner-nav {
  display: block; /* links stay in flow; replaced by a flex drawer on mobile */
}

.nav-toggle {
  display: none;
}

/* ── Network controls section ──────────────────────────────────────────────── */

#network-controls {
    padding: 0px;
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.network-control-group {
    min-width: 0;
}

.network-control-label {
    color: #888888;
    font-size: 9pt;
    font-family: Roboto;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 8px;
    display: block;
}

#network-controls .dropdown_container {
    margin: 0;
    height: auto;
    padding: 0;
}

#network-controls .ts-wrapper {
    border-color: #cccccc;
}

#network-controls .ts-control {
    background-color: #ffffff;
    color: #333333;
    border-color: #cccccc;
}

#network-controls .ts-control input {
    color: #333333;
}

#network-controls .dropdown_container .ts-wrapper.multi .ts-control > div.item,
#network-controls .dropdown_container .ts-control .item {
    background-color: #cccccc !important;
    background-image: none !important;
    box-shadow: none !important;
    color: #333333 !important;
    border-color: #aaaaaa !important;
}

#network-controls .dropdown_container .ts-control .item .remove,
#network-controls .dropdown_container .ts-wrapper.multi .ts-control > div.item .remove {
    color: #555555 !important;
    border-left: 1px solid #aaaaaa !important;
    background: none !important;
}

#network-controls .dropdown_container .ts-control .item .remove:hover {
    background-color: rgba(0,0,0,0.1) !important;
    color: #222222 !important;
}

#network-controls .ts-dropdown {
    background-color: #ffffff;
    border-color: #cccccc;
    color: #333333;
}

#network-controls .ts-dropdown .option {
    color: #333333;
}

#network-controls .ts-dropdown .option.active,
#network-controls .ts-dropdown .option:hover {
    background-color: #e8e8e8;
}

#network-controls .dropdown_container .ts-control input::placeholder {
  color: #252525;
  opacity: 1;
}

/* ═══════════════════════════════════════════════════════════════════════════
   MOBILE  ≤ 850 px
   ═══════════════════════════════════════════════════════════════════════════ */

@media (max-width: 850px) {

  /* Slide-down animation for the nav drawer */
  @keyframes navSlideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  /* ── Prevent horizontal overflow ─────────────────────────────────────────── */

  body {
    overflow-x: hidden;
  }

  h6 {
    font-family: 'Roboto';
    font-weight: 400;
    color: #ffffff;
    margin-block-start: 0em;
    margin-block-end: 1em;
  }


  /* ── Banner → fixed top bar ──────────────────────────────────────────────── */

  .banner {
    width: 100%;
    height: 60px;
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 0 16px;
    border-bottom: 1px solid #eeeeee;
  }

  /* Slightly larger title for readability */
  .banner h1,
  .banner_header {
    font-size: 12pt;
    font-weight: 500;
    flex: 1;
    margin: 0;
    padding: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #222222;
    line-height: 1.3;
  }

  /* Nav wrapper becomes a slide-down drawer */
  .banner-nav {
    display: none;
    position: fixed;
    top: 60px;
    left: 0;
    width: 100%;
    background: #ffffff;
    flex-direction: column;
    padding: 20px 24px 28px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    z-index: 10;
    gap: 4px;
  }

  .banner.nav-open .banner-nav {
    display: flex;
    animation: navSlideDown 0.2s ease-out forwards;
  }

  /* Spacers are replaced by flexbox gap in the drawer */
  .banner-nav .spacer-sm {
    display: none;
  }

  /* Bigger tap targets for nav links inside the drawer */
  .banner-nav .banner_link,
  .banner-nav .banner_link_fixed {
    line-height: 2.4em;
    font-size: 11pt;
  }

  .banner_link::before,
  .banner_link::after {
    display: none;
  }

  /* Hamburger button */
  .nav-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    margin-left: 12px;
    flex-shrink: 0;
  }

  .nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: #8e8e8e;
    border-radius: 1px;
    transition: opacity 0.2s, transform 0.2s;
  }

  /* Animate to ✕ when the drawer is open */
  .banner.nav-open .nav-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .banner.nav-open .nav-toggle span:nth-child(2) {
    opacity: 0;
  }

  .banner.nav-open .nav-toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  /* ── Page-content top offset ─────────────────── */

  #page_content {
    padding-top: 60px;
  }

  /* Must use div. prefix to beat base rule specificity (div.page_glossary) */
  div.page_glossary {
    padding-top: 80px;
    padding-left: 16px;
    padding-right: 16px;
    width: 100%;
    min-height: 100vh;
  }

  div.page_about {
    padding-top: 80px;
    padding-left: 16px;
    padding-right: 16px;
    width: 100%;
    min-height: 100vh;
  }

  /* Must use div. prefix to beat base rule specificity (div.page_lists) */
  div.page_lists {
    position: relative;
    top: 0;
    left: 0;
    padding-top: 60px;
    padding-left: 0;
    width: 100%;
    overflow-x: auto;
  }

  /* ── Remove 300 px left offsets ──────────────────────────────────────────── */

  div.page_columns {
    padding-left: 0;
    padding-right: 0;
    padding-top: 0;
  }

  #sunburst-section {
    padding-top: 0;
  }

  .chart-view-switcher {
    padding-left: 16px;
    padding-top: 20px;
  }

  .chart-view-switcher-col {
    width: 100%;
    padding-left: 0;
    padding-bottom: 0.5cm;
  }

  #network-section {
    padding-left: 0;
    padding-top: 0;
  }

  .network-main-section {
    padding-left: 0;
    padding-top: 0;
    padding-right: 0;
  }

  .list_inst {
    left: 0;
    width: 100%;
    overflow-x: auto;
  }

  /* Fixed credits are intrusive on mobile */
  .credits_home {
    display: none;
  }

  /* Remove the 1cm left indent so credits align with page content */
  .credits_block {
    display: none;
  }

  /* ── Two columns → single column ─────────────────────────────────────────── */

  div.page_columns,
  .network-columns {
    flex-direction: column;
  }

  div.page_left,
  div.page_right {
    width: 100%;
  }

  /* ── Sunburst right column ───────────────────────────────────────────────── */

  /* Override the inline padding-left:70px on the instruction h6 */
  .page_right .instruction_text h6 {
    padding-left: 16px !important;
    font-size: 1pt !important;
    line-height: 0pt !important;
    color:rgb(0, 0, 0, 0);
  }

  .dropdown_container {
    padding-left: 16px;
    padding-right: 16px;
    height: auto;
    margin-bottom: 16px;
  }

  div.radio_buttons {
    padding-left: 0;
    padding-top: 0;
    margin-top: 0;
    margin-bottom: 20px;
    text-align: center;
  }

  .dropdown_container .ts-dropdown {
    background-color: rgba(70, 70, 70, 1);
    border: 1px solid #ffffffaf;
    color: rgb(255, 255, 255);
    font-size: 10pt;
    font-weight: 500;
  }

  /* ── Network section ─────────────────────────────────────────────────────── */

  .network-columns .page_right {
    padding-left: 16px;
    padding-right: 16px;
    padding-top: 24px;
  }

  .network-message {
    padding-top: 8px;
    padding-left: 16px;
    padding-right: 16px;
  }

  /* Override the desktop 60% width; legend is full-width when stacked */
  .network-bottom {
    width: 100%;
    padding-left: 16px;
    padding-right: 16px;
  }

  #cy {
    height: 55vh;
  }

  /* ── Glossary ────────────────────────────────────────────────────────────── */

  .summary_theme {
    font-size: 36pt;
    line-height: 2.8rem;
  }

  .summary_category {
    font-size: 24pt;
    padding-top: 0;
    padding-bottom: 0;
  }

  summary {
    font-size: 1.8rem;
    line-height: 2.0rem;
    padding-left: 26px;
    padding-bottom: 0rem;
  }

  details[open] summary ~ * {
    padding-left: 1.5rem;
  }

  details {
    max-width: 100%;
  }

  /* ── Results count ───────────────────────────────────────────────────────── */

  table {
    font-size: 0.6rem;
  }

  .n_results,
  .n_results_page {
    font-size: 52pt;
    padding-left: 16px;
    padding-right: 16px;
    letter-spacing: -5%;
  }

  /* Restore legend title to normal size — overrides the .n_results 52pt above */
  .network-legend-title {
    font-size: 1rem;
    padding-left: 0;
    padding-right: 0;
  }

  /* ── Table ───────────────────────────────────────────────────────────────── */

  th,
  td {
    padding-left: 16px;
  }

  th:last-child,
  td:last-child {
    padding-right: 16px;
  }

  /* ── Network controls dropdowns (full width on mobile) ───────────────────── */

  #network-controls .dropdown_container {
    padding: 0;
  }

  /* ── Network mobile reorder: page_right and node-detail become direct
     children of #network-section after JS reorder in applyMobileNetworkOrder ── */

  #network-section > .page_right {
    width: 100%;
    box-sizing: border-box;
    padding: 24px 16px 44px;
  }

  #network-section > #node-detail {
    margin: 16px 16px 0;
    width: auto;
  }

}