:root {
  --red: #bc2336; --red-dark: #96182a; --red-soft: #fbe9eb;
  --amber: #c98a00; --amber-soft: #fff4d6;
  --green: #1f7a4d; --green-soft: #e3f4ea;
  --ink: #1d2126; --muted: #6b7280; --line: #e5e7eb; --bg: #f5f6f8; --card: #fff;
  --radius: 10px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font: 15px/1.5 "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif; color: var(--ink); background: var(--bg); }
a { color: var(--red); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.55rem; margin: 0 0 .6rem; }
h2 { font-size: 1.15rem; margin: 0 0 .6rem; }
h3 { font-size: 1rem; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.pre { white-space: pre-wrap; }

/* top bar */
.licence-banner { background: var(--amber-soft); color: #6b4a00; text-align: center; padding: .5rem 1rem; font-weight: 600; border-bottom: 1px solid #f0d58a; }
.topbar { display: flex; align-items: center; gap: 2rem; background: var(--red); color: #fff; padding: .55rem 1.5rem; position: sticky; top: 0; z-index: 10; box-shadow: 0 2px 8px rgba(0,0,0,.12); }
.brand { display: flex; align-items: center; gap: 1rem; color: #fff; }
.brand:hover { text-decoration: none; }
.brand img { height: 46px; display: block; }
.wordmark { font-weight: 800; font-size: 1.25rem; color: #fff; letter-spacing: -.01em; }
.wordmark b { color: #fff; font-weight: 700; }
.appname { border-left: 1px solid rgba(255,255,255,.4); padding-left: 1rem; color: #fff; font-weight: 600; opacity: .95; }
.topbar nav { display: flex; gap: .3rem; flex: 1; }
.topbar nav a { color: #fff; padding: .45rem .85rem; border-radius: 8px; font-weight: 600; opacity: .9; }
.topbar nav a:hover { background: rgba(255,255,255,.14); text-decoration: none; opacity: 1; }
.topbar nav a.on { background: #fff; color: var(--red); opacity: 1; }
.who { display: flex; align-items: center; gap: 1rem; font-size: .9rem; }
.who a, .who button.link { color: #fff; }
.who form { margin: 0; }

main { max-width: 1180px; margin: 0 auto; padding: 1.5rem; }
main.auth { max-width: 460px; padding-top: 4rem; }

/* cards & layout */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem 1.4rem; margin-bottom: 1.2rem; }
.card.flush { padding: 0; overflow: hidden; }
.card .pad { padding: 0 1.4rem; }
.card h2.pad { padding-top: 1.1rem; }
.narrow { max-width: 460px; margin-left: auto; margin-right: auto; }
.narrow.wide { max-width: 760px; }
.pagehead { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin: .4rem 0 1rem; }
.pagehead h1, .pagehead h2 { margin: 0; }
.actions { display: flex; gap: .5rem; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.row3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1rem; align-items: end; }
@media (max-width: 720px) { .row2, .row3 { grid-template-columns: 1fr; } .topbar { flex-wrap: wrap; gap: .6rem; } .appname { display: none; } }

/* forms */
label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .9rem; }
input, select, textarea { font: inherit; display: block; width: 100%; margin-top: .3rem; padding: .55rem .7rem; border: 1px solid #cfd4da; border-radius: 8px; background: #fff; color: var(--ink); }
input:focus, select:focus, textarea:focus { outline: 2px solid rgba(188, 35, 54, .25); border-color: var(--red); }
input[type=checkbox], input[type=radio] { width: auto; display: inline; margin: 0 .4rem 0 0; accent-color: var(--red); }
input:disabled { background: #f1f2f4; color: var(--muted); }
label.check { font-weight: 500; display: flex; align-items: center; gap: .2rem; }
label.check.bottom { margin-bottom: 1.4rem; }
input.tiny { width: 4.5rem; display: inline-block; margin: 0 .3rem; }
form.inline { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; margin: 0 0 .8rem; }
form.inline input, form.inline select { width: auto; margin: 0; }
.formactions { display: flex; gap: .6rem; margin-top: .6rem; }

.btn { display: inline-block; background: var(--red); color: #fff; border: 1px solid var(--red); padding: .55rem 1.05rem; border-radius: 8px; font: inherit; font-weight: 600; cursor: pointer; text-align: center; }
.btn:hover { background: var(--red-dark); text-decoration: none; }
.btn.ghost { background: #fff; color: var(--red); }
.btn.ghost:hover { background: var(--red-soft); }
.btn.small { padding: .3rem .7rem; font-size: .85rem; }
.btn.full { width: 100%; }
.btn.danger { background: #fff; color: #b42318; border-color: #f0b6b0; }
.btn.danger:hover { background: #fdecea; }
button.link { background: none; border: 0; color: var(--red); cursor: pointer; font: inherit; padding: 0; }

.flash { padding: .7rem 1rem; border-radius: 8px; margin-bottom: 1rem; border: 1px solid; }
.flash.ok { background: var(--green-soft); border-color: #b8e0c9; color: #135436; }
.flash.error { background: #fdecea; border-color: #f4c2bd; color: #8a1c13; }
.flash.warn { background: var(--amber-soft); border-color: #f0d58a; color: #6b4a00; }

/* chips / tags / dots */
.chip { display: inline-block; padding: .25rem .7rem; border-radius: 999px; font-weight: 700; font-size: .8rem; white-space: nowrap; }
.chip.banned { background: var(--red); color: #fff; }
.chip.yellow { background: #f6c343; color: #4a3400; }
.chip.clear { background: var(--green-soft); color: var(--green); }
.tag { display: inline-block; padding: .05rem .5rem; border-radius: 6px; font-size: .75rem; font-weight: 600; background: #eef0f3; color: #4b5563; margin-left: .3rem; white-space: nowrap; }
.tag.bad { background: #fdecea; color: #b42318; }
.tag.warn { background: var(--amber-soft); color: #7a5300; }
.tag.ok { background: var(--green-soft); color: var(--green); }
.dot { display: inline-block; width: .7rem; height: .9rem; border-radius: 2px; margin-right: .4rem; vertical-align: -1px; }
.dot.red { background: var(--red); }
.dot.yellow { background: #f6c343; }

/* home / check */
.hero { background: linear-gradient(135deg, var(--red), #7e1424); color: #fff; border-radius: 14px; padding: 2rem 2rem 1.8rem; margin-bottom: 1.2rem; }
.hero h1 { font-size: 1.7rem; margin-bottom: 1rem; }
.searchbar { display: flex; gap: .6rem; }
.searchbar input { margin: 0; font-size: 1.15rem; padding: .8rem 1rem; border: 0; }
.searchbar .btn { background: #fff; color: var(--red); border-color: #fff; padding: 0 1.6rem; font-size: 1.05rem; }
.results { margin-bottom: 1.4rem; }
.result { display: flex; align-items: center; gap: 1.2rem; background: #fff; border: 1px solid var(--line); border-left: 8px solid var(--green); border-radius: var(--radius); padding: 1rem 1.2rem; margin-bottom: .6rem; color: var(--ink); }
.result:hover { text-decoration: none; box-shadow: 0 2px 10px rgba(0,0,0,.06); }
.result.banned { border-left-color: var(--red); background: linear-gradient(90deg, var(--red-soft), #fff 40%); }
.result.yellow { border-left-color: #f6c343; background: linear-gradient(90deg, var(--amber-soft), #fff 40%); }
.result.none { border-left-color: #cfd4da; }
.result.small { padding: .55rem 1rem; }
.r-main { flex: 0 0 34%; }
.r-name { font-weight: 700; font-size: 1.1rem; }
.r-sub { color: var(--muted); font-size: .88rem; }
.r-detail { flex: 1; font-size: .92rem; }
.nearhead { color: var(--muted); font-weight: 600; margin: 1.1rem 0 .5rem; }
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-bottom: 1.2rem; }
@media (max-width: 720px) { .tiles { grid-template-columns: 1fr 1fr; } }
.tile { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.2rem; color: var(--ink); border-top: 4px solid #cfd4da; }
.tile:hover { text-decoration: none; box-shadow: 0 2px 10px rgba(0,0,0,.06); }
.tile b { display: block; font-size: 2rem; line-height: 1.1; }
.tile span { color: var(--muted); font-size: .9rem; }
.tile.red { border-top-color: var(--red); } .tile.red b { color: var(--red); }
.tile.amber { border-top-color: #f6c343; } .tile.amber b { color: #a87100; }

/* tables */
table.list { width: 100%; border-collapse: collapse; }
table.list th { text-align: left; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); padding: .65rem .9rem; border-bottom: 1px solid var(--line); background: #fafbfc; }
table.list td { padding: .65rem .9rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.list tr:last-child td { border-bottom: 0; }
table.list tbody tr, table.list tr[onclick] { cursor: pointer; }
table.list tr[onclick]:hover td { background: #fbf6f7; }
table.list a { color: var(--ink); font-weight: 600; }
table.compact td { padding: .4rem .6rem; }
table.compact input, table.compact select { margin: 0; padding: .35rem .5rem; }
tr.inactive td { color: var(--muted); }
td.clip { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.filters { display: flex; gap: .6rem; align-items: center; margin-bottom: 1rem; flex-wrap: wrap; }
.filters select, .filters input { width: auto; margin: 0; }
.filters input { min-width: 260px; }
.count { color: var(--muted); font-size: .9rem; margin-left: auto; }
h2 .count { font-weight: 500; margin-left: .4rem; }

/* operative page */
.status-banner { display: flex; justify-content: space-between; align-items: center; gap: 1rem; border-radius: 14px; padding: 1.4rem 1.6rem; margin-bottom: 1.2rem; color: #fff; background: var(--green); }
.status-banner.banned { background: linear-gradient(135deg, var(--red), #7e1424); }
.status-banner.yellow { background: linear-gradient(135deg, #f6c343, #e0a800); color: #3d2b00; }
.status-banner h1 { margin: 0; font-size: 1.8rem; }
.status-banner .meta { opacity: .9; }
.big-status { text-align: right; font-weight: 800; font-size: 1.15rem; letter-spacing: .02em; }
.big-status small { display: block; font-weight: 500; font-size: .88rem; opacity: .9; letter-spacing: 0; }
.timeline { margin-bottom: 1.2rem; }
.tl-item { background: #fff; border: 1px solid var(--line); border-left: 6px solid #cfd4da; border-radius: var(--radius); padding: 1rem 1.2rem; margin-bottom: .8rem; }
.tl-item.red.active { border-left-color: var(--red); }
.tl-item.yellow.active { border-left-color: #f6c343; }
.tl-item.lifted, .tl-item.ended { opacity: .85; }
.tl-head { font-size: 1rem; margin-bottom: .5rem; }
.tl-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .4rem 1rem; margin: 0 0 .5rem; }
.tl-grid dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.tl-grid dd { margin: 0; font-weight: 600; }
.tl-text { margin: .3rem 0; white-space: pre-wrap; }
.tl-text.lift { background: var(--green-soft); padding: .4rem .7rem; border-radius: 6px; }
.tl-actions { display: flex; gap: .5rem; margin-top: .6rem; }
.tl-actions form { margin: 0; }
.tl-foot { font-size: .78rem; color: var(--muted); margin-top: .5rem; }
.danger-zone summary { cursor: pointer; font-weight: 600; color: var(--muted); }
.danger-zone[open] summary { margin-bottom: .8rem; }
.similar { background: var(--amber-soft); border: 1px solid #f0d58a; border-radius: 8px; padding: .7rem 1rem; margin-bottom: 1rem; }
.similar ul { margin: .3rem 0 0; }

/* card form */
.cardpick { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1rem; }
.pick { display: flex; gap: .6rem; align-items: flex-start; border: 2px solid var(--line); border-radius: 10px; padding: .8rem 1rem; cursor: pointer; margin: 0; font-weight: 400; }
.pick b { display: block; font-size: 1rem; }
.pick span { color: var(--muted); }
.pick input { margin-top: .3rem; }
.pick.red:has(input:checked) { border-color: var(--red); background: var(--red-soft); }
.pick.yellow:has(input:checked) { border-color: #e0a800; background: var(--amber-soft); }
.guide { background: #f1f5ff; border: 1px solid #d6e0fb; color: #23407a; border-radius: 8px; padding: .55rem .8rem; margin: -.4rem 0 1rem; font-size: .9rem; }
.quickmonths { margin: -.4rem 0 1rem; font-size: .88rem; color: var(--muted); display: flex; gap: .4rem; align-items: center; }

/* MFA */
input.code { font-size: 1.6rem; letter-spacing: .4em; text-align: center; margin-bottom: 1rem; }
.qr { display: flex; justify-content: center; margin: .5rem 0; }
.qr svg { width: 200px; height: 200px; }
.secret { font-family: Consolas, monospace; font-size: 1.1rem; text-align: center; background: var(--bg); padding: .6rem; border-radius: 8px; letter-spacing: .05em; }
ol.steps { padding-left: 1.2rem; margin: .5rem 0; }

/* admin */
.subnav { display: flex; gap: .3rem; margin-bottom: 1.2rem; border-bottom: 1px solid var(--line); }
.subnav a { padding: .5rem .9rem; color: var(--muted); font-weight: 600; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.subnav a.on { color: var(--red); border-bottom-color: var(--red); }
.subnav a:hover { text-decoration: none; color: var(--ink); }
.okline { color: var(--green); }
.warnline { color: #8a5a00; }

/* dashboard */
.kpis { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; margin-bottom: 1.2rem; }
@media (max-width: 900px) { .kpis { grid-template-columns: 1fr 1fr; } }
.kpi { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1.1rem; color: var(--ink); display: flex; flex-direction: column-reverse; justify-content: flex-end; }
a.kpi:hover { text-decoration: none; box-shadow: 0 2px 10px rgba(0,0,0,.06); }
.kpi b { font-size: 2.1rem; line-height: 1.1; font-weight: 700; }
.kpi span { color: var(--muted); font-size: .88rem; }
.kpi.red { border-top: 4px solid var(--red); } .kpi.red b { color: var(--red); }
.kpi.amber { border-top: 4px solid #d39a00; } .kpi.amber b { color: #8a6400; }
.kpi.warn b { color: #b42318; }
.dash-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.dash-grid .card { margin: 0; }
.dash-grid .wide { grid-column: 1 / -1; }
@media (max-width: 900px) { .dash-grid { grid-template-columns: 1fr; } }
.chart-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.legend { display: flex; gap: 1rem; font-size: .85rem; color: var(--muted); }
.legend .sw { display: inline-block; width: .7rem; height: .7rem; border-radius: 2px; margin-right: .35rem; vertical-align: -1px; }
.sw.red, .seg.red, .hb-fill.red { background: var(--red); }
.sw.yellow, .seg.yellow, .hb-fill.yellow { background: #d39a00; }
.hb-fill.muted { background: #b6bcc5; }
.cols { display: flex; align-items: stretch; gap: 10px; height: 220px; padding-top: 1.2rem; border-bottom: 1px solid var(--line); margin-top: .4rem; }
.col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; position: relative; cursor: default; }
.col:hover .col-stack { filter: brightness(1.08); }
.col-val { font-size: .8rem; font-weight: 600; color: var(--ink); margin-bottom: 4px; min-height: 1em; }
.col-stack { width: 100%; max-width: 46px; display: flex; flex-direction: column; gap: 2px; border-radius: 4px 4px 0 0; overflow: hidden; min-height: 0; }
.col-stack .seg { min-height: 2px; }
.col-lab { position: absolute; bottom: -2.4rem; font-size: .78rem; color: var(--muted); text-align: center; line-height: 1.15; }
.col-lab small { display: block; font-size: .7rem; }
.cols + * { margin-top: 2.6rem; }
.dash-grid .wide .cols { margin-bottom: 2.4rem; }
.hbars { display: flex; flex-direction: column; gap: .55rem; margin-top: .3rem; }
.hbar { display: grid; grid-template-columns: minmax(110px, 38%) 1fr 2.2rem; align-items: center; gap: .7rem; font-size: .9rem; cursor: default; }
.hbar:hover .hb-track { background: #eef0f3; }
.hb-lab { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hb-track { height: 14px; border-radius: 0 4px 4px 0; }
.hb-fill { display: block; height: 100%; border-radius: 0 4px 4px 0; min-width: 2px; }
.hb-stack { display: flex; height: 100%; gap: 2px; }
.hb-stack .hb-fill { border-radius: 0; }
.hb-stack .hb-fill:last-child { border-radius: 0 4px 4px 0; }
.hb-val { font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.tip { position: fixed; z-index: 50; background: #1d2126; color: #fff; font-size: .82rem; padding: .35rem .6rem; border-radius: 6px; pointer-events: none; white-space: nowrap; }

/* qualifications */
.meta-link { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.qstate { display: inline-block; padding: .15rem .6rem; border-radius: 999px; font-size: .75rem; font-weight: 700; white-space: nowrap; }
.qstate.valid { background: var(--green-soft); color: var(--green); }
.qstate.expiring { background: var(--amber-soft); color: #7a5300; }
.qstate.expired { background: #fdecea; color: #b42318; }
.qstate.no_expiry { background: #eef0f3; color: #4b5563; }
.qgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; margin-bottom: 1.4rem; }
.qcard { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1rem; display: flex; flex-direction: column; gap: .5rem; border-top: 4px solid #1f7a4d; }
.qcard.expiring { border-top-color: #d39a00; }
.qcard.expired { border-top-color: #b42318; background: #fffafa; }
.qcard.no_expiry { border-top-color: #b6bcc5; }
.qc-head { display: flex; justify-content: space-between; align-items: flex-start; gap: .5rem; }
.qc-name { font-weight: 700; font-size: 1.02rem; }
.qc-num { color: var(--muted); font-size: .85rem; font-family: Consolas, monospace; }
.qc-dates { display: flex; gap: 1rem; flex-wrap: wrap; font-size: .85rem; color: #4b5563; }
.qc-files { display: flex; gap: .5rem; flex-wrap: wrap; }
.qthumb { display: flex; align-items: center; justify-content: center; width: 104px; height: 68px; border-radius: 6px; overflow: hidden; border: 1px solid var(--line); background: #f3f4f6; }
.qthumb img { width: 100%; height: 100%; object-fit: cover; }
.qthumb:hover { outline: 2px solid var(--red); text-decoration: none; }
.qthumb.doc { font-weight: 700; color: var(--red); font-size: .9rem; }
.qc-nofiles { font-size: .85rem; color: var(--muted); font-style: italic; }
.qc-notes { font-size: .85rem; white-space: pre-wrap; }
.qc-actions { margin-top: auto; font-size: .85rem; padding-top: .3rem; border-top: 1px solid var(--line); }
.qstats { display: flex; gap: 1rem; margin-top: .4rem; }
.qstats a { flex: 1; border: 1px solid var(--line); border-radius: 8px; padding: .6rem .8rem; color: var(--muted); font-size: .88rem; }
.qstats a:hover { text-decoration: none; background: #fafbfc; }
.qstats b { display: block; font-size: 1.6rem; color: var(--ink); line-height: 1.1; }
.qstats a.bad b { color: #b42318; } .qstats a.warn b { color: #8a6400; }

/* upload */
.upload { margin-bottom: 1rem; }
.dropzone { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .3rem; border: 2px dashed #cfd4da; border-radius: 10px; padding: 1.3rem; cursor: pointer; background: #fafbfc; font-weight: 400; margin: 0; }
.dropzone:hover, .dropzone.over { border-color: var(--red); background: var(--red-soft); }
.dropzone b { color: var(--red); font-size: 1rem; }
.dropzone span { color: var(--muted); font-size: .85rem; }
.dropzone input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.previews { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: .7rem; }
.pv { position: relative; width: 120px; display: flex; flex-direction: column; gap: .2rem; font-weight: 400; margin: 0; }
.pv img, .pv .doc { width: 120px; height: 80px; object-fit: cover; border-radius: 6px; border: 1px solid var(--line); background: #f3f4f6; display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--red); }
.pv-name { font-size: .72rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pv-x { position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: rgba(0,0,0,.65); color: #fff; cursor: pointer; line-height: 1; }
.pv-remove { font-size: .8rem; display: flex; align-items: center; }
.existing { margin-bottom: 1rem; }

/* lightbox */
.lightbox { position: fixed; inset: 0; background: rgba(15,17,20,.88); z-index: 100; display: flex; align-items: center; justify-content: center; gap: 1rem; }
.lightbox[hidden] { display: none; }
.lightbox figure { margin: 0; max-width: 86vw; max-height: 90vh; text-align: center; }
.lightbox img { max-width: 86vw; max-height: 82vh; border-radius: 6px; background: #fff; }
.lightbox figcaption { color: #e5e7eb; margin-top: .5rem; font-size: .9rem; }
.lightbox button { background: rgba(255,255,255,.12); color: #fff; border: 0; border-radius: 50%; width: 46px; height: 46px; font-size: 1.8rem; cursor: pointer; line-height: 1; }
.lightbox button:hover { background: rgba(255,255,255,.25); }
.lb-close { position: absolute; top: 1rem; right: 1rem; }

/* phones */
@media (max-width: 720px) {
  .topbar { position: static; padding: .5rem .8rem; gap: .4rem; }
  .brand img { height: 36px; }
  .topbar nav { order: 3; flex-basis: 100%; overflow-x: auto; white-space: nowrap; -webkit-overflow-scrolling: touch; }
  .topbar nav a { padding: .35rem .7rem; }
  .who { margin-left: auto; font-size: .82rem; gap: .7rem; }
  main { padding: 1rem .8rem; }
  .status-banner { flex-direction: column; align-items: flex-start; }
  .big-status { text-align: left; }
  .pagehead { flex-wrap: wrap; }
  .lightbox button.lb-prev, .lightbox button.lb-next { position: absolute; bottom: 1.2rem; }
  .lb-prev { left: 1.2rem; } .lb-next { right: 1.2rem; }
  .lightbox img, .lightbox figure { max-width: 96vw; }
}

input.caps { text-transform: uppercase; }
input.caps::placeholder { text-transform: none; }

/* printing a person's record */
.print-head { display: none; }
@media print {
  @page { size: A4 portrait; margin: 12mm; }
  body { background: #fff; -webkit-print-color-adjust: exact; print-color-adjust: exact; font-size: 12px; }
  .topbar, .licence-banner, .actions, .tl-actions, .qc-actions, .danger-zone, .lightbox, .flash, .tip, nav { display: none !important; }
  .print-head { display: flex; align-items: center; gap: 12px; border-bottom: 3px solid #bc2336; padding-bottom: 8px; margin-bottom: 12px; color: #4b5563; }
  .print-head img { height: 40px; }
  main { max-width: none; padding: 0; }
  .status-banner { padding: 12px 16px; border-radius: 8px; }
  .tl-item, .qcard, .card { break-inside: avoid; box-shadow: none; }
  .qgrid { grid-template-columns: 1fr 1fr; }
  .qthumb { width: 150px; height: 98px; }
  a { color: inherit; text-decoration: none; }
}

/* reminders */
.remind-to { display: flex; align-items: center; gap: .6rem; padding: .7rem .9rem; background: var(--bg); border-radius: 8px; }
.inline-email { margin: 0; flex: 1; }
.remind-list { display: flex; flex-direction: column; gap: .4rem; margin-bottom: 1rem; }
.remind-item { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; border: 1px solid var(--line); border-radius: 8px; padding: .6rem .8rem; font-weight: 400; margin: 0; cursor: pointer; }
.remind-item:has(input:checked) { border-color: var(--red); background: #fffafa; }
.ri-main { flex: 1; min-width: 160px; }
.ri-date { font-size: .88rem; }
.ri-rem { flex-basis: 100%; font-size: .8rem; color: var(--muted); padding-left: 1.8rem; }
.email-preview { width: 100%; height: 620px; border: 1px solid var(--line); border-radius: 8px; background: #f5f6f8; }
.qc-rem { font-size: .8rem; color: var(--muted); }
.qc-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

/* CSCS / companies */
.big-status small.follows { margin-top: .2rem; font-style: italic; }
.companies { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: .6rem 1rem; margin-bottom: 1rem; display: flex; flex-wrap: wrap; gap: .4rem .6rem; align-items: center; font-size: .9rem; }
.companies .co { background: var(--bg); border-radius: 6px; padding: .1rem .55rem; }
.companies .co.now { background: var(--red-soft); color: var(--red); font-weight: 600; }
.companies details { flex-basis: 100%; }
.companies summary { cursor: pointer; color: var(--muted); font-size: .85rem; }

/* clickable month bars */
a.col { text-decoration: none; color: inherit; cursor: pointer; border-radius: 6px; }
a.col:hover { background: #fbf6f7; text-decoration: none; }
a.col:hover .col-stack { filter: brightness(1.1); }
a.col:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
.pill { display: inline-flex; align-items: center; padding: .3rem .8rem; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-size: .88rem; font-weight: 600; }
.pill:hover { text-decoration: none; background: var(--bg); }
.pill.on { background: var(--red); border-color: var(--red); color: #fff; }

/* ---- Uniform A&F sign-in (two-panel: faded sprinkler artwork + form) ---- */
.signin { display: flex; min-height: 100vh; }
.signin-visual { flex: 1.15 1 0; position: relative; overflow: hidden;
  background: linear-gradient(155deg, #fafbfc 0%, #f1f2f4 55%, #e8e9ec 100%); border-right: 1px solid var(--line); }
.signin-art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 62% center; filter: grayscale(1); opacity: .3; }
.signin-tag { position: absolute; left: 48px; top: 44px; display: flex; flex-direction: column; gap: 7px; }
.signin-kicker { font-size: .8rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--brand, #bc2336); }
.signin-title { font-size: 2.4rem; font-weight: 800; color: var(--ink); line-height: 1.02; letter-spacing: -.01em; }
.signin-form { flex: .85 1 0; min-width: 350px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 44px 32px; background: #fff; }
.signin-card { width: 100%; max-width: 360px; }
.signin-logo { height: 64px; width: auto; display: block; margin: 0 auto 20px; }
.signin-card h1 { text-align: center; margin: 0 0 4px; }
.signin-sub { text-align: center; color: var(--muted, #737a87); margin: 0 0 20px; }
.signin-foot { margin-top: 26px; color: var(--muted, #737a87); font-size: .78rem; text-align: center; }
@media (max-width: 860px) {
  .signin { flex-direction: column; }
  .signin-visual { flex: none; height: 148px; border-right: 0; border-bottom: 1px solid var(--line); }
  .signin-tag { left: 22px; top: 16px; }
  .signin-title { font-size: 1.5rem; }
  .signin-form { flex: 1 1 auto; min-width: 0; padding: 30px 20px; }
}

main.signwrap { max-width: none; margin: 0; padding: 0; }
