/* Layout concept: a fixed navy "network spine" sidebar carrying the Bluecom mark,
   a bright operations workspace on the right, and a 16:9 presentation stage on top. */
:root {
  --navy: #17195A;          /* Bluekom brand indigo (sampled from logo) */
  --navy-2: #262F7E;
  --navy-ink: #CBD0EC;
  --signal: #1877B5;        /* accent: the logo swoosh blue, darkened for text contrast */
  --sky: #2597D6;           /* logo swoosh blue */
  --signal-soft: #E6F0FD;
  --gold: #D9A52B;          /* Dahabshiil group gold, used sparingly */
  --bg: #F1F4F9;
  --surface: #FFFFFF;
  --surface-2: #F7F9FC;
  --ink: #0B1A33;
  --ink-2: #33415C;
  --muted: #5F6E87;
  --line: #DEE4EE;
  --good: #1D8F62; --good-soft: #E3F4EC;
  --warn: #B86E0E; --warn-soft: #FBF0DF;
  --bad: #C63D37;  --bad-soft: #FBE7E6;
  --none: #7C879B; --none-soft: #EEF1F6;
  --c-SL: #2B7BE4; --c-SS: #12A39A; --c-PL: #C9831F;
  --target: #9AA6BA;
  --shadow: 0 1px 2px rgba(14,35,78,.06), 0 4px 16px rgba(14,35,78,.05);
  --f-display: "Archivo", "Segoe UI", system-ui, sans-serif;
  --f-body: "IBM Plex Sans", "Segoe UI", system-ui, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, Consolas, monospace;
  --r: 10px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --navy: #0E0F3A; --navy-2: #1E2468; --navy-ink: #BFC5E6;
    --signal: #3FA6E0; --signal-soft: #15284D; --gold: #E0B54A;
    --bg: #0A1328; --surface: #101C36; --surface-2: #0D1830;
    --ink: #E7EDF8; --ink-2: #C3CEE2; --muted: #8E9DB8; --line: #213153;
    --good: #3DBB88; --good-soft: #10302A; --warn: #E2A04A; --warn-soft: #33270F; --bad: #EC6A63; --bad-soft: #3A1A1C; --none: #8E99AE; --none-soft: #1A2742;
    --c-SL: #4A8BE6; --c-SS: #1FA89E; --c-PL: #B87A1E; --target: #5E6C88;
    --shadow: 0 1px 2px rgba(0,0,0,.3); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --navy: #0E0F3A; --navy-2: #1E2468; --navy-ink: #BFC5E6;
  --signal: #3FA6E0; --signal-soft: #15284D; --gold: #E0B54A;
  --bg: #0A1328; --surface: #101C36; --surface-2: #0D1830;
  --ink: #E7EDF8; --ink-2: #C3CEE2; --muted: #8E9DB8; --line: #213153;
  --good: #3DBB88; --good-soft: #10302A; --warn: #E2A04A; --warn-soft: #33270F; --bad: #EC6A63; --bad-soft: #3A1A1C; --none: #8E99AE; --none-soft: #1A2742;
  --c-SL: #4A8BE6; --c-SS: #1FA89E; --c-PL: #B87A1E; --target: #5E6C88;
  --shadow: 0 1px 2px rgba(0,0,0,.3); color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 14px/1.5 var(--f-body); -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4 { font-family: var(--f-display); margin: 0; letter-spacing: -.01em; text-wrap: balance; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--signal); }
.num, td.n, .mono { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
:focus-visible { outline: 2px solid var(--signal); outline-offset: 2px; }
[hidden] { display: none !important; }

/* ── shell ── */
.shell { display: grid; grid-template-columns: 248px minmax(0, 1fr); min-height: 100%; }
.side { background: var(--navy); color: var(--navy-ink); display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; padding: 18px 14px; gap: 18px; overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 6px 14px; border-bottom: 1px solid rgba(255,255,255,.08); }
.brand img { width: 40px; height: 40px; }
.brand b { display: block; color: #fff; font: 700 15px/1.15 var(--f-display); letter-spacing: .01em; }
.brand small { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: #8FB4F2; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav .sec { font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: #6F86B3; padding: 12px 10px 4px; }
.nav button { all: unset; cursor: pointer; display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; color: var(--navy-ink); font-weight: 500; }
.nav button svg { width: 18px; height: 18px; flex: none; opacity: .85; }
.nav button:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav button.on { background: rgba(91,155,239,.18); color: #fff; box-shadow: inset 3px 0 0 #2597D6; }
.nav .badge { margin-left: auto; background: rgba(255,255,255,.12); color: #fff; font: 600 11px var(--f-mono); padding: 1px 7px; border-radius: 10px; }
.nav .badge.alert { background: var(--bad); }
.me { margin-top: auto; padding: 12px 8px 0; border-top: 1px solid rgba(255,255,255,.08); display: flex; gap: 10px; align-items: center; }
.me .av { width: 34px; height: 34px; border-radius: 50%; background: #2B4A86; color: #fff; display: grid; place-items: center; font: 700 12px var(--f-display); flex: none; }
.me .who { min-width: 0; line-height: 1.25; }
.me .who b { color: #fff; font-weight: 600; font-size: 13px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me .who span { font-size: 11.5px; color: #8EA3CB; }
.me button { all: unset; cursor: pointer; margin-left: auto; color: #8EA3CB; padding: 6px; border-radius: 6px; }
.me button:hover { color: #fff; background: rgba(255,255,255,.06); }
.group-foot { display: flex; align-items: center; gap: 8px; font-size: 11px; color: #7186AE; padding: 0 8px; }
.group-foot img { width: 22px; height: 22px; border-radius: 4px; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: center; gap: 14px; padding: 16px max(16px, env(safe-area-inset-right, 0px)) 14px max(24px, env(safe-area-inset-left, 0px)); border-bottom: 1px solid var(--line); background: var(--surface); position: sticky; top: 0; z-index: 20; flex-wrap: wrap; }
.topbar h1 { font-size: 21px; font-weight: 700; }
.topbar .sub { color: var(--muted); font-size: 13px; }
.topbar .spacer { flex: 1; }
.menu-btn { display: none; }
.content { padding: 22px max(16px, env(safe-area-inset-right, 0px)) 40px max(24px, env(safe-area-inset-left, 0px)); display: flex; flex-direction: column; gap: 20px; max-width: 1480px; width: 100%; }
.demo-band { background: linear-gradient(90deg, var(--gold), #E8C25B); color: #2A1E00; font-size: 12.5px; padding: 7px 24px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.demo-band button { all: unset; cursor: pointer; text-decoration: underline; font-weight: 600; }

/* ── controls ── */
.btn { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line); background: var(--surface); padding: 8px 14px; border-radius: 8px; cursor: pointer; font-weight: 600; font-size: 13px; white-space: nowrap; color: var(--ink); }
.btn:hover { border-color: var(--signal); }
.btn.primary { background: var(--signal); border-color: var(--signal); color: #fff; }
.btn.primary:hover { filter: brightness(1.07); }
.btn.navy { background: var(--navy); border-color: var(--navy); color: #fff; }
.btn.ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn.danger { color: var(--bad); }
.btn.good { background: var(--good); border-color: var(--good); color: #fff; }
.btn.sm { padding: 5px 10px; font-size: 12px; }
.btn svg { width: 16px; height: 16px; }
.btn:disabled { opacity: .55; cursor: default; }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--line); border-radius: 9px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg button { all: unset; cursor: pointer; padding: 5px 11px; border-radius: 6px; font-size: 12.5px; font-weight: 600; color: var(--muted); }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field > span { font-size: 12px; font-weight: 600; color: var(--ink-2); }
.field small { color: var(--muted); font-size: 11.5px; }
.input, select.input, textarea.input { width: 100%; border: 1px solid var(--line); background: var(--surface); border-radius: 8px; padding: 9px 11px; min-width: 0; }
.input:focus { border-color: var(--signal); outline: none; box-shadow: 0 0 0 3px var(--signal-soft); }
textarea.input { resize: vertical; min-height: 90px; }
.input.num { text-align: right; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip-check { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 20px; padding: 5px 11px; cursor: pointer; font-size: 12.5px; font-weight: 600; background: var(--surface); }
.chip-check input { display: none; }
.chip-check.on { background: var(--signal-soft); border-color: var(--signal); color: var(--signal); }

/* ── surfaces ── */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; min-width: 0; }
.card h3 { font-size: 15px; font-weight: 700; }
.card-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head .hint { color: var(--muted); font-size: 12.5px; }
.card-head .spacer { flex: 1; }
.eyebrow { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 600; }

/* KPI tiles: Actual · Target · % always together */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px 14px; display: flex; flex-direction: column; gap: 6px; min-width: 0; position: relative; overflow: hidden; }
.kpi .lab { font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: .02em; }
.kpi .val { font: 700 28px/1.1 var(--f-display); letter-spacing: -.02em; }
.kpi .tri { display: flex; gap: 14px; font-size: 12px; color: var(--muted); flex-wrap: wrap; }
.kpi .tri b { color: var(--ink-2); font-family: var(--f-mono); font-weight: 600; }
.meter { height: 6px; background: var(--none-soft); border-radius: 4px; position: relative; overflow: visible; margin-top: 4px; }
.meter i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 4px; background: var(--signal); }
.meter i.good { background: var(--good); } .meter i.warn { background: var(--warn); } .meter i.bad { background: var(--bad); }
.meter .pace { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--ink-2); border-radius: 1px; }
.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; padding: 2px 9px; border-radius: 20px; white-space: nowrap; }
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pill.good { background: var(--good-soft); color: var(--good); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.bad { background: var(--bad-soft); color: var(--bad); }
.pill.none { background: var(--none-soft); color: var(--none); }
.pill.info { background: var(--signal-soft); color: var(--signal); }
.pct-good { color: var(--good); } .pct-warn { color: var(--warn); } .pct-bad { color: var(--bad); } .pct-none { color: var(--none); }

/* market cards */
.markets { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.mcard { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.mcard .mh { display: flex; align-items: center; gap: 10px; }
.mcard .dot { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.mcard .mh b { font: 700 15px var(--f-display); }
.mcard .mh span { color: var(--muted); font-size: 12px; }
.mline { display: grid; grid-template-columns: 1fr auto auto auto; gap: 4px 12px; align-items: center; font-size: 12.5px; }
.mline .h { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.mline .n { text-align: right; font-family: var(--f-mono); }
.mline .p { text-align: right; font-weight: 700; font-family: var(--f-mono); }

/* tables */
.tbl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
.tbl th { text-align: left; font-size: 11.5px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; padding: 10px 12px; border-bottom: 1px solid var(--line); background: var(--surface-2); white-space: nowrap; position: sticky; top: 0; }
.tbl td { padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl th.n, .tbl td.n { text-align: right; }
.tbl tr.tot td { font-weight: 700; background: var(--surface-2); }
.tbl tr.click { cursor: pointer; } .tbl tr.click:hover td { background: var(--signal-soft); }
.tbl .grp td { background: var(--surface-2); font-weight: 700; font-size: 12px; color: var(--ink-2); }

/* tasks */
.board { display: grid; grid-template-columns: repeat(5, minmax(220px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 6px; }
.col { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r); padding: 10px; display: flex; flex-direction: column; gap: 8px; min-height: 120px; }
.col.drop { outline: 2px dashed var(--signal); }
.col-h { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 12.5px; padding: 2px 4px 6px; }
.col-h .cnt { margin-left: auto; font-family: var(--f-mono); color: var(--muted); font-weight: 500; }
.tcard { background: var(--surface); border: 1px solid var(--line); border-radius: 9px; padding: 11px 12px; cursor: pointer; display: flex; flex-direction: column; gap: 8px; position: relative; }
.tcard:hover { border-color: var(--signal); }
.tcard.overdue { border-left: 3px solid var(--bad); }
.tcard .tt { font-weight: 600; line-height: 1.35; }
.tcard .meta { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: 11.5px; color: var(--muted); }
.avs { display: flex; }
.avs .av { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font: 700 9.5px var(--f-display); color: #fff; border: 2px solid var(--surface); margin-left: -6px; background: var(--navy-2); }
.avs .av:first-child { margin-left: 0; }
.av.md { background: #17195A; } .av.cbco { background: #12A39A; } .av.cbeo { background: #2B7BE4; } .av.cbso { background: #C9831F; }
.prog { height: 4px; background: var(--none-soft); border-radius: 3px; overflow: hidden; } .prog i { display: block; height: 100%; background: var(--signal); }
.tag { font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 5px; background: var(--none-soft); color: var(--ink-2); white-space: nowrap; }
.tag.High { background: var(--bad-soft); color: var(--bad); } .tag.Medium { background: var(--warn-soft); color: var(--warn); } .tag.Low { background: var(--none-soft); color: var(--none); }
.desks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.desk { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; display: flex; flex-direction: column; gap: 12px; cursor: pointer; min-width: 0; }
.desk:hover { border-color: var(--signal); }
.desk .dh { display: flex; gap: 11px; align-items: center; }
.desk .dh .av { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; color: #fff; font: 700 13px var(--f-display); flex: none; }
.desk .dh b { display: block; font-size: 14px; line-height: 1.2; }
.desk .dh span { font-size: 11.5px; color: var(--muted); }
.desk .stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; text-align: center; }
.desk .stats div { background: var(--surface-2); border-radius: 7px; padding: 7px 2px; }
.desk .stats b { display: block; font: 700 18px var(--f-display); }
.desk .stats span { font-size: 10.5px; color: var(--muted); }
.desk .stats .alert b { color: var(--bad); }

/* drawer + modal */
.scrim { position: fixed; inset: 0; background: rgba(6,14,32,.45); z-index: 60; display: flex; justify-content: flex-end; }
.drawer { width: min(720px, 100%); height: 100%; background: var(--surface); overflow-y: auto; display: flex; flex-direction: column; box-shadow: -10px 0 40px rgba(0,0,0,.2); }
.drawer-h { padding: 18px 22px; border-bottom: 1px solid var(--line); display: flex; gap: 12px; align-items: flex-start; position: sticky; top: 0; background: var(--surface); z-index: 2; }
.drawer-h h2 { font-size: 19px; flex: 1; }
.drawer-b { padding: 18px 22px 30px; display: flex; flex-direction: column; gap: 18px; }
.modal-scrim { position: fixed; inset: 0; background: rgba(6,14,32,.5); z-index: 70; display: grid; place-items: center; padding: 16px; }
.modal { width: min(640px, 100%); max-height: 92vh; overflow-y: auto; background: var(--surface); border-radius: 14px; padding: 22px; display: flex; flex-direction: column; gap: 16px; box-shadow: 0 20px 60px rgba(0,0,0,.3); }
.modal h2 { font-size: 19px; }
.modal .actions { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 8px 14px; font-size: 13px; align-items: center; }
.kv > span { color: var(--muted); font-weight: 600; font-size: 12px; }
.timeline { display: flex; flex-direction: column; gap: 0; }
.ev { display: grid; grid-template-columns: 28px 1fr; gap: 10px; padding: 8px 0; position: relative; }
.ev::before { content: ""; position: absolute; left: 13px; top: 34px; bottom: -8px; width: 2px; background: var(--line); }
.ev:last-child::before { display: none; }
.ev .av { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; color: #fff; font: 700 10px var(--f-display); background: var(--navy-2); }
.ev .head { font-size: 12px; color: var(--muted); }
.ev .head b { color: var(--ink); }
.ev .body { margin-top: 3px; white-space: pre-wrap; overflow-wrap: anywhere; }
.ev.delivered .body { background: var(--good-soft); border-radius: 8px; padding: 8px 10px; }
.ev.returned .body { background: var(--warn-soft); border-radius: 8px; padding: 8px 10px; }
.files { display: flex; flex-direction: column; gap: 6px; }
.file { display: flex; gap: 10px; align-items: center; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; min-width: 0; }
.file .ic { width: 34px; height: 34px; border-radius: 7px; display: grid; place-items: center; font: 700 9.5px var(--f-mono); color: #fff; background: var(--navy-2); flex: none; text-transform: uppercase; }
.file .ic.pdf { background: #C63D37; } .file .ic.xls, .file .ic.xlsx, .file .ic.csv { background: #1D8F62; } .file .ic.doc, .file .ic.docx { background: #2B7BE4; } .file .ic.ppt, .file .ic.pptx { background: #C9831F; } .file .ic.img { background: #7D57C1; }
.file .fn { min-width: 0; flex: 1; } .file .fn a { font-weight: 600; overflow-wrap: anywhere; } .file .fn small { display: block; color: var(--muted); font-size: 11.5px; }
.drop-zone { border: 2px dashed var(--line); border-radius: 10px; padding: 16px; text-align: center; color: var(--muted); cursor: pointer; font-size: 13px; }
.drop-zone.over, .drop-zone:hover { border-color: var(--signal); color: var(--signal); background: var(--signal-soft); }
.upbar { height: 4px; background: var(--none-soft); border-radius: 3px; overflow: hidden; } .upbar i { display: block; height: 100%; background: var(--signal); width: 0; transition: width .2s; }

/* daily entry */
.entry-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.fgroup { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.fgroup.mine { border-color: var(--signal); box-shadow: 0 0 0 3px var(--signal-soft); }
.fgroup h4 { font-size: 13.5px; display: flex; gap: 8px; align-items: center; }
.fgroup h4 .pill { font-family: var(--f-body); }
.savebar { position: sticky; bottom: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 16px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; box-shadow: 0 -6px 20px rgba(14,35,78,.06); }
.cal { display: grid; grid-template-columns: 70px repeat(31, minmax(18px, 1fr)); gap: 3px; font-size: 10.5px; min-width: 760px; }
.cal .lbl { font-weight: 700; font-size: 12px; display: flex; align-items: center; }
.cal .d { aspect-ratio: 1; border-radius: 4px; background: var(--none-soft); display: grid; place-items: center; color: var(--muted); font-family: var(--f-mono); }
.cal .d.f { background: var(--good); color: #fff; } .cal .d.m { background: var(--bad-soft); color: var(--bad); } .cal .d.x { background: transparent; }
.cal .hd { text-align: center; color: var(--muted); font-family: var(--f-mono); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--muted); align-items: center; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.legend i.line { height: 2px; border-radius: 0; width: 16px; }
.legend i.dash { height: 0; border-top: 2px dashed var(--target); width: 16px; background: none; }

.chart-box { position: relative; height: 280px; }
.chart-box.tall { height: 340px; }
.chart-box.short { height: 200px; }
.empty { text-align: center; padding: 34px 16px; color: var(--muted); display: flex; flex-direction: column; gap: 10px; align-items: center; }
.empty b { color: var(--ink); font-size: 15px; font-family: var(--f-display); }
.note { font-size: 12px; color: var(--muted); }
.toast { position: fixed; bottom: max(20px, env(safe-area-inset-bottom, 0px)); left: 50%; transform: translateX(-50%); background: var(--ink); color: var(--surface); padding: 10px 18px; border-radius: 9px; font-weight: 600; z-index: 100; box-shadow: 0 10px 30px rgba(0,0,0,.25); max-width: calc(100% - 32px); }
.toast.err { background: var(--bad); color: #fff; }

/* login */
.login { min-height: 100%; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); }
.login .art { background: var(--navy); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.login .art canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .55; }
.login .art > * { position: relative; }
.login .art h1 { font: 800 clamp(30px, 4vw, 46px)/1.05 var(--f-display); letter-spacing: -.03em; max-width: 12ch; }
.login .art p { color: #AFC2E6; max-width: 44ch; }
.login .art .mk { display: flex; gap: 12px; align-items: center; }
.login .art .mk img { width: 52px; }
.login .art .mk b { font: 700 18px var(--f-display); display: block; }
.login .art .mk small { color: #8FB4F2; letter-spacing: .14em; text-transform: uppercase; font-size: 11px; }
.login .art .mkts { display: flex; gap: 22px; flex-wrap: wrap; font-size: 12px; color: #AFC2E6; }
.login .art .mkts b { display: block; color: #fff; font: 700 20px var(--f-display); }
.login .form { display: grid; place-items: center; padding: 32px max(16px, env(safe-area-inset-right, 0px)) 32px max(16px, env(safe-area-inset-left, 0px)); background: var(--surface); }
.login form { width: min(380px, 100%); display: flex; flex-direction: column; gap: 16px; }
.login form h2 { font-size: 24px; }
.login .err { color: var(--bad); font-size: 13px; min-height: 18px; }
.demo-logins { display: flex; flex-wrap: wrap; gap: 6px; }
.demo-logins button { all: unset; cursor: pointer; font-size: 12px; border: 1px solid var(--line); padding: 4px 10px; border-radius: 20px; }
.demo-logins button:hover { border-color: var(--signal); color: var(--signal); }

/* ── presentation ── */
.present { position: fixed; inset: 0; background: #050C1C; z-index: 90; display: flex; flex-direction: column; }
.present .stage-wrap { flex: 1; display: grid; place-items: center; padding: 18px; min-height: 0; }
.slide { width: 1280px; height: 720px; background: #fff; color: #0B1A33; position: relative; overflow: hidden; transform-origin: center; display: flex; flex-direction: column; padding: 46px 56px 34px; font-family: var(--f-body); --s-ink: #0B1A33; --s-muted: #5F6E87; --s-line: #DEE4EE; }
.slide .s-top { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.slide .s-top img { width: 38px; height: 38px; }
.slide .s-top .kick { font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: #1877B5; font-weight: 700; }
.slide .s-top h2 { font: 800 34px/1.05 var(--f-display); letter-spacing: -.02em; color: #17195A; }
.slide .s-top .asof { margin-left: auto; text-align: right; font-size: 12px; color: #5F6E87; }
.slide .s-foot { position: absolute; left: 56px; right: 56px; bottom: 18px; display: flex; justify-content: space-between; font-size: 11px; color: #8592A8; border-top: 1px solid #E6EAF1; padding-top: 8px; }
.slide .s-body { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 18px; padding-bottom: 26px; }
.slide.cover { background: #17195A; color: #fff; padding: 64px 72px; justify-content: space-between; }
.slide.cover h1 { font: 800 76px/1 var(--f-display); letter-spacing: -.035em; max-width: 13ch; }
.slide.cover .cv-mark { display: flex; align-items: center; gap: 16px; }
.slide.cover .cv-mark img { width: 64px; }
.slide.cover .cv-mark b { font: 700 22px var(--f-display); display: block; }
.slide.cover .cv-mark small { color: #8FB4F2; letter-spacing: .16em; text-transform: uppercase; font-size: 12px; }
.slide.cover .cv-meta { display: flex; gap: 48px; color: #AFC2E6; font-size: 15px; }
.slide.cover .cv-meta b { display: block; color: #fff; font: 700 30px var(--f-display); }
.slide.cover canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .5; }
.slide.cover > *:not(canvas) { position: relative; }
.s-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.s-kpi { border: 1px solid #DEE4EE; border-radius: 12px; padding: 18px 20px; display: flex; flex-direction: column; gap: 6px; }
.s-kpi .lab { font-size: 13px; font-weight: 600; color: #5F6E87; }
.s-kpi .val { font: 800 38px/1 var(--f-display); color: #17195A; letter-spacing: -.02em; }
.s-kpi .tri { display: flex; justify-content: space-between; font-size: 13px; color: #5F6E87; }
.s-kpi .tri b { color: #0B1A33; font-family: var(--f-mono); }
.s-kpi .big-p { font: 800 22px var(--f-mono); }
.slide table.tbl { font-size: 15px; } .slide .tbl th { font-size: 12px; background: #F4F7FB; color: #5F6E87; border-color: #DEE4EE; } .slide .tbl td { border-color: #E6EAF1; padding: 9px 12px; color: #0B1A33; }
.slide .tbl tr.tot td { background: #F4F7FB; }
.slide .pct-good { color: #1D8F62; } .slide .pct-warn { color: #B86E0E; } .slide .pct-bad { color: #C63D37; } .slide .pct-none { color: #7C879B; }
.slide .pill.good { background: #E3F4EC; color: #1D8F62; } .slide .pill.warn { background: #FBF0DF; color: #B86E0E; } .slide .pill.bad { background: #FBE7E6; color: #C63D37; } .slide .pill.none { background: #EEF1F6; color: #7C879B; }
.slide .legend { color: #5F6E87; }
.s-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; flex: 1; min-height: 0; }
.s-chart { position: relative; flex: 1; min-height: 0; }
.slide .note { color: #5F6E87; }
.present .pbar { display: flex; align-items: center; gap: 10px; padding: 10px 18px; color: #AFC2E6; flex-wrap: wrap; }
.present .pbar .btn { background: #13254A; border-color: #22396A; color: #E7EDF8; }
.present .pbar .btn.on { background: #2B7BE4; border-color: #2B7BE4; }
.present .dots { display: flex; gap: 5px; flex: 1; justify-content: center; flex-wrap: wrap; }
.present .dots button { all: unset; cursor: pointer; width: 9px; height: 9px; border-radius: 50%; background: #2A3D66; }
.present .dots button.on { background: #2597D6; width: 22px; border-radius: 5px; }

@media (max-width: 1180px) {
  .kpis, .desks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .markets { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; z-index: 80; width: 260px; left: 0; top: 0; transform: translateX(-105%); transition: transform .2s; padding-top: max(18px, env(safe-area-inset-top, 0px)); }
  .side.open { transform: none; box-shadow: 10px 0 40px rgba(0,0,0,.3); }
  .menu-btn { display: inline-flex; }
  .topbar { top: env(safe-area-inset-top, 0px); padding-left: max(16px, env(safe-area-inset-left, 0px)); }
  .content { padding-left: max(16px, env(safe-area-inset-left, 0px)); }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .login { grid-template-columns: 1fr; }
  .login .art { padding: 28px 20px; min-height: 260px; }
  .kv { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .kpis, .desks { grid-template-columns: 1fr; }
  .kpi .val { font-size: 24px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* print = export presentation to PDF (Firebase-hosted portal) */
@media print {
  @page { size: 1280px 720px; margin: 0; }
  body.printing > *:not(.print-root) { display: none !important; }
  .print-root .slide { transform: none !important; page-break-after: always; break-after: page; }
}

/* Slides are always printed-paper light, whatever the app theme */
.slide { --bg:#F1F4F9; --surface:#FFFFFF; --surface-2:#F4F7FB; --ink:#0B1A33; --ink-2:#33415C; --muted:#5F6E87; --line:#DEE4EE;
  --good:#1D8F62; --good-soft:#E3F4EC; --warn:#B86E0E; --warn-soft:#FBF0DF; --bad:#C63D37; --bad-soft:#FBE7E6; --none:#7C879B; --none-soft:#EEF1F6; --signal:#2B7BE4; --signal-soft:#E6F0FD; color-scheme: light; }
.slide .tbl-wrap { border-color: #DEE4EE; background: #fff; overflow: hidden; }
.slide .tbl th, .slide .tbl td { padding: 7px 10px; }
.slide .eyebrow { color: #5F6E87; }
span.av { display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 5px; border-radius: 12px; color: #fff; font: 700 9.5px var(--f-display); background: var(--navy-2); letter-spacing: .02em; }
.av.md { background: #17195A; } .av.cbco { background: #12A39A; } .av.cbeo { background: #2B7BE4; } .av.cbso { background: #C9831F; }
:root[data-theme="dark"] .av.md { background: #2B4A86; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .av.md { background: #2B4A86; } }
.avs .av { width: auto; min-width: 24px; padding: 0 5px; border-radius: 12px; }
.me .av { font-size: 10px; }
.s-cols > * { min-width: 0; }
.slide .tbl.compact { font-size: 13px; }
.slide .tbl.compact td, .slide .tbl.compact th { padding: 5px 8px; white-space: nowrap; }
.slide .tbl.compact th { font-size: 10.5px; letter-spacing: .04em; }

/* Bluekom logo sizing */
.brand img { width: 42px; height: 42px; }
.login .art .mk img { width: 58px; height: 58px; }
.login form .form-logo { width: 132px; height: auto; }
.slide .s-top img { width: 44px; height: 44px; }
.slide.cover .cv-mark img { width: 76px; height: 76px; }
.slide.cover .cv-logo { width: 230px; height: auto; }
#app { min-height: 100%; } .login { min-height: 100vh; }

/* ── Departments: snapshot-style parts ── */
.filterbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); position: sticky; top: 76px; z-index: 5; }
.part { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 20px; display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.part-h { display: flex; gap: 12px; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.part-h h2 { font-size: 22px; font-weight: 800; color: var(--ink); margin-top: 2px; }
.part-tiles { display: grid; grid-template-columns: minmax(0, 2fr) repeat(var(--n, 2), minmax(0, 1fr)); gap: 14px; }
.part-tiles .kpi.hero { background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 100%); border-color: transparent; color: #fff; }
.part-tiles .kpi.hero .lab, .part-tiles .kpi.hero .kv3 span { color: #B9C3E8; }
.part-tiles .kpi.hero .kv3 b { color: #fff; font-size: 30px; }
.part-tiles .kpi.hero .kv3 b.muted { color: #CBD3F0; }
.part-tiles .kpi.hero .meter { background: rgba(255,255,255,.16); }
.part-tiles .kpi.hero .pct-good { color: #5EE0A6; } .part-tiles .kpi.hero .pct-warn { color: #FFC56B; } .part-tiles .kpi.hero .pct-bad { color: #FF8F88; } .part-tiles .kpi.hero .pct-none { color: #B9C3E8; }
.kv3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 4px; }
.kv3 > div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.kv3 span, .kv2 span { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 600; }
.kv3 b { font: 700 20px/1.15 var(--f-display); letter-spacing: -.01em; overflow-wrap: anywhere; }
.kv3 b.muted, .muted { color: var(--muted); }
.part-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 22px; align-items: start; }
.mbars { display: flex; flex-direction: column; gap: 14px; }
.mbar { padding: 10px 12px; border-radius: 10px; border: 1px solid transparent; }
.mbar.on { border-color: var(--signal); background: var(--signal-soft); }
.mb-h { display: flex; align-items: center; gap: 8px; font-size: 13px; flex-wrap: wrap; }
.mb-h .dot { width: 10px; height: 10px; border-radius: 3px; }
.mb-h .mb-v { margin-left: auto; font-family: var(--f-mono); font-size: 12.5px; }
.mb-h > b.num { min-width: 46px; text-align: right; font-family: var(--f-mono); }
.mb-track { position: relative; height: 12px; background: var(--none-soft); border-radius: 6px; margin-top: 8px; }
.mb-track i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 6px; background: var(--signal); }
.mb-track i.good { background: var(--good); } .mb-track i.warn { background: var(--warn); } .mb-track i.bad { background: var(--bad); }
.mb-goal { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--ink); border-radius: 1px; }
.stage-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.stile { border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 10px; background: var(--surface-2); }
.stile .row b.num { font: 800 24px var(--f-display); }
.stile.st-done { background: var(--good-soft); border-color: var(--good); }
.stile.st-done .row b.num, .stile.st-done .kv2 b { color: var(--good); }
.kv2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.kv2 > div { display: flex; flex-direction: column; gap: 2px; }
.kv2 b { font: 700 15px var(--f-mono); }
/* pipeline table: won rows in green, stage select coloured */
.tbl tr.won td { background: var(--good-soft); }
.tbl tr.won td:first-child { box-shadow: inset 3px 0 0 var(--good); }
select.stage-sel.st-Done { background: var(--good); color: #fff; border-color: var(--good); }
select.stage-sel.st-Contract { background: var(--signal-soft); color: var(--signal); border-color: var(--signal); }
select.stage-sel.st-Quotation { background: var(--warn-soft); color: var(--warn); border-color: var(--warn); }
select.stage-sel.st-Lost { background: var(--bad-soft); color: var(--bad); border-color: var(--bad); }
/* slides */
.slide .part-tiles.slide-tiles { grid-template-columns: minmax(0, 2fr) repeat(var(--n, 2), minmax(0, 1fr)); }
.slide .kpi .val { font-size: 30px; }
.slide .part-tiles .kpi.hero { background: #17195A; }
.slide .kpi { border: 1px solid #DEE4EE; border-radius: 12px; padding: 14px 16px; background: #fff; }
.slide .kv3 b { font-size: 22px; } .slide .part-tiles .kpi.hero .kv3 b { font-size: 30px; }
.slide .mbar.on { border-color: transparent; background: transparent; }
.slide .mb-h { font-size: 15px; } .slide .mb-h .mb-v { font-size: 14px; }
.slide .mb-goal { background: #0B1A33; } .slide .mb-track { background: #EEF1F6; }
.slide .stile { background: #F7F9FC; border-color: #DEE4EE; }
.slide .stile.st-done { background: #E3F4EC; border-color: #1D8F62; }
.slide .stile.st-done .row b.num, .slide .stile.st-done .kv2 b { color: #1D8F62; }
.slide tr.won td { background: #E3F4EC; }
@media (max-width: 1100px) { .part-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } .part-tiles .kpi.hero { grid-column: 1 / -1; } .part-body { grid-template-columns: 1fr; } .stage-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .part-tiles { grid-template-columns: 1fr; }  .stage-tiles { grid-template-columns: 1fr; } .filterbar { position: static; } .kv3 b { font-size: 17px; } .part-tiles .kpi.hero .kv3 b { font-size: 22px; } }
.part-tiles .kpi.hero .kv3 { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1.25fr) minmax(0, .9fr); }
.part-tiles .kpi.hero .kv3 b { font-size: clamp(20px, 2vw, 30px); white-space: nowrap; }
.slide .part-tiles .kpi.hero .kv3 b { font-size: 30px; }
.fb-l { font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.mcard.sel { border-color: var(--signal); box-shadow: 0 0 0 3px var(--signal-soft); }

/* ── branded monthly deck ── */
.slide .sx-wrap { display: grid; grid-template-columns: 1.05fr 1fr; gap: 18px; }
.slide .sx-hero { background: linear-gradient(135deg, #17195A 0%, #262F7E 100%); color: #fff; border-radius: 16px; padding: 22px 26px; display: flex; flex-direction: column; gap: 6px; position: relative; overflow: hidden; }
.slide .sx-hero::after { content: ""; position: absolute; right: -60px; top: -60px; width: 200px; height: 200px; border-radius: 50%; background: radial-gradient(circle, rgba(37,151,214,.35), transparent 70%); }
.slide .sx-h-t { font: 700 20px var(--f-display); }
.slide .sx-h-sub { font-size: 13px; color: #9FB0E0; letter-spacing: .04em; }
.slide .sx-h-p { font: 800 88px/1 var(--f-display); letter-spacing: -.04em; margin-top: 6px; }
.slide .sx-hero.sm .sx-h-p { font-size: 56px; }
.slide .sx-h-l { font-size: 14px; color: #B9C3E8; margin-top: -2px; }
.slide .sx-h-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 10px; }
.slide .sx-h-row span { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; color: #9FB0E0; font-weight: 600; }
.slide .sx-h-row b { font: 700 30px var(--f-display); }
.slide .sx-hero.sm .sx-h-row b { font-size: 22px; }
.slide .sx-h-note { font-size: 13px; color: #FFC56B; }
.slide .sx-hero .pct-good { color: #5EE0A6; } .slide .sx-hero .pct-warn { color: #FFC56B; } .slide .sx-hero .pct-bad { color: #FF8F88; } .slide .sx-hero .pct-none { color: #B9C3E8; }
.slide .sx-bar { height: 10px; background: #E9EDF4; border-radius: 6px; overflow: hidden; margin-top: 8px; }
.slide .sx-hero .sx-bar { background: rgba(255,255,255,.15); }
.slide .sx-bar i { display: block; height: 100%; border-radius: 6px; background: #1877B5; }
.slide .sx-bar i.good { background: #1D8F62; } .slide .sx-bar i.warn { background: #D98C1C; } .slide .sx-bar i.bad { background: #D2453F; }
.slide .sx-hero .sx-bar i.good { background: #5EE0A6; } .slide .sx-hero .sx-bar i.warn { background: #FFC56B; } .slide .sx-hero .sx-bar i.bad { background: #FF8F88; }
.slide .sx-mks { display: flex; flex-direction: column; gap: 12px; }
.slide .sx-mk { border: 1px solid #DEE4EE; border-radius: 14px; padding: 14px 18px; flex: 1; display: flex; flex-direction: column; justify-content: center; }
.slide .sx-mk-h { display: flex; align-items: center; gap: 10px; }
.slide .sx-mk-h b { font: 700 19px var(--f-display); color: #17195A; }
.slide .sx-mk-p { margin-left: auto; font: 800 34px var(--f-display); }
.slide .sx-dot { width: 12px; height: 12px; border-radius: 4px; flex: none; display: inline-block; }
.slide .sx-mk-r { display: flex; gap: 22px; font-size: 15px; color: #5F6E87; margin-top: 2px; }
.slide .sx-mk-r b { color: #0B1A33; font-family: var(--f-mono); }
.slide .sx-na { color: #B86E0E; font-weight: 600; }
.slide .sx-segs { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 12px; align-items: stretch; grid-auto-flow: column; }
.slide .sx-segs-t { grid-column: 1 / -1; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #5F6E87; }
.slide .sx-segs { grid-auto-flow: row; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); }
.slide .sx-seg { border: 1px solid #DEE4EE; border-radius: 12px; padding: 10px 14px; display: grid; grid-template-columns: 1fr auto; gap: 0 10px; align-items: baseline; }
.slide .sx-seg > span { grid-column: 1 / -1; font-size: 13px; font-weight: 600; color: #5F6E87; }
.slide .sx-seg b { font: 700 22px var(--f-display); color: #17195A; }
.slide .sx-seg em { grid-column: 1; font-style: normal; font-size: 12.5px; color: #5F6E87; }
.slide .sx-seg strong { grid-column: 2; grid-row: 2 / 4; font: 800 26px var(--f-display); align-self: center; }
.slide .sx-seg .sx-bar { grid-column: 1 / -1; }
.slide .sx-score, .slide .sx-depts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.slide .sx-depts .sx-hero { min-height: 330px; justify-content: center; }
.slide .sx-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.slide .sx-strip-i { border: 1px solid #DEE4EE; border-radius: 14px; padding: 16px 18px; display: grid; grid-template-columns: auto 1fr auto; gap: 4px 10px; align-items: center; }
.slide .sx-strip-i b { font: 700 18px var(--f-display); color: #17195A; }
.slide .sx-strip-i span:not(.sx-dot) { grid-column: 1 / 3; font-size: 14px; color: #5F6E87; }
.slide .sx-strip-i strong { grid-row: 1 / 3; grid-column: 3; font: 800 38px var(--f-display); }
.slide .sx-matrix { display: grid; grid-template-columns: 210px repeat(var(--c), minmax(0, 1fr)); gap: 12px; align-items: stretch; }
.slide .sx-mx-h { font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #5F6E87; padding: 0 4px; align-self: end; }
.slide .sx-mx-m { display: flex; align-items: center; gap: 10px; font: 700 18px var(--f-display); color: #17195A; }
.slide .sx-mx-c { border: 1px solid #DEE4EE; border-radius: 14px; padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; }
.slide .sx-mx-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.slide .sx-mx-top b { font: 700 24px var(--f-display); color: #0B1A33; }
.slide .sx-mx-top strong { font: 800 28px var(--f-display); }
.slide .sx-mx-c > span { font-size: 13px; color: #5F6E87; }
.slide .sx-score .sx-hero { min-height: 330px; justify-content: center; }
.slide .sx-score .sx-h-p, .slide .sx-depts .sx-h-p { font-size: 76px; }
.slide .sx-score .sx-h-row b, .slide .sx-depts .sx-h-row b { font-size: 26px; }
.slide .sx-depts .sx-hero { min-height: 470px; }
.slide .sx-strip-i { padding: 22px 22px; }
.slide .sx-mx-c { padding: 20px 18px; gap: 6px; }
.slide .sx-matrix { row-gap: 16px; }
.slide .sx-seg.won { background: #E3F4EC; border-color: #1D8F62; } .slide .sx-seg.won b { color: #1D8F62; }

/* ── reminders & notifications ── */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.pill svg { width: 12px; height: 12px; }
.pill:has(svg)::before { display: none; }
.bell { position: relative; padding: 8px 10px; }
.bell svg { width: 19px; height: 19px; }
.bell.has svg { animation: bell-ring 1.4s ease 1; transform-origin: 50% 10%; }
@keyframes bell-ring { 0%,100% { transform: rotate(0); } 15% { transform: rotate(14deg); } 30% { transform: rotate(-12deg); } 45% { transform: rotate(8deg); } 60% { transform: rotate(-5deg); } }
@media (prefers-reduced-motion: reduce) { .bell.has svg { animation: none; } }
.bell-n { position: absolute; top: 2px; right: 2px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--signal); color: #fff; font-size: 10.5px; font-weight: 700; display: grid; place-items: center; border: 2px solid var(--surface); }
.bell-n.alert { background: var(--bad); }
.bell-pop { position: fixed; top: 64px; right: max(12px, env(safe-area-inset-right, 0px)); width: min(400px, calc(100vw - 24px)); max-height: min(72vh, 620px); overflow-y: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 18px 50px rgba(15, 20, 60, .22); z-index: 60; padding: 6px 6px 10px; }
.bp-h { display: flex; justify-content: space-between; align-items: center; padding: 8px 10px 4px; position: sticky; top: -6px; background: var(--surface); z-index: 1; }
.bp-h b { font-size: 15px; }
.bp-sec { display: flex; justify-content: space-between; align-items: center; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 12px 10px 6px; }
.bp-link { background: none; border: 0; color: var(--signal); font-weight: 600; font-size: 12px; cursor: pointer; text-transform: none; letter-spacing: 0; }
.bp-i { display: flex; gap: 10px; align-items: flex-start; width: 100%; text-align: left; background: none; border: 0; border-radius: 10px; padding: 9px 10px; cursor: pointer; color: var(--ink); position: relative; }
.bp-i:hover { background: var(--surface-2); }
.bp-i.nw { background: var(--signal-soft); }
.bp-i.rd { opacity: .78; }
.bp-ic { flex: none; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--none-soft); color: var(--none); }
.bp-ic svg { width: 16px; height: 16px; }
.bp-ic.meeting { background: var(--signal-soft); color: var(--signal); }
.bp-ic.task, .bp-ic.assigned { background: rgba(23, 25, 90, .08); color: var(--navy); }
.bp-ic.approved, .bp-ic.review { background: var(--good-soft); color: var(--good); }
.bp-ic.returned { background: var(--warn-soft); color: var(--warn); }
.bp-i.od .bp-ic { background: var(--bad-soft); color: var(--bad); }
.bp-i.ur .bp-ic { background: var(--warn-soft); color: var(--warn); }
.bp-i.od small { color: var(--bad); font-weight: 600; }
.bp-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.bp-t b { font-size: 13.5px; font-weight: 600; overflow-wrap: anywhere; }
.bp-t small { font-size: 12px; color: var(--muted); }
.bp-dot { position: absolute; right: 10px; top: 14px; width: 8px; height: 8px; border-radius: 50%; background: var(--signal); }
.bp-empty, .bp-note { font-size: 12.5px; color: var(--muted); padding: 6px 10px 8px; }
.bp-perm { display: flex; gap: 10px; align-items: center; width: calc(100% - 8px); margin: 4px; text-align: left; border: 1px dashed var(--signal); background: var(--signal-soft); color: var(--ink); border-radius: 10px; padding: 10px 12px; cursor: pointer; }
.bp-perm svg { width: 18px; height: 18px; color: var(--signal); flex: none; }
.bp-perm span { display: flex; flex-direction: column; } .bp-perm small { color: var(--muted); font-size: 12px; }
#bk-alerts { position: fixed; top: 74px; right: max(14px, env(safe-area-inset-right, 0px)); z-index: 90; display: flex; flex-direction: column; gap: 10px; width: min(360px, calc(100vw - 28px)); pointer-events: none; }
.bk-alert { pointer-events: auto; display: flex; gap: 12px; align-items: flex-start; background: linear-gradient(135deg, #17195A, #262F7E); color: #fff; border-radius: 14px; padding: 13px 14px; box-shadow: 0 16px 40px rgba(15, 20, 60, .35); animation: bk-in .35s ease; border-left: 4px solid #2597D6; }
.bk-alert.due { border-left-color: #FFC56B; } .bk-alert.meeting { border-left-color: #5EE0A6; }
@keyframes bk-in { from { transform: translateY(-10px); opacity: 0; } }
.bk-a-ic { flex: none; width: 32px; height: 32px; border-radius: 10px; background: rgba(255,255,255,.12); display: grid; place-items: center; }
.bk-a-ic svg { width: 17px; height: 17px; }
.bk-a-tx { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; }
.bk-a-tx b { font-size: 14px; overflow-wrap: anywhere; } .bk-a-tx span { font-size: 12.5px; color: #C9D2F2; }
.bk-a-x { background: none; border: 0; color: #C9D2F2; cursor: pointer; padding: 2px; } .bk-a-x svg { width: 15px; height: 15px; }

/* scheduled meetings */
.sc-card { margin-bottom: 18px; display: flex; flex-direction: column; gap: 4px; }
.sc-row { display: grid; grid-template-columns: 62px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px 6px; border-top: 1px solid var(--line); border-radius: 10px; transition: background .2s; }
.sc-row.hl { background: var(--signal-soft); }
.sc-row.live { background: var(--good-soft); }
.sc-row.skip { opacity: .55; } .sc-row.skip .sc-t b { text-decoration: line-through; }
.sc-date { display: flex; flex-direction: column; align-items: center; background: linear-gradient(160deg, #17195A, #262F7E); color: #fff; border-radius: 12px; padding: 7px 0 8px; line-height: 1.05; }
.sc-date small { font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; color: #9FD3F2; font-weight: 700; }
.sc-date b { font-size: 24px; font-family: var(--f-display); } .sc-date span { font-size: 11.5px; color: #C9D2F2; }
.sc-main { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.sc-t { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; } .sc-t b { font-size: 15px; }
.sc-m { display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: center; font-size: 12.5px; color: var(--muted); }
.sc-m svg { width: 13px; height: 13px; vertical-align: -2px; }
.sc-rel { font-weight: 600; color: var(--ink-2); } .sc-rel.soon { color: var(--warn); } .sc-rel.now { color: var(--good); }
.sc-act { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.sc-series { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; border-top: 1px solid var(--line); padding-top: 12px; margin-top: 4px; }
.sc-series .eyebrow { margin-right: 4px; }
.sc-chip { display: inline-flex; gap: 7px; align-items: center; border: 1px solid var(--line); background: var(--surface-2); border-radius: 20px; padding: 5px 12px; font-size: 12.5px; color: var(--ink); cursor: pointer; }
.sc-chip svg { width: 14px; height: 14px; color: var(--signal); } .sc-chip span { color: var(--muted); }
.sec-h { display: flex; align-items: baseline; gap: 10px; margin: 6px 0 10px; } .sec-h h3 { font-size: 16px; }
@media (max-width: 640px) {
  .sc-row { grid-template-columns: 54px minmax(0, 1fr); }
  .sc-act { grid-column: 1 / -1; justify-content: flex-start; }
  #bk-alerts { top: auto; bottom: 16px; right: 14px; }
}
.ov-meets { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 10px; }
.ov-meet { display: flex; flex-direction: column; gap: 5px; align-items: flex-start; text-align: left; border: 1px solid var(--line); border-left: 4px solid var(--signal); background: var(--surface-2); border-radius: 10px; padding: 11px 13px; cursor: pointer; color: var(--ink); }
.ov-meet:hover { border-color: var(--signal); }
.ov-meet b { font-size: 14px; overflow-wrap: anywhere; } .ov-meet .mono { font-size: 12.5px; }
@media (max-width: 900px) { .topbar .bell { position: absolute; top: 10px; right: max(12px, env(safe-area-inset-right, 0px)); } }
/* presentation stage: slide centred absolutely so phones in portrait show it (grid centring pushed it off-screen) */
.present .stage-wrap { position: relative; display: block; overflow: hidden; }
.present .stage-wrap > .slide { position: absolute; left: 50%; top: 50%; transform-origin: center center; }

/* ── phones: compact sticky header, presentation controls that fit ── */
@media (max-width: 640px) {
  .topbar { gap: 6px 8px; padding: 8px 52px 8px 10px; align-items: center; }
  .topbar > div:not(.spacer) { min-width: 0; flex: 1 1 auto; }
  .topbar h1 { font-size: 17px; line-height: 1.25; }
  .topbar .sub { display: none; }
  .topbar .spacer { display: none; }
  .topbar .btn { padding: 6px 10px; font-size: 12.5px; }
  .topbar .btn svg { width: 14px; height: 14px; }
  .topbar .bell { top: 6px; }
  .present .pbar { gap: 6px; padding: 8px 10px max(8px, env(safe-area-inset-bottom, 0px)); justify-content: center; }
  .present .pbar .dots { display: none; }
  .present .pbar .btn { padding: 7px 10px; }
}
@media (max-width: 900px) and (orientation: landscape) {
  .present .pbar { padding: 4px 8px; gap: 4px; }
  .present .pbar .dots { display: none; }
  .present .pbar .btn { padding: 5px 8px; font-size: 12px; }
  .present .stage-wrap { padding: 4px; }
}
.p-rotate { display: none; }
@media (max-width: 640px) and (orientation: portrait) {
  .p-rotate { display: flex; position: absolute; left: 0; right: 0; bottom: 14px; justify-content: center; gap: 8px; align-items: center; color: #9FB3D9; font-size: 13px; pointer-events: none; }
  .p-rotate svg { width: 16px; height: 16px; }
}
@media (max-width: 640px) {
  .filterbar .seg { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
  .filterbar .seg button { text-align: center; }
}
@media (max-width: 640px) {
  .board { grid-template-columns: 1fr; overflow-x: visible; }
  .board .col:not(:has(.tcard)) { padding-bottom: 4px; }
  .board .col:not(:has(.tcard)) .note { display: none; }
}

/* ═════════ Bluekom Enterprise components ═════════ */
.muted { color: var(--muted); }
.x-grid { display: grid; gap: 14px; }
.x-heros { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.x-hero { background: linear-gradient(135deg, #17195A 0%, #262F7E 100%); color: #fff; border-radius: 16px; padding: 18px 22px 16px; display: flex; flex-direction: column; gap: 4px; position: relative; overflow: hidden; min-width: 0; }
.x-hero::after { content: ""; position: absolute; right: -50px; top: -60px; width: 180px; height: 180px; border-radius: 50%; background: radial-gradient(circle, rgba(37,151,214,.35), transparent 70%); pointer-events: none; }
.x-h-t { font-weight: 700; font-size: 14px; }
.x-h-s { font-size: 11.5px; color: #B9C3E8; }
.x-h-p { font-family: var(--f-display); font-size: 46px; font-weight: 800; line-height: 1.05; margin-top: 4px; }
.x-h-r { display: flex; gap: 22px; flex-wrap: wrap; }
.x-h-r span { display: block; font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: #9FB0E0; }
.x-h-r b { font-family: var(--f-mono); font-size: 19px; }
.x-hero .x-bar { background: rgba(255,255,255,.15); margin-top: 8px; }
.x-hero .pct-good { color: #5EE0A6; } .x-hero .pct-warn { color: #FFC56B; } .x-hero .pct-bad { color: #FF8F88; } .x-hero .pct-none { color: #B9C3E8; }
.x-hero .x-bar i.good { background: #5EE0A6; } .x-hero .x-bar i.warn { background: #FFC56B; } .x-hero .x-bar i.bad { background: #FF8F88; }
.x-bar { height: 7px; border-radius: 4px; background: var(--none-soft); overflow: hidden; }
.x-bar i { display: block; height: 100%; border-radius: 4px; background: var(--none); }
.x-bar i.good { background: var(--good); } .x-bar i.warn { background: var(--warn); } .x-bar i.bad { background: var(--bad); }
.x-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; }
.x-tile { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; box-shadow: var(--shadow); min-width: 0; }
.x-t-h { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.x-t-h strong { font-size: 18px; font-family: var(--f-display); }
.x-t-v { font-family: var(--f-display); font-size: 24px; font-weight: 800; }
.x-t-r { font-size: 12px; color: var(--muted); } .x-t-r b { color: var(--ink-2); font-family: var(--f-mono); }
.x-t-n { font-size: 11.5px; color: var(--muted); }
.x-mks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.x-mk { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.x-mk-h { display: flex; align-items: center; gap: 8px; } .x-mk-h b { flex: 1; } .x-mk-h strong { font-family: var(--f-display); font-size: 20px; }
.x-mk-r { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--muted); flex-wrap: wrap; } .x-mk-r b { color: var(--ink-2); font-family: var(--f-mono); }
.x-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; flex: none; vertical-align: 0; }
.pct-good { color: var(--good); } .pct-warn { color: var(--warn); } .pct-bad { color: var(--bad); } .pct-none { color: var(--none); }
.x-sec { display: flex; align-items: baseline; gap: 10px; margin: 22px 0 10px; flex-wrap: wrap; } .x-sec h2 { font-size: 18px; } .x-sec .note { flex: 1; }
.x-two { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 14px; }
.x-three { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.x-chart { position: relative; height: 270px; }
.x-list { display: flex; flex-direction: column; }
.x-li { display: flex; gap: 10px; align-items: flex-start; padding: 9px 2px; border-top: 1px solid var(--line); }
.x-li:first-child { border-top: 0; }
.x-li .x-li-b { flex: 1; min-width: 0; } .x-li b { overflow-wrap: anywhere; } .x-li small { display: block; color: var(--muted); font-size: 12px; }
.x-chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; background: var(--none-soft); color: var(--ink-2); border: 1px solid transparent; }
.x-count { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; }
.x-cnt { border-radius: 12px; padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); cursor: pointer; text-align: left; color: var(--ink); }
.x-cnt b { display: block; font-family: var(--f-display); font-size: 24px; } .x-cnt span { font-size: 12px; color: var(--muted); font-weight: 600; } .x-cnt small { display: block; font-family: var(--f-mono); color: var(--muted); font-size: 12px; }
.x-cnt.on { border-color: var(--signal); box-shadow: 0 0 0 3px var(--signal-soft); }
.x-cnt.good { border-left: 4px solid var(--good); } .x-cnt.warn { border-left: 4px solid var(--warn); } .x-cnt.bad { border-left: 4px solid var(--bad); } .x-cnt.none { border-left: 4px solid var(--none); }
select.st-sel { border-radius: 20px; padding: 3px 26px 3px 10px; font-size: 12.5px; font-weight: 700; border: 1px solid var(--line); background-color: var(--none-soft); max-width: 170px; }
select.st-sel.good { background-color: var(--good-soft); color: var(--good); border-color: color-mix(in srgb, var(--good) 35%, transparent); }
select.st-sel.warn { background-color: var(--warn-soft); color: var(--warn); border-color: color-mix(in srgb, var(--warn) 35%, transparent); }
select.st-sel.bad { background-color: var(--bad-soft); color: var(--bad); border-color: color-mix(in srgb, var(--bad) 35%, transparent); }
.x-online { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; color: var(--good); }
.x-online::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--good); box-shadow: 0 0 0 3px var(--good-soft); }
.tbl td.wrap { white-space: normal; min-width: 160px; }
.tbl tr.dim td { opacity: .55; }
.tbl tr.flag td { background: var(--bad-soft); }
.tbl th.n, .tbl td.n { text-align: right; }
.x-rank { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--none-soft); font-weight: 700; font-size: 12px; }
.x-rank.r1 { background: #F5D36B; color: #4A3500; } .x-rank.r2 { background: #D9DEE8; color: #333; } .x-rank.r3 { background: #E8B98A; color: #4A2600; }
.x-day { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.x-am { border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; background: var(--surface); display: flex; flex-direction: column; gap: 2px; }
.x-am b { font-size: 13px; } .x-am span { font-size: 12px; color: var(--muted); }
.x-am.ok { border-left: 4px solid var(--good); } .x-am.no { border-left: 4px solid var(--bad); background: var(--bad-soft); } .x-am.off { border-left: 4px solid var(--signal); opacity: .8; }
.x-ext { font-size: 12px; color: var(--warn); font-weight: 600; }
.x-plan-g { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--surface); }
.x-plan-h { background: var(--navy); color: #fff; padding: 8px 14px; display: flex; justify-content: space-between; gap: 8px; align-items: center; font-weight: 700; }
.x-plan-h small { color: #B9C3E8; font-weight: 500; }
.x-plan-k { background: var(--surface-2); padding: 5px 14px; font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); border-top: 1px solid var(--line); }
.x-plan-i { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 8px; align-items: center; padding: 6px 14px; border-top: 1px solid var(--line); }
.x-plan-i .num { color: var(--muted); font-size: 12px; }
.x-plan-i.done b { text-decoration: line-through; color: var(--muted); }
.x-plan-i input.input { padding: 4px 8px; font-size: 12.5px; }
@media (max-width: 1100px) { .x-heros { grid-template-columns: 1fr 1fr; } .x-two, .x-three { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .x-heros, .x-mks { grid-template-columns: 1fr; } .x-h-p { font-size: 40px; } .x-plan-i { grid-template-columns: 22px minmax(0, 1fr); } .x-plan-i > :last-child { grid-column: 2; } }
@media (max-width: 640px) { .tbl .hs { display: none; } }
/* slides keep their desktop layout at any screen size */
.slide .x-heros { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; gap: 16px; }
.slide .x-mks { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
.slide .x-tiles { display: grid; gap: 14px; }
.slide .x-h-p { font-size: 52px !important; }
.slide .x-tile { box-shadow: none; padding: 14px 16px; }
.slide .x-t-v { font-size: 26px; }
.slide .tbl .hs { display: table-cell !important; }
.x-crit { border-left: 4px solid var(--bad); cursor: pointer; text-align: left; font: inherit; color: inherit; }
/* individual performance cards */
.pc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 14px; }
.pc { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; border-top: 4px solid var(--navy-2); }
.pc-h { display: flex; align-items: center; gap: 10px; }
.pc-n { flex: 1; min-width: 0; display: flex; flex-direction: column; } .pc-n b { font-size: 15px; overflow-wrap: anywhere; } .pc-n span { font-size: 12px; color: var(--muted); }
.pc-p { font-family: var(--f-display); font-weight: 800; font-size: 30px; }
.pc-tot { display: flex; align-items: baseline; gap: 8px; } .pc-tot span { font-size: 12px; color: var(--muted); font-weight: 600; flex: 1; } .pc-tot b { font-family: var(--f-mono); font-size: 18px; } .pc-tot small { color: var(--muted); font-family: var(--f-mono); }
.pc-ms { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; margin-top: 4px; }
.pc-m { background: var(--surface-2); border-radius: 10px; padding: 8px 10px; display: flex; flex-direction: column; gap: 3px; }
.pc-m-h { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); font-weight: 600; } .pc-m-v { font-family: var(--f-mono); font-weight: 600; } .pc-m-v small { color: var(--muted); font-weight: 400; }
.pc-m .x-bar { height: 5px; }
.pc-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.pc-chip { font-size: 11.5px; padding: 3px 8px; border-radius: 12px; background: var(--none-soft); color: var(--ink-2); } .pc-chip b { font-family: var(--f-mono); }
.pc-chip.good { background: var(--good-soft); color: var(--good); } .pc-chip.bad { background: var(--bad-soft); color: var(--bad); } .pc-chip.warn { background: var(--warn-soft); color: var(--warn); }
.pc-a { display: flex; gap: 8px; justify-content: flex-end; margin-top: 2px; }
@media (max-width: 640px) { .pc-grid { grid-template-columns: 1fr; } }
/* months */
.mo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.mo-card { all: unset; box-sizing: border-box; cursor: pointer; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; box-shadow: var(--shadow); color: var(--ink); }
.mo-card:hover, .mo-card:focus-visible { border-color: var(--signal); }
.mo-card.cur { border: 2px solid var(--signal); box-shadow: 0 0 0 3px var(--signal-soft); }
.mo-card.planned { background: var(--surface-2); }
.mo-h { display: flex; justify-content: space-between; align-items: center; } .mo-h b { font-family: var(--f-display); font-size: 16px; }
.mo-p { font-family: var(--f-display); font-weight: 800; font-size: 30px; line-height: 1; }
.mo-r { display: flex; justify-content: space-between; gap: 6px; font-size: 11.5px; color: var(--muted); } .mo-r b { font-family: var(--f-mono); color: var(--ink-2); }
.mo-mk { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); } .mo-mk span { display: inline-flex; gap: 4px; align-items: center; } .mo-mk .x-dot { width: 8px; height: 8px; }
/* difference (Actual − Target) */
.pc-m-d { font-size: 11px; color: var(--muted); margin-top: 1px; } .pc-m-d b { font-family: var(--f-mono); }
.x-t-r b.pct-good, .x-mk-r b.pct-good, .mo-r b.pct-good, .pc-m-d b.pct-good, .tri b.pct-good { color: var(--good); }
.x-t-r b.pct-bad, .x-mk-r b.pct-bad, .mo-r b.pct-bad, .pc-m-d b.pct-bad, .tri b.pct-bad { color: var(--bad); }
.x-h-r b.pct-good { color: #5BE0A0; } .x-h-r b.pct-bad { color: #FF8A8A; }
.mo-r { flex-wrap: wrap; }

/* ── AI analyst chat ── */
.content[data-view="ai"] { padding-bottom: 14px; }
.ai-wrap { display: flex; flex-direction: column; height: calc(100dvh - 150px); min-height: 440px; width: 100%; max-width: 1000px; margin: 0 auto; }
.ai-log { flex: 1; overflow-y: auto; padding: 4px 2px 18px; display: flex; flex-direction: column; gap: 18px; overscroll-behavior: contain; }
.ai-msg { display: flex; gap: 10px; align-items: flex-start; min-width: 0; }
.ai-msg.me { justify-content: flex-end; }
.ai-msg.me .ai-b { background: var(--navy); color: #fff; border-radius: 16px 16px 4px 16px; padding: 10px 14px; max-width: 78%; overflow-wrap: anywhere; }
.ai-msg.bot .ai-b { background: var(--surface); border: 1px solid var(--line); border-radius: 4px 16px 16px 16px; padding: 12px 16px; flex: 1; min-width: 0; box-shadow: var(--shadow); line-height: 1.55; }
.ai-msg.err .ai-b { background: var(--bad-soft); border-color: transparent; color: var(--ink); }
.ai-av { width: 32px; height: 32px; border-radius: 10px; background: linear-gradient(135deg, #17195A, #2597D6); color: #fff; display: grid; place-items: center; flex: none; }
.ai-av svg { width: 18px; height: 18px; }
.ai-b p { margin: 0 0 8px; } .ai-b > :last-child { margin-bottom: 0; }
.ai-b h3, .ai-b h4, .ai-b h5 { margin: 14px 0 6px; font: 700 15px/1.3 var(--f-display); } .ai-b h3 { font-size: 17px; } .ai-b > h3:first-child, .ai-b > h4:first-child { margin-top: 0; }
.ai-b ul, .ai-b ol { margin: 4px 0 10px; padding-left: 22px; } .ai-b li { margin: 3px 0; } .ai-b li.sub { margin-left: 18px; list-style-type: circle; }
.ai-b code { font-family: var(--f-mono); font-size: .9em; background: var(--surface-2); padding: 1px 5px; border-radius: 5px; }
.ai-b pre { background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; overflow-x: auto; font-size: 12.5px; } .ai-b pre code { background: none; padding: 0; }
.ai-b blockquote { margin: 6px 0 10px; padding: 4px 12px; border-left: 3px solid var(--sky); color: var(--ink-2); }
.ai-b hr { border: 0; border-top: 1px solid var(--line); margin: 12px 0; }
.ai-b a { color: var(--signal); }
.ai-tbl { margin: 8px 0 12px; border: 1px solid var(--line); border-radius: 10px; }
.ai-tbl td.neg { color: var(--bad); font-weight: 700; } .ai-tbl td.pos { color: var(--good); font-weight: 700; }
.ai-chart { margin: 10px 0 12px; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; background: var(--surface); }
.ai-chart.wait { color: var(--muted); font-size: 13px; }
.ai-ct { font-weight: 700; font-size: 13.5px; margin-bottom: 6px; }
.ai-cv { position: relative; height: 290px; }
.ai-tools { margin-top: 8px; display: flex; gap: 6px; }
.ai-typing { display: inline-flex; gap: 4px; padding: 4px 0; } .ai-typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: aiDot 1.2s infinite ease-in-out; } .ai-typing i:nth-child(2) { animation-delay: .15s; } .ai-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes aiDot { 0%, 80%, 100% { opacity: .25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
@media (prefers-reduced-motion: reduce) { .ai-typing i { animation: none; opacity: .6; } }
.ai-ask { display: flex; gap: 8px; align-items: flex-end; border: 1px solid var(--line); background: var(--surface); border-radius: 16px; padding: 8px 8px 8px 14px; box-shadow: var(--shadow); }
.ai-ask:focus-within { border-color: var(--sky); }
.ai-ask textarea { flex: 1; border: 0; outline: 0; resize: none; background: transparent; font: inherit; font-size: 15px; color: var(--ink); max-height: 180px; padding: 8px 0; min-width: 0; }
.ai-ask .btn { border-radius: 12px; width: 42px; height: 42px; padding: 0; justify-content: center; flex: none; } .ai-ask .btn svg { width: 19px; height: 19px; }
.ai-ask .btn.stop { background: var(--ink-2); border-color: var(--ink-2); }
.ai-foot { display: flex; justify-content: space-between; gap: 4px 14px; flex-wrap: wrap; font-size: 11.5px; color: var(--muted); padding: 7px 4px 0; }
.ai-hello { margin: auto 0; text-align: center; padding: 20px 6px; }
.ai-hello h2 { font: 700 24px/1.2 var(--f-display); margin: 12px 0 6px; } .ai-hello .note { max-width: 560px; margin: 0 auto; }
.ai-badge { width: 54px; height: 54px; border-radius: 16px; margin: 0 auto; background: linear-gradient(135deg, #17195A, #2597D6); color: #fff; display: grid; place-items: center; } .ai-badge svg { width: 28px; height: 28px; }
.ai-sugs { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 8px; margin-top: 18px; text-align: left; }
.ai-sug { border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 11px 13px; font: inherit; font-size: 13px; line-height: 1.4; color: var(--ink-2); cursor: pointer; text-align: left; }
.ai-sug:hover, .ai-sug:focus-visible { border-color: var(--sky); color: var(--ink); }
@media (max-width: 620px) {
  .ai-wrap { height: calc(100dvh - 118px); min-height: 360px; }
  .ai-av { display: none; } .ai-msg.me .ai-b { max-width: 90%; } .ai-msg.bot .ai-b { padding: 10px 12px; }
  .ai-hello h2 { font-size: 20px; } .ai-sugs { grid-template-columns: 1fr; } .ai-cv { height: 240px; }
  #ai-seen { display: none; }
}
.pc-tot small b { font-size: inherit; font-weight: 700; }
b.dif { white-space: nowrap; }
.pp-range { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }

/* ══ Brand layer: the same Bluekom look on every tab (cards, tables, sections, tiles) ══ */
.content .card { border-radius: 16px; box-shadow: var(--shadow); padding: 20px; }
.content .card-head h3 { font: 800 16.5px/1.25 var(--f-display); display: inline-flex; align-items: center; gap: 9px; }
.content .card-head h3::before { content: ""; width: 4px; height: 17px; border-radius: 3px; background: linear-gradient(180deg, #2597D6, #262F7E); flex: none; }
.content .filterbar { border-radius: 16px; box-shadow: var(--shadow); }
.content .fb-l { color: var(--navy-2, #262F7E); font-weight: 800; }
:root[data-theme="dark"] .content .fb-l { color: #9FB0E0; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .content .fb-l { color: #9FB0E0; } }
/* tables: navy header, soft zebra rows, highlighted totals */
.content .tbl-wrap { border-radius: 14px; box-shadow: var(--shadow); }
.content .card .tbl-wrap { box-shadow: none; }
.content .tbl th { background: linear-gradient(135deg, #17195A 0%, #262F7E 100%); color: #DCE3FA; border-bottom: 0; }
.content .tbl tbody tr:nth-child(even) > td { background: color-mix(in srgb, var(--surface-2) 75%, transparent); }
.content .tbl tbody tr:hover > td { background: var(--signal-soft); }
.content .tbl tr.tot > td { background: color-mix(in srgb, var(--signal-soft) 80%, var(--surface)); font-weight: 700; border-top: 2px solid var(--sky, #2597D6); }
.content .tbl tr.grp > td { background: var(--surface-2); color: var(--navy-2, #262F7E); font: 800 12px var(--f-display); letter-spacing: .08em; text-transform: uppercase; }
/* section titles */
.content .x-sec h2, .content .sec-h { display: inline-flex; align-items: center; gap: 9px; }
.content .x-sec h2::before { content: ""; width: 4px; height: 18px; border-radius: 3px; background: linear-gradient(180deg, #2597D6, #262F7E); }
/* KPI tiles: rounded, shadow, coloured top accent */
.content .kpi, .content .x-tile { position: relative; overflow: hidden; border-radius: 16px; box-shadow: var(--shadow); }
.content .kpi::before, .content .x-tile::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--sky, #2597D6); }
.content .kpi.hero::before { background: linear-gradient(90deg, #2597D6, #D9A52B); }
.content .x-tile:nth-child(4n+2)::before, .content .kpi:nth-child(4n+2)::before { background: #D9A52B; }
.content .x-tile:nth-child(4n+3)::before, .content .kpi:nth-child(4n+3)::before { background: #1D8F62; }
.content .x-tile:nth-child(4n+4)::before, .content .kpi:nth-child(4n+4)::before { background: #7B5EA7; }
.content .x-tile.x-crit::before { background: var(--bad); }
/* % in tile headers becomes a coloured badge */
.content .x-t-h strong { padding: 2px 10px; border-radius: 999px; background: var(--none-soft); font-size: 15px; }
.content .x-t-h strong.pct-good { background: var(--good-soft); } .content .x-t-h strong.pct-warn { background: var(--warn-soft); } .content .x-t-h strong.pct-bad { background: var(--bad-soft); }
.content .x-t-v { font-size: 27px; letter-spacing: -.01em; }
/* empty states and buttons */
.content .empty b { font: 800 16px var(--f-display); color: var(--ink); }
.btn.primary { background: linear-gradient(135deg, #1877B5, #2597D6); border-color: transparent; }

/* ── branded scorecard (Overview) ── */
:root { --bk-navy: #2597D6; --bk-sky: #2597D6; --bk-gold: #D9A52B; --bk-red: #C63D37; --bk-green: #1D8F62; }
.bk-kpis { display: grid; grid-template-columns: 1.25fr 1fr 1fr 1fr; gap: 16px; }
.bk-k { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 18px 20px 16px; display: flex; flex-direction: column; gap: 8px; min-width: 0; overflow: hidden; box-shadow: var(--shadow); }
.bk-k::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--acc); }
.bk-k-h { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.bk-lab { font: 700 12px var(--f-body); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.bk-badge { font: 800 15px var(--f-display); padding: 3px 10px; border-radius: 999px; background: var(--none-soft); color: var(--none); white-space: nowrap; }
.bk-badge.good { background: var(--good-soft); color: var(--good); } .bk-badge.warn { background: var(--warn-soft); color: var(--warn); } .bk-badge.bad { background: var(--bad-soft); color: var(--bad); }
.bk-val { font: 800 clamp(26px, 2.4vw, 36px)/1.05 var(--f-display); letter-spacing: -.02em; color: var(--ink); overflow-wrap: anywhere; }
.bk-rows { display: grid; grid-template-columns: repeat(3, minmax(0, auto)); justify-content: start; gap: 4px 22px; }
.bk-rows span { display: block; font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.bk-rows b { font: 700 14.5px var(--f-mono); color: var(--ink-2); white-space: nowrap; }
.bk-bar { position: relative; height: 8px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--line); margin-top: 2px; }
.bk-bar i { position: absolute; inset: 0 auto 0 0; border-radius: 99px; background: var(--none); }
.bk-bar i.good { background: linear-gradient(90deg, #1D8F62, #3BC48C); } .bk-bar i.warn { background: linear-gradient(90deg, #B86E0E, #E6A23C); } .bk-bar i.bad { background: linear-gradient(90deg, #C63D37, #E86A5F); }
.bk-pace { position: absolute; top: -4px; bottom: -4px; width: 2px; margin-left: -1px; background: var(--ink); border-radius: 2px; }
.bk-note { font-size: 12px; color: var(--muted); } .bk-note b { font-family: var(--f-mono); color: var(--ink-2); }
/* navy headline card */
.bk-k.hero { background: radial-gradient(120% 140% at 100% 0%, rgba(37,151,214,.35) 0%, rgba(37,151,214,0) 55%), linear-gradient(135deg, #17195A 0%, #262F7E 100%); border-color: transparent; color: #fff; }
.bk-k.hero::before { background: linear-gradient(90deg, #2597D6, #D9A52B); }
.bk-k.hero .bk-lab, .bk-k.hero .bk-rows span, .bk-k.hero .bk-note { color: #AFC0EE; }
.bk-k.hero .bk-val { color: #fff; font-size: clamp(30px, 2.8vw, 42px); }
.bk-k.hero .bk-rows b, .bk-k.hero .bk-note b { color: #fff; }
.bk-k.hero .bk-bar { background: rgba(255,255,255,.12); border-color: transparent; } .bk-k.hero .bk-pace { background: #fff; }
.bk-k.hero .bk-badge { background: rgba(255,255,255,.14); }
.bk-k.hero .bk-badge.good, .bk-k.hero .pct-good, .bk-k.hero b.dif.pct-good { color: #5EE0A6; } .bk-k.hero .bk-badge.warn, .bk-k.hero .pct-warn { color: #FFC56B; } .bk-k.hero .bk-badge.bad, .bk-k.hero .pct-bad, .bk-k.hero b.dif.pct-bad { color: #FF8F88; }
/* market cards */
.bk-ms { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.bk-m { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; min-width: 0; box-shadow: var(--shadow); }
.bk-m.sel { outline: 2px solid var(--mc); outline-offset: -1px; }
.bk-m-h { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 18px 20px; color: #fff;
  background: radial-gradient(130% 160% at 100% 0%, color-mix(in srgb, var(--mc) 70%, transparent) 0%, transparent 60%), linear-gradient(135deg, #17195A 0%, #262F7E 100%); }
.bk-m-code { display: inline-block; font: 800 11px var(--f-mono); letter-spacing: .12em; padding: 2px 8px; border-radius: 6px; background: var(--mc); color: #fff; }
.bk-m-name { font: 800 19px var(--f-display); margin-top: 6px; }
.bk-ring { --c: var(--none); width: 92px; height: 92px; border-radius: 50%; flex: none; display: grid; place-items: center;
  background: conic-gradient(var(--c) calc(var(--p) * 1%), rgba(255,255,255,.14) 0); }
.bk-ring.good { --c: #3BC48C; } .bk-ring.warn { --c: #F0AE4C; } .bk-ring.bad { --c: #F07A70; }
.bk-ring > div { width: 74px; height: 74px; border-radius: 50%; background: #1C2268; display: grid; place-content: center; text-align: center; }
.bk-ring b { font: 800 20px var(--f-display); line-height: 1; } .bk-ring small { font-size: 8.5px; line-height: 1.15; color: #AFC0EE; text-transform: uppercase; letter-spacing: .06em; padding: 3px 6px 0; }
.bk-m-top { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; padding: 14px 20px 12px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.bk-m-top span { display: block; font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.bk-m-top b { font: 700 16px var(--f-mono); color: var(--ink); white-space: nowrap; }
.bk-m-rows { padding: 6px 20px 8px; display: flex; flex-direction: column; }
.bk-mr { padding: 10px 0; border-bottom: 1px dashed var(--line); display: flex; flex-direction: column; gap: 5px; } .bk-mr:last-child { border-bottom: 0; }
.bk-mr-l { display: flex; justify-content: space-between; align-items: center; font-weight: 600; font-size: 13.5px; color: var(--ink-2); }
.bk-mr-l em { font-style: normal; font-weight: 500; font-size: 12px; color: var(--muted); }
.bk-chip { font: 800 12.5px var(--f-display); padding: 2px 8px; border-radius: 999px; background: var(--none-soft); color: var(--none); }
.bk-chip.good { background: var(--good-soft); color: var(--good); } .bk-chip.warn { background: var(--warn-soft); color: var(--warn); } .bk-chip.bad { background: var(--bad-soft); color: var(--bad); }
.bk-mr-v { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; font-size: 12.5px; }
.bk-mr-v > b { font: 700 15px var(--f-mono); color: var(--ink); } .bk-mr-v > span { color: var(--muted); font-family: var(--f-mono); } .bk-mr-v .dif { margin-left: auto; }
.bk-mr .bk-bar { height: 6px; }
.bk-m-f { margin-top: auto; padding: 11px 20px; font-size: 12px; color: var(--muted); border-top: 1px solid var(--line); display: flex; align-items: center; gap: 8px; }
.bk-m-f i { width: 8px; height: 8px; border-radius: 50%; background: var(--none); flex: none; } .bk-m-f i.ok { background: var(--good); } .bk-m-f i.bad { background: var(--bad); }
@media (max-width: 1100px) { .bk-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .bk-ms { grid-template-columns: 1fr; } }
@media (max-width: 620px) { .bk-kpis { grid-template-columns: 1fr; } .bk-ring { width: 78px; height: 78px; } .bk-ring > div { width: 62px; height: 62px; } .bk-ring b { font-size: 17px; } }
.bk-rows { display: flex; flex-wrap: wrap; gap: 6px 20px; }

/* daily entry calendar */
.en-cal { margin-top: 16px; } .en-cal .card-head { align-items: center; gap: 10px; flex-wrap: wrap; } .en-cal .card-head h3 { margin: 0; }
.dcal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.dcal .dh { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 600; text-align: center; padding-bottom: 2px; }
.dc { border: 1px solid var(--line); background: var(--surface); border-radius: 10px; min-height: 56px; padding: 6px 7px; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; font: inherit; color: var(--ink); cursor: pointer; text-align: left; min-width: 0; }
.dc b { font: 700 14px var(--f-display); } .dc small { font: 600 11px var(--f-mono); color: var(--muted); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dc.pad { border: 0; background: none; cursor: default; }
.dc.ok { background: var(--good-soft); border-color: transparent; } .dc.ok small { color: var(--good); }
.dc.miss { background: var(--bad-soft); border-color: transparent; } .dc.miss small { color: var(--bad); }
.dc.wk { background: var(--surface-2); color: var(--muted); }
.dc.fut { opacity: .4; cursor: default; }
.dc.sel { outline: 2px solid var(--signal); outline-offset: 1px; }
.dc:not(.fut):not(.pad):hover { border-color: var(--signal); }
@media (max-width: 620px) { .dcal { gap: 4px; } .dc { min-height: 44px; padding: 4px; } .dc small { font-size: 9px; } }
