/* Allora shop: catalog, product pages, cart and confirmation.
   Self-contained (doesn't load styles.css, which sets landing-page
   behavior like scroll snapping). Colors from design-reference/brand_guide.md. */

@font-face {
  font-family: "TAN ASHFORD";
  src: url("/fonts/TAN-ASHFORD.otf") format("opentype");
  font-weight: 400 900;
  font-display: swap;
}
@font-face {
  font-family: "TAN ANGELTON";
  src: url("/fonts/TAN-ANGLETON.ttf") format("truetype");
  font-weight: 400 700;
  font-display: swap;
}
@font-face {
  font-family: "Chillink";
  src: url("/fonts/Chillink.ttf") format("truetype");
  font-display: swap;
}
@font-face {
  font-family: "Arial Nova";
  src: url("/fonts/ArialNova.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Arial Nova";
  src: url("/fonts/ArialNova-Bold.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}

:root {
  --crimson: #ff4375;
  --crimson-deep: #e02f5f;
  --light-crimson: #ff9aba;
  --orange-slice: #ffb502;
  --orange-peel: #ff7d00;
  --light-orange: #ffdac5;
  --lemon: #fffac5;
  --ink: #1f1b1d;
  --muted: #62585b;
  --line: #f4d6c6;
  --paper: #fffaf6;
  --tile: #fff1e8;
  --white: #ffffff;
  --success: #1e7a4c;
  --radius: 18px;
  --gutter: clamp(16px, 4vw, 40px);
  --max: 1200px;
  --display: "TAN ASHFORD", Georgia, serif;
  --sub: "TAN ANGELTON", Georgia, serif;
  --body: "Arial Nova", Arial, Helvetica, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body.shop {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.55;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 3px solid rgba(255, 67, 117, 0.45);
  outline-offset: 2px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 100;
  padding: 0.5rem 1rem;
  background: var(--ink);
  color: var(--white);
  border-radius: 999px;
}
.skip-link:focus {
  top: 0.75rem;
}

/* ---------- header ---------- */

.shop-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 0.75rem var(--gutter);
  background: var(--lemon);
  border-bottom: 2px solid var(--crimson);
}

.shop-header__brand img {
  width: auto;
  height: 52px;
}

.shop-header__nav {
  display: flex;
  gap: 0.25rem;
  margin-right: auto;
  overflow-x: auto;
  scrollbar-width: none;
}
.shop-header__nav::-webkit-scrollbar {
  display: none;
}
.shop-header__nav a {
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  white-space: nowrap;
}
.shop-header__nav a:hover {
  background: rgba(255, 67, 117, 0.1);
}

.shop-cart-button {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 1rem;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  font: 700 0.92rem var(--body);
  cursor: pointer;
}
.shop-cart-button__count {
  min-width: 1.4rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: var(--crimson);
  color: var(--white);
  font-size: 0.8rem;
  line-height: 1.4rem;
  text-align: center;
}

@media (max-width: 760px) {
  .shop-header {
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
  }
  .shop-header__brand img {
    height: 44px;
  }
  .shop-cart-button {
    margin-left: auto;
  }
  .shop-header__nav {
    order: 3;
    flex-basis: 100%;
    margin: 0 calc(var(--gutter) * -1);
    padding: 0 var(--gutter);
  }
}

/* ---------- layout ---------- */

.shop-main {
  flex: 1;
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter) 4rem;
}

.shop-eyebrow {
  margin: 0 0 0.5rem;
  color: var(--crimson);
  font: 400 0.95rem var(--sub);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* TAN ASHFORD draws taller than its em box, so tight line-heights make
   wrapped lines collide. */
h1,
h2 {
  font-family: var(--display);
  font-weight: 400;
  line-height: 1.32;
  margin: 0 0 0.75rem;
}

.shop-hero {
  padding: clamp(2rem, 6vw, 4rem) 0 1.5rem;
  max-width: 44rem;
}
.shop-hero h1 {
  font-size: clamp(2.2rem, 6vw, 3.6rem);
}
.shop-hero__lead {
  margin: 0;
  color: var(--muted);
  font-size: 1.1rem;
}

/* ---------- buttons ---------- */

.shop-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.1rem;
  padding: 0.75rem 1.5rem;
  border: 2px solid transparent;
  border-radius: 999px;
  font: 700 1rem var(--body);
  text-decoration: none;
  cursor: pointer;
  transition: transform 160ms ease, background-color 160ms ease;
}
.shop-button:hover {
  transform: translateY(-1px);
}
.shop-button:disabled {
  opacity: 0.6;
  cursor: progress;
  transform: none;
}
.shop-button--primary {
  background: var(--crimson);
  color: var(--white);
}
.shop-button--primary:hover {
  background: var(--crimson-deep);
}
.shop-button--secondary {
  background: var(--white);
  border-color: var(--ink);
  color: var(--ink);
}
.shop-button--block {
  width: 100%;
}

.shop-icon-button {
  display: inline-grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1.5px solid var(--line);
  border-radius: 50%;
  background: var(--white);
  color: var(--ink);
  font: 700 1.15rem/1 var(--body);
  cursor: pointer;
}
.shop-icon-button:hover {
  border-color: var(--ink);
}

.shop-link-button {
  padding: 0;
  border: 0;
  background: none;
  color: var(--muted);
  font: inherit;
  font-size: 0.9rem;
  text-decoration: underline;
  cursor: pointer;
}

/* ---------- catalog ---------- */

.shop-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  margin: 0.5rem 0 0.75rem;
}
.shop-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* Group colors / Every color segmented control. */
.shop-view-toggle {
  display: inline-flex;
  padding: 3px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--white);
}
.shop-view-toggle button {
  padding: 0.4rem 0.9rem;
  border: 0;
  border-radius: 999px;
  background: none;
  color: var(--muted);
  font: 700 0.88rem var(--body);
  cursor: pointer;
}
.shop-view-toggle button:hover {
  color: var(--ink);
}
.shop-view-toggle button[aria-pressed="true"] {
  background: var(--crimson);
  color: var(--white);
}
.shop-chip {
  padding: 0.5rem 1rem;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
}
.shop-chip:hover {
  border-color: var(--ink);
}
.shop-chip[aria-current="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--white);
}
.shop-filters__blurb {
  min-height: 1.5em;
  margin: 0 0 1.25rem;
  color: var(--muted);
}

.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
  gap: clamp(1rem, 2.5vw, 1.75rem);
  margin: 0;
  padding: 0;
  list-style: none;
}
.shop-grid--compact {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr));
}
@media (max-width: 560px) {
  .shop-grid,
  .shop-grid--compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem 0.75rem;
  }
  .shop-card__summary {
    display: none;
  }
  .shop-card__name {
    font-size: 0.98rem;
  }
  .shop-badge {
    top: 0.5rem;
    left: 0.5rem;
    font-size: 0.66rem;
    padding: 0.2rem 0.5rem;
  }
}
.shop-card[hidden] {
  display: none;
}

.shop-card__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
}
.shop-card__media {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  background: linear-gradient(165deg, var(--lemon), var(--light-orange));
  overflow: hidden;
}
.shop-card__media img {
  position: absolute;
  inset: 6%;
  width: 88%;
  height: 88%;
  object-fit: contain;
  transition: opacity 260ms ease, transform 400ms ease;
}
.shop-card__alt {
  opacity: 0;
}
/* A lifestyle photo fills the card instead of sitting inside it like a render. */
.shop-card__media img.shop-card__alt--photo {
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 55%;
}
.shop-card__link:hover .shop-card__media--swap img:not(.shop-card__alt),
.shop-card__link:focus-visible .shop-card__media--swap img:not(.shop-card__alt) {
  opacity: 0;
}
.shop-card__link:hover .shop-card__alt,
.shop-card__link:focus-visible .shop-card__alt {
  opacity: 1;
}
.shop-card__link:hover .shop-card__media img {
  transform: scale(1.03);
}
@media (prefers-reduced-motion: reduce) {
  .shop-card__media img {
    transition: none;
  }
  .shop-card__link:hover .shop-card__media img {
    transform: none;
  }
}

.shop-card__body {
  padding: 0.85rem 0.25rem 0;
}
.shop-card__category {
  margin: 0 0 0.15rem;
  color: var(--muted);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.shop-card__name {
  margin: 0 0 0.25rem;
  font: 700 1.08rem/1.3 var(--body);
}
.shop-card__link:hover .shop-card__name {
  text-decoration: underline;
}
.shop-card__summary {
  margin: 0 0 0.4rem;
  color: var(--muted);
  font-size: 0.93rem;
}
.shop-card__color {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0 0 0.3rem;
  font-size: 0.93rem;
  font-weight: 700;
}
.shop-card__dot {
  flex: none;
  width: 0.95rem;
  height: 0.95rem;
  border-radius: 50%;
  background: radial-gradient(circle, var(--sw-b) 0 1.5px, transparent 2px) 0 0 / 6px 6px, var(--sw-a);
  box-shadow: inset 0 0 0 1px rgba(31, 27, 29, 0.18);
}
.shop-card__price {
  margin: 0;
  font-weight: 700;
}
.shop-card__swatches {
  display: flex;
  gap: 0.35rem;
  margin: 0.55rem 0 0;
  padding: 0;
  list-style: none;
}
.shop-card__swatches li {
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  background: radial-gradient(circle, var(--sw-b) 0 1.5px, transparent 2px) 0 0 / 6px 6px, var(--sw-a);
  box-shadow: inset 0 0 0 1px rgba(31, 27, 29, 0.18);
}

.shop-badge {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 2;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: var(--white);
  color: var(--ink);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.shop-badge--preorder {
  background: var(--ink);
  color: var(--lemon);
}
.shop-badge--soon {
  background: var(--crimson);
  color: var(--white);
}
.shop-badge--soldout {
  background: var(--muted);
  color: var(--white);
}

.shop-empty {
  padding: 2rem 0;
  color: var(--muted);
}

/* ---------- product page ---------- */

.shop-breadcrumb {
  padding: 1.25rem 0;
  color: var(--muted);
  font-size: 0.9rem;
}
.shop-breadcrumb a {
  text-decoration: none;
}
.shop-breadcrumb a:hover {
  text-decoration: underline;
}
.shop-breadcrumb span[aria-hidden] {
  margin: 0 0.35rem;
}

.shop-product {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: start;
}
@media (max-width: 860px) {
  .shop-product {
    grid-template-columns: minmax(0, 1fr);
  }
}

.shop-gallery {
  position: sticky;
  top: 5.5rem;
}
@media (max-width: 860px) {
  .shop-gallery {
    position: static;
  }
}
.shop-gallery__main {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: calc(var(--radius) + 6px);
  background: linear-gradient(165deg, var(--lemon), var(--light-orange));
  overflow: hidden;
}
.shop-gallery__main img {
  position: absolute;
  inset: 4%;
  width: 92%;
  height: 92%;
  object-fit: contain;
}
/* Lifestyle photos fill the frame instead of sitting inside it like a render. */
.shop-gallery__main img.is-photo {
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.shop-gallery__thumbs {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.75rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
}
.shop-thumb {
  flex: 0 0 4.5rem;
  aspect-ratio: 4 / 5;
  padding: 0.25rem;
  border: 2px solid transparent;
  border-radius: 12px;
  background: var(--tile);
  cursor: pointer;
}
.shop-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.shop-thumb--photo img {
  object-fit: cover;
  border-radius: 8px;
}
.shop-thumb[aria-pressed="true"] {
  border-color: var(--crimson);
}

/* Keep the price and buy button close to the fold on phones. */
@media (max-width: 860px) {
  .shop-gallery__main {
    aspect-ratio: auto;
    height: min(56vh, 100vw);
  }
  .shop-thumb {
    flex-basis: 3.6rem;
  }
}

.shop-buy h1 {
  font-size: clamp(2rem, 4.5vw, 2.9rem);
  margin-bottom: 0.35rem;
}
.shop-buy__price {
  margin: 0 0 0.75rem;
  font-size: 1.35rem;
  font-weight: 700;
}
.shop-buy__summary {
  margin: 0 0 1.5rem;
  color: var(--muted);
  font-size: 1.05rem;
}
.shop-buy__form,
.shop-buy__cta {
  display: grid;
  gap: 1.15rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
}
.shop-buy__note {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}
.shop-buy__error {
  margin: 0;
  padding: 0.65rem 0.9rem;
  border-radius: 12px;
  background: #fff0f3;
  color: var(--crimson-deep);
  font-weight: 700;
  font-size: 0.93rem;
}

.shop-notify__field {
  display: grid;
  gap: 0.4rem;
  font-size: 0.95rem;
}
.shop-notify__field input {
  min-height: 2.75rem;
  padding: 0.5rem 0.9rem;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  font: inherit;
}

.shop-option {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}
.shop-option legend {
  padding: 0;
  margin-bottom: 0.55rem;
  font-size: 0.95rem;
}
.shop-option.is-missing legend {
  color: var(--crimson-deep);
}
.shop-option__help {
  margin: 0.55rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}
.shop-option__values {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.shop-pill {
  position: relative;
  display: inline-flex;
}
.shop-pill input {
  position: absolute;
  inset: 0;
  opacity: 0;
  margin: 0;
  cursor: pointer;
}
.shop-pill__text {
  display: inline-flex;
  align-items: center;
  min-width: 3.2rem;
  min-height: 2.75rem;
  padding: 0.5rem 1rem;
  justify-content: center;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  font-weight: 700;
  font-size: 0.95rem;
}
.shop-pill--swatch {
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.9rem 0.35rem 0.4rem;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--white);
}
.shop-pill--swatch .shop-pill__text {
  min-width: 0;
  min-height: 0;
  padding: 0;
  border: 0;
  background: none;
}
.shop-pill__swatch {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--sw-a) 0 60%, var(--sw-b) 60% 100%);
  box-shadow: inset 0 0 0 1px rgba(31, 27, 29, 0.15);
}
.shop-pill:hover .shop-pill__text,
.shop-pill--swatch:hover {
  border-color: var(--ink);
}
.shop-pill input:checked + .shop-pill__text,
.shop-pill input:checked ~ .shop-pill__text {
  border-color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
}
.shop-pill--swatch:has(input:checked) {
  border-color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
}
.shop-pill--swatch input:checked ~ .shop-pill__text {
  box-shadow: none;
}
.shop-pill input:focus-visible ~ .shop-pill__text,
.shop-pill--swatch:has(input:focus-visible) {
  outline: 3px solid rgba(255, 67, 117, 0.45);
  outline-offset: 2px;
}
.shop-pill.is-soldout .shop-pill__text {
  color: var(--muted);
  text-decoration: line-through;
  background: var(--tile);
}
.shop-pill.is-soldout input {
  cursor: not-allowed;
}

.shop-qty {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
}
.shop-qty__label {
  margin-right: 0.4rem;
  font-size: 0.95rem;
}
.shop-qty output {
  min-width: 1.5rem;
  text-align: center;
  font-weight: 700;
}
.shop-qty--small .shop-icon-button {
  width: 1.9rem;
  height: 1.9rem;
  font-size: 1rem;
}

.shop-callout {
  margin: 0 0 1.5rem;
  padding: 1rem 1.1rem;
  border-radius: 14px;
  background: var(--lemon);
  font-size: 0.93rem;
}
.shop-callout p {
  margin: 0;
}
.shop-callout__title {
  margin-bottom: 0.25rem !important;
  font-weight: 700;
}

.shop-accordion {
  border-bottom: 1px solid var(--line);
}
.shop-accordion summary {
  display: flex;
  justify-content: space-between;
  padding: 1rem 0;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.shop-accordion summary::-webkit-details-marker {
  display: none;
}
.shop-accordion summary::after {
  content: "\002B";
  font-size: 1.25rem;
  line-height: 1;
}
.shop-accordion[open] summary::after {
  content: "\2212";
}
.shop-accordion__body {
  padding-bottom: 1rem;
  color: var(--muted);
}
.shop-accordion__body p {
  margin: 0 0 0.75rem;
}
.shop-sheets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.75rem;
}
.shop-sheets figure {
  margin: 0;
}
.shop-sheets img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
.shop-sheets figcaption {
  margin-top: 0.35rem;
  font-weight: 700;
  color: var(--ink);
  text-align: center;
}
.shop-accordion__body ul {
  margin: 0;
  padding-left: 1.2rem;
}

.shop-related {
  margin-top: clamp(3rem, 8vw, 5rem);
}
.shop-related h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
}

/* ---------- cart drawer ---------- */

.shop-cart {
  width: min(100%, 26rem);
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  margin: 0 0 0 auto;
  padding: 0;
  border: 0;
  background: var(--white);
  color: var(--ink);
}
.shop-cart::backdrop {
  background: rgba(31, 27, 29, 0.45);
}
.shop-cart[open] {
  animation: shop-slide 220ms ease-out;
}
@keyframes shop-slide {
  from {
    transform: translateX(100%);
  }
}
@media (prefers-reduced-motion: reduce) {
  .shop-cart[open] {
    animation: none;
  }
}
.shop-cart__panel {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.shop-cart__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--line);
}
.shop-cart__head h2 {
  margin: 0;
  font-size: 1.6rem;
}
.shop-cart__body {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}
.shop-cart__added {
  margin: 0;
  padding: 0.75rem 1.25rem;
  background: #eaf6ef;
  color: var(--success);
  font-weight: 700;
  font-size: 0.93rem;
}
.shop-cart__lines {
  margin: 0;
  padding: 0 1.25rem;
  list-style: none;
}
.shop-line {
  display: flex;
  gap: 0.9rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
}
.shop-line__media {
  flex: 0 0 4.5rem;
  border-radius: 12px;
  background: var(--tile);
  overflow: hidden;
}
.shop-line__media img {
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 5;
  object-fit: contain;
}
.shop-line__body {
  flex: 1;
  min-width: 0;
}
.shop-line__top {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  font-weight: 700;
}
.shop-line__top a {
  text-decoration: none;
}
.shop-line__variant {
  margin: 0.15rem 0 0.5rem;
  color: var(--muted);
  font-size: 0.9rem;
}
.shop-line__controls {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.shop-cart__foot {
  margin-top: auto;
  padding: 1.25rem;
  display: grid;
  gap: 0.75rem;
  border-top: 1px solid var(--line);
  background: var(--paper);
}
.shop-cart__subtotal {
  display: flex;
  justify-content: space-between;
  margin: 0;
  font-size: 1.1rem;
}
.shop-cart__note {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}
.shop-cart__empty {
  margin: auto;
  padding: 2rem;
  text-align: center;
  color: var(--muted);
}

/* ---------- pre-order extras (cart, overlay, kit pages) ---------- */

/* Product page extras cards: included ones get a check, locked ones say
   what unlocks them. */
.shop-perks {
  margin: 0 0 1.5rem;
}
.shop-perks__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.25rem 1rem;
  margin-bottom: 0.75rem;
}
.shop-perks__head h2 {
  margin: 0;
  font-size: 1.35rem;
}
.shop-perks__total {
  margin: 0;
  color: var(--success);
  font-weight: 700;
  font-size: 0.93rem;
}
.shop-perks__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
  gap: 0.65rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.shop-perk {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.65rem 0.65rem 0.8rem;
  border: 1.5px dashed var(--line);
  border-radius: 16px;
  background: var(--white);
  font-size: 0.85rem;
  transition: border-color 200ms ease, box-shadow 200ms ease;
}
.shop-perk.is-included {
  border-style: solid;
  border-color: var(--success);
  box-shadow: 0 0 0 1px var(--success) inset;
}
.shop-perk__check {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  display: none;
}
.shop-perk.is-included .shop-perk__check {
  display: block;
  animation: shop-pop-thumb 320ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
.shop-perk__check circle {
  fill: var(--success);
}
.shop-perk__check path {
  fill: none;
  stroke: var(--white);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.shop-perk__media {
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  margin-bottom: 0.4rem;
  border-radius: 12px;
  background: var(--tile);
}
.shop-perk__media img {
  width: 68%;
  height: auto;
  max-height: 92%;
  object-fit: contain;
  transition: opacity 200ms ease, filter 200ms ease;
}
.shop-perk__media--photo {
  overflow: hidden;
}
.shop-perk__media--photo img {
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: cover;
}
.shop-perk:not(.is-included) .shop-perk__media img {
  opacity: 0.55;
  filter: grayscale(0.5);
}
.shop-perk__name {
  font-weight: 700;
  line-height: 1.25;
}
.shop-perk__value {
  color: var(--muted);
}
.shop-perk__status {
  margin-top: auto;
  padding-top: 0.35rem;
  color: var(--crimson-deep);
  font-weight: 700;
  line-height: 1.3;
}
.shop-perk.is-included .shop-perk__status {
  color: var(--success);
}
.shop-perk__bar {
  display: block;
  height: 5px;
  margin-top: 0.3rem;
  border-radius: 999px;
  background: var(--tile);
  overflow: hidden;
}
.shop-perk__bar[hidden] {
  display: none;
}
.shop-perk__bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--crimson);
  transition: width 300ms ease;
}
.shop-perk__action {
  margin-top: 0.3rem;
  color: var(--ink);
  font-weight: 700;
}
@media (prefers-reduced-motion: reduce) {
  .shop-perk.is-included .shop-perk__check {
    animation: none;
  }
}
.shop-extras {
  margin: 1rem 1.25rem 0;
  padding: 0.9rem 1rem;
  border-radius: 14px;
  background: var(--lemon);
  font-size: 0.9rem;
}
.shop-extras p {
  margin: 0;
}
.shop-extras a {
  font-weight: 700;
  color: var(--crimson-deep);
}
.shop-extras__title {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  font-weight: 700;
}
.shop-extras__title span {
  color: var(--success);
}
.shop-extras__list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem 0.4rem;
  margin: 0.5rem 0 0;
  padding: 0;
  list-style: none;
}
.shop-extras__list li {
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  background: var(--white);
  color: var(--success);
  font-size: 0.82rem;
  font-weight: 700;
}
.shop-extras__next {
  margin-top: 0.65rem;
  padding-top: 0.65rem;
  border-top: 1px dashed rgba(31, 27, 29, 0.18);
}
.shop-extras__bar {
  display: block;
  height: 6px;
  margin-bottom: 0.45rem;
  border-radius: 999px;
  background: var(--white);
  overflow: hidden;
}
.shop-extras__bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--crimson);
}
.shop-extras--teaser {
  display: grid;
  gap: 0.35rem;
}

/* ---------- pairing picks (cart, overlay) ---------- */

.shop-picks {
  margin: 1rem 1.25rem 0;
}
.shop-picks__title {
  margin: 0 0 0.25rem;
  font: 700 1rem var(--body);
}
.shop-picks__list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.shop-pick {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--line);
}
.shop-pick:last-child {
  border-bottom: 0;
}
.shop-pick__media {
  flex: 0 0 3.5rem;
  border-radius: 10px;
  background: var(--tile);
  overflow: hidden;
}
.shop-pick__media img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: contain;
}
.shop-pick__body {
  flex: 1;
  min-width: 0;
  font-size: 0.88rem;
}
.shop-pick__body p {
  margin: 0;
}
.shop-pick__name {
  font-weight: 700;
  text-decoration: none;
}
.shop-pick__note {
  color: var(--muted);
}
.shop-pick__unlock {
  color: var(--crimson-deep);
  font-weight: 700;
}
.shop-pick__price {
  font-weight: 700;
}
.shop-pick__action {
  flex: none;
  min-height: 2.4rem;
  padding: 0.4rem 1rem;
  font-size: 0.88rem;
}
.shop-pick__done {
  flex: none;
  color: var(--success);
  font-weight: 700;
  font-size: 0.88rem;
}

/* ---------- "added to your cart" overlay ---------- */

.shop-added {
  width: min(calc(100% - 2rem), 30rem);
  max-height: min(calc(100% - 2rem), 46rem);
  /* Pinned near the top so it grows downward when the picks reveal. */
  margin: max(1rem, 8vh) auto auto;
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--ink);
  box-shadow: 0 24px 60px rgba(31, 27, 29, 0.25);
}
.shop-added::backdrop {
  background: rgba(31, 27, 29, 0.45);
}
.shop-added[open] {
  animation: shop-pop 200ms ease-out;
}
@keyframes shop-pop {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
}
.shop-added__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.25rem 0;
}
.shop-added__head h2 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  font-size: 1.5rem;
}
.shop-added__item {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin: 0.9rem 1.25rem 1.1rem;
}

/* Beat one: the confirmation. The check draws its circle, then its tick,
   while the item pops in and the heading slides over. These only run until
   the overlay settles, so a re-render (a quick add) doesn't replay them;
   the rules without animation are the finished state. */
.shop-added__check {
  flex: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.shop-added__check circle {
  fill: var(--success);
  stroke: var(--success);
}
.shop-added__check path {
  fill: none;
  stroke: var(--white);
}
.shop-added__check circle,
.shop-added__check path {
  stroke-dasharray: 1;
}
.shop-added:not(.is-settled) .shop-added__check circle {
  animation: shop-draw 380ms 80ms ease-out both, shop-fill 260ms 420ms ease-out both;
}
.shop-added:not(.is-settled) .shop-added__check path {
  animation: shop-draw 260ms 380ms ease-out both;
}
.shop-added:not(.is-settled) .shop-added__check {
  animation: shop-thump 320ms 600ms ease-out;
}
@keyframes shop-draw {
  from {
    stroke-dashoffset: 1;
  }
}
@keyframes shop-fill {
  from {
    fill: transparent;
  }
}
@keyframes shop-thump {
  50% {
    transform: scale(1.18);
  }
}
.shop-added:not(.is-settled) .shop-added__head h2 span {
  animation: shop-slide-in 320ms 120ms ease-out both;
}
.shop-added:not(.is-settled) .shop-added__item {
  animation: shop-slide-in 360ms 200ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
.shop-added:not(.is-settled) .shop-added__item img {
  animation: shop-pop-thumb 480ms 220ms cubic-bezier(0.34, 1.56, 0.64, 1) both;
}
@keyframes shop-slide-in {
  from {
    opacity: 0;
    transform: translateX(-10px);
  }
}
@keyframes shop-pop-thumb {
  from {
    opacity: 0;
    transform: scale(0.6) rotate(-6deg);
  }
}

/* Beat two: the panel grows, then extras, picks and checkout rise in one
   after another. It clips while growing, then stops clipping
   (.is-settled) so the sticky checkout bar works. */
.shop-added__more {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 460ms cubic-bezier(0.2, 0.8, 0.2, 1);
}
.shop-added.is-revealed .shop-added__more {
  grid-template-rows: 1fr;
}
.shop-added__more-inner {
  min-height: 0;
  overflow: hidden;
}
.shop-added.is-settled .shop-added__more-inner {
  overflow: visible;
}
.shop-added__more-inner > :first-child {
  margin-top: 0;
}
.shop-added .shop-extras,
.shop-added .shop-picks__title,
.shop-added .shop-pick,
.shop-added .shop-added__actions {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 320ms ease-out var(--d, 0ms), transform 420ms cubic-bezier(0.2, 0.8, 0.2, 1) var(--d, 0ms);
}
.shop-added.is-revealed .shop-extras,
.shop-added.is-revealed .shop-picks__title,
.shop-added.is-revealed .shop-pick,
.shop-added.is-revealed .shop-added__actions {
  opacity: 1;
  transform: none;
}
.shop-added .shop-extras {
  --d: 40ms;
}
.shop-added .shop-picks__title {
  --d: 100ms;
}
.shop-added .shop-pick:nth-child(1) {
  --d: 150ms;
}
.shop-added .shop-pick:nth-child(2) {
  --d: 210ms;
}
.shop-added .shop-pick:nth-child(3) {
  --d: 270ms;
}
.shop-added .shop-added__actions {
  --d: 320ms;
}
/* A freshly unlocked extra (after a quick add) pops in. */
.shop-added .shop-extras__list li.is-new {
  animation: shop-pop-thumb 360ms cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

/* The header cart count bounces when something is added. */
.shop-cart-button__count.is-bumped {
  animation: shop-bump 500ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes shop-bump {
  40% {
    transform: scale(1.45);
  }
}
.shop-added__item img {
  flex: 0 0 4.5rem;
  width: 4.5rem;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: contain;
  border-radius: 12px;
  background: var(--tile);
}
.shop-added__item p {
  margin: 0;
}
.shop-added__name,
.shop-added__price {
  font-weight: 700;
}
.shop-added__item .shop-line__variant {
  margin: 0.1rem 0 0.2rem;
}
/* Checkout stays in reach while the picks scroll. */
.shop-added__actions {
  position: sticky;
  bottom: 0;
  display: grid;
  gap: 0.6rem;
  margin-top: 1rem;
  padding: 1rem 1.25rem 1.25rem;
  border-top: 1px solid var(--line);
  background: var(--paper);
}
.shop-added__actions .shop-link-button {
  justify-self: center;
}
/* A bottom sheet on phones. */
@media (max-width: 560px) {
  .shop-added {
    width: 100%;
    max-width: 100%;
    max-height: 88dvh;
    margin: auto 0 0;
    border-radius: var(--radius) var(--radius) 0 0;
  }
  .shop-added__head h2 {
    font-size: 1.25rem;
  }
  .shop-added__actions {
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    padding: 0.75rem 1rem calc(0.75rem + env(safe-area-inset-bottom));
  }
  .shop-added__actions .shop-button {
    min-height: 2.75rem;
    padding: 0.5rem 0.75rem;
    font-size: 0.92rem;
  }
  .shop-added__actions .shop-link-button {
    grid-column: 1 / -1;
  }
  .shop-added[open] {
    animation-name: shop-rise;
  }
  @keyframes shop-rise {
    from {
      transform: translateY(100%);
    }
  }
}
@media (prefers-reduced-motion: reduce) {
  .shop-added[open],
  .shop-added[open] *,
  .shop-added .shop-extras__list li.is-new,
  .shop-cart-button__count.is-bumped {
    animation: none !important;
  }
  .shop-added .shop-added__more,
  .shop-added .shop-added__more * {
    transition: none !important;
  }
}

/* ---------- thanks ---------- */

.shop-thanks {
  max-width: 36rem;
  padding: clamp(2rem, 6vw, 4rem) 0;
}
.shop-thanks h1 {
  font-size: clamp(2.2rem, 6vw, 3.2rem);
}
.shop-thanks__order {
  margin: 1.75rem 0;
  padding: 1.25rem;
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--line);
}
.shop-thanks__lines {
  margin: 0;
  padding: 0;
  list-style: none;
}
.shop-thanks__lines li,
.shop-thanks__total {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.5rem 0;
}
.shop-thanks__total {
  margin: 0.5rem 0 0;
  border-top: 1px solid var(--line);
  font-size: 1.1rem;
}
.shop-thanks .shop-callout {
  margin: 1rem 0 0;
}

/* ---------- footer ---------- */

.shop-footer {
  padding: 2.5rem var(--gutter);
  background: var(--light-crimson);
  color: var(--ink);
  text-align: center;
  font-size: 0.9rem;
}
.shop-footer p {
  margin: 0.25rem 0;
}
.shop-footer__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.25rem;
  margin: 0.75rem 0;
  font-weight: 700;
}
.shop-footer__script {
  font-family: "Chillink", cursive;
  font-size: 2rem;
  color: var(--white);
  margin-bottom: 0.5rem !important;
}
