/* Imbalo — corporate theme. Tokens first; light + dark. */
:root {
  --font: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  --bg: #f4f6fa; --panel: #ffffff; --panel-2: #f8fafc; --ink: #0f172a; --ink-2: #334155; --muted: #64748b; --line: #e2e8f0; --line-2: #eef2f7;
  --brand: #1d4ed8; --brand-600: #1e40af; --brand-50: #eef3ff; --brand-ink: #ffffff; --accent: #0ea5a4;
  --side: #0b1b33; --side-2: #10264a; --side-ink: #a9b8d0; --side-h: #6f84a6; --side-on-bg: rgba(59, 130, 246, .18); --side-on: #ffffff;
  --ok: #047857; --ok-bg: #e7f7f0; --bad: #b91c1c; --bad-bg: #fdecec; --warn: #b45309; --warn-bg: #fff4e0; --info: #1d4ed8; --info-bg: #eaf0ff;
  --radius: 10px; --radius-sm: 7px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, .05); --shadow: 0 1px 3px rgba(15, 23, 42, .06), 0 1px 2px rgba(15, 23, 42, .04);
  --shadow-lg: 0 12px 32px rgba(15, 23, 42, .14), 0 2px 6px rgba(15, 23, 42, .06);
  --side-w: 248px; --side-w-min: 68px; --top-h: 60px;
  font-family: var(--font); font-size: 14px; color: var(--ink); -webkit-font-smoothing: antialiased;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0a1020; --panel: #111a2e; --panel-2: #0e1628; --ink: #e5eaf3; --ink-2: #c3cddd; --muted: #8b98ae; --line: #22304a; --line-2: #1a2640;
    --brand: #3b82f6; --brand-600: #2563eb; --brand-50: #13244a; --side: #070e1c; --side-2: #0c1830;
    --ok: #34d399; --ok-bg: #0d2b22; --bad: #f87171; --bad-bg: #351616; --warn: #fbbf24; --warn-bg: #33250b; --info: #93b4ff; --info-bg: #15244a;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4); --shadow-lg: 0 12px 32px rgba(0, 0, 0, .5);
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--ink); line-height: 1.45; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 22px; margin: 0; font-weight: 700; letter-spacing: -.01em; }
h2 { font-size: 15px; margin: 0 0 12px; font-weight: 600; letter-spacing: -.005em; }
h3 { font-size: 13.5px; margin: 0 0 8px; font-weight: 600; }
code { font-size: 12.5px; background: var(--panel-2); border: 1px solid var(--line); padding: 1px 5px; border-radius: 5px; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.num, td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pos { color: var(--ok); } .neg { color: var(--bad); }
.ic { flex-shrink: 0; display: inline-block; vertical-align: middle; }

/* ------------------------------------------------------------ shell */
.shell { display: flex; min-height: 100vh; }
.side {
  width: var(--side-w); background: linear-gradient(180deg, var(--side) 0%, var(--side-2) 100%); color: var(--side-ink);
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; flex-shrink: 0; transition: width .18s ease; z-index: 30;
}
.brand { display: flex; align-items: center; gap: 11px; padding: 0 18px; height: var(--top-h); color: #fff; border-bottom: 1px solid rgba(255,255,255,.06); }
.brand:hover { text-decoration: none; }
.mark { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; color: #fff; flex-shrink: 0;
  background: linear-gradient(135deg, #3b82f6, #0ea5a4); box-shadow: 0 4px 12px rgba(59,130,246,.35); }
.brand-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.15; }
.brand-text b { font-size: 16px; letter-spacing: .01em; }
.brand-text small { font-size: 11.5px; color: var(--side-h); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav { flex: 1; overflow-y: auto; padding: 8px 10px 16px; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.12) transparent; }
.nav-h { font-size: 10.5px; font-weight: 600; text-transform: uppercase; letter-spacing: .09em; color: var(--side-h); padding: 16px 10px 6px; white-space: nowrap; }
.nav a { display: flex; align-items: center; gap: 11px; color: var(--side-ink); padding: 8px 10px; border-radius: 8px; font-size: 13.5px; font-weight: 500;
  white-space: nowrap; position: relative; }
.nav a .ic { opacity: .85; }
.nav a:hover { background: rgba(255,255,255,.06); color: #fff; text-decoration: none; }
.nav a.on { background: var(--side-on-bg); color: var(--side-on); }
.nav a.on::before { content: ""; position: absolute; left: -10px; top: 7px; bottom: 7px; width: 3px; border-radius: 0 3px 3px 0; background: #60a5fa; }
.nav a.on .ic { opacity: 1; color: #93c5fd; }
.side-foot { padding: 12px 14px; border-top: 1px solid rgba(255,255,255,.06); font-size: 11.5px; color: var(--side-h); }
.fy { display: flex; align-items: center; gap: 8px; white-space: nowrap; overflow: hidden; }

/* collapsed rail (desktop) */
.nav-collapsed .side { width: var(--side-w-min); }
.nav-collapsed .brand { padding: 0 17px; }
.nav-collapsed .brand-text, .nav-collapsed .nav a span, .nav-collapsed .fy span { display: none; }
.nav-collapsed .nav-h { font-size: 0; padding: 10px 0 4px; border-top: 1px solid rgba(255,255,255,.06); margin: 6px 6px 0; }
.nav-collapsed .nav-h:first-child { border-top: 0; }
.nav-collapsed .nav a { justify-content: center; padding: 10px 0; }
.nav-collapsed .side-foot { display: flex; justify-content: center; }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar { height: var(--top-h); display: flex; align-items: center; gap: 12px; padding: 0 24px; background: var(--panel); border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20; box-shadow: var(--shadow-sm); }
.crumbs { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; min-width: 0; white-space: nowrap; overflow: hidden; }
.crumbs a { color: var(--muted); display: inline-flex; } .crumbs a:hover { color: var(--ink); text-decoration: none; }
.crumbs .sep { opacity: .5; }
.top-right { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.icon-btn { position: relative; width: 38px; height: 38px; display: inline-grid; place-items: center; border-radius: 9px; border: 1px solid transparent;
  background: transparent; color: var(--ink-2); cursor: pointer; }
.icon-btn:hover { background: var(--panel-2); border-color: var(--line); color: var(--ink); text-decoration: none; }
.dot { position: absolute; top: 3px; right: 2px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--bad); color: #fff;
  font-size: 10.5px; font-weight: 700; display: grid; place-items: center; border: 2px solid var(--panel); }
.user-btn { display: flex; align-items: center; gap: 9px; padding: 4px 8px 4px 4px; border-radius: 10px; border: 1px solid transparent; background: transparent;
  cursor: pointer; color: var(--ink); font: inherit; }
.user-btn:hover { background: var(--panel-2); border-color: var(--line); }
.avatar { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700; color: #fff;
  background: linear-gradient(135deg, #1d4ed8, #0ea5a4); flex-shrink: 0; letter-spacing: .02em; }
.avatar.lg { width: 42px; height: 42px; font-size: 14px; }
.who { display: flex; flex-direction: column; text-align: left; line-height: 1.15; }
.who b { font-size: 13px; font-weight: 600; } .who small { font-size: 11.5px; color: var(--muted); }

/* dropdowns */
.dd { position: relative; }
.dd-menu { display: none; position: absolute; top: calc(100% + 8px); left: 0; min-width: 230px; background: var(--panel); border: 1px solid var(--line);
  border-radius: 12px; box-shadow: var(--shadow-lg); padding: 6px; z-index: 40; }
.dd-menu.right { left: auto; right: 0; }
.dd.open .dd-menu { display: block; animation: pop .12s ease-out; }
@keyframes pop { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.dd-menu a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; color: var(--ink-2); font-size: 13.5px; }
.dd-menu a:hover { background: var(--panel-2); color: var(--ink); text-decoration: none; }
.dd-menu a .ic { color: var(--muted); }
.dd-menu a.danger, .dd-menu a.danger .ic { color: var(--bad); }
.dd-h { font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 600; padding: 10px 10px 4px; }
.dd-sep { height: 1px; background: var(--line); margin: 6px 4px; }
.dd-user { display: flex; gap: 12px; align-items: center; padding: 10px 10px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.dd-user div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.dd-user small { color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; }
.dd-user .badge { align-self: flex-start; margin-top: 3px; }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; padding: 22px 28px 4px; }
.page-head p { margin: 4px 0 0; color: var(--muted); }
.content { padding: 14px 28px 32px; flex: 1; }
.foot { padding: 14px 28px 20px; font-size: 12px; color: var(--muted); }
.scrim { display: none; }

@media (max-width: 900px) {
  .side { position: fixed; left: 0; top: 0; transform: translateX(-100%); transition: transform .2s ease; width: var(--side-w) !important; box-shadow: var(--shadow-lg); }
  .nav-open .side { transform: none; }
  .nav-open .scrim { display: block; position: fixed; inset: 0; background: rgba(2, 6, 23, .45); z-index: 25; }
  .nav-collapsed .brand-text, .nav-collapsed .nav a span, .nav-collapsed .fy span { display: initial; }
  .nav-collapsed .nav a { justify-content: flex-start; padding: 8px 10px; }
  .nav-collapsed .nav-h { font-size: 10.5px; padding: 16px 10px 6px; border: 0; margin: 0; }
  .topbar, .page-head, .content, .foot { padding-left: 16px; padding-right: 16px; }
  .hide-sm { display: none; }
  .crumbs { display: none; }
}

/* ------------------------------------------------------------ surfaces */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); margin-bottom: 18px; }
.card.flush { padding: 0; overflow-x: auto; }
.card.flush > h2 { padding: 16px 20px 0; margin-bottom: 12px; }
.card.flush > .card-h { padding: 14px 20px 0; }
.card-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.card-h h2 { margin: 0; }
a.card:hover { border-color: var(--brand); text-decoration: none; box-shadow: var(--shadow-lg); }
.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1150px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: 1fr 1fr; } .g3 > [style*="span 2"] { grid-column: span 2 !important; } }
@media (max-width: 720px) { .g2, .g3, .g4 { grid-template-columns: 1fr; } .g3 > [style*="span 2"] { grid-column: auto !important; } }

.stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow); display: block; color: inherit; position: relative; }
.stat .k { font-size: 12.5px; color: var(--muted); font-weight: 500; display: flex; align-items: center; gap: 8px; }
.stat .v { font-size: 24px; font-weight: 700; margin-top: 8px; font-variant-numeric: tabular-nums; letter-spacing: -.02em; color: var(--ink); }
.stat .s { font-size: 12px; color: var(--muted); margin-top: 4px; }
a.stat:hover { text-decoration: none; border-color: var(--brand); }
.chip { width: 30px; height: 30px; border-radius: 8px; display: inline-grid; place-items: center; background: var(--brand-50); color: var(--brand); }
.chip.ok { background: var(--ok-bg); color: var(--ok); } .chip.warn { background: var(--warn-bg); color: var(--warn); } .chip.bad { background: var(--bad-bg); color: var(--bad); }
.chip.teal { background: rgba(14,165,164,.12); color: var(--accent); }

/* ------------------------------------------------------------ tables */
table { width: 100%; border-collapse: collapse; }
th, td { padding: 10px 14px; border-bottom: 1px solid var(--line-2); text-align: left; vertical-align: top; }
th { font-size: 11.5px; font-weight: 600; color: var(--muted); background: var(--panel-2); white-space: nowrap; text-transform: uppercase; letter-spacing: .04em;
  border-bottom: 1px solid var(--line); }
.card.flush th:first-child, .card.flush td:first-child { padding-left: 20px; }
.card.flush th:last-child, .card.flush td:last-child { padding-right: 20px; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--panel-2); }
tr.total td { font-weight: 700; border-top: 2px solid var(--ink-2); background: transparent; }
tr.sub td { font-weight: 600; background: var(--panel-2); }
tr.head td { font-weight: 700; padding-top: 18px; background: transparent; border-bottom: 0; color: var(--ink); }
td.indent { padding-left: 32px !important; }
.table-scroll { overflow-x: auto; }

/* ------------------------------------------------------------ forms */
label { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-2); margin-bottom: 5px; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=number], input[type=search], input[type=file], select, textarea {
  width: 100%; padding: 9px 11px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel); color: var(--ink); font: inherit;
  transition: border-color .12s, box-shadow .12s;
}
input:hover, select:hover, textarea:hover { border-color: #cbd5e1; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(29, 78, 216, .15); }
input:disabled { background: var(--panel-2); color: var(--muted); }
textarea { min-height: 78px; resize: vertical; }
.field { margin-bottom: 14px; }
.row { display: flex; gap: 14px; flex-wrap: wrap; align-items: flex-end; }
.row > .field { flex: 1; min-width: 160px; }
.check { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 500; color: var(--ink); cursor: pointer; }
.check input { width: 16px; height: 16px; accent-color: var(--brand); }
.help { font-size: 12px; color: var(--muted); margin-top: 5px; font-weight: 400; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; padding: 0 15px; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--panel); color: var(--ink); font: inherit; font-weight: 600; font-size: 13.5px; cursor: pointer;
  white-space: nowrap; box-shadow: var(--shadow-sm); transition: background .12s, border-color .12s; }
.btn:hover { text-decoration: none; border-color: #cbd5e1; background: var(--panel-2); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); box-shadow: 0 1px 2px rgba(29,78,216,.3); }
.btn.primary:hover { background: var(--brand-600); border-color: var(--brand-600); }
.btn.danger { color: var(--bad); } .btn.danger:hover { background: var(--bad-bg); border-color: transparent; }
.btn.sm { height: 32px; padding: 0 11px; font-size: 12.5px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
details > summary { list-style: none; } details > summary::-webkit-details-marker { display: none; }
form.inline { display: inline; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.filters input, .filters select { width: auto; }
.filters input[type=search] { min-width: 240px; padding-left: 34px;
  background: var(--panel) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") no-repeat 11px center; }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 16px; flex-wrap: wrap; align-items: flex-end; }
.tabs a { padding: 9px 14px; color: var(--muted); border-bottom: 2px solid transparent; font-weight: 500; margin-bottom: -1px; }
.tabs a.on { color: var(--brand); border-color: var(--brand); font-weight: 600; }
.tabs a:hover { text-decoration: none; color: var(--ink); }

/* document line editor */
table.lines th { text-transform: none; letter-spacing: 0; font-size: 12px; }
table.lines td { padding: 6px; vertical-align: middle; }
table.lines input, table.lines select { padding: 7px 9px; }
table.lines .w-qty { width: 80px; } table.lines .w-amt { width: 125px; } table.lines .w-pct { width: 72px; } table.lines .w-vat { width: 160px; }
table.lines .w-acc { width: 230px; }
.totals { margin-left: auto; width: 340px; max-width: 100%; }
.totals td { border: 0; padding: 6px 8px; }
.totals tr:hover td { background: transparent; }
.totals tr.grand td { font-size: 17px; font-weight: 700; border-top: 2px solid var(--ink-2); padding-top: 10px; }
.x { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 18px; width: 28px; height: 28px; border-radius: 6px; }
.x:hover { background: var(--bad-bg); color: var(--bad); }

/* badges, flashes, notes */
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 99px; font-size: 11.5px; font-weight: 600; background: var(--line-2);
  color: var(--muted); line-height: 1.6; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .8; }
.badge.ok { background: var(--ok-bg); color: var(--ok); } .badge.bad { background: var(--bad-bg); color: var(--bad); }
.badge.warn { background: var(--warn-bg); color: var(--warn); } .badge.info { background: var(--info-bg); color: var(--info); }
.flash { margin: 10px 28px 0; padding: 11px 14px; border-radius: var(--radius-sm); display: flex; gap: 10px; align-items: flex-start; font-weight: 500;
  border: 1px solid transparent; }
.flash.ok { background: var(--ok-bg); color: var(--ok); border-color: rgba(4,120,87,.18); }
.flash.bad { background: var(--bad-bg); color: var(--bad); border-color: rgba(185,28,28,.18); }
@media (max-width: 900px) { .flash { margin: 10px 16px 0; } }
.note { background: var(--info-bg); border: 1px solid rgba(29,78,216,.15); border-radius: var(--radius-sm); padding: 12px 16px; font-size: 13.5px; margin-bottom: 16px; color: var(--ink-2); }
.note.warn { background: var(--warn-bg); border-color: rgba(180,83,9,.2); }
.empty { text-align: center; padding: 38px 20px; color: var(--muted); }

/* ------------------------------------------------------------ sign-in */
.auth-body { min-height: 100vh; display: flex; }
.auth-wrap { display: flex; flex: 1; min-height: 100vh; }
.auth-hero { flex: 1.1; background: radial-gradient(1200px 600px at 10% 10%, #163a74 0%, transparent 60%), linear-gradient(160deg, #0b1b33 0%, #0b2547 60%, #0c3b4e 100%);
  color: #dbe5f5; padding: 40px 56px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-hero .brand { border: 0; padding: 0; height: auto; }
.auth-hero .brand-text small { color: #8ea3c4; }
.hero-copy h2 { font-size: 30px; line-height: 1.2; color: #fff; max-width: 460px; margin-bottom: 22px; letter-spacing: -.02em; }
.hero-copy ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.hero-copy li { display: flex; gap: 10px; align-items: center; color: #c5d3ea; }
.hero-copy li .ic { color: #5eead4; }
.hero-foot { color: #7f93b5; }
.auth-card { flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 40px max(32px, calc((50vw - 400px) / 2)); background: var(--panel); }
.auth-card h1 { margin-bottom: 6px; }
.auth-card form { max-width: 400px; }
.auth-card .flash { margin: 12px 0; max-width: 400px; }
.auth-card .btn { height: 42px; }
@media (max-width: 860px) { .auth-hero { display: none; } .auth-card { padding: 32px 20px; } }

/* ------------------------------------------------------------ bank feed */
.txn { border-bottom: 1px solid var(--line-2); padding: 13px 20px; }
.txn:last-child { border-bottom: 0; }
.txn:hover { background: var(--panel-2); }
.txn.open { background: var(--panel-2); }
.txn-top { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.txn-top .d { width: 92px; color: var(--muted); flex-shrink: 0; font-size: 13px; }
.txn-top .desc { flex: 1; min-width: 200px; overflow-wrap: anywhere; font-weight: 500; }
.txn-top .a { font-weight: 700; font-variant-numeric: tabular-nums; }
.txn-act { margin-top: 12px; display: none; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 4px 16px 14px; }
.txn.open .txn-act { display: block; }
.txn-act .tabs { margin-bottom: 14px; }
.pane { display: none; } .pane.on { display: block; }

/* ------------------------------------------------------------ charts & misc */
.bars { display: flex; align-items: flex-end; gap: 8px; height: 170px; padding-top: 14px; border-bottom: 1px solid var(--line); }
.bars .m { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; }
.bars .pair { display: flex; gap: 3px; align-items: flex-end; height: 100%; width: 100%; justify-content: center; }
.bars .b { width: 38%; max-width: 18px; border-radius: 4px 4px 0 0; min-height: 2px; }
.bars .b.i { background: linear-gradient(180deg, #3b82f6, #1d4ed8); } .bars .b.e { background: #cbd5e1; }
.bars .l { font-size: 11px; color: var(--muted); padding-bottom: 4px; }
.legend { display: flex; gap: 16px; font-size: 12px; color: var(--muted); margin-top: 10px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.kpi { display: flex; flex-direction: column; gap: 2px; }
.kpi .muted { font-size: 12.5px; }
.kpi .big { font-size: 20px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.dl { display: grid; grid-template-columns: 150px 1fr; gap: 8px 14px; font-size: 13.5px; }
.dl dt { color: var(--muted); } .dl dd { margin: 0; font-weight: 500; }
.deadline { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.deadline:last-child { border-bottom: 0; }
.deadline .date { width: 46px; text-align: center; border: 1px solid var(--line); border-radius: 8px; padding: 4px 0; flex-shrink: 0; background: var(--panel-2); }
.deadline .date b { display: block; font-size: 16px; line-height: 1.1; } .deadline .date small { font-size: 10.5px; color: var(--muted); text-transform: uppercase; }
.deadline .t { flex: 1; min-width: 0; } .deadline .t div { font-weight: 600; font-size: 13px; } .deadline .t small { color: var(--muted); }
.steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.steps a { display: flex; gap: 10px; align-items: flex-start; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px;
  color: var(--ink-2); font-size: 13px; }
.steps a:hover { border-color: var(--brand); text-decoration: none; }
.steps b { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--brand); color: #fff; font-size: 12px; flex-shrink: 0; }
@media (max-width: 1100px) { .steps { grid-template-columns: 1fr 1fr; } }

@media print {
  .side, .topbar, .filters, .no-print, .btn, .foot, .scrim { display: none !important; }
  .content, .page-head { padding: 0; } .card { border: 0; box-shadow: none; }
  body { background: #fff; }
}

/* ------------------------------------------------------------ back link, entity view */
.back-link { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 6px;
  padding: 3px 8px 3px 4px; border-radius: 6px; margin-left: -4px; }
.back-link:hover { color: var(--brand); background: var(--brand-50); text-decoration: none; }
.ic.rot90 { transform: rotate(90deg); }
.card.flush details.add { padding: 10px 20px 16px; border-top: 1px solid var(--line-2); }
.card.flush details.add[open] summary { margin-bottom: 12px; }
.card.flush .empty.small { padding: 16px 20px; text-align: left; font-size: 13px; }
.card-h h2 .ic, h2 .ic { color: var(--muted); margin-right: 4px; vertical-align: -3px; }
[hidden] { display: none !important; }
