/* OgroOS Licensing portal (AP1). Our own stylesheet: system fonts, 8-px grid, light + dark.
   SPDX-FileCopyrightText: 2026 Dhaka Tek
   SPDX-License-Identifier: LicenseRef-OgroOS-Proprietary */

:root {
  color-scheme: light;
  --bg: #f4f6f5;
  --surface: #ffffff;
  --surface-2: #eef2f0;
  --surface-3: #e6ebe8;
  --border: #dde3e0;
  --border-strong: #c5cec9;
  --text: #17201b;
  --text-2: #56625b;
  --accent: #00733f;
  --accent-hover: #005f34;
  --accent-text: #ffffff;
  --accent-soft: #e3f4ea;
  --accent-soft-text: #00602f;
  --brand: #00a55b;
  --focus: #00a55b;
  --ok: #0b6b33; --ok-bg: #e2f5e8; --ok-line: #a9dcbb;
  --warn: #7a4a00; --warn-bg: #fdf0d5; --warn-line: #f0cf8a;
  --bad: #a8231b; --bad-bg: #fde8e6; --bad-line: #f2b8b2;
  --neutral: #47524c; --neutral-bg: #eaeeec; --neutral-line: #d3dad6;
  --info: #1d4f86; --info-bg: #e6f0fb; --info-line: #b9d2ee;
  --danger: #b3261e; --danger-hover: #93201a;
  --warn-fill: #c98200;
  --shadow-sm: 0 1px 2px rgba(16, 24, 20, .06);
  --shadow: 0 1px 2px rgba(16, 24, 20, .05), 0 4px 16px rgba(16, 24, 20, .06);
  --shadow-lg: 0 12px 40px rgba(16, 24, 20, .18);
  --sidebar: #fbfcfb;
  --radius: 12px;
  --radius-sm: 8px;
  --sidebar-w: 248px;
  --sidebar-w-collapsed: 72px;
  --topbar-h: 64px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0f1412; --surface: #161d1a; --surface-2: #1c2521; --surface-3: #232d29;
    --border: #2a3530; --border-strong: #3a4842; --text: #e6ece8; --text-2: #9aa8a0;
    --accent: #3fd18a; --accent-hover: #5fe0a0; --accent-text: #04140c; --accent-soft: #173a29; --accent-soft-text: #7ff0b8;
    --ok: #86e3ab; --ok-bg: #12301f; --ok-line: #23573a; --warn: #f5c46b; --warn-bg: #352507; --warn-line: #6a4a10;
    --bad: #ff9d95; --bad-bg: #3a1714; --bad-line: #6e2a24; --neutral: #bac5bf; --neutral-bg: #252e2a; --neutral-line: #36423c;
    --info: #9cc6f5; --info-bg: #13253a; --info-line: #27466b; --danger: #c7362d; --danger-hover: #dc4a40; --warn-fill: #e0a23a;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3); --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25);
    --shadow-lg: 0 12px 40px rgba(0, 0, 0, .5); --sidebar: #131916;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0f1412; --surface: #161d1a; --surface-2: #1c2521; --surface-3: #232d29;
  --border: #2a3530; --border-strong: #3a4842; --text: #e6ece8; --text-2: #9aa8a0;
  --accent: #3fd18a; --accent-hover: #5fe0a0; --accent-text: #04140c; --accent-soft: #173a29; --accent-soft-text: #7ff0b8;
  --ok: #86e3ab; --ok-bg: #12301f; --ok-line: #23573a; --warn: #f5c46b; --warn-bg: #352507; --warn-line: #6a4a10;
  --bad: #ff9d95; --bad-bg: #3a1714; --bad-line: #6e2a24; --neutral: #bac5bf; --neutral-bg: #252e2a; --neutral-line: #36423c;
  --info: #9cc6f5; --info-bg: #13253a; --info-line: #27466b; --danger: #c7362d; --danger-hover: #dc4a40; --warn-fill: #e0a23a;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3); --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 4px 16px rgba(0, 0, 0, .25);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, .5); --sidebar: #131916;
}

/* ---- base ---------------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 14px/1.5 system-ui, -apple-system, "Segoe UI", "Noto Sans", "Noto Sans Bengali", Ubuntu, Cantarell, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-underline-offset: 2px; }
a:hover { color: var(--accent-hover); }
h1, h2, h3 { margin: 0; line-height: 1.25; }
p { margin: 0 0 8px; }
code, kbd, .mono { font-family: ui-monospace, "SFMono-Regular", "DejaVu Sans Mono", Menlo, Consolas, monospace; font-size: .925em; }
.hash { overflow-wrap: anywhere; word-break: break-all; }  /* DL1: SHA-256 values */
.hash-line { margin: 16px 0 0; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }  /* DL1 */
details.withdraw > summary { list-style: none; cursor: pointer; }  /* DL1: withdraw a release */
details.withdraw > summary::-webkit-details-marker { display: none; }
details.withdraw[open] > summary { margin-bottom: 8px; }
details.withdraw form { display: flex; gap: 8px; align-items: center; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
html:not(.js) .js-only { display: none !important; }
.muted { color: var(--text-2); }
.icon { width: 20px; height: 20px; flex: none; }
.skip { position: absolute; left: 8px; top: -48px; z-index: 100; background: var(--accent); color: var(--accent-text);
  padding: 8px 16px; border-radius: var(--radius-sm); }
.skip:focus { top: 8px; }

/* ---- app shell ----------------------------------------------------------------------------- */
.app { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-w); flex: none; background: var(--sidebar); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; overflow-y: auto;
  transition: width .18s ease;
}
.brand { display: flex; align-items: center; gap: 12px; padding: 16px 20px; min-height: var(--topbar-h);
  text-decoration: none; color: var(--text); }
.brand img { width: 32px; height: 32px; flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.brand-text strong { font-size: 15px; letter-spacing: -.01em; white-space: nowrap; }
.brand-org { color: var(--text-2); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav { padding: 8px 12px; flex: 1; }
.nav-list, .nav-list ul { list-style: none; margin: 0; padding: 0; }
.nav-group { margin-top: 16px; }
.nav-label { display: block; padding: 0 12px 4px; font-size: 11px; font-weight: 600; letter-spacing: .06em;
  text-transform: uppercase; color: var(--text-2); }
.nav-item {
  display: flex; align-items: center; gap: 12px; padding: 8px 12px; margin: 2px 0; border-radius: var(--radius-sm);
  color: var(--text); text-decoration: none; font-weight: 500; width: 100%; border: 0; background: none;
  font: inherit; font-weight: 500; cursor: pointer; text-align: left; white-space: nowrap;
}
.nav-item .icon { color: var(--text-2); }
.nav-item:hover { background: var(--surface-2); color: var(--text); }
.nav-item[aria-current="page"] { background: var(--accent-soft); color: var(--accent-soft-text); font-weight: 600; }
.nav-item[aria-current="page"] .icon { color: var(--accent-soft-text); }
.sidebar-foot { padding: 8px 12px 16px; border-top: 1px solid var(--border); }
.collapse-btn .icon { transition: transform .18s ease; }

:root[data-sidebar="collapsed"] .sidebar { width: var(--sidebar-w-collapsed); }
:root[data-sidebar="collapsed"] .sidebar .brand { padding: 16px 20px; }
:root[data-sidebar="collapsed"] .sidebar .brand-text,
:root[data-sidebar="collapsed"] .sidebar .nav-text { display: none; }
:root[data-sidebar="collapsed"] .sidebar .nav-label { height: 1px; padding: 0; margin: 8px 12px; background: var(--border);
  overflow: hidden; color: transparent; }
:root[data-sidebar="collapsed"] .sidebar .nav-item { justify-content: center; padding: 10px; }
:root[data-sidebar="collapsed"] .collapse-btn .icon { transform: rotate(180deg); }

.main-col { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 20; height: var(--topbar-h); display: flex; align-items: center; gap: 16px;
  padding: 0 24px; background: color-mix(in srgb, var(--surface) 88%, transparent); border-bottom: 1px solid var(--border);
  backdrop-filter: saturate(1.4) blur(8px);
}
.topbar-end { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0;
  font-size: 13px; color: var(--text-2); }
.crumbs li + li::before { content: "/"; margin: 0 4px 0 0; color: var(--border-strong); }
.crumbs a { color: var(--text-2); text-decoration: none; }
.crumbs a:hover { color: var(--text); text-decoration: underline; }
.crumbs [aria-current] { color: var(--text); font-weight: 600; }
.env-badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; white-space: nowrap;
  background: var(--warn-bg); color: var(--warn); border: 1px solid var(--warn-line); font-size: 12px; font-weight: 600;
}
.env-icon { width: 14px; height: 14px; }
.search { position: relative; display: flex; align-items: center; }
.search input[type="search"] {
  width: 340px; height: 36px; padding: 0 36px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text); font: inherit;
}
.search input[type="search"]:focus { background: var(--surface); border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px var(--accent-soft); }
.search-icon { position: absolute; left: 10px; width: 16px; height: 16px; color: var(--text-2); pointer-events: none; }
.search kbd { position: absolute; right: 8px; font-size: 11px; padding: 1px 6px; border: 1px solid var(--border);
  border-radius: 4px; color: var(--text-2); background: var(--surface); }
.icon-btn {
  display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: var(--radius-sm);
  border: 1px solid transparent; background: none; color: var(--text-2); cursor: pointer; padding: 0;
}
.icon-btn:hover { background: var(--surface-2); color: var(--text); }
.icon-btn .t-light, .icon-btn .t-dark { display: none; }
:root[data-theme="light"] .icon-btn .t-system, :root[data-theme="dark"] .icon-btn .t-system { display: none; }
:root[data-theme="light"] .icon-btn .t-light { display: block; }
:root[data-theme="dark"] .icon-btn .t-dark { display: block; }
.menu-btn { display: none; }

.user-menu { position: relative; }
.user-menu summary {
  list-style: none; display: flex; align-items: center; gap: 8px; padding: 4px 8px 4px 4px; border-radius: 999px;
  cursor: pointer; border: 1px solid var(--border); background: var(--surface);
}
.user-menu summary::-webkit-details-marker { display: none; }
.user-menu summary:hover { background: var(--surface-2); }
.avatar { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; font-size: 12px;
  font-weight: 700; background: var(--accent); color: var(--accent-text); }
.user-text { display: flex; flex-direction: column; line-height: 1.15; max-width: 180px; }
.user-name { font-weight: 600; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-role { font-size: 11px; color: var(--text-2); white-space: nowrap; }
.caret { width: 16px; height: 16px; color: var(--text-2); }
.menu {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 240px; background: var(--surface); z-index: 30;
  border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 8px;
}
.menu-head { display: flex; flex-direction: column; gap: 2px; padding: 8px 12px 12px; border-bottom: 1px solid var(--border);
  margin-bottom: 8px; font-size: 13px; }
.menu-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: var(--radius-sm);
  color: var(--text); text-decoration: none; }
.menu-item:hover { background: var(--surface-2); color: var(--text); }

.content { padding: 24px; width: 100%; max-width: 1360px; outline: none; }
.foot { margin-top: auto; padding: 16px 24px 24px; color: var(--text-2); font-size: 12px; }

/* ---- page parts ---------------------------------------------------------------------------- */
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 24px;
  flex-wrap: wrap; }
.page-head h1 { font-size: 24px; letter-spacing: -.015em; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.page-head .desc { color: var(--text-2); margin: 4px 0 0; max-width: 72ch; }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm);
  margin-bottom: 24px; min-width: 0;
}
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 16px 24px;
  border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.card-head h2 { font-size: 16px; }
.card-desc { color: var(--text-2); margin: 2px 0 0; font-size: 13px; }
.card-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.card-body { padding: 24px; }
.card.flush > .card-body { padding: 0; }
.grid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); align-items: start; }
.grid > .card { margin-bottom: 0; }
.grid + .card, .grid + .grid { margin-top: 24px; }
.grid-2-1 { display: grid; gap: 24px; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); align-items: start; }
.grid-2-1 > .card { margin-bottom: 0; }
.stack > * + * { margin-top: 16px; }

.kpis { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); margin-bottom: 24px; }
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px;
  box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.kpi-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.kpi-label { color: var(--text-2); font-size: 13px; font-weight: 500; }
.kpi-icon { color: var(--accent); background: var(--accent-soft); border-radius: 8px; padding: 6px; width: 32px; height: 32px; }
.kpi.warn .kpi-icon { color: var(--warn); background: var(--warn-bg); }
.kpi-value { font-size: 28px; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.kpi-value small { font-size: 16px; font-weight: 600; color: var(--text-2); }
.kpi-sub { color: var(--text-2); font-size: 12px; }
.kpi .bar { width: 100%; height: 8px; }

.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px 24px; margin: 0; }
.facts dt { color: var(--text-2); font-size: 12px; font-weight: 500; margin-bottom: 4px; }
.facts dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }

/* ---- alerts, badges, pills, bars --------------------------------------------------------- */
.alert { display: flex; gap: 12px; align-items: flex-start; padding: 12px 16px; border-radius: var(--radius-sm);
  border: 1px solid; margin-bottom: 24px; }
.alert.ok { background: var(--ok-bg); color: var(--ok); border-color: var(--ok-line); }
.alert.bad { background: var(--bad-bg); color: var(--bad); border-color: var(--bad-line); }
.alert.info { background: var(--info-bg); color: var(--info); border-color: var(--info-line); }
.alert.warn { background: var(--warn-bg); color: var(--warn); border-color: var(--warn-line); }
.alert p:last-child { margin: 0; }
.card-body > .alert:last-child { margin-bottom: 0; }
.badge, .pill { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 600; line-height: 18px; white-space: nowrap; border: 1px solid transparent; vertical-align: middle; }
.badge .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.ok, .pill.ok { background: var(--ok-bg); color: var(--ok); border-color: var(--ok-line); }
.badge.warn, .pill.warn { background: var(--warn-bg); color: var(--warn); border-color: var(--warn-line); }
.badge.bad, .pill.bad { background: var(--bad-bg); color: var(--bad); border-color: var(--bad-line); }
.badge.neutral, .pill.neutral { background: var(--neutral-bg); color: var(--neutral); border-color: var(--neutral-line); }
.badge.info, .pill.info { background: var(--info-bg); color: var(--info); border-color: var(--info-line); }
.pill { font-weight: 500; padding: 1px 8px; }
.pill.mono { font-family: ui-monospace, "DejaVu Sans Mono", Menlo, monospace; font-size: 11.5px; }
.page-head .badge { font-size: 12px; }

.seats { display: inline-flex; flex-direction: column; gap: 4px; min-width: 88px; }
.seats-num { font-variant-numeric: tabular-nums; font-weight: 600; }
.bar { display: block; width: 88px; height: 6px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.bar-fill { display: block; height: 100%; border-radius: 999px; background: var(--accent); }
.bar.full .bar-fill { background: var(--warn-fill); }
.w0 { width: 0; } .w5 { width: 5%; } .w10 { width: 10%; } .w15 { width: 15%; } .w20 { width: 20%; } .w25 { width: 25%; }
.w30 { width: 30%; } .w35 { width: 35%; } .w40 { width: 40%; } .w45 { width: 45%; } .w50 { width: 50%; } .w55 { width: 55%; }
.w60 { width: 60%; } .w65 { width: 65%; } .w70 { width: 70%; } .w75 { width: 75%; } .w80 { width: 80%; } .w85 { width: 85%; }
.w90 { width: 90%; } .w95 { width: 95%; } .w100 { width: 100%; }

/* ---- tables -------------------------------------------------------------------------------- */
.table-wrap { overflow: auto; max-height: 72vh; }
.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13.5px; }
.table th { position: sticky; top: 0; z-index: 1; background: var(--surface-2); color: var(--text-2); font-size: 12px;
  font-weight: 600; text-align: left; padding: 10px 16px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.table td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover td { background: color-mix(in srgb, var(--surface-2) 55%, transparent); }
.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table .act { text-align: right; white-space: nowrap; width: 1%; }
.table .act > * + * { margin-left: 8px; }
.table .nowrap, .table td.date { white-space: nowrap; }
.table .strong { font-weight: 600; color: var(--text); }
.sub { display: block; color: var(--text-2); font-size: 12px; font-weight: 400; margin-top: 2px; }
.table a.row-link { color: var(--text); font-weight: 600; text-decoration: none; }
.table a.row-link:hover { color: var(--accent); text-decoration: underline; }
.table .mono { color: var(--text-2); }
.table details summary { cursor: pointer; color: var(--accent); }
.table details ul { margin: 8px 0 0; padding-left: 16px; }
.card.flush .table th:first-child, .card.flush .table td:first-child { padding-left: 24px; }
.card.flush .table th:last-child, .card.flush .table td:last-child { padding-right: 24px; }
.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; padding: 40px 24px;
  color: var(--text-2); }
.empty p { margin: 0; max-width: 48ch; }
.empty-icon { width: 40px; height: 40px; padding: 8px; border-radius: 50%; background: var(--surface-2); color: var(--text-2); }

/* ---- buttons and forms --------------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 36px; padding: 0 14px;
  border-radius: var(--radius-sm); border: 1px solid var(--border-strong); background: var(--surface); color: var(--text);
  font: inherit; font-weight: 600; font-size: 13.5px; cursor: pointer; text-decoration: none; white-space: nowrap;
  box-shadow: var(--shadow-sm);
}
.btn .icon { width: 16px; height: 16px; }
.btn:hover { background: var(--surface-2); color: var(--text); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-text); }
.btn.danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn.danger:hover { background: var(--danger-hover); border-color: var(--danger-hover); color: #fff; }
.btn.danger-ghost { color: var(--bad); border-color: var(--bad-line); }
.btn.danger-ghost:hover { background: var(--bad-bg); color: var(--bad); }
.btn.ghost { border-color: transparent; box-shadow: none; background: none; }
.btn.ghost:hover { background: var(--surface-2); }
.btn.sm { height: 30px; padding: 0 10px; font-size: 12.5px; }
.btn.block { width: 100%; height: 40px; }
form.inline { display: inline; margin: 0; }
.form { display: grid; gap: 16px; }
.form-row { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.form-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding-top: 8px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label { font-weight: 600; font-size: 13px; }
.req { color: var(--bad); margin-left: 2px; }
.help { color: var(--text-2); font-size: 12px; margin: 0; }
.field.check { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px; }
.field.check > label { font-weight: 500; }
.field.check .help { flex-basis: 100%; margin-left: 26px; }
input[type="text"], input[type="password"], input[type="number"], input[type="date"], input[type="search"],
input:not([type]), select, textarea {
  font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm); padding: 8px 12px; min-height: 38px; width: 100%; max-width: 100%;
}
textarea { min-height: 120px; resize: vertical; font-family: ui-monospace, "DejaVu Sans Mono", Menlo, monospace; font-size: 13px; }
input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--accent); margin: 0; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
input:user-invalid, select:user-invalid, textarea:user-invalid { border-color: var(--bad); box-shadow: 0 0 0 3px var(--bad-bg); }
input.mono { font-family: ui-monospace, "DejaVu Sans Mono", Menlo, monospace; letter-spacing: .03em; }
.inline-form { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; }
.inline-form .field { flex: 1 1 160px; }
.actions-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.action-tile { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px; background: var(--surface);
  display: flex; flex-direction: column; gap: 12px; }
.action-tile h3 { font-size: 14px; }
.action-tile p { color: var(--text-2); font-size: 12.5px; margin: 0; }
.action-tile form { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; margin-top: auto; }
.action-tile form .field { flex: 1 1 140px; }
.action-tile.danger-zone { border-color: var(--bad-line); }

/* ---- once-shown secrets -------------------------------------------------------------------- */
.secret { border: 1px solid var(--ok-line); background: var(--ok-bg); border-radius: var(--radius); padding: 16px;
  margin-bottom: 16px; }
.secret-label { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--ok); margin-bottom: 8px;
  font-size: 13px; }
.secret-label .icon { width: 16px; height: 16px; }
.secret-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.secret-value { flex: 1 1 260px; font-size: 18px; font-weight: 600; letter-spacing: .04em; color: var(--text);
  background: var(--surface); border: 1px dashed var(--ok-line); border-radius: var(--radius-sm); padding: 10px 14px;
  overflow-wrap: anywhere; user-select: all; }
.secret-note { margin: 8px 0 0; color: var(--ok); font-size: 12px; }
.answer { width: 100%; min-height: 280px; }
.btn.copied { border-color: var(--ok-line); color: var(--ok); }

/* ---- dialog -------------------------------------------------------------------------------- */
.dialog { border: 1px solid var(--border); border-radius: var(--radius); padding: 0; background: var(--surface);
  color: var(--text); box-shadow: var(--shadow-lg); width: min(440px, calc(100vw - 32px)); }
.dialog::backdrop { background: rgba(8, 14, 11, .55); }
.dialog form { margin: 0; }
.dialog-body { display: flex; gap: 16px; padding: 24px; }
.dialog-body h2 { font-size: 16px; margin-bottom: 8px; }
.dialog-body p { color: var(--text-2); margin: 0; }
.dialog-icon { width: 40px; height: 40px; padding: 9px; border-radius: 50%; background: var(--bad-bg); color: var(--bad); }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 24px; background: var(--surface-2);
  border-top: 1px solid var(--border); border-radius: 0 0 var(--radius) var(--radius); }

/* ---- sign-in and public pages -------------------------------------------------------------- */
.auth { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 32px 16px; position: relative; background:
  radial-gradient(1200px 600px at 50% -10%, var(--accent-soft), transparent 70%), var(--bg); }
.auth-tools { position: absolute; top: 16px; right: 16px; }
.auth-card { width: min(400px, 100%); background: var(--surface); border: 1px solid var(--border); border-radius: 16px;
  box-shadow: var(--shadow-lg); padding: 32px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.auth-mark { width: 56px; height: 56px; margin-bottom: 16px; }
.auth-card h1 { font-size: 20px; letter-spacing: -.01em; }
.auth-role { color: var(--text-2); margin: 4px 0 12px; }
.auth-card .env-badge { margin-bottom: 24px; }
.auth-card .alert { width: 100%; text-align: left; }
.auth-card form { width: 100%; text-align: left; display: grid; gap: 16px; }
.auth-foot { margin-top: 16px; font-size: 13px; }
.auth-foot a { color: var(--text-2); }

.public-bar { display: flex; align-items: center; gap: 16px; padding: 0 24px; height: var(--topbar-h);
  background: var(--surface); border-bottom: 1px solid var(--border); }
.public-bar .brand { padding: 0; min-height: 0; }
.public-main { max-width: 960px; margin: 0 auto; padding: 40px 24px; width: 100%; outline: none; }
.area-public { display: flex; flex-direction: column; min-height: 100vh; }
.tiles { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.tile { display: flex; flex-direction: column; gap: 8px; padding: 20px; border: 1px solid var(--border);
  border-radius: var(--radius); background: var(--surface); color: var(--text); text-decoration: none; box-shadow: var(--shadow-sm); }
.tile:hover { border-color: var(--accent); color: var(--text); box-shadow: var(--shadow); }
.tile .icon { color: var(--accent); background: var(--accent-soft); border-radius: 8px; padding: 6px; width: 34px; height: 34px; }
.tile strong { font-size: 15px; }
.tile span { color: var(--text-2); font-size: 13px; }
.steps { margin: 0 0 16px; padding-left: 20px; color: var(--text-2); }
.steps li { margin-bottom: 4px; }
.search-group + .search-group { margin-top: 24px; }
.result-list { list-style: none; margin: 0; padding: 0; }
.result-list li { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 12px 24px;
  border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.result-list li:last-child { border-bottom: 0; }

/* ---- responsive ---------------------------------------------------------------------------- */
@media (max-width: 1279px) {
  .search input[type="search"] { width: 240px; }
  .user-text { display: none; }
}
@media (max-width: 1023px) {
  .grid-2-1 { grid-template-columns: minmax(0, 1fr); }
  .user-text { display: none; }
  /* without JavaScript: the navigation stacks above the content */
  html:not(.js) .app { flex-direction: column; }
  html:not(.js) .sidebar { width: 100%; height: auto; position: static; border-right: 0; border-bottom: 1px solid var(--border); }
  html:not(.js) .nav-list, html:not(.js) .nav-list ul { display: flex; flex-wrap: wrap; gap: 4px; }
  html:not(.js) .nav-group { margin: 0; display: contents; }
  html:not(.js) .nav-label { display: none; }
  html:not(.js) .nav-item { width: auto; }
  /* with JavaScript: an off-canvas drawer */
  .js .sidebar { position: fixed; left: 0; top: 0; bottom: 0; z-index: 50; width: min(288px, 86vw) !important;
    transform: translateX(-100%); transition: transform .2s ease; box-shadow: none; visibility: hidden; }
  .js[data-drawer="open"] .sidebar { transform: none; box-shadow: var(--shadow-lg); visibility: visible; }
  .js .sidebar .brand-text, .js .sidebar .nav-text { display: flex !important; }
  .js .sidebar .nav-label { height: auto !important; margin: 0 !important; padding: 0 12px 4px !important;
    background: none !important; color: var(--text-2) !important; }
  .js .sidebar .nav-item { justify-content: flex-start !important; padding: 8px 12px !important; }
  .js .sidebar-foot { display: none; }
  .scrim { position: fixed; inset: 0; background: rgba(8, 14, 11, .5); z-index: 40; }
  .menu-btn { display: inline-grid; }
  .topbar { padding: 0 16px; gap: 8px; }
  .search { display: none; }
}
@media (max-width: 719px) {
  .content { padding: 16px; }
  .topbar .crumbs { display: none; }
  .topbar .env-badge span { display: none; }
  .topbar .env-badge { padding: 6px; }
  .public-bar .env-badge span { display: none; }
  .public-bar .env-badge { padding: 6px; }
  .public-bar { padding: 0 16px; }
  .public-main { padding: 24px 16px; }
  .page-head h1 { font-size: 20px; }
  .card-head { padding: 16px; }
  .card-body { padding: 16px; }
  .card.flush .table th:first-child, .card.flush .table td:first-child { padding-left: 16px; }
  .card.flush .table th:last-child, .card.flush .table td:last-child { padding-right: 16px; }
  .table th, .table td { padding: 10px 12px; }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .kpi { padding: 12px 14px; }
  .kpi-value { font-size: 22px; }
  .kpi-icon { display: none; }
  .kpi:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .table td { white-space: nowrap; }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .auth-card { padding: 24px; }
  .result-list li { padding: 12px 16px; }
  .secret-value { font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
@media print {
  .sidebar, .topbar, .foot, .page-actions, .js-only { display: none !important; }
  .card { box-shadow: none; break-inside: avoid; }
  .table-wrap { max-height: none; overflow: visible; }
}
