/* Image & video create v2 layout (UI_CREATE_V2) */

html.create-v2-page {
  --cv2-page: #000000;
  background: var(--cv2-page);
}

/* P0 V.UI.1 — create video vs design_layouts/create_video.png */
/* Neon Glow L0 ambient · L1 hover/focus · L2 selected · L3 CTA */
.sheet-create-v2 {
  --cv2-accent-border: rgba(168, 85, 247, 0.55);
  --cv2-accent-soft: rgba(168, 85, 247, 0.12);
  --cv2-utility: var(--neon-blue, #00d4ff);
  --cv2-glow-ambient: 0 0 6px rgba(168, 85, 247, 0.05);
  /* hover/focus glow: inherit --ui-* via interaction-tokens aliases */
  --cv2-glow-selected: var(--ui-selected-glow, 0 0 0 1px rgba(168, 85, 247, 0.14), 0 0 12px rgba(168, 85, 247, 0.18));
  --cv2-glow-nav-selected: 0 0 0 1px rgba(168, 85, 247, 0.1), 0 0 8px rgba(168, 85, 247, 0.12);
  --cv2-glow-cta: 0 0 18px rgba(0, 212, 255, 0.22), 0 0 28px rgba(168, 85, 247, 0.28);
  --cv2-glow-cta-hover: 0 0 22px rgba(0, 212, 255, 0.3), 0 0 36px rgba(168, 85, 247, 0.36);
  --cv2-glow-cta-secondary: 0 0 12px rgba(0, 212, 255, 0.14), 0 0 18px rgba(168, 85, 247, 0.18);
  --cv2-glow-cta-secondary-hover: 0 0 16px rgba(0, 212, 255, 0.2), 0 0 24px rgba(168, 85, 247, 0.24);
  --cv2-glow-topup: 0 0 10px rgba(168, 85, 247, 0.14);
  --cv2-glow-topup-hover: 0 0 14px rgba(168, 85, 247, 0.2);
  --cv2-glow-error: 0 0 0 1px rgba(255, 77, 94, 0.2), 0 0 10px rgba(255, 77, 94, 0.12);
  --cv2-accent-glow: var(--cv2-glow-selected);
  --cv2-space-8: 8px;
  --cv2-space-12: 12px;
  --cv2-space-16: 16px;
  --cv2-space-24: 24px;
  --cv2-space-32: 32px;
  /* Visual consistency tokens (Create V2 shared primitives) */
  --cv2-control-h: 36px;
  --cv2-field-h: 44px;
  --cv2-radius-sm: 10px;
  --cv2-radius-md: 12px;
  --cv2-label-size: 13px;
  --cv2-section-size: 14px;
  --cv2-helper-size: 12px;
  --cv2-meta-size: 11px;
  --cv2-help-size: 18px;
  --cv2-qty-max-w: 220px;
  --cv2-field-gap: 14px;
  --cv2-section-gap-y: 20px;
  --cv2-pill-active-bg: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
  --cv2-pill-active-text: var(--text, #fff);
  --create-mobile-bar-h: 118px;
}

@media (min-width: 768px) {
  .sheet-create-v2 .create-v2-ctabs .ctab,
  .sheet-create-v2 .create-v2-ctabs .ctab.is-on,
  .sheet-create-v2 .create-v2-ctabs .ctab:hover {
    border: 0;
    background: transparent;
    box-shadow: none;
    padding: 0;
    width: 72px;
  }

  .sheet-create-v2 .create-v2-ctabs .ctab.is-on i {
    border-color: var(--cv2-accent-border);
    background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
    box-shadow: 0 0 12px rgba(168, 85, 247, 0.18);
  }
}

.sheet-create-v2 .prompt-v2-shell {
  position: relative;
  box-sizing: border-box;
  overflow: hidden;
  isolation: isolate;
  border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.1));
  border-radius: 12px;
  background: var(--cv2-input, #0f0f0f);
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

.sheet-create-v2 .prompt-v2-shell:hover {
  border-color: var(--cv2-hover-border, rgba(255, 255, 255, 0.16));
  box-shadow: var(--cv2-glow-hover);
}

.sheet-create-v2 .prompt-v2-shell:focus-within {
  border-width: 1px;
  border-color: var(--cv2-accent-border);
  box-shadow: var(--cv2-glow-focus);
}

.sheet-create-v2 .prompt-v2-shell.is-error {
  border-color: rgba(255, 77, 94, 0.65);
  box-shadow: var(--cv2-glow-error);
}

.sheet-create-v2 .fg-prompt-v2,
.sheet-create-v2 .fg-prompt-video,
.sheet-create-v2 .prompt-v2-field {
  display: block;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}

.sheet-create-v2 .prompt-v2-shell .prompt-v2-field.field-with-clear {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px;
  align-items: start;
  column-gap: 8px;
}

.sheet-create-v2 .prompt-v2-shell .prompt-v2-field textarea,
.sheet-create-v2 .prompt-v2-shell .prompt-v2-field textarea:focus,
html[data-ui-theme="magicbox"] .sheet-create-v2 .prompt-v2-shell textarea:focus {
  border: 0 !important;
  outline: 0;
  box-shadow: none !important;
  padding: 12px 12px 28px;
  padding-right: 12px;
  resize: none;
  overflow-x: hidden;
  overflow-y: hidden;
  background: transparent;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
  grid-column: 1;
}

.sheet-create-v2 .prompt-v2-shell .prompt-v2-field .field-clear-btn {
  position: static;
  grid-column: 2;
  justify-self: center;
  align-self: start;
  margin: 8px 4px 0 0;
  z-index: 1;
}

/* Counter: bottom-right of the shell, in reserved bottom padding — not over editable lines. */
.sheet-create-v2 .prompt-v2-shell .field-char {
  position: absolute;
  right: 8px;
  bottom: 8px;
  display: block !important;
  margin: 0;
  padding: 0 2px;
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
  text-align: right;
  color: var(--muted, rgba(160, 160, 170, 0.85));
  pointer-events: none;
  z-index: 1;
}

.sheet-create-v2 .fg-prompt-video .prompt-v2-actions,
.sheet-create-v2 .fg-prompt-v2 .prompt-v2-actions {
  margin-top: 10px;
  margin-bottom: 8px;
}

.sheet-create-v2 .fg-prompt-video .prompt-chips,
.sheet-create-v2 .fg-prompt-v2 .prompt-chips {
  margin-top: 4px;
}

.sheet-create-v2 .fg-aspect-video .aspect-pill,
.sheet-create-v2 .fg-aspect-compact .aspect-pill {
  min-width: 0;
  min-height: 36px;
  padding: 7px 12px !important;
  flex-direction: row;
  border-radius: 10px;
  gap: 6px;
}

.sheet-create-v2 .fg-aspect-compact .aspect-pill-auto {
  min-height: 36px;
}

.sheet-create-v2 .fg-aspect-compact .aspect-pill-hint {
  display: none;
}

.sheet-create-v2 .fg-aspect-video .aspect-pill-more,
.sheet-create-v2 .fg-aspect-compact .aspect-pill-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.sheet-create-v2 .aspect-pill-more-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 12px;
  height: 12px;
  line-height: 1;
  font-size: 11px;
  flex: 0 0 12px;
  transition: transform 160ms ease;
}

.sheet-create-v2 .aspect-pill-more[aria-expanded="true"] .aspect-pill-more-chevron {
  transform: rotate(180deg);
}

.sheet-create-v2 .video-setting-row-chevron {
  width: auto;
  height: auto;
  border: 0;
  border-radius: 0;
}

.sheet-create-v2 .video-setting-row:hover .video-setting-row-chevron {
  border-color: transparent;
}

.sheet-create-v2 .fg-qty .qty-v2 {
  gap: 0;
  padding: 0;
  flex-wrap: nowrap;
  box-sizing: border-box;
}

.sheet-create-v2 .fg-qty .qty-v2 span[data-qty-val] {
  white-space: nowrap;
  flex-shrink: 0;
}

.sheet-create-v2 .create-sidebar-stars {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0;
}

.sheet-create-v2 .create-sidebar-cost-label {
  font-size: 12px;
  margin-bottom: 6px;
}

.sheet-create-v2 .create-sidebar-rub {
  font-size: 14px;
  margin-top: 4px;
}

.sheet-create-v2 .create-sidebar-gen {
  min-height: 48px;
  border-radius: 14px;
  margin-top: 18px;
}

.sheet-create-v2 .create-sidebar-delivery {
  display: block;
  margin: 14px 0 0;
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
}

@media (min-width: 960px) {
  .sheet-create-v2 .create-layout,
  .sheet-create-v2 .create-layout {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 320px);
    gap: 28px;
    align-items: start;
    width: 100%;
    max-width: 100%;
  }

  .sheet-create-v2 .create-sidebar-col,
  .sheet-create-v2 .create-sidebar-col {
    width: 100%;
    min-width: 0;
    max-width: 320px;
    margin-top: 0;
  }

  .sheet-create-v2 .create-main,
  .sheet-create-v2 .create-form-v2-video,
  .sheet-create-v2 .create-fields {
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }

  .sheet-create-v2 .create-sidebar-inner,
  .sheet-create-v2 .create-sidebar-inner {
    border-radius: var(--cv2-radius-lg, 16px);
    border: 1px solid rgba(168, 85, 247, 0.16);
    border-bottom: 1px solid rgba(168, 85, 247, 0.16);
    padding: 20px;
    box-shadow: 0 0 16px rgba(168, 85, 247, 0.035);
  }

  .sheet-create-v2 .create-sidebar-preview-video:not(.has-result),
  .sheet-create-v2 .create-sidebar-preview:not(.has-result) {
    display: none;
  }

  .sheet-create-v2 .create-sidebar-preview-video.has-result,
  .sheet-create-v2 .create-sidebar-preview.has-result {
    margin-top: 12px;
    padding: 12px;
    border-radius: var(--cv2-radius-lg, 16px);
    border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.1));
  }

  .sheet-create-v2 .create-telegram-link,
  .sheet-create-v2 .create-telegram-link {
    display: none;
  }
}

@media (min-width: 768px) and (max-width: 1099px) {
  .sheet-create-v2 .fg-settings-basic-video .settings-basic-grid-video {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(180px, 1fr);
    column-gap: 20px;
    row-gap: 16px;
    align-items: start;
  }

  .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="aspect_video_compact"] {
    grid-column: 1;
    grid-row: 1;
  }

  .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="duration"] {
    grid-column: 2;
    grid-row: 1;
  }

  .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="qty"] {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="resolution"] {
    grid-column: 1 / -1;
    grid-row: 3;
  }
}

@media (min-width: 1100px) {
  .sheet-create-v2 .fg-settings-basic-video .settings-basic-grid-video {
    display: grid;
    grid-template-columns:
      minmax(0, 1.6fr)
      minmax(200px, 0.8fr)
      minmax(200px, 0.8fr);
    column-gap: 24px;
    row-gap: 16px;
    align-items: start;
  }

  .sheet-create-v2 .fg-settings-basic-video .settings-basic-grid-video .fg-aspect-compact,
  .sheet-create-v2 .fg-settings-basic-video .settings-basic-grid-video .fg-qty {
    grid-column: auto;
  }

  .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="aspect_video_compact"] {
    grid-column: 1;
    grid-row: 1;
  }

  .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="duration"] {
    grid-column: 2;
    grid-row: 1;
  }

  .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="qty"] {
    grid-column: 3;
    grid-row: 1;
  }

  .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="resolution"] {
    grid-column: 1;
    grid-row: 2;
  }

  .sheet-create-v2 .settings-basic-grid-video .fg-qty .qty-v2 {
    width: fit-content;
    min-width: 168px;
    max-width: 280px;
    flex-wrap: nowrap;
  }

  .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="duration"] .fg {
    width: min(100%, 320px);
  }

  .sheet-create-v2 .settings-basic-grid-video .fg-qty .qty-v2,
  .sheet-create-v2 .settings-basic-grid-video .fg-qty .qty-v2 button {
    min-height: 36px;
    height: 36px;
  }

  .sheet-create-v2 .settings-basic-grid-video .fg-qty .qty-v2 button {
    flex: 0 0 42px;
  }

  .sheet-create-v2 .settings-basic-grid-video .fg-qty .qty-v2 span[data-qty-val] {
    flex: 1 0 82px;
    min-width: 82px;
    white-space: nowrap;
    text-align: center;
    line-height: 1;
  }
}

@media (min-width: 768px) {
  .sheet-create-v2 .prompt-v2-shell .prompt-v2-field textarea,
  .sheet-create-v2 .prompt-v2-shell .prompt-v2-field textarea:focus {
    min-height: 92px;
    max-height: 240px;
    height: auto;
    resize: none;
  }

  .sheet-create-v2 .fg-settings-basic-video {
    margin-top: 8px;
  }

  .sheet-create-v2 .create-section-divider {
    margin: 20px 0 16px;
  }
}

@media (max-width: 767px) {
  html.create-v2-page .dock {
    display: none;
  }

  html.create-v2-page body {
    padding-bottom: calc(var(--create-mobile-bar-h, 118px) + env(safe-area-inset-bottom));
  }

  .sheet-create-v2 .create-sidebar-preview:not(.has-result) {
    display: none;
  }

  .sheet-create-v2 .create-v2-ctabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    width: 100%;
    padding: 4px 0 18px;
    overflow: visible;
  }

  .sheet-create-v2 .create-v2-ctabs .ctab {
    width: auto;
    min-width: 0;
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 8px;
    border: 1px solid var(--cv2-border, var(--border));
    border-radius: var(--cv2-radius-md, 12px);
    background: var(--cv2-input, var(--surface-4));
    font-size: 12px;
  }

  .sheet-create-v2 .create-v2-ctabs .ctab i,
  .sheet-create-v2 .create-v2-ctabs .ctab.is-on i {
    display: inline-grid;
    width: auto;
    height: auto;
    margin: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    font-size: 17px;
    box-shadow: none;
  }

  .sheet-create-v2 .create-v2-ctabs .ctab.is-on {
    border-color: var(--cv2-accent-border);
    background: var(--cv2-accent-soft);
    box-shadow: var(--cv2-accent-glow);
  }

  .sheet-create-v2 .fg-upload-start-frame .upload-dropzone-start-frame,
  .sheet-create-v2 .fg-upload-start-frame .upload-dropzone-btn,
  .sheet-create-v2 .fg-upload-v2 .upload-dropzone-ref,
  .sheet-create-v2 .fg-upload-v2 .upload-dropzone-btn {
    min-height: 88px;
  }

  .sheet-create-v2 .prompt-v2-shell .prompt-v2-field textarea,
  .sheet-create-v2 .prompt-v2-shell .prompt-v2-field textarea:focus {
    min-height: 76px;
    max-height: 200px;
    height: auto;
    resize: none;
  }

  .sheet-create-v2 .prompt-v2-footer {
    align-items: flex-end;
    padding: 7px 8px 8px;
  }

  .sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo) {
    padding: 6px 9px;
    font-size: 11px;
  }

  .sheet-create-v2 .video-settings-rows {
    border-top: 1px solid var(--cv2-border, var(--border));
    border-bottom: 1px solid var(--cv2-border, var(--border));
  }

  .sheet-create-v2 .video-setting-row:first-child {
    border-top: 0;
  }

  .sheet-create-v2 .video-setting-row:last-child {
    border-bottom: 0;
  }

  .sheet-create-v2 .create-mobile-bar {
    display: block;
    min-height: 108px;
    padding: 12px 16px 10px;
    border: 1px solid var(--cv2-border, var(--border));
    border-bottom: 0;
    border-radius: 18px 18px 0 0;
    background: var(--cv2-chrome-fill, rgba(24, 24, 26, 0.98));
    bottom: 0;
  }

  .sheet-create-v2 .create-mobile-summary-btn {
    flex: 0 1 42%;
  }

  .sheet-create-v2 .create-mobile-summary-compact,
  .sheet-create-v2 .create-mobile-summary-chevron {
    display: none;
  }

  .sheet-create-v2 .create-mobile-summary-meta {
    display: grid;
    gap: 2px;
  }

  .sheet-create-v2 .create-mobile-cost-label {
    display: block;
    font-size: 10px;
    font-weight: 500;
  }

  .sheet-create-v2 .create-mobile-gen {
    min-width: 0;
    min-height: 58px;
    border-radius: 12px;
  }

  .sheet-create-v2 .create-mobile-delivery,
  .sheet-create-v2 .create-mobile-delivery {
    display: block;
    margin: 8px 0 0;
    font-size: 10px;
    line-height: 1.4;
  }

}

html.create-v2-page body {
  background: var(--cv2-page, #000000);
}

html.create-v2-page .wrap {
  width: 100%;
  max-width: none;
  padding: 12px 12px 0;
  box-sizing: border-box;
}

@media (min-width: 768px) {
  html.create-v2-page .wrap {
    padding: 16px 24px 0;
  }
}

@media (min-width: 1280px) {
  html.create-v2-page .wrap {
    padding: 20px 32px 0;
  }
}

/* Flat header nav on create screens: inherit shared MagicBox .menu a pill styles (theme-magicbox.css). */

.sheet-create-v2 {
  --cv2-page: #000000;
  --cv2-container: #121212;
  --cv2-card: #1a1a1a;
  --cv2-input: #0f0f0f;
  --cv2-border: rgba(255, 255, 255, 0.08);
  --cv2-hover-border: rgba(255, 255, 255, 0.16);
  --cv2-dropzone-bg: rgba(255, 255, 255, 0.02);
  --cv2-soft-fill: rgba(255, 255, 255, 0.04);
  --cv2-soft-fill-hover: rgba(255, 255, 255, 0.08);
  --cv2-chrome-fill: rgba(20, 20, 24, 0.92);
  --cv2-accent: #a855f7;
  --cv2-accent-soft: rgba(168, 85, 247, 0.14);
  --cv2-accent-border: rgba(168, 85, 247, 0.55);
  --cv2-accent-glow: 0 0 0 1px rgba(168, 85, 247, 0.25), 0 0 20px rgba(168, 85, 247, 0.12);
  /* Keep violet selected tokens from the primary .sheet-create-v2 block (do not reset to white). */
  --cv2-gradient-cta: linear-gradient(90deg, #00d4ff, #a855f7, #ff00ff);
  --cv2-radius-xl: 24px;
  --cv2-radius-lg: 20px;
  --cv2-radius-md: 12px;
  --cv2-radius-sm: 10px;
  --cv2-radius-xs: 8px;
  --create-mobile-bar-h: 88px;
  max-width: 1440px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

@media (min-width: 1280px) {
  .sheet-create-v2 {
    padding-left: 32px;
    padding-right: 32px;
  }
}

html.create-v2-page .sheet-create-v2 {
  background: var(--cv2-container);
  border: 1px solid var(--cv2-border);
  border-radius: var(--cv2-radius-xl);
  padding: 16px 16px 20px;
  box-sizing: border-box;
}

@media (min-width: 768px) {
  html.create-v2-page .sheet-create-v2 {
    padding: 20px 24px 24px;
  }
}

html.create-v2-page .sheet-create-v2 .create-main {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
}

.sheet-create-v2 .create-main {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
}

.sheet-h-create h1 {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

@media (min-width: 1024px) {
  .sheet-h-create h1 {
    font-size: 26px;
  }
}

.sheet-h-create {
  align-items: center;
  gap: 12px;
}

.sheet-h-create-v2 {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
}

.sheet-h-create-v2 h1 {
  margin: 0;
  text-align: center;
  min-width: 0;
}

.create-v2-back {
  display: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid var(--cv2-border, var(--border));
  background: var(--cv2-input, var(--surface-4));
  color: var(--text);
  text-decoration: none;
  font-size: 18px;
  line-height: 1;
  flex-shrink: 0;
}

.create-title-short {
  display: none;
}

.create-v2-my-works {
  font-size: 12px;
  padding: 6px 10px;
}

@media (max-width: 767px) {
  html.create-v2-page .top {
    display: none;
  }

  html.create-v2-page .beta-notice {
    display: none;
  }

  .sheet-h-create-v2 .create-v2-back {
    display: inline-flex;
  }

  .sheet-h-create-v2 .create-title-full {
    display: none;
  }

  .sheet-h-create-v2 .create-title-short {
    display: inline;
  }

  .sheet-h-create-v2 .sheet-h-close {
    display: none;
  }

  .sheet-h-create-v2 .create-v2-my-works {
    display: inline-flex;
  }

  .sheet-h-create-v2-video .create-title-full,
  .sheet-h-create-v2-audio .create-title-full {
    display: inline;
  }

  .sheet-h-create-v2-video .create-title-short,
  .sheet-h-create-v2-audio .create-title-short {
    display: none;
  }

  .sheet-h-create-v2-video .sheet-h-close,
  .sheet-h-create-v2-audio .sheet-h-close {
    display: inline-flex;
  }

  .sheet-h-create-v2-video .create-v2-my-works,
  .sheet-h-create-v2-audio .create-v2-my-works {
    display: none;
  }

  html.create-v2-page .sheet-create-v2 {
    padding-left: 12px;
    padding-right: 12px;
    border-left: none;
    border-right: none;
    border-radius: 0;
    margin-left: -12px;
    margin-right: -12px;
    width: calc(100% + 24px);
    max-width: none;
  }
}

@media (min-width: 768px) {
  .sheet-h-create-v2 .create-v2-back {
    display: none;
  }

  .sheet-h-create-v2 {
    display: flex;
    justify-content: space-between;
  }

  .sheet-h-create-v2 h1 {
    text-align: left;
  }
}

.sheet-h-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.create-v2-ctabs {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 4px 0 16px;
  margin: 0 0 14px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.create-v2-ctabs::-webkit-scrollbar {
  display: none;
}

.create-v2-ctabs .ctab {
  flex: 0 0 auto;
  text-align: center;
  width: 72px;
  font-size: 11px;
  color: var(--muted);
  text-decoration: none;
  line-height: 1.25;
}

.create-v2-ctabs .ctab-label-short {
  display: none;
}

@media (max-width: 767px) {
  .create-v2-ctabs .ctab-label-full {
    display: none;
  }

  .create-v2-ctabs .ctab-label-short {
    display: inline;
  }
}

.create-v2-ctabs .ctab i {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin: 0 auto 6px;
  border-radius: 14px;
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.10));
  border: 1px solid rgba(168, 85, 247, 0.20);
  color: var(--text);
  font-style: normal;
  font-size: 20px;
  box-sizing: border-box;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s, color 0.15s;
}

.create-v2-ctabs .ctab:hover {
  color: var(--text);
}

.create-v2-ctabs .ctab:hover i {
  border-color: rgba(168, 85, 247, 0.32);
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.14));
}

.create-v2-ctabs .ctab.is-on {
  color: var(--text);
  font-weight: 600;
}

.create-v2-ctabs .ctab.is-on i {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.18));
  box-shadow: var(--cv2-accent-glow, 0 0 0 3px rgba(168, 85, 247, 0.2));
  color: #fff;
}

/* Canonical Create V2 stroke media/model icons (Quick Tools language) */
.cv2-media-ico {
  display: block;
  flex: 0 0 auto;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
  color: inherit;
}

.create-v2-ctabs .ctab i .cv2-media-ico--ctab {
  width: 24px;
  height: 24px;
}

.model-row-v2 .model-row-icon .cv2-media-ico--model {
  width: 20px;
  height: 20px;
}

.model-opt-icon .cv2-media-ico--opt {
  display: inline-block;
  width: 18px;
  height: 18px;
  vertical-align: -3px;
}

.create-summary-model-icon:has(.cv2-media-ico) {
  filter: none;
}

.create-summary-model-icon .cv2-media-ico--summary {
  width: 16px;
  height: 16px;
}

@media (min-width: 960px) {
  .create-v2-ctabs {
    justify-content: flex-start;
    margin-bottom: 18px;
  }
}

.cv2-sheet-handle {
  width: 40px;
  height: 4px;
  border-radius: 999px;
  background: var(--cv2-hover-border, rgba(255, 255, 255, 0.22));
  margin: 0 auto 12px;
  flex-shrink: 0;
}

.cv2-sheet-handle-mobile {
  display: none;
}

@media (max-width: 767px) {
  .cv2-sheet-handle-mobile {
    display: block;
  }

  .create-mobile-summary-panel .cv2-sheet-handle {
    margin-top: -4px;
  }
}

.btn-ghost {
  border: 1px solid var(--border);
  background: var(--surface-4);
  color: var(--text);
  border-radius: 10px;
  padding: 6px 12px;
  font-size: 13px;
  text-decoration: none;
  white-space: nowrap;
}

.task-mode-toggle {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  max-width: 400px;
}

.sheet-create-v2 .task-mode-toggle-image {
  width: auto;
  max-width: none;
  margin-bottom: 16px;
}

.sheet-create-v2 .task-mode-toggle-image .task-mode-btn {
  flex: 0 1 auto;
  min-width: 148px;
  min-height: 0;
  padding: 8px 16px;
  border-radius: var(--cv2-radius-md, 12px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.sheet-create-v2 .task-mode-icon {
  font-size: 15px;
  line-height: 1;
  opacity: 0.9;
}

.sheet-create-v2 .task-mode-icon-create {
  color: var(--cv2-accent, #a855f7);
  opacity: 1;
}

.sheet-create-v2 .task-mode-btn.is-on .task-mode-icon-create {
  color: var(--cv2-accent, #a855f7);
}

.sheet-create-v2 .task-mode-btn {
  flex: 1;
  text-align: center;
  border: 1px solid var(--cv2-border, var(--border));
  background: var(--cv2-input, var(--surface-4));
  color: var(--muted);
  border-radius: var(--cv2-radius-md, 12px);
  padding: 10px 12px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.15s, background 0.15s, color 0.15s, box-shadow 0.15s;
}

.sheet-create-v2 .task-mode-btn:hover {
  border-color: rgba(255, 255, 255, 0.16);
  color: var(--text);
  box-shadow: var(--cv2-glow-hover);
}

.sheet-create-v2 .task-mode-btn.is-on {
  color: var(--text);
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
  box-shadow: var(--cv2-glow-selected);
}

.sheet-create-v2 .task-mode-toggle-image .task-mode-btn.is-on {
  color: var(--text);
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
  box-shadow: var(--cv2-glow-selected);
}

.sheet-create-v2 .task-mode-toggle-image .task-mode-btn.is-on .task-mode-icon-create {
  color: #e9d5ff;
}

.task-mode-btn {
  flex: 1;
  text-align: center;
  border: 1px solid var(--border);
  background: var(--surface-4);
  color: var(--muted);
  border-radius: 12px;
  padding: 10px 12px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
}

.task-mode-btn.is-on {
  color: var(--text);
  border-color: rgba(255, 211, 77, 0.55);
  background: var(--chip-on);
}

.create-layout {
  display: block;
}

@media (min-width: 1024px) {
  .create-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 24px;
    align-items: start;
  }
  .create-mobile-bar { display: none !important; }
  .draft-hint-v2 { display: none; }
}

@media (min-width: 960px) and (max-width: 1023px) {
  .create-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 20px;
    align-items: start;
  }
  .create-mobile-bar { display: none !important; }
  .draft-hint-v2 { display: none; }
}

.create-sidebar-col {
  display: block;
}

@media (min-width: 960px) {
  .create-sidebar-col {
    display: flex;
    flex-direction: column;
    gap: 0;
    position: sticky;
    top: 88px;
  }
}

.create-sidebar {
  display: none;
}

@media (min-width: 960px) {
  .create-sidebar {
    display: block;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    position: static;
    top: auto;
  }
}

.create-sidebar-inner {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: var(--cv2-radius-lg, 16px);
  background: var(--cv2-card, var(--surface-3));
  padding: 20px;
}

.create-sidebar-title {
  margin: 0 0 18px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--text, #fff);
}

.create-summary {
  margin: 0;
}

.create-summary-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 5px 0;
  font-size: 13px;
}

.create-summary-row dt {
  color: var(--muted);
  font-weight: 500;
  margin: 0;
}

.create-summary-row dd {
  margin: 0;
  text-align: right;
  font-weight: 600;
  color: var(--text, #fff);
}

.create-summary-model-value {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  text-align: right;
  font-weight: 700;
}

.create-summary-model-icon {
  flex: 0 0 auto;
  font-size: 14px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.14));
  border: 1px solid rgba(168, 85, 247, 0.22);
  box-sizing: border-box;
  color: var(--text);
  filter: none;
}

.create-summary-row dd[data-summary-model],
.create-summary-model-value [data-summary-model] {
  font-weight: 700;
}

/* Desktop Parameters shell (video etalon → image/audio): stacked label/value */
@media (min-width: 960px) {
  html.create-v2-page .create-sidebar .create-summary {
    display: grid;
    row-gap: 14px;
    margin: 0;
  }

  html.create-v2-page .create-sidebar .create-summary-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    row-gap: 4px;
    padding: 0;
    align-items: start;
    font-size: 13px;
  }

  html.create-v2-page .create-sidebar .create-summary-row[hidden] {
    display: none !important;
  }

  html.create-v2-page .create-sidebar .create-summary-row dt {
    font-size: 12px;
    font-weight: 500;
    line-height: 1.35;
    color: var(--muted);
  }

  html.create-v2-page .create-sidebar .create-summary-row dd {
    text-align: left;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.35;
    color: var(--text, #fff);
  }

  html.create-v2-page .create-sidebar .create-summary-row dd.muted {
    color: var(--text, #fff);
    opacity: 0.92;
  }

  html.create-v2-page .create-sidebar .create-summary-model-value {
    justify-content: flex-start;
    text-align: left;
  }

  html.create-v2-page .create-sidebar-inner {
    padding: 20px;
    border-color: rgba(168, 85, 247, 0.16);
    box-shadow: 0 0 16px rgba(168, 85, 247, 0.035);
  }
}

.create-sidebar-divider {
  height: 1px;
  margin: 18px 0 16px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
}

.create-sidebar-cost {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}

.create-sidebar-cost-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 6px;
}

/* Mockup: cost opens with ⭐ N, without a separate “Стоимость” caption */
@media (min-width: 960px) {
  html.create-v2-page .create-sidebar .create-sidebar-cost-label {
    display: none;
  }
}

.create-sidebar-stars {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.2;
  color: var(--text, #fff);
}

.create-sidebar-rub {
  font-size: 14px;
  font-weight: 600;
  margin-top: 4px;
  line-height: 1.3;
}

.create-sidebar-cost-hint {
  margin: 8px 0 0;
  font-size: 11px;
  line-height: 1.35;
}

html.create-v2-page .create-sidebar-cost-hint,
html.create-v2-page .draft-hint-v2 {
  display: none !important;
}

.sheet-create-v2-image .create-sidebar-cost-hint {
  display: none !important;
}


.create-section-divider {
  height: 1px;
  background: var(--cv2-border, var(--border));
  margin: 20px 0 16px;
  border: none;
}

.create-sidebar-gen {
  width: 100%;
  margin-top: 18px;
  font-size: 14px;
  line-height: 1.25;
  white-space: normal;
  background: var(--cv2-gradient-cta, linear-gradient(90deg, #00d4ff, #a855f7, #ff00ff));
  border: none;
  min-height: 48px;
  border-radius: 14px;
}

.create-form-cta-gen,
.create-mobile-gen,
.create-mobile-summary-gen {
  background: var(--cv2-gradient-cta, linear-gradient(90deg, #00d4ff, #a855f7, #ff00ff));
  border: none;
}

.create-sidebar-delivery,
.create-mobile-delivery {
  margin: 14px 0 0;
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
}

.create-sidebar-telegram {
  display: inline;
  color: #29b6f6;
  font: inherit;
  font-weight: 600;
  line-height: inherit;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.15s ease, text-shadow 0.15s ease;
  vertical-align: baseline;
}

.create-sidebar-telegram--static {
  font-weight: 600;
  cursor: default;
}

.create-sidebar-telegram-icon {
  display: inline-block;
  width: 13px;
  height: 13px;
  margin-right: 3px;
  vertical-align: -2px;
  filter: drop-shadow(0 0 4px rgba(41, 182, 246, 0.25));
}

a.create-sidebar-telegram:hover {
  color: #5ac8fa;
  text-shadow: 0 0 8px rgba(41, 182, 246, 0.35);
}

a.create-sidebar-telegram:focus-visible {
  outline: 1px solid rgba(41, 182, 246, 0.55);
  outline-offset: 2px;
  border-radius: 3px;
}

.create-mobile-delivery .create-sidebar-telegram {
  font-size: inherit;
  line-height: inherit;
}

/* Keep Telegram + icon on the same baseline as surrounding delivery copy */
html.create-v2-page .create-sidebar-delivery,
html.create-v2-page .create-mobile-delivery {
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
}

html.create-v2-page .create-sidebar-telegram {
  display: inline;
  font: inherit;
  font-weight: 600;
  line-height: inherit;
  vertical-align: baseline;
}

html.create-v2-page .create-sidebar-telegram-icon {
  display: inline-block;
  width: 13px;
  height: 13px;
  margin-right: 3px;
  vertical-align: -2px;
}

.create-sidebar-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin-top: 14px;
  padding: 12px;
  border-radius: var(--cv2-radius-md, 12px);
  border: 1px dashed var(--cv2-border, var(--border));
  background: rgba(255, 255, 255, 0.02);
  min-height: 96px;
}

@media (min-width: 960px) {
  html.create-v2-page .create-sidebar-preview {
    margin-top: 12px;
    border-radius: var(--cv2-radius-lg, 16px);
    border-style: solid;
    border-color: var(--cv2-border, rgba(255, 255, 255, 0.1));
    background: rgba(255, 255, 255, 0.03);
    padding: 12px;
  }

  html.create-v2-page .create-sidebar-preview:not(.has-result) {
    display: none;
  }

  html.create-v2-page .create-sidebar-inner {
    border-bottom-left-radius: var(--cv2-radius-lg, 16px);
    border-bottom-right-radius: var(--cv2-radius-lg, 16px);
    border-bottom: 1px solid rgba(168, 85, 247, 0.16);
    padding-bottom: 20px;
  }
}

.create-sidebar-preview .create-telegram-link {
  display: inline-block;
  margin-top: 8px;
}

.create-sidebar-preview .create-sidebar-safe {
  margin-top: 12px;
}

.create-sidebar-preview-placeholder {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
  padding: 18px 8px;
}

.create-sidebar-preview .create-result {
  width: 100%;
  max-width: 100%;
  margin-top: 0;
  border-top: none;
  padding-top: 0;
}

.create-sidebar-preview .create-result-title {
  display: none;
}

.create-sidebar-preview .create-result-media-wrap {
  min-height: 120px;
  margin-bottom: 10px;
}

.create-sidebar-preview .create-result-image {
  max-height: 220px;
}

.create-sidebar-preview .create-result-actions {
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  width: 100%;
}

.create-sidebar-preview .create-result-actions .btn-chip {
  font-size: 11px;
  padding: 5px 8px;
}

.create-sidebar-preview .create-result[hidden] {
  display: none !important;
}

.create-sidebar-preview .create-result.is-sidebar-active,
.create-sidebar-preview .create-result:not([hidden]) {
  display: block;
}

.create-telegram-link {
  display: inline-block;
  margin-top: 6px;
  color: #8eb8ff;
  font-weight: 600;
  text-decoration: none;
}

.create-telegram-link:hover {
  text-decoration: underline;
}

.create-sidebar-safe {
  margin: 10px 0 0;
  font-size: 11px;
  line-height: 1.35;
  opacity: 0.85;
}

.create-sidebar-safe span[aria-hidden="true"] {
  margin-right: 2px;
}

.create-mobile-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: calc(var(--dock) + 6px + env(safe-area-inset-bottom, 0px));
  z-index: 70;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: var(--create-mobile-bar-h, 88px);
  padding: 12px 16px;
  border-top: 1px solid var(--cv2-border, var(--border));
  background: rgba(10, 10, 12, 0.96);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.28);
}

@media (min-width: 960px) {
  .create-mobile-bar { display: none !important; }
}

.create-mobile-summary-btn {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  color: var(--text);
  text-align: left;
  padding: 2px 0;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.create-mobile-summary-compact {
  display: block;
  font-size: 12px;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.create-mobile-summary-meta {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px 8px;
  min-width: 0;
}

.create-mobile-summary-price {
  font-size: 17px;
  font-weight: 700;
  line-height: 1.2;
}

.create-mobile-summary-rub {
  font-size: 13px;
  font-weight: 500;
  line-height: 1.2;
}

.create-mobile-summary-chevron {
  font-size: 14px;
  color: var(--muted);
  line-height: 1;
  flex-shrink: 0;
  margin-left: auto;
}

.create-mobile-summary-sheet {
  position: fixed;
  inset: 0;
  z-index: 85;
  display: flex;
  align-items: flex-end;
}

.create-mobile-summary-sheet[hidden] {
  display: none !important;
}

.create-mobile-summary-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.create-mobile-summary-panel {
  position: relative;
  z-index: 1;
  width: 100%;
  max-height: 78vh;
  overflow: auto;
  border-radius: 18px 18px 0 0;
  background: var(--surface-3);
  border: 1px solid var(--border);
  border-bottom: none;
  padding: 12px 16px calc(16px + env(safe-area-inset-bottom));
}

.create-mobile-summary-h {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 15px;
}

.create-summary-mobile {
  margin-bottom: 14px;
}

.create-mobile-summary-cost {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.create-mobile-summary-cost-main {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.create-mobile-summary-cost-label {
  font-size: 13px;
  color: var(--muted);
}

.create-mobile-summary-stars {
  font-size: 20px;
  font-weight: 700;
}

.create-mobile-summary-rub {
  font-size: 12px;
  text-align: right;
}

.create-mobile-summary-gen {
  width: 100%;
  margin-top: 14px;
  min-height: 48px;
}

.create-mobile-gen {
  flex: 1 1 auto;
  min-width: 148px;
  max-width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  white-space: normal;
}

.sheet-create-v2 {
  padding-bottom: calc(var(--create-mobile-bar-h, 88px) + var(--dock) + 18px + env(safe-area-inset-bottom, 0px));
}

@media (min-width: 960px) {
  .sheet-create-v2 {
    padding-bottom: 24px;
  }
}

/* Model picker v2 */
.model-picker-v2-row {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 10px;
}

.model-picker-v2 .model-row-v2 {
  flex: 1 1 220px;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: var(--cv2-radius-sm, 10px);
  background: var(--cv2-input, var(--surface-4));
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.model-picker-v2 .model-row-v2:hover {
  border-color: rgba(255, 255, 255, 0.16);
  box-shadow: none;
}

.model-picker-v2 .model-row-v2[aria-expanded="true"],
.model-picker-v2 .model-row-v2:focus-visible {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  box-shadow: var(--cv2-glow-focus, 0 0 0 1px rgba(168, 85, 247, 0.16), 0 0 10px rgba(168, 85, 247, 0.08));
}


@media (max-width: 767px) {
  .model-picker-v2-row {
    flex-direction: column;
  }

  .model-picker-v2 .model-row-v2 {
    flex: 1 1 auto;
    width: 100%;
  }
}

.model-row-v2 .model-row-main {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.model-row-v2 .model-row-icon {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  line-height: 1;
  border-radius: 10px;
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.14));
  border: 1px solid rgba(168, 85, 247, 0.22);
  box-sizing: border-box;
  color: var(--text);
}

.model-row-v2 .model-row-text {
  min-width: 0;
  flex: 1;
}

.model-picker-v2 .model-row small {
  color: var(--muted);
  display: block;
  font-size: 12px;
  line-height: 1.3;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.model-picker-v2 .model-row-title strong {
  font-size: 14px;
}

.model-sheet-v2 .model-sheet-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

@media (max-width: 767px) {
  .model-sheet-v2 .model-sheet-filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 2px;
  }

  .model-sheet-v2 .model-sheet-filters::-webkit-scrollbar {
    display: none;
  }

  .model-sheet-v2 .model-sheet-filters .pill {
    flex: 0 0 auto;
  }
}

.model-sheet-v2 .model-badges-v2 {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-left: 6px;
  vertical-align: middle;
}

.model-sheet-v2 .model-badges-v2 .model-badge {
  font-size: 10px;
  font-weight: 600;
  line-height: 1.2;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid rgba(168, 85, 247, 0.28);
  background: rgba(168, 85, 247, 0.1);
  color: var(--muted, #a0a0a0);
}

.model-sheet-footer {
  padding: 10px 16px 16px;
  border-top: 1px solid var(--border);
}

.model-opt-icon {
  margin-right: 4px;
}

/* Prompt v2 */
.sheet-create-v2 .create-form-v2 select,
.sheet-create-v2 .create-form-v2 input[type="text"],
.sheet-create-v2 .create-form-v2 input[type="number"],
.sheet-create-v2 .create-form-v2 textarea:not(.prompt-v2-shell textarea) {
  background: var(--cv2-input, var(--surface-4));
  border-radius: var(--cv2-radius-sm, 10px);
}

.sheet-create-v2 .fg-settings-advanced {
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: var(--cv2-radius-md, 12px);
  padding: 0 12px;
  margin-top: var(--cv2-space-8, 8px);
  background: var(--cv2-card, var(--surface-3));
  box-shadow: none;
}

.sheet-create-v2 .fg-settings-advanced[open] {
  border-color: rgba(168, 85, 247, 0.28);
  background: rgba(168, 85, 247, 0.04);
  box-shadow: var(--cv2-glow-ambient);
}

.sheet-create-v2 .fg-settings-advanced summary {
  padding: 12px 0;
  min-height: 44px;
  box-sizing: border-box;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
  font-size: var(--cv2-section-size, 14px);
  font-weight: 600;
  color: var(--text);
}

.sheet-create-v2 .settings-advanced-summary-inner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.sheet-create-v2 .fg-settings-advanced summary::after {
  content: '▾';
  font-size: 14px;
  color: var(--muted);
  transition: transform 0.15s ease;
  flex-shrink: 0;
}

.sheet-create-v2 .fg-settings-advanced[open] summary::after {
  transform: rotate(180deg);
}

.sheet-create-v2 .fg-settings-advanced summary::-webkit-details-marker {
  display: none;
}

.prompt-v2-shell {
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: var(--cv2-radius-sm, 10px);
  background: var(--cv2-input, var(--surface-4));
  overflow: hidden;
}

.prompt-v2-shell .prompt-v2-field textarea {
  min-height: 92px;
  max-height: 240px;
  border: none;
  border-radius: 0;
  background: transparent;
  padding: 12px 12px 8px;
  resize: none;
  overflow-y: hidden;
}



.prompt-v2-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px 10px;
  border-top: 1px solid var(--cv2-border, var(--border));
  background: rgba(0, 0, 0, 0.15);
}

.prompt-v2-footer .field-char {
  display: block !important;
  margin: 0;
  font-size: 11px;
  opacity: 0.55;
  white-space: nowrap;
}

.prompt-v2-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo) {
  border: 1px solid var(--cv2-border, var(--border));
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  font-weight: 600;
  padding: 7px 12px;
  box-shadow: none;
}

.sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo):hover {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.09);
}

.sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo):active {
  border-color: rgba(168, 85, 247, 0.4);
  background: rgba(168, 85, 247, 0.1);
}

.btn-chip-ghost {
  background: transparent;
  border-color: transparent;
  color: var(--muted);
}

.btn-chip-ghost:hover {
  color: var(--text);
  border-color: var(--cv2-border, var(--border));
  background: rgba(255, 255, 255, 0.04);
}

.btn-chip {
  border: 1px solid var(--border);
  background: var(--surface-4);
  color: var(--text);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 12px;
  cursor: pointer;
  font-family: inherit;
}

.btn-enhance.is-loading {
  opacity: 0.6;
  pointer-events: none;
}

.prompt-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.prompt-chip {
  border: 1px solid var(--border);
  background: var(--surface-4);
  color: var(--text);
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 12px;
  cursor: pointer;
  font-family: inherit;
}

.prompt-examples {
  position: relative;
  margin-top: 4px;
}

.prompt-examples:has(.prompt-examples-sheet:not([hidden])) {
  z-index: 80;
}

.prompt-examples .prompt-chips {
  margin-top: 0;
}

.prompt-examples-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  border-style: dashed;
}

.prompt-examples-more-ico {
  display: block;
  flex-shrink: 0;
}

.prompt-examples-sheet {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  box-sizing: border-box;
}

.prompt-examples-sheet[hidden] {
  display: none !important;
}

.prompt-examples-backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: rgba(0, 0, 0, 0.4);
  pointer-events: auto;
}

.prompt-examples-panel {
  position: relative;
  z-index: 1;
  width: min(960px, calc(100vw - 48px));
  max-width: 100%;
  background: var(--modal, var(--surface-3));
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: 14px;
  padding: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.32);
  max-height: calc(100dvh - 64px);
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  box-sizing: border-box;
}

.prompt-examples-h {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
  font-size: 13px;
  flex-shrink: 0;
  background: var(--modal, var(--surface-3));
}

.prompt-examples-body {
  overflow: auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-right: 8px;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.28) transparent;
}

.prompt-examples-body::-webkit-scrollbar {
  width: 7px;
}

.prompt-examples-body::-webkit-scrollbar-track {
  background: transparent;
}

.prompt-examples-body::-webkit-scrollbar-thumb {
  background-color: rgba(255, 255, 255, 0.22);
  border-radius: 999px;
}

.prompt-examples-body::-webkit-scrollbar-thumb:hover {
  background-color: rgba(255, 255, 255, 0.38);
}

html[data-theme="light"] .prompt-examples-backdrop {
  background: rgba(20, 22, 30, 0.4);
}

html[data-theme="light"] .prompt-examples-body {
  scrollbar-color: rgba(20, 22, 30, 0.32) transparent;
}

html[data-theme="light"] .prompt-examples-body::-webkit-scrollbar-thumb {
  background-color: rgba(20, 22, 30, 0.28);
}

html[data-theme="light"] .prompt-examples-body::-webkit-scrollbar-thumb:hover {
  background-color: rgba(20, 22, 30, 0.45);
}

.prompt-examples-cat {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 8px;
}

.prompt-examples-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.prompt-example-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  width: 100%;
  text-align: left;
  border: 1px solid var(--cv2-border, var(--border));
  background: var(--cv2-input, var(--surface-4));
  color: var(--text);
  border-radius: var(--cv2-radius-xs, 8px);
  padding: 8px 10px;
  cursor: pointer;
  font-family: inherit;
}

.prompt-example-item-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
}

.prompt-example-item-preview {
  font-size: 12px;
  line-height: 1.4;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
}

@media (max-width: 767px) {
  .prompt-examples-sheet {
    position: fixed;
    inset: 0;
    z-index: 80;
    min-width: 0;
    max-width: none;
    display: flex;
    align-items: flex-end;
    justify-content: stretch;
  }

  .prompt-examples-sheet[hidden] {
    display: none !important;
  }

  .prompt-examples-backdrop {
    position: absolute;
    inset: 0;
    z-index: 0;
  }

  .prompt-examples-panel {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: none;
    max-height: 72vh;
    border-radius: 18px 18px 0 0;
    padding: 16px 16px calc(16px + env(safe-area-inset-bottom));
    box-shadow: none;
  }
}

/* Image Prompt Builder (deterministic scene composer) */
.ipb-selected {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
  min-width: 0;
}

.ipb-selected[hidden] {
  display: none !important;
}

.ipb-selected-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  min-height: 32px;
  padding: 4px 8px 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--cv2-border, var(--border));
  background: var(--cv2-soft-fill, var(--chip));
  color: var(--text);
  font-size: 12px;
  line-height: 1.2;
  cursor: pointer;
  touch-action: manipulation;
  box-sizing: border-box;
}

.ipb-selected-chip[aria-pressed="true"],
.ipb-selected-chip.is-on {
  border-color: var(--cv2-accent-border, var(--accent));
  background: var(--cv2-accent-soft, var(--chip-on));
  box-shadow: var(--cv2-glow-selected, none);
}

.ipb-selected-chip-x {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  opacity: 0.75;
  flex-shrink: 0;
}

.ipb-preview {
  margin-top: 8px;
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: var(--cv2-radius-md, 12px);
  background: var(--cv2-card, var(--surface-3));
  padding: 0 10px;
  min-width: 0;
}

.ipb-preview[hidden] {
  display: none !important;
}

.ipb-preview > summary {
  cursor: pointer;
  list-style: none;
  font-size: 12px;
  font-weight: 600;
  padding: 10px 0;
  color: var(--text);
}

.ipb-preview > summary::-webkit-details-marker {
  display: none;
}

.ipb-preview-text {
  margin: 0 0 10px;
  font-size: 12px;
  line-height: 1.45;
  color: var(--muted);
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 7.5em;
  overflow: auto;
}

.ipb-preview-warn {
  margin: 0 0 10px;
  font-size: 12px;
  color: var(--danger, #c44);
}

.ipb-sheet {
  position: fixed;
  inset: 0;
  z-index: 85;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  box-sizing: border-box;
}

.ipb-sheet[hidden] {
  display: none !important;
}

.ipb-backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: rgba(0, 0, 0, 0.4);
}

.ipb-panel {
  position: relative;
  z-index: 1;
  width: min(560px, calc(100vw - 32px));
  max-width: 100%;
  max-height: calc(100dvh - 48px);
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  box-sizing: border-box;
  background: var(--modal, var(--surface-3));
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: 16px;
  padding: 12px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.32);
}

.ipb-h {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 14px;
  flex-shrink: 0;
}

.ipb-h-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.ipb-body {
  overflow: auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-right: 4px;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.ipb-group-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 8px;
}

.ipb-options {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
}

.ipb-opt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--cv2-border, var(--border));
  background: var(--cv2-soft-fill, var(--chip));
  color: var(--text);
  font-size: 13px;
  line-height: 1.2;
  cursor: pointer;
  touch-action: manipulation;
  box-sizing: border-box;
  max-width: 100%;
}

.ipb-opt:hover {
  border-color: var(--cv2-accent-border, var(--accent));
  background: var(--cv2-soft-fill-hover, var(--hover));
}

.ipb-opt:focus-visible {
  outline: 2px solid var(--cv2-accent-border, var(--accent));
  outline-offset: 2px;
}

.ipb-opt[aria-selected="true"],
.ipb-opt[aria-pressed="true"],
.ipb-opt.is-on {
  border-color: var(--cv2-accent-border, var(--accent));
  background: var(--cv2-accent-soft, var(--chip-on));
  box-shadow: var(--cv2-glow-selected, none);
  font-weight: 600;
}

.ipb-footer {
  flex-shrink: 0;
  padding-top: 10px;
  display: flex;
  justify-content: stretch;
}

.ipb-footer .ipb-done {
  width: 100%;
  min-height: 44px;
}

@media (max-width: 767px) {
  .ipb-sheet {
    align-items: flex-end;
    justify-content: stretch;
  }

  .ipb-panel {
    width: 100%;
    max-width: none;
    max-height: min(78vh, calc(100dvh - 56px - env(safe-area-inset-bottom)));
    border-radius: 18px 18px 0 0;
    padding: 12px 14px calc(12px + env(safe-area-inset-bottom));
    box-shadow: none;
  }

  .sheet-create-v2 .prompt-v2-actions {
    flex-wrap: wrap;
  }

  .sheet-create-v2 .prompt-v2-actions .btn-ipb-open {
    min-height: 36px;
  }
}

html[data-theme="light"] .ipb-opt[aria-selected="true"],
html[data-theme="light"] .ipb-opt[aria-pressed="true"],
html[data-theme="light"] .ipb-opt.is-on,
html[data-theme="light"] .ipb-selected-chip {
  color: var(--text) !important;
  background: var(--cv2-accent-soft, var(--chip-on)) !important;
  border-color: var(--cv2-accent-border) !important;
}

/* Prompt enhance compare panel */
.prompt-enhance-panel {
  margin-top: 12px;
}

.prompt-enhance-panel[hidden] {
  display: none !important;
}

.prompt-enhance-backdrop {
  display: none;
}

.prompt-enhance-panel-inner {
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: var(--cv2-radius-md, 12px);
  background: var(--cv2-card, var(--surface-3));
  padding: 14px;
}

.prompt-enhance-panel-h {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 14px;
}

.prompt-enhance-compare {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 12px;
  align-items: start;
}

.prompt-enhance-col-label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.prompt-enhance-text {
  font-size: 13px;
  line-height: 1.45;
  white-space: pre-wrap;
  padding: 10px;
  border-radius: var(--cv2-radius-xs, 8px);
  background: var(--cv2-input, var(--surface-4));
  border: 1px solid var(--cv2-border, var(--border));
  min-height: 72px;
}

.prompt-enhance-text:not(.muted) {
  color: var(--text);
}

.prompt-enhance-arrow {
  align-self: center;
  font-size: 18px;
  color: var(--muted);
  padding-top: 24px;
}

.prompt-enhance-inline-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
  margin-top: 12px;
  flex-wrap: wrap;
}

.prompt-enhance-inline-actions .cab-btn-secondary {
  height: 36px;
  padding: 0 12px;
  font-size: 13px;
  text-decoration: none;
}

.prompt-enhance-inline-actions .cab-cta {
  min-height: 36px;
  padding: 0 16px;
  font-size: 13px;
  border-radius: 10px;
}

/* Prompt Assistant (paid) — reuse enhance panel chrome */
.pa-action-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pa-action-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.pa-action-price {
  opacity: 0.85;
  font-variant-numeric: tabular-nums;
}

.pa-menu-hint {
  margin: 12px 0 0;
  font-size: 12px;
  line-height: 1.4;
}

.pa-variants {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

.pa-variant-card {
  text-align: left;
  width: 100%;
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: var(--cv2-radius-xs, 8px);
  background: var(--cv2-input, var(--surface-4));
  color: inherit;
  font: inherit;
  padding: 10px 12px;
  cursor: pointer;
}

.pa-variant-card.is-on {
  border-color: var(--cv2-accent, var(--text));
  box-shadow: inset 0 0 0 1px var(--cv2-accent, var(--text));
}

.pa-variant-label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.pa-variant-text {
  display: block;
  font-size: 13px;
  line-height: 1.45;
  white-space: pre-wrap;
}

.pa-result-loading {
  margin-bottom: 10px;
  font-size: 13px;
}

@media (max-width: 767px) {
  .prompt-enhance-panel {
    position: fixed;
    inset: 0;
    z-index: 90;
    margin: 0;
    display: flex;
    align-items: flex-end;
  }

  .prompt-enhance-panel[hidden] {
    display: none !important;
  }

  .prompt-enhance-backdrop {
    display: block;
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
  }

  .prompt-enhance-panel-inner {
    position: relative;
    width: 100%;
    max-height: 92vh;
    overflow: auto;
    border-radius: 18px 18px 0 0;
    padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  }

  .prompt-enhance-compare {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .prompt-enhance-arrow {
    text-align: center;
    padding: 0;
  }
}

/* Upload dropzone v2 */
.lbl-upload-v2 {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.upload-v2-counter {
  font-size: 12px;
  font-weight: 500;
}

.upload-v2-body {
  display: block;
}

.upload-dropzone {
  border: 1px dashed var(--border);
  border-radius: 14px;
  padding: 12px;
  background: var(--surface-4);
}

.sheet-create-v2 .upload-dropzone {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.14));
  background: var(--cv2-dropzone-bg, rgba(255, 255, 255, 0.02));
  border-radius: var(--cv2-radius-md, 12px);
  padding: 16px;
  min-height: 120px;
  box-shadow: none;
}

.sheet-create-v2 .upload-dropzone.is-drag,
.sheet-create-v2 .upload-dropzone-start-frame.is-drag {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  border-style: dashed;
  background: rgba(168, 85, 247, 0.08);
  box-shadow: var(--cv2-glow-selected, 0 0 0 1px rgba(168, 85, 247, 0.14), 0 0 12px rgba(168, 85, 247, 0.18));
}

.sheet-create-v2 .upload-dropzone-start-frame {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.14));
  background: var(--cv2-dropzone-bg, rgba(255, 255, 255, 0.02));
  box-shadow: none;
}

.sheet-create-v2 .upload-dropzone-start-frame.is-drag {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  border-style: dashed;
  background: rgba(168, 85, 247, 0.08);
  box-shadow: var(--cv2-glow-selected, 0 0 0 1px rgba(168, 85, 247, 0.14), 0 0 12px rgba(168, 85, 247, 0.18));
}

.sheet-create-v2 .upload-dropzone-start-frame .upload-dropzone-plus,
.sheet-create-v2 .upload-dropzone-ref .upload-dropzone-plus,
.sheet-create-v2 .upload-dropzone .upload-dropzone-plus {
  color: var(--muted);
}

.sheet-create-v2 .upload-dropzone-btn {
  min-height: 100px;
  gap: 8px;
}

.sheet-create-v2 .upload-dropzone-plus {
  font-size: 28px;
  color: var(--muted);
  opacity: 1;
}

.upload-dropzone-btn {
  width: 100%;
  border: none;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 6px;
  min-height: 80px;
  justify-content: center;
}

.upload-dropzone-plus {
  font-size: 24px;
  line-height: 1;
  opacity: 0.7;
}

.upload-v2-gallery {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px;
}

.upload-v2-gallery[hidden],
.upload-dropzone[hidden],
.upload-add-tile[hidden],
.upload-thumbs-v2[hidden] {
  display: none !important;
}

.upload-thumbs-v2 {
  display: contents;
}

.upload-thumbs-v2 .upload-thumb {
  position: relative;
  width: 72px;
  height: 72px;
  flex: 0 0 72px;
}

.upload-thumbs-v2 .upload-thumb img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--border);
  display: block;
}

.upload-thumb-rm {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 22px;
  height: 22px;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.65);
  color: #fff;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
}

.upload-add-tile {
  width: 72px;
  height: 72px;
  flex: 0 0 72px;
  border: 1px dashed var(--border);
  border-radius: 10px;
  background: var(--surface-4);
  color: var(--muted);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  font-size: 11px;
  padding: 4px;
}

.upload-add-tile .upload-dropzone-plus {
  font-size: 18px;
}

.fg-prompt-v2 .field-char {
  display: none;
  font-size: 11px;
  opacity: 0.55;
  text-align: right;
  margin-top: 4px;
}

.fg-prompt-v2:focus-within .field-char,
.fg-prompt-v2 .field-char.is-visible {
  display: block;
}

/* Aspect compact */
.aspect-compact-row {
  position: relative;
}

.aspect-pills-compact {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.aspect-pill {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 36px;
  padding: 7px 12px !important;
  line-height: 1.2;
  gap: 6px;
  border-radius: 10px;
}

.aspect-pill-auto {
  min-height: 36px;
}

.aspect-pill-glyph,
.aspect-pill-icon {
  font-size: 14px;
  line-height: 1;
  opacity: 0.85;
}

/* Legacy shape pictograms — hidden in Create v2 text-only aspect UI */
.sheet-create-v2 .aspect-shape,
.sheet-create-v2 .aspect-pill-glyph,
.sheet-create-v2 .aspect-pill-hint {
  display: none !important;
}

.aspect-shape {
  display: inline-block;
  border: 1.5px solid currentColor;
  border-radius: 2px;
  box-sizing: border-box;
  opacity: 0.9;
}

.aspect-shape--1-1 { width: 14px; height: 14px; }
.aspect-shape--2-3 { width: 10px; height: 15px; }
.aspect-shape--3-2 { width: 15px; height: 10px; }
.aspect-shape--3-4 { width: 11px; height: 15px; }
.aspect-shape--4-3 { width: 15px; height: 11px; }
.aspect-shape--4-5 { width: 11px; height: 14px; }
.aspect-shape--5-4 { width: 14px; height: 11px; }
.aspect-shape--9-16 { width: 9px; height: 16px; }
.aspect-shape--16-9 { width: 16px; height: 9px; }
.aspect-shape--21-9 { width: 18px; height: 8px; }

.aspect-pill-more.is-on {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
}

.aspect-pill-ratio {
  font-weight: 700;
  font-size: 13px;
}

.aspect-pill-hint {
  font-size: 10px;
  color: var(--muted);
  margin-top: 2px;
}

.aspect-all-sheet {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 70;
  min-width: 280px;
}

.aspect-all-sheet[hidden] {
  display: none !important;
}

.aspect-all-backdrop {
  display: none;
}

.aspect-all-panel {
  position: relative;
  background: var(--modal, var(--surface-3));
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
}

.aspect-all-h {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 13px;
}

.aspect-pills-all {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

@media (max-width: 767px) {
  .aspect-all-sheet {
    position: fixed;
    inset: 0;
    z-index: 80;
    min-width: 0;
    display: flex;
    align-items: flex-end;
    justify-content: stretch;
  }

  .aspect-all-sheet[hidden] {
    display: none !important;
  }

  .aspect-all-backdrop {
    display: block;
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
  }

  .aspect-all-panel {
    position: relative;
    z-index: 1;
    width: 100%;
    max-height: 55vh;
    border-radius: 18px 18px 0 0;
    padding: 16px 16px calc(16px + env(safe-area-inset-bottom));
    overflow: auto;
    box-shadow: none;
  }
}

.video-mode-toggle .video-mode-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.video-mode-icon {
  font-size: 15px;
  line-height: 1;
}

.duration-pills-v2 {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.duration-pills-v2 .pill {
  min-width: 0;
  min-height: var(--cv2-control-h, 36px);
  height: var(--cv2-control-h, 36px);
  box-sizing: border-box;
  padding: 0 12px !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.duration-pill-main {
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

.prompt-motion-chips {
  margin-top: 8px;
}

.fg-video-motion-advanced {
  margin-bottom: 4px;
}

.fg-video-motion-advanced .lbl {
  margin-bottom: 8px;
}

@media (max-width: 959px) {
  .create-sidebar-preview {
    margin: 16px 0 8px;
  }
}

.fg-upload-start-frame .upload-dropzone-start-frame {
  min-height: 140px;
}

.fg-upload-start-frame .upload-dropzone-btn {
  min-height: 140px;
}

@media (min-width: 768px) {
  .fg-upload-start-frame .upload-dropzone-start-frame,
  .fg-upload-start-frame .upload-dropzone-btn {
    min-height: 120px;
  }
}

.video-settings-rows {
  display: none;
}

.video-setting-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 14px 0;
  border: none;
  border-bottom: 1px solid var(--cv2-border, var(--border));
  background: transparent;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.video-setting-row:first-child {
  border-top: 1px solid var(--cv2-border, var(--border));
}

.video-setting-row-label {
  flex: 0 0 auto;
  font-size: 14px;
  font-weight: 600;
}

.video-setting-row-value {
  flex: 1 1 auto;
  font-size: 14px;
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.video-setting-row-chevron {
  flex: 0 0 auto;
  font-size: 18px;
  line-height: 1;
  color: var(--muted);
}

.video-setting-sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: 44;
  background: rgba(0, 0, 0, 0.55);
}

.video-setting-block.is-sheet-open {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 45;
  margin: 0;
  padding: 12px 16px calc(16px + env(safe-area-inset-bottom));
  border-radius: 16px 16px 0 0;
  background: var(--cv2-card, var(--surface-3));
  border: 1px solid var(--cv2-border, var(--border));
  border-bottom: none;
  box-shadow: 0 -12px 32px rgba(0, 0, 0, 0.35);
  max-height: min(72vh, 520px);
  overflow-y: auto;
}

.video-setting-block.is-sheet-open .lbl {
  display: none;
}

@media (max-width: 767px) {
  .fg-settings-basic-video .video-settings-rows {
    display: block;
    margin-bottom: 4px;
  }

  .fg-settings-basic-video .settings-basic-grid-video .video-setting-block {
    display: none;
  }

  .fg-settings-basic-video .settings-basic-grid-video .video-setting-block.is-sheet-open {
    display: block;
  }
}

@media (min-width: 768px) {
  .video-settings-rows,
  .video-setting-sheet-backdrop {
    display: none !important;
  }
}

.fg-settings-basic .lbl-section {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 16px;
}

.settings-basic-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (max-width: 767px) {
  .settings-basic-grid-image {
    grid-template-columns: 1fr 1fr;
    column-gap: 12px;
    row-gap: 16px;
  }

  .settings-basic-grid-image [data-image-setting-block="aspect_compact"],
  .settings-basic-grid-image [data-image-setting-block="aspect_full"],
  .settings-basic-grid-image [data-image-setting-block="aspect_nano"] {
    grid-column: 1 / -1;
  }

  .settings-basic-grid-image [data-image-setting-block="qty"] .qty-v2 {
    width: 100%;
    max-width: 280px;
  }
}

@media (max-width: 359px) {
  .settings-basic-grid-image {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1100px) {
  .settings-basic-grid-image {
    grid-template-columns:
      minmax(0, 1.6fr)
      minmax(200px, 0.8fr)
      minmax(200px, 0.8fr);
    column-gap: 24px;
    row-gap: 16px;
    align-items: start;
  }

  .settings-basic-grid-image [data-image-setting-block="aspect_compact"],
  .settings-basic-grid-image [data-image-setting-block="aspect_full"],
  .settings-basic-grid-image [data-image-setting-block="aspect_nano"] {
    grid-column: 1;
    grid-row: 1;
  }

  .settings-basic-grid-image [data-image-setting-block^="image_resolution"],
  .settings-basic-grid-image [data-image-setting-block="resolution"] {
    grid-column: 2;
    grid-row: 1;
  }

  .settings-basic-grid-image [data-image-setting-block="qty"] {
    grid-column: 3;
    grid-row: 1;
  }

  .settings-basic-grid-image .fg-qty .qty-v2 {
    width: 100%;
    min-width: 0;
    max-width: 280px;
    flex-wrap: nowrap;
  }

  .settings-basic-grid-image .fg-qty .qty-v2,
  .settings-basic-grid-image .fg-qty .qty-v2 button {
    min-height: 36px;
    height: 36px;
  }

  .settings-basic-grid-image .fg-qty .qty-v2 button {
    flex: 0 0 42px;
  }

  .settings-basic-grid-image .fg-qty .qty-v2 span[data-qty-val] {
    flex: 1 1 auto;
    min-width: 82px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1.2;
  }
}

.sheet-create-v2 .fg-qty .qty-v2-hint {
  display: block;
  margin-top: 8px;
  font-size: 12px;
  line-height: 1.4;
}

.settings-basic-grid .fg-aspect-compact,
.settings-basic-grid .fg-qty,
.settings-basic-grid [data-kie-param="resolution"] {
  margin-bottom: 0;
}

.settings-basic-grid [data-resolution-v2="1"] .select-option-hint {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.35;
}

.fg-settings-advanced summary {
  cursor: pointer;
  font-weight: 600;
  padding: 12px 0;
}

.fg-settings-advanced .settings-advanced-body {
  padding: 8px 0 14px;
}

.advanced-kie-range {
  margin-bottom: var(--cv2-field-gap, 14px);
}

.advanced-kie-range-head {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
}

.advanced-kie-range-label {
  font-size: var(--cv2-label-size, 13px);
  font-weight: 600;
}

.advanced-kie-range-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.advanced-kie-range-input {
  flex: 1;
  min-width: 0;
  height: 24px;
  accent-color: var(--cv2-accent, #a855f7);
  cursor: pointer;
}

.advanced-kie-range-display {
  width: 64px;
  min-width: 56px;
  max-width: 68px;
  height: var(--cv2-control-h, 36px);
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  font-weight: 700;
  color: var(--text, #fff);
  border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.12));
  border-radius: var(--cv2-radius-sm, 10px);
  background: var(--cv2-input, rgba(255, 255, 255, 0.04));
}

.advanced-kie-range-endpoints {
  display: flex;
  justify-content: space-between;
  margin-top: 4px;
  font-size: 11px;
  color: var(--muted, #888);
}

.create-quick-tools {
  margin: 24px 0 16px;
  padding-top: 8px;
}

.create-quick-tools-label {
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 700;
}

.create-quick-tools-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 359px) {
  .create-quick-tools-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (min-width: 768px) {
  .create-quick-tools-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }
}

.create-quick-tool-card {
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 12px;
  min-height: 96px;
  border-radius: var(--cv2-radius-md, 12px);
  border: 1px solid var(--cv2-border, var(--border));
  background: var(--cv2-card, var(--surface-3));
  color: var(--text);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
  box-sizing: border-box;
  width: 100%;
}

a.create-quick-tool-card:hover {
  color: var(--text);
  text-decoration: none;
}

.create-quick-tool-card:hover {
  border-color: var(--cv2-hover-border, rgba(255, 255, 255, 0.16));
  box-shadow: var(--cv2-glow-hover);
}

.create-quick-tool-card:focus-visible {
  outline: none;
  border-color: var(--cv2-accent-border, var(--ui-focus-border, rgba(168, 85, 247, 0.55)));
  box-shadow: var(--cv2-glow-focus, var(--ui-focus-glow));
}

.create-quick-tool-card:active:not(.is-disabled):not(.is-locked) {
  box-shadow: none;
}

.create-quick-tool-card.is-on {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.1));
  box-shadow: var(--cv2-glow-selected);
}

.create-quick-tool-card.is-disabled,
.create-quick-tool-card.is-locked {
  opacity: 0.55;
  cursor: not-allowed;
}

.create-quick-tool-card.is-disabled:hover,
.create-quick-tool-card.is-locked:hover {
  box-shadow: none;
  border-color: var(--cv2-border, var(--border));
}

.create-quick-tool-card-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1 1 auto;
  min-width: 0;
  padding-right: 8px;
}

.create-quick-tool-card-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.25;
}

.create-quick-tool-card-hint {
  font-size: 11px;
  line-height: 1.35;
  color: var(--muted);
}

.create-quick-tool-icon {
  font-size: 20px;
  line-height: 1;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.14));
  border: 1px solid rgba(168, 85, 247, 0.22);
  box-sizing: border-box;
  color: var(--text);
}

.create-quick-tool-icon img,
.create-quick-tool-ico-img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  filter: none;
  mix-blend-mode: normal;
  display: block;
}

.create-quick-tool-icon .create-quick-tool-ico-svg {
  width: 20px;
  height: 20px;
  display: block;
  flex-shrink: 0;
}

.create-quick-tool-chevron {
  flex: 0 0 auto;
  margin-left: auto;
  align-self: center;
  font-size: 14px;
  line-height: 1;
  color: var(--muted, #888);
  opacity: 0.75;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.create-quick-tool-chevron .create-quick-tool-chevron-svg {
  width: 16px;
  height: 16px;
  display: block;
  flex-shrink: 0;
}

.create-quick-tool-lock {
  font-size: 12px;
}

.settings-basic-grid [data-resolution-v2="1"] .select-option-hint {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
}

.settings-basic-grid [data-resolution-v2="1"] select {
  font-weight: 600;
}

.qty-v2 {
  display: inline-flex;
  align-items: center;
  max-width: 280px;
}

.qty-v2 span[data-qty-val] {
  flex: 1;
  min-width: 110px;
  text-align: center;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1.2;
}

/* Result panel */
.create-result[hidden] {
  display: none !important;
}

.create-result {
  margin-top: 24px;
  border-top: 1px solid var(--border);
  padding-top: 20px;
}

.create-result-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.create-result-title {
  margin: 0 0 12px;
  font-size: 18px;
  width: 100%;
  text-align: center;
}

.create-result-media-wrap {
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface-4);
  min-height: 200px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.create-result-image {
  display: block;
  width: 100%;
  max-height: 520px;
  object-fit: contain;
}

.create-result-loading,
.create-result-fallback {
  width: 100%;
  padding: 24px;
  text-align: center;
  font-size: 14px;
}

.create-result-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

/* [hidden] alone loses to display:flex — must force hide or FAILED+RUNNING both show */
.create-result-loading[hidden],
.create-result-fallback[hidden] {
  display: none !important;
}

.create-result-spinner {
  width: 28px;
  height: 28px;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-top-color: var(--cv2-accent, #a855f7);
  border-radius: 50%;
  animation: cv2-result-spin 0.8s linear infinite;
}

@keyframes cv2-result-spin {
  to { transform: rotate(360deg); }
}

.create-result-error {
  margin: 0 0 12px;
  padding: 14px 16px;
  border-radius: var(--cv2-radius-sm, 10px);
  border: 1px solid rgba(255, 90, 90, 0.35);
  background: rgba(255, 90, 90, 0.08);
  color: #ffb4b4;
  font-size: 13px;
  line-height: 1.45;
  text-align: center;
  white-space: pre-line;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.create-result-error[hidden] {
  display: none !important;
}

/* Terminal states are mutually exclusive — never FAILED+LOADING */
.create-result[data-result-state="failed"] .create-result-loading,
.create-result[data-result-state="success"] .create-result-loading,
.create-result[data-result-state="continue"] .create-result-loading,
.create-result[data-result-state="idle"] .create-result-loading {
  display: none !important;
}

.create-result[data-result-state="failed"] .create-result-media-wrap {
  display: none;
}

.create-result[data-result-state="loading"] .create-result-error,
.create-result[data-result-state="success"] .create-result-error,
.create-result[data-result-state="continue"] .create-result-error,
.create-result[data-result-state="idle"] .create-result-error {
  display: none !important;
}

.create-result[data-result-state="failed"] .create-result-spinner,
.create-result[data-result-state="success"] .create-result-spinner,
.create-result[data-result-state="continue"] .create-result-spinner,
.create-result[data-result-state="idle"] .create-result-spinner {
  animation: none;
}

.create-result-continue {
  width: 100%;
  padding: 20px 16px;
  text-align: center;
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted, #9a9aa0);
}

.create-result-continue[hidden] {
  display: none !important;
}

.create-result-video,
.create-result-audio {
  width: 100%;
  max-height: 420px;
  border-radius: 12px;
  background: #000;
}

.create-result-audio {
  max-height: none;
  background: transparent;
}

.create-result-grid-item.is-video {
  font-size: 13px;
  font-weight: 600;
}

.create-result-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 8px;
  width: 100%;
}

.create-result-grid-item {
  border: none;
  padding: 0;
  margin: 0;
  background: var(--surface, rgba(255, 255, 255, 0.06));
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  min-height: 96px;
  color: var(--muted);
}

.create-result-grid-item.is-on {
  outline: 2px solid var(--accent, #6cf);
  outline-offset: 2px;
}

.create-result-grid-item img {
  width: 100%;
  height: auto;
  display: block;
}

.create-result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.create-result-actions .btn-chip {
  text-decoration: none;
}

.create-result-actions .btn-chip[hidden] {
  display: none !important;
}

/* Resolution picker v2 */
.resolution-picker-v2 {
  position: relative;
}

.resolution-picker-v2-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: var(--cv2-radius-sm, 10px);
  background: var(--cv2-input, var(--surface-4));
  color: var(--text);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}

.resolution-picker-v2-btn:hover {
  border-color: rgba(168, 85, 247, 0.4);
  background: rgba(168, 85, 247, 0.06);
  box-shadow: var(--cv2-glow-hover);
}

.resolution-picker-v2-chevron {
  color: var(--muted);
  font-size: 14px;
  line-height: 1;
}

.resolution-picker-v2-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 70;
}

.resolution-picker-v2-menu[hidden] {
  display: none !important;
}

.resolution-picker-v2-backdrop {
  display: none;
}

.resolution-picker-v2-panel {
  background: var(--modal, var(--surface-3));
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
}

.resolution-picker-v2-h {
  display: none;
}

.resolution-picker-v2-options {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 240px;
  overflow: auto;
}

.resolution-picker-v2-opt {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 10px 12px;
  border: 1px solid var(--cv2-border, var(--border));
  border-radius: var(--cv2-radius-sm, 10px);
  background: var(--cv2-card, var(--surface-4));
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.resolution-picker-v2-opt:hover {
  border-color: rgba(255, 255, 255, 0.14);
}

.resolution-picker-v2-opt.is-on {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.14));
  box-shadow: var(--cv2-accent-glow);
}

.resolution-picker-v2-opt-main {
  font-size: 14px;
  font-weight: 600;
}

.resolution-picker-v2-opt-hint {
  font-size: 12px;
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
}

@media (max-width: 767px) {
  .resolution-picker-v2-menu {
    position: fixed;
    inset: 0;
    z-index: 82;
    display: flex;
    align-items: flex-end;
  }

  .resolution-picker-v2-backdrop {
    display: block;
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
  }

  .resolution-picker-v2-panel {
    position: relative;
    z-index: 1;
    width: 100%;
    max-height: 60vh;
    border-radius: 18px 18px 0 0;
    padding: 12px 16px calc(16px + env(safe-area-inset-bottom));
    overflow: auto;
    box-shadow: none;
  }

  .resolution-picker-v2-h {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 15px;
  }

  .resolution-picker-v2-options {
    max-height: none;
  }
}

.settings-basic-grid [data-resolution-picker-v2="1"] .select-option-hint {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
}

/* Balance + generate states */
.create-balance-alert {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: var(--cv2-radius-sm, 10px);
  border: 1px solid rgba(255, 90, 90, 0.35);
  background: rgba(255, 90, 90, 0.08);
  font-size: 12px;
  line-height: 1.4;
}

.create-balance-alert-text {
  margin: 0 0 6px;
}

.create-balance-alert-link {
  font-size: 12px;
}

.create-mobile-bar {
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
}

.create-mobile-bar-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.create-mobile-bar-alert {
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(255, 90, 90, 0.35);
  background: rgba(255, 90, 90, 0.08);
  font-size: 11px;
  line-height: 1.35;
}

.create-mobile-bar-alert .create-balance-alert-text {
  margin: 0;
}

.create-form-v2.is-insufficient-balance .create-sidebar-gen,
.create-form-v2.is-insufficient-balance .create-mobile-gen,
.create-form-v2.is-insufficient-balance .create-mobile-summary-gen {
  opacity: 0.55;
  box-shadow: none;
  filter: saturate(0.45) brightness(0.72);
  transform: none;
}

button.gen.is-loading {
  opacity: 0.85;
  pointer-events: none;
}

/* Audio v2: locked only for single-provider picker */
.model-picker-audio-v2[data-model-picker-single] .model-row-audio-v2 {
  cursor: default;
  pointer-events: none;
}

.model-picker-audio-v2:not([data-model-picker-single]) .model-row-audio-v2 {
  cursor: pointer;
}

.suno-mode-toggle-v2 .task-mode-btn.is-on {
  color: var(--text);
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
  box-shadow: var(--cv2-glow-selected);
}

/* Audio segmented icons — visual markers only; keep equal segments & Create V2 neon */
.sheet-create-v2-audio .suno-mode-toggle-v2 {
  width: 100%;
  max-width: 420px;
}

.sheet-create-v2-audio .suno-mode-toggle-v2 .task-mode-btn {
  flex: 1 1 0;
  min-width: 0;
  gap: 6px;
}

.sheet-create-v2-audio .suno-track-pills-v2 {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.sheet-create-v2-audio .suno-track-pills-v2 .pill {
  flex: 1 1 0;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.sheet-create-v2-audio .segmented-option-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  font-size: 14px;
  line-height: 1;
  opacity: 0.75;
  pointer-events: none;
}

.sheet-create-v2-audio .task-mode-btn:hover .segmented-option-icon,
.sheet-create-v2-audio .task-mode-btn.is-on .segmented-option-icon,
.sheet-create-v2-audio .suno-track-pills-v2 .pill:hover .segmented-option-icon,
.sheet-create-v2-audio .suno-track-pills-v2 .pill.is-on .segmented-option-icon {
  opacity: 1;
}

.sheet-create-v2-audio .segmented-option-label {
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 420px) {
  .sheet-create-v2-audio .segmented-option-icon {
    font-size: 13px;
  }

  .sheet-create-v2-audio .suno-mode-toggle-v2 .task-mode-btn,
  .sheet-create-v2-audio .suno-track-pills-v2 .pill {
    gap: 5px;
    padding-left: 10px;
    padding-right: 10px;
  }
}

html.create-v2-page .sheet-create-v2-audio .suno-mode-toggle-v2 .task-mode-btn.is-on,
html.create-v2-page.create-v2-audio-page .sheet-create-v2 .suno-mode-toggle-v2 .task-mode-btn.is-on {
  color: var(--text) !important;
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55)) !important;
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12)) !important;
  box-shadow: var(--cv2-glow-selected) !important;
}

html.create-v2-page .sheet-create-v2-audio .suno-track-pills-v2 .pill.is-on,
html.create-v2-page.create-v2-audio-page .sheet-create-v2 .suno-track-pills-v2 .pill.is-on {
  color: var(--text) !important;
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55)) !important;
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.14)) !important;
  box-shadow: var(--cv2-glow-selected) !important;
}

.sheet-create-v2-audio .fg-suno-mode-v2 .suno-mode-hint {
  margin: 8px 0 0;
  font-size: 12px;
  line-height: 1.4;
  font-weight: 400;
  color: var(--muted, #a0a0a0);
}

.sheet-create-v2-audio .fg-settings-basic-audio {
  margin-top: 4px;
}

.sheet-create-v2-audio .settings-basic-grid-audio {
  display: grid;
  gap: 16px;
}

.sheet-create-v2-audio .settings-basic-grid-audio .suno-v2-format-quality {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

/* Never place Duration beside Version — keeps left alignment when V5.5 unlocks duration */
.sheet-create-v2-audio .fg-suno-duration-v2[hidden],
.sheet-create-v2-audio .fg-suno-vocal-gender-v2[hidden],
.sheet-create-v2-audio .suno-extras-wrap[hidden],
html.create-v2-page .sheet-create-v2-audio [data-suno-author-field][hidden],
html.create-v2-page .sheet-create-v2-audio [data-suno-duration-field][hidden],
html.create-v2-page .sheet-create-v2-audio [data-suno-vocal-field][hidden] {
  display: none !important;
}

.sheet-create-v2-audio .fg-settings-basic-audio .fg-qty .qty-v2 {
  width: fit-content;
  min-width: 168px;
  max-width: 280px;
}

.sheet-create-v2-audio .fg-settings-basic-audio .fg-qty .qty-v2,
.sheet-create-v2-audio .fg-settings-basic-audio .fg-qty .qty-v2 button {
  min-height: 36px;
  height: 36px;
  box-sizing: border-box;
}

.create-form-v2-audio .create-form-cta-row {
  display: none !important;
}

.suno-track-pills-v2 .pill.is-on {
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.14));
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  color: var(--text);
  box-shadow: var(--cv2-glow-selected);
}

.suno-format-pills-v2 .pill.is-on,
.suno-quality-pills-v2 .pill.is-on,
.suno-vocal-gender-pills-v2 .pill.is-on {
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.14));
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  color: var(--text);
  box-shadow: var(--cv2-accent-glow);
}

.suno-quality-pills-v2 {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.suno-quality-pills-v2 .pill {
  flex: 1 1 140px;
  min-width: 0;
  justify-content: center;
  text-align: center;
}

.el-range {
  margin-bottom: 14px;
}

.el-range-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.el-range-input {
  flex: 1;
  min-width: 0;
  height: 24px;
  accent-color: var(--cv2-accent, #a855f7);
  cursor: pointer;
}

.el-range-value {
  width: 64px;
  min-width: 56px;
  max-width: 68px;
  height: 36px;
  box-sizing: border-box;
  margin: 0;
  padding: 0 8px;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
  border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.12));
  border-radius: var(--cv2-radius-sm, 10px);
  background: var(--cv2-input, rgba(255, 255, 255, 0.04));
  color: var(--text, #fff);
  -moz-appearance: textfield;
  appearance: textfield;
}

.el-range-value::-webkit-outer-spin-button,
.el-range-value::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .el-settings-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 16px;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .el-settings-head .lbl-section-txt {
  font-size: inherit;
  font-weight: inherit;
}

/* Shared Create V2 utility reset (Suno «Сбросить стиль» + ElevenLabs «Сбросить все») */
html.create-v2-page .sheet-create-v2 .cv2-reset-action,
html.create-v2-page .sheet-create-v2 .create-form-v2 .cv2-reset-action,
html.create-v2-page .sheet-create-v2 .create-form-v2 .el-ranges-reset {
  flex-shrink: 0;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  color: var(--muted, #9aa0a6);
  text-decoration: none;
  cursor: pointer;
  opacity: 1;
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .cv2-reset-action:hover:not(:disabled),
html.create-v2-page .sheet-create-v2 .create-form-v2 .cv2-reset-action:hover:not(:disabled),
html.create-v2-page .sheet-create-v2 .create-form-v2 .el-ranges-reset:hover:not(:disabled) {
  color: var(--cv2-utility, var(--neon-blue, #00d4ff));
  background: transparent;
  box-shadow: none;
  filter: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .cv2-reset-action:focus-visible,
html.create-v2-page .sheet-create-v2 .create-form-v2 .cv2-reset-action:focus-visible,
html.create-v2-page .sheet-create-v2 .create-form-v2 .el-ranges-reset:focus-visible {
  outline: none;
  color: var(--cv2-utility, var(--neon-blue, #00d4ff));
  box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.35);
  border-radius: 6px;
}

html.create-v2-page .sheet-create-v2 .cv2-reset-action:disabled,
html.create-v2-page .sheet-create-v2 .create-form-v2 .cv2-reset-action:disabled,
html.create-v2-page .sheet-create-v2 .create-form-v2 .el-ranges-reset:disabled,
html.create-v2-page .sheet-create-v2 .create-form-v2 .el-ranges-reset.is-muted {
  opacity: 0.4;
  cursor: default;
  pointer-events: none;
  color: var(--muted, #9aa0a6);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .el-range-value:focus,
html.create-v2-page .sheet-create-v2 .create-form-v2 .el-range-value:focus-visible {
  outline: none !important;
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  box-shadow: var(--cv2-glow-focus);
}

/* Range fields: no row-level glow; neon on thumb / numeric only */
html.create-v2-page .sheet-create-v2 .create-form-v2 .fg.el-range:focus-within,
html.create-v2-page .sheet-create-v2 .create-form-v2 .el-range:focus-within,
html.create-v2-page .sheet-create-v2 .create-form-v2 .fg.suno-tuning:focus-within,
html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning:focus-within {
  outline: none;
  box-shadow: none;
  border-color: transparent;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input,
html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:focus,
html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:focus-visible,
html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:active,
html.create-v2-page[data-ui-theme="magicbox"] .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:focus,
html.create-v2-page[data-ui-theme="magicbox"] .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:focus-visible {
  outline: none !important;
  box-shadow: none !important;
  border: 0 !important;
  background: transparent;
  accent-color: var(--cv2-accent, #a855f7);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  margin-top: -5px;
  border-radius: 50%;
  border: 2px solid rgba(168, 85, 247, 0.85);
  background: #fff;
  box-shadow: 0 0 0 0 transparent;
  transition: box-shadow 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:hover::-webkit-slider-thumb {
  border-color: rgba(196, 120, 255, 0.95);
  box-shadow: var(--cv2-glow-hover), 0 0 8px rgba(168, 85, 247, 0.35);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:focus-visible::-webkit-slider-thumb {
  border-color: rgba(196, 120, 255, 1);
  box-shadow: var(--cv2-glow-selected), 0 0 0 2px rgba(168, 85, 247, 0.35), 0 0 12px rgba(168, 85, 247, 0.45);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:active::-webkit-slider-thumb {
  transform: scale(1.06);
  box-shadow: var(--cv2-glow-selected), 0 0 0 2px rgba(168, 85, 247, 0.4), 0 0 16px rgba(168, 85, 247, 0.55);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input::-moz-range-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid rgba(168, 85, 247, 0.85);
  background: #fff;
  box-shadow: 0 0 0 0 transparent;
  transition: box-shadow 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:hover::-moz-range-thumb {
  border-color: rgba(196, 120, 255, 0.95);
  box-shadow: var(--cv2-glow-hover), 0 0 8px rgba(168, 85, 247, 0.35);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:focus-visible::-moz-range-thumb {
  border-color: rgba(196, 120, 255, 1);
  box-shadow: var(--cv2-glow-selected), 0 0 0 2px rgba(168, 85, 247, 0.35), 0 0 12px rgba(168, 85, 247, 0.45);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="range"].el-range-input:active::-moz-range-thumb {
  transform: scale(1.06);
  box-shadow: var(--cv2-glow-selected), 0 0 0 2px rgba(168, 85, 247, 0.4), 0 0 16px rgba(168, 85, 247, 0.55);
}

/* Suno advanced: same purple range + numeric chrome as ElevenLabs */
html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning-head {
  width: 100%;
  margin-bottom: 8px;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning-head .suno-tuning-toggle {
  margin-left: auto;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning-range {
  accent-color: var(--cv2-accent, #a855f7);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning .el-range-value {
  background: var(--cv2-input, #0f0f0f);
  color: var(--text, #fff);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning-switch {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.14));
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning-toggle:hover .suno-tuning-switch {
  background: rgba(255, 255, 255, 0.12);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning-enable-cb:checked + .suno-tuning-switch {
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.28));
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  box-shadow: var(--cv2-glow-selected);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning-enable-cb:checked + .suno-tuning-switch::after {
  background: var(--cv2-accent, #a855f7);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning-enable-cb:focus-visible + .suno-tuning-switch {
  box-shadow: var(--cv2-glow-focus);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning.is-disabled .el-range-row {
  opacity: 0.45;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .suno-tuning-endpoints {
  padding-right: 68px;
}

.suno-style-custom-label-row,
.suno-style-preview-head,
.suno-style-section-head {
  display: flex;
  align-items: center;
  gap: 6px;
}

html.create-v2-page .sheet-create-v2-audio .field-help-tip {
  white-space: pre-line;
}

.suno-v2-meta-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 767px) {
  .suno-v2-meta-row {
    grid-template-columns: 1fr 1fr;
  }

  .suno-v2-meta-row .fg-suno-duration-v2 {
    grid-column: 1 / -1;
  }
}

.suno-v2-meta-field,
.fg-suno-duration-v2 {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.suno-v2-meta-label {
  font-size: 13px;
  color: var(--muted, rgba(255, 255, 255, 0.62));
}

.suno-v2-meta-field select,
.fg-suno-duration-v2 select {
  width: 100%;
  padding: 0 36px 0 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: inherit;
  font: inherit;
  line-height: normal;
  box-sizing: border-box;
}

.fg-suno-duration-v2 {
  margin: 0;
}

.suno-v2-format-quality {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.create-form-cta-row {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.create-form-cta-row .fg-qty-cta {
  margin: 0;
}

.create-form-cta-row .fg-qty-cta .lbl {
  display: none;
}

.create-form-cta-row .create-form-cta-gen {
  flex: 1;
  max-width: 420px;
}

/* Mockup polish — bottom of create v2 */
html.create-v2-page .beta-notice {
  display: none;
}

.sheet-create-v2 .fg-prompt-video .prompt-v2-shell {
  margin-bottom: 0;
}

html.create-v2-page .sheet-create-v2-audio .suno-style-chip {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.12));
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2-audio .suno-style-chip:hover {
  border-color: rgba(168, 85, 247, 0.4);
  background: rgba(168, 85, 247, 0.08);
  box-shadow: var(--cv2-glow-hover);
}

html.create-v2-page .sheet-create-v2-audio .suno-style-chip.is-on {
  border-color: var(--cv2-accent-border) !important;
  background: var(--cv2-accent-soft) !important;
  color: #fff !important;
  box-shadow: var(--cv2-glow-selected) !important;
}

html.create-v2-page .sheet-create-v2-audio .suno-style-chip:focus-visible {
  outline: none;
  border-color: var(--cv2-accent-border);
  box-shadow: var(--cv2-glow-focus);
}

html.create-v2-page .sheet-create-v2-audio .fg-settings-advanced[data-suno-extras-wrap] {
  margin-top: 8px;
}

html.create-v2-page .sheet-create-v2-audio .fg-settings-advanced[data-suno-extras-wrap] .settings-advanced-body > .fg:first-child {
  margin-top: 0;
}

html.create-v2-page .sheet-create-v2-audio .suno-extras-wrap {
  margin-top: 12px;
  margin-bottom: 8px;
  border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.1));
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  padding: 0 12px;
}

html.create-v2-page .sheet-create-v2-audio .suno-extras-wrap[hidden] {
  display: none !important;
}

html.create-v2-page .sheet-create-v2-audio .suno-extras-summary {
  cursor: pointer;
  padding: 12px 0;
  font-weight: 600;
  list-style: none;
}

html.create-v2-page .sheet-create-v2-audio .suno-extras-summary::-webkit-details-marker {
  display: none;
}

html.create-v2-page .sheet-create-v2-audio .suno-extras-summary::before {
  content: '▾ ';
  opacity: 0.7;
}

html.create-v2-page .sheet-create-v2-audio .suno-extras-wrap:not([open]) .suno-extras-summary::before {
  content: '▸ ';
}

html.create-v2-page .sheet-create-v2-audio .suno-style-custom-wrap textarea {
  min-height: 64px;
}

.sheet-create-v2 .create-sidebar-stars {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.sheet-create-v2 .aspect-pill.is-on,
.sheet-create-v2 .duration-pills-v2 .pill.is-on,
.sheet-create-v2 .resolution-pills-v2 .pill.is-on {
  border-color: var(--cv2-accent-border);
  background: var(--cv2-accent-soft);
  color: var(--text);
  box-shadow: var(--cv2-glow-selected, var(--cv2-accent-glow));
  transform: none;
}

.fg-settings-basic-video .settings-basic-grid-video {
  grid-template-columns: 1fr;
  gap: 12px;
}

/* Shared Create V2 main settings: Image Aspect|Resolution|Qty, Video Aspect|Duration|Qty */
@media (min-width: 768px) and (max-width: 1099px) {
  .settings-basic-grid-image,
  .settings-basic-grid-video {
    grid-template-columns: minmax(0, 1.4fr) minmax(180px, 1fr);
    column-gap: 20px;
    row-gap: 16px;
    align-items: start;
  }

  .settings-basic-grid-image [data-image-setting-block="aspect_compact"],
  .settings-basic-grid-image [data-image-setting-block="aspect_full"],
  .settings-basic-grid-image [data-image-setting-block="aspect_nano"],
  .settings-basic-grid-video [data-video-setting-block="aspect_video_compact"] {
    grid-column: 1;
    grid-row: 1;
  }

  .settings-basic-grid-image [data-image-setting-block^="image_resolution"],
  .settings-basic-grid-image [data-image-setting-block="resolution"],
  .settings-basic-grid-video [data-video-setting-block="duration"] {
    grid-column: 2;
    grid-row: 1;
  }

  .settings-basic-grid-image [data-image-setting-block="qty"],
  .settings-basic-grid-video [data-video-setting-block="qty"] {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .settings-basic-grid-video [data-video-setting-block="resolution"] {
    grid-column: 1 / -1;
    grid-row: 3;
  }
}

@media (min-width: 1100px) {
  .settings-basic-grid-video {
    grid-template-columns:
      minmax(0, 1.6fr)
      minmax(200px, 0.8fr)
      minmax(200px, 0.8fr);
    column-gap: 24px;
    row-gap: 16px;
    align-items: start;
  }

  .settings-basic-grid-video [data-video-setting-block="aspect_video_compact"] {
    grid-column: 1;
    grid-row: 1;
  }

  .settings-basic-grid-video [data-video-setting-block="duration"] {
    grid-column: 2;
    grid-row: 1;
  }

  .settings-basic-grid-video [data-video-setting-block="qty"] {
    grid-column: 3;
    grid-row: 1;
  }

  .settings-basic-grid-video [data-video-setting-block="resolution"] {
    grid-column: 1;
    grid-row: 2;
  }

  .settings-basic-grid-video .fg-qty .qty-v2 {
    width: fit-content;
    min-width: 168px;
    max-width: 280px;
    flex-wrap: nowrap;
  }

  .settings-basic-grid-video .fg-qty .qty-v2,
  .settings-basic-grid-video .fg-qty .qty-v2 button {
    min-height: 36px;
    height: 36px;
  }
}

@media (min-width: 768px) {
  .create-form-v2-audio .create-form-cta-row {
    display: none !important;
  }
}

.create-mobile-qty {
  flex: 0 0 auto;
  max-width: 140px;
}

.sheet-create-v2-audio .create-mobile-bar-row {
  align-items: center;
  gap: 12px;
}

.sheet-create-v2-audio .create-mobile-gen {
  flex: 1 1 auto;
  max-width: none;
}


/* Final mockup surface polish */
.create-v2-my-works {
  border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.12));
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
  background: var(--cv2-chrome-fill, rgba(20, 20, 24, 0.92));
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.create-v2-my-works-icon {
  font-size: 13px;
  line-height: 1;
  opacity: 0.9;
}

/* Hover/focus for My Works: see html.create-v2-page .sheet-h-create-v2 .create-v2-my-works:* (violet L1). */

.create-sidebar-title {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.create-section-divider {
  margin: var(--cv2-section-gap-y, 20px) 0 var(--cv2-space-16, 16px);
}

.model-row-v2 .model-row-icon {
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.18));
  color: var(--text);
  border: 1px solid rgba(168, 85, 247, 0.28);
}

.model-picker-v2 .model-row-v2 {
  padding: 12px 14px;
  border-radius: var(--cv2-radius-md, 12px);
}

.model-row-v2 .model-row-chev {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  margin-left: 6px;
  opacity: 0.55;
  background: no-repeat center / 10px 10px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%23a0a0a0' d='M1.2 1.2 6 6l4.8-4.8'/%3E%3C/svg%3E");
}


@media (max-width: 767px) {
  .model-row-v2 .model-row-chev {
    display: none;
  }
}

.sheet-create-v2 .create-form-v2 select,
.sheet-create-v2 .create-form-v2 input[type="text"],
.sheet-create-v2 .create-form-v2 input[type="number"] {
  min-height: var(--cv2-field-h, 44px);
  padding: 11px 36px 11px 12px;
  border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.1));
  color: var(--text);
  appearance: none;
  background-color: var(--cv2-input, #0f0f0f);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%23999999' d='M1.2 1.2 6 6l4.8-4.8'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 10px 10px;
  box-shadow: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.sheet-create-v2 .create-form-v2 select:hover,
.sheet-create-v2 .create-form-v2 input[type="text"]:hover,
.sheet-create-v2 .create-form-v2 input[type="number"]:hover {
  border-color: var(--ui-hover-form-border, rgba(168, 85, 247, 0.35));
  box-shadow: var(--ui-hover-form-glow, var(--cv2-glow-hover));
}

.sheet-create-v2 .create-form-v2 select:focus,
.sheet-create-v2 .create-form-v2 input[type="text"]:focus,
.sheet-create-v2 .create-form-v2 input[type="number"]:focus {
  outline: none;
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  box-shadow: var(--cv2-glow-focus, 0 0 0 1px rgba(168, 85, 247, 0.16), 0 0 10px rgba(168, 85, 247, 0.08));
}

/* Audio/legacy textareas: same neon focus as Video .prompt-v2-shell (not theme white/cyan ring) */
html.create-v2-page .sheet-create-v2 .create-form-v2 textarea:not(.prompt-v2-shell textarea) {
  border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.1));
  background: var(--cv2-input, #0f0f0f);
  border-radius: 12px;
  box-shadow: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 textarea:not(.prompt-v2-shell textarea):hover {
  border-color: var(--ui-hover-form-border, rgba(168, 85, 247, 0.35));
  box-shadow: var(--ui-hover-form-glow, var(--cv2-glow-hover));
}

html.create-v2-page .sheet-create-v2 .create-form-v2 textarea:not(.prompt-v2-shell textarea):focus,
html.create-v2-page .sheet-create-v2 .create-form-v2 textarea:not(.prompt-v2-shell textarea):focus-visible,
html.create-v2-page[data-ui-theme="magicbox"] .sheet-create-v2 .create-form-v2 textarea:not(.prompt-v2-shell textarea):focus,
html.create-v2-page[data-ui-theme="magicbox"] .sheet-create-v2 .create-form-v2 textarea:not(.prompt-v2-shell textarea):focus-visible {
  outline: none !important;
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55)) !important;
  box-shadow: var(--cv2-glow-focus) !important;
}

html.create-v2-page .sheet-create-v2 .field-clear-btn {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.12));
  color: var(--muted, #a0a0a0);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: none;
  transform: none;
  transition: var(--ui-transition-quiet, background 0.15s ease, color 0.15s ease, border-color 0.15s ease);
}

/* Quiet chrome hover/focus for clear × lives in interaction.css */

.sheet-create-v2 .create-form-v2 input[type="text"],
.sheet-create-v2 .create-form-v2 input[type="number"] {
  padding-right: 12px;
  background-image: none;
}

.sheet-create-v2 .prompt-chip {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.1));
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  padding: 6px 12px;
  font-weight: 500;
  transition: border-color 0.15s, background 0.15s, color 0.15s, box-shadow 0.15s;
}

.sheet-create-v2 .prompt-chip:hover {
  border-color: rgba(168, 85, 247, 0.4);
  background: rgba(168, 85, 247, 0.06);
  box-shadow: var(--cv2-glow-hover);
}

/* Prompt chips insert text — no persistent selected glow after click */
.sheet-create-v2 .prompt-chip.is-on,
.sheet-create-v2 .prompt-chip.is-active {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
  box-shadow: none;
}

.sheet-create-v2 .qty-v2 {
  border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.12));
  border-radius: var(--cv2-radius-md, 12px);
  background: var(--cv2-input, #0f0f0f);
  overflow: hidden;
  max-width: var(--cv2-qty-max-w, 220px);
  height: var(--cv2-control-h, 36px);
  min-height: var(--cv2-control-h, 36px);
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
}

.sheet-create-v2 .qty-v2 button {
  width: 42px;
  height: var(--cv2-control-h, 36px);
  min-height: var(--cv2-control-h, 36px);
  border: 0;
  background: transparent;
  color: var(--text);
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  padding: 0;
  flex: 0 0 auto;
}

.sheet-create-v2 .qty-v2 button:hover {
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
  color: var(--text);
  box-shadow: var(--cv2-glow-hover);
}

.sheet-create-v2 .qty-v2 button:active {
  background: rgba(168, 85, 247, 0.14);
  color: #fff;
}

.sheet-create-v2 .qty-v2 span[data-qty-val] {
  min-width: 72px;
  padding: 0 6px;
  border-left: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.08));
  border-right: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.08));
  color: #fff;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: stretch;
  line-height: 1.2;
  box-sizing: border-box;
  text-align: center;
}

.sheet-create-v2 .gen.create-sidebar-gen,
.sheet-create-v2 .gen.create-form-cta-gen,
.sheet-create-v2 .gen.create-mobile-summary-gen,
.sheet-create-v2 .gen.create-mobile-gen {
  border-radius: var(--cv2-radius-md, 12px);
  font-weight: 700;
  letter-spacing: -0.01em;
  box-shadow: var(--cv2-glow-cta, 0 0 18px rgba(0, 212, 255, 0.22), 0 0 28px rgba(168, 85, 247, 0.28));
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.sheet-create-v2 .gen.create-sidebar-gen:hover,
.sheet-create-v2 .gen.create-form-cta-gen:hover,
.sheet-create-v2 .gen.create-mobile-summary-gen:hover,
.sheet-create-v2 .gen.create-mobile-gen:hover {
  box-shadow: var(--cv2-glow-cta-hover, 0 0 24px rgba(0, 212, 255, 0.3), 0 0 36px rgba(168, 85, 247, 0.34));
  filter: brightness(1.06);
  transform: translateY(-1px);
}

.sheet-create-v2 .gen.create-sidebar-gen:active,
.sheet-create-v2 .gen.create-form-cta-gen:active,
.sheet-create-v2 .gen.create-mobile-summary-gen:active,
.sheet-create-v2 .gen.create-mobile-gen:active {
  box-shadow: 0 0 12px rgba(168, 85, 247, 0.2);
  filter: brightness(0.96);
  transform: translateY(1px);
}

.sheet-create-v2 .gen.create-sidebar-gen:disabled,
.sheet-create-v2 .gen.create-form-cta-gen:disabled,
.sheet-create-v2 .gen.create-mobile-summary-gen:disabled,
.sheet-create-v2 .gen.create-mobile-gen:disabled {
  box-shadow: none;
  filter: saturate(0.45) brightness(0.72);
  transform: none;
}

.sheet-create-v2 .field-max {
  color: #67e8f9;
  font-weight: 500;
}

.sheet-create-v2 .prompt-v2-footer .field-char,
.sheet-create-v2 .fg-prompt-v2 .field-char {
  color: rgba(103, 232, 249, 0.72);
}

.video-setting-row-chevron {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid var(--cv2-border, rgba(255, 255, 255, 0.14));
  font-size: 16px;
  color: var(--muted);
}

.video-setting-row:hover .video-setting-row-chevron {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.45));
  color: var(--cv2-accent, #a855f7);
}

.sheet-create-v2 .create-sidebar-stars {
  font-size: 19px;
}

.sheet-create-v2 .fg-upload-start-frame .upload-v2-hint,
.sheet-create-v2 .fg-upload-v2 .upload-v2-hint {
  margin-top: 8px;
  font-size: 12px;
  line-height: 1.4;
  font-weight: 400;
  color: var(--muted, #a0a0a0);
}

.sheet-create-v2 .settings-basic-grid [data-resolution-v2="1"] select {
  font-variant-numeric: tabular-nums;
}

.sheet-create-v2 .create-sidebar-preview {
  border-style: solid;
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.1));
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--cv2-radius-md, 12px);
}

.sheet-create-v2 .aspect-pill-auto.is-on .aspect-pill-icon {
  color: var(--cv2-accent, #a855f7);
}



.model-picker-v2-row-shared .model-row-v2 {
  width: 100%;
}

@media (max-width: 767px) {
  .sheet-create-v2 .prompt-chips {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 2px;
  }

  .sheet-create-v2 .prompt-chips::-webkit-scrollbar {
    display: none;
  }

  .sheet-create-v2 .prompt-chip,
  .sheet-create-v2 .prompt-examples-more {
    flex: 0 0 auto;
  }

  .sheet-create-v2 .aspect-pills-compact {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 2px;
    gap: 8px;
  }

  .sheet-create-v2 .aspect-pills-compact::-webkit-scrollbar {
    display: none;
  }

  .sheet-create-v2 .aspect-pill {
    flex: 0 0 auto;
  }

  .sheet-create-v2 .aspect-pill-hint {
    display: none;
  }

}

/* =============================================================================
   Create v2 shared — glow hierarchy (L0–L3)
   Neon is brand language; intensity encodes UX state.
   Load order in public/app/index.php:
     app.css → interaction-tokens.css → create_v2.css → cabinet.css → theme-magicbox.css → interaction.css
   Dock interaction lives in interaction.css (late) using --ui-dock-* surface tokens.
   ============================================================================= */

html.create-v2-page {
  --cv2-glow-ambient: 0 0 6px rgba(168, 85, 247, 0.05);
  --cv2-glow-selected: var(--ui-selected-glow, 0 0 0 1px rgba(168, 85, 247, 0.14), 0 0 12px rgba(168, 85, 247, 0.18));
  --cv2-glow-nav-selected: 0 0 0 1px rgba(168, 85, 247, 0.1), 0 0 8px rgba(168, 85, 247, 0.12);
  --cv2-glow-cta: 0 0 18px rgba(0, 212, 255, 0.22), 0 0 28px rgba(168, 85, 247, 0.28);
  --cv2-glow-cta-hover: 0 0 22px rgba(0, 212, 255, 0.3), 0 0 36px rgba(168, 85, 247, 0.36);
  --cv2-glow-cta-secondary: 0 0 12px rgba(0, 212, 255, 0.14), 0 0 18px rgba(168, 85, 247, 0.18);
  --cv2-glow-cta-secondary-hover: 0 0 16px rgba(0, 212, 255, 0.2), 0 0 24px rgba(168, 85, 247, 0.24);
  --cv2-glow-topup: 0 0 10px rgba(168, 85, 247, 0.14);
  --cv2-glow-topup-hover: 0 0 14px rgba(168, 85, 247, 0.2);
  --cv2-glow-error: 0 0 0 1px rgba(255, 77, 94, 0.2), 0 0 10px rgba(255, 77, 94, 0.12);
  --cv2-accent-border: rgba(168, 85, 247, 0.55);
  --cv2-accent-soft: rgba(168, 85, 247, 0.12);
  --cv2-utility: var(--neon-blue, #00d4ff);
}

/* --- 5. Top nav: shared MagicBox pill (theme-magicbox.css .menu a) — no create-only underline --- */
/* --- 6. Type tabs Image / Video / Audio --- */
html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab:hover {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  transform: none;
  color: var(--text, #fff);
}

html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab.is-on {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  transform: none;
  color: var(--text, #fff);
}

html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab i {
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab:hover i {
  border-color: rgba(168, 85, 247, 0.35);
  background: var(--cv2-input, var(--surface-5));
  box-shadow: var(--cv2-glow-hover) !important;
  transform: none !important;
}

html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab.is-on i {
  border-color: var(--cv2-accent-border) !important;
  background: var(--cv2-accent-soft) !important;
  box-shadow: var(--cv2-glow-selected) !important;
  transform: none !important;
  color: #fff;
}

@media (max-width: 767px) {
  html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab {
    border: 1px solid var(--cv2-border, var(--border));
    background: var(--cv2-input, var(--surface-4));
    box-shadow: none;
  }

  html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab:hover {
    border-color: rgba(168, 85, 247, 0.35);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: var(--cv2-glow-hover);
  }

  html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab.is-on {
    border-color: var(--cv2-accent-border);
    background: var(--cv2-accent-soft);
    box-shadow: var(--cv2-glow-selected);
  }

  html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab i,
  html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab:hover i,
  html.create-v2-page .sheet-create-v2 .create-v2-ctabs .ctab.is-on i {
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }
}

/* --- 7. Model trigger --- */
html.create-v2-page .sheet-create-v2 .model-picker-v2 .model-row-v2 {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.1));
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .model-picker-v2 .model-row-v2:hover {
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: var(--cv2-glow-hover);
  transform: none;
}

html.create-v2-page .sheet-create-v2 .model-picker-v2 .model-row-v2:focus-visible {
  border-color: var(--cv2-accent-border);
  box-shadow: var(--cv2-glow-focus);
  outline: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .model-picker-v2 .model-row-v2[aria-expanded="true"] {
  border-color: var(--cv2-accent-border);
  box-shadow: var(--cv2-glow-focus);
  transform: none;
}

/* --- 8. Model list options --- */
html.create-v2-page .model-sheet-v2 .model-opt:not(.is-locked):not(.is-on) {
  box-shadow: none;
  transform: none;
}

html.create-v2-page .model-sheet-v2 .model-opt:not(.is-locked):hover {
  border-color: rgba(168, 85, 247, 0.4) !important;
  background: rgba(168, 85, 247, 0.08);
  box-shadow: var(--cv2-glow-hover) !important;
  transform: none !important;
  color: #fff;
}

html.create-v2-page .model-sheet-v2 .model-opt.is-on {
  border-color: var(--cv2-accent-border) !important;
  background: var(--cv2-accent-soft) !important;
  box-shadow: var(--cv2-glow-selected) !important;
  transform: none !important;
  color: #fff !important;
}

html.create-v2-page .model-sheet-v2 .model-opt.is-on:hover {
  border-color: var(--cv2-accent-border) !important;
  background: rgba(168, 85, 247, 0.16) !important;
  box-shadow: var(--cv2-glow-selected) !important;
}

/* --- 9. Start-frame / reference upload --- */
html.create-v2-page .sheet-create-v2 .upload-dropzone-start-frame,
html.create-v2-page .sheet-create-v2 .upload-dropzone-ref,
html.create-v2-page .sheet-create-v2 .upload-dropzone {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.14));
  background: var(--cv2-dropzone-bg, rgba(255, 255, 255, 0.02));
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .upload-dropzone-start-frame:hover,
html.create-v2-page .sheet-create-v2 .upload-dropzone-ref:hover,
html.create-v2-page .sheet-create-v2 .upload-dropzone:hover {
  border-color: rgba(168, 85, 247, 0.35);
  box-shadow: var(--cv2-glow-hover);
}

html.create-v2-page .sheet-create-v2 .upload-dropzone-start-frame.is-drag,
html.create-v2-page .sheet-create-v2 .upload-dropzone-ref.is-drag,
html.create-v2-page .sheet-create-v2 .upload-dropzone.is-drag {
  border-color: var(--cv2-accent-border);
  border-style: dashed;
  background: rgba(168, 85, 247, 0.1);
  box-shadow: var(--cv2-glow-selected);
}

/* --- 10. Prompt shell --- */
html.create-v2-page .sheet-create-v2 .prompt-v2-shell {
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .prompt-v2-shell:hover {
  border-color: var(--cv2-hover-border, rgba(255, 255, 255, 0.18));
  box-shadow: var(--cv2-glow-hover);
}

html.create-v2-page .sheet-create-v2 .prompt-v2-shell:focus-within {
  border-color: var(--cv2-accent-border);
  box-shadow: var(--cv2-glow-focus);
}

html.create-v2-page .sheet-create-v2 .prompt-v2-shell.is-error,
html.create-v2-page .sheet-create-v2 .prompt-v2-shell.is-error:hover,
html.create-v2-page .sheet-create-v2 .prompt-v2-shell.is-error:focus-within {
  border-color: rgba(255, 77, 94, 0.65);
  box-shadow: var(--cv2-glow-error);
}

/* --- 11. Secondary: Examples / Improve --- */
html.create-v2-page .sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo) {
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo):hover {
  border-color: rgba(168, 85, 247, 0.4);
  background: rgba(168, 85, 247, 0.08);
  box-shadow: var(--cv2-glow-hover);
  transform: none;
}

html.create-v2-page .sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo):focus-visible {
  border-color: var(--cv2-accent-border);
  box-shadow: var(--cv2-glow-focus);
  outline: none;
}

html.create-v2-page .sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo):active {
  border-color: var(--cv2-accent-border);
  background: rgba(168, 85, 247, 0.14);
  box-shadow: var(--cv2-glow-selected);
}

/* --- 12. Prompt presets (insert text — no persistent selected) --- */
html.create-v2-page .sheet-create-v2 .prompt-chip,
html.create-v2-page .sheet-create-v2 .prompt-examples-more,
html.create-v2-page .sheet-create-v2 .prompt-example-item {
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .prompt-chip:hover,
html.create-v2-page .sheet-create-v2 .prompt-examples-more:hover,
html.create-v2-page .sheet-create-v2 .prompt-example-item:hover {
  border-color: rgba(168, 85, 247, 0.4);
  background: rgba(168, 85, 247, 0.08);
  box-shadow: var(--cv2-glow-hover);
  transform: none;
}

html.create-v2-page .sheet-create-v2 .prompt-chip:focus-visible,
html.create-v2-page .sheet-create-v2 .prompt-examples-more:focus-visible,
html.create-v2-page .sheet-create-v2 .prompt-example-item:focus-visible {
  border-color: var(--cv2-accent-border);
  box-shadow: var(--cv2-glow-focus);
  outline: none;
}

html.create-v2-page .sheet-create-v2 .prompt-chip:active,
html.create-v2-page .sheet-create-v2 .prompt-examples-more:active,
html.create-v2-page .sheet-create-v2 .prompt-example-item:active {
  border-color: var(--cv2-accent-border);
  background: rgba(168, 85, 247, 0.14);
  box-shadow: var(--cv2-glow-selected);
}

/* Insert-text chips (data-prompt-chip / data-motion-chip): no persistent selected.
   True toggle presets must omit those attrs (or use a non-insert class) to keep L2. */
html.create-v2-page .sheet-create-v2 .prompt-chip[data-prompt-chip].is-on,
html.create-v2-page .sheet-create-v2 .prompt-chip[data-prompt-chip].is-active,
html.create-v2-page .sheet-create-v2 .prompt-chip[data-motion-chip].is-on,
html.create-v2-page .sheet-create-v2 .prompt-chip[data-motion-chip].is-active {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.1));
  background: rgba(255, 255, 255, 0.04);
  box-shadow: none;
}

html.create-v2-page .sheet-create-v2 .prompt-chip.is-on:not([data-prompt-chip]):not([data-motion-chip]),
html.create-v2-page .sheet-create-v2 .prompt-chip.is-active:not([data-prompt-chip]):not([data-motion-chip]) {
  border-color: var(--cv2-accent-border);
  background: var(--cv2-accent-soft);
  box-shadow: var(--cv2-glow-selected);
  color: #fff;
}

/* --- 13. Aspect ratio (+ other true selected pills) --- */
html.create-v2-page .sheet-create-v2 .aspect-pill:not(.is-on),
html.create-v2-page .sheet-create-v2 .pill:not(.is-on) {
  box-shadow: none !important;
  transform: none !important;
}

html.create-v2-page .sheet-create-v2 .aspect-pill:not(.is-on):hover,
html.create-v2-page .sheet-create-v2 .pill:not(.is-on):hover {
  border-color: rgba(168, 85, 247, 0.4) !important;
  background: rgba(168, 85, 247, 0.06) !important;
  box-shadow: var(--cv2-glow-hover) !important;
  transform: none !important;
  color: #fff;
}

html.create-v2-page .sheet-create-v2 .aspect-pill:not(.is-on):focus-visible,
html.create-v2-page .sheet-create-v2 .pill:not(.is-on):focus-visible {
  border-color: var(--cv2-accent-border) !important;
  box-shadow: var(--cv2-glow-focus) !important;
  outline: none;
  transform: none !important;
}

html.create-v2-page .sheet-create-v2 .aspect-pill.is-on,
html.create-v2-page .sheet-create-v2 .pill.is-on {
  border-color: var(--cv2-accent-border) !important;
  background: var(--cv2-accent-soft) !important;
  color: #fff !important;
  box-shadow: var(--cv2-glow-selected) !important;
  transform: none !important;
}

html.create-v2-page .sheet-create-v2 .aspect-pill.is-on:hover,
html.create-v2-page .sheet-create-v2 .pill.is-on:hover {
  border-color: var(--cv2-accent-border) !important;
  background: rgba(168, 85, 247, 0.16) !important;
  box-shadow: var(--cv2-glow-selected) !important;
  transform: none !important;
}

html.create-v2-page .sheet-create-v2 .aspect-pill.is-on:focus-visible,
html.create-v2-page .sheet-create-v2 .pill.is-on:focus-visible {
  border-color: var(--cv2-accent-border) !important;
  box-shadow: var(--cv2-glow-selected), 0 0 0 2px rgba(168, 85, 247, 0.22) !important;
  outline: none;
  transform: none !important;
}
/* --- 14. Duration / Resolution selects --- */
html.create-v2-page .sheet-create-v2 .create-form-v2 select {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.1));
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 select:hover {
  border-color: rgba(168, 85, 247, 0.4);
  box-shadow: var(--cv2-glow-hover);
  transform: none;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 select:focus,
html.create-v2-page .sheet-create-v2 .create-form-v2 select:focus-visible {
  border-color: var(--cv2-accent-border) !important;
  box-shadow: var(--cv2-glow-focus) !important;
  outline: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="text"],
html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="number"] {
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="text"]:hover,
html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="number"]:hover {
  border-color: rgba(168, 85, 247, 0.4);
  box-shadow: var(--cv2-glow-hover);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="text"]:focus,
html.create-v2-page .sheet-create-v2 .create-form-v2 input[type="number"]:focus {
  border-color: var(--cv2-accent-border) !important;
  box-shadow: var(--cv2-glow-focus) !important;
  outline: none;
}

/* --- 15. Quantity stepper --- */
html.create-v2-page .sheet-create-v2 .qty-v2 {
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.12));
  box-shadow: none;
}

html.create-v2-page .sheet-create-v2 .qty-v2 button {
  box-shadow: none;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .qty-v2 button:hover {
  background: rgba(168, 85, 247, 0.08);
  color: #fff;
  box-shadow: var(--cv2-glow-hover);
}

html.create-v2-page .sheet-create-v2 .qty-v2 button:focus-visible {
  box-shadow: var(--cv2-glow-focus);
  outline: none;
}

html.create-v2-page .sheet-create-v2 .qty-v2 button:active {
  background: rgba(168, 85, 247, 0.16);
  color: #fff;
  box-shadow: var(--cv2-glow-selected);
}

/* Field help ? sits next to label text (Suno .lbl pattern), never at row end */
html.create-v2-page .sheet-create-v2 .lbl {
  justify-content: flex-start;
  gap: 6px;
}

html.create-v2-page .sheet-create-v2 .lbl > .help-wrap {
  margin-left: 0;
  margin-right: 0;
}

/* Help ? — muted → cyan (utility), not purple CTA */
html.create-v2-page .sheet-create-v2 .create-form-v2 button.help {
  color: var(--muted, #9aa0a6);
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.14));
  background: rgba(255, 255, 255, 0.04);
  box-shadow: none;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 button.help:hover,
html.create-v2-page .sheet-create-v2 .create-form-v2 button.help:focus-visible,
html.create-v2-page[data-ui-theme="magicbox"] .sheet-create-v2 .create-form-v2 button.help:hover,
html.create-v2-page[data-ui-theme="magicbox"] .sheet-create-v2 .create-form-v2 button.help:focus-visible {
  color: var(--cv2-utility, var(--neon-blue, #00d4ff));
  border-color: rgba(0, 212, 255, 0.55);
  background: rgba(0, 212, 255, 0.08);
  box-shadow: 0 0 8px rgba(0, 212, 255, 0.22);
  outline: none;
}

/* --- 16. Advanced settings accordion --- */
html.create-v2-page .sheet-create-v2 .fg-settings-advanced {
  border-color: var(--cv2-border, var(--border));
  box-shadow: none;
}

html.create-v2-page .sheet-create-v2 .fg-settings-advanced:hover {
  border-color: rgba(168, 85, 247, 0.35);
  box-shadow: var(--cv2-glow-hover);
}

html.create-v2-page .sheet-create-v2 .fg-settings-advanced[open] {
  border-color: rgba(168, 85, 247, 0.28);
  background: rgba(168, 85, 247, 0.04);
  box-shadow: var(--cv2-glow-ambient);
}

html.create-v2-page .sheet-create-v2 .fg-settings-advanced summary:focus {
  outline: none;
}

html.create-v2-page .sheet-create-v2 .fg-settings-advanced summary:focus-visible {
  outline: none;
  border-radius: 8px;
  box-shadow: var(--cv2-glow-focus, var(--ui-focus-glow));
  /* Ensure keyboard focus is visible even when summary has no border */
  background: rgba(168, 85, 247, 0.06);
}

html.create-v2-page .sheet-create-v2 .fg-settings-advanced .settings-advanced-body > .el-range:last-child,
html.create-v2-page .sheet-create-v2 .fg-settings-advanced .settings-advanced-body > .suno-tuning:last-child,
html.create-v2-page .sheet-create-v2 .fg-settings-advanced .suno-advanced-inner > .suno-tuning:last-child {
  margin-bottom: 0;
}

/* --- 17. Parameters card — ambient only (all Create v2) --- */
html.create-v2-page .create-sidebar-inner,
html.create-v2-page .create-sidebar-inner,
html.create-v2-page .sheet-create-v2 .create-sidebar-inner {
  border-color: rgba(168, 85, 247, 0.16) !important;
  box-shadow: 0 0 16px rgba(168, 85, 247, 0.035) !important;
}

/* --- 18. My works (shared Create V2 header chrome — Video is source of truth) --- */
html.create-v2-page .sheet-h-create-v2 .create-v2-my-works {
  box-shadow: none !important;
  transform: none !important;
  background: var(--cv2-chrome-fill, rgba(20, 20, 24, 0.92)) !important;
}

html.create-v2-page .sheet-h-create-v2 .create-v2-my-works:hover {
  border-color: rgba(168, 85, 247, 0.4) !important;
  background: rgba(168, 85, 247, 0.06) !important;
  color: var(--text, #fff) !important;
  box-shadow: var(--cv2-glow-hover) !important;
  transform: none !important;
}

html.create-v2-page .sheet-h-create-v2 .create-v2-my-works:focus-visible {
  border-color: var(--cv2-accent-border) !important;
  box-shadow: var(--cv2-glow-focus) !important;
  outline: none;
  transform: none !important;
}

/* --- 19. Close button (shared; secondary glow — not stronger than selected/CTA) --- */
html.create-v2-page .sheet-h-create-v2 .sheet-h-close,
html.create-v2-page .sheet-create-v2 .aspect-all-h .x,
html.create-v2-page .sheet-create-v2 .prompt-examples-h .x {
  box-shadow: none !important;
  transform: none !important;
}

html.create-v2-page .sheet-h-create-v2 .sheet-h-close:hover,
html.create-v2-page .sheet-create-v2 .aspect-all-h .x:hover,
html.create-v2-page .sheet-create-v2 .prompt-examples-h .x:hover {
  border-color: rgba(168, 85, 247, 0.4) !important;
  background: rgba(168, 85, 247, 0.08) !important;
  color: #fff !important;
  box-shadow: var(--cv2-glow-hover) !important;
  transform: none !important;
}

html.create-v2-page .sheet-h-create-v2 .sheet-h-close:focus-visible,
html.create-v2-page .sheet-create-v2 .aspect-all-h .x:focus-visible,
html.create-v2-page .sheet-create-v2 .prompt-examples-h .x:focus-visible {
  border-color: var(--cv2-accent-border) !important;
  box-shadow: var(--cv2-glow-focus) !important;
  outline: none;
  transform: none !important;
}

html.create-v2-page .sheet-h-create-v2 .sheet-h-close:active,
html.create-v2-page .sheet-create-v2 .aspect-all-h .x:active,
html.create-v2-page .sheet-create-v2 .prompt-examples-h .x:active {
  box-shadow: var(--cv2-glow-selected) !important;
}

/* Dock must sit above page fields (textarea focus ring) and below modals (80+) */
html.create-v2-page .dock,
html.create-v2-page[data-ui-theme="magicbox"] .dock {
  z-index: 60;
  isolation: isolate;
}

/* Dock hover/focus/active/is-on: interaction.css (late cascade, shared --ui-dock-* tokens) */

/* --- 21. + Create (secondary CTA) --- */
html.create-v2-page .dock .go {
  box-shadow: var(--cv2-glow-cta-secondary) !important;
  filter: brightness(0.94);
  transform: none;
}

html.create-v2-page .dock .go:hover {
  box-shadow: var(--cv2-glow-cta-secondary-hover) !important;
  filter: brightness(1);
  transform: translateY(-1px);
}

html.create-v2-page .dock .go:active {
  box-shadow: var(--cv2-glow-cta-secondary) !important;
  filter: brightness(0.96);
  transform: translateY(0);
}

/* --- 22. Topup (tertiary CTA) --- */
html.create-v2-page .bal-topup,
html.create-v2-page .buy {
  box-shadow: var(--cv2-glow-topup) !important;
}

html.create-v2-page .bal-topup:hover,
html.create-v2-page .buy:hover {
  box-shadow: var(--cv2-glow-topup-hover) !important;
  filter: brightness(1.03);
  transform: translateY(-1px);
}

/* --- 23. RU / EN — yellow semantic, no purple neon --- */
html.create-v2-page .lang-switch a {
  box-shadow: none !important;
  transform: none !important;
}

html.create-v2-page .lang-switch a:hover,
html.create-v2-page .lang-switch a:focus-visible {
  box-shadow: none !important;
  transform: none !important;
}

html.create-v2-page .lang-switch a.is-on {
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.18) !important;
  transform: none !important;
}

html.create-v2-page .lang-switch a.is-on:hover {
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.22) !important;
  transform: none !important;
}

/* Header chrome: keep L1 soft, no legacy CTA-strength glow */
html.create-v2-page .theme-toggle:hover,
html.create-v2-page .help-ico:hover,
html.create-v2-page .bal:hover,
html.create-v2-page .ava:hover,
html.create-v2-page .h-row > a:hover {
  border-color: rgba(168, 85, 247, 0.35) !important;
  background: rgba(168, 85, 247, 0.06) !important;
  box-shadow: var(--cv2-glow-hover) !important;
  transform: none !important;
}

html.create-v2-page .theme-toggle:focus-visible,
html.create-v2-page .help-ico:focus-visible,
html.create-v2-page .bal:focus-visible,
html.create-v2-page .ava:focus-visible,
html.create-v2-page .h-row > a:focus-visible {
  border-color: var(--cv2-accent-border) !important;
  box-shadow: var(--cv2-glow-focus) !important;
  transform: none !important;
  outline: none;
}

/* Account menu — MagicBox / Create V2 chrome (shared header) */
html.create-v2-page .account-menu-panel {
  background: var(--cv2-input, #0f0f0f);
  border-color: var(--cv2-border, rgba(255, 255, 255, 0.12));
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.55), var(--cv2-glow-ambient);
}

html.create-v2-page .account-menu-item:hover {
  background: rgba(168, 85, 247, 0.08);
}

html.create-v2-page .account-menu-item:focus-visible {
  background: rgba(168, 85, 247, 0.12);
  box-shadow: var(--cv2-glow-focus);
}

html.create-v2-page .account-menu-item.is-on {
  background: var(--hover, rgba(168, 85, 247, 0.1));
}

html.create-v2-page .account-menu-item--logout:hover,
html.create-v2-page .account-menu-item--logout:focus-visible {
  color: #ff6b7a;
  background: rgba(255, 77, 94, 0.1);
}

/* --- 24 + 25. Primary CTA + disabled --- */
html.create-v2-page .sheet-create-v2 .gen.create-sidebar-gen,
html.create-v2-page .sheet-create-v2 .gen.create-form-cta-gen,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-summary-gen,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-gen {
  box-shadow: var(--cv2-glow-cta) !important;
  transform: none;
}

html.create-v2-page .sheet-create-v2 .gen.create-sidebar-gen:hover,
html.create-v2-page .sheet-create-v2 .gen.create-form-cta-gen:hover,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-summary-gen:hover,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-gen:hover {
  box-shadow: var(--cv2-glow-cta-hover) !important;
  filter: brightness(1.06);
  transform: translateY(-1px);
}

html.create-v2-page .sheet-create-v2 .gen.create-sidebar-gen:focus-visible,
html.create-v2-page .sheet-create-v2 .gen.create-form-cta-gen:focus-visible,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-summary-gen:focus-visible,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-gen:focus-visible {
  box-shadow: var(--cv2-glow-cta-hover) !important;
  outline: none;
}

html.create-v2-page .sheet-create-v2 .gen.create-sidebar-gen:active,
html.create-v2-page .sheet-create-v2 .gen.create-form-cta-gen:active,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-summary-gen:active,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-gen:active {
  box-shadow: 0 0 12px rgba(168, 85, 247, 0.22) !important;
  filter: brightness(0.96);
  transform: translateY(1px);
}

html.create-v2-page .sheet-create-v2 .gen.create-sidebar-gen:disabled,
html.create-v2-page .sheet-create-v2 .gen.create-form-cta-gen:disabled,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-summary-gen:disabled,
html.create-v2-page .sheet-create-v2 .gen.create-mobile-gen:disabled,
html.create-v2-page .sheet-create-v2 .create-form-v2.is-insufficient-balance .create-sidebar-gen,
html.create-v2-page .sheet-create-v2 .create-form-v2.is-insufficient-balance .create-mobile-gen,
html.create-v2-page .sheet-create-v2 .create-form-v2.is-insufficient-balance .create-mobile-summary-gen {
  opacity: 0.45 !important;
  box-shadow: none !important;
  filter: none !important;
  transform: none !important;
  cursor: not-allowed;
}

html.create-v2-page .sheet-create-v2 .qty-v2 button:disabled,
html.create-v2-page .sheet-create-v2 .prompt-v2-actions .btn-chip:disabled,
html.create-v2-page .sheet-create-v2 .aspect-pill:disabled,
html.create-v2-page .sheet-create-v2 select:disabled {
  opacity: 0.45;
  box-shadow: none !important;
  cursor: not-allowed;
  filter: none;
}

/* =============================================================================
   Shared main-settings geometry (Image + Video)
   Labels share one vertical slot; controls share one top line; helpers grow down.
   Resolution/Duration selects must beat generic .create-form-v2 select (44px).
   ============================================================================= */
html.create-v2-page .sheet-create-v2 .settings-basic-grid {
  align-items: start;
}

html.create-v2-page .sheet-create-v2 .settings-basic-grid > .image-setting-block,
html.create-v2-page .sheet-create-v2 .settings-basic-grid > .video-setting-block {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  min-width: 0;
}

html.create-v2-page .sheet-create-v2 .settings-basic-grid .fg {
  margin-bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  min-width: 0;
  width: 100%;
}

html.create-v2-page .sheet-create-v2 .settings-basic-grid .lbl {
  margin: 0 0 8px;
  padding: 0;
  font-size: 13px;
  /* Aspect/Quantity (plain .lbl text) compute ~20px; Duration wraps .lbl-txt at 13×1.2=15.6. */
  line-height: 20px;
  min-height: 20px;
  font-weight: 400;
  align-items: center;
  box-sizing: border-box;
}

html.create-v2-page .sheet-create-v2 .settings-basic-grid .lbl-txt {
  display: inline;
  font-size: inherit;
  line-height: inherit;
}

html.create-v2-page .sheet-create-v2 .settings-basic-grid [data-resolution-v2="1"] select,
html.create-v2-page .sheet-create-v2 .settings-basic-grid [data-duration-v2="1"] select,
html.create-v2-page .sheet-create-v2 .settings-basic-grid-video [data-video-setting-block="resolution"] select,
html.create-v2-page .sheet-create-v2 .settings-basic-grid-image [data-resolution-picker-v2="1"] .resolution-picker-v2-btn {
  height: var(--cv2-control-h, 36px);
  min-height: var(--cv2-control-h, 36px);
  max-height: var(--cv2-control-h, 36px);
  padding-top: 0;
  padding-bottom: 0;
  padding-left: 12px;
  padding-right: 36px;
  line-height: normal;
  box-sizing: border-box;
}

html.create-v2-page .sheet-create-v2 .settings-basic-grid .qty-v2,
html.create-v2-page .sheet-create-v2 .settings-basic-grid .qty-v2 button {
  min-height: var(--cv2-control-h, 36px);
  height: var(--cv2-control-h, 36px);
  box-sizing: border-box;
}

html.create-v2-page .sheet-create-v2 .settings-basic-grid .select-option-hint,
html.create-v2-page .sheet-create-v2 .settings-basic-grid .qty-v2-hint {
  margin-top: 6px;
  font-size: var(--cv2-helper-size, 12px);
  line-height: 1.35;
  font-weight: 400;
  color: var(--muted, #9aa0a6);
}

/* =============================================================================
   Create V2 visual consistency — shared primitives (Photo / Video / Audio / Tools)
   ============================================================================= */

html.create-v2-page .sheet-create-v2 .create-form-v2 .fg > .lbl,
html.create-v2-page .sheet-create-v2 .create-form-v2 .lbl {
  font-size: var(--cv2-label-size, 13px);
  font-weight: 400;
  color: var(--muted, #9aa0a6);
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .lbl {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
}

html.create-v2-page .sheet-create-v2 .create-form-v2 .lbl > .help-wrap,
html.create-v2-page .sheet-create-v2 .create-form-v2 .lbl > button.help {
  margin-left: 0;
  flex: 0 0 auto;
}

html.create-v2-page .sheet-create-v2 button.help,
html.create-v2-page .sheet-create-v2 .suno-tuning-head button.help,
html.create-v2-page .sheet-create-v2 .advanced-kie-range-head button.help,
html.create-v2-page .sheet-create-v2 .el-range-head button.help {
  width: var(--cv2-help-size, 18px);
  height: var(--cv2-help-size, 18px);
  min-width: var(--cv2-help-size, 18px);
  min-height: var(--cv2-help-size, 18px);
  font-size: 11px;
  line-height: 1;
  box-sizing: border-box;
}

html.create-v2-page .sheet-create-v2 .qty-v2-hint,
html.create-v2-page .sheet-create-v2 .select-option-hint,
html.create-v2-page .sheet-create-v2 .upload-v2-hint,
html.create-v2-page .sheet-create-v2 .suno-mode-hint,
html.create-v2-page .sheet-create-v2 .suno-simple-hint,
html.create-v2-page .sheet-create-v2 [data-suno-simple-hint],
html.create-v2-page .sheet-create-v2 .seg-hint,
html.create-v2-page .sheet-create-v2 .draft-hint-v2 {
  font-size: var(--cv2-helper-size, 12px);
  font-weight: 400;
  line-height: 1.4;
  color: var(--muted, #9aa0a6);
}

html.create-v2-page .sheet-create-v2 .draft-hint-v2 {
  margin: 10px 0 0;
}

html.create-v2-page .sheet-create-v2 .settings-basic-grid-audio select,
html.create-v2-page .sheet-create-v2 .settings-basic-grid-audio .qty-v2,
html.create-v2-page .sheet-create-v2 .settings-basic-grid-audio .qty-v2 button,
html.create-v2-page .sheet-create-v2 .suno-v2-meta-field select,
html.create-v2-page .sheet-create-v2 .fg-suno-duration-v2 select,
html.create-v2-page .sheet-create-v2 [data-suno-duration-field] select {
  height: var(--cv2-control-h, 36px);
  min-height: var(--cv2-control-h, 36px);
  max-height: var(--cv2-control-h, 36px);
  box-sizing: border-box;
}

html.create-v2-page .sheet-create-v2 .suno-v2-meta-field select,
html.create-v2-page .sheet-create-v2 .fg-suno-duration-v2 select,
html.create-v2-page .sheet-create-v2 [data-suno-duration-field] select,
html.create-v2-page .sheet-create-v2 .settings-basic-grid-audio select {
  padding-top: 0;
  padding-bottom: 0;
  padding-left: 12px;
  padding-right: 36px;
  line-height: normal;
}

html.create-v2-page .sheet-create-v2 .settings-basic-grid .aspect-pill,
html.create-v2-page .sheet-create-v2 .settings-basic-grid-video .aspect-pill {
  min-height: var(--cv2-control-h, 36px);
  height: var(--cv2-control-h, 36px);
  box-sizing: border-box;
}

html.create-v2-page .sheet-create-v2 .el-range-value,
html.create-v2-page .sheet-create-v2 .suno-tuning .el-range-value {
  height: var(--cv2-control-h, 36px);
}

/* Shared range track/thumb — Video advanced + ElevenLabs + Suno */
html.create-v2-page .sheet-create-v2 .advanced-kie-range-input,
html.create-v2-page .sheet-create-v2 .el-range-input,
html.create-v2-page .sheet-create-v2 .suno-tuning-range {
  accent-color: var(--cv2-accent, #a855f7);
}

html.create-v2-page .sheet-create-v2 .advanced-kie-range-input::-webkit-slider-runnable-track,
html.create-v2-page .sheet-create-v2 .el-range-input::-webkit-slider-runnable-track,
html.create-v2-page .sheet-create-v2 .suno-tuning-range::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
}

html.create-v2-page .sheet-create-v2 .advanced-kie-range-input::-webkit-slider-thumb,
html.create-v2-page .sheet-create-v2 .el-range-input::-webkit-slider-thumb,
html.create-v2-page .sheet-create-v2 .suno-tuning-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  margin-top: -5px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.9);
  background: var(--cv2-accent, #a855f7);
  box-shadow: 0 0 0 1px rgba(168, 85, 247, 0.35);
  cursor: pointer;
}

html.create-v2-page .sheet-create-v2 .fg.advanced-kie-range:focus-within,
html.create-v2-page .sheet-create-v2 .fg.el-range:focus-within,
html.create-v2-page .sheet-create-v2 .fg.suno-tuning:focus-within {
  box-shadow: none;
}

html.create-v2-page .sheet-create-v2 .create-v2-my-works:hover,
html.create-v2-page .sheet-create-v2 .create-v2-my-works:focus-visible {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
  box-shadow: var(--cv2-glow-hover);
  outline: none;
}

html.create-v2-page .sheet-create-v2 .sheet-h-close:hover,
html.create-v2-page .sheet-create-v2 .sheet-h-close:focus-visible,
html.create-v2-page .sheet-create-v2 a.x.sheet-h-close:hover,
html.create-v2-page .sheet-create-v2 a.x.sheet-h-close:focus-visible {
  border-color: var(--cv2-accent-border, rgba(168, 85, 247, 0.55));
  background: var(--cv2-accent-soft, rgba(168, 85, 247, 0.12));
  box-shadow: var(--cv2-glow-hover);
  color: var(--text);
  outline: none;
}

html.create-v2-page .sheet-create-v2 [data-suno-extras-wrap].fg-settings-advanced {
  margin-top: var(--cv2-space-8, 8px);
}

html.create-v2-page .sheet-create-v2 .upload-dropzone {
  border-radius: var(--cv2-radius-md, 12px);
}

html.create-v2-page .sheet-create-v2 .upload-v2-hint {
  margin-top: 8px;
}

@media (max-width: 1023px) {
  html.create-v2-page .sheet-create-v2 .settings-basic-grid {
    row-gap: 14px;
  }
}

/* ==========================================================================
   Create V2 Light Theme — semantic surface remap (same pattern as Home)
   Dark defaults above remain the source of truth for data-theme != light.
   ========================================================================== */

html[data-theme="light"].create-v2-page,
html[data-ui-theme="magicbox"][data-theme="light"].create-v2-page {
  --cv2-page: var(--bg);
  background: var(--cv2-page);
}

html[data-theme="light"].create-v2-page body,
html[data-ui-theme="magicbox"][data-theme="light"].create-v2-page body {
  background: var(--cv2-page, var(--bg));
}

html[data-theme="light"] .sheet-create-v2,
html[data-ui-theme="magicbox"][data-theme="light"] .sheet-create-v2 {
  --cv2-page: var(--bg);
  --cv2-container: var(--elev);
  --cv2-card: var(--card);
  --cv2-input: var(--input-bg);
  --cv2-border: var(--border);
  --cv2-hover-border: rgba(20, 22, 30, 0.18);
  --cv2-dropzone-bg: var(--surface-2);
  --cv2-soft-fill: var(--surface-2);
  --cv2-soft-fill-hover: var(--hover);
  --cv2-chrome-fill: var(--elev);
  --cv2-accent-soft: var(--chip-on);
  --cv2-accent-border: rgba(138, 43, 226, 0.45);
  --cv2-glow-ambient: 0 0 6px rgba(138, 43, 226, 0.04);
  /* hover/focus inherit light --ui-* from interaction-tokens */
  --cv2-glow-selected: var(--ui-selected-glow, 0 0 0 1px rgba(138, 43, 226, 0.14), 0 0 12px rgba(138, 43, 226, 0.14));
  --cv2-glow-nav-selected: 0 0 0 1px rgba(138, 43, 226, 0.1), 0 0 8px rgba(138, 43, 226, 0.1);
  --cv2-accent-glow: var(--cv2-glow-selected);
  --cv2-pill-active-text: var(--text);
}

/* Soft fills that were white-alpha on dark */
html[data-theme="light"] .sheet-create-v2 .prompt-chips .prompt-chip:not(.is-on):hover,
html[data-theme="light"] .sheet-create-v2 .btn-chip:hover,
html[data-theme="light"] .sheet-create-v2 .prompt-examples-more:hover,
html[data-theme="light"] .sheet-create-v2 .prompt-example-item:hover,
html[data-theme="light"] .sheet-create-v2 .aspect-pill:hover {
  border-color: var(--cv2-hover-border);
}

html[data-theme="light"] .sheet-create-v2 .create-quick-tool-card.is-on {
  background: var(--cv2-accent-soft);
  border-color: var(--cv2-accent-border);
  color: var(--text);
}

html[data-theme="light"] .sheet-create-v2 .create-quick-tool-card.is-on .create-quick-tool-card-title,
html[data-theme="light"] .sheet-create-v2 .create-quick-tool-card.is-on .create-quick-tool-card-hint {
  color: var(--text);
}

html[data-theme="light"] .sheet-create-v2 .create-quick-tool-card.is-on .create-quick-tool-card-hint {
  color: var(--muted);
}

/* Model sheet / picker selected: dark forced #fff → theme text */
html[data-theme="light"].create-v2-page .model-sheet-v2 .model-opt,
html[data-theme="light"].create-v2-page .model-sheet-v2 .model-opt.is-on,
html[data-theme="light"].create-v2-page .model-sheet-v2 .model-opt.is-on:hover {
  color: var(--text) !important;
}

html[data-theme="light"] .sheet-create-v2 .model-opt.is-on,
html[data-theme="light"] .sheet-create-v2 .prompt-chip.is-on {
  color: var(--text);
}

/* Header chrome: keep theme text color; pill border/glow comes from shared MagicBox .menu a */
html[data-theme="light"].create-v2-page .menu.menu-flat > a.create-flat-tab,
html[data-theme="light"].create-v2-page .menu.menu-flat > a.create-flat-tab:hover,
html[data-theme="light"].create-v2-page .menu.menu-flat > a.create-flat-tab:focus-visible,
html[data-theme="light"].create-v2-page .menu.menu-flat > a.create-flat-tab.is-on,
html[data-theme="light"].create-v2-page .menu.menu-flat > a.create-flat-tab.is-on:hover,
html[data-theme="light"].create-v2-page .menu.menu-flat > a.create-flat-tab.is-on:focus-visible {
  color: var(--text) !important;
  text-shadow: none !important;
}

html[data-theme="light"].create-v2-page .sheet-h-create-v2 .sheet-h-close:hover,
html[data-theme="light"].create-v2-page .sheet-create-v2 .aspect-all-h .x:hover,
html[data-theme="light"].create-v2-page .sheet-h-create-v2 .create-v2-my-works:hover {
  color: var(--text) !important;
}

/* Dock on Create pages: opaque Light surfaces via --ui-dock-* (interaction.css) */

html[data-theme="light"] .sheet-create-v2 .create-mobile-bar {
  background: var(--cv2-chrome-fill, var(--elev));
}

/* Preserve MagicBox CTA gradient in both themes */
html[data-theme="light"] .sheet-create-v2 .create-gen-btn,
html[data-theme="light"] .sheet-create-v2 .create-mobile-gen,
html[data-theme="light"] .sheet-create-v2 [data-create-submit] {
  background: var(--cv2-gradient-cta, linear-gradient(90deg, #00d4ff, #a855f7, #ff00ff));
  color: #fff;
}

/* Soft utility fills used by audio / advanced panels */
html[data-theme="light"] .sheet-create-v2 .suno-extras-panel,
html[data-theme="light"] .sheet-create-v2 .video-setting-row,
html[data-theme="light"] .sheet-create-v2 .advanced-kie-block {
  border-color: var(--cv2-border);
}

html[data-theme="light"] .sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo),
html[data-theme="light"] .sheet-create-v2 .prompt-chips .prompt-chip {
  background: var(--cv2-soft-fill, var(--surface-2));
  border-color: var(--cv2-border);
  color: var(--text);
}

html[data-theme="light"] .sheet-create-v2 .prompt-v2-actions .btn-chip:not(.btn-enhance-undo):hover,
html[data-theme="light"] .sheet-create-v2 .prompt-chips .prompt-chip:hover {
  background: var(--cv2-soft-fill-hover, var(--hover));
  border-color: var(--cv2-accent-border);
  color: var(--text);
}

html[data-theme="light"] .sheet-create-v2 .task-mode-btn:hover,
html[data-theme="light"] .sheet-create-v2 .model-picker-v2 .model-row-v2:hover {
  border-color: var(--cv2-hover-border);
}

html[data-theme="light"] .sheet-create-v2 .task-mode-toggle-image .task-mode-btn.is-on .task-mode-icon-create {
  color: var(--cv2-accent, #8a2be2);
}

html[data-theme="light"].create-v2-page .sheet-create-v2 .model-picker-v2 .model-row-v2:hover {
  border-color: var(--cv2-hover-border);
}

/* MagicBox global .pill.is-on forces color:#fff + dark fill — remapped for Create Light */
html[data-ui-theme="magicbox"][data-theme="light"] .sheet-create-v2 .pill.is-on,
html[data-theme="light"] .sheet-create-v2 .pill.is-on,
html[data-ui-theme="magicbox"][data-theme="light"] .sheet-create-v2 .suno-quality-pills-v2 .pill.is-on,
html[data-ui-theme="magicbox"][data-theme="light"] .sheet-create-v2 .suno-format-pills-v2 .pill.is-on,
html[data-ui-theme="magicbox"][data-theme="light"] .sheet-create-v2 .suno-vocal-gender-pills-v2 .pill.is-on,
html[data-ui-theme="magicbox"][data-theme="light"] .sheet-create-v2 .suno-track-pills-v2 .pill.is-on {
  color: var(--text) !important;
  background: var(--cv2-accent-soft, var(--chip-on)) !important;
  border-color: var(--cv2-accent-border) !important;
  box-shadow: var(--cv2-glow-selected) !important;
  transform: none !important;
  text-shadow: none !important;
}

html[data-ui-theme="magicbox"][data-theme="light"] .sheet-create-v2 .pill:hover,
html[data-theme="light"] .sheet-create-v2 .pill:hover {
  color: var(--text) !important;
  background: var(--cv2-soft-fill-hover, var(--hover)) !important;
  border-color: var(--cv2-accent-border) !important;
  transform: none !important;
}
