:root {
  --studio-ink:#193f40; --studio-teal:#245e59; --studio-line:#cebfaa;
  --studio-wall:url("./studio-paper-desk-v1.webp");
  --studio-surface:linear-gradient(114deg,rgba(255,251,232,.64),rgba(255,247,233,.73) 47%,rgba(255,243,229,.59));
  --studio-frost:linear-gradient(120deg,rgba(255,253,241,.66),rgba(249,239,222,.53));
  --studio-edge:inset 0 1px 0 #fffffff0,inset 0 0 0 1px #fff9e563,0 8px 26px #183a3038;
}
body.store-page,body.constructor-page {
  background:#91a294 var(--studio-wall) center / cover fixed no-repeat;
}
/* Raised side panels overlap the shallower navigation band. */
body .top {
  --side:max(clamp(16px,3vw,48px),calc((100% - 1370px)/2));
  --brand-space:clamp(154px,15vw,218px);
  --search-space:clamp(162px,15vw,214px);
  --cart-space:130px;
  --gap:clamp(10px,1vw,17px);
  --panel-inset:15px;
  --left-wing:calc(var(--side) + var(--brand-space) + var(--gap));
  --right-wing:calc(var(--side) + var(--search-space) + var(--cart-space) + var(--gap) + var(--panel-inset) + 3px);
  position:sticky;top:0;z-index:12;isolation:isolate;
  display:grid;grid-template-columns:var(--brand-space) minmax(0,1fr) var(--search-space) var(--cart-space);
  align-items:center;gap:0 var(--gap);min-height:62px;padding:7px var(--side);
  color:var(--studio-ink);background:transparent;border:0;box-shadow:none;
}
.header-paper {
  position:absolute;inset:0;z-index:-1;pointer-events:none;overflow-x:clip;clip-path:inset(0 0 -7px);
}
.header-paper i {display:block;position:absolute;top:0;}
.header-paper i:first-child {
  inset-inline:0;height:75%;background:linear-gradient(180deg,#fff8eb,#f0e2cc);
  border-bottom:1px solid #c8b699;box-shadow:0 2px 3px #46332024;box-sizing:border-box;
}
.header-paper i:nth-child(2),.header-paper i:nth-child(3) {height:100%;filter:drop-shadow(0 2px 2px #50391f42);}
.header-paper i:nth-child(2) {left:0;width:var(--left-wing);--slant:calc(-1 * var(--panel-angle));}
.header-paper i:nth-child(3) {right:0;width:var(--right-wing);--slant:var(--panel-angle);}
.header-paper i:nth-child(n+2)::before {
  content:"";position:absolute;inset:0;box-sizing:border-box;transform-origin:50% 0;transform:skewX(var(--slant));
  background:linear-gradient(168deg,#fff8e9,#f6ead5);border:1px solid #cbb99d;border-top:0;
  box-shadow:inset 0 -1px #fffaee;
}
.header-paper i:nth-child(2)::before {border-left:0;border-bottom-right-radius:3px;}
.header-paper i:nth-child(3)::before {border-right:0;border-bottom-left-radius:3px;}
@media(min-width:861px) {
  body .top {--panel-angle:17deg;min-height:64px;grid-template-rows:minmax(64px,auto);padding-block:0;}
  .top nav {height:75%;align-self:start;align-items:center;}
}
@media(min-width:861px) and (max-width:1090px) {
  body .top {--panel-angle:10deg;}
}
.top,#grid :is(.quick-cart,.name,.card-photo),#detail[data-view=product] {-webkit-tap-highlight-color:transparent;}
.top :is(a,button):focus-visible {outline:2px solid #30695d;outline-offset:1px;}
.top .brand:active,.top nav a:active {color:#18584d;background-color:#e4ecdf;border-radius:8px;}
.top .brand {grid-column:1;grid-row:1;justify-self:start;display:flex;align-items:center;gap:9px;margin:0;color:#204940;}
.top .brand img {display:block;width:40px;height:40px;object-fit:contain;}
.top .nav-toggle:focus-visible {outline:2px solid #33766a;outline-offset:1px;}
.top .brand strong {display:block;font-size:17px;font-weight:720;letter-spacing:.055em;line-height:1.15;}
.top .brand small {margin-top:2px;color:#625b4b;font-size:10px;line-height:1.12;}
.top nav {--link-gap:clamp(14px,1.6vw,26px);grid-row:1;grid-column:2;justify-self:center;gap:var(--link-gap);}
@media(min-width:861px) {
  .top nav a {position:relative;display:inline-flex;align-items:center;min-height:36px;}
  .top nav a+a::before {
    content:"";position:absolute;pointer-events:none;left:calc(var(--link-gap) * -.5);top:50%;
    width:1px;height:15px;transform:translateY(-50%);background:linear-gradient(transparent,#bfac91 23% 77%,transparent);
  }
}
.top nav a {color:#354c42;font-size:clamp(12px,.96vw,14px);line-height:1.25;font-weight:600;white-space:nowrap;}
.top-search,.top .catalog-cart {
  box-sizing:border-box;align-items:center;height:38px;min-width:0;margin:0;border:1px solid #baab918c;
  border-radius:12px;box-shadow:inset 0 1px #fffaf0a6;
}
.top-search {grid-column:3;grid-row:1;display:flex;width:100%;padding:0 9px 0 1px;background:#fff9edc9;}
.top-search:focus-within {outline:2px solid #37746a;outline-offset:1px;}
.top-search button {flex:none;display:grid;place-items:center;width:34px;height:100%;padding:0;color:#456153;background:transparent;border:0;border-radius:10px;}
.top-search svg {width:17px;height:17px;}
.top .top-search input {width:100%;min-width:0;margin:0;padding:4px 0;border:0;outline:0;background:transparent;color:var(--studio-ink);font:inherit;font-size:13px;}
.top .top-search input::placeholder {color:#696e60;}
.top .catalog-cart {
  grid-column:4;grid-row:1;display:inline-flex;justify-content:center;gap:6px;padding:0 8px;
  background:linear-gradient(130deg,#fff8e9dc,#ecdfc9bc);color:#205247;font:inherit;font-size:13px;font-weight:650;white-space:nowrap;text-decoration:none;
}
.top .catalog-cart:hover,.top .catalog-cart:focus-visible {border-color:#819b85;background:#f8efd9;}
.top .header-cart-icon {flex:none;width:18px;height:18px;}
.top .catalog-cart #cartCount {display:grid;place-items:center;min-width:20px;height:20px;padding:0 4px;margin:0;border-radius:999px;background:#2b6257;color:white;font-size:11px;font-weight:700;line-height:1;}
@media(min-width:861px) and (max-width:1090px) {
  body .top {--panel-inset:9px;--side:14px;--brand-space:132px;--search-space:134px;--cart-space:118px;--gap:9px;}
  .top .brand {gap:5px;}
  .top .brand img {width:31px;height:33px;}
  .top .brand strong {font-size:14px;}
  .top .brand small {font-size:9px;}
  .top .top-search {padding-right:4px;}
  .top .top-search button {width:27px;}
  .top .top-search input {font-size:12px;}
  .top-search input:placeholder-shown::-webkit-search-cancel-button {display:none;}
  .top nav {--link-gap:12px;}
  .top nav a {font-size:12px;}
  .top .catalog-cart {gap:4px;padding-inline:5px;}
}
.top .cart-title {font:inherit;}
@media(min-width:861px) and (max-width:970px) {
  body .top {--search-space:122px;--cart-space:58px;}
  .top .cart-title {position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap;}
}
@media(max-width:860px) {
  :root {--header-safe:env(safe-area-inset-top,0px);--mobile-header-height:calc(94px + var(--header-safe));}
  body.store-page:has(> .top.has-menu),body.constructor-page {padding-block-start:var(--mobile-header-height);box-sizing:border-box;}
  body .top,body.store-page .top.has-menu,body.constructor-page .top {
    --side:clamp(10px,3vw,19px);--brand-space:43px;--catalog-space:110px;--cart-space:130px;--menu-space:44px;
    display:grid;grid-template-columns:var(--brand-space) var(--catalog-space) minmax(4px,1fr) var(--menu-space) var(--cart-space);
    grid-template-rows:44px 34px;gap:5px 0;align-content:start;min-height:0;
    padding:calc(4px + var(--header-safe)) var(--side) 6px;box-sizing:border-box;
    background:#fbf4e8;border:0;border-bottom:1px solid #cfc2ae;box-shadow:0 2px 5px #44382b18;
  }
  body .top.has-menu,body.constructor-page .top {position:fixed;inset:0 0 auto;height:var(--mobile-header-height);}
  .top .header-paper {
    display:block;top:var(--header-safe);height:48px;--panel-angle:9deg;
    --left-wing:calc(var(--side) + var(--brand-space));
    --right-wing:calc(var(--side) + var(--menu-space) + var(--cart-space) + 9px);
  }
  /* The middle paper is the catalog link's visible surface. */
  .top .header-paper i:first-child {
    background:linear-gradient(180deg,#ffffff0a,transparent 65%),#226859;border-bottom-color:#184d42;
  }
  .top:has(> .header-catalog:active) .header-paper i:first-child {background:#194e45;}
  .top .header-paper i:nth-child(n+2) {filter:drop-shadow(0 1px 1px #50391f33);}
  .top .brand,.top.has-menu .brand {margin:0;justify-self:start;gap:6px;border-radius:8px;}
  .top .brand img,.top.has-menu .brand img,.constructor-page .top .brand img {width:32px;height:36px;}
  .top .brand > span {display:none;}
  .top > .header-catalog {
    grid-column:2/4;grid-row:1;justify-self:stretch;align-self:start;position:relative;top:-4px;
    display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;
    min-height:44px;margin:0;padding:0 9px 8px 0;font-size:13px;font-weight:650;line-height:1.15;
    color:#fffaf0;border:0;border-radius:0;background:transparent;box-shadow:none;animation:none;
  }
  .top > .header-catalog:is(:hover,:focus-visible,:active) {background:transparent;}
  .top > .header-catalog:focus-visible {outline:0;text-decoration:underline;text-underline-offset:3px;}
  .top.has-menu .nav-toggle,.top .catalog-cart,.top.has-menu .catalog-cart {
    position:relative;top:-2px;box-sizing:border-box;width:100%;height:44px;margin:0;
    color:#26564a;background:transparent;border:0;border-radius:0;box-shadow:none;
  }
  .top.has-menu .nav-toggle {grid-column:4;grid-row:1;display:grid;place-items:center;padding:0;}
  .top.has-menu .nav-toggle::before {content:"";position:absolute;right:0;top:13px;bottom:13px;width:1px;background:#c7b69a;}
  .top .catalog-cart,.top.has-menu .catalog-cart {grid-column:5;grid-row:1;font-size:13px;gap:6px;padding:0 6px;}
  .top.has-menu .nav-toggle:is(:hover,:focus-visible,:active,[aria-expanded=true]),.top .catalog-cart:is(:hover,:focus-visible,:active) {background:transparent;color:#174e42;}
  .top :is(.catalog-cart,.nav-toggle):focus-visible {outline-offset:-4px;}
  .top.has-menu #shopNav {right:var(--side);top:calc(100% + 4px);max-height:calc(100dvh - var(--mobile-header-height) - 12px);z-index:5;justify-self:auto;background:#fff9ee;border-color:#cebea5;}
  .top .top-search {
    grid-column:1/-1;grid-row:2;order:initial;width:100%;height:34px;border-radius:11px;background:#fffaf1;border:1px solid #cebfaa;
    box-shadow:inset 0 1px 2px #614b2b0b;
  }
  .top .top-search input {padding:2px 0;font-size:16px;}
  .top-search button {width:34px;}
  .store-page .top:not(.has-menu) #shopNav {grid-column:1/-1;grid-row:3;display:flex;flex-wrap:wrap;justify-content:center;}
}
@media(min-width:580px) and (max-width:860px) {
  body .top,body.store-page .top.has-menu,body.constructor-page .top {--brand-space:170px;}
  .top .brand > span {display:block;}
}
@media(max-width:359px) {
  .top .header-paper {--panel-angle:5deg;--right-wing:calc(var(--side) + var(--menu-space) + var(--cart-space) + 4px);}
  body .top,body.store-page .top.has-menu,body.constructor-page .top {--side:8px;--brand-space:39px;--catalog-space:100px;--cart-space:114px;}
  body .top > .header-catalog,body.store-page .top > .header-catalog {font-size:12px;padding-inline:0 4px;}
  .top .brand img,.top.has-menu .brand img,.constructor-page .top .brand img {width:31px;}
  .top .header-cart-icon {width:15px;height:15px;}
  .top .catalog-cart,.top.has-menu .catalog-cart {gap:4px;font-size:12px;}
}
@media(max-width:860px) and (prefers-reduced-motion:no-preference) {
  .top:not(:has(> .header-catalog:active)) .header-paper i:first-child {animation:catalog-ink 3.4s ease-in-out infinite;}
  @keyframes catalog-ink {0%,100% {background-color:#226859;}50% {background-color:#267966;}}
}
#catalogPage { max-width:1370px; margin:clamp(26px,2.4vw,36px) auto; width:calc(100% - clamp(28px,7vw,125px)); backdrop-filter:blur(9px) saturate(.91); -webkit-backdrop-filter:blur(9px) saturate(.91); background:var(--studio-surface); border:1px solid #fff8e9; border-radius:24px; box-shadow:var(--studio-edge); }
#catalogPage :is(.intro,.catalog) { box-sizing:border-box;width:100%;min-width:0;margin-inline:0;max-width:none; background:none; box-shadow:none; border:0; padding-inline:clamp(12px,2.1vw,30px); }
#catalogPage .intro { padding-top:clamp(15px,2vw,27px); padding-bottom:12px; }
#catalogPage .intro h1,#detail :is(h2,h3,h4),.co-summary dt,.co-summary dd { color:var(--studio-ink); }
#catalogPage .catalog { padding-bottom:24px; }
#catalogPage .tools { display:block; padding:0;background:transparent;border:0; }
#catalogPage .category-field>span {position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);}
#catalogPage .category-picker { width:100%; max-width:900px; margin-inline:auto; background:#f6efe3a6;border:1px solid #d6cbb6;border-radius:999px;padding:3px; }
.category-track button {border-radius:999px;padding-inline:19px;position:relative;}
.category-track button[aria-checked=true] {color:#fffaf0;background:linear-gradient(#42796f,#285b55);border-color:#37645d;box-shadow:inset 0 1px #ffffff38;}
.category-track button[aria-checked=true]::before,.category-track button[aria-checked=true]::after {
  content:"";position:absolute;top:50%;width:4px;height:4px;border:solid currentColor;border-width:1px 1px 0 0;opacity:.9;
}
.category-track button[aria-checked=true]::before {left:7px;transform:translateY(-50%) rotate(45deg);}
.category-track button[aria-checked=true]::after {right:7px;transform:translateY(-50%) rotate(-135deg);}
#grid {gap:clamp(10px,1.8vw,25px);}
#grid .card {display:flex;flex-direction:column;align-items:stretch;padding:clamp(5px,.8vw,12px);border:1px solid #fffae8a6;border-radius:17px;background:linear-gradient(155deg,#fffaf06b,#f3e7d239);box-shadow:inset 0 1px #fff9ee69,0 2px 6px #48372911;}
#grid .name {display:grid;place-content:center;width:100%;min-height:2.55em;margin:0 0 7px;text-align:center;color:#193e3e;font-weight:650;font-size:clamp(13px,1.12vw,18px);line-height:1.24;}
#grid .card-media {isolation:isolate;border-radius:12px;overflow:hidden;}
#grid .card-photo {border-radius:inherit;}
#grid .price {text-align:center;margin:6px 0 0;padding:0;line-height:1.25;color:var(--studio-ink);font-size:clamp(17px,1.5vw,24px);}
/* The cart tab ends flush with the photograph and follows its outside corner. */
#grid .quick-cart {
  top:0;right:0;width:46px;height:44px;display:grid;place-items:center;
  padding:0 0 2px 3px;border:0;border-radius:0 0 0 18px;transform:none;
  color:#265646;background:linear-gradient(155deg,#f8eedcfa,#ebdbc1f2);
  box-shadow:inset 1px -1px 0 #fff6e3aa,0 1px 3px #352a1e2e;
}
#grid .quick-cart::before,#grid .quick-cart::after {content:none;}
#grid .quick-cart.in-cart {background:var(--price-color);color:#fffaf0;box-shadow:inset 1px -1px 0 #ffffff35;}
#grid .quick-cart:active {box-shadow:inset 0 1px 5px #3b473a4a;}
#grid .quick-cart svg {width:22px;height:22px;}
#grid .quick-cart:focus-visible {outline:2px solid currentColor;outline-offset:-4px;}
.pack-glass {padding:2px 0 4px;gap:0; background:linear-gradient(0deg,#f9eddbed,#f2e4cfa8 78%,#f7ecd22b);}
.pack-glass .pack-unit {margin:-3px 0 0;font-size:11px;color:#2d4d47;line-height:1.05;}
.drum-ready .pack-lens {overflow:visible;border:2px solid #a87e49;box-shadow:inset 0 0 0 1px #ffefd2,0 0 0 1px #fff8d98c,0 2px 3px #61482e66;pointer-events:none;}
.drum-ready .pack-lens::after {content:"";position:absolute;left:85%;top:85%;width:30%;height:4px;transform:rotate(46deg);transform-origin:0 50%;background:linear-gradient(#d5b27a,#745b3b);box-shadow:0 1px 1px #58402355;border:1px solid #8e6d44;border-radius:4px;}
#detail[open] {background:var(--studio-surface);color:#293f3c;border:1px solid #fff8e5;border-radius:22px;box-shadow:0 22px 68px #20353355,inset 0 0 0 1px #bbaa8f4d;backdrop-filter:blur(15px);}
#detail::backdrop {background:#28392e32;}
.store-page:has(#detail[open]) #catalogPage {opacity:.045;}
#detail[open],#detail.checkout-dialog:has(.customer-account,.shop-auth),#detail:not(.checkout-dialog)[data-view=cart] {background:var(--studio-surface);backdrop-filter:blur(18px) saturate(.86);-webkit-backdrop-filter:blur(18px) saturate(.86);box-shadow:inset 0 1px #fffdf6,0 16px 54px #19392f41;}
#detail .dialog-head {background:transparent;}
#detail[data-view=product]:not(.checkout-dialog) {max-width:960px;width:min(960px,calc(100% - 24px));padding:clamp(12px,1.7vw,24px);}
#detail[data-view=product] .detail-body {padding:clamp(10px,1.4vw,20px);border:1px solid #ded2bd;border-radius:16px;background:var(--studio-frost);align-items:start;}
.product-purchase .wb-link,.co-shell .co-primary {border-radius:12px;background:linear-gradient(#39766d,#235852);box-shadow:inset 0 1px #ffffff35,0 2px 5px #254c4224;}
#detail .co-panel,#detail .co-line {border-color:#d8cab4;background:var(--studio-frost);box-shadow:inset 0 1px #fffaf0;}
#detail .co-summary {background:linear-gradient(148deg,#fff9e9c2,#efe4d396);}
#detail.checkout-dialog:has(.customer-account) {max-width:830px;width:calc(100% - 24px);}
#detail .customer-account {display:grid;gap:16px;}
.customer-account .profile-head,.customer-account .profile-history,.customer-account .profile-bonus {border:1px solid #d6cbb7;border-radius:15px;padding:clamp(12px,2vw,20px);background:var(--studio-frost);}
.customer-account .profile-bonus {background:linear-gradient(115deg,#e1eee5,#f7eedc);}
.customer-account .profile-order {border-color:#d9cebb;background:#fffaf0c9;}
#detail.checkout-dialog:has(.studio-order) {width:min(1010px,calc(100% - 24px));max-width:1010px;padding:clamp(14px,2.2vw,28px);}
.checkout-dialog .studio-order {display:grid;grid-template-columns:minmax(0,1fr);gap:16px;}
.studio-order .order-uploads,.studio-order .order-chat {background:var(--studio-frost);border-color:#d5c9b7;border-radius:16px;padding:clamp(12px,1.8vw,21px);}
.studio-order .product-file-grid {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;align-items:start;}
.studio-order .product-file-area {min-width:0;margin:0;border:1px solid #d8cbb8;border-radius:13px;background:#fffaf0c9;padding:12px;}
.studio-order .product-file-area:only-child {grid-column:1/-1;}
.studio-order .file-product {display:flex;align-items:center;gap:11px;padding-bottom:9px;border-bottom:1px solid #ddcfbb;}
.studio-order .file-product h4 {margin:0 0 4px;font-size:16px;line-height:1.2;}
.studio-order .file-cover {display:grid;place-items:center;flex:none;width:64px;height:68px;border-radius:9px;background:#e8dfce;color:#847c63;overflow:hidden;}
.file-cover img {width:100%;height:100%;object-fit:cover;}
.file-cover svg {width:24px;}
.studio-order .product-file-area :is(p,ul):empty,.studio-order .chat-compose :is(p,span,ul):empty {display:none;}
.studio-order .product-file-area [id$=uploadSummary] {font-size:12px;color:#4e625b;margin:8px 0;}
.studio-order .file-gallery {display:grid;grid-template-columns:repeat(auto-fill,minmax(60px,1fr));gap:5px;list-style:none;padding:0;margin:6px 0;max-height:210px;overflow:auto;}
.studio-order .file-gallery li {min-width:0;}
.studio-order .file-gallery a {display:flex;height:66px;flex-direction:column;justify-content:center;overflow:hidden;border:1px solid #d8cab6;border-radius:7px;background:#eee6d6;color:#264e4b;text-decoration:none;}
.studio-order .file-gallery img {width:100%;height:44px;min-height:0;object-fit:cover;flex:1;}
.studio-order .file-gallery span {display:block;flex:none;padding:3px 4px;font-size:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.gallery-more {background:transparent;border:0;color:#215b58;text-decoration:underline;padding:4px 0;font:inherit;}
.mini-photo-drop {display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:6px;width:100%;min-height:43px;border:1px dashed #829e91;background:#edf2e8;color:#264d46;border-radius:9px;padding:6px 9px;font-weight:650;}
.mini-photo-drop svg,.compose-icon svg {width:20px;height:20px;}
.mini-photo-drop small {font-size:11px;font-weight:450;}
.file-dragging .mini-photo-drop,.mini-photo-drop:hover:enabled {border-color:#356659;background:#dcece0;}
.studio-order .chat-messages {display:flex;flex-direction:column;gap:8px;padding:6px 2px 12px;min-height:76px;max-height:35dvh;background:transparent;}
.studio-order .chat-row {display:flex;justify-content:flex-start;}
.studio-order .from-customer {justify-content:flex-end;}
.studio-order .chat-bubble {max-width:85%;min-width:0;margin:0;padding:8px 13px;border:1px solid #d8cdbb;background:#fffbf0;border-radius:12px 12px 12px 3px;}
.studio-order .from-customer .chat-bubble {background:#dfede3;border-color:#c3d6c8;border-radius:12px 12px 3px 12px;}
.studio-order .chat-bubble b {font-size:11px;color:#44635a;}
.compose-bar {display:flex;align-items:center;gap:4px;padding:4px;border:1px solid #baae98;border-radius:14px;background:#fffaf2;box-shadow:inset 0 1px 3px #6650310d;}
.compose-bar:focus-within {border-color:#37716c;}
.studio-order .compose-bar textarea {flex:1;min-width:0;width:0;min-height:40px;height:40px;margin:0;padding:9px 5px;resize:vertical;border:0;box-shadow:none;background:transparent;font:inherit;font-size:15px;}
.compose-icon {display:grid;place-items:center;flex:none;width:40px;height:40px;padding:0;background:transparent;border:0;border-radius:9px;color:#26564e;}
.compose-icon:hover:enabled {background:#e8eddf;}
.compose-icon.compose-send {background:#285e56;color:white;}
.compose-icon.compose-send:hover:enabled {background:#1c5148;}
.studio-order [hidden] {display:none;}
@media (max-width:860px) {
  html {scroll-padding-top:calc(var(--mobile-header-height) + 4px);}
  #catalogPage {width:calc(100% - 16px);margin:19px auto 10px;border-radius:16px;}
  #catalogPage .catalog,#catalogPage .intro {padding-inline:9px;}
}
@media (max-width:600px) {
  .studio-order .product-file-grid {grid-template-columns:minmax(0,1fr);}
  #detail.checkout-dialog:has(.studio-order) {width:calc(100% - 10px);padding:10px;}
  .studio-order .order-chat,.studio-order .order-uploads {padding:9px;}
  #grid .quick-cart {width:44px;}
  #grid .name {font-size:13px;}
  .mini-photo-drop small {display:none;}
}
.account-sections {display:flex;flex-wrap:wrap;gap:6px;border-bottom:1px solid #d5c7b1;padding:0 0 12px;}
.account-sections button {border:1px solid #cfc0a9;border-radius:10px;padding:8px 14px;background:#fff8e9;color:#284e46;font:inherit;font-weight:650;}
.account-sections button[aria-pressed=true] {background:linear-gradient(#3f756c,#295c54);border-color:#37685f;color:#fffaf0;}
.customer-account .profile-card {padding:16px;border:1px solid #d5c7b1;background:var(--studio-frost);border-radius:14px;}
#detail .customer-account [hidden] {display:none;}
.queued-thumbs:not(:empty) {display:flex;gap:5px;margin:6px 0;}
.queued-thumbs img {width:42px;height:42px;object-fit:cover;border-radius:7px;}
.studio-order progress {width:100%;height:5px;accent-color:#34766c;}
.product-purchase .purchase-line {display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 14px;margin-top:12px;}
.product-purchase .purchase-line .price {margin:0;font-size:clamp(20px,2.1vw,29px);}
.product-purchase .pack-choice {margin:12px 0 0;background:#f8eedc;border:1px solid #d5c6af;border-radius:20px;padding:2px 6px;}
.product-purchase .pack-choice .pack-unit {margin-top:-3px;line-height:1.05;font-size:11px;}
#detail .studio-order .file-gallery {padding:0;grid-template-columns:repeat(3,minmax(0,1fr));}
#detail .studio-order .file-gallery a {display:flex;padding:0;height:clamp(73px,7vw,92px);}
.studio-order .spend-bonus:not([hidden]) {display:flex;align-items:center;margin:8px 0;padding:6px 8px;gap:5px;font-weight:550;font-size:13px;}
.studio-order .spend-bonus input {flex:none;margin:0;}
@media(min-width:601px){
 .studio-order .product-file-area:only-child .file-gallery {grid-template-columns:repeat(6,minmax(0,1fr));}
}
#detail[data-view=product] .product-description {
  display:block;overflow:visible;-webkit-line-clamp:unset;max-height:none;white-space:normal;
  font-size:clamp(14px,1.12vw,16px);line-height:1.55;color:#343e36;margin:0 0 .75em;
}
#detail[data-view=product] .product-copy {align-self:start;}
#detail[data-view=product] .product-copy h2 {margin-top:0;}
#detail[data-view=product] .product-copy [data-wb-intro] {margin-block:12px;}
@media(min-width:701px) {
  #detail[data-view=product] .detail-body {grid-template-columns:minmax(200px,.8fr) minmax(0,1.12fr);gap:clamp(18px,2.3vw,35px);}
  #detail[data-view=product] .product-photo {position:static;align-self:start;width:100%;height:auto;max-height:410px;object-fit:contain;}
}
#detail .customer-account {gap:12px;}
:is(.customer-account,.shop-auth) .profile-heading {position:relative;display:flex;align-items:center;min-height:84px;padding:10px 152px 12px 0;}
:is(.customer-account,.shop-auth) .profile-heading h2 {padding:0;margin:0;}
.studio-prints {position:absolute;right:36px;bottom:7px;width:132px;height:74px;pointer-events:none;}
.studio-prints img {position:absolute;width:86px;height:64px;object-fit:cover;border:4px solid #fffaed;border-bottom-width:8px;box-shadow:0 2px 5px #3c382c40;}
.studio-prints img:first-child {left:0;top:0;transform:rotate(-9deg);}
.studio-prints img:last-child {right:0;bottom:0;transform:rotate(8deg);}
#detail .profile-history {background:var(--studio-frost);}
.customer-account .profile-order {display:grid;gap:12px 14px;padding:15px;background:linear-gradient(110deg,#fffcf1c9,#f7eddac0);}
.profile-order .history-items {display:flex;flex-wrap:wrap;grid-column:1/-1;gap:10px 17px;list-style:none;padding:0;margin:0;}
.history-items li {flex:1 1 175px;max-width:310px;display:flex;align-items:center;gap:10px;min-width:0;}
.history-cover {width:62px;height:73px;flex:none;display:block;overflow:hidden;border:3px solid #fff9ed;border-bottom-width:6px;border-radius:3px;
  background:linear-gradient(148deg,transparent 58%,#b5c3a9 59% 68%,#afbaa0 69%),#e6ddc9;box-shadow:0 1px 4px #5144313b;}
.history-cover img {display:block;width:100%;height:100%;object-fit:cover;}
.history-caption {color:#273f38;font-weight:625;font-size:13px;line-height:1.35;}
.history-caption small {display:block;margin-top:3px;color:#516257;font-size:12px;font-weight:500;}
.history-extra {grid-column:1/-1;color:#4b5c51;}
.profile-order .order-meta {border-top:1px solid #a798792f;padding-top:6px;}
@media(max-width:860px) {
  body.store-page,body.constructor-page {background-position:66% center;}
}
@media(max-width:520px) {
  :is(.customer-account,.shop-auth) .profile-heading {min-height:66px;padding-right:98px;}
  .studio-prints {width:82px;height:51px;right:16px;bottom:1px;}
  .studio-prints img {width:56px;height:43px;border-width:2px 2px 5px;}
  .profile-order .history-items {gap:7px;}
  .history-items li {max-width:none;flex-basis:100%;}
  .history-cover {width:43px;height:48px;}
}
@media(prefers-reduced-transparency:reduce),(forced-colors:active) {
  #catalogPage,#detail[open],#detail.checkout-dialog:has(.customer-account,.shop-auth),#detail:not(.checkout-dialog)[data-view=cart] {background:#faf4e9;backdrop-filter:none;}
}

.file-cover {position:relative;}
.file-cover img {position:absolute;inset:0;}
.shop-auth .profile-heading {padding-right:105px;}
.shop-auth .studio-prints {width:83px;height:53px;right:13px;}
.shop-auth .studio-prints img {width:58px;height:45px;border-width:2px 2px 5px;}

#detail[data-view=product] [data-wb-rest]:not(:empty) {grid-column:1/-1;border-top:1px solid #a491742e;padding:15px 0 0;}
#detail[data-view=product] [data-wb-rest]:empty {display:none;}
#detail[data-view=product] [data-wb-rest] p {max-width:83ch;margin:0 auto .7em;}
.history-items li {border-radius:8px;padding:5px;background:#fffcf266;}
@media(min-width:861px) {
  .history-cover {width:75px;height:82px;}
}

#detail h2[tabindex="-1"]:focus,#detail #cartHeading:focus {outline:0;}

/* Keep the document at its current position throughout the native dialog lifecycle. */
html:has(#detail[open]) {overflow:hidden;overscroll-behavior:none;padding-inline-end:var(--shop-scrollbar,0px);}
#detail[open] {overflow-y:auto;overscroll-behavior:contain;}
#detail[open] .pack-track {overscroll-behavior-x:contain;}

/* The reading area and ordering controls share the desktop grid. Only the reading area scrolls in the mobile sheet. */
.product-reading {display:contents;}
#detail[data-view=product] .product-photo {grid-area:photo;}
#detail[data-view=product] .product-copy {grid-area:copy;}
#detail[data-view=product] .product-purchase {grid-area:purchase;min-width:0;}
#detail[data-view=product] [data-wb-rest] {grid-area:rest;}
#detail[data-view=product] .detail-body {grid-template-areas:"photo copy" "photo purchase" "rest rest";grid-template-rows:auto 1fr auto;}
#detail .product-purchase .cart-error:empty {display:none;}

@media(max-width:860px),(hover:none) and (max-width:1024px) and (max-height:560px) {
  #detail[open][data-view=product]:not(.checkout-dialog) {
    position:fixed;inset:auto 0 0;margin:0 auto;width:min(100%,660px);max-width:100%;
    max-height:calc(100dvh - max(8px,env(safe-area-inset-top,0px)));
    display:flex;flex-direction:column;overflow:hidden;padding:0;box-sizing:border-box;
    border-radius:20px 20px 0 0;border-bottom:0;
  }
  #detail[data-view=product] .dialog-head {flex:none;margin:0;padding:4px 12px 4px 16px;background:#faf3e6ee;}
  #detail[data-view=product] #detailContent {display:flex;flex-direction:column;min-height:0;}
  #detail[data-view=product] .detail-body {
    display:flex;flex-direction:column;align-items:stretch;min-height:0;padding:0;gap:0;border:0;border-radius:0;background:transparent;
  }
  #detail[data-view=product] .product-reading {
    display:grid;grid-template-columns:minmax(0,1fr);grid-template-areas:"photo" "copy" "rest";
    align-content:start;flex:0 1 auto;min-height:0;overflow-y:auto;overscroll-behavior-y:contain;
    gap:10px;padding:8px clamp(14px,3vw,22px) 18px;background:var(--studio-frost);
  }
  #detail[data-view=product] .product-photo {justify-self:center;width:100%;height:auto;max-height:clamp(120px,30dvh,245px);object-fit:contain;}
  #detail[data-view=product] .product-copy [data-wb-intro] {margin-bottom:0;}
  #detail[data-view=product] [data-wb-rest]:not(:empty) {padding:0;border:0;}
  #detail[data-view=product] .product-purchase {
    display:grid;flex:none;align-items:center;gap:6px 16px;
    padding:9px clamp(14px,3vw,22px) max(10px,env(safe-area-inset-bottom,0px));
    border-top:1px solid #cdbfa9;background:#faf3e6;box-shadow:0 -3px 9px #45382016;z-index:1;
  }
  #detail .product-purchase .pack-choice {justify-self:center;width:100%;max-width:24rem;margin:0;}
  #detail .product-purchase > .pack-unit {margin:0;}
  #detail .product-purchase .purchase-line {margin:0;gap:4px 10px;}
  #detail .product-purchase #orderProduct {min-height:44px;margin:0;}
  #detail .product-purchase .cart-error:not(:empty) {grid-column:1/-1;margin:0;}
}
@media(min-width:590px) and (max-width:860px),(hover:none) and (min-width:590px) and (max-width:1024px) and (max-height:560px) {
  #detail[data-view=product] .product-purchase:has(.pack-choice) {grid-template-columns:minmax(0,1fr) auto;}
  #detail .product-purchase .purchase-line {gap:16px;}
}

/* Keep the active destination visible in the persistent navigation. */
@media(min-width:861px) {
  .top nav a[aria-current=page] {color:var(--studio-teal);text-decoration:underline;text-underline-offset:5px;text-decoration-thickness:1px;}
}
@media(prefers-reduced-motion:no-preference) {
  #detail[open] {animation:shop-dialog-appear 140ms ease-out;}
  .top.has-menu .nav-toggle[aria-expanded=true]+#shopNav {animation:shop-dialog-appear 110ms ease-out;}
  @keyframes shop-dialog-appear {from {opacity:.55;}to {opacity:1;}}
}

#detail[open]:not([data-view=product]) {--studio-surface:linear-gradient(115deg,#fffaf0ea,#f3eadced);}
#detail:has(.studio-order) .dialog-head {height:0;min-height:0;margin:0;padding:0;}
#detail:has(.studio-order) #close {position:absolute;inset:10px 12px auto auto;z-index:2;}
#detail:has(.studio-order) #dialogTitle {margin:0;padding-inline-end:48px;overflow-wrap:anywhere;}
.order-chat-jump {display:inline-flex;align-items:center;min-height:42px;padding:0 2px;margin:0 0 6px;border:0;background:transparent;color:var(--studio-teal);font:inherit;font-weight:650;text-decoration:underline;text-underline-offset:3px;}
@media(max-width:740px) {
  #detail [data-section=delivery] .co-options {grid-template-columns:repeat(2,minmax(0,1fr));}
  #detail [data-section=delivery] .co-option {min-height:46px;flex-direction:row;gap:6px;padding:6px;}
  #detail .co-steps button {min-height:40px;}
  #detail .co-stepper button,#detail .co-remove {min-height:36px;min-width:32px;}
}
