/* AILO Dashboard D02 — CloudOne Console
   원형: 터미널형 다크 콘솔 + 접히는 좌측 사이드바 / 타이포: JetBrains Mono(+Pretendard 한글) / 컬러: 블랙 + 터미널 그린 */

:root {
  --ailo-bg: #050806;
  --ailo-fg: #d3ecd8;
  --ailo-muted: #86a38c;
  --ailo-line: rgba(61, 220, 120, .14);
  --ailo-accent: #3ddc78;
  --ailo-accent-ink: #03140a;
  --ailo-header-h: 64px;

  --d02-mono: "JetBrains Mono", "Pretendard Variable", Pretendard, ui-monospace, SFMono-Regular, Menlo, monospace;
  --d02-panel: #0b100c;
  --d02-panel-2: #0f1611;
  --d02-hover: #142019;
  --d02-grid: #17221a;
  --d02-axis: #2a3a2f;
  --d02-spark: #557a5f;
  /* 차트 범주색 — 검증: dark / surface #0b100c / adjacent 통과 */
  --d02-s1: #2bb062;
  --d02-s2: #3a9fd8;
  --d02-s3: #c98500;
  /* 상태색(고정) */
  --d02-good: #0ca30c;
  --d02-warn: #fab219;
  --d02-serious: #ec835a;
  --d02-crit: #d03b3b;
  --d02-info: #3a9fd8;
  --d02-up: #3ddc78;
  --d02-bad: #ff8080;
  --d02-sb-w: 252px;
  --d02-gap: 12px;
}

body {
  font-family: var(--d02-mono);
  font-size: 13px;
  line-height: 1.55;
  letter-spacing: -.01em;
  background:
    radial-gradient(1200px 500px at 70% -10%, rgba(61, 220, 120, .07), transparent 70%),
    var(--ailo-bg);
  color: var(--ailo-fg);
}
::selection { background: var(--ailo-accent); color: var(--ailo-accent-ink); }
.dim { color: var(--ailo-muted); }
code { font-family: inherit; color: var(--ailo-accent); font-size: inherit; background: rgba(61, 220, 120, .08); padding: 0 4px; border-radius: 2px; }
kbd {
  font-family: inherit; font-size: 10px; font-weight: 500; color: var(--ailo-muted);
  background: transparent; border: 1px solid var(--ailo-line); border-radius: 3px; padding: 0 5px; box-shadow: none;
}

/* ===== Shell ===== */
.shell { display: grid; grid-template-columns: var(--d02-sb-w) minmax(0, 1fr); min-height: 100vh; transition: grid-template-columns .3s var(--ailo-ease); }
html.sb-collapsed { --d02-sb-w: 68px; }
.col { min-width: 0; display: flex; flex-direction: column; }

/* ===== Sidebar ===== */
.sb {
  position: sticky; top: 0; height: 100vh; overflow-y: auto; overflow-x: hidden;
  background: #070b08; border-right: 1px solid var(--ailo-line);
  display: flex; flex-direction: column; gap: 18px; padding: 16px 12px;
  scrollbar-width: thin; scrollbar-color: var(--d02-axis) transparent;
}
.sb__head { display: flex; align-items: center; justify-content: space-between; min-height: 32px; }
.sb__brand { display: inline-flex; align-items: baseline; gap: 8px; font-weight: 800; font-size: 17px; padding: 0 6px; white-space: nowrap; }
.sb__prompt { color: var(--ailo-accent); }
.sb__cursor { display: inline-block; width: 8px; height: 15px; background: var(--ailo-accent); margin-left: 3px; vertical-align: -2px; animation: d02-blink 1.1s steps(1) infinite; }
@keyframes d02-blink { 50% { opacity: 0; } }
.sb__close { display: none; width: 36px; height: 36px; border: 1px solid var(--ailo-line); background: transparent; border-radius: 4px; }

.sb__org { border: 1px dashed var(--ailo-line); border-radius: 4px; padding: 10px 12px; display: grid; gap: 2px; white-space: nowrap; }
.sb__label, .sb__group { font-size: 10px; text-transform: uppercase; letter-spacing: .12em; color: var(--ailo-muted); }
.sb__group { padding: 0 10px; margin: 6px 0 6px; }
.sb__env { font-size: 11px; color: var(--ailo-accent); }
.sb__env i { font-size: 7px; vertical-align: 2px; }

.sb__nav ul { display: grid; gap: 2px; margin-bottom: 8px; }
.sb__nav a {
  position: relative; display: grid; grid-template-columns: 20px 1fr auto; align-items: center; gap: 10px;
  padding: 8px 10px; border-radius: 4px; color: #b5d1bb; white-space: nowrap;
  transition: background .15s, color .15s;
}
.sb__nav a i { text-align: center; color: var(--ailo-muted); }
.sb__nav a:hover { background: var(--d02-hover); color: var(--ailo-fg); }
.sb__nav a.is-active { background: rgba(61, 220, 120, .1); color: var(--ailo-accent); }
.sb__nav a.is-active i { color: var(--ailo-accent); }
.sb__nav a.is-active::before { content: ">"; position: absolute; left: -4px; color: var(--ailo-accent); font-weight: 800; }
.sb__nav kbd { opacity: .7; }
.sb__count { position: absolute; right: 52px; font-style: normal; font-size: 10px; background: var(--ailo-accent); color: var(--ailo-accent-ink); border-radius: 8px; padding: 0 6px; font-weight: 700; }

.sb__quota { display: grid; gap: 10px; margin-top: auto; }
.quota { display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; padding: 0 10px; font-size: 11px; white-space: nowrap; }
.quota span { color: var(--ailo-muted); }
.quota b { font-weight: 500; }
.quota i { grid-column: 1 / -1; height: 4px; border-radius: 2px; background: #15301f; position: relative; overflow: hidden; }
.quota i::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--q); background: var(--d02-s1); border-radius: 2px; }
.quota--warn i { background: #3a2c0c; }
.quota--warn i::after { background: var(--d02-warn); }

.sb__collapse {
  display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 4px;
  border: 1px solid var(--ailo-line); background: transparent; color: var(--ailo-muted); white-space: nowrap; font-size: 12px;
}
.sb__collapse:hover { color: var(--ailo-fg); background: var(--d02-hover); }
.sb__collapse i { width: 20px; transition: rotate .3s; }

/* 접힘 상태 (데스크톱) */
@media (min-width: 992px) {
  html.sb-collapsed .sb { padding-inline: 10px; }
  html.sb-collapsed .sb__name,
  html.sb-collapsed .sb__org,
  html.sb-collapsed .sb__group,
  html.sb-collapsed .sb__quota,
  html.sb-collapsed .sb__nav span,
  html.sb-collapsed .sb__nav kbd,
  html.sb-collapsed .sb__collapse span { display: none; }
  html.sb-collapsed .sb__nav a { grid-template-columns: 1fr; justify-items: center; padding: 10px 0; }
  html.sb-collapsed .sb__nav a.is-active::before { left: 0; }
  html.sb-collapsed .sb__count { right: 4px; top: 2px; }
  html.sb-collapsed .sb__collapse { justify-content: center; margin-top: auto; }
  html.sb-collapsed .sb__collapse i { rotate: 180deg; }
  html.sb-collapsed .sb__brand { padding: 0; margin: 0 auto; }
}

.sb-ov { display: none; }

/* ===== Topbar ===== */
.tb {
  position: sticky; top: 0; z-index: 40; min-height: var(--ailo-header-h);
  display: flex; align-items: center; gap: 16px; padding: 10px clamp(16px, 2vw, 28px);
  background: rgba(5, 8, 6, .88); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--ailo-line);
}
.tb__menu { display: none; width: 40px; height: 40px; border: 1px solid var(--ailo-line); border-radius: 4px; background: transparent; flex: none; }
.tb__title { min-width: 0; flex: 0 1 auto; }
.crumb { display: flex; flex-wrap: wrap; gap: 6px; font-size: 11px; color: var(--ailo-muted); }
.crumb li + li::before { content: "/"; margin-right: 6px; opacity: .6; }
.crumb a:hover { color: var(--ailo-accent); }
.tb h1 { font-size: clamp(17px, 1.6vw, 21px); font-weight: 800; letter-spacing: -.03em; font-family: "Pretendard Variable", Pretendard, sans-serif; }

.tb__search {
  margin-left: auto; position: relative; display: flex; align-items: center; gap: 8px; width: min(360px, 32vw);
  border: 1px solid var(--ailo-line); border-radius: 4px; padding: 0 10px; background: var(--d02-panel); height: 38px;
}
.tb__search:focus-within { border-color: var(--ailo-accent); }
.tb__search i { color: var(--ailo-muted); }
.tb__search input { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--ailo-fg); font: inherit; outline: none; }
.tb__search input::placeholder { color: #6d8a73; }

.tb__tools { display: flex; align-items: center; gap: 10px; }
.tb__icon { position: relative; width: 40px; height: 40px; border: 1px solid var(--ailo-line); border-radius: 4px; background: transparent; }
.tb__icon:hover, .tb__menu:hover { border-color: var(--ailo-accent); color: var(--ailo-accent); }
.noti { position: relative; }
.noti__badge {
  position: absolute; top: -6px; right: -6px; min-width: 18px; height: 18px; border-radius: 9px; padding: 0 5px;
  background: var(--d02-crit); color: #fff; font-size: 10px; font-weight: 700; line-height: 18px; border: 2px solid var(--ailo-bg);
}
.noti__panel {
  position: absolute; right: 0; top: calc(100% + 8px); width: min(340px, calc(100vw - 32px)); z-index: 60;
  background: var(--d02-panel-2); border: 1px solid var(--d02-axis); border-radius: 4px; box-shadow: 0 18px 40px rgba(0, 0, 0, .6);
}
.noti__head { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--ailo-line); }
.noti__panel ul { max-height: 320px; overflow: auto; }
.noti__panel li { display: grid; grid-template-columns: 20px 1fr; gap: 10px; padding: 11px 14px; border-bottom: 1px solid var(--ailo-line); font-size: 12px; position: relative; }
.noti__panel li.is-new::after { content: ""; position: absolute; right: 14px; top: 16px; width: 6px; height: 6px; border-radius: 50%; background: var(--ailo-accent); }
.noti__panel li p { padding-right: 14px; }
.noti__panel time { color: var(--ailo-muted); font-size: 11px; }
.noti__all { display: block; padding: 11px 14px; color: var(--ailo-accent); font-size: 12px; }
.st-crit { color: var(--d02-crit); }
.st-warn { color: var(--d02-warn); }
.st-serious { color: var(--d02-serious); }

.tb__me { display: flex; align-items: center; gap: 10px; background: transparent; border: 0; padding: 0; text-align: left; }
.avatar {
  width: 36px; height: 36px; border-radius: 4px; display: grid; place-items: center; flex: none;
  background: #133a22; color: var(--ailo-accent); font-weight: 700; font-size: 11px; font-family: "Pretendard Variable", Pretendard, sans-serif;
  border: 1px solid rgba(61, 220, 120, .35);
}
.tb__who { display: grid; line-height: 1.25; white-space: nowrap; }
.tb__who b { font-weight: 700; font-size: 12px; }
.tb__who small { color: var(--ailo-muted); font-size: 11px; }
.link-btn { background: none; border: 0; padding: 0; color: var(--ailo-accent); font-size: 12px; white-space: nowrap; }
.link-btn:hover { text-decoration: underline; }

/* ===== Main ===== */
.main { flex: 1; padding: clamp(14px, 2vw, 24px) clamp(16px, 2vw, 28px); display: grid; gap: var(--d02-gap); align-content: start; }

.statusline { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.statusline__msg { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: 12px; }
.statusline__msg b { color: var(--ailo-accent); font-weight: 500; }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--d02-good); box-shadow: 0 0 0 0 rgba(12, 163, 12, .6); animation: d02-pulse 2s infinite; }
@keyframes d02-pulse { 70% { box-shadow: 0 0 0 8px rgba(12, 163, 12, 0); } 100% { box-shadow: 0 0 0 0 rgba(12, 163, 12, 0); } }

.seg { display: inline-flex; border: 1px solid var(--ailo-line); border-radius: 4px; overflow: hidden; }
.seg button { border: 0; background: transparent; padding: 7px 14px; font-size: 12px; color: var(--ailo-muted); border-right: 1px solid var(--ailo-line); }
.seg button:last-child { border-right: 0; }
.seg button:hover { color: var(--ailo-fg); background: var(--d02-hover); }
.seg button[aria-pressed="true"] { background: var(--ailo-accent); color: var(--ailo-accent-ink); font-weight: 700; }
.seg button[aria-pressed="true"]::before { content: "["; }
.seg button[aria-pressed="true"]::after { content: "]"; }

/* ===== KPI ===== */
.kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--d02-gap); }
.kpi {
  position: relative; background: var(--d02-panel); border: 1px solid var(--ailo-line); border-radius: 3px;
  padding: 14px 14px 12px; display: grid; gap: 4px; overflow: hidden;
}
.kpi::before { content: ""; position: absolute; left: 0; top: 0; width: 24px; height: 2px; background: var(--ailo-accent); }
.kpi__label { font-size: 11px; font-weight: 500; color: var(--ailo-accent); display: grid; gap: 1px; }
.kpi__label span { color: var(--ailo-muted); font-weight: 400; font-size: 11px; }
.kpi__val { font-size: clamp(20px, 1.7vw, 25px); font-weight: 700; letter-spacing: -.04em; line-height: 1.15; white-space: nowrap; margin-top: 4px; font-family: "Pretendard Variable", Pretendard, sans-serif; }
.kpi__val small { font-size: .55em; font-weight: 500; color: var(--ailo-muted); margin-left: 2px; letter-spacing: 0; }
.kpi__delta { font-size: 11px; white-space: nowrap; }
.kpi__delta.is-good { color: var(--d02-up); }
.kpi__delta.is-bad { color: var(--d02-bad); }
.kpi__delta.is-flat { color: var(--ailo-muted); }
.kpi__delta .dim { margin-left: 2px; }
.spark { position: relative; display: block; height: 28px; margin-top: 6px; }
.spark svg { width: 100%; height: 100%; overflow: visible; }
.spark__dot { position: absolute; width: 7px; height: 7px; margin: -3.5px 0 0 -3.5px; border-radius: 50%; background: var(--ailo-accent); box-shadow: 0 0 0 2px var(--d02-panel); }

/* ===== Panels ===== */
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--d02-gap); }
.g-4 { grid-column: span 4; } .g-5 { grid-column: span 5; } .g-7 { grid-column: span 7; } .g-8 { grid-column: span 8; }
.panel {
  background: var(--d02-panel); border: 1px solid var(--ailo-line); border-radius: 3px;
  padding: 14px 16px 16px; min-width: 0; display: flex; flex-direction: column; gap: 12px;
}
.panel__hd { display: flex; align-items: center; justify-content: space-between; gap: 8px 12px; flex-wrap: wrap; }
.panel__hd h2 { font-size: 13px; font-weight: 700; display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; }
.panel__hd h2 small { font-weight: 400; color: var(--ailo-muted); font-size: 11px; }
.hash { color: var(--ailo-accent); }
.panel__note { font-size: 11px; }
.tag { font-size: 11px; border: 1px solid var(--ailo-line); border-radius: 3px; padding: 1px 8px; color: var(--ailo-muted); }
.tag::before { content: "range="; opacity: .7; }

.legend { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 11px; color: var(--ailo-fg); }
.legend li { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 14px; height: 2px; background: var(--c); border-radius: 1px; }

.chart { position: relative; width: 100%; }
.chart--lg { height: 270px; }
.chart--md { height: 240px; }

/* ===== Pipelines ===== */
.pipes { display: grid; gap: 10px; }
.pipe {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 16px; align-items: center;
  border: 1px solid var(--ailo-line); border-radius: 3px; padding: 12px; background: var(--d02-panel-2);
}
.pipe__meta { min-width: 0; display: grid; gap: 2px; }
.pipe__svc b { font-size: 13px; }
.pipe__commit { font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pipe__commit i { color: var(--ailo-muted); }
.pipe__by { font-size: 11px; }
.pipe__act { display: flex; align-items: center; gap: 10px; grid-column: 2; grid-row: 1; }
.stages { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; counter-reset: stg; }
.stages li {
  position: relative; display: grid; grid-template-columns: 16px 1fr; grid-template-rows: auto auto; column-gap: 6px;
  padding: 7px 8px; background: #0a0f0b; border-top: 2px solid var(--d02-axis); font-size: 11px; min-width: 0;
}
.stages li i { grid-row: 1 / 3; align-self: center; font-size: 11px; text-align: center; }
.stages li span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stages li small { color: var(--ailo-muted); font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stages .is-ok { border-top-color: var(--d02-good); }
.stages .is-ok i { color: var(--d02-good); }
.stages .is-run { border-top-color: var(--d02-info); background: linear-gradient(90deg, rgba(58, 159, 216, .18), transparent); }
.stages .is-run i { color: var(--d02-info); animation: fa-spin 1.4s linear infinite; }
.stages .is-run small { color: var(--d02-info); }
.stages .is-fail { border-top-color: var(--d02-crit); background: rgba(208, 59, 59, .12); }
.stages .is-fail i, .stages .is-fail small { color: #ff8a8a; }
.stages .is-wait, .stages .is-skip { opacity: .55; }
.stages .is-skip span { text-decoration: line-through; }

.st { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; white-space: nowrap; padding: 2px 8px; border-radius: 3px; border: 1px solid; }
.st--ok { color: #7fe39b; border-color: rgba(12, 163, 12, .5); background: rgba(12, 163, 12, .1); }
.st--run, .st--info { color: #8ccbf0; border-color: rgba(58, 159, 216, .5); background: rgba(58, 159, 216, .1); }
.st--warn { color: #ffd166; border-color: rgba(250, 178, 25, .5); background: rgba(250, 178, 25, .08); }
.st--serious { color: #f4a37f; border-color: rgba(236, 131, 90, .5); background: rgba(236, 131, 90, .08); }
.st--crit { color: #ff9a9a; border-color: rgba(208, 59, 59, .6); background: rgba(208, 59, 59, .12); }
.st--run i { animation: fa-spin 1.4s linear infinite; }

.btn-t {
  border: 1px solid var(--d02-axis); background: transparent; color: var(--ailo-fg); border-radius: 3px;
  padding: 5px 10px; font-size: 11px; white-space: nowrap;
}
.btn-t:hover { border-color: var(--ailo-accent); color: var(--ailo-accent); }
.btn-t[aria-pressed="true"] { color: var(--d02-warn); border-color: rgba(250, 178, 25, .5); }

/* ===== Fleet ===== */
.chips { display: flex; flex-wrap: wrap; gap: 4px; }
.chips button { border: 1px solid var(--ailo-line); background: transparent; color: var(--ailo-muted); font-size: 11px; padding: 3px 9px; border-radius: 3px; }
.chips button:hover { color: var(--ailo-fg); }
.chips button[aria-pressed="true"] { color: var(--ailo-accent); border-color: var(--ailo-accent); }

.fleet { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 5px; }
.fleet__stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--ailo-line); border: 1px solid var(--ailo-line); border-radius: 3px; margin: 0; overflow: hidden; }
.fleet__stats div { background: var(--d02-panel-2); padding: 8px 10px; min-width: 0; }
.fleet__stats dt { font-size: 10px; font-weight: 400; color: var(--ailo-muted); white-space: nowrap; }
.fleet__stats dd { margin: 0; font-size: 13px; font-weight: 700; white-space: nowrap; }
.cell {
  position: relative; aspect-ratio: 1; border-radius: 2px; border: 1px solid; padding: 0; overflow: hidden;
  display: grid; place-items: center; font-size: 11px; font-weight: 800; transition: opacity .2s, transform .15s;
}
.cell:hover, .cell:focus-visible { transform: scale(1.12); z-index: 2; }
.cell.is-ok { background: rgba(12, 163, 12, .2); border-color: rgba(12, 163, 12, .45); }
.cell.is-warn { background: rgba(250, 178, 25, .35); border-color: var(--d02-warn); color: #fff3cf; }
.cell.is-crit { background: var(--d02-crit); border-color: #ff8a8a; color: #fff; }
.cell.is-off { background: repeating-linear-gradient(135deg, #1c241e 0 4px, #111712 4px 8px); border-color: var(--d02-axis); color: var(--ailo-muted); font-size: 10px; }
.cell.is-dim { opacity: .14; }
.cell__cpu { position: absolute; left: 0; bottom: 0; height: 2px; width: var(--cpu); background: rgba(211, 236, 216, .55); }
.fleet__foot { display: grid; gap: 8px; }
.fleet__legend { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 11px; }
.fleet__legend li { display: inline-flex; align-items: center; gap: 6px; }
.fleet__legend b { color: var(--ailo-fg); }
.cell-key { width: 10px; height: 10px; border-radius: 2px; border: 1px solid; }
.cell-key.is-ok { background: rgba(12, 163, 12, .35); border-color: var(--d02-good); }
.cell-key.is-warn { background: rgba(250, 178, 25, .5); border-color: var(--d02-warn); }
.cell-key.is-crit { background: var(--d02-crit); border-color: #ff8a8a; }
.cell-key.is-off { background: #1c241e; border-color: var(--d02-axis); }
.fleet__tip { font-size: 11px; color: var(--ailo-muted); border-top: 1px dashed var(--ailo-line); padding-top: 8px; min-height: 2.6em; }

/* ===== Table ===== */
.panel__hd--wrap { row-gap: 10px; }
.tsearch { display: flex; align-items: center; gap: 8px; border: 1px solid var(--ailo-line); border-radius: 3px; padding: 0 10px; height: 32px; background: var(--d02-panel-2); }
.tsearch:focus-within { border-color: var(--ailo-accent); }
.tsearch span { color: var(--ailo-accent); font-size: 11px; }
.tsearch input { border: 0; background: transparent; color: var(--ailo-fg); font: inherit; font-size: 12px; outline: none; width: 160px; }
.twrap { overflow-x: auto; margin: 0 -4px; padding: 0 4px; scrollbar-width: thin; scrollbar-color: var(--d02-axis) transparent; }
.tbl { width: 100%; min-width: 720px; border-collapse: collapse; font-size: 12px; font-variant-numeric: tabular-nums; }
.tbl th { text-align: left; font-weight: 500; color: var(--ailo-muted); border-bottom: 1px solid var(--d02-axis); padding: 0; white-space: nowrap; }
.tbl th button { width: 100%; text-align: inherit; background: none; border: 0; padding: 8px 8px; color: inherit; font-size: 11px; text-transform: none; }
.tbl th button:hover { color: var(--ailo-fg); }
.tbl th button i { opacity: .5; font-size: 10px; margin-left: 2px; }
.tbl th[aria-sort="ascending"] button, .tbl th[aria-sort="descending"] button { color: var(--ailo-accent); }
.tbl th[aria-sort="ascending"] i, .tbl th[aria-sort="descending"] i { opacity: 1; }
.tbl td { padding: 9px 8px; border-bottom: 1px solid var(--ailo-line); white-space: nowrap; }
.tbl tbody tr:hover { background: var(--d02-hover); }
.tbl .num { text-align: right; }
.tbl th.num button { text-align: right; }
.plan { font-size: 11px; padding: 1px 7px; border-radius: 3px; border: 1px solid var(--ailo-line); }
.plan--ent { color: var(--ailo-accent); border-color: rgba(61, 220, 120, .4); }
.plan--pro { color: #9fd2f0; border-color: rgba(58, 159, 216, .4); }
.plan--start { color: var(--ailo-muted); }
.bar { display: inline-block; width: 38px; height: 4px; border-radius: 2px; background: #15301f; margin-right: 8px; vertical-align: 2px; position: relative; overflow: hidden; }
.bar::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--v); background: var(--d02-s1); }
.bar.is-hot::after { background: var(--d02-warn); }
.tfoot { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; font-size: 11px; }
.pager { display: flex; gap: 4px; }
.pager button { min-width: 30px; height: 30px; border: 1px solid var(--ailo-line); background: transparent; border-radius: 3px; font-size: 11px; color: var(--ailo-muted); }
.pager button:hover:not(:disabled) { color: var(--ailo-fg); border-color: var(--d02-axis); }
.pager button[aria-current="page"] { background: var(--ailo-accent); color: var(--ailo-accent-ink); border-color: var(--ailo-accent); font-weight: 700; }
.pager button:disabled { opacity: .35; cursor: default; }

/* ===== Log ===== */
.panel--log { background: #030504; }
.log { display: grid; align-content: start; gap: 0; max-height: 420px; overflow-y: auto; font-size: 11.5px; scrollbar-width: thin; scrollbar-color: var(--d02-axis) transparent; }
.log li { display: grid; grid-template-columns: auto auto 1fr; gap: 8px; padding: 5px 0; border-bottom: 1px dashed rgba(61, 220, 120, .07); align-items: baseline; }
.log li.is-fresh { animation: d02-in .6s var(--ailo-ease); }
@keyframes d02-in { from { background: rgba(61, 220, 120, .14); } to { background: transparent; } }
.log time { color: #6b8a72; }
.lv { font-size: 10px; font-weight: 700; padding: 0 5px; border-radius: 2px; min-width: 50px; text-align: center; }
.lv--info { color: #9fd2f0; background: rgba(58, 159, 216, .12); }
.lv--warn { color: #ffd166; background: rgba(250, 178, 25, .12); }
.lv--err { color: #ff9a9a; background: rgba(208, 59, 59, .18); }
.lv--dep { color: var(--ailo-accent); background: rgba(61, 220, 120, .12); }

/* ===== Footer ===== */
.ft {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px;
  padding: 16px clamp(16px, 2vw, 28px) 22px; border-top: 1px solid var(--ailo-line); font-size: 11px; color: var(--ailo-muted);
}
.ft a:hover { color: var(--ailo-accent); }
.ft b { color: var(--ailo-fg); }

/* SweetAlert 다크 */
.swal2-popup { font-family: var(--d02-mono); border: 1px solid var(--d02-axis); border-radius: 4px !important; }

/* ===== Responsive ===== */
@media (max-width: 1399.98px) {
  .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 1199.98px) {
  .g-4, .g-5, .g-7, .g-8 { grid-column: span 12; }
  .panel--log .log { max-height: 300px; }
  .tb__who { display: none; }
}
@media (max-width: 991.98px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .sb {
    position: fixed; z-index: 90; left: 0; top: 0; bottom: 0; width: min(290px, 86vw); height: auto;
    translate: -100% 0; transition: translate .3s var(--ailo-ease), visibility .3s; visibility: hidden;
    box-shadow: 20px 0 50px rgba(0, 0, 0, .6);
  }
  html.dash-open .sb { translate: 0 0; visibility: visible; transition: translate .3s var(--ailo-ease), visibility 0s; }
  .sb__close { display: grid; place-items: center; }
  .sb__collapse { display: none; }
  .sb-ov { display: block; position: fixed; inset: 0; z-index: 80; background: rgba(0, 0, 0, .6); opacity: 0; visibility: hidden; transition: opacity .3s, visibility .3s; }
  html.dash-open .sb-ov { opacity: 1; visibility: visible; }
  html.dash-open body { overflow: hidden; }
  .tb__menu { display: grid; place-items: center; }
  .tb__search { width: auto; flex: 1; max-width: 360px; }
}
@media (max-width: 767.98px) {
  .tb { flex-wrap: wrap; gap: 10px; }
  .tb__title { flex: 1 1 0; }
  .crumb { flex-wrap: nowrap; white-space: nowrap; overflow: hidden; }
  .crumb li:first-child { display: none; }
  .crumb li:nth-child(2)::before { display: none; }
  .tb__search { order: 5; flex-basis: 100%; max-width: none; margin-left: 0; }
  .tb__tools { margin-left: auto; }
  .pipe { grid-template-columns: 1fr; }
  .pipe__act { grid-column: 1; grid-row: auto; }
  .stages { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .fleet { grid-template-columns: repeat(8, minmax(0, 1fr)); }
}
@media (max-width: 575.98px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .kpi { padding: 12px 10px 10px; }
  .kpi__delta .dim { display: block; margin: 0; }
  .kpi__delta { white-space: normal; }
  .statusline { flex-direction: column; align-items: stretch; }
  .seg { display: grid; grid-template-columns: repeat(4, 1fr); }
  .seg button { padding: 8px 4px; }
  .chart--lg { height: 230px; }
  .tsearch { width: 100%; }
  .fleet__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tsearch input { width: 100%; flex: 1; }
  .ft { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  .sb__cursor, .pulse { animation: none; }
}
