Files
clinicpro/assets/admin/styles.css
T

633 lines
33 KiB
CSS

@import "tailwindcss";
@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;500;600;700;800&display=swap');
/* Class-based dark mode for Tailwind v4 */
@custom-variant dark (&:where(.dark, .dark *));
@theme {
--font-sans: "Vazirmatn", ui-sans-serif, system-ui, sans-serif;
}
/* ── Template Design System Variables ─────────────────────────── */
:root {
--brand-h: 256;
--brand-c: 0.15;
--bg: #eef2f8;
--bg-2: #e6ecf4;
--surface: #ffffff;
--surface-2: #f6f8fc;
--surface-3: #eef2f8;
--border: #e4e9f1;
--border-2: #d6dde8;
--text: #0f1b2e;
--text-2: #56657c;
--text-3: #8a98ad;
--primary: oklch(0.55 var(--brand-c) var(--brand-h));
--primary-600: oklch(0.49 var(--brand-c) var(--brand-h));
--primary-700: oklch(0.43 var(--brand-c) var(--brand-h));
--primary-soft: oklch(0.95 0.03 var(--brand-h));
--primary-soft2: oklch(0.90 0.05 var(--brand-h));
--on-primary: #ffffff;
--success: #15a35a;
--success-bg: #e6f6ed;
--warning: #d98a09;
--warning-bg: #fcf2df;
--danger: #e0394a;
--danger-bg: #fdebed;
--info: #2b86d8;
--info-bg: #e7f1fb;
--violet: #7c5cf0;
--violet-bg: #efeafe;
--ring: color-mix(in oklch, var(--primary) 32%, transparent);
--shadow-sm: 0 1px 2px rgba(15,27,46,.06), 0 1px 3px rgba(15,27,46,.05);
--shadow: 0 2px 6px rgba(15,27,46,.06), 0 8px 24px rgba(15,27,46,.06);
--shadow-lg: 0 12px 32px rgba(15,27,46,.12), 0 4px 10px rgba(15,27,46,.06);
--r-xs: 7px; --r-sm: 10px; --r: 14px; --r-lg: 18px; --r-xl: 24px; --r-pill: 999px;
--gap: 20px;
--card-pad: 22px;
--row-h: 56px;
--sidebar-w: 252px;
--topbar-h: 64px;
--ease: cubic-bezier(.22,.61,.36,1);
}
[data-density="compact"] {
--gap: 14px;
--card-pad: 16px;
--row-h: 46px;
}
[data-theme="dark"] {
--bg: #080d16;
--bg-2: #0b1220;
--surface: #111a29;
--surface-2: #16202f;
--surface-3: #1b2738;
--border: #243042;
--border-2: #2e3c52;
--text: #e9eef7;
--text-2: #9eb0c6;
--text-3: #67788e;
--primary: oklch(0.66 var(--brand-c) var(--brand-h));
--primary-600: oklch(0.60 var(--brand-c) var(--brand-h));
--primary-700: oklch(0.54 var(--brand-c) var(--brand-h));
--primary-soft: color-mix(in oklch, var(--primary) 16%, var(--surface));
--primary-soft2: color-mix(in oklch, var(--primary) 26%, var(--surface));
--on-primary: #07101f;
--success-bg: color-mix(in oklch, var(--success) 18%, var(--surface));
--warning-bg: color-mix(in oklch, var(--warning) 18%, var(--surface));
--danger-bg: color-mix(in oklch, var(--danger) 18%, var(--surface));
--info-bg: color-mix(in oklch, var(--info) 18%, var(--surface));
--violet-bg: color-mix(in oklch, var(--violet) 20%, var(--surface));
--shadow-sm: 0 1px 2px rgba(0,0,0,.4);
--shadow: 0 2px 8px rgba(0,0,0,.4), 0 12px 30px rgba(0,0,0,.35);
--shadow-lg: 0 18px 44px rgba(0,0,0,.55);
}
/* ── Base ─────────────────────────────────────────────────────── */
*, *::before, *::after { font-family: var(--font-sans); box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
direction: rtl;
background: var(--bg);
color: var(--text);
font-size: 15px;
line-height: 1.6;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
transition: background .3s var(--ease), color .3s var(--ease);
margin: 0;
}
/* ── Scrollbar ──────────────────────────────────────────────────*/
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-2); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-3); }
/* ── Animations ─────────────────────────────────────────────────*/
@keyframes scale-in { from { opacity: 0; transform: scale(0.96) translateY(-4px); } to { opacity: 1; transform: scale(1) translateY(0); } }
@keyframes slide-up { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes shimmer { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } }
@keyframes fadein { from { opacity: 0; transform: translateY(10px); } }
@keyframes pop { from { opacity: 0; transform: translateY(14px) scale(.97); } }
@keyframes slidein { from { transform: translateX(30px); opacity: 0; } }
@keyframes slideup { from { opacity: 0; transform: translateY(16px); } }
@keyframes growbar { from { width: 0; } }
@keyframes spin { to { transform: rotate(360deg); } }
.animate-scale-in { animation: scale-in 200ms cubic-bezier(0.34, 1.2, 0.64, 1) both; }
.animate-slide-up { animation: slide-up 200ms ease both; }
.animate-fade-in { animation: fade-in 150ms ease both; }
.fade-in { animation: fadein .4s var(--ease); }
/* ── Skeleton shimmer ───────────────────────────────────────────*/
.skeleton {
background: linear-gradient(90deg, var(--surface-2) 25%, var(--surface-3) 50%, var(--surface-2) 75%);
background-size: 200% 100%;
animation: shimmer 1.4s infinite;
}
/* ── Utility ────────────────────────────────────────────────────*/
.line-clamp-1 { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; }
.line-clamp-2 { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.line-clamp-3 { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; }
/* ── Admin component tokens ─────────────────────────────────────*/
@layer components {
.cp-card {
background: var(--surface);
border: 1px solid var(--border);
border-radius: var(--r-lg);
box-shadow: var(--shadow-sm);
}
.cp-input {
width: 100%; height: 42px;
background: var(--surface);
border: 1px solid var(--border);
border-radius: var(--r-sm);
padding: 0 14px;
font-size: 14px; color: var(--text);
outline: none;
transition: border-color .15s, box-shadow .15s;
}
.cp-input:focus { border-color: var(--primary); box-shadow: 0 0 0 4px var(--ring); }
.cp-input::placeholder { color: var(--text-3); }
.cp-textarea {
background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-sm);
padding: 10px 14px; font-size: 14px; color: var(--text); outline: none; width: 100%;
transition: border-color .15s, box-shadow .15s;
}
.cp-textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 4px var(--ring); }
.cp-textarea::placeholder { color: var(--text-3); }
.cp-select {
width: 100%; height: 42px;
background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-sm);
padding: 0 14px; font-size: 14px; color: var(--text);
outline: none; transition: border-color .15s, box-shadow .15s;
}
.cp-select:focus { border-color: var(--primary); box-shadow: 0 0 0 4px var(--ring); }
.cp-label {
display: block; font-size: 13px; font-weight: 600; color: var(--text-2); margin-bottom: 6px;
}
.cp-btn-primary {
display: inline-flex; align-items: center; justify-content: center; gap: 8px;
height: 42px; padding: 0 18px; border-radius: var(--r-sm);
font-size: 14px; font-weight: 700; white-space: nowrap; border: none; cursor: pointer;
background: var(--primary); color: var(--on-primary); box-shadow: 0 4px 14px var(--ring);
transition: background .16s;
}
.cp-btn-primary:hover { background: var(--primary-600); }
.cp-btn-primary:disabled { opacity: .5; cursor: not-allowed; }
.cp-btn-secondary {
display: inline-flex; align-items: center; justify-content: center; gap: 8px;
height: 42px; padding: 0 18px; border-radius: var(--r-sm);
font-size: 14px; font-weight: 600; white-space: nowrap; cursor: pointer;
background: var(--surface); color: var(--text); border: 1px solid var(--border);
transition: .16s;
}
.cp-btn-secondary:hover { background: var(--surface-2); border-color: var(--border-2); }
.cp-btn-secondary:disabled { opacity: .5; cursor: not-allowed; }
.cp-btn-danger {
display: inline-flex; align-items: center; justify-content: center; gap: 8px;
height: 42px; padding: 0 18px; border-radius: var(--r-sm);
font-size: 14px; font-weight: 700; white-space: nowrap; border: none; cursor: pointer;
background: var(--danger); color: #fff; transition: .16s;
}
.cp-btn-danger:hover { filter: brightness(.92); }
.cp-btn-danger:disabled { opacity: .5; cursor: not-allowed; }
.cp-btn-ghost {
display: inline-flex; align-items: center; justify-content: center; gap: 8px;
height: 42px; padding: 0 18px; border-radius: var(--r-sm);
font-size: 14px; font-weight: 600; white-space: nowrap; border: none; cursor: pointer;
background: transparent; color: var(--text-2); transition: .16s;
}
.cp-btn-ghost:hover { background: var(--surface-2); color: var(--text); }
.cp-btn-ghost:disabled { opacity: .5; cursor: not-allowed; }
.cp-action-view { padding: 6px; border-radius: 8px; color: var(--text-3); transition: .14s; cursor: pointer; }
.cp-action-view:hover { background: var(--info-bg); color: var(--info); }
.cp-action-edit { padding: 6px; border-radius: 8px; color: var(--text-3); transition: .14s; cursor: pointer; }
.cp-action-edit:hover { background: var(--primary-soft); color: var(--primary-700); }
.cp-action-delete { padding: 6px; border-radius: 8px; color: var(--text-3); transition: .14s; cursor: pointer; }
.cp-action-delete:hover { background: var(--danger-bg); color: var(--danger); }
.cp-action-approve{ padding: 6px; border-radius: 8px; color: var(--text-3); transition: .14s; cursor: pointer; }
.cp-action-approve:hover{ background: var(--success-bg); color: var(--success); }
.cp-stat {
background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg);
padding: 18px; box-shadow: var(--shadow-sm);
display: flex; align-items: flex-start; gap: 16px;
transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s;
}
.cp-stat:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--border-2); }
.cp-stat-icon {
width: 40px; height: 40px; border-radius: 12px;
display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.cp-section-title { font-size: 14px; font-weight: 700; color: var(--text); margin-bottom: 16px; }
.cp-info-row {
display: flex; align-items: center; justify-content: space-between;
padding: 10px 0; border-bottom: 1px solid var(--border);
}
.cp-info-row:last-child { border-bottom: none; }
.cp-info-label { font-size: 12px; color: var(--text-3); }
.cp-info-value { font-size: 13px; font-weight: 600; color: var(--text); }
}
/* ══ Template component classes ══════════════════════════════════*/
/* ── Layout ──────────────────────────────────────────────────── */
.app { display: flex; min-height: 100vh; }
.main {
flex: 1; min-width: 0; display: flex; flex-direction: column;
margin-right: var(--sidebar-w);
transition: margin .28s var(--ease);
}
.app[data-collapsed="true"] .main { margin-right: 76px; }
.content { padding: var(--gap); max-width: 1480px; width: 100%; margin: 0 auto; }
/* ── Sidebar ─────────────────────────────────────────────────── */
.sidebar {
position: fixed; top: 0; bottom: 0; right: 0;
width: var(--sidebar-w);
background: var(--surface);
border-left: 1px solid var(--border);
display: flex; flex-direction: column;
z-index: 40;
transition: width .28s var(--ease);
}
.app[data-collapsed="true"] .sidebar { width: 76px; }
.sidebar-brand {
height: var(--topbar-h); flex: none;
display: flex; align-items: center; gap: 12px;
padding: 0 20px;
border-bottom: 1px solid var(--border);
}
.brand-logo {
width: 38px; height: 38px; flex: none; border-radius: 11px;
background: linear-gradient(150deg, var(--primary), var(--primary-700));
display: grid; place-items: center; color: #fff;
box-shadow: 0 6px 16px var(--ring);
flex-shrink: 0;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.25; overflow: hidden; white-space: nowrap; }
.brand-text b { font-size: 16px; letter-spacing: -.2px; color: var(--text); }
.brand-text span { font-size: 11.5px; color: var(--text-3); }
.app[data-collapsed="true"] .brand-text { display: none; }
.nav { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 14px 12px; }
.nav-group { margin-bottom: 6px; }
.nav-label {
font-size: 11px; font-weight: 700; color: var(--text-3);
padding: 14px 12px 8px; letter-spacing: .2px; display: block;
}
.app[data-collapsed="true"] .nav-label { text-align: center; padding: 12px 0 6px; font-size: 9px; }
.nav-item {
display: flex; align-items: center; gap: 12px;
padding: 9px 12px; border-radius: var(--r-sm);
color: var(--text-2); font-size: 14px; font-weight: 500;
position: relative; width: 100%; text-align: start;
transition: background .15s, color .15s;
white-space: nowrap; text-decoration: none;
background: none; border: none; cursor: pointer;
}
.nav-item svg { flex-shrink: 0; }
.nav-item:hover { background: var(--surface-2); color: var(--text); }
.nav-item.active { background: var(--primary-soft); color: var(--primary-700); font-weight: 700; }
.nav-item.active::before {
content: ""; position: absolute; right: -12px; top: 50%; transform: translateY(-50%);
width: 4px; height: 22px; border-radius: 99px; background: var(--primary);
}
.nav-item .badge-count {
margin-inline-start: auto; background: var(--primary); color: var(--on-primary);
font-size: 11px; font-weight: 700; min-width: 20px; height: 20px; padding: 0 6px;
border-radius: 99px; display: grid; place-items: center;
}
.app[data-collapsed="true"] .nav-item { justify-content: center; padding: 10px; }
.app[data-collapsed="true"] .nav-item > span,
.app[data-collapsed="true"] .nav-item .badge-count { display: none; }
.app[data-collapsed="true"] .nav-item.active::before { display: none; }
.sidebar-foot { flex: none; border-top: 1px solid var(--border); padding: 12px; }
.user-chip {
display: flex; align-items: center; gap: 11px; padding: 8px; border-radius: var(--r-sm);
transition: background .15s; cursor: pointer;
}
.user-chip:hover { background: var(--surface-2); }
.app[data-collapsed="true"] .user-chip .user-meta { display: none; }
.user-meta { display: flex; flex-direction: column; line-height: 1.3; overflow: hidden; flex: 1; min-width: 0; }
.user-meta b { font-size: 13.5px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-meta span { font-size: 11.5px; color: var(--text-3); }
.cp-avatar {
width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
display: grid; place-items: center; font-weight: 700; color: #fff; font-size: 13px;
background: linear-gradient(145deg, var(--primary), var(--primary-700));
overflow: hidden;
}
.cp-avatar.sm { width: 28px; height: 28px; font-size: 11px; }
.cp-avatar.lg { width: 96px; height: 96px; font-size: 32px; border-radius: 20px; }
/* ── Topbar ──────────────────────────────────────────────────── */
.topbar {
height: var(--topbar-h); flex: none; position: sticky; top: 0; z-index: 30;
display: flex; align-items: center; gap: 12px;
padding: 0 var(--gap);
background: color-mix(in srgb, var(--bg) 85%, transparent);
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);
border-bottom: 1px solid var(--border);
}
.icon-btn {
width: 40px; height: 40px; border-radius: var(--r-sm); flex-shrink: 0;
display: grid; place-items: center; color: var(--text-2);
background: var(--surface); border: 1px solid var(--border);
position: relative; transition: .15s; cursor: pointer;
}
.icon-btn:hover { color: var(--text); border-color: var(--border-2); background: var(--surface-2); }
.icon-btn .dot {
position: absolute; top: 8px; right: 9px;
width: 8px; height: 8px; border-radius: 50%;
background: var(--danger); border: 2px solid var(--surface);
}
.topbar-search {
display: flex; align-items: center; gap: 9px; flex: 1; max-width: 360px;
background: var(--surface); border: 1px solid var(--border);
border-radius: var(--r-pill); padding: 0 14px; height: 42px; color: var(--text-3);
transition: .18s;
}
.topbar-search:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px var(--ring); }
.topbar-search input {
border: none; outline: none; background: none; flex: 1; font-size: 14px; color: var(--text);
font-family: inherit;
}
.topbar-search input::placeholder { color: var(--text-3); }
.topbar-search kbd {
font-size: 11px; color: var(--text-3); font-family: inherit;
background: var(--surface-3); border: 1px solid var(--border); border-radius: 6px; padding: 1px 7px;
}
.topbar-crumbs { display: flex; align-items: center; gap: 8px; color: var(--text-3); font-size: 13px; }
.topbar-crumbs b { color: var(--text); }
/* ── Generic Card ────────────────────────────────────────────── */
.card {
background: var(--surface); border: 1px solid var(--border);
border-radius: var(--r-lg); box-shadow: var(--shadow-sm);
}
.card-pad { padding: var(--card-pad); }
.card-head {
display: flex; align-items: center; justify-content: space-between; gap: 12px;
padding: var(--card-pad) var(--card-pad) 0;
}
.card-head h3 { font-size: 16px; font-weight: 700; color: var(--text); }
.section-title { font-size: 19px; font-weight: 800; letter-spacing: -.3px; color: var(--text); }
.muted { color: var(--text-3); }
.link { color: var(--primary); font-weight: 600; font-size: 13px; text-decoration: none; }
.link:hover { color: var(--primary-700); }
.card-title-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.flex { display: flex; align-items: center; }
.between { display: flex; align-items: center; justify-content: space-between; }
/* ── Stat cards ──────────────────────────────────────────────── */
.stat {
background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg);
padding: 18px; box-shadow: var(--shadow-sm); position: relative; overflow: hidden;
transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s;
}
.stat:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--border-2); }
.stat .ico { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 14px; }
.stat .lbl { color: var(--text-2); font-size: 13px; font-weight: 500; }
.stat .val { font-size: 26px; font-weight: 800; letter-spacing: -.5px; margin: 4px 0 2px; color: var(--text); }
.stat .hint { font-size: 11.5px; color: var(--text-3); }
.stat-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: var(--gap); margin-bottom: var(--gap); }
.trend { display: inline-flex; align-items: center; gap: 3px; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; }
.trend.up { color: var(--success); background: var(--success-bg); }
.trend.down { color: var(--danger); background: var(--danger-bg); }
/* ── Badges ──────────────────────────────────────────────────── */
.badge {
display: inline-flex; align-items: center; gap: 5px;
font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 99px; white-space: nowrap;
}
.badge .bdot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex-shrink: 0; }
.badge.green { color: var(--success); background: var(--success-bg); }
.badge.amber { color: var(--warning); background: var(--warning-bg); }
.badge.red { color: var(--danger); background: var(--danger-bg); }
.badge.blue { color: var(--info); background: var(--info-bg); }
.badge.violet { color: var(--violet); background: var(--violet-bg); }
.badge.gray { color: var(--text-2); background: var(--surface-3); }
/* ── Buttons ─────────────────────────────────────────────────── */
.btn {
display: inline-flex; align-items: center; justify-content: center; gap: 8px;
height: 42px; padding: 0 18px; border-radius: var(--r-sm);
font-size: 14px; font-weight: 700; transition: .16s var(--ease); white-space: nowrap;
border: 1px solid transparent; cursor: pointer; font-family: inherit;
}
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--primary); color: var(--on-primary); box-shadow: 0 4px 14px var(--ring); }
.btn.primary:hover { background: var(--primary-600); }
.btn.ghost { background: var(--surface); border-color: var(--border); color: var(--text); }
.btn.ghost:hover { background: var(--surface-2); border-color: var(--border-2); }
.btn.soft { background: var(--primary-soft); color: var(--primary-700); border-color: transparent; }
.btn.soft:hover { background: var(--primary-soft2); }
.btn.danger { background: var(--danger-bg); color: var(--danger); border-color: transparent; }
.btn.danger:hover { filter: brightness(.97); }
.btn.sm { height: 36px; padding: 0 14px; font-size: 13px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
/* ── Tables ──────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; border-radius: var(--r-lg); border: 1px solid var(--border); }
table.t { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.t thead th {
text-align: start; font-size: 12px; font-weight: 700; color: var(--text-3);
padding: 14px 16px 12px; white-space: nowrap; border-bottom: 1px solid var(--border);
background: var(--surface-2);
}
table.t tbody td {
padding: 0 16px; height: var(--row-h); border-bottom: 1px solid var(--border);
vertical-align: middle; color: var(--text);
}
table.t tbody tr { transition: background .12s; }
table.t tbody tr:hover { background: var(--surface-2); }
table.t tbody tr:last-child td { border-bottom: none; }
.cell-user { display: flex; align-items: center; gap: 11px; }
.cell-user b { font-weight: 700; font-size: 13.5px; color: var(--text); }
.cell-user small { color: var(--text-3); font-size: 11.5px; }
.row-actions { display: flex; gap: 6px; opacity: 0; transition: opacity .15s; }
table.t tbody tr:hover .row-actions { opacity: 1; }
.mini-btn {
width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center;
color: var(--text-3); transition: .14s; cursor: pointer; border: none; background: none;
}
.mini-btn:hover { background: var(--surface-3); color: var(--text); }
.mini-btn.danger:hover { background: var(--danger-bg); color: var(--danger); }
/* ── Toolbar / Fields ────────────────────────────────────────── */
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.toolbar .spacer { flex: 1; }
.field {
display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px;
background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-sm); color: var(--text-2);
transition: .15s;
}
.field:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px var(--ring); }
.field input, .field select { border: none; outline: none; background: none; flex: 1; min-width: 60px; color: var(--text); font-family: inherit; font-size: 14px; }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 3px; gap: 2px; }
.seg button { padding: 7px 14px; border-radius: 8px; font-size: 13px; font-weight: 600; color: var(--text-2); transition: .14s; cursor: pointer; font-family: inherit; }
.seg button.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }
/* ── Pagination ──────────────────────────────────────────────── */
.pagination {
display: flex; align-items: center; gap: 6px; padding: 16px 0;
justify-content: space-between; flex-wrap: wrap; border-top: 1px solid var(--border); margin-top: 4px;
}
.page-btns { display: flex; gap: 4px; }
.page-btns button {
min-width: 36px; height: 36px; border-radius: 9px; font-weight: 600; font-size: 13px;
color: var(--text-2); border: 1px solid transparent; background: none;
cursor: pointer; transition: .14s; font-family: inherit;
}
.page-btns button:hover:not(.on):not(:disabled) { background: var(--surface-2); }
.page-btns button.on { background: var(--primary); color: var(--on-primary); }
.page-btns button:disabled { opacity: .3; cursor: not-allowed; }
/* ── Progress bar ────────────────────────────────────────────── */
.bar { height: 8px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--primary), var(--primary-600)); }
/* ── Toggle switch ───────────────────────────────────────────── */
.switch {
width: 44px; height: 26px; border-radius: 99px; background: var(--border-2);
position: relative; flex-shrink: 0; transition: background .2s var(--ease); cursor: pointer; display: inline-block;
}
.switch.on { background: var(--primary); }
.switch::after {
content: ""; position: absolute; top: 3px; inset-inline-start: 3px;
width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: var(--shadow-sm);
transition: transform .2s var(--ease);
}
.switch.on::after { transform: translateX(-18px); }
/* ── Modal ───────────────────────────────────────────────────── */
.overlay {
position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px;
background: rgba(8,13,22,.5); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
animation: fade-in .2s var(--ease);
}
.modal {
background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-xl);
box-shadow: var(--shadow-lg); width: 100%; max-width: 540px; max-height: 90vh;
overflow-y: auto; overflow-x: hidden; animation: pop .26s var(--ease);
}
.modal-head {
display: flex; align-items: center; justify-content: space-between;
padding: 22px 24px; border-bottom: 1px solid var(--border);
}
.modal-head h2 { font-size: 17px; font-weight: 700; color: var(--text); margin: 0; }
.modal-body { padding: 24px; }
.modal-foot {
display: flex; gap: 10px; padding: 18px 24px; border-top: 1px solid var(--border); justify-content: flex-end;
}
.settings-panel {
width: 360px; height: 100%; overflow-y: auto;
animation: slidein .3s var(--ease);
border-radius: 0; max-height: 100%;
}
/* ── Form rows ───────────────────────────────────────────────── */
.form-row { display: flex; flex-direction: column; gap: 7px; margin-bottom: 16px; }
.form-row label { font-size: 13px; font-weight: 600; color: var(--text-2); }
.input {
height: 44px; padding: 0 14px; border-radius: var(--r-sm);
background: var(--surface-2); border: 1px solid var(--border); color: var(--text);
outline: none; width: 100%; transition: .15s; font-family: inherit; font-size: 14px;
}
.input:focus { border-color: var(--primary); background: var(--surface); box-shadow: 0 0 0 4px var(--ring); }
.input.err { border-color: var(--danger); }
.slot-select {
height: 42px; padding: 0 12px; border-radius: var(--r-sm);
background: var(--surface); border: 1px solid var(--border); color: var(--text);
outline: none; transition: .15s; font-family: inherit; font-size: 14px;
}
.slot-select:focus { border-color: var(--primary); box-shadow: 0 0 0 4px var(--ring); }
/* ── Toast ───────────────────────────────────────────────────── */
.toasts {
position: fixed; bottom: 22px; left: 22px; z-index: 100;
display: flex; flex-direction: column; gap: 10px; pointer-events: none;
}
.toast {
display: flex; align-items: center; gap: 11px; padding: 13px 16px; min-width: 280px;
background: var(--surface); border: 1px solid var(--border); border-radius: var(--r);
box-shadow: var(--shadow-lg); animation: slideup .3s var(--ease); pointer-events: auto;
}
.toast .tx { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; flex-shrink: 0; }
/* ── Dashboard misc ──────────────────────────────────────────── */
.timeline-item { display: flex; gap: 13px; padding: 11px 0; }
.timeline-item .tl-dot { width: 9px; height: 9px; border-radius: 50%; margin-top: 7px; flex-shrink: 0; box-shadow: 0 0 0 4px var(--surface); }
.timeline-item .tl-body { flex: 1; min-width: 0; }
.timeline-item .tl-body b { font-size: 13.5px; font-weight: 700; color: var(--text); display: block; }
.timeline-item .tl-body p { margin: 2px 0 0; font-size: 12.5px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.timeline-item .tl-body time { font-size: 11px; color: var(--text-3); }
.tl-connector { width: 1px; background: var(--border); flex-shrink: 0; margin: 0 4px; }
.quick-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.quick {
display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 20px 12px;
border: 1px solid var(--border); border-radius: var(--r); background: var(--surface-2);
transition: .18s var(--ease); text-align: center; text-decoration: none; cursor: pointer;
}
.quick:hover { transform: translateY(-3px); border-color: var(--primary); background: var(--surface); box-shadow: var(--shadow); }
.quick .qi { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; }
.quick b { font-size: 13px; color: var(--text); }
/* ── Dashboard grid layouts ──────────────────────────────────── */
.dash-main { display: grid; grid-template-columns: 360px 1fr; gap: var(--gap); margin-bottom: var(--gap); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); }
.dash-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
/* ── Colored avatar (hue-based gradient) ─────────────────────── */
.avatar {
width: 38px; height: 38px; border-radius: 50%; flex-shrink: 0;
display: grid; place-items: center; font-weight: 700; color: #fff; font-size: 14px;
overflow: hidden;
}
.avatar.sm { width: 32px; height: 32px; font-size: 12px; }
.avatar.lg { width: 104px; height: 104px; font-size: 34px; border-radius: 22px; }
/* ── Responsive ──────────────────────────────────────────────── */
.scrim { display: none; }
@media (max-width: 1080px) {
.stat-grid { grid-template-columns: repeat(3, 1fr); }
.dash-main { grid-template-columns: 1fr; }
.dash-3 { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
.main { margin-right: 0 !important; }
.sidebar { transform: translateX(100%); box-shadow: var(--shadow-lg); }
.app[data-mobile-open="true"] .sidebar { transform: translateX(0); width: var(--sidebar-w); }
.app[data-mobile-open="true"] .scrim {
display: block; position: fixed; inset: 0; background: rgba(8,13,22,.5);
z-index: 35; backdrop-filter: blur(2px);
}
.topbar-search { display: none; }
.grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
.stat-grid { grid-template-columns: 1fr 1fr; }
}