:root {
  --bg: #f4f6f8;
  --surface: #ffffff;
  --surface-2: #eef2f5;
  --ink: #15181c;
  --muted: #68717c;
  --soft: #98a1ad;
  --line: #dbe1e7;
  --accent: #e14639;
  --accent-soft: #fff0ed;
  --blue: #265f92;
  --green: #167161;
  --amber: #ad6a18;
  --violet: #6957a7;
  --nav: #111820;
  --nav-soft: #1d2731;
  --shadow: 0 18px 52px rgba(21, 24, 28, 0.1);
  --text-xs: 11px;
  --text-sm: 12px;
  --text-base: 13px;
  --text-md: 15px;
  --text-lg: 18px;
  --text-xl: 24px;
  --text-display: clamp(38px, 4vw, 56px);
  --fw-regular: 520;
  --fw-medium: 650;
  --fw-semibold: 720;
  --fw-bold: 800;
  --fw-heavy: 900;
  color-scheme: light;
}

@keyframes overlayFadeIn {
  from {
    background: rgba(17, 24, 32, 0);
    backdrop-filter: blur(0);
  }
  to {
    background: rgba(17, 24, 32, 0.46);
    backdrop-filter: blur(10px);
  }
}

@keyframes modalFloatIn {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  overflow: auto;
  padding: 32px;
  background: #edf0f2;
}

.auth-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(380px, 0.95fr);
  width: min(100%, 1040px);
  min-height: 620px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.auth-brand-panel,
.auth-form-panel {
  min-width: 0;
  padding: clamp(36px, 5vw, 64px);
}

.auth-brand-panel {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 48px;
  background: var(--nav);
  color: #fff;
}

.auth-brand-lockup {
  display: flex;
  align-items: center;
  gap: 12px;
}

.auth-brand-lockup .brand-mark {
  width: 42px;
  height: 42px;
}

.auth-brand-lockup strong,
.auth-brand-lockup span {
  display: block;
}

.auth-brand-lockup strong {
  font-size: var(--text-lg);
}

.auth-brand-lockup span {
  margin-top: 2px;
  color: rgba(255, 255, 255, 0.56);
  font-size: var(--text-sm);
  font-weight: var(--fw-medium);
}

.auth-brand-panel h1 {
  max-width: 520px;
  margin: 0;
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1.08;
}

.auth-brand-panel p {
  max-width: 500px;
  margin: 16px 0 0;
  color: rgba(255, 255, 255, 0.66);
  font-size: var(--text-md);
}

.auth-brand-panel small {
  color: rgba(255, 255, 255, 0.42);
}

.auth-form-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.auth-form-head h2 {
  margin: 0;
  font-size: 30px;
  line-height: 1.15;
}

.auth-form-head p {
  margin: 8px 0 0;
  color: var(--muted);
}

.auth-mode-toggle {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  margin: 28px 0 22px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.auth-mode-toggle button {
  min-height: 40px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-weight: var(--fw-medium);
}

.auth-mode-toggle button.active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 4px rgba(21, 24, 28, 0.08);
}

.auth-form {
  display: grid;
  gap: 16px;
}

.auth-field {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: var(--text-sm);
  font-weight: var(--fw-medium);
}

.auth-field input {
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  outline: none;
  background: var(--surface);
  color: var(--ink);
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.auth-field input:focus {
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(21, 24, 28, 0.08);
}

.auth-error {
  min-height: 20px;
  margin: 0;
  color: var(--accent);
  font-size: var(--text-sm);
}

.auth-submit {
  min-height: 46px;
  border: 0;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  font-weight: var(--fw-semibold);
}

.auth-submit:disabled {
  cursor: wait;
  opacity: 0.62;
}

.auth-note {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: var(--text-xs);
}

.session-user {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding-left: 10px;
  border-left: 1px solid var(--line);
}

.session-avatar {
  display: grid;
  place-items: center;
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  font-size: var(--text-sm);
  font-weight: var(--fw-semibold);
}

.session-user-copy {
  display: grid;
  min-width: 0;
}

.session-user-copy strong,
.session-user-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.session-user-copy strong {
  max-width: 140px;
  font-size: var(--text-sm);
}

.session-user-copy small {
  color: var(--muted);
  font-size: var(--text-xs);
}

@media (max-width: 760px) {
  .auth-gate {
    place-items: start center;
    padding: 16px;
  }

  .auth-shell {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
  }

  .auth-brand-panel,
  .auth-form-panel {
    padding: 28px 24px;
  }

  .auth-brand-panel {
    gap: 28px;
  }

  .auth-brand-panel h1 {
    font-size: 32px;
  }

  .auth-brand-panel small {
    display: none;
  }

  .session-user-copy {
    display: none;
  }
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background:
    linear-gradient(rgba(24, 32, 40, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(24, 32, 40, 0.035) 1px, transparent 1px),
    linear-gradient(180deg, rgba(255, 255, 255, 0.76), rgba(255, 255, 255, 0)),
    var(--bg);
  background-size: 36px 36px, 36px 36px, auto;
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: var(--text-base);
  line-height: 1.45;
  letter-spacing: 0;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  display: grid;
  grid-template-columns: 276px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding: 24px 18px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(225, 70, 57, 0.12), rgba(225, 70, 57, 0)),
    var(--nav);
  backdrop-filter: blur(16px);
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 42px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--accent);
  color: white;
  font-weight: 760;
}

.brand-lockup strong,
.brand-lockup span {
  display: block;
}

.brand-lockup strong {
  color: #ffffff;
  font-size: 15px;
}

.brand-lockup span,
.signal-panel span,
.sidebar-section p,
.eyebrow {
  color: var(--muted);
  font-size: 11px;
  font-weight: 720;
  text-transform: uppercase;
}

.sidebar .brand-lockup span,
.sidebar .sidebar-section p,
.sidebar .signal-panel span,
.sidebar .signal-panel small {
  color: rgba(255, 255, 255, 0.56);
}

.nav-list,
.sidebar-section {
  display: grid;
  gap: 6px;
}

.nav-item,
.type-filter {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 38px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  text-align: left;
}

.sidebar .nav-item,
.sidebar .type-filter {
  color: rgba(255, 255, 255, 0.66);
}

.nav-item {
  gap: 10px;
  padding: 0 11px;
  font-weight: 660;
}

.customer-nav-item .nav-caret {
  margin-left: auto;
  color: rgba(255, 255, 255, 0.46);
  font-size: 12px;
  transition: transform 0.18s ease;
}

.customer-subnav {
  display: grid;
  gap: 4px;
  margin: -2px 0 4px 34px;
  padding-left: 10px;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
  max-height: 260px;
  opacity: 1;
  transition: max-height 0.22s ease, opacity 0.18s ease, margin 0.22s ease;
}

.customer-subnav.collapsed {
  max-height: 0 !important;
  height: 0;
  margin-top: -6px;
  margin-bottom: 0;
  padding-top: 0;
  padding-bottom: 0;
  opacity: 0;
  pointer-events: none;
}

.nav-icon {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  color: var(--soft);
  font-size: 17px;
}

.sidebar .nav-icon {
  color: rgba(255, 255, 255, 0.42);
}

.nav-item.active,
.type-filter.active {
  border-color: rgba(225, 70, 57, 0.18);
  background: var(--accent-soft);
  color: var(--ink);
}

.sidebar .nav-item.active,
.sidebar .type-filter.active {
  border-color: rgba(225, 70, 57, 0.38);
  background: rgba(225, 70, 57, 0.16);
  color: #ffffff;
}

.sidebar .nav-item:hover,
.sidebar .type-filter:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #ffffff;
}

.type-filter {
  justify-content: space-between;
  padding: 0 10px;
  font-size: 13px;
  min-height: 34px;
}

.sidebar-section p {
  margin: 0 0 7px;
  padding-left: 10px;
}

.signal-panel {
  margin-top: auto;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.sidebar .signal-panel {
  border-color: rgba(255, 255, 255, 0.1);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.045));
}

.sidebar .signal-panel strong {
  color: #ffffff;
}

.signal-panel strong,
.signal-panel small {
  display: block;
}

.signal-panel strong {
  margin-top: 8px;
  font-size: 18px;
}

.signal-panel small {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.45;
}

.main-panel {
  min-width: 0;
  padding: 28px clamp(18px, 3vw, 38px) 38px;
}

.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 28px;
}

.eyebrow {
  margin: 0 0 7px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: var(--text-display);
  font-weight: var(--fw-heavy);
  line-height: 1;
}

h2 {
  margin-bottom: 6px;
  font-size: var(--text-lg);
  line-height: 1.22;
}

h3 {
  margin-bottom: 8px;
  font-size: var(--text-md);
  line-height: 1.28;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.language-toggle {
  display: flex;
  gap: 3px;
  height: 40px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
}

.language-toggle button {
  min-width: 44px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.language-toggle button.active {
  background: var(--ink);
  color: #ffffff;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(360px, 34vw);
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
}

.search-box input {
  width: 100%;
  min-width: 80px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
}

.icon-command,
.primary-command,
.secondary-command {
  min-height: 40px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font-weight: 680;
}

.icon-command {
  width: 40px;
  padding: 0;
}

.primary-command {
  padding: 0 15px;
  border-color: var(--accent);
  background: var(--accent);
  color: white;
  white-space: nowrap;
}

.primary-action-wrap {
  display: grid;
  gap: 4px;
  justify-items: end;
  min-width: 140px;
}

.primary-action-wrap .primary-command {
  width: 100%;
}

.primary-action-wrap small {
  max-width: 190px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  line-height: 1.25;
  text-align: right;
}

.secondary-command {
  padding: 0 13px;
}

.primary-command:disabled,
.secondary-command:disabled {
  cursor: not-allowed;
  opacity: 0.52;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.today-command {
  display: grid;
  grid-template-columns: minmax(340px, 0.75fr) minmax(420px, 1fr);
  align-items: stretch;
  gap: 10px;
  margin-bottom: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 10px 26px rgba(21, 24, 28, 0.045);
}

.today-action-stack {
  display: grid;
  grid-template-columns: minmax(210px, 0.7fr) minmax(0, 1.3fr);
  align-items: stretch;
  gap: 8px;
}

.today-command-copy {
  display: grid;
  align-content: center;
  gap: 6px;
  min-height: 0;
  padding: 12px 14px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.34);
}

.today-command-copy span {
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: var(--fw-bold);
  text-transform: uppercase;
}

.today-command-copy h2 {
  max-width: 560px;
  font-size: clamp(24px, 2.6vw, 36px);
  font-weight: var(--fw-heavy);
  line-height: 1.06;
}

.today-command-copy p {
  max-width: 560px;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: 1.5;
}

.today-role-focus {
  display: grid;
  gap: 2px;
  margin-top: 6px;
  padding: 7px 9px;
  border: 1px solid rgba(225, 70, 57, 0.15);
  border-radius: 8px;
  background: rgba(255, 249, 247, 0.78);
}

.today-role-focus span {
  color: var(--accent);
  font-size: var(--text-xs);
  font-weight: var(--fw-bold);
}

.today-role-focus strong {
  font-size: var(--text-sm);
  line-height: 1.25;
}

.today-role-focus small {
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: 720;
  line-height: 1.35;
}

.today-signal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.today-signal-grid div {
  min-height: 34px;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.58);
}

.today-signal-grid span,
.today-signal-grid strong {
  display: block;
}

.today-signal-grid span {
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: var(--fw-semibold);
}

.today-signal-grid strong {
  margin-top: 3px;
  font-size: 20px;
  line-height: 1;
}

.today-mention-strip,
.today-queue-hint {
  display: grid;
  gap: 6px;
  padding: 7px 9px;
  border: 1px solid rgba(225, 70, 57, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 240, 237, 0.75), rgba(255, 255, 255, 0.86)),
    var(--surface);
}

.today-queue-hint {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  min-height: 36px;
}

.today-queue-hint span {
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
}

.today-queue-hint strong {
  min-width: 0;
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: 760;
  line-height: 1.35;
}

.today-mention-inline {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.today-mention-inline button,
.today-empty-inline {
  min-height: 48px;
  padding: 7px 9px;
  text-align: left;
  border: 1px solid rgba(225, 70, 57, 0.18);
  border-radius: 8px;
  background: rgba(255, 249, 247, 0.92);
}

.today-empty-inline {
  grid-column: 1 / -1;
}

.today-mention-inline button {
  cursor: pointer;
}

.today-mention-inline button:hover {
  border-color: rgba(225, 70, 57, 0.38);
  box-shadow: 0 10px 24px rgba(21, 24, 28, 0.08);
}

.today-mention-inline span,
.today-empty-inline span {
  display: inline-flex;
  width: max-content;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(225, 70, 57, 0.1);
  color: var(--accent);
  font-size: 10px;
  font-weight: 900;
}

.today-mention-inline strong,
.today-empty-inline strong {
  display: -webkit-box;
  margin-top: 5px;
  overflow: hidden;
  color: var(--ink);
  font-size: 11px;
  line-height: 1.32;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.today-mention-inline small {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

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

.today-mention-head span {
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
}

.today-mention-head strong {
  display: none;
}

.today-mention-head small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 760;
}

.command-banner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 18px;
  min-height: 196px;
  margin-bottom: 16px;
  overflow: hidden;
  border: 1px solid rgba(21, 24, 28, 0.1);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(17, 24, 32, 0.98), rgba(31, 47, 59, 0.98)),
    var(--nav);
  color: #ffffff;
  box-shadow: var(--shadow);
}

.command-banner::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), #f0b64c 34%, #2e9f8f 66%, #6d7ee8);
}

.banner-copy {
  position: relative;
  z-index: 1;
  max-width: 680px;
  padding: 26px;
}

.banner-copy span {
  display: inline-flex;
  margin-bottom: 18px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 11px;
  font-weight: 820;
  text-transform: uppercase;
}

.banner-copy strong {
  display: block;
  max-width: 620px;
  font-size: clamp(28px, 4.3vw, 52px);
  line-height: 0.98;
  letter-spacing: 0;
}

.banner-copy p {
  max-width: 520px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 15px;
  line-height: 1.55;
}

.radar-card {
  position: relative;
  align-self: stretch;
  min-height: 190px;
  margin: 18px 18px 18px 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background:
    linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    rgba(255, 255, 255, 0.055);
  background-size: 38px 38px;
}

.radar-grid {
  position: absolute;
  inset: 28px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
}

.radar-grid span {
  position: absolute;
  inset: 16%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: inherit;
}

.radar-grid span:nth-child(2) {
  inset: 31%;
}

.radar-grid span:nth-child(3) {
  inset: 46%;
}

.radar-grid span:nth-child(4) {
  inset: 0;
  border-style: dashed;
}

.radar-node {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.12);
}

.radar-node.primary {
  top: 48%;
  left: 48%;
  width: 16px;
  height: 16px;
  background: var(--accent);
  box-shadow: 0 0 0 8px rgba(225, 70, 57, 0.18);
}

.node-a {
  top: 22%;
  right: 24%;
  background: #f0b64c;
}

.node-b {
  bottom: 24%;
  left: 24%;
  background: #2e9f8f;
}

.node-c {
  bottom: 30%;
  right: 16%;
  background: #6d7ee8;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.metric-strip:empty {
  display: none;
}

.mention-notification-center {
  display: grid;
  grid-template-columns: minmax(260px, 0.36fr) minmax(0, 1fr);
  gap: 12px;
  margin: 0 0 14px;
  padding: 14px;
  border: 1px solid rgba(225, 70, 57, 0.2);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 240, 237, 0.92), rgba(255, 255, 255, 0.9) 55%),
    var(--surface);
  box-shadow: 0 14px 36px rgba(21, 24, 28, 0.07);
}

.revenue-overview {
  display: grid;
  grid-template-columns: minmax(220px, 0.28fr) minmax(0, 1fr);
  gap: 10px;
  margin: 0 0 12px;
  padding: 12px;
  border: 1px solid rgba(38, 95, 146, 0.2);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(240, 246, 252, 0.96), rgba(255, 255, 255, 0.92) 56%),
    var(--surface);
  box-shadow: 0 10px 26px rgba(21, 24, 28, 0.045);
}

.revenue-overview-head span {
  color: var(--blue);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.revenue-overview-head p {
  max-width: 360px;
  margin-top: 7px;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: 1.42;
}

.revenue-period-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.revenue-period-grid article {
  min-height: 92px;
  padding: 12px;
  border: 1px solid rgba(219, 225, 231, 0.86);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.88);
}

.revenue-period-grid article.receivable {
  background: rgba(255, 248, 232, 0.76);
}

.revenue-period-grid span,
.revenue-period-grid strong,
.revenue-period-grid small {
  display: block;
}

.revenue-period-grid span {
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: var(--fw-bold);
}

.revenue-period-grid strong {
  margin-top: 8px;
  color: var(--ink);
  font-size: var(--text-xl);
  letter-spacing: 0;
}

.revenue-period-grid small {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.mention-center-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.mention-center-head span {
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.mention-center-head h2 {
  margin-top: 6px;
  font-size: var(--text-xl);
}

.mention-center-head p {
  margin-top: 5px;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: 1.4;
}

.mention-center-head > strong {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: var(--accent);
  color: #ffffff;
  font-size: 22px;
}

.mention-alert-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.mention-alert-list.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.mention-alert {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 4px;
  min-height: 32px;
  padding: 6px 8px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.88);
}

.mention-alert.unread {
  border-color: rgba(225, 70, 57, 0.28);
  background: rgba(255, 249, 247, 0.98);
}

.mention-alert span {
  width: max-content;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(225, 70, 57, 0.1);
  color: var(--accent);
  font-size: 10px;
  font-weight: 900;
}

.mention-alert strong {
  font-size: var(--text-xs);
  line-height: 1.32;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.mention-alert small,
.mention-empty {
  color: var(--muted);
  font-size: var(--text-xs);
  line-height: 1.3;
}

.mention-alert-list.compact .mention-alert small {
  display: none;
}

.metric {
  position: relative;
  overflow: hidden;
  min-height: 78px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(249, 251, 252, 0.98)),
    var(--surface);
  box-shadow: 0 8px 22px rgba(21, 24, 28, 0.045);
}

.metric::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--metric-color, var(--accent));
}

.metric:nth-child(2) {
  --metric-color: #f0b64c;
}

.metric:nth-child(3) {
  --metric-color: #2e9f8f;
}

.metric:nth-child(4) {
  --metric-color: #6d7ee8;
}

.metric span {
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: var(--fw-bold);
}

.metric strong {
  display: block;
  margin-top: 8px;
  font-size: var(--text-xl);
  line-height: 1;
}

.metric small {
  display: block;
  margin-top: 7px;
  color: var(--muted);
}

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.work-surface,
.intelligence-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

.work-surface {
  overflow: hidden;
}

.section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 15px 18px;
  border-bottom: 1px solid var(--line);
}

.section-head.wide {
  margin-bottom: 14px;
  padding: 0 0 14px;
  border-bottom: 1px solid var(--line);
}

.section-head p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: 1.42;
}

.queue-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.segmented {
  display: flex;
  gap: 3px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.segmented button {
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.segmented button.active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 2px 8px rgba(33, 25, 20, 0.07);
}

.role-segmented {
  max-width: 100%;
}

.role-segmented button {
  white-space: nowrap;
}

.priority-empty-state {
  display: grid;
  gap: 6px;
  padding: 28px 18px;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
}

.priority-empty-state strong {
  color: var(--ink);
  font-size: 16px;
}

.priority-empty-state span {
  color: var(--muted);
  font-size: 13px;
}

.account-row {
  display: grid;
  grid-template-columns: minmax(170px, 1.25fr) minmax(116px, 0.85fr) minmax(104px, 0.65fr) minmax(118px, 0.75fr) minmax(120px, 0.78fr) minmax(116px, 0.72fr) 88px;
  align-items: center;
  gap: 12px;
  min-height: 76px;
  padding: 0 18px;
  border-right: 0;
  border-bottom: 0;
  border-left: 0;
  border-top: 1px solid var(--line);
  background: transparent;
  color: inherit;
  text-align: left;
}

.account-row:first-child {
  border-top: 0;
}

.account-row.header {
  min-height: 38px;
  background: rgba(238, 242, 245, 0.78);
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.account-row.data {
  border-left: 3px solid transparent;
  width: 100%;
}

.account-row.data:hover,
.account-row.data.selected {
  border-left-color: var(--accent);
  background: linear-gradient(90deg, rgba(255, 240, 237, 0.74), rgba(255, 255, 255, 0.9));
}

#priorityTable {
  overflow-x: auto;
}

.priority-row {
  display: grid;
  grid-template-columns:
    minmax(320px, 1.35fr)
    minmax(150px, 0.72fr)
    112px
    minmax(150px, 0.72fr)
    minmax(190px, 1fr)
    130px
    66px;
  align-items: center;
  gap: 12px;
  min-width: 1180px;
  min-height: 70px;
  padding: 0 14px;
  border: 0;
  border-top: 1px solid var(--line);
  background: transparent;
  color: inherit;
  text-align: left;
}

.priority-row:first-child {
  border-top: 0;
}

.priority-row.header {
  min-height: 36px;
  background: rgba(238, 242, 245, 0.78);
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: var(--fw-bold);
  text-transform: uppercase;
}

.priority-row.data {
  border-left: 3px solid transparent;
  width: 100%;
}

.priority-row.data:hover,
.priority-row.data.selected {
  border-left-color: var(--accent);
  background: linear-gradient(90deg, rgba(255, 240, 237, 0.74), rgba(255, 255, 255, 0.9));
}

.priority-row > span {
  min-width: 0;
  overflow: hidden;
}

.priority-row .subtle,
.priority-row .row-context-name,
.priority-row .row-context-meta {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.priority-row .account-name strong {
  color: var(--ink);
  font-size: var(--text-md);
  font-weight: var(--fw-bold);
  line-height: 1.25;
  max-width: 100%;
}

.priority-row .account-name small {
  margin-top: 3px;
  font-size: var(--text-xs);
  max-width: 100%;
}

.priority-row .logo-dot {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  font-size: var(--text-base);
}

.priority-row .row-context-tags {
  display: none;
}

.priority-row .owner-pair > span {
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
  font-size: var(--text-sm);
}

.priority-row .owner-pair b {
  display: block;
  margin-bottom: 2px;
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: var(--fw-bold);
  text-transform: none;
}

.priority-row .subtle {
  color: #303842;
  font-size: var(--text-sm);
  line-height: 1.4;
  max-width: 100%;
}

.priority-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(220px, 1fr));
  gap: 10px;
  padding: 14px;
}

.priority-project-card {
  display: grid;
  gap: 11px;
  min-height: 236px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  color: inherit;
  text-align: left;
  box-shadow: 0 10px 24px rgba(21, 24, 28, 0.04);
}

.priority-project-card:hover,
.priority-project-card.selected {
  border-color: rgba(225, 70, 57, 0.34);
  background: linear-gradient(180deg, rgba(255, 249, 247, 0.96), #ffffff);
}

.priority-card-top {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.priority-card-top strong,
.priority-card-top small {
  display: block;
}

.priority-card-top small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.priority-card-top strong {
  font-size: var(--text-md);
  font-weight: var(--fw-bold);
  line-height: 1.25;
}

.priority-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.priority-card-focus,
.priority-card-next {
  display: grid;
  gap: 5px;
  padding: 11px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.68);
}

.priority-card-focus {
  background: rgba(238, 242, 245, 0.82);
}

.priority-card-focus span,
.priority-card-next span,
.priority-card-footer b {
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: var(--fw-bold);
  text-transform: uppercase;
}

.priority-card-focus strong,
.priority-card-next strong {
  font-size: var(--text-sm);
  line-height: 1.35;
}

.priority-card-footer {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  margin-top: auto;
}

.priority-card-footer span {
  display: block;
  min-height: 48px;
  padding: 8px;
  border: 1px solid rgba(219, 225, 231, 0.76);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  font-size: 12px;
  font-weight: 720;
}

.priority-card-footer b {
  display: block;
  margin-bottom: 3px;
}

.account-name {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}

.account-name > span:last-child {
  min-width: 0;
}

.logo-dot {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: #111820;
  color: #ffffff;
  font-weight: 760;
}

.account-name strong,
.account-name small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.app-version-badge {
  position: fixed;
  right: 14px;
  bottom: 12px;
  z-index: 30;
  padding: 5px 9px;
  border: 1px solid rgba(219, 225, 231, 0.9);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 10px 24px rgba(21, 24, 28, 0.08);
  backdrop-filter: blur(8px);
}

.account-name small,
.subtle {
  color: var(--muted);
  font-size: 12px;
}

.row-context-name,
.row-context-meta {
  display: block;
  min-width: 0;
}

.row-context-name {
  font-size: var(--text-sm);
  line-height: 1.25;
}

.row-context-meta {
  margin-top: 3px;
  color: var(--muted);
  font-size: var(--text-xs);
  line-height: 1.25;
}

.row-context-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 6px;
}

.pill,
.stage-pill,
.priority-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  min-height: 22px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-size: var(--text-xs);
  font-weight: var(--fw-bold);
  white-space: nowrap;
}

.pill {
  color: var(--blue);
  border-color: rgba(49, 93, 124, 0.24);
  background: rgba(49, 93, 124, 0.08);
}

.type-ai-model-and-infra {
  color: #245b91;
  border-color: rgba(38, 95, 146, 0.25);
  background: rgba(38, 95, 146, 0.09);
}

.type-ai-agents {
  color: #8a4f12;
  border-color: rgba(240, 182, 76, 0.42);
  background: rgba(240, 182, 76, 0.14);
}

.type-ai-hardware {
  color: #156c5d;
  border-color: rgba(46, 159, 143, 0.3);
  background: rgba(46, 159, 143, 0.1);
}

.type-physical-ai {
  color: #5a4ea0;
  border-color: rgba(109, 126, 232, 0.3);
  background: rgba(109, 126, 232, 0.1);
}

.type-tech-brands {
  color: #c13e34;
  border-color: rgba(225, 70, 57, 0.28);
  background: rgba(225, 70, 57, 0.09);
}

.stage-pill {
  color: var(--green);
  border-color: rgba(37, 113, 99, 0.22);
  background: rgba(37, 113, 99, 0.08);
}

.priority-pill.hot {
  color: var(--accent);
  border-color: rgba(225, 70, 57, 0.26);
  background: var(--accent-soft);
}

.priority-pill.warm {
  color: var(--amber);
  border-color: rgba(168, 101, 35, 0.24);
  background: rgba(168, 101, 35, 0.08);
}

.priority-pill.watch {
  color: var(--violet);
  border-color: rgba(101, 85, 143, 0.22);
  background: rgba(101, 85, 143, 0.08);
}

.intelligence-panel {
  position: sticky;
  top: 24px;
  padding: 16px;
  overflow: hidden;
}

.intelligence-panel::before {
  content: "";
  display: block;
  height: 4px;
  margin: -16px -16px 16px;
  background: linear-gradient(90deg, var(--accent), #f0b64c, #2e9f8f, #6d7ee8);
}

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

.intel-title strong,
.intel-title span {
  display: block;
}

.intel-title strong {
  font-size: 20px;
}

.intel-title span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}

.score-ring {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, var(--surface) 56%, transparent 57%),
    conic-gradient(var(--accent) 0deg, var(--accent) var(--score), var(--surface-2) var(--score), var(--surface-2) 360deg);
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
}

.action-focus-card {
  display: grid;
  gap: 7px;
  margin-bottom: 12px;
  padding: 13px;
  border: 1px solid rgba(225, 70, 57, 0.22);
  border-radius: 8px;
  background: rgba(255, 240, 237, 0.74);
}

.action-focus-card span,
.action-focus-card small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.action-focus-card span {
  font-weight: 820;
}

.action-focus-card strong {
  line-height: 1.35;
}

.intel-block {
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.intel-block:first-of-type {
  border-top: 0;
}

.intel-block h3 {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.channel-list,
.moment-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.play-card {
  padding: 13px;
  border-radius: 8px;
  background: var(--surface-2);
}

.play-card strong,
.play-card span {
  display: block;
}

.play-card span {
  margin-top: 7px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.activity-list {
  display: grid;
  gap: 12px;
}

.activity {
  display: grid;
  grid-template-columns: 10px 1fr;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
}

.activity::before {
  content: "";
  width: 8px;
  height: 8px;
  margin-top: 5px;
  border-radius: 50%;
  background: var(--accent);
}

.account-directory {
  display: grid;
  gap: 14px;
}

.account-summary-section,
.customer-list-card {
  min-width: 0;
}

.subsection-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 4px 0 10px;
}

.subsection-head h3 {
  font-size: 15px;
}

.subsection-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 720;
}

.directory-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.directory-card,
.pipeline-column,
.campaign-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.directory-card {
  position: relative;
  display: block;
  width: 100%;
  color: inherit;
  text-align: left;
  overflow: hidden;
  min-height: 205px;
  padding: 16px;
  font: inherit;
  cursor: pointer;
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.directory-card:hover {
  transform: translateY(-1px);
  border-color: rgba(225, 70, 57, 0.22);
  box-shadow: 0 16px 36px rgba(21, 24, 28, 0.075);
}

.directory-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--card-color, var(--accent));
}

.type-card-ai-model-and-infra {
  --card-color: #265f92;
}

.type-card-ai-agents {
  --card-color: #f0b64c;
}

.type-card-ai-hardware {
  --card-color: #2e9f8f;
}

.type-card-physical-ai {
  --card-color: #6d7ee8;
}

.type-card-tech-brands {
  --card-color: #e14639;
}

.directory-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}

.directory-card p {
  min-height: 38px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.mini-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 14px;
}

.mini-stat {
  padding: 9px;
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(238, 242, 245, 0.9), rgba(247, 249, 251, 0.9));
}

.mini-stat strong,
.mini-stat span {
  display: block;
}

.mini-stat strong {
  font-size: 17px;
}

.mini-stat span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.customer-list-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
}

.customer-directory-table {
  overflow: hidden;
  border: 1px solid rgba(219, 225, 231, 0.72);
  border-radius: 8px;
  background: #ffffff;
}

.empty-state {
  padding: 18px;
  border: 1px dashed rgba(104, 113, 124, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
  color: var(--muted);
  font-size: 13px;
  font-weight: 680;
}

.open-detail-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(38, 95, 146, 0.18);
  border-radius: 999px;
  background: rgba(38, 95, 146, 0.08);
  color: var(--blue);
  font-size: 11px;
  font-weight: 820;
}

.open-detail-pill.needs-opportunity {
  border-color: rgba(225, 70, 57, 0.28);
  background: rgba(225, 70, 57, 0.08);
  color: var(--accent);
}

.split-row-actions {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.customer-directory-row:hover .open-detail-pill.needs-opportunity {
  border-color: rgba(225, 70, 57, 0.28);
  background: rgba(225, 70, 57, 0.08);
  color: var(--accent);
}

.pipeline-board {
  display: grid;
  grid-template-columns: repeat(6, minmax(180px, 1fr));
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.pipeline-dragging,
.pipeline-dragging * {
  cursor: grabbing !important;
}

.pipeline-column {
  position: relative;
  min-width: 190px;
  min-height: 620px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.78);
  transition: border-color 0.22s ease, background 0.22s ease, box-shadow 0.22s ease, transform 0.22s ease;
}

.pipeline-column.drag-over {
  border-color: rgba(225, 70, 57, 0.42);
  background:
    linear-gradient(180deg, rgba(255, 240, 237, 0.7), rgba(255, 255, 255, 0.88)),
    #ffffff;
  box-shadow:
    inset 0 0 0 1px rgba(225, 70, 57, 0.2),
    0 18px 44px rgba(225, 70, 57, 0.08);
  transform: translateY(-2px);
}

.pipeline-column.drag-over::after {
  content: "";
  position: absolute;
  inset: 44px 10px 10px;
  pointer-events: none;
  border: 1px dashed rgba(225, 70, 57, 0.28);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(225, 70, 57, 0.055), rgba(240, 182, 76, 0.045));
  animation: dropZoneBreath 1.05s ease-in-out infinite;
}

.pipeline-column.drop-success {
  animation: columnSuccess 0.62s ease;
}

.pipeline-column:nth-child(-n + 3) {
  border-color: rgba(38, 95, 146, 0.18);
  background:
    linear-gradient(180deg, rgba(240, 246, 252, 0.92), rgba(255, 255, 255, 0.82)),
    #ffffff;
}

.setup-column {
  border-color: rgba(225, 70, 57, 0.24);
  background:
    linear-gradient(180deg, rgba(255, 240, 237, 0.82), rgba(255, 255, 255, 0.8)),
    #ffffff;
}

.brief-column {
  border-color: rgba(240, 182, 76, 0.35);
  background:
    linear-gradient(180deg, rgba(255, 247, 229, 0.88), rgba(255, 255, 255, 0.82)),
    #ffffff;
}

.column-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  min-height: 86px;
  margin-bottom: 8px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(219, 225, 231, 0.82);
  color: var(--muted);
}

.column-head strong {
  display: block;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.2;
}

.column-head small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.35;
}

.column-head > span {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  min-width: 25px;
  height: 25px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--ink);
  font-size: 12px;
  font-weight: 820;
}

.column-owner {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  margin-bottom: 4px;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(21, 24, 28, 0.06);
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.deal-card {
  margin-top: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 8px 20px rgba(21, 24, 28, 0.055);
  cursor: grab;
  user-select: none;
  transform-origin: center;
  transition: transform 0.22s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.18s ease, box-shadow 0.22s ease, border-color 0.22s ease, background 0.22s ease;
  will-change: transform;
}

.deal-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(21, 24, 28, 0.085);
}

.deal-card.dragging {
  opacity: 0.72;
  cursor: grabbing;
  transform: translateY(-8px) rotate(1deg) scale(1.025);
  border-color: rgba(225, 70, 57, 0.32);
  background: linear-gradient(180deg, #ffffff, rgba(255, 248, 244, 0.98));
  box-shadow: 0 24px 52px rgba(21, 24, 28, 0.18);
}

.deal-card.stage-landed {
  animation: cardLanded 0.72s cubic-bezier(0.2, 0.8, 0.2, 1);
  border-color: rgba(22, 113, 97, 0.26);
}

.pipeline-dragging .deal-card:not(.dragging) {
  transition-duration: 0.28s;
}

.deal-card strong,
.deal-card span,
.deal-card small {
  display: block;
}

.deal-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.work-object-label {
  width: fit-content;
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.deal-card-top strong {
  min-width: 0;
  font-size: 13px;
  line-height: 1.25;
}

.deal-card-top small {
  flex: 0 0 auto;
  margin-top: 0;
  color: var(--accent);
  font-size: 13px;
  font-weight: 820;
  text-align: right;
}

.deal-card span {
  margin-top: 7px;
  color: var(--muted);
  font-size: 12px;
}

.pipeline-card-tools {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  align-items: center;
  margin-top: 8px;
}

.pipeline-editor label {
  display: grid;
  gap: 4px;
}

.pipeline-editor label > span {
  margin-top: 0;
  color: var(--muted);
  font-size: 9px;
  font-weight: 850;
  text-transform: uppercase;
}

.pipeline-editor select,
.pipeline-editor input,
.pipeline-editor textarea {
  width: 100%;
  min-height: 31px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.9);
  color: var(--ink);
  font: inherit;
  font-size: 11px;
  font-weight: 720;
}

.pipeline-editor select,
.pipeline-editor input {
  padding: 0 8px;
}

.drag-only-hint {
  display: inline-flex;
  margin-top: 0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 780;
}

.pipeline-editor textarea {
  min-height: 58px;
  padding: 8px;
  resize: vertical;
  line-height: 1.35;
}

.mini-command {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 31px;
  padding: 0 9px;
  border: 1px solid rgba(21, 24, 28, 0.12);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font-size: 11px;
  font-weight: 820;
  cursor: pointer;
}

.mini-command:hover {
  border-color: rgba(225, 70, 57, 0.32);
  color: var(--accent);
}

.deal-card .event-account {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  padding: 4px 7px;
  border-radius: 999px;
  background: rgba(38, 95, 146, 0.08);
  color: var(--blue);
  font-size: 10px;
  font-weight: 760;
}

.pipeline-next-step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 8px;
  margin-top: 8px;
  padding: 8px;
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.86);
}

.pipeline-next-step span,
.pipeline-next-step strong {
  margin: 0;
  min-width: 0;
}

.pipeline-next-step span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 820;
}

.pipeline-next-step strong {
  color: var(--ink);
  font-size: 11px;
  line-height: 1.25;
}

.owner-rail {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 8px;
}

.owner-rail span {
  margin-top: 0;
  padding: 5px 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(238, 242, 245, 0.72);
  color: var(--ink);
  font-size: 10px;
}

.owner-rail b,
.reminder-card b,
.partner-rule b {
  display: block;
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 850;
  text-transform: uppercase;
}

.source-chip {
  margin-top: 8px;
  padding: 7px 8px;
  border-radius: 8px;
  background: rgba(38, 95, 146, 0.08);
  color: var(--blue);
  font-size: 11px;
  font-weight: 720;
}

.reminder-card {
  margin-top: 8px;
  padding: 7px 8px;
  border: 1px solid rgba(225, 70, 57, 0.18);
  border-radius: 8px;
  background: rgba(255, 240, 237, 0.58);
}

.reminder-card span {
  margin-top: 0;
  color: var(--ink);
  font-size: 10px;
  line-height: 1.35;
}

.gate-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 8px;
}

.gate-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  position: relative;
  margin-top: 0;
  padding: 4px 7px 4px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #ffffff;
  color: var(--muted);
  font-size: 9px;
  font-weight: 760;
}

.gate-chip::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 8px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--soft);
}

.gate-chip b {
  color: inherit;
  font-size: 8px;
  font-weight: 860;
}

.gate-chip.complete {
  border-color: rgba(22, 113, 97, 0.22);
  background: rgba(22, 113, 97, 0.08);
  color: var(--green);
}

.gate-chip.complete::before {
  background: var(--green);
}

.gate-chip.current {
  border-color: rgba(225, 70, 57, 0.28);
  background: rgba(255, 240, 237, 0.68);
  color: var(--accent);
}

.gate-chip.current::before {
  background: var(--accent);
}

.gate-chip.future {
  border-color: rgba(219, 225, 231, 0.96);
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
}

.pipeline-editor {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
  padding: 10px;
  border: 1px solid rgba(38, 95, 146, 0.16);
  border-radius: 8px;
  background: rgba(240, 246, 252, 0.72);
}

.pipeline-editor .wide {
  grid-column: 1 / -1;
}

.setup-deal {
  border-color: rgba(225, 70, 57, 0.22);
}

.brief-deal {
  border-color: rgba(240, 182, 76, 0.34);
}

.ops-note-grid {
  display: grid;
  gap: 7px;
  margin-top: 12px;
  padding: 10px;
  border: 1px solid rgba(240, 182, 76, 0.28);
  border-radius: 8px;
  background: rgba(255, 248, 232, 0.72);
}

.ops-note-grid span {
  display: block;
  margin-top: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.ops-note-grid b {
  display: block;
  margin-bottom: 2px;
  color: var(--ink);
  font-size: 10px;
  font-weight: 820;
  text-transform: uppercase;
}

.setup-list {
  display: grid;
  gap: 6px;
  margin-top: 12px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(255, 240, 237, 0.72);
}

.setup-list span {
  position: relative;
  margin-top: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.setup-list span::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 10px;
  height: 10px;
  border: 1px solid rgba(104, 113, 124, 0.42);
  border-radius: 50%;
  background: #ffffff;
}

.setup-list span.done {
  color: var(--ink);
  font-weight: 760;
}

.setup-list span.done::before {
  border-color: var(--accent);
  background: var(--accent);
  box-shadow: inset 0 0 0 2px #ffffff;
}

.campaign-board,
.product-board-inner {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.campaign-board {
  grid-template-columns: 1fr;
}

.campaign-board-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.campaign-revenue-panel,
.people-overview-card,
.people-list-panel,
.people-map-card {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.06);
}

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

.campaign-revenue-grid div,
.campaign-money-grid div,
.campaign-payment-row div {
  padding: 9px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.76);
}

.campaign-revenue-grid span,
.campaign-money-grid span,
.campaign-payment-row span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.campaign-revenue-grid strong,
.campaign-money-grid strong,
.campaign-payment-row strong {
  display: block;
  margin-top: 5px;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.2;
}

.campaign-revenue-grid div:nth-child(2) strong {
  color: var(--green);
}

.campaign-revenue-grid div:nth-child(3) strong,
.campaign-revenue-grid div:nth-child(4) strong {
  color: var(--accent);
}

.partner-board {
  display: grid;
  gap: 14px;
}

.product-board {
  display: grid;
  gap: 16px;
}

.product-section,
.partner-list-panel {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.06);
}

.product-section .section-head {
  margin-bottom: 12px;
}

.product-section:first-child {
  border-color: rgba(240, 182, 76, 0.34);
  background:
    linear-gradient(135deg, rgba(255, 250, 238, 0.72), rgba(255, 255, 255, 0.94) 48%),
    #ffffff;
}

.product-section:first-child .section-head {
  border-bottom-color: rgba(240, 182, 76, 0.34);
}

.template-board {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.template-card {
  position: relative;
  overflow: hidden;
  padding: 16px;
  border-color: rgba(240, 182, 76, 0.42);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 252, 244, 0.96), rgba(255, 255, 255, 0.98)),
    #ffffff;
  box-shadow: 0 16px 40px rgba(168, 101, 35, 0.1);
}

.template-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: linear-gradient(180deg, #f0b64c, var(--accent));
}

.template-card-top,
.template-hero-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.template-card-top {
  margin-left: 6px;
}

.template-card-top strong {
  color: var(--accent);
  white-space: nowrap;
}

.template-badge,
.product-kind-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.template-badge {
  border: 1px solid rgba(240, 182, 76, 0.44);
  background: rgba(240, 182, 76, 0.15);
  color: #8a4f12;
}

.product-kind-badge {
  margin: 0 0 8px;
  border: 1px solid rgba(49, 93, 124, 0.18);
  background: rgba(49, 93, 124, 0.08);
  color: var(--blue);
}

.template-hero-row {
  justify-content: flex-start;
  margin: 14px 0;
  padding-left: 6px;
}

.template-icon {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: #111820;
  color: #ffffff;
  font-size: 20px;
  font-weight: 900;
}

.template-hero-row h3 {
  font-size: 18px;
}

.template-hero-row p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.template-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 10px 6px;
}

.template-facts div {
  min-height: 54px;
  padding: 9px;
  border-radius: 8px;
  background: rgba(255, 248, 232, 0.88);
}

.template-facts span,
.template-facts b,
.template-resource b,
.template-resource span {
  display: block;
}

.template-facts span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.template-facts b {
  margin-top: 5px;
  font-size: 16px;
}

.template-resource {
  margin: 0 0 10px 6px;
  padding: 12px;
  border-radius: 8px;
  background: rgba(255, 248, 232, 0.74);
}

.template-resource b {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.template-resource span {
  font-size: 13px;
  line-height: 1.4;
}

.template-components,
.sample-list-grid {
  display: grid;
  gap: 8px;
  margin: 10px 0;
  padding: 10px;
  border-radius: 8px;
  background: rgba(240, 246, 252, 0.76);
}

.template-components b,
.sample-list-grid b {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.template-components div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.template-components span {
  padding: 4px 7px;
  border-radius: 999px;
  background: #ffffff;
  color: var(--blue);
  font-size: 11px;
  font-weight: 760;
}

.sample-list-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.sample-list-grid span {
  display: block;
  margin-top: 4px;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.35;
}

.brief-template-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0 18px 12px;
}

.brief-template {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  min-height: 70px;
  padding: 14px;
  border: 1px solid rgba(240, 182, 76, 0.38);
  border-radius: 8px;
  background: rgba(255, 250, 238, 0.86);
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.18s ease,
    background 0.18s ease;
}

.brief-template.selected {
  border-color: rgba(225, 70, 57, 0.34);
  background: linear-gradient(135deg, rgba(255, 245, 232, 0.95), rgba(255, 255, 255, 0.96));
  box-shadow: inset 3px 0 0 var(--accent);
}

.brief-template:hover {
  border-color: rgba(225, 70, 57, 0.34);
  box-shadow: 0 14px 28px rgba(18, 24, 33, 0.06);
  transform: translateY(-1px);
}

.brief-template strong,
.brief-template small {
  display: block;
}

.brief-template strong {
  color: var(--ink);
  font-size: 15px;
  line-height: 1.25;
}

.brief-template small,
.brief-template span {
  color: var(--muted);
  font-size: 12px;
}

.brief-template small {
  margin-top: 5px;
}

.brief-template-meta {
  display: grid;
  flex: 0 0 auto;
  gap: 4px;
  justify-items: end;
  align-content: start;
  min-width: 96px;
  text-align: right;
}

.brief-template-meta b {
  color: var(--accent);
  font-size: 14px;
  font-weight: 900;
  line-height: 1.1;
  white-space: nowrap;
}

.selected-template-products {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  margin: 0 18px 14px;
  padding: 13px 14px;
  border: 1px solid rgba(38, 95, 146, 0.12);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(238, 242, 245, 0.92), rgba(255, 255, 255, 0.82));
}

.selected-template-products span,
.selected-template-products small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 820;
}

.selected-template-products strong {
  display: block;
  margin-top: 6px;
  line-height: 1.25;
}

.selected-template-products small {
  margin-top: 6px;
  line-height: 1.35;
}

.selected-template-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-content: center;
}

.selected-template-chip-list span {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  padding: 0 10px;
  border-radius: 999px;
  background: #ffffff;
  color: var(--blue);
  font-size: 11px;
  font-weight: 850;
}

.save-template-defaults {
  white-space: nowrap;
}

.partner-card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.people-library {
  display: grid;
  gap: 14px;
}

.people-overview-card {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.people-library-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 14px;
  align-items: start;
}

.people-table {
  display: grid;
  gap: 10px;
}

.people-library-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: inherit;
  cursor: pointer;
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.people-library-row:hover {
  border-color: rgba(225, 70, 57, 0.32);
  box-shadow: 0 12px 28px rgba(21, 24, 28, 0.08);
  transform: translateY(-1px);
}

.people-row-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  min-width: 164px;
}

.people-row-main > p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.people-row-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 9px;
}

.people-row-tags span {
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(238, 242, 245, 0.78);
  color: var(--ink);
  font-size: 11px;
  font-weight: 760;
}

.people-row-detail {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.people-row-detail div {
  min-height: 64px;
  padding: 9px;
  border-radius: 8px;
  background: rgba(240, 246, 252, 0.72);
}

.people-row-detail b,
.people-row-detail span {
  display: block;
}

.people-row-detail b {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.people-row-detail span {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.35;
}

.people-map-panel {
  display: grid;
  gap: 14px;
}

.people-network-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.people-network-list article {
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.56);
}

.people-network-list span,
.people-network-list strong,
.people-network-list small {
  display: block;
}

.people-network-list span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 820;
}

.people-network-list strong {
  margin-top: 4px;
}

.people-network-list small {
  margin-top: 5px;
  color: var(--amber);
  line-height: 1.35;
}

.people-detail-hero {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) minmax(280px, 0.42fr);
  gap: 16px;
  align-items: center;
  margin-bottom: 14px;
  padding: 18px;
  border: 1px solid rgba(219, 225, 231, 0.9);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(17, 24, 32, 0.96), rgba(34, 51, 65, 0.94)),
    var(--nav);
  color: #ffffff;
  box-shadow: 0 20px 48px rgba(21, 24, 28, 0.16);
}

.people-detail-avatar {
  display: grid;
  place-items: center;
  width: 66px;
  height: 66px;
  border-radius: 8px;
  background: var(--accent);
  color: #ffffff;
  font-size: 30px;
  font-weight: 900;
}

.people-detail-hero h2 {
  margin-top: 8px;
  color: #ffffff;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 0.95;
}

.people-detail-hero p,
.people-detail-hero .detail-status-line span {
  color: rgba(255, 255, 255, 0.72);
}

.people-detail-hero .pill {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.86);
}

.people-detail-next {
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
}

.people-detail-next span,
.people-detail-next strong {
  display: block;
}

.people-detail-next span {
  margin-bottom: 7px;
  color: rgba(255, 255, 255, 0.58);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.people-detail-next strong {
  color: #ffffff;
  font-size: 16px;
  line-height: 1.35;
}

.people-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 14px;
  align-items: start;
}

.people-detail-main,
.people-detail-side,
.people-side-stack {
  display: grid;
  gap: 14px;
}

.people-profile-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.people-profile-grid div,
.people-side-stack div,
.people-related-account,
.people-related-person {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.66);
}

.people-profile-grid span,
.people-side-stack span,
.people-related-account span,
.people-related-person span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.people-profile-grid strong,
.people-side-stack strong,
.people-related-account strong,
.people-related-person strong {
  display: block;
  margin-top: 7px;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.3;
}

.people-detail-timeline {
  display: grid;
  gap: 12px;
}

.people-detail-timeline article {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
}

.people-detail-timeline article > span {
  width: 10px;
  height: 10px;
  margin-top: 8px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(225, 70, 57, 0.1);
}

.people-detail-timeline article > div {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.people-detail-timeline small,
.people-detail-timeline strong,
.people-detail-timeline p,
.people-detail-timeline em,
.people-related-account small,
.people-related-person small {
  display: block;
}

.people-detail-timeline small,
.people-related-account small,
.people-related-person small {
  color: var(--muted);
  font-size: 12px;
}

.people-detail-timeline strong {
  margin-top: 5px;
  font-size: 16px;
}

.people-detail-timeline p {
  margin-top: 7px;
  color: var(--muted);
  line-height: 1.45;
}

.people-detail-timeline em {
  margin-top: 8px;
  color: var(--blue);
  font-size: 12px;
  font-style: normal;
  font-weight: 760;
}

.people-related-account,
.people-related-person {
  width: 100%;
  text-align: left;
}

.people-related-account:hover,
.people-related-person:hover {
  border-color: rgba(49, 93, 124, 0.28);
  background: rgba(240, 246, 252, 0.9);
}

.team-board {
  display: grid;
  gap: 14px;
}

.team-overview-card,
.team-flow-card,
.team-role-section {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.06);
}

.team-overview-card {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(0, 1.2fr);
  gap: 16px;
  align-items: end;
  padding: 18px;
  border-top: 3px solid var(--red);
}

.team-overview-card > div:first-child > span,
.team-linked-work span,
.team-next-duty span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.team-overview-card h3 {
  margin-top: 6px;
  font-size: 22px;
}

.team-overview-card p {
  max-width: 620px;
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.45;
}

.team-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.team-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 14px;
  align-items: start;
}

.team-role-board {
  display: grid;
  gap: 14px;
}

.team-role-section {
  padding: 14px;
}

.team-role-section.role-marketing {
  border-left: 4px solid #f0b64c;
}

.team-role-section.role-project {
  border-left: 4px solid #2ea99b;
}

.team-role-section.role-finance {
  border-left: 4px solid #286da8;
}

.team-role-section.role-legal {
  border-left: 4px solid #6f7ff0;
}

.team-role-section.role-ceo {
  border-left: 4px solid var(--red);
}

.team-role-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.team-role-head h3 {
  margin-top: 6px;
}

.team-role-head > strong {
  min-width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(238, 242, 245, 0.9);
}

.team-role-badge {
  display: inline-flex;
  width: max-content;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(238, 242, 245, 0.9);
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.team-member-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.team-member-card {
  display: grid;
  gap: 12px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 0%, rgba(247, 250, 252, 0.82) 100%);
}

.team-member-top {
  display: flex;
  gap: 10px;
  align-items: center;
}

.team-member-top h4,
.team-member-top span {
  display: block;
}

.team-member-top span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.team-work-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.team-work-grid div {
  min-height: 58px;
  padding: 9px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.team-work-grid strong,
.team-work-grid span {
  display: block;
}

.team-work-grid span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 780;
}

.team-responsibility-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.team-responsibility-list b {
  width: 100%;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.team-responsibility-list span {
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(233, 245, 243, 0.9);
  color: #176f65;
  font-size: 11px;
  font-weight: 780;
}

.team-linked-work,
.team-next-duty {
  display: grid;
  gap: 5px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--line);
}

.team-linked-work strong,
.team-next-duty strong {
  font-size: 12px;
  line-height: 1.35;
}

.team-flow-card {
  position: sticky;
  top: 18px;
  padding: 16px;
}

.team-flow-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.team-flow-list article {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 11px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.7);
}

.team-flow-list article > span {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #ffffff;
  color: var(--red);
  font-weight: 900;
}

.team-flow-list strong,
.team-flow-list small {
  display: block;
}

.team-flow-list small {
  margin-top: 4px;
  color: var(--muted);
}

.partner-overview-card {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.partner-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.partner-side-panel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  min-width: 0;
  gap: 12px;
}

.campaign-card,
.partner-card,
.product-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.07);
}

.product-card {
  box-shadow: 0 8px 24px rgba(21, 24, 28, 0.045);
}

.campaign-head,
.partner-head,
.product-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.campaign-head {
  margin-bottom: 14px;
}

.campaign-source-brief {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: -4px 0 12px;
  padding: 9px 10px;
  border: 1px solid rgba(32, 105, 165, 0.14);
  border-radius: 8px;
  background: #f5f9fc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.campaign-source-brief strong {
  color: var(--ink);
}

.campaign-source-brief em {
  margin-left: auto;
  color: var(--accent);
  font-style: normal;
}

.campaign-title-block {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.campaign-title-block h3 {
  max-width: 560px;
  font-size: 30px;
  line-height: 1.08;
  letter-spacing: 0;
}

.campaign-brand-lockup {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.campaign-logo {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 10px;
  background:
    linear-gradient(135deg, rgba(225, 70, 57, 0.92), rgba(17, 24, 32, 0.98));
  color: #ffffff;
  font-size: 24px;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(21, 24, 28, 0.18);
}

.campaign-brand-lockup strong,
.campaign-brand-lockup small {
  display: block;
}

.campaign-brand-lockup strong {
  font-size: 16px;
}

.campaign-brand-lockup small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.campaign-payment-row {
  display: grid;
  grid-template-columns: minmax(0, 0.48fr) minmax(0, 1fr);
  gap: 8px;
  margin-top: 8px;
}

.campaign-window-row {
  display: grid;
  grid-template-columns: minmax(180px, 0.42fr) minmax(0, 1fr);
  gap: 8px;
  margin: 8px 0;
}

.campaign-window-row > div {
  display: grid;
  align-content: start;
  gap: 6px;
  min-height: 58px;
  padding: 9px;
  border: 1px solid rgba(219, 225, 231, 0.92);
  border-radius: 8px;
  background: rgba(248, 250, 251, 0.9);
}

.campaign-window-row > div:first-child {
  border-color: rgba(46, 159, 143, 0.28);
  background: linear-gradient(135deg, rgba(237, 249, 246, 0.95), rgba(255, 255, 255, 0.96));
}

.campaign-money-grid.compact {
  margin-top: 8px;
}

.release-window-card strong {
  color: var(--green);
}

.campaign-window-row span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.campaign-window-row strong {
  color: var(--ink);
  font-size: 17px;
  line-height: 1.2;
}

.campaign-window-row textarea {
  width: 100%;
  min-height: 38px;
  resize: vertical;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 12px;
  line-height: 1.35;
}

.campaign-product-closeouts {
  margin: 10px 0 8px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.campaign-subhead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.campaign-subhead strong {
  color: var(--ink);
  font-size: 13px;
}

.campaign-subhead span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.campaign-closeout-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.campaign-closeout-item {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 9px;
  border: 1px solid rgba(219, 225, 231, 0.92);
  border-radius: 8px;
  background: rgba(248, 250, 251, 0.82);
}

.campaign-closeout-item span {
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.25;
}

.campaign-closeout-item textarea {
  width: 100%;
  min-height: 42px;
  resize: vertical;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 12px;
  line-height: 1.35;
}

.campaign-payment-row strong {
  font-size: 13px;
}

.product-head span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.product-head .product-kind-badge {
  display: inline-flex;
  margin: 0 0 8px;
  color: var(--blue);
  font-size: 11px;
  line-height: 1;
}

.product-head strong {
  color: var(--accent);
  white-space: nowrap;
}

.product-resource {
  margin: 14px 0;
  padding: 12px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.product-resource b {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
}

.product-resource span {
  color: var(--ink);
  font-size: 13px;
  line-height: 1.4;
}

.owner-pair {
  display: grid;
  gap: 4px;
}

.owner-pair > span {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  min-height: 22px;
  align-items: center;
  gap: 5px;
  padding: 0 8px;
  border: 1px solid rgba(104, 113, 124, 0.18);
  border-radius: 999px;
  background: rgba(238, 242, 245, 0.82);
  color: var(--ink);
  font-size: 10px;
  font-weight: 760;
}

.owner-pair b {
  color: var(--muted);
  font-size: 9px;
  font-weight: 850;
  text-transform: uppercase;
}

.partner-config-card,
.contract-queue-card {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.06);
}

.partner-config-card p,
.contract-queue-card p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.partner-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
  margin-top: 14px;
}

.partner-form label:nth-child(3),
.partner-form button {
  grid-column: 1 / -1;
}

.partner-form label {
  display: grid;
  gap: 6px;
}

.partner-form label span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.partner-form input {
  width: 100%;
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
  font-size: 12px;
  font-weight: 680;
}

.contract-mini {
  margin-top: 10px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(240, 246, 252, 0.78);
}

.contract-mini b,
.contract-mini span {
  display: block;
}

.contract-mini b {
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
}

.contract-mini span {
  margin-top: 4px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 720;
}

.contract-table {
  overflow: hidden;
  margin-top: 12px;
  border: 1px solid rgba(219, 225, 231, 0.82);
  border-radius: 8px;
  background: #ffffff;
}

.contract-row {
  display: grid;
  grid-template-columns: minmax(140px, 0.8fr) minmax(180px, 1fr) minmax(120px, 0.6fr) minmax(220px, 1.2fr);
  gap: 12px;
  align-items: center;
  min-height: 64px;
  padding: 10px 14px;
  border-top: 1px solid var(--line);
  font-size: 12px;
}

.compact-contract-table .contract-row {
  grid-template-columns: 1fr;
  gap: 8px;
  align-items: start;
}

.compact-contract-table .contract-row span:last-child {
  display: grid;
  gap: 5px;
}

.contract-row:first-child {
  border-top: 0;
}

.contract-row.header {
  min-height: 38px;
  background: rgba(238, 242, 245, 0.78);
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.contract-row strong,
.contract-row small {
  display: block;
}

.contract-row small {
  margin-top: 3px;
  color: var(--muted);
}

.customer-status-pill {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  min-height: 22px;
  margin-top: 6px;
  padding: 0 8px;
  border: 1px solid rgba(104, 113, 124, 0.18);
  border-radius: 999px;
  background: rgba(238, 242, 245, 0.82);
  color: var(--muted);
  font-size: 10px;
  font-weight: 820;
  line-height: 20px;
}

.customer-status-pill.status-blue {
  border-color: rgba(38, 95, 146, 0.2);
  background: rgba(38, 95, 146, 0.09);
  color: var(--blue);
}

.customer-status-pill.status-green {
  border-color: rgba(22, 113, 97, 0.22);
  background: rgba(22, 113, 97, 0.09);
  color: var(--green);
}

.customer-status-pill.status-amber {
  border-color: rgba(240, 182, 76, 0.34);
  background: rgba(255, 247, 229, 0.95);
  color: #8d5f08;
}

.customer-status-pill.status-red {
  border-color: rgba(225, 70, 57, 0.22);
  background: rgba(255, 240, 237, 0.88);
  color: var(--accent);
}

.customer-status-pill.status-purple {
  border-color: rgba(109, 126, 232, 0.22);
  background: rgba(109, 126, 232, 0.1);
  color: #4f5dc7;
}

.customer-status-pill.status-slate {
  border-color: rgba(104, 113, 124, 0.2);
  background: rgba(238, 242, 245, 0.88);
  color: var(--muted);
}

.product-card.editing,
.template-card.editing {
  border-color: rgba(225, 70, 57, 0.26);
  box-shadow: 0 16px 38px rgba(21, 24, 28, 0.09);
}

.product-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.product-editor {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 12px 0;
  padding: 12px;
  border: 1px solid rgba(38, 95, 146, 0.16);
  border-radius: 8px;
  background: rgba(240, 246, 252, 0.76);
}

.product-editor label {
  display: grid;
  gap: 5px;
}

.product-editor .wide {
  grid-column: 1 / -1;
}

.product-editor label > span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.product-editor input,
.product-editor textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
  font-size: 12px;
  font-weight: 680;
}

.product-editor input {
  min-height: 34px;
  padding: 0 9px;
}

.product-editor textarea {
  min-height: 64px;
  padding: 9px;
  resize: vertical;
  line-height: 1.4;
}

.product-editor-hero {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
  padding: 20px;
  border: 1px solid rgba(38, 95, 146, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(240, 246, 252, 0.96), rgba(255, 255, 255, 0.92) 62%),
    var(--surface);
  box-shadow: 0 14px 38px rgba(21, 24, 28, 0.06);
}

.product-editor-hero h2 {
  margin-top: 8px;
  font-size: clamp(34px, 4vw, 58px);
  line-height: 0.98;
}

.product-editor-hero p {
  max-width: 680px;
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.48;
}

.product-editor-meta {
  min-width: 260px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-self: end;
}

.product-editor-meta div {
  padding: 11px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--line);
}

.product-editor-meta span,
.product-editor-meta strong {
  display: block;
}

.product-editor-meta span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.product-editor-meta strong {
  margin-top: 5px;
}

.product-editor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 14px;
  align-items: start;
}

.product-editor-panel,
.product-change-log {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.06);
}

.product-editor.page-editor {
  margin: 12px 0 0;
  background: rgba(240, 246, 252, 0.52);
}

.product-change-log {
  position: sticky;
  top: 18px;
}

.product-log-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.product-log-item {
  display: grid;
  gap: 8px;
  padding: 11px;
  border: 1px solid rgba(219, 225, 231, 0.9);
  border-radius: 8px;
  background: rgba(250, 252, 254, 0.9);
}

.product-log-item strong,
.product-log-item span,
.product-log-item b {
  display: block;
}

.product-log-item span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.product-log-item p {
  margin: 0;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.35;
}

.product-log-item b {
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.empty-log {
  padding: 14px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
}

.partner-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 16px;
}

.partner-rule {
  margin-top: 12px;
  padding: 11px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.partner-rule span {
  color: var(--ink);
  font-size: 13px;
}

.partner-accounts {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.partner-command-card {
  display: grid;
  grid-template-columns: minmax(300px, 0.78fr) minmax(480px, 1.22fr);
  gap: 12px;
  align-items: stretch;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(247, 251, 252, 0.82));
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.055);
}

.partner-command-card h3 {
  max-width: 620px;
  margin-bottom: 6px;
  font-size: clamp(20px, 1.85vw, 30px);
  line-height: 1.08;
  letter-spacing: 0;
}

.partner-command-card p {
  max-width: 620px;
  margin-bottom: 0;
  color: var(--muted);
}

.partner-summary-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  align-content: stretch;
}

.partner-summary-strip .mini-stat {
  display: grid;
  align-content: center;
  min-height: 72px;
  background: rgba(238, 242, 245, 0.72);
}

.partner-table {
  overflow-x: visible;
  overflow-y: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
}

.partner-table-row {
  display: grid;
  grid-template-columns: minmax(190px, 1.05fr) minmax(92px, 0.42fr) minmax(180px, 0.92fr) minmax(128px, 0.5fr) minmax(176px, 220px);
  gap: 10px;
  align-items: center;
  min-width: 0;
  min-height: 70px;
  padding: 9px 10px;
  border-top: 1px solid var(--line);
  cursor: pointer;
  transition:
    background 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease;
}

.partner-table-row:first-child {
  border-top: 0;
}

.partner-table-row.header {
  min-height: 38px;
  background: rgba(238, 242, 245, 0.78);
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.partner-table-row.needs-action {
  background: linear-gradient(90deg, rgba(225, 70, 57, 0.055), rgba(255, 255, 255, 0.86) 42%);
}

.partner-table-row.selected {
  border-left: 3px solid var(--accent);
  background: linear-gradient(90deg, rgba(225, 70, 57, 0.095), rgba(255, 255, 255, 0.92) 52%);
  box-shadow: inset 0 0 0 1px rgba(225, 70, 57, 0.12);
}

.partner-table-row.header {
  cursor: default;
}

.partner-name-cell,
.partner-progress-cell,
.partner-rule-cell,
.partner-contract-cell,
.partner-action-cell {
  min-width: 0;
}

.partner-rule-cell {
  display: grid;
  gap: 5px;
}

.partner-action-cell {
  display: grid;
  gap: 4px;
  justify-items: stretch;
}

.partner-rule-cell .stage-pill {
  width: fit-content;
}

.partner-rule-cell small {
  margin-top: 0;
}

.partner-name-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.partner-avatar {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  background: var(--ink);
  color: #ffffff;
  font-weight: 850;
}

.partner-table-row strong,
.partner-table-row small,
.partner-focus-item strong,
.partner-focus-item small {
  display: block;
}

.partner-table-row strong {
  overflow: hidden;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.partner-table-row small {
  overflow: hidden;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.partner-empty-row {
  padding: 18px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.partner-action-cell .secondary-command {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 34px;
  padding: 6px 10px;
  font-size: 12px;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: clip;
  white-space: normal;
}

.partner-action-cell small {
  max-width: 100%;
  overflow: hidden;
  margin-top: 3px;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.partner-detail-panel {
  display: grid;
  gap: 12px;
  margin-top: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.045);
}

.partner-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.partner-detail-head h3 {
  margin: 3px 0 4px;
  font-size: 20px;
  line-height: 1.12;
}

.partner-detail-head p {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

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

.partner-detail-grid div,
.partner-contract-summary > div {
  min-width: 0;
  padding: 10px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.72);
}

.partner-detail-grid span,
.partner-contract-summary span,
.partner-detail-log > span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
}

.partner-detail-grid strong,
.partner-contract-summary strong {
  display: block;
  overflow: hidden;
  margin-top: 6px;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.3;
  text-overflow: ellipsis;
}

.partner-contract-summary {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  gap: 8px;
}

.partner-contract-summary small {
  display: block;
  overflow: hidden;
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.partner-detail-log {
  display: grid;
  gap: 8px;
}

.partner-detail-log article {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.partner-detail-log small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.partner-detail-log strong {
  display: block;
  margin-top: 5px;
  color: var(--ink);
  font-size: 13px;
}

.partner-detail-log p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.partner-filter-tabs {
  display: flex;
  gap: 4px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.76);
}

.partner-filter-tabs button {
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-weight: 780;
}

.partner-filter-tabs button.active {
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 5px 14px rgba(21, 24, 28, 0.08);
}

.partner-focus-card {
  padding: 14px;
  border: 1px solid rgba(225, 70, 57, 0.18);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255, 246, 244, 0.86), rgba(255, 255, 255, 0.9));
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.055);
}

.partner-focus-card p {
  color: var(--muted);
}

.partner-focus-list,
.partner-contract-list {
  display: grid;
  gap: 8px;
}

.partner-focus-item,
.partner-contract-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
}

.partner-focus-item span {
  flex: 0 0 auto;
  color: var(--accent);
  font-size: 12px;
  font-weight: 850;
}

.text-action {
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  color: var(--accent);
  font: inherit;
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.text-action:hover {
  text-decoration: underline;
}

.partner-contract-item strong {
  display: block;
  font-size: 12px;
}

.partner-contract-item small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.partner-config-card.compact {
  padding: 14px;
}

.partner-config-card.compact .partner-form label:nth-child(3) {
  grid-column: auto;
}

.partner-form .wide-field {
  grid-column: 1 / -1;
}

.stage-pill.tone-ready {
  color: var(--accent);
  border-color: rgba(225, 70, 57, 0.24);
  background: var(--accent-soft);
}

.stage-pill.tone-warn {
  color: #8a4f12;
  border-color: rgba(240, 182, 76, 0.42);
  background: rgba(240, 182, 76, 0.14);
}

.stage-pill.tone-done {
  color: var(--green);
  border-color: rgba(37, 113, 99, 0.22);
  background: rgba(37, 113, 99, 0.08);
}

.stage-pill.tone-neutral {
  color: var(--muted);
  background: rgba(238, 242, 245, 0.78);
}

.stage-pill.blocked {
  color: var(--brand);
  border-color: rgba(225, 70, 57, 0.24);
  background: #fff3f0;
}

@media (max-width: 1180px) {
  .partner-command-card,
  .partner-layout {
    grid-template-columns: 1fr;
  }

  .partner-table-row {
    grid-template-columns: minmax(180px, 1fr) minmax(88px, 0.4fr) minmax(170px, 0.9fr) minmax(124px, 0.48fr) minmax(176px, 220px);
    min-width: 0;
  }

  .partner-action-cell {
    display: grid;
    grid-column: auto;
  }
}

@media (max-width: 760px) {
  .partner-summary-strip,
  .partner-form {
    grid-template-columns: 1fr;
  }

  .partner-table-row,
  .partner-table-row.header {
    grid-template-columns: 1fr;
  }

  .partner-table-row.header {
    display: none;
  }

  .partner-filter-tabs {
    width: 100%;
    overflow-x: auto;
  }

  .partner-action-cell {
    grid-template-columns: 1fr;
  }

  .draft-person-actions {
    grid-template-columns: 1fr;
  }

  .draft-person-control-block,
  .draft-person-picker,
  .draft-person-manual {
    grid-template-columns: 1fr;
  }
}

.deal-card {
  cursor: pointer;
}

.detail-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: -4px 0 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
}

.breadcrumb-back {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  font: inherit;
  font-size: 12px;
  font-weight: 820;
  cursor: pointer;
}

.breadcrumb-back span {
  font-size: 15px;
  line-height: 1;
}

.breadcrumb-back:hover {
  border-color: rgba(225, 70, 57, 0.28);
  color: var(--accent);
}

.detail-breadcrumb > span {
  color: rgba(104, 113, 124, 0.56);
}

.detail-breadcrumb strong {
  color: var(--ink);
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.46fr);
  gap: 18px;
  align-items: start;
  margin-bottom: 14px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(17, 24, 32, 0.98), rgba(31, 47, 59, 0.98)),
    var(--nav);
  color: #ffffff;
  box-shadow: var(--shadow);
}

.detail-title h2 {
  margin: 12px 0 8px;
  color: #ffffff;
  font-size: clamp(32px, 4vw, 56px);
  line-height: 0.95;
}

.detail-title p {
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.68);
}

.detail-status-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 12px;
}

.detail-status-line .customer-status-pill {
  margin-top: 0;
  background: rgba(255, 255, 255, 0.12);
}

.detail-status-line > span:last-child {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  line-height: 1.35;
}

.detail-hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(100px, 1fr));
  gap: 8px;
}

.detail-hero-stats div {
  min-width: 110px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
}

.detail-hero-stats span,
.overview-list span,
.commercial-grid span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.detail-hero-stats span {
  color: rgba(255, 255, 255, 0.56);
}

.detail-hero-stats strong {
  display: block;
  margin-top: 8px;
  color: #ffffff;
  font-size: 15px;
  line-height: 1.25;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 14px;
}

.action-hero {
  display: block;
  align-items: stretch;
  padding: 18px 20px;
}

.detail-action-panel {
  display: grid;
  gap: 10px;
  min-width: 380px;
  max-width: 520px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
}

.detail-action-panel span {
  color: rgba(255, 255, 255, 0.58);
  font-size: 10px;
  font-weight: 880;
  text-transform: uppercase;
}

.detail-action-panel strong {
  color: #ffffff;
  font-size: 17px;
  line-height: 1.3;
}

.detail-action-panel div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.detail-action-panel button:disabled {
  opacity: 0.52;
  cursor: not-allowed;
}

.detail-command-card {
  margin-bottom: 14px;
}

.project-command-center {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
  padding: 18px;
  border-color: rgba(225, 70, 57, 0.16);
  background:
    linear-gradient(135deg, rgba(255, 247, 244, 0.7), rgba(255, 255, 255, 0.96) 42%),
    #ffffff;
}

.project-command-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.35fr) minmax(260px, 0.9fr);
  gap: 10px;
}

.project-command-main,
.project-command-strategy,
.project-command-commercial div {
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.project-command-main,
.project-command-strategy {
  min-height: 96px;
  padding: 13px;
}

.project-command-main span,
.project-command-strategy span,
.project-command-commercial span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.project-command-main strong,
.project-command-strategy strong,
.project-command-commercial strong {
  display: block;
  margin-top: 7px;
  color: var(--ink);
  line-height: 1.25;
}

.project-command-main strong {
  font-size: 18px;
}

.project-command-strategy strong {
  color: var(--accent);
  font-size: 22px;
}

.project-command-main small,
.project-command-strategy small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.project-command-strategy {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  background: rgba(255, 240, 237, 0.62);
}

.project-command-commercial {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.project-command-commercial div {
  min-height: 62px;
  padding: 10px;
}

.project-command-commercial strong {
  font-size: 13px;
}

.project-command-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 2px;
}

.project-command-actions button:disabled {
  opacity: 0.52;
  cursor: not-allowed;
}

.project-command-solution {
  display: grid;
  gap: 12px;
  margin-top: 4px;
  padding-top: 14px;
  border-top: 1px solid rgba(217, 225, 232, 0.88);
}

.project-command-solution .section-head {
  padding: 0;
}

.project-command-solution .opportunity-solution-grid {
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.72fr);
}

.project-command-solution .strategy-brief-version,
.project-command-solution .confirmed-solution-card {
  background-color: rgba(255, 255, 255, 0.92);
}

.strategy-locked-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px;
  border: 1px dashed rgba(149, 163, 180, 0.55);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.86);
}

.strategy-locked-panel strong,
.strategy-locked-panel span {
  display: block;
}

.strategy-locked-panel strong {
  color: var(--ink);
  font-size: 15px;
}

.strategy-locked-panel span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.strategy-locked-panel em {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 7px 10px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
  box-shadow: inset 0 0 0 1px rgba(217, 225, 232, 0.9);
}

.account-start-card {
  border-color: rgba(99, 112, 126, 0.18);
  background:
    linear-gradient(135deg, rgba(241, 245, 249, 0.8), rgba(255, 255, 255, 0.97) 46%),
    #ffffff;
}

.account-start-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.account-start-grid div,
.account-start-people {
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.82);
  padding: 12px;
}

.account-start-grid span,
.account-start-people span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.account-start-grid strong,
.account-start-people strong {
  display: block;
  margin-top: 7px;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.3;
}

.account-start-people {
  display: grid;
  grid-template-columns: 120px repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-items: center;
}

.account-start-people span,
.account-start-people strong {
  margin-top: 0;
}

.handoff-check {
  display: grid;
  grid-template-columns: minmax(220px, 0.62fr) minmax(0, 1.38fr);
  gap: 12px;
  padding: 12px;
  border: 1px solid rgba(225, 70, 57, 0.18);
  border-radius: 8px;
  background: rgba(255, 250, 244, 0.78);
}

.handoff-blocker {
  display: grid;
  gap: 9px;
  padding: 12px;
  border: 1px solid rgba(225, 70, 57, 0.24);
  border-radius: 8px;
  background: rgba(255, 240, 237, 0.72);
}

.handoff-blocker strong {
  color: var(--accent);
  font-size: 13px;
}

.handoff-blocker div {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.handoff-blocker span {
  border-radius: 999px;
  padding: 6px 9px;
  background: rgba(255, 255, 255, 0.88);
  color: var(--accent);
  font-size: 11px;
  font-weight: 850;
  box-shadow: inset 0 0 0 1px rgba(225, 70, 57, 0.18);
}

.handoff-copy strong,
.handoff-copy span,
.handoff-copy em,
.handoff-copy p,
.handoff-copy small {
  display: block;
}

.handoff-copy strong {
  color: var(--ink);
  font-size: 15px;
}

.handoff-copy span {
  color: var(--accent);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.handoff-copy p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.handoff-copy small {
  margin-top: 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 780;
  line-height: 1.35;
}

.handoff-copy em {
  margin-top: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  font-style: normal;
  font-size: 11px;
  font-weight: 850;
}

.handoff-copy em.missing {
  color: var(--accent);
  background: rgba(225, 70, 57, 0.08);
  border: 1px solid rgba(225, 70, 57, 0.18);
}

.handoff-copy em.ready {
  color: var(--teal);
  background: rgba(39, 154, 137, 0.08);
  border: 1px solid rgba(39, 154, 137, 0.2);
}

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

.handoff-grid div {
  min-height: 68px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(217, 225, 232, 0.86);
}

.handoff-grid div.missing {
  background: rgba(255, 240, 237, 0.78);
  border-color: rgba(225, 70, 57, 0.22);
}

.handoff-grid div.missing strong {
  color: var(--accent);
}

.handoff-grid span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.handoff-grid strong {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.35;
}

.opportunity-hub-card {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.opportunity-hub-intro,
.confirmed-solution-card,
.strategy-brief-version {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
}

.opportunity-hub-intro {
  padding: 16px;
  background: linear-gradient(135deg, rgba(239, 246, 255, 0.8), rgba(255, 255, 255, 0.94));
}

.opportunity-hub-intro > span,
.confirmed-solution-card > div > span,
.strategy-brief-version span,
.confirmed-contract-grid span,
.opportunity-hub-meta b {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.opportunity-hub-intro strong {
  display: block;
  margin-top: 8px;
  color: var(--ink);
  font-size: 22px;
  line-height: 1.1;
}

.opportunity-hub-intro p,
.confirmed-solution-card p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.opportunity-hub-meta {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-top: 16px;
}

.opportunity-hub-meta div,
.confirmed-contract-grid div {
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.82);
  padding: 10px;
}

.opportunity-hub-meta span,
.confirmed-contract-grid strong {
  display: block;
  margin-top: 5px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
}

.strategy-brief-stack {
  display: grid;
  gap: 8px;
}

.opportunity-solution-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.72fr);
  gap: 12px;
  align-items: stretch;
}

.strategy-brief-stack-wide {
  grid-template-columns: minmax(0, 1fr);
}

.strategy-brief-version {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: start;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.strategy-brief-version.selected {
  border-color: rgba(225, 70, 57, 0.3);
  background: linear-gradient(135deg, rgba(255, 243, 240, 0.72), #ffffff);
}

.strategy-brief-version strong {
  display: block;
  margin-top: 4px;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.25;
}

.strategy-brief-version b {
  color: var(--accent);
  font-size: 15px;
}

.strategy-brief-version small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.strategy-brief-card-actions {
  display: grid;
  justify-items: end;
  gap: 8px;
}

.strategy-brief-card-actions .secondary-command {
  min-height: 30px;
  padding: 7px 9px;
  font-size: 12px;
  white-space: nowrap;
}

.strategy-module-row {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.strategy-module-row em,
.confirmed-module-list span {
  border-radius: 999px;
  background: #eef4f8;
  color: #25649a;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  line-height: 1;
  padding: 6px 8px;
}

.confirmed-solution-card {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(225, 70, 57, 0.2);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(255, 250, 240, 0.88), rgba(255, 255, 255, 0.94));
}

.confirmed-solution-card strong {
  display: block;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.25;
}

.confirmed-solution-head span,
.confirmed-next-step span,
.confirmed-contract-grid span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.confirmed-solution-head strong {
  font-size: 18px;
}

.confirmed-solution-head p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.confirmed-module-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.confirmed-contract-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.confirmed-contract-grid div,
.confirmed-next-step {
  padding: 10px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.82);
}

.confirmed-next-step small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.confirmed-solution-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.relationship-summary-card {
  display: grid;
  gap: 12px;
}

.relationship-summary-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.relationship-summary-head p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.relationship-summary-head .secondary-command {
  min-height: 32px;
  padding: 0 10px;
  font-size: 12px;
  white-space: nowrap;
}

.relationship-owner-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.relationship-owner-grid div {
  min-height: 58px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
  padding: 10px;
}

.relationship-owner-grid span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.relationship-owner-grid strong {
  display: block;
  margin-top: 7px;
  color: var(--ink);
  line-height: 1.25;
}

.relationship-person-list {
  display: grid;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.relationship-person {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.relationship-person-empty {
  padding: 10px;
  border: 1px dashed rgba(124, 135, 149, 0.38);
  border-radius: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
  background: rgba(238, 242, 245, 0.42);
}

.relationship-person strong,
.relationship-person small {
  display: block;
}

.relationship-person small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.opportunity-mini-stack {
  display: grid;
  grid-template-columns: 1fr;
  gap: 4px;
  margin-top: 8px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.75);
  padding: 8px;
}

.opportunity-mini-stack span {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.opportunity-mini-stack strong {
  color: var(--ink);
  font-size: 12px;
  line-height: 1.25;
}

.pipeline-handoff-readiness {
  display: grid;
  gap: 4px;
  margin-top: 8px;
  padding: 8px;
  border: 1px solid rgba(217, 225, 232, 0.9);
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.86);
}

.pipeline-handoff-readiness span,
.pipeline-handoff-readiness strong {
  margin: 0;
}

.pipeline-handoff-readiness span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.pipeline-handoff-readiness strong {
  color: var(--ink);
  font-size: 11px;
  line-height: 1.35;
}

.pipeline-handoff-readiness.missing {
  border-color: rgba(225, 70, 57, 0.22);
  background: rgba(255, 240, 237, 0.62);
}

.pipeline-handoff-readiness.missing strong {
  color: var(--accent);
}

.pipeline-handoff-readiness.ready {
  border-color: rgba(39, 154, 137, 0.24);
  background: rgba(39, 154, 137, 0.08);
}

.pipeline-handoff-readiness.ready strong {
  color: var(--teal);
}

.command-status-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.command-status-row div,
.primary-project-strip,
.compact-fact-list div,
.owner-hub-list div,
.detail-readiness-list div {
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.command-status-row div {
  min-height: 74px;
  padding: 12px;
}

.command-status-row span,
.primary-project-strip span,
.compact-fact-list span,
.owner-hub-list span,
.detail-readiness-list span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.command-status-row strong,
.primary-project-strip strong,
.compact-fact-list strong,
.owner-hub-list strong,
.detail-readiness-list strong {
  display: block;
  margin-top: 8px;
  color: var(--ink);
  line-height: 1.28;
}

.detail-stage-rail {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.detail-stage-rail span {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--muted);
  font-size: 11px;
  font-weight: 820;
}

.detail-stage-rail b {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: rgba(21, 24, 28, 0.08);
  color: var(--muted);
  font-size: 10px;
}

.detail-stage-rail span.complete {
  border-color: rgba(22, 113, 97, 0.18);
  background: rgba(22, 113, 97, 0.07);
  color: var(--green);
}

.detail-stage-rail span.complete b {
  background: var(--green);
  color: #ffffff;
}

.detail-stage-rail span.active {
  border-color: rgba(225, 70, 57, 0.28);
  background: rgba(255, 240, 237, 0.72);
  color: var(--accent);
}

.detail-stage-rail span.active b {
  background: var(--accent);
  color: #ffffff;
}

.detail-focus-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 14px;
  align-items: start;
}

.project-focus-card,
.project-portfolio-card,
.detail-timeline-card {
  min-width: 0;
}

.detail-main-stack {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.detail-side-stack {
  display: grid;
  gap: 12px;
}

.compact-card h3 {
  margin-bottom: 12px;
}

.primary-project-strip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  margin-top: 12px;
  padding: 12px;
}

.primary-project-strip small {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 12px;
}

.owner-hub-list,
.compact-fact-list,
.detail-readiness-list {
  display: grid;
  gap: 8px;
}

.owner-hub-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.owner-hub-list div,
.compact-fact-list div,
.detail-readiness-list div {
  min-height: 58px;
  padding: 10px;
}

.detail-readiness-list div.complete {
  background: rgba(22, 113, 97, 0.08);
}

.detail-readiness-list div.complete strong,
.detail-readiness-list div.complete span {
  color: var(--green);
}

.detail-readiness-list div.current {
  background: rgba(255, 240, 237, 0.72);
}

.detail-readiness-list div.current strong,
.detail-readiness-list div.current span {
  color: var(--accent);
}

.compact-actions {
  gap: 7px;
}

.detail-side-stack .strategy-entry-card {
  grid-column: auto;
}

.detail-side-stack .strategy-entry-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.detail-side-stack .strategy-entry-grid div {
  min-height: 58px;
}

.detail-side-stack .strategy-entry-footer {
  align-items: stretch;
  flex-direction: column;
}

.people-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.people-card-head p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.people-card-head .secondary-command {
  min-height: 32px;
  padding: 0 10px;
  font-size: 12px;
}

.people-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.person-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.person-avatar {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: #111820;
  color: #ffffff;
  font-weight: 820;
}

.person-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
}

.person-title strong {
  font-size: 14px;
}

.person-title span {
  padding: 4px 7px;
  border: 1px solid rgba(49, 93, 124, 0.2);
  border-radius: 999px;
  background: rgba(49, 93, 124, 0.08);
  color: var(--blue);
  font-size: 11px;
  font-weight: 760;
}

.person-main > p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.person-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin-top: 9px;
}

.person-meta-grid div {
  min-height: 48px;
  padding: 8px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.72);
}

.person-meta-grid span,
.person-meta-grid b,
.person-history span,
.person-history strong,
.person-mobility span,
.person-mobility strong {
  display: block;
}

.person-meta-grid span,
.person-history span,
.person-mobility span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.person-meta-grid b {
  margin-top: 5px;
  font-size: 12px;
  line-height: 1.3;
}

.person-history,
.person-mobility {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.person-history strong,
.person-mobility strong {
  margin-top: 4px;
  font-size: 12px;
  line-height: 1.45;
}

.person-mobility strong {
  color: var(--amber);
}

.detail-card {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.07);
}

.overview-list,
.commercial-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.overview-list div,
.commercial-grid div {
  min-height: 72px;
  padding: 11px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.overview-list strong,
.commercial-grid strong {
  display: block;
  margin-top: 8px;
  line-height: 1.35;
}

.detail-ai {
  margin-top: 12px;
}

.project-list,
.detail-timeline {
  display: grid;
  gap: 10px;
}

.project-portfolio-card {
  display: grid;
  gap: 14px;
}

.portfolio-money-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.portfolio-money-strip div {
  min-height: 58px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.portfolio-money-strip span,
.project-contract-row-meta span {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.portfolio-money-strip strong {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.15;
}

.project-pending-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 14px;
  border: 1px dashed rgba(49, 93, 124, 0.24);
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.52);
}

.project-pending-card span,
.project-pending-card em {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
  font-weight: 820;
}

.project-pending-card strong {
  display: block;
  margin-top: 5px;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.35;
}

.project-pending-card em {
  flex: 0 0 auto;
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #ffffff;
}

.portfolio-section {
  display: grid;
  gap: 10px;
}

.portfolio-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 2px;
}

.portfolio-section-head strong {
  font-size: 13px;
}

.portfolio-section-head span {
  display: inline-flex;
  min-width: 26px;
  height: 24px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(238, 242, 245, 0.92);
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.active-project-contracts {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.active-project-contract,
.history-project-row {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.18s ease,
    background 0.18s ease;
}

.active-project-contract:hover,
.history-project-row:hover {
  border-color: rgba(225, 70, 57, 0.32);
  box-shadow: 0 16px 34px rgba(18, 24, 33, 0.08);
  transform: translateY(-1px);
}

.active-project-contract {
  padding: 12px;
}

.active-project-contract.project-contract-row {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 1fr) auto;
  align-items: center;
  gap: 12px;
}

.active-project-contract.next-cycle {
  background: rgba(238, 242, 245, 0.42);
}

.active-project-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.active-project-title span,
.active-project-contract p,
.history-project-row span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.active-project-title strong,
.active-project-title span {
  display: block;
}

.active-project-title strong {
  margin-top: 4px;
}

.active-project-title b {
  color: var(--accent);
  white-space: nowrap;
}

.project-contract-row .active-project-title {
  min-width: 0;
}

.project-contract-row .active-project-title > div {
  min-width: 0;
}

.project-contract-row-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.project-contract-row-meta span {
  min-height: 34px;
  padding: 7px 8px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
  line-height: 1.35;
  text-transform: none;
}

.project-contract-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.project-contract-meta div {
  min-height: 54px;
  padding: 9px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.project-contract-meta span,
.project-contract-meta strong,
.history-project-row strong,
.history-project-row b {
  display: block;
}

.project-contract-meta span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.project-contract-meta strong {
  margin-top: 5px;
  font-size: 12px;
  line-height: 1.35;
}

.active-project-contract p {
  margin-top: 9px;
  padding-top: 9px;
  border-top: 1px solid var(--line);
}

.history-section {
  padding-top: 2px;
  border-top: 1px solid var(--line);
}

.history-project-list {
  display: grid;
  gap: 8px;
}

.history-project-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 16px;
  padding: 10px 12px;
}

.history-project-row > div:last-child {
  text-align: right;
}

.history-project-row b {
  font-size: 12px;
}

.project-open-link {
  min-height: 30px;
  padding: 0 11px;
  border: 1px solid rgba(38, 95, 146, 0.18);
  border-radius: 999px;
  background: #ffffff;
  color: var(--blue);
  font-size: 11px;
  font-weight: 850;
  cursor: pointer;
}

.active-project-contract .project-open-link {
  margin-top: 10px;
}

.project-contract-row .project-open-link {
  margin-top: 0;
  white-space: nowrap;
}

.project-open-link:hover {
  border-color: rgba(38, 95, 146, 0.34);
  background: rgba(38, 95, 146, 0.06);
}

.project-detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 18px;
  align-items: stretch;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: linear-gradient(135deg, #111b24, #20313e);
  color: #ffffff;
  box-shadow: 0 18px 40px rgba(13, 20, 29, 0.12);
}

.project-detail-hero h2 {
  margin: 12px 0 6px;
  font-size: clamp(40px, 5vw, 72px);
  line-height: 0.92;
  letter-spacing: 0;
}

.project-detail-hero p {
  color: rgba(255, 255, 255, 0.72);
  font-weight: 800;
}

.project-detail-status {
  display: grid;
  align-content: center;
  gap: 8px;
  min-height: 138px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
}

.project-detail-status span,
.project-detail-status small {
  color: rgba(255, 255, 255, 0.68);
  font-size: 12px;
  font-weight: 850;
}

.project-detail-status strong {
  font-size: 28px;
  line-height: 1.1;
}

.project-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 14px;
  margin-top: 14px;
  align-items: start;
}

.project-detail-main,
.project-detail-side {
  display: grid;
  gap: 14px;
}

.project-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.project-summary-grid div,
.project-delivery-note {
  min-height: 76px;
  padding: 12px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.project-summary-grid span,
.project-delivery-note span,
.project-record-timeline span,
.project-record-timeline small,
.project-switch-list span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.project-summary-grid strong,
.project-delivery-note strong {
  display: block;
  margin-top: 8px;
  line-height: 1.25;
}

.project-delivery-note {
  margin-top: 10px;
}

.project-record-timeline {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.project-record-timeline article {
  position: relative;
  padding: 13px 13px 13px 32px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.project-record-timeline article::before {
  position: absolute;
  top: 18px;
  left: 14px;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
  content: "";
}

.project-record-timeline strong {
  display: block;
  margin-top: 6px;
  font-size: 15px;
  line-height: 1.35;
}

.project-record-timeline p {
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.55;
}

.project-record-timeline small {
  margin-top: 8px;
}

.project-file-list,
.project-switch-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.project-file-list span {
  min-height: 42px;
  padding: 11px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
  color: var(--ink);
  font-size: 12px;
  font-weight: 850;
}

.project-switch-list button {
  display: grid;
  gap: 5px;
  width: 100%;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  text-align: left;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    background 0.18s ease;
}

.project-switch-list button.active {
  border-color: rgba(225, 70, 57, 0.28);
  background: rgba(225, 70, 57, 0.06);
}

.project-switch-list button:hover {
  border-color: rgba(38, 95, 146, 0.28);
}

.project-item {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.project-item span,
.detail-timeline span,
.detail-timeline small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
}

.project-item b {
  color: var(--accent);
}

.contract-workflow-card {
  grid-column: 1 / -1;
}

.campaign-contract-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.campaign-contract-item {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.contract-project-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.contract-project-head strong,
.contract-project-head span {
  display: block;
}

.contract-project-head > div > span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

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

.contract-meta-grid div {
  min-height: 62px;
  padding: 9px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.76);
}

.contract-meta-grid span,
.contract-meta-grid strong {
  display: block;
}

.contract-meta-grid span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.contract-meta-grid strong {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.35;
}

.contract-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.file-command {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font-size: 12px;
  font-weight: 780;
  cursor: pointer;
}

.file-command input {
  display: none;
}

.detail-timeline article {
  position: relative;
  padding: 12px 12px 12px 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.detail-timeline article::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 18px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.detail-timeline strong {
  display: block;
  margin-top: 5px;
  line-height: 1.4;
}

.product-builder-card {
  grid-column: 1 / -1;
}

.strategy-workspace-card {
  padding: 0;
  overflow: hidden;
  border-color: rgba(219, 225, 231, 0.92);
  background: rgba(255, 255, 255, 0.94);
}

.strategy-entry-card {
  grid-column: 1 / -1;
  border-color: rgba(225, 70, 57, 0.16);
  background:
    linear-gradient(135deg, rgba(255, 247, 244, 0.72), rgba(255, 255, 255, 0.96) 46%),
    #ffffff;
}

.strategy-entry-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.strategy-entry-grid div {
  min-height: 72px;
  padding: 12px;
  border-radius: 8px;
  background: rgba(240, 246, 252, 0.78);
}

.strategy-entry-grid span,
.strategy-entry-footer span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.strategy-entry-grid strong {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.25;
}

.strategy-entry-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(219, 225, 231, 0.82);
}

.strategy-entry-footer span {
  line-height: 1.4;
}

.strategy-hero {
  grid-template-columns: minmax(0, 1fr) minmax(420px, 0.66fr);
  align-items: center;
  margin-bottom: 12px;
  padding: 18px 20px;
}

.strategy-breadcrumb {
  margin-top: -2px;
}

.strategy-hero .detail-title h2 {
  margin: 10px 0 7px;
  font-size: clamp(36px, 3.8vw, 54px);
  line-height: 0.95;
}

.strategy-hero .detail-title p {
  font-size: 14px;
}

.strategy-hero .detail-status-line {
  margin-top: 8px;
}

.strategy-hero .detail-hero-stats div {
  min-height: 58px;
  padding: 10px;
}

.strategy-context-card {
  margin-bottom: 16px;
}

.strategy-context-card .overview-list {
  grid-template-columns: 1.1fr 1fr 0.8fr 1.35fr 1fr;
}

.strategy-create {
  min-height: 36px;
  white-space: nowrap;
}

.strategy-workspace-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 14px;
  padding: 18px;
  align-items: start;
}

.brief-editor-panel,
.brief-action-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.brief-editor-panel {
  min-height: 0;
  padding: 16px;
}

.brief-panel-title,
.strategy-product-section-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brief-panel-title > span,
.strategy-product-section-title > span {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  border-radius: 8px;
  background: var(--ink);
  color: #ffffff;
  font-size: 11px;
  font-weight: 900;
}

.brief-panel-title strong,
.strategy-product-section-title strong {
  display: block;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.25;
}

.brief-panel-title p,
.strategy-product-section-title p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.brief-action-panel {
  display: grid;
  grid-template-rows: auto auto auto 1fr;
  gap: 12px;
  position: sticky;
  top: 18px;
  padding: 14px;
  background:
    linear-gradient(180deg, rgba(255, 247, 244, 0.9), rgba(255, 255, 255, 0.98) 42%),
    #ffffff;
}

.brief-action-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.brief-action-title strong,
.brief-action-title span {
  display: block;
}

.brief-action-title strong {
  color: var(--ink);
  font-size: 15px;
  line-height: 1.25;
}

.brief-action-title span {
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(240, 182, 76, 0.14);
  color: #946120;
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}

.brief-action-value {
  padding: 14px;
  border: 1px solid rgba(225, 70, 57, 0.18);
  border-radius: 8px;
  background: #ffffff;
}

.brief-action-value span,
.brief-action-value small,
.brief-action-list span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.brief-action-value strong {
  display: block;
  margin-top: 4px;
  color: var(--accent);
  font-size: 30px;
  line-height: 1;
}

.brief-action-value small {
  margin-top: 7px;
}

.brief-action-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.brief-action-list div:nth-child(4) {
  grid-column: 1 / -1;
}

.brief-action-list div {
  padding: 10px;
  border-radius: 8px;
  background: rgba(240, 246, 252, 0.78);
}

.brief-action-list strong {
  display: block;
  margin-top: 4px;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.35;
}

.strategy-brief-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.strategy-brief-grid label {
  display: grid;
  gap: 6px;
}

.strategy-brief-grid .wide {
  grid-column: span 2;
}

.strategy-brief-grid span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.strategy-brief-grid input,
.strategy-brief-grid textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  font-weight: 720;
}

.strategy-brief-grid input {
  min-height: 40px;
  padding: 0 12px;
}

.strategy-brief-grid textarea {
  min-height: 82px;
  padding: 11px 12px;
  resize: vertical;
  line-height: 1.4;
}

.strategy-products-head {
  padding: 18px 18px 14px;
  border-top: 1px solid rgba(219, 225, 231, 0.82);
  background: rgba(250, 252, 253, 0.76);
}

.strategy-product-section-title {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  margin: 0 18px 12px;
  padding: 14px;
  border-radius: 8px;
  background: rgba(255, 250, 238, 0.82);
}

.strategy-product-section-title.service {
  margin-top: 18px;
  background: rgba(240, 246, 252, 0.82);
}

.strategy-product-section-title > span {
  background: #f0b64c;
  color: #111418;
}

.strategy-product-section-title.service > span {
  background: var(--accent);
  color: #ffffff;
}

.strategy-product-section-title .secondary-command {
  white-space: nowrap;
}

.brief-product-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 0 18px 18px;
}

.brief-product {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px 12px;
  align-items: start;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.brief-product.selected {
  border-color: rgba(225, 70, 57, 0.28);
  background: rgba(255, 240, 237, 0.48);
}

.brief-product input {
  margin-top: 3px;
  accent-color: var(--accent);
}

.brief-product strong,
.brief-product small {
  display: block;
}

.brief-product > span > strong {
  color: var(--ink);
  font-size: 15px;
  line-height: 1.24;
}

.brief-product small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.brief-product em {
  color: var(--accent);
  font-size: 13px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.resource-stepper {
  grid-column: 2 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.78);
}

.resource-stepper b,
.resource-stepper span {
  font-size: 11px;
}

.resource-stepper b {
  color: var(--muted);
  text-transform: uppercase;
}

.resource-stepper span {
  color: var(--ink);
  font-weight: 760;
}

.resource-quantity-control,
.resource-price-control {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}

.resource-quantity-control input,
.resource-price-control input {
  width: 86px;
  min-height: 34px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
  font-weight: 850;
}

.resource-quantity-control input:disabled,
.resource-price-control input:disabled {
  opacity: 0.52;
}

.resource-price-control span {
  color: var(--muted);
}

.intake-overlay {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  place-items: center;
  padding: 24px;
  background: rgba(17, 24, 32, 0);
  backdrop-filter: blur(0);
  cursor: default;
}

.intake-overlay.open {
  display: grid;
  animation: overlayFadeIn 220ms ease forwards;
}

.stage-note-overlay,
.campaign-intake-overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: none;
  place-items: center;
  padding: 24px;
  background: rgba(13, 16, 20, 0.38);
  backdrop-filter: blur(5px);
  cursor: default;
}

.stage-note-overlay.open,
.campaign-intake-overlay.open {
  display: grid;
  animation: overlayFadeIn 200ms ease forwards;
}

.campaign-intake-overlay {
  z-index: 55;
  background: rgba(13, 16, 20, 0.42);
  backdrop-filter: blur(8px);
}

.opportunity-overlay {
  position: fixed;
  inset: 0;
  z-index: 58;
  display: none;
  place-items: center;
  padding: 24px;
  background: rgba(13, 16, 20, 0.42);
  backdrop-filter: blur(8px);
  cursor: default;
}

.opportunity-overlay.open {
  display: grid;
  animation: overlayFadeIn 200ms ease forwards;
}

.opportunity-dialog {
  width: min(720px, calc(100vw - 48px));
  max-height: min(820px, calc(100vh - 48px));
  overflow: auto;
  border: 1px solid rgba(219, 225, 231, 0.9);
  border-radius: 8px;
  background: rgba(249, 251, 252, 0.98);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.24);
  animation: modalFloatIn 260ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.opportunity-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 22px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
}

.opportunity-head span {
  color: var(--accent);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.opportunity-head h2 {
  margin: 8px 0;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1;
}

.opportunity-head p {
  max-width: 560px;
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.opportunity-flow-hint {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin: 14px 22px 0;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.62);
  color: var(--muted);
  font-size: 12px;
  font-weight: 820;
}

.opportunity-flow-hint span,
.opportunity-flow-hint strong {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  background: #ffffff;
}

.opportunity-flow-hint strong {
  border: 1px solid rgba(225, 70, 57, 0.22);
  background: rgba(255, 240, 237, 0.86);
  color: var(--red);
}

.opportunity-flow-hint b {
  color: rgba(103, 112, 124, 0.7);
  font-weight: 850;
}

.opportunity-handoff-strip {
  display: grid;
  gap: 10px;
  margin: 10px 22px 0;
  padding: 12px;
  border: 1px solid rgba(225, 70, 57, 0.16);
  border-radius: 8px;
  background: rgba(255, 247, 241, 0.74);
}

.opportunity-handoff-strip > div:first-child {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px;
}

.opportunity-handoff-strip strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.opportunity-handoff-strip > div:first-child span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 720;
}

.opportunity-handoff-items {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.opportunity-handoff-items span {
  min-height: 24px;
  padding: 5px 8px;
  border: 1px solid rgba(225, 70, 57, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--red);
  font-size: 11px;
  font-weight: 850;
}

.opportunity-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 18px;
}

.opportunity-form label {
  display: grid;
  gap: 6px;
}

.opportunity-form label.wide {
  grid-column: 1 / -1;
}

.opportunity-form span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.opportunity-account-hint {
  color: var(--muted);
  font-size: 11px;
  font-weight: 720;
  line-height: 1.35;
}

.opportunity-account-hint.blocked {
  color: var(--red);
}

.opportunity-form input,
.opportunity-form select,
.opportunity-form textarea {
  width: 100%;
  min-height: 40px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
  font-weight: 760;
}

.opportunity-form input:disabled,
.opportunity-form select:disabled,
.opportunity-form textarea:disabled {
  cursor: not-allowed;
  color: rgba(103, 112, 124, 0.9);
  background: rgba(239, 243, 246, 0.86);
}

.opportunity-form textarea {
  min-height: 86px;
  resize: vertical;
  line-height: 1.45;
}

.opportunity-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 0 18px 18px;
}

.detail-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.detail-hero-actions .secondary-command {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.campaign-intake-dialog {
  width: min(1060px, calc(100vw - 48px));
  max-height: min(860px, calc(100vh - 48px));
  overflow: auto;
  border: 1px solid rgba(219, 225, 231, 0.9);
  border-radius: 8px;
  background:
    linear-gradient(rgba(24, 32, 40, 0.032) 1px, transparent 1px),
    linear-gradient(90deg, rgba(24, 32, 40, 0.032) 1px, transparent 1px),
    #f9fbfc;
  background-size: 34px 34px, 34px 34px, auto;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.24);
  animation: modalFloatIn 280ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.campaign-intake-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
}

.campaign-intake-head span {
  color: var(--accent);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.campaign-intake-head h2 {
  margin: 8px 0;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1;
}

.campaign-intake-head p {
  max-width: 720px;
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.campaign-intake-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.8fr) minmax(0, 1.2fr);
  gap: 14px;
  padding: 14px;
}

.campaign-intake-panel {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.07);
}

.campaign-mode-toggle {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 14px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.campaign-mode-toggle button {
  min-height: 36px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  font-weight: 800;
}

.campaign-mode-toggle button.active {
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 6px 18px rgba(21, 24, 28, 0.08);
}

.campaign-mode-panel[hidden] {
  display: none;
}

.campaign-customer-summary,
.campaign-brief-summary {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.campaign-customer-summary > div,
.campaign-brief-summary > div,
.campaign-empty-path {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.campaign-customer-summary span,
.campaign-brief-summary span,
.campaign-form-grid span,
.campaign-wide-field span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.campaign-customer-summary strong,
.campaign-brief-summary strong {
  display: block;
  font-size: 15px;
}

.campaign-customer-summary p,
.campaign-brief-summary p,
.campaign-empty-path p {
  margin: 5px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.campaign-brief-standard {
  border-color: rgba(225, 70, 57, 0.22) !important;
  background: linear-gradient(135deg, #fff7f4, #ffffff) !important;
}

.campaign-brief-warning {
  border-color: rgba(225, 70, 57, 0.26) !important;
  background: #fff3f0 !important;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.campaign-brief-warning strong {
  color: var(--brand);
}

.campaign-brief-warning .secondary-command {
  flex: 0 0 auto;
}

.campaign-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.campaign-form-grid input,
.campaign-form-grid select,
.campaign-wide-field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
  outline: 0;
}

.campaign-form-grid input,
.campaign-form-grid select {
  height: 42px;
  padding: 0 12px;
}

.campaign-wide-field {
  display: block;
  margin-top: 12px;
}

.campaign-wide-field textarea {
  min-height: 76px;
  padding: 12px;
  resize: vertical;
  line-height: 1.45;
}

.campaign-intake-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 14px;
}

.stage-note-dialog {
  width: min(620px, 100%);
  padding: 18px;
  border: 1px solid rgba(219, 225, 231, 0.9);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 24px 70px rgba(21, 24, 28, 0.22);
  animation: modalFloatIn 260ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.stage-note-dialog header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.stage-note-dialog header span {
  color: var(--accent);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.stage-note-dialog h2 {
  margin-top: 5px;
  font-size: 24px;
}

.stage-note-dialog p {
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.45;
}

.stage-note-dialog textarea {
  width: 100%;
  min-height: 116px;
  margin-top: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font: inherit;
  resize: vertical;
}

.stage-note-dialog textarea.invalid {
  border-color: rgba(225, 70, 57, 0.74);
  box-shadow: 0 0 0 3px rgba(225, 70, 57, 0.12);
}

.stage-note-error {
  margin-top: 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 780;
}

.meeting-link-panel {
  display: grid;
  gap: 10px;
  margin-top: 12px;
  padding: 12px;
  border: 1px solid rgba(49, 93, 124, 0.18);
  border-radius: 8px;
  background: rgba(238, 242, 245, 0.62);
}

.meeting-link-panel[hidden] {
  display: none;
}

.meeting-link-panel strong,
.meeting-link-panel p,
.meeting-link-field span {
  display: block;
}

.meeting-link-panel strong {
  font-size: 14px;
}

.meeting-link-panel p {
  margin-top: 4px;
  font-size: 12px;
}

.meeting-provider-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.meeting-link-field span {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 820;
  text-transform: uppercase;
}

.meeting-link-field input {
  width: 100%;
  min-height: 38px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font: inherit;
}

.meeting-link-preview {
  overflow: hidden;
  padding: 9px 10px;
  border-radius: 8px;
  background: rgba(37, 113, 99, 0.1);
  color: var(--green);
  font-size: 12px;
  font-weight: 760;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stage-note-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 12px;
}

.mention-enabled:focus {
  border-color: rgba(225, 70, 57, 0.58);
  box-shadow: 0 0 0 3px rgba(225, 70, 57, 0.08);
}

.mention-popover {
  position: fixed;
  z-index: 100;
  overflow: hidden;
  border: 1px solid rgba(219, 225, 231, 0.95);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 46px rgba(21, 24, 28, 0.16);
}

.mention-popover-head {
  padding: 9px 10px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.mention-popover button {
  width: 100%;
  display: grid;
  grid-template-columns: 28px minmax(0, 0.6fr) minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 9px 10px;
  border: 0;
  border-bottom: 1px solid rgba(219, 225, 231, 0.58);
  background: transparent;
  text-align: left;
}

.mention-popover button:hover {
  background: rgba(255, 240, 237, 0.72);
}

.mention-popover button span {
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: var(--nav);
  color: #ffffff;
  font-size: 12px;
  font-weight: 850;
}

.mention-popover button strong {
  font-size: 12px;
}

.mention-popover button small {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.intake-drawer {
  width: min(1060px, calc(100vw - 48px));
  max-height: min(860px, calc(100vh - 48px));
  margin: 0;
  overflow: auto;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 8px;
  background:
    linear-gradient(rgba(24, 32, 40, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(24, 32, 40, 0.035) 1px, transparent 1px),
    #f8fafb;
  background-size: 34px 34px, 34px 34px, auto;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.22);
  animation: modalFloatIn 280ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.intake-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.84);
}

.intake-head span {
  color: var(--accent);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.intake-head h2 {
  margin: 8px 0 8px;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1;
}

.intake-head p {
  max-width: 620px;
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.45;
}

.close-command {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font-size: 24px;
}

.intake-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 14px;
  padding: 14px;
}

.intake-panel {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 34px rgba(21, 24, 28, 0.07);
}

.field-label {
  display: block;
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.field-input,
.field-textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  outline: 0;
}

.field-input {
  height: 42px;
  padding: 0 12px;
}

.field-textarea {
  min-height: 220px;
  margin-bottom: 12px;
  padding: 12px;
  resize: vertical;
  line-height: 1.45;
}

.intake-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.intake-actions.end {
  margin-top: 14px;
}

.intake-created-card {
  display: grid;
  gap: 12px;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid rgba(28, 123, 101, 0.22);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(231, 246, 241, 0.95), rgba(255, 255, 255, 0.96));
}

.intake-created-card[hidden] {
  display: none;
}

.intake-created-card strong {
  display: block;
  margin-bottom: 4px;
  font-size: 15px;
}

.intake-created-card p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.45;
}

.intake-created-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.intake-primary:disabled {
  cursor: default;
  opacity: 0.55;
}

.ai-signal-card {
  margin-top: 14px;
  padding: 14px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--nav), #223341);
  color: #ffffff;
}

.ai-signal-card b {
  display: block;
  margin-bottom: 10px;
  font-size: 12px;
  text-transform: uppercase;
}

.ai-signal-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.ai-signal-list span {
  padding: 6px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.8);
  font-size: 12px;
}

.section-head.compact {
  margin: -4px 0 14px;
  padding: 0 0 12px;
}

.draft-grid {
  display: block;
}

.draft-item {
  min-height: 82px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.draft-item:nth-child(n + 5) {
  grid-column: span 2;
}

.draft-item span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.draft-item strong {
  font-size: 14px;
  line-height: 1.4;
}

.draft-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.draft-form-grid.intake-review-grid {
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}

.draft-review-section {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
}

.draft-field-row {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.draft-field-row.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.draft-field-row.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.draft-form-field,
.draft-people-editor {
  display: block;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.draft-people-editor {
  background: linear-gradient(180deg, #ffffff 0%, #fbfcfd 100%);
}

.draft-people-editor.compact {
  padding: 12px;
  border-color: rgba(28, 123, 101, 0.16);
  background: linear-gradient(180deg, rgba(248, 252, 251, 0.96), #ffffff 100%);
}

.draft-form-field.wide,
.draft-people-editor {
  grid-column: 1 / -1;
}

.draft-form-field span,
.draft-section-title span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.draft-form-field input,
.draft-form-field select,
.draft-form-field textarea,
.draft-person-picker select,
.draft-person-manual input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafb;
  color: var(--ink);
  font: inherit;
  font-weight: 750;
  outline: 0;
}

.draft-form-field input,
.draft-form-field select,
.draft-person-picker select,
.draft-person-manual input {
  height: 38px;
  padding: 0 10px;
}

.draft-form-field textarea {
  min-height: 76px;
  padding: 10px;
  line-height: 1.45;
  resize: vertical;
}

.draft-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 7px;
}

.draft-section-title small {
  display: block;
  max-width: 560px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 650;
  line-height: 1.45;
}

.draft-section-title > strong {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  min-width: 28px;
  height: 28px;
  padding: 0 8px;
  border: 1px solid rgba(28, 123, 101, 0.18);
  border-radius: 999px;
  background: rgba(231, 246, 241, 0.78);
  color: #166352;
  font-size: 12px;
}

.draft-person-tools {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.draft-person-tools.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.draft-person-tools article {
  display: grid;
  gap: 10px;
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(219, 225, 231, 0.88);
  border-radius: 8px;
  background: rgba(248, 250, 251, 0.86);
}

.draft-person-tool-copy b,
.draft-person-tool-copy small {
  display: block;
}

.draft-person-tool-copy b {
  color: var(--ink);
  font-size: 13px;
}

.draft-person-tool-copy small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.draft-person-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  gap: 8px;
  min-height: 40px;
  padding: 10px;
  border: 1px solid rgba(15, 25, 36, 0.07);
  border-radius: 8px;
  background: rgba(247, 250, 252, 0.9);
}

.draft-person-list-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
}

.draft-person-list-head strong {
  color: var(--ink);
  font-size: 12px;
}

.draft-person-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
}

.draft-person-controls {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-top: 10px;
}

.draft-person-controls.simplified {
  grid-template-columns: 1fr;
  align-items: stretch;
}

.draft-person-control-block {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
}

.draft-person-control-block.compact {
  grid-template-columns: minmax(0, 1fr);
}

.draft-person-control-block > span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  line-height: 1.25;
}

.draft-person-empty {
  display: flex;
  align-items: center;
  min-height: 28px;
  padding: 2px 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.45;
}

.draft-person-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  max-width: 100%;
  padding: 5px 8px;
  border: 1px solid rgba(28, 123, 101, 0.2);
  border-radius: 999px;
  background: rgba(231, 246, 241, 0.88);
  color: #166352;
  font-size: 12px;
}

.draft-person-chip b,
.draft-person-chip small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.draft-person-chip b {
  max-width: 130px;
}

.draft-person-chip small {
  max-width: 180px;
  color: rgba(22, 99, 82, 0.74);
  font-weight: 750;
}

.draft-person-chip button {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border: 0;
  border-radius: 999px;
  background: rgba(22, 99, 82, 0.12);
  color: #166352;
  font-size: 16px;
  line-height: 1;
}

.draft-person-picker,
.draft-person-manual {
  display: grid;
  gap: 6px;
  align-items: center;
}

.draft-person-picker {
  grid-template-columns: minmax(180px, 1fr) auto;
}

.draft-person-manual {
  grid-template-columns: minmax(120px, 1fr) minmax(92px, 0.72fr) auto;
}

.draft-person-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 0.84fr) minmax(0, 1.16fr);
  gap: 8px;
}

.draft-person-tool {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(219, 225, 231, 0.9);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
}

.draft-person-tool.manual {
  grid-template-columns: auto minmax(120px, 1fr) minmax(90px, 0.72fr) auto;
}

.draft-person-tool > span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  white-space: nowrap;
}

.draft-person-tool select,
.draft-person-tool input {
  min-width: 0;
}

.draft-person-controls .secondary-command {
  padding-inline: 12px;
}

.draft-person-picker button,
.draft-person-manual button,
.draft-person-tool button {
  height: 38px;
  white-space: nowrap;
}

.missing-card {
  margin-top: 14px;
  padding: 12px;
  border: 1px solid rgba(225, 70, 57, 0.18);
  border-radius: 8px;
  background: rgba(255, 240, 237, 0.58);
}

.missing-card b {
  display: block;
  margin-bottom: 8px;
  color: var(--accent);
  font-size: 11px;
  text-transform: uppercase;
}

.missing-card div {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.missing-card span {
  padding: 5px 8px;
  border-radius: 999px;
  background: #ffffff;
  color: var(--ink);
  font-size: 12px;
}

.campaign-metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 18px;
}

.campaign-progress {
  height: 7px;
  margin-top: 16px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--surface-2);
}

.campaign-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), #f0b64c);
}

@media (max-width: 1180px) {
  .metric-strip,
  .revenue-overview,
  .mention-notification-center,
  .priority-card-grid,
  .directory-summary,
  .campaign-board,
  .partner-overview-card,
  .product-board-inner,
  .template-board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .today-command {
    grid-template-columns: 1fr;
  }

  .workspace-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .people-library-layout {
    grid-template-columns: 1fr;
  }

  .team-overview-card,
  .team-layout {
    grid-template-columns: 1fr;
  }

  .team-flow-card {
    position: static;
  }

  .partner-layout {
    grid-template-columns: 1fr;
  }

  .partner-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .partner-form button {
    grid-column: 1 / -1;
  }

  .strategy-brief-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .strategy-entry-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .strategy-brief-stack-wide,
  .confirmed-solution-card {
    grid-template-columns: 1fr;
  }

  .product-editor-layout,
  .product-editor-hero {
    grid-template-columns: 1fr;
  }

  .product-editor-hero {
    display: grid;
  }

  .product-change-log {
    position: static;
  }

  .contract-meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .project-detail-layout,
  .project-detail-hero {
    grid-template-columns: 1fr;
  }

  .project-detail-status {
    min-height: auto;
  }

  .intelligence-panel {
    position: static;
  }
}

@media (max-width: 860px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
    padding: 16px;
  }

  .nav-list {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .sidebar-section {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .customer-subnav {
    margin-left: 0;
    padding-left: 0;
    border-left: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sidebar-section p {
    grid-column: 1 / -1;
  }

  .signal-panel {
    display: none;
  }

  .topbar,
  .section-head {
    flex-direction: column;
  }

  .topbar-actions,
  .search-box {
    width: 100%;
  }

  .topbar-actions {
    flex-wrap: wrap;
  }

  .language-toggle {
    order: -1;
  }

  .command-banner {
    grid-template-columns: 1fr;
  }

  .today-signal-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .account-start-grid,
  .account-start-people {
    grid-template-columns: 1fr;
  }

  .intake-grid {
    grid-template-columns: 1fr;
  }

  .draft-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .draft-field-row.three,
  .draft-field-row.two,
  .draft-person-controls.simplified {
    grid-template-columns: 1fr;
  }

  .draft-person-actions.compact {
    grid-template-columns: 1fr;
  }

  .draft-person-controls {
    grid-template-columns: 1fr;
  }

  .draft-person-manual {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .draft-person-manual button {
    grid-column: 1 / -1;
  }

  .detail-hero,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .detail-action-panel {
    min-width: 0;
    max-width: none;
  }

  .command-status-row,
  .detail-focus-grid,
  .project-command-grid,
  .handoff-check {
    grid-template-columns: 1fr;
  }

  .handoff-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .project-command-commercial {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-stage-rail {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .primary-project-strip {
    grid-template-columns: 1fr;
  }

  .project-contract-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-hero-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .brief-product-list {
    grid-template-columns: 1fr;
  }

  .brief-template-list,
  .selected-template-products,
  .sample-list-grid,
  .campaign-board-grid,
  .product-board-inner,
  .template-board,
  .partner-overview-card {
    grid-template-columns: 1fr;
  }

  .strategy-entry-grid {
    grid-template-columns: 1fr;
  }

  .strategy-entry-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .strategy-context-card .overview-list,
  .strategy-workspace-layout {
    grid-template-columns: 1fr;
  }

  .brief-action-panel {
    position: static;
  }

  .strategy-brief-grid {
    grid-template-columns: 1fr;
  }

  .product-editor,
  .product-editor-meta {
    grid-template-columns: 1fr;
  }

  .product-editor .wide {
    grid-column: 1;
  }

  .contract-meta-grid {
    grid-template-columns: 1fr;
  }

  .project-summary-grid,
  .active-project-contracts {
    grid-template-columns: 1fr;
  }

  .history-project-row {
    grid-template-columns: 1fr;
  }

  .history-project-row > div:last-child {
    text-align: left;
  }

  .campaign-revenue-grid,
  .campaign-money-grid,
  .revenue-period-grid,
  .mention-alert-list,
  .priority-card-grid,
  .people-overview-card,
  .team-stat-grid,
  .team-member-grid,
  .people-row-detail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .strategy-brief-grid .wide {
    grid-column: 1;
  }

  .resource-stepper {
    grid-template-columns: 1fr;
  }

  .radar-card {
    min-height: 160px;
    margin: 0 18px 18px;
  }

  .account-row,
  .account-row.header {
    grid-template-columns: minmax(180px, 1.4fr) minmax(132px, 1fr) minmax(120px, 0.8fr);
  }

  .account-row > :nth-child(4),
  .account-row > :nth-child(5),
  .account-row > :nth-child(6),
  .account-row > :nth-child(7) {
    display: none;
  }
}

/* Key-person picker: one path at a time, searchable, direct add. */
.draft-people-editor.compact {
  gap: 10px;
}

.draft-person-mode-switch {
  display: inline-flex;
  width: fit-content;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: var(--radius-element);
  background: var(--surface-2);
}

.draft-person-mode-switch button {
  min-height: 32px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.draft-person-mode-switch button.active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

.draft-person-mode-panel {
  display: none;
}

.draft-person-mode-panel.active {
  display: grid;
  gap: 8px;
}

.draft-person-search {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-element);
  background: var(--surface);
  color: var(--muted);
}

.draft-person-search:focus-within {
  border-color: #737373;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.06);
}

.draft-person-search input {
  flex: 1;
  min-width: 0;
  height: 38px;
  padding: 0;
  border: 0;
  border-radius: 0;
  outline: 0;
  background: transparent;
}

.draft-person-search-results {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.draft-person-result {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  min-width: 0;
  min-height: 52px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-element);
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  transition: border-color 125ms ease, background-color 125ms ease;
}

.draft-person-result:hover:not(:disabled) {
  border-color: var(--line-strong);
  background: #fafafa;
}

.draft-person-result.selected,
.draft-person-result:disabled {
  cursor: default;
  opacity: 0.62;
  background: var(--surface-2);
}

.draft-person-result-avatar {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-element);
  background: #262626;
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
}

.draft-person-result-copy,
.draft-person-result-copy strong,
.draft-person-result-copy small {
  display: block;
  min-width: 0;
}

.draft-person-result-copy strong,
.draft-person-result-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.draft-person-result-copy strong {
  font-size: 12px;
  font-weight: 650;
}

.draft-person-result-copy small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.draft-person-result > b {
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
}

.draft-person-search-empty {
  grid-column: 1 / -1;
  padding: 14px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-element);
  background: var(--surface-2);
}

.draft-person-search-empty strong,
.draft-person-search-empty span {
  display: block;
}

.draft-person-search-empty strong {
  font-size: 12px;
}

.draft-person-search-empty span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.draft-person-create-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(160px, 0.7fr) auto;
  align-items: end;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-element);
  background: var(--surface-2);
}

.draft-person-create-row label,
.draft-person-create-row label > span {
  display: block;
  min-width: 0;
}

.draft-person-create-row label > span {
  margin-bottom: 5px;
  color: #525252;
  font-size: 11px;
  font-weight: 600;
}

.draft-person-create-row input {
  width: 100%;
  height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-element);
  background: var(--surface);
}

.draft-person-create-row .primary-command {
  height: 40px;
}

.draft-person-list {
  margin-top: 2px;
}

@media (max-width: 1060px) {
  .draft-person-search-results {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 860px) {
  .draft-person-create-row {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .draft-person-mode-switch,
  .draft-person-mode-switch button {
    width: 100%;
  }
}

@media (max-width: 620px) {
  .main-panel {
    padding: 20px 14px 28px;
  }

  .metric-strip,
  .revenue-overview,
  .revenue-period-grid,
  .mention-notification-center,
  .mention-alert-list,
  .priority-card-grid,
  .today-signal-grid,
  .campaign-revenue-grid,
  .campaign-money-grid,
  .campaign-payment-row,
  .people-overview-card,
  .team-stat-grid,
  .team-member-grid,
  .team-work-grid,
  .people-row-detail,
  .directory-summary,
  .campaign-board,
  .partner-card-grid,
  .product-board {
    grid-template-columns: 1fr;
  }

  .partner-form,
  .people-library-row,
  .contract-row,
  .contract-row.header {
    grid-template-columns: 1fr;
  }

  .nav-list,
  .sidebar-section {
    grid-template-columns: 1fr;
  }

  .campaign-metrics,
  .mini-stats,
  .partner-stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .draft-grid,
  .draft-form-grid,
  .draft-field-row.three,
  .draft-field-row.two,
  .draft-person-toolbar,
  .draft-person-tool,
  .draft-person-tool.manual,
  .draft-person-tools.compact,
  .draft-person-controls,
  .draft-person-picker,
  .draft-person-manual,
  .overview-list,
  .commercial-grid,
  .brief-product-list {
    grid-template-columns: 1fr;
  }

  .detail-hero-stats {
    grid-template-columns: 1fr;
  }

  .draft-item:nth-child(n + 5) {
    grid-column: auto;
  }

  .command-banner {
    min-height: 0;
  }

  .today-command {
    padding: 8px;
  }

  .today-command-copy h2 {
    font-size: 22px;
  }

  .banner-copy {
    padding: 22px;
  }

  .banner-copy strong {
    font-size: 30px;
  }

  .radar-card {
    display: none;
  }

  .primary-command {
    width: 40px;
    padding: 0;
    font-size: 0;
  }

  .primary-action-wrap {
    min-width: 40px;
  }

  .primary-action-wrap small {
    display: none;
  }

  .primary-command::before {
    content: "+";
    font-size: 22px;
    line-height: 1;
  }

  .intake-primary {
    width: auto;
    padding: 0 14px;
    font-size: 13px;
  }

  .intake-primary::before {
    content: none;
  }

  h1 {
    font-size: 36px;
  }
}

@keyframes dropZoneBreath {
  0%, 100% {
    opacity: 0.55;
    transform: scale(0.992);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes columnSuccess {
  0% {
    box-shadow: inset 0 0 0 1px rgba(22, 113, 97, 0.1);
  }
  45% {
    box-shadow:
      inset 0 0 0 2px rgba(22, 113, 97, 0.28),
      0 18px 44px rgba(22, 113, 97, 0.12);
  }
  100% {
    box-shadow: inset 0 0 0 1px rgba(225, 70, 57, 0);
  }
}

@keyframes cardLanded {
  0% {
    transform: translateY(-10px) scale(0.985);
    box-shadow: 0 24px 52px rgba(21, 24, 28, 0.16);
  }
  45% {
    transform: translateY(2px) scale(1.01);
    box-shadow: 0 18px 40px rgba(22, 113, 97, 0.14);
  }
  100% {
    transform: translateY(0) scale(1);
    box-shadow: 0 8px 20px rgba(21, 24, 28, 0.055);
  }
}

@media (prefers-reduced-motion: reduce) {
  .deal-card,
  .pipeline-column {
    transition-duration: 0.01ms;
  }

  .deal-card.stage-landed,
  .pipeline-column.drag-over::after,
  .pipeline-column.drop-success {
    animation: none;
  }
}

/* Codex-style visual refresh: skin layer only, no workflow logic changes. */
:root {
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-2: #f6f6f7;
  --surface-3: #eeeeef;
  --ink: #202124;
  --muted: #6f737a;
  --soft: #9ca0a6;
  --line: #e7e7e9;
  --accent: #202124;
  --accent-soft: #f1f1f2;
  --blue: #2563eb;
  --green: #0f766e;
  --amber: #a16207;
  --violet: #7c3aed;
  --nav: #f7f7f8;
  --nav-soft: #eeeeef;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 12px 34px rgba(0, 0, 0, 0.06);
  --text-xs: 11px;
  --text-sm: 12px;
  --text-base: 13px;
  --text-md: 14px;
  --text-lg: 17px;
  --text-xl: 22px;
  --text-display: clamp(34px, 4vw, 48px);
  --fw-regular: 450;
  --fw-medium: 560;
  --fw-semibold: 650;
  --fw-bold: 720;
  --fw-heavy: 780;
}

body {
  background:
    radial-gradient(circle at 8% 92%, rgba(37, 99, 235, 0.06), transparent 26%),
    linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
  color: var(--ink);
  font-weight: 450;
  -webkit-font-smoothing: antialiased;
}

.app-shell {
  grid-template-columns: 286px minmax(0, 1fr);
}

.sidebar {
  padding: 18px 16px;
  gap: 20px;
  border-right: 1px solid var(--line);
  background: rgba(247, 247, 248, 0.92);
  box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.65);
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: #202124;
  color: #ffffff;
}

.brand-lockup strong {
  color: var(--ink);
  font-size: 15px;
  font-weight: 720;
}

.sidebar .brand-lockup span,
.sidebar .sidebar-section p,
.sidebar .signal-panel span,
.sidebar .signal-panel small {
  color: var(--muted);
}

.sidebar .nav-item,
.sidebar .type-filter {
  color: #4f5359;
  border-radius: 10px;
}

.nav-item {
  min-height: 34px;
  padding: 0 9px;
  gap: 9px;
  font-weight: 620;
}

.type-filter {
  min-height: 31px;
  padding: 0 10px;
  font-size: 13px;
}

.sidebar .nav-icon {
  color: #6f737a;
  background: transparent;
  border: 0;
}

.sidebar .nav-item.active,
.sidebar .type-filter.active {
  border-color: transparent;
  background: #e9e9eb;
  color: #202124;
  box-shadow: none;
}

.sidebar .nav-item:hover,
.sidebar .type-filter:hover {
  background: #eeeeef;
  color: #202124;
  border-color: transparent;
}

.customer-subnav {
  margin-left: 25px;
  padding-left: 12px;
  border-left: 1px solid #dedee1;
}

.signal-panel {
  margin-top: auto;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.76);
  box-shadow: none;
}

.signal-panel strong {
  color: var(--ink);
}

.main-panel {
  padding: 24px clamp(22px, 3vw, 42px) 42px;
}

.topbar {
  align-items: center;
  margin-bottom: 22px;
}

.eyebrow {
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
  text-transform: none;
}

h1 {
  font-size: var(--text-display);
  font-weight: 760;
  letter-spacing: 0;
}

h2 {
  font-size: 18px;
  font-weight: 720;
}

h3 {
  font-size: 15px;
  font-weight: 680;
}

.language-toggle,
.search-box,
.icon-command,
.primary-command,
.secondary-command,
.segmented,
.field-input,
.field-textarea,
input,
select,
textarea {
  border-color: var(--line);
  border-radius: 12px;
  box-shadow: none;
}

.search-box,
.language-toggle,
.segmented {
  background: rgba(255, 255, 255, 0.88);
}

.primary-command {
  border-color: #202124;
  background: #202124;
  color: #ffffff;
  font-weight: 680;
}

.secondary-command,
.icon-command {
  background: #ffffff;
  color: #202124;
}

.secondary-command:hover,
.icon-command:hover {
  background: #f5f5f6;
}

.view > .section-head.wide,
.today-command,
.revenue-overview,
.work-surface,
.intelligence-panel,
.metric,
.pipeline-column,
.deal-card,
.account-directory,
.directory-card,
.product-section,
.product-card,
.partner-board section,
.partner-list-panel,
.partner-detail-panel,
.people-card,
.people-detail-main > section,
.people-detail-side > section,
.team-role-section,
.modal,
.intake-modal,
.strategy-workspace-shell,
.strategy-context-card,
.brief-action-panel,
.project-command-solution,
.project-summary-card,
.contract-money-card,
.current-project-control,
.opportunity-strategy-panel,
.account-side-card,
.project-card,
.campaign-card {
  border: 1px solid var(--line) !important;
  border-radius: 14px !important;
  background: rgba(255, 255, 255, 0.92) !important;
  box-shadow: none !important;
}

.today-command {
  grid-template-columns: minmax(360px, 0.78fr) minmax(360px, 1fr);
  min-height: 0;
  padding: 16px;
  gap: 14px;
}

.today-command-copy {
  padding: 14px 4px 14px 6px;
}

.today-command-copy span {
  color: var(--muted);
  text-transform: none;
}

.today-command-copy h2 {
  max-width: 760px;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.08;
  font-weight: 760;
}

.today-command-copy p {
  max-width: 780px;
  color: var(--muted);
  font-size: 14px;
}

.today-signal-grid {
  gap: 10px;
}

.today-signal-grid div,
.revenue-period-grid > div,
.mini-stat,
.partner-stat,
.people-profile-grid div,
.detail-hero-stats div,
.overview-list div,
.commercial-grid div,
.strategy-summary-card,
.campaign-money-grid div,
.campaign-payment-row div,
.project-finance-card,
.project-info-cell {
  border: 1px solid #ededee !important;
  border-radius: 12px !important;
  background: #f7f7f8 !important;
  box-shadow: none !important;
}

.metric {
  min-height: 74px;
}

.metric::before {
  height: 2px;
  background: #d7d7da;
}

.metric strong,
.revenue-period-grid strong,
.campaign-money-grid strong {
  font-weight: 760;
}

.section-head {
  padding: 14px 18px;
}

.section-head.wide {
  margin-bottom: 12px;
  padding: 0 0 12px;
}

.section-head p {
  color: var(--muted);
  font-size: 13px;
}

.pill,
.stage-pill,
.priority-pill,
.status-pill,
.customer-status-pill,
.brief-status-pill,
.commission-status,
.product-badge {
  border-color: #dedee1 !important;
  background: #f7f7f8 !important;
  color: #4f5359 !important;
  box-shadow: none !important;
}

.priority-pill.hot,
.current-gate,
.unread .pill,
.customer-status-pill.urgent {
  border-color: #ffd6d1 !important;
  background: #fff3f1 !important;
  color: #c24132 !important;
}

.logo-dot {
  border-radius: 10px;
  background: #202124;
  color: #ffffff;
}

#priorityTable,
.account-table {
  overflow-x: auto;
}

.priority-row {
  grid-template-columns:
    minmax(330px, 1.35fr)
    minmax(220px, 0.85fr)
    minmax(108px, 0.5fr)
    minmax(170px, 0.72fr)
    minmax(230px, 1fr)
    minmax(140px, 0.58fr)
    72px;
  min-width: 1280px;
  min-height: 64px;
  padding: 0 18px;
  gap: 16px;
}

.priority-row.header {
  min-height: 38px;
  background: #f3f4f5;
  font-size: 12px;
  font-weight: 650;
  text-transform: none;
}

.priority-row.data {
  border-left: 0;
  border-top-color: #eeeeef;
}

.priority-row.data:hover,
.priority-row.data.selected {
  border-left-color: transparent;
  background: #fafafa;
}

.priority-row .account-name strong {
  font-size: 15px;
  font-weight: 720;
  line-height: 1.25;
}

.priority-row .account-name small,
.priority-row .subtle,
.row-context-meta {
  color: var(--muted);
  font-size: 12px;
}

.priority-row > span,
.priority-row .account-name > span:last-child,
.row-context-name,
.row-context-meta {
  min-width: 0;
}

.priority-row .subtle,
.row-context-name,
.row-context-meta,
.account-name strong,
.account-name small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.priority-card-grid {
  gap: 12px;
  padding: 14px;
}

.priority-project-card {
  min-height: 0;
  border-radius: 14px;
  box-shadow: none;
}

.priority-project-card:hover,
.priority-project-card.selected {
  background: #fafafa;
  border-color: #d8d8dc;
}

.pipeline-board {
  gap: 10px;
}

.pipeline-column {
  border-radius: 14px;
}

.deal-card {
  border-radius: 12px;
}

.deal-card:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow) !important;
}

/* Pipeline cards: one operational summary, ordered for fast scanning. */
.pipeline-card-account {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  margin-bottom: 7px;
}

.pipeline-card-account span,
.pipeline-card-account strong {
  margin: 0;
}

.pipeline-card-account span {
  min-width: 0;
  overflow: hidden;
  color: var(--blue);
  font-size: 11px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pipeline-card-account strong {
  flex: 0 0 auto;
  color: var(--ink);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.pipeline-card-campaign {
  min-height: 38px;
  margin: 0 0 12px;
  color: var(--ink);
  font-size: 15px;
  font-weight: 740;
  line-height: 1.28;
}

.pipeline-card-owners {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin-bottom: 8px;
}

.pipeline-card-owners > span,
.pipeline-card-milestones > span {
  min-width: 0;
  margin: 0;
  padding: 7px 8px;
  border: 1px solid #ececef;
  border-radius: 9px;
  background: #f8f8f9;
}

.pipeline-card-owners small,
.pipeline-card-owners strong,
.pipeline-card-milestones small,
.pipeline-card-milestones strong {
  margin: 0;
}

.pipeline-card-owners small,
.pipeline-card-milestones small {
  color: var(--muted);
  font-size: 9px;
  font-weight: 650;
}

.pipeline-card-owners strong,
.pipeline-card-milestones strong {
  margin-top: 3px;
  overflow: hidden;
  color: var(--ink);
  font-size: 11px;
  font-weight: 730;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pipeline-card-milestones {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.pipeline-card-milestones > span.complete {
  border-color: #cfe5df;
  background: #f0f8f5;
}

.pipeline-card-milestones > span.current {
  border-color: #f0d9ad;
  background: #fff9ed;
}

.pipeline-card-milestones > span.future {
  color: var(--muted);
}

.pipeline-card-milestones > span.complete strong {
  color: #197563;
}

.pipeline-card-milestones > span.current strong {
  color: #95620d;
}

.pipeline-card-milestones > span.future strong {
  color: #777b82;
}

.pipeline-card-next {
  margin-top: 9px;
  padding: 9px 10px;
  border-left: 2px solid #202124;
  border-radius: 0 8px 8px 0;
  background: #f7f7f8;
}

.pipeline-card-next span,
.pipeline-card-next strong {
  margin: 0;
}

.pipeline-card-next span {
  color: var(--muted);
  font-size: 9px;
  font-weight: 650;
}

.pipeline-card-next strong {
  margin-top: 3px;
  color: var(--ink);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.3;
}

.deal-card .pipeline-card-tools {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid #eeeeef;
}

.deal-card .pipeline-card-tools > span {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 620;
}

.account-row,
.contract-row,
.partner-row,
.people-library-row {
  border-top-color: #eeeeef;
}

.account-row.header,
.contract-row.header,
.partner-table-head {
  background: #f3f4f5;
  text-transform: none;
}

.modal-backdrop,
.intake-overlay {
  background: rgba(20, 20, 22, 0.42);
  backdrop-filter: blur(14px);
}

.modal,
.intake-modal {
  border-radius: 18px !important;
}

.app-version-badge {
  right: 16px;
  bottom: 14px;
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.88);
  color: var(--muted);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.08);
}

@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

  .today-command {
    grid-template-columns: 1fr;
  }
}

/* ========================================================================== */
/* Astryx Neutral visual system                                                */
/* Adapted from Astryx's Neutral theme for this framework-free CRM prototype. */
/* ========================================================================== */

:root {
  --bg: #f1f1f1;
  --surface: #ffffff;
  --surface-2: #f5f5f5;
  --ink: #171717;
  --muted: #737373;
  --soft: #a3a3a3;
  --line: #ebebeb;
  --line-strong: #d4d4d4;
  --accent: #262626;
  --accent-soft: #f1f1f1;
  --blue: #00458c;
  --green: #007004;
  --amber: #745b00;
  --violet: #700084;
  --nav: #ffffff;
  --nav-soft: #f5f5f5;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.06), 0 8px 24px rgba(0, 0, 0, 0.04);
  --shadow-med: 0 4px 12px rgba(0, 0, 0, 0.08), 0 18px 48px rgba(0, 0, 0, 0.08);
  --radius-inner: 6px;
  --radius-element: 10px;
  --radius-container: 12px;
  --text-xs: 11px;
  --text-sm: 12px;
  --text-base: 14px;
  --text-md: 15px;
  --text-lg: 18px;
  --text-xl: 24px;
  --text-display: 32px;
  --fw-regular: 450;
  --fw-medium: 550;
  --fw-semibold: 650;
  --fw-bold: 700;
  --fw-heavy: 750;
}

html {
  background: var(--bg);
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: Figtree, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.45;
}

button,
input,
select,
textarea {
  letter-spacing: 0;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid #171717;
  outline-offset: 2px;
}

.app-shell {
  grid-template-columns: 260px minmax(0, 1fr);
}

.sidebar {
  gap: 16px;
  padding: 12px 10px;
  border-right: 1px solid var(--line);
  background: var(--surface);
  backdrop-filter: none;
}

.brand-lockup {
  gap: 10px;
  min-height: 44px;
  padding: 4px 8px;
}

.brand-mark {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-element);
  background: #262626;
  font-size: 13px;
  font-weight: 700;
}

.brand-lockup strong {
  color: var(--ink);
  font-size: 14px;
  font-weight: 650;
}

.sidebar .brand-lockup span,
.sidebar .sidebar-section p,
.sidebar .signal-panel span,
.sidebar .signal-panel small {
  color: var(--muted);
}

.nav-list,
.sidebar-section {
  gap: 2px;
}

.nav-item,
.type-filter {
  min-height: 36px;
  border: 0;
  border-radius: var(--radius-element);
  color: var(--muted);
  transition: background-color 125ms ease, color 125ms ease;
}

.sidebar .nav-item,
.sidebar .type-filter {
  color: #525252;
}

.nav-item {
  gap: 8px;
  padding: 0 10px;
  font-size: 14px;
  font-weight: 550;
}

.nav-icon,
.sidebar .nav-icon {
  width: 20px;
  height: 20px;
  color: var(--muted);
  font-size: 15px;
}

.customer-nav-item .nav-caret {
  color: var(--muted);
}

.sidebar .nav-item:hover,
.sidebar .type-filter:hover {
  background: rgba(0, 0, 0, 0.05);
  color: var(--ink);
}

.nav-item.active,
.type-filter.active,
.sidebar .nav-item.active,
.sidebar .type-filter.active {
  border: 0;
  background: #e5e5e5;
  color: var(--ink);
  font-weight: 650;
  box-shadow: none;
}

.customer-subnav {
  gap: 1px;
  margin: 0 0 4px 28px;
  padding-left: 8px;
  border-left-color: var(--line);
}

.type-filter {
  min-height: 32px;
  padding: 0 10px;
  font-size: 12px;
}

.signal-panel,
.sidebar .signal-panel {
  padding: 12px;
  border-color: var(--line);
  border-radius: var(--radius-container);
  background: var(--surface-2);
  box-shadow: none;
}

.sidebar .signal-panel strong {
  color: var(--ink);
  font-size: 15px;
}

.signal-panel strong,
.signal-panel small {
  margin-top: 4px;
}

.main-panel {
  padding: 20px clamp(16px, 2.2vw, 32px) 48px;
}

.topbar {
  align-items: center;
  min-height: 56px;
  margin-bottom: 20px;
}

.eyebrow {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 550;
  text-transform: none;
}

h1 {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.12;
}

h2 {
  font-size: 18px;
  font-weight: 650;
}

h3 {
  font-size: 15px;
  font-weight: 650;
}

.topbar-actions {
  gap: 8px;
}

.language-toggle,
.search-box,
.segmented,
.icon-command,
.primary-command,
.secondary-command,
.field-input,
.field-textarea,
input,
select,
textarea {
  border-color: var(--line-strong);
  border-radius: var(--radius-element);
  box-shadow: none;
}

.language-toggle,
.search-box,
.segmented {
  background: var(--surface);
}

.language-toggle,
.search-box,
.icon-command,
.primary-command,
.secondary-command {
  min-height: 38px;
}

.language-toggle {
  height: 38px;
}

.search-box {
  width: min(340px, 31vw);
  height: 38px;
}

.primary-command {
  border-color: #262626;
  background: #262626;
  color: #ffffff;
  font-weight: 600;
}

.primary-command:hover {
  background: #404040;
}

.secondary-command,
.icon-command {
  background: #ffffff;
  color: var(--ink);
  font-weight: 600;
}

.secondary-command:hover,
.icon-command:hover {
  background: #f5f5f5;
}

.section-head {
  padding: 14px 16px;
}

.section-head.wide {
  margin-bottom: 12px;
  padding: 0 0 12px;
}

.section-head p {
  color: var(--muted);
  font-size: 13px;
}

.view > .section-head.wide,
.today-command,
.revenue-overview,
.work-surface,
.intelligence-panel,
.metric,
.pipeline-column,
.deal-card,
.account-directory,
.directory-card,
.customer-list-card,
.product-section,
.product-card,
.partner-board section,
.partner-list-panel,
.partner-detail-panel,
.people-card,
.people-detail-main > section,
.people-detail-side > section,
.team-role-section,
.modal,
.strategy-workspace-shell,
.strategy-context-card,
.brief-action-panel,
.project-command-solution,
.project-summary-card,
.contract-money-card,
.current-project-control,
.opportunity-strategy-panel,
.account-side-card,
.project-card,
.campaign-card {
  border: 1px solid var(--line) !important;
  border-radius: var(--radius-container) !important;
  background: var(--surface) !important;
  box-shadow: none !important;
}

.today-command {
  grid-template-columns: minmax(320px, 0.9fr) minmax(360px, 1.1fr);
  min-height: 0;
  padding: 12px;
  gap: 12px;
}

.today-command-copy {
  padding: 10px 4px;
}

.today-command-copy h2 {
  max-width: 680px;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.15;
}

.today-command-copy p {
  color: var(--muted);
  font-size: 13px;
}

.today-signal-grid {
  gap: 8px;
}

.today-signal-grid div,
.revenue-period-grid > div,
.revenue-period-grid article,
.mini-stat,
.partner-stat,
.people-profile-grid div,
.detail-hero-stats div,
.overview-list div,
.commercial-grid div,
.strategy-summary-card,
.campaign-money-grid div,
.campaign-payment-row div,
.project-finance-card,
.project-info-cell {
  border: 1px solid var(--line) !important;
  border-radius: var(--radius-element) !important;
  background: var(--surface-2) !important;
  box-shadow: none !important;
}

.metric-strip {
  gap: 8px;
}

.metric {
  min-height: 72px;
  padding: 12px;
}

.metric::before {
  display: none;
}

.metric strong,
.revenue-period-grid strong,
.campaign-money-grid strong {
  font-weight: 700;
}

.revenue-overview {
  border-color: var(--line) !important;
  padding: 12px;
}

.revenue-period-grid {
  gap: 8px;
}

.revenue-period-grid article {
  min-height: 80px;
  padding: 10px;
}

.mention-notification-center {
  border-color: var(--line);
  border-radius: var(--radius-container);
  background: var(--surface);
  box-shadow: none;
}

.mention-center-head span,
.revenue-overview-head span {
  color: var(--muted);
  text-transform: none;
}

.mention-center-head > strong {
  background: #262626;
}

.mention-alert,
.mention-alert.unread {
  border-color: var(--line);
  border-radius: var(--radius-element);
  background: var(--surface-2);
}

.segmented {
  gap: 2px;
  padding: 3px;
  background: var(--surface-2);
}

.segmented button {
  border-radius: 8px;
  color: var(--muted);
  font-weight: 550;
}

.segmented button.active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.priority-row.header,
.account-row.header,
.contract-row.header,
.partner-table-head {
  background: var(--surface-2);
  color: var(--muted);
  font-weight: 600;
  text-transform: none;
}

.priority-row.data:hover,
.priority-row.data.selected,
.account-row:hover,
.partner-row:hover {
  background: #fafafa;
}

.pill,
.stage-pill,
.priority-pill,
.status-pill,
.customer-status-pill,
.brief-status-pill,
.commission-status,
.product-badge,
.column-owner {
  border-color: var(--line-strong) !important;
  background: var(--surface-2) !important;
  color: #525252 !important;
  box-shadow: none !important;
}

.priority-pill.hot,
.current-gate,
.unread .pill,
.customer-status-pill.urgent {
  border-color: #e6bab8 !important;
  background: #facecb !important;
  color: #89001a !important;
}

.pipeline-board {
  gap: 10px;
  padding: 2px 2px 8px;
}

.pipeline-column,
.pipeline-column:nth-child(-n + 3),
.pipeline-column.setup-column,
.pipeline-column.brief-column {
  min-width: 200px;
  min-height: 600px;
  padding: 10px;
  border-color: var(--line) !important;
  background: #fafafa !important;
}

.column-head {
  min-height: 78px;
  border-bottom-color: var(--line);
}

.column-head > span {
  background: #e5e5e5;
}

.deal-card {
  padding: 12px;
  cursor: grab;
  transition: transform 125ms ease, border-color 125ms ease, box-shadow 125ms ease;
}

.deal-card:hover {
  transform: translateY(-1px);
  border-color: var(--line-strong) !important;
  box-shadow: var(--shadow) !important;
}

.deal-card.dragging {
  opacity: 0.82;
  transform: translateY(-5px) scale(1.015);
  border-color: #a3a3a3 !important;
  background: #ffffff !important;
  box-shadow: var(--shadow-med) !important;
}

.pipeline-column.drag-over,
.pipeline-column:nth-child(-n + 3).drag-over,
.pipeline-column.setup-column.drag-over,
.pipeline-column.brief-column.drag-over {
  border-color: #737373 !important;
  background: #f5f5f5 !important;
  box-shadow: inset 0 0 0 1px #737373 !important;
}

.pipeline-column.drag-over::after {
  border-color: #a3a3a3;
  background: rgba(0, 0, 0, 0.025);
}

.pipeline-card-owners small,
.pipeline-card-milestones small,
.pipeline-card-next span {
  color: var(--muted);
}

.pipeline-card-owners > span,
.pipeline-card-milestones > span {
  border-color: var(--line);
  border-radius: var(--radius-inner);
  background: var(--surface-2);
}

.pipeline-card-milestones > span.complete,
.pipeline-card-milestones > span.current,
.pipeline-card-milestones > span.future {
  border-color: var(--line);
  background: var(--surface-2);
}

.pipeline-card-milestones > span.complete strong {
  color: #005600;
}

.pipeline-card-milestones > span.current strong {
  color: #171717;
}

.pipeline-card-next {
  border-left-color: #262626;
  background: var(--surface-2);
}

.directory-card,
.priority-project-card,
.product-card,
.campaign-card,
.project-card {
  transition: transform 125ms ease, border-color 125ms ease, box-shadow 125ms ease;
}

.directory-card:hover,
.priority-project-card:hover,
.product-card:hover,
.campaign-card:hover,
.project-card:hover {
  transform: translateY(-1px);
  border-color: var(--line-strong) !important;
  box-shadow: var(--shadow) !important;
}

.directory-card::before {
  width: 2px;
  background: #737373;
}

.logo-dot {
  border-radius: var(--radius-element);
  background: #262626;
  color: #ffffff;
}

.modal-backdrop,
.intake-overlay,
.opportunity-overlay,
.campaign-intake-overlay {
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
}

.intake-drawer {
  display: flex;
  flex-direction: column;
  width: min(1180px, calc(100vw - 48px));
  max-width: 1180px;
  max-height: min(880px, calc(100vh - 40px));
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-container);
  background: var(--surface);
  box-shadow: var(--shadow-med);
  animation: modalFloatIn 300ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.intake-head {
  flex: 0 0 auto;
  gap: 16px;
  padding: 20px 24px;
  border-bottom-color: var(--line);
  background: var(--surface);
}

.intake-head span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  text-transform: none;
}

.intake-head h2 {
  margin: 4px 0 6px;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.15;
}

.intake-head p {
  max-width: 720px;
  color: var(--muted);
  font-size: 13px;
}

.close-command {
  width: 36px;
  height: 36px;
  border-color: var(--line-strong);
  border-radius: var(--radius-element);
  background: var(--surface);
  font-size: 21px;
}

.intake-grid {
  grid-template-columns: minmax(320px, 0.8fr) minmax(520px, 1.2fr);
  flex: 1 1 auto;
  gap: 0;
  min-height: 0;
  padding: 0;
  overflow: hidden;
}

.intake-panel {
  min-width: 0;
  overflow-y: auto;
  padding: 20px;
  border: 0;
  border-radius: 0;
  background: var(--surface);
  box-shadow: none;
}

.intake-panel:first-child {
  border-right: 1px solid var(--line);
  background: #fafafa;
}

.result-panel {
  padding-bottom: 24px;
}

.field-label {
  margin-bottom: 6px;
  color: #525252;
  font-size: 12px;
  font-weight: 600;
  text-transform: none;
}

.field-input,
.field-textarea {
  border-color: var(--line-strong);
  border-radius: var(--radius-element);
  background: var(--surface);
}

.field-input {
  height: 40px;
}

.field-textarea {
  min-height: 240px;
}

.ai-signal-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-container);
  background: #262626;
}

.ai-signal-card b {
  font-size: 12px;
  text-transform: none;
}

.ai-signal-list span {
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.1);
}

.section-head.compact {
  margin: 0 0 14px;
}

.draft-form-grid.intake-review-grid {
  gap: 0;
}

.draft-review-section {
  gap: 12px;
  padding: 16px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
}

.draft-review-section:first-child {
  padding-top: 0;
}

.draft-review-section:last-child {
  border-bottom: 0;
}

.draft-section-title {
  align-items: flex-start;
  margin-bottom: 0;
}

.draft-form-field,
.draft-people-editor,
.draft-people-editor.compact {
  min-width: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.draft-form-field span,
.draft-section-title span {
  margin-bottom: 5px;
  color: #525252;
  font-size: 12px;
  font-weight: 600;
  text-transform: none;
}

.draft-section-title small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 450;
}

.draft-form-field input,
.draft-form-field select,
.draft-form-field textarea,
.draft-person-tool select,
.draft-person-tool input {
  border-color: var(--line-strong);
  border-radius: var(--radius-element);
  background: var(--surface);
  font-weight: 550;
}

.draft-form-field input,
.draft-form-field select,
.draft-person-tool select,
.draft-person-tool input {
  height: 40px;
}

.draft-form-field textarea {
  min-height: 88px;
}

.draft-person-list {
  min-height: 56px;
  padding: 10px 12px;
  border-color: var(--line);
  border-radius: var(--radius-element);
  background: var(--surface-2);
}

.draft-person-chip {
  border-color: var(--line-strong);
  background: var(--surface);
  color: var(--ink);
}

.draft-person-chip small {
  color: var(--muted);
}

.draft-person-chip button {
  background: #e5e5e5;
  color: var(--ink);
}

.draft-person-toolbar {
  grid-template-columns: 1fr;
  gap: 8px;
}

.draft-person-tool,
.draft-person-tool.manual {
  grid-template-columns: 88px minmax(0, 1fr) auto;
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
}

.draft-person-tool.manual {
  grid-template-columns: 88px minmax(0, 1fr) minmax(120px, 0.65fr) auto;
}

.draft-person-tool > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 550;
}

.missing-card {
  margin-top: 14px;
  padding: 12px;
  border-color: #e6bab8;
  border-radius: var(--radius-element);
  background: #fff8f7;
}

.missing-card b {
  color: #89001a;
}

.intake-actions.end {
  position: sticky;
  bottom: -24px;
  z-index: 2;
  margin: 16px -20px -24px;
  padding: 14px 20px;
  border-top: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}

.intake-created-card {
  border-color: var(--line);
  border-radius: var(--radius-container);
  background: var(--surface-2);
}

.opportunity-dialog,
.campaign-intake-dialog,
.modal {
  border: 1px solid var(--line-strong) !important;
  border-radius: var(--radius-container) !important;
  background: var(--surface) !important;
  box-shadow: var(--shadow-med) !important;
}

.app-version-badge {
  right: 12px;
  bottom: 10px;
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.92);
  color: var(--muted);
  box-shadow: var(--shadow);
}

/* Accounts overview: keep headings and controls clear of container edges. */
#accountsView > .section-head.wide {
  align-items: flex-start;
  gap: 24px;
  margin: 0 0 16px;
  padding: 20px;
}

#accountsView > .section-head.wide > div:first-child {
  min-width: 0;
  padding-top: 2px;
}

#accountsView > .section-head.wide h2 {
  margin: 0 0 6px;
}

#accountsView > .section-head.wide p {
  max-width: 680px;
  margin: 0;
}

#accountsView .section-actions {
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

#accountsView .account-directory {
  gap: 18px;
  padding: 18px 20px 20px;
}

#accountsView .account-summary-section,
#accountsView .customer-list-card {
  display: grid;
  gap: 14px;
}

#accountsView .subsection-head {
  min-height: 32px;
  margin: 0;
}

#accountsView .subsection-head h3,
#accountsView .subsection-head span {
  margin: 0;
}

@media (max-width: 1180px) {
  .topbar {
    align-items: flex-start;
  }

  .topbar-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .intake-grid {
    grid-template-columns: minmax(280px, 0.72fr) minmax(480px, 1.28fr);
  }

  .draft-field-row.three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #accountsView > .section-head.wide {
    gap: 16px;
    padding: 18px;
  }

  #accountsView .account-directory {
    padding: 16px 18px 18px;
  }
}

@media (max-width: 860px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

  .intake-drawer {
    width: calc(100vw - 24px);
    max-height: calc(100vh - 24px);
  }

  .intake-grid {
    display: block;
    overflow-y: auto;
  }

  .intake-panel {
    overflow: visible;
  }

  .intake-panel:first-child {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .draft-field-row.three,
  .draft-field-row.two,
  .draft-person-tool,
  .draft-person-tool.manual {
    grid-template-columns: 1fr;
  }

  .today-command {
    grid-template-columns: 1fr;
  }

  .topbar {
    display: grid;
  }

  .topbar-actions {
    justify-content: flex-start;
  }

  .search-box {
    width: min(100%, 360px);
  }

  #accountsView > .section-head.wide {
    display: grid;
  }

  #accountsView .section-actions {
    align-items: flex-start;
  }
}

/* Responsive shell and pipeline layout ------------------------------------ */
html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

.app-shell,
.main-panel,
.view,
#pipelineView {
  min-width: 0;
}

.topbar > div:first-child {
  min-width: max-content;
}

#viewTitle {
  white-space: nowrap;
}

#pipelineView > .section-head.wide {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 18px;
  padding: 16px 18px;
}

#pipelineView > .section-head.wide > div:first-child {
  min-width: 0;
}

#pipelineView > .section-head.wide p {
  max-width: 760px;
  margin-top: 4px;
}

#pipelineView .section-actions {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
}

#pipelineView .section-actions .button {
  white-space: nowrap;
}

#pipelineView .pipeline-board {
  display: grid;
  grid-template-columns: repeat(6, minmax(248px, 1fr));
  width: 100%;
  min-width: 0;
  max-width: 100%;
  gap: 10px;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-inline: contain;
  scrollbar-gutter: stable;
  padding: 2px 2px 14px;
}

#pipelineView .pipeline-column,
#pipelineView .pipeline-column.stage-strategy,
#pipelineView .pipeline-column.stage-project {
  width: auto;
  min-width: 248px;
}

#pipelineView .deal-card,
#pipelineView .pipeline-card-account,
#pipelineView .pipeline-card-title-row,
#pipelineView .pipeline-card-next {
  min-width: 0;
}

#pipelineView .pipeline-card-account span,
#pipelineView .pipeline-card-title-row h3,
#pipelineView .pipeline-card-next strong {
  overflow-wrap: anywhere;
}

@media (max-width: 1400px) {
  .app-shell {
    grid-template-columns: 220px minmax(0, 1fr);
  }

  .sidebar {
    padding-inline: 10px;
  }

  .main-panel {
    padding: 18px 18px 40px;
  }

  .topbar {
    display: grid;
    grid-template-columns: minmax(150px, auto) minmax(0, 1fr);
    gap: 16px;
  }

  .topbar-actions {
    display: grid;
    grid-template-columns: auto minmax(180px, 1fr) 40px auto;
    align-items: start;
    width: 100%;
    min-width: 0;
    gap: 8px;
  }

  .search-box {
    width: 100%;
    min-width: 0;
  }

  .primary-action-wrap,
  .primary-command {
    min-width: 0;
  }

  .primary-command {
    white-space: nowrap;
  }
}

@media (max-width: 1120px) {
  .app-shell {
    grid-template-columns: 200px minmax(0, 1fr);
  }

  .main-panel {
    padding-inline: 14px;
  }

  .topbar {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .topbar-actions {
    grid-template-columns: auto minmax(160px, 1fr) 40px auto;
  }

  #pipelineView > .section-head.wide {
    grid-template-columns: minmax(0, 1fr);
  }

  #pipelineView .section-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 860px) {
  .app-shell {
    display: block;
  }

  .sidebar {
    position: relative;
    z-index: 4;
    width: 100%;
    height: auto;
    padding: 10px 12px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .sidebar .brand {
    margin-bottom: 8px;
  }

  .sidebar .nav-list {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .sidebar .nav-item {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  .sidebar .customer-subnav,
  .sidebar .signal-panel {
    display: none !important;
  }

  .main-panel {
    padding: 14px 12px 32px;
  }

  .topbar-actions {
    grid-template-columns: auto minmax(0, 1fr) 40px;
  }

  .primary-action-wrap {
    grid-column: 1 / -1;
  }

  .primary-command {
    width: 100%;
  }

  #pipelineView > .section-head.wide {
    padding: 14px;
  }

  #pipelineView .pipeline-board {
    grid-template-columns: repeat(6, 232px);
  }

  #pipelineView .pipeline-column,
  #pipelineView .pipeline-column.stage-strategy,
  #pipelineView .pipeline-column.stage-project {
    min-width: 232px;
  }
}

@media (max-width: 560px) {
  .topbar-actions {
    grid-template-columns: auto 40px;
  }

  .search-box {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .primary-action-wrap {
    grid-row: 3;
  }

  #pipelineView .section-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
  }

  #pipelineView .section-actions .button {
    width: 100%;
  }
}

/* Content-aware dashboard responsiveness --------------------------------- */
#todayView {
  container-name: today-workspace;
  container-type: inline-size;
}

#todayView .today-command,
#todayView .today-action-stack,
#todayView .today-command-copy,
#todayView .today-signal-grid,
#todayView .today-mention-inline,
#todayView .revenue-overview,
#todayView .revenue-period-grid,
#todayView .work-surface,
#todayView #priorityTable {
  min-width: 0;
}

#todayView .today-mention-inline button,
#todayView .revenue-period-grid article {
  overflow: hidden;
}

#todayView .revenue-period-grid strong {
  font-size: clamp(21px, 2.15cqi, 30px);
  line-height: 1.05;
  white-space: nowrap;
}

@container today-workspace (max-width: 1250px) {
  #todayView .today-command {
    grid-template-columns: minmax(300px, 0.82fr) minmax(0, 1.18fr);
  }

  #todayView .today-action-stack {
    grid-template-columns: minmax(0, 1fr);
  }

  #todayView .today-signal-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  #todayView .today-signal-grid div {
    min-height: 64px;
    padding: 10px;
  }

  #todayView .today-mention-inline {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #todayView .revenue-overview {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  #todayView .revenue-overview-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
  }

  #todayView .revenue-overview-head p {
    max-width: none;
    margin-top: 0;
    text-align: right;
  }

  #todayView .priority-row {
    grid-template-columns:
      minmax(260px, 1.45fr)
      minmax(140px, 0.8fr)
      minmax(96px, 0.5fr)
      minmax(180px, 1fr)
      minmax(110px, 0.62fr)
      58px;
    min-width: 0;
    gap: 10px;
    padding-inline: 14px;
  }

  #todayView .priority-row > span:nth-child(4) {
    display: none;
  }
}

@container today-workspace (max-width: 900px) {
  #todayView .today-command {
    grid-template-columns: minmax(0, 1fr);
  }

  #todayView .today-command-copy {
    padding: 12px;
  }

  #todayView .today-command-copy h2 {
    max-width: none;
    font-size: 26px;
  }

  #todayView .revenue-period-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #todayView .work-surface > .section-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }

  #todayView .queue-controls {
    justify-content: flex-start;
  }

  #todayView .priority-row.header {
    display: none;
  }

  #todayView .priority-row.data {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px 14px;
    min-height: 0;
    padding: 14px;
  }

  #todayView .priority-row.data > span {
    display: block;
  }

  #todayView .priority-row.data > span:nth-child(1),
  #todayView .priority-row.data > span:nth-child(5) {
    grid-column: 1 / -1;
  }

  #todayView .priority-row.data > span:nth-child(4) {
    display: none;
  }

  #todayView .priority-row.data > span:nth-child(5) {
    padding: 9px 10px;
    border-radius: 8px;
    background: var(--surface-2);
    white-space: normal;
  }

  #todayView .priority-row.data > span:nth-child(6) {
    align-self: end;
  }

  #todayView .priority-row.data > span:nth-child(7) {
    justify-self: end;
    align-self: end;
  }
}

@container today-workspace (max-width: 620px) {
  #todayView .today-signal-grid,
  #todayView .today-mention-inline,
  #todayView .revenue-period-grid,
  #todayView .metric-strip {
    grid-template-columns: minmax(0, 1fr);
  }

  #todayView .revenue-overview-head {
    display: grid;
    justify-content: start;
  }

  #todayView .revenue-overview-head p {
    text-align: left;
  }

  #todayView .priority-row.data {
    grid-template-columns: minmax(0, 1fr);
  }

  #todayView .priority-row.data > span:nth-child(1),
  #todayView .priority-row.data > span:nth-child(2),
  #todayView .priority-row.data > span:nth-child(3),
  #todayView .priority-row.data > span:nth-child(5),
  #todayView .priority-row.data > span:nth-child(6),
  #todayView .priority-row.data > span:nth-child(7) {
    grid-column: 1;
    justify-self: stretch;
  }
}
