/* ============================================================
   EDITOR · estilos base (sin preview)
   ============================================================ */
/* ============================================================
   FIX: el atributo hidden debe respetarse siempre
   ============================================================ */
[hidden] {
  display: none !important;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

.material-symbols-outlined {
  font-family: "Material Symbols Outlined";
  font-weight: normal;
  font-style: normal;
  font-size: 1.15em;
  line-height: 1;
  display: inline-block;
  text-transform: none;
  letter-spacing: normal;
  word-wrap: normal;
  white-space: nowrap;
  direction: ltr;
  vertical-align: -0.2em;
  user-select: none;
  font-feature-settings: "liga";
  -webkit-font-smoothing: antialiased;
}

:root {
  color-scheme: dark light;
  --ed-bg: #0b0d13;
  --ed-bg-subtle: #11141e;
  --ed-surface: #141824;
  --ed-surface-elev: #1b2030;
  --ed-surface-soft: rgba(255, 255, 255, 0.035);
  --ed-surface-hover: rgba(255, 255, 255, 0.065);
  --ed-border: rgba(255, 255, 255, 0.09);
  --ed-border-strong: rgba(255, 255, 255, 0.16);
  --ed-text: #f3f4f8;
  --ed-text-soft: #9ca3b8;
  --ed-text-muted: #6b7280;
  --ed-accent: #6366f1;
  --ed-accent-hover: #4f46e5;
  --ed-accent-soft: rgba(99, 102, 241, 0.16);
  --ed-accent-text: #b4b7ff;
  --ed-shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.22);
  --ed-shadow-lg: 0 24px 64px rgba(0, 0, 0, 0.55);
  --ed-input-bg: rgba(255, 255, 255, 0.045);
  --ed-select-bg: #141824;
  --ed-picker-filter: invert(1);
}

@media (prefers-color-scheme: light) {
  :root {
    --ed-bg: #f3f5fa;
    --ed-bg-subtle: #eef1f7;
    --ed-surface: #ffffff;
    --ed-surface-elev: #ffffff;
    --ed-surface-soft: #f8fafc;
    --ed-surface-hover: #f1f5f9;
    --ed-border: rgba(15, 23, 42, 0.1);
    --ed-border-strong: rgba(15, 23, 42, 0.18);
    --ed-text: #0f172a;
    --ed-text-soft: #475569;
    --ed-text-muted: #94a3b8;
    --ed-accent: #4f46e5;
    --ed-accent-hover: #4338ca;
    --ed-accent-soft: rgba(79, 70, 229, 0.1);
    --ed-accent-text: #4338ca;
    --ed-shadow-sm: 0 2px 12px rgba(15, 23, 42, 0.06);
    --ed-shadow-lg: 0 24px 60px rgba(15, 23, 42, 0.16);
    --ed-input-bg: #ffffff;
    --ed-select-bg: #ffffff;
    --ed-picker-filter: invert(0);
  }
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  overflow: hidden;
  font-family:
    "Inter",
    system-ui,
    -apple-system,
    sans-serif;
  background: var(--ed-bg);
  color: var(--ed-text);
  -webkit-font-smoothing: antialiased;
}

/* ============================================================
   ESTADOS
   ============================================================ */
.editor-state {
  position: fixed;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  padding: 2rem;
  text-align: center;
  background: var(--ed-bg);
}

.editor-state h2 {
  margin: 0;
  font-size: 1.35rem;
  color: var(--ed-text);
}
.editor-state p {
  margin: 0;
  color: var(--ed-text-soft);
  max-width: 40ch;
}
.editor-state button {
  margin-top: 1rem;
  padding: 0.85rem 1.7rem;
  border: 0;
  border-radius: 10px;
  background: var(--ed-accent);
  color: #fff;
  font: 600 0.9rem inherit;
  cursor: pointer;
  transition: background 0.15s ease;
}
.editor-state button:hover {
  background: var(--ed-accent-hover);
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--ed-border);
  border-top-color: var(--ed-accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ============================================================
   EDITOR LAYOUT
   ============================================================ */
.editor {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
}

/* ---------- HEADER ---------- */
.editor-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: 68px;
  padding: 0 1.5rem;
  background: var(--ed-surface);
  border-bottom: 1px solid var(--ed-border);
  box-shadow: var(--ed-shadow-sm);
  flex-shrink: 0;
  z-index: 10;
}

.editor-header__left {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
}

.editor-header__brand {
  font-weight: 700;
  font-size: 1rem;
  color: var(--ed-text);
  letter-spacing: -0.01em;
}

.editor-header__badge {
  display: inline-flex;
  align-items: center;
  padding: 0.34rem 0.72rem;
  border-radius: 999px;
  background: var(--ed-accent-soft);
  color: var(--ed-accent-text);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: capitalize;
}

.editor-header__badge--plan {
  background: rgba(245, 158, 11, 0.16);
  color: #d97706;
}

@media (prefers-color-scheme: dark) {
  .editor-header__badge--plan {
    color: #fbbf24;
  }
}

.editor-header__right {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

/* ---------- BOTONES ---------- */
.editor-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.65rem 1.15rem;
  border: 1px solid transparent;
  border-radius: 10px;
  font: 600 0.84rem inherit;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.1s ease;
}
.editor-btn:active {
  transform: scale(0.97);
}

.editor-btn--ghost {
  background: var(--ed-surface-soft);
  border-color: var(--ed-border);
  color: var(--ed-text);
}
.editor-btn--ghost:hover {
  background: var(--ed-surface-hover);
  border-color: var(--ed-border-strong);
}

.editor-btn--primary {
  background: var(--ed-accent);
  color: #fff;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.28);
}
.editor-btn--primary:hover {
  background: var(--ed-accent-hover);
}

/* ---------- BODY ---------- */
.editor-body {
  display: grid;
  grid-template-columns: 296px 1fr;
  flex: 1;
  min-height: 0;
  position: relative;
}

/* ---------- SIDEBAR ---------- */
.editor-sidebar {
  display: flex;
  flex-direction: column;
  background: var(--ed-surface);
  border-right: 1px solid var(--ed-border);
  overflow: hidden;
}

.editor-sidebar__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.15rem 1.35rem;
  border-bottom: 1px solid var(--ed-border);
  flex-shrink: 0;
}

.editor-sidebar__header h2 {
  margin: 0;
  font-size: 0.96rem;
  font-weight: 700;
  color: var(--ed-text);
  letter-spacing: -0.01em;
}

.editor-sidebar__close {
  display: none;
  width: 34px;
  height: 34px;
  border: 1px solid var(--ed-border);
  border-radius: 8px;
  background: var(--ed-surface-soft);
  color: var(--ed-text);
  font-size: 1rem;
  cursor: pointer;
}

.editor-panel__nav {
  display: flex;
  flex-direction: column;
  padding: 1rem 0.9rem;
  gap: 0.35rem;
  overflow-y: auto;
  flex: 1;
}

.editor-nav-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.8rem 0.95rem;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: var(--ed-text-soft);
  font: 500 0.89rem inherit;
  text-align: left;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}
.editor-nav-item:hover {
  background: var(--ed-surface-hover);
  color: var(--ed-text);
}
.editor-nav-item.is-active {
  background: var(--ed-accent-soft);
  border-color: rgba(99, 102, 241, 0.28);
  color: var(--ed-accent-text);
  font-weight: 600;
}
.editor-nav-item__icon {
  font-size: 1.15rem;
  width: 22px;
  text-align: center;
}
.editor-nav-item__label {
  flex: 1;
}
.editor-nav-item__badge {
  font-size: 0.65rem;
  padding: 0.15rem 0.45rem;
  border-radius: 6px;
  background: var(--ed-surface-soft);
  color: var(--ed-text-soft);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ---------- CONTENT ---------- */
.editor-content {
  overflow-y: auto;
  padding: clamp(1.75rem, 4vw, 3.25rem) clamp(1.35rem, 4vw, 3.25rem);
  width: 100%;
  background: var(--ed-bg);
}

.editor-content > * {
  max-width: 780px;
  margin-left: auto;
  margin-right: auto;
}

.editor-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 320px;
  text-align: center;
  color: var(--ed-text-soft);
}
.editor-empty p {
  margin: 0 0 0.5rem;
  font-size: 0.98rem;
}
.editor-empty__hint {
  font-size: 0.82rem;
  color: var(--ed-text-muted);
}

/* ---------- FAB mobile ---------- */
.editor-fab {
  display: none;
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 54px;
  height: 54px;
  border: 0;
  border-radius: 50%;
  background: var(--ed-accent);
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4);
  z-index: 100;
}

/* ============================================================
   FORMULARIOS
   ============================================================ */
.editor-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  background: var(--ed-surface);
  border: 1px solid var(--ed-border);
  border-radius: 16px;
  padding: clamp(1.4rem, 3vw, 2.25rem);
  box-shadow: var(--ed-shadow-sm);
}

.editor-form > form {
  display: flex;
  flex-direction: column;
  gap: 1.35rem;
}

.editor-form__status {
  min-height: 24px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ed-text-soft);
  padding: 0.45rem 0.85rem;
  border-radius: 8px;
  transition:
    opacity 0.2s ease,
    background 0.2s ease;
}
.editor-form__status.is-saving {
  color: var(--ed-accent-text);
  background: var(--ed-accent-soft);
}
.editor-form__status.is-saved {
  color: #16a34a;
  background: rgba(34, 197, 94, 0.14);
}
@media (prefers-color-scheme: dark) {
  .editor-form__status.is-saved {
    color: #4ade80;
  }
}
.editor-form__status.is-error {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
}

.editor-field {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Bloque destacado (Estilo de portada al inicio del editor) */
.editor-field--featured {
  padding: 1.25rem 1.35rem;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--ed-accent-soft), var(--ed-surface-soft));
  border: 1.5px solid rgba(99, 102, 241, 0.35);
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.08);
}

.editor-field--featured > .editor-field__label {
  color: var(--ed-accent-text);
  font-size: 0.84rem;
}

.editor-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
  margin-top: 0.25rem;
}

@media (max-width: 600px) {
  .editor-choice-grid {
    grid-template-columns: 1fr;
  }
}

.editor-choice-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.45rem;
  padding: 1rem 1.05rem;
  border-radius: 12px;
  border: 1.5px solid var(--ed-border);
  background: var(--ed-surface);
  color: var(--ed-text);
  text-align: left;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.12s ease;
}

.editor-choice-card:hover {
  border-color: var(--ed-border-strong);
  background: var(--ed-surface-hover);
  transform: translateY(-1px);
}

.editor-choice-card.is-selected {
  border-color: var(--ed-accent);
  background: var(--ed-accent-soft);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.16);
}

.editor-choice-card__top {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.editor-choice-card__icon-wrap {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--ed-surface-soft);
  color: var(--ed-accent-text);
}

.editor-choice-card.is-selected .editor-choice-card__icon-wrap {
  background: var(--ed-accent);
  color: #ffffff;
}

.editor-choice-card__badge {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.18);
  color: #d97706;
}
@media (prefers-color-scheme: dark) {
  .editor-choice-card__badge {
    color: #fbbf24;
  }
}

.editor-choice-card__check {
  margin-left: auto;
  font-size: 1.35rem;
  color: var(--ed-text-muted);
}

.editor-choice-card.is-selected .editor-choice-card__check {
  color: var(--ed-accent);
  font-variation-settings: "FILL" 1, "wght" 600, "GRAD" 0, "opsz" 24;
}

.editor-choice-card__title {
  font-size: 0.94rem;
  font-weight: 700;
  color: var(--ed-text);
  margin-top: 0.15rem;
}

.editor-choice-card__desc {
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--ed-text-soft);
}

.editor-field__label {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--ed-text-soft);
  text-transform: uppercase;
}

.editor-field__input {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1px solid var(--ed-border);
  border-radius: 10px;
  background: var(--ed-input-bg);
  color: var(--ed-text);
  font:
    400 0.94rem "Inter",
    system-ui,
    sans-serif;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease,
    background 0.15s ease;
}

select.editor-field__input option {
  background-color: var(--ed-select-bg);
  color: var(--ed-text);
}
.editor-field__input:focus {
  outline: none;
  border-color: var(--ed-accent);
  box-shadow: 0 0 0 3px var(--ed-accent-soft);
  background: var(--ed-surface);
}
.editor-field__input::placeholder {
  color: var(--ed-text-muted);
}

.editor-field__textarea {
  resize: vertical;
  min-height: 92px;
  line-height: 1.55;
  font-family: "Inter", system-ui, sans-serif;
}

.editor-field__input[type="datetime-local"]::-webkit-calendar-picker-indicator {
  filter: var(--ed-picker-filter);
  cursor: pointer;
}

/* ============================================================
   LISTA DE COLORES
   ============================================================ */
.editor-color-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.editor-color-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.editor-color-input {
  width: 44px;
  height: 44px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
  padding: 0;
  overflow: hidden;
}
.editor-color-input::-webkit-color-swatch-wrapper {
  padding: 0;
}
.editor-color-input::-webkit-color-swatch {
  border: 0;
  border-radius: 4px;
}
.editor-color-input::-moz-color-swatch {
  border: 0;
  border-radius: 4px;
}

.editor-color-code {
  font-size: 0.65rem;
  color: #8e8e93;
  font-family: "Courier New", monospace;
  letter-spacing: 0.02em;
}

/* ============================================================
   GALERÍA
   ============================================================ */
.editor-gallery {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.editor-gallery__status {
  font-size: 0.85rem;
  color: #8e8e93;
  text-align: center;
  padding: 2rem 1rem;
}

.editor-gallery__counter {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0.85rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.82rem;
  color: #c7c7cc;
}
.editor-gallery__counter strong {
  color: #f5f5f7;
  font-weight: 700;
  font-size: 0.95rem;
}

.editor-gallery__plan {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #a5a6f6;
  background: rgba(99, 102, 241, 0.15);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

.editor-gallery__dropzone {
  position: relative;
  border: 2px dashed rgba(99, 102, 241, 0.4);
  border-radius: 12px;
  padding: 2rem 1rem;
  text-align: center;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease;
}
.editor-gallery__dropzone:hover,
.editor-gallery__dropzone.is-dragover {
  background: rgba(99, 102, 241, 0.08);
  border-color: rgba(99, 102, 241, 0.7);
}

.editor-gallery__file-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}

.editor-gallery__dropzone-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  pointer-events: none;
}
.editor-gallery__dropzone-icon {
  font-size: 2rem;
  margin-bottom: 0.25rem;
}
.editor-gallery__dropzone-text {
  font-size: 0.9rem;
  font-weight: 600;
  color: #f5f5f7;
}
.editor-gallery__dropzone-hint {
  font-size: 0.72rem;
  color: #8e8e93;
}

.editor-gallery__full {
  padding: 1rem;
  border-radius: 8px;
  background: rgba(251, 191, 36, 0.1);
  border: 1px solid rgba(251, 191, 36, 0.3);
  font-size: 0.82rem;
  color: #fbbf24;
  text-align: center;
}

.editor-gallery__empty {
  padding: 1rem;
  text-align: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}
.editor-gallery__empty p {
  margin: 0 0 0.35rem;
  color: #a1a1aa;
  font-size: 0.85rem;
}
.editor-gallery__empty-hint {
  font-size: 0.72rem !important;
  color: #636366 !important;
  line-height: 1.4;
}

.editor-gallery__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
}

.editor-gallery__item {
  position: relative;
  aspect-ratio: 1;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05);
}

.editor-gallery__thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.editor-gallery__remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  font-size: 0.75rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition:
    opacity 0.15s ease,
    background 0.15s ease;
}
.editor-gallery__item:hover .editor-gallery__remove {
  opacity: 1;
}
.editor-gallery__remove:hover {
  background: #ef4444;
}

.editor-gallery__uploads {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.editor-gallery__upload-row {
  display: grid;
  grid-template-columns: 1fr 80px auto;
  align-items: center;
  gap: 0.65rem;
  padding: 0.55rem 0.75rem;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.75rem;
}
.editor-gallery__upload-row.is-done {
  background: rgba(74, 222, 128, 0.1);
}
.editor-gallery__upload-row.is-error {
  background: rgba(248, 113, 113, 0.1);
}

.editor-gallery__upload-name {
  color: #c7c7cc;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.editor-gallery__progress {
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.editor-gallery__progress-bar {
  height: 100%;
  background: #6366f1;
  border-radius: 999px;
  transition: width 0.15s ease;
}

.editor-gallery__progress-pct {
  color: #a5a6f6;
  font-weight: 600;
  font-size: 0.72rem;
  text-align: right;
  min-width: 30px;
}

/* ============================================================
   MODAL DE CONFIRMACIÓN
   ============================================================ */
.confirm-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.confirm-modal[hidden] {
  display: none;
}

.confirm-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: confirmFadeIn 0.2s ease;
}

.confirm-modal__dialog {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  background: #1a1a22;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 2rem 1.75rem;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.6);
  animation: confirmSlideUp 0.25s cubic-bezier(0.2, 0.9, 0.3, 1.1);
}

.confirm-modal__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  color: #a1a1aa;
  font-size: 0.95rem;
  cursor: pointer;
}
.confirm-modal__close:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #f5f5f7;
}

.confirm-modal__header {
  margin-bottom: 1.5rem;
  padding-right: 2rem;
}
.confirm-modal__header h2 {
  margin: 0 0 0.35rem;
  font-size: 1.35rem;
  font-weight: 700;
  color: #f5f5f7;
}
.confirm-modal__subtitle {
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.55;
  color: #a1a1aa;
}

.confirm-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1.1rem;
}
.confirm-field label {
  font-size: 0.78rem;
  font-weight: 600;
  color: #a1a1aa;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.confirm-field input,
.confirm-field textarea {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: #f5f5f7;
  font:
    400 0.92rem "Inter",
    system-ui,
    sans-serif;
}
.confirm-field input:focus,
.confirm-field textarea:focus {
  outline: none;
  border-color: #6366f1;
  background: rgba(99, 102, 241, 0.06);
}
.confirm-field small {
  font-size: 0.7rem;
  color: #71717a;
  line-height: 1.3;
}
.confirm-slug-row {
  display: flex;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  overflow: hidden;
}
.confirm-slug-row:focus-within {
  border-color: #6366f1;
  background: rgba(99, 102, 241, 0.06);
}
.confirm-slug-prefix {
  padding: 0.75rem 0.65rem 0.75rem 0.9rem;
  font-family: monospace;
  font-size: 0.85rem;
  color: #a5a6f6;
  background: rgba(99, 102, 241, 0.08);
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  user-select: none;
}
.confirm-slug-row input {
  border: none !important;
  background: transparent !important;
  border-radius: 0 !important;
  font-family: monospace;
}
.confirm-slug-status.is-ok {
  color: #4ade80;
}
.confirm-slug-status.is-error {
  color: #f87171;
}
.confirm-slug-status.is-checking {
  color: #a5a6f6;
}
.confirm-field textarea {
  resize: vertical;
  min-height: 70px;
  line-height: 1.5;
}
.confirm-field input[type="date"]::-webkit-calendar-picker-indicator {
  filter: invert(1);
  cursor: pointer;
}

.confirm-fieldset {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 1rem 1.15rem;
  margin: 0 0 1.1rem;
  background: rgba(255, 255, 255, 0.02);
}
.confirm-fieldset legend {
  font-size: 0.78rem;
  font-weight: 600;
  color: #a1a1aa;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0 0.35rem;
}
.confirm-radio {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.55rem 0.25rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: #d4d4d8;
}
.confirm-radio input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: #6366f1;
  cursor: pointer;
}

.confirm-song-fields {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 1rem;
  margin-bottom: 1.1rem;
  border-radius: 10px;
  background: rgba(99, 102, 241, 0.06);
  border: 1px solid rgba(99, 102, 241, 0.2);
}
.confirm-song-fields[hidden] {
  display: none;
}

.confirm-error {
  margin: 0 0 1rem;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  background: rgba(248, 113, 113, 0.1);
  border: 1px solid rgba(248, 113, 113, 0.3);
  font-size: 0.85rem;
  color: #f87171;
}
.confirm-error[hidden] {
  display: none;
}

.confirm-actions {
  display: flex;
  gap: 0.65rem;
  justify-content: flex-end;
  margin-top: 1.5rem;
}
.confirm-actions button {
  min-width: 130px;
}
.confirm-actions button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.confirm-success {
  text-align: center;
  padding: 1rem 0;
}
.confirm-success__icon {
  font-size: 3.5rem;
  margin-bottom: 0.75rem;
  line-height: 1;
}
.confirm-success h2 {
  margin: 0 0 0.75rem;
  font-size: 1.4rem;
  color: #f5f5f7;
}
.confirm-success p {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  line-height: 1.6;
  color: #d4d4d8;
}
.confirm-success__note {
  font-size: 0.82rem !important;
  color: #a1a1aa !important;
  margin-bottom: 1.75rem !important;
}

@keyframes confirmFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes confirmSlideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
  .editor-gallery__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .editor-sidebar {
    top: 0;
    z-index: 80;
    padding-top: 0.5rem;
  }

  .editor-header {
    padding: 0 0.75rem;
    height: 56px;
  }
  .editor-header__brand {
    font-size: 0.85rem;
  }
  .editor-header__badge {
    font-size: 0.65rem;
    padding: 0.25rem 0.5rem;
  }
  .editor-btn {
    padding: 0.5rem 0.75rem;
    font-size: 0.75rem;
  }

  .editor-body {
    grid-template-columns: 1fr;
  }

  .editor-sidebar {
    position: fixed;
    top: 56px;
    left: 0;
    bottom: 0;
    width: 100%;
    max-width: 320px;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    z-index: 50;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.4);
  }
  .editor-sidebar.is-open {
    transform: translateX(0);
  }
  .editor-sidebar__close {
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .editor-fab {
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .editor-sidebar.is-open ~ .editor-fab {
    display: none;
  }

  .editor-content {
    padding: 1.5rem 1.25rem;
  }

  .editor-gallery__grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .editor-gallery__remove {
    opacity: 1;
  }

  .confirm-modal__dialog {
    padding: 1.5rem 1.25rem;
    border-radius: 12px;
  }
  .confirm-modal__header h2 {
    font-size: 1.2rem;
  }
  .confirm-actions {
    flex-direction: column-reverse;
  }
  .confirm-actions button {
    width: 100%;
    min-width: 0;
  }
}

@media (max-width: 560px) {
  .editor-header {
    padding: 0 0.5rem;
    gap: 0.35rem;
  }
  .editor-header__left {
    gap: 0.35rem;
    min-width: 0;
    overflow: hidden;
  }
  #badgeTheme {
    display: none;
  }
  .editor-header__brand {
    font-size: 0.8rem;
  }
  .editor-header__right {
    gap: 0.35rem;
    flex-shrink: 0;
  }
  .editor-btn {
    padding: 0.42rem 0.6rem;
    font-size: 0.72rem;
  }
}

/* ============================================================
   P2: UPLOAD HISTORIA, LISTAS DINÁMICAS, RECOVERY & TOAST
   ============================================================ */
.editor-image-upload-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-top: 0.35rem;
}
.editor-image-upload-row .editor-field__input {
  flex: 1;
  min-width: 180px;
}

.editor-timeline-item__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.editor-item-remove {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(248, 113, 113, 0.25);
  border-radius: 6px;
  background: rgba(248, 113, 113, 0.08);
  color: #f87171;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease;
}
.editor-item-remove:hover {
  background: rgba(248, 113, 113, 0.2);
  border-color: #f87171;
}
.editor-item-remove .material-symbols-outlined {
  font-size: 16px;
}

.editor-list-actions {
  display: flex;
  justify-content: flex-start;
  margin-top: 0.5rem;
}

.confirm-recovery-box {
  text-align: left;
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.25);
  border-radius: 10px;
  padding: 0.85rem 1rem;
  margin-bottom: 1.4rem;
}
.confirm-recovery-box label {
  display: block;
  font-size: 0.74rem;
  font-weight: 600;
  color: #a5a6f6;
  margin-bottom: 0.45rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.confirm-recovery-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.confirm-recovery-row input {
  flex: 1;
  min-width: 0;
  padding: 0.5rem 0.65rem;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.35);
  color: #f5f5f7;
  font-size: 0.78rem;
  font-family: monospace;
}

.confirm-mp-box {
  background: rgba(0, 158, 227, 0.1);
  border-color: rgba(0, 158, 227, 0.35);
}

.confirm-mp-box label {
  color: #7dd3fc;
}

.confirm-mp-box__desc {
  font-size: 0.82rem;
  color: #d4d4d8;
  margin: 0 0 0.75rem !important;
  line-height: 1.4;
}

.editor-btn--mp {
  background: #009ee3;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.editor-btn--mp:hover:not(:disabled) {
  background: #008ad0;
}

/* ============================================================
   MODAL VISTA PREVIA DENTRO DEL EDITOR
   (Con #editorPreviewModal para no chocar con el modal de videos/fondos)
   ============================================================ */
#editorPreviewModal.editor-preview-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

#editorPreviewModal.editor-preview-modal[hidden] {
  display: none;
}

#editorPreviewModal .editor-preview-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 5, 10, 0.82);
  backdrop-filter: blur(6px);
}

#editorPreviewModal .editor-preview-modal__dialog {
  position: relative;
  width: 100%;
  max-width: min(1240px, 95vw);
  height: min(92vh, 900px);
  max-height: min(92vh, 900px);
  aspect-ratio: auto;
  background: #14141b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.65);
}

#editorPreviewModal .editor-preview-modal__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1.1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: #191923;
  flex-shrink: 0;
}

#editorPreviewModal .editor-preview-modal__left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #f5f5f7;
}

#editorPreviewModal .editor-preview-modal__left h2 {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0;
}

#editorPreviewModal .editor-preview-modal__viewport {
  display: inline-flex;
  gap: 0.25rem;
  padding: 0.2rem;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

#editorPreviewModal .editor-vp-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.35rem 0.75rem;
  border: none;
  border-radius: 7px;
  background: transparent;
  color: #a1a1aa;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s;
}

#editorPreviewModal .editor-vp-btn.is-active {
  background: rgba(99, 102, 241, 0.24);
  color: #e0e7ff;
}

#editorPreviewModal .editor-preview-modal__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

#editorPreviewModal .editor-preview-modal__close {
  position: static;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: #f5f5f7;
  cursor: pointer;
}

#editorPreviewModal .editor-preview-modal__close:hover {
  background: rgba(255, 255, 255, 0.12);
}

#editorPreviewModal .editor-preview-modal__stage {
  position: relative;
  flex: 1;
  min-height: 0;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0b0b10;
  padding: 1rem;
}

#editorPreviewModal .editor-preview-modal__stage iframe {
  width: 100%;
  height: 100%;
  border: none;
  background: #fff;
  border-radius: 10px;
  transition: max-width 0.25s ease;
}

#editorPreviewModal .editor-preview-modal__stage.is-mobile iframe {
  max-width: 390px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 22px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.55);
}

#editorPreviewModal .editor-preview-modal__stage.is-desktop {
  padding: 0;
}

#editorPreviewModal .editor-preview-modal__stage.is-desktop iframe {
  max-width: 100%;
  border-radius: 0;
}

#editorPreviewModal .editor-preview-modal__loading {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: rgba(11, 11, 16, 0.9);
  color: #a1a1aa;
  font-size: 0.9rem;
  z-index: 2;
}

#editorPreviewModal .editor-preview-modal__loading[hidden] {
  display: none;
}

@media (max-width: 720px) {
  #editorPreviewModal.editor-preview-modal {
    padding: 0;
  }
  #editorPreviewModal .editor-preview-modal__dialog {
    height: 100vh;
    max-height: 100vh;
    max-width: 100%;
    border-radius: 0;
  }
  #editorPreviewModal .editor-preview-modal__viewport,
  #editorPreviewModal .editor-preview-ext-label {
    display: none;
  }
  #editorPreviewModal .editor-preview-modal__stage.is-mobile {
    padding: 0;
  }
  #editorPreviewModal .editor-preview-modal__stage.is-mobile iframe {
    max-width: 100%;
    border-radius: 0;
    border: none;
  }
}

/* ---------- Hints y vista previa de mapa en ubicación ---------- */
.editor-field__hint {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.78rem;
  line-height: 1.45;
  color: #9ca3af;
}

.editor-map-preview {
  margin-top: 1.1rem;
  padding: 0.9rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.editor-map-preview__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.editor-map-preview__title {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: #f5f5f7;
}

.editor-map-preview__link {
  font-size: 0.78rem;
  color: #a5b4fc;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.editor-map-preview__link:hover {
  text-decoration: underline;
}

.editor-map-preview__frame {
  width: 100%;
  height: 240px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  background: #0d0d12;
}

.editor-map-preview__empty {
  padding: 1.4rem 1rem;
  text-align: center;
  font-size: 0.82rem;
  color: #9ca3af;
  border: 1px dashed rgba(255, 255, 255, 0.14);
  border-radius: 10px;
}

.editor-map-preview__note {
  margin: 0;
  font-size: 0.76rem;
  color: #a1a1aa;
  line-height: 1.4;
}

.editor-toast {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  border-radius: 10px;
  background: #1a1a22;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.55);
  color: #f5f5f7;
  font-size: 0.85rem;
  font-weight: 500;
  z-index: 10000;
  opacity: 0;
  transition:
    transform 0.25s ease,
    opacity 0.2s ease;
  pointer-events: none;
}
.editor-toast.is-visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}
.editor-toast--error .editor-toast__icon {
  color: #f87171;
}
.editor-toast--success .editor-toast__icon {
  color: #4ade80;
}
.editor-toast--info .editor-toast__icon {
  color: #a5a6f6;
}

.editor-dialog-modal {
  z-index: 1200;
}
.editor-dialog__box {
  max-width: 420px;
}
.editor-dialog__body {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.editor-dialog__icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(99, 102, 241, 0.16);
  color: #a5a6f6;
}
.editor-dialog__icon--danger {
  background: rgba(248, 113, 113, 0.16);
  color: #f87171;
}
.editor-dialog__icon .material-symbols-outlined {
  font-size: 1.5rem;
}
.editor-dialog__title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
  color: #f5f5f7;
}
.editor-dialog__message {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.55;
  color: #d4d4d8;
}
.editor-btn--danger {
  background: #dc2626;
  color: #fff;
}
.editor-btn--danger:hover {
  background: #b91c1c;
}

/* ============================================================
   IMAGE FIELD
   ============================================================ */
.editor-image-field {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.editor-image-preview {
  width: 100%;
  max-height: 260px;
  overflow: hidden;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px dashed rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
}

.editor-image-preview img {
  max-width: 100%;
  max-height: 240px;
  object-fit: contain;
  display: block;
  border-radius: 4px;
}

/* ============================================================
   CRONOGRAMA
   ============================================================ */
.editor-timeline-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.editor-timeline-item {
  padding: 1rem 1.15rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.editor-timeline-item__header {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.85rem;
}

.editor-timeline-item__index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(99, 102, 241, 0.2);
  color: #a5a6f6;
  font-size: 0.72rem;
  font-weight: 700;
}

.editor-timeline-item__hint {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #8e8e93;
}

.editor-timeline-item__fields {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 0.75rem;
}

.editor-timeline-item__fields > .editor-field:nth-child(3) {
  grid-column: 1 / -1;
}

@media (max-width: 600px) {
  .editor-timeline-item__fields {
    grid-template-columns: 1fr;
  }
  .editor-timeline-item__fields > .editor-field:nth-child(3) {
    grid-column: auto;
  }
}
/* ============================================================
   CONFIRMACIONES RSVP
   ============================================================ */
.editor-responses {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.editor-responses__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.editor-responses__stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem 0.75rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

.editor-responses__stat--total {
  background: rgba(99, 102, 241, 0.1);
  border-color: rgba(99, 102, 241, 0.3);
}

.editor-responses__stat-num {
  font-size: 1.75rem;
  font-weight: 700;
  color: #f5f5f7;
  line-height: 1;
  margin-bottom: 0.35rem;
}

.editor-responses__stat--total .editor-responses__stat-num {
  color: #a5a6f6;
}

.editor-responses__stat-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #8e8e93;
}

.editor-responses__list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.editor-response-card {
  padding: 0.9rem 1rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-left: 3px solid rgba(255, 255, 255, 0.15);
}

.editor-response-card.is-confirmed {
  border-left-color: #4ade80;
}

.editor-response-card.is-declined {
  border-left-color: #f87171;
}

.editor-response-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.editor-response-card__head strong {
  font-size: 0.95rem;
  color: #f5f5f7;
}

.editor-response-card__badge {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.editor-response-card__badge.is-yes {
  background: rgba(74, 222, 128, 0.15);
  color: #4ade80;
}

.editor-response-card__badge.is-no {
  background: rgba(248, 113, 113, 0.15);
  color: #f87171;
}

.editor-response-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  font-size: 0.82rem;
  color: #a1a1aa;
  margin-bottom: 0.35rem;
}

.editor-response-card__note {
  font-size: 0.82rem;
  color: #a1a1aa;
  margin-top: 0.35rem;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.editor-response-card__note--msg {
  font-style: italic;
  color: #d4d4d8;
}

.editor-response-card__note strong {
  color: #f5f5f7;
}

.editor-responses__toolbar {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.editor-responses__filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.editor-responses__filter {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #a1a1aa;
  font-size: 0.78rem;
  font-weight: 500;
  padding: 0.38rem 0.75rem;
  border-radius: 999px;
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s,
    border-color 0.15s;
}

.editor-responses__filter:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #f5f5f7;
}

.editor-responses__filter.is-active {
  background: rgba(99, 102, 241, 0.2);
  border-color: rgba(129, 140, 248, 0.55);
  color: #e0e7ff;
}

.editor-responses__controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
}

.editor-responses__search {
  flex: 1 1 180px;
  min-width: 0;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: #f5f5f7;
  font-size: 0.85rem;
}

.editor-responses__search:focus {
  outline: none;
  border-color: rgba(129, 140, 248, 0.6);
}

.editor-responses__csv-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  white-space: nowrap;
}

.editor-response-card__actions {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.editor-response-card__wa {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.55rem;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  color: #4ade80;
  background: rgba(34, 197, 94, 0.14);
  border: 1px solid rgba(74, 222, 128, 0.28);
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
}

.editor-response-card__wa:hover {
  background: rgba(34, 197, 94, 0.24);
  border-color: rgba(74, 222, 128, 0.5);
}

.editor-response-card__wa .material-symbols-outlined {
  font-size: 0.95rem;
}

.editor-response-card__delete {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  border: 1px solid transparent;
  background: transparent;
  color: #8e8e93;
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s;
}

.editor-response-card__delete:hover {
  background: rgba(248, 113, 113, 0.15);
  color: #f87171;
}
/* ============================================================
   TRIVIA
   ============================================================ */
.editor-trivia-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.editor-trivia-item {
  padding: 1rem 1.15rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.editor-trivia-option {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.editor-trivia-option input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: #6366f1;
  cursor: pointer;
  flex-shrink: 0;
}

.editor-trivia-option .editor-field__input {
  flex: 1;
}
/* ============================================================
   PLAYLIST + SIGNBOOK (editor)
   ============================================================ */
.editor-social-counter {
  padding: 0.65rem 0.85rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.82rem;
  color: #c7c7cc;
  margin-bottom: 0.75rem;
}
.editor-social-counter strong {
  color: #f5f5f7;
  font-weight: 700;
  font-size: 0.95rem;
}

.editor-social-list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.editor-social-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.editor-social-item__body {
  flex: 1;
  min-width: 0;
}

.editor-social-item__body strong {
  display: block;
  font-size: 0.9rem;
  color: #f5f5f7;
  margin-bottom: 0.2rem;
}

.editor-social-item__meta {
  font-size: 0.75rem;
  color: #8e8e93;
  font-style: italic;
}

.editor-social-item__msg {
  display: block;
  font-size: 0.85rem;
  color: #d4d4d8;
  line-height: 1.5;
}

.editor-social-item__remove {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.05);
  color: #a1a1aa;
  font-size: 0.75rem;
  cursor: pointer;
  transition:
    background 0.15s ease,
    color 0.15s ease;
}
.editor-social-item__remove:hover {
  background: #ef4444;
  color: #fff;
}
/* ============================================================
   COLOR LIST · con agregar/quitar
   ============================================================ */
.editor-color-list-wrapper {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.editor-color-item {
  position: relative;
}

.editor-color-remove {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 20px;
  height: 20px;
  border: 0;
  border-radius: 50%;
  background: #ef4444;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition:
    opacity 0.15s ease,
    transform 0.15s ease;
}

.editor-color-item:hover .editor-color-remove {
  opacity: 1;
}

.editor-color-remove:hover {
  transform: scale(1.15);
}

.editor-color-add {
  align-self: flex-start;
  padding: 0.55rem 1rem;
  border: 1px dashed rgba(99, 102, 241, 0.4);
  border-radius: 8px;
  background: transparent;
  color: #a5a6f6;
  font: 600 0.8rem inherit;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease;
}

.editor-color-add:hover {
  background: rgba(99, 102, 241, 0.08);
  border-color: rgba(99, 102, 241, 0.7);
}

@media (max-width: 768px) {
  .editor-color-remove {
    opacity: 1;
  }
}
/* ============================================================
   GALERÍA · slots visuales
   ============================================================ */
.editor-gallery {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.editor-gallery__counter {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0.85rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.82rem;
  color: #c7c7cc;
}
.editor-gallery__counter strong {
  color: #f5f5f7;
  font-weight: 700;
  font-size: 0.95rem;
}

.editor-gallery__plan {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #a5a6f6;
  background: rgba(99, 102, 241, 0.15);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

.editor-gallery__hint {
  font-size: 0.8rem;
  color: #8e8e93;
  margin: 0;
  line-height: 1.5;
}

.editor-gallery__slots {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.65rem;
}

@media (max-width: 600px) {
  .editor-gallery__slots {
    grid-template-columns: repeat(3, 1fr);
  }
}

.editor-slot {
  position: relative;
  aspect-ratio: 1;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  border: 2px dashed rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.03);
  transition:
    border-color 0.15s ease,
    transform 0.15s ease;
}

.editor-slot:hover {
  border-color: rgba(99, 102, 241, 0.6);
  transform: translateY(-2px);
}

.editor-slot.is-custom {
  border: 2px solid rgba(74, 222, 128, 0.5);
}

.editor-slot.is-template .editor-slot__img {
  opacity: 0.55;
  filter: grayscale(0.3);
}

.editor-slot__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition:
    opacity 0.2s ease,
    filter 0.2s ease;
}

.editor-slot:hover .editor-slot__img {
  opacity: 1;
  filter: none;
}

.editor-slot__input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  display: none;
}

.editor-slot__badge {
  position: absolute;
  top: 6px;
  left: 6px;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  background: rgba(0, 0, 0, 0.65);
  color: #fff;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.editor-slot.is-custom .editor-slot__badge {
  background: rgba(74, 222, 128, 0.85);
  color: #0a2e15;
}

.editor-slot__remove {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 24px;
  height: 24px;
  border: 0;
  border-radius: 6px;
  background: rgba(239, 68, 68, 0.9);
  color: #fff;
  font-size: 0.7rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease;
}

.editor-slot__remove:hover {
  transform: scale(1.15);
}

/* Uploads en progreso (ya existen pero reafirmo) */
.editor-gallery__uploads {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.editor-gallery__upload-row {
  display: grid;
  grid-template-columns: 1fr 80px auto;
  align-items: center;
  gap: 0.65rem;
  padding: 0.55rem 0.75rem;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.75rem;
}
.editor-gallery__upload-row.is-done {
  background: rgba(74, 222, 128, 0.1);
}
.editor-gallery__upload-row.is-error {
  background: rgba(248, 113, 113, 0.1);
}

.editor-gallery__upload-name {
  color: #c7c7cc;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.editor-gallery__progress {
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.editor-gallery__progress-bar {
  height: 100%;
  background: #6366f1;
  border-radius: 999px;
  transition: width 0.15s ease;
}

.editor-gallery__progress-pct {
  color: #a5a6f6;
  font-weight: 600;
  font-size: 0.72rem;
  text-align: right;
  min-width: 30px;
}

/* ============================================================
   BADGE MODO PRUEBA
   ============================================================ */
.editor-header__badge--testing {
  background: rgba(251, 191, 36, 0.15);
  color: #fbbf24;
}

.editor-header__badge--readonly {
  background: rgba(74, 222, 128, 0.15);
  color: #4ade80;
}
/* ============================================================
   BADGES DE ESTADO
   ============================================================ */
.editor-header__badge--state {
  font-size: 0.65rem;
  padding: 0.25rem 0.6rem;
  border-radius: 5px;
  font-weight: 600;
  letter-spacing: 0.03em;
}

/* ============================================================
   PANEL DE SECCIONES VISIBLES
   ============================================================ */
.editor-sections__intro {
  font-size: 0.88rem;
  line-height: 1.6;
  color: #a1a1aa;
  margin: 0 0 1.5rem;
}

.editor-sections__locked {
  padding: 1rem 1.15rem;
  border-radius: 10px;
  background: rgba(74, 222, 128, 0.06);
  border: 1px solid rgba(74, 222, 128, 0.15);
  margin-bottom: 2rem;
}

.editor-sections__locked-title {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #4ade80;
  margin: 0 0 0.65rem;
}

.editor-sections__locked-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.editor-sections__locked-item {
  padding: 0.3rem 0.75rem;
  border-radius: 6px;
  background: rgba(74, 222, 128, 0.12);
  color: #86efac;
  font-size: 0.78rem;
  font-weight: 500;
}

.editor-sections__list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Toggle switch */
.editor-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1.15rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    background 0.15s ease;
  user-select: none;
}

.editor-toggle:hover {
  border-color: rgba(99, 102, 241, 0.3);
  background: rgba(255, 255, 255, 0.05);
}

.editor-toggle__label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
  min-width: 0;
}

.editor-toggle__icon {
  font-size: 1.1rem;
  width: 24px;
  text-align: center;
  flex-shrink: 0;
}

.editor-toggle__text {
  font-size: 0.92rem;
  color: #e5e5ea;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Ocultar el checkbox real */
.editor-toggle input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

/* Switch visual */
.editor-toggle__switch {
  position: relative;
  flex-shrink: 0;
  width: 44px;
  height: 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  transition: background-color 0.25s ease;
}

.editor-toggle__switch::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  transition: transform 0.25s cubic-bezier(0.2, 0.9, 0.3, 1.1);
}

/* Estado activo (checked) */
.editor-toggle input[type="checkbox"]:checked ~ .editor-toggle__switch {
  background: #6366f1;
}

.editor-toggle input[type="checkbox"]:checked ~ .editor-toggle__switch::after {
  transform: translateX(20px);
}

/* Estado desactivado (unchecked): línea tachada */
.editor-toggle input[type="checkbox"]:not(:checked) ~ .editor-toggle__switch {
  background: rgba(255, 255, 255, 0.12);
}

.editor-toggle input[type="checkbox"]:focus-visible ~ .editor-toggle__switch {
  outline: 2px solid #6366f1;
  outline-offset: 3px;
}

/* ============================================================
   MEDIA PICKER (video + música)
   ============================================================ */
.editor-media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1rem;
}

.editor-media-item {
  position: relative;
  aspect-ratio: 9 / 16;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.03);
  border: 2px solid rgba(255, 255, 255, 0.08);
  transition:
    border-color 0.2s ease,
    transform 0.15s ease;
}

.editor-media-item:hover {
  border-color: rgba(99, 102, 241, 0.4);
  transform: translateY(-2px);
}

.editor-media-item.is-selected {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.editor-media-item__thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: #000;
}

.editor-media-item__thumb.is-video-thumb {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: auto;
  height: 100%;
  min-width: 320%;
  max-width: none;
  object-fit: cover;
  pointer-events: none;
}

.editor-media-item__play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid #fff;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    background 0.15s ease,
    transform 0.15s ease;
  z-index: 2;
}

.editor-media-item__play:hover {
  background: rgba(99, 102, 241, 0.85);
  transform: translate(-50%, -50%) scale(1.1);
}

.editor-media-item__check {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #6366f1;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.editor-media-item__label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 0.5rem;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  text-align: center;
}

/* Lista de música — grid de 3 columnas */
.editor-media-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
}

@media (max-width: 900px) {
  .editor-media-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .editor-media-list {
    grid-template-columns: 1fr;
  }
}

.editor-media-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.75rem 0.85rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    background 0.15s ease;
  min-height: 68px;
}

.editor-media-row:hover {
  border-color: rgba(99, 102, 241, 0.3);
  background: rgba(255, 255, 255, 0.05);
}

.editor-media-row.is-selected {
  border-color: #6366f1;
  background: rgba(99, 102, 241, 0.08);
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
}

.editor-media-row__play {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(99, 102, 241, 0.15);
  color: #a5a6f6;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    transform 0.1s ease;
}

.editor-media-row__play:hover {
  background: #6366f1;
  color: #fff;
  transform: scale(1.05);
}

.editor-media-row__name {
  flex: 1;
  min-width: 0;
  font-size: 0.82rem;
  color: #f5f5f7;
  font-weight: 500;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}

.editor-media-row__check {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #6366f1;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Modal de preview de video */
.editor-preview-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.editor-preview-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.editor-preview-modal__dialog {
  position: relative;
  width: 100%;
  max-width: 440px;
  background: #000;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.85);
  aspect-ratio: 9 / 16;
  max-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.editor-preview-modal__video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  background: #000;
}

/* Compensación de videos 16:9 con barras negras laterales en el preview del editor */
.editor-preview-modal.is-pillarboxed .editor-preview-modal__video {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: auto;
  height: 100%;
  min-width: 320%;
  object-fit: cover;
}

.editor-preview-modal__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  z-index: 2;
}

.editor-preview-modal__close:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* ============================================================
   GRID DE FONDOS (aspect ratio 9:16 + Botones Ver y Seleccionar)
   ============================================================ */
.editor-media-grid--bg {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1.15rem;
}

.editor-bg-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.04);
  border: 2px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  overflow: hidden;
  transition:
    border-color 0.2s ease,
    transform 0.15s ease,
    box-shadow 0.2s ease;
}

.editor-bg-card:hover {
  border-color: rgba(99, 102, 241, 0.45);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.editor-bg-card.is-selected {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25);
  background: rgba(99, 102, 241, 0.06);
}

.editor-bg-card__thumb-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 9 / 16;
  background: #111;
  cursor: pointer;
  overflow: hidden;
}

.editor-bg-card__thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.25s ease;
}

.editor-bg-card:hover .editor-bg-card__thumb {
  transform: scale(1.03);
}

.editor-bg-card__btn-view {
  position: absolute;
  top: 8px;
  left: 8px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0.35rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: #fff;
  background: rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 6px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  cursor: pointer;
  z-index: 2;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    transform 0.15s ease;
}

.editor-bg-card__btn-view:hover {
  background: rgba(99, 102, 241, 0.95);
  border-color: #6366f1;
  transform: scale(1.06);
}

.editor-bg-card__btn-view .material-symbols-outlined {
  font-size: 14px;
}

.editor-bg-card__check {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #6366f1;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.editor-bg-card__check .material-symbols-outlined {
  font-size: 16px;
}

.editor-bg-card__footer {
  padding: 0.55rem;
  background: rgba(0, 0, 0, 0.3);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.editor-bg-card__btn-select {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 0.45rem 0.6rem;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.08);
  color: #e5e5ea;
  cursor: pointer;
  transition: all 0.15s ease;
}

.editor-bg-card__btn-select:hover {
  background: rgba(99, 102, 241, 0.3);
  border-color: #6366f1;
  color: #fff;
}

.editor-bg-card__btn-select.is-selected {
  background: #6366f1;
  border-color: #6366f1;
  color: #fff;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.4);
}

.editor-bg-card__btn-select .material-symbols-outlined {
  font-size: 15px;
}

/* Modal de vista previa completa de imagen */
.editor-preview-modal__dialog--img {
  max-width: 480px;
  aspect-ratio: auto;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  background: #141419;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.85);
}

.editor-preview-modal__header-bar {
  padding: 0.85rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: #a5a6f6;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.editor-preview-modal__img-wrap {
  flex: 1;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  padding: 1rem;
  overflow: auto;
}

.editor-preview-modal__img {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
  display: block;
  border-radius: 6px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
}

.editor-preview-modal__footer {
  padding: 0.85rem 1rem;
  background: rgba(18, 18, 24, 0.95);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  justify-content: center;
}

.editor-preview-modal__select-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.65rem 1.6rem;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

/* ============================================================
   SISTEMA UNIFICADO CLARO / OSCURO (Manual + Automático OS)
   Estética Nudo Landing (#faf8f3 · #2c2a26 · #b08d57 / champagne)
   ============================================================ */
:root,
:root[data-editor-theme="dark"] {
  --ed-bg: #12100e;
  --ed-bg-elevated: rgba(24, 21, 18, 0.92);
  --ed-surface: #1b1815;
  --ed-surface-soft: rgba(250, 248, 243, 0.045);
  --ed-surface-hover: rgba(176, 141, 87, 0.12);
  --ed-border: rgba(212, 185, 140, 0.14);
  --ed-border-strong: rgba(212, 185, 140, 0.3);

  --ed-text: #f7f3eb;
  --ed-text-soft: #bcb4a6;
  --ed-text-muted: #8b8375;

  --ed-accent: #c9a56b;
  --ed-accent-hover: #b08d57;
  --ed-accent-soft: rgba(176, 141, 87, 0.18);
  --ed-accent-border: rgba(201, 165, 107, 0.48);
  --ed-accent-text: #efdcb9;
  --ed-accent-btn-text: #191510;

  --ed-input-bg: rgba(14, 12, 10, 0.72);
  --ed-shadow: 0 4px 16px rgba(0, 0, 0, 0.32);
  --ed-shadow-lg: 0 22px 54px rgba(0, 0, 0, 0.56);
}

:root[data-editor-theme="light"] {
  --ed-bg: #faf8f3;
  --ed-bg-elevated: rgba(255, 255, 255, 0.94);
  --ed-surface: #ffffff;
  --ed-surface-soft: #f4efe6;
  --ed-surface-hover: #ede5d5;
  --ed-border: #e5decb;
  --ed-border-strong: #d3c5aa;

  --ed-text: #2c2a26;
  --ed-text-soft: #5f5a50;
  --ed-text-muted: #857e72;

  --ed-accent: #b08d57;
  --ed-accent-hover: #7a5c3a;
  --ed-accent-soft: rgba(176, 141, 87, 0.14);
  --ed-accent-border: rgba(176, 141, 87, 0.45);
  --ed-accent-text: #7a5c3a;
  --ed-accent-btn-text: #ffffff;

  --ed-input-bg: #ffffff;
  --ed-shadow: 0 2px 12px rgba(44, 42, 38, 0.05);
  --ed-shadow-lg: 0 18px 44px rgba(44, 42, 38, 0.14);
}

@media (prefers-color-scheme: light) {
  :root:not([data-editor-theme="dark"]) {
    --ed-bg: #faf8f3;
    --ed-bg-elevated: rgba(255, 255, 255, 0.94);
    --ed-surface: #ffffff;
    --ed-surface-soft: #f4efe6;
    --ed-surface-hover: #ede5d5;
    --ed-border: #e5decb;
    --ed-border-strong: #d3c5aa;

    --ed-text: #2c2a26;
    --ed-text-soft: #5f5a50;
    --ed-text-muted: #857e72;

    --ed-accent: #b08d57;
    --ed-accent-hover: #7a5c3a;
    --ed-accent-soft: rgba(176, 141, 87, 0.14);
    --ed-accent-border: rgba(176, 141, 87, 0.45);
    --ed-accent-text: #7a5c3a;
    --ed-accent-btn-text: #ffffff;

    --ed-input-bg: #ffffff;
    --ed-shadow: 0 2px 12px rgba(44, 42, 38, 0.05);
    --ed-shadow-lg: 0 18px 44px rgba(44, 42, 38, 0.14);
  }
}

/* Detalles y acentos dorados compartidos entre Landing y Editor (Claro & Oscuro) */
.editor-header {
  border-top: 2px solid var(--ed-accent);
  background: var(--ed-bg-elevated);
  border-bottom-color: var(--ed-border);
}

.editor-header__brand {
  color: var(--ed-text);
  letter-spacing: -0.015em;
}

.editor-header__badge--plan {
  background: var(--ed-accent-soft);
  color: var(--ed-accent-text);
  border: 1px solid var(--ed-accent-border);
}

.editor-btn--primary {
  background: linear-gradient(135deg, var(--ed-accent) 0%, var(--ed-accent-hover) 100%);
  color: var(--ed-accent-btn-text);
  border: 1px solid rgba(176, 141, 87, 0.35);
  box-shadow: 0 4px 14px rgba(176, 141, 87, 0.25);
}

.editor-btn--primary:hover:not(:disabled) {
  background: var(--ed-accent-hover);
  color: #ffffff;
}

.editor-btn--ghost {
  background: var(--ed-surface-soft);
  border-color: var(--ed-border);
  color: var(--ed-text);
}

.editor-btn--ghost:hover:not(:disabled) {
  background: var(--ed-surface-hover);
  border-color: var(--ed-accent-border);
}

.editor-nav-item.is-active {
  background: var(--ed-accent-soft);
  border-color: var(--ed-accent-border);
  color: var(--ed-accent-text);
}

.editor-nav-item.is-active::before {
  background: var(--ed-accent);
}

.editor-fab {
  background: linear-gradient(135deg, var(--ed-accent) 0%, var(--ed-accent-hover) 100%);
  color: var(--ed-accent-btn-text);
  box-shadow: 0 8px 24px rgba(176, 141, 87, 0.38);
}

.editor-card--featured {
  border-color: var(--ed-accent-border);
  box-shadow: 0 8px 26px rgba(176, 141, 87, 0.12);
}

.editor-choice-card.is-selected {
  border-color: var(--ed-accent);
  background: var(--ed-accent-soft);
  box-shadow: 0 0 0 3px rgba(176, 141, 87, 0.18);
}

.editor-choice-card__check {
  color: var(--ed-text-muted);
}

.editor-choice-card.is-selected .editor-choice-card__check {
  color: var(--ed-accent-text);
}

.editor-field input:focus,
.editor-field textarea:focus,
.editor-field select:focus {
  border-color: var(--ed-accent);
  box-shadow: 0 0 0 3px rgba(176, 141, 87, 0.18);
}

.editor-gallery__plan,
.editor-gallery__progress-pct,
.editor-color-add,
.editor-responses__stat--total .editor-responses__stat-num,
.editor-media-row__play,
.editor-social-item__num,
.editor-toast--info .editor-toast__icon,
.editor-map-preview__link,
.confirm-slug-prefix,
.confirm-slug-status.is-checking,
.confirm-recovery-box__label,
.editor-sections__locked a {
  color: var(--ed-accent-text);
}

.editor-gallery__plan,
.editor-social-item__num,
.editor-media-row__play,
.editor-responses__stat--total,
.editor-responses__filter.is-active,
.confirm-slug-prefix,
.confirm-recovery-box,
.editor-sections__locked-icon {
  background: var(--ed-accent-soft);
  border-color: var(--ed-accent-border);
}

.editor-gallery__progress-bar,
.editor-toggle input[type="checkbox"]:checked ~ .editor-toggle__switch,
.editor-media-item__badge,
.editor-media-row__badge,
.editor-bg-card__badge,
.editor-bg-card__btn-select.is-selected {
  background: var(--ed-accent);
  border-color: var(--ed-accent);
  color: var(--ed-accent-btn-text);
}

.editor-toggle input[type="checkbox"]:focus-visible ~ .editor-toggle__switch {
  outline: 2px solid var(--ed-accent);
}

.editor-trivia-option input[type="radio"],
.confirm-radio input[type="radio"] {
  accent-color: var(--ed-accent);
}

.editor-media-item:hover,
.editor-media-row:hover,
.editor-bg-card:hover,
.editor-toggle:hover,
.editor-slot:hover,
.editor-color-add:hover,
.editor-gallery__dropzone:hover,
.editor-gallery__dropzone.is-dragover {
  border-color: var(--ed-accent-border);
}

.editor-media-item.is-selected,
.editor-media-row.is-selected,
.editor-bg-card.is-selected {
  border-color: var(--ed-accent);
  background: var(--ed-accent-soft);
  box-shadow: 0 0 0 3px rgba(176, 141, 87, 0.22);
}

.editor-color-add {
  border-color: var(--ed-accent-border);
}

.editor-color-add:hover,
.editor-media-row__play:hover,
.editor-bg-card__btn-view:hover,
.editor-bg-card__btn-select:hover,
.editor-gallery__dropzone:hover,
.editor-gallery__dropzone.is-dragover {
  background: var(--ed-accent-soft);
}

.confirm-field input:focus,
.confirm-field textarea:focus,
.confirm-slug-row:focus-within {
  border-color: var(--ed-accent);
  background: var(--ed-accent-soft);
}

#editorPreviewModal .editor-vp-btn.is-active {
  background: var(--ed-accent-soft);
  border-color: var(--ed-accent-border);
  color: var(--ed-accent-text);
}

/* Espaciado moderno en formularios y tarjetas */
.editor-section {
  padding-bottom: 1.5rem;
}

.editor-card {
  padding: 1.5rem 1.65rem;
  border-radius: 16px;
}

.editor-card + .editor-card {
  margin-top: 1.35rem;
}

.editor-timeline-item,
.editor-trivia-item,
.editor-response-card,
.editor-toggle,
.editor-map-preview {
  border-radius: 14px;
  padding: 1.15rem 1.25rem;
}

.confirm-modal__dialog {
  padding: 2.25rem 2rem;
  border-radius: 18px;
}

/* Ajustes de componentes específicos en modo claro (Manual O OS) */
:root[data-editor-theme="light"] .editor-sidebar__close {
  background: var(--ed-surface-soft);
  color: var(--ed-text);
}

:root[data-editor-theme="light"] .editor-gallery__counter,
:root[data-editor-theme="light"] .editor-gallery__empty,
:root[data-editor-theme="light"] .editor-gallery__upload-row,
:root[data-editor-theme="light"] .editor-timeline-item,
:root[data-editor-theme="light"] .editor-trivia-item,
:root[data-editor-theme="light"] .editor-response-card,
:root[data-editor-theme="light"] .editor-responses__stat,
:root[data-editor-theme="light"] .editor-toggle,
:root[data-editor-theme="light"] .editor-map-preview,
:root[data-editor-theme="light"] .editor-sections__locked,
:root[data-editor-theme="light"] .editor-media-row,
:root[data-editor-theme="light"] .editor-media-item,
:root[data-editor-theme="light"] .editor-social-item,
:root[data-editor-theme="light"] .editor-image-preview,
:root[data-editor-theme="light"] .editor-bg-card {
  background: var(--ed-surface-soft);
  border-color: var(--ed-border);
  color: var(--ed-text);
}

:root[data-editor-theme="light"] .editor-gallery__counter strong,
:root[data-editor-theme="light"] .editor-gallery__dropzone-text,
:root[data-editor-theme="light"] .editor-response-card__head strong,
:root[data-editor-theme="light"] .editor-response-card__note strong,
:root[data-editor-theme="light"] .editor-responses__stat-num,
:root[data-editor-theme="light"] .editor-toggle__text,
:root[data-editor-theme="light"] .editor-map-preview__title,
:root[data-editor-theme="light"] .editor-social-item__body strong,
:root[data-editor-theme="light"] .editor-media-row__name {
  color: var(--ed-text);
}

:root[data-editor-theme="light"] .editor-gallery__empty p,
:root[data-editor-theme="light"] .editor-gallery__dropzone-hint,
:root[data-editor-theme="light"] .editor-timeline-item__hint,
:root[data-editor-theme="light"] .editor-response-card__meta,
:root[data-editor-theme="light"] .editor-response-card__note,
:root[data-editor-theme="light"] .editor-response-card__note--msg,
:root[data-editor-theme="light"] .editor-responses__stat-label,
:root[data-editor-theme="light"] .editor-map-preview__note,
:root[data-editor-theme="light"] .editor-field__hint,
:root[data-editor-theme="light"] .editor-sections__intro {
  color: var(--ed-text-soft);
}

:root[data-editor-theme="light"] .editor-responses__filter {
  background: var(--ed-surface);
  border-color: var(--ed-border);
  color: var(--ed-text-soft);
}

:root[data-editor-theme="light"] .editor-responses__filter:hover {
  background: var(--ed-surface-hover);
  color: var(--ed-text);
}

:root[data-editor-theme="light"] .editor-responses__filter.is-active {
  background: var(--ed-accent-soft);
  border-color: var(--ed-accent);
  color: var(--ed-accent-text);
}

:root[data-editor-theme="light"] .editor-responses__search,
:root[data-editor-theme="light"] .confirm-field input,
:root[data-editor-theme="light"] .confirm-field textarea,
:root[data-editor-theme="light"] .confirm-slug-row {
  background: #ffffff;
  border-color: var(--ed-border);
  color: var(--ed-text);
}

:root[data-editor-theme="light"] .confirm-modal__dialog,
:root[data-editor-theme="light"] .editor-dialog__dialog {
  background: #ffffff;
  border-color: var(--ed-border);
  box-shadow: var(--ed-shadow-lg);
}

:root[data-editor-theme="light"] .confirm-modal__header h2,
:root[data-editor-theme="light"] .confirm-success h2,
:root[data-editor-theme="light"] .editor-dialog__title {
  color: var(--ed-text);
}

:root[data-editor-theme="light"] .confirm-modal__subtitle,
:root[data-editor-theme="light"] .confirm-field label,
:root[data-editor-theme="light"] .confirm-fieldset legend,
:root[data-editor-theme="light"] .confirm-radio,
:root[data-editor-theme="light"] .confirm-success p,
:root[data-editor-theme="light"] .confirm-success__note,
:root[data-editor-theme="light"] .editor-dialog__message {
  color: var(--ed-text-soft);
}

:root[data-editor-theme="light"] .confirm-modal__close {
  background: var(--ed-surface-soft);
  color: var(--ed-text-soft);
}

:root[data-editor-theme="light"] .confirm-modal__close:hover {
  background: var(--ed-surface-hover);
  color: var(--ed-text);
}

:root[data-editor-theme="light"] .confirm-fieldset {
  background: var(--ed-surface-soft);
  border-color: var(--ed-border);
}

:root[data-editor-theme="light"] .confirm-slug-row .confirm-slug-prefix {
  background: var(--ed-accent-soft);
  color: var(--ed-accent-text);
  border-right-color: var(--ed-border);
}

:root[data-editor-theme="light"] .confirm-field input[type="date"]::-webkit-calendar-picker-indicator {
  filter: invert(0);
}

:root[data-editor-theme="light"] .editor-map-preview__empty {
  border-color: var(--ed-border-strong);
  color: var(--ed-text-soft);
}

:root[data-editor-theme="light"] .editor-response-card__wa {
  color: #15803d;
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(22, 163, 74, 0.3);
}

:root[data-editor-theme="light"] .editor-toast {
  background: #2c2a26;
  color: #faf8f3;
}

@media (prefers-color-scheme: light) {
  :root:not([data-editor-theme="dark"]) .editor-sidebar__close {
    background: var(--ed-surface-soft);
    color: var(--ed-text);
  }
  :root:not([data-editor-theme="dark"]) .editor-gallery__counter,
  :root:not([data-editor-theme="dark"]) .editor-gallery__empty,
  :root:not([data-editor-theme="dark"]) .editor-gallery__upload-row,
  :root:not([data-editor-theme="dark"]) .editor-timeline-item,
  :root:not([data-editor-theme="dark"]) .editor-trivia-item,
  :root:not([data-editor-theme="dark"]) .editor-response-card,
  :root:not([data-editor-theme="dark"]) .editor-responses__stat,
  :root:not([data-editor-theme="dark"]) .editor-toggle,
  :root:not([data-editor-theme="dark"]) .editor-map-preview,
  :root:not([data-editor-theme="dark"]) .editor-sections__locked,
  :root:not([data-editor-theme="dark"]) .editor-media-row,
  :root:not([data-editor-theme="dark"]) .editor-media-item,
  :root:not([data-editor-theme="dark"]) .editor-social-item,
  :root:not([data-editor-theme="dark"]) .editor-image-preview,
  :root:not([data-editor-theme="dark"]) .editor-bg-card {
    background: var(--ed-surface-soft);
    border-color: var(--ed-border);
    color: var(--ed-text);
  }
  :root:not([data-editor-theme="dark"]) .editor-gallery__counter strong,
  :root:not([data-editor-theme="dark"]) .editor-gallery__dropzone-text,
  :root:not([data-editor-theme="dark"]) .editor-response-card__head strong,
  :root:not([data-editor-theme="dark"]) .editor-response-card__note strong,
  :root:not([data-editor-theme="dark"]) .editor-responses__stat-num,
  :root:not([data-editor-theme="dark"]) .editor-toggle__text,
  :root:not([data-editor-theme="dark"]) .editor-map-preview__title,
  :root:not([data-editor-theme="dark"]) .editor-social-item__body strong,
  :root:not([data-editor-theme="dark"]) .editor-media-row__name {
    color: var(--ed-text);
  }
  :root:not([data-editor-theme="dark"]) .editor-gallery__empty p,
  :root:not([data-editor-theme="dark"]) .editor-gallery__dropzone-hint,
  :root:not([data-editor-theme="dark"]) .editor-timeline-item__hint,
  :root:not([data-editor-theme="dark"]) .editor-response-card__meta,
  :root:not([data-editor-theme="dark"]) .editor-response-card__note,
  :root:not([data-editor-theme="dark"]) .editor-response-card__note--msg,
  :root:not([data-editor-theme="dark"]) .editor-responses__stat-label,
  :root:not([data-editor-theme="dark"]) .editor-map-preview__note,
  :root:not([data-editor-theme="dark"]) .editor-field__hint,
  :root:not([data-editor-theme="dark"]) .editor-sections__intro {
    color: var(--ed-text-soft);
  }
  :root:not([data-editor-theme="dark"]) .editor-responses__filter {
    background: var(--ed-surface);
    border-color: var(--ed-border);
    color: var(--ed-text-soft);
  }
  :root:not([data-editor-theme="dark"]) .editor-responses__filter.is-active {
    background: var(--ed-accent-soft);
    border-color: var(--ed-accent);
    color: var(--ed-accent-text);
  }
  :root:not([data-editor-theme="dark"]) .editor-responses__search,
  :root:not([data-editor-theme="dark"]) .confirm-field input,
  :root:not([data-editor-theme="dark"]) .confirm-field textarea,
  :root:not([data-editor-theme="dark"]) .confirm-slug-row,
  :root:not([data-editor-theme="dark"]) .confirm-modal__dialog,
  :root:not([data-editor-theme="dark"]) .editor-dialog__dialog {
    background: #ffffff;
    border-color: var(--ed-border);
    color: var(--ed-text);
  }
  :root:not([data-editor-theme="dark"]) .confirm-modal__header h2,
  :root:not([data-editor-theme="dark"]) .confirm-success h2,
  :root:not([data-editor-theme="dark"]) .editor-dialog__title {
    color: var(--ed-text);
  }
  :root:not([data-editor-theme="dark"]) .confirm-modal__subtitle,
  :root:not([data-editor-theme="dark"]) .confirm-field label,
  :root:not([data-editor-theme="dark"]) .confirm-fieldset legend,
  :root:not([data-editor-theme="dark"]) .confirm-radio,
  :root:not([data-editor-theme="dark"]) .confirm-success p,
  :root:not([data-editor-theme="dark"]) .confirm-success__note,
  :root:not([data-editor-theme="dark"]) .editor-dialog__message {
    color: var(--ed-text-soft);
  }
  :root:not([data-editor-theme="dark"]) .confirm-modal__close {
    background: var(--ed-surface-soft);
    color: var(--ed-text-soft);
  }
  :root:not([data-editor-theme="dark"]) .confirm-fieldset {
    background: var(--ed-surface-soft);
    border-color: var(--ed-border);
  }
  :root:not([data-editor-theme="dark"]) .confirm-slug-row .confirm-slug-prefix {
    background: var(--ed-accent-soft);
    color: var(--ed-accent-text);
    border-right-color: var(--ed-border);
  }
  :root:not([data-editor-theme="dark"]) .editor-response-card__wa {
    color: #15803d;
    background: rgba(34, 197, 94, 0.12);
    border-color: rgba(22, 163, 74, 0.3);
  }
  :root:not([data-editor-theme="dark"]) .editor-toast {
    background: #2c2a26;
    color: #faf8f3;
  }
}


/* ============================================================
   RESPONSIVE MÓVIL COMPLETO (EDITOR)
   ============================================================ */
html,
body,
.editor-panel {
  overflow-x: hidden;
  max-width: 100%;
}

.editor-main,
.editor-content {
  min-width: 0;
}

@media (max-width: 768px) {
  .editor-sidebar {
    top: 0;
    z-index: 80;
    padding-top: 0.5rem;
  }

  .editor-header {
    height: auto;
    min-height: 56px;
    padding: 0.55rem 0.9rem;
    flex-wrap: wrap;
    row-gap: 0.5rem;
  }

  .editor-header__left {
    flex: 1 1 auto;
    min-width: 0;
  }

  .editor-header__right {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.4rem;
  }

  .editor-body {
    grid-template-columns: minmax(0, 1fr);
  }

  .editor-content {
    padding: 1.25rem 1rem 6rem;
  }

  .editor-toast {
    left: 1rem;
    right: 1rem;
    bottom: 5.25rem;
    transform: translateY(16px);
    max-width: none;
    justify-content: center;
  }

  .editor-toast.is-visible {
    transform: translateY(0);
  }
}

@media (max-width: 560px) {
  .editor-header {
    padding: 0.5rem 0.75rem;
  }

  .editor-header__right {
    width: 100%;
    justify-content: flex-end;
  }

  .editor-theme-toggle__label {
    display: none;
  }

  .editor-theme-toggle {
    padding: 0.45rem 0.55rem;
    min-width: 36px;
    justify-content: center;
  }

  .editor-btn {
    min-height: 36px;
    padding: 0.45rem 0.68rem;
  }

  .editor-card {
    padding: 1.15rem 1rem;
    border-radius: 14px;
  }

  .editor-choice-grid {
    grid-template-columns: 1fr;
  }

  .editor-responses__stats {
    grid-template-columns: 1fr;
  }

  .editor-gallery__grid,
  .editor-gallery__slots {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .editor-media-grid,
  .editor-media-grid--bg {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .editor-field input,
  .editor-field textarea,
  .editor-field select {
    font-size: 16px;
  }
}


/* ============================================================
   RENDIMIENTO DE PICKERS (VIDEO Y FONDOS LIVIANOS)
   ============================================================ */
.editor-media-item,
.editor-bg-card {
  content-visibility: auto;
  contain-intrinsic-size: 160px 260px;
}

.editor-media-item__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at top, rgba(201, 165, 107, 0.2), transparent 65%),
    linear-gradient(160deg, #1b1815 0%, #0f0d0c 100%);
  color: rgba(247, 243, 235, 0.34);
}

.editor-media-item__placeholder .material-symbols-outlined {
  font-size: 2.6rem;
}

.editor-media-item__label {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.editor-media-loadmore {
  grid-column: 1 / -1;
  display: flex;
  justify-content: center;
  padding: 0.5rem 0 0.25rem;
}

/* ============================================================
   GIF PICKER · Selector interactivo de GIFs por evento
   ============================================================ */
.editor-gif-picker {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  width: 100%;
}

.editor-gif-container {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.editor-gif-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 0.65rem;
  width: 100%;
}

.editor-gif-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.4rem;
  padding: 0.75rem 0.6rem;
  border-radius: 12px;
  border: 1px solid var(--ed-border);
  background: var(--ed-surface);
  color: var(--ed-text);
  cursor: pointer;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.editor-gif-card:hover {
  border-color: var(--ed-accent-border);
  background: var(--ed-surface-hover);
  transform: translateY(-2px);
}

.editor-gif-card.is-selected {
  border-color: var(--ed-accent);
  background: var(--ed-accent-soft);
  box-shadow: 0 0 0 3px rgba(176, 141, 87, 0.22);
}

.editor-gif-card__thumb {
  position: relative;
  width: 100%;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.04);
  border-radius: 8px;
  overflow: hidden;
}

@media (prefers-color-scheme: dark) {
  .editor-gif-card__thumb {
    background: rgba(255, 255, 255, 0.05);
  }
}
body[data-theme="dark"] .editor-gif-card__thumb {
  background: rgba(255, 255, 255, 0.05);
}
body[data-theme="light"] .editor-gif-card__thumb {
  background: rgba(0, 0, 0, 0.04);
}

.editor-gif-card__thumb img {
  max-width: 48px;
  max-height: 48px;
  object-fit: contain;
  display: block;
}

.editor-gif-card__check {
  position: absolute;
  top: 4px;
  right: 4px;
  font-size: 1.15rem;
  color: var(--ed-text-muted);
}

.editor-gif-card.is-selected .editor-gif-card__check {
  color: var(--ed-accent-text);
  font-variation-settings: "FILL" 1, "wght" 600, "GRAD" 0, "opsz" 20;
}

.editor-gif-card__label {
  font-size: 0.74rem;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ed-text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.editor-gif-card__badge {
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.15rem 0.4rem;
  border-radius: 6px;
  background: var(--ed-accent-soft);
  color: var(--ed-accent-text);
  border: 1px solid var(--ed-accent-border);
}

.editor-gif-actions {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0.25rem 0;
}

.editor-gif-toggle-all {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ed-accent-text);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

@media (max-width: 640px) {
  .editor-gif-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
  }
  .editor-gif-card {
    padding: 0.6rem 0.5rem;
  }
  .editor-gif-card__thumb {
    height: 52px;
  }
  .editor-gif-card__thumb img {
    max-width: 40px;
    max-height: 40px;
  }
}

/* Opción "Sin ícono animado" */
.editor-gif-card--none .editor-gif-card__none {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ed-text-muted);
}
.editor-gif-card--none .editor-gif-card__none .material-symbols-outlined {
  font-size: 1.85rem;
}
.editor-gif-card--none.is-selected .editor-gif-card__none {
  color: var(--ed-accent-text);
}

/* Switch toggle moderno para activar/desactivar opciones */
.editor-switch-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  user-select: none;
  margin: 0.35rem 0 0.2rem;
}

.editor-switch-input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.editor-switch-slider {
  position: relative;
  width: 46px;
  height: 26px;
  background-color: var(--ed-border);
  border-radius: 9999px;
  transition: background-color 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.editor-switch-slider::before {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background-color: #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.editor-switch-input:checked + .editor-switch-slider {
  background-color: var(--ed-accent);
}

.editor-switch-input:checked + .editor-switch-slider::before {
  transform: translateX(20px);
}

.editor-switch-input:focus-visible + .editor-switch-slider {
  outline: 2px solid var(--ed-accent);
  outline-offset: 2px;
}

.editor-switch-text {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ed-text);
}

/* Miniatura de video automática en el grid */
.editor-media-item__thumb-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  border-radius: 8px;
  background: #000000;
  display: block;
}

/* Controles de contraste y velo en Imagen de Fondo */
.editor-bg-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  padding: 1rem 1.15rem;
  margin-bottom: 1.25rem;
  border-radius: 14px;
  border: 1px solid var(--ed-border);
  background: var(--ed-surface);
}

@media (max-width: 700px) {
  .editor-bg-controls {
    grid-template-columns: 1fr;
    padding: 0.85rem 0.95rem;
  }
}
