/* CRM هاوین — سیستم طراحی */
@font-face { font-family: Vazirmatn; src: url(../fonts/Vazirmatn-Regular.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: Vazirmatn; src: url(../fonts/Vazirmatn-Medium.woff2) format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: Vazirmatn; src: url(../fonts/Vazirmatn-Bold.woff2) format('woff2'); font-weight: 700; font-display: swap; }

:root {
  --brand: #2aa7a1; --brand-strong: #1d8a85; --brand-soft: #e3f5f4;
  --sun: #f7d64a; --sun-soft: #fff6d1;
  --bg: #f4f6f8; --surface: #ffffff; --surface-2: #f8fafb; --line: #e4e9ee;
  --text: #17222b; --muted: #66737f; --faint: #9aa6b1;
  --ok: #1f9d62; --ok-soft: #e2f6ec; --warn: #c98a07; --warn-soft: #fff4d9;
  --bad: #d64545; --bad-soft: #fde8e8; --info: #3b74d6; --info-soft: #e7effd;
  --shadow: 0 1px 2px rgba(16,32,48,.06), 0 6px 20px rgba(16,32,48,.06);
  --shadow-lg: 0 12px 40px rgba(16,32,48,.16);
  --radius: 14px; --radius-sm: 9px;
  --sidebar: 248px;
  color-scheme: light;
}
[data-theme="dark"] {
  --brand: #3cc3bc; --brand-strong: #5fd6cf; --brand-soft: #123532;
  --sun: #f2d24a; --sun-soft: #3a3214;
  --bg: #0e1418; --surface: #151d23; --surface-2: #1a242b; --line: #26323b;
  --text: #e6edf2; --muted: #9aa8b4; --faint: #6b7883;
  --ok: #3ccf8a; --ok-soft: #143326; --warn: #e8b23a; --warn-soft: #362b10;
  --bad: #f07272; --bad-soft: #3a1a1a; --info: #6f9ff0; --info-soft: #172640;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 20px rgba(0,0,0,.25);
  --shadow-lg: 0 12px 40px rgba(0,0,0,.5);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: Vazirmatn, Tahoma, sans-serif; background: var(--bg); color: var(--text);
  font-size: 14.5px; line-height: 1.75; -webkit-font-smoothing: antialiased;
  transition: background .25s, color .25s;
}
a { color: var(--brand-strong); text-decoration: none; }
a:hover { color: var(--brand); }
h1, h2, h3, h4 { margin: 0; font-weight: 700; line-height: 1.4; }
h1 { font-size: 22px; } h2 { font-size: 17px; } h3 { font-size: 15px; }
small, .muted { color: var(--muted); }
.faint { color: var(--faint); }
hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
.unit { font-size: .78em; color: var(--muted); font-weight: 400; }

/* ---------- layout */
.app { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar); flex-shrink: 0; background: var(--surface); border-left: 1px solid var(--line);
  position: fixed; inset: 0 0 0 auto; display: flex; flex-direction: column; z-index: 40;
  transition: transform .25s ease;
}
.sidebar .brand { padding: 18px 18px 10px; display: flex; align-items: center; gap: 10px; }
.sidebar .brand img { height: 36px; width: auto; }
.sidebar .brand b, .sidebar .brand .sub { white-space: nowrap; }
.sidebar .brand .sub { font-size: 11.5px; color: var(--muted); margin-top: -2px; }
.nav { padding: 8px 10px; overflow-y: auto; flex: 1; }
.nav .group { font-size: 11.5px; color: var(--faint); padding: 14px 12px 4px; font-weight: 500; }
.nav a {
  display: flex; align-items: center; gap: 11px; padding: 8px 12px; border-radius: 10px;
  color: var(--text); font-weight: 500; margin-bottom: 2px; transition: background .15s, color .15s;
}
.nav a:hover { background: var(--surface-2); color: var(--text); }
.nav a.active { background: var(--brand-soft); color: var(--brand-strong); }
.nav a.active .ico { color: var(--brand); }
.nav .ico { width: 19px; height: 19px; color: var(--muted); flex-shrink: 0; }
.nav .badge { margin-right: auto; }
.sidebar .foot { padding: 12px 14px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); }

.main { flex: 1; margin-right: var(--sidebar); min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 12px;
  padding: 12px 28px; background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(10px); border-bottom: 1px solid var(--line);
}
.topbar .search { flex: 1; max-width: 420px; position: relative; }
.topbar .search input { padding-right: 38px; background: var(--surface); }
.topbar .search .ico { position: absolute; right: 11px; top: 50%; transform: translateY(-50%); width: 18px; color: var(--faint); }
.topbar .spacer { flex: 1; }
.icon-btn {
  width: 38px; height: 38px; border-radius: 10px; display: inline-grid; place-items: center; border: 1px solid var(--line);
  background: var(--surface); color: var(--muted); cursor: pointer; position: relative; transition: all .15s;
}
.icon-btn:hover { color: var(--brand); border-color: var(--brand); }
.icon-btn .ico { width: 19px; height: 19px; }
.icon-btn .dot {
  position: absolute; top: -5px; left: -5px; min-width: 18px; height: 18px; border-radius: 9px; padding: 0 5px;
  background: var(--bad); color: #fff; font-size: 11px; line-height: 18px; text-align: center; font-weight: 700;
}
.avatar {
  width: 36px; height: 36px; border-radius: 50%; display: inline-grid; place-items: center; font-weight: 700;
  background: linear-gradient(135deg, var(--brand), var(--brand-strong)); color: #fff; font-size: 13px; flex-shrink: 0;
}
.avatar.sm { width: 28px; height: 28px; font-size: 11px; }
.avatar.sun { background: linear-gradient(135deg, #f7d64a, #eab308); color: #3d2f00; }
.menu-toggle { display: none; }
.content { padding: 24px 28px 48px; max-width: 1400px; width: 100%; }
.page-head { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head h1 { flex: 1; }
.page-head .sub { color: var(--muted); font-size: 13px; font-weight: 400; display: block; }

/* ---------- cards & grid */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-pad { padding: 18px 20px; }
.card-head { display: flex; align-items: center; gap: 10px; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.card-head h2, .card-head h3 { flex: 1; }
.card-body { padding: 16px 20px; }
.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)); }
.split { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 18px; align-items: start; }
.stack > * + * { margin-top: 18px; }

.stat { padding: 18px 20px; position: relative; overflow: hidden; }
.stat .label { color: var(--muted); font-size: 13px; display: flex; align-items: center; gap: 8px; }
.stat .value { font-size: 26px; font-weight: 700; margin-top: 6px; letter-spacing: -.3px; }
.stat .hint { font-size: 12px; color: var(--muted); }
.stat .ico-wrap { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; }
.stat .ico-wrap .ico { width: 18px; height: 18px; }
.tint-brand { background: var(--brand-soft); color: var(--brand); }
.tint-sun { background: var(--sun-soft); color: #b48a00; }
[data-theme="dark"] .tint-sun { color: var(--sun); }
.tint-ok { background: var(--ok-soft); color: var(--ok); }
.tint-info { background: var(--info-soft); color: var(--info); }
.tint-bad { background: var(--bad-soft); color: var(--bad); }

/* ---------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 8px 16px; border-radius: 10px;
  border: 1px solid transparent; font: inherit; font-weight: 500; cursor: pointer; white-space: nowrap;
  transition: transform .08s, background .15s, box-shadow .15s, border-color .15s; line-height: 1.6;
  background: var(--surface); color: var(--text); border-color: var(--line);
}
.btn:hover { border-color: var(--brand); color: var(--brand-strong); }
.btn:active { transform: translateY(1px); }
.btn .ico { width: 17px; height: 17px; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #fff; box-shadow: 0 4px 14px color-mix(in srgb, var(--brand) 35%, transparent); }
.btn-primary:hover { background: var(--brand-strong); border-color: var(--brand-strong); color: #fff; }
[data-theme="dark"] .btn-primary { color: #06201e; }
.btn-sun { background: var(--sun); border-color: var(--sun); color: #3d2f00; }
.btn-sun:hover { filter: brightness(.96); color: #3d2f00; border-color: var(--sun); }
.btn-ok { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn-ok:hover { color: #fff; filter: brightness(1.05); border-color: var(--ok); }
.btn-danger { color: var(--bad); }
.btn-danger:hover { background: var(--bad-soft); border-color: var(--bad); color: var(--bad); }
.btn-ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn-ghost:hover { background: var(--surface-2); border-color: transparent; }
.btn-sm { padding: 4px 11px; font-size: 13px; border-radius: 8px; }
.btn-block { width: 100%; }

/* ---------- forms */
.input, select.input, textarea.input {
  width: 100%; font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 8px 12px; outline: none; transition: border-color .15s, box-shadow .15s;
}
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 18%, transparent); }
select.input { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2366737f' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: left 12px center; padding-left: 32px; }
.input[disabled] { opacity: .7; background: var(--surface-2); }
input[type=number].input { direction: ltr; text-align: right; }
.ltr { direction: ltr; text-align: right; unicode-bidi: plaintext; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 18px; }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; font-size: 13px; font-weight: 500; margin-bottom: 5px; color: var(--muted); }
.field .req { color: var(--bad); }
.field .help { font-size: 12px; color: var(--faint); margin-top: 3px; }
.field .err { font-size: 12.5px; color: var(--bad); margin-top: 3px; }
.field.has-err .input { border-color: var(--bad); }
.switch { appearance: none; width: 40px; height: 22px; border-radius: 11px; background: var(--line); position: relative; cursor: pointer; transition: background .2s; vertical-align: middle; flex-shrink: 0; }
.switch::after { content: ''; position: absolute; top: 3px; right: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: right .2s; box-shadow: 0 1px 3px rgba(0,0,0,.25); }
.switch:checked { background: var(--brand); }
.switch:checked::after { right: 21px; }
.check-row { display: flex; align-items: center; gap: 10px; padding: 6px 0; }
.check-row label { margin: 0; color: var(--text); font-size: 14px; }
.form-actions { display: flex; gap: 10px; justify-content: flex-start; margin-top: 20px; flex-wrap: wrap; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }
.filters .input { width: auto; min-width: 150px; }
.filters .grow { flex: 1; min-width: 200px; }

/* ---------- tables */
.table-wrap { overflow-x: auto; }
table.t { width: 100%; border-collapse: collapse; }
.t th { text-align: right; font-size: 12.5px; font-weight: 500; color: var(--muted); padding: 11px 14px; background: var(--surface-2); border-bottom: 1px solid var(--line); white-space: nowrap; }
.t td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.t tr:last-child td { border-bottom: 0; }
.t tbody tr { transition: background .12s; }
.t tbody tr:hover { background: var(--surface-2); }
.t .num { text-align: left; direction: ltr; white-space: nowrap; }
.t .actions { text-align: left; white-space: nowrap; }
.person { display: flex; align-items: center; gap: 10px; }
.person b { font-weight: 500; display: block; line-height: 1.4; }
.person small { font-size: 12px; }

/* ---------- chips & badges */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 1px 10px; border-radius: 20px; font-size: 12px; font-weight: 500; background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); white-space: nowrap; }
.badge.brand { background: var(--brand-soft); color: var(--brand-strong); border-color: transparent; }
.badge.ok { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.badge.warn { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.badge.bad { background: var(--bad-soft); color: var(--bad); border-color: transparent; }
.badge.info { background: var(--info-soft); color: var(--info); border-color: transparent; }
.badge.sun { background: var(--sun-soft); color: #9a7400; border-color: transparent; }
[data-theme="dark"] .badge.sun { color: var(--sun); }
.tag { display: inline-block; padding: 0 8px; border-radius: 6px; font-size: 11.5px; background: var(--surface-2); color: var(--muted); border: 1px dashed var(--line); margin-left: 4px; }

/* ---------- messages */
.messages { position: fixed; bottom: 22px; left: 22px; z-index: 100; display: flex; flex-direction: column; gap: 10px; max-width: 380px; }
.toast { padding: 12px 16px; border-radius: 12px; background: var(--surface); box-shadow: var(--shadow-lg); border-right: 4px solid var(--brand); display: flex; gap: 10px; align-items: flex-start; animation: slideIn .3s ease; }
.toast.error { border-color: var(--bad); } .toast.warning { border-color: var(--warn); } .toast.info { border-color: var(--info); }
@keyframes slideIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

/* ---------- activity list */
.act { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); align-items: flex-start; }
.act:last-child { border-bottom: 0; }
.act .chk { width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--line); background: var(--surface); cursor: pointer; flex-shrink: 0; display: grid; place-items: center; margin-top: 2px; transition: all .15s; padding: 0; color: transparent; }
.act .chk:hover { border-color: var(--ok); }
.act.done .chk { background: var(--ok); border-color: var(--ok); color: #fff; }
.act.done .subj { text-decoration: line-through; color: var(--muted); }
.act .chk .ico { width: 14px; height: 14px; }
.act .body { flex: 1; min-width: 0; }
.act .subj { font-weight: 500; }
.act .meta { font-size: 12.5px; color: var(--muted); display: flex; gap: 10px; flex-wrap: wrap; }
.act.overdue .when { color: var(--bad); font-weight: 500; }
.empty { text-align: center; padding: 30px 10px; color: var(--muted); }
.empty .ico { width: 42px; height: 42px; color: var(--faint); margin-bottom: 6px; }

/* ---------- kanban */
.board { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 14px; align-items: flex-start; min-height: 60vh; }
.col { width: 272px; flex-shrink: 0; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); display: flex; flex-direction: column; max-height: calc(100vh - 210px); }
.col-head { padding: 12px 14px 10px; border-bottom: 1px solid var(--line); }
.col-head .name { font-weight: 700; display: flex; align-items: center; gap: 8px; }
.col-head .meta { font-size: 12px; color: var(--muted); display: flex; justify-content: space-between; margin-top: 2px; }
.col-head .bar { height: 3px; border-radius: 2px; background: var(--line); margin-top: 8px; overflow: hidden; }
.col-head .bar span { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), var(--sun)); }
.col-body { padding: 10px; overflow-y: auto; flex: 1; min-height: 80px; transition: background .15s; }
.col-body.over { background: var(--brand-soft); }
.dcard { background: var(--surface); border: 1px solid var(--line); border-radius: 11px; padding: 11px 12px; margin-bottom: 9px; cursor: grab; box-shadow: 0 1px 2px rgba(0,0,0,.04); transition: box-shadow .15s, transform .15s; display: block; color: var(--text); }
.dcard:hover { box-shadow: var(--shadow); color: var(--text); }
.dcard.dragging { opacity: .5; transform: rotate(2deg); }
.dcard .title { font-weight: 500; line-height: 1.5; }
.dcard .cust { font-size: 12.5px; color: var(--muted); }
.dcard .foot { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; font-size: 12.5px; }
.dcard.stale { border-right: 3px solid var(--warn); }

/* ---------- misc */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; }
.tabs a { padding: 9px 16px; color: var(--muted); border-bottom: 2px solid transparent; font-weight: 500; white-space: nowrap; }
.tabs a.active { color: var(--brand-strong); border-color: var(--brand); }
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 8px 12px; font-size: 14px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; }
.pager { display: flex; gap: 6px; justify-content: center; padding: 14px; align-items: center; }
.steps { display: flex; gap: 0; margin-bottom: 18px; overflow-x: auto; }
.steps .s { flex: 1; text-align: center; padding: 8px 6px; font-size: 12.5px; color: var(--muted); position: relative; background: var(--surface-2); border: 1px solid var(--line); margin-left: -1px; min-width: 90px; cursor: pointer; }
.steps .s:first-child { border-radius: 0 10px 10px 0; } .steps .s:last-child { border-radius: 10px 0 0 10px; }
.steps .s.done { background: var(--brand-soft); color: var(--brand-strong); }
.steps .s.cur { background: var(--brand); color: #fff; font-weight: 700; border-color: var(--brand); }
[data-theme="dark"] .steps .s.cur { color: #06201e; }
.hero-total { font-size: 28px; font-weight: 700; }
.pipeline-mini { display: flex; gap: 4px; align-items: flex-end; height: 64px; }
.pipeline-mini .b { flex: 1; background: linear-gradient(180deg, var(--brand), color-mix(in srgb, var(--brand) 55%, transparent)); border-radius: 6px 6px 2px 2px; min-height: 4px; position: relative; }
.pipeline-mini-labels { display: flex; gap: 4px; font-size: 11px; color: var(--muted); margin-top: 4px; }
.pipeline-mini-labels span { flex: 1; text-align: center; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.dropdown { position: relative; }
.dropdown .menu { position: absolute; left: 0; top: calc(100% + 8px); width: 320px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); display: none; z-index: 50; overflow: hidden; }
.dropdown.open .menu { display: block; animation: slideIn .2s ease; }
.dropdown .menu a { display: block; padding: 10px 14px; border-bottom: 1px solid var(--line); color: var(--text); font-size: 13.5px; }
.dropdown .menu a:hover { background: var(--surface-2); }
.dropdown .menu .head { padding: 10px 14px; font-weight: 700; border-bottom: 1px solid var(--line); }
.modal-bg { position: fixed; inset: 0; background: rgba(8,16,22,.5); backdrop-filter: blur(3px); z-index: 90; display: none; align-items: center; justify-content: center; padding: 16px; }
.modal-bg.open { display: flex; animation: fade .2s; }
.modal { background: var(--surface); border-radius: 16px; width: 100%; max-width: 520px; box-shadow: var(--shadow-lg); max-height: 90vh; overflow-y: auto; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.row-new { background: var(--ok-soft) !important; } .row-changed { background: var(--warn-soft) !important; } .row-error { background: var(--bad-soft) !important; }
.code { font-family: ui-monospace, Consolas, monospace; direction: ltr; display: inline-block; background: var(--surface-2); border: 1px solid var(--line); padding: 2px 8px; border-radius: 6px; font-size: 13px; word-break: break-all; }

/* ---------- jalali date picker */
.jdp { position: absolute; z-index: 120; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); padding: 12px; width: 286px; user-select: none; animation: slideIn .15s ease; }
.jdp .hd { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; font-weight: 700; }
.jdp .hd button { border: 0; background: var(--surface-2); color: var(--text); width: 30px; height: 30px; border-radius: 8px; cursor: pointer; font: inherit; }
.jdp .grid7 { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; text-align: center; }
.jdp .wd { font-size: 11px; color: var(--muted); padding: 3px 0; }
.jdp .d { padding: 6px 0; border-radius: 8px; cursor: pointer; font-size: 13px; }
.jdp .d:hover { background: var(--brand-soft); }
.jdp .d.today { outline: 1px solid var(--brand); }
.jdp .d.sel { background: var(--brand); color: #fff; }
.jdp .d.fri { color: var(--bad); }
.jdp .ft { display: flex; gap: 8px; margin-top: 10px; align-items: center; }
.jdp .ft input { width: 90px; text-align: center; }

/* ---------- login */
.login-wrap { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.login-art { background: #0b1114; position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 26px; padding: 40px; color: #cfe; }
.login-art img { width: min(380px, 80%); position: relative; z-index: 2; filter: drop-shadow(0 0 30px rgba(247,214,74,.25)); }
.login-art p { position: relative; z-index: 2; color: #9fb3b8; text-align: center; max-width: 360px; }
.login-art .glow { position: absolute; width: 520px; height: 520px; border-radius: 50%; background: radial-gradient(circle, rgba(42,167,161,.35), transparent 65%); top: -120px; left: -140px; }
.login-art .glow2 { position: absolute; width: 420px; height: 420px; border-radius: 50%; background: radial-gradient(circle, rgba(247,214,74,.22), transparent 65%); bottom: -120px; right: -100px; }
.login-form { display: flex; align-items: center; justify-content: center; padding: 30px; }
.login-form .box { width: 100%; max-width: 360px; }
.login-form h1 { font-size: 24px; margin-bottom: 4px; }

/* ---------- responsive */
@media (max-width: 1100px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .split { grid-template-columns: 1fr; } }
@media (max-width: 860px) {
  .sidebar { transform: translateX(100%); box-shadow: var(--shadow-lg); }
  body.nav-open .sidebar { transform: none; }
  body.nav-open::after { content: ''; position: fixed; inset: 0; background: rgba(0,0,0,.35); z-index: 35; }
  .main { margin-right: 0; }
  .menu-toggle { display: inline-grid; }
  .content { padding: 16px 14px 40px; }
  .topbar { padding: 10px 14px; }
  .g2, .g3, .form-grid { grid-template-columns: 1fr; }
  .login-wrap { grid-template-columns: 1fr; } .login-art { min-height: 220px; }
  .hide-sm { display: none !important; }
  .topbar .spacer { display: none; }
  .page-head h1 { flex-basis: 100%; }
  .page-head { gap: 8px; }
}
@media print { .sidebar, .topbar, .messages, .btn { display: none !important; } .main { margin: 0; } }
