/*
 * AI MAYAK — Design System CSS
 *
 * SOURCE OF TRUTH for all UI surfaces in AI MAYAK family:
 *   - pages-dashboard/index.html (Кабина пилота)
 *   - pages-pixel/index.html (Pixel Office — with retro overlay)
 *   - projects/<name>/landing/index.html (any project landing)
 *
 * Spec: governance/DESIGN-SYSTEM.md
 *
 * Changes to this file = visual change across entire family. Always preview-screenshot
 * before commit. Add new tokens via ADR (cross-surface impact).
 *
 * Version: 1.0.0
 * Updated: 2026-05-14
 */

/* ─────────────────────────────────────────────────────────────
 * 1. FONTS (loaded from Google Fonts)
 * ───────────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:ital,wght@0,400;0,500;0,600;0,700;1,400&family=Inter:wght@300;400;500;600;700&display=swap');

/* ─────────────────────────────────────────────────────────────
 * 2. DESIGN TOKENS (CSS variables)
 * ───────────────────────────────────────────────────────────── */
:root {
  /* Backgrounds (dark hierarchy) */
  --bg-base: #080c14;
  --bg-surface: #0d1220;
  --bg-elevated: #131928;
  --bg-hover: #1a2235;

  /* Borders */
  --border: rgba(255, 255, 255, 0.06);
  --border-active: rgba(0, 212, 255, 0.35);

  /* Text */
  --text-primary: #e8ecf4;
  --text-secondary: #7a8499;
  --text-muted: #4a5568;

  /* Accent palette (5 colors only — see DESIGN-SYSTEM.md) */
  --cyan: #00d4ff;
  --cyan-dim: rgba(0, 212, 255, 0.10);
  --cyan-glow: rgba(0, 212, 255, 0.18);
  --green: #10f090;
  --green-dim: rgba(16, 240, 144, 0.10);
  --amber: #f5a623;
  --amber-dim: rgba(245, 166, 35, 0.10);
  --red: #ff4560;
  --red-dim: rgba(255, 69, 96, 0.10);
  --purple: #a78bfa;
  --purple-dim: rgba(167, 139, 250, 0.10);

  /* Typography */
  --mono: 'JetBrains Mono', monospace;
  --sans: 'Inter', system-ui, sans-serif;

  /* Border radius */
  --radius: 10px;
  --radius-sm: 6px;
  --radius-lg: 14px;

  /* Shadows */
  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.4), 0 8px 24px rgba(0, 0, 0, 0.2);
  --shadow-hover: 0 4px 20px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(0, 212, 255, 0.15);

  /* Motion */
  --transition: .15s cubic-bezier(0.4, 0, 0.2, 1);

  /* Spacing scale (4px base) — for use in custom layouts */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-12: 48px;
  --space-16: 64px;
}

/* ─────────────────────────────────────────────────────────────
 * 3. BASE (universal — applies to all surfaces)
 * ───────────────────────────────────────────────────────────── */
* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--sans);
}

/* Dashboard-app shell (full-height + no scroll) — opt-in via html.dashboard-shell */
html.dashboard-shell,
html.dashboard-shell body {
  height: 100%;
  overflow: hidden;
}

.app {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

/* ─────────────────────────────────────────────────────────────
 * 4. SIDEBAR (sb)
 * ───────────────────────────────────────────────────────────── */
.sb {
  width: 220px;
  flex-shrink: 0;
  background: var(--bg-surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}

.sb-brand {
  padding: 16px 14px 14px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}

.sb-icon {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--cyan) 0%, #0066dd 100%);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 0 12px rgba(0, 212, 255, 0.3);
}

.sb-icon svg {
  width: 16px;
  height: 16px;
  stroke: #000;
  stroke-width: 2.5;
}

.sb-name {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.2px;
}

.sb-ver {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--mono);
  margin-top: 1px;
}

.sb-nav {
  flex: 1;
  overflow-y: auto;
  padding: 8px 0;
}

.nav-grp {
  padding: 10px 14px 4px;
  font-size: 9px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.4px;
  font-family: var(--mono);
}

.nav-it {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 10px;
  margin: 1px 6px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 13px;
  color: var(--text-secondary);
  transition: all var(--transition);
  position: relative;
  user-select: none;
}

.nav-it:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.nav-it:hover .nav-icon {
  stroke: var(--text-primary);
}

.nav-it.on {
  background: var(--cyan-dim);
  color: var(--cyan);
  border: 1px solid rgba(0, 212, 255, .12);
}

.nav-it.on::before {
  content: '';
  position: absolute;
  left: -6px;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 20px;
  background: linear-gradient(180deg, var(--cyan), #0066dd);
  border-radius: 0 2px 2px 0;
}

.nav-it.on .nav-icon {
  stroke: var(--cyan);
}

.nav-icon {
  width: 15px;
  height: 15px;
  stroke: var(--text-muted);
  stroke-width: 1.8;
  flex-shrink: 0;
  transition: stroke var(--transition);
}

.nav-badge {
  margin-left: auto;
  background: var(--cyan-dim);
  color: var(--cyan);
  font-size: 10px;
  font-family: var(--mono);
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 10px;
  min-width: 18px;
  text-align: center;
}

.nb-amber { background: var(--amber-dim) !important; color: var(--amber) !important; }
.nb-green { background: var(--green-dim) !important; color: var(--green) !important; }
.nb-red   { background: var(--red-dim) !important; color: var(--red) !important; }

.sb-foot {
  padding: 12px 14px;
  border-top: 1px solid var(--border);
  font-size: 11px;
  font-family: var(--mono);
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.foot-row {
  display: flex;
  align-items: center;
  gap: 7px;
}

/* ─────────────────────────────────────────────────────────────
 * 5. STATUS DOTS (universal)
 * ───────────────────────────────────────────────────────────── */
.dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.dg { background: var(--green); box-shadow: 0 0 4px var(--green); animation: blink 2s ease-in-out infinite; }
.da { background: var(--amber); }
.dr { background: var(--red); }
.dc { background: var(--cyan); box-shadow: 0 0 4px var(--cyan); animation: blink 3s ease-in-out infinite; }

@keyframes blink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: .4; transform: scale(0.85); }
}

/* ─────────────────────────────────────────────────────────────
 * 6. MAIN AREA + TOPBAR
 * ───────────────────────────────────────────────────────────── */
.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.topbar {
  height: 50px;
  flex-shrink: 0;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 20px;
  gap: 12px;
}

.tb-title {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.2px;
}

.tb-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--green-dim);
  color: var(--green);
  font-size: 11px;
  font-family: var(--mono);
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 20px;
  border: 1px solid rgba(16, 240, 144, .18);
}

.tb-ts {
  margin-left: auto;
  font-size: 11px;
  font-family: var(--mono);
  color: var(--text-muted);
}

.tb-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 11px;
  padding: 5px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-family: var(--sans);
  font-weight: 500;
  transition: all var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.tb-btn:hover {
  border-color: var(--cyan);
  color: var(--cyan);
  background: var(--cyan-dim);
}

.tb-btn svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  stroke-width: 2;
}

.content {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  scroll-behavior: smooth;
}

.panel {
  display: none;
}

.panel.on {
  display: block;
  animation: panelIn .22s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes panelIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ─────────────────────────────────────────────────────────────
 * 7. CARDS (Tremor-inspired)
 * ───────────────────────────────────────────────────────────── */
.card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0, 212, 255, 0.03) 0%, transparent 60%);
  opacity: 0;
  transition: opacity var(--transition);
  pointer-events: none;
}

.card:hover {
  border-color: rgba(0, 212, 255, .22);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.card:hover::before {
  opacity: 1;
}

.card-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.3px;
  color: var(--text-muted);
  font-family: var(--mono);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.card-label svg {
  width: 12px;
  height: 12px;
  stroke: var(--text-muted);
  stroke-width: 2;
  flex-shrink: 0;
}

.card-metric {
  font-size: 28px;
  font-weight: 700;
  font-family: var(--mono);
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 6px;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.5px;
}

.card-sub {
  font-size: 12px;
  color: var(--text-secondary);
}

.card-delta {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-family: var(--mono);
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
  margin-top: 6px;
}

.delta-up { background: var(--green-dim); color: var(--green); }
.delta-down { background: var(--red-dim); color: var(--red); }
.delta-neutral { background: rgba(255, 255, 255, .05); color: var(--text-muted); }

.card-sparkline {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 80px;
  height: 44px;
  opacity: 0.35;
  pointer-events: none;
}

/* ─────────────────────────────────────────────────────────────
 * 8. GRIDS
 * ───────────────────────────────────────────────────────────── */
.g4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.g3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.g2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.g6 { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; }

@media (max-width: 1280px) {
  .g6 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1000px) {
  .g4 { grid-template-columns: repeat(2, 1fr); }
  .g3 { grid-template-columns: repeat(2, 1fr); }
  .g6 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .sb { width: 46px; }
  .sb-name, .sb-ver, .nav-it span:not(.nav-badge), .nav-badge, .nav-grp { display: none; }
  .g4, .g3, .g2 { grid-template-columns: 1fr; }
  .content { padding: 10px; }
}

/* ─────────────────────────────────────────────────────────────
 * 9. SECTION HEADER (shdr)
 * ───────────────────────────────────────────────────────────── */
.shdr {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.shdr h2 {
  font-size: 13px;
  font-weight: 700;
  font-family: var(--mono);
  color: var(--text-primary);
  letter-spacing: -0.1px;
  display: flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}

.shdr h2 svg {
  width: 14px;
  height: 14px;
  stroke: var(--cyan);
  stroke-width: 2;
  flex-shrink: 0;
}

.shdr .sep {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--border), transparent);
}

.shdr .ctag {
  font-size: 11px;
  font-family: var(--mono);
  color: var(--text-muted);
  background: var(--bg-surface);
  border: 1px solid var(--border);
  padding: 2px 8px;
  border-radius: 10px;
  white-space: nowrap;
}

/* ─────────────────────────────────────────────────────────────
 * 10. LIST ITEMS (li)
 * ───────────────────────────────────────────────────────────── */
.li {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 11px 13px;
  margin-bottom: 6px;
  cursor: pointer;
  transition: all var(--transition);
  display: flex;
  align-items: flex-start;
  gap: 11px;
}

.li:hover {
  border-color: rgba(0, 212, 255, .22);
  background: var(--bg-hover);
  transform: translateX(2px);
}

.li-ico {
  font-size: 15px;
  flex-shrink: 0;
  margin-top: 1px;
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.li-ico svg {
  width: 15px;
  height: 15px;
  stroke: var(--text-muted);
  stroke-width: 1.8;
}

.li-body {
  flex: 1;
  min-width: 0;
}

.li-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.li-meta {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
  font-family: var(--mono);
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}

.li-actions {
  display: flex;
  gap: 5px;
  flex-shrink: 0;
}

/* ─────────────────────────────────────────────────────────────
 * 11. BADGES (b)
 * ───────────────────────────────────────────────────────────── */
.b {
  font-size: 10px;
  font-family: var(--mono);
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: .5px;
}

.bh  { background: var(--red-dim); color: var(--red); }
.bm  { background: var(--amber-dim); color: var(--amber); }
.bs  { background: var(--green-dim); color: var(--green); }
.bp  { background: var(--cyan-dim); color: var(--cyan); }
.bd  { background: rgba(126, 126, 126, .12); color: #6b7280; }
.bph { background: var(--purple-dim); color: var(--purple); }

/* ─────────────────────────────────────────────────────────────
 * 12. BUTTONS (btn)
 * ───────────────────────────────────────────────────────────── */
.btn {
  font-size: 11px;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: 5px;
  cursor: pointer;
  border: 1px solid transparent;
  font-family: var(--sans);
  transition: all var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.btn svg {
  width: 11px;
  height: 11px;
  stroke: currentColor;
  stroke-width: 2.5;
}

.btn-ok    { background: var(--green-dim); color: var(--green); border-color: rgba(16, 240, 144, .25); }
.btn-ok:hover { background: rgba(16, 240, 144, .2); border-color: rgba(16, 240, 144, .4); }
.btn-no    { background: var(--red-dim); color: var(--red); border-color: rgba(255, 69, 96, .22); }
.btn-no:hover { background: rgba(255, 69, 96, .18); border-color: rgba(255, 69, 96, .4); }
.btn-wait  { background: var(--amber-dim); color: var(--amber); border-color: rgba(245, 166, 35, .22); }
.btn-wait:hover { background: rgba(245, 166, 35, .18); }
.btn-pri   { background: var(--cyan); color: #000; border-color: var(--cyan); font-weight: 700; }
.btn-pri:hover { background: #00b8d9; box-shadow: 0 0 12px rgba(0, 212, 255, 0.35); }

/* ─────────────────────────────────────────────────────────────
 * 13. PROGRESS (pt, pf)
 * ───────────────────────────────────────────────────────────── */
.pt {
  background: rgba(255, 255, 255, .05);
  border-radius: 4px;
  height: 5px;
  overflow: hidden;
}

.pf {
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--cyan), #0066ff);
  transition: width .6s cubic-bezier(0.4, 0, 0.2, 1);
}

.pf-a { background: linear-gradient(90deg, var(--amber), #d4720d) !important; }
.pf-g { background: linear-gradient(90deg, var(--green), #00aa66) !important; }
.pf-r { background: linear-gradient(90deg, var(--red), #cc0033) !important; }

/* ─────────────────────────────────────────────────────────────
 * 14. MODAL
 * ───────────────────────────────────────────────────────────── */
.modal-wrap {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .72);
  backdrop-filter: blur(6px);
  z-index: 100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-wrap.on {
  display: flex;
  animation: fdi .15s ease;
}

@keyframes fdi {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal-box {
  background: var(--bg-elevated);
  border: 1px solid rgba(0, 212, 255, .18);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 680px;
  max-height: 80vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 64px rgba(0, 0, 0, .7), 0 0 0 1px rgba(0, 212, 255, .06);
  animation: su .2s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes su {
  from { transform: translateY(16px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}

.modal-hdr {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
}

.modal-title {
  font-size: 14px;
  font-weight: 700;
  font-family: var(--mono);
  color: var(--text-primary);
  flex: 1;
  letter-spacing: -0.2px;
}

.modal-x {
  width: 28px;
  height: 28px;
  background: var(--bg-hover);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.modal-x:hover {
  color: var(--text-primary);
  border-color: var(--red);
  background: var(--red-dim);
}

.modal-x svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  stroke-width: 2.5;
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  font-size: 13px;
  line-height: 1.65;
  color: var(--text-secondary);
}

.modal-body h1, .modal-body h2, .modal-body h3 {
  color: var(--text-primary);
  font-family: var(--mono);
  margin: 16px 0 7px;
}

.modal-body h1 { font-size: 15px; }
.modal-body h2 { font-size: 13px; color: var(--cyan); }
.modal-body h3 { font-size: 12px; color: var(--amber); }

.modal-body p { margin-bottom: 10px; }

.modal-body code {
  background: var(--cyan-dim);
  padding: 1px 5px;
  border-radius: 3px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--cyan);
}

.modal-body pre {
  background: rgba(0, 0, 0, .35);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  overflow-x: auto;
}

.modal-body ul, .modal-body ol {
  padding-left: 20px;
  margin-bottom: 10px;
}

.modal-body li { margin-bottom: 4px; }
.modal-body strong { color: var(--text-primary); }
.modal-body hr { border: none; border-top: 1px solid var(--border); margin: 16px 0; }

.modal-foot {
  padding: 12px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-end;
}

/* ─────────────────────────────────────────────────────────────
 * 15. IFRAMES
 * ───────────────────────────────────────────────────────────── */
.iframe-wrap {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  height: calc(100vh - 150px);
}

.iframe-wrap iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.iframe-off {
  height: calc(100vh - 150px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-muted);
  gap: 14px;
}

.iframe-off svg {
  width: 44px;
  height: 44px;
  stroke: var(--text-muted);
  stroke-width: 1.2;
  opacity: .5;
}

.iframe-off .big {
  font-size: 40px;
  opacity: .5;
}

/* ─────────────────────────────────────────────────────────────
 * 16. AGENT DOTS (adot — slightly larger than .dot)
 * ───────────────────────────────────────────────────────────── */
.adot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

.a-act  { background: var(--green); box-shadow: 0 0 5px rgba(16, 240, 144, 0.5); }
.a-idle { background: var(--amber); }
.a-dorm { background: var(--text-muted); }

/* ─────────────────────────────────────────────────────────────
 * 17. TODO ITEMS (ti)
 * ───────────────────────────────────────────────────────────── */
.ti {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  margin-bottom: 4px;
  background: rgba(255, 255, 255, .015);
  border: 1px solid transparent;
  transition: all var(--transition);
}

.ti:hover {
  background: var(--bg-hover);
  border-color: var(--border);
}

.ti-chk {
  width: 16px;
  height: 16px;
  border: 1.5px solid var(--text-muted);
  border-radius: 4px;
  flex-shrink: 0;
  margin-top: 1px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.ti-chk:hover { border-color: var(--cyan); }

.ti-chk.done {
  background: var(--green);
  border-color: var(--green);
  color: #000;
  box-shadow: 0 0 6px rgba(16, 240, 144, 0.4);
}

.ti-chk.done svg {
  width: 10px;
  height: 10px;
  stroke: #000;
  stroke-width: 3;
}

.ti-txt {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
}

.ti-txt.done {
  text-decoration: line-through;
  color: var(--text-muted);
}

/* ─────────────────────────────────────────────────────────────
 * 18. PROJECT CARDS (proj-card)
 * ───────────────────────────────────────────────────────────── */
.proj-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  cursor: pointer;
  transition: all var(--transition);
}

.proj-card:hover {
  border-color: rgba(0, 212, 255, .22);
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

.proj-bar {
  height: 3px;
  border-radius: 2px;
  margin-bottom: 15px;
}

.s-act  { background: linear-gradient(90deg, var(--green), #00aa66); box-shadow: 0 0 8px rgba(16, 240, 144, 0.3); }
.s-bld  { background: linear-gradient(90deg, var(--cyan), #0066ff); box-shadow: 0 0 8px rgba(0, 212, 255, 0.3); }
.s-plan { background: rgba(255, 255, 255, .08); }

/* ─────────────────────────────────────────────────────────────
 * 19. EMPTY STATES
 * ───────────────────────────────────────────────────────────── */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 52px 24px;
  gap: 14px;
  text-align: center;
}

.empty-state svg {
  width: 40px;
  height: 40px;
  stroke: var(--text-muted);
  stroke-width: 1.2;
  opacity: .5;
}

.empty-state .es-title {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-muted);
}

.empty-state .es-sub {
  font-size: 11px;
  color: var(--text-muted);
  opacity: .7;
  max-width: 240px;
  line-height: 1.5;
}

/* ─────────────────────────────────────────────────────────────
 * 20. UTILITY: FADE-IN ON SCROLL
 * ───────────────────────────────────────────────────────────── */
.fade-in {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .35s ease, transform .35s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─────────────────────────────────────────────────────────────
 * 21. SKELETON LOADER (skel)
 * ───────────────────────────────────────────────────────────── */
.skel {
  background: linear-gradient(90deg, var(--bg-elevated) 25%, var(--bg-hover) 50%, var(--bg-elevated) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-sm);
}

@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ─────────────────────────────────────────────────────────────
 * 22. SPARKLINES (inline SVG polyline)
 * ───────────────────────────────────────────────────────────── */
.sparkline { overflow: visible; }

.sparkline polyline {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ─────────────────────────────────────────────────────────────
 * 23. SEPARATOR TAG (sep-tag)
 * ───────────────────────────────────────────────────────────── */
.sep-tag {
  display: inline-block;
  font-size: 10px;
  font-family: var(--mono);
  color: var(--text-muted);
  background: var(--bg-surface);
  border: 1px solid var(--border);
  padding: 1px 7px;
  border-radius: 8px;
}

/* ─────────────────────────────────────────────────────────────
 * 24. SCROLLBAR (custom)
 * ───────────────────────────────────────────────────────────── */
::-webkit-scrollbar {
  width: 4px;
  height: 4px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, .08);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, .15);
}

/* ─────────────────────────────────────────────────────────────
 * 25. ACCESSIBILITY: REDUCED MOTION
 * ───────────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
