/* ==========================================================================
   Servidor: what this app adds on top of the Lista de Compras look (app.css, copied as is).
   ========================================================================== */
a.dash-stat { text-decoration: none; }
.srv-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.dash-stats.srv-stats > .dash-stat:last-child { grid-column: auto; }
@container dash-top (max-width: 860px) { .srv-stats .dash-stat > .mud-icon-root { display: none; } }
@container dash-top (max-width: 640px) {
    .srv-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .srv-stats .dash-stat > .mud-icon-root { display: block; }
}
.dash-stat .dash-stat-year b { color: var(--mud-palette-text-secondary); font-weight: 600; }
.dash-stat.due b, .dash-stat.due .dash-stat-link > b { color: var(--mud-palette-warning); }
.dash-stat.pos .dash-stat-link > b { color: var(--mud-palette-success); }
.dash-stat.neg .dash-stat-link > b { color: var(--mud-palette-error); }

/* The cards share the height under the figures; on a phone the page scrolls instead. */
.srv-area { flex: 1 1 auto; min-height: 0; display: flex; }
.srv-area > .srv-grid { flex: 1 1 auto; }
.srv-admin { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-areas: "store disks users" "io temps week"; }
.srv-user { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-areas: "store repos" "week repos"; }
.srv-store { grid-area: store; } .srv-disks { grid-area: disks; } .srv-users { grid-area: users; }
.srv-io { grid-area: io; } .srv-temps { grid-area: temps; } .srv-week { grid-area: week; } .srv-repos { grid-area: repos; }
.dash-card .dash-rows { overflow-y: auto; flex-wrap: nowrap; }
@media (max-width: 1099.98px) {
    .srv-admin { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(3, minmax(220px, 1fr));
        grid-template-areas: "store disks" "users week" "io temps"; }
}
@media (max-width: 959.98px) {
    /* The title and the figures stay put; only the cards scroll, inside their own area (as the Lista de Compras
       lists do), so nothing passes under the title (Bruno, 2026-11-01). */
    .fill-page > .dash-area.srv-area { display: block; container-type: normal; flex: 1 1 auto; min-height: 0;
        overflow-y: auto; overscroll-behavior: contain; margin-inline: -8px; padding-inline: 8px; }
    .dash-area.srv-area > .dash-grid { height: auto; }
    .srv-admin, .srv-user { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; grid-auto-rows: minmax(240px, auto);
        grid-template-areas: none; padding-bottom: 16px; }
    .srv-admin > *, .srv-user > * { grid-area: auto !important; }
    /* One scroll only: the cards show all their rows. */
    .srv-grid .dash-card .dash-rows { overflow: visible; flex: none; }
}

/* Badges for a disk or a mirror: the old dashboard's OK / QUENTE / FALHA in the theme's colours. */
.disk-badge { flex: none; display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: var(--wp-radius);
    font-size: .68rem; font-weight: 700; letter-spacing: .06em; white-space: nowrap; }
.disk-badge.ok { background: color-mix(in srgb, var(--mud-palette-success) 16%, transparent); color: var(--mud-palette-success); }
.disk-badge.warn { background: color-mix(in srgb, var(--mud-palette-warning) 18%, transparent); color: var(--mud-palette-warning); }
.disk-badge.fail { background: color-mix(in srgb, var(--mud-palette-error) 16%, transparent); color: var(--mud-palette-error); }
.disk-badge.unknown { background: color-mix(in srgb, var(--mud-palette-text-secondary) 16%, transparent); color: var(--mud-palette-text-secondary); }

.srv-disk-row, .srv-user-row { display: flex; align-items: center; gap: 12px; padding: 8px 14px; min-height: 56px; box-sizing: border-box; color: inherit; text-decoration: none; }
a.srv-disk-row:hover { background: var(--mud-palette-action-default-hover); text-decoration: none; }
.srv-disk-row .dash-meter { margin-top: 4px; }
.dash-day.pos { background: color-mix(in srgb, var(--mud-palette-success) 14%, transparent); color: var(--mud-palette-success); }
.dash-day.due { background: color-mix(in srgb, var(--mud-palette-warning) 16%, transparent); color: var(--mud-palette-warning); }
.dash-day.neg { background: color-mix(in srgb, var(--mud-palette-error) 14%, transparent); color: var(--mud-palette-error); }
.dash-meter.due > span { background: var(--mud-palette-warning); }
.dash-meter.neg > span { background: var(--mud-palette-error); }

/* Live transfers: the arrows stay faint until that account is moving data. */
.srv-live { flex: none; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; opacity: .22; color: var(--mud-palette-text-secondary); }
.srv-live.up { opacity: 1; color: var(--mud-palette-success); background: color-mix(in srgb, var(--mud-palette-success) 14%, transparent); animation: srv-pulse 1.2s ease-in-out infinite; }
.srv-live.down { opacity: 1; color: var(--mud-palette-info); background: color-mix(in srgb, var(--mud-palette-info) 14%, transparent); animation: srv-pulse 1.2s ease-in-out infinite; }
@keyframes srv-pulse { 50% { transform: translateY(-2px); } }
.srv-live + .srv-live { margin-left: -8px; }

/* Rings in the level's colour (the Lista de Compras ring is always green on amber). */
.dash-donut .ring-bg { stroke: color-mix(in srgb, var(--mud-palette-text-secondary) 18%, transparent); }
.dash-donut.due .ring { stroke: var(--mud-palette-warning); }
.dash-donut.neg .ring { stroke: var(--mud-palette-error); }
/* Néon: the storage ring glows in its own colour, like the dials (Bruno, 2026-11-01). */
.dash-donut { --ring: var(--mud-palette-success); }
.dash-donut.due { --ring: var(--mud-palette-warning); }
.dash-donut.neg { --ring: var(--mud-palette-error); }
html.wp-neon .dash-donut .ring { filter: drop-shadow(0 0 4px var(--ring)) drop-shadow(0 0 10px color-mix(in srgb, var(--ring) 55%, transparent)); }
html.wp-neon .dash-donut .ring-num { filter: drop-shadow(0 0 6px color-mix(in srgb, var(--ring) 60%, transparent)); }
.dash-legend dd .disk-badge { margin-top: 2px; }
.dash-legend dd.keep-case { white-space: normal; overflow-wrap: anywhere; font-weight: 600; }
.srv-big { flex-direction: column; gap: 4px; }
.srv-big b { font-size: 2.2rem; color: var(--mud-palette-text-primary); }

.dot.read { background: var(--mud-palette-success); }
.dot.write { background: var(--mud-palette-error); }
.dash-key { flex-wrap: wrap; justify-content: flex-end; row-gap: 2px; font-size: .72rem; }

/* Time charts: lines over three faint guides, the figures at the left, the times under. */
.line-chart { flex: 1 1 auto; min-height: 140px; display: flex; gap: 6px; padding: 10px 14px 8px 8px; }
.lc-y { flex: none; display: flex; flex-direction: column; justify-content: space-between; padding-bottom: 18px; text-align: right;
    font-size: .66rem; color: var(--mud-palette-text-secondary); font-variant-numeric: tabular-nums; white-space: nowrap; }
.lc-plot { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.lc-plot svg { flex: 1; width: 100%; min-height: 0; overflow: visible; }
.lc-grid { stroke: var(--mud-palette-lines-default); stroke-width: 1; vector-effect: non-scaling-stroke; }
html.wp-dark .lc-grid { stroke: color-mix(in srgb, var(--mud-palette-text-primary) 14%, transparent); }
.lc-line { fill: none; stroke-width: 2; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.lc-area { opacity: .12; stroke: none; }
html.wp-neon .lc-line { filter: drop-shadow(0 0 4px currentColor); }
.lc-x { flex: none; display: flex; justify-content: space-between; height: 18px; padding-top: 4px; font-size: .66rem; color: var(--mud-palette-text-secondary); }

.srv-bars.dense { gap: 3px; padding-inline: 10px; }
.srv-bars.dense .dash-bar .col { width: 45%; }
.srv-bars.dense small { font-size: .6rem; }
.srv-bars { min-height: 120px; }

/* Discos */
.srv-mirror { display: flex; align-items: center; gap: 24px; padding: 8px 16px; flex-wrap: wrap; }
.srv-mirror .dash-donut-wrap { flex: none; height: 150px; padding: 0; }
.srv-disk-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 12px; padding: 4px 16px 16px; }
.srv-disk { display: flex; flex-direction: column; gap: 6px; padding: 12px; border-radius: var(--wp-radius); border: 1px solid var(--mud-palette-lines-default);
    background: color-mix(in srgb, var(--mud-palette-text-primary) 3%, transparent); }
.srv-disk-head { display: flex; align-items: center; gap: 8px; }
.srv-disk-head b { font-size: 1.05rem; }
.srv-disk-head :is(.disk-badge, .disk-state) { margin-left: auto; }
.srv-disk-temp { font-size: 2rem; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.srv-disk-temp small { font-size: .9rem; font-weight: 600; }
.srv-disk-temp.pos { color: var(--mud-palette-success); } .srv-disk-temp.due { color: var(--mud-palette-warning); } .srv-disk-temp.neg { color: var(--mud-palette-error); }
.srv-kv { display: flex; justify-content: space-between; gap: 8px; font-size: .8rem; color: var(--mud-palette-text-secondary); }
.srv-kv b { color: var(--mud-palette-text-primary); font-weight: 600; }
.srv-kv b.pos { color: var(--mud-palette-success); } .srv-kv b.neg { color: var(--mud-palette-error); }
.srv-kv.small { font-size: .68rem; }
.srv-two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.srv-chart { min-height: 280px; }
@media (max-width: 899.98px) { .srv-two { grid-template-columns: minmax(0, 1fr); } }
.srv-foot { font-size: .78rem; text-align: center; margin: 16px 0 8px; }

/* Utilizadores */
.srv-user-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 12px; }
.srv-user-card { min-height: 220px; }
.srv-user-card .srv-user-row { border-bottom: 1px solid var(--mud-palette-lines-default); }
.srv-user-figs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; padding: 8px 14px 0; font-size: .8rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.srv-user-figs > span { display: inline-flex; align-items: center; gap: 6px; }
.srv-user-figs .muted { font-weight: 400; margin-left: auto; }

/* Bibliotecas */
.srv-list > * + * { border-top: .5px solid var(--wp-row-line); }
.srv-repo-link { display: block; color: inherit; text-decoration: none; }
.srv-repo-link:hover { background: var(--mud-palette-action-default-hover); text-decoration: none; }
.srv-repo-row .suggest-when { font-size: .72rem; }

/* The account menu says whether this is an admin. */
.role-tag { display: inline-block; margin-top: 6px; padding: 2px 8px; border-radius: var(--wp-radius); font-size: .66rem; font-weight: 700; letter-spacing: .06em;
    text-transform: uppercase; background: color-mix(in srgb, var(--mud-palette-text-secondary) 14%, transparent); color: var(--mud-palette-text-secondary); }
.role-tag.admin { background: color-mix(in srgb, var(--mud-palette-primary) 16%, transparent); color: var(--mud-palette-primary); }

/* The bottom bar sits lower on iPhones (Bruno, 2026-11-01): only part of the home-indicator area is kept under its
   icons, instead of all of it. The pages end where the bar starts. Since 2026-11-05 the same 10 pt as the other apps
   (app.css --wp-nav-pad), instead of 40% of the safe area (~14 pt). */
:root { --srv-nav-safe: var(--wp-nav-pad); }
@media (max-width: 959.98px) {
    .bottom-nav { height: calc(var(--wp-bottom-nav) + var(--srv-nav-safe)); padding-bottom: var(--srv-nav-safe); }
    .app-container { padding-bottom: calc(var(--wp-bottom-nav) + 32px + var(--srv-nav-safe)); }
    .fill-page { height: calc(100dvh - var(--wp-main-top) - 20px - var(--wp-bottom-nav) - var(--srv-nav-safe)); }
}

/* The detail windows the top figures open (Bruno, 2026-11-01). */
button.dash-stat-link { cursor: pointer; }
.detail-dialog .mud-dialog-content { padding-top: 4px; }
.detail-chart { display: flex; flex-direction: column; height: 260px; margin: 0 -8px 8px; }
.detail-key { justify-content: flex-start; margin: 0 8px 4px; font-size: .74rem; color: var(--mud-palette-text-secondary); }
.detail-bars { display: flex; height: 170px; margin: 0 -8px; }
.detail-head { padding: 0 0 8px; }
.detail-section { display: flex; align-items: center; gap: 8px; margin: 18px 0 6px; padding-bottom: 6px; font-size: .74rem; font-weight: 600;
    letter-spacing: .06em; text-transform: uppercase; color: var(--mud-palette-text-secondary); border-bottom: 1px solid var(--mud-palette-lines-default); }
.detail-section:first-child { margin-top: 4px; }
.detail-section .dash-key { margin-left: auto; text-transform: none; letter-spacing: 0; }
.detail-table { width: 100%; border-collapse: collapse; font-size: .86rem; font-variant-numeric: tabular-nums; }
.detail-table th { text-align: left; font-size: .68rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--mud-palette-text-secondary);
    padding: 6px 6px; border-bottom: 1px solid var(--mud-palette-lines-default); white-space: nowrap; }
.detail-table td { padding: 8px 6px; border-bottom: .5px solid var(--wp-row-line, var(--mud-palette-lines-default)); vertical-align: top; }
.detail-table tfoot td { border-bottom: 0; font-weight: 600; }
.detail-table td small { display: block; font-size: .7rem; font-weight: 400; }
.detail-table td .dot { margin-right: 6px; vertical-align: middle; }
.detail-table td.pos { color: var(--mud-palette-success); } .detail-table td.due { color: var(--mud-palette-warning); } .detail-table td.neg { color: var(--mud-palette-error); }
.detail-table th .dot { margin-right: 4px; }
@media (max-width: 599.98px) { .detail-table { font-size: .78rem; } .detail-table th, .detail-table td { padding-inline: 4px; } }

/* The admins' notification switch in the account menu. */
.push-toggle.on { color: var(--mud-palette-success); }

/* Transferências agora while data moves (Bruno, 2026-11-01): the card eases back and forth between its normal look and
   the direction's colour (uploads red, downloads green, both purple), with moving arrows. The colour lives on a layer
   over the card whose opacity breathes, so the card's own look shows through at the low point. */
.dash-stat.xfer-up { --xfer: var(--mud-palette-error); }
.dash-stat.xfer-down { --xfer: var(--mud-palette-success); }
.dash-stat.xfer-both { --xfer: #A66BFF; }
html:not(.wp-dark) .dash-stat.xfer-both { --xfer: #7C4DDB; }
.dash-stat:is(.xfer-up, .xfer-down, .xfer-both)::before { content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none;
    border: 1px solid color-mix(in srgb, var(--xfer) 80%, transparent);
    background: color-mix(in srgb, var(--xfer) 12%, transparent);
    box-shadow: 0 0 18px color-mix(in srgb, var(--xfer) 45%, transparent), inset 0 0 22px color-mix(in srgb, var(--xfer) 30%, transparent);
    animation: xfer-breathe 2.4s ease-in-out infinite; }
.dash-stat:is(.xfer-up, .xfer-down, .xfer-both) { overflow: visible; }
.dash-stat:is(.xfer-up, .xfer-down, .xfer-both) .dash-stat-link > b,
.dash-stat:is(.xfer-up, .xfer-down, .xfer-both) .dash-stat-year b { color: var(--xfer); }
.dash-stat:is(.xfer-up, .xfer-down, .xfer-both) > .mud-icon-root { background: color-mix(in srgb, var(--xfer) 18%, transparent); color: var(--xfer); }
.dash-stat.xfer-up > .mud-icon-root { animation: xfer-rise 1.1s ease-in-out infinite; }
.dash-stat.xfer-down > .mud-icon-root { animation: xfer-fall 1.1s ease-in-out infinite; }
.dash-stat.xfer-both > .mud-icon-root { animation: xfer-turn 3.2s ease-in-out infinite; }
@keyframes xfer-breathe { 0%, 100% { opacity: 0; } 50% { opacity: 1; } }
@keyframes xfer-rise { 0% { translate: 0 3px; } 50% { translate: 0 -3px; } 100% { translate: 0 3px; } }
@keyframes xfer-fall { 0% { translate: 0 -3px; } 50% { translate: 0 3px; } 100% { translate: 0 -3px; } }
@keyframes xfer-turn { 0%, 100% { rotate: 0deg; } 50% { rotate: 180deg; } }
@media (prefers-reduced-motion: reduce) { .dash-stat.xfer > .mud-icon-root, .dash-stat.xfer::before { animation: none !important; } .dash-stat.xfer::before { opacity: 1; } }

/* The speedometer on Transferências agora, in the card's colour. */
.speed-gauge { flex: none; display: flex; flex-direction: column; align-items: center; width: 92px; margin: -4px -4px -6px auto; position: relative; z-index: 1; pointer-events: none; }
.speed-gauge svg { width: 92px; height: 54px; overflow: visible; }
.sg-track, .sg-fill { fill: none; stroke-width: 7; stroke-linecap: round; }
.sg-track { stroke: color-mix(in srgb, var(--mud-palette-text-secondary) 20%, transparent); }
.sg-fill { stroke: var(--xfer, var(--mud-palette-primary)); }
.sg-tick { stroke: var(--mud-palette-text-secondary); stroke-width: 1.2; opacity: .6; }
.sg-needle { transform-origin: 60px 62px; transform-box: view-box; }
.sg-needle line { stroke: var(--mud-palette-text-primary); stroke-width: 2.5; stroke-linecap: round; }
.sg-hub { fill: var(--mud-palette-text-primary); }
html.wp-neon .sg-fill { filter: drop-shadow(0 0 4px var(--xfer, var(--mud-palette-primary))); }
.sg-value { margin-top: -2px; font-size: .62rem; color: var(--mud-palette-text-secondary); white-space: nowrap; font-variant-numeric: tabular-nums; }
.sg-value b { font-size: .9rem; color: var(--xfer, var(--mud-palette-text-primary)); }
@container dash-top (max-width: 860px) { .speed-gauge { width: 70px; } .speed-gauge svg { width: 70px; height: 42px; } }

/* The temperature dial: green up to the warning, amber to the alert, red beyond; a triangle at the five days' highest. */
.tg-zone { fill: none; stroke-width: 7; }
.tg-zone.ok { stroke: color-mix(in srgb, var(--mud-palette-success) 75%, transparent); stroke-linecap: round; }
.tg-zone.warn { stroke: color-mix(in srgb, var(--mud-palette-warning) 85%, transparent); }
.tg-zone.hot { stroke: color-mix(in srgb, var(--mud-palette-error) 85%, transparent); }
.tg-max { fill: var(--mud-palette-error); }
html.wp-neon .tg-zone { filter: drop-shadow(0 0 3px currentColor); }
.temp-gauge .sg-value b { color: inherit; }
.dash-stat.pos .temp-gauge .sg-value b { color: var(--mud-palette-success); }
.dash-stat.due .temp-gauge .sg-value b { color: var(--mud-palette-warning); }
.dash-stat.neg .temp-gauge .sg-value b { color: var(--mud-palette-error); }
.tg-max-text { font-size: .62rem; }

/* A disk's life used: the bar and its percentage in green, amber or red. */
.srv-life { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.srv-life .dash-meter { flex: 1; margin-top: 0 !important; }
.srv-life b { flex: none; min-width: 34px; text-align: right; font-size: .78rem; font-variant-numeric: tabular-nums; }
.dash-meter.pos > span { background: var(--mud-palette-success); }
.dash-meter.pos { background: color-mix(in srgb, var(--mud-palette-success) 14%, transparent); }
.dash-meter.due { background: color-mix(in srgb, var(--mud-palette-warning) 14%, transparent); }
.dash-meter.neg { background: color-mix(in srgb, var(--mud-palette-error) 14%, transparent); }
b.pos { color: var(--mud-palette-success); } b.due { color: var(--mud-palette-warning); } b.neg { color: var(--mud-palette-error); }

/* Espaço usado's small ring. */
.usage-ring { flex: none; display: flex; flex-direction: column; align-items: center; margin: 0 4px 0 auto; position: relative; z-index: 1; pointer-events: none; }
.usage-ring svg { width: 46px; height: 46px; }
.usage-ring circle { fill: none; stroke-width: 6; }
.ur-bg { stroke: color-mix(in srgb, var(--mud-palette-text-secondary) 20%, transparent); }
.ur-fill { stroke: var(--mud-palette-success); stroke-linecap: round; transform: rotate(-90deg); transform-origin: 30px 30px; transition: stroke-dasharray 1.2s ease-out; }
.usage-ring.due .ur-fill { stroke: var(--mud-palette-warning); }
.usage-ring.neg .ur-fill { stroke: var(--mud-palette-error); }
.ur-num { text-anchor: middle; font-size: 14px; font-weight: 700; fill: var(--mud-palette-text-primary); }
.usage-ring { --ring: var(--mud-palette-success); } .usage-ring.due { --ring: var(--mud-palette-warning); } .usage-ring.neg { --ring: var(--mud-palette-error); }
html.wp-neon .ur-fill { filter: drop-shadow(0 0 3px var(--ring)); }

/* Transferências agora: the faces of whoever is moving data, overlapping a little when there are several. */
.xfer-faces { display: flex; align-items: center; padding: 4px 0 2px 4px; }
.xfer-face { display: inline-flex; margin-left: -7px; border-radius: 50%; box-shadow: 0 0 0 2px var(--mud-palette-surface), 0 0 0 3.5px var(--xfer, transparent); }
.xfer-face:first-child { margin-left: -4px; }
.xfer-face .mud-avatar { width: 24px; height: 24px; font-size: .62rem; }
.xfer-faces:has(.xfer-face:nth-child(4)) .xfer-face { margin-left: -10px; }
.xfer-faces:has(.xfer-face:nth-child(4)) .xfer-face:first-child { margin-left: -4px; }

/* A disk's temperature: the °C beside the figure, not under it (Bruno, 2026-11-01). */
.dash-day.dash-temp { flex-direction: row; align-items: center; justify-content: center; gap: 0; width: 58px; box-sizing: border-box; line-height: 1; }
.dash-day.dash-temp :is(b, small) { font-size: 1rem; font-weight: 700; text-transform: none; line-height: 1; }

/* Any card with something to warn about (space, disks, temperature) breathes amber (warning) or red (alert, faster) as
   the transfer card does, and its icon pulses; in Néon on every card, and on Temperaturas in every theme. When the
   temperature dial is in the red its thermometer shakes, as if under pressure (Bruno, 2026-11-01/02). */
.dash-stat.due { --alert: var(--mud-palette-warning); }
.dash-stat.neg { --alert: var(--mud-palette-error); }
:is(html.wp-neon .dash-stat, .dash-stat.temp-card):is(.due, .neg) { overflow: visible; }
:is(html.wp-neon .dash-stat, .dash-stat.temp-card):is(.due, .neg)::before { content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none;
    border: 1px solid color-mix(in srgb, var(--alert) 80%, transparent);
    background: color-mix(in srgb, var(--alert) 12%, transparent);
    box-shadow: 0 0 18px color-mix(in srgb, var(--alert) 45%, transparent), inset 0 0 22px color-mix(in srgb, var(--alert) 30%, transparent);
    animation: xfer-breathe 2.4s ease-in-out infinite; }
:is(html.wp-neon .dash-stat, .dash-stat.temp-card).neg::before { animation-duration: 1.2s; }
:is(html.wp-neon .dash-stat, .dash-stat.temp-card):is(.due, .neg) > .mud-icon-root { animation: temp-pulse 2.4s ease-in-out infinite; }
:is(html.wp-neon .dash-stat, .dash-stat.temp-card).neg > .mud-icon-root { animation-duration: 1.2s; }
html.wp-neon .dash-stat:is(.due, .neg) > .mud-icon-root { box-shadow: 0 0 12px color-mix(in srgb, var(--alert) 50%, transparent); }
html .dash-stat.temp-card.neg > .mud-icon-root { animation: temp-shake .6s ease-in-out infinite; }
@keyframes temp-pulse { 0%, 100% { scale: 1; } 50% { scale: 1.15; } }
@keyframes temp-shake { 0%, 100% { rotate: 0deg; translate: 0 0; } 15% { rotate: -9deg; translate: -1px 0; } 30% { rotate: 8deg; translate: 1px 0; }
    45% { rotate: -6deg; translate: -1px 0; } 60% { rotate: 5deg; translate: 1px 0; } 75% { rotate: -2deg; translate: 0 0; } }
@media (prefers-reduced-motion: reduce) { .dash-stat::before, .dash-stat > .mud-icon-root { animation: none !important; } .dash-stat:is(.due, .neg)::before { opacity: 1; } }

/* A disk's state as an icon on a round tint instead of the word: tick, flame, exclamation, question (Bruno, 2026-11-01). */
.disk-state { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; color: var(--ds); background: color-mix(in srgb, var(--ds) 18%, transparent); }
.disk-state .mud-icon-root { font-size: 18px; }
.disk-state.ok { --ds: var(--mud-palette-success); }
.disk-state.warn { --ds: var(--mud-palette-warning); }
.disk-state.fail { --ds: var(--mud-palette-error); }
.disk-state.unknown { --ds: var(--mud-palette-text-secondary); }
html.wp-neon .disk-state { box-shadow: 0 0 0 1px color-mix(in srgb, var(--ds) 55%, transparent), 0 0 10px color-mix(in srgb, var(--ds) 35%, transparent); }
html.wp-neon .disk-state .mud-icon-root { filter: drop-shadow(0 0 3px var(--ds)); }

/* Utilizadores: the chosen day window filled green (Bruno, 2026-11-01). */
.mud-button-root.day-on { background-color: var(--mud-palette-success) !important; border-color: var(--mud-palette-success) !important; color: var(--mud-palette-success-text) !important; }
html.wp-neon .mud-button-root.day-on { box-shadow: 0 0 10px color-mix(in srgb, var(--mud-palette-success) 55%, transparent); }

/* Day bars with their figures at the left (Bruno, 2026-11-01): the bars touch so the guides at the top and half run
   across the whole chart; each bar keeps its own width, so they still read apart. */
.srv-bars-y { flex: 1 1 auto; min-height: 0; display: flex; padding-left: 8px; }
.srv-bars-y > .lc-y { padding: 12px 0 calc(8px + 6px + 1.2 * .7rem); }
.srv-bars-y:has(.dense) > .lc-y { padding-bottom: calc(8px + 6px + 1.2 * .6rem); }
.srv-bars-y > .dash-bars, .srv-bars-y > .dash-bars.dense { flex: 1; min-width: 0; gap: 0; padding-left: 6px; }
.srv-bars-y .dash-bar-cols { background: linear-gradient(var(--mud-palette-lines-default) 0 0) top / 100% 1px no-repeat,
    linear-gradient(var(--mud-palette-lines-default) 0 0) center / 100% 1px no-repeat; background-origin: content-box; }
.srv-bars-y .dash-bar small { line-height: 1.2; }
html.wp-dark .srv-bars-y .dash-bar-cols { --g: color-mix(in srgb, var(--mud-palette-text-primary) 14%, transparent);
    background: linear-gradient(var(--g) 0 0) top / 100% 1px no-repeat, linear-gradient(var(--g) 0 0) center / 100% 1px no-repeat; background-origin: content-box; }

/* Faces over the week's bars: whoever sent (green) or fetched (red) something that day, stacked on top of the bar and
   overlapping a little; room is kept above the tallest bar for three (Bruno, 2026-11-01). */
.srv-bars-y.faces .dash-bar-cols { padding-top: 46px; background-origin: content-box; overflow: visible; }
.srv-bars-y.faces > .lc-y { padding-top: calc(12px + 46px); }
.dash-bar .col { position: relative; }
.bar-faces { position: absolute; left: 50%; bottom: calc(100% + 3px); translate: -50% 0; display: flex; flex-direction: column-reverse; align-items: center; z-index: 1; }
.bar-face { display: inline-flex; margin-top: -7px; border-radius: 50%; box-shadow: 0 0 0 2px var(--mud-palette-surface), 0 0 0 3px var(--face, transparent); }
.bar-face:last-child { margin-top: 0; }
.col.in .bar-face { --face: var(--mud-palette-success); }
.col.out .bar-face { --face: var(--mud-palette-error); }
.bar-face .mud-avatar { width: 18px; height: 18px; font-size: .5rem; }
.bar-face.more { width: 18px; height: 18px; align-items: center; justify-content: center; font-size: .55rem; font-weight: 700;
    color: var(--mud-palette-text-primary); background: var(--mud-palette-surface); }
html.wp-neon .bar-face { box-shadow: 0 0 0 2px var(--mud-palette-surface), 0 0 0 3px var(--face), 0 0 8px color-mix(in srgb, var(--face) 60%, transparent); }
.srv-bars-y.faces .dash-bar .col.out { opacity: 1; background: color-mix(in srgb, var(--mud-palette-error) 85%, transparent); }

/* In the red the temperature dial's needle trembles, like a pressure gauge under strain: the disks are running too hot
   (Bruno, 2026-11-02). The script turns the needle's group; the tremor is on the line inside it, about the hub. */
.temp-gauge.hot .sg-needle line { transform-origin: 60px 62px; transform-box: view-box; animation: needle-tremor .35s linear infinite; }
.temp-gauge.hot .sg-hub { animation: temp-pulse 1.2s ease-in-out infinite; transform-origin: 60px 62px; transform-box: view-box; }
html.wp-neon .temp-gauge.hot .sg-needle line { stroke: var(--mud-palette-error); filter: drop-shadow(0 0 3px var(--mud-palette-error)); }
@keyframes needle-tremor { 0%, 100% { rotate: 0deg; } 10% { rotate: -2.5deg; } 25% { rotate: 2deg; } 40% { rotate: -1.5deg; }
    55% { rotate: 3deg; } 70% { rotate: -2deg; } 85% { rotate: 1deg; } }
@media (prefers-reduced-motion: reduce) { .temp-gauge.hot :is(.sg-needle line, .sg-hub) { animation: none; } }
/* Discos uses the whole window width (Bruno, 2026-11-08); Utilizadores too: no 1280px cap; the disk cards fill the extra space. */
.app-container:has(.disks-page, .users-page, .libs-page) { max-width: none; }
/* Discos fills the window height too (Bruno, 2026-11-08): the two charts grow into the space left under the disks, so the page ends at the footnote. */
.disks-page > .fill-scroll { display: flex; flex-direction: column; padding-bottom: 8px; }
.disks-page > .fill-scroll > * { flex: none; }
.disks-page > .fill-scroll > .srv-two { flex: 1 0 auto; }
.disks-page .srv-foot { margin: 12px 0 0; }
/* Utilizadores fills the window height as well (Bruno, 2026-11-08): the "Todos" chart and the rows of user cards share the space left, so the page ends at the footnote. */
.users-page > .fill-scroll { display: flex; flex-direction: column; padding-bottom: 8px; }
.users-page > .fill-scroll > * { flex: none; }
.users-page > .fill-scroll > .srv-chart { flex: 1 0 auto; }
.users-page > .fill-scroll > .srv-user-grid { flex: 2 0 auto; }
/* The charts take their height from the card, not from their width (a wide SVG otherwise grows tall and pushes the cards off the page). */
.users-page .lc-plot { position: relative; }
.users-page .lc-plot svg { position: absolute; left: 0; top: 0; width: 100%; height: calc(100% - 18px); }
.users-page .lc-plot .lc-x { margin-top: auto; }
/* The user cards share each row: as many per row as fit, the rows balanced (7 = 4 + 3, not 5 + 2) and every row stretched to the full width.
   The per-row count comes from container queries that Users.razor writes for the number of accounts. */
.users-page .srv-user-grid { display: flex; flex-wrap: wrap; align-content: stretch; container: users / inline-size; }
.users-page .srv-user-grid > .srv-user-card { flex: 1 1 100%; min-width: 0; box-sizing: border-box; }
.users-page .srv-foot { margin: 12px 0 0; }
/* Bibliotecas (Bruno, 2026-11-08): the whole window, each group of libraries a column side by side down to the bottom;
   the page itself never scrolls, only each list of libraries, under a title that stays put. On a phone the groups stack as before. */
@media (min-width: 900px) {
    .libs-page > .fill-scroll { display: flex; gap: 12px; overflow: hidden; padding-bottom: 16px; }
    .libs-page > .fill-scroll::before, .libs-page > .fill-scroll::after { display: none; }
    .libs-page > .fill-scroll > .dash-card { flex: 1 1 0; min-width: 0; min-height: 0; margin-bottom: 0 !important; }
    .libs-page > .fill-scroll > .dash-card > .dash-head { flex: none; }
    .libs-page > .fill-scroll > .dash-card > .srv-list { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }
}
.lib-total { font-size: .85rem; font-weight: 600; font-variant-numeric: tabular-nums; text-transform: none; letter-spacing: 0; }
/* Every other library a shade lighter, to follow a row across (Bruno, 2026-11-08); hovering still wins. */
.libs-page .srv-list > .srv-repo-link:nth-child(even) { background: color-mix(in srgb, var(--mud-palette-text-primary) 4%, transparent); }
.libs-page .srv-list > .srv-repo-link:hover { background: var(--mud-palette-action-default-hover); }
.repo-pct { margin-left: 6px; font-size: .78em; font-weight: 500; color: var(--mud-palette-text-secondary); }
/* Discos: the temperatures as one row a disk (name and last reading at the left, its line at the right), sharing the card's height. */
.temp-stack { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; padding: 4px 0 6px; }
.temp-row { flex: 1 1 0; min-height: 56px; display: flex; align-items: stretch; }
.temp-row + .temp-row { border-top: .5px solid var(--wp-row-line); }
.temp-name { flex: none; width: 84px; display: flex; flex-direction: column; justify-content: center; gap: 2px; padding-left: 16px; font-size: .78rem; color: var(--mud-palette-text-secondary); }
.temp-name > span { display: flex; align-items: center; gap: 6px; }
.temp-name b { font-size: 1rem; font-weight: 700; color: var(--mud-palette-text-primary); font-variant-numeric: tabular-nums; }
.temp-row > .line-chart { min-height: 0; padding: 6px 14px 4px 4px; }
.temp-row .lc-plot { position: relative; }
.temp-row .lc-plot svg { position: absolute; left: 0; top: 0; width: 100%; height: 100%; }
.temp-row .lc-plot .lc-x { margin-top: auto; }
.temp-row:not(:last-child) .lc-x { display: none; }
.temp-row:not(:last-child) .lc-y { padding-bottom: 0; }
.temp-row:last-child .lc-plot svg { height: calc(100% - 18px); }
/* The 5-day dialog: a bit taller, the four rows need the room. The Dashboard card stacks like Discos. */
.detail-chart.temp-detail { height: 320px; }
.dash-card > .temp-stack, .dash-card > .dash-empty { flex: 1 1 auto; }
