#app .creator-templates {
  max-width: 100%;
  margin-bottom: 12px;
  padding: 0 14px;
  background: var(--workspace-surface);
  border: 1px solid var(--workspace-line);
  border-radius: 12px;
}

#app .creator-templates summary {
  min-height: 44px;
  padding-block: 10px;
  color: var(--text-2);
  font-weight: 650;
  cursor: pointer;
}

#app .creator-templates .tpl-strip { padding-bottom: 12px; }

#app #createForm {
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "content" "settings" "review";
}

#app #createForm > .creator-content { grid-area: content; }

#app #createForm > .creator-settings {
  grid-area: settings;
  position: static;
}

#app #createForm > .creator-review {
  grid-area: review;
  position: relative;
  padding: clamp(16px, 2vw, 26px);
  gap: 12px;
  background: color-mix(in srgb, var(--workspace-surface) 91%, var(--violet));
}

#app .creator-review .create-summary {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}
#app .creator-review .create-summary:has(#createNarrationSummaryRow[hidden]) .creator-summary-style { grid-column: 1 / -1; }

#app .creator-review .create-summary .creator-price {
  grid-column: 1 / -1;
  border-color: color-mix(in srgb, var(--workspace-accent) 56%, transparent);
  background: var(--workspace-highlight);
}

#app .creator-review .creator-price dd { color: var(--workspace-accent); }
#app .creator-review .create-next { line-height: 1.5; }
#app .creator-review #genText:empty { display: none; }
#app #createForm > .card > h3.card-step { margin-block: 0 12px; }
#app .creator-content #modeSwitch { margin: 16px 0 0; }
#app .creator-content #formatOpts { margin-top: 16px; }
#creatorReviewHeading { scroll-margin-top: 12px; }
/* (1-dic-2026, revisión visual) «Generar informativo · 1 crédito» se salía del botón (281 px de texto en 257): el precio
   baja a una segunda línea en vez de recortarse contra el borde. */
#app .creator-review #generateBtn { flex-wrap: wrap; column-gap: 6px; row-gap: 2px; white-space: normal; padding-inline: 14px; font-size: .95rem; line-height: 1.25; }
#app .creator-review #generateBtn #costLabel { white-space: nowrap; }

@media (max-width: 900px) {
  #app .creator-review #generateBtn { display: block; }
  #creatorReviewHeading { scroll-margin-top: calc(60px + env(safe-area-inset-top)); }
  body[data-tab="create"]:not(.gen-away) #mgen { display: none; }
}

#app .creator-style-picker {
  padding-inline: 12px;
  border: 1px solid var(--workspace-line);
  border-radius: 12px;
  background: var(--workspace-input);
}

#app .creator-style-picker > summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto auto;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  cursor: pointer;
  list-style: none;
}

#app .creator-style-picker > summary::-webkit-details-marker { display: none; }
#app .creator-style-picker > summary .ic { color: var(--workspace-accent); }
#app .creator-style-picker > summary small { color: var(--text-2); text-align: end; }
#app .creator-style-picker > summary::after {
  width: 7px;
  height: 7px;
  margin: -4px 3px 0 0;
  transform: rotate(45deg);
  border: solid var(--workspace-accent);
  border-width: 0 1.5px 1.5px 0;
  content: "";
}
#app .creator-style-picker[open] > summary::after { margin-top: 3px; transform: rotate(225deg); }

/* Estilo visual con foto de ejemplo (30-nov-2026): la misma escena en cada estilo, en vertical y grande, para elegir
   viendo cómo saldrá el video. 3 por fila en el teléfono, 6 en la computadora. */
#app .creator-style-picker .style-thumb {
  width: 26px;
  height: 34px;
  border-radius: 6px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}
#app .creator-style-picker .style-hint { margin: 0 0 8px; color: var(--text-2); font-size: 0.8rem; }

#app #styleOpts {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 2px 0 12px;
}
@media (min-width: 700px) {
  #app #styleOpts { grid-template-columns: repeat(6, minmax(0, 1fr)); }
}

#app #styleOpts .style-opt { min-width: 0; padding: 5px 5px 7px; line-height: 1.25; }
#app #styleOpts .style-opt .sw { aspect-ratio: 3 / 4; }
#app #styleOpts .style-opt[aria-pressed="true"] {
  border-color: var(--workspace-accent);
  background: var(--workspace-highlight);
  box-shadow: inset 0 -2px var(--workspace-accent);
}

#app .creator-language { margin-block: 14px 0; }
#app .creator-language select { width: 100%; min-height: 44px; }

.creator-production {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 212px), 1fr));
  gap: 10px;
  margin: 0 0 12px;
}
#app [data-panel="create"]:has(#jobView:not([hidden])) .creator-production { display: none; }
.creator-production-action {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  min-height: 64px;
  padding: 10px 12px;
  border: 1px solid var(--line-2);
  border-radius: 13px;
  color: var(--text);
  background: var(--surface);
  text-align: start;
}
.creator-production-action:hover { border-color: var(--accent-2); background: var(--surface-2); }
.creator-production-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: var(--accent-2);
  background: color-mix(in srgb, var(--accent-2) 14%, transparent);
  border-radius: 9px;
}
.creator-production-action b, .creator-production-action small { display: block; }
.creator-production-action small { margin-top: 3px; color: var(--text-2); line-height: 1.4; }
.creator-production-action > .ic { color: var(--accent-2); }
.tutorial-practice { width: min(100%, 530px); margin-bottom: 15px; }

#app #draftsHome .dr-project-help { margin: 0 0 14px; }
#app #draftsHome .dr-project-help .link { min-height: 44px; }

.project-catalog {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(130px, .44fr) minmax(140px, .48fr);
  align-items: end;
  gap: 8px 12px;
  margin-block: 0 16px;
  padding: clamp(10px, 2vw, 17px);
  border: 1px solid var(--workspace-line);
  border-radius: var(--r);
  background: var(--workspace-surface);
}

.project-catalog-field { display: grid; gap: 5px; min-width: 0; color: var(--text-2); font-size: .84rem; }
.project-catalog-field :is(input, select) { width: 100%; min-width: 0; min-height: 44px; }
.project-catalog #draftCatalogCount { grid-column: 1 / -1; margin: 0; }

.project-list-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 14px;
  padding: clamp(12px, 2.5vw, 22px);
  border: 1px solid var(--workspace-line);
  border-radius: var(--r);
  background: var(--workspace-surface);
}
.project-list-note p { max-width: 54ch; margin: 0; color: var(--text-2); overflow-wrap: anywhere; }
.project-list-note button { min-height: 44px; }

#app .project-editor-nav {
  min-width: 0;
  margin-bottom: 14px;
  padding: clamp(10px, 2vw, 16px);
  border: 1px solid var(--workspace-line);
  border-radius: var(--r-lg);
  background: var(--workspace-surface);
}

.project-nav-heading { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 12px; margin-bottom: 8px; }
.project-nav-heading h3 { margin: 0; color: var(--text); font-size: .95rem; }

#app .project-editor-nav .dr-chapter-nav:not(:empty) {
  position: relative;
  display: grid;
  grid-template-columns: none;
  grid-auto-flow: column;
  grid-auto-columns: clamp(138px, 30vw, 210px);
  overflow-x: auto;
  margin: 0 0 10px;
  padding: 3px 3px 8px;
  scrollbar-width: thin;
}

#app .project-editor-nav .dr-chapter-link { min-height: 70px; background: var(--workspace-input); }
#app .project-editor-nav .dr-chapter-link[aria-current="true"] { background: var(--workspace-highlight); }
#app .project-editor-nav :is(.dr-chapter-link, [role="tab"]):focus-visible { outline: 2px solid var(--workspace-accent); outline-offset: 1px; }

#app .project-editor-nav .dr-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 0;
  padding: 5px;
  overflow: visible;
}
#app .project-editor-nav .dr-tabs button { gap: 4px 7px; padding: 6px 9px; text-align: start; }
#app .project-editor-nav .dr-tabs .ic { flex-shrink: 0; }

.production-dialog {
  width: min(630px, calc(100% - 24px));
  max-height: min(90dvh, 760px);
  padding: clamp(15px, 3.5vw, 25px);
  overflow: auto;
  overscroll-behavior: contain;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--line-3);
  border-radius: 17px;
  box-shadow: var(--shadow-lg);
}
.production-dialog::backdrop { background: #090713d9; }
.production-dialog-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.production-dialog-head h3 { margin: 0; font-size: clamp(1.12rem, 3.3vw, 1.4rem); }
.production-dialog-head h3:focus { outline: none; }
.production-progress { margin: 0 0 2px; }
.production-dialog p:empty { display: none; }
.production-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); gap: 9px; }
.production-fields label { display: grid; gap: 5px; min-width: 0; color: var(--text-2); font-size: .85rem; }
.production-fields select { width: 100%; min-width: 0; min-height: 44px; }
.production-chapter-info { margin-block: 12px; }
.production-chapter-info p { margin: 4px 0 0; }
.production-links, .production-dialog-actions { display: flex; flex-wrap: wrap; gap: 7px; }
.production-dialog-actions { justify-content: end; margin-top: 16px; padding-top: 13px; border-top: 1px solid var(--line); }
.production-dialog-actions .btn, .production-links .btn { min-height: 40px; white-space: normal; }
.production-lesson { display: grid; gap: 12px; }
.production-lesson p { margin: 0; line-height: 1.5; }
.production-lesson > p:first-child { color: var(--text-2); }
.production-lesson-image { margin: 0; height: clamp(94px, 25vw, 165px); overflow: hidden; border-radius: 11px; }
.production-lesson-image img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 34%; }
.production-practice-group { display: grid; gap: 5px; }
.production-practice-group > div { display: flex; flex-wrap: wrap; gap: 7px; }
.production-practice-group .btn { min-height: 40px; }
.production-practice-group .btn[aria-pressed="true"] { color: var(--text); border-color: var(--accent-2); background: color-mix(in srgb, var(--accent-2) 17%, var(--surface)); }
.production-practice-result { padding: 11px 12px; border-left: 3px solid var(--accent-2); border-radius: 0 8px 8px 0; background: var(--surface-2); }
.production-lesson > .link { justify-self: start; min-height: 40px; }

#creatorCastVoices, #creatorNarratedScript { min-height: 38px; }

/* (.project-estimate-link está en landing-premium.css: es de la portada y esta hoja ya no frena su primera pintura.) */

.project-estimate {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: clamp(12px, 2.5vw, 26px);
  align-items: center;
  margin-bottom: 18px;
  padding: clamp(14px, 2.5vw, 24px);
  border: 1px solid var(--line-2);
  border-radius: 18px;
  background: var(--surface);
  text-align: start;
  scroll-margin-top: 90px;
}

#landing .project-estimate { max-width: 860px; margin-inline: auto; }
.project-estimate h3 { margin: 0 0 12px; font-size: clamp(1.1rem, 2.2vw, 1.4rem); }
.project-estimate-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 128px), 1fr)); gap: 9px; }
.project-estimate-fields label { display: grid; grid-template-rows: auto minmax(44px, auto); gap: 5px; color: var(--text-2); font-size: .83rem; }
.project-estimate-fields select { min-width: 0; width: 100%; font-size: .85rem; }
.project-estimate-note { margin: 10px 0 0; line-height: 1.45; }
.project-estimate-result { display: grid; align-content: center; gap: 8px; padding: clamp(10px, 2vw, 19px); border: 1px solid var(--line-2); border-radius: 12px; background: color-mix(in srgb, var(--surface-2) 88%, var(--accent-2)); }
.project-estimate-result strong { display: block; font-size: clamp(1.4rem, 3vw, 2rem); line-height: 1.35; }
.project-estimate-result p { margin: 4px 0 0; color: var(--text-2); font-size: .86rem; }
.project-estimate-result p:empty { display: none; }
.project-estimate-result .btn { justify-self: start; }

@media (max-width: 740px) {
  .project-estimate { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 640px) {
  .creator-production { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .creator-production-action[data-open-creator-project] { grid-column: 1 / -1; }
  .creator-production-action:not([data-open-creator-project]) { grid-template-columns: auto minmax(0, 1fr); gap: 7px; min-height: 44px; padding: 6px; font-size: .82rem; }
  .creator-production-action:not([data-open-creator-project]) small,
  .creator-production-action:not([data-open-creator-project]) > .ic { display: none; }
  .creator-production-action:not([data-open-creator-project]) .creator-production-icon { width: 28px; height: 28px; }
  .project-catalog { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project-catalog-field:first-child { grid-column: 1 / -1; }
  #app .project-editor-nav .dr-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  #app .project-editor-nav .dr-tabs button { flex-wrap: wrap; }
}

@media (min-width: 1180px), (min-width: 720px) and (max-width: 900px) {
  #app #createForm {
    grid-template-columns: minmax(0, 1fr) minmax(276px, .46fr);
    grid-template-areas: "content review" "settings review";
  }
}

@media (min-width: 1180px) {
  #app #createForm > .creator-review:not(.no-stick) { position: sticky; top: 20px; }
}

@media (max-width: 900px) {
  #app #createForm > .creator-review { margin-bottom: 12px; }
}
