/* ── Workspace ── */
    .workspace {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 1px;
      background: var(--rule);
      border: 1px solid var(--border);
    }

    /* ── Preview Panes ── */

    .pane-header {
      display: flex; align-items: center; justify-content: space-between;
      padding: 10px 16px; border-bottom: 1px solid var(--border); background: var(--bg);
    }
    .pane-header-left { display: flex; align-items: center; gap: 8px; }
    .pane-title { font-size: 10px; letter-spacing: 0.2em; color: var(--ink-light); text-transform: uppercase; }
    .badge-color { background: #E8F0FE; color: #3060C0; }
    .badge-mono  { background: #E8E8E8; color: #333333; }
    .pane-meta   { font-size: 10px; color: var(--ink-light); }

    .pane-img-area {
      flex: 1; min-height: 320px;
      display: flex; align-items: center; justify-content: center;
      padding: 20px;
      background: repeating-conic-gradient(#E8EAED 0% 25%, #F8F9FA 0% 50%) 0 0 / 16px 16px;
    }
    .pane-img-area img {
      max-width: 100%; max-height: 360px; object-fit: contain;
      display: block; box-shadow: 0 4px 20px rgba(0,0,0,0.13);
    }

    .pane-footer {
      padding: 10px 16px; border-top: 1px solid var(--border);
      display: flex; align-items: center; justify-content: space-between;
      background: var(--bg);
    }

    /* Algorithm selector */
    .algo-btns { display: flex; gap: 0; }
    .algo-btn {
      font-size: 10px; letter-spacing: 0.08em;
      padding: 8px 14px; border: 1px solid var(--border); background: transparent;
      color: var(--ink-light); cursor: pointer; transition: all 0.15s; margin-left: -1px;
      white-space: nowrap;
    }
    .algo-btn:first-child { margin-left: 0; }
    .algo-btn:hover:not(.active) { border-color: var(--blue); color: var(--blue); z-index: 1; }
    .algo-btn.active { background: var(--blue); color: #fff; border-color: var(--blue); z-index: 1; }

    /* Sliders */

    .slider-wrap { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 160px; }
    .slider-num  { font-size: 18px; color: var(--ink); min-width: 36px; text-align: right; line-height: 1; }

    /* Output format */

    /* ── Tone curve (channel weights) ── */
    .channel-sliders { display: flex; flex-direction: column; gap: 8px; flex: 1; min-width: 200px; }
    .ch-row { display: flex; align-items: center; gap: 8px; }
    .ch-label {
      font-size: 10px; letter-spacing: 0.1em;
      width: 16px; text-align: center; flex-shrink: 0;
    }
    .ch-label.r { color: #C03030; }
    .ch-label.g { color: #308030; }
    .ch-label.b { color: #3060C0; }
    .ch-val { font-size: 11px; color: var(--ink-light); min-width: 30px; text-align: right; flex-shrink: 0; }

    /* ── Saving strip ── */
    .saving-strip {
      display: flex; align-items: stretch;
      border: 1px solid var(--border); background: var(--card);
    }
    .saving-big {
      padding: 18px 24px; background: var(--blue); color: white;
      display: flex; flex-direction: column; justify-content: center; gap: 2px; flex-shrink: 0;
    }
    .saving-big-label { font-size: 9px; letter-spacing: 0.2em; color: rgba(255,255,255,0.45); text-transform: uppercase; }
    .saving-big-num   { font-size: 40px; font-weight: 400; letter-spacing: -0.02em; line-height: 1; }
    .saving-big-unit  { font-size: 10px; color: rgba(255,255,255,0.45); letter-spacing: 0.1em; }

    .saving-details { display: flex; flex: 1; flex-wrap: wrap; }
    .saving-item {
      flex: 1; padding: 14px 18px; border-right: 1px solid var(--border);
      display: flex; flex-direction: column; justify-content: center; gap: 3px; min-width: 100px;
    }
    .saving-item:last-child { border-right: none; }
    .saving-key { font-size: 9px; letter-spacing: 0.2em; color: var(--ink-light); text-transform: uppercase; }
    .saving-val { font-size: 16px; color: var(--ink); }

    /* ── Action bar ── */

    .convert-btn {
      font-size: 12px; letter-spacing: 0.15em;
      background: var(--blue); color: var(--bg); border: none; height: 48px; padding: 0 32px;
      cursor: pointer; transition: background 0.15s, transform 0.1s;
      display: flex; align-items: center; gap: 10px;
    }
    .convert-btn:hover { background: var(--blue-hover); }
    .convert-btn:active { transform: scale(0.98); }
    .convert-btn:disabled { opacity: 0.35; cursor: not-allowed; }
    .convert-btn:disabled:hover { background: var(--blue); }

    /* spinner */
    .is-converting .spinner { display: block; }
    .is-converting .btn-label { display: none; }
