:root {
  --green: #19c98a;
  --green-dark: #159b73;
  --ink: #0f1720;
  --muted: #64717a;
  --line: #e6eeea;
  --soft: #f5f8f6;
  --white: #fff;
  --danger: #d9485f;
  --shadow: 0 14px 42px rgba(16, 35, 25, .07);
}

* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--soft); font: 14px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", sans-serif; }
button, input, textarea, select { font: inherit; }
button { border: 0; cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .55; }
.hidden { display: none !important; }
.login-shell { min-height: 100vh; display: grid; place-items: center; padding: 40px; background: radial-gradient(circle at 80% 0%, #ddfff0, transparent 38%), var(--soft); }
.login-card { width: min(460px, 100%); padding: 42px; border: 1px solid var(--line); border-radius: 28px; background: var(--white); box-shadow: var(--shadow); }
.brand-lockup { display: flex; gap: 14px; align-items: center; margin-bottom: 44px; }
.logo-mark { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px; color: #fff; background: var(--green); font-size: 26px; font-weight: 800; }
.brand-name { display: block; font-size: 22px; font-weight: 800; letter-spacing: -.04em; }
.brand-caption { display: block; color: var(--green-dark); font-size: 12px; font-weight: 700; }
.eyebrow { display: block; color: var(--green-dark); font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
h1, h2, h3, p { margin: 0; }
h1 { margin-top: 8px; font-size: 32px; letter-spacing: -.05em; line-height: 1.15; }
h2 { font-size: 22px; letter-spacing: -.03em; }
.muted { color: var(--muted); }
.login-subtitle { margin-top: 12px; color: var(--muted); }
.field { display: grid; gap: 7px; margin-top: 22px; color: var(--ink); font-weight: 700; }
.field input, .field textarea, .field select, .search-input { width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; outline: none; background: #fbfdfc; color: var(--ink); }
.field input:focus, .field textarea:focus, .field select:focus, .search-input:focus { border-color: var(--green); box-shadow: 0 0 0 4px rgba(25, 201, 138, .12); }
.primary { width: 100%; margin-top: 28px; padding: 13px 18px; border-radius: 999px; color: #fff; background: var(--green); font-weight: 800; }
.primary:hover { background: var(--green-dark); }
.demo-login { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.demo-login button, .ghost { padding: 8px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: #fff; }
.admin-shell { display: grid; grid-template-columns: 250px minmax(0, 1fr); min-height: 100vh; }
.sidebar { position: sticky; top: 0; height: 100vh; padding: 28px 18px; border-right: 1px solid var(--line); background: #fff; }
.sidebar .brand-lockup { margin: 0 12px 52px; }
.sidebar .logo-mark { width: 42px; height: 42px; border-radius: 13px; font-size: 20px; }
.sidebar .brand-name { font-size: 18px; }
.nav-list { display: grid; gap: 8px; }
.nav-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; border-radius: 12px; color: var(--muted); background: transparent; text-align: left; }
.nav-item:hover, .nav-item.active { color: var(--green-dark); background: #eafaf4; font-weight: 800; }
.nav-icon { width: 20px; text-align: center; font-size: 18px; }
.sidebar-footer { position: absolute; right: 18px; bottom: 26px; left: 18px; padding: 16px; border-radius: 14px; background: var(--soft); }
.sidebar-user { display: block; font-weight: 800; }.sidebar-role { display: block; margin-top: 3px; color: var(--muted); font-size: 12px; }
.logout { width: 100%; margin-top: 14px; padding: 9px; border-radius: 10px; color: var(--danger); background: #fff0f0; }
.main { min-width: 0; padding: 28px 38px 60px; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 34px; }
.topbar h1 { margin-top: 5px; }
.topbar-meta { display: flex; align-items: center; gap: 12px; color: var(--muted); }
.avatar { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; color: #fff; background: var(--green); font-weight: 800; }
.topbar-logout { display: none; padding: 8px 11px; border-radius: 9px; color: var(--danger); background: #fff0f0; font-weight: 700; }
.content { max-width: 1440px; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.metric-card, .panel, .data-card { border: 1px solid var(--line); border-radius: 18px; background: #fff; box-shadow: 0 8px 26px rgba(16,35,25,.035); }
.metric-card { padding: 22px; }.metric-card .metric-label { color: var(--muted); }.metric-value { display: block; margin-top: 12px; font-size: 32px; font-weight: 800; letter-spacing: -.04em; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin: 36px 0 16px; }.section-head p { color: var(--muted); }
.shortcut-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }.shortcut { padding: 20px; text-align: left; }.shortcut:hover { border-color: #a9e9d2; transform: translateY(-1px); }.shortcut-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; color: #fff; background: var(--green); font-size: 18px; }.shortcut h3 { margin-top: 16px; }.shortcut p { margin-top: 5px; color: var(--muted); font-size: 12px; }
.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 18px; }.toolbar-left { display: flex; flex-wrap: wrap; gap: 10px; }.search-input { width: min(360px, 100%); }.filter-button { padding: 9px 14px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: #fff; }.filter-button.active { border-color: var(--green); color: var(--green-dark); background: #eafaf4; font-weight: 800; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 18px; background: #fff; box-shadow: 0 8px 26px rgba(16,35,25,.035); }.table { width: 100%; min-width: 900px; border-collapse: collapse; }.table th, .table td { padding: 16px 18px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }.table th { color: var(--muted); background: #fbfdfc; font-size: 12px; font-weight: 700; }.table tr:last-child td { border-bottom: 0; }.table-title { max-width: 300px; font-weight: 800; }.table-sub { display: block; margin-top: 3px; color: var(--muted); font-size: 12px; }.actions { display: flex; flex-wrap: wrap; gap: 7px; }.small-button { padding: 7px 10px; border: 1px solid var(--line); border-radius: 9px; color: var(--muted); background: #fff; }.small-button:hover { border-color: var(--green); color: var(--green-dark); }.small-button.danger { color: var(--danger); background: #fff5f5; }.small-button.success { color: var(--green-dark); background: #eafaf4; }
.status { display: inline-flex; padding: 5px 9px; border-radius: 999px; color: var(--green-dark); background: #eafaf4; font-size: 12px; font-weight: 700; }.status.orange { color: #b96e23; background: #fff4e8; }.status.red { color: var(--danger); background: #fff0f0; }.status.grey { color: #68747d; background: #eef1f1; }
.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }.data-card { padding: 20px; }.data-card h3 { margin-top: 12px; }.data-card p { margin-top: 7px; color: var(--muted); }.data-card .actions { margin-top: 18px; }
.user-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }.user-card { padding: 22px; }.user-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; }.user-name { font-size: 17px; font-weight: 800; }.user-role { display: block; margin-top: 3px; color: var(--muted); font-size: 12px; }.user-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 22px; }.fact-label { display: block; color: var(--muted); font-size: 12px; }.fact-value { display: block; margin-top: 4px; font-weight: 700; }.quota-input { width: 110px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; }.text-button { margin: 4px 8px 0 0; padding: 0; border: 0; background: transparent; color: var(--green); font: inherit; font-weight: 700; cursor: pointer; }
.empty { padding: 70px; border: 1px dashed var(--line); border-radius: 18px; color: var(--muted); background: #fff; text-align: center; }
.modal-backdrop { position: fixed; z-index: 40; inset: 0; display: grid; place-items: center; padding: 30px; background: rgba(15, 23, 32, .42); }.modal { width: min(720px, 100%); max-height: 90vh; overflow: auto; padding: 28px; border-radius: 20px; background: #fff; box-shadow: var(--shadow); }.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }.modal-close { color: var(--muted); background: transparent; font-size: 26px; }.modal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }.modal .actions { justify-content: flex-end; margin-top: 24px; }.modal .primary { width: auto; margin-top: 0; }.toast { position: fixed; z-index: 60; right: 24px; bottom: 24px; max-width: 360px; padding: 12px 16px; border-radius: 12px; color: #fff; background: #10251d; box-shadow: var(--shadow); opacity: 0; transform: translateY(10px); pointer-events: none; transition: .2s ease; }.toast.show { opacity: 1; transform: translateY(0); }
@media (max-width: 980px) { .admin-shell { grid-template-columns: 82px minmax(0, 1fr); }.sidebar { padding: 20px 12px; }.sidebar .brand-lockup { justify-content: center; margin: 0 0 34px; }.sidebar .brand-lockup > div:not(.logo-mark), .nav-item span:not(.nav-icon), .sidebar-footer { display: none; }.nav-item { justify-content: center; padding: 12px 0; }.main { padding: 24px; }.shortcut-grid, .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.topbar-logout { display: block; } }
@media (max-width: 680px) { .admin-shell { display: block; }.sidebar { position: fixed; z-index: 30; right: 0; bottom: 0; left: 0; top: auto; width: 100%; height: calc(68px + env(safe-area-inset-bottom)); padding: 6px 8px calc(6px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); border-right: 0; }.sidebar .brand-lockup { display: none; }.nav-list { display: flex; align-items: stretch; justify-content: space-around; height: 56px; }.nav-item { flex: 1; width: auto; min-width: 0; height: 56px; padding: 3px 4px; flex-direction: column; justify-content: center; gap: 1px; line-height: 1.15; }.nav-item span:not(.nav-icon) { display: block; font-size: 10px; white-space: nowrap; }.nav-icon { line-height: 22px; }.main { padding: 22px 16px calc(94px + env(safe-area-inset-bottom)); }.topbar { align-items: start; }.topbar-meta { font-size: 12px; }.metric-grid, .shortcut-grid, .cards, .user-grid, .modal-grid { grid-template-columns: 1fr; }.toolbar { align-items: stretch; flex-direction: column; }.search-input { width: 100%; } }
