/* Pre-order mode: notice bar, card order buttons and the pre-order dialog. Theme tokens only. */

:root {
  --preorder-width: 480px;
  --preorder-backdrop: 0.8;
  --fs-input: 16px; /* 16px stops iOS zooming into the field */
}

.preorder-bar {
  padding: var(--space-8) var(--gutter);
  background: var(--accent);
  color: var(--bg);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0.06em;
  text-align: center;
}

.pcard__order {
  width: 100%;
  margin-top: var(--space-12);
}

.preorder {
  margin: auto; /* the theme's reset zeroes the UA margin that centres a modal dialog */
  width: min(var(--preorder-width), calc(100vw - var(--gutter) * 2));
  max-height: calc(100svh - var(--gutter) * 2);
  padding: 0;
  border: 1px solid var(--line);
  overflow: auto;
}

.preorder::backdrop {
  background: var(--bg);
  opacity: var(--preorder-backdrop);
}

.preorder__close {
  position: absolute;
  top: var(--space-8);
  right: var(--space-8);
  width: var(--tap);
  height: var(--tap);
  border: 0;
  background: transparent;
  font-size: var(--fs-tile);
  line-height: 1;
  color: var(--text-60);
}

.preorder__close:hover {
  color: var(--text);
}

.preorder__body {
  display: grid;
  gap: var(--space-16);
  padding: var(--space-44) var(--space-30) var(--space-30);
}

.preorder__body[hidden] {
  display: none;
}

.preorder__eyebrow {
  color: var(--accent);
}

.preorder__title {
  font-size: var(--fs-tile);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.preorder__lead {
  font-size: var(--fs-body);
  color: var(--text-75);
}

.preorder__product {
  display: grid;
  gap: var(--space-2);
  padding: var(--space-14) var(--space-16);
  background: var(--surface);
}

.preorder__name {
  font-weight: 700;
}

.preorder__meta {
  color: var(--text-60);
}

.preorder__form {
  display: grid;
  gap: var(--space-14);
}

.preorder__field {
  display: grid;
  gap: var(--space-8);
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}

.preorder__field[hidden] {
  display: none;
}

.preorder__label {
  padding: 0;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-60);
}

.preorder__optional {
  text-transform: none;
  letter-spacing: 0;
}

.preorder__input {
  min-height: var(--tap);
  padding: var(--space-8) var(--space-12);
  border: 1px solid var(--border-strong);
  background: var(--bg);
  font-size: var(--fs-input);
}

.preorder__input:focus-visible {
  border-color: var(--text);
}

.preorder__hp {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.preorder__error {
  color: var(--accent);
  font-size: var(--fs-small);
}

.preorder__submit {
  width: 100%;
  margin-top: var(--space-8);
}

.preorder__fine {
  font-size: var(--fs-xs);
  color: var(--text-50);
}

/* Sorting and filtering need Shopify's server; the static site lists every product. */
.plp__filters {
  display: none;
}
