@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600&display=swap");

* {
  box-sizing: border-box;
}

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

body {
  font-family: "Poppins", sans-serif;
  color: var(--ink-900);
  background: linear-gradient(180deg, #fbf7f1 0%, #f6f0e7 100%);
}

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

.acopes-os-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: 64px 1fr;
}

.os-header {
  height: 64px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  position: sticky;
  top: 0;
  z-index: 25;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 220px;
}

.icon-btn {
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius-sm);
  padding: 0 8px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
}

.icon-btn span {
  width: 100%;
  height: 2px;
  border-radius: 4px;
  background: var(--ink-700);
}

.os-logo {
  border: none;
  background: transparent;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}

.logo-mark {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: linear-gradient(140deg, var(--blue), #0B2F33);
  color: #fff;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-text {
  font-weight: 700;
  letter-spacing: 0.04em;
}

kbd {
  border: 1px solid var(--line);
  background: var(--surface-soft);
  border-radius: 6px;
  font-size: 11px;
  padding: 1px 6px;
  color: var(--ink-500);
}

.header-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-btn,
.connection-status,
.icon-circle,
.secondary-btn,
.secondary,
.copy-btn {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-700);
  border-radius: 10px;
  height: 36px;
  padding: 0 12px;
  cursor: pointer;
}

#commandPaletteTrigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.header-btn-icon {
  display: none;
  flex-shrink: 0;
}

.ai-credit-indicator {
  min-width: 82px;
  height: 42px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-content: center;
  column-gap: 8px;
  padding: 4px 10px;
  border: 1px solid var(--ac-warm-border);
  border-radius: 10px;
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

.ai-credit-indicator span { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.ai-credit-indicator strong { grid-row: 1 / 3; grid-column: 2; align-self: center; font-size: 20px; line-height: 1; }
.ai-credit-indicator small { font-size: 9px; color: var(--ink-500); }
.ai-credit-indicator.loading strong { opacity: .45; }
.connection-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.connection-status.connected {
  color: var(--green);
  border-color: #a6e2c0;
  background: var(--green-soft);
}

.connection-status.not-connected {
  color: #8a5b12;
  border-color: #f3d8ae;
  background: #fff9f1;
}

.connection-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.icon-circle {
  width: 36px;
  padding: 0;
}

.profile-pill {
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  background: linear-gradient(140deg, #007C78, #0B2F33);
}

.os-main-grid {
  display: grid;
  grid-template-columns: 220px 1fr;
  min-height: calc(100vh - 64px);
}

.os-sidebar {
  border-right: 1px solid var(--line);
  background: var(--surface);
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sidebar-item {
  border: 1px solid transparent;
  background: transparent;
  border-radius: 10px;
  height: 40px;
  padding: 0 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  color: var(--ink-700);
  cursor: pointer;
}

.sidebar-item:hover {
  background: var(--surface-soft);
  border-color: var(--line);
}

.sidebar-item.active {
  background: var(--ac-warm-bg);
  border-color: var(--ac-warm-border);
  color: var(--ac-warm-text);
}

.sidebar-icon {
  width: 18px;
  text-align: center;
}

.workspace-grid {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr) minmax(240px, 300px);
}

.research-rail,
.center-canvas,
.ai-brain {
  padding: 12px;
  overflow-y: auto;
}

.research-rail {
  border-right: none;
  background: linear-gradient(180deg, #fbf7f1 0%, #f6f0e7 100%);
  display: none;
}

body.research-mode .research-rail {
  display: block;
}

body.research-mode .workspace-grid {
  grid-template-columns: 200px minmax(0, 1fr) minmax(240px, 300px);
}

/* B2: the left rail is real only for the actual research flow; every other
   inner page removes it and lets the center column reclaim its width. */
body.no-activity-rail .research-rail {
  display: none;
}

body.no-activity-rail .workspace-grid {
  grid-template-columns: minmax(0, 1fr) minmax(240px, 300px);
}

/* UX Sprint 5: fixed 330px right column drifted from ~70/30 as the
   viewport grew wider (76/24 at 1440px, ~82/18 at 1920px) - fr-based
   split with a floor keeps it near 70/30 across desktop widths while
   still protecting the rail from collapsing on narrower screens. */
body.home-mode .workspace-grid {
  grid-template-columns: minmax(0, 7fr) minmax(300px, 3fr);
}

body.home-mode #approvedFactoryOutputs,
body.home-mode #approvedBoardQuery,
body.home-mode #productOpportunityDashboard:empty {
  display: none;
}

body.research-mode .marketing-section,
body.research-mode .marketing-footer {
  display: none;
}

body.home-mode .center-canvas {
  border-left: 1px solid transparent;
}

body.home-mode .research-rail {
  display: none;
}

/* UX Sprint 5: on Home this rail only ever holds the seller-journey and
   credit-summary cards (renderWorkflowContext's "overview" branch), never
   the AI Brain notes the "AI Brain" heading describes elsewhere - hiding
   it here stops Dashboard's own right column from being mislabeled. */
body.home-mode .ai-brain .brain-head {
  display: none;
}

.center-canvas {
  background: linear-gradient(180deg, #fdfefe 0%, #fffdf9 100%);
}

.ai-brain {
  border-left: none;
  background: linear-gradient(180deg, var(--ac-surface) 0%, var(--ac-loading-highlight) 100%);
}

.rail-header,
.brain-head,
.workspace-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.workspace-top h1,
.rail-header h2,
.brain-head h2 {
  margin: 0;
  font-size: 17px;
}

.thinking-pill,
.pill {
  border: 1px solid var(--ac-warm-border);
  border-radius: 999px;
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
  font-size: 11px;
  font-weight: 600;
  padding: 4px 8px;
}

/* Previously unstyled (rendered as bare inline text, no pill shape at
   all) - default state uses the same neutral warm palette as .pill
   above; .safe (a real confirmation/reassurance state - "Draft-only",
   "Seller approval required") is the one place this gets the app's
   real status green (--ac-success/--ac-success-soft), never the brown
   action/accent color, so status and action never visually collide. */
.mini-status-pill {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--ac-warm-border);
  border-radius: 999px;
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  line-height: 1.4;
}

.mini-status-pill.safe {
  border-color: rgba(36, 122, 75, 0.25);
  background: var(--ac-success-soft);
  color: var(--ac-success);
}

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

.workflow-strip {
  margin: 0 0 12px;
}

.workflow-strip-toggle {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-500);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 6px 10px;
  border-radius: 999px;
  cursor: pointer;
}

.workflow-strip-toggle:hover {
  color: var(--ink-700);
}

.workflow-strip-body {
  display: none;
  margin-top: 8px;
}

.workflow-strip.expanded .workflow-strip-body {
  display: block;
}

.workflow-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

body[data-workspace="overview"] .workflow-strip {
  display: none;
}

.workflow-steps li button {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 12px;
  padding: 8px;
  text-align: left;
  color: var(--ink-700);
  white-space: normal;
  overflow-wrap: anywhere;
}

.workflow-steps li.active button {
  background: var(--ac-warm-bg);
  border-color: var(--ac-warm-border);
  color: var(--ac-warm-text);
}

.workflow-steps li.completed button {
  background: var(--green-soft);
  border-color: #ade5c7;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.home-hero {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(170deg, #ffffff 0%, #fffdf9 100%);
  box-shadow: var(--shadow);
  min-height: 360px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 24px;
  margin-bottom: 14px;
}

.hero-eyebrow {
  margin: 0;
  font-size: 12px;
  color: var(--ink-500);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.home-hero h2 {
  margin: 10px 0 16px;
  font-size: clamp(28px, 4vw, 44px);
  max-width: 760px;
  line-height: 1.08;
}

.hero-copy {
  margin: 0 0 16px;
  max-width: 760px;
  color: var(--ink-700);
  font-size: 15px;
  line-height: 1.5;
}

.hero-prompt-form {
  width: min(820px, 100%);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
}

.hero-cta-row {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.hero-cta-row .secondary-btn {
  height: 46px;
  border-radius: 12px;
}

.hero-workflow-strip {
  margin-top: 16px;
  width: min(880px, 100%);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 6px;
}

.workflow-step-pill {
  border: 1px solid #dcc7b3;
  border-radius: 999px;
  background: #fffdf9;
  color: #8a4f21;
  font-size: 11px;
  font-weight: 600;
  padding: 6px 8px;
}

.workflow-step-pill.active {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
  box-shadow: 0 0 0 1px rgba(122, 75, 22, 0.1);
}

.hero-live-panels {
  margin-top: 14px;
  width: min(880px, 100%);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.live-signal-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  text-align: left;
  padding: 10px;
  min-height: 96px;
}

.live-signal-card h2 {
  margin: 6px 0;
  font-size: 16px;
}

.live-signal-card p {
  margin: 0;
  color: var(--ink-600);
  font-size: 12px;
}

.marketing-section {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: #fff;
  box-shadow: var(--shadow);
  padding: 14px;
  margin-bottom: 12px;
}

.section-headline {
  margin-bottom: 10px;
}

.section-headline h3 {
  margin: 0;
  font-size: clamp(22px, 3vw, 30px);
  line-height: 1.15;
}

.feature-grid,
.tool-grid,
.story-grid,
.pricing-grid {
  display: grid;
  gap: 9px;
}

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

.feature-grid article,
.story-grid article,
.tool-grid article {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fdfefe;
  padding: 10px;
}

.feature-grid article h4,
.story-grid article h4 {
  margin: 0 0 6px;
  font-size: 15px;
}

.feature-grid article p,
.story-grid article p {
  margin: 0;
  color: var(--ink-600);
  font-size: 12px;
  line-height: 1.5;
}

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

.tool-grid article {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-700);
  background: linear-gradient(160deg, #ffffff 0%, #f7faff 100%);
}

.pipeline-stage-list {
  display: flex;
  flex-direction: column;
  gap: 22px;
  margin-top: 6px;
}

.pipeline-stage {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: #fdfefe;
  box-shadow: var(--shadow);
  padding: 18px;
}

.pipeline-stage h4 {
  margin: 0 0 6px;
  font-size: 16px;
}

.pipeline-stage > p {
  margin: 0 0 14px;
  color: var(--ink-500);
  font-size: 13px;
  line-height: 1.5;
  max-width: 640px;
}

.pipeline-shot {
  margin: 0;
}

.pipeline-shot img {
  display: block;
  width: 100%;
  max-width: 640px;
  height: auto;
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #ffffff;
}

.pipeline-shot figcaption {
  max-width: 640px;
  margin: 8px auto 0;
  font-size: 12px;
  color: var(--ink-500);
  line-height: 1.5;
}

.studio-section .studio-flow {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
}

.studio-section .studio-flow span {
  border: 1px solid #cfdcf5;
  border-radius: 999px;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: #1d549e;
  background: #fffdf9;
  padding: 9px;
}

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

.pricing-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  padding: 12px;
  display: grid;
  gap: 8px;
}

.pricing-card.recommended {
  border-color: #d7b77d;
  background: linear-gradient(170deg, #fffdf9 0%, #fffdf9 100%);
  box-shadow: 0 12px 24px rgba(27, 73, 151, 0.12);
}

.plan-badge {
  margin: 0;
  width: fit-content;
  border: 1px solid #adc5f5;
  border-radius: 999px;
  background: #e9f1ff;
  color: #215db6;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
}

.pricing-card h4 {
  margin: 0;
  font-size: 17px;
}

.price-tag {
  margin: 0;
  font-size: 30px;
  font-weight: 700;
  color: #1c4f9f;
}

.price-tag span {
  font-size: 12px;
  color: var(--ink-500);
  margin-left: 4px;
}

.pricing-card p {
  margin: 0;
  color: var(--ink-600);
  font-size: 12px;
  line-height: 1.5;
}

.about-copy {
  margin: 0;
  color: var(--ink-700);
  font-size: 14px;
  line-height: 1.6;
}

.marketing-footer {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: #fff;
  box-shadow: var(--shadow);
  padding: 14px;
  margin-bottom: 12px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
}

.marketing-footer h4 {
  margin: 0 0 6px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-500);
}

.marketing-footer a {
  display: block;
  color: var(--ink-700);
  text-decoration: none;
  margin: 0 0 6px;
  font-size: 12px;
}

.marketing-footer a:hover {
  color: #1d5bc0;
}

.hero-prompt-form input {
  height: 54px;
  border-radius: 14px;
  border: 1px solid #cfd9ea;
  padding: 0 14px;
  font-size: 16px;
  background: #fff;
  outline: none;
}

.hero-prompt-form button,
.primary-btn,
button[data-product-action],
button[type="submit"] {
  height: 54px;
  border: none;
  border-radius: 14px;
  padding: 0 18px;
  color: #fff;
  background: linear-gradient(140deg, var(--blue), #0B2F33);
  font-weight: 600;
  cursor: pointer;
}

.home-modules {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}

.module-block,
.live-canvas-shell,
.pipeline-shell,
.production-board,
.launch-checklist-shell,
.ai-note-card,
.card,
.notebook-card,
.v3-modal-card,
.live-activity-panel,
.brain-notes {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.module-block,
.live-canvas-shell,
.pipeline-shell,
.production-board,
.launch-checklist-shell,
.ai-note-card,
.card,
.brain-notes,
.live-activity-panel {
  padding: 12px;
}

.module-head {
  margin-bottom: 8px;
}

.module-head h3 {
  margin: 0;
  font-size: 15px;
}

.module-content,
.quick-action-row,
.template-grid,
.research-canvas-grid,
.live-canvas-grid,
.pipeline-row,
.pipeline-flow,
.module-progress-grid,
.launch-check-grid,
.store-grid,
.draft-list,
.tray-items,
.brain-notes,
.live-task-feed,
.tag-row,
.metric-pill-row,
.button-row,
.factory-output-grid,
.factory-asset-grid,
.factory-video-grid,
.provider-status-grid,
.provider-stage-list,
.opportunity-list,
.product-action-bar,
.v3-waiting-steps,
.verdict-grid,
.executive-card-grid,
.recommendation-grid,
.competitor-card-grid {
  display: grid;
  gap: 8px;
}

.activity-timeline {
  display: grid;
  gap: 7px;
}

.workspace-state-panel {
  margin-top: 8px;
}

.workspace-state-card {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: linear-gradient(160deg, #ffffff 0%, #f6f9ff 100%);
  padding: 10px;
  display: grid;
  gap: 6px;
  position: relative;
  overflow: hidden;
}

.workspace-state-card strong {
  font-size: 12px;
  color: var(--ink-800);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.workspace-state-card p {
  margin: 0;
  color: var(--ink-600);
  font-size: 12px;
}

.workspace-state-card .state-illustration {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: radial-gradient(circle at 35% 35%, #a9c7ff 0%, #5f93f8 55%, #2f66cc 100%);
  box-shadow: 0 8px 18px rgba(47, 102, 204, 0.16);
}

.workspace-state-card.completed .state-illustration {
  background: radial-gradient(circle at 35% 35%, #b0eacb 0%, #3ca86e 55%, #1f8351 100%);
}

.timeline-item {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  padding: 8px;
  display: grid;
  grid-template-columns: 18px 1fr auto;
  align-items: center;
  gap: 8px;
  animation: fadeInUp 0.25s ease;
}

details.timeline-item {
  padding: 0;
  display: block;
}

.timeline-item summary {
  list-style: none;
  cursor: pointer;
  padding: 8px;
  display: grid;
  grid-template-columns: 18px 1fr auto;
  align-items: center;
  gap: 8px;
}

.timeline-item summary::-webkit-details-marker {
  display: none;
}

.timeline-item p {
  margin: 0;
  border-top: 1px dashed #d9e2ef;
  color: var(--ink-600);
  font-size: 11px;
  padding: 7px 8px 8px 34px;
}

.timeline-item strong {
  font-size: 12px;
  color: var(--ink-700);
}

.timeline-item small {
  font-size: 11px;
  color: var(--ink-500);
}

.timeline-item em {
  font-style: normal;
  font-size: 11px;
  color: var(--ink-500);
}

.timeline-item .timeline-icon {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: #625b53;
  background: #efe3d3;
}

.timeline-item.active {
  border-color: #dcc7b3;
  background: #fffdf9;
}

.timeline-item.active .timeline-icon {
  color: #8a4f21;
  background: #efe3d3;
  animation: pulse 1.4s infinite;
}

.timeline-item.done {
  border-color: #b7e5cc;
  background: #f0fbf5;
}

.timeline-item.done .timeline-icon {
  color: #12824b;
  background: #daf5e7;
}

.brain-stream {
  display: grid;
  gap: 8px;
}

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

.brain-section-list {
  display: grid;
  gap: 8px;
}

.brain-section-item {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  padding: 8px;
  display: grid;
  gap: 4px;
  animation: fadeInUp 0.24s ease;
}

.brain-section-item small {
  font-size: 11px;
  color: var(--ink-500);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.brain-section-item strong {
  font-size: 12px;
  color: var(--ink-700);
}

/* UX Sprint 4: Home's right-rail cards (homeJourneyPanelHtml/
   homeCreditSummaryHtml) - same card language as .brain-section-item
   above, just larger since these are the only two cards in the rail. */
.home-rail-card {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  margin-bottom: 12px;
}

.home-rail-card-title {
  margin: 0;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ink-500);
}

.home-journey-steps {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.home-journey-step {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--ink-500);
}

.home-journey-step-num {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  flex: none;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  font-size: 11px;
  font-weight: 700;
  color: var(--ink-500);
}

.home-journey-step.is-active { color: var(--ink-900); font-weight: 650; }
.home-journey-step.is-active .home-journey-step-num { border-color: var(--ac-primary, var(--blue)); background: var(--ac-primary, var(--blue)); color: #fff; }
.home-journey-step.is-done .home-journey-step-num { border-color: var(--ac-success, #247a4b); background: var(--ac-success-soft, #eaf6ee); color: var(--ac-success, #247a4b); }

.home-journey-cta { justify-self: start; margin-top: 2px; }

.home-rail-credit-value { font-size: 22px; color: var(--ink-900); }

/* UX Sprint 5: credit summary's plan/history/estimate detail lines - plain
   list, smaller than the headline credit value above it. */
.home-credit-detail-list { display: grid; gap: 4px; margin: 2px 0 0; padding: 0; list-style: none; }
.home-credit-detail-list li { color: var(--ink-500); font-size: 12px; line-height: 1.4; }

/* UX Sprint 4: Home's "Araçların" preview section - reuses Product
   Factory's own .factory-entry-card-grid/.factory-entry-card styling
   (Sprint 2), just placed inline on Home instead of on the Üret page. */
.home-tools-tabs { margin-bottom: 12px; }

/* UX Sprint 5: "İlk ürün/kredi kartı" - separate card directly under the
   hero, same factory-entry-card visual language as the Araçların grid
   below it but its own section/grid id so the two don't share state. */
.home-quickstart-section { padding: 18px; border: 1px solid var(--line); border-radius: 18px; background: #fff; }
.home-quickstart-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; }
.home-quickstart-credit-note { color: var(--ink-500); font-size: 12px; }
.home-quickstart-card button[disabled] { opacity: .55; cursor: not-allowed; }

/* UX Sprint 5: hero card's secondary "see all studios" action sits beside
   the primary CTA instead of stacking under it. */
.home-hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.home-hero-secondary-cta { border: 1px solid var(--line); background: #fff; color: var(--ink-700); }

.brain-live-log {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  padding: 8px;
  display: grid;
  gap: 6px;
  max-height: 230px;
  overflow-y: auto;
}

.brain-notes-drawer {
  margin-top: 8px;
}

.brain-notes-drawer summary {
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
  color: var(--ink-500);
  padding: 4px 0;
  list-style: none;
}

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

.brain-notes-drawer summary::before {
  content: "▸ ";
}

.brain-notes-drawer[open] summary::before {
  content: "▾ ";
}

.brain-notes-drawer .brain-live-log {
  margin-top: 6px;
}

.brain-log-item {
  border: 1px solid #e3e9f2;
  border-radius: 8px;
  padding: 7px;
  background: #fbfdff;
  display: grid;
  gap: 4px;
  animation: fadeInUp 0.2s ease;
}

.brain-log-item small {
  color: var(--ink-500);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.brain-log-item strong {
  font-size: 12px;
  color: var(--ink-700);
}

.live-section {
  transition: border-color 0.24s ease, background 0.24s ease, transform 0.24s ease;
}

.live-section.live-ready {
  border-color: #dcc7b3;
  background: #fffdf9;
  transform: translateY(-1px);
}

.live-canvas-grid {
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  align-items: start;
}

.live-canvas-flow {
  display: grid;
  gap: 10px;
}

.live-flow-section {
  border: 1px solid rgba(198, 214, 239, 0.5);
  border-radius: 12px;
  background: linear-gradient(180deg, #ffffff 0%, #fbf7f1 100%);
  padding: 10px;
  box-shadow: 0 10px 24px rgba(24, 51, 92, 0.08);
  display: grid;
  gap: 8px;
}

#livePinnedStrip {
  position: sticky;
  top: 74px;
  z-index: 3;
}

.section-headline.compact {
  margin: 0;
}

.section-headline.compact h3 {
  margin: 0;
  font-size: 14px;
}

.market-scan-provenance {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #e6f4ea;
  color: #1e7a34;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  vertical-align: middle;
}

.market-scan-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 6px 0;
}

.market-scan-metrics span {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.market-scan-metrics small {
  color: #66748f;
  font-size: 11px;
}

.market-scan-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.market-scan-tag {
  padding: 2px 8px;
  border-radius: 999px;
  background: #f0f3fa;
  font-size: 11px;
}

.market-scan-error {
  color: #b3261e;
}

.coloring-book-output .factory-pipeline-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
}

.coloring-book-output .factory-pipeline-steps article {
  flex: 1 1 160px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #f0f3fa;
  font-size: 12px;
}

.coloring-book-output .factory-pipeline-steps article span {
  text-transform: uppercase;
  font-size: 10px;
  color: #66748f;
}

.coloring-book-output .factory-pipeline-steps article.completed { background: #e8f6ec; }
.coloring-book-output .factory-pipeline-steps article.retry_required { background: #fbe9e7; }
.coloring-book-output .factory-pipeline-steps article.locked,
.coloring-book-output .factory-pipeline-steps article.skipped { background: #f0f0f0; color: #66748f; }

.coloring-page-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.coloring-page-thumb {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-decoration: none;
  color: inherit;
}

.coloring-page-thumb img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid #e2e6ef;
}

.coloring-page-thumb span,
.coloring-page-thumb small {
  font-size: 10px;
  color: #66748f;
}

.coloring-page-thumb.failed {
  padding: 8px;
  border-radius: 6px;
  background: #fbe9e7;
}

.coloring-page-thumb.failed small {
  color: #b3261e;
}

.factory-trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.factory-trust-row span {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f3f7ff;
  color: #355a97;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 8px;
}

.factory-generate-form {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}

/* B3: quota-cost caption under the research and product-factory inputs -
   so a seller can tell, before submitting, which box spends what. */
.input-quota-note {
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 700;
  color: var(--ac-text-secondary, #6b6156);
  text-transform: none;
}

.factory-generate-form input {
  flex: 1 1 auto;
  min-width: 0;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 10px;
}

.factory-generate-form select {
  flex: 0 0 auto;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 8px;
  background: #fff;
}

/* Physical Product Studio's form has far more fields (photos, material,
   color, installation, shipping, Etsy setup) than the other product
   types' single "type a niche" row, so it deliberately does NOT reuse
   .factory-generate-form's flex-row layout (which was squeezing every
   field into one cramped horizontal strip). Each field gets its own
   full-width row instead. */
.physical-product-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 720px;
}

/* UX Sprint 4: shared 2-panel studio layout (studioTwoPanelHtml in app.js)
   - Pattern Studio's structural pattern (fixed-width form on the left,
   large live preview/result area on the right). Collapses to a single
   column below the same breakpoint the rest of this app's workspace grids
   already use. */
.studio-two-panel {
  display: grid;
  grid-template-columns: minmax(320px, 400px) minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}
.studio-form-panel .physical-product-form { max-width: none; }
.studio-form-panel .factory-generate-form { max-width: none; flex-direction: column; align-items: stretch; }
.studio-preview-panel {
  min-height: 320px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-soft);
  padding: 16px;
}
.studio-preview-output { min-height: 288px; display: flex; flex-direction: column; }
.studio-preview-placeholder {
  margin: auto;
  max-width: 32ch;
  text-align: center;
  color: var(--ink-500);
  font-size: 13px;
}
@media (max-width: 900px) {
  .studio-two-panel { grid-template-columns: minmax(0, 1fr); }
}

.physical-product-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ac-text-secondary, #6b6156);
}

.physical-product-form input,
.physical-product-form textarea {
  font: inherit;
  font-weight: 400;
  color: var(--ac-text, #1f1a15);
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 12px;
  width: 100%;
  box-sizing: border-box;
}

.physical-product-form textarea {
  height: auto;
  min-height: 64px;
  padding: 8px 12px;
  resize: vertical;
}

.physical-product-form input[type="file"] {
  height: auto;
  padding: 8px 0;
  border: none;
}

.physical-photo-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.physical-photo-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.physical-photo-field-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--ac-text-secondary, #6b6156);
}

.file-drop-zone {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 28px 16px;
  border: 2px dashed var(--ac-border-strong, var(--line));
  border-radius: 14px;
  background: var(--ac-surface-muted);
  text-align: center;
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}

.file-drop-zone:hover,
.file-drop-zone:focus-within {
  border-color: var(--ac-primary, #3D210E);
}

.file-drop-zone.file-drop-zone-active {
  border-color: var(--ac-primary, #3D210E);
  background: var(--ac-loading-highlight, #efe4d3);
}

.file-drop-zone-icon {
  font-size: 22px;
  color: var(--ac-primary, #3D210E);
}

.file-drop-zone-text {
  font-size: 13px;
  font-weight: 600;
  color: var(--ac-text-secondary, #6b6156);
}

.physical-product-form .file-drop-zone-input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.seo-expert-input-panels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 20px;
  margin: 12px 0 16px;
  align-items: start;
}

.seo-expert-input-panel {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
  display: grid;
  gap: 10px;
}

.seo-expert-input-panel h4 {
  margin: 0;
}

.seo-expert-input-panel textarea,
.seo-expert-input-panel input[type="text"],
.seo-expert-input-panel select {
  width: 100%;
  box-sizing: border-box;
}

.seo-expert-input-panel textarea {
  font: inherit;
  resize: vertical;
  white-space: pre-wrap;
  overflow-wrap: break-word;
}

/* Title/tags start short but grow with content (see autoGrowTextarea in
   app.js) - a max-height keeps a runaway paste from pushing the rest of
   the card off-screen; past that, the field's own scrollbar takes over
   while the resize handle above still lets a seller drag it taller. */
.seo-expert-title-field,
.seo-expert-tags-field,
.seo-expert-idea-field {
  max-height: 200px;
  overflow-y: auto;
}

.seo-expert-description-field {
  max-height: 480px;
  overflow-y: auto;
}

.seo-expert-rewrite-compare {
  display: grid;
  gap: 16px;
}

.seo-expert-idea-draft {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

.bulk-seo-select-row {
  display: block;
  padding: 6px 0;
}

.store-summary-delta {
  display: block;
  margin-top: 4px;
  font-weight: 700;
}

.store-summary-reassurance {
  margin-top: 12px;
  max-width: 60ch;
}

.physical-review-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.physical-review-gallery img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  object-fit: cover;
}

.physical-photo-chip {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--ac-surface-muted);
  border: 1px solid var(--line);
  font-size: 12px;
}

.physical-product-shipping-setup {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.physical-product-shipping-setup legend {
  font-size: 13px;
  font-weight: 700;
  padding: 0 6px;
}

.physical-shipping-fields {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.physical-taxonomy-results {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 220px;
  overflow-y: auto;
}

.taxonomy-result-btn {
  text-align: left;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  font-size: 12px;
  cursor: pointer;
}

.taxonomy-result-btn:hover {
  background: var(--ac-surface-muted);
}

.product-search-form {
  flex-wrap: wrap;
}

.product-search-form input,
.product-search-form select {
  flex: 1 1 auto;
  min-width: 0;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 10px;
}

.product-search-notes {
  display: block;
  width: 100%;
  height: 38px;
  box-sizing: border-box;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 10px;
  margin-bottom: 8px;
}

.product-search-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.command-response {
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.command-response:empty {
  display: none;
}

.competitor-table {
  width: 100%;
  border-collapse: collapse;
  display: block;
  overflow-x: auto;
}

.competitor-table td {
  padding: 6px 8px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.gallery-section .live-masonry {
  grid-column: span 1;
}

.live-research-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  margin: 0 0 10px;
}

.live-research-form input {
  height: 46px;
  border: 1px solid #dcc7b3;
  border-radius: 11px;
  padding: 0 12px;
  background: #fff;
}

.live-research-form button {
  height: 46px;
  border: none;
  border-radius: 11px;
  padding: 0 14px;
  background: linear-gradient(140deg, var(--blue), #0B2F33);
  color: #fff;
  font-weight: 600;
}

.live-masonry {
  grid-column: span 1;
}

.live-insights-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
}

.market-snapshot-grid {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.live-insights-strip span {
  border: 1px solid #dcc7b3;
  border-radius: 10px;
  background: #fffdf9;
  padding: 7px;
  display: grid;
  gap: 2px;
}

.live-insights-strip strong {
  font-size: 11px;
  color: #234f96;
}

.live-insights-strip small {
  font-size: 10px;
  color: #58759d;
}

.live-visual-masonry {
  column-count: 5;
  column-gap: 16px;
  animation: fadeInUp 0.28s ease;
}

.live-ref-card {
  border: 1px solid #d6e0ef;
  border-radius: 11px;
  background: #fff;
  overflow: hidden;
  display: inline-grid;
  width: 100%;
  margin: 0 0 16px;
  gap: 6px;
  break-inside: avoid;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease, opacity 0.22s ease;
  position: relative;
}

.live-ref-card:hover {
  transform: translateY(-4px) scale(1.012);
  border-color: #b7ccf8;
  box-shadow: 0 18px 36px rgba(34, 84, 168, 0.2);
}

.live-ref-card.selected {
  border-color: #6fa2f8;
  box-shadow: 0 0 0 2px rgba(63, 129, 245, 0.2), 0 16px 28px rgba(34, 84, 168, 0.18);
  transform: translateY(-2px);
}

.live-ref-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(14, 34, 68, 0.02);
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.live-ref-card:hover::after {
  opacity: 1;
}

.live-ref-card.pinned {
  border-color: #89aef5;
}

.live-ref-card.compared {
  outline: 2px solid #dcc7b3;
  outline-offset: -2px;
}

.live-ref-card.favorited {
  box-shadow: 0 0 0 2px rgba(39, 104, 216, 0.12);
}

.live-ref-media {
  height: var(--media-height, 240px);
  overflow: hidden;
  background: linear-gradient(145deg, #ecf2ff 0%, #dce9ff 100%);
}

.live-ref-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1);
  transition: transform 0.3s ease;
}

.live-ref-card:hover .live-ref-media img {
  transform: scale(1.06);
}

.live-ref-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: #25539b;
  font-weight: 700;
  font-size: 20px;
}

.live-ref-meta {
  display: grid;
  gap: 4px;
  padding: 0 8px;
}

.live-badge {
  margin: 0;
  width: fit-content;
  border: 1px solid #d0dbef;
  border-radius: 999px;
  background: #f7faff;
  color: #345a8d;
  padding: 2px 7px;
  font-size: 10px;
  font-weight: 600;
}

.live-ref-meta strong {
  font-size: 16px;
  color: var(--ink-700);
  line-height: 1.25;
}

.live-ref-meta small {
  font-size: 11px;
  color: var(--ink-500);
}

.direction-kpi-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(64px, 1fr));
  gap: 6px;
}

.kpi-chip {
  border: 1px solid #d6e3f6;
  border-radius: 10px;
  background: #f7fbff;
  padding: 6px;
  display: grid;
  gap: 2px;
  min-width: 0;
}

.kpi-chip small {
  font-size: 9px;
  color: #5a759c;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  overflow-wrap: anywhere;
}

.kpi-chip strong {
  font-size: 13px;
  color: #1f549f;
  overflow-wrap: anywhere;
}

.trend-badge {
  border: 1px solid #c7daf8;
  border-radius: 999px;
  background: #fffdf9;
  color: #2457a1;
  width: fit-content;
  padding: 2px 7px;
}

.live-ref-hover-insights {
  padding: 0 8px;
  display: grid;
  gap: 4px;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transform: translateY(6px);
  transition: opacity 0.2s ease, transform 0.2s ease, max-height 0.2s ease;
}

.live-ref-hover-insights small {
  border: 1px solid var(--ac-border);
  border-radius: 8px;
  background: var(--ac-surface);
  color: var(--ac-text-secondary);
  font-size: 10px;
  padding: 5px 6px;
}

.live-ref-card:hover .live-ref-hover-insights,
.live-ref-card:focus-within .live-ref-hover-insights {
  opacity: 1;
  max-height: 180px;
  transform: translateY(0);
}

.live-ref-actions {
  padding: 0 8px 8px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.22s ease, transform 0.22s ease;
  backdrop-filter: blur(5px);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(242, 248, 255, 0.92) 70%);
}

.live-ref-card:hover .live-ref-actions,
.live-ref-card:focus-within .live-ref-actions {
  opacity: 1;
  transform: translateY(0);
}

.live-ref-actions button {
  border: 1px solid #d3dff1;
  border-radius: 8px;
  background: #f7faff;
  color: #2b5fad;
  font-size: 11px;
  font-weight: 600;
  height: 33px;
}

.opportunity-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
}

.opportunity-card {
  border: 1px solid #d7e2f3;
  border-radius: 10px;
  background: #fff;
  padding: 8px;
  display: grid;
  gap: 5px;
}

.opportunity-card img {
  width: 100%;
  height: 104px;
  object-fit: cover;
  border-radius: 8px;
  background: linear-gradient(90deg, var(--ac-loading-base) 0%, var(--ac-loading-highlight) 50%, var(--ac-loading-base) 100%);
  background-size: 200% 100%;
}

.opportunity-card strong {
  font-size: 14px;
  color: var(--ink-700);
}

.opportunity-card small {
  font-size: 11px;
  color: var(--ink-600);
}

.opportunity-card button {
  border: 1px solid #cad8f2;
  border-radius: 8px;
  height: 30px;
  background: #fffdf9;
  color: #2258ab;
  font-size: 11px;
  font-weight: 600;
}

.opportunity-card button + button {
  margin-top: 2px;
}

.confidence-row {
  display: grid;
  gap: 4px;
}

.confidence-row strong {
  font-size: 26px;
  color: #1f5ec7;
  line-height: 1;
}

.confidence-row small {
  color: var(--ink-600);
  font-size: 11px;
}

.confidence-bar {
  height: 10px;
}

.confidence-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.confidence-steps span {
  border: 1px solid #d4def0;
  border-radius: 999px;
  padding: 2px 7px;
  font-size: 11px;
  background: #fff;
  color: #3f5879;
  animation: fadeInUp 0.2s ease;
}

.confidence-reasons {
  display: grid;
  gap: 6px;
}

.confidence-reasons span {
  border: 1px solid #dcc7b3;
  border-radius: 9px;
  background: #fffdf9;
  padding: 6px;
  font-size: 11px;
  color: #8a4f21;
}

.story-state {
  gap: 8px;
}

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

.story-counter-grid span {
  border: 1px solid #dcc7b3;
  border-radius: 9px;
  background: #fffdf9;
  color: #8a4f21;
  font-size: 11px;
  padding: 6px;
}

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

.roadmap-track span {
  border: 1px solid #d6e1f3;
  border-radius: 999px;
  padding: 6px 8px;
  text-align: center;
  font-size: 11px;
  background: #f7fbff;
  color: #5d779a;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.roadmap-track span.active {
  background: #e9f2ff;
  border-color: #a8c7f8;
  color: #1f5ec7;
  transform: translateY(-1px);
}

.roadmap-track span.done {
  background: #eef9f2;
  border-color: #b9e6cc;
  color: #1b7a49;
}

.roadmap-track span.queued {
  opacity: 0.8;
}

.story-counter-grid b {
  color: #1f5ec7;
}

.confidence-reasons strong {
  color: #1f5ec7;
  margin-right: 4px;
}

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

.intel-chip {
  border: 1px solid #d0ddf4;
  border-radius: 12px;
  background: linear-gradient(180deg, #f6faff 0%, #edf4ff 100%);
  color: #2a5ca8;
  font-size: 11px;
  font-weight: 600;
  padding: 8px;
  display: grid;
  gap: 3px;
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.intel-chip small {
  color: #58749c;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.intel-chip strong {
  color: #1f549f;
  font-size: 12px;
}

.intel-chip:hover {
  transform: translateY(-2px);
  border-color: #adc8f9;
  box-shadow: 0 10px 20px rgba(31, 94, 199, 0.14);
}

.intel-chip.active {
  border-color: #9fc0f9;
  background: #e8f1ff;
  color: #164eab;
}

.keyword-bubble-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.keyword-bubble {
  border: 1px solid #d2ddf2;
  border-radius: 999px;
  background: #f7fbff;
  color: #2e5f9f;
  font-size: 11px;
  font-weight: 600;
  padding: 6px 10px;
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
}

.keyword-bubble em {
  font-style: normal;
  font-weight: 500;
  color: #5f7698;
  font-size: 10px;
}

.keyword-bubble.high {
  background: #e9f3ff;
  border-color: #bdd4fb;
}

.keyword-bubble.mid {
  background: #eef8ff;
}

.keyword-bubble.low {
  background: #fffdf9;
}

.dna-visual-grid,
.concept-card-grid {
  display: grid;
  gap: 7px;
}

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

.dna-visual-grid span {
  border: 1px solid #c9d8f5;
  border-radius: 9px;
  background: #fffdf9;
  text-align: center;
  font-size: 11px;
  font-weight: 600;
  color: #275aa8;
  padding: 8px;
}

.concept-card-grid article {
  border: 1px solid #d8e2f3;
  border-radius: 10px;
  background: #fff;
  padding: 8px;
  display: grid;
  gap: 4px;
}

.concept-card-grid button {
  height: 30px;
  border: 1px solid #cad8f2;
  border-radius: 8px;
  background: #fffdf9;
  color: #2258ab;
  font-size: 11px;
  font-weight: 600;
}

.seo-card-grid,
.asset-progress-grid,
.compare-grid {
  display: grid;
  gap: 8px;
}

.seo-card-grid {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.seo-card-grid article,
.asset-progress-grid article {
  border: 1px solid #d7e1f2;
  border-radius: 10px;
  padding: 8px;
  background: #fff;
  display: grid;
  gap: 6px;
}

.seo-card-grid small,
.asset-progress-grid small {
  color: var(--ink-500);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.seo-card-grid strong {
  font-size: 12px;
  color: var(--ink-700);
}

.seo-card-grid p {
  margin: 0;
  color: var(--ink-600);
  font-size: 11px;
}

.asset-progress-grid {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

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

.compare-card {
  border: 1px solid #d3dff1;
  border-radius: 10px;
  background: #fff;
  padding: 8px;
  display: grid;
  gap: 5px;
}

.compare-card.winner {
  border-color: #9fc1fa;
  box-shadow: 0 8px 18px rgba(33, 90, 176, 0.16);
}

.compare-card img {
  width: 100%;
  height: 84px;
  object-fit: cover;
  border-radius: 8px;
}

.compare-card small {
  color: var(--ink-600);
  font-size: 10px;
}

.compare-winner {
  margin: 0;
  color: var(--ink-700);
  font-size: 12px;
}

.compare-floating-tray {
  position: fixed;
  left: 96px;
  right: 344px;
  bottom: 14px;
  z-index: 45;
  border: 1px solid #ccd9ef;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 40px rgba(14, 36, 69, 0.22);
  backdrop-filter: blur(6px);
  transform: translateY(120%);
  transition: transform 0.25s ease;
}

.compare-floating-tray.open {
  transform: translateY(0);
}

.compare-floating-tray h3 {
  margin: 0 0 8px;
}

.compare-tray-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.pinned-strip-inner {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(220px, 1fr);
  gap: 8px;
  overflow-x: auto;
}

.pinned-chip {
  border: 1px solid #cfdcf1;
  border-radius: 10px;
  background: #fdfefe;
  padding: 6px;
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 8px;
  align-items: center;
}

.pinned-chip img {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  object-fit: cover;
}

.pinned-chip strong {
  font-size: 11px;
  color: var(--ink-700);
}

.pinned-chip small {
  font-size: 10px;
  color: var(--ink-500);
}

.pinned-actions {
  grid-column: span 2;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 5px;
}

.pinned-actions button {
  border: 1px solid #d4dff1;
  border-radius: 7px;
  background: #f6faff;
  color: #2d5ea6;
  font-size: 10px;
  height: 26px;
}

.empty-live-note {
  border: 1px dashed #cfdae9;
  border-radius: 10px;
  background: #fbf7f1;
  color: var(--ink-600);
  font-size: 12px;
  padding: 10px;
}

.live-reference-drawer {
  position: fixed;
  top: 72px;
  right: 344px;
  width: min(520px, 92vw);
  bottom: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 16px 34px rgba(18, 36, 68, 0.2);
  transform: translateX(110%);
  transition: transform 0.24s ease;
  z-index: 40;
  display: grid;
  grid-template-rows: auto 1fr;
}

.live-reference-drawer.open {
  transform: translateX(0);
}

.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-bottom: 1px solid var(--line);
  padding: 10px;
}

.drawer-head h3 {
  margin: 0;
  font-size: 14px;
}

.drawer-close-btn {
  width: 28px;
  height: 28px;
  border: 1px solid var(--ac-border);
  border-radius: 8px;
  background: var(--ac-surface);
  color: var(--ac-text-secondary);
  font-weight: 700;
}

.drawer-body {
  padding: 10px;
  overflow: auto;
  display: grid;
  gap: 8px;
}

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

.drawer-actions button {
  border: 1px solid #dcc7b3;
  border-radius: 8px;
  background: #f7faff;
  color: #25539b;
  height: 32px;
  font-size: 11px;
  font-weight: 600;
}

.analyst-report {
  gap: 10px;
}

.analyst-image {
  width: 100%;
  height: 164px;
  object-fit: cover;
  border-radius: 10px;
}

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

.drawer-image {
  width: 100%;
  height: 240px;
  object-fit: cover;
  border-radius: 10px;
}

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

.drawer-inline-gallery article {
  border: 1px solid #d7e1f2;
  border-radius: 9px;
  padding: 6px;
  background: #fbfdff;
  display: grid;
  gap: 5px;
}

.drawer-inline-gallery img {
  width: 100%;
  height: 82px;
  object-fit: cover;
  border-radius: 7px;
}

.drawer-inline-gallery span {
  width: 100%;
  height: 82px;
  border-radius: 7px;
  background: linear-gradient(90deg, var(--ac-loading-base) 0%, var(--ac-loading-highlight) 50%, var(--ac-loading-base) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.4s linear infinite;
}

.drawer-inline-gallery strong {
  font-size: 11px;
  color: var(--ink-700);
}

.drawer-body p {
  margin: 0;
  font-size: 12px;
  color: var(--ink-600);
  line-height: 1.45;
}

.timeline-compact {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  padding: 8px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
}

.timeline-status-icon {
  margin-right: 6px;
}

.timeline-row-data {
  display: grid;
  gap: 2px;
}

.research-rail.timeline-collapsed #liveResearchState {
  display: none;
}

.research-rail .activity-timeline {
  max-width: 200px;
}

.timeline-compact strong {
  font-size: 12px;
  color: var(--ink-700);
}

.timeline-compact small {
  color: var(--ink-500);
  font-size: 11px;
}

.timeline-detailed.collapsed {
  display: none;
}

.timeline-detailed.expanded {
  display: grid;
  gap: 7px;
}

.concept-card-grid small {
  color: var(--ink-500);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.concept-card-grid strong {
  font-size: 12px;
}

.concept-card-grid p {
  margin: 0;
  color: var(--ink-600);
  font-size: 11px;
  line-height: 1.45;
}

.launch-progress-card {
  display: grid;
  gap: 6px;
}

.launch-progress-card small {
  color: var(--ink-500);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.launch-progress-card strong {
  font-size: 15px;
  color: #1f5fc8;
}

.launch-progress-card.done {
  border-color: #b7e5cc;
  background: #f0fbf5;
}

.launch-progress-card.working {
  border-color: #c9dafd;
  background: #f3f8ff;
}

.launch-progress-card.queued {
  border-color: #d9e2ef;
}

.mini-grid {
  display: grid;
  gap: 6px;
}

.mini-grid span {
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  padding: 7px;
  font-size: 11px;
  color: var(--ink-700);
}

.palette-chip-row {
  display: flex;
  gap: 6px;
}

.palette-chip-row i {
  width: 24px;
  height: 24px;
  border-radius: 8px;
  border: 1px solid #d7dfe9;
}

.quick-action-row {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.quick-action-row button {
  border: 1px solid var(--line);
  background: var(--surface-soft);
  color: var(--ink-700);
  height: 42px;
  border-radius: 11px;
}

.visual-market-board {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 10px;
}

.market-opportunity-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
  display: grid;
  gap: 0;
}

.market-opportunity-card.pinned {
  border-color: #98baf6;
  box-shadow: 0 8px 20px rgba(37, 90, 178, 0.12);
}

.market-opportunity-card.compared {
  outline: 2px solid #c9dcff;
  outline-offset: -2px;
}

.market-card-image {
  background: var(--ac-surface-muted);
  min-height: 180px;
  position: relative;
  display: grid;
  place-items: center;
}

.market-card-image img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.market-card-image small {
  position: absolute;
  top: 8px;
  left: 8px;
  border: 1px solid #d8e2f0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  padding: 2px 7px;
  font-size: 10px;
}

.market-card-body {
  padding: 10px;
  display: grid;
  gap: 8px;
}

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

.reference-action-row button {
  border: 1px solid #dcc7b3;
  border-radius: 8px;
  height: 34px;
  background: #fffdf9;
  color: #8a4f21;
  font-size: 11px;
  font-weight: 600;
}

.reference-lightbox-card {
  padding: 14px;
}

.reference-lightbox-body {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.reference-lightbox-body img {
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid #d5deeb;
  background: var(--ac-surface-muted);
}

.reference-lightbox-meta {
  display: grid;
  gap: 8px;
}

.reference-lightbox-meta h3 {
  margin: 0;
}

.template-grid,
.research-canvas-grid,
.live-canvas-grid,
.module-progress-grid,
.launch-check-grid,
.store-grid,
.draft-list,
.pipeline-row,
.pipeline-flow,
.factory-output-grid,
.factory-asset-grid,
.factory-video-grid,
.provider-status-grid,
.provider-stage-list,
.opportunity-list,
.product-action-bar,
.verdict-grid,
.executive-card-grid,
.recommendation-grid,
.competitor-card-grid {
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.template-grid article,
.launch-check-grid article,
.module-progress-grid article,
.store-grid .acp-card,
.pipeline-row span,
.pipeline-flow span {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-soft);
  padding: 10px;
  font-size: 12px;
}

/* UX Sprint 2, Part C: Üret's first-viewport entry-card grid (one card per
   real product type - icon + one outcome sentence + one button, per the
   benchmark report's 5.7). Reuses the same card look module-progress-grid
   already establishes above, just with room for the icon + a real primary
   button instead of a bare clickable article. */
.factory-entry-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}
.factory-entry-card {
  display: grid;
  gap: 8px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(17,31,54,.05);
  text-align: left;
}
.factory-entry-card-icon {
  font-size: 22px;
  color: var(--blue);
}
.factory-entry-card h3 {
  margin: 0;
  font-size: 16px;
}
.factory-entry-card p {
  margin: 0;
  color: var(--ink-500);
  font-size: 13px;
  line-height: 1.5;
}
.factory-entry-card .primary-btn {
  justify-self: start;
  margin-top: 4px;
}

.module-progress-grid article[data-nav] {
  cursor: pointer;
  border-color: var(--ac-border-strong, var(--line));
  box-shadow: 0 2px 6px rgba(17, 31, 54, .04);
  transition: border-color .15s ease, background .15s ease, box-shadow .15s ease, transform .15s ease;
}

.module-progress-grid article[data-nav] h4 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.module-progress-grid article[data-nav] .module-card-arrow {
  color: var(--ac-primary, #3D210E);
  font-weight: 700;
  transition: transform .15s ease;
}

.module-progress-grid article[data-nav]:hover,
.module-progress-grid article[data-nav]:focus-visible {
  border-color: var(--ac-warm-border, #d7b77d);
  background: var(--ac-warm-bg, #f2e1c2);
  box-shadow: 0 6px 16px rgba(61, 33, 14, .14);
  transform: translateY(-1px);
  outline: 0;
}

.module-progress-grid article[data-nav]:hover .module-card-arrow,
.module-progress-grid article[data-nav]:focus-visible .module-card-arrow {
  transform: translateX(2px);
}

.module-progress-grid article.disabled {
  opacity: .6;
  cursor: not-allowed;
}

.module-progress-grid article .coming-soon-badge {
  display: inline-block;
  margin-top: 6px;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--ac-border, #ded4c8);
  background: var(--ac-bg-subtle, #fbf7f1);
  color: var(--ac-text-secondary, #625b53);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.store-grid .acp-card {
  display: grid;
  gap: 4px;
}

.acp-badge {
  font-size: 11px;
  font-weight: 600;
  color: var(--ink-500);
  text-transform: uppercase;
}

.ai-note-card {
  color: var(--ink-700);
  font-size: 13px;
}

.live-task-feed article {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
}

.live-task-feed article span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 4px rgba(61, 33, 14, 0.08);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

.live-task-feed article p {
  margin: 0;
  font-size: 12px;
  color: var(--ink-700);
}

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

.skeleton-card h3 {
  margin: 0 0 8px;
  color: var(--ac-loading-title);
  font-size: 12px;
}

.skeleton-card span,
.skeleton-lines span {
  display: block;
  height: 9px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--ac-loading-base) 0%, var(--ac-loading-highlight) 50%, var(--ac-loading-base) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.4s linear infinite;
}

.skeleton-card span + span,
.skeleton-lines span + span {
  margin-top: 6px;
}

.skeleton-lines span:nth-child(2) {
  width: 84%;
}

.skeleton-lines span:nth-child(3) {
  width: 72%;
}

.tray-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.tray-header p {
  margin: 0;
}

.meta,
.label,
.description {
  color: var(--ink-500);
  font-size: 12px;
}

.progress-bar {
  margin: 10px 0;
  width: 100%;
  height: 8px;
  background: #eaf0fa;
  border-radius: 999px;
  overflow: hidden;
}

.progress-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--blue), #0B2F33);
}

.tag {
  border: 1px solid #dcc7b3;
  background: var(--blue-soft);
  color: #8a4f21;
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 11px;
}

.tagflow-panel {
  display: grid;
  gap: 8px;
}

.tag-research-panel {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-soft);
}

.tag-research-btn {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
}

.tag-research-hint {
  font-size: 11px;
  color: var(--ink-500);
}

.tag-research-success {
  color: var(--green);
}

.tagflow-summary-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-soft);
}

.tagflow-stat {
  display: grid;
  gap: 2px;
  font-size: 12px;
  min-width: 0;
}

.tagflow-stat-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--ink-500);
}

.tagflow-tag-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

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

.tagflow-volume-unknown {
  font-size: 11px;
  font-style: italic;
  color: var(--ink-500);
}

.tagflow-warnings {
  list-style: none;
  margin: 2px 0 0;
  padding: 0;
  flex-basis: 100%;
  display: grid;
  gap: 2px;
  font-size: 11px;
  color: #ac2f49;
}

.copy-block {
  border: 1px dashed #c8d6eb;
  background: #fbf7f1;
  border-radius: 10px;
  padding: 8px;
  white-space: pre-wrap;
  font-size: 12px;
}

.compact-list {
  margin: 0;
  padding-left: 16px;
  display: grid;
  gap: 4px;
  font-size: 12px;
  color: var(--ink-700);
}

/* Backgrounds were very pale tints (#eaf6ee/#fff8ed/#fff1f4 at full
   opacity but low saturation) - real colors, just washed out next to
   several in a row. Stronger rgba tints (same hues) + bigger/bolder/
   mono text reads as a real status label at a glance, matching the
   equivalent draft-detail-status pills' treatment above. */
.decision-badge,
.pill.good,
.pill.safe {
  border: 1px solid rgba(36, 122, 75, 0.35);
  background: rgba(36, 122, 75, 0.16);
  color: #156d43;
  border-radius: 999px;
  padding: 6px 10px;
  font-family: var(--ac-font-mono);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.pill.warn,
.score-mid,
.decision-test {
  border-color: rgba(161, 92, 0, 0.35);
  background: rgba(161, 92, 0, 0.16);
  color: #9d6214;
}

.pill.bad,
.score-low,
.decision-skip {
  border-color: rgba(180, 35, 24, 0.35);
  background: rgba(180, 35, 24, 0.14);
  color: #ac2f49;
}

.score-good,
.decision-produce {
  border-color: rgba(36, 122, 75, 0.35);
  background: rgba(36, 122, 75, 0.16);
  color: #156d43;
}

.bar {
  height: 7px;
  border-radius: 999px;
  background: #e6edf9;
  overflow: hidden;
}

.bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--blue), #0B2F33);
}

.message,
.message-toast {
  position: fixed;
  right: 16px;
  bottom: 14px;
  z-index: 60;
  max-width: 360px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 10px;
  box-shadow: var(--shadow);
  padding: 10px;
  font-size: 12px;
}

.message.error {
  border-color: #efb7c5;
  background: #fff1f4;
  color: #a12842;
}

.message.success {
  border-color: #afe5c6;
  background: #effff5;
  color: #176c41;
}

.v3-modal {
  position: fixed;
  inset: 0;
  background: rgba(9, 15, 26, 0.45);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 14px;
  z-index: 120;
}

.v3-modal.open {
  display: flex;
}
.onboarding-modal {
  background: radial-gradient(circle at 50% 10%, rgba(67, 125, 255, 0.2), transparent 36%), rgba(9, 15, 26, 0.62);
}

.v3-modal .onboarding-card {
  width: min(680px, 100%);
  padding: clamp(24px, 4vw, 40px);
  border-color: #dcc7b3;
  background: linear-gradient(150deg, #ffffff 0%, #fffdf9 100%);
}

.onboarding-eyebrow { margin: 0 0 8px; color: var(--blue); font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.onboarding-card > h2 { max-width: 570px; margin: 0; font-size: clamp(26px, 4vw, 38px); line-height: 1.08; }
.onboarding-intro { max-width: 590px; margin: 14px 0 24px; color: var(--ink-500); line-height: 1.55; }
.onboarding-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 0; padding: 0; list-style: none; }
.onboarding-steps li { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: rgba(255, 255, 255, 0.8); }
.onboarding-steps li.current { border-color: #d8c4ad; box-shadow: 0 8px 22px rgba(61, 33, 14, 0.1); }
.onboarding-step-number { width: 28px; height: 28px; display: grid; place-items: center; margin-bottom: 18px; border-radius: 50%; background: var(--blue-soft); color: var(--blue); font-size: 12px; font-weight: 700; }
.onboarding-steps strong, .onboarding-steps small { display: block; }
.onboarding-steps strong { margin-bottom: 5px; font-size: 13px; }
.onboarding-steps small { color: var(--ink-500); font-size: 11px; line-height: 1.4; }
.onboarding-safety { display: flex; gap: 8px; margin-top: 16px; padding: 11px 13px; border-radius: 11px; background: var(--green-soft); color: #156d43; font-size: 12px; }
.onboarding-actions { margin-top: 18px; }

@media (max-width: 720px) {
  .onboarding-steps { grid-template-columns: 1fr 1fr; }
  .onboarding-step-number { margin-bottom: 10px; }
  .onboarding-safety { display: grid; }
}

@media (max-width: 440px) {
  .v3-modal .onboarding-card { padding: 22px 18px; }
  .onboarding-steps { grid-template-columns: 1fr; }
  .onboarding-steps li { display: grid; grid-template-columns: 30px 1fr; gap: 10px; }
  .onboarding-step-number { margin: 0; }
  .onboarding-actions { display: grid; }
}

.v3-modal-card {
  width: min(640px, 100%);
  max-height: 84vh;
  overflow-y: auto;
  padding: 16px;
}

.v3-modal-card.modal-wide {
  width: min(860px, 100%);
}

.plan-limit-upgrade-line {
  margin-top: 10px;
  padding: 12px 14px;
  border: 1px solid var(--ac-border, var(--line));
  border-radius: var(--ac-radius-card-sm, 10px);
  background: var(--ac-warm-bg, var(--primary-soft));
  color: var(--ac-warm-text, var(--primary));
}

.plan-limit-modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.modal-close {
  float: right;
  width: 30px;
  height: 30px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 8px;
  cursor: pointer;
}

.form {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.form label {
  font-size: 12px;
  color: var(--ink-700);
  display: grid;
  gap: 6px;
}

.form input,
.form textarea,
.form select {
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 10px;
}

.legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 12px;
}

.legal-links a {
  color: #265dbf;
}

.compatibility-shell {
  display: none;
}

body.nav-collapsed .os-main-grid {
  grid-template-columns: 78px 1fr;
}

body.nav-collapsed .sidebar-label,
body.nav-collapsed .logo-text {
  display: none;
}

body.nav-collapsed .sidebar-item {
  justify-content: center;
  padding: 0;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(61, 33, 14, 0.4); }
  70% { box-shadow: 0 0 0 7px rgba(61, 33, 14, 0); }
  100% { box-shadow: 0 0 0 0 rgba(61, 33, 14, 0); }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Sprint 12 - Premium Visual System (visual only) */
body {
  font-family: "Poppins", sans-serif;
  font-size: var(--fs-body);
  line-height: 1.55;
  color: var(--ink-700);
  background:
    radial-gradient(1100px 450px at 15% -12%, rgba(61, 33, 14, 0.08), transparent 65%),
    radial-gradient(900px 420px at 92% 2%, rgba(16, 185, 129, 0.04), transparent 60%),
    linear-gradient(180deg, #fbf7f1 0%, #f6f0e7 100%);
}

.os-header,
.os-sidebar,
.workspace-grid,
.research-rail,
.center-canvas,
.ai-brain {
  border-color: var(--line);
}

.os-header {
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(16px) saturate(1.15);
}

.workspace-top h1,
.home-hero h2 {
  font-size: var(--fs-hero);
  letter-spacing: -0.02em;
  line-height: 1.08;
  color: var(--ink-900);
}

.section-headline h3,
.live-canvas-head h2,
.brain-head h2,
.rail-header h2,
.mission-start-head h2,
.section-head h2 {
  font-size: var(--fs-section);
  letter-spacing: -0.01em;
  color: var(--ink-900);
}

p,
small,
label,
.meta,
.description,
li,
.brain-log-item strong,
.brain-section-item strong {
  font-size: var(--fs-body);
}

.hero-copy,
.about-copy,
.live-signal-card p,
.feature-grid article p,
.story-grid article p,
.drawer-body p {
  color: var(--ink-600);
}

.module-block,
.live-canvas-shell,
.pipeline-shell,
.production-board,
.launch-checklist-shell,
.ai-note-card,
.card,
.notebook-card,
.v3-modal-card,
.live-activity-panel,
.brain-notes,
.marketing-section,
.marketing-footer,
.home-hero,
.live-flow-section,
.workspace-state-card,
.timeline-compact,
.timeline-item,
.live-ref-card,
.opportunity-card,
.compare-floating-tray,
.live-reference-drawer,
.pinned-chip,
.compare-card,
.live-signal-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow);
}

.home-hero,
.marketing-section,
.marketing-footer,
.live-canvas-shell,
.live-flow-section,
.brain-notes,
.live-activity-panel,
.workspace-state-card,
.timeline-compact,
.timeline-item,
.live-signal-card,
.compare-floating-tray,
.live-reference-drawer,
.v3-modal-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.97) 0%, rgba(251, 253, 255, 0.95) 100%);
}

.module-block,
.live-canvas-shell,
.pipeline-shell,
.production-board,
.launch-checklist-shell,
.ai-note-card,
.card,
.brain-notes,
.live-activity-panel {
  padding: var(--space-4);
}

.live-canvas-flow,
.story-counter-grid,
.brain-stream,
.brain-section-list,
.brain-live-log,
.activity-timeline,
.module-content,
.template-grid,
.research-canvas-grid,
.live-canvas-grid,
.pipeline-row,
.pipeline-flow,
.module-progress-grid,
.launch-check-grid,
.store-grid,
.draft-list,
.tray-items,
.tag-row,
.metric-pill-row,
.button-row,
.factory-output-grid,
.factory-asset-grid,
.factory-video-grid,
.provider-status-grid,
.provider-stage-list,
.opportunity-list,
.product-action-bar,
.verdict-grid,
.executive-card-grid,
.recommendation-grid,
.competitor-card-grid {
  gap: var(--space-3);
}

.hero-prompt-form,
.live-research-form {
  gap: var(--space-2);
}

.floating-input {
  position: relative;
  display: grid;
  align-items: end;
  min-height: 58px;
}

.floating-input > input {
  width: 100%;
  height: 58px;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px 16px 10px;
  background: rgba(255, 255, 255, 0.95);
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65), 0 4px 12px rgba(15, 23, 42, 0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.floating-input > span {
  position: absolute;
  left: 16px;
  top: 19px;
  font-size: 13px;
  color: var(--ink-500);
  pointer-events: none;
  transition: transform 0.2s ease, color 0.2s ease, font-size 0.2s ease;
}

.floating-input:focus-within > input,
.floating-input > input:not(:placeholder-shown) {
  border-color: rgba(61, 33, 14, 0.45);
  box-shadow: 0 0 0 4px rgba(61, 33, 14, 0.1), 0 10px 26px rgba(15, 23, 42, 0.09);
}

.floating-input:focus-within > span,
.floating-input > input:not(:placeholder-shown) + span {
  transform: translateY(-9px);
  font-size: 11px;
  color: #8a4f21;
}

button,
.header-btn,
.connection-status,
.icon-circle,
.secondary-btn,
.secondary,
.copy-btn,
.primary-btn,
button[data-product-action],
button[type="submit"] {
  border-radius: 14px;
  border: 1px solid transparent;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.secondary-btn,
.secondary,
.copy-btn,
.header-btn,
.icon-circle,
.connection-status {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.94);
}

.hero-prompt-form button,
.live-research-form button,
.primary-btn,
button[data-product-action],
button[type="submit"] {
  background: linear-gradient(140deg, #007C78 0%, #0B2F33 100%);
  color: #fff;
  box-shadow: 0 8px 20px rgba(61, 33, 14, 0.25);
}

button:hover,
.secondary-btn:hover,
.secondary:hover,
.copy-btn:hover,
.header-btn:hover,
.connection-status:hover,
.icon-circle:hover,
.hero-prompt-form button:hover,
.live-research-form button:hover,
.primary-btn:hover,
button[data-product-action]:hover,
button[type="submit"]:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
}

button.is-pressed,
button:active {
  transform: translateY(1px) scale(0.995);
}

button:disabled,
button[aria-busy="true"],
button.is-loading {
  opacity: 0.72;
  cursor: wait;
}

button.is-loading::after,
button[aria-busy="true"]::after {
  content: "";
  display: inline-block;
  width: 12px;
  height: 12px;
  margin-left: 8px;
  border-radius: 999px;
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  animation: spin 0.8s linear infinite;
  vertical-align: middle;
}

.live-visual-masonry {
  column-gap: 20px;
}

.live-ref-card {
  border-radius: 20px;
  overflow: clip;
  margin: 0 0 20px;
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.09);
}

.live-ref-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(61, 33, 14, 0.36), rgba(16, 185, 129, 0.2));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.live-ref-card:hover,
.live-ref-card:focus-within {
  transform: translateY(-3px) scale(1.005);
  box-shadow: var(--shadow-hover);
}

.live-ref-card:hover::before,
.live-ref-card:focus-within::before,
.live-ref-card.selected::before {
  opacity: 1;
}

.live-ref-card.selected {
  box-shadow: 0 0 0 3px rgba(61, 33, 14, 0.14), 0 26px 44px rgba(15, 23, 42, 0.18);
}

.live-ref-media {
  height: var(--media-height, 260px);
}

.live-ref-meta {
  padding: 0 14px 10px;
  gap: 10px;
}

.live-ref-meta strong {
  font-size: var(--fs-section);
  line-height: 1.2;
  color: var(--ink-900);
}

.direction-kpi-row {
  grid-template-columns: repeat(auto-fit, minmax(64px, 1fr));
  gap: 8px;
}

.kpi-chip {
  border-radius: 12px;
  border: 1px solid rgba(61, 33, 14, 0.18);
  background: linear-gradient(180deg, #fffdf9 0%, #fffdf9 100%);
  padding: 9px 10px;
}

.kpi-chip small {
  font-size: 10px;
  color: #5a6f93;
}

.kpi-chip strong {
  font-size: 14px;
  color: #214f9c;
}

.live-ref-actions {
  padding: 0 14px 14px;
  opacity: 1;
  transform: none;
  background: transparent;
}

.live-ref-actions button {
  height: 36px;
  border-radius: 11px;
}

.activity-timeline .eyebrow,
.brain-stream .eyebrow {
  color: var(--ink-500);
}

.timeline-compact {
  padding: 12px;
  border-radius: 16px;
  background: linear-gradient(180deg, #fff 0%, #fbf7f1 100%);
}

.timeline-compact strong {
  color: var(--ink-900);
}

.timeline-item {
  border-radius: 14px;
  padding: 10px;
}

.timeline-item.active {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
}

.timeline-item.done {
  border-color: rgba(31, 143, 87, 0.24);
  background: linear-gradient(180deg, #f4fbf7 0%, #edf8f2 100%);
}

.timeline-item .timeline-icon {
  width: 20px;
  height: 20px;
}

.analyst-canvas {
  gap: 14px;
}

.analyst-hero {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(160deg, #ffffff 0%, #f7faff 100%);
  padding: 10px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.analyst-image {
  border-radius: 14px;
  height: 192px;
}

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

.analyst-kpis .brain-section-item {
  border-radius: 12px;
  padding: 10px;
  background: linear-gradient(180deg, #fff 0%, #fffdf9 100%);
}

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

.analyst-chart-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px;
  background: linear-gradient(180deg, #fff 0%, #fbf7f1 100%);
  display: grid;
  gap: 8px;
}

.analyst-chart-card small {
  font-size: 11px;
  color: var(--ink-500);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.analyst-mini-bars {
  height: 64px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
  align-items: end;
}

.analyst-mini-bars span {
  height: var(--h, 40%);
  border-radius: 8px;
  background: linear-gradient(180deg, #007C78 0%, #0B2F33 100%);
  animation: fadeInUp 0.35s ease;
}

.analyst-timeline-mini {
  display: grid;
  gap: 6px;
}

.analyst-timeline-mini span {
  border-radius: 999px;
  border: 1px solid var(--line);
  padding: 4px 9px;
  font-size: 11px;
  width: fit-content;
  background: #fff;
  color: var(--ink-600);
}

.analyst-timeline-mini span.done {
  border-color: rgba(31, 143, 87, 0.28);
  background: #eef9f3;
  color: #1f8f57;
}

.analyst-timeline-mini span.active {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

.brain-live-log {
  border-radius: 14px;
  padding: 10px;
  background: linear-gradient(180deg, #fff 0%, #fffdf9 100%);
  max-height: 340px;
}

.brain-log-item {
  border-radius: 12px;
  padding: 9px;
  background: #fff;
}

.live-reference-drawer {
  border-radius: 20px;
  box-shadow: 0 30px 56px rgba(15, 23, 42, 0.2);
  backdrop-filter: blur(6px);
}

.compare-floating-tray {
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
}

.skeleton-card {
  border-radius: 16px;
  background: linear-gradient(180deg, var(--ac-surface) 0%, var(--ac-loading-highlight) 100%);
}

.skeleton-card span,
.skeleton-lines span,
.drawer-inline-gallery span,
.opportunity-card img {
  background: linear-gradient(110deg, var(--ac-loading-base) 18%, var(--ac-loading-highlight) 50%, var(--ac-loading-base) 82%);
  background-size: 220% 100%;
  animation: shimmer 1.5s linear infinite;
}

.pill,
.thinking-pill,
.tag,
.decision-badge,
.pill.good,
.pill.safe {
  border-radius: 999px;
}

.pill,
.thinking-pill {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

.connection-status.connected,
.score-good,
.decision-produce {
  border-color: rgba(36, 122, 75, 0.35);
  background: rgba(36, 122, 75, 0.16);
  color: #1b7f4e;
}

.roadmap-track span {
  border-radius: 999px;
  padding: 7px 9px;
}

.roadmap-track span.active {
  box-shadow: 0 0 0 3px rgba(61, 33, 14, 0.14);
}

.roadmap-track span.done {
  box-shadow: inset 0 0 0 1px rgba(31, 143, 87, 0.2);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Sprint 14 - Workspace isolation architecture */
.workspace-page-shell {
  display: grid;
  gap: 16px;
}

.workspace-page-head {
  display: grid;
  gap: 6px;
}

.workspace-page-head h2 {
  margin: 0;
}

.page-status-summary {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--ac-text, var(--ink-900));
}

#homeStatusSummary {
  margin: 0 0 14px;
}

.workspace-section-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}

/* The [hidden] attribute's UA-stylesheet default (display:none) loses to
   this class's own author-stylesheet display:grid above at equal
   specificity - author styles always win over UA styles regardless of
   selector weight. Generic fix (superseding the one-off #id overrides
   added in UX Sprint 2 for this exact bug) since more views now toggle
   `hidden` on .workspace-section-grid elements (see Store Intelligence's
   tabbed detail view, UX Sprint 4). */
.workspace-section-grid[hidden] { display: none; }

.workspace-section-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, #fff 0%, #fffdf9 100%);
  box-shadow: var(--shadow);
  padding: 12px;
  display: grid;
  gap: 10px;
}

/* Phase 3 pipeline status badges (Artwork -> Etsy draft), shown only for a
   lineage that has actually entered the Phase 3 pipeline. Reuses the
   existing workspace-section-card shell rather than a new component. */
.phase3-badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.phase3-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid var(--line);
}

.phase3-badge.is-ready {
  background: #e7f7ee;
  color: #1c7a4a;
  border-color: #bfe6cf;
}

.phase3-badge.is-pending {
  background: #f4f4f0;
  color: #6b6b62;
}

.phase3-blocked-reason {
  margin: 0;
  font-size: 12px;
  color: #9b3b22;
}

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

.workspace-section-head h3 {
  margin: 0;
  font-size: 16px;
  color: var(--ink-900);
}

.workspace-section-body {
  display: grid;
  gap: 8px;
}

.mission-start-head {
  margin-bottom: 8px;
}

.mission-start-head h2 {
  margin: 0;
}

.mission-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.mission-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, #fff 0%, #fffdf9 100%);
  box-shadow: var(--shadow);
  padding: 14px;
  display: grid;
  gap: 6px;
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: inherit;
  transition: box-shadow 160ms ease, transform 160ms ease, border-color 160ms ease;
}

.mission-card:hover,
.mission-card:focus-visible {
  border-color: var(--blue);
  box-shadow: var(--shadow-hover, var(--shadow));
  transform: translateY(-1px);
}

.mission-card-icon {
  font-size: 18px;
  color: var(--blue);
}

.mission-card-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-900);
}

.mission-card-desc {
  font-size: 12px;
  color: var(--ink-500);
  line-height: 1.4;
}

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

.workspace-chip-grid span,
.workspace-mini-timeline span {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f3f7ff;
  color: #355a97;
  font-size: 11px;
  font-weight: 600;
  padding: 5px 8px;
  text-align: center;
}

.workspace-mini-timeline {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.workspace-status-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(20, 83, 45, 0.14);
  border-radius: 999px;
  background: #eef8f0;
  color: #14532d;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  padding: 6px 8px;
  white-space: nowrap;
}

.workspace-status-chip.active {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

.workspace-progress {
  overflow: hidden;
  height: 7px;
  min-width: 92px;
  border-radius: 999px;
  background: var(--ac-loading-base);
}

.workspace-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #007C78 0%, #15803D 100%);
}

.workspace-production-list {
  display: grid;
  gap: 8px;
}

.workspace-production-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.74);
  padding: 10px;
}

.workspace-production-row > div:first-child {
  display: grid;
  gap: 5px;
  min-width: 0;
  flex: 1 1 140px;
}

.workspace-production-row > div:not(:first-child) {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.workspace-production-row strong {
  color: var(--ink-900);
  font-size: 13px;
  line-height: 1.25;
}

.workspace-production-row small {
  color: var(--ink-600);
  font-size: 11px;
  line-height: 1.35;
}

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

.workspace-metric-tile {
  display: grid;
  gap: 5px;
  min-height: 86px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 8px;
  background: #fff;
  padding: 10px;
}

.workspace-metric-tile small {
  color: var(--ink-500);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.workspace-metric-tile strong {
  color: var(--ink-900);
  font-size: 18px;
  line-height: 1.1;
}

.workspace-metric-tile span {
  color: var(--ink-600);
  font-size: 12px;
  line-height: 1.35;
}

.workspace-approval-gate {
  border-left: 3px solid #16a34a;
  background: #f4fbf6;
  border-radius: 8px;
  padding: 12px;
}

.workspace-approval-gate strong {
  color: #14532d;
  font-size: 14px;
}

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

.workspace-lane {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, #fff 0%, #fbf7f1 100%);
  box-shadow: var(--shadow);
  padding: 10px;
  display: grid;
  gap: 8px;
  min-height: 180px;
}

.workspace-lane h3 {
  margin: 0;
  font-size: 14px;
}

.workspace-lane-body {
  display: grid;
  gap: 8px;
  align-content: start;
}

.production-lane-card {
  border: 1px solid rgba(61, 33, 14, 0.16);
  border-radius: 14px;
  background: #fffdf9;
  padding: 8px;
  display: grid;
  gap: 4px;
}

.production-lane-card strong {
  font-size: 13px;
  color: var(--ink-900);
}

.production-lane-card small {
  color: var(--ink-600);
  font-size: 11px;
}

.workspace-empty-state {
  border: 1px dashed var(--line);
  border-radius: 12px;
  background: linear-gradient(180deg, #fffdf9 0%, #fffdf9 100%);
  color: var(--ink-500);
  font-size: 12px;
  padding: 10px;
}

/* UX Sprint 4: Draft Queue's own centered empty state (genuinely empty
   queue, not just an empty status tab) - icon + headline + copy + 2 real
   CTAs, same structural pattern as Store's disconnected empty state. */
.draft-queue-empty-shell {
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 48px 24px;
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: 16px;
  background: #fff;
}
.draft-queue-empty-shell[hidden] { display: none; }
.draft-queue-empty-icon { font-size: 26px; color: var(--ac-primary, var(--blue)); }
.draft-queue-empty-shell h3 { margin: 0; font-size: 18px; color: var(--ink-900); }
.draft-queue-empty-shell p { margin: 0; max-width: 46ch; color: var(--ink-500); font-size: 13px; }

/* UX Sprint 4: search + refresh row and status-tab strip above the list -
   reuses .idea-hub-tabs styling, just adds a count badge per tab. */
.draft-queue-toolbar { display: flex; gap: 8px; margin: 12px 0; }
.draft-queue-search-input { flex: 1; min-height: 36px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; font: inherit; }
.draft-queue-tab-count { display: inline-block; margin-left: 4px; padding: 0 6px; border-radius: 999px; background: rgba(0,0,0,.08); font-size: 10px; }
.idea-hub-tab.active .draft-queue-tab-count { background: rgba(255,255,255,.25); }

.draft-queue-list { display: grid; gap: 8px; }
.draft-queue-row {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 12px;
}
.draft-queue-row-preview {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--surface-soft);
  overflow: hidden;
  font-weight: 700;
  color: var(--ink-500);
}
.draft-queue-row-preview img { width: 100%; height: 100%; object-fit: cover; }
.draft-queue-row-body { min-width: 0; display: grid; gap: 2px; }
.draft-queue-row-body strong { overflow-wrap: anywhere; }
.draft-queue-row-action { justify-self: end; white-space: nowrap; }

.workspace-empty-state-cta {
  display: grid;
  gap: 8px;
  justify-items: start;
  padding: 14px;
}

.section-head.compact {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.section-head.compact > div {
  min-width: 0;
}

.workspace-placeholder-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

body[data-workspace="live-research"] #liveResearchState,
body[data-workspace="inspiration-board"] #liveResearchState,
body[data-workspace="design-dna"] #liveResearchState,
body[data-workspace="creative-brief"] #liveResearchState,
body[data-workspace="concept-studio"] #liveResearchState {
  display: grid;
}

body[data-workspace="overview"] #liveResearchState,
body[data-workspace="product-factory"] #liveResearchState,
body[data-workspace="mockup-studio"] #liveResearchState,
body[data-workspace="video-studio"] #liveResearchState,
body[data-workspace="launch-center"] #liveResearchState,
body[data-workspace="draft-queue"] #liveResearchState,
body[data-workspace="store-intelligence"] #liveResearchState,
body[data-workspace="automation"] #liveResearchState,
body[data-workspace="settings"] #liveResearchState,
body[data-workspace="seo-studio"] #liveResearchState {
  display: none;
}

/* ============================================================
   Sprint 15 — shadcn/ui visual pass (Path B: CSS-only, no React,
   no Tailwind, no build step, no app.js changes).
   Scope: workspace home (#view-overview) and Research view
   (#view-live-research + its #liveReferenceDrawer "AI Analyst"
   rail). Every rule is anchored to those containers so the other
   13 in-app views are unaffected. This slice: workspace home.
   Tokens/shapes extracted from shadcn's default "new-york" theme
   and acopes-shadcn-prototype/{app/globals.css, tailwind.config.ts,
   components/ui/*.tsx}: large soft-shadow card radius, pill
   buttons/badges, muted-foreground secondary text, tight heading
   tracking. Colors stay on ACOPES's existing ink/warm palette
   rather than the prototype's orange/pink brand — this slice
   restyles shape/depth/rhythm, not brand color.
   See docs/shadcn-feasibility.md.
   ============================================================ */
/* ---- Typography rhythm ---- */
#view-overview .hero-eyebrow {
  font-size: var(--ac-font-eyebrow);
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--ac-text-muted);
}

#view-overview .home-hero h2 {
  font-weight: 650;
  letter-spacing: -0.02em;
}

#view-overview .hero-copy,
#view-overview .live-signal-card p {
  color: var(--ac-text-muted);
}

/* ---- Home hero card ---- */
#view-overview .home-hero {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-hero);
  background: linear-gradient(180deg, #ffffff 0%, #f8faff 100%);
  box-shadow: var(--ac-shadow-card);
  padding: var(--ac-space-10) var(--ac-space-7);
}

#view-overview .live-signal-card {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-panel);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--ac-shadow-card);
  padding: var(--ac-space-4);
}

#view-overview .workflow-step-pill {
  border-radius: var(--ac-radius-pill);
  border: 1px solid var(--ac-border);
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink-700);
  font-weight: 600;
}

#view-overview .workflow-step-pill.active {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

/* ---- Home dashboard cards (market opportunity board) ---- */
#view-overview .market-opportunity-card {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-panel);
  background: #fff;
  box-shadow: var(--ac-shadow-card);
  transition: box-shadow 0.18s ease, transform 0.18s ease;
}

#view-overview .market-opportunity-card:hover {
  box-shadow: var(--ac-shadow-card-hover);
  transform: translateY(-2px);
}

#view-overview .market-card-body {
  padding: var(--ac-space-4);
}

#view-overview .market-card-image small {
  border-radius: var(--ac-radius-pill);
  border: 1px solid var(--ac-border);
  background: rgba(255, 255, 255, 0.92);
  font-weight: 600;
}

#view-overview .reference-action-row button {
  border-radius: var(--ac-radius-pill);
  border: 1px solid var(--ac-border);
  background: #fff;
  color: var(--ink-700);
  font-weight: 600;
  box-shadow: none;
}

#view-overview .reference-action-row button[aria-pressed="true"] {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

/* ---- Inputs: factory search ---- */
#view-overview .floating-input > input {
  border-radius: var(--ac-radius-control);
  border: 1px solid var(--ac-border);
  background: #fff;
}

#view-overview .floating-input:focus-within > input {
  border-color: rgba(61, 33, 14, 0.5);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, 0.15);
}

/* ---- Buttons: primary / secondary / ghost hierarchy ---- */
#view-overview button {
  border-radius: var(--ac-radius-pill);
  font-weight: 600;
}

/* primary: Run Live Scan / Continue Creating */
#view-overview .hero-prompt-form button {
  border: 1px solid transparent;
  box-shadow: var(--ac-shadow-glow);
}

#view-overview button:hover {
  transform: translateY(-1px);
}

/* ============================================================
   Sprint 15 continued — shadcn/ui visual pass, Research view slice.
   Scope: #view-live-research + #liveReferenceDrawer ("AI Analyst"
   rail) only. Reuses the unified ACOPES design tokens defined below.
   ============================================================ */

/* ---- Typography rhythm ---- */
#view-live-research .live-canvas-head p,
#view-live-research .live-ref-meta small,
#liveReferenceDrawer .drawer-body p {
  color: var(--ac-text-muted);
}

#view-live-research .section-headline.compact h3,
#view-live-research .live-canvas-head h2,
#liveReferenceDrawer .drawer-head h3 {
  font-weight: 650;
  letter-spacing: -0.01em;
}

/* ---- Research canvas shell ---- */
#view-live-research .live-canvas-shell {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-hero);
  box-shadow: var(--ac-shadow-card);
  padding: var(--ac-space-7);
}

#view-live-research .live-flow-section {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-panel);
  box-shadow: var(--ac-shadow-card);
  padding: var(--ac-space-4);
}

#view-live-research .section-headline.compact {
  margin-bottom: var(--ac-space-3);
}

/* ---- Live Market Scan panel (real data; honest "--" fields kept) ---- */
#view-live-research .market-scan-provenance {
  border-radius: var(--ac-radius-pill);
  border: 1px solid rgba(31, 143, 87, 0.28);
  background: var(--green-soft);
  color: var(--green);
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 3px 10px;
}

#view-live-research .market-scan-metrics strong {
  font-size: 15px;
  font-weight: 650;
  color: var(--ink-900);
}

#view-live-research .market-scan-tag {
  border-radius: var(--ac-radius-pill);
  border: 1px solid var(--ac-border);
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink-700);
  font-weight: 600;
  padding: 3px 10px;
}

#view-live-research .market-scan-error {
  display: inline-block;
  border-radius: var(--ac-radius-panel);
  border: 1px solid rgba(179, 38, 30, 0.24);
  background: #fdf2f1;
  color: #b3261e;
  padding: var(--ac-space-3) var(--ac-space-4);
}

/* ---- Product Direction cards ---- */
#view-live-research .live-ref-card {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-panel);
  box-shadow: var(--ac-shadow-card);
  transition: box-shadow 0.18s ease, transform 0.18s ease;
}

#view-live-research .live-ref-card:hover,
#view-live-research .live-ref-card:focus-within {
  box-shadow: var(--ac-shadow-card-hover);
}

#view-live-research .live-badge {
  border-radius: var(--ac-radius-pill);
  border: 1px solid var(--ac-border);
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink-700);
  font-weight: 600;
}

#view-live-research .kpi-chip {
  border-radius: 14px;
  border: 1px solid var(--ac-border);
  background: rgba(247, 250, 255, 0.8);
}

#view-live-research .kpi-chip small {
  color: var(--ac-text-muted);
}

#view-live-research .opportunity-card {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-panel);
  box-shadow: var(--ac-shadow-card);
}

#view-live-research .opportunity-card small {
  color: var(--ac-text-muted);
}

/* ---- AI Analyst rail (live reference drawer) ---- */
#liveReferenceDrawer {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-hero);
}

#liveReferenceDrawer .drawer-close-btn {
  border-radius: var(--ac-radius-pill);
}

/* ---- Inputs: research query search ---- */
#view-live-research .floating-input > input {
  border-radius: var(--ac-radius-control);
  border: 1px solid var(--ac-border);
  background: #fff;
}

#view-live-research .floating-input:focus-within > input {
  border-color: rgba(61, 33, 14, 0.5);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, 0.15);
}

/* ---- Buttons: primary / secondary / ghost hierarchy ---- */
#view-live-research button,
#liveReferenceDrawer button {
  border-radius: var(--ac-radius-pill);
  font-weight: 600;
}

/* primary: Start Research / Generate Product */
#view-live-research .live-research-form button,
#view-live-research .live-ref-actions button[data-live-ref-action="generate-coloring-book"] {
  border: 1px solid transparent;
  box-shadow: var(--ac-shadow-glow);
}

/* secondary: Analyze / View Blueprint / drawer actions */
#view-live-research .live-ref-actions button:not([data-live-ref-action="generate-coloring-book"]),
#liveReferenceDrawer .drawer-actions button {
  background: #fff;
  color: var(--ink-700);
  border: 1px solid var(--ac-border);
  box-shadow: none;
}

#view-live-research .live-ref-actions button:not([data-live-ref-action="generate-coloring-book"]):hover,
#liveReferenceDrawer .drawer-actions button:hover {
  background: var(--surface-soft);
}

#view-live-research button:hover,
#liveReferenceDrawer button:hover {
  transform: translateY(-1px);
}

/* ============================================================
   Sprint 16 — Optimsy-inspired bold visual revision (rev2).
   Design language referenced from optimsy.com (dark premium theme,
   elevated glass cards, gradient accent) and the optimsy-inspired-saas/
   prototype in this repo — copy, layout, and brand colors are ours,
   never theirs.

   The landing-page dark theme this comment used to describe (Part A)
   moved out to public/landing.css as part of the 2026 Hallmark redesign;
   public/landing.html no longer links this stylesheet at all, so the
   `.landing-page`-scoped rules that lived here were deleted as dead code.

   Part B — OS home + Research (#view-overview, #view-live-research):
   push Sprint 15's card system further. Missing ingredient was page/card
   contrast: cards were near-white on a near-white page. Fix: soft gray
   page background behind the same white elevated cards, stronger
   shadows, filled chip badges, more breathing room.
   ============================================================ */

/* ---- Part B: OS home + Research — page/card contrast bump ---- */
/* NOTE: intentionally not using .center-canvas:has(> #view-x.active) here.
   body.home-mode is toggled 1:1 with #view-overview (it is the only view id
   not in app.js's researchViews set), so it's an exact, dependency-free match.
   #view-live-research has no equivalent body-level class (research-mode
   covers 13 other views too), so its background is applied directly to the
   view element instead of the .center-canvas ancestor. */
body.home-mode .center-canvas {
  background: linear-gradient(180deg, #f8f9fb 0%, #eef1f6 100%);
}

#view-live-research.active {
  background: linear-gradient(180deg, #f8f9fb 0%, #eef1f6 100%);
  border-radius: var(--ac-radius-panel);
  min-height: calc(100vh - 88px);
}

#view-overview .research-canvas-grid,
#view-overview #approvedFactoryOutputs {
  margin-top: var(--ac-space-4);
}

#view-overview .market-scan-tag,
#view-live-research .market-scan-tag,
#view-live-research .live-badge,
#view-live-research .kpi-chip {
  background: var(--surface-soft);
  border-color: rgba(16, 24, 40, 0.16);
}

#view-overview .workflow-step-pill {
  border-color: rgba(16, 24, 40, 0.16);
  background: var(--surface-soft);
}

/* Research discovery masonry board */
#view-live-research.active {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  align-items: start;
  gap: 18px;
  overflow: visible;
}

#view-live-research .live-canvas-shell,
#view-live-research .live-canvas-flow,
#view-live-research .gallery-section,
#view-live-research #liveVisualReferences {
  min-width: 0;
  container-type: inline-size;
  container-name: product-directions;
}

#view-live-research .live-visual-masonry {
  column-count: 2;
  column-gap: 16px;
  width: 100%;
}

#view-live-research .live-ref-card {
  display: inline-block;
  width: 100%;
  margin: 0 0 16px;
  break-inside: avoid;
  page-break-inside: avoid;
  overflow: hidden;
  border: 1px solid #dcc7b3;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(17, 31, 54, 0.07);
  cursor: pointer;
  transform: none;
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

#view-live-research .live-ref-card:hover,
#view-live-research .live-ref-card:focus-within {
  transform: translateY(-3px);
  border-color: #dcc7b3;
  box-shadow: 0 16px 32px rgba(17, 49, 100, 0.14);
}

#view-live-research .live-ref-card:focus-visible {
  outline: 3px solid rgba(61, 33, 14, .3);
  outline-offset: 3px;
}

#view-live-research .live-ref-card.selected {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, .18), 0 16px 32px rgba(17, 49, 100, .14);
}

#view-live-research .live-ref-media {
  position: relative;
  height: auto;
  min-height: 112px;
  overflow: hidden;
  background: #f1f4f8;
}

#view-live-research .live-ref-media img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  transform: none;
}

#view-live-research .live-ref-card:hover .live-ref-media img { transform: none; }

#view-live-research .live-ref-placeholder {
  min-height: 150px;
  height: auto;
  padding: 24px 14px;
  color: var(--ac-text-muted);
  font-size: 12px;
  font-weight: 600;
  text-align: center;
  background: linear-gradient(145deg, var(--ac-loading-highlight), var(--ac-loading-base));
}

#view-live-research .live-ref-meta {
  display: grid;
  gap: 9px;
  padding: 14px;
}

#view-live-research .live-ref-title {
  display: -webkit-box;
  max-width: 100%;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  color: var(--ink-900);
  font-size: 15px;
  line-height: 1.35;
  overflow-wrap: normal;
  word-break: normal;
}

#view-live-research .direction-signal-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--line);
}

#view-live-research .direction-signal-row span {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
  padding: 7px 0;
  border-bottom: 1px solid var(--line);
}
#view-live-research .direction-signal-row small { color: var(--ink-500); font-size: 9px; text-transform: uppercase; letter-spacing: .05em; }
#view-live-research .direction-signal-row strong { color: var(--ink-700); font-size: 12px; text-align: right; word-break: normal; overflow-wrap: normal; }
#view-live-research .direction-source { display: block; padding-top: 2px; color: var(--ink-500); font-size: 10px; word-break: normal; overflow-wrap: normal; }
#view-live-research .live-badge { max-width: 100%; white-space: nowrap; }

#view-live-research .live-ref-actions {
  position: absolute;
  inset: auto 9px 9px;
  z-index: 2;
  display: flex;
  gap: 6px;
  padding: 0;
  opacity: 0;
  transform: translateY(5px);
  background: transparent;
  transition: opacity .18s ease, transform .18s ease;
}

#view-live-research .live-ref-card:hover .live-ref-actions,
#view-live-research .live-ref-card:focus-within .live-ref-actions {
  opacity: 1;
  transform: none;
}

#view-live-research .live-ref-actions button,
#view-live-research .live-ref-actions a {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  border: 1px solid rgba(255,255,255,.75);
  border-radius: 999px;
  background: rgba(255,255,255,.94);
  box-shadow: 0 5px 16px rgba(17,31,54,.16);
  color: #214f9c;
  font-size: 10px;
  font-weight: 700;
  text-decoration: none;
  backdrop-filter: blur(8px);
}

#liveReferenceDrawer {
  position: sticky;
  top: 76px;
  right: auto;
  bottom: auto;
  width: 100%;
  max-height: calc(100vh - 92px);
  transform: none;
  overflow: auto;
  z-index: 5;
  box-shadow: 0 10px 30px rgba(17,31,54,.08);
}

#liveReferenceDrawer .drawer-close-btn { display: none; }
#liveReferenceDrawer .drawer-body { padding: 14px; }
#liveReferenceDrawer .drawer-image { width: 100%; height: auto; max-height: 230px; object-fit: contain; border-radius: 12px; background: #f1e9de; }
#liveReferenceDrawer .drawer-body h4 { margin: 13px 0; line-height: 1.35; }
#liveReferenceDrawer .analyst-empty-state { padding: 22px 4px; }
#liveReferenceDrawer .analyst-empty-state h4 { margin: 0 0 8px; }
#liveReferenceDrawer .analyst-empty-state p { margin: 0; color: var(--ink-500); font-size: 13px; line-height: 1.55; }
#liveReferenceDrawer .analyst-signal-list { display: grid; gap: 0; border-top: 1px solid var(--line); }
#liveReferenceDrawer .analyst-signal-list p { display: grid; gap: 4px; margin: 0; padding: 10px 0; border-bottom: 1px solid var(--line); }
#liveReferenceDrawer .analyst-signal-list strong { color: var(--ink-500); font-size: 10px; text-transform: uppercase; letter-spacing: .05em; }
#liveReferenceDrawer .analyst-signal-list span { color: var(--ink-700); font-size: 12px; overflow-wrap: anywhere; }
#liveReferenceDrawer .analyst-listing-link { display: inline-flex; margin-top: 13px; color: var(--blue); font-size: 12px; font-weight: 700; }
#liveReferenceDrawer .drawer-actions { margin-top: 14px; }
#liveReferenceDrawer .drawer-actions button { width: 100%; min-height: 40px; border: 0; background: var(--blue); color: #fff; }

@container product-directions (min-width: 760px) {
  #view-live-research .live-visual-masonry { column-count: 3; }
}

@container product-directions (max-width: 435px) {
  #view-live-research .live-visual-masonry { column-count: 1; }
}

/* Store Command Center V1 */
body.home-mode .research-rail, body.research-results-mode .research-rail { display: none; }
body.home-mode .center-canvas, body.research-results-mode .center-canvas { width: 100%; max-width: none; }
/* UX Sprint 4: Home regains its right rail (seller-journey stepper + credit
   summary, see homeJourneyPanelHtml/homeCreditSummaryHtml in app.js) - the
   left AI Activity rail stays hidden on Home (out of this task's scope),
   only the AI Brain rail is restored. */
body.home-mode .workspace-grid { grid-template-columns: minmax(0, 1fr) 330px; }
.store-command-center { display: grid; gap: 18px; padding: 4px; }
.command-center-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 22px; border: 1px solid var(--line); border-radius: 18px; background: #fff; box-shadow: 0 8px 28px rgba(17,31,54,.07); }
.command-center-header h2 { margin: 4px 0; font-size: clamp(22px, 3vw, 30px); }
.command-shop-name { margin: 0; color: var(--ink-600); font-weight: 650; }
.command-statuses { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; max-width: 460px; }
.command-status { padding: 7px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink-600); background: var(--surface-soft); font-size: 11px; font-weight: 700; white-space: nowrap; }
.command-status.connected, .command-status.safe { color: var(--green); border-color: rgba(31,143,87,.25); background: var(--green-soft); }
.store-summary-row { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; }
.store-summary-row article { display: grid; gap: 6px; min-width: 0; padding: 15px 16px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: 0 5px 18px rgba(17,31,54,.05); }
.store-summary-row span { color: var(--ink-500); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.store-summary-row strong { color: var(--ink-900); font-size: 20px; overflow-wrap: break-word; }

/* UX Sprint 4: Store Intelligence summary's "top priority" card - real
   top item from state.marketActions.summary[], same card language as the
   KPI tiles above it. */
.store-priority-card {
  display: grid;
  gap: 6px;
  padding: 16px 18px;
  border: 1px solid var(--ac-warning, #a15c00);
  border-radius: 16px;
  background: var(--ac-warning-soft, #fff4dc);
}
.store-priority-eyebrow { margin: 0; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--ac-warning, #a15c00); }
.store-priority-card h3 { margin: 0; font-size: 16px; color: var(--ink-900); }
.store-priority-card p:not(.store-priority-eyebrow) { margin: 0; color: var(--ink-700); font-size: 13px; }
.store-priority-card button { justify-self: start; margin-top: 4px; }
.command-work-section, .today-operating-section { padding: 18px; border: 1px solid var(--line); border-radius: 18px; background: #fff; }

/* UX Sprint 1, P0 #1: wide priority panel ("N drafts have missing info")
   gets more visual weight than the plain single-line next-task card - see
   draftPriorityPanelHtml()/renderOverview() in app.js. Reuses the same
   --line/--ink-900/--blue tokens the rest of this section already uses,
   no new palette. */
.today-operating-section--priority { padding: 26px; border-color: var(--blue); box-shadow: 0 10px 28px rgba(17,31,54,.08); }
.draft-priority-panel, .home-hero-card { grid-column: 1 / -1; display: grid; gap: 14px; }
.draft-priority-panel h3 { margin: 0; font-size: clamp(19px, 2.4vw, 24px); color: var(--ink-900); }
.draft-priority-chip-row { display: flex; flex-wrap: wrap; gap: 10px; }
.draft-priority-chip { display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--ink-900); font-size: 13px; font-weight: 650; cursor: pointer; transition: border-color .15s ease, transform .15s ease; }
.draft-priority-chip:hover, .draft-priority-chip:focus-visible { border-color: var(--blue); transform: translateY(-1px); outline: 0; }
.draft-priority-chip strong { color: var(--blue); }
.draft-priority-cta { justify-self: start; }

/* UX Sprint 3: 5-state Home hero card (homeNextTaskInfo/homeHeroCardHtml
   in app.js). Structural pattern only (eyebrow label + bold headline +
   one-sentence copy + single CTA) informed by a competitor UX audit - no
   competitor copy, imagery, or color values were used; every color here
   is this app's own token system (--ac-primary/--ac-success/--ac-warning/
   --ac-danger). Each state gets its own eyebrow/heading accent color so
   the hero's urgency reads at a glance without new iconography. */
.home-hero-eyebrow { margin: 0; font-size: 11px; font-weight: 750; letter-spacing: .05em; text-transform: uppercase; color: var(--ac-primary, var(--blue)); }
.home-hero-card h3 { margin: 0; font-size: clamp(20px, 2.6vw, 28px); color: var(--ink-900); }
.home-hero-copy { margin: 0; max-width: 62ch; color: var(--ink-500); font-size: 14px; line-height: 1.55; }
.home-hero-cta { justify-self: start; }
.home-hero-card--error .home-hero-eyebrow { color: var(--ac-danger, #b42318); }
.home-hero-card--error.home-hero-card, .today-operating-section--hero-error.today-operating-section--priority { border-color: var(--ac-danger, #b42318); }
.home-hero-card--pending .home-hero-eyebrow { color: var(--ac-warning, #a15c00); }
.today-operating-section--hero-pending.today-operating-section--priority { border-color: var(--ac-warning, #a15c00); }
.home-hero-card--ready .home-hero-eyebrow { color: var(--ac-success, #247a4b); }
.today-operating-section--hero-ready.today-operating-section--priority { border-color: var(--ac-success, #247a4b); }

/* KPI row (store-summary-row) demoted to a secondary/lower-weight block
   below the priority panel - same tokens, smaller type/padding only. */
.store-summary-secondary { display: grid; gap: 10px; }
.store-summary-secondary .store-summary-row > button, .store-summary-secondary .store-summary-row > article { padding: 11px 13px; }
.store-summary-secondary .store-summary-row strong { font-size: 17px; }

.command-action-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; }
.command-action-grid button { display: grid; align-content: start; gap: 7px; min-height: 116px; padding: 16px; text-align: left; border: 1px solid #dcc7b3; border-radius: 16px; background: #fbf7f1; color: var(--ink-900); box-shadow: none; }
.command-action-grid button:hover, .command-action-grid button:focus-visible { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(61,33,14,.12); transform: translateY(-2px); }
.command-action-grid span { font-size: 15px; font-weight: 750; }
.command-action-grid small { color: var(--ink-500); font-size: 12px; line-height: 1.45; }
.today-operating-list { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
.today-operating-list article { display: flex; flex-direction: column; justify-content: space-between; gap: 12px; min-height: 112px; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-soft); }
.today-operating-list strong { font-size: 13px; } .today-operating-list p { margin: 5px 0 0; color: var(--ink-500); font-size: 11px; line-height: 1.4; }
.today-operating-list button { align-self: flex-start; min-height: 34px; padding: 0 12px; border: 0; border-radius: 999px; background: var(--blue); color: #fff; font-size: 11px; font-weight: 700; }

/* Compact research operating flow */
body.research-results-mode .workspace-grid { grid-template-columns: minmax(0,1fr); }
body.research-results-mode .ai-brain { display: none; }
body.research-results-mode.research-brain-open:not(.product-detail-open) .workspace-grid { grid-template-columns: minmax(0,1fr) 300px; }
body.research-results-mode.research-brain-open:not(.product-detail-open) .ai-brain { display: block; }
#view-live-research.active { display: block; width: 100%; min-height: 0; }
#view-live-research .live-canvas-shell { width: 100%; }
.idea-hub-tabs { display: inline-flex; align-items: center; gap: 0.15rem; padding: 0.18rem; margin-bottom: 12px; border: 1px solid var(--line); border-radius: 999px; background: #fff; }
.idea-hub-tab { width: auto; min-height: 1.9rem; padding: 0 0.85rem; border: 0; border-radius: 999px; background: transparent; color: var(--ac-text-secondary); font: 700 0.78rem/1 Inter, system-ui, sans-serif; cursor: pointer; }
.idea-hub-tab.active { background: var(--ac-primary); color: var(--ac-on-primary); }
.idea-hub-tab:focus-visible { outline: 2px solid var(--ac-focus); outline-offset: 2px; }
#view-live-research .live-canvas-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
#view-live-research .live-canvas-head h2 { margin: 2px 0 0; font-size: 24px; }
#view-live-research .gallery-section { padding: 14px; }
#view-live-research #liveVisualReferences { padding: 0; border: 0; box-shadow: none; background: transparent; }
.results-board-head, .research-results-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.results-board-head h3, .results-board-head p { margin: 0; } .results-board-head p { color: var(--ink-500); font-size: 11px; }
.research-result-grid { display: grid; grid-template-columns: repeat(3,minmax(210px,1fr)); gap: 16px; width: 100%; }
#view-live-research .live-ref-card, .research-results-modal .live-ref-card { display: flex; flex-direction: column; width: 100%; min-width: 0; margin: 0; overflow: hidden; border: 1px solid #dcc7b3; border-radius: 16px; background: #fff; box-shadow: 0 5px 16px rgba(17,31,54,.07); cursor: pointer; }
#view-live-research .live-ref-media, .research-results-modal .live-ref-media { height: 176px; min-height: 176px; background: var(--ac-loading-highlight); overflow: hidden; }
#view-live-research .live-ref-media img, .research-results-modal .live-ref-media img { width: 100%; height: 100%; object-fit: cover; }
#view-live-research .live-ref-placeholder, .research-results-modal .live-ref-placeholder { display: grid; place-items: center; height: 176px; min-height: 176px; padding: 14px; text-align: center; color: var(--ac-text-muted); background: var(--ac-loading-base); }
#view-live-research .live-ref-meta, .research-results-modal .live-ref-meta { display: grid; gap: 9px; flex: 1; padding: 14px; }
#view-live-research .live-ref-title, .research-results-modal .live-ref-title { display: -webkit-box; min-height: 40px; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; font-size: 14px; line-height: 1.4; word-break: normal; overflow-wrap: normal; }
#view-live-research .live-badge, .research-results-modal .live-badge { justify-self: start; max-width: 100%; margin: 0; padding: 4px 8px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; border-radius: 999px; background: var(--surface-soft); color: var(--ink-500); font-size: 9px; font-weight: 750; }
.direction-metrics { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.direction-metrics span { display: grid; gap: 2px; padding: 8px; border-radius: 10px; background: var(--surface-soft); }
.direction-metrics small, .marketplace-signal span { color: var(--ink-500); font-size: 9px; text-transform: uppercase; } .direction-metrics strong { font-size: 12px; }
.marketplace-signal { display: flex; justify-content: space-between; gap: 12px; margin: 0; padding-top: 8px; border-top: 1px solid var(--line); font-size: 11px; }
#view-live-research .live-ref-actions, .research-results-modal .live-ref-actions { position: static; display: flex; gap: 7px; margin-top: auto; padding: 0; opacity: 1; transform: none; }
#view-live-research .live-ref-actions button, #view-live-research .live-ref-actions a, .research-results-modal .live-ref-actions button, .research-results-modal .live-ref-actions a { flex: 1; min-height: 34px; display: inline-flex; align-items: center; justify-content: center; padding: 0 10px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--blue); box-shadow: none; font-size: 10px; font-weight: 750; text-decoration: none; }
#liveReferenceDrawer { display: none; position: fixed; top: 70px; right: 18px; bottom: 18px; width: min(390px,calc(100vw - 36px)); max-height: none; z-index: 80; overflow: auto; background: #fff; box-shadow: 0 24px 70px rgba(17,31,54,.25); }
#liveReferenceDrawer.open { display: block; } #liveReferenceDrawer .drawer-close-btn { display: inline-flex; }
#liveReferenceDrawer .drawer-actions { display: grid; gap: 8px; } #liveReferenceDrawer .drawer-actions .secondary-btn { border: 1px solid var(--line); background: #fff; color: var(--ink-700); }
.research-results-modal { align-items: stretch; padding: 24px; }
.research-results-card { width: min(1180px,100%); max-width: none; max-height: calc(100vh - 48px); margin: auto; overflow: auto; padding: 24px; }
.research-pagination { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 18px; } .research-pagination span { min-width: 110px; text-align: center; color: var(--ink-500); font-size: 12px; }
/* Authenticated workspace responsive system */
.route-page-title { display: grid; gap: 5px; min-width: 0; }
.route-page-title h1, .route-page-title p { min-width: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
.route-page-title h1 { margin: 0; }
.route-page-title p { margin: 0; color: var(--ink-500); font-size: 13px; line-height: 1.45; }
body.home-mode .workspace-top { margin-bottom: 12px; }
body.home-mode .workflow-strip { display: none; }
.store-command-center { gap: 14px; }
.command-center-header { min-height: 0; align-items: center; padding: 12px 16px; border-radius: 16px; }
.command-shop-name { color: var(--ink-900); font-size: 16px; }
.command-statuses { margin-left: auto; }
.store-summary-row > button, .store-summary-row > article { appearance: none; display: grid; gap: 6px; min-width: 0; padding: 14px 16px; text-align: left; border: 1px solid var(--line); border-radius: 16px; background: #fff; color: inherit; box-shadow: 0 5px 18px rgba(17,31,54,.05); }
.store-summary-row > button { cursor: pointer; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.store-summary-row > button:hover, .store-summary-row > button:focus-visible { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(61,33,14,.12), 0 10px 24px rgba(17,31,54,.08); transform: translateY(-2px); outline: 0; }
.store-summary-row > button span, .store-summary-row > article span { color: var(--ink-500); font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.store-summary-row > button strong, .store-summary-row > article strong { color: var(--ink-900); font-size: 20px; }
.store-summary-row > button small { color: var(--blue); font-size: 10px; font-weight: 750; }
.store-summary-row > article small { color: var(--ink-500); font-size: 10px; font-weight: 700; }
.command-work-section, .today-operating-section { padding: 16px; }
.command-action-grid button { grid-template-columns: auto 1fr; grid-template-rows: auto auto 1fr; column-gap: 10px; min-height: 138px; padding: 16px; border-radius: 17px; }
.command-action-grid button i { grid-row: 1 / 3; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: var(--ac-warm-bg); color: var(--ac-warm-text); font-style: normal; font-size: 14px; }
.command-action-grid button span { align-self: center; font-size: 14px; }
.command-action-grid button small { grid-column: 1 / -1; white-space: normal; overflow-wrap: anywhere; }
.command-action-grid button b { grid-column: 1 / -1; align-self: end; color: var(--blue); font-size: 10px; }
.today-operating-list article { min-height: 104px; }
html[data-page="app"] .os-main-grid, html[data-page="app"] .workspace-grid, html[data-page="app"] .center-canvas, html[data-page="app"] .workspace-page-shell, html[data-page="app"] .workspace-section-card, html[data-page="app"] .workspace-section-body, html[data-page="app"] .view.active, html[data-page="app"] .store-command-center, html[data-page="app"] .live-canvas-shell, html[data-page="app"] .live-canvas-flow, html[data-page="app"] .live-flow-section { min-width: 0; max-width: 100%; }
html[data-page="app"] .workspace-top, html[data-page="app"] .workspace-status-row, html[data-page="app"] .command-center-header, html[data-page="app"] .command-statuses, html[data-page="app"] .workspace-section-head, html[data-page="app"] .results-board-head, html[data-page="app"] .live-canvas-head { min-width: 0; max-width: 100%; }
html[data-page="app"] .workspace-status-row .pill, html[data-page="app"] .command-status, html[data-page="app"] .workspace-section-card, html[data-page="app"] .workspace-section-card * { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }

@media (min-width: 601px) and (max-width: 1024px) {
  html[data-page="app"] .os-main-grid { grid-template-columns: 72px minmax(0, 1fr); }
  html[data-page="app"] .os-sidebar { padding-inline: 8px; }
  html[data-page="app"] .sidebar-item { justify-content: center; padding-inline: 0; }
  html[data-page="app"] .sidebar-label { display: none; }
  html[data-page="app"] .workspace-grid, body.research-mode .workspace-grid, body.home-mode .workspace-grid, body.research-results-mode .workspace-grid, body.research-results-mode.research-brain-open:not(.product-detail-open) .workspace-grid { grid-template-columns: minmax(0, 1fr); }
  html[data-page="app"] .research-rail, html[data-page="app"] .ai-brain { display: none; }
  body.research-results-mode.research-brain-open:not(.product-detail-open) .ai-brain { display: block; }
  html[data-page="app"] .workspace-top, html[data-page="app"] .command-center-header, html[data-page="app"] #view-live-research .live-canvas-head { flex-direction: column; align-items: flex-start; }
  html[data-page="app"] .command-statuses { justify-content: flex-start; margin-left: 0; }
  html[data-page="app"] .workflow-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  html[data-page="app"] .store-summary-row, html[data-page="app"] .workspace-metric-grid, html[data-page="app"] .command-action-grid, html[data-page="app"] .workspace-section-grid, html[data-page="app"] .workspace-lane-grid, html[data-page="app"] .research-result-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  html[data-page="app"] .today-operating-list { grid-template-columns: minmax(0, 1fr); }
  html[data-page="app"] .module-progress-grid, html[data-page="app"] .launch-check-grid, html[data-page="app"] .template-grid, html[data-page="app"] .live-canvas-grid, html[data-page="app"] .pipeline-row, html[data-page="app"] .pipeline-flow, html[data-page="app"] .roadmap-track, html[data-page="app"] .opportunity-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  html[data-page="app"] #liveReferenceDrawer { position: relative; inset: auto; width: 100%; margin-top: 16px; }
}

@media (max-width: 600px) {
  html[data-page="app"], html[data-page="app"] body, html[data-page="app"] .acopes-os-shell, html[data-page="app"] .os-main-grid, html[data-page="app"] .workspace-grid, html[data-page="app"] .center-canvas, html[data-page="app"] main { width: 100%; max-width: 100%; min-width: 0; }
  html[data-page="app"] .acopes-os-shell { grid-template-rows: auto 1fr; }
  html[data-page="app"] .os-header { height: auto; display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "brand actions" "store store" "credits credits" "palette palette"; gap: 8px; padding: 8px 12px; }
  html[data-page="app"] .header-left { grid-area: brand; min-width: 0; }
  html[data-page="app"] .header-actions { grid-area: actions; min-width: 0; margin-left: 0; }
  html[data-page="app"] .connection-status { grid-area: store; width: 100%; min-width: 0; overflow: hidden; }
  html[data-page="app"] #topConnectionText { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  html[data-page="app"] .ai-credit-indicator { grid-area: credits; width: 100%; min-width: 0; }
  /* Sole header entry point (B3 - the dead #globalSearchInput was removed,
     not replaced) now fills the full-width row that used to hold it. */
  html[data-page="app"] #commandPaletteTrigger { grid-area: palette; width: 100%; justify-content: center; }
  html[data-page="app"] .header-actions .icon-circle { display: none; }
  html[data-page="app"] .os-main-grid { display: block; min-height: 0; }
  html[data-page="app"] .os-sidebar { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); width: 100%; gap: 3px; padding: 6px; border-right: 0; border-bottom: 1px solid var(--line); overflow: hidden; }
  html[data-page="app"] .sidebar-item { width: 100%; min-width: 0; height: 36px; justify-content: center; padding: 0; }
  html[data-page="app"] .sidebar-label { display: none; }
  html[data-page="app"] .workspace-grid, body.research-mode .workspace-grid, body.home-mode .workspace-grid, body.research-results-mode .workspace-grid, body.research-results-mode.research-brain-open:not(.product-detail-open) .workspace-grid { grid-template-columns: minmax(0, 1fr); }
  html[data-page="app"] .research-rail, html[data-page="app"] .ai-brain { display: none; }
  body.research-results-mode.research-brain-open:not(.product-detail-open) .ai-brain { display: block; }
  html[data-page="app"] .center-canvas { padding: 12px 16px; }
  html[data-page="app"] .workspace-top, html[data-page="app"] .route-page-title, html[data-page="app"] .command-center-header, html[data-page="app"] #view-live-research .live-canvas-head { display: flex; flex-direction: column; align-items: flex-start; width: 100%; }
  html[data-page="app"] .route-page-title h1, html[data-page="app"] #approvedMissionTitle { width: 100%; font-size: 34px; line-height: 1.08; white-space: normal; overflow-wrap: anywhere; }
  html[data-page="app"] .route-page-title p, html[data-page="app"] #approvedMissionSubtitle { width: 100%; font-size: 16px; white-space: normal; overflow-wrap: anywhere; }
  html[data-page="app"] #commitPill { display: none; }
  html[data-page="app"] .workspace-status-row, html[data-page="app"] .command-statuses { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: start; width: 100%; gap: 8px; margin-left: 0; }
  html[data-page="app"] .workspace-status-row .pill, html[data-page="app"] .command-status { width: auto; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
  html[data-page="app"] .workflow-steps { grid-template-columns: minmax(0, 1fr); width: 100%; overflow: visible; }
  html[data-page="app"] .workflow-steps:has(li.active) li:not(.active) { display: none; }
  html[data-page="app"] .workflow-steps li, html[data-page="app"] .workflow-steps li button, html[data-page="app"] .workflow-steps li button * { width: 100%; min-width: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
  html[data-page="app"] .workflow-steps li button strong, html[data-page="app"] .workflow-steps li button b, html[data-page="app"] .workflow-steps li button em, html[data-page="app"] .workflow-steps li button span { display: inline; width: auto; }
  html[data-page="app"] .store-summary-row, html[data-page="app"] .workspace-metric-grid, html[data-page="app"] .command-action-grid, html[data-page="app"] .today-operating-list, html[data-page="app"] .workspace-section-grid, html[data-page="app"] .workspace-lane-grid, html[data-page="app"] .research-result-grid, html[data-page="app"] .mission-card-grid, html[data-page="app"] .workspace-placeholder-grid, html[data-page="app"] .module-progress-grid, html[data-page="app"] .launch-check-grid, html[data-page="app"] .template-grid, html[data-page="app"] .live-canvas-grid, html[data-page="app"] .pipeline-row, html[data-page="app"] .pipeline-flow, html[data-page="app"] .roadmap-track, html[data-page="app"] .opportunity-card-grid, html[data-page="app"] .reference-action-row, html[data-page="app"] .reference-lightbox-body, html[data-page="app"] .drawer-actions, html[data-page="app"] .compare-grid { grid-template-columns: minmax(0, 1fr); width: 100%; }
  html[data-page="app"] .command-action-grid button { width: 100%; min-height: 104px; padding: 14px; border-radius: 20px; }
  html[data-page="app"] .today-operating-list article, html[data-page="app"] .workspace-section-card, html[data-page="app"] .workspace-lane { width: 100%; min-width: 0; }
  html[data-page="app"] #view-live-research .live-canvas-head h2 { width: 100%; font-size: 28px; line-height: 1.12; white-space: normal; overflow-wrap: anywhere; }
  html[data-page="app"] #view-live-research .live-research-form { display: grid; grid-template-columns: minmax(0, 1fr); width: 100%; }
  html[data-page="app"] #view-live-research .live-research-form > * { width: 100%; min-width: 0; }
  html[data-page="app"] #view-live-research .research-brain-toggle { width: 100%; white-space: normal; }
  html[data-page="app"] #view-live-research .live-ref-actions { padding: 0 14px 14px; }
  html[data-page="app"] .research-results-modal { padding: 0; }
  html[data-page="app"] .research-results-card { min-height: 100vh; max-height: 100vh; border-radius: 0; padding: 18px; }
  html[data-page="app"] #liveReferenceDrawer { inset: 0; width: 100%; max-width: 100%; border-radius: 0; }
}

/* ============================================================
   ACOPES DESIGN SYSTEM — Stage 2 Foundation
   Baseline contract: DESIGN.md
   Scope: visual tokens and shared primitives only.
   Shell layout and page composition remain unchanged until Stage 3.
   ============================================================ */

:root {
  color-scheme: light;

  --ac-bg: #F5F4EF;
  --ac-bg-subtle: #F5F4EF;
  --ac-surface: #FFFFFF;
  --ac-surface-strong: #ffffff;
  --ac-surface-muted: #edf2f1;

  --ac-text: #132A2D;
  --ac-text-secondary: #5D6B6D;
  --ac-text-muted: #71817f;
  /* Was #ded4c8, barely distinguishable from --ac-surface/#fffdf9 -
     cards read as borderless. A real step darker, but still lighter
     than --ac-border-strong (used for hover/focus emphasis in ~9
     places) so that escalation is still visible on hover. */
  --ac-border: #dce5e3;
  --ac-border-strong: #bcd7d2;

  --ac-primary: #007C78;
  --ac-primary-hover: #006965;
  --ac-primary-active: #005854;
  --ac-primary-soft: #edf8f6;
  --ac-on-primary: #ffffff;

  --ac-info: #007C78;
  --ac-info-soft: #edf8f6;
  --ac-success: #15803D;
  --ac-success-soft: #eaf6ee;
  --ac-warning: #B45309;
  --ac-warning-soft: #fff4dc;
  --ac-warm-bg: #fff8e8;
  --ac-warm-text: #B45309;
  --ac-warm-border: #E6A84A;
  --ac-loading-base: #edf2f1;
  --ac-loading-highlight: #F5F4EF;
  --ac-loading-title: #132A2D;
  --ac-danger: #C2413A;
  --ac-danger-soft: #fff0ee;
  --ac-focus: #35BFAE;
  --ac-overlay: rgba(11, 47, 51, 0.45);

  --ac-space-1: 4px;
  --ac-space-2: 8px;
  --ac-space-3: 12px;
  --ac-space-4: 16px;
  --ac-space-5: 20px;
  --ac-space-6: 24px;
  --ac-space-7: 28px;
  --ac-space-8: 32px;
  --ac-space-10: 40px;
  --ac-space-12: 48px;

  --ac-radius-control: 10px;
  --ac-radius-control-wide: 11px;
  --ac-radius-card-sm: 12px;
  --ac-radius-card: 16px;
  --ac-radius-panel: 20px;
  --ac-radius-hero: 24px;
  --ac-radius-pill: 999px;

  /* Was a generic near-black rgba(38,34,30,...) at very low opacity -
     matches this file's own --ac-shadow-glow, which already uses this
     app's real brown (rgba(61,33,14,...)), so cards now match the one
     shadow color the design already committed to elsewhere. */
  --ac-shadow-card: 0 1px 2px rgba(61, 33, 14, 0.06), 0 4px 16px rgba(61, 33, 14, 0.08);
  --ac-shadow-card-hover: 0 3px 8px rgba(61, 33, 14, 0.10), 0 8px 24px rgba(61, 33, 14, 0.14);
  --ac-shadow-modal: 0 24px 70px rgba(38, 34, 30, 0.2);
  --ac-shadow-glow: 0 10px 28px rgba(61, 33, 14, 0.24);
  --ac-font-eyebrow: 12px;
  --ac-font-display: "Poppins", sans-serif;
  /* Same real stack as tokens.css's --font-mono - that file is never
     loaded on the authenticated app pages (index.html only loads this
     stylesheet), so --font-mono itself resolves to nothing here; this
     is the same value, named for this file's own --ac-* convention. */
  --ac-font-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", monospace;

  --fs-hero: clamp(30px, 3.4vw, 40px);
  --fs-section: clamp(19px, 2vw, 22px);
  --fs-body: 14px;
  --space-1: 8px;
  --space-2: 12px;
  --space-3: 16px;
  --space-4: 22px;
  --space-5: 30px;

  /* Compatibility aliases for the current workspace. */
  --ink-900: var(--ac-text);
  --ink-700: var(--ac-text-secondary);
  --ink-600: var(--ac-text-secondary);
  --ink-500: var(--ac-text-muted);
  --line: var(--ac-border);
  --surface: var(--ac-surface);
  --surface-soft: var(--ac-bg-subtle);
  --surface-muted: var(--ac-surface-muted);
  --blue: var(--ac-primary);
  --blue-soft: var(--ac-primary-soft);
  --green: var(--ac-success);
  --green-soft: var(--ac-success-soft);
  --shadow: var(--ac-shadow-card);
  --shadow-hover: var(--ac-shadow-card-hover);
  --radius-sm: var(--ac-radius-control);
  --radius-md: var(--ac-radius-card-sm);
  --radius-lg: var(--ac-radius-card);
}

html[data-page="app"] body {
  font-family: "Poppins", sans-serif;
  color: var(--ac-text);
  background: var(--ac-bg);
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

html[data-page="app"] .acopes-os-shell,
html[data-page="app"] .center-canvas,
html[data-page="app"] body.home-mode .center-canvas,
html[data-page="app"] #view-live-research.active {
  background: var(--ac-bg);
}

html[data-page="app"] h1,
html[data-page="app"] h2,
html[data-page="app"] h3,
html[data-page="app"] h4 {
  color: var(--ac-text);
  letter-spacing: -0.018em;
}

html[data-page="app"] .route-page-title h1 {
  font-family: var(--ac-font-display);
  font-size: clamp(28px, 3vw, 32px);
  font-weight: 700;
  line-height: 1.15;
}

html[data-page="app"] :is(.live-canvas-head, .workspace-page-head) > h2 {
  font-family: var(--ac-font-display);
}

html[data-page="app"] .route-page-title p,
html[data-page="app"] .meta {
  color: var(--ac-text-muted);
}

html[data-page="app"] .skeleton-card h3,
html[data-page="app"] .ai-brain .brain-head h2 {
  color: var(--ac-loading-title);
}

html[data-page="app"] .os-header {
  border-color: var(--ac-border);
  background: rgba(255, 253, 249, 0.94);
  box-shadow: 0 1px 0 rgba(98, 91, 83, 0.04);
}

html[data-page="app"] .os-sidebar {
  border-color: var(--ac-border);
  background: var(--ac-surface);
}

html[data-page="app"] .logo-mark {
  background: var(--ac-primary);
  box-shadow: 0 5px 14px rgba(61, 33, 14, 0.2);
}

html[data-page="app"] .profile-pill {
  background: var(--ac-text);
}

html[data-page="app"] input,
html[data-page="app"] textarea,
html[data-page="app"] select {
  border-color: var(--ac-border);
  background: var(--ac-surface-strong);
  color: var(--ac-text);
}

html[data-page="app"] .floating-input:focus-within,
html[data-page="app"] input:focus,
html[data-page="app"] textarea:focus,
html[data-page="app"] select:focus {
  border-color: var(--ac-focus);
  box-shadow: 0 0 0 3px rgba(138, 79, 33, 0.18);
  outline: none;
}

html[data-page="app"] input::placeholder,
html[data-page="app"] textarea::placeholder {
  color: var(--ac-text-muted);
  opacity: 0.82;
}

html[data-page="app"] kbd {
  border-color: var(--ac-border);
  background: var(--ac-surface-muted);
  color: var(--ac-text-muted);
}

html[data-page="app"] .sidebar-item {
  color: var(--ac-text-secondary);
}

html[data-page="app"] .sidebar-item:hover {
  border-color: var(--ac-border);
  background: var(--ac-primary-soft);
  color: var(--ac-primary-hover);
}

html[data-page="app"] .sidebar-item.active {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
  box-shadow: inset 3px 0 0 var(--ac-primary);
}

html[data-page="app"] .header-btn,
html[data-page="app"] .icon-btn,
html[data-page="app"] .icon-circle,
html[data-page="app"] .secondary-btn,
html[data-page="app"] .secondary,
html[data-page="app"] .copy-btn,
html[data-page="app"] .modal-actions .secondary-btn {
  border-color: var(--ac-border);
  background: var(--ac-surface);
  color: var(--ac-text-secondary);
}

html[data-page="app"] .header-btn:hover,
html[data-page="app"] .icon-btn:hover,
html[data-page="app"] .icon-circle:hover,
html[data-page="app"] .secondary-btn:hover,
html[data-page="app"] .secondary:hover,
html[data-page="app"] .copy-btn:hover {
  border-color: var(--ac-border-strong);
  background: var(--ac-bg-subtle);
  color: var(--ac-text);
}

html[data-page="app"] .primary-btn,
html[data-page="app"] button[type="submit"],
html[data-page="app"] .today-operating-list button,
html[data-page="app"] #liveReferenceDrawer .drawer-actions button {
  border-color: var(--ac-primary);
  background: var(--ac-primary);
  color: var(--ac-on-primary);
  box-shadow: 0 5px 14px rgba(61, 33, 14, 0.16);
}

html[data-page="app"] .primary-btn:hover,
html[data-page="app"] button[type="submit"]:hover,
html[data-page="app"] .today-operating-list button:hover,
html[data-page="app"] #liveReferenceDrawer .drawer-actions button:hover {
  border-color: var(--ac-primary-hover);
  background: var(--ac-primary-hover);
  color: var(--ac-on-primary);
}

html[data-page="app"] .primary-btn:active,
html[data-page="app"] button[type="submit"]:active {
  border-color: var(--ac-primary-active);
  background: var(--ac-primary-active);
}

html[data-page="app"] button:disabled,
html[data-page="app"] input:disabled,
html[data-page="app"] textarea:disabled,
html[data-page="app"] select:disabled {
  cursor: not-allowed;
  opacity: 0.56;
  box-shadow: none;
}

html[data-page="app"] :where(
  button,
  a,
  input,
  textarea,
  select,
  [tabindex]:not([tabindex="-1"])
):focus-visible {
  outline: 3px solid rgba(138, 79, 33, 0.42);
  outline-offset: 2px;
}

html[data-page="app"] :where(
  .card,
  .module-block,
  .live-canvas-shell,
  .pipeline-shell,
  .production-board,
  .launch-checklist-shell,
  .ai-note-card,
  .brain-notes,
  .live-activity-panel,
  .workspace-section-card,
  .workspace-lane,
  .command-center-header,
  .command-work-section,
  .today-operating-section,
  .store-summary-row article,
  .store-summary-row button,
  .today-operating-list article,
  .live-flow-section,
  .v3-modal-card
) {
  border-color: var(--ac-border);
  background: var(--ac-surface);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .command-action-grid button {
  border-color: var(--ac-border);
  background: var(--ac-bg-subtle);
  color: var(--ac-text);
  box-shadow: none;
}

html[data-page="app"] .command-action-grid button i {
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

html[data-page="app"] .command-action-grid button b,
html[data-page="app"] .analyst-listing-link {
  color: var(--ac-primary);
}

html[data-page="app"] .command-action-grid button:hover,
html[data-page="app"] .command-action-grid button:focus-visible {
  border-color: var(--ac-primary);
  background: var(--ac-surface-strong);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, 0.12), var(--ac-shadow-card-hover);
}

html[data-page="app"] .pill,
html[data-page="app"] .command-status,
html[data-page="app"] .live-badge,
html[data-page="app"] .kpi-chip,
html[data-page="app"] .market-scan-tag {
  border-color: var(--ac-border);
  background: var(--ac-bg-subtle);
  color: var(--ac-text-secondary);
}

html[data-page="app"] .thinking-pill,
html[data-page="app"] #view-overview .workflow-step-pill.active {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

html[data-page="app"] .workflow-steps li.active button {
  border-color: var(--ac-primary);
  background: var(--ac-primary);
  color: var(--ac-bg);
  box-shadow: 0 10px 24px rgba(61, 33, 14, 0.18);
}

html[data-page="app"] .workflow-steps li.active button :is(em, span, small, b) {
  color: inherit;
}

html[data-page="app"] .connection-status.connected,
html[data-page="app"] .command-status.connected,
html[data-page="app"] .command-status.safe {
  border-color: #b9d7c5;
  background: var(--ac-success-soft);
  color: var(--ac-success);
}

html[data-page="app"] .connection-status.not-connected {
  border-color: #eed3a2;
  background: var(--ac-warning-soft);
  color: var(--ac-warning);
}

html[data-page="app"] .ai-credit-indicator {
  border-color: var(--ac-warm-border);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

html[data-page="app"] .progress-bar,
html[data-page="app"] .bar {
  background: var(--ac-surface-muted);
}

html[data-page="app"] .progress-bar span,
html[data-page="app"] .bar span {
  background: var(--ac-primary);
}

html[data-page="app"] .message.success {
  border-color: #b9d7c5;
  background: var(--ac-success-soft);
  color: var(--ac-success);
}

html[data-page="app"] .message.error {
  border-color: #efb7b1;
  background: var(--ac-danger-soft);
  color: var(--ac-danger);
}

html[data-page="app"] .v3-modal {
  background: var(--ac-overlay);
}

html[data-page="app"] .v3-modal-card {
  border-radius: var(--ac-radius-panel);
  box-shadow: var(--ac-shadow-modal);
}

html[data-page="app"] .live-ref-card,
html[data-page="app"] .research-results-modal .live-ref-card {
  border-color: var(--ac-border);
  background: var(--ac-surface);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .live-ref-card:hover,
html[data-page="app"] .live-ref-card:focus-within {
  border-color: #9fb8ca;
  box-shadow: var(--ac-shadow-card-hover);
}

html[data-page="app"] .live-ref-card.selected {
  border-color: var(--ac-primary);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, 0.16), var(--ac-shadow-card-hover);
}
html[data-page="app"] #view-live-research .live-ref-card,
html[data-page="app"] .research-results-modal .live-ref-card {
  border-color: var(--ac-border);
  background: var(--ac-surface);
  color: var(--ac-text);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] #view-live-research .live-ref-card:hover,
html[data-page="app"] #view-live-research .live-ref-card:focus-within,
html[data-page="app"] .research-results-modal .live-ref-card:hover,
html[data-page="app"] .research-results-modal .live-ref-card:focus-within {
  border-color: var(--ac-border-strong);
  box-shadow: var(--ac-shadow-card-hover);
}

html[data-page="app"] #view-live-research .live-ref-title,
html[data-page="app"] .research-results-modal .live-ref-title,
html[data-page="app"] #view-live-research .direction-metrics strong,
html[data-page="app"] .research-results-modal .direction-metrics strong,
html[data-page="app"] #view-live-research .marketplace-signal strong,
html[data-page="app"] .research-results-modal .marketplace-signal strong {
  color: var(--ac-text);
}

html[data-page="app"] #view-live-research .live-badge,
html[data-page="app"] .research-results-modal .live-badge {
  border-color: var(--ac-border);
  background: var(--ac-surface-muted);
  color: var(--ac-text-muted);
}

html[data-page="app"] #view-live-research .direction-metrics span,
html[data-page="app"] .research-results-modal .direction-metrics span {
  border-color: var(--ac-border);
  background: var(--ac-surface-muted);
  color: var(--ac-text-muted);
}

html[data-page="app"] #view-live-research .direction-metrics small,
html[data-page="app"] .research-results-modal .direction-metrics small,
html[data-page="app"] #view-live-research .marketplace-signal span,
html[data-page="app"] .research-results-modal .marketplace-signal span {
  color: var(--ac-text-muted);
}

html[data-page="app"] #view-live-research .marketplace-signal,
html[data-page="app"] .research-results-modal .marketplace-signal {
  border-top-color: var(--ac-border);
  color: var(--ac-text-muted);
}

html[data-page="app"] #view-live-research .live-ref-actions button,
html[data-page="app"] .research-results-modal .live-ref-actions button {
  border-color: var(--ac-primary);
  background: var(--ac-primary);
  color: var(--ac-on-primary);
}

html[data-page="app"] #view-live-research .live-ref-actions a,
html[data-page="app"] .research-results-modal .live-ref-actions a {
  border-color: var(--ac-border);
  background: var(--ac-surface);
  color: var(--ac-primary-hover);
}

html[data-page="app"] a {
  color: var(--ac-primary-hover);
  text-underline-offset: 3px;
}

html[data-page="app"] ::selection {
  background: #d9e4ec;
  color: var(--ac-text);
}

@media (prefers-reduced-motion: reduce) {
  html[data-page="app"] *,
  html[data-page="app"] *::before,
  html[data-page="app"] *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ============================================================
   ACOPES DESIGN SYSTEM — Stage 3 Shell
   Header, desktop navigation, collapsed rail, and mobile nav.
   ============================================================ */

html[data-page="app"] .acopes-os-shell {
  grid-template-rows: 64px minmax(0, 1fr);
}

html[data-page="app"] .os-header {
  height: 64px;
  padding: 0 20px;
  gap: 16px;
}

html[data-page="app"] .header-left {
  width: 212px;
  min-width: 212px;
}

html[data-page="app"] .os-logo {
  min-width: 0;
}

html[data-page="app"] .logo-mark {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border-radius: 11px;
}

html[data-page="app"] .logo-text {
  color: var(--ac-text);
  font-family: var(--ac-font-display);
  letter-spacing: 0.02em;
}

html[data-page="app"] .header-actions {
  flex: 0 0 auto;
}

html[data-page="app"] .header-btn,
html[data-page="app"] .connection-status,
html[data-page="app"] .icon-circle,
html[data-page="app"] .profile-pill {
  min-height: 38px;
}

html[data-page="app"] #commitPill {
  display: none !important;
}

html[data-page="app"] .os-main-grid {
  grid-template-columns: 232px minmax(0, 1fr);
  min-height: calc(100vh - 64px);
  transition: grid-template-columns 180ms ease;
}

html[data-page="app"] .os-sidebar {
  position: sticky;
  top: 64px;
  align-self: start;
  width: 232px;
  height: calc(100vh - 64px);
  padding: 16px 12px;
  gap: 6px;
  overflow-y: auto;
  transition: width 180ms ease, padding 180ms ease;
}

html[data-page="app"] .sidebar-item {
  width: 100%;
  min-height: 44px;
  height: 44px;
  padding: 0 12px;
  gap: 12px;
  border-radius: 12px;
  font-weight: 600;
  text-align: left;
}

html[data-page="app"] .sidebar-icon {
  display: grid;
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  place-items: center;
}

html[data-page="app"] .sidebar-icon svg {
  display: block;
  width: 20px;
  height: 20px;
}

html[data-page="app"] .sidebar-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

html[data-page="app"] .sidebar-quick-start {
  margin: 2px 0 6px;
  border: 1px solid var(--ac-border);
  border-radius: 12px;
  background: var(--ac-surface-muted);
}

html[data-page="app"] .sidebar-quick-start-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 38px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: var(--ac-text-secondary);
  cursor: pointer;
  font: inherit;
  font-size: .78rem;
  font-weight: 700;
}

html[data-page="app"] .sidebar-quick-start-toggle:focus-visible,
html[data-page="app"] .sidebar-quick-start-actions button:focus-visible { outline: 2px solid var(--ac-primary); outline-offset: -2px; }

html[data-page="app"] .sidebar-quick-start-chevron { width: 8px; height: 8px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translateY(-2px); transition: transform 160ms ease; }
html[data-page="app"] .sidebar-quick-start-toggle[aria-expanded="true"] .sidebar-quick-start-chevron { transform: rotate(225deg) translate(-2px, -2px); }
html[data-page="app"] .sidebar-quick-start-actions { display: grid; gap: 2px; padding: 0 6px 7px; }
html[data-page="app"] .sidebar-quick-start-actions[hidden] { display: none; }
html[data-page="app"] .sidebar-quick-start-actions button { display: flex; align-items: center; gap: 9px; min-height: 32px; padding: 0 7px; border: 0; border-radius: 8px; background: transparent; color: var(--ac-text-secondary); cursor: pointer; font: inherit; font-size: .76rem; text-align: left; }
html[data-page="app"] .sidebar-quick-start-actions button:hover { background: var(--ac-primary-soft); color: var(--ac-primary-hover); }
html[data-page="app"] .sidebar-quick-start-actions i { width: 16px; color: var(--ac-primary); font-style: normal; text-align: center; }

/* UX Sprint 2: single "Yeni görev başlat" launch button, then the 4
   purpose cards nested below it - .quick-start-purpose-cards buttons
   inherit .sidebar-quick-start-actions button's styling above via the
   descendant selector, no separate button rule needed. */
html[data-page="app"] #quickStartLaunchBtn { font-weight: 700; color: var(--ac-primary); }
html[data-page="app"] .quick-start-purpose-cards { display: grid; gap: 2px; margin-top: 2px; padding-top: 6px; border-top: 1px solid var(--ac-border); }
html[data-page="app"] .quick-start-purpose-cards[hidden] { display: none; }

html[data-page="app"] #factoryEntryCards[hidden],
html[data-page="app"] #factoryEntryColoringCanvas[hidden],
html[data-page="app"] #factoryEntryPhysical[hidden],
html[data-page="app"] #factoryEntryStorybookWrap[hidden] { display: none; }

html[data-page="app"] .mobile-more-trigger {
  display: none;
}

html[data-page="app"] body.nav-collapsed .os-main-grid {
  grid-template-columns: 72px minmax(0, 1fr);
}

html[data-page="app"] body.nav-collapsed .os-sidebar {
  width: 72px;
  padding-inline: 10px;
}

html[data-page="app"] body.nav-collapsed .sidebar-item {
  justify-content: center;
  padding-inline: 0;
}

html[data-page="app"] body.nav-collapsed .sidebar-label {
  display: none;
}

html[data-page="app"] body.nav-collapsed .sidebar-quick-start { display: none; }

html[data-page="app"] body.nav-collapsed .header-left {
  width: auto;
  min-width: 54px;
}

html[data-page="app"] body.nav-collapsed .os-logo {
  display: none;
}

html[data-page="app"] .mobile-more-modal {
  display: none;
}

html[data-page="app"] .mobile-more-card {
  width: min(460px, calc(100vw - 32px));
}

html[data-page="app"] .mobile-more-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

html[data-page="app"] .mobile-more-head h2 {
  margin: 0;
}

html[data-page="app"] .mobile-more-grid {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}

html[data-page="app"] .mobile-more-grid button {
  display: grid;
  gap: 3px;
  width: 100%;
  min-height: 64px;
  padding: 12px 14px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
  color: var(--ac-text);
  text-align: left;
}

html[data-page="app"] .mobile-more-grid button:hover,
html[data-page="app"] .mobile-more-grid button:focus-visible {
  border-color: var(--ac-primary);
  background: var(--ac-primary-soft);
}

html[data-page="app"] .mobile-more-grid button span {
  color: var(--ac-text-muted);
  font-size: 12px;
  font-weight: 400;
}

html[data-page="app"] .mobile-more-quick-start { display: none; }

@media (max-width: 600px) {
  html[data-page="app"] .mobile-more-quick-start { display: grid; gap: 8px; padding: 12px; border: 1px solid var(--ac-border); border-radius: 12px; background: var(--ac-surface-muted); }
  html[data-page="app"] .mobile-more-quick-start > strong { font-size: 12px; color: var(--ac-text-secondary); }
  html[data-page="app"] .mobile-more-quick-start > div { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; }
  html[data-page="app"] .mobile-more-quick-start button { display: block; min-height: 34px; padding: 6px 7px; border: 1px solid var(--ac-border); border-radius: 8px; background: var(--ac-surface); color: var(--ac-text-secondary); font: inherit; font-size: 11px; text-align: left; }
}

@media (min-width: 768px) and (max-width: 1023px) {
  html[data-page="app"] .os-header {
    padding-inline: 14px;
  }

  html[data-page="app"] .header-left {
    width: auto;
    min-width: 188px;
  }

  html[data-page="app"] .header-btn-label {
    display: none;
  }

  html[data-page="app"] #commandPaletteTrigger {
    width: 38px;
    padding: 0;
    justify-content: center;
  }

  html[data-page="app"] #commandPaletteTrigger .header-btn-icon {
    display: inline-flex;
  }

  html[data-page="app"] .os-main-grid,
  html[data-page="app"] body.nav-collapsed .os-main-grid {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  html[data-page="app"] .os-sidebar,
  html[data-page="app"] body.nav-collapsed .os-sidebar {
    width: 72px;
    padding-inline: 10px;
  }

  html[data-page="app"] .sidebar-item,
  html[data-page="app"] body.nav-collapsed .sidebar-item {
    justify-content: center;
    padding-inline: 0;
  }

  html[data-page="app"] .sidebar-label {
    display: none;
  }
}

@media (max-width: 767px) {
  html[data-page="app"] body {
    padding-bottom: calc(68px + env(safe-area-inset-bottom));
  }

  html[data-page="app"] .acopes-os-shell {
    display: block;
    min-height: 100vh;
  }

  html[data-page="app"] .os-header {
    position: sticky;
    top: 0;
    z-index: 40;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "brand actions"
      "store credits"
      "palette palette";
    width: 100%;
    height: auto;
    min-height: 64px;
    padding: 10px 16px 12px;
    gap: 8px 10px;
  }

  html[data-page="app"] .header-left {
    grid-area: brand;
    width: auto;
    min-width: 0;
  }

  html[data-page="app"] .icon-btn {
    display: none;
  }

  html[data-page="app"] .logo-text {
    font-size: 14px;
  }

  html[data-page="app"] .header-actions {
    display: contents;
  }

  html[data-page="app"] .header-actions .icon-circle {
    display: none;
  }

  html[data-page="app"] .profile-pill {
    grid-area: actions;
    width: 38px;
    min-width: 38px;
    justify-self: end;
  }

  html[data-page="app"] .connection-status {
    grid-area: store;
    width: 100%;
    min-width: 0;
    justify-content: flex-start;
    overflow: hidden;
  }

  html[data-page="app"] #topConnectionText {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  html[data-page="app"] .ai-credit-indicator {
    grid-area: credits;
    width: auto;
    min-width: 104px;
    justify-self: end;
  }

  html[data-page="app"] #commandPaletteTrigger {
    grid-area: palette;
    width: 100%;
    max-width: none;
    height: 42px;
    justify-content: center;
  }

  html[data-page="app"] .os-main-grid,
  html[data-page="app"] body.nav-collapsed .os-main-grid {
    display: block;
    min-height: 0;
  }

  html[data-page="app"] .os-sidebar,
  html[data-page="app"] body.nav-collapsed .os-sidebar {
    position: fixed;
    inset: auto 0 0;
    z-index: 50;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    width: 100%;
    height: calc(64px + env(safe-area-inset-bottom));
    padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
    gap: 2px;
    overflow: visible;
    border: 0;
    border-top: 1px solid var(--ac-border);
    background: rgba(255, 253, 249, 0.97);
    box-shadow: 0 -8px 24px rgba(38, 34, 30, 0.08);
    backdrop-filter: blur(14px);
  }

  html[data-page="app"] .os-sidebar .sidebar-item {
    display: none;
  }

  html[data-page="app"] .os-sidebar .sidebar-quick-start { display: none; }

  html[data-page="app"] .os-sidebar .sidebar-item:nth-child(1),
  html[data-page="app"] .os-sidebar .sidebar-item:nth-child(2),
  html[data-page="app"] .os-sidebar .sidebar-item:nth-child(4),
  html[data-page="app"] .os-sidebar .sidebar-item:nth-child(6),
  html[data-page="app"] .os-sidebar .mobile-more-trigger {
    display: flex;
  }

  html[data-page="app"] .os-sidebar .sidebar-item,
  html[data-page="app"] body.nav-collapsed .os-sidebar .sidebar-item {
    flex-direction: column;
    justify-content: center;
    width: 100%;
    min-width: 0;
    height: 52px;
    min-height: 52px;
    padding: 4px 2px;
    gap: 2px;
    border: 0;
    border-radius: 10px;
    box-shadow: none;
  }

  html[data-page="app"] .os-sidebar .sidebar-item.active {
    background: var(--ac-warm-bg);
    color: var(--ac-warm-text);
    box-shadow: none;
  }

  html[data-page="app"] .os-sidebar .sidebar-icon {
    flex-basis: 21px;
    width: 21px;
    height: 21px;
  }

  html[data-page="app"] .os-sidebar .sidebar-icon svg {
    width: 19px;
    height: 19px;
  }

  html[data-page="app"] .os-sidebar .sidebar-label,
  html[data-page="app"] body.nav-collapsed .os-sidebar .sidebar-label {
    display: block;
    width: 100%;
    overflow: hidden;
    font-size: 9px;
    line-height: 1.15;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  html[data-page="app"] .mobile-more-modal {
    display: none;
  }

  html[data-page="app"] .mobile-more-modal.open {
    display: flex;
  }

  html[data-page="app"] .mobile-more-card {
    position: absolute;
    inset: auto 12px calc(76px + env(safe-area-inset-bottom));
    width: auto;
    max-height: min(70vh, 560px);
    margin: 0;
    overflow-y: auto;
    padding: 20px;
    border-radius: var(--ac-radius-panel);
  }
}

/* ACOPES Stage 3 mobile legacy override guard.
   Removes the previous eight-column mobile rail behavior. */
@media (max-width: 600px) {
  html[data-page="app"] .os-sidebar,
  html[data-page="app"] body.nav-collapsed .os-sidebar {
    position: fixed !important;
    inset: auto 0 0 !important;
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    grid-auto-flow: row !important;
    width: 100% !important;
    max-width: 100% !important;
    height: calc(64px + env(safe-area-inset-bottom)) !important;
    padding: 6px 8px calc(6px + env(safe-area-inset-bottom)) !important;
    gap: 2px !important;
    overflow: visible !important;
  }

  html[data-page="app"] .os-sidebar .sidebar-item {
    display: none !important;
  }

  html[data-page="app"] .os-sidebar .sidebar-item:nth-child(1),
  html[data-page="app"] .os-sidebar .sidebar-item:nth-child(2),
  html[data-page="app"] .os-sidebar .sidebar-item:nth-child(4),
  html[data-page="app"] .os-sidebar .sidebar-item:nth-child(6),
  html[data-page="app"] .os-sidebar .mobile-more-trigger {
    display: flex !important;
  }

  html[data-page="app"] .os-sidebar .sidebar-item,
  html[data-page="app"] body.nav-collapsed .os-sidebar .sidebar-item {
    width: 100% !important;
    max-width: 100% !important;
    height: 52px !important;
    min-height: 52px !important;
    padding: 4px 2px !important;
  }

  html[data-page="app"] .os-sidebar .sidebar-label,
  html[data-page="app"] body.nav-collapsed .os-sidebar .sidebar-label {
    display: block !important;
    width: 100% !important;
  }
}

/* ============================================================
   ACOPES DESIGN SYSTEM — Stage 4 Core Workspaces
   Home, Research, Product Factory, and Draft Queue.
   ============================================================ */

html[data-page="app"] .center-canvas {
  width: 100%;
  padding: 24px;
}

html[data-page="app"] .center-canvas > .workspace-top,
html[data-page="app"] .center-canvas > .workflow-strip,
html[data-page="app"] .center-canvas > .view {
  width: min(100%, 1440px);
  margin-inline: auto;
}

html[data-page="app"] .workspace-top {
  align-items: flex-start;
  margin-bottom: 20px;
}

html[data-page="app"] .workspace-status-row {
  gap: 8px;
}

/* Home / Store Command Center */

html[data-page="app"] .store-command-center {
  gap: 20px;
  padding: 0;
}

html[data-page="app"] .command-center-header {
  align-items: center;
  padding: 18px 20px;
  border-radius: var(--ac-radius-card);
  box-shadow: none;
}

html[data-page="app"] .command-shop-name {
  color: var(--ac-text);
  font-size: 16px;
  font-weight: 700;
}

html[data-page="app"] .store-summary-row {
  gap: 14px;
}

html[data-page="app"] .store-summary-row article,
html[data-page="app"] .store-summary-row button {
  min-height: 128px;
  padding: 18px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
  color: var(--ac-text);
  text-align: left;
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .store-summary-row button {
  cursor: pointer;
}

html[data-page="app"] .store-summary-row button:hover,
html[data-page="app"] .store-summary-row button:focus-visible {
  border-color: #9fb8ca;
  box-shadow: var(--ac-shadow-card-hover);
  transform: translateY(-2px);
}

html[data-page="app"] .store-summary-row span {
  color: var(--ac-text-muted);
  font-size: 11px;
}

html[data-page="app"] .store-summary-row strong {
  color: var(--ac-text);
  font-size: 28px;
  line-height: 1.1;
}

html[data-page="app"] .store-summary-row small {
  color: var(--ac-primary-hover);
  font-weight: 650;
}

html[data-page="app"] .command-work-section,
html[data-page="app"] .today-operating-section {
  padding: 20px;
  border-radius: var(--ac-radius-card);
  box-shadow: none;
}

html[data-page="app"] .section-headline h3 {
  font-size: 18px;
}

html[data-page="app"] .command-action-grid {
  gap: 14px;
}

html[data-page="app"] .command-action-grid button {
  min-height: 156px;
  padding: 18px;
  border-radius: var(--ac-radius-card);
}

html[data-page="app"] .command-action-grid button i {
  width: 34px;
  height: 34px;
  border-radius: 10px;
}

html[data-page="app"] .command-action-grid button span {
  font-size: 16px;
}

html[data-page="app"] .command-action-grid button b {
  align-self: end;
  margin-top: 6px;
}

html[data-page="app"] .today-operating-list {
  gap: 12px;
}

html[data-page="app"] .today-operating-list article {
  min-height: 138px;
  padding: 16px;
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .today-operating-list article:first-child {
  border-color: #9fb8ca;
  background: var(--ac-primary-soft);
}

html[data-page="app"] .today-operating-list strong {
  color: var(--ac-text);
  font-size: 14px;
}

html[data-page="app"] .today-operating-list p {
  color: var(--ac-text-secondary);
  font-size: 12px;
}

/* Research */

html[data-page="app"] #view-live-research.active {
  display: block;
  padding: 0;
  border-radius: 0;
  background: transparent;
}

html[data-page="app"] #view-live-research .live-canvas-shell {
  display: grid;
  gap: 18px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

html[data-page="app"] #view-live-research .live-canvas-head {
  padding: 20px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
}

html[data-page="app"] #view-live-research .live-canvas-head h2 {
  color: var(--ac-text);
  font-size: 24px;
}

html[data-page="app"] #view-live-research .live-canvas-head > p {
  color: var(--ac-text-secondary);
}

html[data-page="app"] #view-live-research .live-research-form {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] #view-live-research .floating-input {
  min-height: 48px;
  border-radius: var(--ac-radius-control);
  background: var(--ac-surface-strong);
}

html[data-page="app"] #view-live-research .live-research-form button[type="submit"] {
  min-width: 150px;
  min-height: 48px;
  border-radius: var(--ac-radius-control);
}

html[data-page="app"] #view-live-research .live-canvas-flow {
  gap: 18px;
}

html[data-page="app"] #view-live-research .live-flow-section {
  padding: 20px;
  border-radius: var(--ac-radius-card);
  box-shadow: none;
}

html[data-page="app"] #view-live-research .market-scan-provenance {
  border: 1px solid #b9d7c5;
  border-radius: var(--ac-radius-pill);
  background: var(--ac-success-soft);
  color: var(--ac-success);
}

html[data-page="app"] #view-live-research .research-result-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

html[data-page="app"] #view-live-research .live-ref-card,
html[data-page="app"] .research-results-modal .live-ref-card {
  border-radius: var(--ac-radius-card);
}

html[data-page="app"] #view-live-research .live-ref-media,
html[data-page="app"] .research-results-modal .live-ref-media {
  height: 190px;
  min-height: 190px;
  background: var(--ac-surface-muted);
}

html[data-page="app"] #view-live-research .direction-metrics span {
  background: var(--ac-bg-subtle);
}

html[data-page="app"] #view-live-research .live-ref-actions {
  position: static;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: auto;
  opacity: 1;
  transform: none;
}

html[data-page="app"] #view-live-research .live-ref-actions button,
html[data-page="app"] #view-live-research .live-ref-actions a {
  min-height: 36px;
  border-color: var(--ac-border);
  border-radius: var(--ac-radius-control);
  background: var(--ac-surface);
  color: var(--ac-primary-hover);
  box-shadow: none;
}

html[data-page="app"] #view-live-research .live-ref-actions button:first-child {
  border-color: var(--ac-primary);
  background: var(--ac-primary);
  color: var(--ac-on-primary);
}

html[data-page="app"] #researchResultsModal .modal-close {
  position: sticky;
  top: 0;
  z-index: 6;
  display: grid;
  place-items: center;
  float: none;
  margin-left: auto;
  margin-bottom: 10px;
  background: var(--ac-surface);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .research-results-modal .live-ref-card {
  border-color: var(--ac-border);
  background: var(--ac-surface);
  color: var(--ac-text);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .research-results-modal .live-ref-card:hover,
html[data-page="app"] .research-results-modal .live-ref-card:focus-within {
  border-color: var(--ac-border-strong);
  box-shadow: var(--ac-shadow-card-hover);
}

html[data-page="app"] .research-results-modal .live-ref-meta {
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .research-results-modal .live-ref-title,
html[data-page="app"] .research-results-modal .direction-metrics strong,
html[data-page="app"] .research-results-modal .marketplace-signal strong {
  color: var(--ac-text);
}

html[data-page="app"] .research-results-modal .live-badge,
html[data-page="app"] .research-results-modal .direction-metrics span {
  border-color: var(--ac-border);
  background: var(--ac-surface-muted);
  color: var(--ac-text-muted);
}

html[data-page="app"] .research-results-modal .direction-metrics small,
html[data-page="app"] .research-results-modal .marketplace-signal,
html[data-page="app"] .research-results-modal .marketplace-signal span {
  color: var(--ac-text-muted);
}

html[data-page="app"] .research-results-modal .marketplace-signal {
  border-top-color: var(--ac-border);
}

html[data-page="app"] .research-results-modal .live-ref-actions button,
html[data-page="app"] .research-results-modal .live-ref-actions a {
  min-height: 36px;
  border-color: var(--ac-border);
  border-radius: var(--ac-radius-control);
  background: var(--ac-surface);
  color: var(--ac-primary-hover);
  box-shadow: none;
}

html[data-page="app"] .research-results-modal .live-ref-actions button:first-child {
  border-color: var(--ac-primary);
  background: var(--ac-primary);
  color: var(--ac-on-primary);
}

html[data-page="app"] #liveReferenceDrawer {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
}

html[data-page="app"] #liveReferenceDrawer .drawer-actions {
  display: grid;
  gap: 8px;
}

/* Product Factory */

html[data-page="app"] #view-product-factory .production-board {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

html[data-page="app"] .product-factory-workspace {
  display: grid;
  gap: 18px;
}

html[data-page="app"] .factory-workspace-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 20px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
}

html[data-page="app"] .factory-workspace-head h3 {
  margin: 4px 0 0;
  font-size: 22px;
}

html[data-page="app"] .factory-trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

html[data-page="app"] .factory-trust-row span {
  padding: 6px 9px;
  border: 1px solid #b9d7c5;
  border-radius: var(--ac-radius-pill);
  background: var(--ac-success-soft);
  color: var(--ac-success);
  font-size: 10px;
  font-weight: 700;
}

html[data-page="app"] .factory-pipeline-card {
  padding: 20px;
  border-radius: var(--ac-radius-card);
}

html[data-page="app"] .factory-ready-banner {
  padding: 16px;
  border: 1px solid #b9d7c5;
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-success-soft);
}

html[data-page="app"] .factory-pipeline-steps {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
  margin-block: 18px;
}

html[data-page="app"] .factory-pipeline-steps article {
  min-height: 118px;
  padding: 14px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .factory-pipeline-steps article.complete,
html[data-page="app"] .factory-pipeline-steps article.completed,
html[data-page="app"] .factory-pipeline-steps article.ready {
  border-color: #b9d7c5;
  background: var(--ac-success-soft);
}

html[data-page="app"] .factory-output-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

html[data-page="app"] .factory-output-grid > article {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
}

html[data-page="app"] .factory-output-grid > article:last-child {
  grid-column: 1 / -1;
  border-color: #9fb8ca;
  background: var(--ac-primary-soft);
}

/* Draft Queue */

html[data-page="app"] .draft-workspace-shell {
  display: grid;
  gap: 18px;
}

html[data-page="app"] .draft-workspace-shell .workspace-page-head {
  padding: 20px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
}

html[data-page="app"] .draft-workspace-shell .workspace-page-head h2 {
  margin: 4px 0 6px;
  font-size: 24px;
}

html[data-page="app"] .draft-workspace-shell .workspace-page-head .meta {
  max-width: 720px;
  margin: 0;
}

.growth-advisor-section {
  margin-top: 22px;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--surface, #fff);
}

.growth-advisor-section .section-headline p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.growth-advisor-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.growth-advisor-item {
  display: grid;
  grid-template-columns: 9px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 14px 15px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-soft, #f8fafc);
}

.growth-advisor-marker {
  width: 8px;
  height: 8px;
  margin-top: 6px;
  border-radius: 999px;
  background: var(--ac-primary);
}

.growth-advisor-item p,
.growth-advisor-empty {
  margin: 0;
  color: var(--text);
  line-height: 1.5;
}

.growth-advisor-item button {
  margin-top: 8px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ac-primary);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.growth-advisor-item button:hover {
  text-decoration: underline;
}

@media (max-width: 720px) {
  .growth-advisor-section {
    padding: 16px;
  }
}

html[data-page="app"] .draft-queue-head {
  max-width: 760px;
}

html[data-page="app"] .draft-queue-simple-layout {
  display: grid;
  grid-template-columns: minmax(380px, 440px) minmax(300px, 1fr);
  gap: 16px;
  align-items: start;
}

html[data-page="app"] .draft-queue-simple-layout[hidden] { display: none; }

html[data-page="app"] .draft-flow-panel {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-bg-subtle);
  box-shadow: var(--ac-shadow-soft);
}

html[data-page="app"] .draft-flow-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--ac-border);
}

html[data-page="app"] .draft-flow-head h3 {
  margin: 0;
  color: var(--ac-text);
  font-size: 18px;
}

html[data-page="app"] .draft-flow-summary {
  /* flex-basis 100% forces this onto its own line once the multi-clause
     B1a breakdown text ("N entries / A missing info · B awaiting decision
     · ...") no longer fits the narrow Task Flow header alongside the
     title - a fixed-width single-line pill clipped it instead of
     wrapping. */
  flex: 1 1 100%;
  border-radius: 10px;
  background: var(--ac-surface-muted);
  color: #007C78;
  font-size: 11px;
  font-weight: 800;
  padding: 6px 9px;
  line-height: 1.5;
  white-space: normal;
}

html[data-page="app"] .draft-queue-history-toggle {
  flex: 0 0 auto;
  margin-left: auto;
  font-size: 11px;
  padding: 6px 10px;
  white-space: nowrap;
}

html[data-page="app"] .draft-workspace-shell .workspace-lane-grid,
html[data-page="app"] .draft-flow-grid {
  grid-template-columns: 1fr;
  gap: 10px;
}

html[data-page="app"] .draft-workspace-shell .workspace-lane {
  min-height: 0;
  max-height: min(58vh, 520px);
  overflow: auto;
  padding: 12px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
  box-shadow: none;
}

html[data-page="app"] .draft-workspace-shell .workspace-lane h3 {
  margin: 0 0 12px;
  font-size: 13px;
}

html[data-page="app"] .draft-workspace-shell .workspace-lane-count {
  font-weight: 400;
  color: var(--ac-text-secondary);
}

html[data-page="app"] .production-lane-card {
  padding: 13px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-surface);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .draft-lane-card {
  cursor: pointer;
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

html[data-page="app"] .draft-lane-card:hover,
html[data-page="app"] .draft-lane-card:focus-visible,
html[data-page="app"] .draft-lane-card.selected {
  border-color: var(--ac-primary);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, .12), var(--ac-shadow-card);
}

html[data-page="app"] .draft-lane-card:focus-visible {
  outline: none;
}

html[data-page="app"] .draft-flow-card {
  display: grid;
  gap: 5px;
  padding: 10px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .draft-flow-card strong {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-size: 12px;
  line-height: 1.25;
}

html[data-page="app"] .draft-product-type-badge {
  justify-self: start;
  border: 1px solid var(--ac-border);
  background: var(--ac-bg-subtle);
  color: var(--ac-text-secondary);
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

html[data-page="app"] .draft-flow-card small {
  font-size: 11px;
}

html[data-page="app"] .draft-flow-card.status-closed {
  opacity: 0.55;
  background: transparent;
}

html[data-page="app"] .draft-flow-card.status-closed:hover,
html[data-page="app"] .draft-flow-card.status-closed:focus-visible,
html[data-page="app"] .draft-flow-card.status-closed.selected {
  opacity: 0.85;
}

html[data-page="app"] .production-lane-card strong,
html[data-page="app"] .draft-flow-card strong {
  color: var(--ac-text);
}

html[data-page="app"] .production-lane-card small,
html[data-page="app"] .draft-flow-card small {
  color: var(--ac-text-secondary);
}

html[data-page="app"] .draft-workspace-shell .workspace-section-card {
  border-radius: var(--ac-radius-card);
}

html[data-page="app"] .draft-queue-detail-region {
  width: 100%;
  min-width: 0;
}

html[data-page="app"] .draft-queue-detail-output {
  display: grid;
  gap: 16px;
}

html[data-page="app"] .draft-queue-detail-output > .card,
html[data-page="app"] .draft-queue-detail-output .draft-detail-panel {
  padding: 18px;
  border-radius: var(--ac-radius-card);
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-panel {
  border: 1px solid var(--ac-border);
  background: var(--ac-surface);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-panel-head {
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--ac-border);
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  align-items: start;
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-card {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  min-height: 0;
  max-height: min(50vh, 400px);
  overflow: hidden;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 13px 14px;
  border-bottom: 1px solid var(--ac-border);
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-card-head h4 {
  margin: 0;
  color: var(--ac-text);
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-card-head span {
  flex: 0 0 auto;
  border-radius: 6px;
  background: #fffdf9;
  color: #007C78;
  font-family: var(--ac-font-mono);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.03em;
  padding: 6px 10px;
  text-transform: uppercase;
}

/* Was the pale --ac-success-soft/--ac-warning-soft tints (#eaf6ee /
   #fff4dc) - real colors, but low-saturation enough to read as washed
   out next to 5-6 of these in a row. A stronger tinted background
   (still not the solid --ac-success/--ac-warning fill, which would be
   too loud repeated this often) plus a matching border reads as a real
   status label at a glance, closer to Wiro's technical-tag look. */
html[data-page="app"] .draft-queue-detail-output .draft-detail-status.ready {
  background: rgba(36, 122, 75, 0.16);
  border: 1px solid rgba(36, 122, 75, 0.35);
  color: var(--ac-success);
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-status.missing {
  background: rgba(161, 92, 0, 0.16);
  border: 1px solid rgba(161, 92, 0, 0.35);
  color: var(--ac-warning);
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-toggle {
  appearance: none;
  justify-self: start;
  border: none;
  background: none;
  color: var(--ac-primary);
  font-size: 12px;
  font-weight: 700;
  padding: 8px 14px 0;
  cursor: pointer;
  text-align: left;
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-toggle:hover {
  text-decoration: underline;
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-card-body {
  min-height: 0;
  overflow: auto;
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 14px;
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-card-body[hidden] {
  display: none;
}

html[data-page="app"] .draft-queue-detail-output .button-row {
  gap: 8px;
}

html[data-page="app"] .draft-queue-detail-output .draft-content-actions {
  display: grid;
  gap: 12px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--ac-border);
}

html[data-page="app"] .draft-queue-detail-output .draft-decision-actions {
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--ac-border);
}

/* UX Sprint 1, P0 #2: single status banner + a readiness-driven primary
   CTA, replacing 3-4 always-equal-weight decision buttons - see
   draftQueueReadinessBannerHtml()/draftQueueDetailPanelHtml() in app.js.
   Same --ac-* tokens the rest of this panel already uses. */
html[data-page="app"] .draft-queue-detail-output .draft-readiness-banner {
  padding: 12px 14px;
  border-radius: var(--ac-radius-card-sm);
  font-size: 13px;
  font-weight: 650;
}
html[data-page="app"] .draft-queue-detail-output .draft-readiness-banner.ready {
  background: var(--ac-success-soft);
  color: var(--ac-success);
}
html[data-page="app"] .draft-queue-detail-output .draft-readiness-banner.missing {
  display: grid;
  gap: 8px;
  background: var(--ac-danger-soft);
  color: var(--ac-danger);
}
html[data-page="app"] .draft-queue-detail-output .draft-readiness-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
html[data-page="app"] .draft-queue-detail-output .draft-readiness-chip {
  padding: 5px 10px;
  border: 1px solid currentColor;
  border-radius: 999px;
  background: transparent;
  color: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
html[data-page="app"] .draft-queue-detail-output .draft-readiness-chip.static {
  cursor: default;
  opacity: .8;
}
html[data-page="app"] .draft-queue-detail-output .draft-readiness-chip:not(.static):hover {
  background: currentColor;
  color: var(--ac-bg);
}
html[data-page="app"] .draft-queue-detail-output .draft-decision-primary-row .primary-btn {
  min-width: 200px;
}
html[data-page="app"] .draft-queue-detail-output .draft-decision-more summary {
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  color: var(--ac-text-muted);
}
html[data-page="app"] .draft-queue-detail-output .draft-decision-more[open] {
  padding: 10px 12px;
}
html[data-page="app"] .draft-queue-detail-output .draft-decision-more .button-row {
  margin-top: 10px;
}

html[data-page="app"] .draft-queue-detail-output .draft-etsy-status {
  display: grid;
  gap: 8px;
  margin: -4px 0 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--ac-border);
}

html[data-page="app"] .draft-queue-detail-output .draft-etsy-status .draft-detail-status {
  justify-self: start;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  padding: 6px 9px;
  text-transform: uppercase;
}

html[data-page="app"] .draft-queue-detail-output .draft-decision-actions .draft-status-btn[data-status="needs_edit"] {
  border-color: var(--ac-primary);
  color: var(--ac-primary);
}

html[data-page="app"] .draft-queue-detail-output .draft-decision-actions .draft-status-btn[data-status="rejected"] {
  justify-self: start;
  min-height: 34px;
  font-size: 12px;
}

html[data-page="app"] .draft-queue-detail-output .draft-status-btn[data-status="approved"] {
  border-color: var(--ac-primary);
  background: var(--ac-primary);
  color: var(--ac-on-primary);
}

html[data-page="app"] .draft-queue-detail-output .draft-status-btn[data-status="rejected"] {
  border-color: #efb7b1;
  background: var(--ac-danger-soft);
  color: var(--ac-danger);
}

html[data-page="app"] .draft-queue-detail-output details {
  border-color: var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .draft-queue-detail-output .draft-details {
  margin-top: 12px;
}

html[data-page="app"] .draft-queue-detail-output .draft-details-shell {
  display: grid;
  gap: 10px;
  max-height: 460px;
  overflow: auto;
  padding: 10px;
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-section {
  background: var(--ac-surface);
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-section-body {
  display: grid;
  gap: 10px;
  padding: 10px 12px 12px;
}

html[data-page="app"] .draft-queue-detail-output .draft-detail-scroll {
  max-height: 180px;
  overflow: auto;
  padding-right: 4px;
}

html[data-page="app"] .draft-queue-detail-output .draft-tag-analysis {
  display: grid;
  gap: 4px;
  min-width: 0;
  margin-top: 2px;
  padding-top: 10px;
  border-top: 1px solid var(--ac-border);
}

html[data-page="app"] .draft-queue-detail-output .draft-tag-analysis-title,
html[data-page="app"] .draft-queue-detail-output .draft-tag-analysis-score,
html[data-page="app"] .draft-queue-detail-output .draft-tag-analysis-notice {
  margin: 0;
  overflow-wrap: anywhere;
}

html[data-page="app"] .draft-queue-detail-output .draft-tag-analysis-title {
  color: var(--ac-text);
  font-size: 13px;
  font-weight: 700;
}

html[data-page="app"] .draft-queue-detail-output .draft-tag-analysis-score {
  color: var(--ac-text-muted);
  font-size: 13px;
}

html[data-page="app"] .draft-queue-detail-output .draft-tag-analysis-notice {
  max-width: 100%;
}

html[data-page="app"] .mockup-modal-card {
  max-width: 980px;
}

html[data-page="app"] .mockup-studio-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr);
  gap: 16px;
  margin-top: 16px;
}

html[data-page="app"] .mockup-studio-panel {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .mockup-template-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

html[data-page="app"] .mockup-template-card {
  position: relative;
  display: grid;
  gap: 6px;
  min-height: 112px;
  padding: 14px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-surface);
  cursor: pointer;
}

html[data-page="app"] .mockup-template-card.selected,
html[data-page="app"] .mockup-template-card:focus-within {
  border-color: var(--ac-primary);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, .12);
}

html[data-page="app"] .mockup-template-card input {
  position: absolute;
  top: 12px;
  right: 12px;
}

html[data-page="app"] .mockup-tier,
html[data-page="app"] .mockup-usage-badge {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--ac-surface-muted);
  color: #007C78;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .04em;
}

html[data-page="app"] .mockup-usage-badge--included {
  background: #fffdf9;
  border: 1px solid var(--ac-border);
}

html[data-page="app"] .mockup-brief-label {
  display: grid;
  gap: 8px;
  color: var(--ac-text);
  font-size: 13px;
  font-weight: 700;
}

html[data-page="app"] .mockup-brief-label textarea {
  width: 100%;
  resize: vertical;
  min-height: 110px;
  padding: 12px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-surface);
  color: var(--ac-text);
}

html[data-page="app"] .mockup-attachments {
  display: grid;
  gap: 10px;
  margin: 12px 0;
}

html[data-page="app"] .mockup-attachment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 180px));
  gap: 10px;
}

html[data-page="app"] .draft-queue-detail-output .mockup-attachment-grid {
  max-height: 240px;
  overflow: auto;
  padding-right: 4px;
}

html[data-page="app"] .mockup-attachment-grid figure {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .mockup-attachment-grid img,
html[data-page="app"] .mockup-placeholder {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

html[data-page="app"] .mockup-placeholder {
  display: grid;
  place-items: center;
  padding: 12px;
  color: var(--ac-text-secondary);
}

html[data-page="app"] .mockup-placeholder.failed {
  background: var(--ac-danger-soft);
  color: var(--ac-danger);
  font-size: 12px;
  text-align: center;
}

html[data-page="app"] .mockup-attachment-grid figcaption {
  padding: 8px 10px;
  color: var(--ac-text-secondary);
  font-size: 12px;
}

@media (max-width: 1100px) {
  html[data-page="app"] .store-summary-row,
  html[data-page="app"] .command-action-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  html[data-page="app"] #view-live-research .research-result-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  html[data-page="app"] .draft-queue-simple-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  html[data-page="app"] .mockup-studio-layout,
  html[data-page="app"] .mockup-template-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  html[data-page="app"] .center-canvas {
    padding: 16px;
  }

  html[data-page="app"] .store-summary-row,
  html[data-page="app"] .command-action-grid,
  html[data-page="app"] .today-operating-list,
  html[data-page="app"] #view-live-research .research-result-grid,
  html[data-page="app"] .factory-output-grid,
  html[data-page="app"] .draft-workspace-shell .workspace-lane-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  html[data-page="app"] .command-center-header,
  html[data-page="app"] .factory-workspace-head {
    flex-direction: column;
    align-items: stretch;
  }

  html[data-page="app"] .command-statuses {
    justify-content: flex-start;
  }

  html[data-page="app"] .store-summary-row article,
  html[data-page="app"] .store-summary-row button {
    min-height: 110px;
  }

  html[data-page="app"] .command-action-grid button {
    min-height: 132px;
  }

  html[data-page="app"] #view-live-research .live-canvas-head,
  html[data-page="app"] #view-live-research .live-flow-section,
  html[data-page="app"] .factory-workspace-head,
  html[data-page="app"] .draft-workspace-shell .workspace-page-head {
    padding: 16px;
  }

  html[data-page="app"] #view-live-research .live-research-form {
    grid-template-columns: minmax(0, 1fr);
    padding: 12px;
  }

  html[data-page="app"] #view-live-research .live-research-form button[type="submit"] {
    width: 100%;
  }

  html[data-page="app"] .factory-output-grid > article:last-child {
    grid-column: auto;
  }

  html[data-page="app"] .factory-pipeline-card {
    padding: 14px;
  }

  html[data-page="app"] .draft-queue-detail-output > .card {
    padding: 14px;
  }
}

/* ============================================================
   ACOPES DESIGN SYSTEM — Stage 5 Supporting Workspaces
   Creative Studios, Store Intelligence, and Settings.
   ============================================================ */

html[data-page="app"] :where(
  .assets-workspace-shell,
  .store-workspace-shell,
  .settings-workspace-shell
) {
  display: grid;
  gap: 18px;
}

html[data-page="app"] :where(
  .assets-workspace-shell,
  .store-workspace-shell,
  .settings-workspace-shell
) > .workspace-page-head {
  padding: 20px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
}

html[data-page="app"] :where(
  .assets-workspace-shell,
  .store-workspace-shell,
  .settings-workspace-shell
) > .workspace-page-head h2 {
  margin: 4px 0 6px;
  font-size: 24px;
}

html[data-page="app"] :where(
  .assets-workspace-shell,
  .store-workspace-shell,
  .settings-workspace-shell
) > .workspace-page-head .meta {
  max-width: 760px;
  margin: 0;
}

html[data-page="app"] .workspace-section-grid {
  gap: 16px;
}

html[data-page="app"] :where(
  .assets-workspace-shell,
  .store-workspace-shell,
  .settings-workspace-shell
) .workspace-section-card {
  padding: 18px;
  border-radius: var(--ac-radius-card);
  box-shadow: none;
}

html[data-page="app"] :where(
  .assets-workspace-shell,
  .store-workspace-shell,
  .settings-workspace-shell
) .workspace-section-head {
  margin-bottom: 14px;
}

html[data-page="app"] :where(
  .assets-workspace-shell,
  .store-workspace-shell,
  .settings-workspace-shell
) .workspace-section-head h3 {
  font-size: 16px;
}

/* Creative Studios */

html[data-page="app"] .assets-workspace-shell .workspace-section-grid {
  grid-template-columns: minmax(0, 1fr);
}

html[data-page="app"] .assets-workspace-shell .workspace-metric-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

html[data-page="app"] .assets-workspace-shell .workspace-metric-grid article {
  min-height: 132px;
  padding: 18px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .assets-workspace-shell .workspace-metric-grid strong {
  color: var(--ac-text);
  font-size: 28px;
}

html[data-page="app"] .assets-workspace-shell .workspace-empty-state {
  min-height: 220px;
  display: grid;
  gap: 12px;
  place-items: center;
  padding: 32px;
  border: 1px dashed var(--ac-border-strong);
  border-radius: var(--ac-radius-card);
  background: var(--ac-bg-subtle);
  color: var(--ac-text-secondary);
  text-align: center;
}

html[data-page="app"] .mockup-gallery-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

html[data-page="app"] .mockup-gallery-toolbar > div {
  display: grid;
  gap: 8px;
}

html[data-page="app"] .mockup-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}

/* Trend Hunter saved library */

html[data-page="app"] .trend-library-shell {
  display: grid;
  gap: 16px;
}

html[data-page="app"] .trend-library-head,
html[data-page="app"] .trend-library-panel,
html[data-page="app"] .trend-opportunity-card {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .trend-library-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  padding: 20px;
}

html[data-page="app"] .trend-library-actions,
html[data-page="app"] .trend-card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

html[data-page="app"] .trend-library-actions a,
html[data-page="app"] .trend-card-actions a {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  text-decoration: none;
}

html[data-page="app"] .trend-library-panel {
  display: grid;
  gap: 12px;
  padding: 18px;
}

html[data-page="app"] .trend-import-uploader {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
}

html[data-page="app"] .trend-file-drop {
  display: grid;
  gap: 8px;
  min-height: 128px;
  padding: 18px;
  border: 1px dashed var(--ac-border-strong);
  border-radius: var(--ac-radius-card);
  background: var(--ac-bg-subtle);
  color: var(--ac-text);
  cursor: pointer;
}

html[data-page="app"] .trend-file-drop:hover,
html[data-page="app"] .trend-file-drop:focus-within {
  border-color: var(--ac-primary);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, 0.12);
}

html[data-page="app"] .trend-file-drop input {
  max-width: 100%;
  color: var(--ac-text-secondary);
}

html[data-page="app"] .trend-file-drop strong {
  color: var(--ac-text);
  font-size: 16px;
}

html[data-page="app"] .trend-file-drop span {
  color: var(--ac-text-secondary);
}

html[data-page="app"] .trend-import-uploader > .meta {
  grid-column: 1 / -1;
}

/* B3: file-upload half folded into the same accordion as the paste-text
   half, instead of the uploader sitting permanently open next to a
   collapsed textarea. */
html[data-page="app"] .trend-import-details > summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--ac-text);
  padding: 4px 0 8px;
}

html[data-page="app"] .trend-import-details > .meta {
  margin-bottom: 10px;
}

html[data-page="app"] .trend-paste-details {
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-control);
  background: var(--ac-bg-subtle);
  padding: 10px 12px;
  margin-top: 10px;
}

html[data-page="app"] .trend-paste-details summary {
  cursor: pointer;
  color: var(--ac-text-secondary);
  font-weight: 700;
}

html[data-page="app"] .trend-paste-details textarea {
  margin-top: 10px;
}

html[data-page="app"] .trend-library-panel textarea {
  width: 100%;
  min-height: 110px;
  resize: vertical;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-control);
  background: var(--ac-bg-subtle);
  color: var(--ac-text);
  padding: 12px;
  font: inherit;
}

html[data-page="app"] .trend-frequency-grid,
html[data-page="app"] .trend-tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

html[data-page="app"] .trend-frequency-grid span,
html[data-page="app"] .trend-tag-row span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--ac-warm-border);
  border-radius: 999px;
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 700;
}

html[data-page="app"] .trend-frequency-grid small {
  color: inherit;
  opacity: 0.75;
}

html[data-page="app"] .trend-opportunity-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
}

html[data-page="app"] .trend-opportunity-card {
  overflow: hidden;
  display: grid;
}

html[data-page="app"] .trend-opportunity-card > img,
html[data-page="app"] .trend-image-placeholder {
  width: 100%;
  height: 170px;
  object-fit: cover;
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .trend-image-placeholder {
  display: grid;
  place-items: center;
  color: var(--ac-text-muted);
}

html[data-page="app"] .trend-opportunity-card > div {
  display: grid;
  gap: 10px;
  padding: 16px;
}

html[data-page="app"] .trend-opportunity-card h3 {
  margin: 0;
  color: var(--ac-text);
  font-size: 16px;
  line-height: 1.25;
}

html[data-page="app"] .trend-library-empty {
  min-height: 220px;
}

@media (max-width: 720px) {
  html[data-page="app"] .trend-import-uploader {
    grid-template-columns: minmax(0, 1fr);
  }
}

html[data-page="app"] .mockup-gallery-card {
  overflow: hidden;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-bg-subtle);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] .mockup-gallery-card figure {
  margin: 0;
  border-bottom: 1px solid var(--ac-border);
  background: var(--ac-surface);
}

html[data-page="app"] .mockup-gallery-card img,
html[data-page="app"] .mockup-gallery-card .mockup-placeholder {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

html[data-page="app"] .mockup-gallery-card > div {
  display: grid;
  gap: 8px;
  padding: 13px;
}

html[data-page="app"] .mockup-gallery-card h4 {
  margin: 0;
  color: var(--ac-text);
  font-size: 14px;
  line-height: 1.25;
}

html[data-page="app"] .mockup-product-picker {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

html[data-page="app"] .mockup-product-picker button {
  display: grid;
  gap: 6px;
  min-height: 88px;
  padding: 14px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
  color: var(--ac-text);
  text-align: left;
  cursor: pointer;
}

html[data-page="app"] .mockup-product-picker button:hover,
html[data-page="app"] .mockup-product-picker button:focus-visible {
  border-color: var(--ac-primary);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, .12);
  outline: 0;
}

html[data-page="app"] .mockup-product-picker small {
  color: var(--ac-text-secondary);
}

/* Store Intelligence */

html[data-page="app"] .store-workspace-shell .workspace-section-grid {
  grid-template-columns: minmax(0, 1fr);
}

html[data-page="app"] .store-workspace-shell .store-grid,
html[data-page="app"] .store-workspace-shell .workspace-metric-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

html[data-page="app"] .store-workspace-shell .store-grid > *,
html[data-page="app"] .store-workspace-shell .workspace-metric-grid > * {
  min-height: 116px;
  padding: 16px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
}

/* UX Sprint 5: StoreConnectPage / StoreOverviewPage / GrowthTools */

html[data-page="app"] .store-connect-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(320px, 1fr);
  gap: var(--ac-space-6);
  align-items: start;
}

html[data-page="app"] .store-connect-right-stack { display: grid; gap: var(--ac-space-4); align-content: start; }

html[data-page="app"] .store-connect-hero,
html[data-page="app"] .store-connect-score-preview,
html[data-page="app"] .store-connect-permission-panel {
  display: grid;
  gap: var(--ac-space-3);
  align-content: start;
  padding: var(--ac-space-6);
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-surface);
}

html[data-page="app"] .store-connect-hero h2 { max-width: 640px; margin: 0; font-size: clamp(28px, 3.6vw, 38px); line-height: 1.1; letter-spacing: -.03em; color: var(--ac-text); }
html[data-page="app"] .store-connect-benefit-list { margin: var(--ac-space-2) 0 0; padding-left: 1.1em; display: grid; gap: 6px; color: var(--ac-text-secondary); font-size: 13px; }

html[data-page="app"] .store-connect-kpi-grid { display: grid; gap: var(--ac-space-2); }
html[data-page="app"] .store-connect-kpi-cell.locked {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  border: 1px dashed var(--ac-border);
  border-radius: var(--ac-radius-control);
  background: var(--ac-bg-subtle);
  color: var(--ac-text-muted);
}
html[data-page="app"] .store-connect-kpi-cell.locked span { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
html[data-page="app"] .store-connect-kpi-cell.locked strong { font-size: 18px; }
html[data-page="app"] .store-connect-cta { justify-self: center; margin-top: var(--ac-space-2); }

html[data-page="app"] .store-connect-duration-note { margin: 0; font-size: 12px; color: var(--ac-text-muted); text-align: center; }

html[data-page="app"] .store-connect-permission-rows { display: grid; gap: var(--ac-space-3); }
html[data-page="app"] .store-connect-permission-row { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; align-items: start; }
html[data-page="app"] .store-connect-permission-icon { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: var(--ac-bg-subtle); font-size: 14px; }
html[data-page="app"] .store-connect-permission-row strong { display: block; font-size: 13px; color: var(--ac-text); }
html[data-page="app"] .store-connect-permission-row small { display: block; margin-top: 2px; color: var(--ac-text-secondary); font-size: 12px; line-height: 1.5; }

html[data-page="app"] .store-connect-preview-heading {
  margin: var(--ac-space-6) 0 var(--ac-space-2);
  color: var(--ac-text-muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}
html[data-page="app"] .store-connect-preview-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: var(--ac-space-3);
}
html[data-page="app"] .store-connect-preview-cell {
  display: grid;
  gap: 6px;
  align-content: start;
  text-align: left;
  padding: var(--ac-space-3);
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
  color: var(--ac-text-muted);
}
html[data-page="app"] .store-connect-preview-head { display: flex; align-items: center; gap: 6px; }
html[data-page="app"] .store-connect-preview-head strong { font-size: 12px; color: var(--ac-text); }
html[data-page="app"] .store-connect-preview-lock { font-size: 12px; opacity: .6; }
html[data-page="app"] .store-connect-preview-cell p { margin: 0; color: var(--ac-text-secondary); font-size: 11px; line-height: 1.45; }
html[data-page="app"] .store-connect-preview-graphic.sparkline { width: 100%; height: 22px; color: var(--ac-border-strong, #c7d3d0); }
html[data-page="app"] .store-connect-preview-graphic.bars { display: grid; gap: 4px; margin-top: 2px; }
html[data-page="app"] .store-connect-preview-graphic.bars span { display: block; height: 5px; border-radius: 3px; background: var(--ac-loading-base); }
html[data-page="app"] .store-connect-preview-graphic.stars { letter-spacing: 2px; color: var(--ac-border-strong, #c7d3d0); font-size: 13px; }
html[data-page="app"] .store-connect-preview-graphic.input-skeleton { height: 16px; margin-top: 2px; border-radius: 6px; background: var(--ac-loading-base); }

@media (max-width: 960px) {
  html[data-page="app"] .store-connect-grid { grid-template-columns: minmax(0, 1fr); }
  html[data-page="app"] .store-connect-preview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

html[data-page="app"] .store-overview-header-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--ac-space-3);
}
html[data-page="app"] .store-overview-shop-link { display: inline-block; margin-top: 2px; }
html[data-page="app"] .store-overview-live-badge {
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--ac-success-soft);
  color: var(--ac-success);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}
html[data-page="app"] .store-overview-kpi-strip {
  margin-top: var(--ac-space-3);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--ac-space-3);
}
html[data-page="app"] .store-overview-kpi-cell {
  padding: 12px 14px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
}
html[data-page="app"] .store-overview-kpi-cell span { display: block; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--ac-text-muted); }
html[data-page="app"] .store-overview-kpi-cell strong { font-size: 18px; color: var(--ac-text); }

html[data-page="app"] .store-overview-top-products-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
html[data-page="app"] .store-overview-top-products-list li { display: flex; justify-content: space-between; gap: var(--ac-space-3); padding: 8px 10px; border: 1px solid var(--ac-border); border-radius: var(--ac-radius-control); background: var(--ac-bg-subtle); font-size: 13px; }
html[data-page="app"] .store-overview-top-product-revenue { color: var(--ac-success); font-weight: 700; white-space: nowrap; }

html[data-page="app"] .store-overview-listings-table td:last-child { text-align: right; }

html[data-page="app"] .draft-queue-search-empty { display: grid; gap: 10px; justify-items: center; }

html[data-page="app"] .growth-tools-shell .workspace-section-grid { grid-template-columns: minmax(0, 1fr); }

html[data-page="app"] #marketActionsReloadBtn {
  min-height: 42px;
  margin-bottom: 14px;
  border-color: var(--ac-primary);
  background: var(--ac-primary);
  color: var(--ac-on-primary);
}

html[data-page="app"] #marketActionsOutput {
  border-color: var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .action-list {
  display: grid;
  gap: 10px;
}

html[data-page="app"] .action-list > * {
  padding: 14px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-surface);
}

/* Settings */

html[data-page="app"] .settings-workspace-shell .workspace-section-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

html[data-page="app"] .settings-workspace-shell .workspace-metric-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

html[data-page="app"] .settings-workspace-shell .workspace-metric-grid > * {
  min-height: 112px;
  padding: 14px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
}

html[data-page="app"] .settings-workspace-shell .workspace-chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

html[data-page="app"] .settings-workspace-shell .workspace-chip-grid span {
  padding: 8px 11px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-pill);
  background: var(--ac-bg-subtle);
  color: var(--ac-text-secondary);
  font-size: 12px;
  font-weight: 600;
}

html[data-page="app"] .billing-plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

html[data-page="app"] .billing-plan-card {
  display: grid;
  gap: 14px;
  align-content: space-between;
  min-height: 220px;
  padding: 16px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card-sm);
  background: var(--ac-bg-subtle);
  box-shadow: var(--ac-shadow-soft);
}

html[data-page="app"] .billing-plan-card .plan-badge {
  border-color: var(--ac-warm-bg);
  background: var(--ac-warm-bg);
  color: var(--ac-warm-text);
}

html[data-page="app"] .billing-plan-card h4 {
  margin: 10px 0 6px;
  color: var(--ac-text);
  font-family: "Poppins", sans-serif;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
}

html[data-page="app"] .billing-plan-card p,
html[data-page="app"] .billing-plan-card small {
  margin: 0;
  color: var(--ac-text-secondary);
  line-height: 1.5;
}

html[data-page="app"] .billing-plan-card small {
  display: block;
  margin-top: 8px;
}

html[data-page="app"] .billing-plan-generations {
  margin-top: 4px;
  color: var(--ac-warm-text);
  font-size: 1.05rem;
}

html[data-page="app"] .billing-plan-breakdown {
  margin-top: 4px !important;
  color: var(--ac-text-secondary);
  font-size: 0.78rem;
  line-height: 1.45;
  word-break: break-word;
}

html[data-page="app"] .billing-upgrade-btn {
  width: 100%;
}

html[data-page="app"] .billing-plan-current {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 42px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-pill);
  color: var(--ac-text-secondary);
  font-size: 0.84rem;
  font-weight: 800;
  text-align: center;
}

html[data-page="app"] .hero-eyebrow,
html[data-page="app"] .eyebrow {
  color: var(--ac-primary-hover);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

/* All Product Directions modal: keep repeated result cards light.
   The main Research grid remains dark via #view-live-research selectors. */
html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal {
  border-color: var(--ac-border);
  background: var(--ac-surface);
  color: var(--ac-text);
  box-shadow: var(--ac-shadow-card);
}

html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal:hover,
html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal:focus-within {
  border-color: var(--ac-border-strong);
  box-shadow: var(--ac-shadow-card-hover);
}

html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .live-ref-meta {
  background: var(--ac-bg-subtle);
}

html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .live-ref-title,
html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .direction-metrics strong,
html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .marketplace-signal strong {
  color: var(--ac-text);
}

html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .live-badge,
html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .direction-metrics span {
  border-color: var(--ac-border);
  background: var(--ac-surface-muted);
  color: var(--ac-text-muted);
}

html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .direction-metrics small,
html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .marketplace-signal,
html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .marketplace-signal span {
  color: var(--ac-text-muted);
}

html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .marketplace-signal {
  border-top-color: var(--ac-border);
}

html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .live-ref-actions button,
html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .live-ref-actions a {
  min-height: 36px;
  border-color: var(--ac-border);
  border-radius: var(--ac-radius-control);
  background: var(--ac-surface);
  color: var(--ac-primary-hover);
  box-shadow: none;
}

html[data-page="app"] #researchResultsModal #researchResultsGrid .live-ref-card--modal .live-ref-actions button:first-child {
  border-color: var(--ac-primary);
  background: var(--ac-primary);
  color: var(--ac-on-primary);
}

html[data-page="app"] .workspace-empty-state {
  border-color: var(--ac-border);
  background: var(--ac-bg-subtle);
  color: var(--ac-text-secondary);
}

@media (max-width: 1023px) {
  html[data-page="app"] .settings-workspace-shell .workspace-section-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 767px) {
  html[data-page="app"] :where(
    .assets-workspace-shell,
    .store-workspace-shell,
    .settings-workspace-shell
  ) > .workspace-page-head,
  html[data-page="app"] :where(
    .assets-workspace-shell,
    .store-workspace-shell,
    .settings-workspace-shell
  ) .workspace-section-card {
    padding: 16px;
  }

  html[data-page="app"] .assets-workspace-shell .workspace-metric-grid,
  html[data-page="app"] .store-workspace-shell .store-grid,
  html[data-page="app"] .store-workspace-shell .workspace-metric-grid,
  html[data-page="app"] .settings-workspace-shell .workspace-metric-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Home card geometry correction */
html[data-page="app"] .store-summary-row article,
html[data-page="app"] .store-summary-row button,
html[data-page="app"] .command-action-grid button,
html[data-page="app"] .today-operating-list article {
  border-radius: 16px !important;
}
.email-verification-notice {
  position: sticky;
  top: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 22px;
  border-bottom: 1px solid rgba(102, 115, 141, 0.24);
  background: #fff8e8;
  color: #172033;
  box-shadow: 0 8px 24px rgba(23, 32, 51, 0.08);
}

.email-verification-notice p {
  margin: 3px 0 0;
  color: #59677d;
}

.email-verification-notice button {
  flex: 0 0 auto;
}

@media (max-width: 680px) {
  .email-verification-notice {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* ============================================================
   Basit Mod: simplified entry flow (simplified-flow-plan-v1, UX build
   order step 2). Reuses the design-unification pass's --ac-* tokens
   directly rather than the legacy --ink-900, --blue, --line aliases
   still used by .command-action-grid above (both point at the same
   values - see the alias block near the --ac-* root definitions).
   Button styling is NOT reinvented here - primary-btn, secondary,
   button-row, and .pill are the same real classes the Draft Queue
   detail panel already uses.
   ============================================================ */

.simple-flow-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--ac-space-3);
}

.simple-flow-card {
  display: grid;
  align-content: start;
  gap: 7px;
  min-height: 116px;
  padding: var(--ac-space-4);
  text-align: left;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
  color: var(--ac-text);
  box-shadow: var(--ac-shadow-card);
  position: relative;
}

.simple-flow-card:hover,
.simple-flow-card:focus-visible {
  border-color: var(--ac-primary);
  box-shadow: var(--ac-shadow-card-hover);
  transform: translateY(-2px);
}

.simple-flow-card i {
  font-style: normal;
  font-size: 20px;
  color: var(--ac-primary);
}

.simple-flow-card span {
  font-family: var(--ac-font-display);
  font-size: 15px;
  font-weight: 700;
}

.simple-flow-card small {
  color: var(--ac-text-muted);
  font-size: 12px;
  line-height: 1.45;
}

/* The one primary/most-common action ("Generate a product idea") among
   8 otherwise visually-identical cards - solid brown fill instead of
   the neutral outline the other 7 keep, same real primary color already
   used for CTA buttons elsewhere (--ac-primary), not a new color. */
.simple-flow-card.is-primary {
  background: var(--ac-primary);
  border-color: var(--ac-primary);
}

.simple-flow-card.is-primary i,
.simple-flow-card.is-primary span {
  color: var(--ac-on-primary);
}

.simple-flow-card.is-primary small {
  color: rgba(255, 255, 255, 0.78);
}

.simple-flow-card.is-primary:hover,
.simple-flow-card.is-primary:focus-visible {
  background: var(--ac-primary-hover);
  border-color: var(--ac-primary-hover);
}

/* Home keeps the seven real entry points, but separates strategic work from
   production tools without changing any card action or route. */
.simple-flow-grid--recommended {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.simple-flow-grid--recommended .simple-flow-card {
  min-height: 132px;
}

.simple-flow-tools {
  margin-top: var(--ac-space-4);
}

.simple-flow-tools h4 {
  margin: 0 0 var(--ac-space-2);
  color: var(--ac-text-muted);
  font-size: 12px;
  font-weight: 750;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.simple-flow-grid--tools .simple-flow-card {
  min-height: 96px;
  padding: var(--ac-space-3);
}

.simple-flow-grid--tools .simple-flow-card i { font-size: 17px; }
.simple-flow-grid--tools .simple-flow-card span { font-size: 14px; }
.simple-flow-grid--tools .simple-flow-card small { font-size: 11px; }

/* Keep the home workflow entry compact so the current task stays primary. */
.today-operating-section--primary {
  border-color: var(--ac-border-strong);
}

.today-operating-section--primary .section-headline {
  margin-bottom: var(--ac-space-3);
}

.today-operating-section--primary .section-headline h3 {
  color: var(--ac-primary);
}

.simple-flow-actions-heading {
  margin-bottom: var(--ac-space-3) !important;
}

.simple-flow-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ac-space-2);
}

.simple-flow-action-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid var(--ac-border);
  border-radius: 999px;
  background: var(--ac-surface);
  color: var(--ac-text);
  box-shadow: none;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.simple-flow-action-chip i {
  color: var(--ac-primary);
  font-size: 15px;
  font-style: normal;
}

.simple-flow-action-chip:hover,
.simple-flow-action-chip:focus-visible {
  border-color: var(--ac-primary);
  background: var(--ac-warm-bg);
  box-shadow: 0 0 0 3px rgba(61, 33, 14, .12);
  transform: none;
}

.simple-flow-action-chip.is-primary {
  border-color: var(--ac-primary);
  background: var(--ac-primary);
  color: var(--ac-on-primary);
}

.simple-flow-action-chip.is-primary i { color: var(--ac-on-primary); }

@media (max-width: 600px) {
  .simple-flow-action-chip {
    flex: 1 1 calc(50% - var(--ac-space-2));
    justify-content: center;
    min-width: 0;
    padding-inline: 10px;
    white-space: normal;
  }
}

.command-status.warning {
  color: var(--ac-danger, #b42318);
  border-color: rgba(180, 35, 24, .28);
  background: rgba(180, 35, 24, .08);
}

button.command-status { cursor: pointer; }

#storeHealthDetail { display: flex; align-items: center; gap: 10px; }
.store-health-grade { font-size: 12px; font-weight: 750; }
.store-health-grade-strong { color: var(--ac-success); }
.store-health-grade-improving { color: var(--ac-primary); }
.store-health-grade-needs_attention { color: var(--ac-danger, #b42318); }
.store-health-why { color: var(--ac-text-muted); font-size: 12px; }
.store-health-why summary { cursor: pointer; }
.store-health-why ul { margin: 8px 0 0; padding-left: 18px; }

.simple-flow-card.is-disabled {
  cursor: not-allowed;
  opacity: 0.6;
  background: var(--ac-surface-muted);
}

.simple-flow-card.is-disabled:hover {
  transform: none;
  box-shadow: var(--ac-shadow-card);
  border-color: var(--ac-border);
}

.simple-flow-soon-badge {
  position: absolute;
  top: var(--ac-space-3);
  right: var(--ac-space-3);
}

.simple-flow-back {
  border: none;
  background: none;
  color: var(--ac-text-secondary);
  font-size: 13px;
  padding: 0 0 var(--ac-space-3);
  cursor: pointer;
}

.simple-flow-back:hover {
  color: var(--ac-primary);
}

.simple-flow-choice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--ac-space-4);
}

.simple-flow-choice-card {
  display: grid;
  gap: var(--ac-space-2);
  padding: var(--ac-space-5);
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
}

.simple-flow-choice-card > span {
  font-family: var(--ac-font-display);
  font-size: 16px;
  font-weight: 700;
}

.simple-flow-choice-card small {
  color: var(--ac-text-muted);
  font-size: 13px;
  line-height: 1.5;
}

.simple-flow-choice-card input[type="text"] {
  padding: 10px 12px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-control);
  background: var(--ac-surface-strong);
  color: var(--ac-text);
  font-size: 14px;
}

.simple-flow-niche-focus {
  display: grid;
  gap: 6px;
}
.simple-flow-niche-focus select {
  padding: 10px 12px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-control);
  background: var(--ac-surface-strong);
  color: var(--ac-text);
  font-size: 13px;
}

.simple-flow-radio {
  display: flex;
  align-items: center;
  gap: var(--ac-space-2);
  font-size: 13px;
  color: var(--ac-text);
  cursor: pointer;
}

.simple-flow-empty-state {
  display: grid;
  gap: var(--ac-space-3);
  justify-items: start;
  padding: var(--ac-space-6) 0;
}

.simple-flow-muted {
  color: var(--ac-text-muted);
  font-size: 13px;
  line-height: 1.5;
}

.simple-flow-error {
  color: var(--ac-danger);
  font-size: 13px;
}

.simple-flow-waiting {
  display: grid;
  justify-items: center;
  gap: var(--ac-space-3);
  padding: var(--ac-space-10) 0;
  text-align: center;
}

.simple-flow-waiting-title {
  font-family: var(--ac-font-display);
  font-size: 16px;
  font-weight: 700;
  color: var(--ac-text);
}

.simple-flow-spinner {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 3px solid var(--ac-primary-soft);
  border-top-color: var(--ac-primary);
  animation: simple-flow-spin 0.8s linear infinite;
}

@keyframes simple-flow-spin {
  to { transform: rotate(360deg); }
}

.simple-flow-results-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--ac-space-3);
}

.simple-flow-result-card {
  display: grid;
  gap: var(--ac-space-2);
  padding: var(--ac-space-4);
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
  box-shadow: var(--ac-shadow-card);
}

.simple-flow-result-card strong {
  font-family: var(--ac-font-display);
  font-size: 15px;
}

.simple-flow-result-card small {
  color: var(--ac-text-muted);
  font-size: 12px;
}

.simple-flow-potential-pill {
  justify-self: start;
}

.simple-flow-result {
  display: grid;
  gap: var(--ac-space-3);
  max-width: 520px;
}

.simple-flow-result h3 {
  font-family: var(--ac-font-display);
  font-size: 20px;
  margin: 0;
}

.simple-flow-result-image,
.simple-flow-preview-image {
  width: 100%;
  max-width: 320px;
  border-radius: var(--ac-radius-card-sm);
  border: 1px solid var(--ac-border);
}

.simple-flow-result-video {
  width: 100%;
  max-width: 420px;
  border-radius: var(--ac-radius-card-sm);
  background: #000;
}

.simple-flow-not-ready {
  margin: 0;
}

.simple-flow-checklist {
  display: grid;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
  max-width: 420px;
}

.simple-flow-checklist-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ac-space-3);
  padding: 8px 12px;
  border: 1px solid var(--ac-border);
  border-radius: var(--ac-radius-control);
  background: var(--ac-surface);
  font-size: 13px;
}

.simple-flow-checklist-item.is-ready {
  color: var(--ac-text);
}

.simple-flow-checklist-item.is-ready .simple-flow-checklist-status {
  color: var(--ac-success);
  font-weight: 600;
}

.simple-flow-checklist-item.is-pending .simple-flow-checklist-status {
  color: var(--ac-text-muted);
}

.simple-flow-upload-area {
  display: grid;
  gap: var(--ac-space-3);
  padding: var(--ac-space-5);
  border: 1px dashed var(--ac-border-strong);
  border-radius: var(--ac-radius-card);
  background: var(--ac-surface);
  max-width: 420px;
  margin-bottom: var(--ac-space-4);
}

@media (max-width: 900px) {
  .simple-flow-grid,
  .simple-flow-choice-grid,
  .simple-flow-results-grid {
    grid-template-columns: 1fr;
  }
}

/* B4 (1/2, uppercase locale bug): text-transform: uppercase applies
   Turkish-tailored case conversion whenever the elements language
   resolves to tr (document.documentElement.lang, set by i18n.js) - a
   lowercase i becomes dotted-I. Every class below currently holds
   English micro-copy (kickers, status pills, badges) with no Turkish
   translation yet, so it renders with stray dotted-I characters under
   the TR locale. Scoped strictly to lang=tr - the English-locale
   visual design (uppercase labels) is untouched; this only stops the
   Turkish locale from mis-casing text it was never meant to case-
   transform. Once a string moves under t()/tVars() with a real
   Turkish translation (B4 part 2 / B5), it no longer needs uppercase
   styling per the "dont put new labels in an uppercase class" rule
   (see Uygulama notlari) - delete the matching line here as each one
   gets translated. Generated programmatically from every
   text-transform: uppercase rule in this file to avoid manual-
   transcription gaps. Fully reversible: delete this block. */
html[lang="tr"] .ai-credit-indicator span,
html[lang="tr"] .workflow-strip-toggle,
html[lang="tr"] .hero-eyebrow,
html[lang="tr"] .marketing-footer h4,
html[lang="tr"] .workspace-state-card strong,
html[lang="tr"] .brain-section-item small,
html[lang="tr"] .brain-log-item small,
html[lang="tr"] .market-scan-provenance,
html[lang="tr"] .coloring-book-output .factory-pipeline-steps article span,
html[lang="tr"] .kpi-chip small,
html[lang="tr"] .intel-chip small,
html[lang="tr"] .seo-card-grid small,
html[lang="tr"] .asset-progress-grid small,
html[lang="tr"] .concept-card-grid small,
html[lang="tr"] .launch-progress-card small,
html[lang="tr"] .module-progress-grid article .coming-soon-badge,
html[lang="tr"] .tagflow-stat-label,
html[lang="tr"] .decision-badge,
html[lang="tr"] .pill.good,
html[lang="tr"] .pill.safe,
html[lang="tr"] .onboarding-eyebrow,
html[lang="tr"] .analyst-chart-card small,
html[lang="tr"] .workspace-metric-tile small,
html[lang="tr"] #view-live-research .direction-signal-row small,
html[lang="tr"] #liveReferenceDrawer .analyst-signal-list strong,
html[lang="tr"] .store-summary-row span,
html[lang="tr"] .direction-metrics small,
html[lang="tr"] .marketplace-signal span,
html[lang="tr"] .store-summary-row > button span,
html[lang="tr"] .store-summary-row > article span,
html[lang="tr"][data-page="app"] .draft-product-type-badge,
html[lang="tr"][data-page="app"] .draft-queue-detail-output .draft-detail-card-head span,
html[lang="tr"][data-page="app"] .draft-queue-detail-output .draft-etsy-status .draft-detail-status,
html[lang="tr"][data-page="app"] .mockup-tier,
html[lang="tr"][data-page="app"] .mockup-usage-badge,
html[lang="tr"][data-page="app"] .hero-eyebrow,
html[lang="tr"][data-page="app"] .eyebrow,
html[lang="tr"] .simple-flow-tools h4 {
  text-transform: none;
}

/* Final navigation overrides must follow the legacy responsive rules. */
html[data-page="app"] .os-sidebar-nav { background:#0B2F33; color:#fff; padding:14px 10px; gap:14px; align-content:start; }
html[data-page="app"] .sidebar-group { display:grid; gap:4px; min-width:0; }
html[data-page="app"] .sidebar-group-label { padding:0 10px 5px; color:rgba(255,255,255,.52); font-size:10px; font-weight:800; letter-spacing:.11em; text-transform:uppercase; }
html[data-page="app"] .sidebar-group .sidebar-item { display:flex; width:100%; color:rgba(255,255,255,.78); border:1px solid transparent; border-radius:10px; justify-content:flex-start; }
html[data-page="app"] .sidebar-group .sidebar-item:hover { color:#fff; background:rgba(53,191,174,.12); border-color:rgba(53,191,174,.2); }
html[data-page="app"] .sidebar-group .sidebar-item.active { color:#fff; background:#007C78; box-shadow:0 7px 18px rgba(0,0,0,.16); }
html[data-page="app"] .sidebar-group-utility { margin-top:auto; }
html[data-page="app"] body.nav-collapsed .sidebar-group-label { display:none; }
html[data-page="app"] body.nav-collapsed .sidebar-group { gap:7px; }
html[data-page="app"] body.nav-collapsed .sidebar-group .sidebar-item { justify-content:center; }

@media (max-width:820px) {
  html[data-page="app"] .os-sidebar-nav,
  html[data-page="app"] body.nav-collapsed .os-sidebar-nav { display:flex; width:100%; padding:6px 8px; gap:4px; overflow-x:auto; border:0; border-bottom:1px solid rgba(255,255,255,.14); }
  html[data-page="app"] .sidebar-group,
  html[data-page="app"] body.nav-collapsed .sidebar-group { display:contents; }
  html[data-page="app"] .sidebar-group-label { display:none; }
  html[data-page="app"] .os-sidebar-nav .sidebar-item,
  html[data-page="app"] body.nav-collapsed .os-sidebar-nav .sidebar-item { display:none; flex:0 0 48px; width:48px; min-width:48px; height:42px; padding:0; justify-content:center; }
  html[data-page="app"] .os-sidebar-nav [data-app-route="home"],
  html[data-page="app"] .os-sidebar-nav [data-app-route="product-intelligence"],
  html[data-page="app"] .os-sidebar-nav [data-app-route="product-factory"],
  html[data-page="app"] .os-sidebar-nav [data-app-route="draft-queue"],
  html[data-page="app"] .os-sidebar-nav .mobile-more-trigger { display:flex; }
  html[data-page="app"] .os-sidebar-nav .sidebar-label { display:none; }
}

/* Automation & Operations: real run history, filters, safety policy, and right rail. */
.automation-tabs { display:flex; gap:8px; margin:0 0 16px; border-bottom:1px solid var(--ac-border); overflow-x:auto; }
.automation-composition { display:grid; grid-template-columns:minmax(0, 1fr) 280px; gap:16px; align-items:start; }
.automation-main-panel,
.automation-right-rail { min-width:0; }
.automation-right-rail { position:sticky; top:16px; display:grid; gap:14px; }
.automation-right-rail .workspace-metric-grid { grid-template-columns:1fr; }
.automation-run-head { align-items:flex-start; gap:16px; }
.automation-filters { display:flex; flex-wrap:wrap; justify-content:flex-end; gap:6px; }
.automation-filter { min-height:32px; padding:5px 10px; border:1px solid var(--ac-border); border-radius:999px; background:var(--ac-surface); color:var(--ac-text-muted); font-size:12px; font-weight:700; }
.automation-filter:hover,
.automation-filter.active { border-color:#007c78; background:rgba(0,124,120,.08); color:#006b67; }
.automation-table-wrap { width:100%; overflow-x:auto; }
.automation-run-table { width:100%; min-width:640px; border-collapse:collapse; }
.automation-run-table th,
.automation-run-table td { padding:12px 10px; border-bottom:1px solid var(--ac-border); text-align:left; vertical-align:middle; font-size:13px; }
.automation-run-table th { color:var(--ac-text-muted); font-size:11px; font-weight:800; letter-spacing:.04em; }
.automation-run-table tbody tr:hover { background:rgba(0,124,120,.035); }
.automation-safety-list { display:grid; gap:10px; }
.automation-safety-list article { display:grid; gap:5px; padding:14px; border:1px solid var(--ac-border); border-radius:var(--ac-radius-card); background:var(--ac-surface); }
.automation-safety-list span { color:var(--ac-text-muted); font-size:13px; line-height:1.5; }

@media (max-width:980px) {
  .automation-composition { grid-template-columns:1fr; }
  .automation-right-rail { position:static; }
  .automation-right-rail .workspace-metric-grid { grid-template-columns:repeat(3, minmax(0, 1fr)); }
}

@media (max-width:680px) {
  .automation-run-head { display:grid; }
  .automation-filters { justify-content:flex-start; }
  .automation-right-rail .workspace-metric-grid { grid-template-columns:1fr; }
}

/* Route-specific workspaces: SEO Expert and Settings */
.seo-expert-workspace,.settings-workspace-shell { display:grid; gap:16px; }
.seo-expert-head,.settings-page-head { display:flex; justify-content:space-between; gap:20px; align-items:flex-end; }
.seo-expert-summary { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; }
.seo-expert-summary article { display:grid; gap:5px; min-height:104px; padding:15px; border:1px solid var(--ac-border); border-radius:12px; background:#fff; }
.seo-expert-summary span { color:var(--ac-text-muted); font-size:11px; font-weight:750; }
.seo-expert-summary strong { color:#132a2d; font-size:25px; line-height:1; }
.seo-expert-summary small { color:#84928f; font-size:10px; }
.seo-expert-composition { display:grid; grid-template-columns:minmax(0,1fr) 300px; gap:14px; align-items:start; }
.seo-expert-main { min-width:0; }
.seo-expert-table-head { align-items:center; }
.section-kicker { color:#007c78; font-size:9px; font-weight:850; letter-spacing:.09em; text-transform:uppercase; }
.seo-selection-count { padding:5px 8px; border-radius:7px; background:#edf8f6; color:#007c78; font-size:10px; font-weight:800; }
.seo-expert-workspace .seo-studio-table { min-width:980px; }
.seo-expert-workspace .seo-studio-table th,.seo-expert-workspace .seo-studio-table td { max-width:240px; padding:11px 9px; vertical-align:top; }
.seo-expert-rail { display:grid; gap:12px; position:sticky; top:14px; }
.seo-safety-steps { display:grid; gap:8px; }
.seo-safety-steps article { display:grid; gap:3px; padding:10px; border:1px solid #e1e9e7; border-radius:9px; background:#f9fbfa; }
.seo-safety-steps strong { color:#173d40; font-size:11px; }
.seo-safety-steps span,.seo-policy-card p { margin:0; color:#71817f; font-size:10px; line-height:1.5; }
.seo-studio-preview-card ul { display:grid; gap:9px; margin:10px 0 0; padding:0; list-style:none; }
.seo-studio-preview-card li { display:grid; gap:3px; padding-top:9px; border-top:1px solid #e4eae9; }
.seo-studio-preview-card li strong,.seo-studio-preview-card li span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.seo-studio-preview-card li strong { color:#173d40; font-size:10px; }.seo-studio-preview-card li span { color:#71817f; font-size:9px; }
.settings-composition { display:grid; grid-template-columns:220px minmax(0,1fr); gap:14px; align-items:start; }
.settings-nav { display:grid; gap:3px; padding:8px; border:1px solid var(--ac-border); border-radius:12px; background:#fff; position:sticky; top:14px; }
.settings-nav button { width:100%; min-height:38px; padding:8px 10px; border:0; border-radius:8px; background:transparent; color:#5d6b6d; text-align:left; font-size:12px; font-weight:750; }
.settings-nav button:hover,.settings-nav button.active { background:#edf8f6; color:#007c78; }
.settings-panel { display:grid; gap:14px; min-width:0; }
.settings-panel-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; }
.settings-definition-list { display:grid; gap:0; }
.settings-definition-list > div { display:flex; justify-content:space-between; gap:20px; padding:11px 0; border-bottom:1px solid #e4eae9; }
.settings-definition-list span { color:#71817f; font-size:11px; }.settings-definition-list strong { color:#173d40; font-size:11px; text-align:right; }
.connection-detail-card { display:flex; gap:12px; align-items:flex-start; margin-bottom:14px; }
.connection-detail-card p { margin:4px 0 0; color:#71817f; font-size:11px; line-height:1.45; }
.connection-indicator { flex:0 0 10px; width:10px; height:10px; margin-top:4px; border-radius:50%; background:#c2413a; box-shadow:0 0 0 4px rgba(194,65,58,.1); }
.connection-indicator.connected { background:#15803d; box-shadow:0 0 0 4px rgba(21,128,61,.1); }
@media(max-width:1080px){.seo-expert-composition{grid-template-columns:1fr}.seo-expert-rail{position:static;grid-template-columns:repeat(3,minmax(0,1fr))}.settings-panel-grid{grid-template-columns:1fr}}
@media(max-width:760px){.seo-expert-head,.settings-page-head{display:grid;align-items:start}.seo-studio-actions{width:100%}.seo-studio-actions button{flex:1}.seo-expert-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.seo-expert-rail{grid-template-columns:1fr}.settings-composition{grid-template-columns:1fr}.settings-nav{position:static;display:flex;overflow-x:auto}.settings-nav button{width:auto;min-width:max-content}.settings-definition-list>div{align-items:flex-start}}
@media(max-width:460px){.seo-expert-summary{grid-template-columns:1fr}.seo-expert-summary article{min-height:88px}}

/* Production, creative studios, and publish center use distinct workspace compositions. */
.factory-production-workspace,.photo-production-shell,.video-production-shell,.publish-center-shell{display:grid;gap:16px}
.factory-production-head,.studio-production-head,.publish-center-head{display:flex;justify-content:space-between;gap:20px;align-items:flex-end}
.factory-production-composition{display:grid;grid-template-columns:minmax(0,1fr)300px;gap:14px;align-items:start}
.factory-production-main,.factory-context-rail,.photo-studio-main,.photo-control-rail,.video-control-rail{display:grid;gap:14px;min-width:0}
.factory-context-rail,.photo-control-rail,.video-control-rail,.publish-right-rail{position:sticky;top:14px}
.factory-brief-panel{display:grid;gap:14px}.factory-live-status{max-width:320px;color:#5d6b6d;font-size:10px;text-align:right}
.factory-flow-canvas{display:grid;gap:14px}.factory-flow-heading{display:grid;gap:4px}.factory-flow-heading h3{margin:0;color:#132a2d}
.factory-results-panel{display:grid;gap:12px}.factory-production-workspace .factory-entry-card-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
.studio-status-summary,.publish-summary-row{display:grid;gap:10px}.studio-status-summary .workspace-metric-grid,.publish-summary-row .workspace-metric-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
.photo-studio-composition,.video-studio-composition,.publish-center-composition{display:grid;grid-template-columns:minmax(0,1fr)300px;gap:14px;align-items:start}
.video-source-panel{min-width:0}.studio-table-wrap,.publish-table-wrap{width:100%;overflow-x:auto}
.studio-source-table,.publish-table{width:100%;min-width:720px;border-collapse:collapse}.studio-source-table th,.studio-source-table td,.publish-table th,.publish-table td{padding:11px 9px;border-bottom:1px solid #e4eae9;text-align:left;vertical-align:middle;font-size:11px}
.studio-source-table th,.publish-table th{color:#71817f;font-size:9px;letter-spacing:.06em;text-transform:uppercase}.studio-source-table td strong,.studio-source-table td small,.publish-table td strong,.publish-table td small{display:block;max-width:300px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.studio-source-table td small,.publish-table td small{margin-top:3px;color:#84928f;font-size:9px}
.publish-head-actions{display:flex;gap:8px}.publish-main-panel{min-width:0}.publish-right-rail{display:grid;gap:12px}.publish-toolbar{display:flex;gap:8px;align-items:center;margin-bottom:12px}.publish-toolbar input{flex:1;min-height:38px;padding:0 11px;border:1px solid #d7e1df;border-radius:9px;background:#f9fbfa;color:#132a2d;font:inherit}
.publish-tabs{display:flex;gap:4px;margin-bottom:12px;padding:4px;overflow-x:auto;border-radius:9px;background:#f0f4f3}.publish-tabs button{display:flex;gap:6px;align-items:center;min-width:max-content;padding:7px 10px;border:0;border-radius:7px;background:transparent;color:#5d6b6d;font-size:10px;font-weight:800}.publish-tabs button.active{background:#fff;color:#007c78;box-shadow:0 1px 4px rgba(11,47,51,.08)}.publish-tabs span{display:grid;place-items:center;min-width:18px;height:18px;border-radius:99px;background:#e4eae9;font-size:9px}.publish-tabs button.active span{background:#dff3ef}
@media(max-width:1100px){.factory-production-composition,.photo-studio-composition,.video-studio-composition,.publish-center-composition{grid-template-columns:1fr}.factory-context-rail,.photo-control-rail,.video-control-rail,.publish-right-rail{position:static;grid-template-columns:repeat(2,minmax(0,1fr))}.factory-production-workspace .factory-entry-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){.factory-production-head,.studio-production-head,.publish-center-head{display:grid;align-items:start}.factory-context-rail,.photo-control-rail,.video-control-rail,.publish-right-rail{grid-template-columns:1fr}.studio-status-summary .workspace-metric-grid,.publish-summary-row .workspace-metric-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.factory-production-workspace .factory-entry-card-grid{grid-template-columns:1fr}.publish-toolbar{align-items:stretch;flex-wrap:wrap}.publish-toolbar input{flex-basis:100%}.factory-live-status{text-align:left}}
@media(max-width:460px){.studio-status-summary .workspace-metric-grid,.publish-summary-row .workspace-metric-grid{grid-template-columns:1fr}.publish-head-actions{width:100%}.publish-head-actions button{flex:1}}
.draft-decision-summary{margin-bottom:14px}.draft-decision-summary .workspace-metric-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
.tagflow-workspace-shell{display:grid;gap:16px}.tagflow-summary .workspace-metric-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.tagflow-composition{display:grid;grid-template-columns:minmax(0,1fr)300px;gap:14px;align-items:start}.tagflow-main{min-width:0}.tagflow-right-rail{display:grid;gap:12px;position:sticky;top:14px}.tagflow-table{width:100%;min-width:820px;border-collapse:collapse}.tagflow-table th,.tagflow-table td{padding:11px 9px;border-bottom:1px solid #e4eae9;text-align:left;vertical-align:top;font-size:11px}.tagflow-table th{color:#71817f;font-size:9px;letter-spacing:.06em;text-transform:uppercase}.tagflow-table td:first-child{max-width:260px}.tagflow-table td strong{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
@media(max-width:1000px){.tagflow-composition{grid-template-columns:1fr}.tagflow-right-rail{position:static;grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){.draft-decision-summary .workspace-metric-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.tagflow-right-rail{grid-template-columns:1fr}}
@media(max-width:460px){.draft-decision-summary .workspace-metric-grid,.tagflow-summary .workspace-metric-grid{grid-template-columns:1fr}}

/* Remaining page-by-page rebuilds */
.product-intelligence-filterbar{display:grid;grid-template-columns:170px 210px minmax(0,1fr);gap:10px;align-items:end;padding:12px;border:1px solid #dce5e3;border-radius:12px;background:#fff}.product-intelligence-filterbar label,.draft-editor-copy label,.draft-editor-secondary-grid label{display:grid;gap:5px;color:#5d6b6d;font-size:10px;font-weight:800}.product-intelligence-filterbar select,.draft-editor-copy input,.draft-editor-copy textarea,.draft-editor-secondary-grid input{width:100%;padding:9px 10px;border:1px solid #d7e1df;border-radius:8px;background:#fff;color:#132a2d;font:inherit}.product-intelligence-filterbar>div{display:grid;gap:3px}.product-intelligence-filterbar span{color:#007c78;font-size:9px;font-weight:850;text-transform:uppercase}.product-intelligence-filterbar strong{color:#132a2d;font-size:11px}.product-intelligence-filterbar small{color:#71817f;font-size:9px}
.draft-editor-shell{display:grid;gap:16px}.draft-editor-head{display:flex;justify-content:space-between;gap:20px;align-items:flex-end}.draft-editor-composition{display:grid;grid-template-columns:minmax(0,1fr)310px;gap:14px;align-items:start}.draft-editor-main,.draft-editor-rail{display:grid;gap:14px;min-width:0}.draft-editor-rail{position:sticky;top:14px}.draft-editor-media-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px}.draft-editor-media-grid figure{aspect-ratio:1;margin:0;overflow:hidden;border:1px solid #dce5e3;border-radius:9px;background:#f3f6f5}.draft-editor-media-grid img{width:100%;height:100%;object-fit:cover}.draft-editor-copy{display:grid;gap:12px}.draft-editor-copy textarea{resize:vertical;line-height:1.5}.draft-editor-copy small{color:#71817f}.draft-editor-secondary-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.draft-editor-readiness>strong{display:block;margin:8px 0;color:#132a2d;font-size:38px}.draft-editor-readiness p{margin:8px 0 0;color:#5d6b6d;font-size:11px}.blocking-error-list{display:grid;gap:6px;margin:0;padding:0;list-style:none}.blocking-error-list li{padding:8px 9px;border:1px solid #f0c8c3;border-radius:8px;background:#fff5f4;color:#c2413a;font-size:10px;font-weight:750}.validation-success{padding:9px;border-radius:8px;background:#effaf2;color:#15803d;font-size:11px}.draft-editor-actions{display:grid;gap:8px}
.market-intelligence-overview{display:grid;gap:14px}.market-overview-grid .workspace-metric-grid{grid-template-columns:repeat(4,minmax(0,1fr))}.market-intelligence-composition{display:grid;grid-template-columns:minmax(0,1fr)300px;gap:14px;align-items:start}.market-comparison-list{display:grid;gap:8px;margin-top:12px}.market-comparison-list article{display:flex;justify-content:space-between;gap:16px;padding:9px;border:1px solid #e1e9e7;border-radius:8px;background:#f9fbfa;font-size:10px}
.radar-shell,.goldmine-shell,.advisor-workspace-shell,.asset-library-shell,.credits-workspace-shell,.unavailable-feature-shell{display:grid;gap:16px}.radar-toolbar,.library-toolbar{display:flex;justify-content:space-between;gap:10px;align-items:center;padding:10px;border:1px solid #dce5e3;border-radius:11px;background:#fff}.radar-toolbar>div,.library-toolbar>div{display:flex;gap:4px}.radar-toolbar button,.library-toolbar button{padding:7px 10px;border:0;border-radius:7px;background:#edf2f1;color:#5d6b6d;font-size:10px;font-weight:800}.radar-toolbar button.active,.library-toolbar button.active{background:#007c78;color:#fff}.radar-toolbar select,.library-toolbar select,.library-toolbar input{min-height:36px;padding:0 10px;border:1px solid #d7e1df;border-radius:8px;background:#fff;color:#132a2d}.library-toolbar input{flex:1;max-width:520px}.radar-card-grid,.goldmine-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.radar-card-grid article,.goldmine-grid article{display:grid;gap:11px;padding:15px;border:1px solid #dce5e3;border-radius:12px;background:#fff}.radar-card-grid h3,.goldmine-grid h3{margin:0;color:#132a2d;font-size:14px}.radar-card-head{display:flex;justify-content:space-between;gap:10px}.radar-card-head span,.goldmine-grid>article>span{color:#007c78;font-size:9px;font-weight:850;text-transform:uppercase}.radar-card-head strong{display:grid;place-items:center;width:34px;height:34px;border-radius:9px;background:#edf8f6;color:#007c78;font-size:15px}.goldmine-grid p{margin:0;color:#5d6b6d;font-size:10px;line-height:1.45}
.unavailable-feature-composition{display:grid;grid-template-columns:minmax(0,1fr)300px;gap:14px;align-items:start}.unavailable-feature-composition>section:first-child{display:grid;justify-items:start;gap:10px;min-height:260px;align-content:center}.unavailable-feature-composition h3{margin:0;color:#132a2d}.unavailable-feature-composition p{max-width:650px;margin:0;color:#5d6b6d;font-size:12px;line-height:1.55}.unavailable-icon{display:grid;place-items:center;width:42px;height:42px;border-radius:12px;background:#fff4df;color:#b45309;font-size:18px;font-weight:900}
.advisor-lanes{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;align-items:start}.advisor-lanes>section{display:grid;gap:8px;padding:10px;border:1px solid #dce5e3;border-radius:12px;background:#f8faf9}.advisor-lanes>section>header{display:flex;justify-content:space-between;gap:10px;align-items:center}.advisor-lanes h3{margin:0;color:#132a2d;font-size:12px}.advisor-lanes header span{display:grid;place-items:center;min-width:22px;height:22px;border-radius:99px;background:#e6eceb;color:#5d6b6d;font-size:9px;font-weight:850}.advisor-lanes article{display:grid;gap:8px;padding:12px;border:1px solid #e0e8e6;border-radius:10px;background:#fff}.advisor-lanes article>strong{color:#132a2d;font-size:11px}.advisor-lanes article>p{margin:0;color:#71817f;font-size:10px;line-height:1.45}
.asset-library-results.grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.asset-library-results.list{display:grid;gap:9px}.asset-library-results article{overflow:hidden;border:1px solid #dce5e3;border-radius:12px;background:#fff}.asset-library-results.list article{display:grid;grid-template-columns:180px minmax(0,1fr)}.asset-preview{aspect-ratio:1.1;overflow:hidden;background:#edf2f1}.asset-preview img,.asset-preview video{width:100%;height:100%;object-fit:cover}.asset-meta{display:grid;gap:7px;padding:12px}.asset-meta>span{color:#007c78;font-size:9px;font-weight:850;text-transform:uppercase}.asset-meta h3{margin:0;color:#132a2d;font-size:12px}.asset-meta p{margin:0;color:#71817f;font-size:9px}
.credits-summary .workspace-metric-grid{grid-template-columns:repeat(4,minmax(0,1fr))}.credits-composition{display:grid;grid-template-columns:minmax(0,1fr)340px;gap:14px;align-items:start}.credits-right-rail{display:grid;gap:12px;position:sticky;top:14px}.credits-usage-list{display:grid;gap:12px}.credits-usage-list article{display:grid;gap:7px}.credits-usage-list article>div:first-child{display:flex;justify-content:space-between;gap:12px;color:#5d6b6d;font-size:10px}.credits-usage-list strong{color:#132a2d}
@media(max-width:1180px){.radar-card-grid,.goldmine-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.advisor-lanes{grid-template-columns:repeat(2,minmax(0,1fr))}.asset-library-results.grid{grid-template-columns:repeat(3,minmax(0,1fr))}.draft-editor-secondary-grid{grid-template-columns:1fr 1fr}.draft-editor-secondary-grid>section:last-child{grid-column:1/-1}}
@media(max-width:980px){.draft-editor-composition,.market-intelligence-composition,.unavailable-feature-composition,.credits-composition{grid-template-columns:1fr}.draft-editor-rail,.credits-right-rail{position:static;grid-template-columns:repeat(2,minmax(0,1fr))}.draft-editor-media-grid{grid-template-columns:repeat(4,minmax(0,1fr))}.asset-library-results.grid{grid-template-columns:repeat(2,minmax(0,1fr))}.product-intelligence-filterbar{grid-template-columns:1fr 1fr}.product-intelligence-filterbar>div{grid-column:1/-1}}
@media(max-width:720px){.draft-editor-head{display:grid;align-items:start}.draft-editor-rail{grid-template-columns:1fr}.draft-editor-secondary-grid{grid-template-columns:1fr}.draft-editor-secondary-grid>section:last-child{grid-column:auto}.draft-editor-media-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.market-overview-grid .workspace-metric-grid,.credits-summary .workspace-metric-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.radar-card-grid,.goldmine-grid,.advisor-lanes{grid-template-columns:1fr}.library-toolbar{align-items:stretch;flex-wrap:wrap}.library-toolbar input{flex-basis:100%;max-width:none}.asset-library-results.list article{grid-template-columns:110px minmax(0,1fr)}}
@media(max-width:480px){.product-intelligence-filterbar{grid-template-columns:1fr}.product-intelligence-filterbar>div{grid-column:auto}.draft-editor-media-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.market-overview-grid .workspace-metric-grid,.credits-summary .workspace-metric-grid{grid-template-columns:1fr}.asset-library-results.grid{grid-template-columns:1fr}}

/* Seller dashboard parity: journey, creation, credits and tools replace the former operations dashboard. */
html[data-page="app"] body { background:#F5F4EF; }
html[data-page="app"] .workspace-command-bar { grid-template-columns:250px minmax(320px,680px) minmax(360px,1fr); background:#FFFFFF; }
html[data-page="app"] .command-bar-actions .compact-store-context { min-width:auto; padding:0 9px; border:0; background:transparent; }
html[data-page="app"] .command-bar-actions .compact-store-context small { display:none; }
html[data-page="app"] .compact-credit-button { display:inline-flex; align-items:center; gap:6px; min-height:34px; padding:0 10px; border:1px solid #dce5e3; border-radius:9px; background:var(--ac-primary-soft); color:#132A2D; cursor:pointer; }
html[data-page="app"] .compact-credit-button > span { color:var(--ac-primary); }
html[data-page="app"] .compact-credit-button strong { font-size:11px; }
html[data-page="app"] .compact-credit-button small { display:none; }

html[data-page="app"] .os-main-grid { grid-template-columns:250px minmax(0,1fr); }
html[data-page="app"] .dense-sidebar { width:250px; background:#FFFFFF; border-right:1px solid #dce5e3; scrollbar-color:#c8d5d2 transparent; }
html[data-page="app"] .dense-sidebar .sidebar-group-label { color:#7b8b89; }
html[data-page="app"] .dense-sidebar .sidebar-item { position:relative; color:#405456; }
html[data-page="app"] .dense-sidebar .sidebar-item:hover { color:#132A2D; background:#f0f6f4; }
html[data-page="app"] .dense-sidebar .sidebar-item.active { color:#0B2F33; background:#e8f6f3; box-shadow:none; }
html[data-page="app"] .dense-sidebar .sidebar-item.active::before { content:""; position:absolute; left:-2px; top:6px; bottom:6px; width:3px; border-radius:3px; background:#007C78; }
html[data-page="app"] .dense-sidebar .sidebar-icon { color:#007C78; }
html[data-page="app"] .dense-sidebar .nav-state { background:#fff4df; color:#B45309; }
.sidebar-bottom-stack { display:grid; gap:8px; margin-top:18px; padding:10px 4px 0; border-top:1px solid #e3eae8; }
.sidebar-plan-card,.sidebar-profile-card { width:100%; border:1px solid #dce5e3; border-radius:12px; background:#f8faf9; color:#132A2D; text-align:left; cursor:pointer; }
.sidebar-plan-card { display:grid; gap:3px; padding:11px 12px; }
.sidebar-plan-card span,.sidebar-plan-card small,.sidebar-profile-card small { color:#71817f; font-size:9px; }
.sidebar-plan-card strong { font-size:12px; }
.sidebar-plan-card small { color:#007C78; font-weight:750; }
.sidebar-profile-card { display:grid; grid-template-columns:32px minmax(0,1fr); gap:9px; align-items:center; padding:8px; }
.sidebar-profile-card > span:last-child { display:grid; gap:1px; overflow:hidden; }
.sidebar-profile-card strong,.sidebar-profile-card small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.sidebar-profile-avatar { display:grid; place-items:center; width:32px; height:32px; border-radius:9px; background:#0B2F33; color:#FFFFFF; font-size:10px; font-weight:850; }

html[data-page="app"] body.home-mode .center-canvas { padding:24px 28px 52px; background:#F5F4EF; }
.seller-dashboard { display:grid; gap:18px; width:min(1540px,100%); margin:0 auto; }
.seller-dashboard-greeting { display:flex; justify-content:space-between; gap:24px; align-items:flex-end; padding:4px 2px 2px; }
.seller-dashboard-greeting h2 { margin:0; color:#132A2D; font-size:clamp(19px, 1.6vw, 22px); font-weight:800; line-height:1.18; letter-spacing:-0.02em; }
.seller-dashboard-greeting p { margin:6px 0 0; color:#5D6B6D; font-size:13px; }
.seller-dashboard-greeting time { color:#71817f; font-size:12px; white-space:nowrap; }
.seller-dashboard-row { display:grid; grid-template-columns:minmax(0,2.05fr) minmax(310px,.95fr); gap:18px; align-items:stretch; }
.seller-primary-hero,.seller-journey-card,.first-product-card,.seller-credit-card,.seller-tools-section { border:1px solid #dce5e3; border-radius:20px; background:#FFFFFF; box-shadow:0 5px 18px rgba(11,47,51,.045); }
/* --ac-text is redefined here (not just color:#fff on the h3 below) because
   html[data-page="app"] h1,h2,h3,h4 { color:var(--ac-text) } outspecifies any
   single-class heading override - overriding the token itself is what the
   winning rule actually reads. */
.seller-primary-hero { --ac-text:#FFFFFF; display:grid; grid-template-columns:minmax(0,1.35fr) minmax(250px,.65fr); gap:22px; min-height:300px; padding:24px; overflow:hidden; background:linear-gradient(135deg,#0B2F33 0%,#124c50 65%,#0d3b3f 100%); color:#FFFFFF; }
.seller-hero-copy { display:flex; flex-direction:column; align-items:flex-start; justify-content:center; }
.seller-hero-copy > span { color:#75d7cb; font-size:10px; font-weight:900; font-style:italic; letter-spacing:.13em; text-transform:uppercase; }
.seller-hero-copy h3 { max-width:620px; margin:9px 0 10px; color:#FFFFFF; font-size:clamp(26px, 2vw, 30px); font-weight:800; line-height:1.16; letter-spacing:-0.025em; }
.seller-hero-copy p { max-width:610px; margin:0; color:rgba(255,255,255,.7); font-size:14px; line-height:1.6; }
.seller-hero-copy > div { display:flex; flex-wrap:wrap; gap:9px; margin-top:22px; }
.seller-hero-copy button { min-height:44px; padding:0 20px; border-radius:12px; font-size:14px; font-weight:700; cursor:pointer; transition:transform .15s ease-out, box-shadow .15s ease-out, background-color .15s ease-out; }
.seller-hero-copy button:active { transform:translateY(0); }
.seller-hero-copy button:focus-visible { outline:2px solid #fff; outline-offset:2px; }
.seller-hero-primary { border:0; background:linear-gradient(100deg, #3DDBC5 0%, #22B1A0 50%, #007C78 100%); color:#0B2F33; box-shadow:0 4px 16px rgba(0,124,120,.30); }
.seller-hero-primary:hover { transform:translateY(-2px); box-shadow:0 6px 20px rgba(0,124,120,.38); }
.seller-hero-secondary { border:1px solid rgba(255,255,255,.3); background:rgba(255,255,255,.07); color:#FFFFFF; }
.seller-hero-secondary:hover { transform:translateY(-2px); background:rgba(255,255,255,.10); }
.seller-hero-copy small { margin-top:14px; color:rgba(255,255,255,.58); font-size:11px; }
.seller-hero-tiles { display:grid; grid-template-columns:repeat(3,1fr); gap:7px; align-content:center; transform:rotate(-3deg); }
.seller-hero-tiles span { display:grid; place-items:center; aspect-ratio:1; border:1px solid rgba(255,255,255,.12); border-radius:11px; background:linear-gradient(145deg,rgba(255,255,255,.15),rgba(255,255,255,.05)); color:#75d7cb; font-size:18px; box-shadow:0 8px 18px rgba(0,0,0,.11); }
.seller-hero-tiles span:nth-child(2n) { color:#35bfae; transform:translateY(8px); }

.seller-journey-card,.seller-credit-card { padding:16px; }
.seller-journey-card > header,.seller-credit-card > header,.first-product-card > header,.seller-tools-section > header { display:flex; justify-content:space-between; gap:14px; align-items:flex-start; }
.seller-journey-card header span,.seller-credit-card header span,.first-product-card header span,.seller-tools-section header span,#dashboardCreditProduction span { color:#007C78; font-size:9px; font-weight:900; font-style:italic; letter-spacing:.1em; text-transform:uppercase; }
.seller-journey-card h3,.seller-credit-card h3,.first-product-card h3,.seller-tools-section h3 { margin:4px 0 0; color:#132A2D; font-size:16px; }
.seller-journey-card header > strong { color:#007C78; font-size:14px; }
#sellerJourneySteps { display:grid; gap:6px; margin:14px 0; }
.seller-journey-step { display:grid; grid-template-columns:26px minmax(0,1fr); gap:9px; align-items:center; padding:6px; border-radius:10px; }
.seller-journey-step.active { background:#edf8f6; }
.seller-journey-step > span { display:grid; place-items:center; width:24px; height:24px; border:1px solid #d7e1df; border-radius:8px; color:#71817f; font-size:9px; font-weight:850; }
.seller-journey-step.complete > span { border-color:#b8e3c5; background:#ebf8ef; color:#15803D; }
.seller-journey-step.active > span { border-color:#007C78; background:#007C78; color:#FFFFFF; }
.seller-journey-step strong,.seller-journey-step small { display:block; }
.seller-journey-step strong { color:#29484a; font-size:11px; }
.seller-journey-step small { margin-top:2px; color:#879592; font-size:9px; }
#sellerJourneyAction button { width:100%; min-height:38px; }

.first-product-card { padding:18px; }
.first-product-card header p { margin:4px 0 0; color:#71817f; font-size:11px; }
.first-product-options { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:9px; margin-top:15px; }
.first-product-options button { display:grid; grid-template-rows:auto auto 1fr auto; gap:6px; min-height:150px; padding:14px; border:1px solid #dce5e3; border-radius:12px; background:#fbfcfc; color:#132A2D; text-align:left; cursor:pointer; transition:border-color .15s ease-out, transform .15s ease-out; }
.first-product-options button:hover { border-color:color-mix(in srgb, #dce5e3, #007C78 45%); background:#f5fbf9; transform:translateY(-2px); }
.first-product-options button:active { transform:translateY(0); }
.first-product-options button > span { display:grid; place-items:center; width:28px; height:28px; border-radius:9px; background:#e8f6f3; color:#007C78; }
.first-product-options strong { font-size:12px; }
.first-product-options small { color:#71817f; font-size:10px; line-height:1.45; }
.first-product-options em { color:#007C78; font-size:10px; font-style:normal; font-weight:850; }

.seller-credit-card header button,.seller-credit-plans { border:0; background:none; color:#007C78; font-size:10px; font-weight:800; cursor:pointer; }
.seller-credit-value { display:flex; align-items:baseline; gap:7px; margin-top:14px; }
.seller-credit-value strong { color:#132A2D; font-size:28px; line-height:1; }
.seller-credit-value span { color:#71817f; font-size:11px; }
.seller-credit-progress { height:7px; margin:13px 0 9px; overflow:hidden; border-radius:99px; background:#edf2f1; }
.seller-credit-progress span { display:block; height:100%; border-radius:inherit; background:#35bfae; }
.seller-credit-card > p,#dashboardCreditProduction p { margin:0; color:#71817f; font-size:10px; line-height:1.45; }
.seller-credit-card hr { margin:14px 0; border:0; border-top:1px solid #e5ecea; }
#dashboardCreditProduction { display:grid; gap:6px; }
.seller-credit-plans { margin-top:12px; padding:0; }

.seller-tools-section { padding:18px; }
.seller-tools-tabs { display:flex; gap:3px; padding:3px; border-radius:10px; background:#edf2f1; }
.seller-tools-tabs button { min-height:44px; padding:0 12px; border:0; border-radius:8px; background:transparent; color:#5D6B6D; font-size:12.5px; font-weight:800; cursor:pointer; transition:color .15s ease-out, background-color .15s ease-out; }
.seller-tools-tabs button:hover:not(.active) { color:#132A2D; background:rgba(11,47,51,.06); }
.seller-tools-tabs button.active { background:#0B2F33; color:#FFFFFF; }
.seller-tools-tabs button:focus-visible { outline:2px solid #E6A84A; outline-offset:2px; }
.seller-tools-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; margin-top:15px; }
.seller-tools-grid .factory-entry-card { --tc:#007C78; display:grid; grid-template-rows:auto auto 1fr auto; gap:6px; min-height:148px; padding:16px; border:1px solid #dce5e3; border-radius:12px; background:#FFFFFF; box-shadow:none; transition:border-color .15s ease-out, box-shadow .15s ease-out, transform .15s ease-out; }
.seller-tools-grid .factory-entry-card:hover { border-color:color-mix(in srgb, #dce5e3, var(--tc) 55%); box-shadow:0 2px 4px rgba(19,42,45,.06), 0 10px 26px rgba(19,42,45,.10); transform:translateY(-2px); }
.seller-tools-grid .factory-entry-card:active { transform:translateY(0); }
.seller-tools-grid .factory-entry-card-icon { display:grid; place-items:center; width:30px; height:30px; border-radius:10px; background:color-mix(in srgb, var(--tc) 12%, #FFFFFF); color:var(--tc); }
.seller-tools-grid .factory-entry-card h3 { margin:0; color:#132A2D; font-size:12px; }
.seller-oneclick-promo { --ac-text:#FFFFFF; display:grid; grid-template-columns:minmax(0,1.5fr) minmax(120px,.6fr); gap:18px; align-items:center; padding:22px 24px; border:1px solid #dce5e3; border-radius:20px; background:linear-gradient(135deg,#0B2F33 0%,#124c50 65%,#0d3b3f 100%); box-shadow:0 5px 18px rgba(11,47,51,.045); }
.seller-oneclick-copy > p:first-child { margin:0; color:#75d7cb; font-size:10px; font-weight:900; letter-spacing:.13em; text-transform:uppercase; }
.seller-oneclick-copy h3 { margin:8px 0 7px; color:#fff; font-size:20px; line-height:1.25; }
.seller-oneclick-copy > p:nth-child(3) { max-width:520px; margin:0 0 16px; color:rgba(255,255,255,.7); font-size:13px; line-height:1.55; }
.seller-oneclick-copy button { min-height:42px; padding:0 18px; border:0; border-radius:10px; background:#35BFAE; color:#0B2F33; font-weight:800; cursor:pointer; }
.seller-oneclick-copy small { display:block; margin-top:10px; color:rgba(255,255,255,.55); font-size:11px; }
.seller-oneclick-art { width:100%; max-width:130px; justify-self:end; }
@media (max-width:900px) { .seller-oneclick-promo { grid-template-columns:1fr; } .seller-oneclick-art { display:none; } }
.seller-tools-grid .factory-entry-card p { margin:0; color:#71817f; font-size:10px; line-height:1.45; }
.seller-tools-grid .factory-entry-card button { justify-self:start; min-height:auto; padding:0; border:0; background:none; color:#007C78; font-size:10px; font-weight:850; }

@media(max-width:1180px){html[data-page="app"] .workspace-command-bar{grid-template-columns:220px minmax(260px,1fr) auto}html[data-page="app"] .os-main-grid{grid-template-columns:220px minmax(0,1fr)}html[data-page="app"] .dense-sidebar{width:220px}.seller-dashboard-row{grid-template-columns:minmax(0,1.6fr) minmax(280px,.9fr)}.seller-primary-hero{grid-template-columns:1fr}.seller-hero-tiles{display:none}.seller-tools-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:980px){.sidebar-bottom-stack{display:none}.seller-dashboard-row{grid-template-columns:1fr}.seller-dashboard-secondary-row{grid-template-columns:1fr 1fr}.seller-tools-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){html[data-page="app"] body.home-mode .center-canvas{padding:16px 12px 34px}.seller-dashboard-greeting{display:grid}.seller-dashboard-greeting h2{font-size:24px}.seller-dashboard-greeting time{grid-row:1}.seller-primary-hero{min-height:0;padding:23px}.seller-hero-copy h3{font-size:29px}.seller-dashboard-secondary-row{grid-template-columns:1fr}.first-product-options{grid-template-columns:1fr}.first-product-options button{min-height:120px}.seller-tools-section>header{display:grid}.seller-tools-tabs{width:100%}.seller-tools-tabs button{flex:1}.seller-tools-grid{grid-template-columns:1fr}}

/* Command Center rebuild: composition, not a legacy card skin. */
html[data-page="app"] .workspace-command-bar { min-height:72px; height:72px; display:grid; grid-template-columns:270px minmax(280px, 620px) minmax(390px, 1fr); gap:22px; align-items:center; padding:0 18px; background:#fff; border-bottom:1px solid #dfe7e5; box-shadow:0 1px 0 rgba(11,47,51,.03); }
.command-bar-brand { min-width:0; }
.topbar-context { display:grid; gap:2px; min-width:0; padding-left:12px; border-left:1px solid #dfe7e5; }
.topbar-context span { color:#71817f; font-size:10px; font-weight:800; letter-spacing:.08em; text-transform:uppercase; }
.topbar-context strong { overflow:hidden; color:#173d40; font-size:13px; text-overflow:ellipsis; white-space:nowrap; }
.topbar-command-search { display:grid; grid-template-columns:20px minmax(0,1fr) auto; gap:10px; align-items:center; min-height:42px; padding:0 12px; border:1px solid #d7e1df; border-radius:10px; background:#f7f9f8; transition:border-color .16s, box-shadow .16s; }
.topbar-command-search.focused { border-color:#007c78; box-shadow:0 0 0 3px rgba(0,124,120,.09); background:#fff; }
.topbar-command-search input { width:100%; border:0; outline:0; background:transparent; color:#173d40; font:inherit; }
.topbar-command-search kbd { padding:3px 7px; border:1px solid #d7e1df; border-radius:5px; background:#fff; color:#71817f; font-size:10px; }
.command-bar-actions { justify-content:flex-end; min-width:0; }
.command-bar-actions .connection-status { display:flex; align-items:center; gap:8px; }
.command-bar-actions .connection-status > span:not(.connection-dot) { display:grid; text-align:left; }
.command-bar-actions .connection-status small { color:#71817f; font-size:9px; font-weight:700; text-transform:uppercase; }
.command-bar-actions .connection-status strong { font-size:11px; }
.topbar-help { display:grid; place-items:center; text-decoration:none; }

html[data-page="app"] .os-main-grid { grid-template-columns:270px minmax(0,1fr); min-height:calc(100vh - 72px); }
html[data-page="app"] .dense-sidebar { width:270px; max-height:calc(100vh - 72px); position:sticky; top:0; display:block; padding:15px 10px 24px; overflow-y:auto; scrollbar-width:thin; scrollbar-color:rgba(255,255,255,.22) transparent; }
html[data-page="app"] .dense-sidebar .sidebar-group { display:grid; gap:2px; margin-bottom:16px; }
html[data-page="app"] .dense-sidebar .sidebar-group-label { display:block; padding:0 10px 6px; color:rgba(255,255,255,.42); font-size:9px; letter-spacing:.13em; }
html[data-page="app"] .dense-sidebar .sidebar-item { display:grid; grid-template-columns:24px minmax(0,1fr) auto; align-items:center; width:100%; min-height:32px; padding:5px 9px; border-radius:7px; color:rgba(255,255,255,.72); font-size:12px; text-decoration:none; }
html[data-page="app"] .dense-sidebar .sidebar-item:hover { color:#fff; background:rgba(53,191,174,.11); }
html[data-page="app"] .dense-sidebar .sidebar-item.active { color:#fff; background:#007c78; box-shadow:none; }
html[data-page="app"] .dense-sidebar .sidebar-icon { display:grid; place-items:center; width:20px; height:20px; color:#78d6ca; font-size:12px; font-weight:800; }
html[data-page="app"] .dense-sidebar .nav-state { padding:2px 5px; border-radius:999px; background:rgba(230,168,74,.16); color:#f2c16d; font-size:8px; font-weight:800; text-transform:uppercase; }
html[data-page="app"] body.nav-collapsed .os-main-grid { grid-template-columns:68px minmax(0,1fr); }
html[data-page="app"] body.nav-collapsed .dense-sidebar { width:68px; }
html[data-page="app"] body.nav-collapsed .dense-sidebar .sidebar-item { display:flex; justify-content:center; }
html[data-page="app"] body.nav-collapsed .dense-sidebar .sidebar-label,
html[data-page="app"] body.nav-collapsed .dense-sidebar .nav-state { display:none; }

html[data-page="app"] body.home-mode .workspace-grid { display:grid; grid-template-columns:minmax(0,1fr); }
html[data-page="app"] body.home-mode .research-rail,
html[data-page="app"] body.home-mode .ai-brain { display:none; }
html[data-page="app"] body.home-mode .center-canvas { width:100%; padding:20px 24px 42px; background:#f3f6f5; }
html[data-page="app"] body.home-mode .workspace-top { margin:0 0 14px; padding:0; background:transparent; border:0; }
html[data-page="app"] body.home-mode .route-page-title h1 { font-size:13px; color:#607371; }
html[data-page="app"] body.home-mode .route-page-title p,
html[data-page="app"] body.home-mode .workflow-strip { display:none; }

.command-dashboard { display:grid; gap:16px; max-width:1600px; margin:0 auto; }
.dashboard-hero { display:flex; justify-content:space-between; gap:24px; align-items:flex-end; padding:20px 22px; border:1px solid #dce5e3; border-radius:14px; background:linear-gradient(120deg,#fff 0%,#f8fbfa 62%,#eaf7f4 100%); }
.dashboard-kicker { margin:0 0 5px; color:#007c78; font-size:10px; font-weight:900; letter-spacing:.12em; text-transform:uppercase; }
.dashboard-hero h2 { margin:0; color:#123c3e; font-size:25px; line-height:1.15; }
.dashboard-hero p:not(.dashboard-kicker) { max-width:720px; margin:7px 0 0; color:#657876; font-size:13px; }
.dashboard-hero-actions { display:flex; gap:8px; flex:0 0 auto; }
.dashboard-kpi-row { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; }
.dashboard-kpi { display:grid; gap:5px; min-height:108px; padding:15px 16px; border:1px solid #dce5e3; border-radius:12px; background:#fff; text-align:left; }
.dashboard-kpi:hover { border-color:#72c7bd; transform:translateY(-1px); }
.dashboard-kpi span { color:#667976; font-size:11px; font-weight:750; }
.dashboard-kpi strong { color:#123c3e; font-size:25px; line-height:1; }
.dashboard-kpi small { color:#879794; font-size:10px; }
.dashboard-layout { display:grid; grid-template-columns:minmax(0,1fr) 294px; gap:14px; align-items:start; }
.dashboard-main-column { display:grid; gap:14px; min-width:0; }
.dashboard-primary-grid { display:grid; grid-template-columns:minmax(0,1.05fr) minmax(0,.95fr); gap:14px; }
.dashboard-panel,.utility-card { min-width:0; border:1px solid #dce5e3; border-radius:12px; background:#fff; }
.dashboard-panel { padding:17px; }
.dashboard-panel-head,.utility-card-head { display:flex; justify-content:space-between; gap:14px; align-items:flex-start; margin-bottom:14px; }
.dashboard-panel-head span { color:#7b8b89; font-size:9px; font-weight:900; letter-spacing:.1em; text-transform:uppercase; }
.dashboard-panel-head h3 { margin:3px 0 0; color:#173d40; font-size:16px; }
.dashboard-panel-head button,.utility-card-head button { padding:4px 0; border:0; background:none; color:#007c78; font-size:11px; font-weight:800; }
.operator-panel { background:linear-gradient(145deg,#0b2f33,#12484b); color:#fff; border-color:#0b2f33; }
.operator-panel .dashboard-panel-head span,.operator-panel .dashboard-panel-head button { color:#75d7cb; }
.operator-panel .dashboard-panel-head h3 { color:#fff; }
.operator-panel .today-operating-list article { border-color:rgba(255,255,255,.12); background:rgba(255,255,255,.07); color:#fff; }
.operator-progress { display:grid; gap:7px; margin-top:14px; padding-top:13px; border-top:1px solid rgba(255,255,255,.13); }
.operator-progress > div:first-child { display:flex; justify-content:space-between; gap:12px; font-size:11px; }
.operator-progress p,.operator-progress small { margin:0; color:rgba(255,255,255,.65); font-size:11px; }
.operator-progress-track { height:6px; overflow:hidden; border-radius:99px; background:rgba(255,255,255,.12); }
.operator-progress-track span { display:block; height:100%; border-radius:inherit; background:#35bfae; }
.dashboard-analytics { display:grid; gap:16px; }
.analytics-bars { display:grid; gap:11px; }
.analytics-bars > div { display:grid; grid-template-columns:90px minmax(0,1fr) 28px; gap:9px; align-items:center; color:#607371; font-size:11px; }
.analytics-bars > div > div { height:7px; overflow:hidden; border-radius:99px; background:#edf2f1; }
.analytics-bars i { display:block; height:100%; border-radius:inherit; background:#007c78; }
.dashboard-analytics p { margin:0; color:#7a8c89; font-size:11px; line-height:1.5; }
.dashboard-table-wrap { overflow-x:auto; }
.dashboard-table { width:100%; min-width:680px; border-collapse:collapse; }
.dashboard-table th,.dashboard-table td { padding:10px 9px; border-bottom:1px solid #e5ecea; text-align:left; vertical-align:middle; font-size:11px; }
.dashboard-table th { color:#84928f; font-size:9px; letter-spacing:.06em; text-transform:uppercase; }
.dashboard-table td strong,.dashboard-table td small { display:block; max-width:290px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.dashboard-table td small { margin-top:3px; color:#8a9996; font-size:9px; }
.dashboard-table td button { border:0; background:none; color:#007c78; font-size:10px; font-weight:800; }
.dashboard-tabs { display:flex; gap:4px; padding:3px; border-radius:8px; background:#f0f4f3; }
.dashboard-tabs button { padding:5px 9px; border-radius:6px; color:#71817f; }
.dashboard-tabs button.active { background:#fff; color:#007c78; box-shadow:0 1px 4px rgba(11,47,51,.08); }
.dashboard-opportunity-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.dashboard-opportunity-grid article { display:grid; gap:9px; padding:13px; border:1px solid #e0e8e6; border-radius:10px; background:#fbfcfc; }
.dashboard-opportunity-grid article span { color:#007c78; font-size:9px; font-weight:850; text-transform:uppercase; }
.dashboard-opportunity-grid article strong { display:block; margin-top:3px; color:#173d40; font-size:13px; }
.dashboard-opportunity-grid article p { margin:0; color:#70817e; font-size:11px; line-height:1.45; }
.dashboard-opportunity-grid article button,.dashboard-empty button { justify-self:start; border:0; background:none; color:#007c78; font-size:10px; font-weight:850; }
.dashboard-utility-rail { display:grid; gap:12px; position:sticky; top:14px; }
.utility-card { padding:14px; }
.utility-card > span { color:#81908e; font-size:9px; font-weight:900; letter-spacing:.08em; text-transform:uppercase; }
.store-context-card strong { display:block; margin:6px 0 12px; color:#173d40; font-size:14px; }
.store-context-card > button { width:100%; padding:8px; border:1px solid #bcd7d2; border-radius:8px; background:#edf8f6; color:#007c78; font-size:11px; font-weight:850; }
.utility-card-head strong { color:#173d40; font-size:12px; }
.utility-card-head > span { display:grid; place-items:center; min-width:21px; height:21px; border-radius:99px; background:#f0f4f3; color:#617572; font-size:10px; font-weight:850; }
#dashboardWarnings { display:grid; gap:7px; }
#dashboardWarnings button { display:grid; gap:3px; width:100%; padding:9px; border:1px solid #f0dfbd; border-radius:8px; background:#fffaf0; text-align:left; }
#dashboardWarnings strong { color:#71521c; font-size:10px; }
#dashboardWarnings span { color:#89734b; font-size:9px; line-height:1.4; }
#dashboardActivity { display:grid; gap:9px; }
#dashboardActivity article { display:grid; grid-template-columns:7px minmax(0,1fr); gap:8px; align-items:start; }
#dashboardActivity article > span { width:7px; height:7px; margin-top:4px; border-radius:50%; background:#35bfae; }
#dashboardActivity strong,#dashboardActivity small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
#dashboardActivity strong { color:#294b4d; font-size:10px; }
#dashboardActivity small { margin-top:2px; color:#879592; font-size:9px; }
.dashboard-empty,.utility-empty { margin:0; padding:14px; border:1px dashed #d7e1df; border-radius:9px; color:#778986; font-size:11px; text-align:center; }
.dashboard-empty p { margin:5px 0; }
.dashboard-utility-rail .growth-advisor-item { padding:8px 0; border:0; border-top:1px solid #e6eceb; border-radius:0; }

@media (max-width:1240px) {
  html[data-page="app"] .workspace-command-bar { grid-template-columns:240px minmax(230px,1fr) auto; }
  html[data-page="app"] .os-main-grid { grid-template-columns:240px minmax(0,1fr); }
  html[data-page="app"] .dense-sidebar { width:240px; }
  .dashboard-layout { grid-template-columns:minmax(0,1fr) 260px; }
  .dashboard-primary-grid { grid-template-columns:1fr; }
}
@media (max-width:980px) {
  html[data-page="app"] .workspace-command-bar { height:auto; min-height:64px; grid-template-columns:auto minmax(220px,1fr) auto; gap:12px; }
  .topbar-context,.command-bar-actions .ai-credit-indicator,.command-bar-actions [data-i18n-switcher] { display:none; }
  html[data-page="app"] .os-main-grid { grid-template-columns:68px minmax(0,1fr); }
  html[data-page="app"] .dense-sidebar { width:68px; max-height:calc(100vh - 64px); }
  html[data-page="app"] .dense-sidebar .sidebar-group-label,.dense-sidebar .sidebar-label,.dense-sidebar .nav-state { display:none !important; }
  html[data-page="app"] .dense-sidebar .sidebar-item { display:flex; justify-content:center; }
  .dashboard-layout { grid-template-columns:1fr; }
  .dashboard-utility-rail { position:static; grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:720px) {
  html[data-page="app"] .workspace-command-bar { grid-template-columns:auto 1fr; padding:8px 10px; }
  .topbar-command-search { grid-column:1 / -1; grid-row:2; }
  .command-bar-actions .connection-status,.command-bar-actions .icon-circle,.command-bar-actions .profile-pill { display:none; }
  html[data-page="app"] .os-main-grid { display:block; }
  html[data-page="app"] .dense-sidebar { position:static; width:100%; max-height:none; display:flex; overflow-x:auto; padding:6px 8px; }
  html[data-page="app"] .dense-sidebar .sidebar-group { display:contents; }
  html[data-page="app"] .dense-sidebar .sidebar-item { display:none; flex:0 0 46px; width:46px; min-height:42px; }
  html[data-page="app"] .dense-sidebar [data-app-route="home"],html[data-page="app"] .dense-sidebar [data-app-route="product-intelligence"],html[data-page="app"] .dense-sidebar [data-app-route="product-factory"],html[data-page="app"] .dense-sidebar [data-app-route="draft-queue"],html[data-page="app"] .dense-sidebar .mobile-more-trigger { display:flex; }
  html[data-page="app"] body.home-mode .center-canvas { padding:14px 12px 28px; }
  .dashboard-hero { display:grid; align-items:start; }
  .dashboard-hero-actions { width:100%; }
  .dashboard-hero-actions button { flex:1; }
  .dashboard-kpi-row { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .dashboard-opportunity-grid,.dashboard-utility-rail { grid-template-columns:1fr; }
}

/* Final seller-shell overrides must follow the retired Command Center block. */
html[data-page="app"] .workspace-command-bar { grid-template-columns:220px minmax(320px,680px) minmax(360px,1fr); }
html[data-page="app"] .os-main-grid { grid-template-columns:220px minmax(0,1fr); }
html[data-page="app"] .dense-sidebar { width:220px; background:#FFFFFF; border-right:1px solid #dce5e3; scrollbar-color:#c8d5d2 transparent; }
html[data-page="app"] .dense-sidebar .sidebar-group-label { color:#7b8b89; }
html[data-page="app"] .dense-sidebar .sidebar-item { position:relative; color:#405456; }
html[data-page="app"] .dense-sidebar .sidebar-item:hover { color:#132A2D; background:#f0f6f4; }
html[data-page="app"] .dense-sidebar .sidebar-item.active { color:#0B2F33; background:#e8f6f3; }
html[data-page="app"] .dense-sidebar .sidebar-icon { color:#007C78; }
html[data-page="app"] body.home-mode .center-canvas { padding:24px 28px 52px; background:#F5F4EF; }
@media(max-width:1180px){html[data-page="app"] .workspace-command-bar{grid-template-columns:220px minmax(260px,1fr) auto}html[data-page="app"] .os-main-grid{grid-template-columns:220px minmax(0,1fr)}html[data-page="app"] .dense-sidebar{width:220px}}
@media(max-width:980px){html[data-page="app"] .workspace-command-bar{grid-template-columns:auto minmax(220px,1fr) auto}html[data-page="app"] .os-main-grid{grid-template-columns:68px minmax(0,1fr)}html[data-page="app"] .dense-sidebar{width:68px}.sidebar-bottom-stack{display:none}}
@media(max-width:720px){html[data-page="app"] .workspace-command-bar{grid-template-columns:auto 1fr}html[data-page="app"] .os-main-grid{display:block}html[data-page="app"] .dense-sidebar{width:100%;background:#FFFFFF}html[data-page="app"] body.home-mode .center-canvas{padding:16px 12px 34px}}

/* Screenshot-led Optimsy composition: fewer surfaces, one purpose per route. */
html[data-page="app"] body.no-activity-rail .workspace-grid { grid-template-columns:minmax(0,1fr); }
html[data-page="app"] body.no-activity-rail .research-rail,
html[data-page="app"] body.no-activity-rail .ai-brain,
html[data-page="app"] body.no-activity-rail .workflow-strip { display:none; }
html[data-page="app"] body.no-activity-rail .center-canvas { width:100%; padding:32px; background:#f6f7f6; }

.optimsy-page-shell { display:grid; gap:20px; width:min(1240px,100%); margin:0 auto; }
.optimsy-page-head { display:flex; justify-content:space-between; gap:24px; align-items:center; padding:2px 0; }
.optimsy-page-title { display:flex; gap:14px; align-items:center; }
.optimsy-page-icon { display:grid; place-items:center; flex:0 0 48px; width:48px; height:48px; border-radius:15px; background:#e7f4f1; color:#007c78; font-size:20px; font-weight:850; }
.optimsy-page-title h2 { margin:0; color:#132a2d; font-size:25px; letter-spacing:-.02em; }
.optimsy-page-title p { margin:5px 0 0; color:#6f7f80; font-size:13px; }
.optimsy-connection-state { display:inline-flex; align-items:center; gap:7px; padding:7px 11px; border:1px solid #d9e5e2; border-radius:999px; background:#fff; color:#506466; font-size:11px; font-weight:750; }
.optimsy-connection-state::before { content:""; width:7px; height:7px; border-radius:50%; background:#35bfae; }
.optimsy-info-banner { display:flex; justify-content:space-between; gap:24px; align-items:center; padding:16px 18px; border:1px solid #cfe6e1; border-radius:16px; background:#edf8f6; }
.optimsy-info-banner strong { color:#174648; font-size:13px; }
.optimsy-info-banner p { margin:4px 0 0; color:#607574; font-size:12px; }
.optimsy-main-surface { min-height:430px; padding:24px; border:1px solid #e0e6e4; border-radius:22px; background:#fff; box-shadow:0 5px 18px rgba(11,47,51,.035); }
.optimsy-empty-state { display:grid; justify-items:center; align-content:center; min-height:350px; padding:40px; text-align:center; }
.optimsy-empty-state > span { display:grid; place-items:center; width:60px; height:60px; margin-bottom:15px; border-radius:18px; background:#edf6f4; color:#007c78; font-size:25px; }
.optimsy-empty-state h3 { margin:0; color:#132a2d; font-size:19px; }
.optimsy-empty-state p { max-width:520px; margin:8px 0 18px; color:#708082; font-size:13px; line-height:1.55; }
.optimsy-empty-state > div { display:flex; gap:9px; }

.publish-toolbar { display:flex; justify-content:space-between; gap:16px; align-items:center; padding-bottom:18px; }
.publish-toolbar > input { width:min(420px,100%); min-height:42px; padding:0 14px; border:1px solid #dbe4e2; border-radius:12px; background:#fafbfb; }
.publish-toolbar > div { display:flex; gap:8px; }
.publish-tabs { display:flex; gap:24px; padding:0 3px; border-bottom:1px solid #e5eae9; }
.publish-tabs button { display:flex; gap:7px; align-items:center; padding:11px 2px; border:0; border-bottom:2px solid transparent; border-radius:0; background:transparent; color:#718181; font-size:12px; font-weight:750; }
.publish-tabs button.active { border-color:#007c78; background:transparent; color:#007c78; }
.publish-tabs button span { display:grid; place-items:center; min-width:20px; height:20px; padding:0 5px; border-radius:999px; background:#eef3f2; font-size:9px; }
.publish-clean-content { display:grid; gap:0; min-height:350px; }
.publish-queue-row { display:grid; grid-template-columns:minmax(220px,1fr) auto auto; gap:18px; align-items:center; padding:17px 4px; border-bottom:1px solid #e8eceb; }
.publish-queue-copy strong,.publish-queue-copy small { display:block; }
.publish-queue-copy strong { color:#203d3f; font-size:13px; }
.publish-queue-copy small { margin-top:4px; color:#8a9897; font-size:10px; }
.publish-queue-readiness { display:flex; gap:7px; flex-wrap:wrap; }

.optimsy-store-state { display:grid; align-content:center; }
.shop-simple-identity { display:flex; justify-content:space-between; gap:20px; align-items:center; padding:4px 0 22px; border-bottom:1px solid #e6ebea; }
.shop-simple-identity h3 { margin:5px 0; color:#173d40; font-size:20px; }
.shop-simple-identity p { margin:0; color:#7a8989; font-size:11px; }
.shop-simple-metrics { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:0; padding:22px 0; border-bottom:1px solid #e6ebea; }
.shop-simple-metrics > div { display:grid; gap:5px; padding:0 22px; border-left:1px solid #e6ebea; }
.shop-simple-metrics > div:first-child { padding-left:0; border-left:0; }
.shop-simple-metrics span { color:#7b8989; font-size:10px; font-weight:750; }
.shop-simple-metrics strong { color:#173d40; font-size:20px; }
.shop-simple-section { padding-top:24px; }
.shop-simple-listings { overflow-x:auto; }
.shop-simple-listings .competitor-table { min-width:680px; }

/* Secondary routes inherit the same quieter canvas without fabricating a reference layout. */
#view-store-connect .store-connect-shell,
#view-growth-tools .workspace-page-shell,
#view-trend-library .workspace-page-shell,
#view-mockup-studio .workspace-page-shell,
#view-video-studio .workspace-page-shell,
#view-credits .workspace-page-shell { width:min(1240px,100%); margin:0 auto; }
#view-mockup-studio .studio-status-summary,
#view-video-studio .studio-status-summary { display:none; }
#view-mockup-studio .verified-studio-preview { position:sticky; top:14px; align-self:start; }
/* Both #view-video-studio's and #view-mockup-studio's real two-column
   layouts (real left controls, real right canvas/gallery, both visible
   at once - the whole point of these pages) used to be force-collapsed
   to one column here via stale ID-scoped overrides referencing dead
   classes (.photo-studio-composition, .photo-control-rail) left over
   from when these pages were still disabled placeholders. Removed for
   both - the real build's own .verified-studio-layout grid (2 columns,
   side by side) is what actually renders now that these stale overrides
   are gone. The mockup-studio gallery panel additionally gets
   position:sticky above to match Optimsy's right-panel behavior. */

@media(max-width:720px){
  html[data-page="app"] body.no-activity-rail .center-canvas{padding:18px 12px 34px}
  .optimsy-page-head,.optimsy-info-banner,.publish-toolbar,.shop-simple-identity{align-items:flex-start;flex-direction:column}
  .optimsy-main-surface{min-height:360px;padding:17px;border-radius:18px}
  .publish-toolbar>input{width:100%}.publish-toolbar>div{width:100%}.publish-toolbar>div button{flex:1}
  .publish-tabs{gap:12px;overflow-x:auto}.publish-queue-row{grid-template-columns:1fr}.publish-queue-row>button{justify-self:start}
  .shop-simple-metrics{grid-template-columns:1fr}.shop-simple-metrics>div{padding:12px 0;border-left:0;border-top:1px solid #e6ebea}.shop-simple-metrics>div:first-child{border-top:0}
  .optimsy-empty-state{min-height:300px;padding:24px 10px}
}

/* Screenshot-driven parity pass: compact rhythm and single-purpose surfaces. */
html[data-page="app"] .sidebar-nav-scroll{gap:10px;padding-top:10px!important}
html[data-page="app"] .dense-sidebar .sidebar-group{gap:3px}
html[data-page="app"] .dense-sidebar .sidebar-item{min-height:40px;padding-top:6px;padding-bottom:6px}
html[data-page="app"] .dense-sidebar .sidebar-label{overflow:visible;text-overflow:clip;white-space:normal;line-height:1.2}

.radar-pagination{display:flex;justify-content:center;gap:6px;padding:0;border-top:0}
.radar-pagination button{display:grid;place-items:center;min-width:34px;height:34px;padding:0 9px;border:1px solid #dce7e4;border-radius:10px;background:#fff;color:#5d6b6d;font-weight:700;cursor:pointer}
.radar-pagination button.active{border-color:#007c78;background:#e8f6f3;color:#0b2f33}
.radar-pagination-row{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:18px 20px;border-top:1px solid #e4ebe9}
.radar-pagination-summary{margin:0;color:#71817f;font-size:11px}
.radar-info-link{margin:8px 0 0}
.radar-info-link button{border:0;background:none;padding:0;color:#007c78;font-size:11px;font-weight:700;text-decoration:underline;cursor:pointer}
.radar-info-note{margin-top:8px;padding:12px 14px;border:1px solid #e1e9e7;border-radius:12px;background:#fbfcfc;color:#405456;font-size:11px;line-height:1.55}
.radar-methodology-note{margin:0;padding:14px 20px;border-top:1px solid #e4ebe9;color:#8a9795;font-size:10px;line-height:1.6}
.radar-window-filter button[disabled]{cursor:not-allowed;opacity:.65}

/* Verified Optimsy structural archetypes. */
.verified-studio-layout{display:grid;grid-template-columns:minmax(0,1.08fr) minmax(340px,.92fr);gap:20px;align-items:start}
.verified-studio-input,.verified-studio-preview{display:grid;gap:18px;min-width:0;padding:22px;border:1px solid #e1e9e7;border-radius:18px;background:#fff}
.verified-studio-input label{display:grid;gap:7px;color:#405456;font-size:13px;font-weight:700}
.verified-studio-input input,.verified-studio-input textarea,.verified-studio-input select{width:100%;border:1px solid #dce7e4;border-radius:12px;background:#fbfcfc;color:#132a2d}
.studio-option-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;margin-top:9px}
.studio-option-card{min-height:62px;padding:10px;border:1px solid #dce7e4;border-radius:12px;background:#fff;color:#405456;font-size:12px;font-weight:750;text-align:left;cursor:pointer;transition:border-color .15s ease-out,box-shadow .15s ease-out,transform .15s ease-out}
.studio-option-card:hover{border-color:color-mix(in srgb,#dce7e4,#007C78 45%);box-shadow:0 6px 16px rgba(19,42,45,.08);transform:translateY(-2px)}
.studio-option-card:active{transform:translateY(0)}
.studio-option-card.active{border-color:#35bfae;background:#edf9f6;color:#0b2f33}
.studio-upload-slot{display:grid;place-items:center;min-height:92px;border:1px dashed #b9cbc7;border-radius:14px;background:#f8fbfa;color:#718181;cursor:pointer;transition:border-color .15s ease-out,background-color .15s ease-out}
.studio-upload-slot:hover{border-color:#35bfae;background:#f2fbf9}
.video-studio-upload{position:relative;min-height:120px;padding:10px;overflow:hidden;text-align:center}
.video-studio-upload small{grid-column:1/-1;margin-top:4px;color:#8a9997;font-size:10px}
.video-studio-upload.has-file{border-style:solid;padding:0}
.video-studio-upload img{width:100%;max-height:160px;object-fit:cover;border-radius:13px}
.video-studio-validation{margin:6px 0 0;color:#a15c00;font-size:11px;font-weight:700}
.video-studio-usage-note{margin:8px 0 0;color:#71817f;font-size:10px}
.video-studio-actions{display:flex;gap:8px}
.studio-numbered-step{display:grid;grid-template-columns:24px minmax(0,1fr);gap:10px;margin-top:16px}
.studio-step-number{padding-top:2px;color:#007C78;font-size:11px;font-weight:850}
.studio-step-body{display:grid;gap:8px;min-width:0}
.video-studio-movement-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(88px,1fr));gap:8px}
.video-studio-movement-card{padding:0}
.video-studio-movement-card .clipart-style-swatch{aspect-ratio:4/3}
.video-studio-movement-card .clipart-style-label{font-size:10px;padding:5px 6px}
.video-studio-motion-label{display:grid;gap:5px;margin-top:2px;color:#71817f;font-size:10px;font-weight:700}
.video-studio-motion-label textarea{width:100%;padding:9px 11px;border:1px solid #dce5e3;border-radius:11px;background:#fafbfb;font-family:inherit}
.video-studio-step-pills{display:flex;flex-wrap:wrap;justify-content:center;gap:8px;margin-top:14px}
.video-studio-step-pill{display:inline-flex;align-items:center;gap:6px;padding:6px 12px;border-radius:999px;background:#edf2f1;color:#405456;font-size:11px;font-weight:700}
.video-studio-step-pill strong{display:grid;place-items:center;width:16px;height:16px;border-radius:999px;background:#0B2F33;color:#fff;font-size:9px}
.studio-choice-row{display:flex;flex-wrap:wrap;gap:8px;padding:0;border:0}
.studio-choice-row legend{width:100%;margin-bottom:4px;color:#405456;font-size:12px;font-weight:800;text-transform:uppercase}
.studio-choice-row label{display:flex;grid-template-columns:auto 1fr;align-items:center;gap:6px;min-height:38px;padding:8px 11px;border:1px solid #dce7e4;border-radius:11px;background:#fff}
.studio-choice-row input{width:auto}
.studio-preview-toggle,.seo-research-mode{display:inline-flex;justify-self:start;gap:4px;padding:4px;border:1px solid #dce7e4;border-radius:12px;background:#f5f8f7}
.studio-preview-toggle button,.seo-research-mode button{min-height:34px;padding:7px 13px;border:0;border-radius:9px;background:transparent;color:#5d6b6d;font-weight:750}
.studio-preview-toggle button.active,.seo-research-mode button.active{background:#0b2f33;color:#fff}
.studio-primary-preview{display:grid;place-items:center;min-height:420px;overflow:hidden;border:1px solid #e1e9e7;border-radius:16px;background:#f7f9f8}
.studio-primary-preview.vertical{max-width:390px;min-height:500px;justify-self:center;width:100%}
.studio-primary-preview video{width:100%;max-height:520px;background:#0b2f33}
.studio-reference-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;margin-top:8px}
.studio-reference-slot{aspect-ratio:1;border:1px dashed #b9cbc7;border-radius:12px;background:#f8fbfa;color:#718181}
.studio-result-slot{display:grid;gap:10px;padding:16px;border:1px solid #e1e9e7;border-radius:14px}
.coloring-page-slots{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:9px}
.coloring-page-slots article{display:grid;place-items:center;gap:8px;min-height:130px;border:1px dashed #b9cbc7;border-radius:12px;background:#f8fbfa;color:#718181}
.coloring-page-slots .cover-slot{border-style:solid;background:#edf8f6;color:#0b2f33}
.ebook-step-head{display:grid;gap:10px}.ebook-step-head>span{font-size:12px;font-weight:850;color:#007c78}.ebook-step-head>div{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}.ebook-step-head i{display:grid;place-items:center;height:34px;border-radius:10px;background:#eef3f2;color:#718181;font-style:normal}.ebook-step-head i.active{background:#0b2f33;color:#fff}
.photo-gallery-slots{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
.photo-gallery-slots--cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}
.photo-gallery-slots--cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}
.photo-gallery-slots--cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}
.photo-gallery-slot{position:relative;display:grid;place-items:center;min-height:125px;overflow:hidden;border:1px dashed #b9cbc7;border-radius:12px;background:#f8fbfa;color:#718181;font-size:11px;font-weight:750;text-transform:uppercase;cursor:pointer;transition:border-color .15s ease-out,transform .15s ease-out}
.photo-gallery-slot:hover{border-color:#35bfae;transform:translateY(-2px)}
.photo-gallery-slot.selected{border-style:solid;border-color:#007C78;box-shadow:0 0 0 2px rgba(0,124,120,.18)}
.photo-gallery-slot.closed{opacity:.62}.photo-gallery-slot img{width:100%;height:100%;object-fit:cover}
.photo-gallery-slot-index{position:absolute;top:6px;left:6px;display:grid;place-items:center;width:18px;height:18px;border-radius:999px;background:#fff;color:#132A2D;font-size:9px;font-weight:850;text-transform:none}
.photo-gallery-slot-dot{position:absolute;top:8px;right:8px;width:8px;height:8px;border-radius:999px;background:#dce5e3}
.photo-gallery-slot-dot.ready{background:#35bfae}
.photo-gallery-slot-closed{display:grid;gap:2px;padding:8px;text-align:center}
.photo-gallery-slot-closed small{font-size:9px;font-weight:600;text-transform:none;color:#8a9997}
.photo-gallery-toolbar{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin-bottom:10px}
.photo-gallery-columns{display:flex;gap:2px;padding:2px;border-radius:8px;background:#edf2f1}
.photo-gallery-columns button{min-width:26px;min-height:26px;padding:0 8px;border:0;border-radius:6px;background:transparent;color:#5D6B6D;font-size:11px;font-weight:800;cursor:pointer}
.photo-gallery-columns button.active{background:#0B2F33;color:#fff}
.photo-studio-pill-group{margin-top:10px}
.photo-studio-pill-row{grid-template-columns:repeat(auto-fill,minmax(90px,1fr))}
.toggle-switch{position:relative;display:inline-flex;flex-shrink:0;width:36px;height:20px}
.toggle-switch input{position:absolute;opacity:0;width:100%;height:100%;margin:0;cursor:pointer}
.toggle-switch span{position:absolute;inset:0;background:#dce7e4;border-radius:999px;transition:background .15s ease-out}
.toggle-switch span::before{content:"";position:absolute;top:2px;left:2px;width:16px;height:16px;border-radius:50%;background:#fff;box-shadow:0 1px 2px rgba(11,47,51,.25);transition:transform .15s ease-out}
.toggle-switch input:checked+span{background:#0B7A75}
.toggle-switch input:checked+span::before{transform:translateX(16px)}
.toggle-switch input:focus-visible+span{outline:2px solid #0B7A75;outline-offset:2px}
.toggle-switch-row{display:flex;align-items:center;gap:9px;margin:6px 0;font-size:12px;color:#405456}
.seo-metadata-chip-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px}.seo-metadata-chip{display:flex;justify-content:space-between;gap:6px;min-height:44px;padding:9px;border:1px solid #dce7e4;border-radius:11px;background:#fff;color:#405456;font-size:11px;font-weight:750}
.blue-ocean-main{display:grid;gap:18px}.blue-ocean-main>label{display:grid;gap:8px}.blue-ocean-inspiration-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.blue-ocean-inspiration-grid button,.blue-ocean-inspiration-grid article{display:grid;gap:8px;align-content:start;min-height:130px;padding:16px;border:1px solid #e1e9e7;border-radius:14px;background:#fbfcfc;text-align:left}.blue-ocean-inspiration-grid span{color:#007c78}.blue-ocean-inspiration-grid small{color:#718181}.blue-ocean-inspiration-grid article p{margin:0;color:#405456;font-size:12px;line-height:1.55}.blue-ocean-inspiration-grid article.unavailable{opacity:.6;border-style:dashed}
.boh-extra-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin-top:6px}
.boh-grounding-note{margin:0;color:#718181;font-size:11px;font-style:italic}
.boh-hero{--ac-text:#FFFFFF;padding:32px;border-radius:20px;background:linear-gradient(135deg,#0B2F33 0%,#124c50 65%,#0d3b3f 100%);color:#fff;margin-bottom:18px}
.boh-eyebrow{margin:0;color:#75d7cb;font-size:10px;font-weight:900;letter-spacing:.13em;text-transform:uppercase}
.boh-title{max-width:640px;margin:10px 0 8px;font-size:32px;line-height:1.15;color:#fff}
.boh-subtitle{max-width:560px;margin:0;color:rgba(255,255,255,.72);font-size:14px;font-style:italic}
.boh-cta-row{display:flex;align-items:center;gap:12px}
.boh-credit-badge{padding:4px 10px;border-radius:999px;background:#edf8f6;color:#007c78;font-size:11px;font-weight:800}
.boh-info-box{padding:14px 16px;border:1px solid #e1e9e7;border-radius:14px;background:#fbfcfc}
.boh-info-box summary{cursor:pointer;color:#007c78;font-size:11px;font-weight:850;letter-spacing:.04em;text-transform:uppercase}
.boh-info-box p{margin:10px 0 0;color:#405456;font-size:12px;line-height:1.6}
@media(max-width:720px){.boh-hero{padding:20px}.boh-title{font-size:24px}}
.advisor-chat-composition{display:grid;grid-template-columns:260px minmax(0,1fr);gap:18px}.advisor-chat-main,.advisor-conversation-rail{display:grid;gap:16px;align-content:start;padding:20px;border:1px solid #e1e9e7;border-radius:18px;background:#fff}.advisor-prompt-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.advisor-prompt-card{display:grid;grid-template-rows:auto auto 1fr auto;gap:8px;min-height:190px;padding:16px;border:1px solid #e1e9e7;border-radius:14px;background:#fbfcfc}.advisor-prompt-card>span{color:#007c78;font-size:11px;font-weight:850}.advisor-prompt-card h3,.advisor-prompt-card p{margin:0}.advisor-prompt-card.unavailable{opacity:.7}.advisor-composer{display:grid;gap:10px}.advisor-composer textarea{border:1px solid #dce7e4;border-radius:13px}.advisor-conversation-rail input{width:100%;border:1px solid #dce7e4;border-radius:11px}
.advisor-chat-header{display:flex;justify-content:space-between;align-items:flex-start;gap:16px}
.advisor-chat-header h2{margin:0;color:#132A2D;font-size:20px}
.advisor-chat-header p{margin:4px 0 0;color:#71817f;font-size:12px}
.advisor-status-badge{display:inline-flex;align-items:center;gap:6px;padding:6px 11px;border-radius:999px;background:#edf8f6;color:#007C78;font-size:10px;font-weight:800;white-space:nowrap}
.advisor-status-dot{width:7px;height:7px;border-radius:999px;background:#35bfae;box-shadow:0 0 0 3px rgba(53,191,174,.22)}
.advisor-conversation-list{display:grid;gap:8px}
.advisor-conversation-empty{padding:24px 12px}
.advisor-composer-mode{display:flex;gap:6px}
.advisor-composer-mode button{min-height:30px;padding:0 12px;border:0;border-radius:999px;background:#edf2f1;color:#5D6B6D;font-size:10px;font-weight:800}
.advisor-composer-mode button.active{background:#0B2F33;color:#fff}
.advisor-composer-input{display:grid;grid-template-columns:1fr auto;gap:10px;align-items:end}
.advisor-composer-send{display:grid;place-items:center;width:40px;height:40px;border:0;border-radius:11px;background:#0B7A75;color:#fff;cursor:pointer}
.advisor-composer-send:disabled{background:#edf2f1;color:#8a9997;cursor:default}
.advisor-composer-hint{margin:0;color:#8a9997;font-size:10px}
.advisor-chat-thread{display:grid;gap:8px;max-height:280px;overflow-y:auto;padding:4px 2px}
.advisor-chat-bubble{max-width:80%;padding:10px 13px;border-radius:13px;font-size:12px;line-height:1.55}
.advisor-chat-bubble.user{justify-self:end;background:#0B2F33;color:#fff;border-bottom-right-radius:4px}
.advisor-chat-bubble.assistant{justify-self:start;background:#edf7f6;color:#132A2D;border-bottom-left-radius:4px}
.advisor-chat-bubble.loading{color:#71817f;font-style:italic}
.advisor-refresh-btn{justify-self:start}

.support-counters{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:18px}
.support-counters article{padding:14px;border:1px solid #e1e9e7;border-radius:12px;background:#fff;text-align:center}
.support-counters span{color:#71817f;font-size:9px;font-weight:800;text-transform:uppercase}
.support-counters strong{display:block;margin-top:6px;color:#132A2D;font-size:20px}
.support-form{padding:24px;border-radius:20px}
.support-message-label{display:grid;gap:7px;margin-top:14px;color:#586b6c;font-size:11px;font-weight:750}
.support-message-label textarea{width:100%;padding:11px;border:1px solid #dce5e3;border-radius:11px;background:#f8faf9}
.support-context-row{margin-top:12px}
.support-context-detail{display:flex;gap:16px;margin-top:8px;padding:10px 12px;border:1px solid #e1e9e7;border-radius:10px;background:#fbfcfc;color:#5D6B6D;font-size:11px}
.support-submit-btn{margin-top:14px;background:linear-gradient(100deg,#3DDBC5 0%,#22B1A0 50%,#007C78 100%);color:#fff;border:0}
.support-sla-note{margin:8px 0 0;color:#71817f;font-size:10px}
.support-sent-state{padding:40px}

.inbox-searchbar{display:flex;align-items:center;gap:8px;margin:16px 0;padding:0 14px;border:1px solid #dce5e3;border-radius:999px;background:#fff}
.inbox-searchbar span{color:#8a9997}
.inbox-searchbar input{flex:1;min-height:42px;border:0;background:transparent;font-size:13px}
.inbox-tabs{display:flex;gap:3px;margin-bottom:16px;padding:3px;border-radius:10px;background:#edf2f1;width:fit-content}
.inbox-tabs button{min-height:32px;padding:0 14px;border:0;border-radius:8px;background:transparent;color:#5D6B6D;font-size:11px;font-weight:800;cursor:pointer;transition:background-color .15s ease-out,color .15s ease-out}
.inbox-tabs button.active{background:#0B2F33;color:#fff}
.inbox-message-list{display:grid;gap:10px}
.inbox-message-card{display:grid;grid-template-columns:auto 1fr auto;gap:14px;align-items:center;padding:16px;border:1px solid #e1e9e7;border-radius:14px;background:#fff;cursor:pointer;transition:border-color .15s ease-out,transform .15s ease-out}
.inbox-message-card:hover{border-color:#72c7bd;transform:translateY(-2px)}
.inbox-message-card.unread{background:#f7fcfb}
.inbox-message-icon{display:grid;place-items:center;width:34px;height:34px;border-radius:10px;background:#edf8f6;color:#007C78}
.inbox-message-body strong{display:block;color:#132A2D;font-size:13px}
.inbox-message-body p{margin:3px 0 0;color:#71817f;font-size:11px;line-height:1.5}
.inbox-message-meta{display:flex;align-items:center;gap:10px;color:#8a9997;font-size:10px}
.inbox-read-check{color:#35bfae}
.inbox-unread-dot{width:7px;height:7px;border-radius:999px;background:#007C78}
.inbox-chevron{color:#c3cecc;font-size:16px}

.ebook-studio-step-header{display:flex;gap:8px;margin:16px 0 22px}
.ebook-studio-step-indicator{flex:1;display:flex;align-items:center;gap:8px;padding:8px 10px;border:1px solid var(--ac-border);border-radius:12px;background:var(--ac-bg-subtle)}
.ebook-studio-step-indicator.active{border-color:var(--ac-primary);background:var(--ac-primary-soft)}
.ebook-studio-step-indicator.is-done{border-color:var(--ac-success)}
.ebook-studio-step-number{flex-shrink:0;width:22px;height:22px;border-radius:50%;background:var(--ac-surface-muted);display:grid;place-items:center;font-size:11px;font-weight:700}
.ebook-studio-step-indicator.active .ebook-studio-step-number{background:var(--ac-primary);color:var(--ac-on-primary)}
.ebook-studio-step-indicator.is-done .ebook-studio-step-number{background:var(--ac-success);color:#fff}
.ebook-studio-step-label{font-size:11.5px;font-weight:650;color:var(--ac-text-secondary)}
.ebook-studio-layout{display:grid;grid-template-columns:minmax(0,1fr) 260px;gap:20px;align-items:start}
@media(max-width:900px){.ebook-studio-layout{grid-template-columns:1fr}}
.ebook-studio-main{padding:20px;border:1px solid var(--ac-border);border-radius:var(--ac-radius-panel,20px);background:var(--ac-surface)}
.ebook-studio-field{display:grid;gap:4px;margin-bottom:14px}
.ebook-studio-field span{font-size:12.5px;font-weight:650;color:var(--ac-text-secondary)}
.ebook-studio-field-row{display:flex;gap:12px}
.ebook-studio-section-title{margin:6px 0 8px;font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.03em;color:var(--ac-text-muted)}
.ebook-studio-nav-row{display:flex;align-items:center;justify-content:space-between;margin-top:18px}
.ebook-studio-status{margin:10px 0 0;font-size:12.5px;color:var(--ac-danger)}
.ebook-studio-review-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;margin-bottom:12px}
.ebook-studio-review-grid div{padding:10px 12px;border:1px solid var(--ac-border);border-radius:10px;background:var(--ac-bg-subtle);display:grid;gap:2px}
.ebook-studio-review-grid span{font-size:10.5px;font-weight:700;text-transform:uppercase;color:var(--ac-text-muted)}
.ebook-studio-preview-panel{padding:16px;border:1px solid var(--ac-border);border-radius:var(--ac-radius-panel,20px);background:var(--ac-surface);text-align:center}
.ebook-studio-preview-label{margin:0 0 10px;font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.03em;color:var(--ac-text-muted)}
.ebook-studio-preview-cover{aspect-ratio:3/4;border-radius:10px;background:linear-gradient(160deg,var(--ac-primary-soft),var(--ac-surface-muted));display:flex;align-items:flex-end;padding:14px;margin-bottom:14px}
.ebook-studio-preview-cover span{font-size:13px;font-weight:750;color:var(--ac-text);text-align:left}
.ebook-studio-preview-stats{list-style:none;margin:0;padding:0;display:grid;gap:6px;text-align:left}
.ebook-studio-preview-stats li{display:flex;justify-content:space-between;font-size:12px}
.ebook-studio-preview-stats span{color:var(--ac-text-muted)}

.invite-earn-hero{padding:28px;margin-bottom:18px;border-radius:20px;background:linear-gradient(135deg,#e8f8f4 0%,#ffffff 70%)}
.invite-earn-eyebrow-pill{display:inline-block;padding:5px 12px;border-radius:999px;background:#0B2F33;color:#fff;font-size:9px;font-weight:850;letter-spacing:.08em}
.invite-earn-hero h2{margin:14px 0 8px;color:#132A2D;font-size:26px}
.invite-earn-hero p{margin:0;max-width:560px;color:#5D6B6D;font-size:13px;line-height:1.6}
.invite-earn-link-card{margin-bottom:18px}
.invite-earn-link-row{display:flex;gap:10px;margin-top:10px}
.invite-earn-link-row input{flex:1;min-height:42px;padding:0 14px;border:1px solid #dce5e3;border-radius:11px;background:#f8faf9;color:#405456;font-size:12px}
.invite-earn-share-row{display:flex;gap:8px;margin-top:10px}
.invite-earn-share-row a{display:inline-flex;align-items:center;min-height:38px;padding:0 14px;border:1px solid #dce5e3;border-radius:10px;color:#405456;font-size:11px;font-weight:750;text-decoration:none}
.invite-earn-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:18px}
.invite-earn-metrics article{padding:16px;border:1px solid #e1e9e7;border-radius:14px;background:#fff;text-align:center}
.invite-earn-metrics span{color:#71817f;font-size:9px;font-weight:800;text-transform:uppercase}
.invite-earn-metrics strong{display:block;margin-top:8px;color:#132A2D;font-size:24px}
.invite-earn-metric-highlight{background:linear-gradient(100deg,#3DDBC5 0%,#22B1A0 50%,#007C78 100%)}
.invite-earn-metric-highlight span,.invite-earn-metric-highlight strong{color:#fff}
.invite-earn-how{margin-bottom:18px}
.invite-earn-steps{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-top:12px}
.invite-earn-steps article{padding:16px;border:1px solid #e1e9e7;border-radius:14px;background:#fbfcfc}
.invite-earn-steps strong{display:grid;place-items:center;width:26px;height:26px;margin-bottom:8px;border-radius:999px;background:#0B2F33;color:#fff;font-size:12px}
.invite-earn-steps h4{margin:0 0 4px;color:#132A2D;font-size:13px}
.invite-earn-steps p{margin:0;color:#71817f;font-size:11px;line-height:1.5}
.invite-earn-rewards{margin-bottom:18px}
.invite-earn-reward-cards{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:12px}
.invite-earn-reward-cards article{padding:18px;border:1px solid #e1e9e7;border-radius:14px;background:#fbfcfc;text-align:center}
.invite-earn-reward-cards strong{display:block;color:#007C78;font-size:26px}
.invite-earn-reward-cards span{color:#71817f;font-size:11px}
.invite-earn-recent-list{display:grid;gap:1px;margin:10px 0 0;padding:0;list-style:none;background:#e4ebe9;border-radius:12px;overflow:hidden}
.invite-earn-recent-list li{display:flex;justify-content:space-between;padding:12px 16px;background:#fff;font-size:12px;color:#405456}
.invite-earn-recent-list small{color:#8a9997}
@media(max-width:900px){.invite-earn-metrics,.invite-earn-steps,.invite-earn-reward-cards{grid-template-columns:1fr}}

/* Shared studio branded-banner chrome (Clip Art / Wall Art / Pattern /
   Coloring Book all use this, replacing the generic "Ürün Fabrikası"
   Product Factory header they used to inherit). */
.studio-brand-banner{margin-bottom:18px;padding:22px 26px;border-radius:20px;background:linear-gradient(120deg,#0B2F33 0%,#124c50 55%,#007C78 100%);color:#fff}
.studio-brand-pill{display:inline-block;padding:4px 11px;border-radius:999px;background:rgba(255,255,255,.14);color:#75d7cb;font-size:9px;font-weight:850;letter-spacing:.1em}
.studio-brand-head{display:flex;justify-content:space-between;align-items:flex-end;gap:20px;margin-top:12px}
html[data-page="app"] .studio-brand-head h2{margin:0 0 6px;color:#fff;font-size:24px;letter-spacing:normal}
.studio-brand-head p{margin:0;max-width:560px;color:rgba(255,255,255,.72);font-size:12.5px;line-height:1.55}
.studio-brand-actions{display:flex;gap:8px;flex-shrink:0}
.studio-brand-actions button{min-height:36px;padding:0 14px;border-radius:10px;font-size:11px;font-weight:750}
.studio-brand-actions button.secondary{border:1px solid rgba(255,255,255,.3);background:rgba(255,255,255,.08);color:#fff}

/* Fixes the reported letter-by-letter style-card wrapping bug: the
   global `.workspace-section-card *{overflow-wrap:anywhere}` rule
   (styles.css, workspace-status-row block) was breaking single-word
   style names like "Watercolor"/"Hand Drawn" at arbitrary characters
   whenever a 4-per-row grid made cards too narrow. Real, sized cards
   (2 per row, ~173px+) with overflow-wrap explicitly reset to normal -
   text now only wraps at real word boundaries (spaces), never mid-word. */
.clipart-style-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(108px,1fr));gap:10px;margin-top:9px}
.clipart-style-card{display:flex;flex-direction:column;align-items:stretch;gap:0;padding:0;border:1.5px solid #dce7e4;border-radius:11px;background:#fff;cursor:pointer;overflow:hidden;overflow-wrap:normal!important;word-break:normal!important;transition:border-color .15s ease-out,transform .15s ease-out,box-shadow .15s ease-out}
.clipart-style-card:hover{border-color:#007C78;transform:translateY(-2px);box-shadow:0 6px 16px rgba(19,42,45,.10)}
.clipart-style-card.active{border-color:#007C78;box-shadow:0 0 0 2px rgba(0,124,120,.18)}
.clipart-style-swatch{width:100%;aspect-ratio:1/1;object-fit:cover;background:#f3f6f5;display:block}
.clipart-style-label{padding:7px 8px;color:#132A2D;font-size:11px;font-weight:700;white-space:normal;overflow-wrap:normal!important;word-break:normal!important;text-align:center}

.clipart-generate-cta{display:flex;align-items:center;justify-content:center;gap:8px;width:100%;min-height:50px;margin-top:16px;border:0;border-radius:24px;background:linear-gradient(100deg,#3DDBC5 0%,#22B1A0 50%,#007C78 100%);color:#fff;font-size:13px;font-weight:800;text-transform:uppercase;letter-spacing:.03em;cursor:pointer;transition:transform .15s ease-out,box-shadow .15s ease-out}
.clipart-generate-cta:hover{transform:translateY(-2px);box-shadow:0 6px 18px rgba(0,124,120,.32)}
.clipart-generate-cta span{font-size:15px}
.clipart-studio-usage-note{margin:8px 0 0;color:#71817f;font-size:10px}

.clipart-empty-state{padding:44px 24px}
.clipart-example-prompts{display:flex;flex-wrap:wrap;gap:8px;justify-content:center;margin-top:14px}
.clipart-example-prompts button{min-height:32px;padding:0 13px;border:1px solid #dce5e3;border-radius:999px;background:#fff;color:#405456;font-size:11px}
.clipart-example-prompts button:hover{border-color:#72c7bd;background:#f5fbf9}

.studio-preview-bar{display:flex;justify-content:space-between;align-items:center;margin-bottom:10px}
.studio-canvas-tools{display:flex;align-items:center;gap:6px;color:#5D6B6D;font-size:11px}
.icon-btn-sm{display:grid;place-items:center;width:26px;height:26px;border:1px solid #dce5e3;border-radius:8px;background:#fff;color:#405456;font-size:13px;cursor:pointer;transition:border-color .15s ease-out}
.icon-btn-sm:hover{border-color:#72c7bd}
.studio-details-section{margin-top:10px;padding:10px 12px;border:1px solid #e1e9e7;border-radius:11px;background:#fbfcfc}
.studio-details-section summary{cursor:pointer;color:#405456;font-size:11px;font-weight:750;list-style:none}
.studio-details-section summary::-webkit-details-marker{display:none}
.studio-details-section label{display:grid;gap:5px;margin-top:10px;color:#71817f;font-size:10px;font-weight:700}
.studio-details-section input{width:100%;min-height:36px;padding:0 10px;border:1px solid #dce5e3;border-radius:9px;background:#fff}
.gallery-column-controls,.gallery-tool-chips,.credits-workspace-tabs,.credits-period-toggle{display:flex;gap:5px}.gallery-column-controls button,.gallery-tool-chips button,.credits-workspace-tabs button,.credits-period-toggle button{min-height:36px;padding:7px 12px;border:1px solid #dce7e4;border-radius:10px;background:#fff;color:#5d6b6d;font-weight:750}.gallery-column-controls button.active,.gallery-tool-chips button.active,.credits-workspace-tabs button.active,.credits-period-toggle button.active{border-color:#35bfae;background:#edf9f6;color:#0b2f33}.gallery-tool-chips{margin-bottom:16px}.asset-library-results.columns-3{grid-template-columns:repeat(3,minmax(0,1fr))}.asset-library-results.columns-4{grid-template-columns:repeat(4,minmax(0,1fr))}.asset-library-results.columns-6{grid-template-columns:repeat(6,minmax(0,1fr))}.asset-library-results.columns-9{grid-template-columns:repeat(9,minmax(0,1fr))}.asset-library-results.columns-6 .asset-meta,.asset-library-results.columns-9 .asset-meta{padding:8px}.asset-library-results.columns-9 .asset-meta>*:not(h3){display:none}
.credits-workspace-tabs{margin-bottom:20px;border-bottom:1px solid #e1e9e7;padding-bottom:12px}.credits-period-toggle{align-self:start}
.calendar-workspace-layout,.profit-workspace-layout{display:grid;grid-template-columns:minmax(0,1fr) 280px;gap:18px}.calendar-week-head,.calendar-month-grid{display:grid;grid-template-columns:repeat(7,1fr)}.calendar-week-head strong{padding:10px;color:#718181;font-size:11px;text-align:center}.calendar-day{min-height:92px;padding:8px;border-top:1px solid #e1e9e7;border-left:1px solid #e1e9e7;background:#fff}.calendar-day:nth-child(7n){border-right:1px solid #e1e9e7}.calendar-day:nth-last-child(-n+7){border-bottom:1px solid #e1e9e7}.calendar-day.outside{background:#f7f9f8}.calendar-day span{font-size:12px;font-weight:750}.calendar-action-queue,.profit-distribution-rail{align-self:start}.profit-distribution-bar{display:flex;height:14px;overflow:hidden;border-radius:999px;background:#edf2f1}.profit-distribution-bar span:first-child{background:#e6a84a}.profit-distribution-bar span:last-child{background:#35bfae}
@media(max-width:980px){.verified-studio-layout,.advisor-chat-composition,.calendar-workspace-layout,.profit-workspace-layout{grid-template-columns:1fr}.advisor-conversation-rail{grid-row:1}.photo-gallery-slots{grid-template-columns:repeat(3,1fr)}.asset-library-results.columns-6,.asset-library-results.columns-9{grid-template-columns:repeat(4,1fr)}}
@media(max-width:720px){.studio-option-grid,.blue-ocean-inspiration-grid,.seo-metadata-chip-grid{grid-template-columns:repeat(2,1fr)}.photo-gallery-slots,.advisor-prompt-grid{grid-template-columns:repeat(2,1fr)}.coloring-page-slots{grid-template-columns:repeat(2,1fr)}.studio-reference-grid{grid-template-columns:repeat(4,1fr)}.asset-library-results.columns-3,.asset-library-results.columns-4,.asset-library-results.columns-6,.asset-library-results.columns-9{grid-template-columns:repeat(2,1fr)}.calendar-day{min-height:58px;padding:5px}.operation-toolbar{flex-wrap:wrap}.advisor-composer{grid-template-columns:1fr}}
html[data-page="app"] .center-canvas{padding-top:28px!important}
.optimsy-page-shell,.workspace-page-shell{gap:18px}
.optimsy-main-surface,.workspace-section-card,.optimsy-list-surface,.market-main-surface,.radar-table-surface,.operation-main-surface{border-radius:16px!important}
.seller-dashboard{gap:18px}.seller-dashboard-row{gap:18px!important}
.seller-primary-hero,.seller-journey-card{min-height:258px!important}
.first-product-card{min-height:220px}.seller-tools-section{padding:18px!important}
.optimsy-empty-state{min-height:230px;padding:30px}
.product-intelligence-surface .workspace-state-panel,.product-intelligence-surface .live-canvas-flow{padding:16px}
.product-intelligence-surface .live-flow-section{padding:16px 0}
.optimsy-studio-composition,.factory-production-composition{grid-template-columns:minmax(0,1.08fr) minmax(340px,.92fr)!important;gap:16px!important}
.studio-result-column .optimsy-empty-state{min-height:220px}.factory-results-panel{min-height:360px}
.market-overview-panel{overflow:hidden;background:#fff}
.market-overview-panel>.workspace-section-head{padding:18px 20px;border-bottom:1px solid var(--ac-line)}
.market-overview-strip{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));border-bottom:1px solid var(--ac-line)}
.market-overview-strip>div{display:grid;gap:6px;padding:16px 20px;border-right:1px solid var(--ac-line)}
.market-overview-strip>div:last-child{border-right:0}.market-overview-strip span{color:var(--ac-muted);font-size:10px}.market-overview-strip strong{font-size:14px}
.market-comparison-list{display:grid}.market-comparison-list article{display:flex;justify-content:space-between;gap:20px;padding:13px 20px;border-bottom:1px solid var(--ac-line)}
.market-inline-empty,.market-source-note{padding:16px 20px;color:var(--ac-muted);font-size:11px}.market-source-note{display:flex;gap:12px;border-top:1px solid var(--ac-line)}
.credits-plan-row{padding:20px}.credits-balance-row article{padding:17px 20px}.credits-section{padding:18px 20px}
@media(max-width:720px){.market-overview-strip{grid-template-columns:1fr 1fr}.market-overview-strip>div:nth-child(2){border-right:0}.market-overview-strip>div{border-bottom:1px solid var(--ac-line)}.market-overview-strip>div:nth-last-child(-n+2){border-bottom:0}}

/* Direct route structures for table-led intelligence and disabled operation tools. */
.optimsy-table-workspace,.intelligence-input-workspace,.operation-tool-workspace{width:min(1240px,100%);margin:0 auto}
.page-title-with-chip{display:flex;gap:10px;align-items:center}.page-title-with-chip h2{margin:0}.page-title-with-chip span{padding:5px 9px;border:1px solid #d6e6e2;border-radius:999px;background:#edf7f5;color:#007c78;font-size:10px;font-weight:800}
.radar-filterbar{display:flex;gap:10px;align-items:end;padding:14px;border:1px solid #e0e7e5;border-radius:16px;background:#fff}.radar-filterbar label{display:grid;gap:5px;color:#71817f;font-size:9px;font-weight:800;letter-spacing:.06em;text-transform:uppercase}.radar-filterbar select{min-height:38px;padding:0 12px;border:1px solid #dce5e3;border-radius:10px;background:#fff;color:#405456;transition:border-color .15s ease-out}.radar-filterbar select:hover{border-color:#72c7bd}.radar-window-filter{display:flex;gap:3px;margin-right:auto;padding:3px;border-radius:10px;background:#edf2f1}.radar-window-filter button{min-height:34px;padding:0 12px;border:0;border-radius:8px;background:transparent;color:#647674;font-size:11px;font-weight:750}.radar-window-filter button.active{background:#fff;color:#007c78;box-shadow:0 1px 5px rgba(11,47,51,.08)}
.radar-table-surface{overflow:hidden;border:1px solid #e0e7e5;border-radius:20px;background:#fff}.radar-table-surface>header{display:flex;justify-content:space-between;align-items:center;padding:20px 22px;border-bottom:1px solid #e6ecea}.radar-table-surface>header span{color:#7c8b89;font-size:9px;font-weight:850;letter-spacing:.1em}.radar-table-surface>header h3{margin:4px 0 0;color:#173d40}.radar-table-surface>header>strong{color:#647674;font-size:11px}.radar-table-wrap{overflow-x:auto}.radar-table{width:100%;min-width:820px;border-collapse:collapse}.radar-table th,.radar-table td{padding:14px 18px;border-bottom:1px solid #e8edec;text-align:left;font-size:12px}.radar-table th{color:#81908e;font-size:9px;letter-spacing:.07em;text-transform:uppercase}.radar-table td strong,.radar-table td small{display:block}.radar-table td small{margin-top:4px;color:#899694;font-size:9px}
.goldmine-filterbar{display:grid;grid-template-columns:minmax(240px,1fr) 190px 190px;gap:10px;padding:14px;border:1px solid #e0e7e5;border-radius:16px;background:#fff}.goldmine-filterbar input,.goldmine-filterbar select{min-height:40px;padding:0 12px;border:1px solid #dce5e3;border-radius:10px;background:#fafbfb;color:#607270}
.gm-local-nav{display:flex;gap:4px;margin-bottom:14px;padding:3px;border-radius:10px;background:#edf2f1;width:fit-content}
.gm-local-nav button{min-height:34px;padding:0 14px;border:0;border-radius:8px;background:transparent;color:#5D6B6D;font-size:11px;font-weight:800;cursor:pointer;transition:background-color .15s ease-out,color .15s ease-out}
.gm-local-nav button.active{background:#fff;color:#007c78;box-shadow:0 1px 5px rgba(11,47,51,.08)}
.gm-toggle-icon{font-size:14px}
.gm-history-list{display:grid;gap:1px;margin:0;padding:0;list-style:none;background:#e4ebe9}
.gm-history-list li{display:flex;justify-content:space-between;align-items:center;gap:14px;padding:14px 18px;background:#fff}
.gm-history-list strong{display:block;color:#132A2D;font-size:13px}
.gm-history-list small{color:#71817f;font-size:11px}
.gm-history-surface .optimsy-empty-state{padding:38px}
.gm-hero{padding:26px 28px;margin-bottom:18px;border:1px solid #dce5e3;border-radius:20px;background:#fff}
.gm-headline{margin:0 0 16px;color:#0B2F33;font-size:26px;font-weight:900;letter-spacing:-.01em;line-height:1.15;text-transform:uppercase}
.gm-toggle{display:inline-flex;gap:8px;margin-bottom:16px}
.gm-toggle button{display:inline-flex;align-items:center;gap:7px;min-height:44px;padding:0 18px;border:0;border-radius:999px;background:#f8f3ea;color:#132A2D;font-size:12px;font-weight:800;cursor:pointer;transition:transform .15s ease-out,box-shadow .15s ease-out}
.gm-toggle button:hover{transform:translateY(-2px);box-shadow:0 4px 12px rgba(11,47,51,.10)}
.gm-toggle button.active{background:linear-gradient(100deg,#3DDBC5 0%,#22B1A0 50%,#007C78 100%);color:#fff;font-style:italic;font-weight:800}
.gm-search-row{display:flex;gap:10px}
.gm-search-row input{flex:1;min-height:46px;padding:0 16px;border:1px solid #dce5e3;border-radius:12px;background:#fafbfb;font-size:14px}
.gm-search-row .primary-btn{min-height:46px;padding:0 22px;white-space:nowrap}
.gm-scope-note{margin:10px 0 0;color:#71817f;font-size:11px}
.gm-example-pills{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-top:14px}
.gm-example-pills span{color:#71817f;font-size:10px;font-weight:800;text-transform:uppercase;letter-spacing:.06em}
.gm-example-pills button{min-height:30px;padding:0 12px;border:1px solid #dce5e3;border-radius:999px;background:#fbfcfc;color:#405456;font-size:11px;cursor:pointer}
.gm-example-pills button:hover{border-color:#72c7bd;background:#f5fbf9}
@media(max-width:720px){.gm-search-row{flex-direction:column}.gm-headline{font-size:20px}}
.intelligence-input-grid{display:grid;grid-template-columns:minmax(340px,.85fr) minmax(0,1.15fr);gap:18px}.intelligence-input-panel,.intelligence-result-panel{padding:24px;border-radius:20px}.intelligence-input-panel>label,.intelligence-field-grid label,.operation-form-grid label{display:grid;gap:7px;color:#586b6c;font-size:11px;font-weight:750}.intelligence-input-panel textarea,.intelligence-field-grid input,.intelligence-field-grid select,.operation-form-grid input{width:100%;padding:11px;border:1px solid #dce5e3;border-radius:11px;background:#f8faf9}.intelligence-field-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:16px 0}.upload-placeholder{min-height:42px;border:1px dashed #cbd9d6;border-radius:11px;background:#f8faf9;color:#83918f}.intelligence-result-grid,.operation-result-row{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.intelligence-result-grid>div,.operation-result-row>div{display:grid;gap:5px;padding:14px;border:1px solid #e1e8e6;border-radius:12px;background:#fafbfb}.intelligence-result-grid span,.operation-result-row span{color:#7a8987;font-size:9px}.intelligence-result-grid strong,.operation-result-row strong{color:#173d40;font-size:18px}
.operation-main-surface{padding:24px;border-radius:20px}.operation-toolbar{display:flex;justify-content:space-between;align-items:center;margin-bottom:18px}.calendar-placeholder-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));min-height:320px;border:1px solid #e0e7e5;border-radius:14px;overflow:hidden}.calendar-placeholder-grid>div{display:grid;align-content:start;gap:20px;padding:12px;border-right:1px solid #e6ecea;background:#fafbfb}.calendar-placeholder-grid>div:last-child{border:0}.calendar-placeholder-grid strong{font-size:10px;color:#71817f}.calendar-placeholder-grid span{color:#9aa6a4}.operation-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.operation-result-row{margin-top:18px}.operation-inline-state{display:flex;gap:12px;align-items:center;margin-top:18px;padding:14px;border:1px solid #efdcb5;border-radius:12px;background:#fffaf0}.operation-inline-state>span{display:grid;place-items:center;width:30px;height:30px;border-radius:9px;background:#f8e8c8;color:#b45309;font-weight:900}.operation-inline-state strong{color:#61491e}.operation-inline-state p{margin:3px 0 0;color:#85724e;font-size:11px}

.calendar-day{position:relative}
.calendar-day.today span{display:inline-grid;place-items:center;width:22px;height:22px;border-radius:999px;background:#0B2F33;color:#fff}
.calendar-marker{display:block;margin-top:4px;padding:3px 6px;border-radius:6px;font-size:9px;font-weight:750;color:#fff;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.calendar-marker--back_to_school{background:#E6A84A}
.calendar-marker--wedding{background:#D46FA6}
.calendar-marker--halloween{background:#C9862E}
.calendar-marker--q4_holiday{background:#007C78}
.calendar-seasonal-list{display:grid;gap:10px;margin-top:14px}
.calendar-seasonal-item{display:grid;gap:5px;padding:12px;border:1px solid #e1e9e7;border-radius:12px;background:#fbfcfc}
.calendar-seasonal-item strong{color:#132A2D;font-size:13px}
.calendar-seasonal-item small{color:#71817f;font-size:10px}
.calendar-seasonal-item button{justify-self:start;margin-top:2px}

.profit-calc-form{display:grid;gap:16px}
.profit-calc-group{display:grid;gap:8px}
.profit-calc-checkbox{display:flex;align-items:center;gap:7px;margin-top:6px;font-size:12px;color:#405456}
.profit-calc-note{margin:0;padding:11px 13px;border:1px solid #e1e9e7;border-radius:11px;background:#f7faf9;color:#71817f;font-size:10.5px;line-height:1.5}
.profit-calc-presets{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.profit-calc-presets-empty{color:#8a9997;font-size:11px}
.profit-calc-hero-stat{display:flex;justify-content:space-between;align-items:center;margin:10px 0;padding:12px 14px;border-radius:12px;background:#f7faf9}
.profit-calc-hero-stat strong{font-size:20px}
.profit-calc-hero-stat strong.positive{color:#15803D}
.profit-calc-hero-stat strong.negative{color:#c2413a}
.profit-distribution-rail h3{margin:6px 0 0;color:#132A2D;font-size:26px}
.profit-distribution-rail h3 small{color:#71817f;font-size:11px;font-weight:600}
.profit-calc-fee-list{display:grid;gap:1px;margin:14px 0 0;padding:0;list-style:none;background:#e4ebe9;border-radius:12px;overflow:hidden}
.profit-calc-fee-list li{display:grid;grid-template-columns:14px 1fr auto;gap:8px;align-items:center;padding:9px 12px;background:#fff;color:#5D6B6D;font-size:11px}
.profit-calc-fee-list li strong{color:#132A2D}
.profit-calc-fee-list li.profit-calc-fee-total{font-weight:800;background:#f7faf9}
.profit-dot{width:8px;height:8px;border-radius:999px}
.profit-calc-metrics{margin-top:14px;grid-template-columns:repeat(2,minmax(0,1fr))!important}

.all-tools-metrics{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:20px}
.all-tools-metrics article{padding:16px;border:1px solid #e1e9e7;border-radius:14px;background:#fff}
.all-tools-metrics span{color:#71817f;font-size:10px;font-weight:800;text-transform:uppercase}
.all-tools-metrics strong{display:block;margin-top:6px;color:#132A2D;font-size:22px}
.all-tools-quick-flows{margin-bottom:22px}
.all-tools-flow-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-top:10px}
.all-tools-flow-card{display:grid;gap:8px;padding:16px;border:1px solid #e1e9e7;border-radius:14px;background:#fff;transition:transform .15s ease-out,box-shadow .15s ease-out}
.all-tools-flow-card:hover{transform:translateY(-2px);box-shadow:0 8px 22px rgba(19,42,45,.08)}
.all-tools-flow-card h4{margin:0;color:#132A2D;font-size:13px}
.all-tools-flow-card p{margin:0;color:#71817f;font-size:11px;line-height:1.5}
.all-tools-group{margin-bottom:22px}
.all-tools-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin-top:10px}
.all-tools-card{display:grid;gap:6px;padding:14px;border:1px solid #e1e9e7;border-radius:13px;background:#fff;transition:transform .15s ease-out,box-shadow .15s ease-out}
.all-tools-card:hover{transform:translateY(-2px);box-shadow:0 8px 22px rgba(19,42,45,.08)}
.all-tools-card-icon{display:grid;place-items:center;width:28px;height:28px;border-radius:9px;background:#edf8f6;color:#007C78;font-size:14px}
.all-tools-card h4{margin:0;color:#132A2D;font-size:12px}
.all-tools-card small{color:#8a9997;font-size:9px}
@media(max-width:900px){.all-tools-flow-grid,.all-tools-metrics{grid-template-columns:1fr}.all-tools-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:820px){.radar-filterbar{align-items:stretch;flex-direction:column}.radar-window-filter{width:100%;margin:0}.radar-window-filter button{flex:1}.goldmine-filterbar{grid-template-columns:1fr}.intelligence-input-grid{grid-template-columns:1fr}.intelligence-result-grid,.operation-result-row{grid-template-columns:repeat(2,minmax(0,1fr))}.calendar-placeholder-grid{grid-template-columns:repeat(2,minmax(0,1fr));min-height:0}.operation-form-grid{grid-template-columns:1fr}}

.seo-single-workspace{display:grid;gap:18px;width:min(1240px,100%);margin:0 auto}.seo-mode-control{display:inline-flex;justify-self:start;gap:3px;padding:3px;border-radius:11px;background:#e9efee}.seo-mode-control button{min-width:82px;min-height:34px;border:0;border-radius:8px;background:transparent;color:#6a7b79;font-size:11px;font-weight:800}.seo-mode-control button.active{background:#fff;color:#007c78;box-shadow:0 1px 5px rgba(11,47,51,.08)}.seo-editorial-hero{max-width:780px;padding:18px 0 8px}.seo-editorial-hero>span{color:#007c78;font-size:10px;font-weight:900;letter-spacing:.11em}.seo-editorial-hero h2{max-width:700px;margin:10px 0;color:#132a2d;font-size:38px;line-height:1.08;letter-spacing:-.035em}.seo-editorial-hero p{max-width:680px;margin:0;color:#687a79;font-size:13px;line-height:1.6}.seo-single-composition{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(300px,.65fr);gap:18px;align-items:start}.seo-brief-card,.seo-upload-card{padding:24px;border-radius:20px}.seo-brief-card>label{display:grid;gap:7px;color:#5d6b6d;font-size:11px;font-weight:750}.seo-brief-card textarea{width:100%;padding:14px;border:1px solid #dbe5e2;border-radius:13px;background:#fafbfb;resize:vertical}.seo-chip-sections{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:20px}.seo-chip-sections fieldset{display:flex;gap:6px;flex-wrap:wrap;margin:0;padding:0;border:0}.seo-chip-sections legend{width:100%;margin-bottom:7px;color:#6e7f7d;font-size:10px;font-weight:800}.seo-chip-sections button{padding:7px 10px;border:1px solid #dbe5e2;border-radius:999px;background:#fff;color:#4e6263;font-size:10px}.seo-upload-card{display:grid;gap:16px}.seo-upload-drop{display:grid;justify-items:center;gap:7px;min-height:210px;padding:24px;border:1px dashed #c9d8d5;border-radius:15px;background:#f8faf9;color:#71817f}.seo-upload-drop>span{font-size:28px;color:#007c78}.seo-upload-drop strong{color:#405456}.seo-upload-drop small{text-align:center}.seo-credit-context{display:flex;justify-content:space-between;padding:12px 0;border-top:1px solid #e4eae8;border-bottom:1px solid #e4eae8;color:#5d6b6d;font-size:11px}.seo-credit-context strong{color:#e6a84a}
.seo-studio-mode-row{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:16px}
.seo-tagflow-link{white-space:nowrap}
@media(max-width:820px){.seo-single-composition{grid-template-columns:1fr}.seo-editorial-hero h2{font-size:29px}.seo-chip-sections{grid-template-columns:1fr}}

.market-page-structure{width:min(1240px,100%);margin:0 auto}.market-query-surface{display:grid;gap:9px;padding:16px;border:1px solid #dfe7e5;border-radius:16px;background:#fff}.market-query-surface .product-search-form{display:grid;grid-template-columns:minmax(0,1fr) 150px auto;gap:9px}.market-query-surface input,.market-query-surface select{min-height:42px;padding:0 13px;border:1px solid #dce5e3;border-radius:11px;background:#fafbfb}.market-main-surface{overflow:hidden;border:1px solid #dfe7e5;border-radius:20px;background:#fff}.market-page-tabs{display:flex;gap:22px;padding:0 22px;border-bottom:1px solid #e5ebe9}.market-page-tabs button{min-height:48px;border:0;border-bottom:2px solid transparent;background:transparent;color:#71817f;font-size:11px;font-weight:800}.market-page-tabs button.active{border-color:#007c78;color:#007c78}.market-intelligence-overview{padding:20px 22px;border-bottom:1px solid #e5ebe9}.market-report-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(300px,.8fr);gap:0}.market-report-grid>section,.market-report-grid>aside{min-width:0;padding:22px}.market-report-grid>aside{border-left:1px solid #e5ebe9;background:#fafbfb}.market-competitor-section{padding:22px;border-top:1px solid #e5ebe9}.market-history-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;padding:22px;border-top:1px solid #e5ebe9}
@media(max-width:820px){.market-query-surface .product-search-form{grid-template-columns:1fr}.market-report-grid{grid-template-columns:1fr}.market-report-grid>aside{border-top:1px solid #e5ebe9;border-left:0}.market-history-grid{grid-template-columns:1fr}}

.optimsy-list-workspace{width:min(1240px,100%);margin:0 auto}.optimsy-list-surface{overflow:hidden;border:1px solid #dfe7e5;border-radius:20px;background:#fff}.advisor-filter-tabs{display:flex;gap:20px;padding:0 22px;border-bottom:1px solid #e5ebe9;overflow-x:auto}.advisor-filter-tabs button{display:flex;gap:7px;align-items:center;min-height:48px;border:0;border-bottom:2px solid transparent;background:transparent;color:#71817f;font-size:11px;font-weight:800;white-space:nowrap}.advisor-filter-tabs button.active{border-color:#007c78;color:#007c78}.advisor-filter-tabs span{padding:2px 6px;border-radius:999px;background:#edf2f1;font-size:9px}.advisor-recommendation-list{display:grid}.advisor-recommendation-list>article{display:grid;grid-template-columns:100px minmax(0,1fr) auto;gap:18px;align-items:center;padding:18px 22px;border-bottom:1px solid #e8edec}.advisor-priority{color:#b45309;font-size:9px;font-weight:850;letter-spacing:.06em;text-transform:uppercase}.advisor-recommendation-list strong{color:#173d40;font-size:13px}.advisor-recommendation-list p{margin:5px 0;color:#6f807e;font-size:11px}.advisor-recommendation-list small{color:#8a9795}.asset-library-shell .optimsy-list-surface{padding:0}.asset-library-shell .library-toolbar{margin:0;padding:16px 18px;border-bottom:1px solid #e5ebe9}.asset-library-shell .asset-library-results{padding:18px}
.account-page-structure{width:min(1140px,100%);margin:0 auto}.credits-main-surface{overflow:hidden;border:1px solid #dfe7e5;border-radius:20px;background:#fff}.credits-plan-hero{display:flex;justify-content:space-between;gap:24px;align-items:center;padding:24px;background:linear-gradient(120deg,#0b2f33,#124a4c);color:#fff}.credits-plan-hero span{color:rgba(255,255,255,.65);font-size:10px;font-weight:800}.credits-plan-hero h3{margin:5px 0;font-size:25px}.credits-plan-hero p{margin:0;color:rgba(255,255,255,.7);font-size:11px}.credits-balance-pair{display:grid;grid-template-columns:1fr 1fr;gap:10px}.credits-balance-pair>div{min-width:150px;padding:14px;border:1px solid rgba(255,255,255,.15);border-radius:13px;background:rgba(255,255,255,.08)}.credits-balance-pair strong{display:block;margin-top:5px;font-size:22px}.credits-content-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(280px,.8fr)}.credits-content-grid>section,.credits-content-grid>aside{padding:22px}.credits-content-grid>aside{border-left:1px solid #e5ebe9;background:#fafbfb}.credits-history-list{display:grid}.credits-history-list article{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:5px;padding:11px 0;border-bottom:1px solid #e5ebe9}.credits-history-list strong{font-size:11px}.credits-history-list span{color:#b45309;font-weight:800}.credits-history-list small{grid-column:1/-1;color:#889694;font-size:9px}.credits-plans-section{padding:22px;border-top:1px solid #e5ebe9}
@media(max-width:820px){.advisor-recommendation-list>article{grid-template-columns:1fr}.advisor-recommendation-list>article>button{justify-self:start}.credits-plan-hero{align-items:flex-start;flex-direction:column}.credits-balance-pair{width:100%}.credits-content-grid{grid-template-columns:1fr}.credits-content-grid>aside{border-top:1px solid #e5ebe9;border-left:0}}

.optimsy-studio-composition{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(340px,.85fr)!important;gap:18px;align-items:start}.studio-input-column,.studio-result-column{display:grid;gap:14px;min-width:0}.studio-result-column{position:sticky;top:14px}.studio-context-strip{display:grid;grid-template-columns:1fr 1fr 1fr;gap:10px;padding:14px}.studio-context-strip>div{display:grid;gap:4px}.studio-context-strip span,.compact-credit-context{color:#7b8987;font-size:9px;font-weight:800}.studio-context-strip strong{overflow:hidden;color:#294a4c;font-size:11px;text-overflow:ellipsis;white-space:nowrap}.video-studio-composition .studio-input-column>article,.photo-studio-composition .studio-input-column>article{padding:22px;border-radius:20px}.video-studio-composition .studio-input-column select{width:100%;min-height:42px;margin-bottom:14px;border:1px solid #dce5e3;border-radius:11px;background:#fafbfb}.factory-production-workspace .factory-entry-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.factory-production-workspace .factory-entry-card{min-height:150px}.factory-results-panel{min-height:420px;border-radius:20px}
@media(max-width:980px){.optimsy-studio-composition{grid-template-columns:1fr!important}.studio-result-column{position:static}}

/* Final list/account/operations archetype cleanup. */
.draft-workspace-shell{width:min(1240px,100%);margin:0 auto}.draft-queue-simple-layout{overflow:hidden;border:1px solid #dfe7e5;border-radius:20px;background:#fff}.draft-flow-panel,.draft-queue-detail-region{border:0!important;box-shadow:none!important}.draft-queue-status-tabs{border-bottom:1px solid #e5ebe9}.automation-workspace-shell{width:min(1240px,100%);margin:0 auto}.automation-tabs{display:flex;gap:22px;padding:0 20px;border:1px solid #dfe7e5;border-bottom:0;border-radius:18px 18px 0 0;background:#fff}.automation-composition{display:block!important}.automation-main-panel{min-height:430px;border-radius:0 0 18px 18px!important}.automation-inline-state{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;margin-bottom:20px;overflow:hidden;border:1px solid #e1e9e7;border-radius:12px;background:#e1e9e7}.automation-inline-state>div{display:grid;gap:5px;padding:14px;background:#fff}.automation-inline-state span{color:#5d6b6d;font-size:11px}.automation-inline-state strong{color:#132a2d;font-size:14px}.settings-workspace-shell{width:min(1140px,100%);margin:0 auto}.settings-composition{overflow:hidden;border:1px solid #dfe7e5;border-radius:20px;background:#fff}.settings-nav{padding:14px;background:#fafbfb;border-right:1px solid #e5ebe9}.settings-panel{min-height:520px;padding:22px}.settings-panel>.workspace-section-card,.settings-panel-grid>.workspace-section-card{border:0;box-shadow:none}.settings-panel-grid{grid-template-columns:1fr!important}.draft-editor-shell{width:min(1240px,100%);margin:0 auto}.draft-editor-composition{align-items:start}.draft-editor-rail{position:sticky;top:14px}.draft-editor-actions{position:sticky;bottom:12px}
@media(max-width:720px){.automation-inline-state{grid-template-columns:1fr}}

/* Authenticated frontend rebuild: Optimsy structure, ACOPES brand. */
html[data-page="app"]{--ac-bg:#f5f4ef;--ac-surface:#fff;--ac-text:#132a2d;--ac-muted:#5d6b6d;--ac-line:#e4e9e7;--ac-primary:#007c78;--ac-dark:#0b2f33;--ac-mint:#35bfae;--ac-gold:#e6a84a}
html[data-page="app"] body{background:var(--ac-bg);color:var(--ac-text)}
html[data-page="app"] .acopes-os-shell{min-height:100vh;background:var(--ac-bg)}
html[data-page="app"] .os-header{position:fixed;z-index:40;top:0;right:0;left:220px;height:64px;padding:0 28px;border-bottom:1px solid var(--ac-line);background:rgba(255,255,255,.96);box-shadow:none}
html[data-page="app"] .command-bar-brand{display:none}
html[data-page="app"] .topbar-command-search{width:min(520px,48vw);margin:0 auto 0 0}
html[data-page="app"] .topbar-command-search input{height:38px;border:1px solid #dde5e3;border-radius:11px;background:#f8faf9}
html[data-page="app"] .command-bar-actions{gap:8px}.compact-credit-button{height:36px!important;border-radius:10px!important}.profile-pill,.icon-circle{width:36px!important;height:36px!important}
html[data-page="app"] .os-main-grid{display:block;padding:64px 0 0 220px}
html[data-page="app"] .dense-sidebar{position:fixed;z-index:50;top:0;bottom:0;left:0;width:220px!important;height:100vh!important;max-height:none!important;padding:0 10px 12px!important;border-right:1px solid var(--ac-line);background:#fff!important}
.sidebar-brand{display:flex;align-items:center;gap:10px;flex:0 0 64px;width:100%;padding:0 10px;border:0;border-bottom:1px solid var(--ac-line);background:#fff;color:var(--ac-dark);font-size:14px;text-align:left}.sidebar-brand .logo-mark{display:grid;place-items:center;width:30px;height:30px;border-radius:9px;background:var(--ac-dark);color:#fff}
.sidebar-nav-scroll{padding-top:14px!important}.sidebar-bottom-stack{padding-top:10px;border-top:1px solid var(--ac-line)}
html[data-page="app"] .workspace-grid{display:block!important;min-width:0;background:var(--ac-bg)}
html[data-page="app"] .center-canvas{width:100%;max-width:none;min-height:calc(100vh - 64px);padding:30px 32px 56px!important;background:var(--ac-bg)}
html[data-page="app"] .view{width:min(1220px,100%);margin:0 auto}
.optimsy-page-shell,.workspace-page-shell{display:grid;gap:20px;width:100%;margin:0 auto}.optimsy-page-header,.workspace-page-head{display:flex;justify-content:space-between;gap:20px;align-items:flex-start;margin:0;padding:0;border:0;background:transparent}.optimsy-page-header h2,.workspace-page-head h2{margin:2px 0 6px;color:var(--ac-text);font-size:25px;line-height:1.2}.optimsy-page-header p,.workspace-page-head .meta{max-width:700px;margin:0;color:var(--ac-muted);font-size:12px;line-height:1.55}.hero-eyebrow,.eyebrow{margin:0!important;color:var(--ac-primary)!important;font-size:10px!important;font-weight:800;letter-spacing:.08em;text-transform:uppercase}
.optimsy-main-surface,.workspace-section-card,.optimsy-list-surface,.market-main-surface,.radar-table-surface,.operation-main-surface{border:1px solid var(--ac-line)!important;border-radius:18px!important;background:#fff!important;box-shadow:none!important}
.workspace-section-card{padding:20px}.optimsy-empty-state{display:grid;justify-items:center;align-content:center;min-height:270px;padding:38px;text-align:center}.optimsy-empty-state h3{margin:8px 0 4px}.optimsy-empty-state p{max-width:520px;margin:0 0 14px;color:var(--ac-muted);font-size:12px;line-height:1.55}
/* Dashboard proportions */
.seller-dashboard{display:grid;gap:20px}.seller-dashboard-greeting{padding:0}.seller-dashboard-greeting h2{font-size:clamp(19px, 1.6vw, 22px)}.seller-dashboard-row{gap:20px!important}.seller-dashboard-primary-row,.seller-dashboard-secondary-row{grid-template-columns:minmax(0,1.65fr) minmax(300px,.75fr)!important}.seller-primary-hero{min-height:310px!important;border-radius:22px!important}.seller-journey-card,.first-product-card,.seller-credit-card,.seller-tools-section{border:1px solid var(--ac-line)!important;border-radius:18px!important;box-shadow:none!important}.seller-journey-card{min-height:310px}.first-product-card{min-height:260px}.seller-tools-section{padding:22px!important}
/* Consolidated research and tool surfaces */
.product-intelligence-page{gap:18px}.product-intelligence-page>.idea-hub-tabs{order:2;margin:0}.product-intelligence-page>.optimsy-page-header{order:1}.product-intelligence-surface{order:3;overflow:hidden;padding:0}.optimsy-research-bar{display:grid;grid-template-columns:minmax(260px,1fr) 150px 180px auto;gap:10px;align-items:end;padding:18px;border-bottom:1px solid var(--ac-line)}.optimsy-research-bar input,.optimsy-research-bar select{width:100%;height:42px;border:1px solid #dbe4e2;border-radius:11px;background:#fff}.optimsy-research-bar button{height:42px}.optimsy-research-bar small{grid-column:1/-1;color:var(--ac-muted)}.product-intelligence-context{display:flex;justify-content:space-between;padding:11px 18px;border-bottom:1px solid var(--ac-line);color:var(--ac-muted);font-size:10px}.product-intelligence-surface .workspace-state-panel,.product-intelligence-surface .live-canvas-flow{margin:0;padding:18px}.product-intelligence-surface .live-flow-section{margin:0;padding:18px 0;border:0;border-bottom:1px solid var(--ac-line);background:transparent;box-shadow:none}.product-intelligence-surface .live-flow-section:last-child{border-bottom:0}
.seo-expert-workspace,.seo-single-workspace,.tagflow-workspace-shell{display:grid;gap:18px}.seo-expert-main,.tagflow-main{overflow:hidden;padding:0!important}.seo-expert-main>.workspace-section-head,.tagflow-main>.workspace-section-head{padding:18px 20px;border-bottom:1px solid var(--ac-line)}.seo-studio-table-wrap,.tagflow-main .studio-table-wrap{margin:0}.seo-inline-preview{display:grid;gap:4px;padding:16px 20px;border-top:1px solid var(--ac-line);background:#f7faf9}.seo-inline-preview span{color:var(--ac-muted);font-size:11px}
.market-query-surface{padding:14px!important;border:1px solid var(--ac-line)!important;border-radius:16px!important;background:#fff!important}.market-main-surface{overflow:hidden;padding:0!important}.market-page-tabs{padding:0 18px}.market-report-grid{grid-template-columns:1fr!important}.market-report-grid>section,.market-report-grid>aside,.market-competitor-section,.market-history-grid{padding:20px!important;border:0!important;border-top:1px solid var(--ac-line)!important;background:#fff!important;box-shadow:none!important}.market-overview-grid{grid-template-columns:repeat(4,minmax(0,1fr));padding:18px}.market-intelligence-composition{grid-template-columns:1fr!important}.market-intelligence-composition>section,.market-intelligence-composition>aside{border:0!important;border-top:1px solid var(--ac-line)!important;border-radius:0!important;box-shadow:none!important}
/* Creation family */
.optimsy-studio-composition,.factory-production-composition{grid-template-columns:minmax(0,1.05fr) minmax(360px,.95fr)!important;gap:18px!important}.studio-input-column,.studio-result-column{gap:14px}.studio-result-column{top:82px!important}.factory-production-workspace,.photo-production-shell,.video-production-shell{display:grid;gap:20px}.factory-production-workspace>.factory-production-head,.photo-production-shell>.studio-production-head,.video-production-shell>.studio-production-head{margin:0}.factory-results-panel{min-height:460px}.factory-entry-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}.studio-context-strip{border-radius:16px!important}
/* Lists, account and operations */
.optimsy-list-surface{overflow:hidden}.library-toolbar,.radar-toolbar,.goldmine-filterbar{border:0!important;border-bottom:1px solid var(--ac-line)!important;border-radius:0!important}.draft-queue-simple-layout{border-radius:18px!important}.draft-editor-composition{grid-template-columns:minmax(0,1fr) 330px!important;gap:18px}.draft-editor-rail{top:82px!important}.automation-tabs{border-radius:16px 16px 0 0!important}.automation-main-panel{border-radius:0 0 16px 16px!important}.settings-composition{border-radius:18px!important}.credits-clean-surface{overflow:hidden;padding:0}.credits-plan-row{display:flex;justify-content:space-between;gap:20px;align-items:center;padding:24px;border-bottom:1px solid var(--ac-line)}.credits-plan-row span,.credits-balance-row span{color:var(--ac-muted);font-size:10px;font-weight:800}.credits-plan-row h3{margin:4px 0;font-size:22px}.credits-plan-row p{margin:0;color:var(--ac-muted);font-size:11px}.credits-balance-row{display:grid;grid-template-columns:repeat(3,1fr);border-bottom:1px solid var(--ac-line)}.credits-balance-row article{display:grid;gap:7px;padding:20px;border-right:1px solid var(--ac-line)}.credits-balance-row article:last-child{border-right:0}.credits-balance-row strong{font-size:20px}.credits-section{padding:22px;border-bottom:1px solid var(--ac-line)}.credits-section:last-child{border-bottom:0}
@media(max-width:980px){html[data-page="app"] .os-header{left:68px}.os-main-grid{padding-left:68px!important}.optimsy-research-bar{grid-template-columns:1fr 1fr}.optimsy-research-bar>input{grid-column:1/-1}.seller-dashboard-primary-row,.seller-dashboard-secondary-row,.optimsy-studio-composition,.factory-production-composition,.draft-editor-composition{grid-template-columns:1fr!important}.studio-result-column,.draft-editor-rail{position:static!important}.credits-balance-row{grid-template-columns:1fr}}
@media(max-width:720px){html[data-page="app"] .os-header{left:0;padding:0 14px}.command-bar-brand{display:flex}.topbar-command-search{width:auto;flex:1}.topbar-command-search kbd,.compact-credit-button small,.topbar-help{display:none!important}.os-main-grid{padding-left:0!important}.center-canvas{padding:22px 16px 40px!important}.optimsy-page-header,.workspace-page-head{display:grid}.optimsy-research-bar{grid-template-columns:1fr}.optimsy-research-bar>*{grid-column:auto!important}.seller-dashboard-primary-row,.seller-dashboard-secondary-row{display:grid!important}.first-product-options{grid-template-columns:1fr!important}.credits-plan-row{align-items:flex-start;flex-direction:column}}

/* Product-navigation sidebar: compact groups instead of a full tool catalog. */
html[data-page="app"] .dense-sidebar { display:flex; flex-direction:column; width:220px; height:calc(100vh - 72px); max-height:calc(100vh - 72px); padding:12px 10px 10px; overflow:hidden; background:#fff; }
.sidebar-nav-scroll { display:flex; flex:1 1 auto; min-height:0; flex-direction:column; gap:14px; overflow-y:auto; overflow-x:hidden; padding:2px 2px 14px; scrollbar-width:thin; scrollbar-color:#d2dcda transparent; }
html[data-page="app"] .dense-sidebar .sidebar-dashboard { flex:0 0 auto; min-height:42px; margin-bottom:2px; }
html[data-page="app"] .dense-sidebar .sidebar-group { display:grid; gap:5px; margin:0; }
.sidebar-group-toggle,.sidebar-subgroup-toggle { display:flex; justify-content:space-between; gap:10px; align-items:center; width:100%; border:0; background:transparent; color:#718181; cursor:pointer; }
.sidebar-group-toggle { min-height:28px; padding:2px 14px; border-radius:8px; font-size:11px; font-weight:850; letter-spacing:.08em; text-align:left; }
.sidebar-group-toggle:hover,.sidebar-group.has-active-route>.sidebar-group-toggle { background:#f2f7f5; color:#285052; }
.sidebar-chevron { display:inline-block; color:#91a09e; font-size:13px; transition:transform .16s ease; }
.sidebar-group.is-open>.sidebar-group-toggle .sidebar-chevron,.sidebar-subgroup.is-open>.sidebar-subgroup-toggle .sidebar-chevron { transform:rotate(180deg); }
.sidebar-group-items,.sidebar-subgroup-items { display:grid; gap:3px; }
.sidebar-group-items[hidden],.sidebar-subgroup-items[hidden] { display:none !important; }
.sidebar-new-badge { position:absolute; top:4px; right:10px; font-size:9px; font-weight:800; letter-spacing:.04em; color:#fff; background:var(--ac-primary,#007c78); padding:2px 6px; border-radius:999px; line-height:1.4; }
html[data-page="app"] .dense-sidebar .sidebar-item { position:relative; display:grid; grid-template-columns:22px minmax(0,1fr); align-items:center; width:100%; min-height:42px; padding:7px 14px; border:0; border-radius:10px; color:#405456; font-size:14px; font-weight:550; text-decoration:none; }
html[data-page="app"] .dense-sidebar .sidebar-item:hover { color:#132a2d; background:#f2f7f5; }
html[data-page="app"] .dense-sidebar .sidebar-item.active { color:#132a2d; background:#e8f6f3; box-shadow:none; }
html[data-page="app"] .dense-sidebar .sidebar-item.active::before { content:""; position:absolute; left:0; top:8px; bottom:8px; width:2px; border-radius:2px; background:#007c78; }
html[data-page="app"] .dense-sidebar .sidebar-icon { display:grid; place-items:center; width:16px; height:16px; color:#007c78; font-size:16px; }
.sidebar-subgroup { display:grid; gap:3px; }
.sidebar-subgroup-toggle { min-height:42px; padding:7px 14px; border-radius:10px; color:#405456; font-size:14px; font-weight:600; }
.sidebar-subgroup-toggle>span:first-child { display:flex; gap:8px; align-items:center; }
.sidebar-subgroup-toggle:hover { background:#f2f7f5; color:#132a2d; }
.sidebar-subgroup-items { margin-left:14px; padding-left:7px; border-left:1px solid #dce7e4; }
.sidebar-subgroup-items .sidebar-item { min-height:38px !important; padding:6px 9px !important; font-size:13px !important; }
.sidebar-account-group { padding-top:12px; border-top:1px solid #e3eae8; }
.sidebar-account-label { padding:0 14px 4px; color:#7b8b89; font-size:11px; font-weight:850; letter-spacing:.08em; }
.sidebar-bottom-stack { flex:0 0 auto; display:grid; gap:7px; margin:0; padding:10px 2px 0; border-top:1px solid #e3eae8; background:#fff; }
.sidebar-plan-card,.sidebar-profile-card { min-height:0; border-radius:11px; box-shadow:none; }
.sidebar-plan-card { padding:10px 11px; }
.sidebar-profile-card { padding:9px 10px; }

html[data-page="app"] .command-bar-brand { display:flex; align-items:center; gap:10px; min-width:0; }
html[data-page="app"] .command-bar-brand .os-logo { flex:0 0 auto; white-space:nowrap; }
html[data-page="app"] .command-bar-brand .topbar-context { min-width:0; overflow:hidden; }

@media(max-width:980px) and (min-width:721px){
  html[data-page="app"] .dense-sidebar{width:68px;padding:10px 7px}
  .sidebar-bottom-stack,.sidebar-group-toggle,.sidebar-account-label{display:none}
  .sidebar-nav-scroll{gap:8px}
  html[data-page="app"] .dense-sidebar .sidebar-group{display:grid}
  html[data-page="app"] .dense-sidebar .sidebar-group-items{display:grid!important}
  html[data-page="app"] .dense-sidebar .sidebar-item{display:flex;justify-content:center;width:100%;padding:8px;min-height:42px}
  html[data-page="app"] .dense-sidebar .sidebar-label,.sidebar-subgroup-toggle>span:first-child:not(.sidebar-icon),.sidebar-subgroup-toggle>.sidebar-chevron{display:none!important}
  .sidebar-subgroup-toggle{display:flex;justify-content:center;padding:8px}
  .sidebar-subgroup-items{display:none!important}
  .sidebar-account-group{padding-top:8px}
}

@media(max-width:720px){
  html[data-page="app"] .dense-sidebar{position:fixed;z-index:80;top:0;left:0;display:flex;width:min(86vw,320px);height:100vh;max-height:100vh;padding:14px 10px;overflow:hidden;transform:translateX(-105%);transition:transform .2s ease;box-shadow:16px 0 40px rgba(11,47,51,.18)}
  html[data-page="app"] body.nav-collapsed .dense-sidebar{width:min(86vw,320px);transform:translateX(0)}
  html[data-page="app"] .dense-sidebar .sidebar-group{display:grid}
  html[data-page="app"] .dense-sidebar .sidebar-group-toggle{display:flex}
  html[data-page="app"] .dense-sidebar .sidebar-item{display:grid;width:100%;min-height:42px}
  html[data-page="app"] .dense-sidebar .sidebar-label{display:block!important}
  .sidebar-bottom-stack{display:grid}
}

/* Keep compact navigation labels readable after responsive sidebar rules. */
html[data-page="app"] .sidebar-nav-scroll{gap:10px;padding-top:10px!important}
html[data-page="app"] .dense-sidebar .sidebar-group{gap:3px}
html[data-page="app"] .dense-sidebar .sidebar-item{min-height:40px;padding-top:6px;padding-bottom:6px}
html[data-page="app"] .dense-sidebar .sidebar-label{overflow:visible;text-overflow:clip;white-space:normal;line-height:1.2}

/* Phase 2 - shared product context bar.
   Reuses the existing workspace card tokens; it is a strip on top of the view
   it belongs to, not a new surface. */
.product-context-host { display: block; }
.product-context-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  padding: 12px 16px;
  margin-bottom: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: #fffdf9;
  box-shadow: var(--shadow);
}
.product-context-thumb {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--green-soft, #f2f6f4);
  display: flex;
  align-items: center;
  justify-content: center;
}
.product-context-thumb img { width: 100%; height: 100%; object-fit: cover; }
.product-context-thumb-placeholder { font-size: 20px; opacity: 0.55; }
.product-context-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 200px; }
.product-context-kicker {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.6;
}
.product-context-title {
  font-size: 15px;
  /* A long product name truncates instead of pushing the actions off screen. */
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}
.product-context-id { font-size: 11px; opacity: 0.6; }
.product-context-facts { display: flex; gap: 18px; flex-wrap: wrap; min-width: 0; }
.product-context-facts span { display: flex; flex-direction: column; min-width: 0; }
.product-context-facts small { font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; opacity: 0.55; }
.product-context-facts strong {
  font-size: 13px;
  max-width: 16ch;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.product-context-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-left: auto; }
.product-context-bar.is-empty,
.product-context-bar.is-error { background: #fffdf9; }
.product-context-bar.is-error { border-color: #e6b7b0; }
.product-context-bar.is-loading p { margin: 0; opacity: 0.7; }

@media (max-width: 720px) {
  .product-context-bar { gap: 10px; padding: 12px; }
  /* Actions go full width on their own row so nothing overlaps or clips. */
  .product-context-actions { margin-left: 0; width: 100%; }
  .product-context-actions button { flex: 1 1 auto; }
  .product-context-facts { gap: 12px; width: 100%; }
  .product-context-facts strong { max-width: 12ch; }
}
