/* Content Operations V4 — the approved quiet, single-viewport desk. */
:root {
  --ops-bg: var(--sv-color-surface-subtle);
  --ops-surface: var(--sv-color-surface);
  --ops-surface-raised: var(--sv-color-surface-strong);
  --ops-input: #0a0e0b;
  --ops-line: rgba(224, 232, 221, .095);
  --ops-line-strong: rgba(206, 247, 47, .48);
  --ops-text: var(--sv-color-text);
  --ops-muted: var(--sv-color-text-muted);
  --ops-accent: var(--sv-color-brand);
}

html[data-app-rail],
body.has-app-rail {
  height: 100%;
  min-height: 100%;
  overflow: hidden;
}

body.has-app-rail {
  color: var(--ops-text);
  background: var(--sv-color-canvas-raised);
  font-family: var(--sv-font-sans);
}

.ops-shell {
  width: 100%;
  height: 100dvh;
  margin: 0;
  padding: 0;
}

.ops-task-desk {
  width: 100%;
  height: 100%;
  grid-template-columns: clamp(270px, 20vw, 310px) minmax(650px, 1fr) clamp(292px, 20vw, 330px);
  border: 0;
  border-radius: 0;
  background: var(--ops-bg);
  box-shadow: none;
}

/* Left queue */
.ops-inbox {
  padding: 34px 22px 20px;
  border-right-color: var(--ops-line);
  background: var(--sv-color-surface-subtle);
}

.ops-inbox > header {
  padding: 0 4px 21px;
  border-bottom-color: var(--ops-line);
}

.ops-inbox > header h1 {
  margin-bottom: 7px;
  font-size: 25px;
  font-weight: 780;
  letter-spacing: -.045em;
}

.ops-inbox > header p,
.ops-detail-head p,
.ops-strategy > header p {
  color: var(--ops-muted);
  font-size: 13px;
  line-height: 1.55;
}

.ops-queue-nav {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 18px 2px 17px;
  border-bottom-color: var(--ops-line);
}

.ops-queue-nav button {
  position: relative;
  width: auto;
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: 5px;
  padding: 0 12px;
  border: 0;
  border-radius: 0;
  color: var(--sv-color-text-muted);
  background: transparent;
  font-size: 13px;
}

.ops-queue-nav button:first-child { padding-left: 0; }
.ops-queue-nav button + button::before {
  content: "/";
  position: absolute;
  left: 0;
  color: #4b534c;
}

.ops-queue-nav button:hover,
.ops-queue-nav button.is-active {
  border: 0;
  color: var(--ops-text);
  background: transparent;
}

.ops-queue-nav b {
  color: var(--ops-accent);
  font-size: 15px;
  line-height: 1;
}

.ops-task-list {
  min-height: 120px;
  gap: 10px;
  padding: 17px 0;
  scrollbar-width: none;
}

.ops-task-list::-webkit-scrollbar { display: none; }

.ops-task-item {
  position: relative;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 13px;
  padding: 12px;
  border: 0;
  border-radius: 10px;
  background: transparent;
}

.ops-task-item:hover { background: rgba(255, 255, 255, .025); }
.ops-task-item.is-active {
  border: 0;
  background: rgba(255, 255, 255, .055);
  box-shadow: none;
}

.ops-task-item.is-active::before {
  content: "";
  position: absolute;
  inset: 8px auto 8px 0;
  width: 4px;
  border-radius: 999px;
  background: var(--ops-accent);
  box-shadow: 0 0 18px rgba(201, 245, 44, .22);
}

.ops-task-thumb {
  width: 78px;
  height: 88px;
  border-radius: 8px;
  background: var(--sv-color-surface-elevated);
}

.ops-task-item > div:last-child { padding-top: 0; }
.ops-task-item small { color: var(--sv-color-text-muted); font-size: 11px; }
.ops-task-item strong { margin: 5px 0 7px; font-size: 15px; }
.ops-task-platforms { gap: 4px; margin-bottom: 7px; }
.ops-task-item p { color: var(--sv-color-text-faint); font-size: 10px; }

.ops-new-task {
  min-height: 48px;
  border-radius: 7px;
  font-size: 13px;
  box-shadow: 0 12px 28px rgba(130, 166, 0, .08);
}

.ops-inbox > footer {
  margin-top: 12px;
  padding-top: 16px;
  border-top-color: var(--ops-line);
  font-size: 12px;
}

.ops-inbox > footer a + a::before {
  content: "";
  display: inline-block;
  height: 18px;
  margin-right: 28px;
  border-left: 1px solid rgba(224, 232, 221, .18);
  vertical-align: middle;
}

/* Main editor */
.ops-task-detail {
  padding: 34px 34px 18px;
  background: var(--sv-color-surface-subtle);
}

.ops-detail-head {
  min-height: 81px;
  padding-bottom: 20px;
  border-bottom-color: var(--ops-line);
}

.ops-detail-head h2 {
  margin-bottom: 7px;
  font-size: 28px;
  font-weight: 780;
  letter-spacing: -.045em;
}

.ops-detail-head button,
.ops-inline-actions button {
  min-height: 40px;
  border-color: transparent;
  border-radius: 7px;
  background: var(--sv-color-surface-elevated);
  font-size: 12px;
}

.ops-detail-head button.is-quiet,
.ops-inline-actions button.is-quiet { border-color: var(--ops-line); }

.ops-adaptation-note {
  margin: 12px 0 2px;
  color: var(--sv-color-text-muted);
  font-size: 12px;
}

.ops-adaptation-note::before {
  width: 6px;
  height: 6px;
  margin-right: 9px;
  box-shadow: none;
}

.ops-variant-cards {
  min-height: 62px;
  gap: 20px;
  overflow-x: auto;
  border-bottom: 1px solid var(--ops-line);
}

.ops-variant-card {
  position: relative;
  min-width: auto;
  flex: 0 0 auto;
  grid-template-columns: 27px auto;
  gap: 8px;
  min-height: 62px;
  padding: 8px 2px 10px;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.ops-variant-card:hover,
.ops-variant-card.is-active {
  border: 0;
  background: transparent;
  box-shadow: none;
}

.ops-variant-card.is-active::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  border-radius: 999px;
  background: var(--ops-accent);
}

.ops-brand-icon.is-small {
  width: 27px;
  height: 27px;
  border-radius: 8px;
  box-shadow: none;
}

.ops-variant-label { gap: 2px; }
.ops-variant-card strong { font-size: 13px; font-weight: 700; }
.ops-variant-card small { font-size: 10px; }

.ops-platform-add {
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  align-self: center;
  border: 0;
  border-radius: 50%;
  color: var(--sv-color-text-muted);
  background: var(--sv-color-surface-elevated);
}

.ops-platform-add b { font-size: 19px; font-weight: 400; }
.ops-platform-add span { display: none; }

.ops-platform-work {
  margin-top: 0;
  padding: 27px 0 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.ops-platform-work > header { margin-bottom: 17px; }
.ops-platform-work h3 { font-size: 21px; font-weight: 760; }
.ops-platform-work > header span {
  padding: 4px 7px;
  border-radius: 4px;
  color: var(--ops-accent);
  background: rgba(201, 245, 44, .06);
  font-size: 10px;
}

.ops-mode-tabs {
  gap: 22px;
  padding: 0;
  border-radius: 0;
  background: transparent;
}

.ops-mode-tabs button {
  position: relative;
  min-height: 34px;
  padding: 0;
  border-radius: 0;
  font-size: 13px;
}

.ops-mode-tabs button.is-active {
  color: var(--ops-text);
  background: transparent;
}

.ops-mode-tabs button.is-active::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  background: var(--ops-accent);
}

.ops-edit-pane { gap: 13px; }
.ops-edit-pane label { gap: 7px; }
.ops-edit-pane .ops-body-field { min-height: 170px; }
.ops-edit-pane label > span,
.ops-field-label b { color: var(--sv-color-text-muted); font-size: 12px; font-weight: 650; }
.ops-field-label small { color: var(--sv-color-text-faint); font-size: 10px; }

.ops-edit-pane input,
.ops-edit-pane textarea,
.ops-strategy-card select {
  border-color: var(--ops-line);
  border-radius: 6px;
  background: var(--ops-input);
  font-size: 14px;
}

.ops-edit-pane input { min-height: 44px; padding-inline: 14px; }
.ops-edit-pane textarea { padding: 14px; line-height: 1.7; }
.ops-topic-help { color: var(--sv-color-text-faint) !important; font-size: 10px !important; }
.ops-topic-chips { min-height: 0; }
.ops-topic-chips:empty { display: none; }

.ops-preview-pane {
  overflow: hidden;
  padding-right: 2px;
}

.ops-preview-carousel { max-height: calc(100% - 112px); }
.ops-preview-copy { padding-top: 6px; }

.ops-inline-actions {
  min-height: 58px;
  justify-content: flex-start;
  margin-top: 13px;
  padding-top: 13px;
  border-top-color: var(--ops-line);
}

.ops-inline-actions .is-primary {
  min-width: 196px;
  padding-inline: 22px;
}

.ops-inline-actions .is-link {
  margin-left: auto;
  padding-right: 4px;
}

/* Right strategy — one quiet reading column, not a stack of cards. */
.ops-strategy {
  overflow: hidden;
  padding: 34px 28px 18px;
  border-left-color: var(--ops-line);
  background: var(--sv-color-surface-subtle);
}

.ops-strategy > header {
  padding: 0 0 20px;
  border-bottom-color: var(--ops-line);
}

.ops-strategy > header h2 {
  margin-bottom: 7px;
  font-size: 23px;
  font-weight: 780;
  letter-spacing: -.04em;
}

.ops-strategy-card {
  margin: 0;
  padding: 20px 0;
  border: 0;
  border-bottom: 1px solid var(--ops-line);
  border-radius: 0;
  background: transparent;
}

.ops-strategy-card > span {
  margin-bottom: 11px;
  color: var(--sv-color-text-faint);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .02em;
}

.ops-current-account b { font-size: 15px; }
.ops-current-account em { font-size: 11px; }
.ops-strategy-card > a,
.ops-strategy-card > button {
  width: auto;
  min-height: auto;
  margin-top: 11px;
  padding: 0;
  border: 0;
  color: var(--ops-accent);
  background: transparent;
  font-size: 12px;
  text-align: left;
}

.ops-strategy-card select {
  min-height: 48px;
  padding-inline: 13px;
  border: 0;
  background: var(--sv-color-surface-elevated);
}

.ops-strategy-card > p {
  margin: 8px 0 0;
  color: var(--sv-color-text-faint);
  font-size: 10px;
  line-height: 1.5;
}

.ops-production-summary {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0;
  border: 0;
  background: transparent;
}

.ops-production-summary b {
  padding: 7px 9px;
  border-radius: 5px;
  color: var(--ops-accent);
  background: rgba(201, 245, 44, .055);
  font-size: 13px;
}

.ops-production-summary small { font-size: 10px; }

.ops-matched-skill { padding-block: 15px; }
.ops-matched-skill > span { margin-bottom: 7px; }
.ops-skill-map { display: block; }
.ops-skill-map button { display: none; }
.ops-skill-map button.is-active {
  width: 100%;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  grid-template-rows: auto;
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
}

.ops-skill-map button.is-active .ops-brand-icon { grid-row: auto; }
.ops-skill-map button.is-active span { color: var(--sv-color-text-muted); font-size: 10px; }
.ops-skill-map button.is-active b { color: var(--sv-color-text); font-size: 11px; }

.ops-platform-rules { padding-bottom: 12px; border-bottom: 0; }
.ops-platform-rules dl > div { padding: 4px 0; }
.ops-platform-rules dt,
.ops-platform-rules dd { font-size: 11px; }

.ops-strategy > footer {
  padding-top: 7px;
  color: var(--sv-color-text-faint);
  font-size: 10px;
}

@media (max-height: 820px) and (min-width: 1181px) {
  .ops-inbox { padding-top: 24px; }
  .ops-task-detail { padding-top: 24px; }
  .ops-strategy { padding-top: 24px; }
  .ops-strategy-card { padding-block: 14px; }
  .ops-platform-work { padding-top: 18px; }
  .ops-edit-pane .ops-body-field { min-height: 125px; }
  .ops-platform-rules dl > div:nth-child(n+4) { display: none; }
}

@media (max-width: 1180px) {
  html[data-app-rail], body.has-app-rail { height: auto; overflow: visible; }
  .ops-shell { height: auto; min-height: 100dvh; }
  .ops-task-desk { height: auto; min-height: 100dvh; grid-template-columns: 260px minmax(0, 1fr); }
  .ops-strategy {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0 20px;
    overflow: visible;
    border-top: 1px solid var(--ops-line);
    border-left: 0;
  }
  .ops-strategy > header { grid-column: 1 / -1; }
  .ops-strategy-card { padding-inline: 4px; }
}

@media (max-width: 820px) {
  .ops-task-desk { grid-template-columns: 1fr; }
  .ops-inbox { max-height: 420px; border-right: 0; border-bottom: 1px solid var(--ops-line); }
  .ops-task-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ops-strategy { grid-column: auto; grid-template-columns: 1fr; }
  .ops-task-detail { padding-inline: 18px; }
}

@media (max-width: 560px) {
  .ops-task-list { grid-template-columns: 1fr; }
  .ops-detail-head { flex-direction: column; }
  .ops-detail-actions { width: 100%; }
  .ops-detail-actions button { flex: 1; }
  .ops-variant-cards { gap: 17px; }
  .ops-platform-work > header { align-items: flex-start; flex-direction: column; }
  .ops-inline-actions { flex-wrap: wrap; }
  .ops-inline-actions .is-link { width: 100%; margin-left: 0; text-align: right; }
}
