:root {
  --paper: var(--rr-ivory);
  --white: var(--rr-pearl);
  --ink: var(--rr-ink);
  --brown: var(--rr-forest);
  --wine: var(--rr-gold-ink);
  --muted: var(--rr-muted);
  --line: var(--rr-rule);
  --accent: var(--rr-sage);
  --hover: var(--rr-forest-hover);
  --display: var(--rr-display);
  --radius: 10px;
  color-scheme: light;
  font: 16px/1.5 "Segoe UI", Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body, h1, h2, h3, p { margin: 0; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--wine); outline-offset: 3px; }
h1, h2, h3 { font-family: Georgia, serif; font-weight: 400; line-height: 1.12; }
h2 { font-size: clamp(1.85rem, 4vw, 2.75rem); letter-spacing: -.035em; }
h3 { font-size: 1.4rem; }
img { display: block; max-width: 100%; object-fit: cover; }

.shell { width: min(1180px, calc(100% - 72px)); margin-inline: auto; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.top {
  min-height: 74px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}
.brand { font: 500 1.85rem/1.05 Georgia, serif; letter-spacing: -.065em; white-space: nowrap; }
.brand span { color: var(--wine); }
.top nav { display: flex; gap: 4px; padding: 4px; background: var(--rr-linen); border-radius: 7px; }
.top button { border: 1px solid transparent; background: transparent; padding: 6px 14px; border-radius: 5px; font-size: .92rem; }
.top nav [aria-pressed="true"] { border-color: var(--brown); background: var(--brown); color: var(--rr-on-forest); font-weight: 650; }
.top .planner { justify-self: end; border-color: var(--line); white-space: nowrap; }
.top .planner[aria-pressed="true"] { background: var(--accent); border-color: var(--wine); }

.progress {
  list-style: none;
  padding: 13px 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-block: 0;
  border-bottom: 1px solid var(--line);
}
.progress li { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: .88rem; }
.progress span {
  flex: 0 0 24px;
  display: grid;
  place-items: center;
  height: 24px;
  border: 1px solid var(--line);
  border-radius: 50%;
  font-size: .78rem;
}
.progress [aria-current] { color: var(--ink); font-weight: 650; }
.progress [aria-current] span { background: var(--brown); color: var(--white); border-color: var(--brown); }

.hero {
  display: grid;
  grid-template-columns: 1.03fr 1fr;
  align-items: center;
  gap: 42px;
  padding-block: 32px;
}
.hero img { width: 100%; height: auto; aspect-ratio: 1.62; object-position: 50% 55%; border-radius: var(--radius); }
h1 { font-size: clamp(2.85rem, 5.7vw, 4.65rem); line-height: .99; letter-spacing: -.052em; margin-bottom: 16px; }
h1 em { color: var(--wine); }
.intro { max-width: 42ch; color: var(--muted); margin-bottom: 20px; }
.action {
  display: inline-block;
  padding: 11px 17px;
  background: var(--brown);
  color: var(--white);
  border: 1px solid transparent;
  border-radius: 5px;
  font-weight: 650;
  white-space: nowrap;
}
.action:disabled { opacity: .65; cursor: wait; }

.collection, .workbench, .design-card { scroll-margin-top: 16px; }
.section-head { display: flex; align-items: end; gap: 10px 24px; justify-content: space-between; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 19px; margin-bottom: 16px; }
.section-head p, .step-heading p { color: var(--muted); }
.catalog-filters, .catalog-types {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin-bottom: 16px;
}
.catalog-filters a, .catalog-types a {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  min-height: 44px;
  padding: 5px 12px;
  border: 1px solid var(--rr-rule);
  border-radius: 4px;
  background: var(--rr-pearl);
  white-space: nowrap;
}
.catalog-filters a { font: 1rem var(--rr-display); }
.catalog-filters a span { font: .76rem/1.3 system-ui, sans-serif; }
.catalog-filters a:hover, .catalog-types a:hover { background: var(--rr-linen); }
.catalog-filters a[aria-current] {
  border-color: var(--rr-forest);
  background: var(--rr-forest);
  color: var(--rr-on-forest);
}
.catalog-types { font-size: .86rem; }
.catalog-types > span { color: var(--rr-muted); }
.collection-reference { margin-bottom:16px; color:var(--rr-gold-ink); }
.collection-reference a { display:inline-flex;align-items:center;gap:.6em;min-height:44px;text-decoration:underline;text-underline-offset:.25em; }
.category[id] { scroll-margin-top: 16px; }
@media (max-width: 760px) {
  .catalog-filters, .catalog-types { flex-wrap: nowrap; overflow-x: auto; padding: 3px 2px 7px; }
  .catalog-filters a, .catalog-types a, .catalog-types span { flex: none; }
  .catalog-filters a:focus-visible, .catalog-types a:focus-visible { outline-offset: -3px; }
}
.grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: start;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.category { position: relative; min-width: 0; }
.category.is-open { z-index: 2; }
.category-trigger {
  position: relative;
  width: 100%;
  padding: 0;
  text-align: left;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.category-trigger:hover, .is-open .category-trigger { border-color: var(--rr-gold); }
.category-image { width: 100%; height: auto; aspect-ratio: 1.26; border-radius: 9px 9px 0 0; }
.category-caption { display: grid; align-content: start; padding: 10px 28px 11px 11px; min-height: 74px; }
.category-caption strong { font: 1.1rem/1.14 Georgia, serif; }
.category-caption span, .style-row span { color: var(--muted); font-size: .82rem; display: block; margin-top: 3px; }
.chevron { position: absolute; right: 11px; bottom: 13px; font-size: 1.18rem; color: var(--wine); }
.is-open .chevron { transform: rotate(180deg); }
.styles {
  position: absolute;
  inset: calc(100% - 1px) 0 auto;
  overflow: auto;
  max-height: min(380px, 55vh);
  margin: 0;
  padding: 5px 8px;
  background: var(--white);
  border: 1px solid var(--rr-gold);
  border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: 0 14px 28px #3b241a20;
  list-style: none;
}
.style-row { display: grid; grid-template-columns: 43px minmax(0, 1fr) auto; gap: 7px; align-items: center; padding: 7px 0; }
.style-row + .style-row { border-top: 1px solid var(--line); }
.style-row img { width: 43px; height: 43px; border-radius: 5px; }
.style-row strong { display: block; font-size: .85rem; line-height: 1.18; }
.add, .remove {
  padding: 4px 7px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  color: var(--brown);
  font-size: .85rem;
  font-weight: 650;
}
.add:hover, .remove:hover { background: var(--accent); }


.workbench { padding-top: 20px; min-height: 55vh; }
.back-link, .index-link { background: transparent; border: 0; padding: 0; color: var(--wine); text-decoration: underline; text-underline-offset: 3px; }
.step-heading { margin: 12px 0 22px; }
.step-heading p { margin-top: 8px; }
.design-layout, .quote-layout { display: grid; grid-template-columns: minmax(210px, .6fr) minmax(0, 1.65fr); gap: 18px; align-items: start; }
.shared, .design-card, .summary, .quote-form { border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); padding: 16px; }
.shared { position: sticky; top: 14px; }
.shared textarea { margin-top: 10px; }
.design-index { list-style: none; margin: 13px 0 0; padding: 11px 0 0; border-top: 1px solid var(--line); max-height: 32vh; overflow: auto; }
.index-link { display: block; text-align: left; margin: 3px 0 6px; font-size: .86rem; }
.design-items { display: grid; gap: 14px; }
.design-card { display: grid; grid-template-columns: minmax(100px, .58fr) minmax(0, 1.4fr); align-items: start; gap: 16px; }
.design-visual img { width: 100%; height: auto; aspect-ratio: 1; border-radius: 7px; }
.design-visual .hint { margin-top: 8px; }
.quantity-row { display: flex; align-items: center; gap: 10px; margin: 8px 0 12px; }
.fields label, .templates legend { display: block; font-size: .9rem; font-weight: 650; margin: 8px 0 4px; }
.fields input:not([type="checkbox"], [type="radio"]), .fields select, .fields textarea {
  width: 100%;
  min-width: 0;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--rr-pearl);
  padding: 7px 9px;
}
.fields input.quantity { width: 82px; }
.fields input[type="file"] { font-size: .83rem; }
.fields textarea { resize: vertical; }
.templates { margin: 0; padding: 0; border: 0; min-width: 0; }
.template-options { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; }
.template-options .template {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 3px;
  align-content: start;
  margin: 0;
  padding: 6px 3px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--paper);
  text-align: center;
  font-size: .73rem;
  cursor: pointer;
}
.template input { position: absolute; opacity: 0; }
.template:has(input:focus-visible) { outline: 2px solid var(--wine); outline-offset: 2px; }
.template:has(input:checked) { border-color: var(--wine); background: var(--accent); }
.motif { font: 1.37rem/1.2 Georgia, serif; color: var(--wine); white-space: nowrap; }
.fields .wording-toggle { display: flex; align-items: center; gap: 6px; margin-top: 12px; width: fit-content; }
.wording-toggle input { accent-color: var(--wine); }
.shared-preview { background: var(--paper); border-radius: 5px; padding: 7px 9px; color: var(--muted); font-size: .87rem; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 9rem; overflow: auto; }
.hint { color: var(--muted); font-size: .83rem; margin: 4px 0; }
.step-actions { display: grid; justify-items: end; gap: 8px; margin-top: 14px; }
#design-status { color: var(--wine); font-size: .9rem; }
.summary ul { list-style: none; margin: 5px 0; padding: 0; }
.summary li { display: grid; padding: 8px 0; border-bottom: 1px solid var(--line); }
.summary li span { color: var(--muted); font-size: .83rem; }
.summary-total { font-weight: 650; padding-top: 8px; }
.paired { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.submit { width: 100%; margin: 13px 0 3px; }
.notice { margin-top: 12px; padding: 12px; background: var(--accent); border: 1px solid var(--line); border-radius: 6px; }
.notice button { display: block; margin-top: 6px; }
.footer { display: flex; flex-wrap: wrap; column-gap: 22px; row-gap: 8px; align-items: baseline; margin-top: 33px; padding-block: 18px; border-top: 1px solid var(--line); }
.footer .brand { font-size: 1.23rem; }
.footer-about { text-decoration: underline; text-underline-offset: .2em; }

@media (hover: hover) and (min-width: 871px) {
  .grid:has(.category:nth-last-child(-n+4).is-open) { padding-bottom: 17rem; }
}
@media (max-width: 870px) {
  .shell { width: calc(100% - 36px); }
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 11px; }
  .styles { position: static; max-height: none; box-shadow: none; }
  .hero { gap: 22px; }
  .template-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px) {
  .shell { width: calc(100% - 26px); }
  .top { min-height: 62px; grid-template-columns: 1fr auto auto; gap: 6px; }
  .brand { font-size: 1.46rem; }
  .top button { padding: 6px 7px; font-size: .79rem; }
  .top .planner { padding-inline: 6px; }
  .progress { gap: 6px; padding-block: 9px; }
  .progress li { gap: 4px; font-size: .72rem; line-height: 1.2; }
  .progress span { flex-basis: 19px; height: 19px; font-size: .68rem; }
  .hero { grid-template-columns: 1fr; padding-block: 19px; gap: 15px; }
  h1 { margin-bottom: 10px; }
  .intro { margin-bottom: 11px; }
  .hero img { aspect-ratio: 2.1; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .category-caption { min-height: 71px; }
  .category-caption strong { font-size: 1rem; }
  .style-row { grid-template-columns: 29px minmax(0, 1fr) auto; gap: 4px; }
  .style-row img { width: 29px; height: 29px; }
  .style-row strong { font-size: .75rem; }
  .style-row span { font-size: .7rem; }
  .add { padding: 4px; min-height: 34px; }
  .design-layout, .quote-layout { grid-template-columns: 1fr; gap: 11px; }
  .shared { position: static; }
  .design-index { display: flex; flex-wrap: wrap; gap: 2px 12px; max-height: none; }
  .shared, .design-card, .summary, .quote-form { padding: 11px; }
  .design-card { grid-template-columns: 76px minmax(0, 1fr); gap: 9px; }
  .design-visual .hint { font-size: .73rem; }
}

/* Storefront themes and product browsing */
.top { min-height: 79px; }
.top nav { border-radius: 999px; }
.top nav button { border-radius: 999px; min-width: 77px; }
.top .planner { border-radius: 999px; }
.brand { font-size: 2.05rem; }
.brand span { color: var(--wine); }
h1, h2, h3 { font-family: var(--display); }
.progress { padding-block: 11px; }
.progress li { justify-content: center; }
.progress li:first-child { justify-content: flex-start; }
.progress li:last-child { justify-content: flex-end; }
.action { border-radius: 999px; padding-inline: 19px; transition: background-color 160ms ease, transform 160ms ease; }
.action:hover { background: var(--hover); transform: translateY(-1px); }
.hero {
  position: relative;
  margin-block: 21px 34px;
  padding: clamp(22px, 4.1vw, 59px);
  gap: clamp(26px, 4vw, 59px);
  grid-template-columns: 1fr 1.08fr;
  background: linear-gradient(125deg, var(--rr-forest), var(--rr-forest-deep));
  color: var(--rr-on-forest);
  border: 1px solid var(--rr-gold);
  border-radius: 3px 3px 22px 3px;
  isolation: isolate;
}
.hero h1 { font-size: clamp(2.65rem, 5.3vw, 4.85rem); line-height: .97; }
.hero h1 em { font-weight: inherit; color: var(--rr-champagne); }
.hero .intro { max-width: 37ch; color: var(--rr-on-forest-muted); }
.hero .action { color: var(--ink); background: var(--rr-champagne); }
.hero .action:hover { background: var(--rr-pearl); }
.hero-art { position: relative; min-width: 0; }
.hero-art img {
  aspect-ratio: 1.29;
  object-position: 50% 53%;
  border: 1px solid var(--rr-gold);
  border-radius: 45% 45% 2px 2px / 38% 38% 2px 2px;
}
[data-theme="party"] .hero {
  border-color: var(--rr-rule);
  background: linear-gradient(130deg, var(--rr-pearl), var(--rr-linen) 55%, var(--rr-rose));
  color: var(--rr-ink);
}
[data-theme="party"] .hero-art img {
  object-position: 50% 47%;
}
[data-theme="party"] .hero h1 em { color: var(--rr-gold-ink); }
[data-theme="party"] .hero .intro { color: var(--rr-muted); }
[data-theme="party"] .hero .action { color: var(--rr-on-forest); background: var(--rr-forest); }
[data-theme="party"] .hero .action:hover { background: var(--rr-forest-hover); }
@keyframes storefront-enter { from { transform: translateY(6px); } to { transform: translateY(0); } }
@keyframes menu-enter { from { opacity: .4; } to { opacity: 1; } }
.hero, .product-layout { animation: storefront-enter 340ms ease-out both; }
.section-head { padding-top: 12px; }
.section-head h2 { letter-spacing: -.05em; }
.category-tile {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
.category-tile:hover, .is-open .category-tile {
  border-color: var(--wine);
  box-shadow: var(--rr-shadow);
}
.category-cover { display: block; border-radius: var(--radius) var(--radius) 0 0; }
.category-cover:hover img { filter: brightness(1.04); }
.category-trigger { background: transparent; border: 0; border-radius: 0 0 var(--radius) var(--radius); }
.category-caption strong { font-family: var(--display); }
.category-caption { min-height: 67px; }

.styles {
  position: absolute;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 56px) / 5);
  inset: calc(100% - 1px) auto auto var(--panel-left, 0px);
  width: var(--panel-width, 100%);
  margin: 0;
  padding: 12px;
  gap: 14px;
  max-height: min(370px, 58vh);
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  background: var(--white);
  border: 1px solid var(--wine);
  border-radius: 12px;
  box-shadow: 0 14px 40px #23271638;
  animation: menu-enter 140ms ease-out both;
}
.opens-above > .styles { top: auto; bottom: calc(100% - 1px); }
.style-row, .style-row + .style-row {
  display: flex;
  align-items: stretch;
  flex-direction: column;
  padding: 0;
  gap: 7px;
  border: 0;
  min-width: 0;
}
.style-link {
  min-width: 0;
  display: flex;
  flex-direction: column;
  flex: 1;
  border-radius: 8px;
}
.style-link img {
  width: 100%;
  height: auto;
  aspect-ratio: 1.36;
  border-radius: 7px;
}
.style-link strong { margin-top: 7px; font-size: .92rem; font-weight: 650; }
.style-link:hover strong { color: var(--wine); text-decoration: underline; }
.style-link span { margin-top: 2px; }
.style-row .add { align-self: start; padding: 5px 14px; min-height: 31px; border-radius: 999px; }
.category-trigger, .style-link, .product-style, .action, .selection-drawer button { -webkit-tap-highlight-color: #80556d26; }
.product-detail { padding-top: 20px; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 7px; color: var(--muted); font-size: .86rem; margin-bottom: 16px; }
.breadcrumbs a { text-decoration: underline; text-underline-offset: 3px; color: var(--wine); }
.product-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.19fr) minmax(0, 1fr);
  align-items: start;
  gap: clamp(22px, 4vw, 56px);
}
.product-gallery, .product-copy { min-width: 0; }
.product-image-button { position: relative; display: block; width: 100%; padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: transparent; }
.product-image-button img { width: 100%; height: auto; aspect-ratio: 1; object-fit: contain; transition: transform 270ms ease; }
.product-image-button:hover img { transform: scale(1.025); }
.zoom-label { position: absolute; right: 12px; bottom: 12px; color: var(--ink); background: var(--white); border: 1px solid var(--line); border-radius: 999px; padding: 5px 11px; font-size: .8rem; }
.product-gallery-frame { position: relative; }
.photo-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 42px;
  height: 42px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--white);
  font-size: 1.85rem;
  line-height: 1;
}
.photo-prev { left: 9px; }
.photo-next { right: 9px; }
.gallery-caption { display: flex; justify-content: space-between; margin-top: 7px; color: var(--muted); font-size: .8rem; }
.product-photos { display: flex; gap: 8px; padding: 4px; margin: 5px 0 0; list-style: none; overflow-x: auto; }
.photo-thumb { display: block; padding: 3px; border: 1px solid var(--line); border-radius: 7px; background: var(--white); }
.photo-thumb img { width: 69px; height: 69px; border-radius: 4px; }
.photo-thumb[aria-pressed="true"] { border-color: var(--wine); box-shadow: 0 0 0 1px var(--wine); }
.variant-section { border-top: 1px solid var(--line); padding-top: 12px; }
.variant-section h2 { font: 650 .92rem/1.25 "Segoe UI", Arial, sans-serif; letter-spacing: 0; }
.product-styles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); list-style: none; gap: 7px; padding: 0; margin: 8px 0 0; }
.product-style {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 7px;
  height: 100%;
  min-height: 56px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 8px;
  align-items: center;
  color: var(--muted);
  font-size: .73rem;
  line-height: 1.22;
}
.product-style img { width: 44px; height: 44px; aspect-ratio: 1; border-radius: 4px; }
.product-style-labels { min-width: 0; display: grid; gap: 3px; overflow-wrap: anywhere; }
.product-style-labels strong { color: var(--ink); font-size: .83rem; }
.product-style:hover, .product-style[aria-current] { border-color: var(--wine); background: var(--accent); color: var(--ink); }
.product-style[aria-current] { box-shadow: inset 0 0 0 1px var(--wine); }
.product-price { color: var(--wine); font-size: 1.13rem; font-weight: 650; }
.product-description { margin-block: 12px 18px; max-width: 48ch; color: var(--muted); }
.product-estimate-note { margin: -8px 0 16px; max-width: 54ch; color: var(--muted); font-size: .88rem; }
.product-specs { margin: 0; padding: 0; border-top: 1px solid var(--line); }
.product-specs > div { display: grid; grid-template-columns: minmax(90px, .63fr) minmax(0, 1.37fr); padding: 8px 0; gap: 8px; border-bottom: 1px solid var(--line); font-size: .9rem; }
.product-specs dt { font-weight: 650; }
.product-specs dd { margin: 0; color: var(--muted); }
.product-purchase { display: flex; align-items: end; gap: 10px; margin-top: 13px; }
.product-purchase .action { flex: 1; min-height: 43px; }
.product-feedback { color: var(--wine); font-size: .86rem; margin-top: 6px; }
.quote-process { display: grid; gap: 7px; margin: 9px 0 4px 1.3rem; padding: 0; color: var(--muted); font-size: .9rem; }
#image-dialog { padding: 0; width: min(650px, calc(100% - 24px)); max-height: calc(100% - 20px); border: 1px solid var(--line); border-radius: 13px; background: var(--white); }
#image-dialog::backdrop { background: color-mix(in srgb, var(--rr-forest-deep) 74%, transparent); }
#image-dialog img { width: 100%; height: auto; max-height: 88vh; object-fit: contain; }
#zoom-caption { padding: .55rem .8rem; color: var(--muted); text-align: center; }
.style-comparison { margin-top: 12px; color: var(--muted); font-size: .86rem; }
.style-comparison summary { cursor: pointer; min-height: 34px; }
.style-comparison table { width: 100%; border-collapse: collapse; text-align: left; }
.style-comparison th, .style-comparison td { padding: 6px; border-bottom: 1px solid var(--line); }
.style-comparison :is(th, td):last-child { white-space: nowrap; }
.style-comparison .current-style { color: var(--ink); background: var(--rr-linen); }
.shared, .summary { background: linear-gradient(140deg, var(--rr-pearl), var(--rr-linen)); }
.design-card, .quote-form { box-shadow: var(--rr-shadow); }
.hero :focus-visible { outline-color: var(--rr-champagne); }
[data-theme="party"] .hero :focus-visible { outline-color: var(--rr-gold-ink); }
.design-visual h4 { margin: 14px 0 6px; font-size: .85rem; }
.personalization-preview {
  display: grid;
  justify-items: center;
  gap: 6px;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--rr-linen);
  text-align: center;
}
.preview-motif { color: var(--wine); font: 1.4rem/1.25 Georgia, serif; }
.preview-wording {
  max-width: 100%;
  max-height: 12rem;
  overflow: auto;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
  font: 1.02rem/1.4 Georgia, serif;
}
.personalization-preview .preview-upload {
  width: auto;
  max-width: 100%;
  max-height: 132px;
  height: auto;
  aspect-ratio: auto;
  object-fit: contain;
}
.preview-attachment { max-width: 100%; overflow-wrap: anywhere; }
.summary-item-heading {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.summary-item-heading img { width: 48px; height: 48px; border-radius: 4px; object-fit: cover; }
.summary-item-heading span { display: block; }
.summary-item-heading button { min-height: 44px; }
#product-design { min-height: 44px; }
#store-transition {
  position: fixed;
  inset: 0;
  z-index: 70;
  opacity: 0;
  pointer-events: none;
  background: linear-gradient(105deg, var(--rr-linen) 5%, #fcf4e644 56%, var(--rr-champagne));
}
@media (max-width: 480px) {
  .top { grid-template-columns: minmax(0, 1fr) auto; padding-block: 8px; row-gap: 4px; }
  .top nav { grid-row: 2; justify-self: start; }
}
@media (max-width: 370px) {
  .product-purchase { align-items: stretch; flex-direction: column; }
}
#close-image { position: absolute; top: 8px; right: 8px; border: 1px solid var(--line); border-radius: 999px; background: var(--white); width: 38px; height: 38px; font-size: 1.25rem; }

@media (max-width: 870px) {
  .styles { grid-auto-columns: minmax(135px, calc((100% - 42px) / 4)); }
  .style-row img { width: 100%; height: auto; }
  .hero { margin-block: 16px 27px; }
}
@media (max-width: 620px) {
  .top { min-height: 65px; }
  .brand { font-size: 1.52rem; }
  .top nav button { min-width: auto; }
  .hero { grid-template-columns: 1fr; gap: 14px; padding: 20px; margin-bottom: 25px; }
  .hero h1 { font-size: clamp(2.25rem, 10vw, 3.35rem); }
  .hero-art img { aspect-ratio: 1.8; }
  .styles { grid-auto-columns: minmax(121px, 43%); padding: 9px; gap: 9px; }
  .style-row .add { min-height: 34px; }
  .product-layout { grid-template-columns: 1fr; gap: 20px; }
  .product-detail { padding-top: 13px; }
  .product-styles { gap: 5px; }
  .product-style { grid-template-columns: 36px minmax(0, 1fr); font-size: .67rem; padding: 4px; }
  .product-style img { width: 36px; height: 36px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
.hero-actions{display:flex;flex-wrap:wrap;align-items:center;gap:10px 16px}
.hero-actions .action{display:inline-flex;align-items:center;gap:8px;min-height:44px;max-width:100%}
[data-theme="wedding"] #hero-collection{background:transparent;color:var(--rr-on-forest);border:1px solid var(--rr-gold)}
[data-theme="wedding"] #hero-collection:hover{background:var(--rr-forest-hover)}
[data-theme="wedding"] .hero-art img{object-position:65% 50%}
body:has([data-occasion="party"][aria-pressed="true"]) .journey-entry{display:none}

/* Selection drawer and checkout */
.top-actions { justify-self: end; display: flex; align-items: center; gap: 8px; }
.top .selection-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 6px 8px 6px 16px;
  border: 1px solid var(--rr-forest);
  border-radius: 999px;
  background: var(--rr-forest);
  color: var(--rr-on-forest);
  font-weight: 600;
  white-space: nowrap;
  transition: background-color 160ms ease;
}
.top .selection-button:hover { background: var(--rr-forest-hover); }
.selection-icon { display: none; flex: none; }
#selection-count {
  display: grid;
  place-items: center;
  min-width: 26px;
  height: 26px;
  padding-inline: 6px;
  border-radius: 999px;
  background: var(--rr-champagne);
  color: var(--rr-forest-deep);
  font-size: .8rem;
  font-variant-numeric: tabular-nums;
}
.step-kicker {
  margin-bottom: 6px;
  color: var(--rr-gold-ink);
  font-size: .72rem;
  font-weight: 650;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.selection-drawer {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(440px, 100%);
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-left: 1px solid var(--rr-gold);
  background: var(--rr-pearl);
  color: var(--ink);
  box-shadow: -24px 0 60px #192e2533;
  overscroll-behavior: contain;
}
.selection-drawer[open] { display: flex; flex-direction: column; animation: drawer-enter 260ms cubic-bezier(.2, .7, .2, 1) both; }
.selection-drawer::backdrop { background: color-mix(in srgb, var(--rr-forest-deep) 52%, transparent); }
@keyframes drawer-enter { from { transform: translateX(28px); opacity: 0; } to { transform: none; opacity: 1; } }
.drawer-head { display: flex; align-items: start; justify-content: space-between; gap: 12px; padding: 26px 26px 18px; border-bottom: 1px solid var(--rr-rule); }
.drawer-head h2 { font-size: 1.9rem; }
#cart-count { margin-top: 4px; color: var(--muted); font-size: .88rem; }
.drawer-close { flex: none; width: 44px; height: 44px; border: 1px solid var(--rr-rule); border-radius: 50%; background: transparent; font-size: 1.4rem; line-height: 1; }
.drawer-close:hover { background: var(--rr-linen); }
.drawer-added { margin: 14px 26px 0; padding: 10px 14px; border-left: 2px solid var(--rr-gold); background: var(--rr-sage); font-size: .9rem; }
#cart-items { flex: 1; overflow: auto; margin: 0; padding: 6px 26px; list-style: none; }
.cart-entry { display: grid; grid-template-columns: 72px minmax(0, 1fr) auto; gap: 14px; align-items: start; padding: 16px 0; border-bottom: 1px solid var(--rr-rule); }
.cart-entry img { width: 72px; height: 72px; border-radius: 3px; border: 1px solid var(--rr-rule); }
.cart-entry-details { display: grid; gap: 2px; min-width: 0; }
.cart-entry-details small { color: var(--rr-gold-ink); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; }
.cart-entry-details strong { font: 1.08rem/1.2 var(--display); overflow-wrap: anywhere; }
.cart-entry-unit { color: var(--muted); font-size: .82rem; }
.cart-entry-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin-top: 8px; }
.cart-entry-price { font: 1rem/1.3 var(--display); white-space: nowrap; }
.cart-entry .remove { min-height: 36px; padding: 0; border: 0; background: transparent; color: var(--muted); font-weight: 400; text-decoration: underline; text-underline-offset: 3px; }
.cart-entry .remove:hover { color: var(--wine); background: transparent; }
.drawer-empty { flex: 1; padding: 40px 26px; text-align: center; }
.drawer-empty > p:first-child { font: 1.3rem var(--display); margin-bottom: 6px; }
.drawer-foot { display: grid; gap: 10px; padding: 18px 26px calc(22px + env(safe-area-inset-bottom)); border-top: 1px solid var(--rr-rule); background: var(--rr-linen); }
.drawer-subtotal { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.drawer-subtotal strong { font: 1.35rem var(--display); }
.drawer-foot .action { display: flex; justify-content: center; gap: 8px; min-height: 50px; align-items: center; }
.drawer-foot .back-link { justify-self: center; min-height: 40px; }

.stepper { display: inline-flex; align-items: center; border: 1px solid var(--rr-rule); border-radius: 999px; background: var(--rr-pearl); }
.stepper button { width: 38px; height: 38px; padding: 0; border: 0; border-radius: 50%; background: transparent; font-size: 1.1rem; line-height: 1; color: var(--rr-forest); }
.stepper button:hover:not(:disabled) { background: var(--rr-linen); }
.stepper button:disabled { color: var(--rr-rule); cursor: default; }
.stepper input.quantity, .fields .stepper input.quantity:not([type="checkbox"], [type="radio"]) {
  width: 52px;
  min-height: 38px;
  padding: 0 2px;
  border: 0;
  background: transparent;
  text-align: center;
  font-variant-numeric: tabular-nums;
  -moz-appearance: textfield;
}
.stepper input.quantity::-webkit-inner-spin-button, .stepper input.quantity::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }

.product-purchase .quantity-field { display: grid; gap: 4px; }
.product-purchase .quantity-field label { margin: 0; font-size: .8rem; font-weight: 650; letter-spacing: .04em; }
.product-purchase .stepper { min-height: 48px; }
.product-purchase .stepper button { height: 46px; width: 42px; }
.product-quantity-note { margin-top: 6px; color: var(--muted); font-size: .84rem; }
.product-quantity-note:empty, .product-feedback:empty { display: none; }
#product-design { margin-top: 8px; min-height: 44px; font-weight: 600; }
.product-assurances, .checkout-assurances { list-style: none; margin: 16px 0 0; padding: 14px 0 0; border-top: 1px solid var(--rr-rule); display: grid; gap: 7px; color: var(--muted); font-size: .86rem; }
.product-assurances li, .checkout-assurances li { position: relative; padding-left: 20px; }
.product-assurances li::before, .checkout-assurances li::before { content: ""; position: absolute; left: 2px; top: .55em; width: 7px; height: 7px; border: 1px solid var(--rr-gold); transform: rotate(45deg); }
.checkout-assurances { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; padding-top: 10px; font-size: .82rem; }

.file-picker { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.fields .file-picker input.file-input { position: absolute; width: 1px; height: 1px; min-height: 0; padding: 0; overflow: hidden; clip-path: inset(50%); border: 0; opacity: 0; }
.file-button { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 16px; border: 1px solid var(--rr-forest); border-radius: 999px; color: var(--rr-forest); font-size: .88rem; font-weight: 600; cursor: pointer; }
.file-button:hover { background: var(--rr-linen); }
.fields .file-button { margin: 0; }
.file-picker:has(.file-input:focus-visible) .file-button { outline: 2px solid var(--wine); outline-offset: 3px; }
.file-picker:has(.file-input:invalid) .file-button { border-color: #9b3b2f; }
.file-name { min-width: 0; color: var(--muted); font-size: .85rem; overflow-wrap: anywhere; }

#quote:not([hidden]) { scroll-margin-top: 12px; }
.quote-form .submit { min-height: 52px; font-size: 1.02rem; }
.notice.confirmation { margin: 8px 0 0; padding: clamp(24px, 4vw, 48px); border: 1px solid var(--rr-gold); border-radius: 3px 3px 22px 3px; background: linear-gradient(135deg, var(--rr-forest), var(--rr-forest-deep)); color: var(--rr-on-forest); }
.confirmation .step-kicker { color: var(--rr-champagne); }
.confirmation h3 { font-size: clamp(1.7rem, 3.4vw, 2.6rem); max-width: 22ch; }
.confirmation-reference { margin-top: 10px; color: var(--rr-on-forest-muted); }
.confirmation-steps { display: grid; gap: 8px; max-width: 60ch; margin: 18px 0 22px; padding-left: 1.3rem; color: var(--rr-on-forest-muted); }
.notice.confirmation .action { display: inline-flex; margin: 0; color: var(--rr-forest-deep); background: var(--rr-champagne); }
.notice.confirmation .action:hover { background: var(--rr-pearl); }
.confirmation :focus-visible { outline-color: var(--rr-champagne); }

@media (max-width: 620px) {
  .top-actions { gap: 5px; }
  .top .selection-button { min-height: 36px; padding: 4px 5px 4px 10px; gap: 5px; font-size: .79rem; }
  #selection-count { min-width: 22px; height: 22px; font-size: .72rem; }
  .selection-drawer { width: 100%; border-left: 0; }
  .drawer-head, .drawer-foot { padding-inline: 18px; }
  .drawer-head { padding-top: 18px; }
  #cart-items { padding-inline: 18px; }
  .drawer-added { margin-inline: 18px; }
  .cart-entry { grid-template-columns: 60px minmax(0, 1fr) auto; gap: 10px; }
  .cart-entry img { width: 60px; height: 60px; }
  .design-card { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .design-visual { display: grid; grid-template-columns: 64px minmax(0, 1fr); align-items: center; gap: 4px 12px; }
  .design-visual img { width: 64px; }
  .design-visual .hint:first-of-type { margin: 0; }
  .design-visual > :is(h4, .personalization-preview, .hint:last-child) { grid-column: 1 / -1; }
  .design-visual h4 { margin-top: 6px; }
}
@media (max-width: 620px) {
  .top .selection-label { display: none; }
  .selection-icon { display: block; }
  .top .selection-button { padding-left: 8px; }
}
@media (max-width: 480px) {
  .top-actions { grid-area: 1 / 2; }
}
