/* Admin dashboard (docs/ADMINISTRATION.md §5): plain and readable, no external fonts or frameworks. */

:root {
    --text: #1c1f24;
    --muted: #5f6672;
    --line: #d9dde3;
    --surface: #ffffff;
    --background: #f3f4f6;
    --accent: #2f5bd3;
    --warn: #b3261e;
    --plus: #1d7a3a;
    color-scheme: light;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--background);
    color: var(--text);
    font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

a {
    color: var(--accent);
}

h1 {
    font-size: 1.6rem;
    margin: 0 0 1rem;
}

h2 {
    font-size: 1.2rem;
    margin: 0 0 0.75rem;
}

h3 {
    font-size: 1rem;
    margin: 1rem 0 0.5rem;
}

.top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem 2rem;
    padding: 0.75rem 1.5rem;
    background: var(--text);
    color: #fff;
}

.top a {
    color: #fff;
    text-decoration: none;
}

.brand {
    font-weight: 700;
    letter-spacing: 0.08em;
}

.brand span {
    font-weight: 400;
    opacity: 0.7;
}

.top nav {
    display: flex;
    gap: 1.25rem;
}

.account {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

main {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.5rem;
}

.card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 1rem 1.25rem;
    margin-bottom: 1.25rem;
}

.narrow {
    max-width: 32rem;
    margin: 3rem auto;
}

button {
    font: inherit;
    padding: 0.45rem 1rem;
    border: 1px solid var(--accent);
    border-radius: 6px;
    background: var(--accent);
    color: #fff;
    cursor: pointer;
}

button:disabled {
    opacity: 0.6;
    cursor: wait;
}

.account button {
    background: transparent;
    border-color: #fff;
}

input,
select {
    font: inherit;
    padding: 0.4rem 0.6rem;
    border: 1px solid var(--line);
    border-radius: 6px;
}

.search,
.filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.search input {
    font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
    text-transform: uppercase;
    width: 12rem;
}

.tiles {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.tile {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
}

.tile .value {
    font-size: 1.8rem;
    font-weight: 600;
}

.tile .label,
.hint,
.empty {
    color: var(--muted);
}

.notice,
.status:not(:empty) {
    padding: 0.5rem 0.75rem;
    border-left: 3px solid var(--warn);
    background: #fbeaea;
}

.toc {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
    margin-bottom: 1rem;
}

.facts {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 0.25rem 1.5rem;
    margin: 0;
}

.facts dt {
    color: var(--muted);
}

.facts dd {
    margin: 0;
}

.table-wrap {
    overflow-x: auto;
}

table {
    border-collapse: collapse;
    width: 100%;
    font-size: 0.9rem;
}

th,
td {
    text-align: left;
    vertical-align: top;
    padding: 0.35rem 0.6rem;
    border-bottom: 1px solid var(--line);
    white-space: nowrap;
}

th {
    color: var(--muted);
    font-weight: 600;
}

tbody tr:nth-child(even) {
    background: #f8f9fb;
}

.num {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.mono {
    font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
}

.small {
    font-size: 0.8rem;
}

.plus {
    color: var(--plus);
}

.minus,
.warn {
    color: var(--warn);
}

details summary {
    cursor: pointer;
    color: var(--accent);
}

pre {
    margin: 0.25rem 0 0;
    padding: 0.5rem;
    background: #f1f3f6;
    border-radius: 4px;
    font-size: 0.8rem;
    white-space: pre-wrap;
    max-width: 40rem;
}

.pager {
    display: flex;
    gap: 1rem;
    align-items: center;
    margin-top: 0.75rem;
}

code {
    font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
}
