:root {
  --side: #10302f;
  --side-2: #184443;
  --teal: #0f766e;
  --teal-d: #0b5d57;
  --ink: #1f2a2e;
  --muted: #64737a;
  --line: #e2e8e8;
  --bg: #f6f8f7;
  --ok: #15803d;
  --ok-bg: #e7f6ec;
  --amber: #a16207;
  --amber-bg: #fef6dc;
  --err: #b91c1c;
  --err-bg: #fdeaea;
}
* { box-sizing: border-box; }
body { margin: 0; font: 14px/1.5 "Inter", "Segoe UI", system-ui, Arial, sans-serif; color: var(--ink); background: var(--bg); }
a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 22px; font-weight: 650; margin: 0; letter-spacing: -.01em; }
h2 { font-size: 15px; font-weight: 650; margin: 0 0 10px; }

.shell { display: grid; grid-template-columns: 236px 1fr; min-height: 100vh; }
aside { background: var(--side); color: #cfe3df; padding: 18px 12px; display: flex; flex-direction: column; gap: 4px; }
aside .brand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 700; font-size: 16px; padding: 4px 8px 18px; }
aside .brand small { display: block; font-weight: 500; font-size: 11px; color: #8fb8b1; }
aside nav a { display: flex; align-items: center; gap: 10px; color: #cfe3df; padding: 8px 10px; border-radius: 6px; }
aside nav a:hover { background: var(--side-2); text-decoration: none; }
aside nav a.active { background: #e6f2f0; color: var(--side); font-weight: 600; }
aside .foot { margin-top: auto; font-size: 12px; color: #8fb8b1; padding: 8px; }
.icon { width: 18px; text-align: center; }

.top { height: 60px; background: #fff; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 14px; padding: 0 28px; }
.top .search { flex: 1; max-width: 420px; }
.top input { border-radius: 20px; background: var(--bg); }
.top .spacer { flex: 1; }
.chip { background: #fde68a; color: #713f12; font-size: 11px; font-weight: 700; border-radius: 4px; padding: 2px 7px; letter-spacing: .05em; }
.who { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--teal); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 12px; }
main { padding: 26px 28px 48px; max-width: 1200px; }
.crumbs { color: var(--muted); font-size: 13px; margin-bottom: 4px; }
.crumbs a { color: var(--muted); }
.head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 18px; gap: 16px; }
.head .sub { color: var(--muted); margin-top: 4px; }

.card { background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 1px 2px rgba(16, 48, 47, .04); }
.pad { padding: 20px 22px; }
.card + .card { margin-top: 16px; }
.kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 16px; }
.kpi .n { font-size: 28px; font-weight: 700; }
.kpi .l { color: var(--muted); font-size: 13px; }
.split { display: grid; grid-template-columns: 1fr 340px; gap: 16px; align-items: start; }

.btn { display: inline-flex; align-items: center; gap: 6px; background: var(--teal); color: #fff; border: 1px solid var(--teal); border-radius: 8px; padding: 8px 16px; font: inherit; font-weight: 600; cursor: pointer; }
.btn:hover { background: var(--teal-d); text-decoration: none; }
.btn.outline { background: #fff; color: var(--teal); }
.btn.quiet { background: #fff; color: var(--ink); border-color: var(--line); font-weight: 500; }
label { display: block; font-weight: 600; font-size: 13px; margin: 14px 0 5px; }
.req::after { content: " *"; color: var(--err); }
input, select, textarea { font: inherit; width: 100%; border: 1px solid #cbd5d4; border-radius: 8px; padding: 8px 11px; background: #fff; }
input:focus, select:focus, textarea:focus { outline: 3px solid #b7e4dd; border-color: var(--teal); }
.help { color: var(--muted); font-size: 12px; margin-top: 4px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }

.tabs { display: flex; gap: 6px; margin-bottom: 14px; }
.tabs a { padding: 6px 14px; border-radius: 16px; color: var(--muted); font-weight: 600; font-size: 13px; border: 1px solid var(--line); background: #fff; }
.tabs a.on { background: var(--side); color: #fff; border-color: var(--side); }
.tabs a:hover { text-decoration: none; }
.finder { display: flex; gap: 10px; align-items: flex-end; padding: 16px 22px; border-bottom: 1px solid var(--line); }
.finder > div { flex: 1; max-width: 360px; }
.finder label { margin-top: 0; }

table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 10px 22px; border-bottom: 1px solid var(--line); }
td { padding: 12px 22px; border-bottom: 1px solid #eef2f1; }
tr:last-child td { border-bottom: 0; }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.pill { display: inline-block; font-size: 12px; font-weight: 600; border-radius: 12px; padding: 2px 10px; }
.p-open { background: #e0f2fe; color: #075985; }
.p-ok { background: var(--ok-bg); color: var(--ok); }
.p-part { background: var(--amber-bg); color: var(--amber); }
.p-done { background: #eef1f1; color: #4b5a5f; }

.steps { display: flex; gap: 0; margin: 4px 0 0; padding: 0; list-style: none; }
.steps li { flex: 1; text-align: center; font-size: 12px; color: var(--muted); position: relative; padding-top: 22px; }
.steps li::before { content: ""; position: absolute; top: 6px; left: 50%; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: #cfd8d7; }
.steps li.done { color: var(--ink); font-weight: 600; }
.steps li.done::before { background: var(--teal); }

ul.lines { list-style: none; margin: 0; padding: 0; }
ul.lines li { display: grid; grid-template-columns: 70px 1fr 120px 150px 140px 110px; gap: 12px; align-items: center; padding: 14px 22px; border-bottom: 1px solid #eef2f1; }
ul.lines li:last-child { border-bottom: 0; }
ul.lines .muted { color: var(--muted); font-size: 12px; }
dl.facts { display: grid; grid-template-columns: 140px 1fr; gap: 6px 12px; margin: 0; }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; }
.muted { color: var(--muted); }

.banner { padding: 12px 16px; border-radius: 8px; margin-bottom: 16px; font-weight: 500; }
.banner.ok { background: var(--ok-bg); color: #14532d; border: 1px solid #bbe5c8; }
.banner.err { background: var(--err-bg); color: var(--err); border: 1px solid #f5c2c2; }
.toast { transition: opacity .4s; }
.toast-hide { opacity: .0; }

dialog { border: 0; border-radius: 14px; padding: 0; width: 440px; box-shadow: 0 24px 60px rgba(16, 48, 47, .3); }
dialog::backdrop { background: rgba(16, 48, 47, .5); }
dialog .dh { padding: 20px 24px 4px; font-size: 17px; font-weight: 650; }
dialog .db { padding: 4px 24px 8px; color: var(--muted); }
dialog .df { padding: 16px 24px 20px; display: flex; justify-content: flex-end; gap: 10px; }

/* sign in */
.signin { min-height: 100vh; display: grid; place-items: center; background: radial-gradient(circle at 20% 10%, #d6efe9, #f6f8f7 55%); }
.signin .box { width: 400px; background: #fff; border-radius: 16px; box-shadow: 0 12px 40px rgba(16, 48, 47, .12); padding: 34px 36px; }
.signin .brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 17px; margin-bottom: 22px; }
.signin .btn { width: 100%; justify-content: center; margin-top: 18px; padding: 10px; }
.signin .alt { text-align: center; color: var(--muted); font-size: 12px; margin-top: 16px; }
.signin .who-box { background: var(--bg); border-radius: 8px; padding: 8px 12px; display: flex; justify-content: space-between; font-size: 13px; }
.kpis > .card, .split > .card, .split > div > .card:first-child { margin-top: 0; }
ul.attention { list-style: none; padding: 0; margin: 0; }
ul.attention li { display: flex; align-items: center; gap: 14px; padding: 9px 0; border-bottom: 1px solid #eef2f1; }
ul.attention li:last-child { border-bottom: 0; }
ul.attention li span:first-child { flex: 1; }
.p-declined { background: #fee2e2; color: #991b1b; }
