/* _kit.css — estilos aplicados específicos del kit Airexsus.
   Consume tokens de ../../colors_and_type.css; no redefine tokens. */

.ax-shell {
  height: 100vh;
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr;
  background: var(--bg);
  color: var(--fg);
  overflow: hidden;
}
.ax-shell__main {
  display: grid;
  grid-template-columns: 320px 1fr;
  overflow: hidden;
}
.ax-shell__workspace {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ---------- Sidebar ---------- */
.ax-sidebar {
  background: var(--brand-ink);
  color: #C7D6E3;
  display: flex;
  flex-direction: column;
  padding: 20px 16px;
  border-right: 1px solid rgba(255,255,255,0.06);
}
.ax-sidebar__brand { display: flex; align-items: center; gap: 12px; padding: 4px 8px 22px; }
.ax-sidebar__mark { width: 36px; height: 36px; border-radius: 8px; }
.ax-sidebar__wordmark { color: #fff; font-weight: 700; letter-spacing: -0.02em; font-size: 18px; }
.ax-sidebar__sub { font-size: 12px; color: #88A0B5; font-family: var(--font-mono); }
.ax-sidebar__nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }

.ax-nav-item {
  display: flex; align-items: center; gap: 12px;
  width: 100%;
  padding: 10px 12px;
  background: transparent; border: 0;
  color: #C7D6E3; font: 500 14px/1 var(--font-body);
  text-align: left; cursor: pointer;
  border-radius: var(--radius-s);
  transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
  position: relative;
}
.ax-nav-item svg { width: 18px; height: 18px; flex-shrink: 0; }
.ax-nav-item__label { flex: 1; }
.ax-nav-item__badge {
  font: 600 11px/1 var(--font-mono);
  padding: 3px 7px; border-radius: 999px;
  background: var(--brand-primary); color: #fff;
}
.ax-nav-item:hover { background: rgba(255,255,255,0.06); color: #fff; }
.ax-nav-item.is-active { background: rgba(0,164,214,0.14); color: #fff; }
.ax-nav-item.is-active::before {
  content: ''; position: absolute; left: 0; top: 8px; bottom: 8px; width: 3px;
  background: var(--brand-primary); border-radius: 0 3px 3px 0;
}

.ax-sidebar__footer { border-top: 1px solid rgba(255,255,255,0.06); padding-top: 14px; margin-top: 14px; }
.ax-account { display: flex; align-items: center; gap: 12px; padding: 4px 8px; }
.ax-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--brand-primary); color: #fff;
  display: grid; place-items: center;
  font-weight: 600; font-size: 13px;
}
.ax-account__name { color: #fff; font-size: 13px; font-weight: 600; }
.ax-account__role { color: #88A0B5; font-size: 11px; font-family: var(--font-mono); }

/* ---------- EquipmentList rail ---------- */
.ax-list {
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column; overflow: hidden;
}
.ax-list__header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; border-bottom: 1px solid var(--border);
  height: var(--topbar-h);
}
.ax-list__items { list-style: none; margin: 0; padding: 8px; overflow-y: auto; flex: 1; }
.ax-list-item {
  width: 100%; text-align: left;
  background: transparent; border: 0; cursor: pointer;
  padding: 12px 14px; border-radius: var(--radius-m);
  display: flex; flex-direction: column; gap: 6px;
  transition: background var(--dur-fast) var(--ease-out);
}
.ax-list-item:hover { background: color-mix(in oklch, var(--brand-frost) 60%, transparent); }
.ax-list-item.is-selected { background: var(--brand-frost); }
.ax-list-item.is-selected .ax-list-item__name { color: var(--brand-deep); }
.ax-list-item__row { display: flex; align-items: center; gap: 8px; }
.ax-list-item__name { font-weight: 600; font-size: 14px; color: var(--fg); flex: 1; }
.ax-list-item__sku { color: var(--fg-subtle); font-size: 11px; }
.ax-list-item__meta { display: flex; justify-content: space-between; font-size: 12px; color: var(--fg-muted); padding-left: 16px; }

.ax-status-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

/* ---------- Workspace ---------- */
.ax-workspace {
  flex: 1; overflow-y: auto;
  padding: 28px 32px 16px;
  display: flex; flex-direction: column; gap: 20px;
}
.ax-workspace__top {
  display: flex; justify-content: space-between; align-items: flex-end;
  margin-bottom: 4px;
}
.ax-workspace__actions { display: flex; gap: 10px; }

.ax-kpis {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px;
}
.ax-kpi {
  background: var(--surface); border-radius: var(--radius-l);
  padding: 18px 20px;
  box-shadow: var(--shadow-1);
  display: flex; flex-direction: column; gap: 6px;
}
.ax-kpi__value { font-size: 28px; color: var(--brand-deep); font-weight: 600; letter-spacing: -0.01em; }
.ax-kpi__delta { font-size: 12px; font-family: var(--font-mono); }

/* ---------- Cards ---------- */
.ax-card {
  background: var(--surface);
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-1);
  padding: var(--space-6);
}
.ax-card__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 16px; }
.ax-card__title { margin-top: 6px; }
.ax-card__sub { color: var(--fg-muted); font-size: 13px; display: flex; gap: 8px; margin-top: 4px; }

.ax-chart { width: 100%; height: auto; display: block; }
.ax-legend { display: flex; gap: 14px; font-size: 12px; color: var(--fg-muted); }
.ax-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: middle; }

.ax-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 600; white-space: nowrap;
}

/* ---------- Equipment detail ---------- */
.ax-equipment .ax-metrics {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px;
  background: var(--surface-sunken); border-radius: var(--radius-m);
  padding: 16px; margin: 0;
}
.ax-metrics div { display: flex; flex-direction: column; gap: 2px; }
.ax-metrics dt { font-size: 11px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--fg-muted); font-family: var(--font-mono); margin: 0; }
.ax-metrics dd { margin: 0; font-size: 18px; color: var(--brand-deep); font-weight: 600; }
.ax-card__history { margin-top: 18px; }
.ax-card__history ul { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.ax-card__history li { display: flex; gap: 14px; font-size: 13px; color: var(--fg); padding: 8px 0; border-top: 1px solid var(--border); }
.ax-card__history li:first-child { border-top: 0; }
.ax-event__time { color: var(--fg-subtle); min-width: 64px; }

/* ---------- Action bar ---------- */
.ax-action-bar {
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding: 14px 32px 18px;
  display: flex; flex-direction: column; gap: 10px;
}
.ax-action-bar__type { display: flex; gap: 6px; }
.ax-action-bar__type button {
  background: transparent; border: 1px solid transparent;
  color: var(--fg-muted); font: 500 13px/1 var(--font-body);
  padding: 6px 12px; border-radius: 999px; cursor: pointer;
}
.ax-action-bar__type button.is-active {
  background: var(--brand-frost); color: var(--brand-deep);
  border-color: color-mix(in oklch, var(--brand-primary) 24%, transparent);
}
.ax-action-bar__row { display: flex; gap: 8px; align-items: center; }
.ax-action-bar__input {
  flex: 1;
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 10px 14px;
  border-radius: var(--radius-m);
  font: 14px var(--font-body);
  color: var(--fg);
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast);
}
.ax-action-bar__input:focus { outline: none; border-color: var(--brand-primary); box-shadow: var(--shadow-focus); }
.ax-action-bar__hint { font-size: 12px; color: var(--fg-subtle); }

/* ---------- Buttons (kit-scoped) ---------- */
.ax-btn {
  display: inline-flex; align-items: center; gap: 8px;
  font: 600 14px/1 var(--font-body);
  padding: 10px 16px; border-radius: var(--radius-m);
  border: 1px solid transparent; cursor: pointer;
  transition: background var(--dur-fast), border-color var(--dur-fast), color var(--dur-fast);
}
.ax-btn svg { width: 16px; height: 16px; }
.ax-btn--primary { background: var(--brand-primary); color: #fff; }
.ax-btn--primary:hover { background: var(--brand-primary-hover); }
.ax-btn--primary:disabled { opacity: 0.4; cursor: not-allowed; }
.ax-btn--ghost { background: transparent; color: var(--brand-deep); }
.ax-btn--ghost:hover { background: var(--brand-frost); }

.ax-icon-btn {
  width: 36px; height: 36px; border-radius: var(--radius-s);
  background: transparent; border: 0; cursor: pointer;
  color: var(--fg-muted);
  display: grid; place-items: center;
  transition: background var(--dur-fast), color var(--dur-fast);
}
.ax-icon-btn:hover { background: var(--brand-frost); color: var(--brand-deep); }
.ax-icon-btn svg { width: 18px; height: 18px; }
