.optional {
  font-size: 10px;
  font-weight: 600;
  color: var(--muted);
  margin-left: 4px;
}

.field-note {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.4;
  margin: 7px 0 0;
}

.mode-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 18px;
}

.mode-button {
  min-width: 0;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.mode-button strong,
.mode-button span {
  display: block;
}

.mode-button strong {
  font-size: 12px;
}

.mode-button span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.mode-button.is-active {
  border-color: var(--accent);
  background: #fff7f4;
  box-shadow: 0 0 0 2px rgba(255, 107, 74, .1);
}

.mode-panel[hidden] {
  display: none;
}

.photo-note {
  margin: 7px 0 0;
}

.hint {
  text-align: right;
}

.primary-button:disabled {
  cursor: wait;
  opacity: .78;
  transform: none;
}

.generation-status {
  min-height: 18px;
  margin-top: 11px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.generation-status[data-state="error"] {
  color: #b42318;
}

.generation-status[data-state="success"] {
  color: #247b5b;
}

.generation-progress {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
}

.generation-progress li {
  position: relative;
  padding-top: 12px;
  color: #9aa1ac;
  font-size: 10px;
  line-height: 1.25;
  text-align: center;
}

.generation-progress li::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 7px;
  height: 7px;
  border: 1px solid #c9d0d8;
  border-radius: 50%;
  background: #fff;
  transform: translateX(-50%);
}

.generation-progress li.is-active,
.generation-progress li.is-done {
  color: #247b5b;
}

.generation-progress li.is-active::before {
  border-color: var(--accent);
  background: var(--accent);
}

.generation-progress li.is-done::before {
  border-color: #3fb27c;
  background: #3fb27c;
}

@media (max-width: 560px) {
  .mode-switch {
    grid-template-columns: 1fr;
  }

  .generation-progress li {
    font-size: 9px;
  }
}
