/*
 * RAMAC Central theme, staff panel only. Loaded after central-base.css (see that file for how the theme works).
 * Holds the styles of staff-only screens; the shared look lives in central-base.css.
 */

/* The staff brand carries a second line, so the sidebar head needs a little more room below it. */
.fi-panel-staff .fi-sidebar-header {
    padding-bottom: 10px;
}

/* ==== Dashboard (mock-up Main artboard) ======================================================================== */

.fi-panel-staff .fi-page-content .fi-grid:has(> .fi-wi-widget) {
    gap: 20px;
}

.rc-widget {
    min-width: 0;
}

/* Cards */
.rc-card {
    display: flex;
    flex-direction: column;
    gap: 16px;
    height: 100%;
    padding: 24px 26px;
}

.rc-card-wide {
    gap: 18px;
    padding: 26px 28px;
}

.rc-card-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.rc-card-head.rc-baseline {
    align-items: baseline;
}

.rc-card-lead {
    margin-top: 4px;
}

.rc-card-lead-tight {
    margin-top: -8px;
}

.rc-card-total {
    font-size: 15px;
    font-weight: 600;
    white-space: nowrap;
    color: var(--rc-text);
}

.rc-card-end {
    margin-top: auto;
}

.rc-empty {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: var(--rc-text-2);
}

.rc-strong {
    font-weight: 600;
    color: var(--rc-text);
}

.rc-right {
    text-align: right;
}

.rc-nowrap {
    white-space: nowrap;
}

.rc-id {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 13px;
    color: var(--rc-soft);
}

.rc-footnote {
    margin: 0;
    font-size: 12.5px;
    color: var(--rc-muted);
}

/* Units band */
.rc-band {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(190px, 100%), 1fr));
    gap: 1px;
    overflow: hidden;
    border: 1px solid var(--rc-border);
    border-radius: 18px;
    background-color: var(--rc-border);
}

.rc-band-tile {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
    padding: 20px 22px;
    background-color: var(--rc-panel);
}

.rc-band-value {
    font-size: 36px;
    font-weight: 700;
    line-height: 1.1;
    color: var(--rc-text);
}

.rc-band-foot {
    display: flex;
    align-items: flex-end;
    height: 36px;
    margin-top: auto;
    padding-top: 12px;
}

.rc-share-bar {
    display: flex;
    flex: 1;
    gap: 2px;
    height: 8px;
    overflow: hidden;
    border-radius: 4px;
}

/* Where the units stand */
.rc-ring {
    display: block;
    align-self: center;
    width: 100%;
    max-width: 360px;
    height: auto;
}

.rc-ring circle {
    fill: none;
    stroke-width: 34;
}

.rc-ring-total {
    font: 700 24px var(--rc-heading-font);
    fill: var(--rc-text);
    text-anchor: middle;
}

.rc-ring-unit {
    font: 500 12px var(--rc-text-font);
    fill: var(--rc-text-2);
    text-anchor: middle;
}

.rc-legend {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    list-style: none;
}

.rc-legend-row {
    display: grid;
    grid-template-columns: 9px minmax(0, 1fr) auto 50px;
    align-items: center;
    gap: 12px;
    padding: 9px 0;
    border-bottom: 1px solid var(--rc-border);
    font-size: 14px;
}

.rc-legend-row:last-child {
    border-bottom: 0;
}

/* Billing this financial year */
.rc-fy-figures {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 16px 40px;
}

.rc-fy-main {
    flex: 1 1 300px;
    min-width: 0;
}

.rc-fy-expect {
    margin-top: 4px;
    font-size: 48px;
    font-weight: 700;
    line-height: 1.05;
    color: var(--rc-lime);
}

.rc-fy-figure {
    margin-top: 4px;
    font-size: 26px;
    font-weight: 600;
    line-height: 1.15;
    color: var(--rc-text);
}

.rc-fy-none {
    margin-top: 6px;
    font-size: 15px;
    font-weight: 600;
    color: var(--rc-text);
}

.rc-fy-chart {
    display: block;
    width: 100%;
    height: auto;
}

.rc-fy-floor {
    fill: #152f35;
    stroke: #24454d;
    stroke-width: 1;
}

.rc-fy-grid {
    stroke: #21424a;
    stroke-width: 1;
}

.rc-fy-today {
    stroke: var(--rc-lime);
    stroke-width: 2;
    stroke-linecap: round;
}

.rc-fy-billed-front {
    fill: #17b3ad;
}

.rc-fy-billed-side {
    fill: #0b7672;
}

.rc-fy-billed-top {
    fill: #6df2ea;
}

.rc-fy-expect-front,
.rc-fy-expect-side,
.rc-fy-expect-top {
    stroke: var(--rc-lime);
    stroke-width: 1.2;
    stroke-linejoin: round;
}

.rc-fy-expect-front {
    fill: rgba(214, 244, 2, 0.14);
}

.rc-fy-expect-side {
    fill: rgba(214, 244, 2, 0.07);
}

.rc-fy-expect-top {
    fill: rgba(214, 244, 2, 0.36);
}

.rc-fy-value {
    font: 600 11.5px var(--rc-text-font);
    text-anchor: middle;
}

.rc-fy-value-billed {
    fill: var(--rc-soft);
}

.rc-fy-value-expect {
    font-weight: 700;
    fill: var(--rc-lime);
}

.rc-fy-month {
    font: 500 12px var(--rc-text-font);
    fill: var(--rc-muted);
    text-anchor: middle;
}

.rc-fy-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 22px;
    font-size: 12.5px;
    font-weight: 600;
}

.rc-fy-legend .rc-row:first-child {
    color: var(--rc-link);
}

.rc-fy-legend .rc-row:nth-child(2) {
    color: var(--rc-lime);
}

.rc-fy-key {
    display: inline-block;
    width: 22px;
    height: 2px;
    border-radius: 1px;
}

.rc-fy-key-billed {
    background-color: var(--rc-primary);
}

.rc-fy-key-expect {
    background-color: var(--rc-lime);
}

/* Billing by client */
.rc-bars {
    display: flex;
    flex-direction: column;
    gap: 13px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.rc-bars li {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.rc-bars-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 14px;
}

.rc-bars-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Coming up for renewal */
.rc-renew {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.rc-renew li {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rc-renew-head {
    display: flex;
    align-items: baseline;
    gap: 10px;
    font-size: 14px;
}

.rc-renew-count {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
    color: var(--rc-text);
}

.rc-track > i.rc-track-orange {
    background-color: var(--rc-orange);
}

.rc-next {
    padding-top: 12px;
    border-top: 1px solid var(--rc-border);
}

.rc-next-title {
    margin-bottom: 4px;
}

.rc-list {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    list-style: none;
}

.rc-list-row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid var(--rc-divider);
    font-size: 13.5px;
}

.rc-list-row:last-child {
    border-bottom: 0;
}

.rc-list-main {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Needs attention */
.rc-attention {
    gap: 6px;
}

.rc-attention .rc-h2 {
    margin-bottom: 6px;
}

.rc-att {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin: 0 -10px;
    padding: 12px 10px;
    border-radius: 12px;
    text-decoration: none;
}

.rc-att:hover,
.rc-att:focus-visible {
    background-color: var(--rc-hover);
}

.rc-att-dot {
    margin-top: 6px;
}

.rc-dot-ok {
    background-color: var(--rc-primary);
}

.rc-dot-warn {
    background-color: var(--rc-orange);
}

.rc-dot-info {
    background-color: var(--rc-blue);
}

.rc-att-text {
    flex: 1;
    min-width: 0;
}

.rc-att-title {
    display: block;
    font-weight: 600;
    color: var(--rc-text);
}

.rc-att-sub {
    display: block;
    margin-top: 2px;
}

.rc-att svg {
    flex: none;
    width: 18px;
    height: 18px;
    margin-top: 2px;
    fill: none;
    stroke: var(--rc-muted);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.rc-att-none {
    margin: 4px 0 0;
}

/* ==== Screens other than the dashboard (mock-up Devices, DeviceDetail, BillingRun, Reconciliation artboards) ===== */

/* A header line of inline parts and pills under a page title (it sits in Filament's subheading <p>). */
.rc-head-meta {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 10px;
    margin-top: 4px;
    color: var(--rc-text-2);
}

/* Figure tiles (billing run totals, SigfoxSA groups): the dashboard band with the mock-up's .big figures. */
.rc-band-figures .rc-band-tile {
    padding: 18px 22px;
}

.rc-figure {
    font-size: 32px;
    font-weight: 700;
    line-height: 1.1;
    color: var(--rc-text);
}

.rc-figure-warn {
    color: #ffab66;
}

.rc-figure-more {
    font-size: 15px;
    font-weight: 600;
    color: var(--rc-soft);
}

/* Devices: billing status rows (dot, label and sub line, figure on the right). */
.rc-stat-rows {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.rc-stat-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
}

.rc-stat-row > .rc-dot {
    margin-top: 6px;
}

.rc-stat-text {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-width: 0;
}

.rc-stat-label {
    color: var(--rc-text);
}

.rc-stat-value {
    font-weight: 600;
    color: var(--rc-text);
}

/* Devices: the last sync's time as the mock-up's .big figure. */
.rc-big {
    display: block;
    font-size: 32px;
    font-weight: 700;
    line-height: 1.1;
    color: var(--rc-text);
}

.rc-big-link {
    text-decoration: none;
}

.rc-big-link:hover .rc-big {
    color: var(--rc-link-hover);
}

.rc-big-sub {
    margin-top: 6px;
}

.rc-warn-line {
    margin-top: 10px;
    font-size: 13px;
    color: #ffab66;
}

/* Device page: label and value rows (shared .rc-kv) with a pill or a second line, and the History list. */
.rc-kv dd .rc-kv-pill {
    margin-left: 6px;
}

.rc-kv-sub {
    display: block;
    margin-top: 2px;
}

.rc-hist {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    list-style: none;
}

.rc-hist li {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 14px;
    padding: 11px 0;
    border-bottom: 1px solid var(--rc-divider);
    font-size: 14px;
    color: var(--rc-text);
}

.rc-hist li:last-child {
    border-bottom: 0;
}

.rc-hist + .rc-footnote {
    margin-top: 12px;
}

/* Phone width: the grid stacks to one column (Filament's grid); tighten the cards. */
@media (max-width: 640px) {
    .rc-card,
    .rc-card-wide {
        padding: 20px 18px;
    }

    .rc-band-value {
        font-size: 30px;
    }

    .rc-fy-expect {
        font-size: 36px;
    }

    .rc-figure,
    .rc-big {
        font-size: 28px;
    }

    .rc-hist li {
        grid-template-columns: minmax(0, 1fr);
        gap: 2px;
    }
}
