/* A listbox keeps DOM focus while the current option carries the visible focus ring. */
@layer premium-field-controls {
  @media screen {
    .jp-select-popup .jp-select-list[role=listbox]:focus-visible {
      outline:none !important;box-shadow:none !important;
    }
    .jp-select-popup[data-keyboard] .jp-select-list:focus-visible:not(:has([data-active])) [aria-selected=true],
    .jp-select-popup[data-keyboard] .jp-select-list:focus-visible:has(.jp-select-empty) {
      outline:2px solid var(--color-focus) !important;outline-offset:-3px !important;
    }
  }
}
@layer jp-select-surface {
  @media screen {
    html {
      --jp-select-paper: var(--color-bg-card);
      --jp-select-ink: var(--color-text-primary);
      --jp-select-quiet: var(--color-text-secondary);
      --jp-select-line: var(--color-border-default);
      --jp-select-soft: var(--color-bg-secondary);
      --jp-select-hover: var(--color-hover);
      --jp-select-brand: var(--color-link);
      --jp-select-tint: var(--color-selected);
      --jp-select-press: var(--color-active);
      --jp-select-check: var(--color-action);
      --jp-select-check-ink: var(--color-on-primary);
      --jp-select-shade: var(--color-backdrop);
      --jp-select-depth: 0 12px 32px -10px rgb(22 46 76 / .24), 0 2px 8px -3px rgb(22 46 76 / .10);
      --jp-select-arrow: url("/static/icon-system/controls/chevron-down-light.svg");
      --jp-select-up: url("/static/icon-system/controls/chevron-up-light.svg");
    }
    html[data-theme=dark] {
      --jp-select-paper: var(--color-bg-card);
      --jp-select-ink: var(--color-text-primary);
      --jp-select-quiet: var(--color-text-secondary);
      --jp-select-line: var(--color-border-default);
      --jp-select-soft: var(--color-bg-secondary);
      --jp-select-hover: var(--color-hover);
      --jp-select-brand: var(--color-link);
      --jp-select-tint: var(--color-selected);
      --jp-select-press: var(--color-active);
      --jp-select-check: var(--color-action);
      --jp-select-check-ink: var(--color-on-primary);
      --jp-select-shade: var(--color-backdrop);
      --jp-select-depth: 0 12px 32px -8px rgb(2 8 16 / .54);
      --jp-select-arrow: url("/static/icon-system/controls/chevron-down-dark.svg");
      --jp-select-up: url("/static/icon-system/controls/chevron-up-dark.svg");
    }
    html[data-jp-select-ready] :is(#jp-native-root,#jp-vue-root,dialog[open],[role="dialog"],.n-layout-editor[data-native-editor]) select:not([multiple],[data-native-picker]):is(:not([size]),[size="0"],[size="1"]) {
      appearance: none !important;
      padding-inline-end: 31px !important;
      background-image: var(--jp-select-arrow) !important;
      background-position: right 10px center !important;
      background-size: 14px 14px !important;
      background-repeat: no-repeat !important;
      text-overflow: ellipsis;
      cursor: pointer;
      &:disabled {cursor: not-allowed;}
      &[data-jp-picker-open] {
        background-image: var(--jp-select-up) !important;
        border-color: var(--jp-select-brand) !important;
        box-shadow: 0 0 0 3px color-mix(in srgb,var(--jp-select-brand) 13%,transparent) !important;
      }
    }
    html[data-jp-select-ready] :is(#jp-native-root,#jp-vue-root,dialog[open],[role="dialog"],.n-layout-editor[data-native-editor]) .n-page-size select:not([multiple],[data-native-picker]) {
      padding-inline-end: 22px !important;
      background-position: right 5px center !important;
    }
    @media (max-width:767px), (max-width:1023px) and (pointer:coarse) {
      html[data-jp-select-ready] :is(#jp-native-root,#jp-vue-root,dialog[open],[role="dialog"],.n-layout-editor[data-native-editor]) select:not([multiple],[data-native-picker]):is(:not([size]),[size="0"],[size="1"]) {
        min-height: 44px !important;
        font-size: 16px !important;
      }
    }

    .jp-select-popup {
      position: fixed !important;
      inset: 0 !important;
      width: 100% !important;
      height: 100% !important;
      max-width: none !important;
      max-height: none !important;
      margin: 0 !important;
      padding: 0 !important;
      border: 0 !important;
      border-radius: 0 !important;
      background: transparent !important;
      box-shadow: none !important;
      overflow: visible !important;
      z-index: 2147483000 !important;
      pointer-events: none;
      color: var(--jp-select-ink);
      font: 400 15px/1.45 -apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Microsoft YaHei UI","Microsoft YaHei",sans-serif;
      letter-spacing: normal;
      text-align: start;
      -webkit-text-size-adjust: 100%;
    }
    .jp-select-popup::backdrop {background: transparent !important; backdrop-filter: none !important;}
    .jp-select-popup *, .jp-select-popup *::after, .jp-select-popup *::before {box-sizing: border-box;}
    .jp-select-popup [hidden] {display: none !important;}
    .jp-select-popup .jp-select-backdrop {
      display: none;
      position: absolute;
      inset: 0;
      background-color: var(--jp-select-shade);
    }
    .jp-select-popup .jp-select-panel {
      display: flex;
      flex-flow: column nowrap;
      min-height: 0;
      min-width: 0;
      margin: 0;
      padding: 0;
      overflow: hidden;
      color: var(--jp-select-ink);
      background: var(--jp-select-paper);
      border: 1px solid var(--jp-select-line);
      box-shadow: var(--jp-select-depth);
      pointer-events: auto;
    }
    .jp-select-popup .jp-select-header {
      position: relative;
      display: flex;
      flex: none;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      margin: 0;
      padding: 13px 12px 12px 22px;
    }
    .jp-select-popup .jp-select-title {
      margin: 0;
      padding: 0;
      color: var(--jp-select-ink);
      font: inherit;
      font-size: 20px;
      font-weight: 650;
      line-height: 1.35;
      overflow-wrap: anywhere;
    }
    .jp-select-popup .jp-select-close {
      position: relative;
      display: inline-grid !important;
      place-items: center;
      flex: 0 0 44px;
      width: 44px !important;
      height: 44px !important;
      min-width: 0 !important;
      min-height: 0 !important;
      margin: 0 !important;
      padding: 0 !important;
      border: 0 !important;
      border-radius: 50% !important;
      color: var(--jp-select-quiet) !important;
      background: transparent !important;
      box-shadow: none !important;
      cursor: pointer;
      touch-action: manipulation;
    }
    .jp-select-popup .jp-select-close::before {
      content: "";
      position: absolute;
      inset: 6px;
      border: 1px solid var(--jp-select-line);
      border-radius: inherit;
      background: var(--jp-select-soft);
    }
    .jp-select-popup .jp-select-close svg {position: relative; width: 17px; height: 17px;}
    .jp-select-popup .jp-select-search {
      position: relative;
      flex: none;
      margin: 0 8px 6px;
    }
    .jp-select-popup .jp-select-search input {
      display: block;
      box-sizing: border-box !important;
      width: 100% !important;
      height: 39px !important;
      min-height: 0 !important;
      margin: 0 !important;
      padding: 0 12px !important;
      border: 1px solid var(--jp-select-line) !important;
      border-radius: 9px !important;
      background: var(--jp-select-soft) !important;
      color: var(--jp-select-ink) !important;
      font-family: inherit !important;
      font-size: 14px !important;
      letter-spacing: normal;
    }
    .jp-select-popup .jp-select-search:has(.jp-select-search-icon) input {padding-inline-start: 36px !important;}
    .jp-select-popup .jp-select-search-icon {
      position: absolute;
      inset-inline-start: 11px;
      top: 50%;
      width: 16px;
      height: 16px;
      transform: translateY(-50%);
      color: var(--jp-select-quiet);
      pointer-events: none;
    }
    .jp-select-popup .jp-select-search input::placeholder {color: var(--jp-select-quiet);opacity: 1;}
    .jp-select-popup .jp-select-search input {padding-inline-end:44px !important;}
    .jp-select-popup .jp-select-search input::-webkit-search-cancel-button {appearance:none;}
    .jp-select-popup .jp-select-query-clear {
      position:absolute; inset:0 0 0 auto; width:44px; display:grid; place-content:center;
      padding:0; border:0; background:transparent; color:var(--jp-select-quiet); cursor:pointer;
    }
    .jp-select-popup .jp-select-reset-choice {
      flex:none; margin:4px 6px; padding:8px 12px; min-height:38px; text-align:start;
      border:0; border-top:1px solid var(--jp-select-line); border-radius:0 0 8px 8px;
      color:var(--jp-select-brand); background:var(--jp-select-paper); cursor:pointer;
      font:inherit; overflow-wrap:anywhere;
    }
    .jp-select-popup :is(.jp-select-reset-choice,.jp-select-query-clear)[hidden] {display:none !important;}
    .jp-select-popup :is(.jp-select-query-clear,.jp-select-reset-choice):focus-visible {
      outline:2px solid var(--jp-select-brand);outline-offset:-2px;
    }
    .jp-select-popup[data-layout=sheet] .jp-select-reset-choice {min-height:44px;}
    @media (hover:hover) {
      .jp-select-popup :is(.jp-select-query-clear,.jp-select-reset-choice):hover {background-color:var(--jp-select-hover);color:var(--jp-select-brand);}
    }
    .jp-select-popup :is(.jp-select-search input,.jp-select-close):focus-visible {
      outline: 2px solid var(--jp-select-brand) !important;
      outline-offset: -2px !important;
    }
    .jp-select-popup .jp-select-list {
      flex: 1 1 auto;
      min-height: 0;
      margin: 0;
      padding: 5px;
      overflow-x: hidden;
      overflow-y: auto;
      overscroll-behavior: contain;
      scrollbar-width: thin;
      scrollbar-color: color-mix(in srgb,var(--jp-select-quiet) 38%,transparent) transparent;
      -webkit-overflow-scrolling: touch;
      outline: none;
      scroll-padding-block: 5px;
    }
    /* Focus stays on the list while its active descendant is outlined. */
    .jp-select-popup .jp-select-list:is(:focus,:focus-visible) {
      outline: 0 !important;
      box-shadow: none !important;
    }
    .jp-select-popup .jp-select-group {
      margin: 0;
      padding: 10px 10px 4px;
      color: var(--jp-select-quiet);
      font-size: 12px;
      font-weight: 600;
      line-height: 1.5;
    }
    .jp-select-popup .jp-select-option {
      position: relative;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 14px;
      min-height: 38px;
      margin: 0;
      padding: 8px 10px;
      border-radius: 7px;
      color: var(--jp-select-ink);
      background: transparent;
      cursor: pointer;
      touch-action: pan-y;
      user-select: none;
      -webkit-tap-highlight-color: transparent;
    }
    .jp-select-popup .jp-select-option + .jp-select-option {margin-top: 2px;}
    .jp-select-popup .jp-select-label {min-width: 0; white-space: normal; overflow-wrap: anywhere;}
    .jp-select-popup .jp-select-option-icon {display: none;}
    .jp-select-popup .jp-select-option[aria-selected=true] {
      color: var(--jp-select-brand);
      background: var(--jp-select-tint);
      font-weight: 600;
    }
    .jp-select-popup .jp-select-check {
      flex: 0 0 auto;
      width: 17px;
      height: 17px;
      padding: 2px;
      border-radius: 50%;
      color: var(--jp-select-check-ink);
      background: var(--jp-select-check);
    }
    .jp-select-popup .jp-select-option:not([aria-selected=true]) .jp-select-check {visibility: hidden;}
    @media (hover:hover) and (pointer:fine) {
      .jp-select-popup .jp-select-option:hover:not([aria-disabled=true],[aria-selected=true]) {background: var(--jp-select-hover);}
      .jp-select-popup .jp-select-close:hover::before {background: var(--jp-select-line);}
    }
    .jp-select-popup .jp-select-option[data-active]:not([aria-disabled=true]) {
      outline: 2px solid var(--jp-select-brand);
      outline-offset: -2px;
    }
    .jp-select-popup .jp-select-option:active:not([aria-disabled=true]) {background: var(--jp-select-press);}
    .jp-select-popup .jp-select-option[aria-disabled=true] {
      color: var(--jp-select-quiet);
      opacity: .65;
      cursor: not-allowed;
    }
    .jp-select-popup .jp-select-empty {
      margin: 0;
      padding: 22px 14px;
      color: var(--jp-select-quiet);
      text-align: center;
      overflow-wrap: anywhere;
    }
    .jp-select-popup[data-layout=menu] .jp-select-panel {
      position: fixed;
      max-height: var(--jp-picker-max-height, min(400px, 70vh));
      border-radius: 12px;
      transform-origin: center top;
    }
    .jp-select-popup[data-layout=menu][data-side=above] .jp-select-panel {transform-origin: center bottom;}
    .jp-select-popup[data-layout=menu] .jp-select-header {
      /* The menu receives its accessible name from the field; only the sheet shows a title. */
      display: none;
    }
    .jp-select-popup[data-layout=menu] .jp-select-search {margin-top: 8px;}

    .jp-select-popup[data-layout=sheet] {
      inset: var(--jp-vv-top, 0px) 0 auto !important;
      height: var(--jp-vv-height, 100%) !important;
      overflow: hidden !important;
      pointer-events: auto;
    }
    .jp-select-popup[data-layout=sheet] .jp-select-backdrop {display: block; touch-action: none;}
    .jp-select-popup[data-layout=sheet] .jp-select-panel {
      position: absolute;
      inset: auto 0 0;
      width: 100%;
      max-width: 620px;
      max-height: calc(100% - max(14px,env(safe-area-inset-top)));
      max-height: min(82%,calc(100% - max(14px,env(safe-area-inset-top))));
      margin: 0 auto;
      padding-bottom: max(8px,env(safe-area-inset-bottom));
      padding-inline: env(safe-area-inset-left) env(safe-area-inset-right);
      border-radius: 22px 22px 0 0;
      border-bottom: 0;
      box-shadow: 0 -8px 42px -18px rgb(14 33 59 / .28);
    }
    .jp-select-popup[data-layout=sheet] .jp-select-header {
      padding-top: 18px;
      touch-action: none;
      user-select: none;
    }
    .jp-select-popup[data-layout=sheet] .jp-select-header::before {
      content: "";
      position: absolute;
      inset: 7px 0 auto;
      width: 32px;
      height: 4px;
      margin: 0 auto;
      border-radius: 4px;
      background: color-mix(in srgb,var(--jp-select-quiet) 34%,var(--jp-select-paper));
    }
    .jp-select-popup[data-layout=sheet] .jp-select-header::after {
      content: "";
      position: absolute;
      inset: auto 22px 0;
      height: 1px;
      background: var(--jp-select-line);
    }
    .jp-select-popup[data-layout=sheet] .jp-select-search {margin: 12px 14px 0;}
    .jp-select-popup[data-layout=sheet] .jp-select-search input {
      height: 44px !important;
      font-size: 16px !important;
    }
    .jp-select-popup[data-layout=sheet] .jp-select-list {padding: 10px 12px 8px; scroll-padding-block: 10px;}
    .jp-select-popup[data-layout=sheet] .jp-select-group {padding: 12px 12px 5px; font-size: 13px;}
    .jp-select-popup[data-layout=sheet] .jp-select-option {
      min-height: 50px;
      padding: 11px 12px;
      border-radius: 10px;
      font-size: 16px;
      line-height: 1.5;
    }
    .jp-select-popup[data-layout=sheet] .jp-select-check {width: 20px; height: 20px; padding: 3px;}
    .jp-select-popup[data-layout=sheet][data-kind=payment] .jp-select-list {
      display: grid;
      grid-template-columns: repeat(2,minmax(0,1fr));
      gap: 8px;
      padding: 16px 14px 12px;
    }
    .jp-select-popup[data-layout=sheet][data-kind=payment] .jp-select-option {
      display: grid;
      grid-template-columns: 20px minmax(0,1fr) 17px;
      column-gap: 9px;
      min-height: 58px;
      margin: 0;
      padding-inline: 11px;
      border: 1px solid var(--jp-select-line);
    }
    .jp-select-popup[data-layout=sheet][data-kind=payment] .jp-select-option[aria-selected=true] {
      border-color: color-mix(in srgb,var(--jp-select-check) 49%,var(--jp-select-paper));
    }
    .jp-select-popup[data-layout=sheet][data-kind=payment] .jp-select-option-icon {
      display: block;
      width: 20px;
      height: 20px;
      color: var(--jp-select-quiet);
    }
    .jp-select-popup[data-layout=sheet][data-kind=payment] .jp-select-option[aria-selected=true] .jp-select-option-icon {color: var(--jp-select-brand);}
    .jp-select-popup[data-layout=sheet][data-kind=payment] .jp-select-check {width: 17px; height: 17px; padding: 2px;}
    @media (max-width:359px) {
      .jp-select-popup[data-layout=sheet][data-kind=payment] .jp-select-list {padding-inline: 10px; gap: 6px;}
      .jp-select-popup[data-layout=sheet][data-kind=payment] .jp-select-option {column-gap: 5px; padding-inline: 8px;}
    }
    @media (max-width:285px) {
      .jp-select-popup[data-layout=sheet][data-kind=payment] .jp-select-list {grid-template-columns: 1fr;}
    }
    @media (max-height:520px) {
      .jp-select-popup[data-layout=sheet] .jp-select-panel {max-height: calc(100% - max(8px,env(safe-area-inset-top)));}
      .jp-select-popup[data-layout=sheet] .jp-select-header {padding-block: 10px 2px;}
      .jp-select-popup[data-layout=sheet] .jp-select-header::before {top: 5px; height: 3px;}
      .jp-select-popup[data-layout=sheet] .jp-select-option {min-height: 44px;padding-block: 8px;}
    }
    @media (prefers-reduced-motion:no-preference) {
      .jp-select-popup[data-layout=menu] .jp-select-panel {animation: jp-select-enter-menu var(--ui-menu-time,180ms) var(--ui-ease,ease-out) both;}
      .jp-select-popup[data-layout=sheet] .jp-select-backdrop {animation: jp-select-enter-veil 150ms ease-out both;}
      .jp-select-popup[data-layout=sheet] .jp-select-panel {animation: jp-select-enter-sheet 190ms cubic-bezier(.18,.72,.2,1) both;}
      .jp-select-popup[data-layout=sheet]:not([data-dragging]) .jp-select-panel {transition: translate 140ms ease-out;}
      .jp-select-popup[data-closing] .jp-select-panel {animation: jp-select-leave-menu 85ms ease-in both;}
      .jp-select-popup[data-closing][data-layout=sheet] .jp-select-backdrop {animation: jp-select-leave-menu 115ms ease-in both;}
      .jp-select-popup[data-closing][data-layout=sheet] .jp-select-panel {animation: jp-select-leave-sheet 115ms ease-in both;}
      .jp-select-popup .jp-select-option {transition: background-color 95ms ease-out,color 95ms ease-out;}
      @keyframes jp-select-enter-menu {
        from {opacity: 0;transform: scale(.985);}
        to {opacity: 1;transform: none;}
      }
      @keyframes jp-select-enter-veil {from {opacity:0;} to {opacity:1;}}
      @keyframes jp-select-enter-sheet {from {opacity:.85; transform:translateY(26px);} to {opacity:1;transform:none;}}
      @keyframes jp-select-leave-menu {from {opacity:1;} to {opacity:0;}}
      @keyframes jp-select-leave-sheet {from {opacity:1; transform:none;} to {opacity:.25;transform:translateY(26px);}}
    }
    @media (forced-colors:active) {
      .jp-select-popup .jp-select-panel {border: 1px solid CanvasText;}
      .jp-select-popup .jp-select-option[aria-selected=true] {border-inline-start: 3px solid Highlight;}
      .jp-select-popup .jp-select-option[data-active] {outline-color: Highlight;}
      .jp-select-popup .jp-select-check {forced-color-adjust: none; background: Highlight; color: HighlightText;}
      .jp-select-popup .jp-select-option[aria-disabled=true] {color: GrayText; opacity:1;}
      html[data-jp-select-ready] :is(#jp-native-root,#jp-vue-root,dialog[open],[role="dialog"],.n-layout-editor[data-native-editor]) select:not([multiple],[data-native-picker]):is(:not([size]),[size="0"],[size="1"]) {
        appearance: auto !important;background-image: none !important;
      }
    }
  }
  @media print {.jp-select-popup {display:none !important;}}
}
