:root {
  --bg: #f3f9ff;
  --surface: #ffffff;
  --surface-2: #eef6ff;
  --ink: #061746;
  --muted: #5d6f9a;
  --line: #dce8f8;
  --primary: #075cf5;
  --primary-2: #0aa9ee;
  --primary-soft: #e8f4ff;
  --green: #14b86f;
  --green-soft: #e4faef;
  --amber: #f4a72d;
  --amber-soft: #fff3dc;
  --red: #e04464;
  --red-soft: #fff0f4;
  --blue: #075cf5;
  --shadow: 0 24px 70px rgba(12, 66, 130, .10);
  --shadow-sm: 0 16px 44px rgba(12, 66, 130, .08);
  --radius: 22px;
  --radius-sm: 14px;
}

body {
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 4%, rgba(10, 169, 238, .16), transparent 30%),
    radial-gradient(circle at 88% 0%, rgba(7, 92, 245, .13), transparent 28%),
    linear-gradient(180deg, #ffffff 0%, #f5fbff 48%, #eef7ff 100%);
}

h1,
h2,
h3 {
  color: var(--ink);
}

.button {
  background: linear-gradient(145deg, #1282ff, var(--primary));
  border-radius: 14px;
  box-shadow: 0 14px 30px rgba(7, 92, 245, .22);
}

.button.ghost {
  background: rgba(255, 255, 255, .86);
  color: var(--primary);
  border-color: var(--line);
  box-shadow: none;
}

.button:hover {
  box-shadow: 0 18px 38px rgba(7, 92, 245, .24);
}

.soft-pill,
.recommended,
.eyebrow {
  color: var(--primary);
}

.soft-pill,
.recommended {
  background: rgba(232, 244, 255, .95);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.brand-logo {
  filter: drop-shadow(0 10px 20px rgba(7, 92, 245, .08));
}

/* Public pages */
.public-shell {
  background:
    radial-gradient(circle at 10% 6%, rgba(10, 169, 238, .17), transparent 28%),
    radial-gradient(circle at 88% 9%, rgba(7, 92, 245, .16), transparent 28%),
    linear-gradient(180deg, #ffffff 0%, #f7fbff 55%, #edf7ff 100%);
}

.public-nav {
  max-width: 1240px;
  margin: 12px auto 0;
  padding: 11px 16px;
  border: 1px solid rgba(212, 227, 246, .88);
  border-radius: 21px;
  background: rgba(255, 255, 255, .84);
  box-shadow: 0 18px 54px rgba(8, 50, 112, .08);
  backdrop-filter: blur(18px);
}

.public-nav > div {
  gap: 22px;
}

.public-nav > div > a:not(.button) {
  color: #183366;
  font-weight: 850;
}

.hero {
  max-width: 1240px;
  padding: 74px 30px 84px;
  grid-template-columns: minmax(0, 1fr) minmax(420px, .88fr);
  gap: 48px;
}

.hero-copy h1 {
  max-width: 760px;
  margin: 20px 0 18px;
  font-size: clamp(44px, 5.2vw, 72px);
  line-height: .98;
  letter-spacing: -.065em;
}

.hero-copy h1 strong,
.pricing-head h1 strong {
  color: var(--primary);
}

.hero-copy > p {
  color: var(--muted);
  font-size: 19px;
  line-height: 1.55;
}

.trust-row {
  gap: 16px;
  color: #38517c;
}

.trust-row span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.trust-row span::before {
  content: "";
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: inset 0 0 0 5px rgba(255, 255, 255, .72);
}

.hero-visual {
  min-height: 470px;
  position: relative;
}

.hero-visual::before {
  content: "";
  position: absolute;
  inset: 36px 44px 88px 0;
  border: 1px solid rgba(196, 217, 244, .86);
  border-radius: 28px;
  background:
    linear-gradient(90deg, rgba(238, 246, 255, .86) 0 30%, rgba(255, 255, 255, .84) 30% 100%),
    radial-gradient(circle at 80% 28%, rgba(10, 169, 238, .16), transparent 26%);
  box-shadow: 0 30px 70px rgba(26, 91, 151, .13);
  transform: rotate(1deg);
}

.conversation-orbit {
  width: min(100%, 395px);
  justify-self: end;
  z-index: 1;
  border-radius: 24px;
  border-color: rgba(205, 224, 248, .92);
  box-shadow: 0 28px 68px rgba(9, 50, 110, .18);
}

.conversation-orbit::before,
.conversation-orbit::after {
  display: none;
}

.orbit-head {
  color: var(--ink);
  border-bottom: 1px solid var(--line);
  margin: -4px -4px 14px;
  padding: 0 0 14px;
}

.bubble.customer {
  background: #eef3fa;
  color: #223b64;
}

.bubble.ai {
  margin-left: auto;
  background: linear-gradient(145deg, #1590ff, var(--primary));
  color: #fff;
}

.action-object {
  border-color: #bed8fa;
  background: #f5faff;
}

.action-object button {
  background: var(--primary);
  box-shadow: 0 12px 24px rgba(7, 92, 245, .18);
}

.feature-band {
  gap: 14px;
}

.feature-band article,
.price-card,
.focused-form,
.help-hero,
.faq-list details,
.ticket-row,
.ticket-thread-card,
.ticket-side-panel {
  border-color: rgba(205, 224, 248, .88);
  border-radius: 20px;
  background: rgba(255, 255, 255, .86);
  box-shadow: var(--shadow-sm);
}

.pricing-preview {
  color: var(--ink);
  background: linear-gradient(120deg, rgba(232, 244, 255, .95), rgba(255, 255, 255, .96));
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}

.pricing-preview .eyebrow {
  color: var(--primary);
}

.mini-plans a {
  color: var(--ink);
  background: rgba(255, 255, 255, .88);
  border-color: var(--line);
}

.pricing-head h1 {
  font-size: clamp(38px, 4.6vw, 62px);
  line-height: 1;
  letter-spacing: -.06em;
}

.pricing-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.pricing-grid .price-card:only-child {
  max-width: 430px;
  width: 100%;
  justify-self: center;
}

.price-card.featured {
  border-color: #9cc8ff;
  box-shadow: 0 26px 70px rgba(7, 92, 245, .14);
}

/* Workspace shell */
.app-shell-body {
  background:
    radial-gradient(circle at 18% 0%, rgba(10, 169, 238, .13), transparent 28%),
    radial-gradient(circle at 92% 2%, rgba(7, 92, 245, .10), transparent 26%),
    linear-gradient(180deg, #ffffff 0%, #f4faff 46%, #eef7ff 100%);
}

.app-shell {
  grid-template-columns: 238px minmax(0, 1fr);
}

.sidebar {
  color: #183366;
  background: rgba(255, 255, 255, .76);
  border-right: 1px solid rgba(198, 218, 244, .74);
  box-shadow: 14px 0 40px rgba(12, 66, 130, .05);
  backdrop-filter: blur(20px);
}

.sidebar .brand strong,
.sidebar .user-card strong {
  color: var(--ink);
}

.sidebar .brand small,
.sidebar .user-card small,
.nav-label {
  color: var(--muted);
}

.nav-list > a {
  color: #25416e;
  font-weight: 800;
  border-radius: 15px;
}

.nav-list > a > span {
  width: 25px;
  height: 25px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: #edf5ff;
  color: var(--primary);
}

.nav-list > a:hover,
.nav-list > a.active {
  background: linear-gradient(90deg, rgba(7, 92, 245, .14), rgba(10, 169, 238, .07));
  color: var(--primary);
  box-shadow: inset 3px 0 0 var(--primary);
}

.nav-list > a.active > span {
  color: var(--primary);
}

.plan-chip,
.sidebar .icon-button {
  color: #244574;
  background: rgba(248, 251, 255, .96);
  border-color: var(--line);
}

.sidebar-foot {
  color: var(--ink);
}

.topbar {
  min-height: 78px;
  padding: 17px 28px 14px;
  background: rgba(255, 255, 255, .72);
  border-bottom: 1px solid rgba(198, 218, 244, .72);
  box-shadow: 0 14px 36px rgba(12, 66, 130, .05);
}

.topbar h1 {
  font-size: clamp(26px, 2.6vw, 38px);
  line-height: 1.06;
  letter-spacing: -.05em;
}

.page-content {
  padding: 20px 28px 42px;
}

.billing-alert,
.setup-shell-banner,
.journey-page-guide,
.brain-sync-note {
  border: 1px solid #c9defd;
  border-radius: 18px;
  background: linear-gradient(90deg, #edf7ff, #ffffff);
  color: #244574;
  box-shadow: 0 14px 34px rgba(12, 66, 130, .06);
}

.billing-alert strong,
.setup-shell-banner strong,
.journey-page-guide strong,
.brain-sync-note strong {
  color: var(--ink);
}

.pulse-card,
.flow-panel,
.day-rail,
.signal-panel,
.channel-panel,
.table-card,
.operation-panel,
.knowledge-main,
.knowledge-compose,
.embed-panel,
.customer-card,
.profile-hero,
.lead-node {
  border-color: rgba(205, 224, 248, .88);
  border-radius: 20px;
  background: rgba(255, 255, 255, .88);
  box-shadow: var(--shadow-sm);
}

.pulse-card.primary {
  background: linear-gradient(145deg, #1590ff, var(--primary));
}

.pulse-card.quiet {
  background: linear-gradient(145deg, var(--ink), #123b76);
}

.avatar,
.score-ring {
  background: linear-gradient(145deg, #e4f2ff, #ffffff);
  color: var(--primary);
}

.avatar.ai {
  background: linear-gradient(145deg, #1590ff, var(--primary));
  color: #fff;
}

.field input:not([type=checkbox]):not([type=radio]),
.field select,
.field textarea,
.thread-toolbar input,
.thread-toolbar select,
.search-bar input,
.filter-strip select,
.composer textarea,
.public-chat textarea {
  min-height: 44px;
  border-color: var(--line);
  border-radius: 14px;
  background: #f9fcff;
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.composer textarea:focus {
  border-color: #9cc8ff;
  box-shadow: 0 0 0 4px rgba(7, 92, 245, .09);
}

/* Interactions */
.inbox-shell {
  height: calc(100vh - 158px);
  grid-template-columns: 300px minmax(0, 1fr) 294px;
  border-color: rgba(205, 224, 248, .9);
  border-radius: 22px;
  background: rgba(255, 255, 255, .88);
  box-shadow: var(--shadow-sm);
}

.thread-list,
.context-rail {
  border-color: var(--line);
  background: rgba(255, 255, 255, .78);
}

.thread-tabs a {
  border-radius: 999px;
  font-size: 11px;
}

.thread-tabs a.active {
  background: #e6f2ff;
  color: var(--primary);
}

.thread.active {
  background: linear-gradient(90deg, rgba(7, 92, 245, .12), rgba(255, 255, 255, .38));
  box-shadow: inset 3px 0 0 var(--primary);
}

.thread.attention {
  background: linear-gradient(90deg, rgba(255, 243, 220, .9), rgba(255, 255, 255, .5));
}

.channel-avatar,
.channel-dot,
.channel-logo {
  border-radius: 15px;
}

.channel-avatar.whatsapp,
.channel-dot.whatsapp,
.channel-logo.whatsapp {
  background: #19c76f;
  color: #fff;
}

.channel-avatar.instagram,
.channel-dot.instagram,
.channel-logo.instagram {
  background: linear-gradient(145deg, #7b35ff, #ff4f88, #ffc044);
  color: #fff;
}

.channel-avatar.facebook,
.channel-dot.facebook,
.channel-logo.facebook {
  background: #1768ee;
  color: #fff;
}

.channel-avatar.website,
.channel-dot.website,
.channel-logo.website {
  background: var(--primary-2);
  color: #fff;
}

.conversation-head {
  background: rgba(255, 255, 255, .92);
  border-color: var(--line);
}

.message-stage {
  background: linear-gradient(180deg, rgba(244, 249, 255, .82), #ffffff);
}

.message-bubble {
  border-color: var(--line);
  border-radius: 17px;
}

.message-line.outbound .message-bubble {
  background: linear-gradient(145deg, #1590ff, var(--primary));
  border-color: #1590ff;
  color: #fff;
}

.message-line.outbound .message-bubble span,
.message-line.outbound .message-bubble time,
.message-line.outbound .message-delivery-status {
  color: rgba(255, 255, 255, .78);
}

.handoff-alert {
  border-color: #ffe1a7;
  background: linear-gradient(90deg, #fff7e8, #ffffff);
}

.context-rail section,
.agent-popover,
.agent-row {
  border-color: var(--line);
  border-radius: 17px;
}

.ai-context {
  background: linear-gradient(145deg, #eaf5ff, #ffffff) !important;
}

.composer {
  border-color: var(--line);
}

/* Channels */
.channel-hero {
  color: var(--ink);
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at 88% 12%, rgba(7, 92, 245, .12), transparent 26%),
    linear-gradient(135deg, #edf7ff, #ffffff 62%, #f7fcff);
  box-shadow: var(--shadow-sm);
}

.channel-hero p,
.connection-map span {
  color: var(--muted);
}

.connection-map {
  border-color: #c9defd;
  background: rgba(255, 255, 255, .78);
}

.connection-map strong {
  color: var(--primary);
}

.channel-cards {
  gap: 12px;
}

.channel-cards > article.channel-card {
  border-color: rgba(205, 224, 248, .9);
  border-radius: 20px;
  background: rgba(255, 255, 255, .88);
  box-shadow: var(--shadow-sm);
}

.channel-card:hover {
  transform: translateY(-2px);
  border-color: #9cc8ff;
}

.channel-card .channel-card-head h3 {
  color: var(--ink);
}

.connected-asset {
  border-color: #c8f3dd;
  background: linear-gradient(145deg, #eafff5, #ffffff);
}

.embed-panel {
  background: linear-gradient(120deg, rgba(232, 244, 255, .92), rgba(255, 255, 255, .96));
}

/* Services and slots */
.filter-strip {
  border: 1px solid var(--line);
  border-radius: 17px;
  background: rgba(255, 255, 255, .84);
  box-shadow: var(--shadow-sm);
}

.operations-grid {
  gap: 14px;
}

.operation-review-banner {
  background:
    radial-gradient(circle at 88% 12%, rgba(20, 184, 111, .16), transparent 24%),
    linear-gradient(135deg, #eef8ff, #ffffff);
}

.operation-row,
.staff-row {
  border-color: #edf3fb;
}

.operation-row.manageable,
.staff-row.manageable {
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 8px;
  background: #fbfdff;
  border: 1px solid #edf3fb;
}

.operation-row.manageable:last-child,
.staff-row.manageable:last-child {
  margin-bottom: 0;
}

.operation-row b,
.staff-row em,
.availability-window em {
  width: max-content;
  padding: 5px 8px;
  border-radius: 999px;
  background: var(--green-soft);
  color: #087548;
  font-weight: 900;
}

.staff-row > i {
  width: 42px;
  height: 42px;
  border-radius: 15px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .28), 0 12px 24px rgba(12, 66, 130, .12);
}

.staff-hours-panel {
  background: linear-gradient(180deg, rgba(255, 255, 255, .9), #f8fcff);
}

.availability-staff-group {
  border-color: var(--line);
  border-radius: 18px;
  background: #fbfdff;
  box-shadow: 0 14px 32px rgba(12, 66, 130, .07);
}

.availability-window {
  border-color: #e4eefb;
  background: #ffffff;
}

.status-dot.active,
.status-dot.connected,
.status-dot.captured,
.status-dot.paid,
.status-dot.completed,
.status-dot.confirmed {
  background: var(--green-soft);
  color: #087548;
}

.status-dot.pending,
.status-dot.processing,
.status-dot.authorized,
.state-pill.waiting {
  background: var(--amber-soft);
  color: #99620d;
}

.status-dot.failed,
.status-dot.overdue,
.status-dot.error,
.status-dot.suspended,
.status-dot.cancelled,
.status-dot.past_due {
  background: var(--red-soft);
  color: var(--red);
}

/* Screenshot QA fixes */
.app-shell select,
.public-chat select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 42px !important;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 14px;
  background-color: #f9fcff;
  background-image:
    url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 7.5L10 12.5L15 7.5' stroke='%23061746' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 14px 14px;
}

.filter-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 20px;
}

.filter-strip form {
  display: flex;
  align-items: center;
  flex: 1 1 auto;
  flex-wrap: wrap;
  gap: 10px;
  min-width: 0;
}

.filter-strip select {
  width: auto;
  min-width: 190px;
  max-width: 260px;
  flex: 0 1 230px;
  box-shadow: none;
}

.filter-strip > span {
  flex: 0 0 auto;
  margin-left: auto;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.interaction-row {
  grid-template-columns: auto minmax(0, 1fr) auto;
}

.interaction-row form {
  margin: 0;
  justify-self: end;
}

.interaction-row form select {
  width: auto;
  min-width: 178px;
  min-height: 40px;
  padding: 8px 38px 8px 12px !important;
  font-size: 13px;
  font-weight: 800;
  box-shadow: none;
}

.staff-row.manageable {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
}

.staff-row.manageable > i {
  grid-column: 1;
  flex: 0 0 auto;
}

.staff-row.manageable > a {
  grid-column: 2;
  display: grid;
  gap: 2px;
  min-width: 0;
}

.staff-row.manageable > a strong,
.staff-row.manageable > a span,
.staff-row.manageable > a small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.staff-row.manageable > a small {
  color: var(--muted);
  font-size: 11px;
}

.staff-row.manageable > em,
.staff-row.manageable > form {
  justify-self: end;
}

.message-line.outbound .structured-reply .reply-summary,
.message-line.outbound .structured-reply .reply-section,
.public-chat .message-line.outbound .structured-reply .reply-summary,
.public-chat .message-line.outbound .structured-reply .reply-section {
  color: rgba(255, 255, 255, .82);
}

.message-line.outbound .structured-reply .reply-heading,
.message-line.outbound .structured-reply .reply-section strong,
.public-chat .message-line.outbound .structured-reply .reply-heading,
.public-chat .message-line.outbound .structured-reply .reply-section strong {
  color: #ffffff;
}

.message-line.outbound .structured-reply .reply-section,
.public-chat .message-line.outbound .structured-reply .reply-section {
  border-top-color: rgba(255, 255, 255, .22);
}

.message-line.outbound .reply-action,
.public-chat .message-line.outbound .reply-action {
  color: #ffffff;
  border-color: rgba(255, 255, 255, .58);
}

.message-line.outbound .reply-action:hover,
.message-line.outbound .reply-action:focus-visible,
.public-chat .message-line.outbound .reply-action:hover,
.public-chat .message-line.outbound .reply-action:focus-visible {
  background: rgba(255, 255, 255, .14);
}

@media (max-width: 1100px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    min-height: 420px;
  }

  .conversation-orbit {
    justify-self: center;
  }
}

@media (max-width: 800px) {
  .app-shell-body {
    background: #f6fbff;
  }

  .sidebar {
    background: rgba(255, 255, 255, .96);
  }

  .topbar {
    min-height: 66px;
    padding: 10px 14px;
  }

  .page-content {
    padding: 10px 14px 78px;
  }

  .inbox-shell {
    height: calc(100dvh - 133px);
    border-radius: 0;
    border: 0;
  }

  .filter-strip {
    align-items: stretch;
  }

  .filter-strip,
  .filter-strip form {
    display: grid;
  }

  .filter-strip select {
    width: 100%;
    max-width: none;
    flex-basis: auto;
  }

  .filter-strip > span {
    margin-left: 0;
  }

  .interaction-row,
  .staff-row.manageable {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .staff-row.manageable > i {
    grid-row: 1 / span 3;
  }

  .staff-row.manageable > a {
    grid-column: 2;
  }

  .interaction-row form,
  .staff-row.manageable > em,
  .staff-row.manageable > form {
    grid-column: 2;
    justify-self: start;
  }

  .interaction-row form select {
    width: 100%;
    min-width: 170px;
  }
}

@media (max-width: 520px) {
  .public-nav {
    margin: 0;
    border-radius: 0 0 18px 18px;
  }

  .hero {
    padding: 36px 18px 68px;
  }

  .hero-copy h1 {
    font-size: 39px;
  }

  .hero-visual::before {
    inset: 36px 0 110px;
  }

  .conversation-orbit {
    width: 100%;
  }

  .pricing-preview {
    margin-left: 18px;
    margin-right: 18px;
  }
}

/* Authenticated workspace contrast guardrails.
   Keep this block last: app.css contains legacy dark variants for these
   components, and this stylesheet is the final workspace theme layer. */
.app-shell .pulse-card.quiet {
  color: var(--ink);
  border: 1px solid #c9defd;
  background: linear-gradient(145deg, #edf7ff, #ffffff);
  box-shadow: var(--shadow-sm);
}

.app-shell .pulse-card.quiet .metric-label,
.app-shell .pulse-card.quiet p {
  color: var(--muted);
}

.app-shell .pulse-card.quiet .live-status {
  color: var(--ink);
}

.app-shell .setup-hero {
  color: var(--ink);
  border: 1px solid #c9defd;
  background:
    radial-gradient(circle at 88% 12%, rgba(7, 92, 245, .12), transparent 26%),
    linear-gradient(135deg, #edf7ff, #ffffff 62%, #f7fcff);
  box-shadow: var(--shadow-sm);
}

.app-shell .setup-hero h2,
.app-shell .setup-score strong,
.app-shell .setup-pass-line strong {
  color: var(--ink);
}

.app-shell .setup-hero > div > p,
.app-shell .setup-score span,
.app-shell .setup-pass-line span {
  color: var(--muted);
}

.app-shell .setup-pass-line,
.app-shell .setup-score {
  border-color: #c9defd;
  background: rgba(255, 255, 255, .82);
}

.app-shell .setup-pass-line.expired {
  border-color: #f2cd88;
  background: #fff8e8;
}

.app-shell .setup-score progress {
  accent-color: var(--primary);
}

.app-shell .knowledge-ready-hero,
.app-shell .knowledge-ready-hero.waiting,
.app-shell .knowledge-ready-hero.complete,
.app-shell .brain-hero,
.app-shell .operation-review-banner,
.app-shell .help-ticket-cta {
  color: var(--ink);
  border: 1px solid #c9defd !important;
  background:
    radial-gradient(circle at 88% 12%, rgba(10, 169, 238, .11), transparent 25%),
    linear-gradient(135deg, #edf7ff, #ffffff 66%, #f7fcff);
  box-shadow: var(--shadow-sm);
}

.app-shell .knowledge-ready-hero.complete {
  border-color: #bfe7d6 !important;
  background: linear-gradient(135deg, #eafff5, #ffffff 72%, #f2fffa);
}

.app-shell .brain-hero.review_required,
.app-shell .brain-hero.not_configured {
  border-color: #f2cd88 !important;
  background: linear-gradient(135deg, #fff8e8, #ffffff 72%, #fffaf0);
}

.app-shell .knowledge-ready-hero h2,
.app-shell .brain-hero h2,
.app-shell .brain-score > strong,
.app-shell .operation-review-banner h2,
.app-shell .help-ticket-cta h2 {
  color: var(--ink);
}

.app-shell .knowledge-ready-hero p,
.app-shell .knowledge-ready-hero small,
.app-shell .brain-hero p,
.app-shell .brain-score > span,
.app-shell .operation-review-banner p,
.app-shell .help-ticket-cta p {
  color: var(--muted) !important;
}

.app-shell .operation-review-banner .eyebrow,
.app-shell .help-ticket-cta .eyebrow {
  color: var(--primary);
}

.app-shell .help-ticket-cta .button.secondary {
  color: var(--primary);
  border-color: #b9d5f8;
  background: #ffffff;
}

.landing-clarity,
.control-band {
  max-width: 1180px;
  margin: 0 auto 80px;
  padding: 0 30px;
}

.landing-section-head {
  max-width: 720px;
  margin-bottom: 22px;
}

.landing-section-head h2,
.control-copy h2 {
  font-size: clamp(30px, 3.2vw, 46px);
  line-height: 1.02;
  letter-spacing: -.045em;
  margin: 8px 0 12px;
}

.landing-section-head p,
.control-copy p,
.clarity-grid p,
.control-grid span {
  color: var(--muted);
}

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

.clarity-grid article,
.control-grid article {
  border: 1px solid rgba(205, 224, 248, .88);
  border-radius: 20px;
  background: rgba(255, 255, 255, .86);
  box-shadow: var(--shadow-sm);
}

.clarity-grid article {
  min-height: 230px;
  padding: 26px;
}

.clarity-number {
  display: inline-grid;
  width: 38px;
  height: 38px;
  place-items: center;
  margin-bottom: 20px;
  border-radius: 13px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 12px;
  font-weight: 900;
}

.clarity-grid h3 {
  font-size: 21px;
  margin: 0 0 9px;
}

.clarity-grid p {
  margin: 0;
  line-height: 1.62;
}

.control-band {
  display: grid;
  grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr);
  gap: 22px;
  align-items: stretch;
  padding-top: 42px;
  padding-bottom: 42px;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    radial-gradient(circle at 8% 12%, rgba(10, 169, 238, .13), transparent 28%),
    linear-gradient(120deg, rgba(232, 244, 255, .95), rgba(255, 255, 255, .96));
  box-shadow: var(--shadow-sm);
}

.control-copy {
  padding: 0 10px;
}

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

.control-grid article {
  display: grid;
  gap: 7px;
  padding: 18px;
  background: rgba(255, 255, 255, .76);
}

.control-grid strong {
  font-size: 15px;
}

.control-grid span {
  font-size: 13px;
  line-height: 1.5;
}

@media (max-width: 900px) {
  .clarity-grid,
  .control-band,
  .control-grid {
    grid-template-columns: 1fr;
  }

  .landing-clarity,
  .control-band {
    margin-bottom: 48px;
  }
}

@media (max-width: 640px) {
  .landing-clarity,
  .control-band {
    padding-left: 20px;
    padding-right: 20px;
  }

  .control-band {
    border-radius: 22px;
  }
}


.book-demo-dialog {
  width: min(680px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 0;
  overflow: auto;
  color: var(--ink);
  border: 1px solid rgba(196, 217, 244, .95);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 28px 90px rgba(8, 50, 112, .24);
}

.book-demo-dialog[open] {
  animation: book-demo-enter .22s ease-out;
}

.book-demo-dialog::backdrop {
  background: rgba(4, 19, 49, .58);
  backdrop-filter: blur(5px);
}

.book-demo-intro {
  padding: 32px 34px 20px;
  background: linear-gradient(145deg, #f4f9ff, #fff);
  border-bottom: 1px solid var(--line);
}

.book-demo-intro h2 {
  margin: 8px 48px 8px 0;
  font-size: 30px;
  line-height: 1.1;
}

.book-demo-intro p {
  max-width: 570px;
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.book-demo-close {
  position: absolute;
  z-index: 1;
  top: 18px;
  right: 20px;
  display: grid;
  width: 38px;
  height: 38px;
  padding: 0;
  place-items: center;
  color: #38517c;
  font-size: 25px;
  line-height: 1;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
}

.book-demo-close:hover {
  color: var(--primary);
  border-color: #a8c9f7;
}

.book-demo-form {
  padding: 24px 34px 32px;
}

.book-demo-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.book-demo-fields label {
  display: grid;
  gap: 7px;
  min-width: 0;
  color: var(--ink);
  font-weight: 800;
}

.book-demo-fields label > span {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.book-demo-fields label strong {
  color: #d42d4b;
}

.book-demo-fields label em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
}

.book-demo-fields input,
.book-demo-fields select {
  width: 100%;
  min-width: 0;
  height: 48px;
  padding: 0 14px;
  color: var(--ink);
  font: inherit;
  font-weight: 650;
  border: 1px solid #c9defd;
  border-radius: 10px;
  background: #fafdff;
  outline: none;
}

.book-demo-fields input:focus,
.book-demo-fields select:focus {
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(7, 92, 245, .11);
}

.book-demo-fields [aria-invalid="true"] {
  border-color: #d42d4b;
}

.book-demo-state {
  grid-column: 1 / -1;
}

.field-error {
  min-height: 16px;
  color: #b4233d;
  font-size: 12px;
  font-weight: 700;
}

.book-demo-status {
  min-height: 21px;
  margin: 10px 0 4px;
  color: #b4233d;
  font-size: 14px;
  font-weight: 700;
}

.book-demo-submit {
  width: 100%;
  min-height: 50px;
  border: 0;
  cursor: pointer;
}

.book-demo-submit:disabled {
  opacity: .68;
  cursor: wait;
}

.book-demo-success {
  padding: 42px 34px 36px;
  text-align: center;
}

.book-demo-success-icon {
  display: grid;
  width: 54px;
  height: 54px;
  margin: 0 auto 16px;
  place-items: center;
  color: #087a47;
  font-size: 28px;
  border-radius: 50%;
  background: #dcf8e9;
}

.book-demo-success h3 {
  margin: 0 0 8px;
  font-size: 26px;
}

.book-demo-success p {
  margin: 0 0 24px;
  color: var(--muted);
}

@keyframes book-demo-enter {
  from { opacity: 0; transform: translateY(12px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 620px) {
  .book-demo-dialog {
    width: calc(100vw - 20px);
    max-height: calc(100dvh - 20px);
    border-radius: 16px;
  }

  .book-demo-intro {
    padding: 26px 22px 18px;
  }

  .book-demo-intro h2 {
    font-size: 25px;
  }

  .book-demo-form {
    padding: 20px 22px 24px;
  }

  .book-demo-fields {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .book-demo-state {
    grid-column: auto;
  }
}
@media (prefers-reduced-motion: reduce) {
  .book-demo-dialog[open] {
    animation: none;
  }
}