:root {
  --bg: #090b0c;
  --surface: #111416;
  --surface-2: #171b1e;
  --surface-3: #202529;
  --text: #f5f0e8;
  --muted: #a9a39a;
  --line: rgba(245, 240, 232, 0.14);
  --accent: #8fd7bd;
  --gold: #c6a15b;
  --danger: #d96f66;
  --radius: 8px;
  --shadow: 0 18px 60px rgba(0, 0, 0, 0.32);
}

.morning-brief,
.reliability-card,
.live-session-card {
  display: grid;
  gap: 12px;
}

.morning-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
}

.morning-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  background: var(--surface-2);
}

.morning-card span,
.morning-card small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.morning-card strong {
  display: block;
  margin: 5px 0;
  color: var(--accent);
  font-size: 24px;
  line-height: 1;
}

.decision-strip {
  display: grid;
  gap: 8px;
  margin: 12px 0;
}

.decision-strip div {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px;
  background: rgba(143, 215, 189, 0.06);
}

.decision-strip dt {
  color: var(--gold);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.decision-strip dd {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  line-height: 1.45;
}

.memory-card strong,
.decision-card strong {
  line-height: 1.25;
}

.inline-command {
  display: inline-flex;
}

.detail-actions {
  margin-top: 16px;
}

.project-operating-room .workspace-grid {
  align-items: start;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.018) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: linear-gradient(to bottom, black, transparent 82%);
}

a { color: inherit; text-decoration: none; }

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

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

h1 {
  margin-bottom: 14px;
  font-size: 54px;
  line-height: 0.94;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 12px;
  font-size: 28px;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 18px;
  letter-spacing: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 760;
}

.mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--accent);
  background: #0d1112;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 14px;
  color: var(--text);
  background: var(--surface-2);
  font-weight: 720;
  cursor: pointer;
}

.button.primary {
  color: #08110e;
  border-color: var(--accent);
  background: var(--accent);
}

.eyebrow {
  margin-bottom: 10px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.lede {
  max-width: 680px;
  color: #d9d2c6;
  font-size: 17px;
  line-height: 1.55;
}

.quiet {
  color: var(--muted);
  line-height: 1.5;
}

.public-page {
  display: grid;
  place-items: center;
  min-height: 100vh;
}

.public-shell {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: space-between;
  width: min(980px, calc(100vw - 32px));
  min-height: min(720px, calc(100vh - 32px));
  padding: 18px 0;
}

.public-nav,
.app-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.public-nav { padding-top: 4px; }

.public-hero {
  max-width: 660px;
  padding: 76px 0;
}

.public-hero p:not(.eyebrow) {
  max-width: 520px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.55;
}

.public-shell footer {
  color: var(--muted);
  font-size: 13px;
}

.login-shell {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 20px;
}

.login-panel {
  width: min(420px, 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.login-panel input {
  width: 100%;
  min-height: 46px;
  margin: 12px 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 12px;
  color: var(--text);
  background: var(--bg);
}

.app-top {
  position: sticky;
  top: 0;
  z-index: 3;
  display: grid;
  gap: 12px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(9, 11, 12, 0.9);
  backdrop-filter: blur(14px);
}

.app-top nav {
  display: flex;
  gap: 12px;
  color: var(--muted);
  font-size: 14px;
}

.app-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  min-width: 0;
}

.context-nav {
  padding-top: 2px;
  white-space: nowrap;
}

.app-context {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.76fr);
  gap: 18px;
  align-items: end;
}

.app-context .eyebrow {
  margin-bottom: 4px;
}

.app-context h1 {
  margin-bottom: 4px;
  font-size: 30px;
  line-height: 1;
}

.app-context p:not(.eyebrow) {
  margin-bottom: 0;
  max-width: 620px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.4;
}

.header-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(74px, 1fr));
  gap: 6px;
  margin: 0;
}

.header-stats div {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px 10px;
  background: rgba(23, 27, 30, 0.82);
}

.header-stats dt {
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 720;
}

.header-stats dd {
  margin: 0;
  color: var(--text);
  font-size: 15px;
  font-weight: 800;
  line-height: 1;
}

.command-shell {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100vw - 28px));
  margin: 0 auto;
  padding: 14px 0 86px;
}

.daily-quote {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 12px;
  padding: 16px 18px;
}

.daily-quote blockquote {
  margin: 0 0 8px;
  max-width: 860px;
  color: var(--text);
  font-size: 22px;
  font-weight: 720;
  line-height: 1.25;
}

.daily-quote span:not(.status-pill),
.daily-quote p:not(.eyebrow) {
  display: block;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

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

.cockpit-card {
  display: grid;
  gap: 7px;
  min-height: 116px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  background: rgba(17, 20, 22, 0.94);
  box-shadow: var(--shadow);
}

.cockpit-card.priority {
  border-color: rgba(143, 215, 189, 0.36);
  background: #101b18;
}

.cockpit-card strong {
  font-size: 20px;
  line-height: 1.15;
}

.cockpit-card small {
  align-self: end;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.card-kicker {
  color: var(--gold);
  font-size: 11px;
  font-weight: 820;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(17, 20, 22, 0.94);
  box-shadow: var(--shadow);
}

.status-grid,
.module-launcher,
.mini-grid {
  display: grid;
  gap: 10px;
}

.status-grid {
  grid-template-columns: repeat(4, 1fr);
  margin-top: 22px;
}

.status-grid div,
.module,
.mini-card,
.fit-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-2);
}

.status-grid div {
  padding: 14px;
}

.status-grid strong,
.mini-card strong {
  display: block;
  margin-bottom: 5px;
  font-size: 20px;
}

.status-grid span,
.mini-card span,
.module small {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.module-launcher {
  grid-template-columns: repeat(4, 1fr);
  margin: 14px 0;
}

.module {
  display: grid;
  gap: 7px;
  min-height: 116px;
  padding: 14px;
}

.module span {
  color: var(--gold);
  font-size: 12px;
  font-weight: 800;
}

.module.active {
  border-color: rgba(143, 215, 189, 0.42);
  background: #14201d;
}

.tab-shell {
  margin-top: 12px;
}

body.module-view .daily-quote,
body.module-view .morning-brief,
body.module-view .cockpit-grid {
  display: none;
}

body.module-view .tab-shell {
  margin-top: 0;
}

.tab-list {
  position: sticky;
  top: 137px;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 4px;
  margin-bottom: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 4px;
  background: rgba(9, 11, 12, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.tab-button {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 0;
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 0 10px;
  color: var(--text);
  background: transparent;
  text-align: center;
  cursor: pointer;
}

.tab-button span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.tab-button strong {
  font-size: 13px;
  line-height: 1;
  white-space: nowrap;
}

.tab-button.active {
  border-color: rgba(143, 215, 189, 0.5);
  background: #14201d;
  color: var(--accent);
}

.tab-button.active span {
  color: var(--gold);
}

.tab-button.active::after {
  content: "";
  position: absolute;
  right: 14px;
  bottom: 4px;
  left: 14px;
  height: 2px;
  border-radius: 999px;
  background: var(--accent);
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

.tab-panel[hidden] {
  display: none;
}

.tab-panel,
.workspace {
  scroll-margin-top: 150px;
}

.dashboard-summary {
  margin-top: 14px;
}

.inbox-board,
.action-list,
.activity-list,
.agent-jobs {
  display: grid;
  gap: 10px;
}

.inbox-board {
  margin-top: 12px;
}

.inbox-group {
  display: grid;
  gap: 8px;
}

.inbox-group h3,
.agent-jobs h3 {
  margin-bottom: 0;
}

.action-card,
.activity-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 13px;
  background: var(--surface-2);
}

.action-card h3 {
  margin-bottom: 7px;
  font-size: 16px;
}

.action-card p,
.activity-item p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.45;
}

.action-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 12px;
}

.action-controls {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin-top: 12px;
}

.action-controls button {
  width: 100%;
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  background: #0c0f10;
  cursor: pointer;
}

.approval-preview {
  margin-top: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #0c0f10;
}

.approval-preview summary {
  padding: 9px 11px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.approval-preview pre {
  max-height: 180px;
  overflow: auto;
  margin: 0;
  border-top: 1px solid var(--line);
  padding: 10px 11px;
  color: var(--text);
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
}

.approval-preview span {
  display: block;
  border-top: 1px solid var(--line);
  padding: 8px 11px;
  color: var(--muted);
  font-size: 12px;
}

.activity-panel {
  margin-top: 14px;
}

.activity-item {
  display: grid;
  gap: 5px;
}

.activity-item span {
  color: var(--muted);
  font-size: 12px;
}

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

.workspace,
.agent-card {
  padding: 18px;
}

.mobile-fab {
  display: none;
}

.compact-head {
  align-items: center;
  margin-bottom: 12px;
}

.compact-head h2,
.compact-head h3 {
  margin-bottom: 0;
}

.api-costs {
  border-top: 1px solid var(--line);
  margin-top: 14px;
  padding-top: 14px;
}

.cost-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin: 0 0 8px;
}

.cost-list div {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px;
  background: rgba(23, 27, 30, 0.6);
}

.cost-list dt {
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 750;
}

.cost-list dd {
  margin: 0;
  color: var(--text);
  font-size: 13px;
  font-weight: 820;
}

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

.section-head,
.fit-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border: 1px solid rgba(143, 215, 189, 0.32);
  border-radius: var(--radius);
  padding: 0 8px;
  color: var(--accent);
  background: rgba(143, 215, 189, 0.08);
  font-size: 12px;
  font-weight: 800;
}

.fit-carousel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 12px 0 18px;
}

.fit-card {
  display: grid;
  gap: 12px;
  min-height: 300px;
  padding: 14px;
}

.fit-card p {
  color: var(--muted);
  line-height: 1.45;
}

.garment-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: auto;
}

.garment-strip span {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--gold);
  background: var(--surface-3);
  font-weight: 800;
}

.feedback-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.feedback-row form {
  min-width: 0;
}

.feedback-row button {
  width: 100%;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  background: #0c0f10;
  cursor: pointer;
}

.feedback-row button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

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

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

.form-grid.compact {
  grid-template-columns: 1fr;
}

.form-grid input,
.form-grid select,
.form-grid textarea,
.quick-ask input,
.quick-ask select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  color: var(--text);
  background: #090b0c;
}

.form-grid textarea {
  min-height: 76px;
  resize: vertical;
}

.form-grid textarea,
.form-grid button {
  grid-column: 1 / -1;
}

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

.mini-card {
  padding: 13px;
}

.mini-card p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.supporting-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.supporting-links a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 8px;
  color: var(--accent);
  background: #0c0f10;
  font-size: 12px;
  font-weight: 760;
}

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

.tag-row span {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  min-height: 27px;
  border: 1px solid rgba(143, 215, 189, 0.26);
  border-radius: var(--radius);
  padding: 0 8px;
  color: #d7eee6;
  background: rgba(143, 215, 189, 0.08);
  font-size: 12px;
  font-weight: 760;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.project-title-stack {
  min-width: 0;
}

.project-title-stack h1 {
  overflow-wrap: anywhere;
}

.app-top .project-mobile-nav {
  display: none;
}

.project-overview-card {
  display: grid;
  gap: 13px;
}

.project-overview-top,
.project-state-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.project-overview-top {
  justify-content: space-between;
}

.priority-pill {
  border-color: rgba(198, 161, 91, 0.36);
  color: #f1ddad;
  background: rgba(198, 161, 91, 0.08);
}

.project-next-block .eyebrow {
  margin-bottom: 6px;
}

.project-next-action {
  max-width: 860px;
  margin: 0;
  color: var(--text);
  font-size: 21px;
  font-weight: 780;
  line-height: 1.32;
  overflow-wrap: anywhere;
}

.project-summary-inline {
  max-width: 860px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.project-overview-card .supporting-links {
  margin-top: 0;
}

.project-meta-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 2px 0 0;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}

.project-meta-strip div {
  min-width: 0;
}

.project-meta-strip dt {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.project-meta-strip dd {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  font-weight: 760;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.project-command-panel {
  grid-column: 2;
  grid-row: 1;
}

.project-attention-panel {
  grid-column: 1;
  grid-row: 1;
}

.research-links a {
  max-width: 100%;
}

.link-badge {
  display: inline-grid;
  place-items: center;
  min-width: 32px;
  min-height: 20px;
  border-radius: 4px;
  color: #08110e;
  background: var(--accent);
  font-size: 10px;
  font-weight: 900;
}

.entity-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 5px;
}

.entity-card-head strong {
  min-width: 0;
  margin-bottom: 0;
}

.project-status-form {
  flex: 0 0 auto;
  margin: 0;
}

.project-status-form button {
  min-height: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 10px;
  color: var(--text);
  background: #0c0f10;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.project-status-form button:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.entity-card-actions {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.entity-card-actions .eyebrow {
  margin-bottom: 0;
}

.entity-card-actions span {
  min-width: 0;
}

.button-cluster {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.briefing-status-form,
.briefing-read-form {
  flex: 0 0 auto;
  margin: 0;
}

.briefing-status-form button,
.briefing-read-form button {
  min-height: 30px;
  border: 1px solid rgba(143, 215, 189, 0.32);
  border-radius: var(--radius);
  padding: 0 10px;
  color: var(--accent);
  background: rgba(143, 215, 189, 0.08);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.briefing-read-form button {
  color: var(--text);
  border-color: var(--line);
  background: #0c0f10;
}

.briefing-status-form button:hover,
.briefing-read-form button:hover {
  border-color: var(--accent);
  background: #0c0f10;
}

.entity-card {
  min-height: 104px;
}

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

.research-lane {
  display: grid;
  gap: 10px;
}

.research-unread .unread-briefing {
  border-color: rgba(198, 161, 91, 0.34);
  background: rgba(198, 161, 91, 0.07);
}

.research-history .mini-card:not(.empty-card) {
  min-height: 96px;
}

.people-directory,
.people-due {
  display: grid;
  gap: 10px;
}

.people-directory {
  margin-top: 14px;
}

.person-card strong a {
  color: var(--text);
  overflow-wrap: anywhere;
}

.wardrobe-stats,
.drawer-grid {
  display: grid;
  gap: 10px;
}

.wardrobe-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0 0 14px;
}

.signal-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  background: rgba(23, 27, 30, 0.82);
}

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

.signal-card span {
  color: var(--muted);
  font-size: 12px;
}

.style-profile,
.style-advice {
  margin: 0 0 18px;
}

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

.style-profile-grid .signal-card strong {
  font-size: 15px;
  line-height: 1.28;
}

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

.style-guidance div {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  background: rgba(23, 27, 30, 0.72);
}

.style-guidance dt {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.style-guidance dd {
  margin: 0;
  color: var(--text);
  font-size: 13px;
  line-height: 1.45;
}

.style-advice-grid {
  margin-top: 12px;
}

.style-advice-card p {
  margin: 8px 0 0;
}

.drawer-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0 0 18px;
}

.action-drawer {
  margin-top: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(23, 27, 30, 0.72);
}

.action-drawer.wide-drawer {
  max-width: 520px;
}

.drawer-grid .action-drawer {
  margin-top: 0;
}

.action-drawer summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 54px;
  padding: 0 13px;
  cursor: pointer;
  list-style: none;
}

.action-drawer summary::-webkit-details-marker {
  display: none;
}

.action-drawer summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.action-drawer summary strong {
  margin-left: auto;
  font-size: 14px;
}

.action-drawer summary::after {
  content: "+";
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--accent);
  background: #0c0f10;
  font-weight: 820;
}

.action-drawer[open] summary {
  border-bottom: 1px solid var(--line);
}

.action-drawer[open] summary::after {
  content: "-";
}

.action-drawer form {
  padding: 12px;
}

.archived-projects {
  opacity: 0.86;
}

.archived-grid {
  padding: 12px;
}

.photo-queue {
  margin: 8px 0 22px;
}

.photo-grid,
.dedupe-list {
  display: grid;
  gap: 10px;
}

.photo-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 12px;
}

.photo-card,
.dedupe-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(23, 27, 30, 0.82);
}

.photo-card {
  display: grid;
  min-width: 0;
  overflow: hidden;
}

.photo-thumb,
.compare-pane {
  min-width: 0;
}

.photo-thumb {
  aspect-ratio: 4 / 5;
  border-bottom: 1px solid var(--line);
  background: #0c0f10;
}

.photo-thumb img,
.compare-pane img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photo-body {
  display: grid;
  gap: 6px;
  padding: 12px;
}

.photo-body strong,
.compare-pane strong {
  font-size: 15px;
  line-height: 1.25;
}

.photo-body span,
.compare-pane span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.photo-body p {
  margin-bottom: 0;
  color: var(--danger);
  font-size: 12px;
  line-height: 1.35;
}

.photo-placeholder {
  display: grid;
  place-items: center;
  width: 100%;
  min-height: 180px;
  color: var(--muted);
  background: #0c0f10;
}

.inline-drawer {
  margin-top: 6px;
}

.inline-drawer summary {
  color: var(--accent);
  font-size: 13px;
  font-weight: 760;
  cursor: pointer;
}

.mini-form {
  display: grid;
  gap: 7px;
  margin-top: 8px;
}

.mini-form input,
.mini-form button {
  width: 100%;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 9px;
  color: var(--text);
  background: #090b0c;
}

.mini-form button {
  color: #08110e;
  border-color: var(--accent);
  background: var(--accent);
  font-weight: 800;
  cursor: pointer;
}

.dedupe-list {
  margin-top: 12px;
}

.dedupe-card {
  padding: 12px;
}

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

.compare-pane {
  display: grid;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px;
  background: #0c0f10;
}

.compare-pane img,
.compare-pane .photo-placeholder {
  aspect-ratio: 4 / 5;
  min-height: 0;
  border-radius: calc(var(--radius) - 2px);
}

.dedupe-footer {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.dedupe-footer p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.message {
  border: 1px solid rgba(143, 215, 189, 0.28);
  border-radius: var(--radius);
  padding: 13px;
  color: #ded7cc;
  background: #12201c;
  line-height: 1.5;
}

.quick-ask {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.command-composer {
  margin: 0 0 18px;
}

.command-composer input {
  min-height: 54px;
  font-size: 15px;
}

@media (max-width: 760px) {
  h1 { font-size: 44px; }
  h2 { font-size: 24px; }
  .public-shell { min-height: calc(100vh - 24px); }
  .public-hero { padding: 52px 0; }
  .app-top { gap: 8px; padding: 10px 12px; }
  .app-bar { display: none; }
  .app-context {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .app-heading {
    align-items: flex-start;
    gap: 10px;
  }
  .context-nav {
    padding-top: 3px;
    font-size: 13px;
  }
  .app-context h1 {
    font-size: 24px;
  }
  .app-context p:not(.eyebrow) {
    display: none;
  }
  .header-stats {
    grid-template-columns: repeat(auto-fit, minmax(56px, 1fr));
    gap: 4px;
  }
  .header-stats div {
    padding: 6px 7px;
  }
  .header-stats dt {
    display: block;
    margin-bottom: 2px;
    font-size: 10px;
  }
  .header-stats dd {
    font-size: 13px;
  }
  .project-detail-top .app-heading {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .project-detail-top .app-context h1 {
    font-size: 22px;
    line-height: 1.08;
  }
  .project-detail-top .project-mobile-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
  }
  .project-mobile-nav a {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 0 9px;
    color: var(--text);
    background: rgba(23, 27, 30, 0.88);
    font-size: 12px;
    font-weight: 800;
  }
  .project-detail-stats {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }
  .project-detail-stats::-webkit-scrollbar {
    display: none;
  }
  .project-detail-stats div {
    flex: 0 0 auto;
    min-width: 74px;
  }
  .project-detail .section-head h2 {
    font-size: 20px;
    line-height: 1.15;
  }
  .project-overview-card {
    gap: 12px;
    padding: 14px;
  }
  .project-overview-top {
    align-items: flex-start;
  }
  .project-next-action {
    font-size: 18px;
    line-height: 1.35;
  }
  .project-chip-row {
    gap: 5px;
  }
  .project-meta-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 12px;
  }
  .project-workspace-grid {
    grid-template-columns: 1fr;
  }
  .project-command-panel,
  .project-attention-panel {
    grid-column: auto;
    grid-row: auto;
  }
  .command-shell { width: min(100vw - 20px, 680px); padding-top: 10px; padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
  body:not(.module-view) .morning-brief {
    gap: 8px;
  }
  body:not(.module-view) .morning-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .morning-card {
    padding: 9px;
  }
  .morning-card strong {
    font-size: 19px;
  }
  .daily-quote {
    display: grid;
    gap: 10px;
    padding: 14px;
  }
  .daily-quote blockquote {
    font-size: 18px;
  }
  .status-grid { grid-template-columns: repeat(2, 1fr); }
  .module-launcher,
  .cockpit-grid,
  .workspace-grid,
  .secondary,
  .split,
  .fit-carousel,
  .mini-grid,
  .wardrobe-stats,
  .style-profile-grid,
  .style-guidance,
  .drawer-grid,
  .photo-grid,
  .dedupe-compare {
    grid-template-columns: 1fr;
  }
  .action-controls {
    grid-template-columns: 1fr;
  }
  .tab-list {
    position: fixed;
    inset: auto 0 0;
    top: auto;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 2px;
    margin: 0;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 0;
    padding: 5px max(5px, env(safe-area-inset-right)) max(5px, env(safe-area-inset-bottom)) max(5px, env(safe-area-inset-left));
    overflow: visible;
  }
  .tab-button {
    min-height: 46px;
    padding: 0 3px;
  }
  .tab-button span {
    display: none;
  }
  .tab-button strong {
    font-size: clamp(9px, 2.6vw, 11px);
    line-height: 1.05;
    white-space: normal;
    overflow-wrap: anywhere;
  }
  .tab-button.active::after {
    right: 10px;
    left: 10px;
  }
  .mobile-fab {
    position: fixed;
    right: 12px;
    bottom: calc(62px + env(safe-area-inset-bottom));
    z-index: 4;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    border: 1px solid rgba(143, 215, 189, 0.48);
    border-radius: var(--radius);
    padding: 0 13px;
    color: #08110e;
    background: var(--accent);
    box-shadow: var(--shadow);
    font-size: 13px;
    font-weight: 850;
  }
  .agent-card {
    scroll-margin-top: 12px;
  }
  .module { min-height: 92px; }
  .fit-card { min-height: 260px; }
}

@media (max-width: 360px) {
  .command-shell {
    padding-bottom: calc(120px + env(safe-area-inset-bottom));
  }
  .tab-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .tab-button {
    min-height: 42px;
  }
  .tab-button strong {
    font-size: 10px;
  }
  .mobile-fab {
    bottom: calc(106px + env(safe-area-inset-bottom));
  }
}
