:root {
  --font-display: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif,
    "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  --font-body: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif,
    "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";

  --bg-app: #f6f4fb;
  --bg-device: rgba(255, 255, 255, 0.72);
  --text-main: #1f2430;
  --text-muted: #8f95ab;
  --text-sub: #5f667b;
  
  --accent-violet: #a78bfa;
  --accent-violet-soft: #efe9ff;
  --accent-pink: #f4a7c7;
  --accent-blue: #8dc5ff;
  --accent-teal: #76dacc;
  --accent-orange: #ffc58a;
  
  --border-light: rgba(255, 255, 255, 0.78);
  --shadow-soft: 0 3px 12px rgba(63, 52, 89, 0.06);
  --shadow-float: 0 10px 24px rgba(57, 44, 97, 0.08);
  
  --safe-top: 40px;
  --safe-bottom: 30px;
  --nav-height: 80px;
  --nav-offset: 24px;
  --nav-clearance: calc(var(--nav-height) + var(--nav-offset) + var(--safe-bottom));
  --composer-height: 72px;
  --composer-clearance: calc(var(--nav-clearance) + var(--composer-height) + 12px);
  --chat-font-size: 14px;
}

.terminal-placeholder {
  border-radius: 18px;
  padding: 14px 16px;
  background: rgba(255, 230, 240, 0.5);
  color: var(--text-sub);
  font-size: 12px;
  border: 1px solid rgba(214, 164, 190, 0.35);
  display: grid;
  gap: 10px;
}

.terminal-placeholder-guidance {
  text-align: left;
  background: linear-gradient(135deg, rgba(255, 240, 246, 0.6), rgba(255, 255, 255, 0.75));
  box-shadow: 0 3px 10px rgba(214, 164, 190, 0.16);
  margin-top: 22px;
  margin-bottom: 14px;
}

.terminal-placeholder__top {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.terminal-placeholder__icon {
  display: none;
}

.terminal-placeholder__title {
  margin: 0;
  font-weight: 800;
  font-size: 13px;
  color: #1f2937;
}

.terminal-placeholder__body {
  display: grid;
  gap: 8px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-sub);
}

.terminal-placeholder__body p {
  margin: 0;
}

.terminal-placeholder__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.terminal-placeholder__pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(214, 164, 190, 0.35);
  background: rgba(255, 230, 240, 0.45);
  color: #1f2937;
  font-weight: 600;
}

.terminal-placeholder--warning {
  border-color: rgba(214, 164, 190, 0.32);
  background: rgba(255, 240, 246, 0.7);
}

.terminal-placeholder--warning .terminal-placeholder__icon {
  display: none;
}

.terminal-placeholder--warning .terminal-placeholder__title {
  color: rgba(255, 0, 0, 0.5);
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

:where(
  button,
  input,
  textarea,
  select,
  [role="button"],
  .pill-btn,
  .icon-btn-circle,
  .chat-list-item,
  .setting-item,
  .setting-toggle,
  .skills-tab-btn,
  .log-tab,
  .terminal-entry
):focus-visible {
  outline: 2px solid rgba(140, 110, 232, 0.9);
  outline-offset: 2px;
  box-shadow: 0 0 0 4px rgba(167, 139, 250, 0.2);
}

input::placeholder,
textarea::placeholder {
  color: rgba(96, 103, 128, 0.72);
}

body {
  margin: 0;
  font-family: var(--font-body);
  background:
    radial-gradient(1200px 700px at -5% -15%, rgba(255, 206, 229, 0.32), transparent 60%),
    radial-gradient(900px 580px at 95% 15%, rgba(255, 191, 214, 0.28), transparent 56%),
    radial-gradient(720px 460px at 80% 96%, rgba(255, 210, 183, 0.22), transparent 58%),
    linear-gradient(140deg, #fff7fb 0%, #fff9fd 55%, #fffdfd 100%);
  background-blend-mode: screen, screen, screen, normal;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--text-main);
  overflow: hidden;
  position: relative;
}

body::before,
body::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
}

body::before {
  width: 320px;
  height: 320px;
  background: rgba(167, 139, 250, 0.28);
  top: -80px;
  left: -60px;
}

body::after {
  width: 280px;
  height: 280px;
  background: rgba(244, 167, 199, 0.22);
  right: -40px;
  bottom: -70px;
}

.device {
  width: 100%;
  max-width: 400px;
  height: calc(100vh - 16px);
  max-height: 780px;
  margin: 8px auto;
  background:
    linear-gradient(rgba(255, 255, 255, 0.45), rgba(255, 255, 255, 0.45)),
    url("/static/img/app-background.png") center/cover no-repeat;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 22px rgba(57, 44, 97, 0.12);
  display: flex;
  flex-direction: column;
  border-radius: 36px;
  border: 6px solid rgba(255, 255, 255, 0.84);
  backdrop-filter: blur(3px);
  z-index: 1;
}

/* Status Bar */
.status-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 44px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 24px;
  z-index: 50;
  font-size: 14px;
  font-weight: 600;
  color: #475569;
}

.status-app-name {
  position: absolute;
  left: 48%;
  transform: translateX(-50%);
  display: inline-block;
  color: #8b95a9;
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1;
  pointer-events: none;
}

.status-icons {
  display: flex;
  align-items: center;
  gap: 6px;
}

.battery-wrap {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 6px;
  border-radius: 999px;
  background: rgba(129, 140, 248, 0.14);
  color: #4f46e5;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.battery-wrap .status-icon {
  width: 14px;
  height: 14px;
}

.status-icon {
  width: 16px;
  height: 16px;
  stroke-width: 2.5px;
}

/* Main App Area */
.app {
  flex: 1;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(6px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding-top: var(--safe-top);
  position: relative;
}

.tab-view {
  display: none;
  flex-direction: column;
  height: 100%;
  position: relative;
  animation: fadeIn 0.3s ease;
}

.tab-view.active {
  display: flex;
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.98); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes chatDrawerIn {
  from { opacity: 0; transform: translateX(24px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes chatDrawerOut {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(18px); }
}

/* Scroll Containers */
.content-scroll {
  flex: 1;
  overflow-y: auto;
  padding-bottom: 120px; /* Space for floating nav */
  padding-top: 10px;
  /* Hide scrollbar */
  scrollbar-width: none; 
  -ms-overflow-style: none;
}
.content-scroll::-webkit-scrollbar { 
  display: none; 
}

/* Lobsters Header */
.header-glass {
  padding: 10px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255, 255, 255, 0.56);
  backdrop-filter: blur(18px);
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(255, 255, 255, 0.82);
}

.tab-view[data-tab-view="skills"] > .header-glass,
.logs-content > .header-glass,
.settings-content > .header-glass {
  background: rgba(255, 255, 255, 0.56);
  backdrop-filter: blur(18px);
}

.page-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 900;
  margin: 0;
  letter-spacing: -0.03em;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-main);
}

.hero-title {
  margin: 4px 0 6px;
  font-family: var(--font-display);
  font-size: 26px;
  letter-spacing: -0.04em;
  color: var(--text-main);
  line-height: 1.1;
}

.hero-sub {
  margin: 0;
  color: var(--text-sub);
  font-size: 12px;
  max-width: 240px;
}

.gradient-text {
  background: linear-gradient(120deg, #a855f7, #6366f1, #22d3ee);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-tags {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-app);
  color: var(--text-main);
  border: 1px solid var(--border-light);
  border-radius: 12px;
  padding: 8px 10px;
  box-shadow: var(--shadow-soft);
  font-weight: 700;
  font-size: 12px;
}

.hero-pill.soft {
  background: rgba(255,255,255,0.85);
}

.hero-badge {
  min-width: 96px;
  background: linear-gradient(160deg, #eef2ff, #f5f3ff);
  border: 1px solid var(--border-light);
  border-radius: 16px;
  padding: 12px 10px;
  box-shadow: var(--shadow-soft);
  text-align: center;
}

.badge-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: var(--accent-violet-soft);
  display: grid;
  place-items: center;
  margin: 0 auto 8px;
  color: var(--accent-violet);
}

.badge-text {
  margin: 0;
  font-weight: 800;
  font-size: 12px;
  color: var(--text-main);
}

.hero-chip {
  background: var(--bg-app);
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}

.accent-icon {
  width: 20px;
  height: 20px;
  color: var(--accent-violet);
  stroke-width: 2.5px;
}

.brand-icon {
  width: 30px;
  height: 30px;
  stroke-width: 4px;
}

.icon-btn-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: transform 0.1s;
}
.icon-btn-circle:active {
  transform: scale(0.95);
}

/* Welcome Card */
.welcome-card {
  margin: 0 24px 24px;
  background: linear-gradient(135deg, var(--accent-violet), #d946ef);
  border-radius: 24px;
  padding: 20px;
  color: white;
  box-shadow: 0 4px 10px rgba(61, 46, 90, 0.07);
}

.welcome-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0 0 4px;
}

.welcome-text {
  font-size: 14px;
  opacity: 0.9;
  margin: 0;
}

/* Lobsters WeChat-style */
.lobsters-shell {
  flex: 1;
  display: flex;
  flex-direction: column;
  position: relative;
  padding: 0 14px calc(var(--nav-clearance) + 20px);
}

.chat-drawer-open .lobsters-shell {
  padding-bottom: 20px;
}

.lobsters-tabs {
  display: flex;
  gap: 10px;
  padding: 12px 0 6px;
}

.lobsters-tab-btn {
  border: none;
  background: transparent;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-sub);
  cursor: pointer;
}

.lobsters-tab-btn.active {
  background: var(--accent-violet-soft);
  color: var(--accent-violet);
}

.chat-list-view,
.chat-detail-view {
  display: none;
  flex: 1;
  position: relative;
}

.gateway-list-view,
.gateway-detail-view {
  display: none;
  flex: 1;
  min-height: 0;
  position: relative;
}

.chat-drawer-open .chat-detail-view {
  position: absolute;
  inset: 0;
  background: transparent;
  z-index: 120;
  padding: 0 14px;
  animation: chatDrawerIn 0.25s ease;
}

.chat-drawer-open .gateway-detail-view {
  position: absolute;
  inset: 0;
  background: transparent;
  z-index: 120;
  padding: 0 14px;
  animation: chatDrawerIn 0.25s ease;
}

.chat-drawer-open .gateway-detail-view.is-exiting {
  animation: chatDrawerOut 0.22s ease forwards;
  pointer-events: none;
}

.chat-drawer-open .gateway-detail-view .config-backdrop,
.chat-drawer-open .gateway-detail-view .contacts-backdrop,
.chat-drawer-open .gateway-detail-view .config-drawer,
.chat-drawer-open .gateway-detail-view .contacts-drawer {
  left: -14px;
  right: -14px;
}

.chat-drawer-open .chat-detail-view .chat-thread {
  padding-bottom: calc(var(--composer-height) + var(--safe-bottom) + 12px);
}

.chat-drawer-open .gateway-detail-view .chat-thread {
  padding-bottom: calc(var(--composer-height) + var(--safe-bottom) + 12px);
}

.chat-drawer-open .chat-detail-view .chat-composer {
  bottom: var(--safe-bottom);
}

.chat-drawer-open .gateway-detail-view .chat-composer {
  bottom: var(--safe-bottom);
}

.chat-list-view.active,
.chat-detail-view.active {
  display: flex;
  flex-direction: column;
}

.gateway-list-view.active,
.gateway-detail-view.active {
  display: flex;
  flex-direction: column;
}

.chat-detail-view .chat-composer,
.gateway-detail-view .chat-composer {
  position: absolute;
  left: 0;
  right: 0;
  bottom: var(--nav-clearance);
  z-index: 20;
}

.chat-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 11px;
}

.chat-list-item {
  background: rgba(255, 255, 255, 0.54);
  border: 1px solid transparent;
  border-radius: 25px;
  width: calc(100% - 10px);
  margin-inline: auto;
  padding: 16px 14px;
  display: flex;
  gap: 14px;
  align-items: center;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.035);
  backdrop-filter: blur(16px);
  cursor: pointer;
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.chat-list-item:hover {
  transform: translateY(-0.5px);
  box-shadow: 0 5px 10px rgba(61, 46, 90, 0.06);
}

.chat-list-item.active {
  border-color: transparent;
  background: rgba(255, 255, 255, 0.8);
  box-shadow: 0 5px 11px rgba(74, 53, 118, 0.07);
}

.chat-list-avatar {
  width: 44px;
  height: 44px;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(239, 233, 255, 0.95), rgba(255, 255, 255, 0.9));
  color: #8f73ee;
  display: grid;
  place-items: center;
  font-weight: 800;
  border: 1px solid rgba(255, 255, 255, 0.86);
  box-shadow: 0 3px 8px rgba(68, 57, 96, 0.05);
  backdrop-filter: blur(14px);
  position: relative;
}

.chat-list-avatar::after {
  content: "";
  position: absolute;
  right: -2px;
  bottom: -2px;
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: #22c55e;
  border: 2px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.2);
}

.chat-list-avatar[data-tone="warning"]::after {
  background: #f59e0b;
  box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.22);
}

.chat-list-avatar[data-tone="idle"]::after {
  background: #94a3b8;
  box-shadow: 0 0 0 1px rgba(148, 163, 184, 0.28);
}

.chat-list-avatar[data-tone="error"]::after {
  background: #ef4444;
  box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.2);
}

.chat-list-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
}

.chat-list-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0;
  gap: 8px;
}

.chat-list-titleline {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.chat-list-meta {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-shrink: 0;
}

.chat-list-name {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text-main);
  font-size: 14px;
  letter-spacing: -0.01em;
}

.chat-list-time {
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.chat-list-preview {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: var(--text-sub);
  line-height: 1.3;
  min-width: 0;
}

.chat-list-preview-time {
  flex: 0 0 auto;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: #8b93a5;
  text-transform: uppercase;
}

.chat-list-preview-text {
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-list-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.chat-list-controls .icon-btn-circle {
  width: 26px;
  height: 26px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(229, 231, 235, 0.8);
  color: #737b92;
  box-shadow: 0 3px 6px rgba(65, 53, 93, 0.06);
}

.chat-list-controls .icon-btn-circle i {
  width: 13px;
  height: 13px;
}

.chat-list-status {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--text-sub);
}

.chat-list-status[data-tone="ok"] {
  color: #047857;
}

.chat-list-status[data-tone="warning"] {
  color: inherit;
}

.chat-list-status[data-tone="error"] {
  color: #b91c1c;
}

.chat-detail-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 6px 2px 12px;
}

.chat-detail-header--template {
  grid-template-columns: auto 1fr auto;
  align-items: center;
  padding: 0;
}

.chat-detail-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  justify-self: end;
  min-width: 0;
  flex-wrap: nowrap;
}

.gateway-pipeline {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 6px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  background: rgba(255, 255, 255, 0.85);
  color: #64748b;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.01em;
  max-width: 230px;
  overflow: hidden;
  white-space: nowrap;
}

.gateway-pipeline-shell {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  width: 100%;
  min-width: 0;
}

.gateway-pipeline--panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 4px;
  max-width: 100%;
  width: 100%;
  justify-content: initial;
  overflow: visible;
  white-space: normal;
  padding: 6px 0 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.gateway-pipeline--panel .gateway-pipeline-node {
  min-width: 0;
  justify-content: center;
  padding: 2px 6px;
}

.gateway-pipeline--panel .gateway-pipeline-sep {
  justify-self: center;
}

.gateway-pipeline--panel .gateway-pipeline-node strong {
  font-size: 10px;
}

.gateway-pipeline--panel .gateway-pipeline-node em {
  display: none;
}

.gateway-pipeline-node {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  min-height: 24px;
  border-radius: 999px;
  padding: 3px 6px;
  background: rgba(241, 245, 249, 0.85);
  color: #64748b;
  box-shadow: 0 1px 2px rgba(51, 65, 85, 0.08);
}

.gateway-pipeline-node strong {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.gateway-pipeline-node em {
  display: none;
}

.gateway-pipeline-node[data-stage="ok"] {
  background: rgba(236, 253, 245, 0.9);
  color: #047857;
}

.gateway-pipeline-node[data-stage="pending"] {
  background: rgba(255, 251, 235, 0.95);
  color: #b45309;
}

.gateway-pipeline-node[data-stage="error"] {
  background: rgba(254, 242, 242, 0.95);
  color: #b91c1c;
}

.gateway-pipeline-node[data-stage="off"] {
  background: rgba(248, 250, 252, 0.95);
  color: #64748b;
}

.gateway-pipeline-sep {
  color: rgba(100, 116, 139, 0.7);
  font-size: 9px;
}

.chat-detail-controls .chat-live-chip--header {
  padding: 4px 7px;
  font-size: 10px;
  gap: 5px;
  min-width: 0;
}

.chat-detail-controls .chat-live-chip--header[data-action="gateway-reconnect"] {
  cursor: pointer;
  user-select: none;
  transition: transform 0.14s ease, box-shadow 0.16s ease;
}

.chat-detail-controls .chat-live-chip--header[data-action="gateway-reconnect"]:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(64, 51, 95, 0.1);
}

.chat-detail-controls .chat-live-chip--header[data-action="gateway-reconnect"]:active {
  transform: translateY(0);
  box-shadow: none;
}

.chat-detail-controls .chat-detail-status {
  font-size: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 90px;
}

.chat-detail-controls .icon-btn-circle {
  width: 30px;
  height: 30px;
  border-radius: 10px;
  box-shadow: 0 2px 5px rgba(64, 51, 95, 0.08);
}

.chat-detail-controls .icon-btn-circle i,
.chat-detail-controls .icon-btn-circle svg {
  width: 14px;
  height: 14px;
}

@media (max-width: 390px) {
  .chat-detail-controls {
    gap: 4px;
  }

  .chat-detail-controls .chat-live-chip--header {
    padding: 3px 6px;
  }

  .chat-detail-controls .chat-detail-status {
    max-width: 78px;
  }

  .gateway-pipeline {
    max-width: 170px;
    gap: 2px;
    padding: 3px 5px;
  }

  .gateway-pipeline--panel {
    max-width: 100%;
    width: 100%;
    padding: 0;
  }

  .gateway-pipeline-node {
    min-height: 22px;
    padding: 1px 4px;
  }

  .chat-detail-controls .icon-btn-circle {
    width: 28px;
    height: 28px;
  }
}

.chat-live-chip {
  justify-self: center;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(226, 231, 240, 0.9);
  border-radius: 999px;
  padding: 6px 10px;
  box-shadow: 0 2px 8px rgba(69, 57, 97, 0.06);
  color: #4b5563;
  font-size: 11px;
}

.chat-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.14);
}

.chat-live-chip[data-tone="warning"] .chat-live-dot {
  background: #f59e0b;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}

.chat-live-chip[data-tone="error"] .chat-live-dot {
  background: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
}

.chat-live-chip[data-tone="idle"] .chat-live-dot {
  background: #94a3b8;
  box-shadow: 0 0 0 2px rgba(148, 163, 184, 0.18);
}

.chat-detail-header--list {
  grid-template-columns: 1fr;
}

.chat-live-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 2px 10px;
}

.chat-live-row--padded {
  padding: 10px 4px 12px;
}

.chat-live-row--under-profile {
  padding-top: 6px;
  padding-bottom: 0;
}

.config-divider--after-pipeline {
  margin: 8px 0 12px;
}

.chat-live-label {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #9aa3b6;
}

.chat-detail-title {
  margin: 11px 0 0;
  font-weight: 800;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #9aa3b6;
}

.chat-detail-title[data-gateway-detail-title] {
  margin: 0;
  padding: 0;
  border-radius: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 900;
  letter-spacing: 0.07em;
  color: #4a5064;
  line-height: 1.1;
  justify-self: start;
  align-self: center;
  max-width: min(46vw, 240px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-detail-status {
  font-family: var(--font-display);
  font-size: 13px;
  color: #334155;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.chat-detail-status[data-tone="ok"] {
  color: #047857;
}

.chat-detail-status[data-tone="warning"] {
  color: #b45309;
}

.chat-detail-status[data-tone="error"] {
  color: #b91c1c;
}

.chat-detail-status[data-tone="idle"] {
  color: #64748b;
}

.chat-detail-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.gateway-config {
  background: white;
  border: 1px solid var(--border-light);
  border-radius: 16px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.04);
}

.gateway-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.gateway-field label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-sub);
}

.gateway-field input {
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid var(--border-light);
  font-size: 12px;
}

.gateway-actions {
  display: flex;
  gap: 10px;
}

.chat-thread {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-top: 14px;
  padding-bottom: var(--composer-clearance);
}
.chat-thread::-webkit-scrollbar { display: none; }

.chat-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 76%) 38px;
  column-gap: 8px;
  align-items: flex-start;
  justify-content: center;
}

.chat-row.me {
  justify-content: center;
}

.chat-avatar-stack {
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  align-self: start;
}

.chat-avatar-stack--bot {
  grid-column: 1;
}

.chat-avatar-stack--user {
  grid-column: 3;
}

.chat-row--clustered {
  margin-top: -4px;
}

.chat-row--clustered:not(.me) .chat-bubble,
.chat-row--clustered:not(.me) .chat-inline,
.chat-row--clustered:not(.me) .chat-structured {
  border-top-left-radius: 10px;
}

.chat-row--clustered.me .chat-bubble,
.chat-row--clustered.me .chat-inline,
.chat-row--clustered.me .chat-structured {
  border-top-right-radius: 10px;
}

.chat-row > div:not(.chat-avatar-stack) {
  grid-column: 2;
  display: flex;
  flex-direction: column;
  max-width: none;
  justify-self: start;
  align-items: flex-start;
  text-align: left;
}

.chat-row.me > div:not(.chat-avatar-stack) {
  justify-self: end;
  align-items: flex-end;
  text-align: right;
}

.chat-bubble {
  max-width: 100%;
  display: inline-block;
  min-height: 0;
  padding: 7px 13px;
  border-radius: 11px;
  font-size: var(--chat-font-size, 14px);
  line-height: 1.3;
  box-shadow: 0 4px 10px rgba(70, 60, 99, 0.07);
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  color: var(--text-main);
  word-break: break-word;
  white-space: normal;
}

.chat-md {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.chat-md > * {
  margin: 0;
}

.chat-md p {
  line-height: 1.34;
}

.chat-emoji {
  display: inline-block;
  font-size: 0.9em;
  line-height: 1;
  vertical-align: -0.08em;
  letter-spacing: 0;
}

.chat-md-h1,
.chat-md-h2,
.chat-md-h3,
.chat-md-h4 {
  margin: 0;
  line-height: 1.35;
  letter-spacing: 0.01em;
  color: #111827;
}

.chat-md-h1 {
  font-size: 18px;
  font-weight: 800;
}

.chat-md-h2 {
  font-size: 16px;
  font-weight: 800;
}

.chat-md-h3 {
  font-size: 15px;
  font-weight: 700;
}

.chat-md-h4 {
  font-size: 14px;
  font-weight: 700;
}

.chat-md-hr {
  margin: 2px 0;
  border: 0;
  border-top: 1px solid rgba(148, 163, 184, 0.35);
}

.chat-md ul,
.chat-md ol {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 4px;
}

.chat-task-list {
  list-style: none;
  padding-left: 0;
}

.chat-task-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px;
  align-items: start;
}

.chat-task-item input[type="checkbox"] {
  width: 14px;
  height: 14px;
  margin: 2px 0 0;
  accent-color: #6366f1;
}

.chat-md blockquote {
  margin: 0;
  padding: 4px 0 4px 10px;
  border-left: 2px solid rgba(148, 163, 184, 0.55);
  color: #475569;
}

.chat-md a {
  color: #4f46e5;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.chat-md code {
  font-family: "JetBrains Mono", "Fira Code", monospace;
  font-size: 12px;
  padding: 0 5px;
  border-radius: 6px;
  border: 1px solid rgba(203, 213, 225, 0.8);
  background: rgba(248, 250, 252, 0.95);
  color: #334155;
}

.chat-code-wrap {
  border: 1px solid rgba(148, 163, 184, 0.33);
  border-radius: 11px;
  overflow: hidden;
  background: #0f172a;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.chat-code-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 10px;
  font-size: 10px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  font-weight: 700;
  color: #cbd5e1;
  background: rgba(30, 41, 59, 0.95);
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.chat-code-lang {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chat-code-copy {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(51, 65, 85, 0.9);
  color: #e2e8f0;
  border-radius: 999px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 8px;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.16s ease;
}

.chat-code-copy:hover {
  background: rgba(71, 85, 105, 0.95);
  border-color: rgba(148, 163, 184, 0.48);
}

.chat-code-copy:active {
  transform: translateY(1px);
}

.chat-code-copy.is-copied {
  background: rgba(34, 197, 94, 0.25);
  border-color: rgba(74, 222, 128, 0.65);
  color: #dcfce7;
}

.chat-code-block {
  margin: 0;
  padding: 10px 12px;
  max-width: 100%;
  overflow-x: auto;
  white-space: pre;
  word-break: normal;
  color: #e2e8f0;
  font-family: "JetBrains Mono", "Fira Code", monospace;
  font-size: 12px;
  line-height: 1.5;
}

.chat-code-block code {
  display: block;
  border: none;
  padding: 0;
  background: transparent;
  color: inherit;
}

.chat-syn-comment {
  color: #94a3b8;
}

.chat-syn-keyword {
  color: #7dd3fc;
  font-weight: 600;
}

.chat-syn-string {
  color: #86efac;
}

.chat-syn-number {
  color: #fbbf24;
}

.chat-syn-literal {
  color: #fca5a5;
  font-weight: 600;
}

.chat-bubble.streaming {
  position: relative;
}

.chat-stream-cursor {
  display: inline-block;
  width: 0.55ch;
  margin-left: 1px;
  border-right: 2px solid currentColor;
  vertical-align: text-bottom;
  opacity: 0.75;
  animation: chatStreamCursorBlink 0.95s steps(1, end) infinite;
}

@keyframes chatStreamCursorBlink {
  0%, 45% {
    opacity: 0.75;
  }
  46%, 100% {
    opacity: 0;
  }
}

.chat-bubble.thinking {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  min-width: 48px;
}

.chat-bubble.thinking-note {
  opacity: 0.65;
  font-style: italic;
}

.chat-bubble.thinking span {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--text-sub);
  animation: thinkingPulse 1.2s ease-in-out infinite;
}

.chat-bubble.thinking span:nth-child(2) { animation-delay: 0.15s; }
.chat-bubble.thinking span:nth-child(3) { animation-delay: 0.3s; }

@keyframes thinkingPulse {
  0%, 100% { transform: translateY(0); opacity: 0.6; }
  50% { transform: translateY(-4px); opacity: 1; }
}

.chat-row.me .chat-bubble {
  background: linear-gradient(140deg, rgba(167, 139, 250, 0.9), rgba(149, 122, 241, 0.88));
  border-color: rgba(190, 167, 255, 0.86);
  color: #ffffff;
  box-shadow: 0 6px 14px rgba(110, 88, 167, 0.14);
}

.chat-row.me .chat-md a {
  color: #eef2ff;
}

.chat-row.me .chat-md code {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.22);
  color: #f8fafc;
}

.chat-row.me .chat-md blockquote {
  border-left-color: rgba(255, 255, 255, 0.34);
  color: rgba(255, 255, 255, 0.9);
}

.chat-avatar {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: #ffffff;
  background: linear-gradient(145deg, #8f7ae9, #7c61dd);
  border: 0;
  box-shadow: 0 4px 10px rgba(70, 60, 99, 0.08);
  flex-shrink: 0;
  align-self: start;
  overflow: hidden;
}

.chat-avatar--bot {
  grid-column: 1;
  transform: rotate(-1.5deg);
}

.chat-avatar--user {
  grid-column: 3;
  transform: rotate(1.5deg);
}

.chat-avatar-img {
  object-fit: cover;
}

.chat-meta {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 4px;
  margin-bottom: 0;
  font-weight: 700;
  letter-spacing: 0.045em;
  text-transform: uppercase;
}

.chat-time-row {
  width: 100%;
  display: flex;
  justify-content: center;
  margin: 6px 0;
}

.chat-time-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 10px;
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: rgba(100, 116, 139, 0.82);
  background: rgba(255, 255, 255, 0.52);
  border: 1px solid rgba(255, 255, 255, 0.66);
  backdrop-filter: blur(8px);
}

.hide-timestamps .chat-meta,
.hide-timestamps .chat-time-row {
  display: none;
}

.chat-row--inline > div:not(.chat-avatar-stack) {
  max-width: 90%;
}

.chat-row--inline.is-expanded > div:not(.chat-avatar-stack) {
  max-width: 100%;
}

.chat-row--inline .chat-meta {
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.055em;
  color: var(--text-muted);
}

.chat-inline {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  padding: 1px 0;
  border-radius: 0;
  font-size: 12px;
  line-height: 1.45;
  background: transparent;
  color: var(--text-sub);
  border: none;
  white-space: nowrap;
  word-break: normal;
  font-family: var(--font-body);
  opacity: 0.92;
  max-width: 100%;
}

.chat-inline--meta {
  color: #475569;
}

.chat-inline--tool {
  color: #4338ca;
}

.chat-inline--warning {
  color: #c2410c;
}

.chat-inline--error {
  color: #b91c1c;
}

.chat-inline--app-error {
  color: #dc2626;
  font-weight: 600;
}

.chat-inline-badge {
  display: inline-flex;
  align-items: center;
  padding: 0;
  border-radius: 0;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: transparent;
  color: #70798d;
  border: none;
}

.chat-inline-badge::after {
  content: ":";
  margin-left: 4px;
  color: inherit;
}

.chat-inline-badge--tool {
  color: #4f46e5;
}

.chat-inline-badge--warning {
  color: #b45309;
}

.chat-inline-badge--meta {
  color: #64748b;
}

.chat-inline-badge--error,
.chat-inline-badge--app-error {
  color: #b91c1c;
}

.chat-inline--tool .chat-inline-text {
  color: #3730a3;
}

.chat-inline--warning .chat-inline-text {
  color: #9a3412;
}

.chat-inline--error .chat-inline-text,
.chat-inline--app-error .chat-inline-text {
  color: #991b1b;
}

.chat-inline-text {
  vertical-align: middle;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
  font-size: 12px;
  font-weight: 500;
}

.chat-inline-toggle {
  background: transparent;
  border: none;
  color: #6b7280;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
  padding: 0;
  opacity: 0.8;
  text-underline-offset: 2px;
}

.chat-inline-toggle:hover {
  opacity: 1;
  text-decoration: underline;
}

.chat-inline-full {
  margin-top: 4px;
  padding: 2px 0 0 10px;
  border-radius: 0;
  background: transparent;
  border: none;
  border-left: 2px solid rgba(148, 163, 184, 0.42);
  font-size: 11px;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
  color: inherit;
}

.chat-inline.is-expanded {
  white-space: normal;
  opacity: 0.9;
}

.chat-inline.is-expanded {
  width: 100%;
  max-width: 100%;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.chat-inline.is-expanded .chat-inline-full {
  width: 100%;
  box-sizing: border-box;
}

.chat-structured {
  background: white;
  border-radius: 16px;
  border: 1px solid var(--border-light);
  padding: 12px 14px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.04);
}

.chat-structured--info {
  border-color: rgba(148, 163, 184, 0.4);
  background: rgba(248, 250, 252, 0.9);
}

.chat-structured--warning {
  border-color: rgba(251, 146, 60, 0.5);
  background: rgba(255, 237, 213, 0.55);
}

.chat-structured--error {
  border-color: rgba(248, 113, 113, 0.5);
  background: rgba(254, 226, 226, 0.6);
}

.chat-structured-title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-sub);
  margin-bottom: 6px;
}

.chat-structured-subtitle {
  font-size: 13px;
  color: var(--text-main);
  margin-bottom: 8px;
}

.chat-structured-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.chat-structured-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
  color: var(--text-sub);
}

.chat-structured-label {
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.chat-structured-value {
  color: var(--text-main);
  text-align: right;
  word-break: break-word;
}

.chat-structured-raw {
  margin-top: 8px;
  font-size: 11px;
  color: var(--text-muted);
}

.chat-structured-raw summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--text-sub);
}

.chat-structured-raw pre {
  margin: 8px 0 0;
  padding: 8px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.04);
  border: 1px solid rgba(148, 163, 184, 0.25);
  font-family: "JetBrains Mono", "Fira Code", monospace;
  font-size: 11px;
  white-space: pre-wrap;
}

.chat-muted {
  text-align: center;
  font-size: 11px;
  color: var(--text-muted);
  opacity: 0.5;
  padding: 2px 0;
  line-height: 1.4;
}

.chat-composer {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 11px 13px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.86);
  border-radius: 18px;
  box-shadow: 0 6px 14px rgba(68, 57, 96, 0.08);
  backdrop-filter: blur(14px);
}

.chat-composer--template {
  grid-template-columns: auto 1fr auto auto;
  gap: 8px;
  padding: 10px 10px 10px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.84);
  left: 0;
  right: 0;
  width: min(340px, calc(100% - 28px));
  margin-left: auto;
  margin-right: auto;
  transform: none;
}

.composer-icon-btn {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: #9aa3b6;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.composer-icon-btn i {
  width: 17px;
  height: 17px;
}

.composer-send-btn {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid rgba(198, 182, 255, 0.8);
  background: rgba(255, 255, 255, 0.86);
  color: #9a7ef2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 12px rgba(90, 70, 150, 0.08);
  cursor: pointer;
}

.composer-send-btn i {
  width: 17px;
  height: 17px;
}

.chat-composer input {
  border: none;
  outline: none;
  background: transparent;
  font-size: 14px;
  color: var(--text-main);
}

/* Lobsters config drawer */
.config-backdrop,
.contacts-backdrop,
.share-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(45, 38, 68, 0.28);
  backdrop-filter: blur(2px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0.2s ease;
  z-index: 30;
}

.config-backdrop {
  z-index: 170;
}

.config-backdrop.active,
.contacts-backdrop.active,
.share-backdrop.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.contacts-drawer,
.share-drawer {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-bottom: none;
  border-radius: 28px 28px 0 0;
  padding: 18px 20px calc(var(--nav-clearance) + 24px);
  max-height: calc(100% - 24px);
  overflow-y: auto;
  box-shadow: 0 -10px 24px rgba(49, 40, 78, 0.12);
  backdrop-filter: blur(20px);
  transform: translateY(100%);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.25s ease, opacity 0.2s ease, visibility 0.2s ease;
  z-index: 40;
  pointer-events: none;
}

.contacts-drawer.active {
  transform: translateY(0%);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.share-drawer.active {
  transform: translateY(0%);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.wizard-step {
  display: flex;
  flex-direction: column;
  height: 100%;
  animation: fadeIn 0.3s ease;
}

.wizard-step[hidden] {
  display: none !important;
}

.wizard-qr-stage {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.wizard-qr-video-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  border: 1px solid rgba(227, 232, 243, 0.95);
  background: radial-gradient(circle at 24% 22%, rgba(255, 255, 255, 0.9), rgba(238, 243, 252, 0.82));
  min-height: 230px;
}

.wizard-qr-video {
  width: 100%;
  height: min(58vw, 290px);
  min-height: 230px;
  display: block;
  object-fit: cover;
  background: #f5f8fc;
}

.wizard-qr-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 14px;
  pointer-events: none;
}

.wizard-qr-overlay::before {
  content: "";
  position: absolute;
  width: min(62vw, 200px);
  height: min(62vw, 200px);
  border-radius: 16px;
  border: 2px solid rgba(255, 255, 255, 0.8);
  box-shadow: 0 0 0 999px rgba(17, 24, 39, 0.2);
}

.wizard-qr-overlay span {
  position: relative;
  z-index: 1;
  font-size: 11px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  font-weight: 700;
  color: #f8fbff;
  text-shadow: 0 1px 2px rgba(17, 24, 39, 0.4);
}

.wizard-qr-hint {
  margin-top: 2px;
}

.wizard-qr-actions {
  justify-content: flex-start;
  flex-wrap: wrap;
}

.share-step {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 100%;
  animation: fadeIn 0.3s ease;
}

.share-step[hidden] {
  display: none !important;
}

.share-warning-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(248, 113, 113, 0.22);
  background: linear-gradient(165deg, rgba(255, 246, 247, 0.95), rgba(255, 255, 255, 0.86));
}

.share-warning-card .wizard-icon-box {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: rgba(248, 113, 113, 0.14);
  color: #b91c1c;
}

.share-warning-card .wizard-icon-box i,
.share-warning-card .wizard-icon-box svg {
  width: 22px;
  height: 22px;
}

.share-warning-copy {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.share-warning-copy strong {
  font-size: 13px;
  font-weight: 800;
  color: var(--text-main);
}

.share-warning-copy p {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
  color: #6f7789;
}

.share-qr-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 14px;
  border-radius: 20px;
  border: 1px solid rgba(226, 231, 240, 0.9);
  background: rgba(255, 255, 255, 0.72);
  position: relative;
}

.share-qr-image {
  width: min(76vw, 260px);
  height: min(76vw, 260px);
  border-radius: 16px;
  border: 1px solid rgba(226, 231, 240, 0.9);
  background: rgba(255, 255, 255, 0.95);
  padding: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

.share-qr-panel.is-loading .share-qr-image {
  opacity: 0.4;
  filter: grayscale(0.6);
}

.share-qr-panel.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at center, rgba(255,255,255,0.85) 0%, rgba(255,255,255,0.65) 45%, rgba(255,255,255,0.15) 70%, transparent 100%);
  border-radius: 20px;
  pointer-events: none;
  animation: share-qr-pulse 1s ease-in-out infinite;
}

@keyframes share-qr-pulse {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.02); opacity: 0.65; }
  100% { transform: scale(1); opacity: 1; }
}

.share-payload-row {
  gap: 8px;
}

.share-payload {
  margin: 0;
  border-radius: 14px;
  border: 1px solid rgba(226, 231, 240, 0.95);
  background: rgba(247, 249, 253, 0.92);
  padding: 10px;
  font-size: 10px;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
  color: #667085;
  max-height: 120px;
  overflow: auto;
}

.wizard-options {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 10px 0;
}

.wizard-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 24px;
  text-align: left;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.04);
  width: 100%;
}

.wizard-card:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 16px rgba(100, 90, 140, 0.08);
  border-color: rgba(167, 139, 250, 0.4);
}

.wizard-card:active {
  transform: scale(0.98);
}

.wizard-icon-box {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  background: rgba(167, 139, 250, 0.12);
  color: #8b5cf6;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.wizard-card:hover .wizard-icon-box {
  transform: scale(1.1) rotate(-3deg);
  background: rgba(167, 139, 250, 0.2);
}

.wizard-icon-box i,
.wizard-icon-box svg {
  width: 28px;
  height: 28px;
  stroke-width: 2;
}

.wizard-card-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.wizard-card h4 {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.01em;
}

.wizard-card p {
  margin: 0;
  font-size: 13px;
  color: var(--text-sub);
  font-weight: 500;
}

.config-drawer {
  position: absolute;
  inset: 0;
  width: 100%;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(235, 238, 247, 0.9);
  border-radius: 0;
  overflow: hidden;
  box-shadow: -8px 0 20px rgba(49, 40, 78, 0.1);
  backdrop-filter: blur(20px);
  transform: translateX(112%);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.25s ease, opacity 0.2s ease, visibility 0.2s ease;
  z-index: 180;
  pointer-events: none;
}

.config-drawer.active {
  transform: translateX(0%);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.config-main-view {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  padding: calc(var(--safe-top) + 16px) 18px calc(var(--nav-clearance) + 18px);
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.config-main-view::-webkit-scrollbar {
  display: none;
}

.config-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.config-drawer-header h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 30px;
  line-height: 1;
  letter-spacing: -0.01em;
  text-align: center;
  flex: 1;
}

.config-drawer-header .page-title {
  font-size: 22px;
  justify-content: center;
  text-align: center;
}

.config-header-spacer {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.config-profile-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  position: relative;
  border-radius: 25px;
  width: calc(100% - 8px);
  margin-inline: auto;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 3px 8px rgba(60, 49, 89, 0.07);
  cursor: pointer;
  transition: transform 0.14s ease, box-shadow 0.2s ease;
}

.config-profile-card:hover {
  transform: translateY(-0.5px);
  box-shadow: 0 6px 13px rgba(60, 49, 89, 0.09);
}

.config-profile-card:focus-visible {
  outline: 2px solid rgba(141, 121, 242, 0.5);
  outline-offset: 2px;
}

.config-profile-avatar {
  width: 78px;
  height: 78px;
  border-radius: 24px;
  border: 2px solid rgba(255, 255, 255, 0.92);
  background: #dbeafe;
  object-fit: cover;
  box-shadow: 0 6px 12px rgba(69, 57, 97, 0.08);
}

.config-profile-copy h4 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 26px;
  letter-spacing: -0.01em;
  color: #232a3a;
}

.config-profile-copy p {
  margin: 4px 0 0;
  font-size: 11px;
  letter-spacing: 0.09em;
  font-weight: 800;
  text-transform: uppercase;
  color: #8f95ab;
}

.config-profile-share-btn {
  position: absolute;
  top: calc(50% - 16px);
  right: 44px;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 12px;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.9);
  color: #9099ad;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: none;
  transition: transform 0.16s ease, box-shadow 0.18s ease, background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.config-profile-share-btn:hover {
  transform: translateY(calc(-50% - 2px));
  background: rgba(255, 255, 255, 0.98);
  border-color: transparent;
  color: #6f7a92;
  box-shadow: 0 6px 14px rgba(73, 84, 114, 0.16);
}

.config-profile-share-btn:active {
  transform: translateY(-50%);
  box-shadow: 0 2px 6px rgba(73, 84, 114, 0.1);
}

.config-profile-share-btn i,
.config-profile-share-btn svg {
  width: 28px;
  height: 28px;
}

.config-profile-enter {
  margin-left: auto;
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #9aa3b6;
}

.config-helper--profile-jump {
  margin: 8px 2px 6px;
}

.config-profile-subpage {
  position: absolute;
  inset: 0;
  padding: calc(var(--safe-top) + 16px) 18px calc(var(--nav-clearance) + 18px);
  background: linear-gradient(180deg, rgba(244, 247, 253, 0.98) 0%, rgba(232, 237, 247, 0.98) 100%);
  border-radius: 0;
  box-shadow: inset 0 -18px 36px rgba(44, 37, 67, 0.08);
  backdrop-filter: blur(20px);
  transform: translateX(108%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: transform 0.24s ease, opacity 0.2s ease, visibility 0.2s ease;
  z-index: 5;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.config-profile-subpage::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: calc(var(--nav-clearance) + 18px);
  background: linear-gradient(180deg, rgba(230, 236, 247, 0) 0%, rgba(216, 223, 237, 0.78) 100%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 0;
}

.config-profile-subpage > * {
  position: relative;
  z-index: 1;
}

.config-profile-subpage.active {
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.config-profile-subpage.active::after {
  opacity: 0.72;
}

.config-profile-history-sync {
  gap: 8px;
  padding: 0;
  border-radius: 0;
  width: 100%;
  margin-inline: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.config-profile-history-sync .config-section-title {
  color: #8f98af;
  letter-spacing: 0.14em;
}

.config-profile-history-sync .config-helper {
  margin: 0;
  color: #7e879c;
}

.config-actions--history-sync {
  margin-top: 2px;
  gap: 8px;
}

.config-actions--history-sync .pill-btn {
  min-height: 40px;
}

.config-profile-history-sync .config-meta {
  margin: 2px 0 0;
}

.config-profile-path-settings {
  gap: 8px;
  padding: 0;
  border-radius: 0;
  width: 100%;
  margin-inline: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.config-profile-path-settings .config-section-title {
  color: #8f98af;
  letter-spacing: 0.14em;
}

.config-profile-path-settings .config-helper {
  margin: 0;
  color: #7e879c;
}

.config-profile-path-settings .path-settings-list {
  margin: 2px 0 0;
}

.config-pill-tabs {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  overflow-x: auto;
  scrollbar-width: none;
}

.config-pill-tabs::-webkit-scrollbar {
  display: none;
}

.config-pill-tab {
  white-space: nowrap;
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.95);
  color: #929ab0;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.config-pill-tab.active {
  background: linear-gradient(145deg, #a78bfa, #8d79f2);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 6px 12px rgba(128, 104, 214, 0.16);
}

.config-note-card {
  margin-top: 12px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.74);
  padding: 18px 18px 60px;
  box-shadow: 0 6px 12px rgba(128, 104, 214, 0.16);
  position: relative;
}

.config-note-title {
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #9aa3b6;
}

.config-note-card pre {
  margin: 0;
  font-size: 12px;
  line-height: 1.55;
  color: #566074;
  white-space: pre-wrap;
  font-family: "JetBrains Mono", "Fira Code", monospace;
}

.config-note-save {
  position: absolute;
  right: 16px;
  bottom: 16px;
  width: 28px;
  height: 28px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f6f7fb;
  color: #4b5563;
  border: 1px solid #dfe3ed;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.06);
  cursor: pointer;
  transition: transform 0.1s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.config-note-save:hover {
  background: #eff2f8;
  border-color: #d1d7e4;
  color: #1f2937;
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.08);
}

.config-note-save:active {
  transform: translateY(1px) scale(0.99);
}

.config-advanced {
  display: none;
}

.config-advanced.active {
  display: block;
}

.config-helper {
  font-size: 11px;
  color: var(--text-sub);
  margin: 0 0 10px;
  line-height: 1.45;
}

.config-helper--center {
  text-align: center;
}

.config-helper-link {
  border: none;
  background: transparent;
  padding: 0;
  color: #4f46e5;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

.config-helper-link:hover {
  color: #4338ca;
}

.config-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.config-section--collapsible {
  gap: 12px;
}

.config-section-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  font-weight: 800;
  color: var(--text-main);
  cursor: pointer;
  box-shadow: var(--shadow-soft);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.config-section-toggle:hover {
  box-shadow: 0 10px 20px rgba(68, 57, 96, 0.1);
}

.config-section-toggle i {
  transition: transform 0.2s ease;
}

.config-section-toggle[aria-expanded="true"] i {
  transform: rotate(180deg);
}

.config-section-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.config-section-body[hidden] {
  display: none;
}

.config-section-title {
  margin: 0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #9aa3b6;
}

.config-section-title--spaced {
  margin-bottom: 10px;
}

.path-settings-list {
  margin: 0 0 10px;
  padding-top: 1px;
  border-top: none;
  border-bottom: none;
}

.path-settings-list .settings-group {
  border-bottom: none;
  margin-bottom: 8px;
}

.path-settings-list .settings-group:last-child {
  margin-bottom: 0;
}

.path-settings-list--profile .settings-group {
  margin-bottom: 10px;
}

.path-settings-list .settings-row {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 2px 6px rgba(72, 60, 101, 0.04);
}

.path-settings-list--profile .settings-row {
  border-radius: 16px;
  border: 1px solid rgba(229, 236, 247, 0.95);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 5px 10px rgba(62, 55, 90, 0.07);
  transition: transform 0.16s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.path-settings-list--profile .settings-row:hover {
  transform: translateY(-1px);
  border-color: rgba(210, 221, 239, 0.96);
  box-shadow: 0 9px 18px rgba(69, 62, 100, 0.1);
}

.path-settings-list--profile .settings-row:active {
  transform: translateY(0);
}

.path-settings-list .settings-row::after {
  display: none;
}

.path-settings-list .settings-row:active {
  transform: translateY(1px);
  background: rgba(255, 255, 255, 0.58);
}

.config-profile-path-settings .path-settings-list--profile .settings-row:active {
  transform: translateY(0);
}

.path-settings-list .settings-group[data-mode-locked="true"] .settings-row {
  opacity: 0.72;
}

.path-settings-list .settings-row-left {
  gap: 10px;
}

.path-settings-list .settings-group[data-section="beacon-direct-mode"] > .settings-row .settings-row-left,
.path-settings-list .settings-group[data-section="beacon-terrabus-mode"] > .settings-row .settings-row-left {
  padding-left: 8px;
}

.path-settings-list .settings-row-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  border: 1px solid rgba(203, 210, 223, 0.8);
  background: rgba(255, 255, 255, 0.32);
  color: #8c95a8;
}

.path-settings-list .settings-row-icon[data-tone="gray"] {
  color: #64748b;
}

.path-settings-list .settings-row-icon[data-tone="violet"] {
  color: #7b5fe3;
}

.path-settings-list .settings-row-text strong {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.005em;
  color: #4b5563;
}

.config-profile-path-settings .path-settings-list--profile [data-cli-path-input],
.config-profile-path-settings .path-settings-list--profile [data-skills-path-input] {
  border-color: rgba(223, 232, 245, 0.95);
  background: rgba(255, 255, 255, 0.82);
}

.path-settings-list .settings-row-text span {
  font-size: 11px;
  color: #97a0b2;
}

.path-settings-list .settings-details-body {
  padding: 6px 12px 10px 30px;
  border-top: none;
  background: transparent;
}

.path-settings-list--profile .settings-details-body {
  margin: 6px 2px 2px;
  padding: 8px 12px 12px 24px;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(246, 250, 255, 0.8), rgba(237, 244, 255, 0.62));
}

[data-beacon-terrabus-body].settings-details-body {
  padding-right: 20px;
}

.path-settings-list .settings-details-body.is-mode-locked {
  opacity: 0.52;
  filter: grayscale(0.18);
}

.path-settings-list .settings-details-body.is-mode-locked input,
.path-settings-list .settings-details-body.is-mode-locked textarea,
.path-settings-list .settings-details-body.is-mode-locked select,
.path-settings-list .settings-details-body.is-mode-locked button {
  cursor: not-allowed;
}

.path-settings-list .settings-details-body .config-helper {
  margin: 0 0 8px;
}

.path-settings-list [data-cli-path-input],
.path-settings-list [data-skills-path-input] {
  padding: 12px 13px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  font-size: 13px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  color: #4b5563;
}

.path-settings-list [data-cli-path-input]:focus,
.path-settings-list [data-skills-path-input]:focus {
  outline: none;
  border-color: rgba(167, 139, 250, 0.6);
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.14);
}

.path-settings-list .settings-details-body .config-actions {
  justify-content: flex-start;
  gap: 8px;
}

.path-settings-list .settings-details-body .config-actions .pill-btn {
  flex: 0 0 auto;
  min-width: 136px;
  padding: 8px 12px;
}

.config-info-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.92);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 6px 12px rgba(60, 49, 89, 0.08);
}

.config-info-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(237, 233, 254, 0.92);
  color: #7c63de;
  flex-shrink: 0;
}

.config-info-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.config-info-copy strong {
  font-size: 14px;
  color: #2a3244;
  font-family: var(--font-display);
}

.config-info-copy small {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #97a0b4;
  font-weight: 700;
}

.config-info-badge {
  margin-left: auto;
  padding: 7px 10px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #0f9f47;
  background: rgba(187, 247, 208, 0.72);
}

.config-divider {
  height: 1px;
  background: var(--border-light);
  margin: 16px 0;
}

.config-row {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-bottom: 0px;
}

.config-row--terrabus-beacon-id {
  margin-bottom: 12px;
}

.config-row label {
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
}

.config-value {
  width: 100%;
  min-width: 0;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(226, 231, 240, 0.9);
  background: rgba(255, 255, 255, 0.8);
  font-size: 12px;
  font-weight: 600;
  color: #4b5563;
  overflow-wrap: anywhere;
}

.config-row input {
  width: 100%;
  min-width: 0;
  padding: 12px 13px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  font-size: 13px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.config-row input:focus {
  outline: none;
  border-color: rgba(167, 139, 250, 0.6);
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.14);
}

.config-avatar-row {
  margin-top: 2px;
}

.config-avatar-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border: 1px solid rgba(226, 231, 240, 0.9);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.52);
}

.config-avatar-preview {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.92);
  object-fit: cover;
  background: #dbeafe;
  box-shadow: 0 4px 8px rgba(69, 57, 97, 0.08);
}

.config-avatar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.config-avatar-actions .pill-btn {
  flex: 0 0 auto;
  min-width: 120px;
  padding: 8px 12px;
}

.config-meta {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: var(--text-sub);
  background: rgba(239, 233, 255, 0.82);
  border: 1px solid rgba(216, 204, 255, 0.7);
  border-radius: 14px;
  padding: 10px 12px;
  margin-bottom: 16px;
  width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
}

.config-meta strong {
  color: var(--text-main);
}

.config-meta[data-tone="ok"] {
  color: #047857;
  background: rgba(209, 250, 229, 0.86);
}

.config-meta[data-tone="error"] {
  color: #b91c1c;
  background: rgba(254, 226, 226, 0.9);
}

.config-actions {
  display: flex;
  gap: 10px;
  margin-top: 0px;
}

.config-actions--single {
  justify-content: center;
}

.config-actions--single .pill-btn {
  flex: 0 1 220px;
}

.config-actions .pill-btn {
  flex: 1;
}

.config-actions--danger .pill-btn {
  flex: 1;
}

/* Terminal feed entries */
.terminal-entry {
  background: rgba(255, 255, 255, 0.68);
  border: 1px solid rgba(255, 255, 255, 0.88);
  border-radius: 20px;
  padding: 13px 15px;
  box-shadow: 0 4px 10px rgba(68, 57, 96, 0.06);
  backdrop-filter: blur(14px);
  text-align: left;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.22s ease;
}

.terminal-entry:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(61, 46, 90, 0.1);
}

.terminal-entry-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.terminal-entry-title {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text-main);
  font-size: 13px;
}

.terminal-entry-time {
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.terminal-entry-preview {
  font-size: 12px;
  color: var(--text-sub);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lobster-card {
  background: white;
  border-radius: 24px;
  padding: 16px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-soft);
  transition: transform 0.1s;
}

.lobster-card:active {
  transform: scale(0.98);
}

.lobster-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.lobster-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.lobster-info h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}

.lobster-meta {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.lobster-content {
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-sub);
  margin-bottom: 12px;
}

.lobster-actions {
  display: flex;
  gap: 16px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
}

.action-item {
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: color 0.2s;
}
.action-item:hover { color: var(--accent-pink); }

/* Skills View */

.skills-search {
  position: relative;
  width: clamp(112px, 30vw, 138px);
  height: 36px;
  flex: 0 0 auto;
}

.skills-search-trigger {
  position: absolute;
  inset: 0;
  height: 36px;
  border: 1px solid rgba(148, 163, 184, 0.34);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.74);
  color: #646f88;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 12px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.94);
  cursor: pointer;
  transition: transform 0.08s ease, border-color 0.16s ease, color 0.16s ease, background 0.16s ease, opacity 0.12s ease;
}

.skills-search-trigger:active {
  transform: scale(0.96);
}

.skills-search.is-open .skills-search-trigger {
  border-color: rgba(129, 140, 248, 0.48);
  color: #4f46e5;
  background: rgba(236, 239, 255, 0.76);
}

.skills-search-trigger i,
.skills-search-trigger svg {
  width: 14px;
  height: 14px;
  stroke-width: 2.2;
}

.skills-search-field {
  position: absolute;
  inset: 0;
  width: 100%;
  opacity: 0;
  pointer-events: none;
  height: 36px;
  border: 1px solid rgba(148, 163, 184, 0.34);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  transition: opacity 0.16s ease, border-color 0.16s ease;
}

.skills-search.is-open .skills-search-field {
  opacity: 1;
  pointer-events: auto;
}

.skills-search.is-open .skills-search-trigger {
  opacity: 0;
  pointer-events: none;
}

.skills-search-field:focus-within {
  border-color: rgba(129, 140, 248, 0.62);
}

.skills-search-field i,
.skills-search-field svg,
.skills-search-clear i,
.skills-search-clear svg {
  width: 14px;
  height: 14px;
  stroke-width: 2.2;
  color: #7d859b;
}

.skills-search-field input {
  border: none;
  outline: none;
  background: transparent;
  color: var(--text-main);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0;
  width: 100%;
}

.skills-search-field input::placeholder {
  color: #9aa2b7;
  font-weight: 500;
}

.skills-search-clear {
  width: 18px;
  height: 18px;
  border: none;
  background: transparent;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #7d859b;
  cursor: pointer;
  border-radius: 999px;
  transition: transform 0.08s ease, color 0.16s ease, background 0.16s ease;
}

.skills-search-clear:active {
  transform: scale(0.92);
}

.skills-search-clear:hover {
  color: #4f46e5;
  background: rgba(129, 140, 248, 0.12);
}

.skills-search:not(.is-open) .skills-search-clear {
  display: none;
}

.skills-search:not(.is-open) .skills-search-field input {
  width: 0;
}

.skills-hub-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 12px 18px 126px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  scrollbar-width: none;
}

.skills-hub-scroll::-webkit-scrollbar {
  display: none;
}

.skills-panel {
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.7);
  box-shadow: 0 6px 16px rgba(69, 57, 99, 0.08);
  backdrop-filter: blur(14px);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.skills-panel--marketplace {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  padding: 0;
  outline: none;
}

.tab-view[data-tab-view="skills"] .skills-panel:not(.skills-panel--marketplace) {
  background: transparent;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
}

.skills-panel--marketplace .skills-panel-head {
  position: relative;
  z-index: 20;
  overflow: visible;
  padding: 2px 14px 0;
}

.skills-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.skills-store-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 0;
  border: none;
  background: transparent;
  color: #7a8398;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
}

.skills-store-link-btn i,
.skills-store-link-btn svg {
  width: 13px;
  height: 13px;
}

.skills-store-link-btn:hover {
  color: #4f46e5;
}

.skills-store-link-btn:active {
  transform: translateY(1px);
}

.skills-store-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(25, 28, 39, 0.2);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 26;
}

.skills-store-backdrop.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.skills-store-page {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(248, 250, 255, 0.98), rgba(241, 245, 255, 0.96));
  transform: translateX(104%);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: transform 0.26s ease, opacity 0.2s ease;
  z-index: 27;
  display: flex;
  flex-direction: column;
}

.skills-store-page.active {
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.skills-store-header {
  padding: calc(var(--safe-top) + 12px) 18px 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(226, 231, 240, 0.82);
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(12px);
}

.skills-store-title-stack {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.skills-store-title-stack span {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #9aa3b6;
}

.skills-store-title-stack h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--text-main);
}

.skills-store-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 14px 18px calc(var(--nav-clearance) + 20px);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.skills-store-scroll::-webkit-scrollbar {
  display: none;
}

.skills-store-feature {
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.88);
  background: linear-gradient(145deg, #5f68f2, #7c5cf0 58%, #9f6cf2);
  color: #f8faff;
  box-shadow: 0 14px 28px rgba(84, 70, 164, 0.22);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.skills-store-feature-eyebrow {
  margin: 0;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.8;
}

.skills-store-feature h4 {
  margin: 0;
  font-size: 22px;
  line-height: 1.06;
  letter-spacing: -0.02em;
}

.skills-store-feature p {
  margin: 0;
  font-size: 12px;
  color: rgba(243, 246, 255, 0.92);
}

.skills-store-feature .skills-store-get {
  margin-top: 6px;
  align-self: flex-start;
}

.skills-store-section {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.skills-store-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.skills-store-section-head h4 {
  margin: 0;
  font-size: 17px;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--text-main);
}

.skills-store-section-head span {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #96a0b5;
}

.skills-store-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.skills-store-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 10px;
  border-radius: 16px;
  border: 1px solid rgba(226, 231, 240, 0.8);
  background: rgba(255, 255, 255, 0.86);
}

.skills-store-rank {
  width: 16px;
  text-align: center;
  font-size: 11px;
  font-weight: 800;
  color: #98a2b6;
}

.skills-store-row-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.92);
  color: #6654de;
  box-shadow: 0 2px 5px rgba(67, 56, 112, 0.12);
}

.skills-store-row-icon[data-tone="blue"] {
  color: #2563eb;
}

.skills-store-row-icon[data-tone="green"] {
  color: #0f9f47;
}

.skills-store-row-icon i,
.skills-store-row-icon svg {
  width: 17px;
  height: 17px;
}

.skills-store-row-copy {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.skills-store-row-copy strong {
  font-size: 13px;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.skills-store-row-copy p {
  margin: 0;
  font-size: 11px;
  color: #778099;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.skills-store-row-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 10px;
  font-weight: 700;
  color: #a0a7bb;
}

.skills-store-get,
.skills-market-get {
  border: 1px solid rgba(129, 140, 248, 0.38);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: #4f46e5;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 7px 11px;
  cursor: pointer;
  transition: border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease, transform 0.1s ease;
}

.skills-store-get:hover,
.skills-market-get:hover {
  border-color: rgba(99, 102, 241, 0.5);
  color: #4338ca;
  box-shadow: 0 2px 6px rgba(79, 70, 229, 0.14);
}

.skills-store-get:active,
.skills-market-get:active {
  transform: translateY(1px);
}

.skills-store-get.is-open,
.skills-market-get.is-open {
  border-color: rgba(79, 70, 229, 0.52);
  color: #3730a3;
  box-shadow: 0 2px 8px rgba(79, 70, 229, 0.18);
}

.skills-store-get:disabled,
.skills-market-get:disabled {
  cursor: default;
}

.skills-install-popover {
  position: absolute;
  z-index: 1250;
  min-width: 170px;
  max-width: min(240px, calc(100vw - 20px));
  border-radius: 14px;
  border: 1px solid rgba(180, 191, 219, 0.5);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 14px 32px rgba(54, 68, 100, 0.2);
  padding: 8px;
  opacity: 0;
  transform: translateY(-4px) scale(0.98);
  pointer-events: none;
  transition: opacity 0.14s ease, transform 0.14s ease;
  backdrop-filter: blur(8px);
}

.skills-install-popover.is-open {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.skills-install-popover-title {
  margin: 0;
  padding: 2px 4px 7px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #7f8aa6;
}

.skills-install-popover-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.skills-install-popover-option {
  width: 100%;
  border: 1px solid transparent;
  border-radius: 10px;
  background: rgba(247, 249, 255, 0.72);
  color: #344054;
  font-size: 12px;
  font-weight: 700;
  padding: 7px 8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  text-align: left;
}

.skills-install-popover-option:hover {
  border-color: rgba(129, 140, 248, 0.38);
  background: rgba(238, 242, 255, 0.9);
}

.skills-install-popover-avatar {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  object-fit: cover;
}

.skills-install-popover-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #818cf8;
}

.skills-delete-sheet-backdrop {
  position: absolute;
  inset: 0;
  z-index: 1300;
  background: rgba(15, 23, 42, 0.26);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 14px;
  opacity: 0;
  transition: opacity 0.16s ease;
}

.skills-delete-sheet-backdrop.is-open {
  opacity: 1;
}

.skills-delete-sheet {
  width: min(360px, 100%);
  border-radius: 18px;
  border: 1px solid rgba(208, 216, 235, 0.64);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.22);
  overflow: hidden;
  transform: translateY(14px);
  transition: transform 0.18s ease;
}

.skills-delete-sheet-backdrop.is-open .skills-delete-sheet {
  transform: translateY(0);
}

.skills-delete-sheet-copy {
  padding: 14px 16px;
  text-align: center;
}

.skills-delete-sheet-title {
  margin: 0;
  font-size: 14px;
  font-weight: 800;
  color: #1f2a44;
}

.skills-delete-sheet-detail {
  margin: 6px 0 0;
  font-size: 12px;
  color: #5f6d8b;
  line-height: 1.4;
}

.skills-delete-sheet-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: rgba(224, 231, 255, 0.8);
}

.skills-delete-sheet-btn {
  border: 0;
  background: rgba(255, 255, 255, 0.98);
  color: #4f46e5;
  font-size: 13px;
  font-weight: 700;
  padding: 12px 10px;
  cursor: pointer;
}

.skills-delete-sheet-btn--danger {
  color: #dc2626;
}

.skills-market-actions {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: nowrap;
}

.skills-market-actions--row {
  margin-left: auto;
  margin-top: 0;
}

.skills-library-add-btn {
  border: 1px solid rgba(157, 171, 196, 0.52);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 249, 255, 0.94));
  color: #5a667f;
  padding: 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(64, 75, 103, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.92);
  transition: border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease, transform 0.1s ease;
}

.skills-library-add-btn--icon {
  width: 28px;
  height: 28px;
  min-width: 28px;
  min-height: 28px;
}

.skills-library-add-btn i,
.skills-library-add-btn svg {
  width: 13px;
  height: 13px;
  stroke-width: 2.4;
}

.skills-library-add-btn:hover {
  border-color: rgba(118, 137, 174, 0.62);
  color: #425372;
  box-shadow: 0 2px 6px rgba(64, 75, 103, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.skills-library-add-btn:active {
  transform: translateY(1px);
}

.skills-library-add-btn.is-added {
  border-color: rgba(71, 192, 145, 0.52);
  background: linear-gradient(180deg, rgba(241, 253, 248, 0.98), rgba(230, 250, 241, 0.92));
  color: #067a5f;
  box-shadow: 0 1px 2px rgba(34, 122, 93, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.skills-library-add-btn:disabled {
  cursor: default;
  transform: none;
}

.skills-store-get.is-added,
.skills-market-get.is-added {
  border-color: rgba(148, 163, 184, 0.4);
  color: #64748b;
  background: rgba(241, 245, 249, 0.92);
}

.skills-store-empty {
  margin: 0;
  border-radius: 14px;
  border: 1px dashed rgba(160, 138, 241, 0.35);
  background: rgba(239, 233, 255, 0.36);
  padding: 12px;
  font-size: 11px;
  color: #7f86a1;
}

.skills-kicker {
  margin: 0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #9aa3b6;
}

.skills-panel--library {
  gap: 10px;
}

.skills-panel-head--library {
  align-items: flex-start;
}

.skills-library-headline {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.skills-library-meta {
  margin: 0;
  font-size: 11px;
  font-weight: 600;
  color: #7f86a1;
  letter-spacing: 0.01em;
  line-height: 1.35;
}

.skills-market-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  overflow-y: visible;
  padding: 1px 2px 5px;
  margin-bottom: 0;
  scrollbar-width: none;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.skills-market-row::-webkit-scrollbar {
  display: none;
}

.skills-grid--installed {
  margin-top: 2px;
}

.skills-market-card {
  flex: 0 0 156px;
  min-height: 178px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 2px 8px rgba(69, 57, 99, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.92);
  padding: 9px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  transition: box-shadow 0.18s ease;
}

.skills-market-card[data-tone="indigo"] {
  background: rgba(255, 255, 255, 0.88);
}

.skills-market-card[data-tone="blue"] {
  background: rgba(255, 255, 255, 0.88);
}

.skills-market-card[data-tone="green"] {
  background: rgba(255, 255, 255, 0.88);
}

.skills-market-card:hover {
  transform: none;
  box-shadow: 0 2px 8px rgba(69, 57, 99, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.skills-market-icon {
  width: 40px;
  height: 40px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  color: #7e65de;
  border: 1px solid rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 2px 4px rgba(73, 61, 103, 0.08);
}

.skills-market-icon svg,
.skills-market-icon i {
  width: 18px;
  height: 18px;
  stroke-width: 2.2;
}

.skills-market-name {
  font-size: 13px;
  font-weight: 800;
  color: var(--text-main);
}

.skills-market-meta {
  display: flex;
  gap: 6px;
  font-size: 10px;
  font-weight: 700;
  color: #8f95ab;
}

.skills-market-get {
  margin-top: auto;
}

.status-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}

.status-dropdown {
  border-top: 1px solid rgba(226, 231, 240, 0.75);
  padding: 8px 12px 14px;
  background: rgba(248, 250, 255, 0.8);
  transition: max-height 0.25s ease, opacity 0.2s ease;
  overflow: hidden;
}

.status-dropdown[hidden] {
  display: block;
  max-height: 0;
  opacity: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.status-dropdown-inner {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px 8px;
}

.skills-empty {
  grid-column: 1 / -1;
  border-radius: 14px;
  border: 1px dashed rgba(160, 138, 241, 0.35);
  background: rgba(239, 233, 255, 0.36);
  padding: 12px;
  font-size: 11px;
  color: #7f86a1;
}

.skill-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: transform 0.1s ease;
  width: 100%;
  max-width: 78px;
  margin: 0 auto;
}

.skill-chip .skill-status-pill {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.15);
  color: var(--text-sub);
}

.skill-chip[data-status="ready"] .skill-status-pill {
  background: rgba(16, 185, 129, 0.12);
  color: #0f766e;
}

.skill-chip[data-status="error"] .skill-status-pill {
  background: rgba(248, 113, 113, 0.15);
  color: #b91c1c;
}

.skill-chip[data-status="pending"] .skill-status-pill {
  background: rgba(251, 191, 36, 0.18);
  color: #92400e;
}

.skill-icon-box .skill-initial {
  font-weight: 800;
  font-size: 16px;
  color: var(--accent-violet);
}

.skill-icon-box .skill-emoji {
  font-size: 20px;
  line-height: 1;
}

.skill-icon-box .skill-fallback-icon {
  width: 20px;
  height: 20px;
  color: #5c55d9;
  stroke-width: 2.2px;
}
.skill-chip:hover { transform: none; }

.skill-chip:active { transform: scale(0.97); }

.skill-icon-box {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
  border: 1px solid white;
  box-shadow: var(--shadow-soft);
  position: relative;
  overflow: hidden;
  transition: shadow 0.2s;
}

.skill-chip:hover .skill-icon-box {
  box-shadow: var(--shadow-soft);
}

.gloss-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(to bottom, rgba(255,255,255,0.5), transparent);
  pointer-events: none;
}

.skill-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-sub);
  text-align: center;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
}

.skills-upload-card {
  margin: 0;
  padding: 15px;
  border-radius: 22px;
  border: none;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.skills-upload-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.skills-upload-header h3 {
  margin: 0 0 4px;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: var(--text-main);
}

.skills-upload-header p {
  margin: 0;
  font-size: 12px;
  color: var(--text-sub);
}

.skills-upload-body {
  border-radius: 18px;
  border: 1px dashed rgba(156, 129, 239, 0.55);
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(159, 134, 245, 0.08);
  cursor: pointer;
}

.skills-upload-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(236, 228, 255, 0.95), rgba(255, 255, 255, 0.92));
  color: #7e65de;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 6px 14px rgba(73, 61, 103, 0.1);
}

.skills-upload-icon svg,
.skills-upload-icon i {
  width: 20px;
  height: 20px;
  stroke-width: 2.2;
}

.skills-upload-text span {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-main);
}

.skills-upload-text small {
  font-size: 11px;
  color: var(--text-sub);
}

.skills-upload-status {
  font-size: 11px;
  color: var(--text-muted);
}

.skills-upload-status[data-tone="ready"] {
  color: #0f766e;
}

.skills-upload-status[data-tone="idle"] {
  color: var(--text-muted);
}

.skills-upload-error {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(248, 113, 113, 0.45);
  background: rgba(254, 226, 226, 0.55);
  color: #b91c1c;
  font-size: 12px;
}

.skills-upload-error strong {
  font-size: 12px;
  display: block;
  margin-bottom: 4px;
}

.skills-upload-error p {
  margin: 0;
  color: #b45309;
  font-size: 11px;
}

.skills-tab-btn {
  border: 1px solid rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.66);
  border-radius: 14px;
  padding: 9px 10px;
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text-sub);
  box-shadow: 0 8px 22px rgba(73, 61, 103, 0.09);
  cursor: pointer;
  transition: all 0.2s ease;
}

.skills-tab-btn.active {
  background: linear-gradient(145deg, rgba(239, 233, 255, 0.96), rgba(255, 255, 255, 0.92));
  color: #7e65de;
  border-color: rgba(179, 156, 247, 0.62);
  box-shadow: 0 12px 24px rgba(108, 83, 177, 0.18);
}

.skills-tab-btn:active {
  transform: translateY(1px);
}

.icon-btn-circle.loading i {
  animation: spin 0.9s linear infinite;
}

.skill-chip.skeleton {
  cursor: default;
}

.skill-chip.skeleton .skill-icon-box {
  background: #e2e8f0;
  border-color: #e2e8f0;
  box-shadow: none;
}

.skill-chip.skeleton .skill-label {
  width: 56px;
}

.skill-chip.skeleton .skeleton-line {
  height: 10px;
  border-radius: 999px;
  background: #e2e8f0;
  display: inline-block;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Custom Dropzone */
.custom-dropzone {
  margin-top: 16px;
  background: white;
  border: 2px dashed #e2e8f0;
  border-radius: 18px;
  padding: 14px 16px;
  box-shadow: var(--shadow-soft);
  position: sticky;
  bottom: 20px;
  z-index: 1;
  backdrop-filter: blur(20px);
}

.drop-inner {
  display: flex;
  align-items: center;
  gap: 14px;
}

.drop-icon {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: var(--accent-violet-soft);
  color: var(--accent-violet);
  display: grid;
  place-items: center;
}

.drop-text {
  flex: 1;
}

.drop-title {
  margin: 0;
  font-weight: 700;
  color: var(--text-main);
  font-size: 14px;
}

.drop-sub {
  margin: 4px 0 0;
  color: var(--text-sub);
  font-size: 12px;
}

.custom-dropzone input[type="file"] {
  opacity: 0;
  position: absolute;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

/* Logs Tab */
.logs-content {
  padding: 0 18px 120px;
  flex: 1;
  overflow-y: auto;
}

.logs-content .header-glass {
  margin: 0 -18px;
  border-radius: 0;
}

.terminal-beacon-bar {
  margin-top: 10px;
  margin-bottom: 10px;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 10px;
}

.terminal-beacon-label {
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  color: #94a3b8;
}

.terminal-beacon-field {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.terminal-beacon-select {
  width: min(100%, 120px);
  max-width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.34);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.72);
  color: #52617a;
  font-size: 12px;
  font-weight: 500;
  padding: 7px 10px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
}

.terminal-beacon-select:focus-visible {
  outline: 2px solid rgba(99, 102, 241, 0.45);
  outline-offset: 1px;
}

.terminal-beacon-meta {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
  color: #64748b;
}

@media (max-width: 560px) {
  .terminal-beacon-bar {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .terminal-beacon-field {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }

  .terminal-beacon-select {
    width: 100%;
  }

  .terminal-beacon-meta {
    white-space: normal;
    text-overflow: clip;
  }
}

.term-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 4px;
  padding: 4px 0 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.term-tabs::-webkit-scrollbar { display: none; }

.term-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(226, 232, 240, 0.56);
  border: 1px solid rgba(203, 213, 225, 0.78);
  border-bottom-color: rgba(203, 213, 225, 0.52);
  padding: 6px 10px;
  border-radius: 12px 12px 0 0;
  font-size: 11px;
  font-weight: 500;
  color: var(--text-sub);
  cursor: pointer;
  white-space: nowrap;
  margin-bottom: -1px;
}

.term-tab-add {
  padding: 4px 7px;
  min-width: 26px;
  justify-content: center;
  border-radius: 10px 10px 0 0;
  background: rgba(226, 232, 240, 0.42);
}

.term-tab-add:hover {
  background: rgba(167, 139, 250, 0.2);
  color: var(--accent-violet);
}

.term-tab-plus {
  font-size: 16px;
  line-height: 1;
  font-weight: 500;
}

.term-tabs-empty {
  font-size: 11px;
  color: #64748b;
  font-weight: 500;
  margin-right: 2px;
}

.term-tab.active {
  background: #0b1020;
  border-color: rgba(148, 163, 184, 0.5);
  border-bottom-color: #0b1020;
  color: #e2e8f0;
}

.term-tab.dead .term-tab-label {
  opacity: 0.5;
  text-decoration: line-through;
}

.term-tab-close {
  font-size: 14px;
  line-height: 1;
  opacity: 0.4;
  cursor: pointer;
  padding: 0 2px;
}

.term-tab-close:hover {
  opacity: 1;
}

.term-shells {
  flex: 1;
  min-height: 0;
  position: relative;
  margin-top: -2px;
}

.terminal-examples {
  margin-top: 14px;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(196, 184, 232, 0.62);
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.96), rgba(245, 240, 255, 0.9));
  box-shadow:
    0 10px 22px rgba(90, 74, 130, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
  color: #616a82;
  font-size: 12px;
  position: relative;
  overflow: hidden;
}

.terminal-examples::before {
  content: "";
  position: absolute;
  top: -36px;
  right: -24px;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle at center, rgba(167, 139, 250, 0.22), rgba(167, 139, 250, 0));
}

.terminal-examples h3 {
  margin: 0 0 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  text-transform: none;
  letter-spacing: 0.03em;
  color: #7761b4;
  font-weight: 700;
}

.terminal-examples h3::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: linear-gradient(140deg, rgba(167, 139, 250, 0.95), rgba(141, 197, 255, 0.92));
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.16);
}

.terminal-examples ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.terminal-examples li {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: baseline;
  padding: 7px 9px;
  border-radius: 10px;
  border: 1px solid rgba(207, 199, 233, 0.52);
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 2px 8px rgba(84, 65, 128, 0.05);
  line-height: 1.4;
}

.terminal-examples li[data-terminal-quick-command] {
  cursor: pointer;
  user-select: none;
  transition: transform 0.14s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.terminal-examples li[data-terminal-quick-command]:hover {
  transform: translateY(-1px);
  border-color: rgba(167, 139, 250, 0.5);
  box-shadow: 0 6px 12px rgba(84, 65, 128, 0.12);
}

.terminal-examples li[data-terminal-quick-command]:focus-visible {
  outline: 2px solid rgba(99, 102, 241, 0.45);
  outline-offset: 1px;
}

.terminal-examples code {
  font-family: "JetBrains Mono", "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 11px;
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.2), rgba(141, 197, 255, 0.2));
  border: 1px solid rgba(167, 139, 250, 0.34);
  color: #4a3f70;
  padding: 2px 8px;
  border-radius: 999px;
  font-weight: 600;
}

.terminal-shell {
  height: 420px;
  margin-top: 0;
  border-radius: 3px 18px 18px 18px;
  overflow: hidden;
  background: #0b1020;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-top-color: #0b1020;
  position: relative;
  box-shadow: var(--shadow-soft);
}

.terminal-shell::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 18px;
  height: 18px;
  border-top-right-radius: 18px;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0));
}

.terminal-shell .xterm {
  padding: 14px;
}

.terminal-shell .xterm-viewport {
  scrollbar-width: none;
  -ms-overflow-style: none;
  border-top-right-radius: 16px;
  background-color: #0b1020 !important;
}

.terminal-shell .xterm-viewport::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.logs-hint {
  margin: 8px 0 12px;
  color: var(--text-sub);
  font-size: 12px;
}

.logs-feed {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.log-entry {
  background: white;
  border: 1px solid var(--border-light);
  border-radius: 16px;
  padding: 12px 14px;
  box-shadow: var(--shadow-soft);
}

.log-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  gap: 10px;
}

.log-title {
  font-weight: 700;
  color: var(--text-main);
  font-size: 14px;
  margin: 0;
}

.log-time {
  color: var(--text-sub);
  font-size: 11px;
}

.log-body {
  margin: 0;
  color: var(--text-sub);
  font-size: 12px;
  white-space: pre-wrap;
  word-break: break-word;
}

.log-body-block {
  margin: 0;
  font-family: "JetBrains Mono", "Fira Code", monospace;
  font-size: 12px;
  color: var(--text-main);
  white-space: pre-wrap;
  word-break: break-word;
}

.log-empty {
  color: var(--text-sub);
  font-size: 12px;
  text-align: center;
  padding: 12px 0;
}

.log-command-form {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.log-input-shell {
  flex: 1;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 8px;
  background: white;
  border: 1px solid var(--border-light);
  border-radius: 14px;
  padding: 10px 12px;
  box-shadow: var(--shadow-soft);
}

.log-input-shell .prompt {
  color: var(--accent-violet);
  font-weight: 800;
  font-family: "JetBrains Mono", "Fira Code", monospace;
}

.log-input-shell input {
  border: none;
  outline: none;
  font-size: 13px;
  color: var(--text-main);
  background: transparent;
  font-family: "JetBrains Mono", "Fira Code", monospace;
}

.pill-btn {
  background: linear-gradient(140deg, #9a7ef2, #8770eb);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 14px;
  padding: 10px 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
  box-shadow: 0 4px 10px rgba(105, 82, 168, 0.14);
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.pill-btn:active { transform: translateY(1px); }

.pill-btn:hover {
  box-shadow: 0 6px 14px rgba(100, 75, 166, 0.18);
}

.pill-btn.ghost {
  background: rgba(255, 255, 255, 0.62);
  color: #4b5563;
  border: 1px solid rgba(226, 231, 240, 0.9);
  box-shadow: 0 5px 12px rgba(72, 60, 101, 0.08);
}

.pill-btn.danger {
  background: linear-gradient(140deg, #f97373, #ef4444);
  border-color: rgba(255, 255, 255, 0.8);
  box-shadow: 0 4px 10px rgba(239, 68, 68, 0.12);
}

.pill-btn.ghost.danger {
  background: rgba(254, 226, 226, 0.7);
  color: #b91c1c;
  border-color: rgba(248, 113, 113, 0.4);
}

.pill-btn.danger:disabled,
.pill-btn.ghost.danger:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: none;
}

/* Side Log Panel */
.side-panel {
  position: fixed;
  top: 12px;
  right: 12px;
  width: 320px;
  max-width: 80vw;
  height: calc(100% - 24px);
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.88);
  border-radius: 20px;
  box-shadow: 0 22px 54px rgba(39, 30, 62, 0.26);
  transform: translateX(110%);
  transition: transform 0.25s ease;
  display: flex;
  flex-direction: column;
  z-index: 260;
  backdrop-filter: blur(20px);
}

.side-panel.open {
  transform: translateX(0);
}

.gateway-dev-panel {
  width: min(340px, 92vw);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.gateway-dev-meta {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: var(--text-sub);
  padding: 0 12px;
  white-space: pre-line;
}

.gateway-dev-log {
  flex: 1;
  margin: 0 12px 14px;
  padding: 12px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.9);
  font-family: "JetBrains Mono", "Fira Code", monospace;
  font-size: 11px;
  color: var(--text-main);
  overflow-y: auto;
  white-space: pre-wrap;
}

.side-panel-header-glass {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.68);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.9);
}

.header-actions {
  display: flex;
  gap: 10px;
}

.log-tabs {
  flex: 1;
  display: flex;
  gap: 6px;
  overflow-x: auto;
}

.log-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 10px;
  padding: 6px 8px;
  font-size: 12px;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(72, 60, 101, 0.1);
  white-space: nowrap;
}

.log-tab.active {
  background: linear-gradient(145deg, rgba(239, 233, 255, 0.96), rgba(255, 255, 255, 0.92));
  border-color: rgba(179, 156, 247, 0.62);
  color: #7e65de;
}

.log-tab-close {
  font-weight: 800;
  color: var(--text-sub);
  padding-left: 4px;
}

.side-panel-body {
  flex: 1;
  padding: 0 12px 14px;
  overflow-y: auto;
}

/* Hide legacy toast overlays */
#toast-container,
.toast {
  display: none !important;
}

/* Settings View */
.settings-content {
  padding: 0 20px;
  flex: 1;
  overflow-y: auto;
  padding-bottom: calc(var(--nav-clearance) + 20px);
  scrollbar-width: none;
}
.settings-content::-webkit-scrollbar { display: none; }

.settings-content .header-glass {
  margin: 0 -20px;
  border-radius: 0;
}

.settings-section {
  margin-top: 18px;
}

.settings-section-label {
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #9aa3b6;
}

.settings-card {
  background: rgba(255, 255, 255, 0.82);
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 6px 16px rgba(71, 58, 104, 0.06);
  overflow: hidden;
}

.settings-subpage-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(30, 41, 59, 0.15);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease;
  z-index: 30;
}

.settings-subpage {
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
  transform: translateX(100%);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.25s ease, opacity 0.25s ease;
  z-index: 40;
  display: flex;
  flex-direction: column;
  padding-bottom: calc(var(--nav-clearance) + 20px);
  overflow-y: auto;
}

.settings-subpage.active {
  transform: translateX(0);
  opacity: 1;
  visibility: visible;
}

.settings-subpage-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.settings-subpage .header-glass {
  margin: 0;
  padding: calc(var(--safe-top) + 20px) 18px 16px;
  border-bottom: 1px solid rgba(226, 231, 240, 0.75);
  background: rgba(255, 255, 255, 0.94);
  position: sticky;
  top: 0;
  z-index: 1;
  display: block;
}

.settings-subpage-subtitle {
  margin: 6px 0 0;
  font-size: 12.5px;
  line-height: 1.4;
  color: #6c7283;
  text-align: center;
}

.settings-subpage-header {
  margin-top: 6px;
  margin-bottom: 6px;
}

.settings-subpage-header h3 {
  font-size: 24px;
  letter-spacing: -0.01em;
}

.settings-subpage .settings-section {
  margin: 18px 20px 0;
}

.settings-subpage .settings-section-label {
  font-size: 11px;
  letter-spacing: 0.18em;
  color: #9aa3b6;
}

.settings-subpage .config-helper {
  margin: 0 0 14px 12px;
  color: #5f6573;
  font-size: 12.5px;
}

.settings-subpage .settings-card {
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(229, 233, 242, 0.9);
  box-shadow: 0 10px 26px rgba(70, 60, 108, 0.08);
}

.settings-subpage .settings-row {
  padding: 16px 18px;
}

.settings-subpage .settings-row::after {
  left: 72px;
  background: rgba(228, 232, 240, 0.58);
}

.settings-subpage .settings-row-text strong {
  font-size: 14px;
  letter-spacing: 0.01em;
}

.settings-subpage .settings-row-text span {
  font-size: 12px;
  color: #7a8396;
}

.settings-subpage .settings-row-meta {
  font-size: 11px;
  font-weight: 700;
  color: #8a92a5;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.settings-subpage .settings-details-body {
  padding: 16px 18px 18px 78px;
  background: rgba(244, 247, 252, 0.8);
  position: relative;
}

.settings-subpage [data-credential-kind] .settings-details-body {
  padding: 16px 18px 18px;
}

.settings-subpage [data-credential-kind] .settings-details-aside {
  display: none;
}

.settings-credential-warning {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(226, 231, 240, 0.9);
  background: rgba(250, 248, 255, 0.9);
  margin: 12px 14px 14px;
}

.settings-credential-copy strong {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-main);
}

.settings-credential-copy p {
  margin: 4px 0 0;
  font-size: 11px;
  color: #6f7789;
}

.settings-credential-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.settings-credential-actions .pill-btn {
  flex: 1 1 140px;
}

.settings-credential-target-row {
  margin-bottom: 2px;
  gap: 0;
}

.settings-credential-target-row label {
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #8b93a5;
}

.settings-credential-target-row select {
  padding: 12px 13px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  font-size: 13px;
  font-family: var(--font-display);
  background: rgba(255, 255, 255, 0.58);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  color: #4b5563;
}

.settings-credential-target-row select:focus {
  outline: none;
  border-color: rgba(167, 139, 250, 0.6);
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.14);
}

.settings-credential-target-hint {
  margin: 4px 0 0;
  font-size: 11px;
  color: #6f7789;
}

.settings-credential-warning .config-meta {
  margin: 0;
}

.settings-subpage .settings-details-aside {
  position: absolute;
  left: 18px;
  top: 16px;
  display: flex;
  align-items: flex-start;
}

.settings-subpage .settings-sync-btn {
  width: 40px;
  height: 40px;
  border-radius: 13px;
  border: 1px solid rgba(126, 101, 222, 0.2);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 6px 14px rgba(73, 61, 103, 0.1);
  color: #7e65de;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.2s ease, border 0.2s ease;
}

.settings-subpage .settings-sync-btn i {
  width: 18px;
  height: 18px;
  stroke-width: 2.2;
}

.settings-subpage .settings-sync-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(126, 101, 222, 0.35);
  box-shadow: 0 8px 18px rgba(73, 61, 103, 0.12);
}

.settings-subpage .settings-sync-btn:active {
  transform: scale(0.97);
  box-shadow: 0 4px 10px rgba(73, 61, 103, 0.1);
}

.settings-subpage .settings-details-body .config-row {
  margin-bottom: 12px;
}

.settings-subpage .settings-details-body label {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #8d97aa;
}

.settings-subpage .settings-details-body input {
  font-size: 13px;
}

.settings-subpage [data-account-profile-section] .settings-details-body {
  padding: 16px 18px 18px;
}

.settings-subpage [data-account-register-section] .settings-details-body {
  padding: 16px 18px 18px;
}

.settings-section-label--inline {
  margin: 14px 0 8px;
  letter-spacing: 0.1em;
}

.beacon-management-inline-label {
  margin-top: 16px;
}

.beacon-management-slot .settings-empty {
  padding-top: 12px;
}

.skills-management-slot {
  display: flex;
  flex-direction: column;
}

.skills-management-slot--detail {
  padding: 8px 12px 12px;
}

.skills-management-detail-head {
  padding: 14px 16px 6px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.skills-management-detail-meta {
  margin: 0;
  font-size: 12px;
  color: #6f7789;
  font-weight: 600;
}

.settings-row--skills-management-bot {
  gap: 10px;
}

.skills-management-bot-avatar {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, rgba(99, 102, 241, 0.16), rgba(59, 130, 246, 0.12));
  color: #4750c7;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.skills-management-app-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.skills-management-app-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 14px;
  border: 1px solid rgba(224, 231, 245, 0.9);
  background: rgba(255, 255, 255, 0.7);
}

.skills-management-app-row.is-installed {
  cursor: pointer;
}

.skills-management-app-row.is-installed:active {
  transform: translateY(1px);
}

.skills-management-app-icon {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: rgba(125, 142, 236, 0.14);
  color: #4f46e5;
  font-size: 13px;
  font-weight: 800;
  flex-shrink: 0;
}

.skills-management-app-copy {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.skills-management-app-copy strong {
  font-size: 13px;
  font-weight: 800;
  color: var(--text-main);
}

.skills-management-app-copy span {
  font-size: 11px;
  color: #7a8499;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.account-auth-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(215, 224, 238, 0.9);
  background: linear-gradient(135deg, rgba(235, 244, 255, 0.9), rgba(255, 250, 238, 0.9));
}

.account-auth-hero-main h4 {
  margin: 2px 0 3px;
  font-size: 18px;
  line-height: 1.2;
  color: #1f2937;
}

.account-auth-hero-main p {
  margin: 0;
  font-size: 12px;
  color: #5b6477;
}

.account-auth-kicker {
  margin: 0;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-weight: 800;
  color: #67748b;
}

.account-auth-inline {
  display: flex;
  align-items: center;
  gap: 10px;
}

.account-auth-inline--stack {
  flex-direction: column;
  align-items: stretch;
}

.account-auth-inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.account-auth-inline-actions .pill-btn {
  flex: 1 1 140px;
}

.account-auth-social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 10px;
}

.account-auth-social[data-account-auth-logged-in] {
  margin: 10px 0 12px;
}

.account-auth-social .pill-btn {
  flex: 1 1 180px;
}

.account-auth-social .pill-btn i,
.account-auth-social .pill-btn svg {
  width: 14px;
  height: 14px;
}

.config-row textarea {
  resize: vertical;
  min-height: 78px;
  padding: 12px 13px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  font-size: 13px;
  font-family: var(--font-display);
  background: rgba(255, 255, 255, 0.58);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  color: #4b5563;
}

.config-row textarea:focus {
  outline: none;
  border-color: rgba(167, 139, 250, 0.6);
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.14);
}

.settings-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border: none;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}

.settings-row:active {
  transform: scale(0.98);
  background: rgba(255, 255, 255, 0.6);
}

.settings-row--details > summary:active {
  transform: scale(0.98);
  background: rgba(255, 255, 255, 0.6);
}

.settings-row::after {
  content: "";
  position: absolute;
  left: 64px;
  right: 0;
  bottom: 0;
  height: 1px;
  background: rgba(228, 232, 240, 0.58);
}

.settings-empty {
  padding: 14px 16px 16px 64px;
  font-size: 12px;
  color: #9aa2b3;
  font-weight: 600;
}

.settings-row:last-child::after {
  display: none;
}

.settings-group {
  display: block;
}

.settings-group:last-child .settings-row::after {
  display: none;
}

.settings-row[aria-expanded="true"] .lucide-chevron-down {
  transform: rotate(180deg);
}

.settings-row-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.settings-avatar {
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: linear-gradient(150deg, #f8e8ff, #e0dcff);
  color: #5c4bb7;
  font-weight: 800;
  display: grid;
  place-items: center;
  font-size: 14px;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.8);
}

.settings-avatar.has-image {
  background: rgba(255, 255, 255, 0.62);
  box-shadow: inset 0 0 0 1.5px rgba(205, 212, 228, 0.8);
  overflow: hidden;
}

.settings-avatar-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

.settings-row-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(237, 233, 254, 0.48);
  color: #7c6ad6;
}

.settings-row-icon svg {
  width: 18px;
  height: 18px;
  stroke-width: 2.2;
}

.settings-row-icon[data-tone="indigo"] { background: rgba(139, 92, 246, 0.12); color: #6d5bd0; }
.settings-row-icon[data-tone="violet"] { background: rgba(167, 139, 250, 0.13); color: #7b5fe3; }
.settings-row-icon[data-tone="coral"] { background: rgba(251, 113, 133, 0.13); color: #ef5b7d; }
.settings-row-icon[data-tone="mint"] { background: rgba(74, 222, 128, 0.13); color: #22a660; }
.settings-row-icon[data-tone="sky"] { background: rgba(56, 189, 248, 0.13); color: #1d87c9; }
.settings-row-icon[data-tone="gray"] { background: rgba(148, 163, 184, 0.13); color: #64748b; }

.settings-row-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.settings-row-text strong {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 800;
  color: var(--text-main);
}

.settings-row-text span {
  font-family: var(--font-display);
  font-size: 11px;
  color: #9aa2b3;
  font-weight: 600;
}

.settings-row-meta {
  font-size: 12px;
  font-weight: 700;
  color: #9aa2b3;
}

.settings-row-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  color: #9aa2b3;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #cbd5f5;
  box-shadow: 0 0 0 3px rgba(203, 213, 245, 0.35);
}

.status-dot[data-tone="ok"] {
  background: #4ade80;
  box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.22);
}

.status-dot[data-tone="idle"] {
  background: #fbbf24;
  box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.22);
}

.settings-row-pill {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(253, 186, 116, 0.3);
  color: #d97706;
  border: 1px solid rgba(251, 191, 36, 0.45);
}

.settings-row-pill[data-tone="idle"] {
  background: rgba(191, 219, 254, 0.4);
  color: #3b82f6;
  border-color: rgba(147, 197, 253, 0.6);
}

.settings-row-pill[data-tone="ok"] {
  background: rgba(187, 247, 208, 0.45);
  color: #047857;
  border-color: rgba(110, 231, 183, 0.68);
}

.settings-row-pill[data-tone="warn"] {
  background: rgba(254, 240, 138, 0.45);
  color: #b45309;
  border-color: rgba(250, 204, 21, 0.56);
}

.settings-row-pill[data-tone="error"] {
  background: rgba(254, 202, 202, 0.5);
  color: #b91c1c;
  border-color: rgba(248, 113, 113, 0.56);
}

.settings-row-pill--auth {
  display: inline-flex;
  width: fit-content;
  margin-top: 2px;
  padding: 4px 8px;
  font-size: 9px;
}

.settings-row i,
.settings-row svg {
  width: 16px;
  height: 16px;
  color: #c2c7d6;
}

.settings-row--details[open] > summary i,
.settings-row--details[open] > summary svg {
  transform: rotate(90deg);
}

.settings-details-body {
  padding: 12px 16px 16px 72px;
  border-top: 1px solid rgba(226, 231, 240, 0.7);
  background: rgba(248, 250, 255, 0.7);
}

.profile-card {
  background: rgba(255, 255, 255, 0.72);
  border-radius: 24px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 16px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  margin-bottom: 24px;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
  box-shadow: 0 6px 16px rgba(69, 57, 99, 0.08);
  backdrop-filter: blur(14px);
}

.profile-card:active {
  background: rgba(255, 255, 255, 0.86);
  transform: scale(0.98);
}

.profile-avatar img {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  background: #f1f5f9;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.profile-info {
  flex: 1;
  min-width: 0;
}

.profile-info h3 {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 700;
  margin: 0 0 4px;
  color: var(--text-main);
  letter-spacing: -0.01em;
}

.profile-info p {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--text-sub);
  margin: 0;
}

.profile-badge {
  flex-shrink: 0;
  opacity: 0.4;
}
.profile-badge svg { width: 18px; height: 18px; }

/* Profile Editor Panel */
.settings-panel {
  background: rgba(255, 255, 255, 0.74);
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 30px rgba(69, 57, 99, 0.12);
  backdrop-filter: blur(16px);
  padding: 16px 18px 20px;
  margin-bottom: 24px;
  animation: fadeIn 0.2s ease;
}

.settings-panel-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.settings-panel-title {
  flex: 1;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  color: var(--text-main);
}

.pill-btn-sm {
  padding: 6px 14px;
  font-size: 12px;
  border-radius: 10px;
}

.profile-editor-avatar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}

.profile-editor-avatar img {
  width: 80px;
  height: 80px;
  border-radius: 24px;
  background: var(--accent-violet-soft);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.12);
}

.settings-field {
  margin-bottom: 14px;
}

.settings-field label {
  display: block;
  font-size: 10px;
  font-weight: 800;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 6px;
}

.settings-field input {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 14px;
  font-size: 14px;
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.58);
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.settings-field input:focus {
  border-color: rgba(167, 139, 250, 0.6);
  box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.14);
}

/* Settings Groups (rounded card container) */
.settings-group {
  background: rgba(255, 255, 255, 0.72);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 24px rgba(68, 57, 96, 0.1);
  backdrop-filter: blur(12px);
  overflow: hidden;
  margin-bottom: 24px;
}

.settings-group .setting-item {
  border-radius: 0;
  border: none;
  box-shadow: none;
  position: relative;
  padding: 16px;
}

.settings-group .setting-item::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 60px;
  right: 0;
  height: 1px;
  background: var(--border-light);
}

.settings-group .setting-item:last-child::after {
  display: none;
}

.settings-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.setting-toggle,
.setting-item {
  background: transparent;
  border-radius: 16px;
  padding: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: none;
  box-shadow: 0 1px 2px rgba(0,0,0,0.02);
  cursor: pointer;
  transition: background 0.2s;
  min-height: 56px;
  text-align: left;
  width: 100%;
}

.setting-toggle:active,
.setting-item:active {
  transform: none;
  background: rgba(255, 255, 255, 0.5);
}

.setting-left {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  flex: 1;
}

.setting-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.setting-icon svg { width: 20px; height: 20px; }

.setting-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.setting-text strong {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 2px;
}

.setting-text small {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
}


.setting-sub {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-muted);
  margin-top: 1px;
}

.setting-right {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-sub);
  flex-shrink: 0;
}

.setting-value {
  font-size: 13px;
  color: var(--text-sub);
}

.chevron {
  width: 16px;
  height: 16px;
  opacity: 0.4;
}

.setting-item > svg.lucide-chevron-right {
  color: var(--text-sub);
  width: 20px;
  height: 20px;
  opacity: 0.5;
  transition: transform 0.2s ease;
}

/* Stepper Buttons */
.setting-stepper {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.74);
  color: var(--text-main);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.1s;
}

.setting-stepper:active {
  background: rgba(239, 233, 255, 0.88);
}

/* Toggle Pill */
.toggle-pill {
  width: 44px;
  height: 26px;
  border-radius: 99px;
  background: rgba(226, 232, 240, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.85);
  box-shadow: inset 0 1px 2px rgba(44, 31, 79, 0.16);
  position: relative;
  cursor: pointer;
  transition: background 0.25s, border-color 0.25s;
}

.toggle-pill::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 2px 6px rgba(0,0,0,0.14);
  transition: transform 0.25s;
}

.toggle-pill.active {
  background: linear-gradient(140deg, #9a7ef2, #8770eb);
  border-color: rgba(181, 158, 247, 0.72);
}

.toggle-pill.active::after {
  transform: translateX(18px);
}

/* About Card */
.settings-about {
  background: rgba(255, 255, 255, 0.72);
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 30px rgba(69, 57, 99, 0.12);
  backdrop-filter: blur(16px);
  padding: 28px 20px;
  text-align: center;
  margin-bottom: 24px;
}

.about-logo {
  font-size: 32px;
  color: var(--accent-violet);
  margin-bottom: 8px;
}

.about-name {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.03em;
  margin-bottom: 4px;
}

.about-tagline {
  font-size: 13px;
  color: var(--text-sub);
  margin-bottom: 14px;
}

.about-meta {
  display: flex;
  justify-content: center;
  gap: 8px;
}

.about-pill {
  display: inline-block;
  padding: 5px 11px;
  border-radius: 10px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.68);
  color: var(--text-sub);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 6px 16px rgba(73, 61, 103, 0.08);
  font-family: "JetBrains Mono", monospace;
}

/* Floating Nav */
.floating-nav {
  position: absolute;
  bottom: var(--nav-offset);
  left: 14px;
  right: 14px;
  height: var(--nav-height);
  background: rgba(255, 255, 255, 0.76);
  backdrop-filter: blur(24px);
  border-radius: 40px;
  box-shadow: 0 5px 15px rgba(54, 40, 89, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.92);
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 0 12px;
  z-index: 100;
}

.chat-drawer-open .floating-nav,
.chat-drawer-open .home-indicator {
  opacity: 0;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

.nav-item {
  background: transparent;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  cursor: pointer;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  transition: transform 0.25s ease, background 0.3s ease, box-shadow 0.3s ease;
}

.nav-item:active {
  transform: scale(0.92);
}

.nav-icon-box {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  color: var(--text-muted);
  transition: color 0.35s ease;
}

.nav-icon-box svg {
  width: 22px;
  height: 22px;
  stroke-width: 2;
}

.nav-item span {
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.03em;
  text-transform: none;
  color: rgba(95, 102, 123, 0.86);
  opacity: 0.92;
  transform: translateY(0);
  transition: color 0.3s ease, opacity 0.3s ease, transform 0.3s ease;
}

.nav-item:hover .nav-icon-box,
.nav-item:hover span {
  color: #8d73e9;
  opacity: 1;
}

.nav-item.active .nav-icon-box {
  color: #8d73e9;
}

.nav-item.active .nav-icon-box svg {
  stroke-width: 2.4;
}

.nav-item.active {
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 5px 8px rgba(67, 51, 104, 0.12);
}

.nav-item.active span {
  color: #8d73e9;
  opacity: 1;
  transform: translateY(-1px);
}

.home-indicator {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 130px;
  height: 5px;
  background: #cbd5e1;
  border-radius: 10px;
  z-index: 200;
}

/* Utilities */
.bg-pink-400 { background: var(--accent-pink); }
.bg-blue-400 { background: var(--accent-blue); }
.bg-teal-400 { background: var(--accent-teal); }
.bg-orange-400 { background: var(--accent-orange); }

.bg-blue-100 { background: #dbeafe; }
.text-blue-600 { color: #2563eb; }

.bg-purple-100 { background: #f3e8ff; }
.text-purple-600 { color: #9333ea; }

.bg-emerald-100 { background: #d1fae5; }
.text-emerald-600 { color: #059669; }

.bg-slate-200 { background: #e2e8f0; }
.text-slate-700 { color: #334155; }

.bg-orange-100 { background: #ffedd5; }
.text-orange-600 { color: #ea580c; }

.bg-rose-100 { background: #ffe4e6; }
.text-rose-600 { color: #e11d48; }

.bg-pink-100 { background: #fce7f3; }
.text-pink-600 { color: #db2777; }

.bg-teal-100 { background: #ccfbf1; }
.text-teal-600 { color: #0d9488; }

.bg-cyan-100 { background: #cffafe; }
.text-cyan-600 { color: #0891b2; }

.bg-amber-100 { background: #fef3c7; }
.text-amber-600 { color: #d97706; }

.bg-indigo-100 { background: #e0e7ff; }
.text-indigo-600 { color: #4f46e5; }

.bg-yellow-100 { background: #fef9c3; }
.text-yellow-600 { color: #ca8a04; }

/* Toast & Sheet Overrides for Light Mode */
#toast-container {
  bottom: 120px;
}
.toast {
  background: rgba(255, 255, 255, 0.95);
  color: var(--text-main);
  box-shadow: var(--shadow-float);
  border: 1px solid white;
}

.bottom-sheet {
  background: rgba(255, 255, 255, 0.95);
  border-top: 1px solid white;
  color: var(--text-main);
}
.sheet-handle { background: #cbd5e1; }
.sheet-subtitle { color: var(--text-sub); }
.sheet-body { color: var(--text-sub); }
.sheet-icon-large {
  background: var(--bg-app);
  border: 1px solid var(--border-light);
  box-shadow: none;
}

/* System Status Widgets */
.status-details {
  margin-top: 8px;
}

.status-details > summary {
  list-style: none;
}

.status-details > summary::-webkit-details-marker {
  display: none;
}

.status-summary {
  width: 100%;
}

.status-details-body {
  margin-top: 10px;
}

.status-details[open] .status-summary > svg.lucide-chevron-right {
  transform: rotate(90deg);
}

.status-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 8px;
}

.status-widget {
  background: rgba(255, 255, 255, 0.72);
  border-radius: 20px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 24px rgba(68, 57, 96, 0.1);
  backdrop-filter: blur(12px);
  display: flex;
  flex-direction: row;
  gap: 12px;
  min-height: 56px;
  justify-content: space-between;
  text-align: left;
  align-items: center;
}

.widget-label {
  font-size: 12px;
  color: var(--text-sub);
  font-weight: 700;
  letter-spacing: 0.025em;
  margin: 0;
  text-align: left;
}

.widget-value {
  font-size: 14px;
  font-weight: 700;
  color: #52525b;
  margin: 0;
  letter-spacing: -0.01em;
  text-align: right;
}

/* Toast Notifications */
#toast-container {
  position: absolute;
  bottom: 100px;
  left: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  z-index: 100;
  pointer-events: none;
  padding: 0 24px;
}

.toast {
  background: rgba(35, 35, 40, 0.9);
  color: #fff;
  padding: 12px 20px;
  border-radius: 99px;
  font-size: 13px;
  font-weight: 500;
  text-align: center;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  opacity: 0;
  transform: translateY(20px) scale(0.9);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.toast.show {
  opacity: 1;
  transform: translateY(0) scale(1);
}
