/* AvaClik Editor 0.5.76 — actual mobile color-dropdown and Create selects.
   Scoped to touch UI chrome ONLY: colored dots/texture thumbnails, desktop,
   tool logic, and user photos retain their original styles. */
@media (max-width: 768px) {
  /* Hair / beard / outfit all use the same .color-dd component. Their list
     is rendered in the React tool tree, not in .sg256-texture-picker alone. */
  html[data-ava-editor-theme] #fotor-root .editor-shell.is-mobile .color-dd,
  html[data-ava-editor-theme] body .color-dd {
    --ava-dd-panel:var(--ava-m-panel);
    --ava-dd-row:var(--ava-m-surface);
    --ava-dd-stroke:var(--ava-m-stroke);
    --ava-dd-fg:var(--ava-m-text);
    --ava-dd-muted:var(--ava-m-muted);
    --ava-dd-selected:var(--ava-m-selected);
    --ava-dd-selected-border:var(--ava-m-accent);
  }
  html[data-ava-editor-theme] #fotor-root .editor-shell.is-mobile .color-dd .color-dd-menu,
  html[data-ava-editor-theme] body .color-dd .color-dd-menu {
    background:var(--ava-dd-panel)!important;
    background-image:none!important;
    border:1px solid var(--ava-dd-stroke)!important;
    box-shadow:0 16px 44px rgba(0,0,0,.25)!important;
    color:var(--ava-dd-fg)!important;
    backdrop-filter:none!important;
    -webkit-backdrop-filter:none!important;
  }
  html[data-ava-editor-theme] #fotor-root .editor-shell.is-mobile .color-dd .color-dd-list,
  html[data-ava-editor-theme] body .color-dd .color-dd-list {
    background:transparent!important;
    color:var(--ava-dd-fg)!important;
  }
  html[data-ava-editor-theme] #fotor-root .editor-shell.is-mobile .color-dd :is(.color-dd-item,.color-dd-extra,.color-dd-trigger),
  html[data-ava-editor-theme] body .color-dd :is(.color-dd-item,.color-dd-extra,.color-dd-trigger) {
    background:var(--ava-dd-row)!important;
    background-image:none!important;
    border-color:var(--ava-dd-stroke)!important;
    color:var(--ava-dd-fg)!important;
    -webkit-text-fill-color:var(--ava-dd-fg)!important;
    box-shadow:none!important;
    text-shadow:none!important;
    opacity:1!important;
  }
  html[data-ava-editor-theme] #fotor-root .editor-shell.is-mobile .color-dd :is(.color-dd-item,.color-dd-extra).active,
  html[data-ava-editor-theme] #fotor-root .editor-shell.is-mobile .color-dd .color-dd-item[aria-selected="true"],
  html[data-ava-editor-theme] body .color-dd :is(.color-dd-item,.color-dd-extra).active,
  html[data-ava-editor-theme] body .color-dd .color-dd-item[aria-selected="true"] {
    background:var(--ava-dd-selected)!important;
    background-image:none!important;
    border-color:var(--ava-dd-selected-border)!important;
    color:var(--ava-dd-fg)!important;
    -webkit-text-fill-color:var(--ava-dd-fg)!important;
    box-shadow:inset 0 0 0 1px var(--ava-dd-stroke)!important;
  }
  html[data-ava-editor-theme] #fotor-root .editor-shell.is-mobile .color-dd :is(.color-dd-trigger-text,.color-dd-item-text,.color-dd-check,.color-dd-chevron,.color-dd-label,.color-dd-extra > span:not(.color-dd-dot)),
  html[data-ava-editor-theme] body .color-dd :is(.color-dd-trigger-text,.color-dd-item-text,.color-dd-check,.color-dd-chevron,.color-dd-label,.color-dd-extra > span:not(.color-dd-dot)) {
    color:var(--ava-dd-fg)!important;
    -webkit-text-fill-color:var(--ava-dd-fg)!important;
    opacity:1!important;
    text-shadow:none!important;
  }
  /* Important: do not overwrite the inline background colors or the
     sg256-texture atlas painted on .color-dd-dot. */

  /* Create Image uses native selects for quality and image aspect ratio.
     Set OPTION colors as well; default selects otherwise inherit the old
     burgundy #211321 / cobalt highlight from the browser. */
  html[data-ava-editor-theme] :is(#fotor-root,body) :is(.text-image-popup,.text-image-page,.ti-mobile-prompt-sheet) select,
  html[data-ava-editor-theme] :is(#fotor-root,body) .text-image-popup :is(.ti-grid,.ti-quality,.ti-field,.ti-hot-aspect--toolbar) select {
    background:var(--ava-m-surface)!important;
    background-image:none!important;
    border:1px solid var(--ava-m-stroke)!important;
    color:var(--ava-m-text)!important;
    -webkit-text-fill-color:var(--ava-m-text)!important;
    box-shadow:none!important;
    color-scheme:inherit!important;
    accent-color:var(--ava-m-accent)!important;
  }
  html[data-ava-editor-theme] :is(#fotor-root,body) :is(.text-image-popup,.text-image-page,.ti-mobile-prompt-sheet) select :is(option,optgroup) {
    background-color:var(--ava-m-panel)!important;
    color:var(--ava-m-text)!important;
    -webkit-text-fill-color:var(--ava-m-text)!important;
    color-scheme:inherit!important;
  }
  html[data-ava-editor-theme] :is(#fotor-root,body) :is(.text-image-popup,.text-image-page,.ti-mobile-prompt-sheet) select option:checked {
    background-color:var(--ava-m-selected)!important;
    color:var(--ava-m-text)!important;
    -webkit-text-fill-color:var(--ava-m-text)!important;
  }
  html[data-ava-editor-theme="dark"] :is(#fotor-root,body) :is(.text-image-popup,.text-image-page,.ti-mobile-prompt-sheet) select {color-scheme:dark!important;}
  html[data-ava-editor-theme="light"] :is(#fotor-root,body) :is(.text-image-popup,.text-image-page,.ti-mobile-prompt-sheet) select {color-scheme:light!important;}

  /* Slightly round the whole tool control strip shown above mobile presets.
     No overflow: hidden here: color menus must escape the toolbar. */
  html[data-ava-editor-theme] #fotor-root .editor-shell.is-mobile:not(.sg-mobile-panel-collapsed) .mtool-top-controls {
    border-radius:10px!important;
    background-clip:padding-box!important;
  }
  html[data-ava-editor-theme] #fotor-root .editor-shell.is-mobile .mtool-top-controls :is(.mtool-top-group--left,.mtool-top-group--right) {
    border-radius:9px!important;
  }
}
