/* Product controls inherit the store typography and theme tokens. */
#productSizes { margin: 24px 0; }
.size-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; margin:0 0 12px; }
.size-selection-status { color:var(--muted-fg); font-family:var(--ui); font-size:11px; }
:is(#sizeRow,#facetSizeRow) { display:flex; flex-wrap:wrap; gap:10px; }
:is(#sizeRow,#facetSizeRow) .size {
  position:relative; display:grid; place-items:center; flex:0 1 auto;
  min-width:64px; min-height:56px; height:auto; padding:15px 18px;
  border:2px solid var(--hard); border-radius:var(--r);
  background:var(--bg); color:var(--fg); font-family:var(--ui);
  font-size:16px; font-weight:600; line-height:1.2; letter-spacing:-.04em;
  transition:background-color 160ms ease, color 160ms ease, border-color 160ms ease;
}
:is(#sizeRow,#facetSizeRow) .size[aria-pressed=true] { background:var(--fg); color:var(--bg); }
:is(#sizeRow,#facetSizeRow) .size:disabled { border-color:var(--line); background:var(--muted); color:var(--muted-fg); text-decoration:line-through; text-decoration-thickness:1px; cursor:not-allowed; }
:is(#sizeRow,#facetSizeRow) .size:focus-visible { outline:2px solid var(--fg); outline-offset:4px; }
:is(#sizeRow,#facetSizeRow) .size:active { transform:none; }
@media (hover:hover) { :is(#sizeRow,#facetSizeRow) .size:not(:disabled):not([aria-pressed=true]):hover { background:var(--muted); } }
@media (prefers-reduced-motion:reduce) { :is(#sizeRow,#facetSizeRow) .size { transition:none; } }
/* Compact retail controls, using the same rounded monochrome vocabulary. */
#s-product .title { font-family:var(--display); font-size:clamp(25px,6.8vw,32px); font-weight:800; line-height:1.15; letter-spacing:-.055em; margin:24px 0 12px; }
#s-product .pricebig { font-family:var(--display); font-size:26px; font-weight:700; letter-spacing:-.035em; }
#productPricing > .desc { font-size:12px; margin:6px 0 0; color:var(--muted-fg); }
.size-heading .mono { font-family:var(--ui); font-size:13px; font-weight:600; letter-spacing:0; text-transform:none; color:var(--fg); }
:is(#sizeRow,#facetSizeRow) { gap:8px; }
:is(#sizeRow,#facetSizeRow) .size { min-width:62px; min-height:54px; padding:14px 19px; border:1.5px solid var(--hard); border-radius:16px; font-size:17px; letter-spacing:-.035em; }
:is(#sizeRow,#facetSizeRow) .size[aria-pressed=true] { box-shadow:0 3px 0 var(--line); }
:is(#sizeRow,#facetSizeRow) .size:disabled { border-color:var(--line); }
#s-product .iconbtn { border-width:1.5px; }
.actionbar.product-actionbar button { height:58px; padding:0 24px; border-radius:999px; font-family:var(--ui); font-size:16px; font-weight:700; letter-spacing:-.025em; }
.actionbar.product-actionbar .amt { font-size:14px; padding-left:18px; margin-left:16px; border-left:1px solid color-mix(in srgb,var(--bg) 30%,transparent); font-variant-numeric:tabular-nums; }
.product-details { border-top:1px solid var(--line); border-bottom:1px solid var(--line); margin:24px 0; }
.product-details > summary { cursor:pointer; padding:18px 0; min-height:52px; font-family:var(--ui); font-size:14px; font-weight:600; }
.product-details .product-material { margin:0 0 18px; }
.product-details .product-measurements { margin-top:0; }

#s-product > .product-measurements { margin-top:24px; border-top:1px solid var(--line); }
#s-product > .product-measurements > summary { padding-top:18px; }
#s-product > .product-measurements > summary .mono { font-family:var(--ui); font-size:15px; font-weight:700; letter-spacing:-.025em; text-transform:none; }
@media (prefers-reduced-motion:reduce) { .actionbar, .actionbar.on { transition:none; } }

#s-product .backbar:has(.product-wordmark) { display:grid; grid-template-columns:44px minmax(0,1fr) auto; align-items:center; gap:8px; }
.product-wordmark { justify-self:center; font-family:var(--display); font-size:clamp(12px,3.5vw,17px); font-weight:800; letter-spacing:-.065em; line-height:1.2; white-space:nowrap; }
.size-selection-status.visually-hidden { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; border:0; }
.product-measurements .measurement-notes { margin-top:20px; }
.product-measurements .measurement-notes > .desc { margin:0; }
.product-measurements .measurement-notes > .desc + .desc { margin-top:12px; }

.product-wordmark { font-family:var(--display); font-weight:800; letter-spacing:-.04em; }
#s-product .gallery { margin-left:0; margin-right:0; padding-left:0; padding-right:0; gap:12px; scroll-padding-inline:0; }
#s-product .gallery > .media-frame, #s-product .gallery > img { flex:0 0 100%; min-width:0; scroll-snap-align:center; }
#s-product .gallery > .media-frame > img { width:100%; }

#s-product { position:relative; }
#s-product > .product-wordmark { position:absolute; top:42px; left:50%; transform:translate(-50%,-50%); z-index:11; pointer-events:none; }
#s-product { --gallery-gutter:20px; }
#s-product .gallery { margin-inline:calc(-1 * var(--gallery-gutter)); padding-inline:var(--gallery-gutter); scroll-padding-inline:var(--gallery-gutter); background:transparent; }
@media (max-width:360px) { #s-product { --gallery-gutter:16px; } }
#s-product .gallery > .media-frame, #s-product .gallery > img { border-radius:var(--r); }
#s-product .gallery > .media-frame > img { border-radius:inherit; }

#s-product .gallery > .media-frame, #s-product .gallery > img { transform-origin:center; }
#s-product .gallery-dot { transition:width 180ms ease, background-color 180ms ease; }
@media (prefers-reduced-motion:reduce) { #s-product .gallery-dot { transition:none; } }

#s-product > .product-measurements, #s-product > .product-details { border-top:1px solid var(--line); border-bottom:0; }
#s-product > :is(.product-measurements,.product-details) > summary { display:flex; align-items:center; justify-content:space-between; gap:12px; min-height:58px; padding:18px 0; list-style:none; }
#s-product > :is(.product-measurements,.product-details) > summary::-webkit-details-marker { display:none; }
#s-product > :is(.product-measurements,.product-details) > summary .mono { font-family:var(--ui); font-size:15px; font-weight:700; letter-spacing:-.025em; text-transform:none; }
#s-product > .product-details > summary svg { width:18px; height:18px; stroke:currentColor; fill:none; stroke-width:1.8; flex-shrink:0; transition:transform var(--fast); }
#s-product > .product-details[open] > summary svg { transform:rotate(180deg); }

:is(#sizeRow,#facetSizeRow) { flex-wrap:nowrap; overflow-x:auto; gap:12px; scroll-snap-type:x mandatory; scrollbar-width:none; padding:6px 0 6px; scroll-behavior:smooth; }
:is(#sizeRow,#facetSizeRow)::-webkit-scrollbar { display:none; }
:is(#sizeRow,#facetSizeRow) .size-page { flex:0 0 100%; display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; scroll-snap-align:start; scroll-snap-stop:always; }
:is(#sizeRow,#facetSizeRow) .size { min-width:0; width:100%; padding-inline:8px; overflow-wrap:anywhere; }
.size-pagination { display:flex; gap:2px; margin:-10px -8px -10px 0; }
.size-pagination button { display:grid; place-items:center; width:44px; height:44px; border:0; border-radius:50%; background:transparent; color:var(--fg); }
.size-pagination button:disabled { opacity:.25; }
.size-pagination button:focus-visible { outline:2px solid var(--fg); outline-offset:-4px; }
.size-pagination svg { width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
@media (hover:hover) { .size-pagination button:not(:disabled):hover { background:var(--muted); } }
@media (prefers-reduced-motion:reduce) { :is(#sizeRow,#facetSizeRow) { scroll-behavior:auto; } }

/* A quieter category list with the shop's monochrome controls. */
.head.small { border-bottom-color:transparent; }
.ticker { display:block; }
#chips { display:none; }
.category-menu { padding:22px 20px 20px; border-radius:24px; }
.category-menu h2 { font-size:22px; }
.category-menu-head { align-items:center; margin-bottom:18px; }
.category-menu-close { width:44px; height:44px; margin:0; border:1.5px solid var(--hard); border-radius:50%; }
.category-menu-grid { grid-template-columns:minmax(0,1fr); gap:6px; }
.category-menu-tile { flex-direction:row; align-items:center; justify-content:flex-start; min-height:56px; padding:14px 44px 14px 16px; gap:14px; border-radius:14px; }
.category-menu-tile strong { flex:1; min-width:0; font-size:14px; }
.category-menu-quantity { flex:none; font-size:11px; font-variant-numeric:tabular-nums; }
.category-menu-check { top:50%; right:14px; transform:translateY(-50%); width:18px; height:18px; }
.category-menu-footer { padding-top:18px; }
.category-menu-footer > div { margin-bottom:12px; }
.category-menu-apply { min-height:54px; border-radius:999px; font-family:var(--ui); font-size:15px; font-weight:700; }
.category-menu[open] { animation:category-reveal 200ms cubic-bezier(.2,.8,.3,1); }
@keyframes category-reveal { from { opacity:0; transform:translateY(12px); } to { opacity:1; transform:translateY(0); } }
@media(prefers-reduced-motion:reduce) { .category-menu[open] { animation:none; } }

/* Ralph Store monogram and solid navigation symbols. */
.nav { border-top:1px solid var(--line); }
.nav button[aria-current="page"]::before { content:none; }
.nav button { gap:5px; }
.nav .ico { width:28px; height:28px; }
.nav svg { width:25px; height:25px; fill:currentColor; stroke:none; }
.nav .lbl { font-family:var(--ui); font-size:10px; font-weight:600; }
.nav .ico .dot { top:-4px; right:-8px; border:2px solid var(--bg); min-width:16px; height:16px; padding:0 3px; line-height:12px; font-size:9px; }
.nav button:focus-visible { outline:2px solid var(--fg); outline-offset:-5px; border-radius:12px; }

.nav .ico { width:30px; height:30px; }
.nav .nav-image { display:block; width:30px; height:30px; object-fit:contain; opacity:.54; }
.nav button[aria-current="page"] .nav-image { opacity:1; }
html.dark .nav .nav-image { filter:invert(1); }

#s-catalog > .facetbar { margin-top:16px; }

.favorite-image { display:block; width:24px; height:24px; object-fit:contain; opacity:1; }
.heart .favorite-image { width:22px; height:22px; }
html.dark .favorite-image, :is(.heart,#favBtn)[aria-pressed="true"] .favorite-image { filter:invert(1); }
:is(.heart,#favBtn)[aria-pressed="true"] .favorite-image { opacity:1; }
html.dark :is(.heart,#favBtn)[aria-pressed="true"] .favorite-image { filter:none; }

/* Capsule actions and a clear selected payment method. */
.btn, .actionbar button { border-radius:999px; }
.actionbar button { height:58px; padding-inline:24px; font-family:var(--ui); font-size:16px; font-weight:700; }
.actionbar .amt { font-size:14px; }
.pay > button { min-height:58px; padding:16px 52px 16px 22px; border-radius:999px; }
.pay > button .t { font-size:14px; font-weight:700; }
.pay > button[aria-pressed="true"] { background:var(--fg); color:var(--bg); border-color:var(--fg); }
.pay > button[aria-pressed="true"]::after { border-color:var(--bg); background:var(--fg); }
.pay > .pay-coming-soon { justify-content:space-between; padding-right:22px; background:var(--muted); border-color:var(--line); color:var(--muted-fg); cursor:default; }
.pay > .pay-coming-soon:active { transform:none; }
.pay-soon-label { font-size:11px; font-weight:500; }
html.dark { --profile-hero-bg:#FFFFFF; }
html.dark #s-profile .profile-hero { color:#0A0A0A; }

#s-fav .card { animation:none; }

#s-cart .pay > button { border-radius:999px; }
#s-cart .box .chip { border-radius:999px; }
body:has(#s-cart.on) #actionbar { background:transparent; border-top-color:transparent; box-shadow:none; pointer-events:none; }
body:has(#s-cart.on) #actionbar button { pointer-events:auto; border-radius:999px; }

#s-profile .profile-order-open,
#s-profile .profile-catalog-button,
#s-profile .profile-help-actions button,
#s-profile .profile-guest-entry .profile-catalog-button,
#s-profile .profile-guest-entry .profile-telegram-entry { border-radius:999px; box-shadow:none; }
#s-profile .profile-order-open { min-height:50px; padding:13px 20px; }

#s-profile .profile-tabs { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:0; }
#s-profile .profile-tab { width:100%; text-align:center; justify-content:center; }

/* Full-width checkout target, with separate legal links below it. */
#s-cart .cart-checkout-footer {
  --checkout-gutter:20px;
  margin:28px calc(-1 * var(--checkout-gutter)) -28px;
  padding:0 0 36px;
  border-radius:0;
  background:#0a0a0a;
  color:#fff;
}
#s-cart #actionbar, #s-cart #actionbar.on {
  position:static; width:100%; transform:none; margin:0; padding:0;
  background:transparent; border:0; box-shadow:none; transition:none;
}
#s-cart #actionbar button {
  width:100%;
  min-height:136px;
  padding:16px var(--checkout-gutter);
  border-radius:0;
  background:transparent;
  color:#fff;
  box-shadow:none;
}
#s-cart #actionbar button:focus-visible { outline:2px solid #fff; outline-offset:-4px; }
#s-cart .cart-checkout-footer .cart-legal {
  margin:0;
  padding:0 var(--checkout-gutter);
  color:#fff;
}
#s-cart .cart-checkout-footer a { color:#fff; }
@media (max-width:360px) {
  #s-cart .cart-checkout-footer { --checkout-gutter:16px; }
}

/* Online payment keeps the original QR image on a plain white field. */
.online-payment { display:grid; gap:22px; margin:16px 0 24px; }
.online-payment-total { display:grid; gap:4px; margin:0; }
.online-payment-total span, .online-payment-qr figcaption { color:var(--muted-fg); font-size:13px; }
.online-payment-total strong { font-size:clamp(30px,9vw,42px); line-height:1.1; font-variant-numeric:tabular-nums; }
.online-payment-qr { margin:0; display:grid; justify-items:center; gap:10px; }
.online-payment-qr > div { box-sizing:border-box; width:min(100%,264px); padding:20px; border-radius:16px; background:#fff; border:1px solid var(--line); }
.online-payment-qr img { width:100%; height:auto; }
.online-payment-actions { display:grid; gap:8px; }
.online-payment-actions button { min-height:52px; padding:12px 18px; border:1px solid var(--line); border-radius:999px; font-weight:700; }
.online-payment-actions .online-payment-primary { background:var(--fg); color:var(--bg); border-color:var(--fg); }
.online-payment .wait { justify-content:center; margin:0; text-align:center; }

/* Unbounded has wider letters than the previous body font. */
.nav .lbl { max-width:100%; padding-inline:2px; overflow-wrap:anywhere; }
#s-profile .profile-tab { font-size:clamp(11px,3.5vw,14px); }
#s-cart .cart-summary .sum > span { min-width:0; overflow-wrap:anywhere; }

#s-cart .cart-removal { position:relative; overflow:hidden; }
#s-cart .cart-removal > .row { position:relative; background:var(--bg); }
#s-cart .cart-removal-trail {
  position:absolute;
  inset:50% 0 auto;
  height:4px;
  background:#0a0a0a;
  transform:scaleX(0);
  transform-origin:left center;
}
html.dark #s-cart .cart-removal-trail { background:#fff; }

/* Let the product photo scroll through the web inset under the native controls. */
body:has(#s-product.on)::after { background:transparent; }
#s-product .gallery { position:relative; }
@media (prefers-reduced-motion:reduce) {
  .screen.on { animation:none; }
}

.sheet.closing > .panel { animation:sheet-exit 190ms cubic-bezier(.4,0,1,1) both; }
.sheet.closing > .scrim { animation:sheet-scrim-exit 190ms ease-out both; }
.sheet.closing :is(.panel,.scrim) { pointer-events:none; }
@keyframes sheet-exit { to { transform:translateY(100%); } }
@keyframes sheet-scrim-exit { to { opacity:0; } }
@media (prefers-reduced-motion:reduce) { .sheet .panel { animation:none; } }

.sheet .panel:has(.brand-picker) { display:flex; flex-direction:column; overflow:hidden; }
.brand-picker { display:flex; flex-direction:column; min-height:0; height: min(550px,67dvh); }
.brand-picker .grip { flex-shrink:0; }
.brand-picker-head { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:8px; }
.brand-picker-head h3 { margin:0; }
.brand-picker-close { width:44px; height:44px; flex:none; border:1px solid var(--line); border-radius:50%; font:400 24px/1 system-ui; }
#brandSearch { width:100%; min-height:46px; flex:none; padding:0 15px; border:1px solid var(--line); border-radius:999px; background:var(--muted); font-size:16px; }
.brand-picker-list { flex:1 1 auto; min-height:0; overflow-y:auto; overscroll-behavior:contain; margin-top:12px; }
.brand-picker-list h4 { position:sticky; top:0; z-index:1; margin:0; padding:8px 10px; background:var(--muted); font-size:12px; }
.brand-picker-row { display:grid; grid-template-columns:20px minmax(0,1fr) auto; align-items:center; gap:11px; min-height:48px; padding:8px 10px; border-bottom:1px solid var(--line); font-size:13px; cursor:pointer; }
.brand-picker-row input { width:18px; height:18px; margin:0; accent-color:var(--fg); }
.brand-picker-row span { overflow-wrap:anywhere; }
.brand-picker-count,.brand-picker-empty { color:var(--muted-fg); }
.brand-picker-count { font-size:11px; font-variant-numeric:tabular-nums; }
.brand-picker-empty { padding:12px 10px; font-size:13px; }
.brand-picker-actions { margin-top:12px; flex:none; }
.brand-picker-actions button { padding-inline:8px; font-size:12px; }
.brand-picker-actions button:disabled { opacity:.45; }

#s-catalog > .head { position:sticky; top:var(--store-safe-top); transition:none; }
.toolbar .toolbar-icon { width:20px; height:20px; object-fit:contain; }
.toolbar button { display:flex; align-items:center; justify-content:center; gap:2px; }
.dark .toolbar-icon, .toolbar button.on .toolbar-icon { filter:invert(1); }
.dark .toolbar button.on .toolbar-icon { filter:none; }
.toolbar button:has(.dot:not([hidden])) .toolbar-icon { width:16px; height:16px; }
.size-tabs button[aria-pressed=true] { background:var(--fg); color:var(--bg); }
.facet-size-heading { justify-content:space-between; margin:12px 0 6px; }
.facet-size-heading[hidden] { display:none; }
#facetSizeRow .size:active { transform:scale(.96); }
.product-stock-status { display:inline-block; margin:10px 0 0; padding:9px 12px; border-radius:999px; background:var(--muted); color:var(--fg); font-size:12px; font-weight:700; }

/* Keep the header's flow box stable: scrolling never relayouts the catalog. */
#s-catalog { overflow-anchor:none; }
#s-catalog > .head {
  clip-path:inset(0); contain:paint; will-change:clip-path;
  transition:clip-path 240ms cubic-bezier(.22,1,.36,1);
}
#s-catalog > .head.small { clip-path:inset(0 0 58px); }
#s-catalog > .head::after {
  content:""; position:absolute; left:0; right:0; bottom:58px; height:2px;
  background:var(--hard); opacity:0; pointer-events:none; transition:opacity 160ms ease;
}
#s-catalog > .head.small::after { opacity:1; }
#s-catalog .brand {
  transform-origin:left center; will-change:transform;
  transition:transform 240ms cubic-bezier(.22,1,.36,1);
}
#s-catalog .head.small .brand { transform:scale(var(--catalog-compact-brand-scale,.7142857)); }
#s-catalog .searchwrap {
  transition:opacity 180ms ease,transform 240ms cubic-bezier(.22,1,.36,1),visibility 0s;
}
#s-catalog .head.small .searchwrap { transition-delay:0s,0s,240ms; }
@media (prefers-reduced-motion:reduce) {
  #s-catalog > .head,#s-catalog .brand,#s-catalog .searchwrap,#s-catalog > .head::after { transition:none; }
}
