:root {
  --project-green: #5f7f73;
  --project-green-dark: #38594e;
  --project-green-soft: #e8f0ec;
  --project-ink: #26332f;
  --project-muted: #6c7773;
  --project-line: #dde4e0;
  --project-bg: #f3f5f4;
  --project-white: #fff;
  --project-amber: #c58c3a;
  --project-danger: #a85252;
  --project-radius: 18px;
  --project-shadow: 0 14px 38px rgba(42, 60, 53, .08);
}

* { box-sizing: border-box; }
body { background: var(--project-bg); color: var(--project-ink); }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }
.project-shell { max-width: 1480px; padding-bottom: 64px; }
.app-view { animation: view-in .22s ease; }
@keyframes view-in { from { opacity: 0; transform: translateY(5px); } }

.eyebrow {
  margin: 0 0 7px;
  color: var(--project-green);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.dashboard-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin-top: 22px;
  padding: 42px 46px;
  overflow: clip;
  position: relative;
  color: #f7faf8;
  border-radius: 24px;
  background:
    radial-gradient(circle at 83% 18%, rgba(209, 228, 218, .22), transparent 31%),
    linear-gradient(128deg, #2e4b41, #5f7f73);
  box-shadow: var(--project-shadow);
}
.dashboard-hero::after {
  content: "";
  position: absolute;
  right: -68px;
  bottom: -110px;
  width: 310px;
  height: 310px;
  border: 46px solid rgba(255,255,255,.055);
  border-radius: 50%;
}
.dashboard-hero > * { position: relative; z-index: 1; }
.dashboard-hero .eyebrow { color: #cfe1d8; }
.dashboard-hero h1 { max-width: 760px; margin: 0; color: #f7faf8; font-size: clamp(2rem, 4vw, 3.55rem); line-height: 1.03; letter-spacing: -.045em; }
.hero-copy { max-width: 680px; margin: 18px 0 0; color: rgba(247,250,248,.76); font-size: 1.04rem; line-height: 1.65; }

.primary-button, .secondary-button, .quiet-button, .danger-button, .danger-link, .back-button, .icon-button {
  border: 0;
  border-radius: 11px;
  font-weight: 750;
  transition: transform .14s ease, background .14s ease, border-color .14s ease, box-shadow .14s ease;
}
.primary-button { padding: 11px 17px; color: white; background: var(--project-green); box-shadow: 0 6px 16px rgba(63, 94, 82, .18); }
.primary-button:hover { background: var(--project-green-dark); transform: translateY(-1px); }
.secondary-button { padding: 10px 16px; color: var(--project-green-dark); border: 1px solid #cdd9d3; background: white; }
.secondary-button:hover { border-color: #a9beb4; background: #f8fbf9; }
.quiet-button { padding: 8px 11px; color: var(--project-green-dark); background: var(--project-green-soft); }
.quiet-button:hover { background: #dce9e3; }
.danger-button { padding: 10px 15px; color: white; background: var(--project-danger); }
.danger-link { padding: 7px 0; color: var(--project-danger); background: transparent; }
.back-button { width: 42px; height: 42px; color: var(--project-green-dark); border: 1px solid var(--project-line); background: white; font-size: 1.25rem; }
.icon-button { width: 38px; height: 38px; color: var(--project-muted); background: #f1f4f2; font-size: 1.35rem; }
.hero-action { padding: 14px 21px; white-space: nowrap; color: var(--project-green-dark); background: white; box-shadow: 0 10px 28px rgba(26, 48, 40, .2); }
.hero-action:hover { color: white; }

.metric-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 18px 0 30px; }
.metric-card { display: flex; align-items: center; gap: 15px; padding: 19px 21px; border: 1px solid var(--project-line); border-radius: 16px; background: white; }
.metric-card strong { display: block; font-size: 1.65rem; line-height: 1; }
.metric-card span:last-child { display: block; margin-top: 7px; color: var(--project-muted); font-size: .82rem; }
.metric-icon { display: grid; place-items: center; width: 45px; height: 45px; border-radius: 13px; font-size: 1.05rem; }
.metric-icon--leaf { color: #4f7767; background: #e5f0eb; }
.metric-icon--ink { color: #5d6680; background: #ebedf4; }
.metric-icon--amber { color: #9a6d2e; background: #f7eedc; }

.project-library, .brief-card, .design-card { padding: 26px; border: 1px solid var(--project-line); border-radius: var(--project-radius); background: white; box-shadow: 0 8px 24px rgba(55, 71, 65, .035); }
.section-heading, .card-heading, .workspace-heading, .goal-heading, .sample-toolbar, .attachment-upload, .modal-header, .modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}
.section-heading h2, .card-heading h2 { margin: 0; font-size: 1.35rem; letter-spacing: -.02em; }
.search-field { display: flex; align-items: center; gap: 9px; min-width: 260px; padding: 9px 12px; border: 1px solid var(--project-line); border-radius: 11px; background: #fafcfb; }
.search-field svg { width: 18px; fill: none; stroke: #7d8984; stroke-width: 1.8; }
.search-field input { width: 100%; border: 0; outline: 0; background: transparent; }
.status-filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0; }
.filter-chip { padding: 8px 13px; color: var(--project-muted); border: 1px solid var(--project-line); border-radius: 999px; background: white; font-size: .82rem; font-weight: 700; }
.filter-chip span { display: inline-grid; place-items: center; min-width: 22px; margin-left: 5px; padding: 2px 6px; border-radius: 999px; background: #edf1ef; font-size: .7rem; }
.filter-chip.is-active { color: var(--project-green-dark); border-color: #aebfb7; background: var(--project-green-soft); }

.project-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.project-card {
  position: relative;
  display: flex;
  min-height: 276px;
  padding: 21px 21px 18px;
  overflow: hidden;
  color: var(--project-ink);
  text-align: left;
  border: 1px solid #dce5e0;
  border-radius: 18px;
  background: linear-gradient(145deg, color-mix(in srgb, var(--card-color, var(--project-green)) 7%, white), white 52%);
  box-shadow: 0 5px 16px rgba(43, 64, 55, .035);
  flex-direction: column;
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.project-card:hover { transform: translateY(-4px); border-color: color-mix(in srgb, var(--card-color, var(--project-green)) 45%, #dce5e0); box-shadow: 0 18px 38px rgba(52, 73, 65, .11); }
.project-card::after { content: ""; position: absolute; top: -62px; right: -52px; width: 140px; height: 140px; border: 23px solid color-mix(in srgb, var(--card-color, var(--project-green)) 7%, transparent); border-radius: 50%; pointer-events: none; }
.project-card-top { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.project-card-top .status-pill { gap: 6px; }
.project-status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--card-color, currentColor); box-shadow: 0 0 0 3px color-mix(in srgb, var(--card-color, currentColor) 12%, transparent); }
.project-card-body { position: relative; z-index: 1; flex: 1; padding: 22px 0 18px; }
.project-card h3 { margin: 0 0 8px; font-size: 1.25rem; line-height: 1.25; letter-spacing: -.025em; }
.project-card p { display: -webkit-box; min-height: 42px; margin: 0; overflow: hidden; color: var(--project-muted); font-size: .82rem; line-height: 1.55; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.project-card-stats { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; padding: 11px; border: 1px solid #e5ebe8; border-radius: 12px; background: rgba(248, 250, 249, .88); }
.project-card-stats div { min-width: 0; padding: 0 8px; border-right: 1px solid #e2e8e5; }
.project-card-stats div:first-child { padding-left: 2px; }
.project-card-stats div:last-child { padding-right: 2px; border-right: 0; }
.project-card-stats strong { display: block; color: var(--project-ink); font-size: 1.04rem; line-height: 1.1; }
.project-card-stats span { display: block; margin-top: 4px; color: var(--project-muted); font-size: .66rem; white-space: nowrap; }
.project-open { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; width: 100%; margin-top: 13px; color: var(--project-green-dark); font-size: .74rem; font-weight: 800; }
.project-open span:last-child { font-size: 1rem; transition: transform .16s ease; }
.project-card:hover .project-open span:last-child { transform: translateX(3px); }
.status-pill, .small-status { display: inline-flex; align-items: center; width: max-content; border-radius: 999px; text-transform: capitalize; }
.status-pill { padding: 5px 9px; font-size: .7rem; font-weight: 800; }
.status-pill--draft { color: #6f667a; background: #eeeaf2; }
.status-pill--active { color: #346552; background: #e3f0ea; }
.status-pill--completed { color: #4b637c; background: #e5edf4; }
.status-pill--archived { color: #717775; background: #eceeed; }
.updated-text { color: #8a9490; font-size: .7rem; }
.library-empty { grid-column: 1 / -1; padding: 64px 20px; text-align: center; color: var(--project-muted); border: 1px dashed #cad5d0; border-radius: 15px; background: #fafcfb; }
.library-empty h3 { margin: 8px 0; color: var(--project-ink); }

.workspace-heading { margin: 24px 0 16px; }
.workspace-title { flex: 1; }
.workspace-title h1 { margin: 0; font-size: 1.75rem; letter-spacing: -.03em; }
.workspace-title p:last-child { margin: 5px 0 0; color: var(--project-muted); font-size: .8rem; }
.workspace-heading-actions { display: flex; align-items: center; gap: 15px; }
.brief-card { margin-bottom: 18px; }
.card-heading { margin-bottom: 22px; }
.brief-form, .form-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 17px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field > span, .panel-label, .template-control label > span { color: #56625e; font-size: .76rem; font-weight: 800; letter-spacing: .015em; }
.field input:not([type=color]), .field textarea, .field select, .template-control select, .bulk-repeats input {
  width: 100%;
  padding: 10px 11px;
  color: var(--project-ink);
  border: 1px solid #d4ddd9;
  border-radius: 10px;
  outline: none;
  background: #fbfcfc;
  transition: border-color .14s ease, box-shadow .14s ease;
}
.field input:focus, .field textarea:focus, .field select:focus, .template-control select:focus { border-color: #7fa293; box-shadow: 0 0 0 3px rgba(95,127,115,.12); }
.field textarea { resize: vertical; line-height: 1.55; }
.field input[type=color] { width: 100%; height: 42px; padding: 4px; border: 1px solid #d4ddd9; border-radius: 10px; background: #fbfcfc; }
.field--span-2 { grid-column: span 2; }

.project-capture-grid { display: grid; grid-template-columns: minmax(350px, .78fr) minmax(580px, 1.22fr); align-items: start; gap: 18px; margin-bottom: 18px; }
.project-capture-grid .thought-card, .project-capture-grid .unclassified-card { margin-bottom: 0; }
.thought-card { display: flex; flex-direction: column; overflow: hidden; border: 1px solid #dfe6e2; border-radius: 16px; background: white; box-shadow: 0 7px 22px rgba(55, 71, 65, .04); }
.thought-heading { display: flex; align-items: flex-start; padding: 17px 18px; border-bottom: 1px solid #e5e8df; background: linear-gradient(145deg, #fbf5e5, #f7faf8 78%); }
.thought-heading-copy { display: flex; align-items: flex-start; gap: 13px; }
.thought-mark { display: grid; flex: 0 0 auto; place-items: center; width: 39px; height: 39px; color: #725b25; border: 1px solid rgba(157, 119, 38, .12); border-radius: 12px; background: rgba(247, 229, 179, .7); font-size: .66rem; font-weight: 900; letter-spacing: .035em; }
.thought-heading .eyebrow { margin-bottom: 2px; font-size: .61rem; }
.thought-title-line { display: flex; align-items: center; gap: 8px; }
.thought-title-line h2 { margin: 0; font-size: 1.05rem; letter-spacing: -.015em; }
.panel-count { display: inline-grid; place-items: center; min-width: 24px; height: 20px; padding: 0 7px; color: var(--project-green-dark); border-radius: 999px; background: var(--project-green-soft); font-size: .68rem; font-weight: 850; }
.thought-heading-copy p:last-child { margin: 5px 0 0; color: var(--project-muted); font-size: .7rem; line-height: 1.45; }
.thought-quick-form { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; gap: 8px; padding: 12px 14px 10px; border-bottom: 1px solid #edf0ee; background: white; }
.thought-quick-form label { min-width: 0; }
.thought-quick-form select, .thought-quick-form input { width: 100%; height: 39px; padding: 8px 11px; color: var(--project-ink); border: 1px solid #d4ddd9; border-radius: 10px; outline: none; background: #fbfcfc; }
.thought-quick-form select:focus, .thought-quick-form input:focus { border-color: #7fa293; box-shadow: 0 0 0 3px rgba(95,127,115,.12); }
.thought-quick-form .primary-button { min-width: 62px; padding: 8px 14px; box-shadow: none; }
.thought-list { max-height: 334px; padding: 0 14px; overflow: auto; overscroll-behavior: contain; }
.thought-item { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 11px; min-height: 61px; padding: 8px 0; border-bottom: 1px solid #edf0ee; }
.thought-item:last-child { border-bottom: 0; }
.thought-kind { min-width: 66px; padding: 5px 8px; text-align: center; border-radius: 999px; font-size: .63rem; font-weight: 850; letter-spacing: .06em; text-transform: uppercase; }
.thought-kind--idea { color: #735b24; background: #f7edcf; }
.thought-kind--question { color: #4b6278; background: #e8eff5; }
.thought-copy { min-width: 0; }
.thought-copy strong, .thought-copy p { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.thought-copy strong { font-size: .82rem; }
.thought-copy p { margin: 4px 0 0; color: var(--project-muted); font-size: .7rem; }
.thought-copy p.is-empty { color: #98a19d; font-style: italic; }
.thought-empty { display: flex; align-items: baseline; gap: 7px; padding: 13px 2px 15px; color: var(--project-muted); font-size: .7rem; }
.thought-empty strong { color: #57635e; font-size: .73rem; }

.design-card { padding: 0; overflow: hidden; }
.design-heading { padding: 24px 26px; margin: 0; border-bottom: 1px solid var(--project-line); }
.design-layout { display: grid; grid-template-columns: 300px 1fr; min-height: 460px; }
.goal-panel { padding: 20px 16px; border-right: 1px solid var(--project-line); background: #f8faf9; }
.panel-label { padding: 0 8px 10px; text-transform: uppercase; letter-spacing: .1em; }
.goal-list { display: grid; gap: 7px; }
.goal-item { width: 100%; padding: 13px; text-align: left; border: 1px solid transparent; border-radius: 12px; background: transparent; }
.goal-item:hover { background: white; }
.goal-item.is-active { border-color: #c7d7cf; background: white; box-shadow: 0 6px 16px rgba(53, 78, 68, .06); }
.goal-item strong { display: block; color: var(--project-ink); font-size: .87rem; line-height: 1.35; }
.goal-item span { display: block; margin-top: 7px; color: var(--project-muted); font-size: .7rem; }
.experiment-panel { padding: 26px; }
.empty-state { display: grid; justify-items: center; align-content: center; min-height: 390px; text-align: center; }
.empty-state .empty-icon { display: grid; place-items: center; width: 58px; height: 58px; color: var(--project-green); border-radius: 18px; background: var(--project-green-soft); font-size: 1.45rem; }
.empty-state h3 { margin: 18px 0 5px; }
.empty-state p { max-width: 380px; margin: 0 0 18px; color: var(--project-muted); }
.goal-heading { align-items: flex-start; padding-bottom: 20px; border-bottom: 1px solid var(--project-line); }
.goal-heading h3 { margin: 7px 0 6px; font-size: 1.25rem; }
.goal-heading p { max-width: 720px; margin: 0; color: var(--project-muted); line-height: 1.5; }
.goal-actions { display: flex; gap: 9px; }
.small-status { padding: 4px 7px; color: var(--project-green-dark); background: var(--project-green-soft); font-size: .66rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.experiment-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; margin-top: 18px; }
.experiment-card { padding: 17px; text-align: left; border: 1px solid var(--project-line); border-radius: 14px; background: #fbfcfb; transition: border-color .14s ease, transform .14s ease; }
.experiment-card:hover { transform: translateY(-2px); border-color: #aebfb7; }
.experiment-card-top { display: flex; justify-content: space-between; gap: 10px; }
.experiment-card h4 { margin: 13px 0 6px; font-size: .96rem; }
.experiment-card p { min-height: 40px; margin: 0; color: var(--project-muted); font-size: .78rem; line-height: 1.5; }
.experiment-card-meta { display: flex; gap: 12px; margin-top: 14px; color: #71807a; font-size: .7rem; font-weight: 700; }
.experiment-task-dots { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; min-height: 18px; margin-top: 13px; }
.task-dot { display: inline-block; width: 9px; height: 9px; border: 1px solid rgba(38, 51, 47, .1); border-radius: 50%; box-shadow: 0 0 0 2px white; }
.task-dot--draft { background: #aab2af; }
.task-dot--planned { background: #d8a53f; }
.task-dot--completed { background: #4f9478; }
.no-task-label { color: var(--project-muted); font-size: .66rem; font-weight: 750; }

dialog.modal {
  width: min(680px, calc(100vw - 28px));
  max-height: calc(100vh - 34px);
  padding: 0;
  overflow: hidden;
  color: var(--project-ink);
  border: 0;
  border-radius: 19px;
  background: white;
  box-shadow: 0 30px 90px rgba(20, 35, 29, .3);
}
dialog.modal::backdrop { background: rgba(26, 40, 35, .5); backdrop-filter: blur(3px); }
dialog.modal[open] { animation: modal-in .18s ease; }
@keyframes modal-in { from { opacity: 0; transform: translateY(8px) scale(.985); } }
.modal-header { padding: 21px 23px; border-bottom: 1px solid var(--project-line); }
.modal-header h2 { margin: 0; font-size: 1.25rem; }
.modal-body { padding: 22px 23px; overflow: auto; }
.modal-body.form-grid { grid-template-columns: repeat(2, 1fr); }
.modal-footer { padding: 15px 23px; border-top: 1px solid var(--project-line); background: #fafbfB; }
.modal-actions { display: flex; gap: 8px; margin-left: auto; }
.footer-spacer { flex: 1; }
dialog.experiment-modal { width: min(1180px, calc(100vw - 28px)); height: min(850px, calc(100vh - 28px)); }
.experiment-modal form { display: grid; grid-template-rows: auto auto 1fr auto; height: 100%; }
.experiment-modal-header { padding-bottom: 17px; }
.experiment-tabs { display: flex; gap: 5px; padding: 10px 22px; border-bottom: 1px solid var(--project-line); background: #fafcfb; }
.experiment-tabs button { padding: 8px 12px; color: var(--project-muted); border: 0; border-radius: 9px; background: transparent; font-size: .79rem; font-weight: 800; }
.experiment-tabs button.is-active { color: var(--project-green-dark); background: var(--project-green-soft); }
.experiment-tabs button:disabled { opacity: .4; cursor: not-allowed; }
.experiment-modal-body { min-height: 0; padding: 24px; }
.experiment-tab-panel > .form-grid { grid-template-columns: repeat(2, 1fr); }
.inline-note { margin: 20px 0 0; padding: 11px 13px; color: #6d735e; border-radius: 10px; background: #f6f3e7; font-size: .78rem; }

.sample-toolbar { align-items: flex-end; padding-bottom: 16px; border-bottom: 1px solid var(--project-line); }
.template-control { display: flex; align-items: flex-end; gap: 9px; }
.template-control label { display: flex; flex-direction: column; gap: 7px; }
.template-control select { min-width: 250px; }
.sample-actions { display: flex; gap: 8px; }
.bulk-repeats { display: flex; align-items: center; flex-wrap: wrap; gap: 11px; margin: 14px 0; padding: 10px 12px; border-radius: 10px; background: #f4f7f5; font-size: .76rem; }
.bulk-repeats > span { font-weight: 800; }
.bulk-repeats label { display: flex; align-items: center; gap: 6px; color: var(--project-muted); }
.bulk-repeats input { width: 65px; padding: 7px; background: white; }
.sample-table-wrap { overflow: auto; border: 1px solid var(--project-line); border-radius: 12px; }
.sample-table { width: 100%; min-width: 980px; border-collapse: collapse; font-size: .76rem; }
.sample-table th { padding: 10px 9px; color: #5e6b66; text-align: left; white-space: nowrap; background: #f4f7f5; }
.sample-table td { padding: 8px; border-top: 1px solid #e6ebe8; }
.sample-table input { width: 100%; min-width: 100px; padding: 8px; border: 1px solid #d5ded9; border-radius: 8px; background: white; }
.sample-table input[type=number] { min-width: 72px; }
.sample-id-pattern { min-width: 150px; color: var(--project-green-dark); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .7rem; white-space: nowrap; }
.row-actions { display: flex; gap: 4px; }
.row-actions button { width: 30px; height: 30px; color: var(--project-muted); border: 0; border-radius: 7px; background: #edf2ef; }
.row-actions button:last-child { color: var(--project-danger); }
.sample-summary { display: flex; align-items: center; justify-content: flex-end; gap: 24px; margin-top: 15px; }
.sample-summary div { display: flex; flex-direction: column; }
.sample-summary span { color: var(--project-muted); font-size: .7rem; }
.sample-summary strong { font-size: 1.2rem; }

.attachment-upload { padding: 18px; border: 1px dashed #b9cbc2; border-radius: 14px; background: #f8fbf9; }
.attachment-upload h3, .planner-intro h3, .send-history h3 { margin: 0 0 5px; font-size: 1rem; }
.attachment-upload p, .planner-intro p { margin: 0; color: var(--project-muted); font-size: .78rem; line-height: 1.5; }
.file-button input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.attachment-list { display: grid; gap: 9px; margin-top: 15px; }
.attachment-item { display: grid; grid-template-columns: 42px 1fr auto; align-items: center; gap: 12px; padding: 11px 13px; border: 1px solid var(--project-line); border-radius: 11px; }
.file-icon { display: grid; place-items: center; width: 42px; height: 42px; color: var(--project-green-dark); border-radius: 10px; background: var(--project-green-soft); font-size: .7rem; font-weight: 900; text-transform: uppercase; }
.attachment-item strong { display: block; font-size: .82rem; }
.attachment-item span { color: var(--project-muted); font-size: .68rem; }
.attachment-actions { display: flex; gap: 6px; }
.attachment-actions a, .attachment-actions button { padding: 7px 9px; color: var(--project-green-dark); border: 0; border-radius: 8px; background: #edf3f0; text-decoration: none; font-size: .7rem; font-weight: 800; }
.attachment-actions button { color: var(--project-danger); }

.planner-layout { max-width: 800px; margin: 0 auto; }
.planner-intro { display: flex; gap: 14px; padding: 18px; border-radius: 14px; background: var(--project-green-soft); }
.planner-mark { display: grid; flex: 0 0 auto; place-items: center; width: 40px; height: 40px; color: white; border-radius: 12px; background: var(--project-green); }
.planner-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 18px 0 26px; padding: 18px; border: 1px solid var(--project-line); border-radius: 14px; }
.planner-send { grid-column: 1 / -1; justify-self: end; }
.send-history { padding-top: 20px; border-top: 1px solid var(--project-line); }
#send-history-list { display: grid; gap: 8px; margin-top: 11px; }
.send-history-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border: 1px solid var(--project-line); border-radius: 10px; font-size: .76rem; }
.send-history-item span { color: var(--project-muted); }

.unclassified-card { margin-bottom: 18px; padding: 0; overflow: hidden; border: 1px solid #dfe6e2; border-radius: 15px; background: #fff; box-shadow: 0 5px 18px rgba(55, 71, 65, .03); }
.inbox-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 15px 17px; border-bottom: 1px solid #e6ebe8; background: #fbfcfb; }
.inbox-heading-copy { display: flex; align-items: center; gap: 12px; min-width: 0; }
.inbox-mark, .planner-task-mark { display: grid; flex: 0 0 auto; place-items: center; color: #66532b; border-radius: 9px; background: #f5ecd5; font-weight: 900; }
.inbox-mark { width: 36px; height: 36px; font-size: .76rem; }
.inbox-heading .eyebrow { margin-bottom: 2px; font-size: .61rem; }
.inbox-title-line { display: flex; align-items: center; gap: 8px; }
.inbox-title-line h2 { margin: 0; font-size: 1rem; letter-spacing: -.015em; }
.inbox-heading-copy p:last-child { margin: 2px 0 0; color: var(--project-muted); font-size: .7rem; }
.inbox-toggle, .inbox-more { color: var(--project-green-dark); border: 0; border-radius: 9px; background: var(--project-green-soft); font-size: .72rem; font-weight: 800; }
.inbox-toggle { padding: 8px 11px; white-space: nowrap; }
.inbox-toggle:hover, .inbox-more:hover { background: #dce9e3; }
.unclassified-list { display: grid; gap: 0; padding: 0 17px; }
.unclassified-list.is-expanded { max-height: 460px; overflow: auto; overscroll-behavior: contain; }
.unclassified-item { display: grid; grid-template-columns: 30px minmax(0, 1fr) minmax(135px, 185px) minmax(155px, 210px) auto; align-items: center; gap: 9px; min-height: 61px; padding: 9px 0; border-bottom: 1px solid #edf0ee; }
.project-capture-grid .unclassified-item { grid-template-columns: 30px minmax(105px, 1fr) minmax(105px, 145px) minmax(120px, 165px) auto; }
.planner-task-mark { width: 30px; height: 30px; font-size: .65rem; }
.unclassified-task-copy { min-width: 0; }
.unclassified-task-title { display: flex; align-items: center; gap: 7px; min-width: 0; }
.unclassified-task-title strong { overflow: hidden; font-size: .79rem; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.unclassified-task-title .status-pill { flex: 0 0 auto; padding: 3px 6px; font-size: .58rem; }
.unclassified-item p { margin: 3px 0 0; color: var(--project-muted); font-size: .65rem; }
.assign-goal-field { display: block; }
.assign-goal-field select { width: 100%; padding: 7px 9px; color: var(--project-ink); border: 1px solid #d8e0dc; border-radius: 8px; background: white; font-size: .72rem; }
.unclassified-item .quiet-button { padding: 7px 10px; font-size: .7rem; }
.inbox-more { justify-self: center; margin: 10px 0 12px; padding: 7px 11px; }
.inbox-empty { display: flex; align-items: center; gap: 8px; min-height: 54px; color: var(--project-muted); font-size: .72rem; }
.inbox-empty strong { color: var(--project-ink); }
.task-section-heading, .task-editor-heading, .task-editor-actions { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.task-section-heading { margin-bottom: 15px; }
.task-section-heading h3, .task-editor-heading h3 { margin: 0 0 4px; }
.task-section-heading p { margin: 0; color: var(--project-muted); font-size: .75rem; }
.experiment-task-list { display: grid; gap: 8px; }
.experiment-task-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 12px; width: 100%; padding: 11px 13px; color: var(--project-ink); text-align: left; border: 1px solid var(--project-line); border-radius: 11px; background: #fbfcfb; }
.experiment-task-row:hover { border-color: #b7c8c0; background: white; }
.experiment-task-copy { min-width: 0; }
.experiment-task-copy strong, .experiment-task-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.experiment-task-copy strong { font-size: .8rem; }
.experiment-task-copy small { margin-top: 3px; color: var(--project-muted); font-size: .66rem; }
.task-row-status { color: var(--project-muted); font-size: .67rem; font-weight: 800; }
.experiment-task-editor { margin-top: 18px; padding: 18px; border: 1px solid #d8e2dd; border-radius: 14px; background: #f8faf9; }
.task-editor-heading { margin-bottom: 14px; }
.task-editor-heading .eyebrow { margin-bottom: 3px; }
.task-editor-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.task-editor-actions { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--project-line); }
.task-attachment-list { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin-top: 12px; }
.task-attachment-list strong { margin-right: 3px; font-size: .72rem; }
.task-attachment-list a { padding: 6px 8px; color: var(--project-green-dark); border-radius: 8px; background: var(--project-green-soft); text-decoration: none; font-size: .66rem; font-weight: 750; }
.compact-empty { padding: 28px 16px; }
.goal-list-item { display: grid; grid-template-columns: auto 1fr; gap: 10px; width: 100%; padding: 13px; text-align: left; border: 1px solid transparent; border-radius: 12px; background: transparent; }
.goal-list-item:hover, .goal-list-item.is-active { border-color: #c7d7cf; background: white; }
.goal-list-item strong, .goal-list-item small { display: block; }
.goal-list-item small { margin-top: 5px; color: var(--project-muted); font-size: .68rem; }
.goal-status-dot { width: 9px; height: 9px; margin-top: 4px; border-radius: 50%; background: #9eaaa4; }
.goal-status-dot--in_progress { background: var(--project-green); }
.goal-status-dot--completed { background: #b9863d; }
.work-item-badges { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.source-pill { padding: 4px 7px; border-radius: 999px; font-size: .62rem; font-weight: 850; letter-spacing: .025em; text-transform: uppercase; }
.source-pill--project { color: #315f51; background: #e4f0eb; }
.source-pill--planner { color: #66532b; background: #f5ecd5; }
.experiment-card-footer { display: flex; justify-content: space-between; gap: 10px; margin-top: 14px; color: var(--project-muted); font-size: .68rem; font-weight: 750; }
.dialog-status-area { display: flex; align-items: center; gap: 12px; }
.design-callout { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 18px; border: 1px solid #d4e3dc; border-radius: 14px; background: #f3f8f5; }
.design-callout p { margin: 5px 0 0; color: var(--project-muted); font-size: .78rem; }
.planner-goal-control { max-width: 420px; margin-bottom: 16px; }
.group-design-heading, .attribute-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 12px; }
.group-design-heading h3, .attribute-heading h3 { margin: 0 0 4px; }
.group-design-heading p, .attribute-heading p { margin: 0; color: var(--project-muted); font-size: .75rem; }
.attribute-heading { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--project-line); }
.design-group-list, .attribute-list { display: grid; gap: 9px; }
.design-group-row, .attribute-row { display: grid; grid-template-columns: minmax(220px, 1.5fr) minmax(150px, .75fr) auto; align-items: end; gap: 10px; padding: 12px; border: 1px solid var(--project-line); border-radius: 12px; background: #fafcfb; }
.attribute-row { grid-template-columns: minmax(180px, 1fr) minmax(140px, .65fr) minmax(220px, 1.2fr) auto; }
.bulk-attribute-bar { display: grid; grid-template-columns: 1fr 1fr 1.4fr auto; align-items: end; gap: 10px; margin: 18px 0 12px; padding: 12px; border-radius: 12px; background: #f3f7f5; }
.bulk-attribute-bar label { display: flex; flex-direction: column; gap: 5px; color: var(--project-muted); font-size: .7rem; font-weight: 800; }
.bulk-attribute-bar select, .bulk-attribute-bar input, .sample-table select { width: 100%; padding: 8px; border: 1px solid #d5ded9; border-radius: 8px; background: white; }
.generated-sample-wrap .sample-table { min-width: 760px; }
.planner-existing { max-width: 800px; margin: 0 auto; }
.planner-send-button { display: block; margin-left: auto; }
.toast--error { background: #873f3f; }

.toast-region { position: fixed; right: 22px; bottom: 22px; z-index: 1000; display: grid; gap: 9px; }
.toast { min-width: 260px; max-width: 420px; padding: 12px 15px; color: white; border-radius: 11px; background: #334c43; box-shadow: 0 12px 28px rgba(25,45,37,.22); font-size: .8rem; animation: toast-in .2s ease; }
.toast.is-error { background: #873f3f; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

@media (max-width: 1080px) {
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .design-layout { grid-template-columns: 250px 1fr; }
  .brief-form { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  .project-capture-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .project-shell { padding-inline: 12px; }
  .dashboard-hero { align-items: flex-start; flex-direction: column; padding: 30px 24px; }
  .metric-grid, .project-grid, .experiment-grid { grid-template-columns: 1fr; }
  .section-heading, .workspace-heading, .goal-heading, .sample-toolbar, .attachment-upload { align-items: stretch; flex-direction: column; }
  .search-field { min-width: 0; }
  .workspace-heading { display: grid; grid-template-columns: auto 1fr; }
  .workspace-heading-actions { grid-column: 1 / -1; justify-content: space-between; }
  .brief-form, .modal-body.form-grid, .experiment-tab-panel > .form-grid, .planner-fields { grid-template-columns: 1fr; }
  .field--span-2 { grid-column: span 1; }
  .thought-heading { padding: 16px 17px; }
  .thought-quick-form { grid-template-columns: 1fr auto; }
  .thought-quick-form label:first-child { grid-column: 1 / -1; }
  .thought-heading-copy p:last-child { max-width: none; }
  .thought-item { grid-template-columns: auto minmax(0, 1fr); }
  .thought-item .quiet-button { grid-column: 2; justify-self: start; }
  .thought-empty { align-items: flex-start; flex-direction: column; gap: 2px; }
  .design-layout { grid-template-columns: 1fr; }
  .goal-panel { border-right: 0; border-bottom: 1px solid var(--project-line); }
  .goal-list { display: flex; overflow-x: auto; }
  .goal-item { min-width: 210px; }
  .goal-actions { justify-content: flex-start; }
  .experiment-tabs { overflow-x: auto; }
  .experiment-tabs button { white-space: nowrap; }
  .template-control { align-items: stretch; flex-direction: column; }
  .template-control select { min-width: 0; }
  .sample-actions { flex-wrap: wrap; }
  .sample-summary { align-items: stretch; flex-wrap: wrap; justify-content: flex-start; }
  .planner-send { grid-column: auto; justify-self: stretch; }
  .unclassified-item { grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; }
  .unclassified-task-copy { grid-column: 2 / -1; }
  .unclassified-item .assign-goal-field { grid-column: 2 / -1; }
  .unclassified-item .quiet-button { grid-column: 3; }
  .inbox-heading { align-items: flex-start; }
  .inbox-heading-copy p:last-child { display: none; }
  .task-section-heading, .task-editor-actions { align-items: stretch; flex-direction: column; }
  .task-editor-grid { grid-template-columns: 1fr; }
  .task-editor-grid .field--span-2 { grid-column: auto; }
  .design-group-row, .attribute-row, .bulk-attribute-bar { grid-template-columns: 1fr; align-items: stretch; }
  .group-design-heading, .attribute-heading { align-items: stretch; flex-direction: column; }
}
