/* KashManajers admin pages (switches, staff, audit log). Uses the colours from kash-theme.css. */
* { box-sizing: border-box; }
body.ka { margin: 0; background: var(--bg-main, #F4F7FA); color: var(--text-main, #0B1220);
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; padding-bottom: 48px; }

.ka-nav { position: sticky; top: 0; z-index: 30; background: #0B1220; color: #fff; display: flex; align-items: center;
  gap: 4px; padding: 10px 14px; overflow-x: auto; white-space: nowrap; -webkit-overflow-scrolling: touch; }
.ka-nav .ka-brand { font-weight: 800; letter-spacing: -.02em; margin-right: 10px; background: linear-gradient(135deg,#00C98A,#1D9BF0);
  -webkit-background-clip: text; background-clip: text; color: transparent; font-size: 16px; }
.ka-nav a { color: #C9D3E0; text-decoration: none; font-size: 13px; font-weight: 600; padding: 8px 12px; border-radius: 999px; }
.ka-nav a:hover { background: rgba(255,255,255,.08); color: #fff; }
.ka-nav a.on { background: rgba(0,201,138,.18); color: #3BE3AE; }
.ka-nav .ka-sp { flex: 1; min-width: 8px; }

.ka-wrap { width: 100%; max-width: 980px; margin: 22px auto 0; padding: 0 16px; }
.ka-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.ka-head h1 { margin: 0; font-size: 24px; font-weight: 800; }
.ka-head p { margin: 4px 0 0; color: var(--text-muted, #5A6778); font-size: 14px; max-width: 620px; line-height: 1.5; }

.ka-card { background: var(--surface); border: 1px solid var(--border-color, #E4E9EF); border-radius: 16px; padding: 18px; margin-bottom: 14px;
  box-shadow: 0 1px 2px rgba(11,18,32,.05), 0 2px 8px rgba(11,18,32,.04); }
.ka-card h2 { margin: 0 0 4px; font-size: 16px; font-weight: 800; }
.ka-sub { color: var(--text-muted, #5A6778); font-size: 13px; line-height: 1.5; }

.ka-btn { display: inline-flex; align-items: center; gap: 6px; border: 0; cursor: pointer; font: inherit; font-weight: 700; font-size: 13px;
  padding: 10px 16px; border-radius: 999px; background: linear-gradient(135deg,#00C98A,#1D9BF0); color: #fff; text-decoration: none; }
.ka-btn.ghost { background: #EEF2F6; color: #0B1220; }
.ka-btn.danger { background: #F43F5E; }
.ka-btn.small { padding: 7px 12px; font-size: 12px; }
.ka-btn:disabled { opacity: .5; cursor: not-allowed; }

.ka-flash { background: rgba(0,201,138,.12); border: 1px solid rgba(0,201,138,.35); color: #067a55; border-radius: 12px;
  padding: 10px 14px; font-size: 13px; font-weight: 600; margin-bottom: 14px; }
.ka-warn { background: #FFF4E5; border: 1px solid #FFD8A8; color: #8a4b00; border-radius: 12px; padding: 10px 14px; font-size: 13px; font-weight: 600; margin-bottom: 14px; }

/* switchboard */
.ka-group { margin: 22px 0 8px; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--text-muted, #5A6778); }
.ka-feat { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px 4px; border-bottom: 1px solid var(--border-color, #E4E9EF); }
.ka-feat:last-child { border-bottom: 0; }
.ka-feat b { font-size: 15px; }
.ka-feat .ka-sub { margin-top: 2px; }
.ka-feat small { display: block; margin-top: 4px; color: #8A96A6; font-size: 11px; }
.ka-pill { display: inline-block; font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: 999px; margin-left: 8px; vertical-align: middle; }
.ka-pill.on { background: rgba(0,201,138,.14); color: #067a55; }
.ka-pill.off { background: rgba(244,63,94,.12); color: #c0203d; }
.ka-pill.founder { background: #0B1220; color: #3BE3AE; }
.ka-switch { position: relative; width: 52px; height: 30px; flex: none; }
.ka-switch button { all: unset; box-sizing: border-box; display: block; width: 52px; height: 30px; border-radius: 999px; cursor: pointer;
  background: var(--chip); position: relative; transition: background .18s; }
.ka-switch button::after { content: ''; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: var(--surface);
  box-shadow: 0 1px 3px rgba(0,0,0,.3); transition: transform .18s; }
.ka-switch.on button { background: #00C98A; }
.ka-switch.on button::after { transform: translateX(22px); }
.ka-switch button:focus-visible { outline: 2px solid #1D9BF0; outline-offset: 2px; }

/* tables */
.ka-tablewrap { overflow-x: auto; border-radius: 12px; }
table.ka-table { width: 100%; border-collapse: collapse; min-width: 640px; font-size: 13px; }
.ka-table th { text-align: left; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted, #5A6778); padding: 10px 8px; border-bottom: 2px solid var(--border-color); }
.ka-table td { padding: 11px 8px; border-bottom: 1px solid var(--border-color); vertical-align: top; }
.ka-table tr:hover td { background: var(--hover-bg); }
.ka-tag { display: inline-block; background: #EEF6FD; color: #1471B8; font-weight: 700; font-size: 11px; padding: 3px 8px; border-radius: 6px; }
.ka-mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; color: #5A6778; }

/* filters */
.ka-filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; align-items: end; }
.ka-filters label { display: block; font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--text-muted, #5A6778); margin-bottom: 5px; }
.ka-filters input, .ka-filters select { width: 100%; padding: 10px 12px; border: 1px solid var(--border-color); border-radius: 10px; font: inherit; font-size: 14px; background: var(--surface); color: inherit; }
.ka-pager { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 14px; font-size: 13px; color: var(--text-muted, #5A6778); }

/* staff */
.ka-person { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 0; border-bottom: 1px solid var(--border-color); }
.ka-person:last-child { border-bottom: 0; }
.ka-person .who { display: flex; align-items: center; gap: 12px; min-width: 0; }
.ka-person img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; background: #E4E9EF; }
.ka-person b { display: block; }
dialog.ka-dialog { border: 0; border-radius: 18px; padding: 0; width: min(560px, 94vw); max-height: 90vh; box-shadow: 0 24px 60px rgba(11,18,32,.35); }
dialog.ka-dialog::backdrop { background: rgba(11,18,32,.55); }
.ka-dialog form { display: flex; flex-direction: column; max-height: 90vh; }
.ka-dialog header { padding: 18px 20px 8px; }
.ka-dialog header h3 { margin: 0; font-size: 18px; }
.ka-dialog .ka-body { padding: 6px 20px; overflow-y: auto; }
.ka-dialog footer { padding: 14px 20px 18px; display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; border-top: 1px solid var(--border-color); }
.ka-priv { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border-color); cursor: pointer; }
.ka-priv input { width: 20px; height: 20px; margin-top: 2px; accent-color: #00C98A; flex: none; }
.ka-priv b { display: block; font-size: 14px; }
.ka-empty { text-align: center; padding: 30px 10px; color: var(--text-muted, #5A6778); font-size: 14px; }

@media (max-width: 600px) {
  .ka-head h1 { font-size: 20px; }
  .ka-card { padding: 14px; border-radius: 14px; }
}

/* dark mode touches for the admin pages */
html[data-theme="dark"] .ka-btn.ghost { background: var(--chip); color: var(--text-main); }
html[data-theme="dark"] .ka-flash { color: var(--ink-green); background: var(--tint-green); border-color: var(--tint-green-b); }
html[data-theme="dark"] .ka-warn { background: var(--tint-amber); border-color: var(--tint-amber-b); color: var(--ink-amber); }
html[data-theme="dark"] .ka-pill.on { color: var(--ink-green); }
html[data-theme="dark"] .ka-pill.off { color: var(--ink-red); }
html[data-theme="dark"] .ka-pill.founder { background: #223357; }
html[data-theme="dark"] .ka-nav { background: #070B14; border-bottom: 1px solid var(--border-color); }

/* Hotfix100/101: console icon sweep - shared line-icon class for every <svg class="icon"> that
   references a symbol from the sprite embedded in admin/_nav.html. Inherits currentColor, so
   it automatically matches whatever text/button color it sits inside, in both themes.
   Hotfix101: bumped from a thin 2px line to a rounder, softer 2.5px per the Founder's chosen
   style - round caps/joins were already on, so this mainly thickens and softens the strokes;
   the symbol shapes themselves also got rounder corners (see _nav.html/sprite.svg). */
.icon {
  width: 1em;
  height: 1em;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.15em;
  flex: none;
}
/* A handful of icons (star, crown, status dot, tag) read better filled than outlined. */
.icon.icon-fill { fill: currentColor; stroke: none; }
/* Default inline size next to text; .icon-lg bumps it up for a lone/standalone icon button. */
.icon-lg { width: 1.3em; height: 1.3em; }
