/* /Components/FigureContainer.razor.rz.scp.css */
.figure-container[b-9hyxjfr8n5] {
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid var(--border-color, #ccc);
    border-radius: 8px;
    padding: 8px;
    background: var(--bg-secondary, #f9f9f9);
    width: 100%;
    height: 100%;
    min-height: 120px;
    position: relative;
    transition: border-color 0.3s ease, box-shadow 0.2s ease, background 0.3s ease;
    box-sizing: border-box;
    contain: layout style;
}

.figure-container:hover[b-9hyxjfr8n5] {
    border-color: var(--accent-color, #007bff);
    box-shadow: 0 3px 8px var(--shadow-hover, rgba(0, 123, 255, 0.25));
    transform: translateY(-1px);
}

/* Wiki panels and other fixed-size preview boxes */
.figure-container.is-compact[b-9hyxjfr8n5] {
    min-height: 0;
    padding: 0.5rem;
    contain: none;
}

.figure-container.is-compact:hover[b-9hyxjfr8n5] {
    transform: none;
}

.figure-container.is-compact .figure-lines[b-9hyxjfr8n5] {
    gap: 3px;
}

.figure-container.is-compact .figure-line[b-9hyxjfr8n5] {
    font-size: 0.82rem;
    min-height: 0;
    height: auto;
    line-height: 1.15;
}

.figure-container.is-compact .figure-line-glyphs[b-9hyxjfr8n5] {
    gap: 0.32em;
    min-width: 1.1em;
}

.figure-container.is-compact .figure-line-glyphs--pair[b-9hyxjfr8n5] {
    gap: 0.42em;
    min-width: 1.85em;
}

.figure-label[b-9hyxjfr8n5] {
    font-weight: bold;
    font-size: 12px;
    margin-bottom: 4px;
    color: var(--text-primary, #333);
    text-align: center;
    transition: color 0.3s ease;
}

.figure-lines[b-9hyxjfr8n5] {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex: 1;
    justify-content: center;
}

.figure-line[b-9hyxjfr8n5] {
    font-size: 20px;
    line-height: 1.2;
    text-align: center;
    color: var(--text-primary, #000);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    user-select: none;
    min-height: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease, color 0.3s ease;
}

.figure-line-glyphs[b-9hyxjfr8n5] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4em;
    min-width: 1.35em;
    flex: 0 0 auto;
}

.figure-line-glyphs--pair[b-9hyxjfr8n5] {
    gap: 0.55em;
    min-width: 2.35em;
}

.figure-line-glyphs--placeholder[b-9hyxjfr8n5] {
    gap: 0.55em;
    min-width: 2.35em;
    opacity: 0.45;
}

.figure-glyph[b-9hyxjfr8n5] {
    flex: 0 0 auto;
    line-height: 1;
    white-space: nowrap;
}

.figure-line.interactive[b-9hyxjfr8n5] {
    cursor: pointer;
    transition: transform 0.2s ease, color 0.2s ease;
    will-change: transform;
}

.figure-line.interactive:hover[b-9hyxjfr8n5] {
    transform: scale(1.1);
    color: var(--accent-color, #007bff);
}

.figure-line.interactive:active[b-9hyxjfr8n5] {
    transform: scale(0.95);
}

.figure-name[b-9hyxjfr8n5] {
    font-size: 10px;
    color: var(--text-secondary, #666);
    margin-top: 4px;
    text-align: center;
    font-style: italic;
    transition: color 0.3s ease;
}

/* Override for traditional house chart - bring labels closer */
/* This targets figure containers within the traditional house chart */
.traditional-house-chart-container .figure-label[b-9hyxjfr8n5],
.house-card-container .figure-label[b-9hyxjfr8n5] {
    margin-bottom: 0 !important;
    margin-top: 0 !important;
    line-height: 1 !important;
    padding: 0 !important;
}

.traditional-house-chart-container .figure-name[b-9hyxjfr8n5],
.house-card-container .figure-name[b-9hyxjfr8n5] {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    line-height: 1 !important;
    padding: 0 !important;
}

.traditional-house-chart-container .figure-lines[b-9hyxjfr8n5],
.house-card-container .figure-lines[b-9hyxjfr8n5] {
    flex: 0 0 auto !important; /* Remove flex: 1 to prevent expansion */
    gap: 1px !important;
    margin: 0 !important;
    padding: 0 !important;
    justify-content: flex-start !important; /* Remove center justification */
}

/* House Strength Indicators */
.house-strength-badge[b-9hyxjfr8n5] {
    display: inline-block;
    margin-left: 4px;
    font-size: 10px;
    font-weight: bold;
    padding: 2px 4px;
    border-radius: 3px;
    vertical-align: middle;
    line-height: 1;
}

.badge-strong[b-9hyxjfr8n5] {
    background-color: #28a745;
    color: white;
    border: 1px solid #1e7e34;
}

.badge-weak[b-9hyxjfr8n5] {
    background-color: #dc3545;
    color: white;
    border: 1px solid #c82333;
}

/* Container styling for strong/weak houses */
.figure-container.house-strong[b-9hyxjfr8n5] {
    border-color: #28a745;
    background: linear-gradient(to bottom, #f9f9f9 0%, #f0f9f2 100%);
}

.figure-container.house-strong:hover[b-9hyxjfr8n5] {
    border-color: #1e7e34;
    box-shadow: 0 2px 4px rgba(40, 167, 69, 0.3);
}

.figure-container.house-weak[b-9hyxjfr8n5] {
    border-color: #dc3545;
    background: linear-gradient(to bottom, #f9f9f9 0%, #fdf0f0 100%);
}

.figure-container.house-weak:hover[b-9hyxjfr8n5] {
    border-color: #c82333;
    box-shadow: 0 2px 4px rgba(220, 53, 69, 0.3);
}

/* /Components/Workspace/CourtAndHousesTab.razor.rz.scp.css */
/*
 * Two stacked tables (Court 4 rows + Houses 12 rows) that together fit the
 * available vertical space without scrolling. Row padding scales down using
 * clamp() so everything stays aligned with the chart on the left.
 */
.court-houses-tables[b-xqau6hjg8v] {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    min-width: 0;
    min-height: 0;
    height: 100%;
    box-sizing: border-box;
}

.court-houses-section-title[b-xqau6hjg8v] {
    font-size: clamp(0.85rem, 1.4vh, 1.05rem);
    font-weight: 600;
    margin: 0;
    color: var(--text-primary);
    text-align: center;
    line-height: 1.2;
    flex-shrink: 0;
}

.court-houses-table[b-xqau6hjg8v] {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
    font-size: clamp(0.7rem, 1.1vh, 0.85rem);
    table-layout: fixed;
}

/*
 * We turn each table into a CSS grid so rows can flex/shrink to fit the
 * available height. Both tables use the same 40/60 column split; only the
 * tbody's grid-template-rows differs.
 */
.court-houses-table.court-table[b-xqau6hjg8v] {
    flex: 0 0 auto;
    display: grid;
    grid-template-rows: auto auto;
}

.court-houses-table.houses-table[b-xqau6hjg8v] {
    flex: 1 1 auto;
    min-height: 0;
    display: grid;
    grid-template-rows: auto 1fr;
}

.court-houses-table thead[b-xqau6hjg8v],
.court-houses-table tbody[b-xqau6hjg8v] {
    display: grid;
    width: 100%;
    min-height: 0;
}

.court-houses-table.court-table tbody[b-xqau6hjg8v] {
    grid-template-rows: repeat(4, auto);
}

.court-houses-table.houses-table tbody[b-xqau6hjg8v] {
    grid-template-rows: repeat(12, minmax(0, 1fr));
}

/* Court table is 2 columns; Houses table is 3 columns (#, House Name, Occupant). */
.court-houses-table.court-table thead tr[b-xqau6hjg8v],
.court-houses-table.court-table tbody tr[b-xqau6hjg8v] {
    display: grid;
    grid-template-columns: 40% 60%;
    width: 100%;
    min-height: 0;
}

.court-houses-table.houses-table thead tr[b-xqau6hjg8v],
.court-houses-table.houses-table tbody tr[b-xqau6hjg8v] {
    display: grid;
    grid-template-columns: 14% 38% 48%;
    width: 100%;
    min-height: 0;
}

.court-houses-table thead[b-xqau6hjg8v] {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.court-houses-table th[b-xqau6hjg8v],
.court-houses-table td[b-xqau6hjg8v] {
    padding: clamp(0.1rem, 0.4vh, 0.45rem) 0.5rem;
    text-align: center;
    /* Use right + bottom borders only to avoid doubling between cells */
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.15;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
}

.court-houses-table th:last-child[b-xqau6hjg8v],
.court-houses-table td:last-child[b-xqau6hjg8v] {
    border-right: none;
}

.court-houses-table tbody tr:last-child td[b-xqau6hjg8v] {
    border-bottom: none;
}

.court-houses-table tbody tr[b-xqau6hjg8v] {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.court-houses-table tbody tr:hover[b-xqau6hjg8v] {
    background-color: rgba(255, 255, 255, 0.04);
}

.court-houses-table tbody tr.is-selected[b-xqau6hjg8v] {
    background-color: rgba(120, 80, 200, 0.18);
    color: var(--accent-color);
}

.court-houses-table tbody tr.is-selected td[b-xqau6hjg8v] {
    color: var(--accent-color);
    font-weight: 600;
}

.court-houses-table .number-cell[b-xqau6hjg8v] {
    font-weight: 600;
    color: var(--text-secondary);
    font-variant-numeric: tabular-nums;
}

.court-houses-table .position-cell[b-xqau6hjg8v] {
    font-weight: 500;
}

.court-houses-table .occupant-cell[b-xqau6hjg8v] {
    /* No fixed width here - let the grid columns drive sizing */
}
/* /Components/Workspace/FigureDetailPanel.razor.rz.scp.css */
/*
 * FigureDetailPanel - scrollable figure inspector for Court & Houses.
 * Sticky summary + section jump chips; rich elemental badges and themed cards.
 */
.figure-detail-panel[b-6uclmx1gsd] {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0 1rem 1.25rem;
    box-shadow: 0 4px 16px var(--shadow);
    flex: 1 1 auto;
    min-height: 0;
    height: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    overflow-y: auto;
    overscroll-behavior: contain;
    scroll-behavior: smooth;
}

.figure-detail-panel.is-empty[b-6uclmx1gsd] {
    align-items: center;
    justify-content: center;
}

.detail-empty-state[b-6uclmx1gsd] {
    color: var(--text-secondary);
    font-style: italic;
    text-align: center;
    padding: 2rem 1rem;
}

/* ============================================================
 * Summary header (scrolls away) + sticky section tabs
 * ============================================================ */
.detail-summary-block[b-6uclmx1gsd] {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding-top: 0.85rem;
    padding-bottom: 0.4rem;
    margin-bottom: 0;
    border-bottom: 1px solid var(--border-color);
}

.detail-header[b-6uclmx1gsd] {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.detail-header-titles[b-6uclmx1gsd] {
    min-width: 0;
}

.slot-eyebrow[b-6uclmx1gsd] {
    margin: 0 0 0.15rem 0;
    color: var(--accent-color);
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.figure-name-display[b-6uclmx1gsd] {
    margin: 0;
    font-size: 1.55rem;
    font-weight: 700;
    line-height: 1.1;
    color: var(--text-primary);
    letter-spacing: -0.01em;
}

.english-name[b-6uclmx1gsd] {
    margin: 0.15rem 0 0;
    color: var(--text-primary);
    font-size: 0.82rem;
    font-weight: 500;
    opacity: 0.85;
}

.other-names[b-6uclmx1gsd] {
    margin: 0.2rem 0 0;
    color: var(--text-secondary);
    font-size: 0.82rem;
    font-style: italic;
}

.figure-tagline[b-6uclmx1gsd] {
    margin: 0.3rem 0 0;
    font-size: 0.92rem;
    font-weight: 600;
    font-style: italic;
    color: var(--text-secondary);
    line-height: 1.35;
}

.detail-header-aside[b-6uclmx1gsd] {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
}

.detail-figure-emblem[b-6uclmx1gsd] {
    width: 4.75rem;
    height: 4.75rem;
    border-radius: 50%;
    border: 2px solid var(--border-color);
    background: color-mix(in srgb, var(--bg-secondary) 88%, var(--bg-primary));
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 2px 10px var(--shadow);
}

.detail-figure-emblem.strength-strong[b-6uclmx1gsd] {
    border-color: rgba(76, 175, 80, 0.55);
    background: color-mix(in srgb, rgba(76, 175, 80, 0.08) 100%, var(--bg-secondary));
}

.detail-figure-emblem.strength-weak[b-6uclmx1gsd] {
    border-color: rgba(244, 67, 54, 0.55);
    background: color-mix(in srgb, rgba(244, 67, 54, 0.08) 100%, var(--bg-secondary));
}

.detail-figure-emblem[b-6uclmx1gsd]  .figure-container {
    width: 100%;
    height: 100%;
    min-height: 0;
    padding: 0.28rem 0.35rem;
    border: none;
    background: transparent;
    box-shadow: none;
    border-radius: 0;
}

.detail-figure-emblem[b-6uclmx1gsd]  .figure-container:hover {
    border: none;
    background: transparent;
    box-shadow: none;
    transform: none;
}

.detail-figure-emblem[b-6uclmx1gsd]  .figure-lines {
    gap: 1px;
    flex: 1 1 auto;
    justify-content: center;
}

.detail-figure-emblem[b-6uclmx1gsd]  .figure-line {
    font-size: 0.82rem;
    min-height: 1rem;
    height: 1rem;
    line-height: 1;
}

.detail-header-strength[b-6uclmx1gsd] {
    flex-shrink: 0;
    align-self: center;
    padding: 0.28rem 0.65rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    border: 1px solid transparent;
    white-space: nowrap;
}

.strength-strong[b-6uclmx1gsd] {
    background: rgba(76, 175, 80, 0.15);
    color: #4caf50;
    border-color: rgba(76, 175, 80, 0.4);
}

.strength-weak[b-6uclmx1gsd] {
    background: rgba(244, 67, 54, 0.15);
    color: #f44336;
    border-color: rgba(244, 67, 54, 0.4);
}

.strength-neutral[b-6uclmx1gsd] {
    background: rgba(158, 158, 158, 0.15);
    color: var(--text-secondary);
    border-color: var(--border-color);
}

/* ============================================================
 * Chip row
 * ============================================================ */
.chip-row.compact-chips[b-6uclmx1gsd] {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-top: 0.4rem;
}

.chip[b-6uclmx1gsd] {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.24rem 0.58rem;
    border-radius: 999px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-size: 0.78rem;
    font-weight: 500;
    line-height: 1;
}

.chip-glyph[b-6uclmx1gsd] {
    font-size: 0.95rem;
    line-height: 1;
}

.chip-planet[b-6uclmx1gsd] {
    background: rgba(255, 193, 7, 0.10);
    border-color: rgba(255, 193, 7, 0.35);
}

.chip-planet .chip-glyph[b-6uclmx1gsd] {
    color: #ffc107;
}

.chip-sign[b-6uclmx1gsd] {
    background: rgba(120, 80, 200, 0.10);
    border-color: rgba(120, 80, 200, 0.35);
}

.chip-sign .chip-glyph[b-6uclmx1gsd] {
    color: #9575cd;
}

.chip-keyword[b-6uclmx1gsd] {
    font-style: italic;
    color: var(--text-secondary);
    background: transparent;
    border-style: dashed;
}

.chip-humor[b-6uclmx1gsd] {
    border-style: dashed;
    color: var(--text-secondary);
    font-style: italic;
}

.chip-quality-mobile[b-6uclmx1gsd] {
    background: rgba(255, 152, 0, 0.12);
    border-color: rgba(255, 152, 0, 0.4);
    color: #ef6c00;
    font-weight: 600;
}

.chip-quality-stable[b-6uclmx1gsd] {
    background: rgba(96, 125, 139, 0.12);
    border-color: rgba(96, 125, 139, 0.4);
    color: #546e7a;
    font-weight: 600;
}

/* ============================================================
 * Section jump chips (buttons — avoids Blazor router hijacking # links)
 * ============================================================ */
.section-jump-nav[b-6uclmx1gsd] {
    display: flex;
    flex-wrap: wrap;
    gap: 0.28rem;
}

.section-jump-nav.detail-sticky-tabs[b-6uclmx1gsd] {
    position: sticky;
    top: 0;
    z-index: 6;
    background: var(--bg-primary);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 0.45rem 0 0.5rem;
    margin: 0 -1rem 0.4rem;
    padding-left: 1rem;
    padding-right: 1rem;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 1px 0 var(--border-color);
}

.jump-chip[b-6uclmx1gsd] {
    font-family: inherit;
    font-size: 0.66rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    border-radius: 999px;
    padding: 0.14rem 0.48rem;
    cursor: pointer;
    transition: color 0.12s ease, border-color 0.12s ease, background 0.12s ease, transform 0.12s ease;
}

.jump-chip:hover[b-6uclmx1gsd],
.jump-chip:focus-visible[b-6uclmx1gsd] {
    color: var(--accent-color);
    border-color: color-mix(in srgb, var(--accent-color) 45%, var(--border-color));
    background: color-mix(in srgb, var(--accent-color) 12%, var(--bg-secondary));
    outline: none;
    transform: translateY(-1px);
}

.jump-chip:active[b-6uclmx1gsd] {
    transform: translateY(0);
}

.jump-chip.is-active[b-6uclmx1gsd] {
    color: var(--accent-color);
    border-color: var(--accent-color);
    background: color-mix(in srgb, var(--accent-color) 16%, var(--bg-secondary));
    box-shadow: 0 1px 4px color-mix(in srgb, var(--accent-color) 20%, transparent);
}

/* ============================================================
 * Cards
 * ============================================================ */
.figure-detail-panel.is-ready .detail-summary-block[b-6uclmx1gsd],
.figure-detail-panel.is-ready .detail-sticky-tabs[b-6uclmx1gsd],
.figure-detail-panel.is-ready .detail-card[b-6uclmx1gsd] {
    animation: detail-fade-in-b-6uclmx1gsd 0.22s ease-out both;
}

.figure-detail-panel.is-ready .detail-card:nth-child(2)[b-6uclmx1gsd] { animation-delay: 0.02s; }
.figure-detail-panel.is-ready .detail-card:nth-child(3)[b-6uclmx1gsd] { animation-delay: 0.04s; }
.figure-detail-panel.is-ready .detail-card:nth-child(4)[b-6uclmx1gsd] { animation-delay: 0.06s; }

@keyframes detail-fade-in-b-6uclmx1gsd {
    from {
        opacity: 0;
        transform: translateY(4px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .figure-detail-panel.is-ready .detail-summary-block[b-6uclmx1gsd],
    .figure-detail-panel.is-ready .detail-sticky-tabs[b-6uclmx1gsd],
    .figure-detail-panel.is-ready .detail-card[b-6uclmx1gsd] {
        animation: none;
    }
}

.detail-card[b-6uclmx1gsd] {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.75rem 0.9rem;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    scroll-margin-top: 3.5rem;
}

.detail-card-primary[b-6uclmx1gsd] {
    border-color: color-mix(in srgb, var(--accent-color) 25%, var(--border-color));
}

.card-title[b-6uclmx1gsd] {
    margin: 0;
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-secondary);
    padding-bottom: 0.35rem;
    border-bottom: 1px solid var(--border-color);
}

.context-block + .context-block[b-6uclmx1gsd] {
    padding-top: 0.45rem;
    border-top: 1px dashed var(--border-color);
}

.prose-heading[b-6uclmx1gsd] {
    margin: 0 0 0.25rem;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-secondary);
}

.prose-text[b-6uclmx1gsd] {
    margin: 0;
    color: var(--text-primary);
    font-size: 0.9rem;
    line-height: 1.55;
}

/* ============================================================
 * In-slot contextual highlight
 * ============================================================ */
.in-slot-card[b-6uclmx1gsd] {
    border-left: 4px solid var(--accent-color);
    background: linear-gradient(
        180deg,
        color-mix(in srgb, var(--accent-color) 10%, var(--bg-secondary)) 0%,
        var(--bg-secondary) 100%
    );
    box-shadow: 0 2px 10px var(--shadow);
    border-radius: 0 8px 8px 0;
    padding: 0.55rem 0.65rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.in-slot-eyebrow[b-6uclmx1gsd] {
    margin: 0;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-color);
}

.in-slot-title[b-6uclmx1gsd] {
    margin: 0;
    font-size: 1.02rem;
    font-weight: 700;
    color: var(--text-primary);
}

.in-slot-body[b-6uclmx1gsd] {
    margin: 0;
    font-size: 0.92rem;
    line-height: 1.55;
}

.divinatory-hero[b-6uclmx1gsd] {
    padding: 0.45rem 0.55rem;
    border-radius: 8px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
}

.divinatory-hero.is-lead[b-6uclmx1gsd] {
    border-left: 3px solid var(--accent-color);
    background: linear-gradient(
        180deg,
        color-mix(in srgb, var(--accent-color) 8%, var(--bg-primary)) 0%,
        var(--bg-primary) 100%
    );
}

.divinatory-text[b-6uclmx1gsd] {
    font-size: 0.93rem;
    line-height: 1.58;
}

.pill-row[b-6uclmx1gsd] {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
}

.meaning-pill[b-6uclmx1gsd] {
    display: inline-block;
    padding: 0.18rem 0.52rem;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 600;
    background: rgba(100, 181, 246, 0.12);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

/* ============================================================
 * Verdict columns
 * ============================================================ */
.verdict-grid[b-6uclmx1gsd] {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.55rem;
}

.verdict-col[b-6uclmx1gsd] {
    padding: 0.55rem 0.65rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
}

.verdict-col h4[b-6uclmx1gsd] {
    margin: 0 0 0.25rem;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.verdict-col.fav-card[b-6uclmx1gsd] {
    border-left: 3px solid rgba(76, 175, 80, 0.7);
    background: linear-gradient(180deg, rgba(76, 175, 80, 0.1), var(--bg-primary) 65%);
}

.verdict-col.fav-card h4[b-6uclmx1gsd] {
    color: #66bb6a;
}

.verdict-col.unfav-card[b-6uclmx1gsd] {
    border-left: 3px solid rgba(244, 67, 54, 0.7);
    background: linear-gradient(180deg, rgba(244, 67, 54, 0.08), var(--bg-primary) 65%);
}

.verdict-col.unfav-card h4[b-6uclmx1gsd] {
    color: #ef5350;
}

.mini-empty[b-6uclmx1gsd] {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.78rem;
    font-style: italic;
}

/* ============================================================
 * Collapsible sections
 * ============================================================ */
.details-summary[b-6uclmx1gsd] {
    list-style: none;
    cursor: pointer;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent-color);
    padding: 0.22rem 0.35rem;
    margin: 0 -0.35rem;
    border-radius: 6px;
    user-select: none;
    transition: background 0.12s ease;
}

.details-summary:hover[b-6uclmx1gsd] {
    background: color-mix(in srgb, var(--accent-color) 8%, transparent);
}

.details-summary[b-6uclmx1gsd]::-webkit-details-marker {
    display: none;
}

.details-summary[b-6uclmx1gsd]::before {
    content: "▸";
    display: inline-block;
    margin-right: 0.35rem;
    font-size: 0.76rem;
    opacity: 0.85;
    transition: transform 0.15s ease;
}

@media (prefers-reduced-motion: no-preference) {
    details[open] > .details-summary[b-6uclmx1gsd]::before {
        transform: rotate(90deg);
    }
}

.details-body[b-6uclmx1gsd] {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    padding-top: 0.25rem;
}

/* ============================================================
 * Elements grid (4 alchemical badges)
 * ============================================================ */
.elements-card[b-6uclmx1gsd] {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.elements-grid[b-6uclmx1gsd] {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
}

.element-badge[b-6uclmx1gsd] {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.12rem;
    padding: 0.5rem 0.3rem;
    border-radius: 8px;
    border: 1.5px solid var(--border-color);
    background: var(--bg-primary);
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
    min-height: 4.25rem;
}

.element-glyph[b-6uclmx1gsd] {
    font-size: 1.45rem;
    line-height: 1;
}

.element-label[b-6uclmx1gsd] {
    font-size: 0.66rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-secondary);
}

.element-value[b-6uclmx1gsd] {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-primary);
    font-variant-numeric: tabular-nums;
}

.element-badge.is-dormant[b-6uclmx1gsd] {
    opacity: 0.38;
}

.element-badge.is-active[b-6uclmx1gsd] {
    box-shadow: 0 2px 8px var(--shadow);
}

@media (prefers-reduced-motion: no-preference) {
    .element-badge.is-active:hover[b-6uclmx1gsd] {
        transform: translateY(-1px);
    }
}

.element-badge.is-dormant .element-value[b-6uclmx1gsd] {
    color: var(--text-secondary);
    font-weight: 600;
}

.element-badge.fire.is-active[b-6uclmx1gsd] {
    background: linear-gradient(180deg, rgba(244, 67, 54, 0.18), rgba(244, 67, 54, 0.05));
    border-color: rgba(244, 67, 54, 0.55);
}

.element-badge.fire .element-glyph[b-6uclmx1gsd] { color: #f44336; }

.element-badge.air.is-active[b-6uclmx1gsd] {
    background: linear-gradient(180deg, rgba(255, 235, 59, 0.20), rgba(255, 235, 59, 0.05));
    border-color: rgba(255, 235, 59, 0.55);
}

.element-badge.air .element-glyph[b-6uclmx1gsd] { color: #fbc02d; }

.element-badge.water.is-active[b-6uclmx1gsd] {
    background: linear-gradient(180deg, rgba(33, 150, 243, 0.20), rgba(33, 150, 243, 0.05));
    border-color: rgba(33, 150, 243, 0.55);
}

.element-badge.water .element-glyph[b-6uclmx1gsd] { color: #2196f3; }

.element-badge.earth.is-active[b-6uclmx1gsd] {
    background: linear-gradient(180deg, rgba(76, 175, 80, 0.18), rgba(76, 175, 80, 0.05));
    border-color: rgba(76, 175, 80, 0.55);
}

.element-badge.earth .element-glyph[b-6uclmx1gsd] { color: #66bb6a; }

.inner-outer-row[b-6uclmx1gsd] {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.io-pill[b-6uclmx1gsd] {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.22rem 0.52rem;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.76rem;
    color: var(--text-primary);
}

.io-label[b-6uclmx1gsd] {
    color: var(--text-secondary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.66rem;
}

.io-glyph[b-6uclmx1gsd] {
    font-size: 0.95rem;
    line-height: 1;
}

.io-glyph.fire[b-6uclmx1gsd]  { color: #f44336; }
.io-glyph.air[b-6uclmx1gsd]   { color: #fbc02d; }
.io-glyph.water[b-6uclmx1gsd] { color: #2196f3; }
.io-glyph.earth[b-6uclmx1gsd] { color: #66bb6a; }

.io-pill-pattern .io-value[b-6uclmx1gsd] {
    font-style: italic;
}

/* ============================================================
 * Person & body
 * ============================================================ */
.person-card[b-6uclmx1gsd] {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    padding-top: 0.15rem;
    border-top: 1px dashed var(--border-color);
}

.person-row[b-6uclmx1gsd] {
    display: grid;
    grid-template-columns: minmax(4.5rem, 5.5rem) 1fr;
    gap: 0.55rem;
    align-items: start;
}

.person-label[b-6uclmx1gsd] {
    margin: 0;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-secondary);
    padding-top: 0.12rem;
}

.person-body[b-6uclmx1gsd] {
    margin: 0;
}

.person-meta-row[b-6uclmx1gsd] {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    padding-top: 0.2rem;
}

.person-meta[b-6uclmx1gsd] {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.22rem 0.55rem;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.8rem;
}

.person-meta-label[b-6uclmx1gsd] {
    font-size: 0.64rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-secondary);
}

.person-meta-value[b-6uclmx1gsd] {
    color: var(--text-primary);
}

/* ============================================================
 * House affinity
 * ============================================================ */
.house-affinity-card[b-6uclmx1gsd] {
    padding-top: 0.15rem;
    border-top: 1px dashed var(--border-color);
}

.affinity-row[b-6uclmx1gsd] {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 0.5rem;
}

.affinity-pill[b-6uclmx1gsd] {
    flex: 1 1 8.5rem;
    min-width: 7.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.55rem 0.75rem;
    border-radius: 10px;
    border: 1.5px solid var(--border-color);
    background: var(--bg-primary);
}

.affinity-strong[b-6uclmx1gsd] {
    background: linear-gradient(180deg, rgba(76, 175, 80, 0.15), rgba(76, 175, 80, 0.04));
    border-color: rgba(76, 175, 80, 0.5);
}

.affinity-weak[b-6uclmx1gsd] {
    background: linear-gradient(180deg, rgba(244, 67, 54, 0.13), rgba(244, 67, 54, 0.04));
    border-color: rgba(244, 67, 54, 0.5);
}

.affinity-glyph[b-6uclmx1gsd] {
    font-size: 1.05rem;
    line-height: 1;
}

.affinity-strong .affinity-glyph[b-6uclmx1gsd],
.affinity-strong .affinity-label[b-6uclmx1gsd] {
    color: #66bb6a;
}

.affinity-weak .affinity-glyph[b-6uclmx1gsd],
.affinity-weak .affinity-label[b-6uclmx1gsd] {
    color: #ef5350;
}

.affinity-label[b-6uclmx1gsd] {
    font-size: 0.64rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-secondary);
}

.affinity-value[b-6uclmx1gsd] {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-primary);
}

.affinity-vs[b-6uclmx1gsd] {
    align-self: center;
    font-size: 0.76rem;
    font-style: italic;
    color: var(--text-secondary);
}

/* ============================================================
 * Planetary correspondences
 * ============================================================ */
.correspondence-meta-block[b-6uclmx1gsd] {
    padding-top: 0.15rem;
    border-top: 1px dashed var(--border-color);
}

.correspondence-meta-row[b-6uclmx1gsd] {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.correspondence-meta[b-6uclmx1gsd] {
    display: inline-flex;
    flex-direction: column;
    gap: 0.08rem;
    padding: 0.35rem 0.55rem;
    background: color-mix(in srgb, rgba(120, 80, 200, 0.08) 50%, var(--bg-primary));
    border: 1px solid rgba(120, 80, 200, 0.35);
    border-radius: 8px;
    min-width: 7rem;
}

.correspondence-meta-label[b-6uclmx1gsd] {
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #9575cd;
}

.correspondence-meta-value[b-6uclmx1gsd] {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* ============================================================
 * Imagery & interpretation
 * ============================================================ */
.imagery-card .imagery-primary[b-6uclmx1gsd] {
    font-style: italic;
}

.imagery-card .imagery-bullets[b-6uclmx1gsd] {
    margin-top: 0.15rem;
}

.corpus-interpretation .interpretation-para + .interpretation-para[b-6uclmx1gsd] {
    margin-top: 0.55rem;
}

/* ============================================================
 * Reference (house / court directory stacks)
 * ============================================================ */
.reference-section[b-6uclmx1gsd] {
    border-left: 3px solid var(--accent-color);
}

.reference-stack[b-6uclmx1gsd] {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.reference-subcard[b-6uclmx1gsd] {
    scroll-margin-top: 0;
    margin: 0;
}

.reference-subcard.reference-card[b-6uclmx1gsd] {
    border-left: 3px solid var(--accent-color);
}

.reference-section-eyebrow[b-6uclmx1gsd] {
    margin: 0 0 0.15rem;
    padding-bottom: 0.35rem;
    border-bottom: 1px dashed var(--border-color);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-color);
}

.reference-title-line[b-6uclmx1gsd] {
    margin: 0;
    font-size: 1.02rem;
    font-weight: 700;
    color: var(--text-primary);
}

.reference-subtitle[b-6uclmx1gsd] {
    margin: 0.15rem 0 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.reading-craft-card[b-6uclmx1gsd] {
    gap: 0.85rem;
}

.craft-subsection + .craft-subsection[b-6uclmx1gsd] {
    padding-top: 0.7rem;
    border-top: 1px dashed var(--border-color);
}

.craft-subheading[b-6uclmx1gsd] {
    margin: 0 0 0.4rem 0;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-secondary);
}

.bullet-warning[b-6uclmx1gsd] {
    color: var(--text-primary);
}

.bullet-warning li[b-6uclmx1gsd]::marker {
    color: #ef5350;
}

.example-questions-card .bullet-list[b-6uclmx1gsd] {
    font-size: 0.88rem;
    line-height: 1.5;
}

.governs-card .two-col-bullets[b-6uclmx1gsd] {
    column-gap: 1.25rem;
}

/* Legacy reference helpers (callouts elsewhere) */
.reference-card[b-6uclmx1gsd] {
    border-left: 3px solid var(--accent-color);
}

/* ============================================================
 * Lists & sources
 * ============================================================ */
.bullet-list[b-6uclmx1gsd] {
    margin: 0;
    padding-left: 1.1rem;
    color: var(--text-primary);
    font-size: 0.86rem;
    line-height: 1.48;
}

.bullet-list.compact li[b-6uclmx1gsd] {
    margin-bottom: 0.15rem;
}

.bullet-favorable li[b-6uclmx1gsd]::marker {
    color: #66bb6a;
}

.bullet-unfavorable li[b-6uclmx1gsd]::marker {
    color: #ef5350;
}

.callout-block[b-6uclmx1gsd] {
    padding: 0.45rem 0.55rem;
    border-left: 3px solid color-mix(in srgb, var(--accent-color) 55%, transparent);
    background: color-mix(in srgb, var(--accent-color) 6%, var(--bg-primary));
    border-radius: 0 8px 8px 0;
}

.callout-list[b-6uclmx1gsd] {
    margin-top: 0.1rem;
}

.reference-callout[b-6uclmx1gsd] {
    padding: 0.4rem 0.5rem;
    border-radius: 6px;
    background: color-mix(in srgb, var(--accent-color) 6%, var(--bg-primary));
    border: 1px dashed color-mix(in srgb, var(--accent-color) 30%, var(--border-color));
}

.two-col-bullets[b-6uclmx1gsd] {
    columns: 2;
    column-gap: 1.1rem;
}

.two-col-bullets li[b-6uclmx1gsd] {
    break-inside: avoid;
}

.sources-card.sources-footer[b-6uclmx1gsd] {
    background: color-mix(in srgb, var(--bg-secondary) 70%, transparent);
    border: 1px dashed var(--border-color);
    color: var(--text-secondary);
}

.sources-list[b-6uclmx1gsd] {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.source-entry[b-6uclmx1gsd] {
    padding: 0.55rem 0.65rem;
    border-radius: 8px;
    background: color-mix(in srgb, var(--bg-primary) 55%, transparent);
    border: 1px solid color-mix(in srgb, var(--border-color) 85%, transparent);
}

.source-citation[b-6uclmx1gsd] {
    margin: 0;
    font-size: 0.8rem;
    line-height: 1.45;
    color: var(--text-primary);
}

.src-author[b-6uclmx1gsd] {
    font-weight: 700;
    color: var(--text-primary);
}

.src-separator[b-6uclmx1gsd] {
    margin: 0 0.28rem;
    color: var(--text-secondary);
    opacity: 0.65;
}

.src-work[b-6uclmx1gsd] {
    font-weight: 500;
    color: var(--text-primary);
}

.source-meta[b-6uclmx1gsd] {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    margin-top: 0.4rem;
}

.src-section-ref[b-6uclmx1gsd] {
    display: inline-flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.3rem;
    max-width: 100%;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    background: var(--bg-secondary);
    border: 1px dashed color-mix(in srgb, var(--accent-color) 28%, var(--border-color));
    line-height: 1.35;
}

.src-section-label[b-6uclmx1gsd] {
    flex-shrink: 0;
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent-color);
}

.src-section-text[b-6uclmx1gsd] {
    font-size: 0.74rem;
    font-style: italic;
    color: var(--text-secondary);
}

.src-year-badge[b-6uclmx1gsd] {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
    padding: 0.18rem 0.5rem;
    border-radius: 6px;
    font-size: 0.68rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.04em;
    background: color-mix(in srgb, var(--accent-color) 12%, var(--bg-secondary));
    border: 1px solid color-mix(in srgb, var(--accent-color) 28%, var(--border-color));
    color: var(--accent-color);
}

.src-note[b-6uclmx1gsd] {
    margin: 0.35rem 0 0;
    padding-top: 0.35rem;
    border-top: 1px dashed color-mix(in srgb, var(--border-color) 80%, transparent);
    color: var(--text-secondary);
    font-size: 0.74rem;
    line-height: 1.45;
    font-style: italic;
}

@media (max-width: 640px) {
    .figure-name-display[b-6uclmx1gsd] {
        font-size: 1.28rem;
    }

    .detail-figure-emblem[b-6uclmx1gsd] {
        width: 4.1rem;
        height: 4.1rem;
    }

    .detail-figure-emblem[b-6uclmx1gsd]  .figure-line {
        font-size: 0.74rem;
        min-height: 0.9rem;
        height: 0.9rem;
    }

    .jump-chip-short[b-6uclmx1gsd] {
        letter-spacing: 0.04em;
    }

    .detail-card[b-6uclmx1gsd] {
        scroll-margin-top: 3.25rem;
    }

    .elements-grid[b-6uclmx1gsd] {
        grid-template-columns: repeat(2, 1fr);
    }

    .verdict-grid[b-6uclmx1gsd] {
        grid-template-columns: 1fr;
    }

    .two-col-bullets[b-6uclmx1gsd] {
        columns: 1;
    }
}

@media (max-width: 480px) {
    .elements-grid[b-6uclmx1gsd] {
        grid-template-columns: repeat(2, 1fr);
    }

    .affinity-pill[b-6uclmx1gsd] {
        min-width: 100%;
    }
}
/* /Components/Workspace/StageScopedCourtAndHousesTable.razor.rz.scp.css */
/*
 * Stage-scoped table for walkthrough completion panes.
 * Reuses the same visual language as CourtAndHousesTab.
 */
.court-houses-tables[b-yirratnqa3] {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    min-width: 0;
    min-height: 0;
    height: auto;
    box-sizing: border-box;
}

.court-houses-section-title[b-yirratnqa3] {
    font-size: clamp(0.85rem, 1.4vh, 1.05rem);
    font-weight: 600;
    margin: 0;
    color: var(--text-primary);
    text-align: center;
    line-height: 1.2;
    flex-shrink: 0;
}

.court-houses-table[b-yirratnqa3] {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
    font-size: clamp(0.7rem, 1.1vh, 0.85rem);
    table-layout: fixed;
}

.court-houses-table.court-table[b-yirratnqa3] {
    flex: 0 0 auto;
    display: grid;
    grid-template-rows: auto auto;
}

.court-houses-table.houses-table[b-yirratnqa3] {
    flex: 0 0 auto;
    display: grid;
    grid-template-rows: auto auto;
}

.court-houses-table thead[b-yirratnqa3],
.court-houses-table tbody[b-yirratnqa3] {
    display: grid;
    width: 100%;
    min-height: 0;
}

.court-houses-table.court-table tbody[b-yirratnqa3] {
    grid-template-rows: repeat(4, auto);
}

.court-houses-table.houses-table tbody[b-yirratnqa3] {
    grid-template-rows: repeat(4, auto);
}

.court-houses-table.court-table thead tr[b-yirratnqa3],
.court-houses-table.court-table tbody tr[b-yirratnqa3] {
    display: grid;
    grid-template-columns: 40% 60%;
    width: 100%;
    min-height: 0;
}

.court-houses-table.houses-table thead tr[b-yirratnqa3],
.court-houses-table.houses-table tbody tr[b-yirratnqa3] {
    display: grid;
    grid-template-columns: 14% 38% 48%;
    width: 100%;
    min-height: 0;
}

.court-houses-table thead[b-yirratnqa3] {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.court-houses-table th[b-yirratnqa3],
.court-houses-table td[b-yirratnqa3] {
    padding: clamp(0.1rem, 0.4vh, 0.45rem) 0.5rem;
    text-align: center;
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.15;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
}

.court-houses-table th:last-child[b-yirratnqa3],
.court-houses-table td:last-child[b-yirratnqa3] {
    border-right: none;
}

.court-houses-table tbody tr:last-child td[b-yirratnqa3] {
    border-bottom: none;
}

.court-houses-table tbody tr[b-yirratnqa3] {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.court-houses-table tbody tr:hover[b-yirratnqa3] {
    background-color: rgba(255, 255, 255, 0.04);
}

.court-houses-table tbody tr.is-selected[b-yirratnqa3] {
    background-color: rgba(120, 80, 200, 0.18);
    color: var(--accent-color);
}

.court-houses-table tbody tr.is-selected td[b-yirratnqa3] {
    color: var(--accent-color);
    font-weight: 600;
}

.court-houses-table .number-cell[b-yirratnqa3] {
    font-weight: 600;
    color: var(--text-secondary);
    font-variant-numeric: tabular-nums;
}

.court-houses-table .position-cell[b-yirratnqa3] {
    font-weight: 500;
}
