/* Shared export-ratio chip toolbar — used by textflow, wrapflow and audioflow
   so every app offers the same multi-ratio + All Ratios export as frameflow and
   clipflow. Mirrors the chip styling those two define inline. Token-based, so it
   follows each app's theme. */

.ratio-toolbar {
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
  pointer-events: auto;
}

.topbar-ratio-toolbar {
  flex: 0 1 330px;
  min-width: 0;
}

.topbar-ratio-toolbar .ratio-chips {
  max-width: min(28vw, 320px);
  overflow-x: auto;
  scrollbar-width: none;
}

.topbar-ratio-toolbar .ratio-chips::-webkit-scrollbar {
  display: none;
}

.ratio-chips {
  display: flex;
  gap: 5px;
}

.ratio-remove-button,
.ratio-select-button,
.ratio-add-button {
  min-height: 28px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--soft);
  font-size: 12px;
  font-weight: 800;
}

.ratio-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.ratio-remove-button {
  min-height: 20px;
  width: 20px;
  padding: 0;
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
}

.ratio-chip.is-active .ratio-select-button {
  border-color: rgba(76, 212, 154, 0.66);
  color: #dffff8;
  background: #16302d;
}

.ratio-chip.is-active .ratio-remove-button {
  border-color: rgba(76, 212, 154, 0.36);
}

.ratio-add-button {
  width: 28px;
  padding: 0;
}

.ratio-menu {
  position: absolute;
  z-index: 40;
  top: 34px;
  left: 0;
  display: grid;
  gap: 4px;
  min-width: 132px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--overlay);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
}

.ratio-menu.is-hidden {
  display: none;
}

.ratio-menu button {
  justify-content: flex-start;
  min-height: 30px;
  padding: 0 9px;
  border-radius: 6px;
  color: var(--soft);
  font-size: 12px;
  font-weight: 750;
  text-align: left;
}

/* "All Ratios" checkbox in the export panel. */
.export-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--soft);
  font-size: 12px;
}

.export-toggle input {
  width: 16px;
  height: 16px;
}

/* Toggle switches in the export panel — matches frameflow's golden-standard
   layout so every app's export reads the same. */
.switch {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  cursor: pointer;
}

.switch input {
  accent-color: var(--accent);
}

.export-switch {
  margin-top: 2px;
}

/* Highlight a drop-zone while a file is dragged over it. */
.drop-zone.is-drop-target {
  border-color: var(--accent);
  background: var(--accent-soft);
}
