/* Prime Surgical Hospital — admin panel */
:root {
    --navy: #0b1f3a; --navy-2: #12305a; --blue: #1663d6; --teal: #0fb5ae; --red: #e11d2e;
    --ink: #0f172a; --text: #334155; --muted: #64748b; --line: #e5eaf2; --bg: #f4f7fb; --card: #fff;
    --grad: linear-gradient(135deg, #1663d6, #0fb5ae);
    --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px -12px rgba(15, 23, 42, .12);
    --radius: 16px; --side: 260px;
    --font-head: 'Plus Jakarta Sans', system-ui, sans-serif; --font-body: 'Inter', system-ui, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font-family: var(--font-body); font-size: 15px; line-height: 1.55; color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { font-family: var(--font-head); color: var(--ink); margin: 0; line-height: 1.25; }
img { max-width: 100%; display: block; }
code, .code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85em; background: #eef3fb; color: var(--navy); padding: 2px 7px; border-radius: 6px; }
.icon { width: 18px; height: 18px; flex-shrink: 0; }
.muted { color: var(--muted); }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.inline { display: inline; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 18px; border-radius: 10px; border: 0; cursor: pointer; font-family: var(--font-head); font-weight: 700; font-size: .9rem; background: var(--navy); color: #fff; transition: transform .2s, box-shadow .2s, background .2s; white-space: nowrap; }
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn--primary { background: var(--grad); box-shadow: 0 8px 18px -10px rgba(22, 99, 214, .8); color: #fff; }
.btn--ghost { background: #fff; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn--ghost:hover { box-shadow: inset 0 0 0 1.5px var(--blue); color: var(--blue); }
.btn--light { background: #fff; color: var(--navy); }
.btn--danger-ghost { background: #fff; color: var(--red); box-shadow: inset 0 0 0 1.5px #fecdd3; }
.btn--danger-ghost:hover { background: #fff1f2; }
.btn--block { width: 100%; }
.btn--lg { padding: 13px 22px; font-size: .95rem; }
.btn--sm { padding: 7px 12px; font-size: .8rem; }
.icon-btn { width: 36px; height: 36px; display: inline-grid; place-items: center; border-radius: 10px; border: 0; background: #f1f5fb; color: var(--navy); cursor: pointer; transition: background .2s, color .2s; vertical-align: middle; }
.icon-btn:hover { background: #e3ecfa; color: var(--blue); text-decoration: none; }
.icon-btn--danger:hover { background: #ffe4e6; color: var(--red); }

/* Badges */
.badge { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 999px; font-size: .75rem; font-weight: 700; font-family: var(--font-head); }
.badge--amber { background: #fef3c7; color: #b45309; }
.badge--blue { background: #dbeafe; color: #1d4ed8; }
.badge--green { background: #dcfce7; color: #15803d; }
.badge--red { background: #ffe4e6; color: #be123c; }
.badge--gray { background: #f1f5f9; color: #64748b; }
.c-blue { background: #e7f0fe; color: #1663d6; } .c-teal { background: #e2f8f6; color: #0b9a93; } .c-amber { background: #fef3c7; color: #d97706; }
.c-rose { background: #fdeaf0; color: #d6336c; } .c-indigo { background: #eceafd; color: #5b4bd6; } .c-green { background: #dcfce7; color: #16a34a; }

/* Alerts */
.alert { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 12px; margin-bottom: 16px; font-size: .92rem; animation: slide .35s ease; }
.alert .icon { width: 20px; height: 20px; margin-top: 1px; }
.alert--success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.alert--error { background: #fff1f2; color: #9f1239; border: 1px solid #fecdd3; }
.alert.is-hiding { opacity: 0; transform: translateY(-6px); transition: .3s; }
@keyframes slide { from { opacity: 0; transform: translateY(-8px); } }

/* ---------- Layout ---------- */
.sidebar { position: fixed; inset: 0 auto 0 0; width: var(--side); background: var(--navy); color: #b6c4d9; display: flex; flex-direction: column; z-index: 50; transition: transform .35s ease; }
.sidebar::before { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 0 100%, rgba(15, 181, 174, .25), transparent 55%); pointer-events: none; }
.sidebar__brand { display: block; padding: 26px 24px 22px; border-bottom: 1px solid rgba(255, 255, 255, .07); position: relative; }
.sidebar__brand:hover { text-decoration: none; }
.sidebar__brand img { width: 130px; }
.sidebar__brand span { display: block; margin-top: 8px; font-size: .7rem; letter-spacing: .3em; text-transform: uppercase; color: #5ff0e2; font-weight: 700; }
.sidebar__nav { flex: 1; padding: 18px 14px; display: grid; align-content: start; gap: 4px; overflow-y: auto; position: relative; }
.sidebar__nav a, .sidebar__foot a, .sidebar__foot button { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 11px; color: #b6c4d9; font-weight: 500; transition: background .2s, color .2s; position: relative; width: 100%; background: none; border: 0; font: inherit; cursor: pointer; text-align: left; }
.sidebar__nav a:hover, .sidebar__foot a:hover, .sidebar__foot button:hover { background: rgba(255, 255, 255, .06); color: #fff; text-decoration: none; }
.sidebar__nav a.is-active { background: var(--grad); color: #fff; box-shadow: 0 10px 22px -12px rgba(15, 181, 174, .8); }
.sidebar__nav em { margin-left: auto; font-style: normal; font-size: .72rem; font-weight: 700; background: var(--red); color: #fff; min-width: 22px; height: 22px; border-radius: 999px; display: grid; place-items: center; padding: 0 6px; }
.sidebar__foot { padding: 14px; border-top: 1px solid rgba(255, 255, 255, .07); display: grid; gap: 4px; position: relative; }
.sidebar-overlay { display: none; }
.main { margin-left: var(--side); min-height: 100vh; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 16px; padding: 16px 32px; background: rgba(244, 247, 251, .85); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar h1 { font-size: 1.35rem; flex: 1; }
.topbar__menu { display: none; width: 40px; height: 40px; border-radius: 10px; border: 0; background: #fff; box-shadow: var(--shadow); cursor: pointer; place-items: center; }
.topbar__user { display: flex; align-items: center; gap: 10px; line-height: 1.2; }
.topbar__user strong { display: block; font-size: .9rem; color: var(--ink); }
.topbar__user small { color: var(--muted); }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--grad); color: #fff; display: inline-grid; place-items: center; font-family: var(--font-head); font-weight: 800; flex-shrink: 0; }
.avatar--sm { width: 34px; height: 34px; font-size: .85rem; }
.content { padding: 28px 32px 60px; max-width: 1400px; }

/* Cards & grids */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 24px; margin-bottom: 22px; border: 1px solid var(--line); }
.card__head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 16px; }
.card__head h3 { font-size: 1.05rem; }
.card__head a { font-size: .88rem; font-weight: 600; }
.cols { display: grid; gap: 22px; }
.cols > .card { margin-bottom: 0; }
/* grid children must be allowed to shrink, otherwise wide tables push the page sideways */
.cols > *, .stat-grid > *, .form-row > *, .stat-card > div, .inbox__row > * { min-width: 0; }
.hint code, .dl dd { word-break: break-all; }
.hint { flex-wrap: wrap; }
.cols + .cols, .cols + .card, .card + .cols { margin-top: 22px; }
.cols--2 { grid-template-columns: 1fr 1fr; }
.cols--2-1 { grid-template-columns: 2fr 1fr; }
.cols--1-2 { grid-template-columns: 1fr 1.6fr; align-items: start; }

.welcome { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding: 26px 28px; border-radius: 20px; background: linear-gradient(135deg, #0b1f3a, #12305a 60%, #1663d6); color: #c7d7ee; margin-bottom: 22px; position: relative; overflow: hidden; }
.welcome::after { content: ''; position: absolute; right: -60px; top: -80px; width: 240px; height: 240px; border-radius: 50%; border: 40px solid rgba(255, 255, 255, .06); }
.welcome h2 { color: #fff; font-size: 1.4rem; margin-bottom: 4px; }
.welcome p { margin: 0; }
.welcome .btn { position: relative; z-index: 1; }
.stat-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; margin-bottom: 22px; }
.stat-card { display: flex; gap: 14px; align-items: center; padding: 18px; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); border: 1px solid var(--line); color: var(--text); transition: transform .25s, box-shadow .25s; }
.stat-card:hover { transform: translateY(-3px); text-decoration: none; box-shadow: 0 14px 30px -16px rgba(15, 23, 42, .25); }
.stat-card .ic { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0; }
.stat-card .ic .icon { width: 22px; height: 22px; }
.stat-card small { display: block; color: var(--muted); font-size: .78rem; line-height: 1.3; }
.stat-card strong { font-family: var(--font-head); font-size: 1.6rem; color: var(--ink); line-height: 1.2; }

/* Charts */
.bars { display: flex; align-items: flex-end; gap: 8px; height: 220px; padding-top: 20px; }
.bars__col { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 6px; }
.bars__bar { width: 100%; max-width: 34px; height: var(--h); min-height: 3px; border-radius: 8px 8px 3px 3px; background: var(--grad); transform-origin: bottom; animation: grow .9s cubic-bezier(.22, 1, .36, 1) both; }
.bars__col:nth-child(n) .bars__bar { animation-delay: calc(var(--i, 0) * 40ms); }
.bars__val { font-size: .72rem; font-weight: 700; color: var(--navy); min-height: 1em; }
.bars__lbl { font-size: .7rem; color: var(--muted); }
@keyframes grow { from { transform: scaleY(0); } }
.hbar { margin-bottom: 14px; }
.hbar__top { display: flex; justify-content: space-between; font-size: .86rem; margin-bottom: 6px; gap: 10px; }
.hbar__top span { color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hbar__track { height: 8px; border-radius: 8px; background: #eef2f8; overflow: hidden; }
.hbar__track span { display: block; height: 100%; border-radius: 8px; background: var(--grad); animation: widen 1s cubic-bezier(.22, 1, .36, 1) both; }
@keyframes widen { from { width: 0; } }

/* Tables */
.table-wrap { overflow-x: auto; margin: 0 -24px; padding: 0 24px; }
.table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.table th { text-align: left; font-family: var(--font-head); font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 14px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tbody tr { transition: background .15s; }
.table tbody tr:hover { background: #f8fbff; }
.table tbody tr:last-child td { border-bottom: 0; }
.table strong { color: var(--ink); }
.with-thumb { display: flex; align-items: center; gap: 10px; }
.thumb { width: 70px; height: 70px; object-fit: cover; border-radius: 10px; }
.thumb--sm { width: 34px; height: 34px; border-radius: 50%; }
.thumb-row { display: flex; align-items: center; gap: 14px; margin-top: 10px; }
.empty, .empty-state { color: var(--muted); }
.empty-state { text-align: center; padding: 50px 20px; }
.empty-state .icon { width: 48px; height: 48px; color: #c3d0e2; margin-bottom: 10px; }
.empty-state h3 { margin-bottom: 6px; }
.empty-state p { max-width: 440px; margin: 0 auto 18px; }
.hint { display: flex; gap: 8px; align-items: flex-start; font-size: .85rem; color: var(--muted); }
.hint .icon { color: var(--blue); margin-top: 2px; }

/* Toolbar */
.toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 18px; }
.toolbar__right { display: flex; gap: 10px; flex-wrap: wrap; }
.tabs { display: flex; gap: 4px; background: #fff; padding: 5px; border-radius: 12px; box-shadow: var(--shadow); border: 1px solid var(--line); flex-wrap: wrap; }
.tabs a { padding: 8px 14px; border-radius: 9px; color: var(--muted); font-weight: 600; font-size: .87rem; display: inline-flex; gap: 8px; align-items: center; }
.tabs a:hover { text-decoration: none; color: var(--ink); background: #f4f7fb; }
.tabs a.is-active { background: var(--navy); color: #fff; }
.tabs em { font-style: normal; font-size: .72rem; background: rgba(100, 116, 139, .15); padding: 1px 7px; border-radius: 999px; }
.tabs a.is-active em { background: rgba(255, 255, 255, .2); }
.search { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.search input { padding: 10px 12px; border-radius: 10px; border: 1.5px solid var(--line); background: #fff; font: inherit; min-width: 0; }
.input-icon { position: relative; display: block; }
.input-icon > .icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.input-icon input { padding-left: 38px !important; width: 100%; }
.search .input-icon input { width: 240px; }
.pager { display: flex; gap: 6px; justify-content: center; padding-top: 18px; flex-wrap: wrap; }
.pager a, .pager span { min-width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; font-weight: 600; color: var(--ink); background: #f4f7fb; padding: 0 8px; }
.pager a.is-active { background: var(--navy); color: #fff; }
.pager a:hover { text-decoration: none; background: #e3ecfa; }

/* Forms */
.form { display: grid; gap: 14px; }
.form label { display: flex; flex-direction: column; gap: 6px; font-family: var(--font-head); font-weight: 600; font-size: .85rem; color: var(--ink); }
.form label small { font-family: var(--font-body); font-weight: 400; color: var(--muted); font-size: .78rem; }
.form input:not([type="checkbox"]):not([type="file"]), .form select, .form textarea {
    width: 100%; padding: 11px 13px; border-radius: 10px; border: 1.5px solid var(--line); background: #fbfcfe; font: inherit; font-family: var(--font-body); font-weight: 400; color: var(--ink); outline: none; transition: border-color .2s, box-shadow .2s;
}
.form input:focus, .form select:focus, .form textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(22, 99, 214, .1); background: #fff; }
.form input:disabled { background: #f1f5f9; color: var(--muted); }
.form input[type="file"] { padding: 9px; border: 1.5px dashed var(--line); border-radius: 10px; background: #fbfcfe; font-family: var(--font-body); font-weight: 400; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-row--3 { grid-template-columns: repeat(3, 1fr); }
.form-row--4 { grid-template-columns: repeat(4, 1fr); }
.form-row .span-2 { grid-column: 1 / -1; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; padding-top: 6px; }
label.check { flex-direction: row !important; align-items: center; gap: 8px !important; font-weight: 500 !important; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--blue); }
.sticky-save { position: sticky; bottom: 16px; display: flex; justify-content: flex-end; }
.sticky-save .btn { box-shadow: 0 16px 30px -12px rgba(22, 99, 214, .7); }
.pw-toggle { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--muted); cursor: pointer; padding: 6px; }

.dropzone { position: relative; display: grid !important; justify-items: center; gap: 4px !important; padding: 30px; border: 2px dashed #c9d6ea; border-radius: 14px; background: #f8fbff; text-align: center; cursor: pointer; transition: border-color .2s, background .2s; font-weight: 500 !important; }
.dropzone:hover, .dropzone.is-over { border-color: var(--blue); background: #eef5ff; }
.dropzone .icon { width: 36px; height: 36px; color: var(--blue); }
.dropzone small { color: var(--muted); font-weight: 400; }
.dropzone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.dropzone__files { color: var(--teal); font-size: .85rem; }
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 16px; }
.media { border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: #fff; }
.media img { width: 100%; height: 150px; object-fit: cover; }
.media__form { padding: 10px; display: grid; gap: 8px; }
.media__form input { width: 100%; padding: 8px 10px; border-radius: 8px; border: 1.5px solid var(--line); font: inherit; font-size: .85rem; }
.media__row { display: flex; gap: 8px; }
.media__row .btn:first-child { flex: 1; }

/* Feed / inbox / reviews */
.feed { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.feed li { display: flex; gap: 12px; padding: 10px; border-radius: 12px; }
.feed li.is-unread { background: #f3f8ff; }
.feed strong { color: var(--ink); font-size: .9rem; }
.feed p { margin: 2px 0; font-size: .85rem; color: var(--text); }
.feed small { color: var(--muted); font-size: .75rem; }
.inbox { list-style: none; margin: 0 -24px; padding: 0; }
.inbox li + li { border-top: 1px solid var(--line); }
.inbox__row { width: 100%; display: grid; grid-template-columns: 34px 180px 1fr auto; gap: 14px; align-items: center; padding: 14px 24px; background: none; border: 0; text-align: left; font: inherit; color: var(--text); cursor: pointer; transition: background .15s; }
.inbox__row:hover { background: #f8fbff; }
.inbox li.is-unread .inbox__row { background: #f3f8ff; }
.inbox li.is-unread .inbox__who strong::after { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); margin-left: 8px; vertical-align: middle; }
.inbox__who { line-height: 1.3; min-width: 0; }
.inbox__who strong { display: block; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox__who small { color: var(--muted); }
.inbox__text { font-size: .88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.inbox__text strong { color: var(--ink); }
.inbox__date { font-size: .78rem; color: var(--muted); white-space: nowrap; }
.review-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.review-list li { padding: 16px; border-radius: 12px; border: 1px solid var(--line); }
.review-list li.is-muted { opacity: .6; }
.review-list__top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.review-list__top strong { color: var(--ink); }
.review-list p { margin: 8px 0 12px; font-size: .9rem; }
.review-list__actions { display: flex; gap: 8px; flex-wrap: wrap; }
.stars-txt { color: #f59e0b; letter-spacing: 1px; }
.quick-actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.qa { display: flex; align-items: center; gap: 10px; padding: 16px 18px; border-radius: 14px; background: #fff; border: 1.5px dashed #c9d6ea; color: var(--navy); font-weight: 600; transition: all .2s; }
.qa:hover { border-color: var(--blue); color: var(--blue); background: #f3f8ff; text-decoration: none; }

/* Modal */
.modal { border: 0; padding: 0; border-radius: 18px; width: min(560px, calc(100vw - 32px)); box-shadow: 0 40px 80px -20px rgba(11, 31, 58, .45); color: var(--text); }
.modal::backdrop { background: rgba(11, 31, 58, .5); backdrop-filter: blur(3px); }
.modal[open] { animation: pop .3s cubic-bezier(.22, 1, .36, 1); }
@keyframes pop { from { opacity: 0; transform: translateY(14px) scale(.97); } }
.modal__head { display: flex; justify-content: space-between; align-items: center; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.modal__head h3 { font-size: 1.1rem; }
.modal__body { padding: 20px 22px; max-height: 65vh; overflow-y: auto; }
.modal__foot { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 22px; border-top: 1px solid var(--line); background: #fafcff; flex-wrap: wrap; }
.dl { display: grid; grid-template-columns: 110px 1fr; gap: 8px 14px; margin: 0 0 18px; font-size: .9rem; }
.dl dt { color: var(--muted); font-weight: 600; }
.dl dd { margin: 0; color: var(--ink); word-break: break-word; }
.message-body { padding: 16px; border-radius: 12px; background: #f6f9fd; font-size: .93rem; color: var(--ink); white-space: normal; }
.copied { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--navy); color: #fff; padding: 10px 18px; border-radius: 999px; font-weight: 600; font-size: .88rem; z-index: 100; animation: slide .3s ease; }

/* ---------- Auth (login / install) ---------- */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 30px 16px; background: #eef3fa; position: relative; overflow-x: hidden; }
.auth__bg { position: fixed; inset: 0; background: radial-gradient(circle at 15% 20%, rgba(22, 99, 214, .18), transparent 40%), radial-gradient(circle at 85% 80%, rgba(15, 181, 174, .2), transparent 40%); pointer-events: none; }
.auth__split { position: relative; display: grid; grid-template-columns: 1fr 1fr; width: min(980px, 100%); border-radius: 26px; overflow: hidden; box-shadow: 0 40px 80px -30px rgba(11, 31, 58, .4); background: #fff; }
.auth__side { padding: 50px 44px; background: linear-gradient(150deg, #0b1f3a, #12305a 60%, #1663d6); color: #b8cbe6; position: relative; overflow: hidden; }
.auth__side::after { content: ''; position: absolute; right: -80px; bottom: -80px; width: 280px; height: 280px; border-radius: 50%; border: 50px solid rgba(255, 255, 255, .06); }
.auth__side-logo { width: 150px; margin-bottom: 50px; }
.auth__side h2 { color: #fff; font-size: 1.7rem; margin-bottom: 12px; }
.auth__side ul { list-style: none; padding: 0; margin: 30px 0 0; display: grid; gap: 14px; }
.auth__side li { display: flex; gap: 12px; align-items: center; color: #e2e8f0; }
.auth__side li .icon { color: #5ff0e2; }
.auth__card { position: relative; background: #fff; padding: 50px 44px; width: 100%; }
.auth__card--wide { width: min(560px, 100%); border-radius: 24px; box-shadow: 0 40px 80px -30px rgba(11, 31, 58, .4); }
.auth__logo { width: 140px; margin-bottom: 26px; }
.auth__card h1 { font-size: 1.6rem; margin-bottom: 6px; }
.auth__card .form { margin-top: 22px; }
.auth__actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.auth__back { display: inline-block; margin-top: 22px; color: var(--muted); font-size: .88rem; }

/* ---------- Responsive ---------- */
@media (max-width: 1280px) { .stat-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 1024px) {
    .sidebar { transform: translateX(-100%); }
    .sidebar-open .sidebar { transform: none; }
    .sidebar-overlay { display: block; position: fixed; inset: 0; background: rgba(11, 31, 58, .45); z-index: 40; opacity: 0; visibility: hidden; transition: .3s; }
    .sidebar-open .sidebar-overlay { opacity: 1; visibility: visible; }
    .main { margin-left: 0; }
    .topbar__menu { display: grid; }
    .cols--2-1, .cols--1-2, .cols--2 { grid-template-columns: 1fr; }
    .form-row--4 { grid-template-columns: 1fr 1fr; }
    .quick-actions { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
    .hide-sm { display: none; }
    .topbar { padding: 12px 16px; }
    .content { padding: 18px 14px 50px; }
    .card { padding: 18px 16px; }
    .table-wrap { margin: 0 -16px; padding: 0 16px; }
    .inbox { margin: 0 -16px; }
    .inbox__row { grid-template-columns: 34px 1fr; padding: 12px 16px; }
    .inbox__text, .inbox__date { grid-column: 2; }
    .stat-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
    .stat-card { padding: 14px; gap: 10px; flex-direction: column; align-items: flex-start; }
    .stat-card .ic { width: 38px; height: 38px; }
    .stat-card strong { font-size: 1.35rem; }
    .welcome { padding: 20px; }
    .welcome h2 { font-size: 1.15rem; }
    .topbar h1 { font-size: 1.1rem; }
    .toolbar { flex-direction: column; align-items: stretch; }
    .tabs { overflow-x: auto; flex-wrap: nowrap; min-width: 0; max-width: 100%; }
    .tabs a { white-space: nowrap; }
    .toolbar__right { justify-content: stretch; }
    .toolbar__right .btn { flex: 1; }
    .bars { gap: 4px; height: 180px; }
    .modal__foot { justify-content: stretch; }
    .modal__foot > * { flex: 1; }
    .modal__foot .btn { width: 100%; }
    .dl { grid-template-columns: 90px 1fr; }
    .form-row, .form-row--3, .form-row--4 { grid-template-columns: 1fr; }
    .search .input-icon input { width: 100%; }
    .search, .search .input-icon { width: 100%; }
    .auth__split { grid-template-columns: 1fr; }
    .auth__side { display: none; }
    .auth__card { padding: 34px 24px; }
    .quick-actions { grid-template-columns: 1fr; }
}
