/* The Storefront settings page (W11.B2) and the public store page. Every selector starts with cce-sf-, cce-store-,
   cce-pager, cce-sort or cce-chip. The seller shell (merchant-shell.css) supplies the avatar, the copy button and the
   buttons of the seller bar. No external fonts. Touch targets are 44px. */

/* The hidden attribute always wins over the classes below. */
[hidden] { display: none !important; }

/* Settings page: two columns, the right column drops below the main column at 1040px. */
.cce-storefront-settings { color: #232529; padding: 24px 16px 64px; max-width: 1200px; margin: 0 auto; }
.cce-sf-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 12px 16px; margin-bottom: 16px; }
.cce-sf-title { font-size: 1.75rem; font-weight: 800; margin: 0 0 4px; }
.cce-sf-sub { margin: 0; color: #4b5563; }
.cce-sf-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
.cce-sf-main, .cce-sf-side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.cce-sf-card { background: #fff; border: 1px solid #e3e8ef; border-radius: 10px; padding: 16px; }
.cce-sf-h2 { font-size: 1.1rem; font-weight: 700; margin: 0 0 8px; }
.cce-sf-card-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.cce-sf-card-head .cce-sf-h2 { margin: 0; }
.cce-sf-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.cce-sf-label { font-weight: 700; }
.cce-sf-input { width: 100%; min-height: 44px; padding: 8px 10px; border: 1px solid #aeb6c2; border-radius: 6px; font: inherit; background: #fff; color: #232529; box-sizing: border-box; }
.cce-sf-input[aria-invalid='true'] { border-color: #9A3A12; }
.cce-sf-textarea { min-height: 132px; resize: vertical; }
.cce-sf-help { font-size: 0.9rem; color: #4b5563; margin: 0; }
.cce-sf-help a, .cce-sf-policy a, .cce-sf-card a { color: #2E4A82; }
.cce-sf-msg { font-size: 0.9rem; min-height: 0; margin: 0; }
.cce-sf-msg:empty { display: none; }
.cce-sf-msg-err { color: #C00000; font-weight: 700; }
/* The failed-save dialog's list of problems. */
.cce-sf-errlist { padding-left: 1.2rem; margin: 0; }
.cce-sf-errlist li { margin-bottom: 0.5rem; }
.cce-sf-errlist .cce-sf-msg-err { color: #C00000; font-weight: 700; }

/* Logo row. The file input is visually hidden but stays in the label, so the label is the real control. */
.cce-sf-logo-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.cce-sf-avatar { width: 72px; height: 72px; flex: 0 0 72px; font-size: 1.4rem; }
.cce-sf-logo-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.cce-sf-upload { cursor: pointer; }
.cce-sf-visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; padding: 0; margin: -1px; }
.cce-sf-upload:focus-within { outline: 3px solid #E48A3D; outline-offset: 2px; }
.cce-sf-textbtn { background: none; border: 0; color: #2E4A82; text-decoration: underline; min-height: 44px; padding: 0 4px; font: inherit; cursor: pointer; }

/* Resources card. */
.cce-sf-res-list { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-direction: column; }
.cce-sf-res { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; padding: 12px 0; border-top: 1px solid #eef1f5; }
.cce-sf-res-left { display: flex; align-items: flex-start; gap: 12px; min-width: 0; flex: 1 1 240px; }
.cce-sf-res-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cce-sf-res-title { font-weight: 700; overflow-wrap: anywhere; }
.cce-sf-res-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 0.9rem; color: #4b5563; }
.cce-sf-res-locked { background: #faf9f7; }
.cce-sf-thumb { display: inline-block; width: 48px; height: 64px; flex: 0 0 48px; border-radius: 4px; background: #eef1f5; object-fit: cover; }
.cce-sf-chip, .cce-chip { display: inline-block; font-size: 0.8rem; font-weight: 600; border-radius: 999px; padding: 2px 8px; background: #eef1f5; color: #232529; }
.cce-chip-green { background: #E3F0DA; color: #2F5E22; }
.cce-chip-amber { background: #FBE7CF; color: #7A3E0B; }
.cce-chip-red { background: #F6DDD2; color: #7A2A0C; }
.cce-chip-grey { background: #eef1f5; color: #374151; }

/* The switch: a button with role switch. Its colour follows aria-pressed, the text says On or Off. */
.cce-sf-switch { min-width: 84px; min-height: 44px; padding: 6px 14px; border: 1px solid #aeb6c2; border-radius: 999px; background: #fff; color: #232529; font: inherit; font-weight: 700; cursor: pointer; }
.cce-sf-switch[aria-pressed='true'], .cce-sf-switch-on { background: #5A8F3F; border-color: #5A8F3F; color: #fff; }
.cce-sf-switch:focus-visible, .cce-sf-textbtn:focus-visible, .cce-sf-btn-ghost:focus-visible, .cce-sf-btn-primary:focus-visible,
.cce-sf-upload:focus-within, .cce-store-btn:focus-visible, .cce-store-share:focus-visible, .cce-store-ownerlink:focus-visible,
.cce-sort select:focus-visible, .cce-pager a:focus-visible, .cce-sf-card a:focus-visible,
.cce-sf-help a:focus-visible, .cce-sf-policy a:focus-visible {
    outline: 3px solid #E48A3D;
    outline-offset: 2px;
}


/* Definition lists (seller information, payout method). */
.cce-sf-dl { margin: 0 0 12px; display: flex; flex-direction: column; gap: 8px; }
.cce-sf-dl > div { display: grid; grid-template-columns: minmax(96px, 35%) 1fr; gap: 8px; }
.cce-sf-dl dt { color: #4b5563; font-weight: 600; }
.cce-sf-dl dd { margin: 0; overflow-wrap: anywhere; }
.cce-sf-payout-action { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }

/* Coming soon card. */
.cce-sf-soon { background: #faf9f7; }
.cce-sf-soon-tag { display: inline-block; font-size: 0.75rem; font-weight: 700; background: #eef1f5; color: #4b5563; border-radius: 4px; padding: 0 6px; }

/* Buttons used by the settings page and the public page. */
.cce-sf-btn-primary, .cce-store-btn-primary, .btn-primary.cce-store-btn { background: #E48A3D; border: 1px solid #C9731F; color: #232529; font-weight: 700; }
.cce-sf-btn-primary, .cce-sf-btn-ghost, .cce-store-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 6px 14px; border-radius: 6px; font: inherit; cursor: pointer; text-decoration: none; }
.cce-sf-btn-primary:disabled { opacity: 0.55; cursor: not-allowed; }
.cce-sf-btn-ghost { background: #fff; border: 1px solid #aeb6c2; color: #232529; }
.cce-store-btn { background: #fff; border: 1px solid #d7dde5; color: #232529; }

/* Unsaved bar: sticky at the bottom of the screen while the form has changes. */
.cce-sf-savebar { position: sticky; bottom: 0; z-index: 5; margin-top: 16px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; background: #232529; color: #fff; border-radius: 10px; padding: 12px 16px; }
.cce-sf-savebar-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.cce-sf-savebar .cce-sf-btn-ghost { background: transparent; border-color: #fff; color: #fff; }
.cce-sf-savebar .cce-sf-btn-primary { background: #E48A3D; }

/* Toast: an empty toast is not shown. */
.cce-sf-toast { margin-top: 16px; background: #E3F0DA; color: #2F5E22; border-radius: 8px; padding: 10px 14px; font-weight: 600; }
.cce-sf-toast:empty { display: none; }
/* A refused save: strong red and bold, never the saved green. */
.cce-sf-toast[data-state='error'] { background: #FDECEC; color: #C00000; font-weight: 700; border: 1px solid #C00000; }

.cce-sf-policy { padding: 0 4px; }

/* Store links: the six link fields of the details card and the list of filled-in links in the preview. */
.cce-sf-links { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.cce-sf-link { margin-bottom: 8px; }

/* Public store page. */
.cce-store-page { color: #232529; padding: 16px 16px 64px; max-width: 1200px; margin: 0 auto; }
.cce-store-ownerbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; background: #232529; color: #fff; border-radius: 8px; padding: 10px 14px; margin-bottom: 16px; }
.cce-store-ownerlink { color: #fff; font-weight: 700; text-decoration: underline; min-height: 44px; display: inline-flex; align-items: center; }
.cce-store-header { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 16px; background: #fff; border: 1px solid #e3e8ef; border-radius: 10px; padding: 20px; margin-bottom: 24px; }
.cce-store-header .cce-shell-avatar, .cce-store-header .cce-shell-avatar-img { width: 72px; height: 72px; flex: 0 0 72px; font-size: 1.4rem; }
.cce-store-id { flex: 1 1 260px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.cce-store-name { font-size: 1.6rem; font-weight: 800; margin: 0; overflow-wrap: anywhere; }
.cce-store-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; color: #4b5563; margin: 0; font-size: 0.95rem; }
.cce-store-sep { display: inline-block; width: 4px; height: 4px; border-radius: 50%; background: #aeb6c2; }
.cce-store-about { margin: 4px 0 0; white-space: normal; overflow-wrap: anywhere; }
.cce-store-share { align-self: flex-start; }
.cce-store-links { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.cce-store-link { display: inline-flex; align-items: center; min-height: 44px; max-width: 100%; box-sizing: border-box; padding: 6px 14px; border: 1px solid #d7dde5; border-radius: 999px; background: #fff; color: #2E4A82; font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.cce-store-link:hover { background: #eef1f5; }
.cce-store-link:focus-visible { outline: 3px solid #E48A3D; outline-offset: 2px; }
.cce-store-res-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; margin-bottom: 12px; }
.cce-store-h2 { font-size: 1.3rem; font-weight: 800; margin: 0; }
.cce-sort-form { margin: 0; }
.cce-sort { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cce-sort select { min-height: 44px; padding: 6px 10px; border: 1px solid #aeb6c2; border-radius: 6px; font: inherit; background: #fff; }
.cce-store-unavailable, .cce-store-empty { background: #fff; border: 1px solid #e3e8ef; border-radius: 10px; padding: 24px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.cce-store-unavailable p, .cce-store-empty p { margin: 0; color: #4b5563; }
.cce-pager { margin-top: 24px; }
.cce-pager-list { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; justify-content: center; }
.cce-pager-list a, .cce-pager-list span { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 0 10px; border: 1px solid #d7dde5; border-radius: 6px; color: #232529; text-decoration: none; background: #fff; }
.cce-pager-current { background: #232529 !important; color: #fff !important; font-weight: 700; }
.cce-pager-off { color: #9ca3af; }

/* The breakpoint: below 1040px the right column drops under the main column. */
@media (max-width: 1040px) {
    .cce-sf-grid { grid-template-columns: minmax(0, 1fr); }
}

/* Phones: 16px side gutters, stacked buttons, no horizontal page scroll. */
@media (max-width: 760px) {
    .cce-storefront-settings, .cce-store-page { padding-left: 16px; padding-right: 16px; }
    .cce-sf-head { flex-direction: column; }
    .cce-sf-dl > div { grid-template-columns: 1fr; gap: 2px; }
    .cce-sf-res-left { flex-basis: 100%; }
    .cce-sf-savebar { position: sticky; }
    .cce-store-header { padding: 16px; }
    .cce-store-share { width: 100%; justify-content: center; }
}

/* Touch: 44px targets on coarse pointers. */
@media (pointer: coarse) {
    .cce-sf-switch, .cce-sf-textbtn, .cce-store-btn, .cce-sf-btn-ghost, .cce-sf-btn-primary { min-height: 44px; }
}

@media (prefers-reduced-motion: reduce) {
    .cce-sf-switch, .cce-store-btn, .cce-sf-btn-ghost, .cce-sf-btn-primary { transition: none; }
}

/* Public store header (T11, design decisions 1-3 and 24). The banner, the white card that overlaps it, the avatar, the
   icon link buttons and Share. Colours are the tokens of cce-theme.css. These rules replace the legacy header rules above for the new markup. */
.cce-store-header { position: relative; display: block; background: none; border: 0; padding: 0; margin-bottom: 24px; }
.cce-banner { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; overflow: hidden; aspect-ratio: 6 / 1; padding: 0 5%; text-align: center; border-radius: var(--cce-radius-card); background-color: var(--cce-picture-bg); background-repeat: no-repeat; }
.cce-banner-tagline, .cce-banner-subtitle { position: relative; z-index: 1; margin: 0; max-width: 100%; overflow-wrap: anywhere; }
.cce-banner-tagline { font-size: clamp(1.5rem, 4vw, 3rem); font-weight: 700; line-height: 1.1; }
.cce-banner-subtitle { margin-top: 0.35em; font-size: clamp(1rem, 2.2vw, 1.5rem); line-height: 1.3; }
.cce-has-outline { -webkit-text-stroke: var(--cce-outline-width) var(--cce-outline-color); paint-order: stroke fill; }
.cce-store-card { position: relative; z-index: 1; display: flex; flex-wrap: wrap; align-items: flex-start; gap: 12px 20px; margin: -48px 20px 0; padding: 16px 20px; background: var(--cce-surface); border: 1px solid var(--cce-line); border-radius: var(--cce-radius-card); box-shadow: var(--cce-shadow-card); }
.cce-store-card .cce-store-id { flex: 1 1 260px; }
.cce-store-name { color: var(--cce-ink); }
.cce-store-meta { color: var(--cce-muted); }
.cce-store-intro { margin: 0; color: var(--cce-text); overflow-wrap: anywhere; }
.cce-store-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-left: auto; }
.cce-avatar { position: relative; flex: 0 0 112px; width: 112px; height: 112px; margin-top: -64px; background: var(--cce-line); }
/* The avatar is three layers cut to the same shape (each clip-path is relative to its own box, so the shapes nest):
   the outer box is the thin border, the pad the white band, the picture inside it (owner, 2026-11-19: no ring showed). */
.cce-avatar--circle, .cce-avatar--circle .cce-avatar-pad, .cce-avatar--circle .cce-avatar-img { clip-path: circle(50%); }
.cce-avatar--square, .cce-avatar--square .cce-avatar-pad, .cce-avatar--square .cce-avatar-img { clip-path: none; }
/* The star is two overlapping squares, one turned 45 degrees (owner, 2026-11-19): it leaves room for the picture. */
.cce-avatar--star, .cce-avatar--star .cce-avatar-pad, .cce-avatar--star .cce-avatar-img { clip-path: polygon(50% 0%, 64.64% 14.64%, 85.36% 14.64%, 85.36% 35.36%, 100% 50%, 85.36% 64.64%, 85.36% 85.36%, 64.64% 85.36%, 50% 100%, 35.36% 85.36%, 14.64% 85.36%, 14.64% 64.64%, 0% 50%, 14.64% 35.36%, 14.64% 14.64%, 35.36% 14.64%); }
.cce-avatar--hexagon, .cce-avatar--hexagon .cce-avatar-pad, .cce-avatar--hexagon .cce-avatar-img { clip-path: polygon(25% 0%, 75% 0%, 100% 50%, 75% 100%, 25% 100%, 0% 50%); }
.cce-avatar-pad { position: absolute; inset: 2px; background: var(--cce-surface); }
.cce-avatar-img { position: absolute; inset: 6px; background-color: var(--cce-picture-bg); background-repeat: no-repeat; }
.cce-avatar-initials { display: flex; align-items: center; justify-content: center; background-color: var(--cce-primary-tint); color: var(--cce-ink); font-size: 2rem; font-weight: 800; }
.cce-store-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.cce-store-link { width: 44px; height: 44px; min-height: 44px; padding: 0; justify-content: center; border: 1px solid var(--cce-line); border-radius: var(--cce-radius-pill); background: var(--cce-surface); color: var(--cce-primary); }
.cce-store-link:hover { background: var(--cce-primary-tint); }
.cce-store-share { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; margin-left: auto; padding: 0 16px; border: 1px solid var(--cce-primary); border-radius: var(--cce-radius-pill); background: var(--cce-surface); color: var(--cce-primary); font-weight: 700; cursor: pointer; }
.cce-store-share:hover { background: var(--cce-primary-tint); }
.cce-store-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; align-items: start; }
.cce-store-main { min-width: 0; display: flex; flex-direction: column; gap: 16px; order: 0; }

/* Side column (T14, design decisions 12, 13 and 24). Below 992px the aside is not a box: its sections and the idea box
   become items of the body. About the store comes first, above the resources, where a phone shopper finds it; Browse
   resources is hidden, the filters above the list do its job (#6566); the idea box sits right under the resources. At
   992px and up the aside is the 280px column on the left. */
.cce-store-side { min-width: 0; display: contents; }
.cce-store-side > .cce-section { order: 2; }
.cce-store-side > .cce-section:has(#cce-store-about-panel) { order: -1; }
.cce-store-idea { order: 1; }
@media (max-width: 991.98px) {
    .cce-store-side > .cce-section:has(#cce-store-topics-panel) { display: none; }
}
.cce-store-topics { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.cce-store-topic { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 6px 10px; border-radius: 8px; color: var(--cce-text); text-decoration: none; }
.cce-store-topic:hover { background: var(--cce-picture-bg); color: var(--cce-ink); }
.cce-store-topic.is-selected { background: var(--cce-primary-tint); color: var(--cce-ink); font-weight: 700; }
.cce-store-topic:focus-visible, .cce-store-readmore:focus-visible, .cce-store-idea:focus-visible, .cce-store-explore a:focus-visible { outline: 3px solid var(--cce-primary); outline-offset: 2px; }
.cce-store-topic-name { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.cce-store-topic-count { flex: 0 0 auto; color: var(--cce-muted); font-weight: 600; }
.cce-store-side .cce-store-about { margin: 0; color: var(--cce-text); }
.cce-store-side .cce-store-about p { margin: 0 0 8px; }
.cce-store-readmore { display: inline-flex; align-items: center; min-height: 44px; color: var(--cce-primary); font-weight: 700; text-decoration: none; }
.cce-store-idea { display: block; margin-top: 16px; padding: 16px; border-radius: var(--cce-radius-card); background: var(--cce-cream); color: var(--cce-text); text-decoration: none; }
.cce-store-idea:hover { color: var(--cce-ink); }
.cce-store-idea-h { display: block; margin-bottom: 4px; font-size: 1.1rem; font-weight: 800; color: var(--cce-ink); }
.cce-store-idea-body { display: block; }
.cce-store-explore { margin: 24px 0 0; text-align: center; }
.cce-store-clear { margin-top: 12px; }
.cce-store-explore a { display: inline-flex; align-items: center; min-height: 44px; color: var(--cce-primary); font-weight: 700; text-decoration: none; }
.cce-store-aboutpage { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; padding: 24px; background: var(--cce-surface); border: 1px solid var(--cce-line); border-radius: var(--cce-radius-card); }
.cce-store-about-text { color: var(--cce-text); overflow-wrap: anywhere; }
.cce-store-about-empty { margin: 0; color: var(--cce-muted); }
@media (min-width: 992px) {
    .cce-store-body { grid-template-columns: 280px minmax(0, 1fr); }
    .cce-store-side { display: block; }
    .cce-store-side > .cce-section, .cce-store-idea { order: 0; }
}
/* Below desktop a 6:1 band has no room for the headline: a taller box the picture covers, from the centre of the
   seller's frame (--cce-banner-focus, the picture's centre for a stock banner), so the text sits on the same part of the
   picture as on desktop. The 6:1 frame cannot fill a taller box, so its size is not used; !important outranks the
   frame's inline style. */
@media (max-width: 991.98px) {
    .cce-banner { aspect-ratio: 4 / 1; background-size: cover !important; background-position: var(--cce-banner-focus, center) !important; }
}
@media (max-width: 767.98px) {
    /* The text is centred on the banner, as on desktop (Gitea 6566: with room left for the card only at the bottom it
       sat above the spot it has on desktop). The card and avatar cover the banner's bottom 48px, so 48px is kept clear at
       the bottom AND the top (the centre stays the centre), and a long headline grows the box past 16:9 instead of
       running under the card (overflow visible lets the aspect ratio give way to the text). */
    .cce-banner { aspect-ratio: 16 / 9; justify-content: center; padding-top: 48px; padding-bottom: 48px; overflow: visible; }
    .cce-banner-tagline { font-size: clamp(1.4rem, 7.5vw, 2rem); }
    .cce-banner-subtitle { margin-top: 0.25em; font-size: clamp(0.95rem, 4.4vw, 1.2rem); }
    .cce-store-card { margin: -32px 12px 0; padding: 12px 14px; }
    .cce-avatar { flex-basis: 72px; width: 72px; height: 72px; margin-top: -16px; }
    .cce-avatar-img { inset: 4px; }
    .cce-store-share { min-height: 44px; }
    .cce-store-share-text { display: none; }
    .cce-store-share { width: 44px; padding: 0; justify-content: center; }
}

/* Store look editor (T12). Tokens only: no colour here is a literal, the tokens live in cce-theme.css. */
.cce-look-layout { display: flex; flex-direction: column; gap: 12px; }
.cce-look-layout > .cce-section:first-child { background: var(--cce-surface); }
@media (min-width: 992px) {
    .cce-look-layout > .cce-section:first-child { position: sticky; top: 8px; z-index: 2; }
}
.cce-look-preview { border: 1px solid var(--cce-line); border-radius: var(--cce-radius-card); overflow: hidden; background: var(--cce-picture-bg); }
.cce-look-preview .cce-store-header { margin: 0; }
.cce-look-group { border: 0; margin: 0 0 12px; padding: 0; min-width: 0; }
.cce-look-legend { font-size: 0.95rem; font-weight: 700; color: var(--cce-ink); margin: 0 0 6px; padding: 0; }
.cce-look-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; min-width: 0; }
.cce-look-count { font-size: 0.85rem; color: var(--cce-muted); }
.cce-look-stocks { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.cce-look-stock { display: flex; flex-direction: column; gap: 4px; margin: 0; padding: 6px; border: 1px solid var(--cce-line); border-radius: var(--cce-radius-card); background: var(--cce-surface); cursor: pointer; min-width: 0; }
.cce-look-stock img { width: 100%; height: auto; border-radius: 8px; display: block; }
.cce-look-stock span { font-size: 0.85rem; color: var(--cce-text); }
.cce-look-stock:has(input:checked) { border-color: var(--cce-primary); background: var(--cce-primary-tint); }
.cce-look-stock input[type='radio'], .cce-look-radio input[type='radio'], .cce-look-shape-choice input[type='radio'] { min-width: 20px; min-height: 20px; margin-right: 4px; accent-color: var(--cce-primary); }
.cce-look-radios { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.cce-look-radio { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; color: var(--cce-text); }
.cce-look-radio:has(input:disabled) { color: var(--cce-muted); }
.cce-look-shapes { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.cce-look-shape-choice { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; cursor: pointer; color: var(--cce-text); font-weight: 600; }
.cce-look-shape { display: inline-block; width: 36px; height: 36px; background: var(--cce-primary); }
.cce-look-shape--circle { clip-path: circle(50%); }
.cce-look-shape--square { clip-path: none; }
.cce-look-shape--star { clip-path: polygon(50% 0%, 64.64% 14.64%, 85.36% 14.64%, 85.36% 35.36%, 100% 50%, 85.36% 64.64%, 85.36% 85.36%, 64.64% 85.36%, 50% 100%, 35.36% 85.36%, 14.64% 85.36%, 14.64% 64.64%, 0% 50%, 14.64% 35.36%, 14.64% 14.64%, 35.36% 14.64%); }
.cce-look-shape--hexagon { clip-path: polygon(25% 0%, 75% 0%, 100% 50%, 75% 100%, 25% 100%, 0% 50%); }

/* Store toolbar, search, filters and sort (T15, design decisions 12, 19 and 24). The one GET form over the resource
   list. Tokens only: no colour here is a literal. */
.cce-store-toolbar { display: flex; flex-direction: column; gap: 12px; margin: 0; min-width: 0; }
.cce-store-toolbar .cce-store-res-head { margin-bottom: 0; }
.cce-store-count { margin: 0; color: var(--cce-muted); font-size: 0.95rem; }
.cce-store-res-head .cce-view-switch { margin-left: auto; }
.cce-store-search { display: flex; flex-wrap: wrap; align-items: stretch; gap: 8px; }
.cce-store-input { flex: 1 1 240px; min-width: 0; min-height: 44px; padding: 8px 16px; border: 1px solid var(--cce-line); border-radius: var(--cce-radius-pill); background: var(--cce-surface); color: var(--cce-text); font: inherit; box-sizing: border-box; }
.cce-store-search .cce-store-btn-primary { min-width: 96px; padding: 0 22px; border: 1px solid var(--cce-primary); border-radius: var(--cce-radius-pill); background: var(--cce-primary); color: var(--cce-surface); font-weight: 700; }
.cce-store-filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px 12px; }
.cce-store-sort { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px 12px; margin-top: 12px; }
.cce-store-field { display: flex; flex: 1 1 150px; flex-direction: column; gap: 4px; min-width: 0; color: var(--cce-text); font-size: 0.9rem; }
.cce-store-field-label { font-weight: 600; color: var(--cce-muted); }
.cce-store-field select { width: 100%; min-width: 0; min-height: 44px; max-width: 100%; padding: 6px 12px; border: 1px solid var(--cce-line); border-radius: var(--cce-radius-pill); background: var(--cce-surface); color: var(--cce-ink); font: inherit; box-sizing: border-box; }
.cce-store-sort .cce-store-field { flex: 0 1 260px; }
.cce-store-toolbar select:focus-visible, .cce-store-input:focus-visible, .cce-store-search .cce-store-btn-primary:focus-visible {
    outline: 3px solid var(--cce-primary);
    outline-offset: 2px;
}
.cce-store-nomatch { background: var(--cce-surface); border: 1px solid var(--cce-line); border-radius: var(--cce-radius-card); padding: 24px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.cce-store-nomatch .cce-store-h2 { color: var(--cce-ink); }
@media (min-width: 992px) {
    .cce-store-filters { flex-wrap: nowrap; }
}

/* Pixel-match pass (T16, against docs/feature-storefront-redesign/heather-mockup.png): the side column is one white
   rounded card, the avatar is larger, the header sits closer to the breadcrumb, and Sort shares the row of the filters.
   Tokens only. */
@media (min-width: 992px) {
    .cce-store-side { padding: 20px; background: var(--cce-surface); border: 1px solid var(--cce-line); border-radius: var(--cce-radius-card); box-shadow: var(--cce-shadow-card); }
    .cce-store-side > .cce-section { margin-bottom: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--cce-line); }
    .cce-store-side > .cce-section:last-of-type { border-bottom: 0; margin-bottom: 0; padding-bottom: 0; }
    .cce-store-side .cce-store-idea { margin-top: 0; }
    .cce-store-side-h { display: block; margin: 0 0 8px; font-size: 1.15rem; font-weight: 800; color: var(--cce-ink); }
    .cce-avatar { flex-basis: 128px; width: 128px; height: 128px; margin-top: -72px; }
    .cce-store-header { margin-top: -28px; }
    .cce-store-toolbar .cce-section-panel { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px; }
    .cce-store-toolbar .cce-store-filters { flex: 1 1 auto; }
    .cce-store-toolbar .cce-store-sort { margin-top: 0; margin-left: auto; flex: 0 0 auto; }
}
@media (max-width: 991.98px) {
    .cce-store-side-h { display: none; }
}
@media (max-width: 767.98px) {
    /* Phone: the Search button stays on the input's row (the mockup's search bar). */
    .cce-store-search { flex-wrap: nowrap; }
    .cce-store-search .cce-store-input { flex: 1 1 0; }
    .cce-store-search .cce-store-btn-primary { min-width: 84px; padding: 0 16px; }
}
