/* rollup tab: Shield Command styles for this tab only (shared pieces live in practice.css). */

/* Card header: title + description on the left (flex items-start justify-between mb-4) */
.ru-card-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 1rem; }
.ru-card-head.center { align-items: center; }
.ru-card-title { display: flex; align-items: center; gap: .5rem; }
.ru-card-title [class*="icon-"] { font-size: 1rem; }
.ru-card-desc { margin-top: .125rem; }
.ru-icon-new { color: #059669; }   /* emerald-600 */
.ru-icon-not { color: #e11d48; }   /* rose-600 */

/* Implementation: two cards side by side from lg up (grid-cols-1 lg:grid-cols-2 gap-4) */
.ru-impl-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1rem; }
@media (min-width: 1024px) {
  .ru-impl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Practice list: dot + name, "Live <date>" under it, date on the right (divide-y, py-2.5) */
.ru-list { margin: 0; padding: 0; list-style: none; }
.ru-list li { display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem; padding: .625rem 0; }
.ru-list li + li { border-top: 1px solid var(--line); }
.ru-list-main { min-width: 0; }
.ru-list-name { display: flex; align-items: center; gap: .5rem; }
.ru-list-name.wrap { flex-wrap: wrap; }
.ru-dot { flex-shrink: 0; width: .5rem; height: .5rem; border-radius: 9999px; }
.ru-dot.new { background: #10b981; }   /* emerald-500 */
.ru-dot.not { background: #f43f5e; }   /* rose-500 */
.ru-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .875rem; line-height: 1.25rem; font-weight: 500; }
.ru-live { margin: .125rem 0 0; padding-left: 1rem; font-size: .75rem; line-height: 1rem; color: #0284c7; }   /* sky-600 */
.ru-list-date { flex-shrink: 0; white-space: nowrap; font-size: .875rem; line-height: 1.25rem; color: var(--muted); }
.ru-empty { margin: 0; font-size: .875rem; line-height: 1.25rem; font-style: italic; color: var(--muted); }

/* Comparison: shadcn Table (text-sm, h-12 px-4 headings, p-4 cells, row borders) */
.ru-table-wrap { position: relative; width: 100%; overflow: auto; }
.ru-table { width: 100%; caption-side: bottom; border-collapse: collapse; font-size: .875rem; line-height: 1.25rem; }
.ru-table tr { border-bottom: 1px solid var(--line); transition: background-color .15s cubic-bezier(.4, 0, .2, 1); }
.ru-table tbody tr:last-child { border-bottom: 0; }
.ru-table thead tr:hover { background: rgb(241 245 249 / .5); }   /* hover:bg-muted/50 */
.ru-table tbody tr { position: relative; cursor: pointer; }
.ru-table tbody tr:hover { background: rgb(241 245 249 / .4); }   /* hover:bg-muted/40 */
.ru-table th { height: 3rem; padding: 0 1rem; text-align: left; vertical-align: middle; font-weight: 500; color: var(--muted); white-space: nowrap; }
.ru-table td { padding: 1rem; vertical-align: middle; }
.ru-table .right { text-align: right; }

/* Sortable heading: bold label with ▲/▼, then the info bubble (inline-flex gap-1). The label ignores
   the pointer so clicks land on the heading itself; the sort action only fires for those (:self). */
.ru-table th[data-action] { cursor: pointer; }
.ru-table th[data-action]:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--primary); }
.ru-sort { pointer-events: none; margin-right: .25rem; font-weight: 600; }
.ru-table th[data-action]:hover:not(:has(.info-tip:hover)) .ru-sort { text-decoration: underline; }
.ru-table th[data-sorted="desc"] .ru-sort::after { content: "▼"; margin-left: .25rem; }
.ru-table th[data-sorted="asc"] .ru-sort::after { content: "▲"; margin-left: .25rem; }
.ru-table th .info-tip { vertical-align: middle; }
/* Keep the first and last bubbles' tooltips inside the card (Shield Command's tooltip avoids the edges). */
.ru-table th:first-child .info-tip[data-tip]::after { left: 0; transform: none; }
.ru-table th:nth-last-child(2) .info-tip[data-tip]::after { left: auto; right: 0; transform: none; }
/* The scroll box would clip tooltips above the heading row: scroll only when the table can't fit,
   and there open the heading tooltips downward. */
@media (min-width: 1280px) {
  .ru-table-wrap { overflow: visible; }
}
@media (max-width: 1279.98px) {
  .ru-table th .info-tip[data-tip]::after { top: calc(100% + 6px); bottom: auto; }
}

.ru-practice { font-weight: 500; }
.ru-up { color: #047857; }     /* emerald-700 */
.ru-down { color: #be123c; }   /* rose-700 */
.ru-delta { display: block; font-size: 10px; }
.ru-delta.muted { color: var(--muted); }
.ru-delta.good { color: #047857; }
.ru-delta.bad { color: #be123c; }
.ru-table tbody tr:has(.ru-table-empty) { cursor: default; }
.ru-table td.ru-table-empty { padding-top: 1.5rem; padding-bottom: 1.5rem; text-align: center; font-style: italic; color: var(--muted); }

/* Chevron link stretched over its row, so clicking anywhere on the row opens the practice */
.ru-row-link { display: inline-flex; color: var(--muted); text-decoration: none; }
.ru-row-link [class*="icon-"] { font-size: 1rem; }
.ru-row-link::after { content: ""; position: absolute; inset: 0; }
.ru-row-link:focus-visible { outline: none; }
.ru-row-link:focus-visible::after { box-shadow: inset 0 0 0 2px var(--primary); }
