/* Creative tool styles: stage, settings, HTML preview. */
/* Drop-surface base (border, background, upload icon) lives in workspace-ui.css. */
.creative-stage {
  min-height: 600px;
}
.creative-settings {
  position: sticky;
  top: 16px;
}

/* Section: drop surface (layout differences only) — legacy creative-stage */
.creative-stage #creative-drop {
  min-height: 390px;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 12px;
}
.creative-stage #creative-drop strong {
  font-family: var(--display);
  font-size: 24px;
}
.creative-stage #creative-drop span:not(.upload-icon) {
  font-size: 14px;
  color: var(--muted);
}

/* Unificado con vectorizar: #creative-drop dentro de .files-panel sin .creative-stage usa el mismo estilo que #drop */
.files-panel:not(.creative-stage) #creative-drop {
  min-height: 310px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 1.5px dashed rgba(104, 107, 130, 0.35);
  border-radius: 16px;
  background: rgba(148, 151, 169, 0.04);
  transition: 0.2s;
  padding: 24px;
  text-align: center;
  gap: 0;
  cursor: pointer;
}
.files-panel:not(.creative-stage) #creative-drop:hover {
  border-color: #7132f5;
}
.files-panel:not(.creative-stage) #creative-drop.drag {
  background: rgba(133, 91, 251, 0.16);
  border-color: #7132f5;
}
.files-panel:not(.creative-stage) #creative-drop h3 {
  font-size: 28px;
  line-height: 1.29;
  letter-spacing: -0.5px;
  font-weight: 700;
  margin: 20px 0 0;
  font-family: var(--display);
}
.files-panel:not(.creative-stage) #creative-drop p {
  font-size: 16px;
  margin-bottom: 24px;
  color: var(--muted);
}
.files-panel:not(.creative-stage) #creative-drop small {
  font-size: 12px;
  color: var(--muted);
  display: block;
  margin-top: 20px;
  line-height: 1.5;
}
.ui-shell .files-panel:not(.creative-stage) #creative-drop {
  min-height: 290px;
  background: rgba(148, 151, 169, 0.04);
  border: 1.5px dashed rgba(104, 107, 130, 0.3);
}
.ui-shell .files-panel:not(.creative-stage) #creative-drop h3 {
  font-size: 24px;
  letter-spacing: -0.5px;
  margin-top: 16px;
}
.ui-shell .files-panel:not(.creative-stage) #creative-drop p {
  font-size: 14px;
}

/* Botón Seleccionar imagen violeta con letra blanca — mismo que #choose en vectorizar */
#creative-choose,
#creative-chose,
.files-panel:not(.creative-stage) #creative-choose,
.files-panel:not(.creative-stage) #creative-chose {
  background: #7132f5;
  color: #fff;
  border-color: #5741d8;
}
#creative-choose:hover,
#creative-chose:hover,
.files-panel:not(.creative-stage) #creative-choose:hover,
.files-panel:not(.creative-stage) #creative-chose:hover {
  background: #5b1ecf;
  color: #fff;
  border-color: #5741d8;
}
.ui-shell #creative-choose,
.ui-shell #creative-chose {
  background: #7132f5;
  color: #fff;
  border-color: #5741d8;
}
.ui-shell #creative-choose:hover,
.ui-shell #creative-chose:hover {
  background: #5b1ecf;
  color: #fff;
}

/* Section: canvas output — soporta tanto .creative-stage como .files-panel unificado */
.creative-stage canvas,
.files-panel:not(.creative-stage) canvas {
  display: block;
  max-width: 100%;
  max-height: 480px;
  width: auto;
  height: auto;
  margin: auto;
  border-radius: 12px;
  background: repeating-conic-gradient(#dedee5 0% 25%, #fff 0% 50%) 0/16px 16px;
  touch-action: none;
}
.creative-stage #creative-download,
.files-panel:not(.creative-stage) #creative-download {
  justify-content: center;
}

/* Section: settings form */
.creative-settings input[type="text"],
.creative-settings textarea {
  display: block;
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
  font-size: 16px;
  margin-top: 10px;
}
.creative-settings textarea {
  resize: vertical;
  font-family: monospace;
  font-size: 13px;
}
.creative-settings .field {
  margin: 16px 0;
}
.creative-settings h2 {
  font-size: 20px;
  color: var(--text);
  font-weight: 600;
}
.two-buttons {
  display: flex;
  gap: 10px;
  margin: 16px 0;
}
.two-buttons button {
  flex: 1;
  padding: 12px 8px;
}

/* Section: HTML preview */
.creative-stage #html-preview,
.files-panel:not(.creative-stage) #html-preview {
  min-height: 420px;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: repeating-conic-gradient(#dedee5 0% 25%, white 0% 50%) 0/16px 16px;
  display: grid;
  place-items: center;
  overflow: auto;
}
.creative-stage #html-card,
.files-panel:not(.creative-stage) #html-card {
  background: white;
  max-width: 100%;
  overflow: hidden;
}
.creative-stage #html-card h2,
.files-panel:not(.creative-stage) #html-card h2 {
  color: inherit;
  font-size: 24px;
}
.creative-stage #html-card p,
.files-panel:not(.creative-stage) #html-card p {
  font-size: 16px;
}
.creative-stage #creative-status,
.files-panel:not(.creative-stage) #creative-status {
  font-size: 14px;
}
@media (max-width: 768px) {
  .creative-settings {
    position: static;
  }
  .creative-stage {
    min-height: 0;
  }
  .creative-stage #creative-drop {
    min-height: 300px;
  }
  .files-panel:not(.creative-stage) #creative-drop {
    min-height: 270px;
  }
}
@media (max-width: 425px) {
  .two-buttons {
    flex-direction: column;
  }
}
