/* Onboarding chip ------------------------------------------------ */
.onb-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--accent-wash);
  border: 1px solid var(--accent-soft);
  color: var(--ink);
  font-size: 11.5px; font-weight: 500;
  text-decoration: none;
  position: relative;
  cursor: pointer;
  transition: background .12s, border-color .12s;
}
.onb-chip:hover {
  background: color-mix(in srgb, var(--accent-wash) 80%, white);
  border-color: var(--accent-deep);
}
.onb-chip-spark {
  display: inline-flex;
  color: var(--accent-deep);
}
.onb-chip-pct {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--ink-3);
}
.onb-chip-bar {
  display: inline-block;
  width: 40px; height: 4px;
  background: var(--bg-elev);
  border-radius: 2px;
  overflow: hidden;
}
.onb-chip-bar-fill {
  display: block; height: 100%;
  background: var(--accent-deep);
  border-radius: 2px;
}

[data-theme="dark"] .onb-chip {
  background: rgba(245,197,24,.13);
  border-color: rgba(245,197,24,.28);
  color: #FFE799;
}
[data-theme="dark"] .onb-chip:hover {
  background: rgba(245,197,24,.20);
}
[data-theme="dark"] .onb-chip-pct { color: #F4F1E8; }
[data-theme="dark"] .notif-pip { color: #14130F; }

/* Notification bell --------------------------------------------- */
.notif-bell { position: relative; }
.notif-bell-trigger { position: relative; }
.notif-pip {
  position: absolute;
  top: 1px; right: 1px;
  min-width: 14px; height: 14px;
  padding: 0 3px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  line-height: 1;
  display: grid; place-items: center;
  border: 1.5px solid var(--bg);
  letter-spacing: 0;
  pointer-events: none;
}
.notif-pop {
  position: absolute;
  top: calc(100% + 6px); right: 0;
  width: 360px;
  background: var(--bg-elev);
  border: 1px solid var(--line-2);
  border-radius: 12px;
  box-shadow: var(--sh-3);
  z-index: 70;
  max-height: 480px;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.notif-pop-h {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  font-size: 13px; font-weight: 600; color: var(--ink);
}
.notif-pop-count {
  background: var(--accent-wash);
  border: 1px solid var(--accent-soft);
  border-radius: 999px;
  padding: 1px 7px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--ink);
}
.notif-pop-ack-all {
  height: 26px;
  padding: 0 9px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink-3);
  font-size: 11.5px;
  font-weight: 500;
  border-radius: 7px;
  cursor: pointer;
  transition: background .12s, color .12s, border-color .12s;
}
.notif-pop-ack-all:hover {
  background: var(--bg-sunk);
  color: var(--ink);
}
.notif-pop-ack-all:active { transform: translateY(1px); }
.notif-list {
  flex: 1; min-height: 80px;
  overflow-y: auto;
  display: flex; flex-direction: column;
}
.notif-loading, .notif-empty {
  padding: 24px;
  text-align: center;
  font-size: 12px;
  color: var(--ink-4);
}
.notif-row {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: var(--ink-2);
  font-size: 13px;
}
.notif-row:hover { background: var(--bg-sunk); }
.notif-row[data-unread="true"] {
  background: linear-gradient(90deg, var(--accent-wash) 0, transparent 6px);
  color: var(--ink);
}
.notif-icon {
  width: 28px; height: 28px;
  border-radius: 8px;
  background: var(--accent-wash);
  color: var(--accent-deep);
  display: grid; place-items: center;
  flex: none;
}
.notif-body { flex: 1; min-width: 0; }
.notif-title {
  display: block;
  font-size: 13px; font-weight: 500; color: var(--ink);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.notif-sub {
  display: block;
  font-size: 11.5px; color: var(--ink-4);
  margin-top: 1px;
  overflow: hidden; text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.notif-time {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--ink-4);
  flex: none;
}

/* Command K palette ---------------------------------------------- */
.cmdk-scrim {
  position: fixed; inset: 0;
  background: rgba(20,19,15,.5);
  z-index: 100;
  animation: fadein .12s ease-out;
}
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
.cmdk-modal {
  position: fixed;
  top: 80px; left: 50%;
  transform: translateX(-50%);
  width: 100%; max-width: 600px;
  background: var(--bg-elev);
  border: 1px solid var(--line-2);
  border-radius: 14px;
  box-shadow: var(--sh-3);
  z-index: 110;
  display: flex; flex-direction: column;
  max-height: 70vh;
  overflow: hidden;
}
.cmdk-input-row {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}
.cmdk-input-row > svg { color: var(--ink-4); flex: none; }
.cmdk-input {
  flex: 1;
  border: 0; outline: none;
  background: transparent;
  font-size: 15px; color: var(--ink);
}
.cmdk-input::placeholder { color: var(--ink-4); }
.cmdk-results {
  flex: 1;
  overflow-y: auto;
  padding: 6px 0;
}
.cmdk-group {
  padding: 8px 16px 4px;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.cmdk-item {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 16px;
  font-size: 13.5px;
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
}
.cmdk-item:hover { background: var(--bg-sunk); }
.cmdk-item-label { flex: 1; }
.cmdk-empty {
  padding: 32px;
  text-align: center;
  font-size: 13px;
  color: var(--ink-4);
}
.cmdk-footer {
  display: flex; gap: 14px;
  padding: 8px 16px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  color: var(--ink-4);
}
.cmdk-footer .kbd { margin-right: 4px; }
