/* Commerce only. Warm paper, charcoal type, brown accents; the main site is unchanged. */
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]){
 --ink:#211d19;--muted:#6b6259;--green:#80573e;--bright:#f3ece3;--line:#e5e0d9;--paper:#fff;--bg:#faf9f7;
 --shop-accent:#80573e;--shop-accent-dark:#69432e;--shop-soft:#f4f0ea;--shop-border:#e5e0d9;--shop-error:#8b3e26;
 min-width:0;background:var(--bg);color:var(--ink);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Microsoft YaHei",sans-serif;font-size:14px;line-height:1.65;-webkit-font-smoothing:antialiased;
}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) :is(button,input,textarea,select){font:inherit}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) :is(button,a,input,textarea,select,summary):focus-visible{outline:2px solid var(--shop-accent);outline-offset:3px}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) button:disabled{opacity:1;cursor:not-allowed;transform:none;box-shadow:none}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) button:is(.primary,.secondary):disabled{background:#ede9e3;color:var(--muted);border-color:#ddd5cb;opacity:1}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) [hidden]{display:none!important}
.shop-skip{position:fixed;top:12px;left:16px;z-index:1000;display:inline-flex;align-items:center;min-height:44px;padding:10px 16px;border-radius:8px;background:var(--ink);color:#fff;font-size:14px;transform:translateY(-180%)}
.shop-skip:focus,.shop-skip:focus-visible{transform:none;outline:2px solid var(--shop-accent);outline-offset:3px}

/* Header and hierarchy. Small screens keep readable navigation, even across two rows. */
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .topbar{max-width:1280px;min-height:84px;height:auto;padding:16px 32px;border-bottom:1px solid var(--shop-border);gap:24px;background:transparent}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .brand{font-size:23px;letter-spacing:-.7px;gap:10px;color:var(--ink);flex-shrink:0}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .brand img{width:32px;height:32px;filter:grayscale(1)}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .brand small{font-size:12px;color:var(--muted);letter-spacing:.7px}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .topbar nav{max-width:none;gap:22px;font-size:13px;color:var(--muted);line-height:1.6}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .topbar nav :is(a,button){display:inline-flex;align-items:center;min-height:44px;padding:10px 0}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .topbar nav [aria-current="page"]{color:var(--ink);font-weight:600}
.topbar nav .shop-redeem-link{gap:5px}
.topbar nav .shop-redeem-link::after{content:"";flex:0 0 6px;width:6px;height:6px;border:solid currentColor;border-width:0 1.5px 1.5px 0;transform:rotate(-45deg);margin-inline-end:2px}
.shop-main{max-width:1280px;margin:0 auto;padding:24px 32px 64px;min-width:0}
body:is([data-page="order"],[data-page="support"]) .shop-main{max-width:1040px}
.beta-banner{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:4px 20px;padding:10px 14px;border-left:2px solid var(--shop-accent);border-radius:8px;background:var(--shop-soft);color:var(--muted);font-size:12px;line-height:1.7}
.beta-banner strong{font-size:12px;font-weight:600;color:var(--shop-accent-dark)}
.shop-hero{max-width:760px;padding:28px 0 26px}
.shop-hero h1{font-size:clamp(28px,3vw,37px);font-weight:600;line-height:1.25;letter-spacing:-1.2px;margin:10px 0 12px;color:var(--ink)}
.shop-hero p{max-width:680px;color:var(--muted);font-size:14px;line-height:1.8;margin:0 0 12px}
.shop-hero .eyebrow,.shop-main .mini-label{font-size:12px;letter-spacing:1.1px;color:var(--shop-accent)}
.compact-hero{padding-bottom:22px}
body:is([data-page="order"],[data-page="support"]) .compact-hero{max-width:820px;margin:0 auto}
body[data-page="shop"] .shop-hero{display:flex;align-items:flex-end;justify-content:space-between;gap:24px;max-width:none;padding:24px 0 25px}
body[data-page="shop"] .shop-hero>div{max-width:720px}
body[data-page="shop"] .shop-hero p{margin-bottom:0}
body[data-page="shop"] .shop-hero>.text-button{flex-shrink:0;font-size:13px}

/* Shared controls. Feedback remains legible while a control is unavailable. */
.shop-main .primary,.product-dialog .primary{display:inline-flex;align-items:center;justify-content:center;gap:9px;min-height:44px;padding:10px 17px;width:auto;border:1px solid var(--ink);border-radius:8px;background:var(--ink);color:#fff;font-size:14px;font-weight:550;line-height:1.6;text-align:center;transition:background .16s,border-color .16s,box-shadow .16s}
.shop-main .primary:hover:enabled,.product-dialog .primary:hover:enabled{background:var(--ink);border-color:var(--ink);transform:none}
.shop-main .secondary{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:10px 15px;border:1px solid #d6cdc2;border-radius:8px;background:#fff;color:var(--ink);font-size:13px;line-height:1.6;transition:background .16s,border-color .16s}
.shop-main .text-button{display:inline-flex;align-items:center;gap:7px;min-height:44px;padding:10px 0;color:var(--shop-accent);font-size:13px;line-height:1.65}
.shop-main :is(input:not([type="radio"]):not([type="checkbox"]),select,textarea){display:block;width:100%;min-width:0;max-width:100%;border:1px solid #b8ada0;border-radius:8px;background:#fff;color:var(--ink);padding:11px 13px;min-height:46px;font-size:14px;line-height:1.6;box-sizing:border-box;transition:border-color .16s,background .16s}
.shop-main :is(input,textarea,select):focus{border-color:var(--shop-accent);box-shadow:none}
.shop-main :is(input,textarea)::placeholder{color:var(--muted);opacity:1;font-weight:400}
.shop-main :is(input,textarea,select):disabled{opacity:1;-webkit-text-fill-color:var(--muted);color:var(--muted);background:#f2efea;cursor:not-allowed}
.shop-main input[readonly]{background:#f7f5f1}
.shop-main textarea{min-height:128px;resize:vertical;line-height:1.8}
.shop-main label{margin:0;color:var(--ink);font-size:13px;font-weight:550;line-height:1.7}
.shop-main .field-note{color:var(--muted);font-size:13px;line-height:1.8;margin:4px 0 10px}
.shop-main :is(input[type="checkbox"],input[type="radio"]){accent-color:var(--shop-accent)}
.shop-main input[type="file"]{padding:8px;font-size:13px}
.shop-main input::file-selector-button{padding:8px 10px;min-height:34px;margin-right:10px;border:0;border-radius:6px;background:var(--shop-soft);color:var(--shop-accent-dark);font:inherit;cursor:pointer}
.shop-main :is(input,textarea,select)[aria-invalid="true"]{border-color:var(--shop-error)}
.field-error{margin:0;color:var(--shop-error);font-size:13px;font-weight:450;line-height:1.7}

/* A slim category rail and compact product cards; only previews are truncated. */
.shop-benefits{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px;margin:0 0 25px;padding:0 0 22px;border-bottom:1px solid var(--shop-border)}
.shop-benefits>div,.shop-benefits>a{display:flex;align-items:center;gap:12px;min-width:0;padding:6px 0;border-radius:8px}
.shop-benefits strong,.shop-benefits small{display:block;line-height:1.65}
.shop-benefits strong{font-size:13px;font-weight:550;color:var(--ink)}
.shop-benefits small{font-size:12px;font-weight:400;color:var(--muted);margin-top:2px}
.shop-benefits>a>span:last-child{margin-left:auto;color:var(--shop-accent);font-size:14px}
.benefit-icon{display:grid;place-items:center;flex:0 0 28px;width:28px;height:28px;border-radius:6px;background:var(--shop-soft);color:var(--shop-accent);font:11px ui-monospace,SFMono-Regular,Consolas,monospace}
.shop-shell{display:grid;grid-template-columns:184px minmax(0,1fr);align-items:start;gap:28px;min-width:0}
.catalog-sidebar{padding:14px 8px;min-width:0}
.catalog-sidebar>.mini-label{margin:0 11px 12px;font-size:12px;letter-spacing:.8px;color:var(--muted)}
.catalog-content{min-width:0}
.catalog-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;min-width:0;margin:0 0 20px}
.catalog-heading>div{min-width:0}
.catalog-heading h1,.catalog-heading h2{font-size:24px;line-height:1.4;letter-spacing:-.65px;font-weight:600;margin:0 0 5px;color:var(--ink)}
.catalog-heading p{font-size:13px;color:var(--muted);line-height:1.7;margin:0}
.catalog-guide-links:not([hidden]){display:flex;flex-wrap:wrap;gap:0 18px}
.catalog-tools{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0 0 16px;min-width:0}
.category-tabs{display:flex;align-items:center;flex-wrap:wrap;gap:7px;min-width:0}
.catalog-sidebar .category-tabs{display:grid;grid-template-columns:minmax(0,1fr);gap:5px}
.category-tabs :is(button,a,:where(.category-unavailable)){display:inline-flex;align-items:center;justify-content:flex-start;gap:8px;min-height:44px;padding:10px 11px;border:1px solid transparent;border-radius:8px;background:transparent;color:var(--muted);font-size:13px;text-align:left;line-height:1.6;white-space:nowrap}
.category-tabs :is(.active,[aria-selected="true"],[aria-pressed="true"],[aria-current="page"]){background:#f1e9df;color:var(--shop-accent-dark);font-weight:600}
.category-tabs button span{margin-left:0;font-size:inherit;color:inherit;text-align:left}
.category-tabs :is(button,:where(.category-unavailable)) small{margin-left:auto;font-size:12px;font-weight:400;color:var(--muted)}
.catalog-order-link{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:44px;margin:15px 10px 0;padding:14px 0 0;border-top:1px solid var(--shop-border);font-size:13px;color:var(--shop-accent);line-height:1.7}
.catalog-search{display:flex;align-items:center;gap:10px;flex:0 1 260px;min-width:180px;max-width:100%;padding:0 13px;border:1px solid #b8ada0;border-radius:8px;background:#fff;color:var(--muted)}
.catalog-search:focus-within{outline:2px solid var(--shop-accent);outline-offset:3px;border-color:var(--shop-accent);box-shadow:none}
.catalog-search svg{flex:0 0 17px;width:17px;height:17px}
body[data-page="shop"] .shop-main .catalog-search input{min-height:0;height:44px;margin:0;padding:0;border:0;border-radius:0;background:transparent;box-shadow:none;outline:none;font-size:14px}
.catalog-summary{font-size:13px;color:var(--muted);line-height:1.7}
.catalog-groups{display:grid;gap:26px;min-width:0}
.catalog-product-group{min-width:0}
.catalog-product-group>h2{margin:0 0 10px;color:var(--ink);font-size:17px;font-weight:600;line-height:1.45}
.product-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;max-width:none;min-width:0;align-items:stretch}
.product-card{position:relative;display:flex;flex-direction:column;min-width:0;padding:17px;border:1px solid var(--shop-border);border-radius:12px;background:#fff;transition:border-color .16s,box-shadow .16s}
.product-card.is-selected{border-color:var(--shop-accent);box-shadow:inset 0 0 0 1px var(--shop-accent);background:#fffdf9}
.product-open{display:grid;grid-template-columns:72px minmax(0,1fr);align-items:start;gap:13px;min-width:0;width:100%;padding:0;border:0;border-radius:8px;background:transparent;text-align:left;color:inherit;flex:1}
.product-visual{display:grid;place-items:center;align-self:start;width:72px;height:76px;min-width:0;margin:0;border-radius:8px;background:#f7f4ef;overflow:hidden}
.product-card .product-image{display:block;flex-shrink:0;width:64px;height:64px;max-width:100%;aspect-ratio:auto;object-fit:contain;margin:0;border:0;border-radius:4px;background:transparent}
.product-placeholder{color:var(--shop-accent);font-size:29px;font-weight:600;letter-spacing:-2px}
.product-info{display:flex;flex-direction:column;min-width:0;gap:6px}
.product-tag{display:inline-flex;align-self:flex-start;max-width:100%;padding:0;margin:0;color:var(--shop-accent);font-size:12px;line-height:1.5}
.product-title,.product-card h2{display:block;margin:0;font-size:16px;font-weight:600;letter-spacing:-.2px;line-height:1.5;overflow-wrap:anywhere;color:var(--ink)}
.product-description{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;margin:0;white-space:pre-line;color:var(--muted);font-size:13px;line-height:1.7;font-weight:400}
.product-meta{display:flex;align-items:center;flex-wrap:wrap;gap:4px 9px;margin:0;font-size:12px;font-weight:400;color:var(--muted);line-height:1.7;overflow-wrap:anywhere}
.product-meta :is(span,small){max-width:100%;font-size:inherit}
.product-meta.is-unavailable{color:var(--muted);font-weight:550}
.product-bottom{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:10px;margin-top:14px;padding-top:4px}
.product-price{display:flex;align-items:baseline;flex-wrap:wrap;gap:5px;margin:0;color:var(--shop-accent);font-size:24px;font-weight:600;line-height:1.25;letter-spacing:-.8px;font-variant-numeric:tabular-nums}
.product-price small{font-size:12px;font-weight:400;color:var(--muted);letter-spacing:0}
.product-card .primary{min-height:44px;padding:10px 12px;font-size:13px;border-radius:8px;white-space:normal}
.empty-products{grid-column:1/-1;min-height:170px;padding:32px 24px;border:1px solid var(--shop-border);border-radius:12px;background:#fff;text-align:center;color:var(--muted);font-size:14px;line-height:1.8}
.empty-products :is(h2,h3){font-size:18px;font-weight:550;color:var(--ink);margin:0 0 8px}
.empty-products p{margin:6px 0}
.empty-products .secondary{margin-top:12px}
#shop-products>p{grid-column:1/-1;display:grid;place-items:center;min-height:160px;margin:0;padding:24px;border-radius:12px;background:#fff;color:var(--muted);font-size:14px;text-align:center}

/* Deliberate, separate read and mutation states: never suggest a payment succeeded. */
.read-status{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:12px 18px;margin:16px 0;padding:14px 16px;border-radius:8px;background:var(--shop-soft);color:var(--muted);font-size:13px;line-height:1.8;overflow-wrap:anywhere}
.read-status p{flex:1 1 220px;min-width:0;margin:0}
.read-status .secondary{flex-shrink:0;min-height:44px;font-size:13px}
.read-status[data-state="error"]{border-left:3px solid var(--shop-error);background:#fcf3ed;color:var(--shop-error)}
.catalog-state{margin:0 0 16px}
.catalog-state[data-state="loading"]{justify-content:center;min-height:148px;background:#fff;text-align:center;border:1px solid var(--shop-border);border-radius:12px}
.catalog-state[data-state="error"]{min-height:112px}
.lookup-instructions{margin:14px 0;padding:15px 17px;border-left:3px solid var(--shop-accent);border-radius:8px;background:var(--shop-soft);color:var(--ink);font-size:13px;line-height:1.9}
.lookup-instructions p{margin:5px 0}
.shop-main .feedback{position:static;margin:20px 0;padding:14px 16px;border-left:3px solid var(--shop-accent);border-radius:8px;background:#f7f0e6;color:var(--shop-accent-dark);font-size:14px;line-height:1.8;overflow-wrap:anywhere}
.shop-main .feedback[data-state="error"]{border-left-color:var(--shop-error);background:#fcf3ed;color:var(--shop-error)}

/* Checkout: one clear product summary, then large payment option tiles. */
.shop-panel{max-width:820px;margin:24px 0;padding:28px;border:1px solid var(--shop-border);border-radius:12px;background:#fff;min-width:0}
.shop-main>.shop-panel{margin-left:auto;margin-right:auto}
.shop-panel h2{margin:0 0 16px;font-size:22px;color:var(--ink);font-weight:600;letter-spacing:-.5px;line-height:1.5}
.shop-panel form{display:grid;gap:12px;min-width:0}
.shop-panel .panel-heading{margin-bottom:24px}
.shop-panel .panel-heading p{font-size:13px;line-height:1.8;color:var(--muted)}
#checkout-panel{max-width:820px;margin:28px auto 0;padding:28px;scroll-margin-top:24px}
#checkout-panel .primary{width:100%}
.checkout-summary{display:flex;align-items:center;gap:14px;margin:14px 0 6px;min-width:0}
.checkout-summary>img{display:block;width:48px;height:48px;flex:0 0 48px;object-fit:contain;border-radius:8px;background:#f7f4ef}
.checkout-summary-info{min-width:0;flex:1}
.checkout-summary h2{font-size:20px;margin:0 0 4px;line-height:1.45;overflow-wrap:anywhere}
.shop-panel .checkout-summary p{margin:0;color:var(--shop-accent);font-size:16px;font-weight:550;font-variant-numeric:tabular-nums}
#checkout-details{font-size:13px;min-height:44px}
.checkout-quantity{display:flex;align-items:center;justify-content:space-between;gap:16px;min-height:44px;padding:2px 0}
.checkout-quantity label{margin:0;font-size:13px;font-weight:500;color:var(--muted)}
.shop-main .checkout-quantity #buy-quantity{width:56px;min-width:56px;height:44px;min-height:44px;margin:0;padding:0;border:0;border-radius:8px;background:transparent;color:var(--ink);font-size:16px;font-weight:550;text-align:right;box-shadow:none;appearance:textfield;-moz-appearance:textfield;font-variant-numeric:tabular-nums}
.checkout-quantity #buy-quantity::-webkit-inner-spin-button,.checkout-quantity #buy-quantity::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
.shop-panel .consent{display:flex;align-items:flex-start;gap:10px;min-height:44px;margin:8px 0 0;padding:7px 0;font-size:13px;font-weight:400;line-height:1.8;color:var(--muted)}
.shop-panel .consent input{flex:0 0 18px;width:18px;height:18px;margin:3px 0 0}
.shop-panel .consent a,#detail-meta>a{color:var(--shop-accent);text-decoration:underline;text-underline-offset:3px}
.pay-methods{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;padding:9px 0 0;border:0;min-width:0;margin:0}
.pay-methods legend{font-size:13px;font-weight:550;color:var(--ink);margin-bottom:7px;padding:0}
.shop-panel .pay-methods label{display:grid;grid-template-columns:18px minmax(0,1fr);align-items:center;align-content:center;gap:5px 10px;min-height:66px;margin:0;padding:14px;border:1px solid #b8ada0;border-radius:10px;background:#fff;color:var(--ink);font-size:14px;font-weight:500;cursor:pointer}
.shop-panel .pay-methods label:has(input:checked):not(:has(input:disabled)){border-color:var(--shop-accent);box-shadow:inset 0 0 0 1px var(--shop-accent);background:#fbf6ee;color:var(--shop-accent-dark)}
.shop-panel .pay-methods label:has(input:disabled){background:#f2efea;color:var(--muted);border-color:#ded7ce;cursor:not-allowed}
.shop-panel .pay-methods label:has(input:disabled)::after{grid-column:2;content:"暂不可选";font-size:12px;font-weight:400;line-height:1.5;color:var(--muted)}
.pay-methods input[type="radio"]{display:inline-block;width:18px;height:18px;min-height:0;margin:0;padding:0;border:0;box-shadow:none;background:transparent;flex-shrink:0}
.shop-total{display:flex;align-items:baseline;justify-content:space-between;gap:12px;padding-top:17px;margin:9px 0 0;border-top:1px solid var(--shop-border);font-size:14px;color:var(--muted)}
.shop-total strong{font-size:28px;letter-spacing:-1px;color:var(--ink);font-weight:600}
.service-readiness{padding:12px 14px;margin:4px 0;border-radius:8px;background:#f7f0e6;color:var(--shop-accent-dark);font-size:13px;line-height:1.8}
.shop-promise{margin:32px 0 0;padding:24px 28px;border-radius:12px;background:var(--shop-soft)}
.shop-promise .eyebrow{color:var(--shop-accent);font-size:12px;letter-spacing:1px}
.shop-promise h2{margin:10px 0 14px;font-size:23px;letter-spacing:-.5px;font-weight:600;color:var(--ink)}
.shop-promise p{max-width:88ch;margin:8px 0 0;font-size:14px;line-height:1.85;color:var(--muted)}
.shop-promise summary{display:flex;align-items:center;justify-content:space-between;gap:18px;min-height:44px;cursor:pointer;list-style:none}
.shop-promise summary strong{display:block;font-size:15px;font-weight:550;color:var(--ink);line-height:1.65}
.shop-promise summary small{display:block;font-size:13px;font-weight:400;color:var(--muted);line-height:1.8;margin-top:4px}
.promise-toggle{display:grid;place-items:center;flex:0 0 32px;width:32px;height:32px;color:var(--shop-accent);font-size:22px;font-weight:300;transition:transform .16s}
.shop-promise[open] .promise-toggle{transform:rotate(45deg)}
.shop-promise[open] summary{margin-bottom:16px}

/* Product details: a simple cross, a small original image, and the full description. */
.product-dialog{width:min(620px,calc(100vw - 32px));max-height:calc(100vh - 32px);max-height:calc(100dvh - 32px);margin:auto;padding:26px;border:1px solid var(--shop-border);border-radius:12px;background:#fff;color:var(--ink);box-shadow:0 18px 64px #2f231a24;overflow-y:auto;overscroll-behavior:contain}
.product-dialog::backdrop{background:#211b1666}
.product-dialog-heading{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-bottom:20px}
.product-dialog .mini-label{color:var(--shop-accent);font-size:12px;letter-spacing:1px}
.product-dialog .dialog-close{display:grid;place-items:center;width:44px;height:44px;min-width:44px;padding:0;border:0;border-radius:8px;background:transparent;color:var(--muted);font-size:27px;font-weight:300;line-height:1;box-shadow:none}
.product-dialog-overview{display:grid;grid-template-columns:100px minmax(0,1fr);align-items:center;gap:22px;margin-bottom:24px}
.detail-image{display:block;width:100px;height:100px;object-fit:contain;border:0;border-radius:8px;background:#f7f4ef}
.product-dialog-overview>div{min-width:0}
.product-dialog h2{font-size:24px;font-weight:600;line-height:1.45;letter-spacing:-.6px;margin:8px 0 12px;overflow-wrap:anywhere;color:var(--ink)}
.product-dialog .product-price{font-size:27px}
.detail-description{white-space:pre-line;overflow-wrap:anywhere;font-size:14px;line-height:1.85;color:var(--muted);margin:0 0 24px}
.detail-delivery{padding:15px 17px;border-radius:8px;background:var(--shop-soft)}
.detail-delivery strong{font-size:14px;font-weight:550;color:var(--ink)}
.detail-delivery p{font-size:13px;line-height:1.8;color:var(--muted);margin:6px 0 0}
.product-dialog .field-note{font-size:13px;color:var(--muted);line-height:1.8;margin:17px 0}
.product-dialog .primary{width:100%;min-height:44px}

/* Purchase details, verified mailbox and support retain prominent status and codes. */
.shop-main .status-tag{display:inline-flex;max-width:100%;margin-bottom:16px;padding:7px 11px;border-radius:8px;background:var(--shop-soft);color:var(--shop-accent-dark);font-size:13px;font-weight:500;line-height:1.7}
.purchase-summary{display:grid;grid-template-columns:1fr 1fr;gap:11px 24px;margin:20px 0;padding:17px 19px;border-radius:10px;background:#f7f5f1;min-width:0;overflow-wrap:anywhere}
.purchase-summary p{margin:0;color:var(--muted);font-size:14px;line-height:1.8;min-width:0}
.purchase-summary p:first-child{grid-column:1/-1}
.purchase-summary .mono{font-size:13px;color:var(--ink)}
#purchase-payment>p{font-size:14px;line-height:1.8;color:var(--muted)}
.shop-panel canvas{display:block;width:min(240px,100%);height:auto;aspect-ratio:1;max-width:100%;margin:18px auto}
#purchase-codes{margin:20px 0;padding:18px;border-radius:10px;background:#f7f2eb;min-width:0}
#purchase-codes label{font-size:13px;color:var(--ink);margin-bottom:10px}
.shop-main .delivered-code{min-height:100px;padding:13px 14px;background:#fff;border-color:#b8ada0;resize:vertical;font-family:ui-monospace,SFMono-Regular,Consolas,monospace;font-size:14px;line-height:1.8;overflow-wrap:anywhere}
#purchase-codes :is(.primary,.secondary){display:inline-flex;width:auto;min-height:44px;padding:10px 14px;margin:12px 8px 0 0;font-size:13px}
.code-line{margin:14px 0;padding:17px;border-radius:8px;background:var(--shop-soft);overflow-wrap:anywhere}
.code-line strong{display:block;margin:7px 0 13px;font-size:14px;font-family:ui-monospace,SFMono-Regular,Consolas,monospace;font-weight:500;line-height:1.8}
.shop-main .result-actions{display:flex;flex-wrap:wrap;gap:10px;margin:20px 0 0}
.shop-main .result-actions>*{min-width:130px}
.support-links{display:flex;flex-wrap:wrap;gap:6px 22px;margin-top:21px;padding-top:15px;border-top:1px solid var(--shop-border)}
.support-links .text-button{min-height:44px}
.ticket-row{margin-top:14px;padding:16px;border-radius:8px;background:var(--shop-soft);overflow-wrap:anywhere;font-size:14px;line-height:1.8;color:var(--muted)}
.ticket-row strong{font-size:14px;color:var(--ink);font-weight:550}
.mailbox-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}
.mailbox-heading h2{margin:0}
.mailbox-list{display:grid;gap:12px;margin:20px 0}
.mailbox-order{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:15px;padding:18px;border:1px solid var(--shop-border);border-radius:10px;background:#fff;overflow-wrap:anywhere;min-width:0}
.mailbox-order>div{min-width:0}
.mailbox-order h3{font-size:16px;line-height:1.6;font-weight:550;color:var(--ink);margin:0 0 8px}
.mailbox-order p{font-size:13px;color:var(--muted);line-height:1.8;margin:5px 0}
.mailbox-order .mono{font-size:12px;color:var(--muted)}
.mailbox-order .secondary{min-height:44px;font-size:13px;padding:10px 12px}

/* Administration uses the same hierarchy without diminishing audit information. */
.shop-admin-grid{display:grid;grid-template-columns:minmax(300px,390px) minmax(0,1fr);gap:24px;align-items:start;min-width:0}
.shop-admin-grid .shop-panel{margin:0;max-width:none}
.admin-shop-nav{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:22px 0}
.admin-shop-nav .secondary{min-height:44px;font-size:13px;padding:10px 16px}
.admin-shop-nav :is(.active,[aria-selected="true"]){background:var(--ink);border-color:var(--ink);color:#fff}
.admin-list{display:grid;gap:16px;min-width:0}
.admin-item{min-width:0;padding:22px;border:1px solid var(--shop-border);border-radius:12px;background:#fff;overflow-wrap:anywhere}
.admin-item h2{font-size:20px;font-weight:600;color:var(--ink);line-height:1.5;margin:0 0 12px}
.admin-item p{font-size:14px;color:var(--muted);line-height:1.8;margin:9px 0}
.admin-item small{color:var(--muted);font-size:12px}
.admin-item pre{white-space:pre-wrap;overflow-wrap:anywhere;word-break:break-word;font-family:inherit;font-size:14px;line-height:1.8;color:var(--muted)}
.admin-item .item-actions{display:flex;flex-wrap:wrap;align-items:center;gap:9px;margin-top:18px}
.admin-item .item-actions :is(button,select){width:auto;max-width:100%;min-height:44px;font-size:13px}
.admin-item .product-image{display:block;width:128px;height:128px;max-width:100%;margin:0 0 18px;border:0;border-radius:8px;background:#f7f4ef;object-fit:contain;aspect-ratio:auto}
.image-preview{display:block;width:100%;height:148px;max-width:100%;object-fit:contain;border:1px dashed #b8ada0;border-radius:8px;background:#f7f4ef}
.admin-filters{display:flex;align-items:center;flex-wrap:wrap;gap:10px;margin:0 0 20px;padding:16px;border-radius:10px;background:#fff}
.admin-filters input{min-width:180px;flex:1 1 260px}
.admin-filters select{flex:0 1 180px;width:auto}
.admin-filters .secondary{min-height:46px}
.shop-page-note{margin:0 0 20px;padding:14px 16px;border-radius:8px;background:var(--shop-soft);font-size:14px;line-height:1.8;color:var(--muted)}
.shop-main .badge-warning{color:var(--shop-error);font-weight:550}
#product-batch-fields,#product-stock-fields{display:grid;gap:12px}
#manual-replace-output{margin-top:22px;padding-top:20px;border-top:1px solid var(--shop-border)}
#manual-new-code{font-family:ui-monospace,SFMono-Regular,Consolas,monospace;margin:10px 0 14px}
#commerce-readiness{overflow-wrap:anywhere}

/* Service QR remains untouched; close buttons are a simple cross with a transparent hit area. */
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .contact-dialog{border-color:var(--shop-border);border-radius:12px;background:#fff;color:var(--ink);box-shadow:0 20px 70px #34241024}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .contact-dialog::backdrop{background:#211b1666}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .contact-close{width:44px;height:44px;min-width:44px;padding:0;border:0;border-radius:8px;background:transparent;color:var(--muted);box-shadow:none}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) :is(.contact-caption,.contact-hint,.contact-qr figcaption,.contact-direct span){font-size:12px;color:var(--muted);line-height:1.8}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .contact-direct a{min-height:44px;background:var(--shop-soft);color:var(--shop-accent);font-size:14px}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .contact-qr{border-color:var(--shop-border)}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) footer{max-width:1216px;margin:0 auto;padding:24px 0 32px;border-color:var(--shop-border);color:var(--muted);font-size:12px}
body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .footer-brand{color:var(--ink);font-size:17px}

/* Hover is an enhancement for a precise pointing device, never the touch state. */
@media(hover:hover) and (pointer:fine){
 body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .topbar nav :is(a,button):hover{color:var(--shop-accent-dark)}
 .shop-main .primary:hover:enabled,.shop-main a.primary:hover,.product-dialog .primary:hover:enabled{background:#3b3026;border-color:#3b3026}
 .shop-main .secondary:hover:enabled,.shop-main a.secondary:hover{background:#f5f1eb;border-color:#a98e72}
 .shop-main .text-button:hover,.catalog-order-link:hover{color:var(--shop-accent-dark);text-decoration:underline;text-underline-offset:4px}
 .shop-benefits>a:hover{color:var(--shop-accent-dark)}
 .category-tabs :is(button,a):hover{background:#f4eee6;color:var(--shop-accent-dark)}
 .product-card:hover{border-color:#b99c7f;box-shadow:0 5px 16px #4b321407}
 .product-card.is-selected:hover{border-color:var(--shop-accent);box-shadow:inset 0 0 0 1px var(--shop-accent)}
 .shop-panel .pay-methods label:not(:has(input:disabled)):hover{border-color:var(--shop-accent);background:#fcf8f2}
 .product-dialog .dialog-close:hover{background:#f4f0ea;color:var(--shop-accent)}
 body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .contact-close:hover{background:#f4f0ea;color:var(--shop-accent)}
 body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .contact-direct a:hover{background:#ece2d5}
}

/* Responsive flow: three columns, then two, then a readable horizontal mobile card. */
@media(max-width:1100px){
 .shop-shell{grid-template-columns:166px minmax(0,1fr);gap:22px}
 .product-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
 .shop-admin-grid{grid-template-columns:minmax(280px,360px) minmax(0,1fr);gap:18px}
}
@media(max-width:900px){
 .shop-shell{grid-template-columns:minmax(0,1fr);gap:17px}
 .catalog-sidebar{padding:0;background:transparent}
 .catalog-sidebar>.mini-label,.catalog-order-link{display:none}
 .catalog-sidebar .category-tabs{display:flex;flex-wrap:nowrap;overflow-x:auto;gap:7px;max-width:100%;padding:4px;margin:-4px;scrollbar-width:thin;scroll-padding-inline:4px}
 .category-tabs :is(button,a,:where(.category-unavailable)){border-color:var(--shop-border);background:#fff;flex-shrink:0}
}
@media(max-width:760px){
 .shop-main{padding:20px 20px 48px}
 .shop-hero{padding:24px 0 22px}
 .shop-hero h1{font-size:30px;letter-spacing:-1px}
 .catalog-heading h1,.catalog-heading h2{font-size:23px}
 .catalog-tools{align-items:stretch;flex-direction:column;gap:12px}
 .catalog-search{flex:auto;width:100%;min-width:0}
 .shop-admin-grid{grid-template-columns:minmax(0,1fr)}
 .shop-panel{padding:24px;max-width:none}
 .shop-benefits{gap:16px}
 .shop-benefits .benefit-icon{display:none}
 .shop-promise{padding:24px}
 body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) footer{margin:0 20px;padding:22px 0 28px;flex-wrap:wrap;justify-content:space-between;text-align:left;font-size:12px}
 body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .footer-brand{width:auto}
}
@media(max-width:600px){
 body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .topbar{min-height:80px;padding:12px 16px;gap:8px 12px;flex-wrap:wrap}
 body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .topbar nav{width:100%;max-width:none;flex-basis:100%;justify-content:space-between;gap:8px;font-size:13px}
 body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .topbar nav :is(a,button){min-height:44px;padding:9px 0}
 body:is([data-page="shop"],[data-page="order"],[data-page="support"],[data-page="shop-admin"]) .brand{font-size:22px}
 .shop-main{padding:16px 16px 38px}
 .beta-banner{padding:9px 12px;gap:3px 12px;font-size:12px}
 body[data-page="shop"] .shop-hero{align-items:flex-start;flex-direction:column;gap:0;padding:18px 0 15px}
 body[data-page="shop"] .shop-hero .eyebrow{display:none}
 body[data-page="shop"] .shop-hero h1{font-size:28px;line-height:1.25;margin:5px 0 8px;letter-spacing:-.8px}
 body[data-page="shop"] .shop-hero p{font-size:13px;line-height:1.75}
 body[data-page="shop"] .shop-hero>.text-button{min-height:44px;margin:2px 0 0;padding:8px 0;font-size:13px}
 .shop-benefits{gap:12px;margin-bottom:20px;padding-bottom:18px}
 .shop-benefits>div,.shop-benefits>a{padding:3px 0;gap:0;align-items:flex-start}
 .shop-benefits strong{font-size:12px;line-height:1.55}
 .shop-benefits small{font-size:12px;line-height:1.55}
 .shop-benefits>a>span:last-child{display:none}
 .catalog-heading{align-items:flex-start;flex-direction:column;gap:12px;margin:0 0 16px}
 .catalog-heading h1,.catalog-heading h2{font-size:23px;margin-bottom:4px}
 .catalog-heading p,.catalog-summary{font-size:12px;line-height:1.65;margin:0;padding:0}
 .catalog-search{flex:auto;width:100%;min-width:0}
 .shop-main :is(input:not([type="radio"]):not([type="checkbox"]),select,textarea){font-size:16px;min-height:48px}
 body[data-page="shop"] .shop-main .catalog-search input{font-size:16px;height:46px;min-height:0}
 .product-grid{grid-template-columns:minmax(0,1fr);gap:12px}
 .product-card{padding:16px}
 .product-open{grid-template-columns:72px minmax(0,1fr);gap:14px}
 .product-visual{width:72px;height:76px}
 .product-card .product-image{width:64px;height:64px}
 .product-title,.product-card h2{font-size:16px;line-height:1.5}
 .product-tag,.product-meta{font-size:12px}
 .product-description{font-size:13px;line-height:1.7}
 .product-bottom{margin-top:13px;padding-top:3px;gap:12px}
 .product-price{font-size:24px}
 .product-card .primary{min-height:44px;font-size:13px;padding:10px 13px}
 .shop-panel,#checkout-panel{padding:22px 18px;border-radius:12px;margin-top:20px}
 .shop-panel h2{font-size:21px}
 .shop-panel .checkout-summary h2{font-size:19px}
 .shop-panel .pay-methods label{padding:12px 11px;gap:5px 8px;min-height:66px}
 .shop-main .primary,.shop-main .secondary,.product-dialog .primary{font-size:14px}
 .product-card .primary{font-size:13px}
 .shop-total strong{font-size:28px}
 .shop-promise{padding:21px 18px;margin-top:28px}
 .shop-promise h2{font-size:22px;line-height:1.5}
 .shop-promise summary strong{font-size:14px}
 .shop-promise p{font-size:14px;line-height:1.8}
 .product-dialog{padding:20px;width:calc(100vw - 28px);max-height:calc(100vh - 28px);max-height:calc(100dvh - 28px)}
 .product-dialog-overview{gap:16px;margin-bottom:22px}
 .product-dialog h2{font-size:22px;line-height:1.5}
 .product-dialog .product-price{font-size:26px}
 .detail-description{font-size:14px;line-height:1.85}
 .detail-delivery{padding:14px}
 .purchase-summary{grid-template-columns:1fr;gap:9px;padding:15px}
 #purchase-codes{padding:15px}
 .shop-main .delivered-code{font-size:16px;padding:12px}
 .mailbox-heading{align-items:flex-start;flex-direction:column;gap:7px}
 .mailbox-order{padding:16px;gap:12px}
 .mailbox-order h3{font-size:16px}
 .mailbox-order .secondary{width:100%}
 .admin-item{padding:18px}
 .admin-item h2{font-size:19px}
 .admin-filters{padding:14px;gap:9px}
 .admin-filters input,.admin-filters select,.admin-filters button{width:100%;flex:auto;min-width:0}
 .admin-item .item-actions{align-items:stretch;gap:8px}
 .admin-item .item-actions button{flex:1 1 130px}
 .admin-shop-nav{gap:7px}
 .admin-shop-nav .secondary{padding:10px 12px;font-size:13px}
 .support-links{gap:4px 18px}
 .read-status{align-items:flex-start;gap:10px;padding:13px 14px;font-size:13px}
 .read-status p{flex-basis:100%}
 .read-status .secondary{width:auto}
 .catalog-state[data-state="loading"] p{flex-basis:auto}
 .shop-main .feedback{font-size:14px;padding:13px 15px}
}
@media(max-width:359px){
 body:is([data-page="shop"],[data-page="order"],[data-page="support"]) .topbar nav{column-gap:5px;font-size:12px}
 .shop-main{padding-right:14px;padding-left:14px}
 .product-card{padding:14px}
 .product-open{grid-template-columns:64px minmax(0,1fr);gap:12px}
 .product-visual{width:64px;height:72px}
 .product-card .product-image{width:64px;height:64px}
 .product-title,.product-card h2{font-size:16px}
 .product-dialog-overview{grid-template-columns:80px minmax(0,1fr);gap:12px}
 .product-dialog .detail-image{width:80px;height:80px}
 .product-dialog h2{font-size:20px;line-height:1.45;letter-spacing:-.35px;word-break:keep-all}
 .product-dialog .product-price{font-size:22px;flex-wrap:nowrap;gap:4px;white-space:nowrap;letter-spacing:-.6px}
 .product-dialog .product-price small{font-size:12px;flex-shrink:0;white-space:nowrap}
 .shop-main .result-actions{display:grid;grid-template-columns:1fr}
 .shop-main .result-actions>*{width:100%;min-width:0}
 #purchase-codes :is(.primary,.secondary){width:100%;margin-right:0}
}
@media(prefers-reduced-motion:reduce){
 .shop-skip,.product-card,.promise-toggle,.shop-main :is(.primary,.secondary,input,textarea,select),.product-dialog :is(.primary,.dialog-close){transition:none;animation:none;scroll-behavior:auto}
}

/* Store catalogue and independent product view */
body[data-page="shop"] .shop-main{max-width:1240px;padding-top:22px}
body[data-page="shop"] .beta-banner{margin-bottom:22px}
body[data-page="shop"] .shop-shell{grid-template-columns:170px minmax(0,1fr);gap:28px;align-items:start}
body[data-page="shop"] .category-tabs{display:grid;gap:5px}
body[data-page="shop"] .category-tabs :is(button,a,:where(.category-unavailable)){min-height:44px;font-size:14px;padding:11px 14px;text-align:left;border-radius:8px}
body[data-page="shop"] .catalog-tagline{margin:0 0 5px;color:var(--shop-accent-dark);font-size:13px;font-weight:600;line-height:1.5}
body[data-page="shop"] a.product-open{text-decoration:none}
body[data-page="shop"] .catalog-heading{margin-bottom:20px}
body[data-page="shop"] .catalog-heading h1{font-size:27px;margin:0 0 6px;letter-spacing:-.5px}
body[data-page="shop"] .catalog-summary{font-size:13px}
body[data-page="shop"] .product-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;max-width:none}
body[data-page="shop"] .product-card{padding:0;display:block;border:1px solid #e5ddd2;border-radius:10px;background:#fff;overflow:hidden;min-width:0;box-shadow:none}
body[data-page="shop"] .product-card:hover{border-color:#b89976;transform:none}
body[data-page="shop"] .product-open{display:grid;width:100%;grid-template-columns:80px minmax(0,1fr);gap:12px;align-items:center;min-height:120px;padding:16px;text-align:left;background:transparent;border:0}
body[data-page="shop"] .product-visual{display:grid;place-items:center;width:80px;height:80px;background:transparent;border:0}
body[data-page="shop"] .product-card .product-image{width:80px;height:80px;object-fit:contain;border-radius:8px;background:#f8f5f0}
body[data-page="shop"] .product-info{display:grid;align-content:center;gap:8px;min-width:0}
body[data-page="shop"] .product-title{display:block;font-size:15px;font-weight:600;line-height:1.5;color:#29231e;overflow-wrap:anywhere}
body[data-page="shop"] .product-card .product-price{font-size:21px;line-height:1.2;margin:0;color:#6b472b;font-weight:650}
body[data-page="shop"] .product-badges{display:flex;flex-wrap:wrap;gap:5px;min-height:0}
.delivery-badge,.stock-badge{display:inline-flex;align-items:center;border:1px solid #e8dfd2;border-radius:5px;padding:3px 6px;font-size:11px;line-height:1.3;color:#6c5843;background:#faf7f2}
.stock-badge{color:#786d63;background:#f4f1ec}
body[data-page="shop"] .product-page{max-width:1120px;margin-inline:auto;padding-top:0}
body[data-page="shop"] .topbar .product-back{gap:5px;color:var(--ink);font-weight:600;white-space:nowrap}
body[data-page="shop"] .product-overview{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:28px;align-items:start}
body[data-page="shop"] .product-photo{display:grid;place-items:center;aspect-ratio:1;background:#fff;border:1px solid #e5ddd2;border-radius:12px;width:100%;padding:12px;max-height:none;overflow:hidden}
body[data-page="shop"] .product-photo img{display:block;width:100%;height:100%;max-width:none;max-height:none;object-fit:contain}
body[data-page="shop"] .product-photo .product-placeholder{font-size:90px;color:#8c6d4e}
body[data-page="shop"] #checkout-panel.product-purchase{padding:4px 0 0;margin:0;max-width:none;border:0;box-shadow:none;background:transparent}
body[data-page="shop"] .product-purchase h1{font-size:28px;line-height:1.35;letter-spacing:-.6px;margin:4px 0 10px;color:#241f1a;overflow-wrap:anywhere;outline:none}
body[data-page="shop"] .product-purchase .product-price{display:flex;align-items:baseline;gap:8px;margin:0 0 10px;color:#754f30}
body[data-page="shop"] .product-purchase .product-price strong{font-size:34px;line-height:1.3;font-weight:650}
body[data-page="shop"] .product-purchase .product-price small{font-size:13px;color:#6b6259;font-weight:400}
body[data-page="shop"] .product-facts{display:flex;flex-wrap:wrap;gap:12px;align-items:center;min-height:26px;margin-bottom:12px;color:#6b6259;font-size:13px}
body[data-page="shop"] #checkout-form{display:grid;gap:8px}
body[data-page="shop"] .manual-purchase-reminder{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;padding:10px 14px;margin-top:4px;border-radius:8px;background:#f7f0e6;color:#65452e}
body[data-page="shop"] .manual-purchase-reminder strong{font-size:14px;line-height:1.7;font-weight:600}
body[data-page="shop"] .manual-purchase-reminder button{min-height:44px;margin:0;font-size:14px;white-space:nowrap}
body[data-page="shop"] #checkout-form label{font-size:13px;margin:0}
body[data-page="shop"] .checkout-quantity{display:flex;justify-content:space-between;gap:20px;align-items:center;padding:6px 0;border-bottom:1px solid #e5ddd2;margin-bottom:2px}
body[data-page="shop"] .checkout-quantity input{width:74px;min-height:40px;height:40px;padding:8px 10px;text-align:center;background:#fff;border:1px solid #dfd5c7;border-radius:6px}
body[data-page="shop"] .checkout-quantity input:read-only{border-color:transparent;background:transparent;appearance:textfield;box-shadow:none}
body[data-page="shop"] #buyer-email-hint{margin:-3px 0 3px;font-size:12px}
body[data-page="shop"] .pay-methods{margin:4px 0 0;padding:0;gap:12px}
body[data-page="shop"] .pay-methods legend{font-size:13px;margin-bottom:8px}
body[data-page="shop"] #checkout-panel .pay-methods label{min-height:52px;font-size:14px;padding:12px 16px}
body[data-page="shop"] .shop-total{font-size:14px;margin:7px 0 0;padding-top:14px;border-top:1px solid #e5ddd2}
body[data-page="shop"] .shop-total strong{font-size:26px}
body[data-page="shop"] .consent{margin:5px 0;font-size:12px;align-items:flex-start}
body[data-page="shop"] .consent input{margin-top:4px}
body[data-page="shop"] .consent a{color:#6b472b;text-decoration:underline;text-underline-offset:3px}
body[data-page="shop"] #checkout-button{min-height:48px;width:100%;font-size:15px}
body[data-page="shop"] .product-description-section{margin-top:24px;border:1px solid #e5ddd2;background:#fff;padding:22px 24px;border-radius:12px}
body[data-page="shop"] .product-description-section>h2,.product-recommendations>h2{font-size:20px;margin:0 0 16px;color:#30261e}
body[data-page="shop"] .detail-description{font-size:14px;line-height:1.8;white-space:pre-line;color:#4d463f;margin:0}
body[data-page="shop"] .detail-description h3{font-size:15px;color:#4e3421;margin:18px 0 8px}
body[data-page="shop"] .detail-description h3:first-child{margin-top:0}
body[data-page="shop"] .detail-description p{margin:5px 0}
body[data-page="shop"] .product-recommendations{margin-top:32px}
body[data-page="shop"] .shop-promise{margin-top:30px;padding:20px 24px}
body[data-page="order"] .order-main{max-width:880px}
body[data-page="order"] .order-page-title{font-size:29px;line-height:1.4;margin:26px 0 22px;color:#29231e}
body[data-page="order"] .shop-panel{max-width:none;margin:20px 0;padding:26px}
body[data-page="order"] #purchase-codes{margin:20px 0 14px}
body[data-page="order"] .purchase-code-heading{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:6px 12px;margin-bottom:8px}
body[data-page="order"] .purchase-code-heading label{margin:0}
body[data-page="order"] .code-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap;margin-left:auto}
body[data-page="order"] #purchase-codes .code-actions :is(.primary,.secondary){margin:0;width:auto;min-height:40px;padding:7px 12px;font-size:13px;white-space:nowrap}
body[data-page="order"] .purchase-copy-control{display:flex;align-items:center;flex-wrap:wrap;gap:6px 10px;min-width:0}
body[data-page="order"] .purchase-copy-control :is(.purchase-copy-status,.text-button){margin-top:6px}
body[data-page="order"] .purchase-copy-status{font-size:12px;line-height:1.6;color:var(--muted);max-width:260px}
body[data-page="order"] .purchase-copy-status[data-state="success"]{color:#366644}
body[data-page="order"] .otp-copy-panel{max-width:440px}
body[data-page="order"] .otp-copy-panel h2{margin:0 0 12px}
body[data-page="order"] .otp-copy-controls{display:flex;align-items:stretch;gap:10px;margin:14px 0}
body[data-page="order"] .otp-copy-controls textarea{flex:1;min-width:0;min-height:48px;margin:0;font:600 19px/1.4 ui-monospace,monospace;letter-spacing:.18em;resize:none}
body[data-page="order"] .otp-copy-controls .primary{flex:none;min-height:48px;margin:0;padding:8px 16px}
body[data-page="order"] #otp-copy-status[data-state="success"]{color:#366644}
body[data-page="order"] .manual-order-next{display:grid;gap:10px;max-width:440px;margin:18px 0;padding:16px;border:1px solid var(--shop-border);border-radius:10px;background:var(--shop-soft)}
body[data-page="order"] .manual-order-next h3{margin:0;font-size:16px;line-height:1.6}
body[data-page="order"] .manual-order-next p{margin:0;color:var(--muted);font-size:13px}
body[data-page="order"] .manual-order-next .primary{width:fit-content;min-height:44px;padding:10px 18px}
body[data-page="order"] .purchase-summary{font-size:13px;margin:20px 0}
body[data-page="order"] .order-search form{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;align-items:start}
body[data-page="order"] .order-search :is(form label,.field-error,.order-search-note,.history-code-tools){grid-column:1/-1}
body[data-page="order"] .order-search form .primary{min-height:48px;margin:0;padding:12px 22px}
body[data-page="order"] .order-search-note{margin:0 0 3px;overflow-wrap:anywhere}
body[data-page="order"] #find-code{font-variant-numeric:tabular-nums}
body[data-page="order"] .history-code-tools{display:flex;align-items:center;flex-wrap:wrap;gap:4px 16px}
body[data-page="order"] .history-code-tools .text-button{min-height:44px}
body[data-page="order"] .mailbox-summary{margin:10px 0 0;color:var(--ink);font-size:14px;font-weight:550;line-height:1.75}
body[data-page="order"] .mailbox-list:empty{display:none}
@media(max-width:1050px){body[data-page="shop"] .product-grid{grid-template-columns:repeat(2,minmax(0,1fr))}body[data-page="shop"] .product-overview{gap:24px}}
@media(max-width:700px){
 body[data-page="shop"] .shop-main{padding:16px 16px 36px}
 body[data-page="shop"] .shop-shell{grid-template-columns:1fr;gap:18px}
 body[data-page="shop"] .catalog-sidebar{position:static;margin:0;padding:0;border:0;background:none}
 body[data-page="shop"] .category-tabs{display:flex;gap:6px;overflow-x:auto;padding-bottom:3px}
 body[data-page="shop"] .category-tabs :is(button,a,:where(.category-unavailable)){flex:0 0 auto;font-size:13px;min-height:44px;white-space:nowrap;padding:10px 13px}
 body[data-page="shop"] .catalog-order-link{display:none}
 body[data-page="shop"] .catalog-heading{display:flex;align-items:flex-start;gap:14px}
 body[data-page="shop"] .catalog-heading h1{font-size:25px}
 body[data-page="shop"] .product-grid{grid-template-columns:1fr;gap:10px}
 body[data-page="shop"] .product-open{min-height:112px;grid-template-columns:76px minmax(0,1fr);padding:14px;gap:14px}
 body[data-page="shop"] .product-visual,body[data-page="shop"] .product-card .product-image{width:76px;height:76px}
 body[data-page="shop"] .product-title{font-size:16px}
 body[data-page="shop"] .product-card .product-price{font-size:22px}
 body[data-page="shop"] .product-overview{grid-template-columns:1fr;gap:16px}
 body[data-page="shop"] .product-photo{width:min(100%,360px);justify-self:center;padding:10px}
 body[data-page="shop"] .product-purchase h1{font-size:25px;margin:6px 0 13px}
 body[data-page="shop"] .product-purchase .product-price strong{font-size:32px}
 body[data-page="shop"] .product-facts{margin-bottom:12px}
 body[data-page="shop"] .checkout-quantity input{font-size:16px;width:74px;min-height:44px}
 body[data-page="shop"] .product-description-section{padding:20px 18px;margin-top:20px}
 body[data-page="shop"] .detail-description{font-size:14px;line-height:1.9}
 body[data-page="shop"] .shop-promise{padding:20px 18px}
 body[data-page="order"] .shop-panel{padding:22px 18px}
 body[data-page="order"] .order-search form{grid-template-columns:1fr}
 body[data-page="order"] .order-search form .primary{width:100%}
 body[data-page="order"] .order-page-title{font-size:26px}
}
body[data-page="shop"] .quantity-control{display:inline-flex;align-items:center;border:1px solid #d9cdbd;border-radius:7px;background:#fff;overflow:hidden;flex-shrink:0}
body[data-page="shop"] .quantity-step{display:grid;place-items:center;min-width:42px;min-height:42px;padding:7px;background:#faf7f2;color:#5b402a;font-size:20px;line-height:1;border:0;border-radius:0}
body[data-page="shop"] .quantity-step:disabled{color:#b2a99e;opacity:.6;cursor:default}
body[data-page="shop"] .quantity-step:hover:enabled{background:#eee4d6}
body[data-page="shop"] .quantity-control #buy-quantity{width:52px;height:42px;min-height:42px;padding:7px 2px;border:0;border-right:1px solid #e6ddd2;border-left:1px solid #e6ddd2;border-radius:0;appearance:textfield;box-shadow:none;background:#fff;font-size:15px;text-align:center;color:#29231e}
body[data-page="shop"] .quantity-control #buy-quantity::-webkit-inner-spin-button,body[data-page="shop"] .quantity-control #buy-quantity::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
@media(max-width:700px){body[data-page="shop"] .quantity-step{min-width:44px;min-height:44px}body[data-page="shop"] .quantity-control #buy-quantity{font-size:16px;height:44px;min-height:44px}}
/* Payment brands and a stable scan surface */
.payment-icon{display:inline-block;flex:0 0 auto;vertical-align:middle;width:28px;height:28px}
.payment-icon-wechat{width:32px;height:27px}
body[data-page="shop"] #checkout-panel .pay-methods label{display:flex;align-items:center;justify-content:center;gap:9px;flex-wrap:nowrap}
.payment-scan{box-sizing:border-box;width:100%;max-width:304px;margin:18px auto;padding:16px 14px 14px;border:1px solid #e4d9cb;border-radius:12px;background:#fff;text-align:center}
.payment-scan>.payment-deadline{margin:0 0 12px;color:#756653;font-size:12px;line-height:1.5;font-variant-numeric:tabular-nums}
.payment-brand-heading{display:flex;align-items:center;justify-content:center;gap:8px;margin:0 0 12px}
.payment-brand-heading .payment-icon{width:22px;height:22px}
.payment-brand-heading .payment-icon-wechat{width:26px;height:22px}
.payment-brand-heading h3{font-size:16px;line-height:1.5;margin:0;color:#302820;font-weight:600}
.payment-method-panel{min-width:0;max-width:100%;margin:0 auto}
.payment-method-panel canvas{display:block;width:240px!important;height:240px!important;max-width:100%;margin:0 auto;background:#fff}
.payment-method-panel .alipay-cashier{display:block;width:240px;max-width:100%;height:248px;margin:0 auto;border:0;background:#fff}
.payment-method-panel>.field-note{font-size:12px;line-height:1.5;margin:8px 0}
.payment-method-panel .payment-scan-instruction{font-size:12px;color:#594d40;margin:8px 0 10px;line-height:1.5}
.payment-method-panel .secondary{display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:9px 16px}
#purchase-payment>.payment-auto-status{min-height:0;margin:8px 0 0;font-size:12px;line-height:1.5;color:#756653}
#purchase-refresh[aria-busy="true"]{cursor:wait;opacity:.65}
@media(max-width:359px){body[data-page="order"] #purchase-detail{padding:20px 12px}.payment-scan{padding:14px 12px 12px}}

/* Keep secondary order actions separate without changing product proportions. */
.mailbox-actions{display:flex;align-items:center;flex-wrap:wrap;gap:12px;margin-top:20px}
@media(max-width:700px){
 body[data-page="shop"] #checkout-form{gap:12px}
 body[data-page="shop"] #checkout-button{margin-top:4px}
 #support-code-field>label{margin-bottom:10px}
 .support-links{gap:12px 18px}
 .mailbox-actions{display:grid;grid-template-columns:1fr;gap:12px}
 .mailbox-actions>button{width:100%;min-height:48px}
}
