/* ==========================================================================
   RUANG KERJA AI — MODERN BENTO & PILL WORKSPACE (REFERENCE IMAGE STYLE)
   Deep Navy (#0f1e46) · Ocean Teal (#1799cd) · Neon Lime (#dff952) · Soft Ice (#f4f7fc)
   ========================================================================== */

:root {
  --bg: #eef2f8;
  --panel: #ffffff;
  --panel2: #f4f7fc;
  --panel3: #e7edf7;
  --input-bg: #f4f7fc;
  --line: #e4eaf4;
  --line2: #d2dceb;

  --navy: #0f1e46;
  --navy-hover: #182d63;
  --teal: #1799cd;
  --royal: #1d52b8;
  --lime: #dff952;
  --lime-dark: #c5e232;
  --sky-card: #d9ecff;

  --text: #0f1e46;
  --text-sec: #3b4a6b;
  --muted: #7a89a8;

  --accent: #1d52b8;
  --accent2: #0f1e46;
  --accent-soft: #eaf1ff;
  --accent-border: #c5d9ff;

  --green: #0f8a5f;
  --green-soft: #e6f9f1;
  --green-border: #b5ebd5;

  --amber: #b45309;
  --amber-soft: #fef6e0;
  --amber-border: #fae19c;

  --red: #d92d20;
  --red-soft: #fef1f0;
  --red-border: #fecdca;

  --shadow-card: 0 10px 28px rgba(15, 30, 70, 0.045), 0 2px 6px rgba(15, 30, 70, 0.025);
  --shadow-float: 0 18px 42px rgba(15, 30, 70, 0.12), 0 4px 12px rgba(15, 30, 70, 0.06);

  --radius-sm: 12px;
  --radius: 20px;
  --radius-lg: 26px;
}

html[data-theme="dark"] {
  --bg: #080e1e;
  --panel: #10192e;
  --panel2: #17233f;
  --panel3: #203054;
  --input-bg: #152039;
  --line: #213052;
  --line2: #2d406b;

  --navy: #0a142e;
  --navy-hover: #162652;
  --sky-card: #162b4d;

  --text: #f4f7fc;
  --text-sec: #c3cfe6;
  --muted: #8496b8;

  --accent: #388bfd;
  --accent2: #58a6ff;
  --accent-soft: #16294a;
  --accent-border: #25467a;

  --green: #34d399;
  --green-soft: #0d2e24;
  --green-border: #17523f;

  --amber: #fbbf24;
  --amber-soft: #2e220c;
  --amber-border: #594114;

  --red: #f87171;
  --red-soft: #301518;
  --red-border: #5e262b;

  --shadow-card: 0 10px 30px rgba(0, 0, 0, 0.28);
  --shadow-float: 0 22px 48px rgba(0, 0, 0, 0.5);
}

*, *::before, *::after {
  box-sizing: border-box;
  transition: none !important;
  animation: none !important;
}

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font: 13.5px/1.55 "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Inter", system-ui, sans-serif;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
code, pre { font-family: "SF Mono", "JetBrains Mono", ui-monospace, Consolas, monospace; font-size: 12px; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.tiny { font-size: 12px; line-height: 1.45; }
.err { color: var(--red); font-size: 12.5px; font-weight: 600; min-height: 18px; }
.full-w { width: 100%; justify-content: center; }

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line2); border-radius: 999px; }

/* ==========================================================================
   LOGIN SCREEN
   ========================================================================== */
.login {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 24px;
}
.login form {
  background: var(--panel);
  box-shadow: var(--shadow-float);
  padding: 32px;
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 400px;
  display: grid;
  gap: 20px;
}
.login-hero {
  background: linear-gradient(140deg, #0d2154 0%, #0d5096 55%, #37c5b3 100%);
  color: #ffffff;
  padding: 24px;
  border-radius: 20px;
  display: grid;
  gap: 14px;
  position: relative;
  overflow: hidden;
}
.login-hero::after {
  content: "";
  position: absolute;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  border: 14px solid var(--lime);
  top: -36px;
  right: -36px;
}
.login-hero h1 { font-size: 24px; font-weight: 800; margin: 4px 0; letter-spacing: -0.03em; }
.login-hero p { margin: 0; font-size: 12.5px; opacity: 0.88; }
.login-fields { display: grid; gap: 14px; }

.lime-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--lime);
  color: #0f1e46;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  width: max-content;
}

/* ==========================================================================
   TOP FLOATING PILL NAVIGATION BAR (Reference Image Header)
   ========================================================================== */
.app-frame {
  max-width: 1480px;
  margin: 0 auto;
  padding: 18px 24px 36px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 100vh;
}

.top-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.top-nav-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-circle {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #0f1e46;
  color: var(--lime);
  display: grid;
  place-items: center;
  box-shadow: var(--shadow-card);
  flex-shrink: 0;
}
.logo-circle svg { width: 22px; height: 22px; }

.brand-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}
.brand-meta strong {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.025em;
}
.brand-meta #root-path {
  max-width: 180px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 11px;
}

/* Center Pill Dock */
.pill-dock {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.pill-dock a {
  height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  background: var(--panel);
  color: var(--text);
  font-size: 13.5px;
  font-weight: 650;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  box-shadow: var(--shadow-card);
}
.pill-dock a .nav-ico {
  width: 18px;
  height: 18px;
  color: var(--text);
  flex-shrink: 0;
}
.pill-dock a:hover {
  background: var(--panel2);
}
.pill-dock a.active {
  background: #0f1e46;
  color: #ffffff;
  padding: 0 22px;
}
.pill-dock a.active .nav-ico {
  color: var(--lime);
}
.nav-badge {
  font-size: 11px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 999px;
  background: var(--panel2);
  color: var(--text);
}
.nav-badge:empty { display: none; }
.pill-dock a.active .nav-badge {
  background: var(--lime);
  color: #0f1e46;
}

/* Right Action Circles & Profile Pill */
.top-nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.circle-btn {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--panel);
  border: none;
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: var(--shadow-card);
  position: relative;
  flex-shrink: 0;
  font-size: 15px;
  font-weight: 700;
}
.circle-btn.sm { width: 36px; height: 36px; background: var(--panel2); box-shadow: none; }
.circle-btn svg { width: 19px; height: 19px; }
.circle-btn:hover { background: var(--panel2); }
.circle-btn.active { background: #0f1e46; color: var(--lime); }

.notif-dot {
  position: absolute;
  top: 11px;
  right: 12px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #38bdf8;
}

/* Quick Search Pill */
.quick-search-wrap {
  position: relative;
}
.search-ico {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--muted);
  pointer-events: none;
}
#global-search {
  height: 46px;
  width: 190px;
  padding: 0 16px 0 38px;
  border-radius: 999px;
  background: var(--panel);
  border: none;
  box-shadow: var(--shadow-card);
  font-size: 13px;
  font-weight: 550;
  color: var(--text);
}
#global-search:focus {
  outline: 2px solid var(--teal);
  width: 240px;
}
.search-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 320px;
  background: var(--panel);
  border-radius: 20px;
  box-shadow: var(--shadow-float);
  padding: 8px;
  z-index: 60;
  max-height: 340px;
  overflow-y: auto;
}
.search-hit {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  cursor: pointer;
  font-size: 13px;
}
.search-hit:hover { background: var(--panel2); }

/* Deep Navy User / Status Pill on Top Right */
.profile-pill {
  height: 46px;
  padding: 5px 18px 5px 6px;
  border-radius: 999px;
  background: #0f1e46;
  color: #ffffff;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: var(--shadow-card);
  text-align: left;
  font: inherit;
}
.profile-pill:hover { background: #172b5e; }
.profile-ava {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1799cd, #45ccb4);
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  display: grid;
  place-items: center;
}
.profile-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}
.profile-meta strong { font-size: 13px; font-weight: 700; color: #ffffff; }
.profile-meta span {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.75);
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--lime);
  display: inline-block;
}
.status-dot.ok { background: var(--lime); }
.status-dot.warn { background: #fbbf24; }
.status-dot.err { background: #f87171; }

/* Sub-Header Bar (For Inner Views & Sub-Tabs) */
.subbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 4px 4px 0;
}
.subbar.home-mode {
  display: none;
}
.subbar-left {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.subbar h1 {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0;
}
.page-sub {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.hub-switcher {
  display: inline-flex;
  gap: 6px;
  background: var(--panel);
  padding: 5px;
  border-radius: 999px;
  box-shadow: var(--shadow-card);
}
.hub-switcher:empty { display: none; }
.hub-pill {
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 650;
  color: var(--muted);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.hub-pill:hover { color: var(--text); }
.hub-pill.on {
  background: #0f1e46;
  color: #ffffff;
}
.hub-pill b {
  font-size: 10.5px;
  padding: 1px 6px;
  border-radius: 999px;
  background: var(--lime);
  color: #0f1e46;
}

.sys-banner {
  background: var(--sky-card);
  color: #0f1e46;
  padding: 14px 20px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  font-size: 13px;
  font-weight: 550;
}
html[data-theme="dark"] .sys-banner { color: #f4f7fc; }

/* ==========================================================================
   DAILY WORKSPACE ("TODAY" VIEW) & STREAMLINED TASK ROWS
   ========================================================================== */
.today {
  display: grid;
  grid-template-columns: 1fr 330px;
  gap: 20px;
  align-items: start;
}
.today-main {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-width: 0;
}
.hero-grad-card.ask {
  min-height: auto;
  padding: 24px 26px;
  gap: 16px;
}
.hero-ask-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}
.hero-kicker {
  display: inline-block;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--lime);
  margin-bottom: 4px;
}
.hero-grad-card.ask h2 {
  margin: 0;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.025em;
}
.hero-chat-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(15, 30, 70, 0.38);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #ffffff;
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}
.hero-chat-link svg { width: 15px; height: 15px; color: var(--lime); }
.hero-chat-link:hover { background: rgba(15, 30, 70, 0.62); }

.hero-emp-select {
  width: auto !important;
  max-width: 185px;
  background: #0f1e46 !important;
  color: #ffffff !important;
  border: none !important;
  border-radius: 999px !important;
  padding: 8px 14px !important;
  font-size: 12.5px !important;
  font-weight: 700 !important;
  cursor: pointer;
  flex-shrink: 0;
}
.team-scroll {
  max-height: calc(100vh - 210px);
  overflow-y: auto;
  padding-right: 2px;
}

.row-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--lime);
  color: #0f1e46;
  margin-left: 6px;
}
.link {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--teal);
}
.link:hover { text-decoration: underline; }
.quiet {
  margin: 0;
  padding: 18px 12px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  background: var(--panel2);
  border-radius: 16px;
}

/* Streamlined Task Row */
.task-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: var(--panel2);
  border-radius: 18px;
  cursor: pointer;
  border: 1.5px solid transparent;
}
.task-row:hover { border-color: var(--line2); }
.task-row.running { border-color: var(--teal); }
.task-row.blocked { border-color: var(--amber); }
.task-row-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.task-row-top {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.task-row-top strong {
  font-size: 14.5px;
  font-weight: 750;
  color: var(--text);
}
.task-row-meta {
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Streamlined Team List on Right Panel */
.team-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: var(--panel2);
  border-radius: 16px;
}
.team-who {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
  cursor: pointer;
}
.team-who strong {
  display: block;
  font-size: 13.5px;
  font-weight: 750;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.team-who small {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  color: var(--muted);
}
.sdot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
}
.sdot.ok { background: var(--green); }
.sdot.run { background: var(--teal); }

/* ==========================================================================
   3-COLUMN BENTO DASHBOARD (Exact Reference Image Architecture)
   ========================================================================== */
.bento-home {
  display: grid;
  grid-template-columns: 1.05fr 1.15fr 1.05fr;
  gap: 20px;
  align-items: stretch;
}

.bento-col {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
}

/* 1. Top-Left Hero Gradient Card ("Welcome back" + Floating Pill Command Bar) */
.hero-grad-card {
  background: linear-gradient(145deg, #0d1f52 0%, #0d488a 46%, #1388b8 76%, #49ceb5 100%);
  color: #ffffff;
  border-radius: var(--radius-lg);
  padding: 26px 24px 22px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 16px 36px rgba(13, 35, 90, 0.18);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  min-height: 310px;
}
/* Dot-Matrix Pattern + Neon Lime Ring from Reference Image */
.hero-grad-card::before {
  content: "";
  position: absolute;
  top: 16px;
  right: 115px;
  width: 72px;
  height: 56px;
  background-image: radial-gradient(rgba(255, 255, 255, 0.28) 1.5px, transparent 1.5px);
  background-size: 14px 14px;
  pointer-events: none;
}
.hero-grad-card::after {
  content: "";
  position: absolute;
  width: 155px;
  height: 155px;
  border-radius: 50%;
  border: 18px solid var(--lime);
  top: -58px;
  right: -45px;
  pointer-events: none;
}

.hero-top-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  width: max-content;
  position: relative;
  z-index: 1;
}

.hero-headline {
  position: relative;
  z-index: 1;
}
.hero-big-num {
  font-size: 54px;
  font-weight: 300;
  letter-spacing: -0.04em;
  line-height: 1;
  margin: 4px 0 8px;
}
.hero-big-num small {
  font-size: 20px;
  font-weight: 500;
  opacity: 0.9;
  margin-left: 4px;
}
.hero-headline h2 {
  margin: 0 0 4px;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.hero-headline p {
  margin: 0;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.82);
}

/* Employee Selector Chips Inside Hero Card */
.hero-emp-strip {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}
.hero-emp-pill {
  background: rgba(15, 30, 70, 0.35);
  color: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.22);
  padding: 4px 11px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
}
.hero-emp-pill:hover { background: rgba(15, 30, 70, 0.55); }
.hero-emp-pill.on {
  background: var(--lime);
  color: #0f1e46;
  border-color: var(--lime);
  font-weight: 800;
}

/* Floating White Pill Input Bar Inside Hero Card */
.hero-pill-bar {
  background: #ffffff;
  border-radius: 999px;
  padding: 6px 6px 6px 18px;
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
  z-index: 1;
  box-shadow: 0 8px 20px rgba(10, 25, 65, 0.2);
}
.hero-pill-bar input {
  border: none !important;
  background: transparent !important;
  color: #0f1e46 !important;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 0 !important;
  box-shadow: none !important;
}
.hero-pill-bar input::placeholder { color: #697a98; font-weight: 500; }
.hero-lime-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--lime);
  color: #0f1e46;
  border: none;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
  font-weight: 800;
}
.hero-lime-btn:hover { background: var(--lime-dark); }
.hero-lime-btn svg { width: 18px; height: 18px; }
.hero-chat-btn {
  height: 40px;
  padding: 0 13px;
  border-radius: 999px;
  background: #eef2f8;
  color: #0f1e46;
  border: none;
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
}
.hero-chat-btn:hover { background: #dfe6f2; }

/* 2. Bento White Card Standard */
.bento-card {
  background: var(--panel);
  border-radius: var(--radius-lg);
  padding: 22px 24px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.bento-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.bento-head h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 750;
  letter-spacing: -0.02em;
}

/* Segmented Usage Bar & 4 Counters (Bottom-Left Reference Card) */
.usage-big-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.usage-num-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}
.usage-num {
  font-size: 40px;
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1;
}
.usage-sub {
  display: flex;
  flex-direction: column;
  font-size: 12px;
  line-height: 1.3;
}
.usage-sub strong { font-weight: 700; color: var(--text); }
.usage-sub span { color: var(--muted); }

.capsule-bar {
  display: flex;
  gap: 6px;
  height: 11px;
  width: 100%;
}
.cap-seg {
  height: 100%;
  border-radius: 999px;
  min-width: 14px;
}
.usage-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding-top: 4px;
}
.u-stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.u-stat strong {
  font-size: 19px;
  font-weight: 750;
  display: flex;
  align-items: center;
  gap: 5px;
}
.u-stat span { font-size: 11.5px; color: var(--muted); }
.u-dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; }

/* 3. Center Column Inner Recommendation/Task Cards (Reference Image Center) */
.rec-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.rec-item {
  background: var(--panel2);
  border-radius: 20px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.rec-item-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.sq-ico {
  width: 42px;
  height: 42px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  color: #ffffff;
  flex-shrink: 0;
}
.sq-ico svg { width: 20px; height: 20px; }
.sq-ico.teal { background: var(--teal); }
.sq-ico.royal { background: var(--royal); }
.sq-ico.navy { background: #0f1e46; color: var(--lime); }

.rec-item-title {
  flex: 1;
  min-width: 0;
}
.rec-item-title small {
  font-size: 11px;
  color: var(--muted);
  display: block;
}
.rec-item-title strong {
  font-size: 15px;
  font-weight: 750;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rec-item-desc {
  font-size: 12.5px;
  color: var(--text-sec);
  line-height: 1.45;
}
.white-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--panel);
  color: var(--text);
  border: none;
  padding: 8px 16px;
  border-radius: 999px;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  width: max-content;
  box-shadow: 0 2px 8px rgba(15, 30, 70, 0.05);
}
.white-pill-btn:hover { background: #0f1e46; color: #ffffff; }

/* 4. Bottom-Center Soft Sky Notification Card */
.sky-bento {
  background: var(--sky-card);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
}
.sky-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--text);
}
.sky-ico {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--panel);
  color: var(--text);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.sky-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

/* 5. Top-Right Completion & Vertical Pill Bar Chart Card */
.pct-big {
  font-size: 44px;
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1;
}
.pct-big small {
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  margin-left: 6px;
}
.slim-bar-track {
  height: 7px;
  background: var(--panel2);
  border-radius: 999px;
  overflow: hidden;
}
.slim-bar-fill {
  height: 100%;
  background: var(--teal);
  border-radius: 999px;
}
.callout-strip {
  background: var(--panel2);
  border-radius: 16px;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

/* Vertical Pill Bar Chart */
.v-chart {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  align-items: end;
  height: 126px;
  padding: 14px 8px 0;
  border-bottom: 1px solid var(--line);
}
.v-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  height: 100%;
  justify-content: flex-end;
}
.v-bars {
  display: flex;
  align-items: flex-end;
  gap: 5px;
  height: 96px;
}
.v-pill {
  width: 11px;
  border-radius: 999px;
  min-height: 12px;
}
.v-pill.soft { background: #cfe4f9; }
.v-pill.solid { background: #1454a6; }
html[data-theme="dark"] .v-pill.soft { background: #22375c; }
html[data-theme="dark"] .v-pill.solid { background: #38bdf8; }
.v-lbl {
  font-size: 11px;
  color: var(--muted);
  font-weight: 600;
  max-width: 64px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 6. Bottom-Right Deep Navy Station Card (Concentric Lime Rings) */
.navy-station-card {
  background: #0f1e46;
  color: #ffffff;
  border-radius: var(--radius-lg);
  padding: 24px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 195px;
  box-shadow: 0 14px 32px rgba(15, 30, 70, 0.18);
  cursor: pointer;
}
.navy-station-card::before {
  content: "";
  position: absolute;
  width: 170px;
  height: 170px;
  border-radius: 50%;
  border: 1.5px solid rgba(223, 249, 82, 0.55);
  top: -55px;
  right: -55px;
  box-shadow: 0 0 0 24px transparent, 0 0 0 25.5px rgba(223, 249, 82, 0.38),
              0 0 0 50px transparent, 0 0 0 51.5px rgba(223, 249, 82, 0.22);
  pointer-events: none;
}
.navy-station-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 1;
}
.navy-station-top span {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.8);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.navy-station-foot {
  position: relative;
  z-index: 1;
}
.navy-station-foot h3 {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 750;
  letter-spacing: -0.025em;
}
.navy-station-foot p {
  margin: 0;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.76);
}

/* ==========================================================================
   GENERAL BUTTONS, INPUTS, CARDS & PAGES
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--panel);
  color: var(--text);
  border: 1px solid var(--line2);
  padding: 8px 16px;
  border-radius: 999px;
  font: inherit;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  user-select: none;
}
.btn:hover { background: var(--panel2); }
.btn:disabled { opacity: 0.5; pointer-events: none; }
.btn.primary, .btn.navy-pill {
  background: #0f1e46;
  border-color: #0f1e46;
  color: #ffffff;
}
html[data-theme="dark"] .btn.primary {
  background: var(--lime);
  border-color: var(--lime);
  color: #0f1e46;
}
.btn.primary:hover, .btn.navy-pill:hover {
  background: var(--navy-hover);
  border-color: var(--navy-hover);
}
.btn.lime {
  background: var(--lime);
  border-color: var(--lime);
  color: #0f1e46;
}
.btn.ghost {
  background: transparent;
  border-color: transparent;
  color: var(--text-sec);
}
.btn.ghost:hover { background: var(--panel2); color: var(--text); }
.btn.tiny { padding: 5px 12px; font-size: 11.5px; }
.btn.danger {
  color: var(--red);
  background: var(--red-soft);
  border-color: var(--red-border);
}
.btn.danger:hover { background: var(--red); color: #fff; }

input, textarea, select {
  background: var(--input-bg);
  border: 1.5px solid transparent;
  color: var(--text);
  border-radius: 14px;
  padding: 10px 14px;
  font: inherit;
  font-size: 13px;
  width: 100%;
}
textarea { min-height: 88px; resize: vertical; line-height: 1.5; }
input:focus, textarea:focus, select:focus {
  outline: none;
  background: var(--panel);
  border-color: var(--teal);
}
input.invalid, textarea.invalid, select.invalid {
  border-color: var(--red) !important;
  background: var(--red-soft);
}
.field-err {
  color: var(--red);
  font-size: 11.5px;
  font-weight: 600;
  margin-top: 2px;
}
label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  font-weight: 650;
  color: var(--text-sec);
}

.grid { display: grid; gap: 16px; }
.grid.c4 { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.grid.c3 { grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.grid.c2 { grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); }

.card {
  background: var(--panel);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  box-shadow: var(--shadow-card);
}

/* Task Pipeline Cards across Task Page */
.task-card {
  background: var(--panel);
  border-radius: 22px;
  padding: 18px 20px;
  box-shadow: var(--shadow-card);
  display: grid;
  gap: 12px;
  border: 1.5px solid transparent;
}
.task-card.running {
  border-color: var(--teal);
}
.task-card.blocked {
  border-color: var(--amber);
}
.task-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.task-title {
  font-size: 15px;
  font-weight: 750;
  line-height: 1.35;
  cursor: pointer;
}
.task-title:hover { color: var(--teal); }

.prog-wrap { display: grid; gap: 5px; }
.prog-meta { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted); font-weight: 600; }
.prog-track { height: 7px; background: var(--panel2); border-radius: 999px; overflow: hidden; }
.prog-fill { height: 100%; background: var(--teal); border-radius: 999px; }
.prog-fill.done { background: var(--green); }
.prog-fill.blocked { background: var(--amber); }

.task-summary {
  font-size: 12.5px;
  color: var(--text-sec);
  background: var(--panel2);
  border-radius: 14px;
  padding: 11px 14px;
  line-height: 1.55;
  white-space: pre-wrap;
}
.att-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.att-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--panel2);
  border: none;
  color: var(--text);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
}
.att-chip:hover { background: #0f1e46; color: #fff; }

/* Employee Cards */
.emp {
  display: grid;
  gap: 14px;
  align-content: space-between;
}
.emp .name { display: flex; align-items: center; gap: 12px; }
.emp .name strong { font-size: 16px; font-weight: 750; letter-spacing: -0.015em; }
.emp-card-actions {
  display: flex;
  gap: 8px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.ava {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: linear-gradient(135deg, #0f1e46, #1799cd);
  color: #ffffff;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 800;
  overflow: hidden;
  flex: 0 0 auto;
}
.ava img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ava.lg { width: 58px; height: 58px; border-radius: 18px; font-size: 18px; }
.ava.sm { width: 30px; height: 30px; border-radius: 10px; font-size: 11px; }
.photo-row { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }

/* Pills & Badges */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--panel2);
  font-size: 11px;
  font-weight: 700;
  color: var(--text-sec);
}
.pill.on, .pill.done {
  background: var(--lime);
  color: #0f1e46;
}
.pill.off, .pill.run {
  background: var(--amber-soft);
  color: var(--amber);
}
.pill.bad {
  background: var(--red-soft);
  color: var(--red);
}
.pill.blue {
  background: #e0f2fe;
  color: #0369a1;
}

.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.pill-row, .chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--panel2);
  border: none;
  border-radius: 999px;
  padding: 6px 13px;
  font-size: 12px;
  font-weight: 650;
  color: var(--text);
  cursor: pointer;
}
.chip:hover { background: var(--panel3); }
.chip.on {
  background: #0f1e46;
  color: #ffffff;
}
.chip button { background: none; border: none; color: inherit; font-size: 14px; cursor: pointer; padding: 0 2px; }

/* Alerts */
.alert {
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 12.5px;
  font-weight: 550;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.alert.warn, .warn { background: var(--amber-soft); color: var(--amber); border-radius: 16px; padding: 11px 15px; }
.alert.err { background: var(--red-soft); color: var(--red); }
.alert.ok { background: var(--green-soft); color: var(--green); }
.alert.info { background: var(--sky-card); color: #0f1e46; }

/* Tables, Toolbars & Pagination */
.tbl-wrap {
  background: var(--panel);
  border-radius: var(--radius-lg);
  overflow-x: auto;
  box-shadow: var(--shadow-card);
  padding: 6px;
}
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th {
  text-align: left;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  font-weight: 700;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}
td { padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: none; }
tr.clickable { cursor: pointer; }
tr.clickable:hover { background: var(--panel2); }

.tabs {
  display: inline-flex;
  gap: 4px;
  flex-wrap: wrap;
  background: var(--panel2);
  padding: 4px;
  border-radius: 999px;
  margin: 10px 0 14px;
}
.tab {
  background: transparent;
  border: none;
  color: var(--muted);
  padding: 6px 14px;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  border-radius: 999px;
}
.tab:hover { color: var(--text); }
.tab.on {
  background: #0f1e46;
  color: #ffffff;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
  padding: 12px 16px;
  background: var(--panel);
  border-radius: 20px;
  box-shadow: var(--shadow-card);
}
.toolbar-left { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; flex: 1; }
.toolbar-search { max-width: 260px; min-width: 170px; border-radius: 999px !important; padding: 8px 16px !important; }
.toolbar-select { width: auto !important; min-width: 140px; border-radius: 999px !important; padding: 8px 14px !important; }

.pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 16px;
  padding: 12px 18px;
  background: var(--panel);
  border-radius: 20px;
  box-shadow: var(--shadow-card);
  font-size: 12.5px;
  color: var(--muted);
}
.pager-btns { display: flex; align-items: center; gap: 8px; }

/* Forms, Steps & Logs */
.form { display: grid; gap: 12px; max-width: 620px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.split { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 18px; align-items: start; }
.pre, .log {
  white-space: pre-wrap;
  background: var(--panel2);
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 12px;
  color: var(--text-sec);
  max-height: 340px;
  overflow: auto;
  margin: 0;
}
h2.section {
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.015em;
  color: var(--text);
  margin: 18px 0 12px;
}
h3.sub {
  font-size: 12px;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 14px 0 8px;
}

.step-feed {
  display: grid;
  gap: 8px;
  max-height: 320px;
  overflow-y: auto;
  background: var(--panel2);
  border-radius: 16px;
  padding: 12px;
}
.step-item {
  font-size: 12px;
  padding: 10px 12px;
  background: var(--panel);
  border-radius: 12px;
  display: grid;
  gap: 4px;
}
.step-item .step-head { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); }

/* ==========================================================================
   FULL-SCREEN SINGLE-PANE CHAT STUDIO (ChatGPT / Claude / Linear Style)
   ========================================================================== */
.full-chat-stage {
  background: var(--panel);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  height: calc(100vh - 92px);
  min-height: 480px;
  overflow: hidden;
  position: relative;
}

.fc-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--line);
  background: var(--panel);
  height: 60px;
  flex-shrink: 0;
}

/* Employee Switcher Dropdown in Chat Header */
.fc-emp-dropdown {
  position: relative;
}
.fc-emp-trigger {
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 5px 12px 5px 6px;
  border-radius: 999px;
  background: var(--panel2);
  cursor: pointer;
  user-select: none;
}
.fc-emp-trigger::-webkit-details-marker { display: none; }
.fc-emp-trigger:hover { background: var(--panel3); }
.fc-emp-info {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  text-align: left;
}
.fc-emp-info strong {
  font-size: 14px;
  font-weight: 800;
  color: var(--text);
}
.fc-emp-info small {
  font-size: 11px;
  color: var(--muted);
  max-width: 220px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.fc-chev {
  width: 16px;
  height: 16px;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
}
.fc-chev svg { width: 16px; height: 16px; }

.fc-dropdown-menu {
  position: absolute;
  left: 0;
  top: calc(100% + 8px);
  width: 310px;
  max-height: 400px;
  background: var(--panel);
  border-radius: 20px;
  box-shadow: var(--shadow-float);
  border: 1px solid var(--line);
  padding: 10px;
  z-index: 65;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.fc-dd-title {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  padding: 4px 8px;
}
.fc-dd-list {
  overflow-y: auto;
  display: grid;
  gap: 4px;
  max-height: 330px;
}
.fc-dd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  text-align: left;
  padding: 8px 10px;
  border-radius: 14px;
  border: none;
  background: transparent;
  color: var(--text);
  font: inherit;
  cursor: pointer;
}
.fc-dd-item:hover { background: var(--panel2); }
.fc-dd-item.on { background: #0f1e46; color: #ffffff; }
.fc-dd-item.on small { color: rgba(255, 255, 255, 0.72); }
.fc-dd-meta {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  line-height: 1.25;
}
.fc-dd-meta strong { font-size: 13px; font-weight: 750; }
.fc-dd-meta small {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Right Action Icons in Chat Header */
.fc-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.fc-pop { position: relative; }
.fc-pop summary { list-style: none; }
.fc-pop summary::-webkit-details-marker { display: none; }
.fc-icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--panel2);
  border: none;
  color: var(--text-sec);
  display: grid;
  place-items: center;
  cursor: pointer;
}
.fc-icon-btn svg { width: 17px; height: 17px; }
.fc-icon-btn:hover { background: var(--panel3); color: var(--text); }
.fc-icon-btn.danger:hover { background: var(--red-soft); color: var(--red); }

.fc-pop-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 310px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow-float);
  padding: 14px;
  display: grid;
  gap: 8px;
  z-index: 65;
}
.fc-hist-list {
  max-height: 290px;
  overflow-y: auto;
  display: grid;
  gap: 4px;
}

/* Full-Height Centered Message Stream */
.fc-msgs {
  flex: 1;
  overflow-y: auto;
  background: var(--panel2);
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
}
.fc-stream {
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

/* Bottom Centered Pro Composer */
.fc-composer-wrap {
  padding: 12px 16px 14px;
  background: var(--panel);
  border-top: 1px solid var(--line);
  flex-shrink: 0;
}
.fc-composer {
  max-width: 780px;
  margin: 0 auto;
}
.conv-side {
  background: var(--panel);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.conv-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px 10px;
}
.conv-head strong { font-size: 17px; font-weight: 800; letter-spacing: -0.02em; }
.conv-emp-select {
  width: auto !important;
  max-width: 135px;
  padding: 5px 10px !important;
  font-size: 11.5px !important;
  border-radius: 999px !important;
  font-weight: 650;
}

/* Quick Employee Strip at Top of Chat Sidebar */
.conv-quick-emps {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 2px 14px 10px;
  border-bottom: 1px solid var(--line);
}
.conv-ava-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px 4px 4px;
  border-radius: 999px;
  background: var(--panel2);
  border: none;
  color: var(--text);
  font: inherit;
  font-size: 11.5px;
  font-weight: 650;
  cursor: pointer;
  flex-shrink: 0;
}
.conv-ava-pill:hover { background: var(--panel3); }
.conv-ava-pill.on { background: #0f1e46; color: #ffffff; }
.conv-ava-pill .ava.sm { width: 22px; height: 22px; border-radius: 50%; font-size: 9px; }

.conv-search { padding: 10px 12px 6px; }
.conv-search input {
  padding: 8px 14px !important;
  border-radius: 999px !important;
  font-size: 12.5px !important;
}
.conv-list { flex: 1; overflow-y: auto; padding: 6px 10px 12px; display: grid; gap: 4px; align-content: start; }
.conv {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border-radius: 16px;
  border: none;
  background: transparent;
  color: var(--text);
  font: inherit;
  cursor: pointer;
}
.conv:hover { background: var(--panel2); }
.conv.on { background: #0f1e46; color: #ffffff; }
.conv.on .conv-top em, .conv.on .conv-sub { color: rgba(255, 255, 255, 0.72); }
.conv-body { display: grid; gap: 2px; flex: 1; min-width: 0; }
.conv-top { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; }
.conv-top strong { font-size: 13.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conv-top em { font-style: normal; font-size: 10.5px; color: var(--muted); flex-shrink: 0; }
.conv-sub { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conv-empty { padding: 24px 14px; text-align: center; }

.chat-main {
  background: var(--panel);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}
.chat-head {
  display: flex;
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding: 14px 20px;
}
.chat-who { display: grid; line-height: 1.25; }
.chat-who strong { font-size: 15px; font-weight: 750; }
.svg-inline { display: inline-flex; width: 13px; height: 13px; }
.svg-inline svg { width: 13px; height: 13px; }

.model-pop { position: relative; }
.model-pop summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; }
.model-pop .pop-body {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 270px;
  background: var(--panel);
  border-radius: 18px;
  box-shadow: var(--shadow-float);
  padding: 14px;
  display: grid;
  gap: 8px;
  z-index: 40;
}
.icon-btn {
  background: var(--panel2);
  border: none;
  color: var(--text-sec);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
}
.icon-btn svg { width: 16px; height: 16px; }
.icon-btn:hover { background: var(--red-soft); color: var(--red); }

.msgs {
  flex: 1;
  min-height: 260px;
  overflow-y: auto;
  background: var(--panel2);
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.dayline { text-align: center; margin: 6px 0; }
.dayline span {
  font-size: 11px;
  font-weight: 650;
  color: var(--muted);
  background: var(--panel);
  padding: 3px 12px;
  border-radius: 999px;
}
.msg-row { display: flex; gap: 10px; align-items: flex-end; }
.msg-row.mine { justify-content: flex-end; }
.msg-row.theirs { justify-content: flex-start; }
.bubble {
  max-width: 74%;
  padding: 12px 16px;
  border-radius: 20px;
  font-size: 13.5px;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
}
.msg-row.mine .bubble { background: #0f1e46; color: #ffffff; border-bottom-right-radius: 4px; }
.msg-row.theirs .bubble { background: var(--panel); color: var(--text); border-bottom-left-radius: 4px; box-shadow: 0 2px 10px rgba(15, 30, 70, 0.045); }
.bubble .meta { font-size: 10.5px; opacity: 0.72; margin-top: 5px; display: flex; justify-content: flex-end; align-items: center; gap: 8px; }
.msg-act {
  background: none;
  border: none;
  color: inherit;
  cursor: pointer;
  padding: 2px;
  display: inline-flex;
  align-items: center;
  opacity: 0.75;
}
.msg-act:hover { opacity: 1; }
.msg-act svg { width: 13px; height: 13px; }
.chat-empty { margin: auto; text-align: center; padding: 32px; display: grid; gap: 10px; place-items: center; color: var(--muted); }
.chat-empty .big { font-size: 17px; font-weight: 750; color: var(--text); }

/* Pro Composer Bar */
.composer-bar {
  padding: 12px 18px 16px;
  background: var(--panel);
  border-top: 1px solid var(--line);
}
.composer {
  display: flex;
  gap: 6px;
  align-items: center;
  background: var(--panel2);
  padding: 6px 8px 6px 10px;
  border-radius: 26px;
  border: 1.5px solid transparent;
}
.composer:focus-within {
  background: var(--panel);
  border-color: var(--teal);
  box-shadow: 0 4px 16px rgba(15, 30, 70, 0.06);
}
.comp-ico-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: transparent;
  border: none;
  color: var(--text-sec);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
}
.comp-ico-btn svg { width: 19px; height: 19px; }
.comp-ico-btn:hover { background: var(--panel3); color: var(--text); }
.comp-ico-btn.rec { background: var(--red); color: #ffffff; }

.composer textarea {
  min-height: 38px;
  max-height: 140px;
  flex: 1;
  background: transparent !important;
  border: none !important;
  padding: 8px 8px !important;
  font-size: 13.5px;
}
.comp-send-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--lime);
  color: #0f1e46;
  border: none;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
}
.comp-send-btn svg { width: 19px; height: 19px; }
.comp-send-btn:hover { background: var(--lime-dark); }

/* Wizard, Org, Presets & Misc */
.steps { display: flex; align-items: center; gap: 6px; }
.dotstep {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 11.5px;
  font-weight: 750;
  color: var(--muted);
  background: var(--panel2);
}
.dotstep.on { color: #fff; background: #0f1e46; }
.dotstep.done { background: var(--lime); color: #0f1e46; }
.steps .sep { width: 14px; height: 2px; background: var(--line2); }
.spacer { flex: 1; }
.wizhead { margin: 12px 0; }
.wizhead strong { font-size: 16px; font-weight: 750; }
.recs, .recruit, .preset-grid { display: grid; gap: 10px; }
.rec, .recruit-card, .preset-card {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 14px 16px;
  border-radius: 18px;
  background: var(--panel2);
  border: 1.5px solid transparent;
  cursor: pointer;
  font: inherit;
  color: var(--text);
  text-align: left;
}
.recruit-card { flex-direction: column; gap: 4px; }
.rec:hover, .recruit-card:hover, .preset-card:hover { border-color: var(--teal); }
.rec.on, .preset-card.on { border-color: #0f1e46; background: var(--accent-soft); }
.rec input, .preset-card input { width: auto; margin-top: 3px; }
.rec span { display: grid; gap: 2px; }
.pills { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 6px; }

.chan, .chan-block, .chan-cfg, .keyrow {
  border-radius: 18px;
  padding: 14px 16px;
  background: var(--panel2);
}
.chan { display: flex; gap: 10px; align-items: center; justify-content: space-between; }
.chan-cfg { margin-top: 10px; display: grid; gap: 10px; }
.chan-block summary, .keyrow summary { cursor: pointer; font-size: 13.5px; font-weight: 700; display: flex; align-items: center; justify-content: space-between; }
.qrbox { display: grid; gap: 8px; justify-items: center; padding: 14px; border-radius: 18px; background: var(--panel); width: max-content; margin-top: 8px; }
.qrbox img { width: 220px; height: 220px; background: #fff; padding: 6px; border-radius: 12px; }
.org-node { display: flex; gap: 12px; align-items: center; background: var(--panel2); border-radius: 16px; padding: 12px 16px; margin-bottom: 8px; }
.org-node .org-who { display: grid; gap: 2px; flex: 1; }
.actlist { display: grid; gap: 6px; margin-bottom: 14px; }
.actlist .line { display: flex; gap: 8px; align-items: center; justify-content: space-between; background: var(--panel2); border-radius: 12px; padding: 9px 12px; font-size: 12.5px; }
.empty-box { text-align: center; padding: 28px 18px; background: var(--panel2); border-radius: 20px; color: var(--muted); display: grid; gap: 4px; place-items: center; }
.empty-box strong { color: var(--text); font-size: 14px; }

/* Board columns */
.board { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 12px; align-items: start; }
.col { background: var(--panel2); border-radius: 22px; min-width: 270px; width: 270px; flex: 0 0 auto; padding: 14px; display: grid; gap: 10px; }
.col h3 { font-size: 12px; font-weight: 750; text-transform: uppercase; color: var(--text-sec); margin: 0; display: flex; justify-content: space-between; }

/* Floating Inspector Sheet, Modal & Toast */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 30, 70, 0.35);
  display: flex;
  justify-content: flex-end;
  padding: 12px;
  z-index: 75;
}
.drawer-panel {
  width: 100%;
  max-width: 580px;
  height: 100%;
  background: var(--panel);
  border-radius: 26px;
  box-shadow: var(--shadow-float);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
}
.drawer-head h3 { margin: 0; font-size: 17px; font-weight: 800; letter-spacing: -0.02em; }
.drawer-body { flex: 1; overflow-y: auto; padding: 20px 22px 28px; }

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 30, 70, 0.4);
  display: grid;
  place-items: center;
  padding: 16px;
  z-index: 85;
}
.modal-box {
  background: var(--panel);
  border-radius: 26px;
  box-shadow: var(--shadow-float);
  padding: 24px;
  width: 100%;
  max-width: 440px;
}
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.modal-head h3 { margin: 0; font-size: 17px; font-weight: 800; }

.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #0f1e46;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 650;
  box-shadow: var(--shadow-float);
  z-index: 95;
}
.toast.bad { background: var(--red); color: #ffffff; }

/* Responsive Breakpoints */
.mobile-nav { display: none; }

@media (max-width: 1120px) {
  .today { grid-template-columns: 1fr; }
  .bento-home { grid-template-columns: 1fr 1fr; }
  .bento-col:last-child { grid-column: span 2; display: grid; grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .app-frame { padding: 10px 12px 76px; gap: 10px; }
  .top-nav { flex-wrap: nowrap; gap: 8px; }
  .brand-meta { display: none; }
  .pill-dock { display: none; }
  .bento-home, .bento-col:last-child, .split, .two {
    grid-template-columns: 1fr;
    height: auto;
  }
  .full-chat-stage {
    height: calc(100vh - 144px);
    min-height: 380px;
  }
  .fc-emp-info small { max-width: 140px; }
  .bento-col:last-child { grid-column: span 1; }
  #global-search, #global-search:focus { width: 130px; height: 40px; }
  .circle-btn, .logo-circle { width: 40px; height: 40px; }
  .profile-meta { display: none; }
  .profile-pill { padding: 2px; height: 40px; }
  .drawer-backdrop { padding: 0; }
  .drawer-panel { max-width: 100%; border-radius: 0; }
  .toast { bottom: 74px; right: 16px; left: 16px; text-align: center; }

  .mobile-nav {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    position: fixed;
    bottom: 10px;
    left: 12px;
    right: 12px;
    height: 60px;
    background: #0f1e46;
    border-radius: 999px;
    box-shadow: var(--shadow-float);
    z-index: 70;
    padding: 0 6px;
  }
  .mobile-nav a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    font-size: 10px;
    font-weight: 650;
    color: rgba(255, 255, 255, 0.65);
  }
  .mobile-nav a svg { width: 18px; height: 18px; }
  .mobile-nav a.active { color: var(--lime); font-weight: 800; }
}
