:root {
  color-scheme: light;
  --bg: #eef3f1;
  --surface: #ffffff;
  --surface-2: #f4f7f6;
  --ink: #16231f;
  --muted: #62716b;
  --line: #cfdbd6;
  --line-strong: #9cada4;
  --green: #168a5a;
  --green-soft: #dff3e9;
  --yellow: #b87a13;
  --yellow-soft: #fff0c8;
  --red: #bd3b2f;
  --red-soft: #ffe2dd;
  --blue: #2f6f9f;
  --blue-soft: #dcebf4;
  --black: #101714;
  --shadow: 0 18px 60px rgba(21, 37, 32, 0.1);
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  margin: 0;
}

body {
  background:
    linear-gradient(180deg, rgba(238, 243, 241, 0.86), rgba(238, 243, 241, 0.98)),
    radial-gradient(circle at 12% 10%, rgba(22, 138, 90, 0.11), transparent 34%),
    radial-gradient(circle at 92% 8%, rgba(47, 111, 159, 0.12), transparent 30%);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  line-height: 1.4;
}

button,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  min-height: 100vh;
}

.workspace-grid {
  display: grid;
  grid-template-columns: 280px minmax(560px, 1fr) 340px;
  min-height: 100vh;
}

.landing-hero {
  background: #020813;
  min-height: 100vh;
  overflow: hidden;
  position: relative;
}

.landing-hero img {
  display: block;
  height: 100vh;
  min-height: 720px;
  object-fit: cover;
  object-position: center;
  width: 100%;
}

.landing-hero::after {
  background:
    linear-gradient(90deg, rgba(2, 8, 19, 0.78), rgba(2, 8, 19, 0.3) 48%, rgba(2, 8, 19, 0.04)),
    linear-gradient(180deg, rgba(2, 8, 19, 0.1), rgba(2, 8, 19, 0.8));
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.landing-overlay {
  color: #ffffff;
  left: auto;
  max-width: 760px;
  position: absolute;
  right: clamp(18px, 5vw, 86px);
  top: 50%;
  transform: translateY(-42%);
  z-index: 1;
}

.landing-kicker {
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  margin-bottom: 12px;
  text-transform: uppercase;
}

.landing-overlay h1 {
  font-size: clamp(38px, 5.8vw, 82px);
  line-height: 0.96;
  max-width: 720px;
}

.landing-copy {
  color: rgba(255, 255, 255, 0.78);
  font-size: clamp(16px, 1.7vw, 21px);
  margin-top: 18px;
  max-width: 660px;
}

.hero-proof {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.hero-proof span {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 12px;
  font-weight: 800;
  padding: 7px 10px;
}

.landing-prompt {
  background: rgba(8, 15, 23, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.34);
  margin-top: 28px;
  padding: 14px;
}

.landing-prompt textarea {
  background: rgba(255, 255, 255, 0.94);
  border-color: rgba(255, 255, 255, 0.3);
  font-size: 16px;
  min-height: 128px;
}

.landing-actions {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-top: 12px;
}

.landing-actions span {
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
}

.how-it-works {
  background: #020813;
  color: #ffffff;
  padding: clamp(28px, 5vw, 72px) clamp(14px, 4vw, 48px);
}

.product-section {
  background: #f8fbfa;
  border-top: 1px solid var(--line);
  padding: clamp(34px, 5vw, 78px) clamp(18px, 5vw, 72px);
}

.product-section + .product-section {
  border-top: 0;
  padding-top: 0;
}

.section-copy {
  max-width: 820px;
}

.section-copy h2 {
  font-size: clamp(28px, 4vw, 52px);
  line-height: 1.03;
  max-width: 760px;
}

.section-copy p:not(.eyebrow) {
  color: var(--muted);
  font-size: 17px;
  margin-top: 14px;
  max-width: 760px;
}

.feature-grid,
.pricing-grid,
.privacy-rail {
  display: grid;
  gap: 14px;
  margin-top: 28px;
}

.feature-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.feature-grid article,
.privacy-rail article,
.price-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
}

.feature-grid strong,
.privacy-rail strong {
  display: block;
  font-size: 17px;
  margin-bottom: 8px;
}

.feature-grid p,
.privacy-rail p,
.price-card li {
  color: var(--muted);
  font-size: 14px;
}

.privacy-model {
  background: #eef3f1;
}

.privacy-rail {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.privacy-rail span,
.plan-name {
  color: var(--blue);
  display: block;
  font-size: 12px;
  font-weight: 850;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.pricing-section {
  background: #f8fbfa;
}

.pricing-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.price-card {
  display: flex;
  flex-direction: column;
  min-height: 300px;
}

.price-card.featured {
  background: #111b17;
  border-color: #111b17;
  color: #ffffff;
}

.price-card strong {
  display: block;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1;
  margin-bottom: 8px;
}

.price-card > span {
  color: var(--muted);
  display: block;
  font-weight: 800;
  margin-bottom: 22px;
}

.price-card.featured > span,
.price-card.featured li,
.price-card.featured .plan-name {
  color: rgba(255, 255, 255, 0.74);
}

.price-card ul {
  display: grid;
  gap: 10px;
  margin: auto 0 0;
  padding-left: 18px;
}

.how-it-works-inner {
  margin: 0 auto;
  max-width: 1320px;
}

.how-it-works .eyebrow,
.how-it-works .subtle {
  color: rgba(255, 255, 255, 0.72);
}

.how-it-works h2 {
  font-size: clamp(28px, 4vw, 54px);
  line-height: 1;
  margin-bottom: 12px;
}

.how-it-works .subtle {
  font-size: 16px;
  margin-bottom: 22px;
  max-width: 760px;
}

.how-it-works img {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  box-shadow: 0 24px 90px rgba(0, 0, 0, 0.38);
  display: block;
  height: auto;
  width: 100%;
}

.left-panel,
.right-panel {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(18px);
  min-height: 100vh;
  overflow: auto;
  padding: 18px;
  position: sticky;
  top: 0;
}

.left-panel {
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 0;
}

.right-panel {
  border-left: 1px solid var(--line);
}

.workspace {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 18px;
}

.brand-lockup,
.console-header,
.section-heading,
.header-actions,
.composer-actions,
.stage-node,
.agent-row,
.memory-row,
.check-item {
  align-items: center;
  display: flex;
}

.brand-lockup {
  gap: 12px;
  margin-bottom: 18px;
}

.brand-mark {
  align-items: end;
  background: var(--black);
  border-radius: 8px;
  display: flex;
  height: 42px;
  justify-content: center;
  padding: 7px;
  width: 42px;
}

.brand-mark span {
  background: linear-gradient(180deg, #f7c857, #f36b3c);
  border-radius: 50% 50% 8px 8px;
  display: block;
  height: 26px;
  width: 14px;
}

.eyebrow {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  margin: 0 0 3px;
  text-transform: uppercase;
}

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

h1 {
  font-size: 23px;
}

h2 {
  font-size: 18px;
}

h3 {
  font-size: 14px;
}

.subtle {
  color: var(--muted);
  font-size: 13px;
}

.primary-action,
.secondary-action,
.send-button,
.chip-button {
  border: 1px solid transparent;
  border-radius: 8px;
  min-height: 40px;
  padding: 0 13px;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.primary-action,
.send-button {
  background: var(--black);
  color: #ffffff;
  font-weight: 750;
}

.secondary-action,
.chip-button {
  background: var(--surface);
  border-color: var(--line);
  color: var(--ink);
}

.primary-action:hover,
.secondary-action:hover,
.send-button:hover,
.chip-button:hover {
  border-color: var(--line-strong);
  transform: translateY(-1px);
}

#newProjectButton {
  width: 100%;
}

.panel-block,
.chat-card,
.side-folder {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.panel-block,
.side-folder {
  margin-top: 14px;
  padding: 14px;
}

.panel-block.compact {
  box-shadow: none;
}

.section-heading {
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.section-heading span {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  padding: 4px 8px;
  white-space: nowrap;
}

.project-list,
.file-tree,
.agent-bench,
.stage-detail,
.status-panel,
.memory-panel,
.agent-synthesis {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.project-button {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  display: grid;
  gap: 6px;
  padding: 11px;
  text-align: left;
  width: 100%;
}

.project-button.active {
  background: #17211d;
  border-color: #17211d;
  color: #ffffff;
}

.project-button span,
.agent-card span,
.stage-detail span {
  color: var(--muted);
  font-size: 12px;
}

.project-button.active span {
  color: rgba(255, 255, 255, 0.74);
}

.agent-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
}

.agent-card strong {
  display: block;
  font-size: 13px;
  margin-bottom: 3px;
}

.file-row {
  align-items: center;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: flex;
  gap: 9px;
  min-height: 38px;
  padding: 8px 10px;
}

.file-icon {
  align-items: center;
  background: #e7efeb;
  border-radius: 6px;
  color: var(--muted);
  display: flex;
  flex: 0 0 24px;
  font-size: 12px;
  font-weight: 900;
  height: 24px;
  justify-content: center;
  width: 24px;
}

.file-row strong {
  display: block;
  font-size: 12px;
}

.file-row span {
  color: var(--muted);
  display: block;
  font-size: 11px;
}

.console-header {
  background: rgba(244, 247, 246, 0.84);
  border-bottom: 1px solid var(--line);
  justify-content: space-between;
  gap: 18px;
  padding: 14px 16px;
}

.header-actions {
  flex-wrap: wrap;
  gap: 9px;
  justify-content: flex-end;
}

.chat-card {
  display: grid;
  grid-template-rows: auto minmax(360px, 1fr) auto;
  min-height: calc(100vh - 36px);
  overflow: hidden;
}

.chat-history {
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow: auto;
  padding: 24px 18px;
}

.message {
  display: grid;
  gap: 10px;
  grid-template-columns: 34px minmax(0, 1fr);
}

.message-avatar {
  align-items: center;
  background: var(--blue-soft);
  border: 1px solid rgba(47, 111, 159, 0.18);
  border-radius: 8px;
  color: var(--blue);
  display: flex;
  font-size: 12px;
  font-weight: 850;
  height: 34px;
  justify-content: center;
  width: 34px;
}

.message.user .message-avatar {
  background: var(--black);
  color: #ffffff;
}

.message-meta {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  margin-bottom: 4px;
}

.message-content {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
  padding: 12px;
}

.message.user .message-content {
  background: var(--black);
  border-color: var(--black);
  color: #ffffff;
}

.message-content ul {
  margin: 8px 0 0;
  padding-left: 18px;
}

.message-content li + li {
  margin-top: 4px;
}

.chat-composer {
  background: rgba(244, 247, 246, 0.94);
  border-top: 1px solid var(--line);
  padding: 16px;
}

textarea {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  min-height: 110px;
  outline: none;
  padding: 12px;
  resize: vertical;
  width: 100%;
}

textarea:focus {
  border-color: var(--black);
}

.composer-actions {
  gap: 10px;
  justify-content: space-between;
  margin-top: 10px;
}

.prompt-chips {
  display: flex;
  flex: 1;
  flex-wrap: wrap;
  gap: 8px;
}

.chip-button {
  font-size: 12px;
  min-height: 34px;
}

.send-button {
  min-width: 94px;
}

.lower-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: start;
}

.insight-panel {
  margin-top: 0;
  min-height: 220px;
}

.synthesis-card,
.memory-row,
.deliverable-card,
.gap-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 11px;
}

.synthesis-card strong,
.deliverable-card strong,
.gap-card strong {
  display: block;
  font-size: 13px;
  margin-bottom: 5px;
}

.synthesis-card p,
.deliverable-card p,
.gap-card p {
  color: var(--muted);
  font-size: 13px;
}

.memory-row {
  align-items: flex-start;
  gap: 10px;
}

.artifact-panel,
.ecosystem-panel {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.ecosystem-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 11px;
}

.ecosystem-card strong {
  display: block;
  font-size: 13px;
  margin-bottom: 5px;
}

.ecosystem-card p {
  color: var(--muted);
  font-size: 13px;
}

.memory-row .dot {
  margin-top: 5px;
}

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

.metric-list article {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 62px;
  padding: 10px;
}

.metric-list span {
  color: var(--muted);
  display: block;
  font-size: 11px;
  margin-bottom: 4px;
}

.metric-list strong {
  display: block;
  font-size: 16px;
}

.dashboard-metrics {
  margin-top: auto;
}

.side-folder {
  box-shadow: 0 10px 28px rgba(21, 37, 32, 0.06);
  padding: 0;
}

.side-folder summary {
  align-items: center;
  cursor: pointer;
  display: flex;
  gap: 10px;
  justify-content: space-between;
  list-style: none;
  min-height: 58px;
  padding: 14px;
}

.side-folder summary::-webkit-details-marker {
  display: none;
}

.side-folder summary h2 {
  font-size: 17px;
}

.side-folder summary span {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  padding: 4px 8px;
  white-space: nowrap;
}

.side-folder summary::after {
  color: var(--muted);
  content: "+";
  font-size: 18px;
  font-weight: 850;
}

.side-folder[open] summary::after {
  content: "-";
}

.side-folder > div {
  border-top: 1px solid var(--line);
  padding: 12px 14px 14px;
}

.stage-rail {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.stage-node {
  background: transparent;
  border: 0;
  color: var(--ink);
  gap: 11px;
  min-height: 58px;
  padding: 0;
  position: relative;
  text-align: left;
}

.stage-node::before {
  background: var(--line);
  content: "";
  height: 100%;
  left: 12px;
  position: absolute;
  top: 29px;
  width: 2px;
  z-index: 0;
}

.stage-node:last-child::before {
  display: none;
}

.bead {
  border: 2px solid var(--surface);
  border-radius: 50%;
  box-shadow: 0 0 0 1px var(--line);
  flex: 0 0 26px;
  height: 26px;
  position: relative;
  width: 26px;
  z-index: 1;
}

.bead.completed {
  background: var(--green);
}

.bead.progress {
  background: var(--yellow);
}

.bead.urgent {
  background: var(--red);
}

.bead.open {
  background: #ffffff;
}

.stage-node.active .bead {
  box-shadow: 0 0 0 3px rgba(23, 33, 29, 0.2);
}

.stage-node strong {
  display: block;
  font-size: 13px;
}

.stage-node span {
  color: var(--muted);
  display: block;
  font-size: 12px;
}

.stage-detail h3 {
  font-size: 15px;
  margin-bottom: 5px;
}

.stage-detail p,
.stage-detail li,
.check-item p {
  color: var(--muted);
  font-size: 13px;
}

.stage-detail ul {
  margin: 0;
  padding-left: 18px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  padding: 4px 8px;
}

.status-panel {
  max-height: 420px;
  overflow: auto;
}

.status-update {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
}

.status-update strong {
  display: block;
  font-size: 13px;
  margin-bottom: 4px;
}

.status-update p {
  color: var(--muted);
  font-size: 12px;
}

.status-update + .status-update {
  margin-top: 8px;
}

.check-group {
  border-top: 1px solid var(--line);
  padding-top: 10px;
}

.check-group:first-child {
  border-top: 0;
  padding-top: 0;
}

.check-group h3 {
  margin-bottom: 8px;
}

.check-item {
  align-items: flex-start;
  gap: 8px;
  margin: 8px 0;
}

.box {
  align-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  display: flex;
  flex: 0 0 18px;
  height: 18px;
  justify-content: center;
  margin-top: 1px;
  width: 18px;
}

.box.checked {
  background: var(--green);
  border-color: var(--green);
  color: white;
}

.box.checked::after {
  content: "✓";
  font-size: 12px;
  font-weight: 900;
}

.dot {
  border-radius: 50%;
  flex: 0 0 9px;
  height: 9px;
  width: 9px;
}

.dot.completed {
  background: var(--green);
}

.dot.progress {
  background: var(--yellow);
}

.dot.urgent {
  background: var(--red);
}

.dot.open {
  background: var(--line-strong);
}

.sr-only {
  border: 0;
  clip: rect(0, 0, 0, 0);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

@media (max-width: 1180px) {
  .workspace-grid {
    grid-template-columns: 240px minmax(420px, 1fr);
  }

  .right-panel {
    border-left: 0;
    grid-column: 1 / -1;
    min-height: auto;
    position: static;
  }
}

@media (max-width: 840px) {
  .workspace-grid,
  .lower-grid,
  .right-panel {
    grid-template-columns: 1fr;
  }

  .landing-hero img {
    min-height: 780px;
    object-position: 32% center;
  }

  .landing-overlay {
    left: 18px;
    right: 18px;
    top: 54%;
  }

  .landing-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .feature-grid,
  .pricing-grid,
  .privacy-rail {
    grid-template-columns: 1fr;
  }

  .left-panel,
  .right-panel {
    min-height: auto;
    position: static;
  }

  .console-header,
  .composer-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .send-button {
    width: 100%;
  }
}
