/* ImageTwist upload controls - scoped presentation only.
   Does not change uploader JavaScript, form fields, endpoints or third-party uploader internals. */
.it-upload-panel,
.it-upload-card {
  width: 100%;
  max-width: 920px;
  margin: 0 auto 18px;
  float: none;
  clear: both;
}
.it-upload-intro {
  text-align: center;
  margin: 8px auto 20px;
  padding: 0 12px;
}
.it-upload-intro h2 {
  margin: 0 0 7px;
  color: var(--it-text, #23384d);
  font-size: 24px;
  font-weight: 650;
}
.it-upload-intro p,
.it-mode-help span,
.it-field-hint {
  color: var(--it-muted, #718096);
}
.it-upload-intro p { margin: 0; font-size: 14px; }
#utmodes.options {
  display: flex;
  justify-content: center;
  align-items: stretch;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 auto 18px;
  padding: 0 10px;
  float: none;
}
#utmodes.options > div {
  float: none;
  width: auto;
  flex: 0 1 190px;
  padding: 0;
  margin: 0;
}
#utmodes input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
#utmodes label {
  display: flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 10px 16px;
  border: 1px solid var(--it-border, #dce5ed);
  border-radius: 10px;
  background: var(--it-surface, #fff);
  color: var(--it-text, #34495e);
  font-weight: 600;
  cursor: pointer;
  transition: background .16s ease, border-color .16s ease, color .16s ease;
}
#utmodes label:hover,
#utmodes input[type="radio"]:focus-visible + label {
  border-color: #278fc7;
  color: #187caf;
}
#utmodes label.active {
  border-color: #278fc7;
  background: #eaf6fc;
  color: #176f9d;
  box-shadow: 0 0 0 2px rgba(39,143,199,.09);
}
.it-upload-card {
  box-sizing: border-box;
  padding: 20px 18px;
  border: 1px solid var(--it-border, #e1e8ef);
  border-radius: 14px;
  background: var(--it-surface, #fff);
  color: var(--it-text, #34495e);
  box-shadow: 0 5px 20px rgba(28,55,80,.045);
}
.it-mode-help {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0 0 16px;
}
.it-mode-help strong { font-size: 17px; color: var(--it-text, #23384d); }
.it-mode-help span { font-size: 13px; line-height: 1.5; }
.it-file-picker input[type="file"] {
  display: block;
  width: 100%;
  max-width: 100%;
  min-height: 42px;
  margin: 9px 0 0;
  padding: 8px;
  border: 1px solid var(--it-border, #dce5ed);
  border-radius: 8px;
  background: var(--it-surface-soft, #f7fafc);
  color: var(--it-text, #34495e);
}
.it-field-hint { margin: 7px 0 0; font-size: 12px; }
.it-upload-card .thumb_size,
.it-upload-card .per_row,
.it-upload-card .gallery {
  margin-top: 12px;
  margin-bottom: 12px;
  color: var(--it-text, #34495e);
}
.it-upload-card select,
.it-upload-card textarea {
  max-width: 100%;
  border: 1px solid var(--it-border, #d5e0e9);
  border-radius: 8px;
  background: var(--it-surface, #fff);
  color: var(--it-text, #34495e);
  padding: 9px 11px;
}
.it-upload-card textarea {
  display: block;
  width: 100%;
  min-height: 125px;
  resize: vertical;
  line-height: 1.5;
}
.it-upload-card .tos_terms { margin: 12px 0; }
.it-upload-card .it-upload-submit {
  min-width: 150px;
  border: 0;
  border-radius: 9px;
  background: #238fc7;
  color: #fff;
  font-weight: 650;
  box-shadow: none;
}
.it-upload-card .it-upload-submit:hover,
.it-upload-card .it-upload-submit:focus {
  background: #187caf;
  color: #fff;
}
#universaluploader_holder {
  max-width: 100%;
  margin: 0 auto;
  color: inherit;
}
/* Style only the third-party uploader's outer frame; leave its generated controls intact. */
#div_html5 #universaluploader_holder {
  overflow: visible;
}
@media (max-width: 600px) {
  .it-upload-card { padding: 16px 12px; border-radius: 11px; }
  #utmodes.options { gap: 8px; padding: 0; }
  #utmodes.options > div { flex: 1 1 calc(50% - 8px); }
  #utmodes label { min-height: 44px; padding: 9px 8px; font-size: 13px; }
  .it-upload-intro h2 { font-size: 21px; }
}
@media (prefers-reduced-motion: reduce) {
  #utmodes label { transition: none; }
}
