:root { --background: #f9faf7; }
body { background: #f9faf7; }
.workbench-header { padding: 28px 32px 0; border-bottom: 1px solid var(--line); background: #f9faf7; }
.heading-row { display: flex; justify-content: space-between; align-items: start; gap: 24px; }
h1 { font-size: 19px; font-weight: 500; line-height: 1.4; letter-spacing: -0.018em; margin: 0; }
h1 span { font-weight: 400; color: var(--muted); margin-left: 5px; }
.heading-row p { font-size: 13px; color: var(--muted); margin: 7px 0 0; line-height: 1.5; }
.font-credit a { display: inline-flex; min-height: 32px; align-items: center; text-decoration-color: #b3b8ad; }
.controls-row { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-top: 23px; }
.button-group { display: inline-flex; align-items: center; gap: 4px; }
.button-group button { border: 1px solid transparent; background: transparent; padding: 10px 14px; min-height: 44px; font-size: 13px; border-radius: 5px; color: var(--muted); }
.button-group button[aria-pressed='true'] { background: #e8ece3; color: var(--ink); }
.button-group button:hover { color: var(--ink); border-color: var(--line); }
.button-group button span { margin-left: 6px; }
.secondary-controls { display: flex; gap: 24px; align-items: center; }
.stress-label { font-size: 12px; display: flex; align-items: center; gap: 7px; min-height: 44px; color: var(--muted); white-space: nowrap; }
.stress-label input { width: 15px; height: 15px; margin: 0; }
.palette-row { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 13px 0 15px; }
.palette { padding: 0; margin: 0; border: 0; min-width: 0; }
#swatches { display: flex; flex-wrap: wrap; gap: 4px; }
.swatch { display: flex; align-items: center; gap: 7px; font-size: 12px; min-height: 44px; padding: 5px 10px; border: 1px solid transparent; background: none; border-radius: 5px; color: var(--muted); }
.swatch[aria-pressed='true'] { border-color: #8b9586; color: var(--ink); }
.swatch:hover { background: #eef0e9; }
.swatch-dot { display: inline-block; width: 17px; height: 17px; border-radius: 50%; border: 1px solid #bcc2b7; background: var(--swatch-color); }
#color-description { margin: 0; font-size: 12px; color: var(--muted); line-height: 1.5; text-align: right; }
.previews { padding: 24px 32px 16px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; min-height: 240px; }
.previews[data-view='both'] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.preview-panel { min-width: 0; }
.preview-panel[hidden] { display: none; }
.preview-label { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; }
.preview-label h2, .preview-label a { font-size: 12px; font-weight: 400; line-height: 1.5; margin: 0; }
.preview-label a { color: var(--muted); min-height: 32px; display: inline-flex; align-items: center; gap: 6px; text-decoration-color: #b3b8ad; }
.frame-space { display: flex; justify-content: center; }
.frame-clip { border: 1px solid #cdd2c7; overflow: hidden; background: var(--paper); }
iframe { display: block; border: 0; transform-origin: top left; }
.workbench-footer { display: flex; justify-content: space-between; gap: 20px; padding: 0 32px 24px; }
.workbench-footer p { font-size: 12px; line-height: 1.6; color: var(--muted); margin: 0; }
.workbench-footer p:last-child { text-align: right; }
.no-script { padding: 24px; }
@media (max-width: 1050px) {
  .controls-row { align-items: start; flex-wrap: wrap; gap: 6px; }
  .palette-row { align-items: start; flex-direction: column; gap: 6px; }
  #color-description { text-align: left; }
}
@media (max-width: 650px) {
  .workbench-header { padding: 20px 16px 0; }
  h1 { font-size: 17px; }
  .heading-row { display: block; }
  .heading-row .font-credit { margin-top: 8px; }
  .controls-row { margin-top: 12px; }
  .button-group { gap: 0; }
  .button-group button { padding-inline: 10px; font-size: 12px; }
  .button-group button span { margin-left: 3px; }
  .secondary-controls { width: 100%; justify-content: space-between; gap: 8px; }
  #swatches { gap: 3px; }
  .swatch { padding-inline: 8px; }
  .previews { padding: 16px; gap: 24px; }
  .previews[data-view='both'] { grid-template-columns: minmax(0, 1fr); }
  .workbench-footer { padding: 0 16px 24px; flex-direction: column; gap: 6px; }
  .workbench-footer p:last-child { text-align: left; }
}

#study { font: inherit; color: var(--muted); background: transparent; border: 0; border-bottom: 1px solid var(--line); padding: 4px 20px 4px 0; min-height: 36px; max-width: 100%; cursor: pointer; }
.stress-label[hidden] { display: none; }
