/* =========================================================================
   Vaultkeeper — ledger & seal design system
   ========================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700&family=Inter:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root {
  --ink:            #10131a;
  --panel:          #191f29;
  --panel-raised:   #212938;
  --panel-hover:    #253044;
  --border:         #2b3547;
  --border-soft:    #232c3b;
  --parchment:      #ece5d4;
  --parchment-dim:  #c9c2ae;
  --muted:          #8a93a8;
  --brass:          #c6a15b;
  --brass-bright:   #e3c07f;
  --rust:           #c1503f;
  --amber:          #dc9c3a;
  --teal:           #4e9c8e;
  --danger:         #c1503f;

  --font-display: 'Fraunces', serif;
  --font-body: 'Inter', -apple-system, sans-serif;
  --font-mono: 'IBM Plex Mono', monospace;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-lift: 0 12px 32px -12px rgba(0,0,0,0.55);
}

* { box-sizing: border-box; }

html[data-theme="light"] {
  --ink:            #f7f3ea;
  --panel:          #ffffff;
  --panel-raised:   #faf7ef;
  --panel-hover:    #f1ead9;
  --border:         #ddd2b3;
  --border-soft:    #ece4d0;
  --parchment:      #241f14;
  --parchment-dim:  #55503f;
  --muted:          #756f5a;
  --brass:          #97742f;
  --brass-bright:   #b08a45;
  --rust:           #b23f2f;
  --amber:          #ad711b;
  --teal:           #2f7a6c;
  --danger:         #b23f2f;
  --shadow-lift: 0 12px 32px -12px rgba(40,30,10,0.18);
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--ink);
  color: var(--parchment);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

body {
  background-image:
    radial-gradient(circle at 15% 0%, rgba(198,161,91,0.06), transparent 45%),
    radial-gradient(circle at 90% 15%, rgba(78,156,142,0.05), transparent 40%);
  min-height: 100vh;
}

html[data-theme="light"] body {
  background-image:
    radial-gradient(circle at 15% 0%, rgba(151,116,47,0.05), transparent 45%),
    radial-gradient(circle at 90% 15%, rgba(47,122,108,0.04), transparent 40%);
}

a { color: inherit; }

::selection { background: var(--brass); color: var(--ink); }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: var(--brass); }

:focus-visible {
  outline: 2px solid var(--brass-bright);
  outline-offset: 2px;
}

button, input, select, textarea { font-family: inherit; }

h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 600; margin: 0; letter-spacing: 0.01em; }

.mono { font-family: var(--font-mono); }

/* =========================================================================
   Login page
   ========================================================================= */

.login-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.login-card {
  width: 100%;
  max-width: 380px;
  background: linear-gradient(180deg, var(--panel-raised), var(--panel));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 36px 32px;
  box-shadow: var(--shadow-lift);
  position: relative;
  overflow: hidden;
}

.login-card::before {
  content: "";
  position: absolute;
  top: -60px; left: -60px;
  width: 160px; height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(198,161,91,0.18), transparent 70%);
}

.login-seal {
  width: 52px; height: 52px;
  border-radius: 50%;
  border: 1.5px solid var(--brass);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 20px;
  color: var(--brass-bright);
  font-family: var(--font-display);
  font-size: 22px;
  box-shadow: 0 0 0 4px rgba(198,161,91,0.08);
}

.login-card h1 {
  text-align: center;
  font-size: 26px;
  color: var(--parchment);
  margin-bottom: 4px;
}

.login-sub {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 28px;
}

.field { margin-bottom: 16px; }

.field label {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brass);
  margin-bottom: 6px;
}

.field input, .field select, .field textarea {
  width: 100%;
  background: var(--ink);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 11px 12px;
  color: var(--parchment);
  font-size: 14px;
  transition: border-color 0.15s ease;
}

.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--brass);
}

.field textarea { resize: vertical; min-height: 70px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--brass);
  background: var(--brass);
  color: var(--ink);
  font-weight: 600;
  font-size: 13.5px;
  padding: 11px 18px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: transform 0.1s ease, background 0.15s ease, box-shadow 0.15s ease;
  letter-spacing: 0.01em;
}
.btn:hover { background: var(--brass-bright); border-color: var(--brass-bright); }
.btn:active { transform: translateY(1px); }
.btn.block { width: 100%; }

.btn-ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--parchment-dim);
}
.btn-ghost:hover { border-color: var(--brass); color: var(--brass-bright); background: rgba(198,161,91,0.06); }

.btn-danger {
  background: transparent;
  border: 1px solid rgba(193,80,63,0.5);
  color: #e08475;
}
.btn-danger:hover { background: rgba(193,80,63,0.12); border-color: var(--rust); }

.btn-sm { padding: 6px 12px; font-size: 12.5px; }

.login-error {
  background: rgba(193,80,63,0.12);
  border: 1px solid rgba(193,80,63,0.4);
  color: #e69488;
  font-size: 13px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  display: none;
}
.login-error.show { display: block; }

.login-hint {
  text-align: center;
  margin-top: 20px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
}
.login-hint .mono { color: var(--brass-bright); }

/* =========================================================================
   App shell
   ========================================================================= */

.app-shell {
  display: grid;
  grid-template-columns: 240px 1fr;
  min-height: 100vh;
}

.sidebar {
  background: var(--panel);
  border-right: 1px solid var(--border-soft);
  padding: 26px 18px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 6px 24px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--border-soft);
}

.brand-mark {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1.5px solid var(--brass);
  display: flex; align-items: center; justify-content: center;
  color: var(--brass-bright);
  font-family: var(--font-display);
  font-size: 16px;
  flex-shrink: 0;
}

.brand-text { font-family: var(--font-display); font-size: 17px; color: var(--parchment); line-height: 1.2; }
.brand-text span { display: block; font-family: var(--font-body); font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-top: 2px; }

.nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: var(--parchment-dim);
  cursor: pointer;
  font-size: 14px;
  border: 1px solid transparent;
  transition: background 0.15s ease, color 0.15s ease;
  user-select: none;
}
.nav-item:hover { background: var(--panel-hover); color: var(--parchment); }
.nav-item.active { background: rgba(198,161,91,0.1); border-color: rgba(198,161,91,0.35); color: var(--brass-bright); }
.nav-icon { width: 18px; text-align: center; opacity: 0.85; }
.nav-count {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
  background: var(--ink);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 1px 7px;
}

.sidebar-footer {
  border-top: 1px solid var(--border-soft);
  padding-top: 16px;
  margin-top: 10px;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
}

.user-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--panel-raised);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display);
  font-size: 13px;
  color: var(--brass-bright);
  overflow: hidden;
  flex-shrink: 0;
}
.user-avatar img { width: 100%; height: 100%; object-fit: cover; }

.user-meta { line-height: 1.25; min-width: 0; }
.user-meta .uname { font-size: 13px; color: var(--parchment); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-meta .urole { font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }

.main {
  padding: 32px 40px 60px;
  max-width: 1180px;
  width: 100%;
}

.page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 26px;
  gap: 20px;
  flex-wrap: wrap;
}

.page-header h1 { font-size: 28px; color: var(--parchment); }
.page-eyebrow { font-size: 11px; text-transform: uppercase; letter-spacing: 0.14em; color: var(--brass); margin-bottom: 6px; }
.page-sub { color: var(--muted); font-size: 13.5px; margin-top: 6px; max-width: 520px; }

/* =========================================================================
   Dashboard
   ========================================================================= */

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px;
  margin-bottom: 34px;
}

.stat-card {
  background: var(--panel);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
  padding: 18px 18px 16px;
  position: relative;
  overflow: hidden;
}
.stat-card .num { font-family: var(--font-display); font-size: 30px; color: var(--brass-bright); }
.stat-card .label { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.07em; margin-top: 4px; }

.section-title {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--parchment);
  margin: 6px 0 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.section-title::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border-soft);
}

/* =========================================================================
   Ledger rows (list items) — expandable cards
   ========================================================================= */

.ledger { display: flex; flex-direction: column; gap: 10px; }

.item-card {
  background: var(--panel);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: border-color 0.15s ease;
}
.item-card:hover { border-color: var(--border); }
.item-card.open { border-color: rgba(198,161,91,0.4); }

.item-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  cursor: pointer;
}

.thumb {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--panel-raised);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display);
  font-size: 16px;
  color: var(--brass-bright);
  overflow: hidden;
  flex-shrink: 0;
}
.thumb img { width: 100%; height: 100%; object-fit: cover; }

.item-main { flex: 1; min-width: 0; }
.item-title { font-size: 14.5px; color: var(--parchment); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item-sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.item-right { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }

/* seal / burn ring — signature element */
.seal-ring {
  --pct: 0;
  --ring-color: var(--teal);
  width: 40px; height: 40px;
  border-radius: 50%;
  background: conic-gradient(var(--ring-color) calc(var(--pct) * 1%), var(--border-soft) 0);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  position: relative;
}
.seal-ring::before {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  background: var(--panel);
}
.seal-ring .seal-label {
  position: relative;
  font-family: var(--font-mono);
  font-size: 9.5px;
  color: var(--parchment-dim);
  text-align: center;
  line-height: 1.1;
}

.status-pill {
  font-family: var(--font-mono);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 9px;
  border-radius: 20px;
  border: 1px solid;
  white-space: nowrap;
}
.status-expired { color: #e69488; border-color: rgba(193,80,63,0.5); background: rgba(193,80,63,0.1); }
.status-critical { color: #f0be6f; border-color: rgba(220,156,58,0.5); background: rgba(220,156,58,0.1); }
.status-warning { color: var(--brass-bright); border-color: rgba(198,161,91,0.5); background: rgba(198,161,91,0.1); }
.status-ok { color: #7fc3b6; border-color: rgba(78,156,142,0.5); background: rgba(78,156,142,0.1); }
.status-none { color: var(--muted); border-color: var(--border); background: transparent; }

html[data-theme="light"] .status-expired { color: #8f3226; border-color: rgba(178,63,47,0.4); background: rgba(178,63,47,0.08); }
html[data-theme="light"] .status-critical { color: #8a5a12; border-color: rgba(173,113,27,0.4); background: rgba(173,113,27,0.08); }
html[data-theme="light"] .status-warning { color: #7a5f24; border-color: rgba(151,116,47,0.4); background: rgba(151,116,47,0.08); }
html[data-theme="light"] .status-ok { color: #235e52; border-color: rgba(47,122,108,0.4); background: rgba(47,122,108,0.08); }

.chevron { color: var(--muted); font-size: 12px; transition: transform 0.15s ease; flex-shrink: 0; }
.item-card.open .chevron { transform: rotate(90deg); color: var(--brass); }

.item-detail {
  display: none;
  padding: 4px 20px 20px 72px;
  border-top: 1px solid var(--border-soft);
}
.item-card.open .item-detail { display: block; }

.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px 20px;
  margin: 16px 0;
}
.detail-field label {
  display: block;
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  margin-bottom: 5px;
}
.detail-field .val { font-size: 13.5px; color: var(--parchment); }
.detail-field .val.mono { font-size: 13px; }

.detail-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--border-soft);
}

.sub-block {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px dashed var(--border-soft);
}
.sub-block-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brass);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--panel-raised);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 5px 10px 5px 6px;
  font-size: 12.5px;
  color: var(--parchment-dim);
}
.chip-x {
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  flex-shrink: 0;
}
.chip-x:hover { color: var(--rust); }

.mini-list { display: flex; flex-direction: column; gap: 8px; }
.mini-item {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--panel-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
}
.mini-item .mi-title { font-size: 13px; color: var(--parchment); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-decoration: none; }
.mini-item .mi-title:hover { color: var(--brass-bright); text-decoration: underline; }
.mini-item .mi-meta { font-size: 11.5px; color: var(--muted); font-family: var(--font-mono); white-space: nowrap; }

/* =========================================================================
   Forms (create / edit)
   ========================================================================= */

.form-panel {
  background: var(--panel-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
  margin-bottom: 18px;
  display: none;
}
.form-panel.show { display: block; }

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}
.form-grid .field { margin-bottom: 0; }
.field.span-2 { grid-column: span 2; }
.field.checkbox-field { display: flex; align-items: center; gap: 8px; margin-top: 6px; }
.field.checkbox-field input { width: auto; }
.field.checkbox-field label { margin: 0; text-transform: none; letter-spacing: 0; font-size: 13.5px; color: var(--parchment-dim); }

.form-actions { display: flex; gap: 10px; margin-top: 18px; }

.image-upload {
  display: flex;
  align-items: center;
  gap: 12px;
}
.image-upload .up-thumb {
  width: 54px; height: 54px;
  border-radius: 50%;
  border: 1px dashed var(--border);
  background: var(--ink);
  display: flex; align-items: center; justify-content: center;
  color: var(--muted);
  font-size: 11px;
  overflow: hidden;
  flex-shrink: 0;
}
.image-upload .up-thumb img { width: 100%; height: 100%; object-fit: cover; }
.image-upload input[type=file] { display: none; }

.toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  gap: 12px;
  flex-wrap: wrap;
}

.search-input {
  background: var(--panel);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-sm);
  padding: 9px 12px;
  color: var(--parchment);
  font-size: 13.5px;
  min-width: 220px;
}

.empty-state {
  text-align: center;
  padding: 50px 20px;
  color: var(--muted);
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  font-size: 13.5px;
}
.empty-state strong { display: block; color: var(--parchment-dim); font-family: var(--font-display); font-size: 17px; margin-bottom: 6px; font-weight: 500; }

.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--panel-raised);
  border: 1px solid var(--brass);
  color: var(--parchment);
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  box-shadow: var(--shadow-lift);
  z-index: 999;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
  max-width: 340px;
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast.err { border-color: var(--rust); }

.badge-admin-only {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2px 6px;
}

.person-select-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.person-select-row select { flex: 1; min-width: 140px; }

/* =========================================================================
   Renewal history — flowchart
   ========================================================================= */

.history-flow {
  display: flex;
  align-items: center;
  gap: 4px;
  overflow-x: auto;
  padding: 6px 2px 12px;
}

.history-node {
  flex-shrink: 0;
  min-width: 148px;
  background: var(--panel-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  text-align: center;
}
.history-node.status-expired { border-color: rgba(193,80,63,0.45); background: rgba(193,80,63,0.08); }
.history-node.status-critical { border-color: rgba(220,156,58,0.45); background: rgba(220,156,58,0.08); }
.history-node.status-warning { border-color: rgba(198,161,91,0.45); background: rgba(198,161,91,0.08); }
.history-node.status-ok { border-color: rgba(78,156,142,0.45); background: rgba(78,156,142,0.08); }

.hn-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brass);
  margin-bottom: 5px;
}
.history-node.status-expired .hn-tag { color: #e69488; }
.history-node.status-ok .hn-tag { color: #7fc3b6; }

.hn-dates {
  font-size: 12.5px;
  color: var(--parchment);
  font-family: var(--font-mono);
  white-space: nowrap;
}

.history-arrow {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 0 6px;
  color: var(--brass);
}
.ha-glyph { font-size: 18px; line-height: 1; }
.ha-label {
  font-size: 9.5px;
  color: var(--muted);
  white-space: nowrap;
  font-family: var(--font-mono);
}

html[data-theme="light"] .history-node.status-expired { border-color: rgba(178,63,47,0.35); background: rgba(178,63,47,0.06); }
html[data-theme="light"] .history-node.status-critical { border-color: rgba(173,113,27,0.35); background: rgba(173,113,27,0.06); }
html[data-theme="light"] .history-node.status-warning { border-color: rgba(151,116,47,0.35); background: rgba(151,116,47,0.06); }
html[data-theme="light"] .history-node.status-ok { border-color: rgba(47,122,108,0.35); background: rgba(47,122,108,0.06); }
html[data-theme="light"] .history-node.status-expired .hn-tag { color: #8f3226; }
html[data-theme="light"] .history-node.status-ok .hn-tag { color: #235e52; }

.login-theme-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  border-radius: 50%;
  width: 38px;
  height: 38px;
  padding: 0;
  font-size: 16px;
}

html[data-theme="light"] .login-error { color: #8f3226; background: rgba(178,63,47,0.08); border-color: rgba(178,63,47,0.35); }
html[data-theme="light"] .btn-danger { color: #8f3226; }
html[data-theme="light"] .btn-danger:hover { background: rgba(178,63,47,0.1); }

/* =========================================================================
   Notifications
   ========================================================================= */

.unread-notification { border-color: rgba(198,161,91,0.5); background: rgba(198,161,91,0.05); }

.notif-check {
  display: flex;
  align-items: center;
  padding-right: 2px;
  cursor: pointer;
}
.notif-check input {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--brass);
}

/* =========================================================================
   Discontinued items
   ========================================================================= */

.item-card.discontinued-item { opacity: 0.6; }
.item-card.discontinued-item:hover { opacity: 0.85; }
.item-card.discontinued-item.open { opacity: 1; }

.status-discontinued {
  color: var(--muted);
  border-color: var(--border);
  background: var(--panel-raised);
  text-decoration: line-through;
  text-decoration-color: rgba(138,147,168,0.5);
}

@media (max-width: 860px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { position: relative; height: auto; flex-direction: row; overflow-x: auto; padding: 14px; }
  .brand { border: none; padding: 0; margin: 0 14px 0 0; }
  .nav { flex-direction: row; }
  .sidebar-footer { display: none; }
  .main { padding: 20px; }
  .item-detail { padding-left: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* =========================================================================
   Dashboard "+ Add" menu (profiles/documents/contracts/subscriptions/
   assets/certifications quick-create shortcut)
   ========================================================================= */

.dash-add-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: var(--panel-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lift);
  min-width: 180px;
  z-index: 50;
  overflow: hidden;
}
.dash-add-menu.show { display: block; }
.dash-add-item {
  padding: 10px 14px;
  font-size: 13.5px;
  color: var(--parchment-dim);
  cursor: pointer;
  white-space: nowrap;
}
.dash-add-item:hover { background: var(--panel-hover); color: var(--brass-bright); }
