/*
 * Fix: Unfold 0.62.0 compiled CSS is missing dark:hover:bg-base-900.
 * Active sidebar nav items fall back to hover:bg-white in dark mode,
 * making the near-white text (base-100) invisible.
 * base-900 = rgb(17, 24, 39)   base-100 = rgb(243, 244, 246)
 */
.dark nav a:hover,
.dark aside a:hover {
    background-color: rgb(17, 24, 39) !important;
    color: rgb(243, 244, 246) !important;
}
.dark nav a:hover span,
.dark aside a:hover span {
    color: rgb(243, 244, 246) !important;
}

/*
 * Fix: change-list row hover in dark mode (admin list pages).
 * base-800 = rgb(31, 41, 55)
 */
.dark #result_list tr:hover td,
.dark #result_list tr:hover th {
    background-color: rgb(31, 41, 55) !important;
    color: rgb(243, 244, 246) !important;
}

/* ── Table headers ─────────────────────────────────────────────────── */
#result_list thead th {
    background-color: #f8fafc;
    border-bottom: 2px solid #e2e8f0 !important;
    padding-top: 10px !important;
    padding-bottom: 10px !important;
    font-size: 0.68rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.07em !important;
    text-transform: uppercase !important;
    color: #475569 !important;
    white-space: nowrap;
}
#result_list thead th a,
#result_list thead th a:link,
#result_list thead th a:visited {
    color: #475569 !important;
    font-weight: 700 !important;
}

.dark #result_list thead th {
    background-color: rgba(255, 255, 255, 0.03) !important;
    border-bottom: 2px solid rgba(255, 255, 255, 0.08) !important;
    color: #94a3b8 !important;
}
.dark #result_list thead th a,
.dark #result_list thead th a:link,
.dark #result_list thead th a:visited {
    color: #94a3b8 !important;
}

/* Sorted column header gets the orange accent */
#result_list thead th.sorted {
    border-bottom-color: #ea580c !important;
    color: #ea580c !important;
}
#result_list thead th.sorted a {
    color: #ea580c !important;
}
.dark #result_list thead th.sorted {
    border-bottom-color: #f97316 !important;
    color: #f97316 !important;
}
.dark #result_list thead th.sorted a {
    color: #f97316 !important;
}
