/* FiberVu: ONE shared style for every module. Loaded last, so it sets the sizes once for all pages (no one-off sizes per page).
   Spacing 4 · 8 · 12 · 16 · 24 px. Page edges 16 px. Buttons, inputs, dropdowns, date pickers 32 px (small 28 px), radius 8 px.
   Table header 36 px, compact rows keep their one height in the whole table. Pills 22 px. Pagination squares 28 px.
   Colours are not touched here (blue theme, status colours stay as they are). */
:root {
    --ui-h: 32px; --ui-h-sm: 28px; --ui-r: 8px; --ui-edge: 16px; --ui-line: var(--dk-bd-d0d5dd, #D0D5DD);
    --ui-s1: 4px; --ui-s2: 8px; --ui-s3: 12px; --ui-s4: 16px; --ui-s5: 24px;
}

/* ---- page edges: title bar, filter bar and body line up at 16 px */
.fv-top { padding-left: var(--ui-edge); }
.fv-bar2 { padding-left: var(--ui-edge); padding-right: var(--ui-edge); }
.fv-body { padding-left: var(--ui-edge); padding-right: var(--ui-edge); }
.fv-top .fv-actions, .fv-bar2 { gap: var(--ui-s2); }

/* ---- buttons: one height, one radius, icon + text centred with a 6 px gap, text never wraps */
.fv-btn { height: var(--ui-h); padding: 0 var(--ui-s3); border-radius: var(--ui-r); font-size: 13px; font-weight: 600; line-height: 1; gap: 6px; justify-content: center; white-space: nowrap; border-color: var(--ui-line); box-sizing: border-box; text-decoration: none; }
.fv-btn.sm, .fv-tbl .fv-btn, .fv-chips-row .fv-btn { height: var(--ui-h-sm); padding: 0 10px; font-size: 12px; }
.fv-btn svg, .fv-btn img { width: 16px; height: 16px; flex: none; }
.fv-btn:hover { background: var(--dk-bg-f9fafb, #F9FAFB); }
.fv-btn.dg { background: #D92D20; border-color: #D92D20; color: #fff; } .fv-btn.dg:hover { background: #B42318; border-color: #B42318; }
.fv-btn.soft { background: var(--dk-bg-e6eef9, #E6EEF9); border-color: var(--dk-bd-e6eef9, #E6EEF9); color: var(--dk-fg-0047bb, #0047BB); }
.fv-btn:focus-visible, .fv-chip:focus-visible, .fv-tab:focus-visible, .fv-inp:focus-visible, .pc-tabs button:focus-visible, .pc-chips button:focus-visible { outline: 2px solid #9CB9E8; outline-offset: 2px; }
.fv-btn[disabled], .fv-btn[disabled]:hover { opacity: .55; cursor: progress; background: var(--dk-bg-f2f4f7, #F2F4F7); color: var(--dk-fg-667085, #667085); border-color: var(--ui-line); }
.fv-btn.dk[disabled] { background: #0047BB !important; color: #fff !important; }
.fv-busy { pointer-events: none; opacity: .55; cursor: progress; }

/* ---- inputs, search boxes, dropdowns, date pickers */
.fv-inp, .fv-bar2 select, .fv-bar2 input:not([type=checkbox]):not([type=radio]), .fv-top select, .fv-top input:not([type=checkbox]):not([type=radio]) { height: var(--ui-h); border-radius: var(--ui-r); border: 1px solid var(--ui-line); font-size: 13px; padding: 0 10px; box-sizing: border-box; }
.fv-inp:hover { border-color: var(--dk-bd-98a2b3, #98A2B3); }

/* ---- chips and tabs on a toolbar: the same height as a small button, vertically centred */
.fv-chip, .pc-tabs button, .pc-chips button { min-height: var(--ui-h-sm); display: inline-flex; align-items: center; box-sizing: border-box; line-height: 1.2; }
.fv-chip { padding-top: 0; padding-bottom: 0; }
.fv-tab:hover:not(.is-on), .pc-tabs button:hover:not(.on) { background: var(--dk-bg-f3f4f6, #F3F4F6); }

/* ---- cards / KPI boxes: even padding and radius, lined up with the table below */
.pc-k, .fv-kpi, .fv-stats > div { border-radius: 10px; }
.pc-kpis { padding-left: var(--ui-s4); padding-right: var(--ui-s4); }

/* ---- tables: header 36 px, text left, numbers right with same-width digits, headers aligned like their data, actions in the last column on one line */
.fv-tbl th { height: 36px; padding-top: 0; padding-bottom: 0; vertical-align: middle; }
.fv-tbl td { vertical-align: middle; }
.fv-tbl th.n, .fv-tbl td.n { font-variant-numeric: tabular-nums; }   /* alignment: the column types in imat-layout.css */
.fv-tbl td.act, .fv-tbl th.act { white-space: nowrap; }
.fv-tbl td .fv-btn + .fv-btn { margin-left: var(--ui-s2); }
.fv-chip b, .pc-k b, .fv-stats b, .pc-cnt { font-variant-numeric: tabular-nums; }

/* ---- pills / badges: 22 px, same radius, centred in the row */
.fv-pill, .pc-pill { height: 22px; padding: 0 9px; border-radius: 999px; font-size: 11px; line-height: 22px; box-sizing: border-box; vertical-align: middle; }
.fv-pill[class*="rs-"] { line-height: 22px; height: 22px; padding: 0 9px; }
.fv-pill.k-r, .fv-pill.k-g, .fv-pill.k-a, .fv-pill.k-x, .fv-pill.k-d, .fv-pill.k-b { display: inline-flex; align-items: center; }

/* ---- pagination: equal square buttons, current page in blue */
.cw-pager { gap: var(--ui-s1); }
.cw-pager button { min-width: 28px; height: 28px; padding: 0 8px; border-radius: 7px; border: 1px solid var(--ui-line); font-size: 12px; display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; }
.cw-pager button:hover:not(.is-on):not(:disabled) { background: var(--dk-bg-f3f4f6, #F3F4F6); }
.cw-pager button:disabled { opacity: .5; cursor: not-allowed; }

/* ---- the Settings pages (Filament): the same button, input and badge sizes */
.fi-btn:not(.fi-size-xs):not(.fi-size-sm):not(.fi-icon-btn) { height: var(--ui-h); padding-top: 0; padding-bottom: 0; border-radius: var(--ui-r); font-size: 13px; }
.fi-btn.fi-size-sm { height: var(--ui-h-sm); border-radius: var(--ui-r); }
.fi-btn:not(.fi-icon-btn), .fi-input-wrp { border-radius: var(--ui-r) !important; }
.fi-input-wrp { border-radius: var(--ui-r); }
.fi-input-wrp .fi-input, .fi-input-wrp .fi-select-input { height: calc(var(--ui-h) - 2px); padding-top: 0; padding-bottom: 0; }
.fi-badge { height: 22px; min-height: 22px; border-radius: 999px; padding-top: 0; padding-bottom: 0; }

/* ---- small screens: toolbars wrap neatly, never overlap */
@media (max-width: 1100px) {
    .fv-bar2 { flex-wrap: wrap; white-space: normal; overflow-x: visible; row-gap: var(--ui-s2); }
}
@media (prefers-reduced-motion: reduce) { .fv-btn, .fv-chip, .fv-pill { transition: none !important; } }

/* PON capacity: the Export button at the right of the tab row and its panel */
.px-wrap { position: sticky; right: 0; z-index: 3; margin-left: auto; flex: none; padding-left: 10px; background: linear-gradient(to right, transparent, var(--fv-bg) 10px); }   /* stays in sight at the right end of a row that scrolls sideways */
.px-btn { display: inline-flex; align-items: center; gap: 6px; }
.px-pop { position: fixed; z-index: 60; width: 400px; max-height: min(78vh, 720px); overflow: auto; background: var(--dk-bg-ffffff, #fff); border: 1px solid var(--dk-bd-d0d5dd, #D0D5DD); border-radius: 12px; box-shadow: 0 12px 32px rgba(16, 24, 40, .18); padding: 12px 14px; font-size: 12.5px; color: var(--dk-fg-101828, #101828); }
.px-h { display: flex; align-items: baseline; gap: 8px; margin-bottom: 4px; } .px-h b { font-size: 14px; } .px-h span { color: var(--dk-fg-667085, #667085); }
.px-x { margin-left: auto; border: 0; background: none; font-size: 20px; line-height: 1; color: var(--dk-fg-667085, #667085); cursor: pointer; }
.px-sec { margin: 11px 0 5px; font-size: 11px; font-weight: 700; color: var(--dk-fg-475467, #475467); text-transform: uppercase; letter-spacing: .03em; display: flex; align-items: center; gap: 8px; }
.px-seg { display: inline-flex; }
.px-radio { display: block; margin: 4px 0; cursor: pointer; line-height: 1.4; padding-left: 20px; text-indent: -20px; }
.px-radio input { width: 14px; margin: 0 6px 0 0; vertical-align: -2px; }
.px-pop { overflow-x: hidden; white-space: normal; text-align: left; } .px-pop * { box-sizing: border-box; max-width: 100%; }
.px-dim, .px-note { color: var(--dk-fg-667085, #667085); font-size: 11.5px; } .px-note { margin-top: 3px; }
.px-sel { width: 100%; }
.px-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 10px; }
.px-cols label { display: flex; gap: 5px; align-items: center; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.px-link { border: 0; background: none; color: var(--dk-fg-0047bb, #0047BB); font-weight: 600; cursor: pointer; padding: 0; font-size: 11.5px; text-transform: none; letter-spacing: 0; }
.px-name { font: 11.5px ui-monospace, SFMono-Regular, Consolas, monospace; background: var(--dk-bg-f2f4f7, #F2F4F7); border-radius: 7px; padding: 6px 8px; word-break: break-all; }
.px-err { color: var(--dk-fg-b42318, #B42318); margin-top: 6px; }
.px-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; } .px-actions .fv-btn { display: inline-flex; align-items: center; gap: 6px; }
.px-actions .fv-btn.is-on { border-color: var(--dk-bd-0047bb, #0047BB); color: var(--dk-fg-0047bb, #0047BB); }
.px-spin { width: 12px; height: 12px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: px-spin .7s linear infinite; }
@keyframes px-spin { to { transform: rotate(360deg); } }
.px-sched { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--dk-bd-eaecf0, #EAECF0); }
.px-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 6px 0; }
.px-to { width: 100%; resize: vertical; min-height: 44px; }
.px-list { margin-top: 8px; display: flex; flex-direction: column; gap: 6px; }
.px-item { display: flex; gap: 8px; justify-content: space-between; align-items: flex-start; border: 1px solid var(--dk-bd-eaecf0, #EAECF0); border-radius: 8px; padding: 6px 8px; }
.px-item small { display: block; color: var(--dk-fg-667085, #667085); }
