/* AMZDUDES Hub. One stylesheet, no build step. */

/* IBM Plex Sans, SIL Open Font License (assets/fonts/OFL-LICENSE.txt) */
@font-face {
    font-family: "IBM Plex Sans";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("fonts/ibm-plex-sans-latin-400-normal.woff2") format("woff2");
}
@font-face {
    font-family: "IBM Plex Sans";
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url("fonts/ibm-plex-sans-latin-500-normal.woff2") format("woff2");
}
@font-face {
    font-family: "IBM Plex Sans";
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url("fonts/ibm-plex-sans-latin-600-normal.woff2") format("woff2");
}
@font-face {
    font-family: "IBM Plex Sans";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("fonts/ibm-plex-sans-latin-700-normal.woff2") format("woff2");
}

:root {
    --ink: #1D2430;
    --ink-2: #273142;
    --ink-line: #2E394B;
    --ink-text: #C3CBD6;
    --ink-muted: #8C98A8;
    --paper: #F3F5F7;
    --panel: #FFFFFF;
    --line: #DDE2E8;
    --line-soft: #ECEFF3;
    --head-bg: #F8F9FB;
    --text: #1D2430;
    --muted: #5B6675;
    --brand: #E4863E;
    --brand-hover: #D5752A;
    --brand-tint: #FCEFE4;
    --brand-text: #8A4B17;
    --good: #2F855A;
    --good-bg: #E3F3EA;
    --good-text: #22603F;
    --bad: #C53030;
    --bad-bg: #FBE5E5;
    --bad-text: #9B2424;
    --warn: #975A16;
    --warn-bg: #FDF3DC;
    --radius: 8px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    font-family: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: var(--text);
    background: var(--paper);
}
h1, h2, h3, h4 { line-height: 1.3; }
a { color: var(--text); text-decoration-color: #AEB8C4; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--brand); }
p { margin: 0 0 10px; }
code { font-size: 13px; background: #EEF1F4; padding: 1px 5px; border-radius: 4px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.strong { font-weight: 600; }
.warn-text { color: var(--warn); }
.num { text-align: right; font-variant-numeric: tabular-nums; }
a:focus-visible, button:focus-visible, summary:focus-visible, .tile:focus-visible {
    outline: 2px solid var(--ink);
    outline-offset: 2px;
}
.skip { position: absolute; left: -999px; top: 8px; background: #fff; padding: 8px 12px; z-index: 10; border-radius: 6px; }
.skip:focus { left: 8px; }

/* ---------- Shell ---------- */

.shell { display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 100vh; }
.side {
    background: var(--ink);
    color: var(--ink-text);
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}
.side a:focus-visible, .side button:focus-visible { outline-color: var(--brand); }
.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 20px 20px 18px;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
}
.mark {
    width: 28px;
    height: 28px;
    flex: none;
    border-radius: 7px;
    background: var(--brand);
    color: var(--ink);
    display: grid;
    place-items: center;
    font-weight: 700;
    font-size: 15px;
}
.nav { display: flex; flex-direction: column; padding: 4px 10px; gap: 1px; }
.nav a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 6px;
    color: var(--ink-text);
    text-decoration: none;
    position: relative;
}
.nav a:hover { background: var(--ink-2); color: #fff; }
.nav a.on { background: var(--ink-2); color: #fff; font-weight: 500; }
.nav a.on::before {
    content: "";
    position: absolute;
    left: -10px;
    top: 8px;
    bottom: 8px;
    width: 3px;
    border-radius: 0 3px 3px 0;
    background: var(--brand);
}
.nav .gap { height: 14px; }
.nav .count {
    font-size: 12px;
    line-height: 18px;
    min-width: 20px;
    padding: 0 6px;
    border-radius: 9px;
    background: #3A4659;
    color: #fff;
    text-align: center;
    font-variant-numeric: tabular-nums;
}
.nav .count.late { background: var(--bad); }
.side-foot { margin-top: auto; padding: 16px 20px 20px; border-top: 1px solid var(--ink-line); font-size: 13px; }
.side-foot .who { color: #fff; font-weight: 500; }
.side-foot .role { color: var(--ink-muted); }
.side-foot .row { display: flex; gap: 14px; margin-top: 10px; align-items: center; }
.side-foot a, .side-foot button {
    color: var(--ink-text);
    background: none;
    border: 0;
    padding: 0;
    font: inherit;
    cursor: pointer;
    text-decoration: underline;
    text-decoration-color: #56637A;
    text-underline-offset: 3px;
}
.side-foot a:hover, .side-foot button:hover { color: #fff; }
.main { padding: 28px 32px 56px; max-width: 1320px; width: 100%; }

/* ---------- Page head, tabs, filters ---------- */

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head h1 { margin: 0; font-size: 24px; font-weight: 600; letter-spacing: -0.01em; }
.page-head p { margin: 4px 0 0; color: var(--muted); max-width: 72ch; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; scrollbar-width: thin; }
.tabs a {
    padding: 9px 14px;
    color: var(--muted);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    white-space: nowrap;
    font-weight: 500;
}
.tabs a:hover { color: var(--text); }
.tabs a.on { color: var(--text); border-bottom-color: var(--brand); }
.filters { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; margin-bottom: 16px; }
.filters .field { margin: 0; min-width: 170px; }
.filters .field.grow { flex: 1; min-width: 220px; }

/* ---------- Messages ---------- */

.flash { padding: 10px 14px; border-radius: 6px; margin-bottom: 12px; border: 1px solid; }
.flash.ok { background: var(--good-bg); border-color: #BCE0CA; color: var(--good-text); }
.flash.err { background: var(--bad-bg); border-color: #F0C0C0; color: var(--bad-text); }
.flash.note { background: var(--warn-bg); border-color: #EFD6A2; color: #6B4210; }

/* ---------- Panels ---------- */

.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 20px; }
.panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 13px 18px;
    border-bottom: 1px solid var(--line-soft);
}
.panel-head h2 { margin: 0; font-size: 15px; font-weight: 600; }
.panel-head .sub { color: var(--muted); font-size: 13px; white-space: nowrap; }
a.sub:hover { color: var(--text); }
.panel-body { padding: 16px 18px; }
.panel-foot { display: flex; align-items: center; gap: 14px; padding: 12px 18px; border-top: 1px solid var(--line-soft); flex-wrap: wrap; }
.panel-note { margin: 0; padding: 10px 18px 14px; color: var(--muted); font-size: 12.5px; }
.grid-2 { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.grid-halves { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; }
.slot { font-weight: 500; margin-bottom: 4px; }
.excerpt { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.facts { display: grid; grid-template-columns: 110px 1fr; gap: 6px 12px; margin: 0 0 14px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; }

/* ---------- Tables ---------- */

.tbl-wrap { overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; }
.tbl th, .tbl td { padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.tbl th:first-child, .tbl td:first-child { padding-left: 18px; }
.tbl th:last-child, .tbl td:last-child { padding-right: 18px; }
.tbl thead th { font-size: 12.5px; font-weight: 500; color: var(--muted); background: var(--head-bg); white-space: nowrap; }
.tbl tbody th { font-weight: 400; }
.tbl tbody tr:last-child > * { border-bottom: 0; }
.tbl .num { text-align: right; }
.tbl .right { text-align: right; white-space: nowrap; }
.tbl .nowrap { white-space: nowrap; }
.tbl tr.dim td, .tbl tr.dim th { color: var(--muted); }
.th-sub { display: block; font-weight: 400; font-size: 12px; color: var(--muted); }
.tbl.entry .cell { padding: 6px 8px; width: 96px; }
.tbl.entry .blk { margin: 0 0 0 auto; }
.m-name { display: block; font-weight: 500; }
.meta { display: block; font-size: 12.5px; color: var(--muted); }
.meta .due, .meta .muted { font-size: inherit; }
.due.late { color: var(--bad); font-weight: 500; }
.row-title { font-weight: 500; text-decoration: none; }
.row-title:hover { text-decoration: underline; }

/* ---------- Scorecard grid: the week blocks ---------- */

.score-wrap { overflow-x: auto; }
.score { border-collapse: separate; border-spacing: 0; width: 100%; font-variant-numeric: tabular-nums; }
.score th, .score td { border-bottom: 1px solid var(--line-soft); }
.score tbody tr:last-child > * { border-bottom: 0; }
.score thead th {
    font-size: 12.5px;
    color: var(--muted);
    font-weight: 500;
    padding: 9px 3px;
    text-align: center;
    white-space: nowrap;
    background: var(--head-bg);
    vertical-align: bottom;
}
.score .sc-name {
    position: sticky;
    left: 0;
    z-index: 1;
    background: #fff;
    text-align: left;
    padding: 8px 12px 8px 18px;
    min-width: 230px;
    max-width: 300px;
    font-weight: 400;
    box-shadow: 1px 0 0 var(--line-soft);
}
.score thead .sc-name { background: var(--head-bg); z-index: 2; text-align: left; padding-left: 18px; }
.score .m-owner { display: block; font-size: 12.5px; color: var(--muted); }
.score .m-owner.none { color: var(--warn); }
.score .sc-goal { padding: 8px 10px; color: var(--muted); white-space: nowrap; text-align: right; font-size: 13px; }
.score thead .sc-goal { text-align: right; }
.score .cell { padding: 4px 2px; }
.score th.wk-now { color: var(--text); background: var(--brand-tint); box-shadow: inset 0 -2px 0 var(--brand); }
.score td.wk-now { background: #FFF9F4; }
.wk-tag { display: block; font-size: 11px; color: var(--brand-text); font-weight: 500; }

.blk {
    display: block;
    width: 74px;
    height: 34px;
    margin: 0 auto;
    border-radius: 5px;
    border: 1px solid var(--line);
    background: #fff;
    text-align: right;
    padding: 0 8px;
    font: inherit;
    font-size: 13.5px;
    line-height: 32px;
    color: var(--text);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
input.blk:hover { border-color: #AEB8C4; }
input.blk:focus { outline: 2px solid var(--ink); outline-offset: 1px; }
.blk.good { background: var(--good); border-color: var(--good); color: #fff; font-weight: 500; }
.blk.bad { background: var(--bad); border-color: var(--bad); color: #fff; font-weight: 500; }
.blk.ro { border-color: transparent; background: #F1F3F6; }
.blk.ro.good { background: var(--good); }
.blk.ro.bad { background: var(--bad); }
.blk.ro.empty { background: transparent; border: 1px dashed #DCE1E7; }
.score-legend { display: flex; gap: 18px; flex-wrap: wrap; padding: 10px 18px 14px; color: var(--muted); font-size: 12.5px; align-items: center; }
.score-legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }

.strip { display: inline-flex; gap: 3px; flex: none; }
.sq { display: inline-block; width: 14px; height: 14px; border-radius: 3px; background: #E3E7EC; }
.sq.good, .score-legend i.good { background: var(--good); }
.sq.bad, .score-legend i.bad { background: var(--bad); }
.sq.nogoal, .score-legend i.nogoal { background: #A3AEBC; }
.sq.empty, .score-legend i.empty { background: transparent; border: 1px dashed #C4CCD6; }
.pulse li { gap: 14px; }
.pulse-val { min-width: 64px; text-align: right; font-variant-numeric: tabular-nums; font-weight: 500; }
.pulse-val.good { color: var(--good); }
.pulse-val.bad { color: var(--bad); }

/* ---------- Lists ---------- */

.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; align-items: center; gap: 12px; padding: 11px 18px; border-bottom: 1px solid var(--line-soft); }
.list li:last-child { border-bottom: 0; }
.list.compact li { padding: 9px 18px; }
.list .grow { flex: 1; min-width: 0; }
.list.links li { justify-content: space-between; }
.list.links a { font-weight: 500; }
.tick {
    width: 20px;
    height: 20px;
    flex: none;
    border-radius: 50%;
    border: 1.5px solid #8E9AAA;
    background: #fff;
    cursor: pointer;
    padding: 0;
    display: inline-block;
    vertical-align: middle;
}
.tick:hover { border-color: var(--good); background: var(--good-bg); }
.tick.done { background: var(--good); border-color: var(--good); position: relative; }
.tick.done::after {
    content: "";
    position: absolute;
    left: 5.5px;
    top: 2.5px;
    width: 5px;
    height: 9px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
.tick.ro { cursor: default; opacity: 0.5; }
.add-row { display: flex; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--line-soft); flex-wrap: wrap; }
.add-row input[type=text] { flex: 1; min-width: 180px; }
.add-row input[type=date] { width: 150px; }
.add-row select { width: auto; min-width: 140px; }

/* ---------- Pills and status selects ---------- */

.pill {
    display: inline-block;
    padding: 0 9px;
    border-radius: 999px;
    font-size: 12.5px;
    font-weight: 500;
    line-height: 22px;
    white-space: nowrap;
    border: 1px solid transparent;
}
.p-on_track, .p-solved { background: var(--good-bg); color: var(--good-text); }
.p-off_track, .p-high { background: var(--bad-bg); color: var(--bad-text); }
.p-done, .p-closed { background: #E7EBF0; color: #3B4757; }
.p-dropped, .p-parked, .p-low { background: #F1F3F5; color: var(--muted); }
.p-medium { background: var(--warn-bg); color: var(--warn); }
.p-open { background: #fff; border-color: var(--line); color: var(--text); }
.p-live { background: var(--brand-tint); color: var(--brand-text); }
.p-private { background: #EEF0F8; color: #3D4670; }
select.status-select { width: auto; height: 30px; font-size: 13px; font-weight: 500; padding: 0 26px 0 10px; border-radius: 999px; }
select.s-on_track { background-color: var(--good-bg); color: var(--good-text); border-color: #BCE0CA; }
select.s-off_track { background-color: var(--bad-bg); color: var(--bad-text); border-color: #F0C0C0; }
select.s-done { background-color: #E7EBF0; color: #3B4757; }
select.s-dropped { color: var(--muted); }

/* ---------- Buttons and forms ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 36px;
    padding: 0 14px;
    border-radius: 6px;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--text);
    font: inherit;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
}
.btn:hover { border-color: #AEB8C4; background: var(--head-bg); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--ink); font-weight: 600; }
.btn.primary:hover { background: var(--brand-hover); border-color: var(--brand-hover); }
.btn.small { height: 30px; padding: 0 10px; font-size: 13px; }
.btn.ghost { border-color: transparent; background: transparent; color: var(--muted); }
.btn.ghost:hover { color: var(--text); background: #EAEEF2; }
.btn.danger { color: var(--bad); }
.btn.danger:hover { border-color: var(--bad); background: var(--bad-bg); }
.btn.wide { width: 100%; height: 40px; }
form.inline { display: inline; margin: 0; }
label { display: block; font-weight: 500; font-size: 13px; margin-bottom: 4px; }
.field { margin-bottom: 14px; }
.hint { color: var(--muted); font-size: 12.5px; margin-top: 4px; font-weight: 400; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=number], input[type=url], input[type=search], select, textarea {
    width: 100%;
    height: 38px;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background-color: #fff;
    font: inherit;
    color: var(--text);
}
textarea { height: auto; min-height: 96px; padding: 8px 10px; line-height: 1.5; resize: vertical; }
textarea.tall { min-height: 360px; font-size: 13.5px; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--ink); outline-offset: 0; border-color: var(--ink); }
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 0 14px; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 400; font-size: 14px; }
.check input { width: 16px; height: 16px; margin: 0; accent-color: var(--ink); }
.row-form { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.row-form .field { margin: 0; }
.row-form .grow { flex: 1; min-width: 200px; }
.form-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 4px; }
.box { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; padding: 18px; margin-bottom: 20px; }
.box h2 { margin: 0 0 14px; font-size: 16px; }
.empty-state { padding: 26px 18px; text-align: center; color: var(--muted); }
.empty-state p { margin: 0 auto 12px; max-width: 52ch; }
details.more > summary { cursor: pointer; color: var(--muted); font-size: 13px; list-style: none; display: inline-block; }
details.more > summary::-webkit-details-marker { display: none; }
details.more > summary:hover { color: var(--text); }
details.more[open] > summary { margin-bottom: 10px; }
details.more .box { margin: 6px 0 0; }

/* ---------- Tiles ---------- */

.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; margin-bottom: 24px; }
a.tile { display: block; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; text-decoration: none; color: var(--text); }
a.tile:hover { border-color: var(--brand); }
a.tile strong { display: block; font-weight: 600; margin-bottom: 2px; }
a.tile span { color: var(--muted); font-size: 13px; }
.group-title { font-size: 15px; font-weight: 600; margin: 4px 0 10px; }

/* ---------- Department cards ---------- */

.dept-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
a.dept-card { display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; text-decoration: none; color: var(--text); }
a.dept-card:hover { border-color: #AEB8C4; }
.dept-card h2 { font-size: 15.5px; margin: 0 0 2px; display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.dept-card .stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 14px; }
.stat b { display: block; font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; }
.stat span { font-size: 12px; color: var(--muted); }
.stat.bad b { color: var(--bad); }
.stat.good b { color: var(--good); }

/* ---------- Meeting runner ---------- */

.meeting { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 24px; align-items: start; }
.agenda { position: sticky; top: 20px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 10px 10px; }
.agenda .timer { padding: 0 10px 12px; margin-bottom: 6px; border-bottom: 1px solid var(--line-soft); }
.agenda .timer b { display: block; font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; }
.agenda .timer span { color: var(--muted); font-size: 12.5px; }
.agenda .timer.over b { color: var(--bad); }
.agenda ol { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.agenda li a { display: flex; gap: 8px; align-items: baseline; padding: 7px 10px; border-radius: 6px; color: var(--text); text-decoration: none; }
.agenda li a::before { counter-increment: step; content: counter(step); color: var(--muted); font-size: 12px; width: 14px; font-variant-numeric: tabular-nums; }
.agenda li a:hover { background: var(--paper); }
.agenda .mins { margin-left: auto; color: var(--muted); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.agenda .end { margin-top: 10px; padding: 10px 10px 2px; border-top: 1px solid var(--line-soft); }
.section { scroll-margin-top: 16px; }
.section .panel-head h2 .mins-inline { color: var(--muted); font-weight: 400; font-size: 13px; margin-left: 6px; }
.prompt { color: var(--muted); margin: 0; }
.issue { padding: 14px 18px; border-bottom: 1px solid var(--line-soft); }
.issue:last-child { border-bottom: 0; }
.issue-top { display: flex; gap: 12px; align-items: flex-start; }
.issue-top .grow { flex: 1; min-width: 0; }
.issue-title { font-weight: 500; }
.issue-details { color: var(--muted); font-size: 13px; margin: 4px 0 0; white-space: pre-line; }
.issue details.more { margin-top: 8px; }
.solve-form { display: grid; gap: 10px; }
.solve-form .form-row { gap: 10px; }
.closed-banner { background: #E7EBF0; border-radius: var(--radius); padding: 12px 16px; margin-bottom: 18px; display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }

/* ---------- Handbook pages ---------- */

.doc-body { max-width: 74ch; font-size: 15px; line-height: 1.65; }
.doc-body h2 { font-size: 19px; margin: 26px 0 8px; }
.doc-body h3 { font-size: 16px; margin: 22px 0 6px; }
.doc-body h4 { font-size: 15px; margin: 18px 0 6px; }
.doc-body h2:first-child, .doc-body h3:first-child { margin-top: 0; }
.doc-body ul, .doc-body ol { padding-left: 22px; margin: 0 0 12px; }
.doc-body li { margin-bottom: 4px; }
.doc-body a { color: #1E5AA0; }
.doc-layout { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 24px; align-items: start; }

/* ---------- Sign in ---------- */

.auth { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; background: var(--ink); }
.auth-card { width: 100%; max-width: 400px; background: #fff; border-radius: 12px; padding: 28px 28px 22px; }
.auth-card h1 { font-size: 22px; margin: 0 0 6px; }
.auth-card form { margin-top: 18px; }
.auth-brand { display: flex; align-items: center; gap: 10px; font-weight: 600; margin-bottom: 22px; }
.secret { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; background: #F1F3F6; padding: 2px 6px; border-radius: 4px; word-break: break-all; }


/* ---------- Details added for specific pages ---------- */

.sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.good-text { color: var(--good); }
.bad-text { color: var(--bad); }
.label-like { display: block; font-weight: 500; font-size: 13px; margin: 0 0 4px; }
.pre { white-space: pre-line; margin: 0 0 8px; }
pre.code {
    background: var(--ink);
    color: #E6EAF0;
    padding: 14px 16px;
    border-radius: 6px;
    overflow-x: auto;
    font-size: 12.5px;
    line-height: 1.55;
    margin: 0 0 10px;
}
.stack > * + * { margin-top: 0; }
.stack-sm { display: grid; gap: 8px; justify-items: start; }
.stack-sm textarea { width: 100%; }
.seg { display: inline-flex; gap: 2px; background: #E7EBF0; padding: 3px; border-radius: 8px; }
.seg .btn { height: 28px; border-radius: 6px; }
.seg .btn.ghost { color: var(--muted); }
.seg .btn.on-seg { background: #fff; border-color: #fff; color: var(--text); box-shadow: 0 1px 0 rgba(29, 36, 48, 0.08); }
.filter-summary { margin: 0 0 9px auto; color: var(--muted); font-size: 13px; }
.danger-zone { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line-soft); }
.panel-body.tight { padding-bottom: 6px; }
.panel-body.tight .prompt { margin-bottom: 8px; }
.subhead { padding: 10px 18px; background: var(--head-bg); color: var(--muted); font-size: 12.5px; font-weight: 500; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.checks { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.close-form { border-top: 1px solid var(--line-soft); }
.act-cell { padding-right: 18px !important; }
.score .act-cell { border-bottom: 1px solid var(--line-soft); }
.tick-cell { width: 36px; }
.add-row.top { border-top: 0; border-bottom: 1px solid var(--line-soft); }
.week-pick select { width: auto; height: 36px; }
.issue-actions { flex: none; display: flex; gap: 4px; }
.solution { margin: 8px 0 0; padding: 8px 12px; background: var(--good-bg); border-radius: 6px; color: var(--good-text); font-size: 13px; }
details.solve { margin-top: 10px; padding-left: 0; }
details.solve > summary { list-style: none; }
details.solve > summary::-webkit-details-marker { display: none; }
details.solve[open] > summary { margin-bottom: 10px; background: var(--head-bg); }
.issue > details.solve { margin-left: 0; }
select.s-prio-high { background-color: var(--bad-bg); color: var(--bad-text); border-color: #F0C0C0; }
select.s-prio-medium { background-color: var(--warn-bg); color: var(--warn); border-color: #EFD6A2; }
select.s-prio-low { color: var(--muted); }
.issue-top select.status-select { width: 96px; }
details.add-issue { padding: 0; border: 0; background: transparent; margin-bottom: 18px; }
details.add-issue > summary { list-style: none; }
details.add-issue > summary::-webkit-details-marker { display: none; }
details.add-issue[open] > summary { margin-bottom: 12px; }
details.add-issue[open] .issue-add { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.logins { border-color: var(--brand); }
.dept-row { padding: 16px 18px 12px; position: relative; }
.dept-row .form-row { gap: 0 12px; }
.dept-row .field { margin-bottom: 10px; }
.dept-row .row-extra { display: flex; gap: 6px; position: absolute; right: 14px; bottom: 12px; }
.tile-wrap { position: relative; }
.tile-wrap a.tile { height: 100%; }
.tile-edit { position: absolute; top: 10px; right: 12px; font-size: 12.5px; color: var(--muted); }
@media (max-width: 900px) {
    .dept-row .row-extra { position: static; margin-top: 8px; }
    .filter-summary { margin-left: 0; width: 100%; }
}


/* ---------- Layout refinements ---------- */

@media (min-width: 901px) {
    .shell { background: linear-gradient(to right, var(--ink) 236px, transparent 236px); }
}
.tabs.wrap { flex-wrap: wrap; overflow: visible; row-gap: 0; }
.score.compact .sc-name { min-width: 170px; max-width: 220px; }
.score.compact .blk { width: 64px; padding: 0 6px; font-size: 13px; }
.score.compact .sc-goal { padding: 8px 6px; }
.cols-prio { table-layout: fixed; min-width: 760px; }
.cols-prio .c-title { width: auto; }
.cols-prio .c-owner { width: 160px; }
.cols-prio .c-due { width: 150px; }
.cols-prio .c-status { width: 150px; }
.cols-prio .c-act { width: 190px; }
.issue { position: relative; }
.issue.can-solve .issue-actions { margin-right: 64px; }
.issue.can-solve > details.solve { margin: 0; }
.issue.can-solve > details.solve > summary { position: absolute; top: 12px; right: 18px; }
.issue.can-solve > details.solve[open] > .solve-form { margin-top: 12px; }
.issue-top select.status-select { width: 112px; }
details.add-in-meeting > summary.btn { color: var(--text); font-size: 13px; }
details.add-in-meeting[open] > summary { margin-bottom: 0; }


/* Name and goal stay in view while the weeks scroll */
.score .sc-name { width: 240px; min-width: 240px; max-width: 240px; }
.score .sc-goal { position: sticky; left: 240px; z-index: 1; background: #fff; width: 86px; min-width: 86px; box-shadow: 1px 0 0 var(--line-soft); }
.score thead .sc-goal { background: var(--head-bg); z-index: 2; }
.score .sc-name { box-shadow: none; }
.score.compact .sc-name { width: 180px; min-width: 180px; max-width: 180px; }
.score.compact .sc-goal { left: 180px; width: 72px; min-width: 72px; }
.panel-head { flex-wrap: wrap; }
.panel-head .sub { white-space: normal; }
@media (max-width: 900px) {
    .score .sc-name, .score.compact .sc-name { width: 150px; min-width: 150px; max-width: 150px; }
    .score .sc-goal, .score.compact .sc-goal { left: 150px; width: 70px; min-width: 70px; font-size: 12.5px; }
}

/* ---------- Getting started ---------- */

.guide { border-color: var(--brand); }
.guide-steps { list-style: none; margin: 0; padding: 4px 0; counter-reset: gs; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.guide-steps li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 18px; counter-increment: gs; }
.guide-steps .step-mark { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid #AEB8C4; display: grid; place-items: center; font-size: 12px; font-weight: 600; color: var(--muted); }
.guide-steps .step-mark::before { content: counter(gs); }
.guide-steps li.done .step-mark { background: var(--good); border-color: var(--good); }
.guide-steps li.done .step-mark::before { content: ""; width: 5px; height: 10px; border: solid #fff; border-width: 0 2px 2px 0; transform: translateY(-1px) rotate(45deg); }
.guide-steps li.done a { color: var(--muted); text-decoration: line-through; text-decoration-color: #AEB8C4; }

/* ---------- Small screens ---------- */

@media (max-width: 1080px) {
    .grid-2 { grid-template-columns: 1fr; }
    .doc-layout { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
    .shell { grid-template-columns: minmax(0, 1fr); }
    .side, .main { min-width: 0; }
    .side { position: static; height: auto; overflow: visible; }
    .brand { padding: 14px 16px 10px; }
    .nav { flex-direction: row; overflow-x: auto; padding: 0 12px 12px; gap: 4px; scrollbar-width: none; }
    .nav a { flex: none; white-space: nowrap; padding: 7px 12px; }
    .nav a.on::before { display: none; }
    .nav .gap { display: none; }
    .side-foot { display: flex; justify-content: space-between; align-items: center; padding: 10px 16px; margin: 0; }
    .side-foot .row { margin: 0; }
    .side-foot .role { display: none; }
    .main { padding: 20px 16px 40px; }
    .grid-halves { grid-template-columns: 1fr; }
    .meeting { grid-template-columns: 1fr; }
    .agenda { position: static; }
    .agenda ol { display: flex; overflow-x: auto; gap: 2px; }
    .agenda li a { white-space: nowrap; }
    .page-head h1 { font-size: 21px; }
    .panel-head { padding: 12px 14px; }
    .list li, .list.compact li { padding-left: 14px; padding-right: 14px; }
    .tbl th:first-child, .tbl td:first-child { padding-left: 14px; }
    .score .sc-name { padding-left: 14px; }
}

@media (max-width: 900px) {
    .issue-top { flex-wrap: wrap; }
    .issue.can-solve .issue-actions { margin-right: 0; }
    .issue.can-solve > details.solve > summary { position: static; margin-top: 10px; }
    .cols-prio { min-width: 680px; }
}

@media (prefers-reduced-motion: reduce) {
    * { scroll-behavior: auto !important; }
}

@media print {
    .side, .actions, .add-row, .panel-foot, .agenda { display: none !important; }
    .shell { display: block; }
    body { background: #fff; }
}
