/* UFY Phone — Pantalla «Subir foto / Subir video»: lo de debajo de la vista
 * previa.
 *
 * Qué hace: da estilo al pie de la pantalla blanca de subida: los números de
 * la tanda, la descripción (que crece al escribir), los destinos y la tarjeta
 * de ajustes («Quién puede verlo», «Comentarios», «Guardar en borradores» y
 * «Portada»).
 * Quién lo usa: media-upload-settings.js (las filas) y media-composer.js (el
 * pie). Va junto a media-upload-screen.css y media-upload-card.css.
 *
 * Todo va bajo .ufy-upload-review:not(.is-editing): con el editor oscuro
 * abierto no se aplica nada de aquí.
 */

/* ---------- El pie: tanda, descripción y destinos ---------- */

.ufy-upload-review:not(.is-editing) .ufy-editor-footer {
  flex: none;
  padding: 6px 0 0;
  border: 0;
  background: transparent;
}

.ufy-upload-review:not(.is-editing) .ufy-editor-batch {
  gap: 8px;
  padding: 6px 0;
}

.ufy-upload-review:not(.is-editing) .ufy-editor-batch button {
  min-width: 44px;
  height: 44px;
  padding: 0 10px;
  border: 1px solid #d9d9e0;
  border-radius: 12px;
  background: var(--upload-soft);
  color: #3a3b40;
  font-size: 15px;
}

.ufy-upload-review:not(.is-editing) .ufy-editor-batch button[aria-pressed=true],
.ufy-upload-review:not(.is-editing) .ufy-editor-destinations button[aria-pressed=true] {
  border-color: var(--upload-dark);
  background: var(--upload-dark);
  color: #fff;
}

.ufy-upload-review:not(.is-editing) .ufy-editor-caption {
  display: block;
  margin: 8px 0;
}

/* 16 px: con menos, el iPhone amplía la página al escribir. La altura la
   ajusta media-upload-screen.js al escribir (hasta un 30 % de la pantalla). */
.ufy-upload-review:not(.is-editing) .ufy-editor-caption textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  max-height: 30dvh;
  padding: 12px 14px;
  border: 1px solid #d9d9e0;
  border-radius: 16px;
  background: #fafafb;
  color: var(--upload-text);
  font: 16px/1.4 Arial, sans-serif;
  resize: none;
}

.ufy-upload-review:not(.is-editing) .ufy-editor-caption textarea::placeholder {
  color: #6b6b74;
  opacity: 1;
}

.ufy-upload-review:not(.is-editing) .ufy-editor-destinations {
  flex-wrap: wrap;
  gap: 8px;
  margin: 6px 0 12px;
}

.ufy-upload-review:not(.is-editing) .ufy-editor-destinations button {
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid #d9d9e0;
  border-radius: 22px;
  background: var(--upload-soft);
  color: #3a3b40;
  font-size: 14px;
}

/* ---------- La tarjeta de ajustes ---------- */

.ufy-upload-review:not(.is-editing) .ufy-upload-settings {
  margin: 12px 0 4px;
  overflow: hidden;
  border: 1px solid var(--upload-line);
  border-radius: 20px;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: 58px;
  padding: 10px 16px;
  border: 0;
  background: transparent;
  color: var(--upload-text);
  text-align: left;
}

/* La raya entre filas empieza después del icono, como en la referencia. */
.ufy-upload-review:not(.is-editing) .ufy-upload-row + .ufy-upload-row::before {
  content: '';
  position: absolute;
  top: 0;
  left: 54px;
  right: 0;
  height: 1px;
  background: #ececf0;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row-icon,
.ufy-upload-review:not(.is-editing) .ufy-upload-row-arrow {
  display: grid;
  flex: none;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row-icon svg {
  width: 24px;
  height: 24px;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row-label {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row-name {
  font-size: 16px;
  line-height: 1.3;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row-hint {
  margin-top: 3px;
  font-size: 12.5px;
  line-height: 1.35;
  color: var(--upload-muted);
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row-value {
  max-width: 45%;
  overflow: hidden;
  font-size: 15px;
  color: var(--upload-muted);
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row-arrow {
  margin-left: -6px;
  color: var(--upload-muted);
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row-arrow svg {
  width: 20px;
  height: 20px;
}

/* Interruptor: apagado se distingue por su borde; encendido, oscuro. */
.ufy-upload-review:not(.is-editing) .ufy-upload-switch {
  position: relative;
  flex: none;
  width: 48px;
  height: 29px;
  border: 1.5px solid #7a7a84;
  border-radius: 20px;
  background: #ececf0;
  transition: background 0.15s, border-color 0.15s;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-switch::before {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px #0005;
  transition: transform 0.15s;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row[aria-checked=true] .ufy-upload-switch {
  border-color: var(--upload-dark);
  background: var(--upload-dark);
}

.ufy-upload-review:not(.is-editing) .ufy-upload-row[aria-checked=true] .ufy-upload-switch::before {
  transform: translateX(19px);
}

/* Portada: la miniatura del fotograma elegido (o un icono si no se pudo). */
.ufy-upload-review:not(.is-editing) .ufy-upload-cover-thumb {
  display: grid;
  place-items: center;
  flex: none;
  width: 38px;
  height: 50px;
  overflow: hidden;
  border-radius: 7px;
  background: #ececf0;
  color: var(--upload-muted);
}

.ufy-upload-review:not(.is-editing) .ufy-upload-cover-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ufy-upload-review:not(.is-editing) .ufy-upload-cover-thumb svg {
  width: 20px;
  height: 20px;
}

@media (prefers-reduced-motion: reduce) {
  .ufy-upload-review:not(.is-editing) .ufy-upload-switch,
  .ufy-upload-review:not(.is-editing) .ufy-upload-switch::before {
    transition: none;
  }
}

/* iPhone pequeño (320 px de ancho). */
@media (max-width: 360px) {
  .ufy-upload-review:not(.is-editing) .ufy-upload-row {
    gap: 12px;
    padding: 10px 12px;
  }

  .ufy-upload-review:not(.is-editing) .ufy-upload-row + .ufy-upload-row::before {
    left: 48px;
  }

  .ufy-upload-review:not(.is-editing) .ufy-upload-row-name {
    font-size: 15px;
  }

  .ufy-upload-review:not(.is-editing) .ufy-upload-row-value {
    font-size: 14px;
  }
}
