

    .page-custom-sticker > header .top-wrap {
      height: 30px;
    }

    .page-custom-sticker > header .top-wrap .btn {
      padding-block: 4px;
      font-size: 12px;
    }

    .page-custom-sticker > header .header-content {
      padding-block: 4px;
    }

    .page-custom-sticker > header .header-content .menu-wrap > .navbar-nav > .nav-item > .nav-link {
      padding-block: 8px;
      font-size: 14px;
    }

    .page-custom-sticker > header .header-content .logo img {
      max-height: 32px;
    }

    .custom-sticker-editor {
      position: relative;
      --sticker-workbench-height: max(440px, calc(100dvh - 140px));
      --sticker-paper: #fff;
      --sticker-mat: #eef2f5;
      --sticker-ink: #253344;
      --sticker-muted: #637185;
      --sticker-line: #dce3e9;
      --sticker-accent: #c94724;
      --sticker-accent-soft: #fff2ed;
      background: #f5f7f9;
      color: var(--sticker-ink);
      font-family: "Jost", "PingFang SC", "Microsoft YaHei", sans-serif;
      font-size: 14px;
      min-height: 78vh;
      padding-top: 8px !important;
      padding-bottom: 8px !important;
    }

    .custom-sticker-editor > .container {
      width: 100%;
      max-width: none;
      padding-right: 12px;
      padding-left: 12px;
    }

    .custom-sticker-editor .btn {
      min-height: 38px;
      border-radius: 7px;
      font-size: 13px;
      font-weight: 500;
      line-height: 1.4;
      white-space: normal;
      overflow-wrap: anywhere;
    }

    .custom-sticker-editor .btn-primary {
      --bs-btn-bg: var(--sticker-accent);
      --bs-btn-border-color: var(--sticker-accent);
      --bs-btn-hover-bg: #af3c1d;
      --bs-btn-hover-border-color: #af3c1d;
      --bs-btn-active-bg: #af3c1d;
      --bs-btn-active-border-color: #af3c1d;
      background: var(--sticker-accent);
      border-color: var(--sticker-accent);
      color: #fff;
    }

    .custom-sticker-editor .btn-primary:hover {
      background: #af3c1d;
      border-color: #af3c1d;
    }

    .custom-sticker-editor :is(.btn-outline-secondary, .btn-outline-dark) {
      --bs-btn-hover-bg: var(--sticker-mat);
      --bs-btn-hover-color: var(--sticker-ink);
      --bs-btn-hover-border-color: #a9b6c5;
      --bs-btn-active-bg: var(--sticker-mat);
      --bs-btn-active-color: var(--sticker-ink);
      border-color: var(--sticker-line);
      color: var(--sticker-ink);
    }

    .custom-sticker-editor :is(.btn-outline-secondary, .btn-outline-dark):hover {
      background: var(--sticker-mat);
      border-color: #a9b6c5;
      color: var(--sticker-ink);
    }

    .custom-sticker-editor :is(button, a, input, select, textarea, [tabindex]):focus-visible {
      outline: 3px solid var(--sticker-accent);
      outline-offset: 3px;
      box-shadow: none;
    }

    .custom-sticker-editor :is(.form-control, .form-select) {
      min-height: 40px;
      border-radius: 7px;
      border-color: var(--sticker-line);
      color: var(--sticker-ink);
      font-size: 14px;
    }

    .custom-sticker-editor :is(.form-text, .text-muted) {
      color: var(--sticker-muted) !important;
    }

    .custom-sticker-editor .form-text {
      font-size: 12px;
      line-height: 1.6;
    }

    .custom-sticker-editor .form-range::-webkit-slider-thumb {
      background: var(--sticker-accent);
    }

    .custom-sticker-editor .form-range::-moz-range-thumb {
      background: var(--sticker-accent);
    }

    .custom-sticker-editor.is-busy {
      cursor: wait;
    }

    .custom-sticker-editor.is-busy .custom-sticker-shell,
    .custom-sticker-editor.is-busy .custom-sticker-stage {
      pointer-events: none;
    }

    .editor-busy-overlay {
      position: fixed;
      inset: 0;
      z-index: 2000;
      display: none;
      align-items: center;
      justify-content: center;
      background: rgba(245, 246, 247, .46);
      backdrop-filter: blur(1px);
    }

    .custom-sticker-editor.is-busy .editor-busy-overlay {
      display: flex;
    }

    .editor-busy-card {
      border: 1px solid #dde2e8;
      border-radius: 14px;
      background: #fff;
      padding: 14px 18px;
      box-shadow: 0 18px 42px rgba(17, 24, 39, .16);
      font-weight: 700;
    }

    .custom-sticker-shell {
      display: grid;
      grid-template-columns: 288px minmax(0, 1fr);
      grid-template-rows: minmax(0, 1fr) auto;
      gap: 8px;
      align-items: stretch;
      height: var(--sticker-workbench-height);
      min-height: 0;
    }

    .custom-sticker-panel,
    .custom-sticker-stage {
      background: var(--sticker-paper);
      border: 1px solid var(--sticker-line);
      border-radius: 9px;
      min-width: 0;
    }

    .custom-sticker-panel {
      position: static;
      display: flex;
      flex-direction: column;
      height: 100%;
      max-height: 100%;
      overflow: hidden;
    }

    .sticker-panel-scroll {
      flex: 1 1 auto;
      min-height: 0;
      padding: 16px;
      overflow: auto;
      overscroll-behavior: contain;
      scrollbar-width: thin;
      scrollbar-color: #c3ccd6 transparent;
    }

    .custom-sticker-stage {
      height: 100%;
      min-height: 0;
      display: grid;
      grid-template-rows: auto minmax(0, 1fr);
      overflow: hidden;
    }

    .sticker-canvas-wrap {
      position: relative;
      display: flex;
      align-items: safe center;
      justify-content: safe center;
      min-height: 0;
      padding: 12px !important;
      /* Artwork is fitted to this viewport; the empty canvas must not add scrollbars while loading. */
      overflow: hidden;
      background-color: var(--sticker-mat);
      background-image:
        linear-gradient(#dce3e980 1px, transparent 1px),
        linear-gradient(90deg, #dce3e980 1px, transparent 1px);
      background-size: 24px 24px;
    }

    .sticker-canvas-wrap.is-night {
      background: #090d12;
    }

    /* Font readiness must not move the workbench or change its viewport-derived height. */
    .sticker-font-status {
      position: absolute;
      z-index: 25;
      top: 12px;
      right: 12px;
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 8px;
      width: max-content;
      max-width: min(420px, calc(100% - 24px));
      margin: 0;
      padding: 8px 12px;
      border: 1px solid var(--sticker-line);
      border-radius: 7px;
      background: var(--sticker-paper);
      color: var(--sticker-ink);
      box-shadow: 0 4px 16px #25334424;
      font-size: 12px;
      line-height: 1.4;
    }

    .sticker-font-status[hidden] {
      display: none !important;
    }

    .sticker-font-status > span {
      flex: 1 1 180px;
      min-width: 0;
      overflow-wrap: anywhere;
    }

    .sticker-canvas {
      --canvas-background-color: #fafafa;
      --canvas-background-image: conic-gradient(#ededed 25%, #fafafa 0 50%, #ededed 0 75%, #fafafa 0);
      position: relative;
      width: min(78vw, 760px);
      max-width: 100%;
      aspect-ratio: 3 / 2;
      background-color: var(--canvas-background-color);
      background-image: var(--canvas-background-image);
      background-size: 16px 16px;
      border: 1px solid rgba(101, 112, 127, .4);
      overflow: hidden;
      flex: 0 0 auto;
      transform-origin: center;
    }

    .sticker-canvas.is-night {
      background: #05080b;
      border-color: rgba(185, 240, 126, .46);
    }

    .sticker-dimension-rulers {
      position: absolute;
      inset: 0;
      display: block;
      pointer-events: none;
      z-index: 7;
      --ruler-size: 18px;
      --ruler-surface: linear-gradient(180deg, rgba(255, 255, 255, .92), rgba(246, 248, 250, .86));
      --ruler-border: rgba(203, 210, 218, .82);
      --ruler-major: #f05a2a;
      --ruler-minor: rgba(102, 112, 133, .48);
      --ruler-label: #475467;
    }

    .sticker-dimension-rulers[hidden] {
      display: none !important;
    }

    .sticker-ruler-horizontal,
    .sticker-ruler-vertical {
      box-sizing: border-box;
      position: absolute;
      z-index: 1;
      display: flex;
      overflow: visible;
      background: var(--ruler-surface);
      border-color: var(--ruler-border);
      box-shadow: 0 1px 4px rgba(13, 20, 29, .1);
      backdrop-filter: blur(3px);
    }

    .sticker-ruler-horizontal {
      top: 0;
      right: 0;
      left: 0;
      height: var(--ruler-size);
      border-top: 1px solid var(--ruler-border);
      border-bottom: 1px solid var(--ruler-border);
      flex-direction: row;
    }

    .sticker-ruler-vertical {
      top: 0;
      bottom: 0;
      left: 0;
      width: var(--ruler-size);
      border-left: 1px solid var(--ruler-border);
      border-right: 1px solid var(--ruler-border);
      flex-direction: column;
    }

    .sticker-ruler-tick {
      position: absolute;
      z-index: 2;
      background: var(--ruler-minor);
    }

    .sticker-ruler-horizontal .sticker-ruler-tick {
      width: 1px;
      bottom: 0;
    }

    .sticker-ruler-horizontal .sticker-ruler-tick.major {
      height: 7px;
      background: var(--ruler-major);
    }

    .sticker-ruler-horizontal .sticker-ruler-tick.minor {
      height: 4px;
    }

    .sticker-ruler-vertical .sticker-ruler-tick {
      height: 1px;
      right: 0;
    }

    .sticker-ruler-vertical .sticker-ruler-tick.major {
      width: 7px;
      background: var(--ruler-major);
    }

    .sticker-ruler-vertical .sticker-ruler-tick.minor {
      width: 4px;
    }

    .sticker-ruler-label {
      position: absolute;
      z-index: 3;
      font-size: 8px;
      font-weight: 700;
      color: var(--ruler-label);
      text-shadow: 0 1px 1px rgba(255, 255, 255, .7);
      line-height: 1;
      white-space: nowrap;
      font-variant-numeric: tabular-nums;
    }

    .sticker-ruler-horizontal .sticker-ruler-label {
      bottom: 8px;
      transform: translateX(-50%);
    }

    .sticker-ruler-horizontal .sticker-ruler-label.is-edge-start {
      left: 3px !important;
      transform: none;
    }

    .sticker-ruler-horizontal .sticker-ruler-label.is-edge-end {
      right: 3px;
      left: auto !important;
      transform: none;
    }

    .sticker-ruler-vertical .sticker-ruler-label {
      right: 5px;
      top: 50%;
      writing-mode: vertical-rl;
      transform: translateY(-50%) rotate(180deg);
      transform-origin: center;
    }

    .sticker-ruler-vertical .sticker-ruler-label.is-edge-start {
      top: 3px !important;
      right: 5px;
      transform: rotate(180deg);
    }

    .sticker-ruler-vertical .sticker-ruler-label.is-edge-end {
      top: auto !important;
      right: 5px;
      bottom: 3px;
      transform: rotate(180deg);
    }

    .sticker-ruler-corner {
      position: absolute;
      width: var(--ruler-size);
      height: var(--ruler-size);
      background: var(--ruler-surface);
      border: 1px solid var(--ruler-border);
      z-index: 2;
      box-shadow: 0 1px 4px rgba(13, 20, 29, .1);
    }

    .sticker-ruler-corner.top-left::after {
      content: attr(data-unit);
      position: absolute;
      inset: 0;
      display: grid;
      place-items: center;
      color: var(--ruler-label);
      font-size: 6px;
      font-weight: 800;
      letter-spacing: .04em;
      text-shadow: 0 1px 1px rgba(255, 255, 255, .7);
    }

    .sticker-ruler-corner.top-left {
      top: 0;
      left: 0;
      border-right-width: 0;
      border-bottom-width: 0;
    }

    .sticker-canvas.is-night .sticker-dimension-rulers {
      --ruler-surface: linear-gradient(180deg, rgba(5, 12, 15, .94), rgba(12, 24, 24, .9));
      --ruler-border: rgba(185, 240, 126, .36);
      --ruler-major: #b9f07e;
      --ruler-minor: rgba(185, 240, 126, .42);
      --ruler-label: rgba(211, 255, 171, .98);
      opacity: .96;
    }

    .sticker-material-options {
      display: flex;
      flex-wrap: wrap;
      gap: 6px;
      margin-top: 8px;
    }

    .sticker-material-option {
      display: flex;
      align-items: center;
      justify-content: center;
      flex: 1 1 100%;
      justify-content: flex-start;
      gap: 8px;
      min-height: 40px;
      padding: 7px 9px;
      font-size: 12px;
      text-align: left;
      border: 1px solid #dce2e9;
      border-radius: 8px;
      background: #fff;
    }

    .sticker-material-option[aria-pressed="true"] {
      border-color: #536c91;
      background: #edf3ff;
      box-shadow: inset 0 0 0 1px #536c91;
    }

    .sticker-material-option:focus-visible {
      outline: 3px solid #536c91;
      outline-offset: 2px;
    }

    .sticker-material-chip {
      flex: 0 0 22px;
      width: 22px;
      height: 22px;
      border: 1px solid #18263820;
      border-radius: 50%;
      background-size: 100% 100%;
    }

    .sticker-material-layer {
      position: absolute;
      inset: 0;
      background-color: var(--canvas-background-color);
      background-image: var(--canvas-background-image);
      background-size: 16px 16px;
    }

    .sticker-material-preview-canvas {
      position: absolute;
      inset: 0;
      z-index: 3;
      display: none;
      width: 100%;
      height: 100%;
      cursor: ew-resize;
      touch-action: none;
    }

    .sticker-canvas.is-material-preview .sticker-material-preview-canvas {
      display: block;
    }

    .sticker-canvas.is-material-preview .sticker-elements {
      opacity: 0;
      pointer-events: none;
    }

    .sticker-canvas.is-material-preview .sticker-artwork-surface,
    .sticker-canvas.is-production-preview .sticker-artwork-surface,
    .sticker-canvas.is-manual-mask .sticker-artwork-surface {
      visibility: hidden;
    }

    .manual-mask-overlay {
      position: absolute;
      inset: 0;
      z-index: 8;
      display: none;
      cursor: crosshair;
      overflow: hidden;
      touch-action: none;
      user-select: none;
    }

    .manual-mask-overlay.is-active {
      display: block;
    }

    .manual-mask-canvas {
      position: absolute;
      z-index: 1;
      opacity: 0;
      pointer-events: none;
    }

    .manual-mask-source {
      position: absolute;
      z-index: 0;
      display: block;
      object-fit: fill;
      pointer-events: none;
      user-select: none;
    }

    .manual-mask-preview-canvas {
      position: absolute;
      z-index: 1;
      display: block;
      pointer-events: none;
      user-select: none;
    }

    .manual-mask-overlay.has-preview .manual-mask-source {
      visibility: hidden;
    }

    .manual-mask-scene-canvas {
      position: absolute;
      pointer-events: none;
      display: none;
    }

    .manual-mask-overlay.has-scene .manual-mask-scene-canvas {
      display: block;
    }

    .manual-mask-overlay.has-scene .manual-mask-source,
    .manual-mask-overlay.has-scene .manual-mask-preview-canvas {
      visibility: hidden;
    }

    .brush-cursor {
      position: absolute;
      z-index: 2;
      border: 2px solid #fff;
      border-radius: 50%;
      pointer-events: none;
      box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.5);
      transform: translate(-50%, -50%);
      display: none;
    }

    .manual-mask-overlay.is-active .brush-cursor {
      display: block;
    }

    .production-preview-image {
      position: absolute;
      inset: 0;
      z-index: 6;
      display: none;
      width: 100%;
      height: 100%;
      object-fit: contain;
      pointer-events: none;
      user-select: none;
    }

    .sticker-canvas.is-production-preview .production-preview-image {
      display: block;
    }

    .sticker-canvas.is-production-preview .sticker-material-layer,
    .sticker-canvas.is-production-preview .sticker-elements,
    .sticker-canvas.is-production-preview .sticker-material-preview-canvas,
    .sticker-canvas.is-production-preview ~ .sticker-placeholder,
    .sticker-canvas.is-production-preview .sticker-transform-controls {
      visibility: hidden;
      pointer-events: none;
    }

    .sticker-canvas.is-manual-mask .sticker-elements,
    .sticker-canvas.is-manual-mask .sticker-transform-controls,
    .sticker-canvas.is-manual-mask .sticker-material-preview-canvas,
    .sticker-canvas.is-manual-mask ~ .sticker-placeholder {
        visibility: hidden;
        pointer-events: none;
      }

    .material-simulation-controls {
      display: grid;
      grid-template-columns: minmax(0, 1fr);
      gap: 14px;
      align-items: start;
      margin-top: 12px;
      padding-top: 12px;
      border-top: 1px solid #edf0f2;
    }

    .material-preview-switch {
      display: flex;
      align-items: flex-start;
      flex-direction: column;
      gap: 10px;
      margin-top: 0;
    }

    .material-preview-switch-label {
      color: #6b7280;
      font-size: 12px;
      font-weight: 700;
      white-space: nowrap;
    }

    .material-preview-switch .btn {
      min-width: 76px;
    }

    .material-preview-switch .btn.active {
      background: #111;
      border-color: #111;
      color: #fff;
    }

    .material-simulation-controls .form-range {
      min-width: 0;
    }

    .material-preview-disclaimer {
      align-self: center;
      white-space: normal;
    }

    .material-renderer-status {
      min-height: 18px;
      margin-top: 8px;
      color: #b42318;
    }

    .vehicle-preview-controls {
      display: grid;
      grid-template-columns: minmax(0, 1fr);
      gap: 16px;
      align-items: start;
    }

    .sticker-preview-settings {
      padding-bottom: 20px;
      margin-bottom: 20px;
      border-bottom: 1px solid var(--sticker-line);
    }

    .vehicle-preview-controls .form-range {
      min-width: 0;
    }

    .vehicle-photo-upload,
    .vehicle-photo-scale-control {
      grid-column: 1 / -1;
      min-width: 0;
    }

    .vehicle-photo-heading {
      display: flex;
      align-items: center;
      gap: 4px;
      margin-bottom: 4px;
    }

    .vehicle-photo-heading label {
      flex: 1;
      min-width: 0;
      margin: 0;
    }

    .vehicle-photo-help,
    .vehicle-photo-remove {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 28px;
      height: 28px;
      flex: 0 0 auto;
      padding: 0;
      color: #64748b;
    }

    .vehicle-photo-popover {
      --bs-popover-max-width: min(240px, calc(100vw - 32px));
      --bs-popover-body-padding-x: 12px;
      --bs-popover-body-padding-y: 10px;
      --bs-popover-font-size: 12px;
      --bs-popover-body-color: #64748b;
      box-shadow: 0 4px 16px #2533441a;
      line-height: 1.6;
    }

    #vehicle-photo-status:not(:empty) { margin-top: 4px; }

    .vehicle-preview-size-value {
      display: flex;
      align-items: center;
      min-height: 31px;
      padding: 4px 6px;
      color: #111827;
      font-size: 13px;
      font-weight: 700;
      white-space: nowrap;
    }

    .vehicle-preview-size-control {
      padding-right: 4px;
    }

    .vehicle-reset-button {
      width: 34px;
      height: 34px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      padding: 0;
    }

    .vehicle-preview-actions {
      display: flex;
      align-items: center;
      justify-content: flex-start;
      gap: 10px;
      padding-top: 0;
    }

    .sticker-canvas-wrap.is-vehicle {
      overflow: hidden;
      padding: 0 !important;
      background: #e9edf0;
    }

    .sticker-canvas-wrap.is-vehicle .sticker-canvas {
      display: none;
    }

    .vehicle-preview-stage {
      position: relative;
      display: none;
      width: 100%;
      aspect-ratio: 16 / 9;
      overflow: hidden;
      flex: 0 0 auto;
      background: #24282c;
      border: 0;
      border-radius: 0;
      isolation: isolate;
    }

    .sticker-canvas-wrap.is-vehicle .vehicle-preview-stage {
      display: block;
    }

    .vehicle-preview-image {
      position: absolute;
      inset: 0;
      width: 100%;
      height: 100%;
    }

    .vehicle-preview-image {
      z-index: 0;
      display: block;
      object-fit: cover;
    }

    .vehicle-sticker-preview {
      position: absolute;
      z-index: 2;
      left: 50%;
      top: 60%;
      width: 25%;
      max-width: none;
      height: auto;
      cursor: grab;
      touch-action: none;
      transform-origin: center;
      opacity: .94;
      mix-blend-mode: normal;
      filter: saturate(.96) brightness(.96) drop-shadow(0 1px 1px rgba(12, 18, 24, .3));
    }

    .vehicle-sticker-preview.is-dragging {
      cursor: grabbing;
    }

    .vehicle-sticker-locator {
      position: absolute;
      z-index: 4;
      left: 50%;
      top: 60%;
      width: 36px;
      height: 36px;
      border: 3px solid rgba(255, 255, 255, .98);
      border-radius: 50%;
      transform: translate(-50%, -50%);
      box-shadow: 0 0 0 3px rgba(15, 23, 42, .78), 0 3px 10px rgba(15, 23, 42, .4);
      cursor: grab;
      touch-action: none;
    }

    .vehicle-sticker-locator.is-dragging {
      cursor: grabbing;
    }

    .vehicle-transform-controls {
      position: absolute;
      inset: 0;
      z-index: 6;
      overflow: hidden;
      pointer-events: none;
    }

    .vehicle-transform-controls .sticker-rotate-connector {
      background: rgba(255, 255, 255, .96);
      box-shadow: 0 0 0 1px rgba(15, 23, 42, .5), 0 2px 6px rgba(15, 23, 42, .3);
    }

    .vehicle-transform-controls .sticker-rotate-handle {
      background: rgba(21, 25, 29, .94);
    }

    .vehicle-detail-preview {
      position: absolute;
      z-index: 5;
      top: 10px;
      right: 10px;
      display: grid;
      grid-template-rows: auto minmax(0, 1fr);
      width: clamp(188px, 34%, 280px);
      max-width: calc(100% - 20px);
      max-height: calc(100% - 20px);
      padding: 10px;
      border: 1px solid rgba(15, 23, 42, .2);
      border-radius: 6px;
      background: rgba(255, 255, 255, .94);
      box-shadow: 0 8px 22px rgba(15, 23, 42, .18);
      color: #111827;
      pointer-events: none;
    }

    .vehicle-detail-preview.is-left {
      right: auto;
      left: 10px;
    }

    .vehicle-detail-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
      margin-bottom: 6px;
      font-size: 11px;
      font-weight: 700;
    }

    .vehicle-detail-scale {
      color: #475569;
      font-variant-numeric: tabular-nums;
    }

    .vehicle-detail-canvas-wrap {
      position: relative;
      width: 100%;
      aspect-ratio: 1;
      min-height: 0;
      max-height: 100%;
      overflow: hidden;
      border: 1px solid #e5e7eb;
      background: #e5e7eb;
      isolation: isolate;
    }

    .vehicle-detail-image {
      position: absolute;
      z-index: 0;
      display: block;
      max-width: none;
      max-height: none;
      object-fit: cover;
      pointer-events: none;
      user-select: none;
    }

    .vehicle-detail-canvas {
      position: absolute;
      z-index: 1;
      display: block;
      max-width: none;
      max-height: none;
      transform-origin: center;
      opacity: .94;
      filter: saturate(.96) brightness(.96) drop-shadow(0 1px 1px rgba(12, 18, 24, .3));
      pointer-events: none;
    }

    .vehicle-preview-empty {
      position: absolute;
      z-index: 4;
      left: 50%;
      top: 50%;
      transform: translate(-50%, -50%);
      padding: 8px 12px;
      border-radius: 4px;
      background: rgba(17, 24, 39, .74);
      color: #fff;
      font-size: 13px;
      pointer-events: none;
    }

    .vehicle-preview-size-badge {
      position: absolute;
      z-index: 4;
      right: 10px;
      bottom: 10px;
      padding: 5px 8px;
      border: 1px solid rgba(255, 255, 255, .28);
      border-radius: 4px;
      background: rgba(17, 24, 39, .74);
      color: #fff;
      font-size: 12px;
      font-weight: 700;
      pointer-events: none;
    }

    .size-comparison-grid {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 16px;
    }

    .size-comparison-card {
      overflow: hidden;
      border: 1px solid #e2e5e9;
      border-radius: 10px;
      background: #fff;
    }

    .size-comparison-card.is-current {
      border-color: #111827;
      box-shadow: 0 0 0 1px #111827;
    }

    .size-comparison-card-header,
    .size-comparison-card-actions {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
      padding: 12px;
    }

    .size-comparison-card-header { min-height: 52px; }
    .size-comparison-card-actions .btn { width: 100%; }
    .size-comparison-card canvas { display: block; width: 100%; height: auto; }
    .size-comparison-detail { border-top: 1px solid #edf0f2; }
    .size-comparison-caption { margin: 0; padding: 6px 12px; color: #64748b; font-size: 12px; }
    .size-comparison-context { max-width: 420px; }

    @media (max-width: 991px) {
      .size-comparison-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    }

    @media (max-width: 575px) {
      .size-comparison-grid { grid-template-columns: minmax(0, 1fr); }
    }

    .sticker-artwork-surface {
      position: absolute;
      inset: 0;
      width: 100%;
      height: 100%;
      z-index: 2;
      pointer-events: none;
    }

    .sticker-elements {
      position: absolute;
      inset: 0;
      overflow: hidden;
      z-index: 2;
      touch-action: none;
      -webkit-mask-size: 100% 100%;
      mask-size: 100% 100%;
      -webkit-mask-repeat: no-repeat;
      mask-repeat: no-repeat;
    }

    .sticker-element {
      position: absolute;
      left: 50%;
      top: 50%;
      width: 100%;
      height: 100%;
      transform-origin: center;
      background-color: #111;
      background-position: center;
      background-repeat: repeat;
      background-size: cover;
      cursor: move;
      user-select: none;
      touch-action: none;
    }

    .sticker-element.is-selected {
      outline: 2px solid rgba(255, 255, 255, .9);
      outline-offset: 3px;
    }

    .sticker-transform-controls {
      position: absolute;
      inset: 0;
      z-index: 7;
      overflow: visible;
      pointer-events: none;
    }

    .sticker-rotate-connector {
      position: absolute;
      width: 24px;
      height: 2px;
      background: rgba(255, 255, 255, .92);
      box-shadow: 0 0 0 1px rgba(17, 24, 39, .22);
      transform-origin: left center;
      pointer-events: none;
    }

    .sticker-rotate-handle {
      position: absolute;
      width: 32px;
      height: 32px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      padding: 0;
      border: 2px solid #fff;
      border-radius: 50%;
      background: #15191d;
      color: #fff;
      box-shadow: 0 2px 8px rgba(0, 0, 0, .34);
      cursor: grab;
      pointer-events: auto;
      touch-action: none;
      transform: translate(-50%, -50%);
    }

    .sticker-rotate-handle:hover,
    .sticker-rotate-handle:focus-visible {
      background: #fff;
      color: #15191d;
    }

    .sticker-rotate-handle:focus-visible {
      outline: 2px solid #111;
      outline-offset: 2px;
    }

    .sticker-rotate-handle.is-rotating {
      cursor: grabbing;
    }

    .sticker-element.is-editing {
      background-image: none !important;
      background-color: transparent !important;
      color: #fff;
      -webkit-background-clip: border-box;
      background-clip: border-box;
      cursor: text;
      text-shadow: 0 1px 2px rgba(0, 0, 0, .5);
      user-select: text;
      white-space: pre-wrap;
    }

    .sticker-text-editor {
      display: block;
      width: 100%;
      min-width: 1ch;
      color: #fff;
      outline: none;
      white-space: pre-wrap;
      overflow-wrap: normal;
      line-height: 1.18;
      font: inherit;
      font-weight: inherit;
      text-shadow: inherit;
    }

    .sticker-element[data-mode="subtract"] {
      opacity: 1;
      filter: none;
    }

    .sticker-element-image {
      -webkit-mask-position: center;
      mask-position: center;
      -webkit-mask-repeat: no-repeat;
      mask-repeat: no-repeat;
      -webkit-mask-size: contain;
      mask-size: contain;
    }

    .sticker-element-text {
      display: flex;
      align-items: center;
      justify-content: center;
      white-space: pre-wrap;
      line-height: 1.18;
      font-weight: 800;
      font-family: "Arial Unicode MS", "PingFang SC", "Microsoft YaHei", Arial, Helvetica, sans-serif;
      color: transparent;
      padding: 0;
      -webkit-mask-position: center;
      mask-position: center;
      -webkit-mask-repeat: no-repeat;
      mask-repeat: no-repeat;
      -webkit-mask-size: 100% 100%;
      mask-size: 100% 100%;
    }

    .sticker-element-rect {
      border-radius: 3px;
    }

    .sticker-element-square {
      border-radius: 3px;
    }

    .sticker-element-rounded_rect {
      border-radius: 30px;
    }

    .sticker-element-circle {
      border-radius: 50%;
    }

    .sticker-element-ellipse {
      border-radius: 50%;
    }

    .sticker-element-star {
      clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 56%, 79% 91%, 50% 70%, 21% 91%, 32% 56%, 2% 35%, 39% 35%);
    }

    .sticker-element-text[data-direction="vertical"] {
      writing-mode: vertical-rl;
      text-orientation: upright;
      letter-spacing: 0;
      white-space: nowrap;
    }

    .sticker-placeholder {
      position: absolute;
      inset: 24px;
      z-index: 8;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: safe center;
      gap: 12px;
      background: var(--sticker-paper);
      color: var(--sticker-ink);
      max-width: 560px;
      max-height: 400px;
      margin: auto;
      border: 1px solid var(--sticker-line);
      border-radius: 10px;
      padding: 20px;
      text-align: center;
      overflow: auto;
      overflow-wrap: anywhere;
      container: sticker-start / size;
    }

    .sticker-canvas.is-empty {
      visibility: hidden;
    }

    .sticker-canvas-wrap.is-vehicle > .sticker-placeholder {
      display: none;
    }

    .sticker-empty-art {
      flex: 0 0 auto;
      width: 52px;
      height: 52px;
      color: var(--sticker-accent);
      transform: rotate(-8deg);
    }

    .custom-sticker-editor .sticker-placeholder h2 {
      flex: 0 0 auto;
      max-width: 100%;
      margin: 0;
      font-size: clamp(18px, 1.7vw, 24px);
      font-weight: 600;
      line-height: 1.3;
      letter-spacing: -.015em;
      text-wrap: balance;
    }

    .custom-sticker-editor .sticker-placeholder p {
      flex: 0 0 auto;
      max-width: 44ch;
      margin: 0;
      color: var(--sticker-muted);
      font-size: 13px;
      line-height: 1.6;
    }

    .sticker-empty-actions {
      flex: 0 0 auto;
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      gap: 8px;
      margin-top: 4px;
    }

    .sticker-entry-notice {
      flex: 0 0 auto;
      max-width: 44ch;
      color: #803b23;
      font-size: 12px;
      line-height: 1.5;
    }

    @container sticker-start (max-height: 180px) {
      .sticker-placeholder:has(.sticker-entry-notice) h2 { display: none; }
    }

    .sticker-empty-actions .btn {
      padding: 9px 16px;
    }

    .sticker-summary {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 12px 28px;
      min-width: 0;
    }

    .sticker-summary > div {
      min-width: 0;
    }

    .sticker-summary .small {
      margin-bottom: 3px;
      font-size: 11px;
    }

    #sticker-price {
      color: var(--sticker-accent);
      font-size: 25px !important;
      line-height: 1.1;
      font-variant-numeric: tabular-nums;
    }

    #sticker-complexity {
      font-size: 13px;
    }

    .sticker-stage-header {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 8px 12px;
      padding: 8px 12px;
      border-bottom: 1px solid var(--sticker-line);
    }

    .sticker-stage-header > :is(.alert, .material-renderer-status) {
      flex: 0 0 100%;
      margin-top: 0 !important;
    }

    .sticker-preview-toolbar {
      display: flex;
      align-items: center;
      flex: 1 1 auto;
      gap: 8px;
      min-width: 0;
    }

    .sticker-stage-toolbar {
      display: flex;
      align-items: center;
      justify-content: space-between;
      flex: 1 1 auto;
      flex-wrap: wrap;
      gap: 8px 12px;
    }

    .sticker-canvas-meta > .text-muted {
      display: none;
    }

    .sticker-stage-actions {
      display: flex;
      align-items: center;
      gap: 8px;
    }

    .sticker-canvas-background-control {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      color: var(--sticker-muted);
      font-size: 12px;
      margin: 0;
    }

    .custom-sticker-editor .sticker-canvas-background-control .form-select {
      width: auto;
      max-width: 160px;
      min-height: 34px;
      font-size: 12px;
      padding-block: 5px;
    }

    .sticker-panel-toggle {
      flex: 0 0 36px;
      width: 36px;
      padding: 6px;
      font-size: 17px !important;
    }

    .sticker-preview-settings-shortcut {
      display: inline-flex;
      align-items: center;
      gap: 5px;
    }

    .sticker-drawing-tools {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 8px;
    }

    .sticker-tool-button {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 34px;
      height: 34px;
      padding: 0;
      flex: 0 0 34px;
    }

    .custom-sticker-editor .sticker-tool-button.active {
      background: var(--sticker-accent-soft);
      border-color: #efc9bd;
      color: var(--sticker-accent);
    }

    .manual-mask-tools {
      display: flex;
      align-items: center;
      gap: 6px;
      height: 34px;
    }

    .manual-mask-tools:has(input:disabled) {
      display: none;
    }

    .manual-mask-tools .form-range {
      width: 72px;
      margin: 0;
    }

    .manual-mask-tools output {
      width: 42px;
      font-size: 12px;
      font-variant-numeric: tabular-nums;
    }

    .manual-mask-session {
      display: flex;
      align-items: center;
      flex: 0 0 auto;
    }

    .manual-mask-session .btn {
      height: 34px;
      min-height: 34px;
      padding-inline: 8px;
      white-space: nowrap;
    }

    .sticker-drawing-tools:has(.manual-mask-session:not(.d-none)) #reset-editor {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 34px;
      height: 34px;
      padding: 0;
    }

    .sticker-drawing-tools:has(.manual-mask-session:not(.d-none)) .sticker-reset-label {
      display: none;
    }

    .sticker-drawing-tools:has(.manual-mask-session:not(.d-none)) #reset-editor .bi {
      margin-right: 0 !important;
    }

    .sticker-ruler-toggle {
      display: inline-flex;
      align-items: center;
      gap: 5px;
      white-space: nowrap;
    }

    .sticker-ruler-toggle[aria-pressed="true"] {
      border-color: rgba(240, 90, 42, .58);
      background: #fff4ef;
      color: #c53e13;
    }

    .sticker-ruler-toggle[aria-pressed="true"]:hover {
      border-color: #f05a2a;
      background: #f05a2a;
      color: #fff;
    }

    .sticker-dimension-reference {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      gap: 6px;
      color: var(--sticker-muted);
      font-size: 12px;
      line-height: 1.3;
    }

    .sticker-dimension-reference-label {
      position: absolute;
      width: 1px;
      height: 1px;
      overflow: hidden;
      clip-path: inset(50%);
      white-space: nowrap;
    }

    .sticker-dimension-reference-value {
      padding: 5px 8px;
      border-radius: 5px;
      background: var(--sticker-mat);
      color: var(--sticker-ink);
      font-size: 13px;
      font-weight: 600;
      font-variant-numeric: tabular-nums;
      white-space: nowrap;
    }

    .sticker-dimension-reference-scale {
      font-size: 11px;
      font-variant-numeric: tabular-nums;
      white-space: nowrap;
    }

    .custom-sticker-editor .sticker-focus-toggle {
      flex: 0 1 auto;
      border: 1px solid var(--sticker-line);
      color: var(--sticker-muted);
      background: #fff;
      padding: 6px 10px;
    }

    .sticker-focus-toggle:hover {
      background: var(--sticker-mat);
    }

    .sticker-focus-toggle::before {
      display: inline-block;
      width: 11px;
      height: 11px;
      border: 1px dashed currentColor;
      content: '';
      margin-right: 6px;
      vertical-align: -1px;
    }

    .sticker-page-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px 16px;
      min-height: 42px;
      margin-bottom: 8px !important;
    }

    .sticker-page-heading {
      display: flex;
      align-items: center;
      gap: 10px;
      min-width: 0;
    }

    .sticker-page-heading h1 {
      margin-bottom: 0 !important;
      font-size: 20px;
      font-weight: 600;
      letter-spacing: -.025em;
    }

    .sticker-page-heading .text-muted {
      display: none;
    }

    .sticker-page-symbol {
      display: grid;
      place-items: center;
      flex: 0 0 32px;
      height: 32px;
      border: 1px solid #edc6b9;
      border-radius: 8px 8px 12px 8px;
      background: var(--sticker-accent-soft);
      color: var(--sticker-accent);
      font-size: 18px;
    }

    .sticker-draft-actions {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      justify-content: flex-end;
      gap: 8px;
      min-width: 0;
    }

    .sticker-guest-link {
      display: block;
      margin-top: 0;
      color: var(--sticker-muted);
      font-size: 11px;
      text-underline-offset: 3px;
    }

    .sticker-action-footer {
      grid-column: 1 / -1;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px 24px;
      min-width: 0;
      padding: 8px 16px;
      border: 1px solid var(--sticker-line);
      border-radius: 9px;
      background: var(--sticker-paper);
    }

    .sticker-shipping-estimate {
      min-width: 0;
      max-width: 30%;
    }

    .sticker-shipping-estimate .fw-bold {
      display: block;
    }

    .sticker-order-actions {
      display: flex;
      align-items: stretch;
      gap: 8px;
      min-width: 0;
      max-width: 54%;
    }

    .sticker-order-actions .btn {
      min-height: 44px;
      padding: 10px 18px;
    }

    .sticker-order-actions .btn-primary {
      min-width: 148px;
      font-weight: 600;
    }

    .sticker-order-actions .sticker-production-trigger {
      padding-inline: 4px;
      color: #795600;
      text-underline-offset: 3px;
    }

    .sticker-preview-mode {
      flex-wrap: wrap;
      gap: 4px;
    }

    .custom-sticker-editor .sticker-preview-mode .btn {
      border: 1px solid transparent;
      border-radius: 6px !important;
      padding: 7px 10px;
      color: var(--sticker-muted);
    }

    .custom-sticker-editor .sticker-preview-mode .btn.active {
      background: var(--sticker-accent-soft);
      border-color: #efc9bd;
      color: #a93619;
    }

    .sticker-workspace-tabs {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      flex: 0 0 auto;
      border-bottom: 1px solid var(--sticker-line);
      padding: 5px 8px 0;
      background: #fbfcfd;
    }

    .sticker-workspace-tabs button {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      gap: 6px;
      position: relative;
      min-width: 0;
      min-height: 72px;
      padding: 10px 5px 12px;
      border: 0;
      background: transparent;
      color: var(--sticker-muted);
      font-size: 12px;
      line-height: 1.4;
      overflow-wrap: anywhere;
    }

    .sticker-workspace-tabs .bi {
      font-size: 19px;
      line-height: 1;
    }

    .sticker-workspace-tabs button:hover {
      color: var(--sticker-ink);
      background: var(--sticker-mat);
    }

    .sticker-workspace-tabs button.active {
      color: var(--sticker-accent);
      font-weight: 600;
    }

    .sticker-workspace-tabs button.active::after {
      position: absolute;
      bottom: -1px;
      right: 16px;
      left: 16px;
      height: 3px;
      border-radius: 3px 3px 0 0;
      background: var(--sticker-accent);
      content: '';
    }

    .sticker-panel-section {
      min-width: 0;
    }

    .sticker-panel-section-title {
      margin-bottom: 16px;
      color: var(--sticker-ink);
      font-size: 16px;
      font-weight: 600;
      line-height: 1.5;
    }

    .sticker-panel-section .form-label {
      margin-bottom: 7px;
      font-size: 13px;
      font-weight: 500 !important;
    }

    .sticker-panel-section .mb-3:last-child {
      margin-bottom: 0 !important;
    }

    .sticker-panel-divider {
      margin: 24px 0 20px;
      border-top: 1px solid var(--sticker-line);
    }

    .sticker-start-grid,
    .sticker-personal-shortcuts {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 10px;
    }

    .custom-sticker-editor .sticker-start-entry {
      display: flex;
      flex-direction: column;
      align-items: flex-start;
      gap: 8px;
      min-width: 0;
      min-height: 108px;
      padding: 12px;
      border-radius: 10px;
      background: #f8fafb;
      text-align: left;
    }

    .sticker-start-entry > .bi {
      color: var(--sticker-muted);
      font-size: 20px;
      line-height: 1;
    }

    .sticker-start-entry > span {
      min-width: 0;
    }

    .sticker-start-entry strong,
    .sticker-start-entry small {
      display: block;
    }

    .sticker-start-entry strong {
      font-size: 14px;
      font-weight: 600;
      line-height: 1.4;
    }

    .sticker-start-entry small {
      margin-top: 4px;
      color: var(--sticker-muted);
      font-size: 12px;
      line-height: 1.5;
    }

    .custom-sticker-editor .sticker-start-ai {
      border-color: #edc6b9;
      background: var(--sticker-accent-soft);
    }

    .sticker-start-ai > .bi,
    .sticker-start-ai strong {
      color: var(--sticker-accent);
    }

    .custom-sticker-editor .sticker-start-ai:hover {
      border-color: var(--sticker-accent);
      background: #ffe8dc;
    }

    .sticker-start-grid > :last-child:nth-child(odd) {
      grid-column: 1 / -1;
      flex-direction: row;
      align-items: center;
      min-height: 64px;
    }

    .sticker-personal-shortcuts {
      margin-top: 12px;
    }

    .sticker-personal-shortcuts > :only-child {
      grid-column: 1 / -1;
    }

    .sticker-personal-shortcuts .btn,
    .sticker-add-shortcuts .btn {
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 6px;
      min-width: 0;
      min-height: 44px;
      padding: 8px 6px;
    }

    .sticker-personal-shortcuts .bi,
    .sticker-add-shortcuts .bi {
      flex-shrink: 0;
      color: var(--sticker-muted);
      font-size: 17px;
      line-height: 1;
    }

    .sticker-add-shortcuts {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 6px;
      margin-top: 16px;
      padding-top: 12px;
      border-top: 1px solid var(--sticker-line);
    }

    .sticker-add-shortcuts .btn {
      flex-direction: column;
      border-color: transparent;
      background: #f8fafb;
      font-size: 12px;
    }

    .sticker-element-panel {
      padding: 16px 0 0;
    }

    .sticker-selection-hint {
      padding: 12px;
      margin-bottom: 16px;
      border-radius: 6px;
      background: var(--sticker-mat);
      color: var(--sticker-muted);
      font-size: 13px;
      line-height: 1.6;
    }

    .custom-sticker-editor.is-focus-mode {
      position: fixed;
      inset: 0;
      z-index: 1040;
      width: 100%;
      height: 100dvh;
      min-height: 100dvh;
      overflow: hidden;
      padding: 8px !important;
      background: #f5f7f9;
    }

    .custom-sticker-editor.is-focus-mode .container {
      display: flex;
      flex-direction: column;
      width: 100%;
      max-width: none;
      height: 100%;
      padding: 0;
    }

    .custom-sticker-editor.is-focus-mode .sticker-page-header {
      flex-shrink: 0;
      justify-content: flex-end;
      margin-bottom: 8px !important;
    }

    .custom-sticker-editor.is-focus-mode .sticker-page-heading {
      display: none;
    }

    .custom-sticker-editor.is-focus-mode .sticker-focus-toggle {
      border-color: #efc9bd;
      background: var(--sticker-accent-soft);
      color: var(--sticker-accent);
    }

    .custom-sticker-editor.is-focus-mode .custom-sticker-shell {
      flex: 1 1 auto;
      height: 0;
    }

    .custom-sticker-editor.is-focus-mode .sticker-canvas-wrap {
      min-height: 0;
      overflow: hidden;
    }

    body.custom-sticker-focus-lock {
      overflow: hidden;
    }

    .cart-confirm-summary {
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
      gap: 16px;
      align-items: start;
    }

    .cart-confirmation-modal .modal-dialog {
      max-width: min(1120px, calc(100% - 24px));
      margin: 12px auto;
      height: calc(100% - 24px);
      min-height: calc(100% - 24px);
    }

    .cart-confirmation-modal .modal-body {
      padding: 16px;
    }

    .cart-confirmation-modal.fade .modal-dialog {
      transition: none;
      transform: none;
    }

    .cart-confirm-pattern,
    .cart-confirm-information {
      min-width: 0;
      padding: 12px;
      border: 1px solid #e5e8eb;
      border-radius: 8px;
      background: #fff;
    }

    .cart-confirm-information {
      display: grid;
      gap: 12px;
      overflow-wrap: anywhere;
    }

    .cart-confirm-label {
      margin-bottom: 5px;
      color: #6b7280;
      font-size: 12px;
      font-weight: 700;
    }

    .cart-confirm-pattern-preview {
      display: flex;
      align-items: center;
      justify-content: center;
      height: clamp(160px, 40dvh, 360px);
      margin-bottom: 8px;
      padding: 10px;
      border: 1px dashed #d8dde3;
      border-radius: 6px;
      background:
        linear-gradient(45deg, #eef0f2 25%, transparent 25%),
        linear-gradient(-45deg, #eef0f2 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, #eef0f2 75%),
        linear-gradient(-45deg, transparent 75%, #eef0f2 75%);
      background-size: 18px 18px;
      background-position: 0 0, 0 9px, 9px -9px, -9px 0;
    }

    .cart-confirm-pattern-preview img {
      display: block;
      max-width: 100%;
      max-height: 100%;
      object-fit: contain;
    }

    .cart-confirm-pattern-text {
      overflow-wrap: anywhere;
      color: #1f2937;
      font-size: 13px;
      font-weight: 700;
      line-height: 1.5;
    }

    .cart-confirm-details {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      align-content: start;
      gap: 10px 12px;
    }

    .cart-confirm-cart-hint {
      margin: 0;
      color: #6b7280;
    }

    .cart-confirm-information .sticker-production-notice {
      margin: 0;
      padding: 10px 12px;
    }

    .cart-confirmation-modal .modal-footer {
      gap: 10px 16px;
      padding: 12px 16px;
    }

    .cart-confirmation-modal .modal-footer > * {
      margin: 0;
    }

    .cart-confirm-draft-hint {
      flex: 0 0 100%;
      padding: 10px 12px;
      border: 1px solid #e9c780;
      border-radius: 6px;
      background: #fff6df;
      color: #704c09;
      line-height: 1.5;
      overflow-wrap: anywhere;
    }

    .cart-confirm-shipping {
      flex: 1 1 240px;
      min-width: 0;
    }

    .cart-confirm-actions {
      display: flex;
      gap: 8px;
    }

    .cart-confirm-actions .btn {
      white-space: normal;
    }

    @media (max-width: 767.98px) {
      .cart-confirmation-modal .modal-header,
      .cart-confirmation-modal .modal-body,
      .cart-confirmation-modal .modal-footer {
        padding: 10px 12px;
      }

      .cart-confirm-summary {
        grid-template-columns: 1fr;
        gap: 10px;
      }

      .cart-confirm-pattern,
      .cart-confirm-information {
        padding: 10px;
      }

      .cart-confirm-information {
        gap: 8px;
      }

      .cart-confirm-details {
        gap: 8px 12px;
      }

      .cart-confirm-pattern-preview {
        height: clamp(96px, 16dvh, 144px);
        padding: 6px;
      }

      .cart-confirmation-modal .modal-footer {
        gap: 8px;
      }

      .cart-confirm-shipping {
        flex-basis: 100%;
      }

      .cart-confirm-actions {
        width: 100%;
      }

      .cart-confirm-actions .btn {
        flex: 1 1 0;
      }
    }

    .sticker-editor-tabs {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 4px;
      background: var(--sticker-mat);
      border: 0 !important;
      border-radius: 7px;
    }

    .sticker-editor-tabs .btn {
      background: #fff;
      border: 1px solid transparent;
      border-radius: 6px;
      min-width: 0;
      white-space: normal;
      overflow-wrap: anywhere;
    }

    .sticker-editor-tabs .btn.active {
      background: #fff;
      border-color: var(--sticker-line);
      color: var(--sticker-accent);
      font-weight: 600;
    }

    .template-action-row {
      gap: 10px;
      flex-wrap: wrap;
    }

    .template-action-row .form-text {
      min-width: 0;
      flex: 1 1 140px;
    }

    .template-action-row .btn {
      flex: 0 1 auto;
      max-width: 100%;
      white-space: normal;
    }

    .template-library-modal .modal-dialog {
      max-width: min(1280px, calc(100vw - 24px));
    }

    .template-library-tools {
      display: grid;
      grid-template-columns: minmax(180px, 1fr);
      gap: 10px;
    }

    .template-library-layout {
      display: grid;
      grid-template-columns: minmax(150px, 220px) minmax(0, 1fr);
      gap: 16px;
    }

    .template-library-layout > div,
    .template-card {
      min-width: 0;
      overflow-wrap: anywhere;
    }

    #template-library-selection {
      flex: 1 1 180px;
      min-width: 0;
      overflow-wrap: anywhere;
    }

    .template-category-list {
      display: grid;
      align-content: start;
      gap: 6px;
      max-height: 58vh;
      overflow: auto;
      border-right: 1px solid #edf0f3;
      padding-right: 12px;
    }

    .template-category-item {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
      border: 1px solid transparent;
      border-radius: 10px;
      background: transparent;
      padding: 9px 10px;
      text-align: left;
      color: #394150;
    }

    .template-category-item:hover,
    .template-category-item.is-active {
      border-color: #111;
      background: #111;
      color: #fff;
    }

    .template-category-count {
      border-radius: 999px;
      background: rgba(17, 24, 39, .08);
      padding: 1px 8px;
      font-size: 12px;
    }

    .template-category-item.is-active .template-category-count,
    .template-category-item:hover .template-category-count {
      background: rgba(255, 255, 255, .18);
    }

    .template-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
      gap: 12px;
      max-height: 58vh;
      overflow: auto;
      padding: 2px;
      align-content: start;
    }

    .template-card[hidden], .template-card-container[hidden] {
      display: none;
    }

    .template-card-container { position: relative; display: flex; flex-direction: column; min-width: 0; }
    .template-card-container .template-card { flex: 1; width: 100%; }
    .template-preview-trigger {
      position: absolute; top: 16px; right: 16px; z-index: 1; display: inline-flex; align-items: center; justify-content: center;
      width: 40px; height: 40px; padding: 0; border: 1px solid #e1e5ea; border-radius: 50%;
      background: rgba(255, 255, 255, .96); color: #344054; box-shadow: 0 2px 8px rgba(17, 24, 39, .12); cursor: zoom-in;
      transition: background-color .15s ease, border-color .15s ease, box-shadow .15s ease;
    }
    .template-preview-trigger .bi { font-size: 16px; line-height: 1; }
    .template-preview-trigger:hover { background: #fff; border-color: #697386; box-shadow: 0 3px 10px rgba(17, 24, 39, .18); }
    .template-preview-trigger:focus-visible { outline: 2px solid #111; outline-offset: 2px; }

    .template-card {
      display: flex;
      min-height: 188px;
      flex-direction: column;
      gap: 8px;
      border: 1px solid #e1e5ea;
      border-radius: 12px;
      background: #fff;
      padding: 10px;
      text-align: left;
      transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
    }

    .template-card:hover,
    .template-card:focus {
      border-color: #111;
      box-shadow: 0 12px 28px rgba(17, 24, 39, .12);
      transform: translateY(-1px);
    }

    .template-card.is-selected {
      border-color: #111;
      box-shadow: 0 0 0 2px #111 inset;
    }

    .template-card-preview {
      display: flex;
      width: 100%;
      height: 112px;
      flex-shrink: 0;
      align-items: center;
      justify-content: center;
      overflow: hidden;
      border-radius: 10px;
      background: #9e9e9e;
    }

    .template-card-preview img {
      display: block;
      max-width: 92%;
      max-height: 92%;
      object-fit: contain;
    }

    .template-card-preview [hidden], .template-image-retry[hidden] { display: none !important; }
    .template-image-status { padding: 10px; color: #fff; font-size: 12px; text-align: center; }
    .template-image-retry { position: absolute; top: 92px; left: 50%; transform: translateX(-50%); z-index: 2; }

    .template-card-title {
      font-weight: 700;
      line-height: 1.2;
    }

    .template-card-meta {
      color: #6b7280;
      font-size: 12px;
      line-height: 1.3;
    }

    .template-library-empty {
      display: none;
      border: 1px dashed #cfd4da;
      border-radius: 12px;
      padding: 28px;
      text-align: center;
      color: #6b7280;
    }

    .template-library-empty .bi {
      display: block;
      margin-bottom: 12px;
      font-size: 36px;
      color: #9ba8b7;
    }

    .template-library-empty.is-visible {
      display: block;
    }

    .image-library-modal .modal-dialog {
      max-width: min(1040px, calc(100vw - 24px));
    }

    .sticker-font-picker {
      position: relative;
      margin-bottom: .5rem;
    }

    .sticker-font-picker-native {
      position: absolute;
      width: 1px;
      height: 1px;
      opacity: 0;
      pointer-events: none;
    }

    /* 与选项行同构：样张 / 名称 / 箭头三列，样张区定宽裁切。 */
    .sticker-font-picker-trigger {
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto 12px;
      align-items: center;
      gap: 8px;
      width: 100%;
      min-height: 34px;
      padding: 4px 8px;
      border: 1px solid #d9dee3;
      border-radius: 6px;
      background: #fff;
      color: #20262d;
      font-size: 13px;
      text-align: left;
      line-height: 1.2;
    }

    .sticker-font-picker-trigger:hover:not(:disabled) {
      border-color: #adb5bd;
    }

    .sticker-font-picker-trigger:focus-visible {
      outline: 2px solid #20262d;
      outline-offset: 1px;
    }

    .sticker-font-picker.is-disabled .sticker-font-picker-trigger {
      background: #eef1f3;
      color: #9aa1a9;
      cursor: not-allowed;
    }

    .sticker-font-picker.is-disabled .sticker-font-picker-sample {
      opacity: .45;
    }

    /*
      样张图由服务端按固定画布和固定基线渲染，各字体高度一致。这里只锁定显示
      高度、禁止任何缩放（max-width: none），否则同一字号会被缩成不同大小、
      基线也会重新错开。过长的样张交给容器裁切并右侧渐隐，不做等比缩小。
    */
    .sticker-font-picker-sample {
      display: block;
      height: 21px;
      width: auto;
      max-width: none;
      flex: 0 0 auto;
    }

    .sticker-font-picker-sample-zone {
      position: relative;
      min-width: 0;
      overflow: hidden;
      display: flex;
      align-items: center;
    }

    /* 样张超出可视宽度时右侧渐隐，避免出现硬切边。 */
    .sticker-font-picker-sample-zone::after {
      content: "";
      position: absolute;
      top: 0;
      right: 0;
      bottom: 0;
      width: 20px;
      background: linear-gradient(to right, rgba(255, 255, 255, 0), #fff);
      opacity: 0;
      pointer-events: none;
    }

    .sticker-font-picker-sample-zone.is-overflowing::after {
      opacity: 1;
    }

    .sticker-font-picker-option:hover .sticker-font-picker-sample-zone::after,
    .sticker-font-picker-option.is-active .sticker-font-picker-sample-zone::after,
    .sticker-font-picker-option[aria-selected="true"] .sticker-font-picker-sample-zone::after {
      background: linear-gradient(to right, rgba(242, 244, 246, 0), #f2f4f6);
    }

    .sticker-font-picker-label,
    .sticker-font-picker-name {
      min-width: 0;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .sticker-font-picker-label {
      max-width: 132px;
      color: #6b7280;
      font-size: 12px;
    }

    .sticker-font-picker-caret {
      justify-self: end;
      color: #6b7280;
      font-size: 12px;
    }

    .sticker-font-picker-trigger .sticker-font-picker-sample-zone {
      height: 22px;
    }

    .sticker-font-picker-trigger .sticker-font-picker-sample-zone::after {
      background: linear-gradient(to right, rgba(255, 255, 255, 0), #fff);
    }

    .sticker-font-picker.is-disabled .sticker-font-picker-sample-zone::after {
      background: linear-gradient(to right, rgba(238, 241, 243, 0), #eef1f3);
    }

    /*
      用 fixed 而不是 absolute：选择器位于 .sticker-panel-scroll 内，那个容器是
      overflow: auto，absolute 面板会被它垂直裁切，且面板一旦宽于侧栏内容区
      （280~340px 减去内边距）就会撑出横向滚动条。fixed 脱离该裁切上下文，
      位置和宽度由 JS 按触发按钮实时计算。
    */
    /*
       `hidden` 的 UA 样式会被下面的 display: flex 覆盖，面板因此常驻可见，
       WebP 样张也会在每次刷新时被懒加载。显式补一条隐藏规则。
    */
    .sticker-font-picker-panel[hidden] {
      display: none;
    }

    .sticker-font-picker-panel {
      position: fixed;
      z-index: 1080;
      display: flex;
      flex-direction: column;
      max-height: 340px;
      border: 1px solid #d9dee3;
      border-radius: 8px;
      background: #fff;
      box-shadow: 0 12px 28px rgba(15, 23, 32, .16);
      overflow: hidden;
    }

    .sticker-font-picker-search {
      display: flex;
      align-items: center;
      gap: 6px;
      flex: 0 0 auto;
      padding: 8px;
      border-bottom: 1px solid #edf0f3;
      color: #6b7280;
    }

    .sticker-font-picker-search input {
      width: 100%;
      border: 0;
      outline: 0;
      background: transparent;
      color: #20262d;
      font-size: 13px;
    }

    .sticker-font-picker-list {
      flex: 1 1 auto;
      overflow-y: auto;
      padding: 4px;
    }

    /*
      固定三列：样张 / 名称 / 勾选。名称列定宽，保证所有名称左边缘对齐，
      不随样张宽度浮动。
    */
    .sticker-font-picker-option {
      display: grid;
      grid-template-columns: minmax(0, 1fr) 104px 14px;
      align-items: center;
      gap: 8px;
      width: 100%;
      padding: 6px 8px;
      border: 0;
      border-radius: 6px;
      background: transparent;
      text-align: left;
    }

    .sticker-font-picker-option[hidden] {
      display: none;
    }

    .sticker-font-picker-option:hover,
    .sticker-font-picker-option.is-active {
      background: #f2f4f6;
    }

    .sticker-font-picker-option .sticker-font-picker-sample {
      height: 24px;
    }

    .sticker-font-picker-option .sticker-font-picker-sample-zone {
      height: 26px;
    }

    .sticker-font-picker-sample-fallback {
      font-size: 15px;
      font-weight: 700;
    }

    .sticker-font-picker-name {
      color: #6b7280;
      font-size: 11px;
      line-height: 1.3;
    }

    .sticker-font-picker-check {
      justify-self: end;
      color: #20262d;
      font-size: 13px;
      visibility: hidden;
    }

    .sticker-font-picker-option[aria-selected="true"] .sticker-font-picker-check {
      visibility: visible;
    }

    .sticker-font-picker-option[aria-selected="true"] {
      background: #eef1f3;
    }

    .sticker-font-picker-empty {
      padding: 18px 8px;
      color: #9aa1a9;
      font-size: 12px;
      text-align: center;
    }

    .sticker-file-input {
      position: relative;
      display: flex;
      align-items: center;
      min-width: 0;
      padding: 0;
      overflow: hidden;
    }

    .sticker-file-input:focus-within {
      outline: 2px solid #ff4d14;
      outline-offset: 2px;
    }

    .sticker-file-control {
      position: absolute;
      inset: 0;
      z-index: 1;
      width: 100%;
      height: 100%;
      opacity: 0;
      cursor: pointer;
    }

    .sticker-file-control:disabled {
      cursor: default;
    }

    .sticker-file-button {
      flex: 0 1 auto;
      max-width: 55%;
      padding: .5rem .65rem;
      border-right: 1px solid #d8dde3;
      background: #f7f8f9;
      overflow-wrap: anywhere;
    }

    .sticker-file-name {
      flex: 1;
      min-width: 0;
      padding: .5rem .65rem;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .ai-sticker-modal .modal-dialog {
      max-width: min(680px, calc(100vw - 24px));
    }

    .ai-sticker-fields {
      display: grid;
      grid-template-columns: minmax(0, 1fr);
      gap: 12px;
    }

    .ai-ideas {
      margin-top: 16px;
      padding: 14px;
      border: 1px solid #e2e6ec;
      border-radius: 12px;
      background: #f7f8fa;
    }

    .ai-idea-categories {
      display: flex;
      flex-wrap: wrap;
      gap: 6px;
      margin: 12px 0;
    }

    .ai-idea-category {
      padding: 5px 10px;
      border: 1px solid #dce2e9;
      border-radius: 20px;
      background: #fff;
      color: #4b5563;
      font-size: 12px;
    }

    .ai-idea-category[aria-pressed="true"] {
      border-color: #253246;
      background: #253246;
      color: #fff;
    }

    .ai-idea-group {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 8px;
    }

    .ai-idea-group[hidden] { display: none; }

    .ai-idea {
      min-width: 0;
      padding: 12px;
      border: 1px solid #dce2e9;
      border-radius: 8px;
      background: #fff;
      color: #253246;
      text-align: left;
      overflow-wrap: anywhere;
    }

    .ai-idea strong { display: block; margin-bottom: 6px; font-size: 13px; }
    .ai-idea span { display: block; color: #5f6873; font-size: 12px; line-height: 1.6; }
    .ai-idea:hover:not(:disabled),
    .ai-idea[aria-pressed="true"] { border-color: #536c91; background: #edf3ff; }
    .ai-idea:focus-visible,
    .ai-idea-category:focus-visible { outline: 3px solid #536c91; outline-offset: 2px; }
    .ai-ideas button:disabled { opacity: .55; cursor: wait; }

    @media (max-width: 575.98px) {
      .ai-idea-group { grid-template-columns: minmax(0, 1fr); }
    }

    .ai-generation-expectation {
      display: flex;
      align-items: flex-start;
      gap: 8px;
      margin-top: 10px;
      color: #5f6873;
      font-size: 13px;
      line-height: 1.5;
    }

    .ai-generation-expectation .bi {
      flex: 0 0 auto;
      margin-top: 1px;
      color: #303840;
    }

    .ai-generation-status {
      margin-top: 16px;
      padding: 14px;
      border: 1px solid #d8dde3;
      border-radius: 6px;
      background: #f8fafb;
    }

    .ai-generation-status[hidden] {
      display: none;
    }

    .ai-generation-status-head {
      display: grid;
      grid-template-columns: auto minmax(0, 1fr) auto;
      gap: 10px;
      align-items: center;
    }

    .ai-generation-spinner {
      width: 22px;
      height: 22px;
      border-width: 2px;
    }

    .ai-generation-status-title {
      color: #20262d;
      font-size: 14px;
      font-weight: 700;
      line-height: 1.4;
    }

    .ai-generation-status-detail {
      margin-top: 2px;
      color: #68717c;
      font-size: 12px;
      line-height: 1.45;
    }

    .ai-generation-elapsed {
      color: #303840;
      font-size: 12px;
      font-variant-numeric: tabular-nums;
      white-space: nowrap;
    }

    .ai-generation-progress {
      height: 5px;
      margin-top: 12px;
      overflow: hidden;
      border-radius: 2px;
      background: #e4e8ec;
    }

    .ai-generation-progress-bar {
      width: 34%;
      height: 100%;
      background: #303840;
      animation: ai-generation-progress 1.7s ease-in-out infinite;
    }

    .ai-generation-note {
      display: flex;
      align-items: flex-start;
      gap: 7px;
      margin-top: 10px;
      color: #5f6873;
      font-size: 12px;
      line-height: 1.45;
    }

    .ai-generation-status.is-error {
      border-color: #e6b8b8;
      background: #fff8f8;
    }

    .ai-generation-status.is-error .ai-generation-status-title,
    .ai-generation-status.is-error .ai-generation-note {
      color: #a12622;
    }

    .ai-generation-status.is-error .ai-generation-spinner,
    .ai-generation-status.is-error .ai-generation-progress,
    .ai-generation-status.is-error .ai-generation-elapsed {
      display: none;
    }

    .ai-sticker-modal.is-generating .modal-content {
      cursor: wait;
    }

    .ai-sticker-modal.is-generating .ai-sticker-fields,
    .ai-sticker-modal.is-generating #ai-sticker-prompt {
      opacity: .64;
    }

    .ai-sticker-reference-preview {
      display: flex;
      align-items: center;
      gap: 10px;
      margin-top: 10px;
    }

    .ai-sticker-reference-preview[hidden] {
      display: none;
    }

    .ai-sticker-reference-preview img {
      width: 64px;
      height: 64px;
      border: 1px solid #d9dee3;
      border-radius: 6px;
      object-fit: cover;
    }

    @keyframes ai-generation-progress {
      from {
        transform: translateX(-110%);
      }

      to {
        transform: translateX(320%);
      }
    }

    @media (prefers-reduced-motion: reduce) {
      .ai-generation-progress-bar {
        width: 100%;
        animation: none;
      }
    }

    .image-library-tools {
      display: grid;
      grid-template-columns: minmax(180px, 1fr) auto;
      gap: 10px;
    }

    .image-library-upload {
      display: grid;
      grid-template-columns: auto minmax(0, 1fr);
      align-items: center;
      gap: 10px;
      border: 1px solid #edf0f3;
      border-radius: 12px;
      background: #fbfcfd;
      padding: 12px;
    }

    .image-library-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
      gap: 12px;
      max-height: 55vh;
      overflow: auto;
      padding: 2px;
    }

    .image-library-card {
      display: flex;
      min-width: 0;
      min-height: 184px;
      flex-direction: column;
      gap: 8px;
      border: 1px solid #e1e5ea;
      border-radius: 12px;
      background: #fff;
      padding: 10px;
      text-align: left;
      transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
    }

    .image-library-card:hover,
    .image-library-card:focus {
      border-color: #111;
      box-shadow: 0 12px 28px rgba(17, 24, 39, .12);
      transform: translateY(-1px);
    }

    .image-library-card.is-selected {
      border-color: #111;
      box-shadow: 0 0 0 2px #111 inset;
    }

    .image-library-preview {
      display: flex;
      aspect-ratio: 1 / 1;
      align-items: center;
      justify-content: center;
      overflow: hidden;
      border-radius: 10px;
      background:
        linear-gradient(45deg, #edf0f3 25%, transparent 25%),
        linear-gradient(-45deg, #edf0f3 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, #edf0f3 75%),
        linear-gradient(-45deg, transparent 75%, #edf0f3 75%);
      background-size: 18px 18px;
      background-position: 0 0, 0 9px, 9px -9px, -9px 0;
    }

    .image-library-preview img {
      display: block;
      max-width: 92%;
      max-height: 92%;
      object-fit: contain;
    }

    .image-library-title {
      display: block;
      min-width: 0;
      max-width: 100%;
      overflow: hidden;
      font-weight: 700;
      line-height: 1.2;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .image-library-meta {
      color: #6b7280;
      font-size: 12px;
      line-height: 1.3;
    }

    #image-library-selection {
      flex: 1 1 180px;
      min-width: 0;
      max-width: 100%;
      overflow-wrap: anywhere;
    }

    .image-library-empty {
      display: none;
      border: 1px dashed #cfd4da;
      border-radius: 12px;
      padding: 28px;
      text-align: center;
      color: #6b7280;
    }

    .image-library-empty.is-visible {
      display: block;
    }

    @media (max-width: 420px) {
      .template-action-row {
        align-items: flex-start !important;
        flex-direction: column;
      }

      .template-library-tools,
      .image-library-tools,
      .image-library-upload {
        grid-template-columns: 1fr;
      }

      .ai-sticker-fields {
        grid-template-columns: 1fr;
      }

      .ai-generation-status-head {
        grid-template-columns: auto minmax(0, 1fr);
      }

      .ai-generation-elapsed {
        grid-column: 2;
      }

      .template-library-layout {
        grid-template-columns: 1fr;
      }

      .template-category-list {
        display: flex;
        max-height: none;
        border-right: 0;
        padding-right: 0;
        overflow: auto;
      }

      .template-category-item {
        flex: 0 0 auto;
        white-space: nowrap;
      }
    }

    .layer-list {
      display: grid;
      gap: 6px;
      max-height: 340px;
      overflow: auto;
    }

    .layer-item {
      border: 1px solid #e7e9ec;
      border-radius: 6px;
      padding: 7px 9px;
      background: #fff;
      text-align: left;
      font-size: 13px;
      cursor: grab;
    }

    .layer-item.active {
      border-color: var(--sticker-accent);
      background: var(--sticker-accent-soft);
    }

    .layer-item.dragging {
      opacity: .45;
      cursor: grabbing;
    }

    .layer-item.drop-before {
      box-shadow: inset 0 2px 0 #111;
    }

    .layer-item.drop-after {
      box-shadow: inset 0 -2px 0 #111;
    }

    @media (min-width: 992px) {
      .custom-sticker-editor.is-panel-collapsed .custom-sticker-shell {
        grid-template-columns: minmax(0, 1fr);
      }

      .custom-sticker-editor.is-panel-collapsed .custom-sticker-panel {
        display: none;
      }
    }

    @media (max-width: 1199.98px) and (min-width: 992px) {
      .custom-sticker-editor > .container {
        padding-right: 8px;
        padding-left: 8px;
      }

      .custom-sticker-shell {
        grid-template-columns: 272px minmax(0, 1fr);
      }

      .sticker-summary {
        gap: 12px 20px;
      }
    }

    @media (max-width: 991.98px) {
      .sticker-page-header {
        flex-wrap: wrap;
      }

      .sticker-draft-actions {
        max-width: 100%;
      }

      .custom-sticker-shell {
        height: auto;
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto auto auto;
      }

      .custom-sticker-stage {
        order: 1;
        height: auto;
      }

      .sticker-canvas-wrap {
        height: clamp(320px, 60dvh, 640px);
        padding: 12px !important;
      }

      .sticker-canvas-wrap.is-vehicle {
        height: auto;
        aspect-ratio: 16 / 9;
      }

      .sticker-panel-toggle {
        display: none;
      }

      .sticker-canvas {
        width: min(100%, 760px);
      }

      .custom-sticker-panel {
        order: 2;
        height: auto;
        max-height: none;
        scroll-margin-top: 12px;
      }

      .sticker-workspace-tabs button {
        min-height: 64px;
      }

      .sticker-panel-scroll {
        flex: 0 1 auto;
        max-height: min(560px, 64dvh);
        padding: 20px;
      }

      .sticker-action-footer {
        position: sticky;
        bottom: 8px;
        z-index: 20;
        order: 3;
        padding: 12px 16px;
        box-shadow: 0 -4px 20px #2533440a;
      }

      .sticker-order-actions .btn {
        padding-right: 12px;
        padding-left: 12px;
      }

      .vehicle-preview-controls {
        grid-template-columns: repeat(2, minmax(0, 1fr));
      }

      .vehicle-preview-actions {
        justify-content: flex-start;
        padding-top: 0;
      }

      .custom-sticker-editor.is-focus-mode {
        padding: 8px !important;
        overflow: auto;
      }

      .custom-sticker-editor.is-focus-mode .container {
        display: block;
        height: auto;
        min-height: 100%;
      }

      .custom-sticker-editor.is-focus-mode .custom-sticker-shell {
        height: auto;
      }
    }

    @media (max-width: 575.98px) {
      .custom-sticker-editor {
        padding-top: 6px !important;
      }

      .custom-sticker-editor > .container {
        padding-right: 8px;
        padding-left: 8px;
      }

      .sticker-page-header {
        gap: 6px;
      }

      .sticker-page-heading {
        gap: 6px;
      }

      .sticker-page-heading h1 {
        font-size: 18px;
      }

      .sticker-page-symbol {
        flex-basis: 28px;
        height: 28px;
        font-size: 16px;
      }

      .sticker-draft-actions {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 6px;
      }

      .sticker-guest-link {
        margin-top: 0;
      }

      .sticker-stage-header {
        padding: 8px;
      }

      .sticker-preview-toolbar {
        flex-wrap: nowrap;
        gap: 6px;
        flex-basis: 100%;
      }

      .sticker-preview-mode {
        display: grid;
        grid-auto-flow: column;
        grid-auto-columns: minmax(0, 1fr);
        flex: 1 1 auto;
        min-width: 0;
      }

      .custom-sticker-editor .sticker-preview-mode .btn {
        width: 100%;
        padding: 7px 5px;
      }

      .custom-sticker-editor .sticker-focus-toggle {
        flex: 0 0 36px;
        min-height: 40px;
        padding: 6px;
        font-size: 0;
      }

      .sticker-focus-toggle::before {
        width: 14px;
        height: 14px;
        margin-right: 0;
      }

      .sticker-stage-toolbar {
        gap: 8px;
      }

      .sticker-stage-actions {
        margin-left: auto;
        justify-content: flex-end;
        gap: 6px;
      }

      .sticker-drawing-tools {
        gap: 6px;
      }

      .sticker-canvas-wrap {
        height: clamp(320px, calc(100dvw - 12px), 540px);
        padding: 8px !important;
      }

      .sticker-placeholder {
        inset: 12px;
        gap: 10px;
        padding: 16px;
      }

      .sticker-empty-art {
        width: 52px;
        height: 52px;
      }

      .sticker-empty-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
        max-width: 310px;
      }

      .sticker-empty-actions .btn {
        min-height: 44px;
        padding: 8px 10px;
      }

      .sticker-empty-actions > :last-child {
        grid-column: 1 / -1;
      }

      .sticker-panel-scroll {
        padding: 16px;
        scroll-padding-bottom: 12px;
      }

      .sticker-action-footer {
        bottom: 0;
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 10px;
        padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px));
        border-radius: 10px 10px 0 0;
      }

      .sticker-summary {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 6px 14px;
      }

      .sticker-summary-price {
        display: flex;
        align-items: baseline;
        gap: 8px;
      }

      .sticker-summary-complexity {
        display: flex;
        align-items: baseline;
        justify-content: flex-end;
        flex-wrap: wrap;
        gap: 0 6px;
      }

      #sticker-price {
        font-size: 22px !important;
      }

      #sticker-complexity {
        font-size: 12px;
      }

      .sticker-shipping-estimate {
        max-width: none;
      }

      .sticker-shipping-estimate .fw-bold {
        display: inline;
      }

      .sticker-order-actions {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        max-width: none;
        gap: 8px;
      }

      .sticker-order-actions .btn {
        min-width: 0;
        min-height: 44px;
        padding: 8px;
        font-size: 12px;
      }

      .material-simulation-controls {
        grid-template-columns: 1fr;
        gap: 8px;
      }

      .material-preview-switch {
        align-items: flex-start;
        flex-direction: column;
        gap: 6px;
      }

      .vehicle-preview-controls {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
      }

      #vehicle-scene-field,
      #vehicle-light-control,
      .vehicle-preview-actions {
        grid-column: 1 / -1;
      }

      .vehicle-preview-actions {
        justify-content: space-between;
        padding-top: 0;
      }

      .vehicle-detail-preview {
        width: clamp(132px, 44vw, 172px);
        padding: 8px;
      }

      .material-preview-disclaimer {
        white-space: normal;
      }
    }

    @media (prefers-reduced-motion: reduce) {
      .custom-sticker-editor *,
      .custom-sticker-editor *::before,
      .custom-sticker-editor *::after {
        scroll-behavior: auto !important;
        transition: none !important;
        animation: none !important;
      }
    }


  .custom-sticker-stage { position: relative; }
  .sticker-preview-settings {
    position: absolute;
    z-index: 35;
    top: 62px;
    right: 12px;
    width: min(320px, calc(100% - 24px));
    max-height: calc(100% - 80px);
    overflow: auto;
    overscroll-behavior: contain;
    padding: 18px;
    border: 1px solid var(--sticker-line);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 8px 28px #25334424;
  }
  .sticker-preview-close { position: absolute; top: 14px; right: 12px; }
  .custom-sticker-editor .sticker-rotate-handle { touch-action: none; }
  .custom-sticker-editor :is(.sticker-preview-settings-shortcut, .sticker-ruler-toggle, .sticker-guest-link, #save-design) { display: inline-flex; align-items: center; justify-content: center; text-align: center; }
  .custom-sticker-editor :is(.sticker-preview-settings-shortcut, .sticker-ruler-toggle) .bi { display: inline-flex; align-items: center; justify-content: center; line-height: 1; }
  .custom-sticker-editor :is(.sticker-preview-settings-shortcut, .sticker-ruler-toggle) .bi::before { display: block; }
  .sticker-preview-settings .sticker-panel-section-title { padding-right: 32px; }
  .sticker-preview-settings .vehicle-preview-controls { grid-template-columns: minmax(0, 1fr); }
  .sticker-preview-settings .material-simulation-controls { grid-template-columns: minmax(0, 1fr); }
  .sticker-preview-settings .material-preview-switch { margin-top: 8px; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px; }
  .sticker-mobile-panel-toggle { display: none; }
  .sticker-panel-navigation { display: contents; }
  .sticker-return-canvas-label { display: none; }
  .sticker-mode-label-short { display: none; }
  .custom-sticker-editor #sticker-price[aria-busy="true"], .custom-sticker-editor #sticker-price:has(+ #retry-sticker-quote:not(.d-none)) { font-size: 14px !important; }

  .sticker-more-actions, .sticker-more-actions-list { display: contents; }
  .sticker-more-toggle { display: none; }

  .custom-sticker-editor .sticker-layer-range-control { touch-action: pan-y pinch-zoom; }
  .custom-sticker-editor .sticker-layer-range { --sticker-range-thumb-size: 24px; display: block; pointer-events: none; }
  .custom-sticker-editor .sticker-layer-range::-webkit-slider-thumb { width: var(--sticker-range-thumb-size); height: var(--sticker-range-thumb-size); margin-top: -8px; }
  .custom-sticker-editor .sticker-layer-range::-moz-range-thumb { width: var(--sticker-range-thumb-size); height: var(--sticker-range-thumb-size); }
  @media (any-pointer: coarse) {
    .custom-sticker-editor .sticker-layer-range { min-height: 44px; }
  }

  @media (max-width: 991.98px) {
    .custom-sticker-editor { min-height: 0; }
    .custom-sticker-editor .sticker-page-header { flex-wrap: nowrap; gap: 8px; margin-bottom: 6px !important; }
    .custom-sticker-editor .sticker-page-heading { min-width: 0; }
    .custom-sticker-editor .sticker-page-heading h1 { min-width: 0; font-size: clamp(14px, 4vw, 16px); margin: 0 !important; white-space: normal; overflow-wrap: anywhere; line-height: 1.3; text-wrap: balance; }
    .custom-sticker-editor .sticker-page-symbol { display: none; }
    .custom-sticker-editor .sticker-draft-actions { flex-wrap: nowrap; gap: 6px; margin-left: auto; }
    .custom-sticker-editor .sticker-draft-actions .btn { min-height: 44px; }
    .sticker-more-actions { display: block; position: relative; }
    .custom-sticker-editor .sticker-more-toggle { display: block; width: 44px; padding: 8px; }
    .sticker-more-actions-list { display: none; }
    .sticker-more-actions.is-open .sticker-more-actions-list {
      position: absolute; display: grid; gap: 6px; top: calc(100% + 6px); right: 0;
      width: 210px; padding: 8px; z-index: 50; border: 1px solid var(--sticker-line);
      border-radius: 12px; background: #fff; box-shadow: 0 8px 28px #25334424;
    }
    .custom-sticker-editor .sticker-more-actions-list .btn { text-align: left; width: 100%; font-size: 13px; }
    .custom-sticker-editor .sticker-more-actions-list .sticker-focus-toggle { font-size: 13px; flex: auto; padding: 8px 12px; }
    .sticker-more-actions-list .sticker-focus-toggle::before { margin-right: 8px; }
    .custom-sticker-editor .custom-sticker-shell {
      height: var(--sticker-workbench-height, calc(100dvh - 130px));
      min-height: 160px;
      grid-template-rows: minmax(130px, 1fr) minmax(220px, 44%) auto;
      gap: 6px;
    }
    .custom-sticker-editor.is-panel-collapsed .custom-sticker-shell { grid-template-rows: minmax(130px, 1fr) 52px auto; }
    .custom-sticker-editor .custom-sticker-stage { min-height: 0; height: 100%; display: flex; flex-direction: column; }
    .custom-sticker-editor .sticker-stage-header { flex: 0 0 auto; padding: 4px; gap: 4px; }
    .custom-sticker-editor .sticker-preview-toolbar { flex-basis: 100%; gap: 4px; flex-wrap: nowrap; }
    .custom-sticker-editor .sticker-preview-mode { display: flex; flex-wrap: nowrap; flex: 1; }
    .custom-sticker-editor .sticker-preview-mode .btn { flex: 1; font-size: 12px; min-height: 44px; padding: 4px 3px; }
    .sticker-mode-label-full { display: none; }
    .sticker-mode-label-short { display: inline; }
    .custom-sticker-editor .sticker-stage-toolbar { gap: 0; flex-basis: 100%; min-width: 0; }
    .custom-sticker-editor .sticker-canvas-meta { display: none; }
    .custom-sticker-editor .sticker-stage-actions { gap: 4px; margin-left: 0; width: 100%; flex-wrap: nowrap !important; }
    .custom-sticker-editor .sticker-stage-actions .btn { min-height: 44px; min-width: 44px; padding: 6px; }
    .custom-sticker-editor .sticker-drawing-tools { gap: 4px; flex: 1; min-width: 0; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
    .custom-sticker-editor .sticker-drawing-tools > * { flex-shrink: 0; }
    .custom-sticker-editor .sticker-drawing-tools .btn-group { gap: 0; }
    .custom-sticker-editor .sticker-reset-label, .custom-sticker-editor .sticker-ruler-toggle span { display: none; }
    .custom-sticker-editor #reset-editor .bi { margin-right: 0 !important; }
    .custom-sticker-editor #canvas-background-control { display: none; }
    .custom-sticker-editor .sticker-preview-label-short { display: none; }
    .custom-sticker-editor .sticker-canvas-wrap,
    .custom-sticker-editor .sticker-canvas-wrap.is-vehicle {
      height: auto; min-height: 0; flex: 1 1 auto; aspect-ratio: auto;
      overflow: hidden; padding: 12px !important;
    }
    .custom-sticker-editor .custom-sticker-panel {
      position: relative; min-height: 0; height: 100%; max-height: 100%; border-radius: 14px 14px 8px 8px;
    }
    .custom-sticker-editor .sticker-workspace-tabs { min-height: 50px; padding: 0 46px 0 4px; }
    .custom-sticker-editor .sticker-workspace-tabs button { min-height: 50px; flex-direction: row; gap: 5px; padding: 4px; }
    .custom-sticker-editor .sticker-workspace-tabs .bi { font-size: 17px; }
    .custom-sticker-editor .sticker-mobile-panel-toggle { display: block; position: absolute; top: 3px; right: 2px; width: 44px; min-height: 44px; padding: 8px !important; }
    .custom-sticker-editor .sticker-panel-scroll { flex: 1 1 auto; min-height: 0; max-height: none; padding: 12px 14px 20px; scroll-padding-block: 12px; }
    .custom-sticker-editor.is-panel-collapsed .sticker-panel-scroll { display: none; }
    .custom-sticker-editor.is-panel-collapsed .sticker-mobile-panel-toggle i { display: block; transform: rotate(180deg); }
    .custom-sticker-editor.is-panel-collapsed .sticker-workspace-tabs { border-bottom: 0; }
    .custom-sticker-editor.is-panel-collapsed .sticker-workspace-tabs button.active::after { display: none; }
    .custom-sticker-editor .sticker-panel-section-title { margin-bottom: 10px; font-size: 14px; }
    .custom-sticker-editor #workspace-edit > .sticker-panel-section-title { display: none; }
    .custom-sticker-editor .sticker-editor-tabs { position: sticky; top: -12px; background: #fff; z-index: 2; }
    .custom-sticker-editor .sticker-panel-scroll :is(.btn, .form-control, .form-select) { min-height: 44px; }
    .custom-sticker-editor :is(.form-control, .form-select) { font-size: 16px; }
    .custom-sticker-editor .sticker-font-picker-search input { min-height: 44px; font-size: 16px; }
    .custom-sticker-editor .form-range { min-height: 36px; }
    .custom-sticker-editor .sticker-layer-range { min-height: 44px; }
    .custom-sticker-editor .sticker-rotate-handle::after { content: ''; position: absolute; inset: -8px; border-radius: 50%; }
    .custom-sticker-editor .layer-list { max-height: none; overflow: visible; }
    .custom-sticker-editor .sticker-action-footer {
      position: static; display: grid; grid-template-columns: minmax(0, 1fr) auto;
      align-items: center; gap: 4px 8px;
      padding: 4px 10px max(6px, env(safe-area-inset-bottom, 0px));
    }
    .custom-sticker-editor .sticker-summary { display: block; }
    .custom-sticker-editor .sticker-summary-price { flex-wrap: wrap; gap: 0 6px; }
    .custom-sticker-editor .sticker-summary-complexity, .custom-sticker-editor .sticker-shipping-estimate { display: none !important; }
    .custom-sticker-editor .sticker-order-actions { display: flex; gap: 4px; max-width: none; }
    .custom-sticker-editor .sticker-order-actions .btn { min-height: 44px; padding: 6px 8px; white-space: nowrap; }
    .custom-sticker-editor .sticker-production-trigger { font-size: 11px; }
    .custom-sticker-editor #sticker-price { font-size: 20px !important; }
    .custom-sticker-editor .sticker-mobile-preview-host { grid-column: 1; grid-row: 2; min-height: 0; overflow: auto; overscroll-behavior: contain; border: 1px solid var(--sticker-line); border-radius: 14px 14px 8px 8px; background: #fff; }
    .custom-sticker-editor.is-preview-settings-open .custom-sticker-shell { grid-template-rows: minmax(130px, 1fr) minmax(220px, 44%) auto; }
    .custom-sticker-editor.is-preview-settings-open .custom-sticker-panel { display: none; }
    .custom-sticker-editor .sticker-preview-settings { position: relative; inset: auto; width: 100%; max-height: none; overflow: visible; padding: 14px; margin: 0; border: 0; box-shadow: none; }
    .custom-sticker-editor .sticker-preview-close { top: 4px; right: 4px; padding: 14px; }
    .custom-sticker-editor .sticker-placeholder { padding: 12px; gap: 12px; }
    .custom-sticker-editor .sticker-empty-art { display: none; }
    .custom-sticker-editor .sticker-placeholder h2 { font-size: 18px; }
    .custom-sticker-editor .sticker-placeholder p { display: none; }
    .custom-sticker-editor .sticker-empty-actions { margin-top: 0; }
    .custom-sticker-editor:not(.has-artwork) .sticker-stage-toolbar { display: none; }
    .custom-sticker-editor.is-focus-mode .custom-sticker-shell { height: var(--sticker-workbench-height); }
    .custom-sticker-editor.is-mobile-keyboard-open {
      position: fixed; inset: var(--sticker-visible-top) 0 auto; z-index: 1040;
      height: var(--sticker-visible-height); min-height: 0; overflow: hidden;
    }
    .custom-sticker-editor.is-mobile-keyboard-open .sticker-page-header,
    .custom-sticker-editor.is-mobile-keyboard-open .custom-sticker-stage,
    .custom-sticker-editor.is-mobile-keyboard-open .sticker-action-footer { display: none; }
    .custom-sticker-editor.is-mobile-keyboard-open .custom-sticker-shell { grid-template-rows: minmax(0, 1fr); }
  }
  .sticker-advanced > summary {
    padding: 8px 0;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
  }
  .sticker-advanced > summary:focus-visible {
    outline: 2px solid #536c91;
    outline-offset: 2px;
  }
  .sticker-primary-entries { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .sticker-primary-entries .sticker-start-entry { flex-direction: row; align-items: center; min-height: 58px; gap: 10px; padding: 10px 12px; }
  .sticker-secondary-heading { margin: 18px 0 8px; font-size: 12px; color: var(--sticker-muted); }
  .sticker-secondary-tools { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
  .sticker-secondary-tools .btn { display: flex; gap: 5px; align-items: center; justify-content: center; min-height: 38px; padding: 7px; font-size: 12px; }
  .sticker-secondary-tools .sticker-start-entry { flex-direction: row; min-height: 38px; background: #fff; text-align: center; }
  .sticker-secondary-tools .sticker-start-entry i { font-size: 14px; }
  .sticker-secondary-tools .sticker-start-entry strong { font-size: 12px; font-weight: 500; }
  .sticker-secondary-tools .sticker-start-entry small { display: none; }
  .sticker-collection-link { display: flex; gap: 8px; align-items: center; margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--sticker-line); font-size: 12px; }
  .sticker-collection-link span { flex: 1; }
  .sticker-size-lock { font-size: 13px; }
  .template-filter-summary { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; min-width: 0; }
  .template-filter-summary > span { min-width: 0; overflow-wrap: anywhere; }
  .template-filter-summary .btn { padding: 0; }
  .template-category-select { display: none; }
  .template-category-item[hidden] { display: none; }
  .custom-sticker-editor .sticker-empty-actions { display: block; width: 100%; max-width: 440px; }
  .sticker-canvas-feature-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .custom-sticker-editor .sticker-canvas-feature-grid .btn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-width: 0; min-height: 72px; padding: 10px 8px; font-size: 12px; line-height: 1.4; white-space: normal; text-align: center; }
  .sticker-canvas-feature-grid .btn span { max-width: 100%; overflow-wrap: anywhere; text-wrap: balance; }
  .sticker-canvas-feature-grid .btn i { flex: 0 0 auto; font-size: 20px; line-height: 1; }
  .sticker-canvas-feature-grid .is-featured { border-color: #efd4ca; background: #fff8f4; color: var(--sticker-ink, #182536); }
  .sticker-canvas-feature-grid .is-featured:hover, .sticker-canvas-feature-grid .is-featured:focus-visible { border-color: #d9987f; background: #fff0e8; }
  .sticker-canvas-feature-grid .is-featured i { color: var(--sticker-accent, #c74826); }
  .template-grid[aria-busy="true"] { pointer-events: none; }
  .template-loading-label { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; color: var(--sticker-muted, #6b7280); font-size: 13px; }
  .template-loading-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
  .template-loading-grid[hidden] { display: none; }
  .template-loading-card { display: grid; gap: 10px; padding: 10px; border: 1px solid #e1e5ea; border-radius: 12px; background: #f8fafc; }
  .template-loading-card span { display: block; height: 12px; border-radius: 6px; background: #e5eaf0; }
  .template-loading-card span:first-child { height: 112px; background: #dce3eb; }
  .template-loading-card span:last-child { width: 60%; }
  @media (max-width: 991.98px) {
    .sticker-canvas-feature-grid { gap: 8px; }
    .custom-sticker-editor .sticker-canvas-feature-grid .btn { gap: 6px; min-height: 64px; padding: 8px 4px; font-size: 12px; }
    .sticker-canvas-feature-grid .btn i { font-size: 20px; }
  }
  @media (max-width: 767.98px) {
    .template-library-layout { grid-template-columns: minmax(0, 1fr); }
    .template-category-browser { display: none; }
    .template-category-select { display: block; }
    .template-library-modal .template-grid { max-height: none; overflow: visible; }
  }
  .sticker-material-information { margin-top: 8px; }
  .sticker-material-information > p { line-height: 1.5; color: var(--sticker-muted); }
  .sticker-material-information summary { padding-bottom: 0; }
  .sticker-material-information details[open] > summary { padding-bottom: 8px; }
  .sticker-preview-scope { margin: 12px 0 0; padding-top: 10px; border-top: 1px solid var(--sticker-line); line-height: 1.5; }
  .sticker-simulation-advanced { min-width: 0; }
  .sticker-simulation-advanced > div + div { margin-top: 12px; }
  .sticker-size-lock label { cursor: pointer; }
  .sticker-summary-selection { display: flex; align-items: center; gap: 12px; justify-content: space-between; grid-column: 1 / -1; min-width: 0; padding-bottom: 6px; border-bottom: 1px solid var(--sticker-line); }
  .sticker-summary-selection .btn { min-width: 0; padding: 0; text-align: left; color: var(--sticker-ink); font-size: 13px; text-decoration: none; white-space: normal; }
  .sticker-summary-quantity { flex: 0 0 auto; font-size: 12px; color: var(--sticker-muted); }
  .sticker-summary-more { padding: 4px 0; font-size: 12px; }
  .sticker-order-detail-list > div { display: grid; grid-template-columns: 100px minmax(0, 1fr); gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--sticker-line); }
  .sticker-order-detail-list dt { font-weight: 500; color: var(--sticker-muted); }
  .sticker-order-detail-list dd { margin: 0; overflow-wrap: anywhere; }
  @media (max-width: 991.98px) {
    .sticker-preview-settings .sticker-panel-section-title { margin-bottom: 8px; font-size: 14px; }
    .sticker-preview-settings .material-simulation-controls { margin-top: 8px; padding-top: 8px; gap: 8px; }
    .sticker-preview-settings .material-simulation-controls > p { font-size: 12px; }
    .custom-sticker-editor .sticker-summary-selection { gap: 8px; padding-bottom: 4px; }
    .custom-sticker-editor .sticker-summary-selection .btn { font-size: 12px; min-height: 36px; }
    .custom-sticker-editor .sticker-summary-quantity { font-size: 10px; }
    .custom-sticker-editor .sticker-summary { display: flex; flex-wrap: wrap; gap: 0 10px; }
    .custom-sticker-editor .sticker-summary-more { font-size: 12px; padding: 0 4px; min-height: 44px; }
    .custom-sticker-editor .sticker-summary-price { flex: 0 0 100%; }
  }
  .custom-sticker-editor .sticker-summary-price { display: grid; grid-template-columns: auto auto; align-items: baseline; gap: 0 10px; min-height: 40px; }
  .sticker-summary-price #sticker-price-label { grid-column: 1 / -1; white-space: nowrap; }
  .sticker-summary-price #sticker-price { grid-column: 1; min-height: 26px; }
  .sticker-summary-price .sticker-summary-more { grid-column: 2; grid-row: 2; justify-self: start; }
  .sticker-summary-price #retry-sticker-quote { grid-column: 1 / -1; grid-row: 3; padding: 0; text-align: left; }
  @media (max-width: 991.98px) {
    .custom-sticker-editor .sticker-summary-selection .btn { display: flex; align-items: center; gap: 3px; }
    .sticker-summary-selection [data-order-material] { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .sticker-summary-selection [data-order-size] { flex-shrink: 0; white-space: nowrap; }
    .sticker-summary-selection .btn > span[aria-hidden], .sticker-summary-selection .bi { flex-shrink: 0; }
    .custom-sticker-editor .sticker-summary-price { gap: 0 6px; min-height: 38px; }
    .custom-sticker-editor .sticker-summary-price #sticker-price-label { font-size: 10px; line-height: 12px; margin: 0; }
  }
  .sticker-preview-label-short { display: none; }
  @media (max-width: 991.98px) {
    .sticker-preview-label-full { display: none; }
    .custom-sticker-editor .sticker-preview-label-short { display: none; }
  }
  @media (max-width: 991.98px) and (max-height: 680px) and (orientation: portrait) {
    .custom-sticker-editor.is-preview-settings-open .custom-sticker-stage { display: none; }
    .custom-sticker-editor.is-preview-settings-open .custom-sticker-shell { grid-template-rows: minmax(0, 1fr) auto; }
    .custom-sticker-editor.is-preview-settings-open .sticker-mobile-preview-host { grid-row: 1; }
    .custom-sticker-editor:not(.is-panel-collapsed) .custom-sticker-stage { display: none; }
    .custom-sticker-editor:not(.is-panel-collapsed) .custom-sticker-shell { grid-template-rows: minmax(0, 1fr) auto; }
    .custom-sticker-editor .sticker-placeholder { gap: 6px; padding: 8px; }
    .custom-sticker-editor .sticker-placeholder h2 { font-size: 14px; }
    .custom-sticker-editor .sticker-canvas-feature-grid .btn { min-height: 48px; gap: 3px; padding: 4px; font-size: 11px; }
  }
  @media (max-width: 991.98px) and (max-height: 540px) and (orientation: landscape) {
    .custom-sticker-editor.is-preview-settings-open .custom-sticker-shell { grid-template-rows: minmax(0, 1fr) auto; }
    .custom-sticker-editor .sticker-mobile-preview-host { grid-column: 2; grid-row: 1; }
    .custom-sticker-editor .custom-sticker-shell { grid-template-columns: minmax(0, 1fr) minmax(280px, 40%); grid-template-rows: minmax(0, 1fr) auto; }
    .custom-sticker-editor .custom-sticker-stage { grid-column: 1; grid-row: 1 / -1; }
    .custom-sticker-editor .custom-sticker-panel { grid-column: 2; grid-row: 1; }
    .custom-sticker-editor .sticker-action-footer { grid-column: 2; grid-row: 2; }
    .custom-sticker-editor.is-panel-collapsed .custom-sticker-shell { grid-template-rows: 52px minmax(0, 1fr); }
    .custom-sticker-editor.is-panel-collapsed .sticker-action-footer { align-self: end; }
    .custom-sticker-editor .sticker-summary-selection { display: none; }
    .custom-sticker-editor .sticker-summary-price #sticker-price-label { white-space: normal; }
    .custom-sticker-editor.is-mobile-keyboard-open .custom-sticker-shell { grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); }
    .custom-sticker-editor.is-mobile-keyboard-open .custom-sticker-panel { grid-column: 1; }
    .custom-sticker-editor .sticker-placeholder { gap: 4px; padding: 6px; }
    .custom-sticker-editor .sticker-placeholder h2 { font-size: 14px; }
    .custom-sticker-editor .sticker-canvas-feature-grid .btn { min-height: 44px; gap: 2px; padding: 2px; font-size: 11px; }
  }
  @media (max-width: 991.98px) and (orientation: portrait) {
    .custom-sticker-editor.has-artwork .custom-sticker-shell {
      height: auto; min-height: var(--sticker-workbench-height); align-content: start;
      grid-template-rows: auto auto auto;
    }
    .custom-sticker-editor.has-artwork .custom-sticker-stage {
      display: flex; height: auto; grid-row: 1; scroll-margin-top: 8px;
    }
    .custom-sticker-editor.has-artwork .sticker-canvas-wrap {
      flex: 0 0 auto; height: var(--sticker-mobile-preview-height, calc(100vw - 16px));
    }
    .custom-sticker-editor.has-artwork .custom-sticker-panel { grid-row: 2; height: auto; max-height: none; overflow: visible; scroll-margin-top: 8px; }
    .custom-sticker-editor.has-artwork .sticker-panel-navigation { display: block; position: sticky; top: 0; z-index: 26; border-radius: 14px 14px 0 0; background: #fff; }
    .custom-sticker-editor.has-artwork:not(.is-panel-collapsed) .sticker-workspace-tabs { padding-right: 84px; }
    .custom-sticker-editor.has-artwork .sticker-editor-tabs { position: static; }
    .custom-sticker-editor.has-artwork .sticker-panel-scroll {
      flex: none; height: auto; overflow: visible;
    }
    .custom-sticker-editor.has-artwork .sticker-mobile-preview-host { grid-row: 2; max-height: min(440px, 60dvh); }
    .custom-sticker-editor.has-artwork .sticker-action-footer { grid-row: 3; position: sticky; bottom: 0; z-index: 25; }
    .custom-sticker-editor.has-artwork:not(.is-panel-collapsed) .sticker-return-canvas-label { display: block; font-size: 10px; line-height: 12px; }
    .custom-sticker-editor.has-artwork:not(.is-panel-collapsed) .sticker-mobile-panel-toggle { width: 80px; padding: 3px 4px !important; }
    .custom-sticker-editor.has-artwork:not(.is-panel-collapsed) .sticker-mobile-panel-toggle i { display: block; font-size: 15px; line-height: 18px; transform: rotate(180deg); }
    .custom-sticker-editor.has-artwork.is-panel-collapsed .sticker-mobile-panel-toggle i { transform: none; }
    .custom-sticker-editor.has-artwork.is-mobile-keyboard-open .custom-sticker-shell { height: var(--sticker-workbench-height); min-height: 0; grid-template-rows: minmax(0, 1fr); }
    .custom-sticker-editor.has-artwork.is-mobile-keyboard-open .custom-sticker-stage,
    .custom-sticker-editor.has-artwork.is-mobile-keyboard-open .sticker-action-footer { display: none; }
    .custom-sticker-editor.has-artwork.is-mobile-keyboard-open .custom-sticker-panel { grid-row: 1; height: 100%; overflow: hidden; }
    .custom-sticker-editor.has-artwork.is-mobile-keyboard-open .sticker-panel-scroll { flex: 1 1 auto; height: auto; overflow: auto; }
  }
  .sticker-focus-exit, .sticker-guest-icon, .sticker-mode-icon { display: none; }
  /* Focus actions join the existing toolbar and canvas; neither owns a row. */
  .custom-sticker-editor.is-focus-mode {
    --sticker-focus-control-size: 32px;
    padding: max(4px, env(safe-area-inset-top, 0px)) max(4px, env(safe-area-inset-right, 0px)) max(4px, env(safe-area-inset-bottom, 0px)) max(4px, env(safe-area-inset-left, 0px)) !important;
  }
  .custom-sticker-editor.is-focus-mode .sticker-page-header,
  .custom-sticker-editor.is-focus-mode .sticker-action-footer { display: none; }
  .custom-sticker-editor.is-focus-mode .sticker-preview-toolbar { position: relative; z-index: 40; flex: 1 1 100%; flex-wrap: nowrap; }
  .custom-sticker-editor.is-focus-mode .custom-sticker-stage { overflow: visible; }
  .custom-sticker-editor.is-focus-mode .sticker-draft-actions { flex: 0 0 auto; flex-wrap: nowrap; gap: 2px; margin-left: auto; padding-left: 8px; border-left: 1px solid var(--sticker-line); }
  .custom-sticker-editor.is-focus-mode .sticker-stage-toolbar { flex-basis: 100%; }
  .custom-sticker-editor.is-focus-mode :is(#save-design, .sticker-guest-link, .sticker-more-toggle, .sticker-focus-exit) {
    display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto;
    width: var(--sticker-focus-control-size); min-width: 0; height: var(--sticker-focus-control-size);
    min-height: var(--sticker-focus-control-size); padding: 0; border-color: transparent;
    border-radius: 8px; background: transparent; color: var(--sticker-muted); font-size: 16px;
  }
  .custom-sticker-editor.is-focus-mode :is(#save-design, .sticker-guest-link, .sticker-more-toggle, .sticker-focus-exit):hover {
    background: var(--sticker-paper); color: var(--sticker-ink);
  }
  .custom-sticker-editor.is-focus-mode .sticker-guest-icon { display: inline-block; }
  .custom-sticker-editor.is-focus-mode :is(#save-design, #add-design-cart) > .bi { margin: 0 !important; }
  /* Keep icon-only actions named for assistive technology. */
  .custom-sticker-editor.is-focus-mode .sticker-action-label {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
  }
  .custom-sticker-editor.is-focus-mode .sticker-more-actions { display: block; position: relative; }
  .custom-sticker-editor.is-focus-mode .sticker-more-actions-list { display: none; }
  .custom-sticker-editor.is-focus-mode .sticker-more-actions.is-open .sticker-more-actions-list {
    position: absolute; display: grid; gap: 6px; top: calc(100% + 4px); right: 0;
    width: min(240px, calc(100vw - 60px)); padding: 8px; z-index: 50;
    border: 1px solid var(--sticker-line); border-radius: 12px;
    background: #fff; box-shadow: 0 8px 28px #25334424;
  }
  .custom-sticker-editor.is-focus-mode .sticker-more-actions-list .btn { width: 100%; min-height: 44px; text-align: left; font-size: 13px; white-space: normal; }
  .custom-sticker-editor.is-focus-mode .sticker-more-actions-list .sticker-focus-toggle { display: none; }
  .custom-sticker-editor.is-focus-mode .custom-sticker-shell { gap: 4px; grid-template-rows: minmax(0, 1fr); }
  .custom-sticker-editor.is-focus-mode #add-design-cart {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; min-width: 44px; height: 44px; min-height: 44px;
    padding: 0; border-radius: 12px; font-size: 19px;
  }
  .custom-sticker-editor.is-focus-mode .custom-sticker-stage > #add-design-cart {
    position: absolute; right: 16px; bottom: 16px; z-index: 30;
    box-shadow: 0 4px 14px #25334426;
  }
  @media (min-width: 992px) {
    .custom-sticker-editor.is-focus-mode .sticker-canvas-wrap { padding-bottom: 68px !important; }
  }
  @media (max-width: 991.98px), (any-pointer: coarse) {
    .custom-sticker-editor.is-focus-mode { --sticker-focus-control-size: 44px; }
  }
  @media (max-width: 991.98px) {
    .custom-sticker-editor.is-focus-mode .sticker-preview-toolbar { gap: 4px; }
    .custom-sticker-editor.is-focus-mode .sticker-draft-actions { padding-left: 4px; }
    .custom-sticker-editor.is-focus-mode .sticker-preview-mode { min-width: 0; gap: 2px; }
    .custom-sticker-editor.is-focus-mode .sticker-preview-mode .btn { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; border-radius: 8px; padding: 0; font-size: 18px; }
    .custom-sticker-editor.is-focus-mode .sticker-preview-mode .btn.d-none { display: none !important; }
    .custom-sticker-editor.is-focus-mode .sticker-preview-mode .bi { display: inline-block; margin: 0 !important; }
    .custom-sticker-editor.is-focus-mode .sticker-preview-mode :is(.sticker-mode-label-full, .sticker-mode-label-short) { display: none; }
    .custom-sticker-editor.is-focus-mode .sticker-more-actions-list :is(#save-design, .sticker-guest-link) {
      justify-content: flex-start; gap: 6px; width: 100%; padding: 8px 12px; border: 1px solid var(--sticker-line); border-radius: 8px; font-size: 13px;
    }
    .custom-sticker-editor.is-focus-mode .sticker-more-actions-list .sticker-action-label { position: static; width: auto; height: auto; margin: 0; overflow: visible; clip-path: none; white-space: normal; }
    .custom-sticker-editor.is-focus-mode .custom-sticker-shell { grid-template-rows: minmax(130px, 1fr) minmax(220px, 44%); }
    .custom-sticker-editor.is-focus-mode.is-panel-collapsed .custom-sticker-shell { grid-template-rows: minmax(130px, 1fr) 52px; }
    .custom-sticker-editor.is-focus-mode .sticker-panel-navigation { display: block; position: relative; flex: 0 0 auto; background: #fff; }
    .custom-sticker-editor.is-focus-mode .sticker-workspace-tabs,
    .custom-sticker-editor.is-focus-mode.has-artwork:not(.is-panel-collapsed) .sticker-workspace-tabs { padding: 0 96px 0 4px; }
    .custom-sticker-editor.is-focus-mode .sticker-workspace-tabs button { flex-direction: column; gap: 2px; font-size: 10px; }
    .custom-sticker-editor.is-focus-mode .sticker-panel-navigation > #add-design-cart { position: absolute; top: 3px; right: 4px; }
    .custom-sticker-editor.is-focus-mode .sticker-mobile-panel-toggle,
    .custom-sticker-editor.is-focus-mode.has-artwork:not(.is-panel-collapsed) .sticker-mobile-panel-toggle { width: 44px; right: 50px; }
    .custom-sticker-editor.is-focus-mode .sticker-return-canvas-label { display: none !important; }
    .custom-sticker-editor.is-focus-mode.is-preview-settings-open .custom-sticker-shell { grid-template-rows: minmax(130px, 1fr) minmax(220px, 44%) 52px; }
    .custom-sticker-editor.is-focus-mode.is-preview-settings-open .custom-sticker-panel { display: flex; grid-row: 3; height: 52px; }
    .custom-sticker-editor.is-focus-mode.is-preview-settings-open .sticker-panel-scroll { display: none; }
    .custom-sticker-editor.is-focus-mode.is-mobile-keyboard-open #add-design-cart { display: none; }
    .custom-sticker-editor.is-focus-mode.is-mobile-keyboard-open .custom-sticker-shell { grid-template-rows: minmax(0, 1fr); }
  }
  @media (max-width: 991.98px) and (orientation: portrait) {
    .custom-sticker-editor.is-focus-mode.has-artwork .custom-sticker-shell { grid-template-rows: auto auto; }
    .custom-sticker-editor.is-focus-mode.has-artwork.is-panel-collapsed:not(.is-preview-settings-open) .custom-sticker-shell {
      height: var(--sticker-workbench-height); min-height: 0; grid-template-rows: minmax(0, 1fr) 52px;
    }
    .custom-sticker-editor.is-focus-mode.has-artwork.is-panel-collapsed:not(.is-preview-settings-open) .custom-sticker-stage { height: 100%; }
    .custom-sticker-editor.is-focus-mode.has-artwork.is-panel-collapsed:not(.is-preview-settings-open) .sticker-canvas-wrap { flex: 1 1 auto; height: auto; }
    .custom-sticker-editor.is-focus-mode.has-artwork .sticker-panel-navigation { position: sticky; top: 0; }
    .custom-sticker-editor.is-focus-mode.has-artwork.is-preview-settings-open .custom-sticker-shell { grid-template-rows: auto auto 52px; }
    .custom-sticker-editor.is-focus-mode.has-artwork.is-mobile-keyboard-open .custom-sticker-shell { grid-template-rows: minmax(0, 1fr); }
  }
  @media (max-width: 991.98px) and (max-height: 680px) and (orientation: portrait) {
    .custom-sticker-editor.is-focus-mode:not(.has-artwork):not(.is-panel-collapsed) .custom-sticker-shell { grid-template-rows: auto minmax(0, 1fr); }
    .custom-sticker-editor.is-focus-mode:not(.has-artwork):not(.is-panel-collapsed) .custom-sticker-stage,
    .custom-sticker-editor.is-focus-mode.is-preview-settings-open .custom-sticker-stage { display: flex; height: auto; }
    .custom-sticker-editor.is-focus-mode:not(.has-artwork):not(.is-panel-collapsed) .sticker-canvas-wrap,
    .custom-sticker-editor.is-focus-mode.is-preview-settings-open .sticker-canvas-wrap { display: none; }
    .custom-sticker-editor.is-focus-mode.is-preview-settings-open .custom-sticker-shell { grid-template-rows: auto minmax(0, 1fr) 52px; }
    .custom-sticker-editor.is-focus-mode.is-preview-settings-open .sticker-mobile-preview-host { grid-row: 2; }
  }
  @media (max-width: 991.98px) and (max-height: 540px) and (orientation: landscape) {
    .custom-sticker-editor.is-focus-mode .custom-sticker-shell,
    .custom-sticker-editor.is-focus-mode.is-panel-collapsed .custom-sticker-shell { grid-template-rows: minmax(0, 1fr); }
    .custom-sticker-editor.is-focus-mode.is-preview-settings-open .custom-sticker-shell { grid-template-rows: minmax(0, 1fr) 52px; }
    .custom-sticker-editor.is-focus-mode.is-preview-settings-open .custom-sticker-panel { grid-row: 2; }
  }
  @media (max-width: 991.98px) {
    .custom-sticker-editor.is-focus-mode.is-mobile-keyboard-open .custom-sticker-stage { display: none !important; }
    .custom-sticker-editor.is-focus-mode.is-mobile-keyboard-open .custom-sticker-shell { grid-template-rows: minmax(0, 1fr) !important; }
  }
  /* Adapt to the remaining canvas space, including wrapped toolbars in other languages. */
  @container sticker-start (max-height: 400px) {
    .custom-sticker-editor .sticker-empty-art { display: none; }
  }
  @container sticker-start (max-height: 320px) {
    .custom-sticker-editor .sticker-empty-art,
    .custom-sticker-editor .sticker-placeholder p { display: none; }
    .custom-sticker-editor .sticker-placeholder h2 { font-size: 18px; }
    .custom-sticker-editor .sticker-canvas-feature-grid .btn { min-height: 64px; padding: 8px 4px; }
  }
  @container sticker-start (max-height: 230px) {
    .custom-sticker-editor .sticker-placeholder h2 { font-size: 14px; }
    .custom-sticker-editor .sticker-canvas-feature-grid .btn { min-height: 44px; padding: 4px; gap: 3px; font-size: 11px; }
    .sticker-canvas-feature-grid .btn i { font-size: 16px; }
  }
  @container sticker-start (max-height: 180px) {
    .sticker-canvas-feature-grid .btn i { display: none; }
  }


  #draft-list-modal .btn { min-height: 44px; white-space: normal; }
  #draft-list-modal .btn-close { min-width: 44px; min-height: 44px; padding: 0; }
  #draft-list-modal .form-control,
  #draft-list-modal .form-select { min-height: 44px; font-size: 16px; }
  #draft-list-modal .modal-body { overscroll-behavior: contain; }
  #draft-pagination { display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px; align-items: center; gap: 12px; padding: 8px; border: 1px solid #e2e8f0; border-radius: 12px; background: #f8fafc; }
  #draft-pagination[hidden], #draft-pagination.is-single-page .draft-page-button { display: none; }
  #draft-pagination.is-single-page { grid-template-columns: minmax(0, 1fr); }
  #draft-list-modal .draft-page-button { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; border: 1px solid #cbd5e1; border-radius: 8px; background: #fff; color: #334155; box-shadow: 0 1px 2px rgba(15, 23, 42, .04); }
  #draft-list-modal .draft-page-button:hover:not(:disabled) { border-color: #94a3b8; background: #f1f5f9; color: #0f172a; }
  #draft-list-modal .draft-page-button:focus-visible { outline: 2px solid #475569; outline-offset: 2px; box-shadow: none; }
  #draft-list-modal .draft-page-button:disabled { border-color: transparent; background: transparent; color: #94a3b8; opacity: 1; box-shadow: none; }
  #draft-list-modal .draft-page-button[aria-busy="true"] { border-color: #cbd5e1; background: #fff; color: #475569; }
  .draft-page-spinner, .draft-page-button[aria-busy="true"] .draft-page-arrow { display: none; }
  .draft-page-button[aria-busy="true"] .draft-page-spinner { display: inline-block; }
  #draft-page-info { min-width: 0; color: #475569; font-size: 13px; line-height: 1.5; font-variant-numeric: tabular-nums; text-align: center; overflow-wrap: anywhere; }
  @media (max-width: 575.98px) {
    #draft-list-modal { top: var(--draft-visible-top, 0px); height: var(--draft-visible-height, 100dvh); }
    #draft-list-modal .modal-dialog { height: calc(100% - 1rem); min-height: 0; margin: .5rem; }
    #draft-list-modal .modal-content { max-height: 100%; }
    #draft-list-modal .modal-header,
    #draft-list-modal .modal-body { padding: 16px; }
    #draft-list-modal .modal-title { font-size: 20px; }
    #rename-draft-form .btn { flex: 1 1 100%; }
    #draft-list-modal .modal-footer { padding-bottom: max(12px, env(safe-area-inset-bottom)); }
    #draft-list-modal .modal-footer .btn { flex: 1; }
  }

  /* Reserve room for translated creation actions and the production notice on short phones. */
  @media (max-width: 575px) and (orientation: portrait) {
    .custom-sticker-editor:not(.has-artwork).is-panel-collapsed .custom-sticker-shell { min-height: 440px; }
  }
  @container sticker-start (max-height: 180px) and (min-width: 380px) {
    .custom-sticker-editor .sticker-placeholder h2 { display: none; }
    .sticker-canvas-feature-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
    .sticker-entry-notice { font-size: 11px; line-height: 1.3; }
  }
