:root {
    --bg: #f8fafc;
    --panel: #ffffff;
    --surface: #ffffff;
    --text: #0f172a;
    --muted: #64748b;
    --soft: #94a3b8;
    --line: #e2e8f0;
    --line-strong: #cbd5e1;
    --chip: #eff6ff;
    --chip-text: #1e3a8a;
    --active: #dbeafe;
    --accent: #1e3a8a;
    --accent-strong: #1e40af;
    --accent-soft: #eff6ff;
    --radius: 8px;
    --shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.4;
}

button,
input,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

.radar-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 248px minmax(560px, 1fr) 260px;
}

.radar-sidebar {
    background: var(--panel);
    border-right: 1px solid var(--line);
    padding: 14px 12px 24px;
    overflow-y: auto;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 4px 18px;
    color: var(--accent);
    text-decoration: none;
    font-weight: 700;
    font-size: 16px;
}

.brand-mark {
    width: 24px;
    height: 24px;
    border-radius: 7px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: white;
    font-size: 11px;
    letter-spacing: 0;
}

.sidebar-nav,
.sidebar-section {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 18px;
}

.sidebar-heading {
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
    padding: 7px 4px 5px;
    text-transform: uppercase;
    letter-spacing: 0;
}

.sidebar-link,
.sidebar-item {
    width: 100%;
    border: 0;
    background: transparent;
    color: var(--muted);
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 30px;
    padding: 5px 9px;
    border-radius: 6px;
    font-size: 13px;
    text-align: left;
}

.sidebar-link:hover,
.sidebar-item:hover,
.sidebar-link.active,
.sidebar-item.active {
    background: var(--active);
    color: var(--accent);
}

.item-count {
    color: var(--soft);
    font-size: 12px;
    font-variant-numeric: tabular-nums;
}

.radar-main {
    padding: 22px 36px 44px;
    overflow-y: auto;
}

.page-header {
    max-width: 980px;
    margin: 14px auto 16px;
    display: grid;
    grid-template-columns: 1fr 260px;
    gap: 24px;
    align-items: start;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
    padding: 20px 22px;
}

.eyebrow {
    color: var(--muted);
    font-size: 12px;
    margin: 0 0 8px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0;
}

h1 {
    font-size: 30px;
    line-height: 1.12;
    margin: 0 0 8px;
    letter-spacing: 0;
    color: var(--accent);
}

.page-subtitle {
    color: var(--muted);
    font-size: 14px;
    max-width: 680px;
    margin: 0;
}

.search-box {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 0 10px;
    color: var(--accent);
    min-height: 34px;
    box-shadow: none;
    font-size: 13px;
}

.search-box input {
    border: 0;
    outline: 0;
    width: 100%;
    min-width: 0;
    color: var(--text);
    background: transparent;
}

.search-box input::placeholder {
    color: var(--soft);
}

.toolbar {
    max-width: 980px;
    margin: 0 auto 12px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 7px;
    flex-wrap: wrap;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.segmented-control {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    display: inline-flex;
    padding: 2px;
}

.segment,
.period-tab {
    border: 0;
    background: transparent;
    color: var(--muted);
    border-radius: 6px;
    padding: 6px 10px;
    font-weight: 600;
    font-size: 13px;
}

.segment.active,
.period-tab.active {
    background: var(--accent);
    color: white;
}

.period-tabs {
    display: flex;
    gap: 6px;
}

.period-tab {
    border-radius: 6px;
    padding-inline: 6px;
    position: relative;
}

.period-tab.active {
    background: var(--accent);
}

.period-tab.active::after {
    content: none;
}

.sort-select {
    margin-left: auto;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--text);
    border-radius: var(--radius);
    padding: 6px 9px;
    font-size: 13px;
}

.active-filter-bar,
.results-meta {
    max-width: 980px;
    margin: 0 auto;
}

.active-filter-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--accent-soft);
    color: var(--accent);
    border: 1px solid #bfdbfe;
    padding: 7px 10px;
    border-radius: var(--radius);
    margin-bottom: 10px;
    font-size: 13px;
}

.active-filter-bar[hidden] {
    display: none;
}

.active-filter-bar button {
    border: 0;
    background: transparent;
    color: inherit;
    font-weight: 700;
}

.results-meta {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    color: var(--soft);
    font-size: 12px;
    margin-bottom: 8px;
}

.report-list {
    max-width: 980px;
    margin: 0 auto;
    border-top: 1px solid var(--line);
}

.report-row {
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr);
    gap: 14px;
    padding: 13px 0;
    border-bottom: 1px solid var(--line);
    background: transparent;
    margin-bottom: 0;
    transition: background-color 0.2s;
}

.report-row:hover {
    background: rgba(30, 58, 138, 0.025);
}

.report-thumb {
    width: 74px;
    height: 100px;
    border: 1px solid var(--line-strong);
    border-radius: 5px;
    background: var(--accent-soft);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--soft);
    font-weight: 700;
    font-size: 12px;
}

.report-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.report-content {
    min-width: 0;
}

.report-title {
    color: var(--text);
    font-size: 15px;
    font-weight: 800;
    line-height: 1.2;
    text-decoration: none;
}

.report-title:hover {
    color: var(--accent);
    text-decoration: none;
}

.report-meta {
    margin-top: 3px;
    color: var(--muted);
    font-size: 12px;
}

.report-description {
    color: var(--muted);
    margin: 6px 0 8px;
    max-width: 820px;
    font-size: 13px;
}

.chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.chip {
    background: var(--chip);
    color: var(--chip-text);
    border: 1px solid #bfdbfe;
    border-radius: 999px;
    padding: 2px 6px;
    font-size: 11px;
    font-weight: 700;
}

.report-actions {
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
}

.report-action {
    color: var(--accent);
    text-decoration: none;
    font-weight: 700;
}

.report-action.secondary {
    color: var(--muted);
    font-weight: 600;
}

.radar-rightbar {
    border-left: 1px solid var(--line);
    background: var(--surface);
    padding: 216px 16px 32px;
    overflow-y: auto;
}

.rightbar-section {
    margin-bottom: 22px;
}

.rightbar-section h2 {
    margin: 0 0 8px;
    color: var(--accent);
    font-size: 12px;
    font-weight: 600;
}

.rank-item {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: var(--muted);
    padding: 4px 0;
    font-size: 12px;
}

.rank-item button {
    border: 0;
    background: transparent;
    color: inherit;
    text-align: left;
    padding: 0;
}

.rank-item button:hover {
    color: var(--accent);
}

.rank-count {
    color: var(--soft);
    font-variant-numeric: tabular-nums;
}

.load-more-wrap {
    max-width: 980px;
    margin: 18px auto 0;
    text-align: center;
}

.load-more-btn {
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--accent);
    border-radius: var(--radius);
    padding: 8px 13px;
    font-weight: 700;
    font-size: 13px;
}

.load-more-btn:hover {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.empty-state,
.loading-state {
    border-bottom: 1px solid var(--line);
    padding: 40px 0;
    color: var(--muted);
}

@media (max-width: 1180px) {
    .radar-shell {
        grid-template-columns: 240px minmax(0, 1fr);
    }

    .radar-rightbar {
        display: none;
    }
}

@media (max-width: 820px) {
    .radar-shell {
        display: block;
    }

    .radar-sidebar {
        border-right: 0;
        border-bottom: 1px solid var(--line);
        max-height: 360px;
    }

    .radar-main {
        padding: 18px 14px 36px;
    }

    .page-header {
        display: block;
        margin-top: 10px;
        padding: 18px 16px;
    }

    .search-box {
        margin-top: 14px;
    }

    .report-row {
        grid-template-columns: 72px minmax(0, 1fr);
        gap: 14px;
        padding: 12px 0;
    }

    .report-thumb {
        width: 72px;
        height: 98px;
    }

    h1 {
        font-size: 26px;
    }
}
