html.preorder-refresh-v1[data-preorder-view="welcome"],
html.preorder-refresh-v1[data-preorder-view="restoring"],
html.preorder-refresh-v1[data-preorder-view="preview"] {
  overflow: hidden;
}

body.preorder-refresh-v1 {
  touch-action: pan-x pan-y;
  --refresh-accent: #1687f8;
  --refresh-accent-pressed: #0872db;
  --refresh-bg: #f5f3f0;
  --refresh-card: rgba(255, 255, 255, 0.86);
  --refresh-card-solid: #fff;
  --refresh-ink: #211f1e;
  --refresh-muted: #77726e;
  --refresh-line: rgba(48, 43, 40, 0.09);
  --refresh-shadow: 0 18px 48px rgba(63, 50, 42, 0.12);
  --refresh-shadow-soft: 0 10px 28px rgba(63, 50, 42, 0.09);
  --sheet-backdrop: rgba(27, 24, 22, 0.3);
  --sheet-border: rgba(255, 255, 255, 0.78);
  --sheet-button-font-size: 0.95rem;
  --sheet-button-font-weight: 650;
  --sheet-button-gap: 8px;
  --sheet-button-height: 56px;
  --sheet-button-radius: 18px;
  --sheet-danger: #dc454b;
  --sheet-danger-pressed: #c6383e;
  --sheet-danger-soft: rgba(211, 61, 66, 0.09);
  --sheet-danger-soft-pressed: rgba(211, 61, 66, 0.15);
  --sheet-danger-text: #c4373b;
  --sheet-neutral: rgba(32, 31, 30, 0.065);
  --sheet-neutral-pressed: rgba(32, 31, 30, 0.11);
  --sheet-radius: 28px;
  --sheet-shadow: 0 24px 64px rgba(28, 24, 21, 0.24);
  --sheet-surface: rgba(255, 255, 255, 0.92);
  --sheet-width: 430px;
  background: var(--refresh-bg);
}

body.preorder-refresh-v1::before {
  position: fixed;
  inset: -12%;
  z-index: 0;
  background:
    radial-gradient(circle at 16% 22%, rgba(255, 181, 222, 0.95), transparent 34%),
    radial-gradient(circle at 82% 18%, rgba(202, 180, 255, 0.9), transparent 38%),
    radial-gradient(circle at 76% 82%, rgba(160, 225, 255, 0.92), transparent 38%),
    linear-gradient(145deg, #f7cce8 0%, #d5c4ff 48%, #bceafa 100%);
  content: "";
  opacity: 0;
  pointer-events: none;
  transform: scale(1.04);
  transition: opacity 280ms ease;
}

body.preorder-refresh-v1[data-preorder-view="welcome"]::before {
  opacity: 1;
  animation: preorder-refresh-aurora 14s ease-in-out infinite alternate;
}

body.preorder-refresh-v1[data-preorder-view="welcome"] {
  position: relative;
  height: calc(var(--vh, 1vh) * 100);
  overflow: hidden;
  background: linear-gradient(
    135deg,
    #ff9a9e,
    #fec9d7,
    #fad0c4,
    #fbc2eb,
    #d6b4fc,
    #a1c4fd,
    #c2e9fb,
    #96e6a1,
    #b8ed96,
    #f6d365,
    #fda085
  );
  background-size: 800% 800%;
  animation: preorder-entry-smooth-gradient 30s linear infinite;
  text-align: center;
}

body.preorder-refresh-v1[data-preorder-view="welcome"]::before {
  display: none;
}

body.preorder-refresh-v1 .app {
  position: relative;
  z-index: 1;
  background: transparent;
}

body.preorder-refresh-v1 .primary-button {
  border-radius: 999px;
  background: var(--refresh-accent);
  box-shadow: 0 13px 28px rgba(22, 135, 248, 0.25);
  transition:
    transform 160ms ease,
    background-color 160ms ease,
    box-shadow 160ms ease,
    opacity 160ms ease;
}

body.preorder-refresh-v1 .primary-button:active {
  background: var(--refresh-accent-pressed);
  box-shadow: 0 7px 18px rgba(22, 135, 248, 0.2);
}

body.preorder-refresh-v1 .view:not([hidden]) {
  animation: preorder-refresh-view-in 280ms ease both;
}

/*
 * Keep the dimmed shell mounted while a ready order changes to a kiosk status.
 * The ready/status views can then animate their notification panels without
 * fading and repainting the full-screen backdrop between polling states.
 */
body.preorder-refresh-v1[data-preorder-view="ready"] .app::before,
body.preorder-refresh-v1[data-preorder-view="status"] .app::before {
  position: fixed;
  inset: 0;
  z-index: 69;
  background: var(--sheet-backdrop);
  backdrop-filter: blur(10px);
  content: "";
  pointer-events: none;
}

body.preorder-refresh-v1 .restore-overlay {
  position: fixed;
  inset: 0;
  z-index: 998;
  background:
    radial-gradient(circle at 18% 5%, rgba(255, 255, 255, 0.9), transparent 32%),
    var(--refresh-bg);
}

body.preorder-refresh-v1 .restore-overlay .busy-spinner {
  border-color: rgba(22, 135, 248, 0.18);
  border-top-color: var(--refresh-accent);
}

body.preorder-refresh-v1 .busy-overlay {
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(5px);
}

body.preorder-refresh-v1 .toast {
  display: flex;
  width: fit-content;
  max-width: calc(100vw - 32px);
  min-height: 48px;
  align-items: center;
  gap: 10px;
  padding: 10px 16px 10px 11px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow:
    0 14px 34px rgba(55, 45, 40, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  color: var(--refresh-ink);
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.25;
  text-align: left;
  backdrop-filter: blur(18px) saturate(1.2);
}

body.preorder-refresh-v1 .toast::before {
  display: grid;
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  place-items: center;
  border-radius: 50%;
  background: var(--refresh-accent);
  color: #fff;
  content: "✓";
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1;
}

body.preorder-refresh-v1 .toast.warning {
  border-color: rgba(224, 153, 36, 0.25);
  background: rgba(255, 251, 241, 0.94);
  color: #7a5314;
}

body.preorder-refresh-v1 .toast.warning::before {
  background: #e6a12f;
  content: "!";
}

body.preorder-refresh-v1 .toast.error {
  border-color: rgba(218, 67, 71, 0.22);
  background: rgba(255, 247, 247, 0.95);
  color: #9d2f35;
}

body.preorder-refresh-v1 .toast.error::before {
  background: #dc454b;
  content: "!";
}

body.preorder-refresh-v1 .confirmation-backdrop {
  position: fixed;
  inset: 0;
  z-index: 140;
  display: grid;
  align-items: end;
  padding: 12px 12px calc(12px + var(--safe-bottom));
  background: var(--sheet-backdrop);
  backdrop-filter: blur(10px);
  overscroll-behavior: contain;
  touch-action: none;
  animation: preorder-confirmation-backdrop-in 170ms ease both;
}

body.preorder-refresh-v1 .confirmation-sheet {
  width: min(100%, var(--sheet-width));
  margin: 0 auto;
  padding: 20px 10px 10px;
  border: 1px solid var(--sheet-border);
  border-radius: var(--sheet-radius);
  background: var(--sheet-surface);
  box-shadow: var(--sheet-shadow);
  backdrop-filter: blur(24px) saturate(1.15);
  animation: preorder-confirmation-sheet-in 190ms ease-out both;
}

body.preorder-refresh-v1 .confirmation-copy {
  padding: 4px 18px 20px;
  text-align: center;
}

body.preorder-refresh-v1 .confirmation-copy h2 {
  margin: 0;
  color: var(--refresh-ink);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.015em;
}

body.preorder-refresh-v1 .confirmation-copy p {
  margin: 7px 0 0;
  color: var(--refresh-muted);
  font-size: 0.95rem;
  line-height: 1.35;
}

body.preorder-refresh-v1 .confirmation-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--sheet-button-gap);
}

body.preorder-refresh-v1 .confirmation-button {
  height: var(--sheet-button-height);
  min-width: 0;
  min-height: var(--sheet-button-height);
  padding: 0 12px;
  border: 0;
  border-radius: var(--sheet-button-radius);
  background: var(--sheet-neutral);
  color: var(--refresh-ink);
  cursor: pointer;
  font-size: var(--sheet-button-font-size);
  font-weight: var(--sheet-button-font-weight);
  line-height: 1.15;
  transition: background-color 140ms ease, transform 140ms ease;
}

body.preorder-refresh-v1 .confirmation-button:active {
  background: var(--sheet-neutral-pressed);
  transform: scale(0.985);
}

body.preorder-refresh-v1 .confirmation-button.danger {
  background: var(--sheet-danger);
  color: #fff;
}

body.preorder-refresh-v1 .confirmation-button.danger:active {
  background: var(--sheet-danger-pressed);
}

body.preorder-refresh-v1 #order-menu.sheet-backdrop {
  background: var(--sheet-backdrop);
  backdrop-filter: blur(10px);
  opacity: 1;
  transition: opacity 170ms ease;
}

body.preorder-refresh-v1 #order-menu.sheet-backdrop.closing {
  opacity: 0;
  pointer-events: none;
}

body.preorder-refresh-v1 #order-menu .bottom-sheet {
  --order-menu-offset-y: 0px;
  right: auto;
  bottom: calc(12px + var(--safe-bottom));
  left: 50%;
  width: min(calc(100% - 24px), var(--sheet-width));
  gap: var(--sheet-button-gap);
  padding: 10px;
  border: 1px solid var(--sheet-border);
  border-radius: var(--sheet-radius);
  background: var(--sheet-surface);
  box-shadow: var(--sheet-shadow);
  backdrop-filter: blur(24px) saturate(1.15);
  transform: translate3d(-50%, var(--order-menu-offset-y), 0);
  will-change: transform;
  animation: preorder-refresh-sheet-in 180ms ease-out both;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

body.preorder-refresh-v1 #order-menu .sheet-handle {
  position: relative;
  width: 100%;
  height: 24px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 11px;
  background: transparent;
  cursor: grab;
  touch-action: none;
}

body.preorder-refresh-v1 #order-menu .sheet-handle::before {
  position: absolute;
  top: 8px;
  left: 50%;
  width: 42px;
  height: 4px;
  border-radius: 999px;
  background: rgba(48, 43, 40, 0.2);
  content: "";
  transform: translateX(-50%);
}

body.preorder-refresh-v1 #order-menu .sheet-handle:active,
body.preorder-refresh-v1 #order-menu .sheet-handle.dragging,
body.preorder-refresh-v1 #order-menu .bottom-sheet.dragging {
  cursor: grabbing;
}

body.preorder-refresh-v1 #order-menu .sheet-action {
  height: var(--sheet-button-height);
  min-height: var(--sheet-button-height);
  padding: 0 12px;
  border-radius: var(--sheet-button-radius);
  background: var(--sheet-neutral);
  color: var(--refresh-ink);
  cursor: pointer;
  font-size: var(--sheet-button-font-size);
  font-weight: var(--sheet-button-font-weight);
  transition: background-color 140ms ease, transform 140ms ease;
}

body.preorder-refresh-v1 #order-menu .sheet-action:active {
  background: var(--sheet-neutral-pressed);
  transform: scale(0.985);
}

body.preorder-refresh-v1 #order-menu .danger-action {
  background: var(--sheet-danger-soft);
  color: var(--sheet-danger-text);
}

body.preorder-refresh-v1 #order-menu .danger-action:active {
  background: var(--sheet-danger-soft-pressed);
}

body.preorder-refresh-v1[data-preorder-view="welcome"] .app {
  height: calc(var(--vh, 1vh) * 100);
  overflow: hidden;
}

body.preorder-refresh-v1[data-preorder-view="welcome"] .app-header {
  display: none;
}

body.preorder-refresh-v1[data-preorder-view="welcome"] .app-main {
  min-height: 0;
}

body.preorder-refresh-v1 .welcome-view {
  position: relative;
  display: flow-root;
  width: 100%;
  min-height: 0;
  margin: 20vh auto 0;
  padding: 0 18px;
  animation: none;
  text-align: center;
  transform: none;
}

body.preorder-refresh-v1[data-preorder-view="welcome"] .welcome-view:not([hidden]) {
  animation: none;
  transform: none;
}

body.preorder-refresh-v1 .preorder-entry-brand {
  display: block;
  margin-top: 0.67em;
  margin-bottom: 30px;
  color: #fff;
  font-family: "Billabong", "AppleColorEmoji", sans-serif;
  font-size: 4rem;
  font-weight: normal;
  line-height: normal;
  text-shadow:
    -0.75px 0 0 rgba(255, 255, 255, 0.4),
    -1.5px 0 0 rgba(255, 255, 255, 0.3),
    0 3px 5px rgba(0, 0, 0, 0.4);
}

body.preorder-refresh-v1 .welcome-view .preorder-entry-action {
  width: auto;
  min-width: 179px;
  max-width: calc(100vw - 36px);
  min-height: 0;
  padding: 14px 28px;
  border: 0;
  border-radius: 50px;
  background: #007bff;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  color: #fff;
  cursor: pointer;
  font-family: "SF Pro Display", "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
  font-size: 1.1rem;
  font-weight: normal;
  line-height: normal;
  white-space: nowrap;
  transition: all 0.2s ease;
}

body.preorder-refresh-v1 .welcome-view .preorder-entry-action:active {
  background: #0056b3;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  transform: scale(1.2);
}

body.preorder-refresh-v1 .welcome-support {
  position: fixed;
  right: 0;
  bottom: 10px;
  left: 0;
  z-index: 2;
  display: block;
  width: 100%;
  color: #fff;
  font-family: "SF Pro Display", "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
  font-size: 0.8rem;
  font-weight: normal;
  text-align: center;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

body.preorder-refresh-v1 .welcome-support a {
  color: inherit;
  text-decoration: none;
}

body.preorder-refresh-v1 .order-ready-view {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  width: 100%;
  min-height: 0;
  flex-direction: row;
  align-items: flex-end;
  justify-content: center;
  padding: 12px 12px calc(12px + var(--safe-bottom));
  background: transparent;
  opacity: 1;
  backdrop-filter: none;
  transition: opacity 180ms ease;
}

body.preorder-refresh-v1 .order-ready-view.closing {
  opacity: 0;
  pointer-events: none;
}

body.preorder-refresh-v1 .ready-panel {
  --ready-sheet-offset-y: 0px;
  display: grid;
  width: min(100%, var(--sheet-width));
  gap: 0;
  padding: 8px 10px 10px;
  border: 1px solid var(--sheet-border);
  border-radius: var(--sheet-radius);
  background: var(--sheet-surface);
  box-shadow: var(--sheet-shadow);
  backdrop-filter: blur(24px) saturate(1.15);
  transform: translate3d(0, var(--ready-sheet-offset-y), 0);
  animation: refresh-ready-sheet-in 220ms cubic-bezier(0.22, 1, 0.36, 1);
  cursor: grab;
  touch-action: none;
  user-select: none;
  will-change: transform;
}

body.preorder-refresh-v1 .ready-sheet-handle {
  position: relative;
  width: 100%;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: 12px;
  background: transparent;
  cursor: grab;
  touch-action: none;
}

body.preorder-refresh-v1 .ready-sheet-handle::before {
  position: absolute;
  top: 8px;
  left: 50%;
  width: 42px;
  height: 4px;
  border-radius: 999px;
  background: rgba(48, 43, 40, 0.2);
  content: "";
  transform: translateX(-50%);
}

body.preorder-refresh-v1 .ready-sheet-handle.dragging,
body.preorder-refresh-v1 .ready-panel.dragging {
  cursor: grabbing;
}

body.preorder-refresh-v1 .ready-success-heading {
  display: grid;
  justify-items: center;
  gap: 2px;
  margin: 0 10px 24px;
}

body.preorder-refresh-v1 .ready-success-icon {
  display: block;
  width: 92px;
  height: 92px;
  pointer-events: none;
}

body.preorder-refresh-v1 .ready-success-heading strong {
  color: var(--refresh-ink);
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1.2;
}

body.preorder-refresh-v1 .ready-key-row {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  gap: 0.45em;
  color: var(--refresh-ink);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.25;
  white-space: nowrap;
}

body.preorder-refresh-v1 .ready-details {
  display: grid;
  gap: 0;
  margin: 0 10px 28px;
}

body.preorder-refresh-v1 .ready-key-row {
  margin-bottom: 3px;
}

body.preorder-refresh-v1 .ready-key-row > span:first-child {
  font-size: 0.95rem;
  font-weight: 400;
}

body.preorder-refresh-v1 .order-ready-view .pickup-code {
  display: inline-flex;
  height: 32px;
  min-width: 80px;
  min-height: 32px;
  align-items: center;
  justify-content: center;
  gap: 0.12em;
  padding: 1px 10px 0;
  border: 1px solid rgba(48, 43, 40, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92);
  color: var(--refresh-ink);
  cursor: default;
  font-size: 1.08rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1;
  backdrop-filter: blur(16px);
}

body.preorder-refresh-v1 .order-ready-view .pickup-code > span {
  display: block;
}

body.preorder-refresh-v1 .order-ready-view .pickup-code:active {
  transform: none;
}

body.preorder-refresh-v1 .order-ready-view .ready-hint,
body.preorder-refresh-v1 .order-ready-view .ready-map-link {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
}

body.preorder-refresh-v1 .order-ready-view .ready-hint {
  margin-bottom: 12px;
  color: var(--refresh-muted);
  font-weight: 400;
}

body.preorder-refresh-v1 .order-ready-view .ready-map-link {
  color: var(--refresh-accent);
  text-decoration: none;
}

body.preorder-refresh-v1 .order-ready-view .ready-actions {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: 100%;
  gap: var(--sheet-button-gap);
  margin-top: 0;
}

body.preorder-refresh-v1 .order-ready-view .ready-action-button {
  width: 100%;
  min-width: 0;
  height: var(--sheet-button-height);
  min-height: var(--sheet-button-height);
  padding: 0 12px;
  border-radius: var(--sheet-button-radius);
  box-shadow: none;
  font-size: var(--sheet-button-font-size);
  font-weight: var(--sheet-button-font-weight);
  white-space: nowrap;
}

body.preorder-refresh-v1 .order-ready-view .ready-action-button.danger-button {
  height: var(--sheet-button-height);
  min-height: var(--sheet-button-height);
  background: var(--sheet-danger-soft);
  box-shadow: none;
  color: var(--sheet-danger-text);
  font-size: var(--sheet-button-font-size);
}

body.preorder-refresh-v1 .order-ready-view .ready-action-button.danger-button:active {
  background: var(--sheet-danger-soft-pressed);
}

body.preorder-refresh-v1 .order-ready-view .ready-action-button:active {
  box-shadow: none;
  transform: scale(0.985);
}

@keyframes refresh-ready-sheet-in {
  from {
    transform: translate3d(0, calc(100% + 32px), 0);
  }
  to {
    transform: translate3d(0, var(--ready-sheet-offset-y), 0);
  }
}

body.preorder-refresh-v1 .order-status-view {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  width: 100%;
  max-width: none;
  min-height: 0;
  align-items: flex-end;
  justify-content: center;
  padding: 12px 12px calc(12px + var(--safe-bottom));
  background: transparent;
  text-align: center;
  backdrop-filter: none;
}

body.preorder-refresh-v1 .status-panel {
  display: grid;
  width: min(100%, var(--sheet-width));
  gap: 24px;
  padding: 26px 10px 10px;
  border: 1px solid var(--sheet-border);
  border-radius: var(--sheet-radius);
  background: var(--sheet-surface);
  box-shadow: var(--sheet-shadow);
  backdrop-filter: blur(24px) saturate(1.15);
  animation: refresh-ready-sheet-in 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

body.preorder-refresh-v1 .status-heading {
  display: grid;
  justify-items: center;
  gap: 12px;
}

body.preorder-refresh-v1 .status-icon {
  display: block;
  width: 92px;
  height: 92px;
}

body.preorder-refresh-v1 .status-heading h2 {
  margin: 0;
  color: var(--refresh-ink);
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1.2;
}

body.preorder-refresh-v1 .status-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: 100%;
  gap: var(--sheet-button-gap);
}

body.preorder-refresh-v1 .status-action-button {
  width: 100%;
  min-width: 0;
  height: var(--sheet-button-height);
  min-height: var(--sheet-button-height);
  padding: 0 12px;
  border-radius: var(--sheet-button-radius);
  box-shadow: none;
  font-size: var(--sheet-button-font-size);
  font-weight: var(--sheet-button-font-weight);
}

body.preorder-refresh-v1 .status-action-button.secondary-button {
  background: var(--surface-muted);
  box-shadow: none;
  color: var(--refresh-ink);
}

body.preorder-refresh-v1 .status-action-button:active {
  box-shadow: none;
  transform: scale(0.985);
}

/* Order grid is deliberately neutral and utility-focused. */
body.preorder-refresh-v1[data-preorder-view="order"] .app-header,
body.preorder-refresh-v1[data-preorder-view="ready"] .app-header,
body.preorder-refresh-v1[data-preorder-view="status"] .app-header {
  background: rgba(245, 243, 240, 0.82);
  border-bottom-color: rgba(48, 43, 40, 0.06);
  backdrop-filter: blur(22px) saturate(1.15);
}

body.preorder-refresh-v1[data-preorder-view="order"] .brand,
body.preorder-refresh-v1[data-preorder-view="ready"] .brand,
body.preorder-refresh-v1[data-preorder-view="status"] .brand {
  font-size: 3rem;
  text-shadow: 0 2px 4px rgba(39, 34, 31, 0.1);
}

body.preorder-refresh-v1 .order-view {
  padding-top: 22px;
}

body.preorder-refresh-v1 .order-heading {
  align-items: center;
  margin-bottom: 18px;
}

body.preorder-refresh-v1 .order-heading h2 {
  font-size: 1.55rem;
}

body.preorder-refresh-v1 .order-heading .eyebrow {
  color: var(--refresh-muted);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
}

body.preorder-refresh-v1 .order-heading .secondary-button {
  min-height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  background: var(--refresh-accent);
  box-shadow: none;
  color: #fff;
}

body.preorder-refresh-v1 .order-heading .secondary-button:active {
  background: var(--refresh-accent-pressed);
}

body.preorder-refresh-v1 .order-heading .secondary-button span {
  font-size: 1.3rem;
}

body.preorder-refresh-v1 .empty-order {
  min-height: 290px;
  gap: 14px;
  border: 0;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.5);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

body.preorder-refresh-v1 .empty-photos-icon {
  display: block;
  width: 92px;
  height: 92px;
  pointer-events: none;
}

body.preorder-refresh-v1 .empty-order p {
  max-width: 340px;
  margin: 0;
  color: var(--refresh-muted);
  font-size: 1rem;
  line-height: 1.35;
}

body.preorder-refresh-v1 .photo-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

body.preorder-refresh-v1 .photo-card {
  border-radius: 16px;
  background: #dedad6;
  box-shadow: var(--refresh-shadow-soft);
}

body.preorder-refresh-v1 .photo-card-copies-control {
  right: 9px;
  bottom: 9px;
  border-color: rgba(255, 255, 255, 0.72);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 5px 14px rgba(28, 25, 23, 0.12);
  color: var(--refresh-ink);
  backdrop-filter: blur(12px);
}

body.preorder-refresh-v1 .photo-card-copies-control button {
  color: var(--refresh-accent);
}

body.preorder-refresh-v1 .photo-card-copies-control button:active {
  background: rgba(22, 135, 248, 0.1);
}

body.preorder-refresh-v1 .photo-card-copy-button {
  bottom: 9px;
  left: 9px;
  border-color: rgba(255, 255, 255, 0.74);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 5px 14px rgba(28, 25, 23, 0.12);
  backdrop-filter: blur(12px);
}

body.preorder-refresh-v1 .photo-card-copy-button:active {
  background: rgba(255, 255, 255, 0.72);
}

body.preorder-refresh-v1 .order-bottom-spacer {
  height: 104px;
}

body.preorder-refresh-v1 .order-footer {
  right: 12px;
  top: calc(
    var(--visual-viewport-top, 0px)
    + var(--visual-viewport-height, 100dvh)
    - 12px
    - var(--safe-bottom)
  );
  bottom: auto;
  left: 12px;
  min-height: 70px;
  padding: 9px 10px 9px 16px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--refresh-shadow);
  backdrop-filter: blur(22px) saturate(1.2);
  transform: translate3d(0, -100%, 0);
}

body.preorder-refresh-v1 .order-footer .checkout-button,
body.preorder-refresh-v1 .order-preview-actions .checkout-button {
  min-height: 50px;
  border-radius: 999px;
  box-shadow: none;
}

body.preorder-refresh-v1 .order-preview {
  position: fixed;
  top: var(--visual-viewport-top, 0px);
  right: 0;
  bottom: auto;
  left: 0;
  z-index: 70;
  display: flex;
  height: var(--visual-viewport-height, 100dvh);
  min-height: 0;
  flex-direction: column;
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 5%, rgba(255, 255, 255, 0.9), transparent 32%),
    var(--refresh-bg);
}

body.preorder-refresh-v1 .order-preview-header {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  flex: 0 0 auto;
  align-items: center;
  min-height: calc(62px + var(--safe-top));
  padding: var(--safe-top) 18px 0;
  border-bottom: 1px solid var(--refresh-line);
  background: rgba(250, 249, 247, 0.9);
  backdrop-filter: blur(22px);
}

body.preorder-refresh-v1 .order-preview-header strong {
  font-size: 0.95rem;
}

body.preorder-refresh-v1 .order-preview-summary {
  flex: 0 0 auto;
  padding: 18px 20px 16px;
  color: var(--refresh-ink);
  text-align: center;
}

body.preorder-refresh-v1 .order-preview-summary > div,
body.preorder-refresh-v1 .order-preview-summary p {
  margin: 0;
  font-size: 1rem;
  line-height: 1.25;
}

body.preorder-refresh-v1 .order-preview-summary p {
  margin-top: 7px;
  color: var(--refresh-muted);
}

body.preorder-refresh-v1 .order-preview-scroll {
  min-height: 0;
  flex: 1 1 auto;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 0 16px calc(98px + var(--safe-bottom));
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

body.preorder-refresh-v1 .order-preview-scroll::-webkit-scrollbar {
  display: none;
}

body.preorder-refresh-v1 .order-preview-list {
  display: grid;
  width: min(100%, 720px);
  gap: 16px;
  margin: 0 auto;
}

body.preorder-refresh-v1 .order-preview-sheet {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--refresh-shadow-soft);
  user-select: none;
  -webkit-user-drag: none;
}

body.preorder-refresh-v1 .order-preview-actions {
  position: absolute;
  bottom: calc(12px + var(--safe-bottom));
  left: 50%;
  z-index: 3;
  display: flex;
  width: calc(100% - 24px);
  min-height: 70px;
  align-items: center;
  justify-content: flex-end;
  margin: 0;
  padding: 9px 10px 9px 16px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--refresh-shadow);
  -webkit-backdrop-filter: blur(22px) saturate(1.2);
  backdrop-filter: blur(22px) saturate(1.2);
  transform: translateX(-50%);
}

body.preorder-refresh-v1 .order-preview-actions .order-summary {
  display: flex;
  min-width: 0;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 2px;
  text-align: left;
}

body.preorder-refresh-v1 .order-preview-actions .order-summary > span {
  color: var(--refresh-muted);
  font-size: 0.78rem;
}

body.preorder-refresh-v1 .order-preview-actions .order-summary strong {
  overflow: hidden;
  font-size: 0.95rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.preorder-refresh-v1 .order-amount-line {
  position: relative;
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 6px;
}

body.preorder-refresh-v1 .order-print-info {
  display: inline-grid;
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(118, 116, 113, 0.55);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.52);
  color: var(--muted);
  cursor: pointer;
  font-family: inherit;
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  line-height: 1;
}

body.preorder-refresh-v1 .order-print-info[hidden],
body.preorder-refresh-v1 .order-print-tooltip[hidden] {
  display: none;
}

body.preorder-refresh-v1 .order-print-info:active {
  transform: scale(0.92);
}

body.preorder-refresh-v1 .order-print-tooltip {
  position: absolute;
  bottom: calc(100% + 12px);
  left: 0;
  z-index: 3;
  width: min(280px, calc(100vw - 44px));
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 28px rgba(40, 35, 32, 0.16);
  color: var(--refresh-ink);
  font-size: 0.8rem;
  font-weight: 400;
  line-height: 1.3;
  text-align: left;
  backdrop-filter: blur(18px) saturate(1.15);
}

body.preorder-refresh-v1 .toast {
  bottom: calc(104px + var(--safe-bottom));
}

/* The image stays on a dark canvas; controls become one light tool sheet. */
body.preorder-refresh-v1[data-preorder-view="editor"] .editor {
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  height: auto;
  background: var(--refresh-bg);
}

body.preorder-refresh-v1 .editor-header {
  background: rgba(250, 249, 247, 0.9);
  border-bottom-color: rgba(48, 43, 40, 0.07);
  backdrop-filter: blur(22px);
}

body.preorder-refresh-v1 .editor-scroll {
  background: #242321;
}

body.preorder-refresh-v1 .editor-stage-wrap {
  min-height: min(64dvh, 640px);
  background: #242321;
}

body.preorder-refresh-v1 .editor-stage {
  box-shadow: 0 20px 52px rgba(0, 0, 0, 0.38);
}

body.preorder-refresh-v1 .editor-tools {
  position: relative;
  z-index: 2;
  gap: 16px;
  width: min(100%, 660px);
  margin-top: -20px;
  padding: 22px 18px calc(34px + var(--safe-bottom));
  border-radius: 28px 28px 0 0;
  background: var(--refresh-bg);
  box-shadow: 0 -12px 34px rgba(0, 0, 0, 0.12);
}

body.preorder-refresh-v1 .editor-tools-handle {
  width: 34px;
  height: 4px;
  margin: -8px auto -4px;
  border-radius: 4px;
  background: rgba(32, 31, 30, 0.16);
}

body.preorder-refresh-v1 .editor-primary-actions {
  grid-template-columns: minmax(0, 1fr) 56px;
  gap: 10px;
}

body.preorder-refresh-v1 .editor-layout-segmented {
  gap: 4px;
  padding: 4px;
  border-radius: 18px;
  background: #e8e5e2;
}

body.preorder-refresh-v1 .editor-layout-segmented button {
  min-height: 48px;
  padding: 6px 7px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  font-size: clamp(0.78rem, 3.5vw, 0.875rem);
  font-weight: 600;
  line-height: 1.2;
}

body.preorder-refresh-v1 .editor-layout-segmented button.active {
  border: 0;
  background: #fff;
  box-shadow: 0 4px 12px rgba(50, 44, 40, 0.09);
  color: var(--refresh-accent);
}

body.preorder-refresh-v1 .editor-rotate-button {
  width: 56px;
  min-height: 56px;
  border: 1px solid rgba(48, 43, 40, 0.07);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 6px 16px rgba(63, 50, 42, 0.07);
  color: var(--refresh-ink);
  transition: background-color 140ms ease, transform 140ms ease;
}

body.preorder-refresh-v1 .editor-rotate-button:active {
  background: rgba(32, 31, 30, 0.08);
  transform: scale(0.96);
}

body.preorder-refresh-v1 .fields-panel {
  border-color: rgba(48, 43, 40, 0.07);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 9px 26px rgba(63, 50, 42, 0.06);
}

body.preorder-refresh-v1 .field-row {
  min-height: 62px;
  border-bottom-color: rgba(48, 43, 40, 0.07);
}

body.preorder-refresh-v1 .field-row input[type="text"],
body.preorder-refresh-v1 .field-row textarea {
  border-radius: 12px;
  background: #efedeb;
}

body.preorder-refresh-v1 .copies-control {
  min-height: 42px;
  border: 0;
  border-radius: 999px;
  background: #efedeb;
}

body.preorder-refresh-v1 .copies-control button {
  color: var(--refresh-accent);
}

body.preorder-refresh-v1 .switch span {
  background: #d1cdca;
}

body.preorder-refresh-v1 .switch input:checked + span {
  background: var(--refresh-accent);
}

body.preorder-refresh-v1 .editor-secondary-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  width: min(100%, 360px);
  margin: 0 auto;
}

body.preorder-refresh-v1 .editor-secondary-actions .tool-button {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(32, 31, 30, 0.055);
  box-shadow: none;
  color: var(--refresh-ink);
  font-size: clamp(0.78rem, 3.5vw, 0.875rem);
  font-weight: 600;
  white-space: nowrap;
}

body.preorder-refresh-v1 .editor-secondary-actions .tool-button:active {
  background: rgba(32, 31, 30, 0.1);
}

body.preorder-refresh-v1 .editor-secondary-actions .danger-tool {
  background: rgba(211, 61, 66, 0.08);
  color: #c4373b;
}

body.preorder-refresh-v1 .editor-secondary-actions .danger-tool:active {
  background: rgba(211, 61, 66, 0.14);
}

body.preorder-refresh-v1 .editor-primary-actions .tool-icon,
body.preorder-refresh-v1 .editor-secondary-actions .tool-icon {
  width: 18px;
  height: 18px;
}

body.preorder-refresh-v1 .editor-primary-actions .tool-icon {
  width: 22px;
  height: 22px;
  stroke-width: 2;
}

@media (min-width: 680px) {
  body.preorder-refresh-v1 .photo-grid {
    grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  }

  body.preorder-refresh-v1 .order-footer {
    right: max(18px, calc((100vw - 760px) / 2));
    left: max(18px, calc((100vw - 760px) / 2));
  }

  body.preorder-refresh-v1 .order-preview-actions {
    width: min(calc(100% - 36px), 760px);
  }
}

@media (max-width: 380px) {
  body.preorder-refresh-v1 .order-footer {
    align-items: center;
  }

  body.preorder-refresh-v1 .field-row {
    grid-template-columns: 56px minmax(0, 1fr) 40px;
  }
}

@keyframes preorder-refresh-aurora {
  0% {
    transform: scale(1.04) translate3d(-1.5%, -1%, 0);
  }
  100% {
    transform: scale(1.08) translate3d(1.5%, 1%, 0);
  }
}

@keyframes preorder-refresh-view-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes preorder-refresh-sheet-in {
  from {
    opacity: 0;
    transform: translate3d(-50%, 18px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(-50%, 0, 0);
  }
}

@keyframes preorder-confirmation-backdrop-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes preorder-confirmation-sheet-in {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes preorder-entry-smooth-gradient {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@media (prefers-reduced-motion: reduce) {
  body.preorder-refresh-v1[data-preorder-view="welcome"],
  body.preorder-refresh-v1::before {
    animation: none !important;
  }
}
