th {
    
    color: white;
}


.video:hover,
.info-cell:hover {
    background-color: rgb(170, 170, 170);
}

.container {
    margin-left: 5% !important;
    margin-right: 5% !important;
    padding-top: 10px;
    display: flex;
    padding-bottom: 50px;
    color: white !important;
    
}

.table {
    width: auto !important;
}

.navbar {
    background-color: #243447!important;
    border-bottom: 1px solid white;
}

td, th {
    border: 1px solid rgb(78, 78, 78);
    text-align: center !important;
    color: white !important;
    border-color: #dee2e6 !important;
}

.rowgreen {
    background-color: rgb(63, 88, 63);
}

.rowred {
    background-color: rgb(104, 73, 73);
}

.rowgray {
    background-color: rgb(70, 70, 70);
}

.rowyellow {
    background-color: rgba(243, 255, 74, 0.329);
}

body {
    background-color: #121a22 !important;
    padding-bottom: 48px;
}

.index-sitelinks-button {
    border: 2px solid black;
    background-color: #141d26;
    color: black;
    padding: 14px 28px;
    font-size: 16px;
    cursor: pointer;
    margin-top: 10px;
}

.index-sitelinks-button-sly1 {
    border-color: dodgerblue;
    color: white;
    margin-right: 5%;
    margin-left: 5%;
}

.index-sitelinks-button-sly1:hover {
    background-size: cover;
    background-repeat: no-repeat center;
    background-color: dodgerblue;
    color: white;
}

.index-sitelinks-button-sly2 {
    border-color: #4CAF50;
    color: white;
    margin-right: 5%;
    margin-left: 5%;
}

.index-sitelinks-button-sly2:hover {
    background-size: cover;
    background-repeat: no-repeat center;
    background-color: #4CAF50;
    color: white;
}

.index-sitelinks-button-sly3 {
    border-color: deeppink;
    color: white;
    margin-right: 5%;
    margin-left: 5%;
}

.index-sitelinks-button-sly3:hover {
    background-size: cover;
    background-repeat: no-repeat center;
    background-color: deeppink;
    color: white;
}

.index-sitelinks-button-sly4 {
    border-color: orange;
    color: white;
    margin-right: 5%;
    margin-left: 5%;
}

.index-sitelinks-button-sly4:hover {
    background-size: cover;
    background-repeat: no-repeat center;
    background-color: orange;
    color: white;
}

.index-header-middletext {
    font-size: 18px;
    color: white;
}

/* Board navigation tabs */
.board-nav {
    display: flex;
    flex-direction: column;
    background-color: #1a2530;
    border-bottom: 1px solid rgba(222, 226, 230, 0.3);
    position: relative;
}

.board-nav-row {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 6px;
    padding: 10px 5%;
}

.board-nav-row + .board-nav-row {
    border-top: 1px solid rgba(222, 226, 230, 0.15);
}

.board-nav-tab {
    padding: 5px 14px;
    background-color: #243447;
    color: white;
    border: 1px solid rgba(222, 226, 230, 0.4);
    cursor: pointer;
    border-radius: 4px;
    font-size: 14px;
}

/* Level 1 toggles (version/category) — pill style */
.board-nav-tab[data-version],
.board-nav-tab[data-cat] {
    border-radius: 20px;
    padding: 3px 13px;
    font-size: 13px;
}

.board-nav-tab:hover {
    background-color: #2d4260;
}

.board-nav-tab.active {
    background-color: #085097;
    border-color: #085097;
}

.board-nav-tab:disabled {
    background-color: #243447;
    border-color: rgba(222, 226, 230, 0.15);
    color: rgba(255, 255, 255, 0.5);
    cursor: default;
}

.board-nav-select {
    padding: 5px 10px;
    background-color: #243447;
    color: white;
    border: 1px solid rgba(222, 226, 230, 0.4);
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
}

.board-nav-select:hover {
    background-color: #2d4260;
}

.board-nav-select.active {
    background-color: #085097;
    border-color: #085097;
}

.board-nav-select option {
    background-color: #243447;
    color: white;
}

.board-nav-divider {
    width: 1px;
    height: 22px;
    background-color: rgba(222, 226, 230, 0.3);
    margin: 0 4px;
}

.board-nav-label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    padding: 0 2px 0 10px;
}

/* Board Info button — overlaid on the first board-nav-row via board-nav positioning.
   height matches one row so it never covers wrapped lines in the second row. */
.board-info-slot {
    position: absolute;
    right: 5%;
    top: 0;
    height: 44px;
    display: flex;
    align-items: center;
}

.board-info-btn {
    padding: 5px 14px;
    background-color: #111821;
    color: white;
    border: 1px solid rgba(222, 226, 230, 0.4);
    cursor: pointer;
    border-radius: 4px;
    font-size: 14px;
}

.board-info-btn:hover {
    background-color: #2d4260;
}

.board-info-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 3000;
    display: none;
    align-items: center;
    justify-content: center;
}

.board-info-modal {
    background-color: #243447;
    border: 1px solid rgba(222, 226, 230, 0.3);
    border-radius: 8px;
    padding: 24px 28px;
    max-width: 480px;
    width: 90%;
    color: white;
}

.board-info-modal h5 {
    margin: 0 0 16px;
    font-size: 18px;
    font-weight: bold;
}

.board-info-body {
    font-size: 14px;
    line-height: 1.6;
}

.board-info-body p {
    margin: 10px 0 4px;
}

.board-info-body a {
    color: #5b9bd5;
    text-decoration: none;
}

.board-info-body a:hover {
    text-decoration: underline;
}

.color-legend {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin: 6px 0;
}

.color-legend-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.color-swatch {
    width: 20px;
    height: 20px;
    border-radius: 3px;
    flex-shrink: 0;
}

.board-info-ok {
    display: block;
    margin: 20px auto 0;
    padding: 6px 28px;
    background-color: #085097;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.board-info-ok:hover {
    background-color: #0a63be;
}

/* Loading spinner modal */
.loading-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 4000;
    display: none;
    align-items: center;
    justify-content: center;
}

.loading-box {
    background-color: #243447;
    border: 1px solid rgba(222, 226, 230, 0.3);
    border-radius: 8px;
    padding: 32px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-spinner {
    width: 48px;
    height: 48px;
    border: 5px solid rgba(255, 255, 255, 0.15);
    border-top-color: #085097;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.loading-text {
    color: white;
    font-size: 15px;
    margin: 0;
}

/* Video embed modal */
.video-modal-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 3000;
    display: none;
    align-items: center;
    justify-content: center;
}

.video-modal {
    background-color: #1a2530;
    border-radius: 8px;
    padding: 12px;
    width: 90%;
    max-width: 800px;
}

.video-modal-title {
    color: white;
    font-size: 15px;
    font-weight: bold;
    text-align: center;
    margin: 0 0 10px;
}

.video-modal-frame {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
}

.video-modal-frame iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 4px;
}

.video-modal-ok {
    display: block;
    margin: 10px auto 0;
    padding: 6px 28px;
    background-color: #085097;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.video-modal-ok:hover {
    background-color: #0a63be;
}

/* Table app container */
#app {
    padding: 20px 5% 30px;
}

#app > table {
    width: fit-content;
    margin: 0 auto;
}

/* Info cell */
.info-cell {
    white-space: nowrap;
}

.has-info {
    cursor: pointer;
}

.info-active {
    background-color: rgba(200, 200, 200, 0.25) !important;
}

/* Tooltip that appears next to the Info cell on click */
.info-tooltip {
    position: fixed;
    background: white;
    color: #333;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 13px;
    max-width: 280px;
    white-space: normal;
    line-height: 1.4;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    z-index: 2000;
    pointer-events: none;
}

.info-tooltip::before {
    content: '';
    position: absolute;
    left: -6px;
    top: 50%;
    transform: translateY(-50%);
    border-width: 6px 6px 6px 0;
    border-style: solid;
    border-color: transparent white transparent transparent;
}

.info-tooltip.info-tooltip-left::before {
    left: auto;
    right: -6px;
    border-width: 6px 0 6px 6px;
    border-color: transparent transparent transparent white;
}

/* Video cell — entire cell is clickable */
.video {
    position: relative;
    cursor: pointer;
}

.video a,
.video a:hover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: white;
}

/* Mobile layout */
@media (max-width: 767px) {
    /* Reduce side padding so the table gets more room */
    #app {
        padding-left: 8px;
        padding-right: 8px;
    }

    /* Table fills full width; smaller cell font/padding lets 4 columns fit */
    #app > table {
        width: 100%;
    }

    #app table td,
    #app table th {
        font-size: 12px;
        padding: 6px 4px;
    }

    /* Hide Video and Info columns — only 4 columns fit comfortably */
    #app table td:nth-child(5),
    #app table th:nth-child(5),
    #app table td:nth-child(6),
    #app table th:nth-child(6) {
        display: none;
    }

    /* Board Info becomes a small floating circle above the footer */
    .board-info-slot {
        position: fixed;
        bottom: 52px;
        right: 12px;
        top: auto;
        height: auto;
        z-index: 500;
    }
    .board-info-text {
        display: none;
    }
    .board-info-btn {
        border-radius: 50%;
        width: 36px;
        height: 36px;
        padding: 0;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .board-info-btn::before {
        content: 'i';
        font-style: italic;
        font-weight: bold;
        font-size: 16px;
    }
}

/* Hover-based navbar dropdowns on desktop */
@media (min-width: 992px) {
    .navbar .nav-item.dropdown:hover > .dropdown-menu {
        display: block;
    }
}

.nav-item .nav-link {
    color: white !important;
}

.navbar .dropdown-menu {
    background-color: #243447 !important;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 0 0 4px 4px;
    min-width: 160px;
    margin-top: 0;
}

.navbar .dropdown-item {
    color: white;
    padding: 6px 16px;
}

.navbar .dropdown-item:hover {
    background-color: #2d4260;
    color: white;
}

/* Fixed footer */
.footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #243447 !important;
    border-top: 1px solid white;
    z-index: 1000;
    padding: 8px 0;
}

.footer-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.footer-nav a {
    color: white;
    padding: 2px 16px;
    text-decoration: none;
    font-size: 15px;
}

.footer-nav a:hover {
    color: #868ea8;
}