/* brand.css - THE BRAND SLOT. This file belongs to the demo, not to the theme.
 *
 * WHAT IT IS
 * theme-default ships this sheet with no paint in it. DefaultHeadInclude.cshtml
 * registers it AFTER default_custom.css, so every rule a brand writes here wins a
 * cascade tie against the theme without !important, and the theme's own sheet is
 * never edited. A theme bump is then a file copy, not a re-copy plus re-append.
 *
 * WHO WRITES IT
 * A demo copies theme-default into a demo-local layer (or its build folder), rewrites
 * THIS file and brand.tokens.json beside it, and delivers the copy. It never appends
 * brand CSS to default_custom.css: an appended sheet is a fork of the theme that the
 * next theme release silently discards or silently fails to receive.
 *
 * WHAT GOES HERE, in this order
 *   1. The token block below, filled from brand.tokens.json (css section). Only the
 *      tokens the brand changes; an omitted token keeps the theme value.
 *   2. Brand-only component rules: the logo lockup, a signature section, a motif.
 *      A rule that would help every demo is not a brand rule: it is a theme fix and
 *      belongs in default_custom.css upstream (Distribution PR), not here.
 *
 * WHAT DOES NOT GO HERE
 *   - --dw-color-button-primary and the rest of the per-scheme palette. They live in
 *     the GENERATED System/Styles/ColorSchemes pair (.css AND .json), block #19 of
 *     default_custom.css. brand.tokens.json carries the scheme table a generator
 *     writes into that pair; this sheet only consumes the result.
 *   - Fonts. The Typography pair loads them (Google Fonts import) and sets
 *     --dw-font-family per role. This sheet may reference a brand font by name.
 *
 * WHY :root:root
 * DefaultHeadInclude.cshtml inlines a render-critical copy of six --td-* tokens in a
 * head <style> element, and its position relative to this sheet's link element is up
 * to the platform. A doubled :root (specificity 0,2,0) beats the inline :root (0,1,0)
 * whatever the source order, so a brand token cannot lose to the neutral copy and no
 * !important is needed.
 *
 * AUTHORING GUARDS (the same G1 to G4 as default_custom.css): never type the
 * comment-close sequence inside comment prose; keep the sentinel rule below so a
 * CSSOM assert can prove the sheet parsed; !important every override of a
 * Bootstrap/Swift flex utility in every tier; never write a numeric-leading id
 * selector. Never write a marker string into the page from here (no content: that
 * names the brand file, no debug banner).
 */

/* The sentinel. Inert: nothing in a Swift document carries the attribute. */
[data-td-block="brand"] { --td-block: brand; }

/* 1. Brand tokens. Ships with every declaration commented out, so the slot paints
 *    nothing until a demo fills it. Uncomment and set what the brand changes.
 *
 * :root:root {
 *   --td-ink:          #1F2933;
 *   --td-ink-soft:     #323F4B;
 *   --td-slate:        #3E4C59;
 *   --td-slate-mid:    #52606D;
 *   --td-slate-light:  #CBD2D9;
 *   --td-grey-light:   #F5F7FA;
 *   --td-hairline:     #E4E7EB;
 *   --td-white:        #FFFFFF;
 *   --td-accent:       #3E4C59;
 *   --td-accent-soft:  rgba(62, 76, 89, .07);
 *   --td-radius:       12px;
 *   --td-radius-sm:    8px;
 *   --td-shadow-soft:  0 1px 2px rgba(31, 41, 51, .06), 0 12px 28px -14px rgba(31, 41, 51, .22);
 *   --td-logo-h:       1.75rem;
 *   --td-logo-w-phone: 132px;
 *   --td-logo-w-laptop: 170px;
 *   --td-hero-max-h:   60vh;
 *   --td-button-primary-ink-primary: #RRGGBB;
 * }
 *
 * The first thirteen are the theme's own token block (the first six also have the
 * inline head copy). The logo and hero tokens size blocks #13, #23 and the
 * image-height caps. The button-ink token is the hook of block #30; set it only
 * when the brand needs it (README, "Opt-in hooks").
 *
 * The accent on dark grounds: a brand whose accent is dark on light schemes sets a
 * lighter one per dark scheme, for example
 *   [data-dw-colorscheme="dark"], [data-dw-colorscheme="darksubtle"] { --td-accent: #4FB184; }
 */

/* 2. Brand-only component rules go below this line. */

/* ---- Muc-Off (test-muc-off demo), 2026-11-23 ----
 * Tokens from muc-off.com: black ink, white ground, the brand pink #FF3DC1 as accent.
 * The per-scheme palette is in the generated ColorSchemes pair (save_color_schemes). */
:root:root {
  --td-ink:          #000000;
  --td-ink-soft:     #1A1A1A;
  --td-accent:       #000000;   /* accent INK on light grounds: pink text or icons on white or on the pink
                                    tint fail contrast (2.5:1 to 3.1:1), so pink stays a fill, never ink */
  --td-accent-soft:  rgba(255, 61, 193, .14);
  --td-radius:       6px;
  --td-radius-sm:    4px;
}
[data-dw-colorscheme="dark"], [data-dw-colorscheme="darksubtle"], [data-dw-colorscheme="secondary"] { --td-accent: #FF3DC1; }
[data-dw-colorscheme="primary"] { --td-accent: #000000; }

/* WORKAROUND, retire when theme-default gives the PLP stock cell a fixed basis below 992px.
 * default_custom.css block 14 sets the mobile stock cell to flex: 0 0 auto, so its left edge
 * moves with the width of "72 In stock" versus "284 In stock" (10px spread on an iPhone 12,
 * design row PLP-ALIGN-01). The desktop block already uses 5.5rem; this applies it to mobile. */
@media (max-width: 991.98px) {
  .product-list article.product [data-dw-itemtype="swift-v2_productstock"] { flex: 0 0 5.5rem !important; }
}

/* Safety net: with Montserrat and uppercase button labels the signed-out price lock measured 378px,
 * wider than a 390px phone's content box, and the PLP widened the layout viewport by 4px (design
 * rows viewport-width and overflowX). Buttons are now sentence case (343px), and the lock may still
 * wrap rather than overflow if a longer label arrives. */
@media (max-width: 991.98px) {
  .product-list article.product [data-dw-itemtype="swift-v2_productprice"],
  .product-list article.product [data-dw-itemtype="swift-v2_productprice"] .flex-fill,
  .product-list article.product .td-price-lock { max-width: 100% !important; min-width: 0 !important; }
  .product-list article.product .td-price-lock { flex-wrap: wrap !important; }
  .product-list article.product .td-price-lock__action { white-space: normal !important; }
}
