/*
 * /designs — Workspace (wowX dashboard) look for the template store.
 * Sources of truth (live dashboard): partials/library.css (hero, CTAs, pills), index.php (icon rail,
 * quick cards), templates.php (template cards "mycats", format tabs, masonry), includes/sections/styles.php
 * (header, cards, popover). Formats/crop ratios: contentEngine/categories.json.
 */
:root {
    --brand-blue: #4C6FFF;
    --brand-blue-600: #3E5BFF;
    --focus-blue: #046bbf;
    --text: #0B1220;
    --text-body: #53565c;
    --text-dark: #383a3f;
    --text-muted: #5F6A7A;
    --ink-92: rgba(15, 23, 42, .92);
    --ink-68: rgba(15, 23, 42, .68);
    --line: rgba(15, 23, 42, .10);
    --line-soft: rgba(56, 58, 63, .08);
    --surface: #ffffff;
    --surface-2: #f6f7fb;
    --radius: 12px;
    --shadow-card: 0 10px 30px rgba(15, 23, 42, .08), 0 1px 2px rgba(15, 23, 42, .06);
    --shadow-tpl: 0 16px 44px rgba(10, 20, 30, .08);
    --shadow-tpl-hover: 0 26px 70px rgba(10, 20, 30, .14);
    --grad-cta: linear-gradient(135deg, #7c3aed, #3b82f6, #06b6d4);
    --grad-hero: linear-gradient(135deg, rgba(124, 58, 237, .14), rgba(59, 130, 246, .12), rgba(6, 182, 212, .10));
    --ease: cubic-bezier(.16, 1, .3, 1);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 12px; }
body.bd {
    margin: 0;
    background: #fff;
    color: var(--text-body);
    font: 16px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}
a { color: #1a73e8; text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; }
h1, h2, h3 { color: var(--text-dark); }
button { font: inherit; }
:focus-visible { outline: 3px solid rgba(92, 144, 255, .45); outline-offset: 2px; }
.material-icons { font-size: 20px; line-height: 1; vertical-align: middle; width: 1em; overflow: hidden; flex: 0 0 auto; }

.bd-skip { position: absolute; left: -9999px; top: 8px; z-index: 2000; background: #fff; padding: 8px 12px; border-radius: 8px; }
.bd-skip:focus { left: 8px; }
.bd-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.bd-muted { color: var(--text-muted); }
.bd-center { text-align: center; }
.bd-block { width: 100%; }
.bd-k { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; font-weight: 700; color: #8e918f; }
.bd-dot { width: 3px; height: 3px; border-radius: 50%; background: currentColor; opacity: .55; display: inline-block; flex: 0 0 auto; }

/* ---------- frame: full width, flush left (dashboard .content-gutter / .teams-ui) ---------- */
.content-gutter { padding: 10px 5px 28px; }
.teams-ui { position: relative; padding: 0 10px; }
.teams-header { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; min-height: 44px; }
.teams-title { display: flex; align-items: center; gap: 8px; font-size: 1.25rem; font-weight: 700; color: var(--text-dark); white-space: nowrap; margin-right: auto; }
.teams-title:hover { text-decoration: none; color: var(--text-dark); }
/* header logo — cropped to the artwork (ink box 132×61 at 13,12 inside the 150×76 PNG) so it aligns with the rail and buttons */
.bd-logo { --logo-h: 32px; gap: 0; line-height: 0; padding: 4px 2px; margin-left: -2px; border-radius: 8px; }
.bd-logo-crop { display: block; height: var(--logo-h); aspect-ratio: 132 / 61; overflow: hidden; }
.bd-logo-crop img { display: block; max-width: none; height: calc(var(--logo-h) * 76 / 61); width: auto; margin: calc(var(--logo-h) * -12 / 61) 0 0 calc(var(--logo-h) * -13 / 61); }
.bd-logo:hover .bd-logo-crop img { opacity: .85; }
.teams-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.teams-section { margin-bottom: 18px; }
/* skip rendering work for sections far below the fold (big card pages stay smooth) */
.bd-main > .teams-section { content-visibility: auto; contain-intrinsic-size: auto 560px; }

/* header search */
.bd-search { position: relative; flex: 0 1 380px; display: flex; align-items: center; height: 38px; background: #f4f6fb; border: 1px solid rgba(15, 23, 42, .08); border-radius: 10px; padding: 0 10px; transition: box-shadow .2s var(--ease), border-color .2s, background .2s; }
.bd-search > .material-icons { color: #8a93a6; font-size: 19px; }
.bd-search input { flex: 1; border: 0; background: transparent; padding: 8px; font-size: .93rem; color: var(--text); min-width: 0; }
.bd-search input:focus { outline: none; }
.bd-search input::-webkit-search-cancel-button { cursor: pointer; }
.bd-search:focus-within { border-color: rgba(76, 111, 255, .45); box-shadow: 0 0 0 4px rgba(76, 111, 255, .12); background: #fff; }
.bd-suggest { position: absolute; top: calc(100% + 8px); left: 0; right: 0; min-width: 320px; z-index: 1200; background: #fff; border: 1px solid rgba(15, 23, 42, .1); border-radius: 14px; box-shadow: 0 28px 80px rgba(15, 23, 42, .18); padding: 6px; }
.bd-suggest a { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 10px; color: var(--text); font-size: .9rem; font-weight: 600; }
.bd-suggest a:hover, .bd-suggest a[aria-selected="true"] { background: #f4f6fb; text-decoration: none; }
.bd-suggest img { width: 38px; height: 38px; border-radius: 8px; object-fit: cover; flex: 0 0 auto; background: #eef1f8; }
.bd-suggest .bd-suggest-all { justify-content: center; font-weight: 800; color: var(--brand-blue); }

/* buttons (dashboard .brand-btn) */
.brand-btn { display: inline-flex; align-items: center; justify-content: center; gap: 5px; height: 34px; padding: 0 12px; margin: 0; line-height: 1; font-weight: 700; text-transform: uppercase; font-size: .78rem; letter-spacing: .01em; border: 1px solid transparent; border-radius: 10px; background: #eee; color: #111; cursor: pointer; text-decoration: none; transition: transform .2s var(--ease), background-color .2s, box-shadow .2s; white-space: nowrap; }
.brand-btn:hover { background: #F6F8FF; text-decoration: none; color: #111; }
.brand-btn .material-icons { font-size: 16px; }
.brand-btn.small { height: 30px; padding: 0 10px; font-size: .74rem; }
.brand-btn.icon-only { width: 34px; padding: 0; }
.brand-btn.primary { background: linear-gradient(90deg, #3E5BFF, #4C6FFF); color: #fff; box-shadow: 0 8px 18px rgba(76, 111, 255, .28); }
.brand-btn.primary:hover { box-shadow: 0 14px 28px rgba(76, 111, 255, .34); transform: translateY(-1px); color: #fff; }
.brand-btn.is-active { background: #ffe8ef; color: #be123c; }
.bd-count { display: inline-flex; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--brand-blue); color: #fff; font-size: 11px; align-items: center; justify-content: center; margin-left: 2px; }
.bd-btn-row { display: flex; gap: 8px; flex-wrap: wrap; }

.brand-form-field { width: 100%; padding: 9px 11px; font-size: 1rem; line-height: 1.3; border: 1px solid rgba(15, 23, 42, .16); border-radius: 10px; background: #fff; color: var(--text); transition: border-color .2s, box-shadow .2s; }
.brand-form-field:focus { outline: none; border-color: rgba(76, 111, 255, .6); box-shadow: 0 0 0 4px rgba(76, 111, 255, .12); }

/* cards (dashboard .teams-card) */
.teams-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 14px; box-shadow: var(--shadow-card); }
.bd-block-card { padding: 18px 18px 20px; }

/* popover (dashboard .teams-popover) */
.teams-popover { position: absolute; right: 10px; top: 54px; z-index: 1000; width: 380px; max-width: calc(100vw - 24px); max-height: calc(100vh - 120px); overflow: auto; border: 1px solid rgba(15, 23, 42, .12); border-radius: 14px; background: #fff; box-shadow: 0 28px 80px rgba(15, 23, 42, .22); padding: 12px; animation: bdPop .18s var(--ease); }
@keyframes bdPop { from { opacity: 0; transform: translateY(-6px) scale(.98); } to { opacity: 1; transform: none; } }
.teams-popover-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; font-weight: 700; color: var(--text-dark); }
.bd-account-card { display: flex; gap: 12px; align-items: center; background: #f8f9fa; border: 1px solid #eef2f6; border-radius: 12px; padding: 12px; margin-bottom: 10px; }
.bd-account-card img { border-radius: 10px; object-fit: cover; background: #e8ebf3; }
.bd-account-name { font-size: 16px; font-weight: 700; color: #1a1c1e; }
.bd-account-sub { font-size: 13px; color: #5f6368; }
.bd-account-row { display: flex; gap: 12px; align-items: center; margin: 8px 0 12px; }
.bd-account-row .material-icons { width: 32px; height: 32px; border-radius: 8px; border: 1px solid #e0e0e0; display: inline-flex; align-items: center; justify-content: center; font-size: 18px; color: #444746; }
.bd-v { font-size: 13px; color: #1a1c1e; font-weight: 500; overflow: hidden; text-overflow: ellipsis; }
.bd-account-menu { display: flex; flex-direction: column; margin: 0 -6px 12px; padding: 6px 0; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.bd-account-menu a { display: flex; align-items: center; gap: 10px; padding: 8px 6px; border-radius: 8px; color: var(--text-dark); font-weight: 650; font-size: .88rem; text-decoration: none; }
.bd-account-menu a:hover, .bd-account-menu a:focus-visible { background: rgba(56, 58, 63, .06); text-decoration: none; }
.bd-account-menu .material-icons { font-size: 18px; color: #444746; }
.bd-account-menu .bd-badge { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: #e11d48; color: #fff; font-size: .7rem; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; }
.bd-account-links { display: flex; flex-wrap: wrap; gap: 8px; }
.bd-account-links form { margin: 0; }
.bd-onboard { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 10px; background: #fff7e6; border: 1px solid #ffe0a3; color: #8a5a00; font-weight: 700; margin-bottom: 10px; }

.bd-flash { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: 12px; margin-bottom: 14px; font-weight: 600; animation: bdPop .25s var(--ease); }
.bd-flash.is-success { background: #ecfdf3; color: #067647; border: 1px solid #abefc6; }
.bd-flash.is-error { background: #fef3f2; color: #b42318; border: 1px solid #fecdca; }

/* ---------- icon rail: measured from the live dashboard (72×64 tiles, 16px apart, 19px icon, 11px label) ---------- */
.bd-shell { display: flex; gap: 24px; align-items: flex-start; }
.TheBrandNavMain { flex: 0 0 auto; }
/* .teams-ui already pads 10px, so the tiles land at x=15 like the dashboard (its rail list has margin-left:10px instead). */
.TheBrandTabList { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; width: 72px; font: 16px/normal -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; }
.TheBrandNavMain .brand-icon-menu-btn { display: flex; }
.TheBrandNavMain .brand-icon-menu-btn + .brand-icon-menu-btn { margin-top: .5em; }
.brand-icon-menu-btn a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; height: 4em; padding: 10px 5px; border-radius: .625em; background: #fff; color: #53565c; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .05); transition: background-color .3s ease-out, color .3s ease-out, box-shadow .3s ease-out; text-decoration: none; }
.brand-icon-menu-btn a:hover { box-shadow: inset 0 0 0 1px #67a5f4; text-decoration: none; }
.brand-icon-menu-btn a:focus-visible { outline: 2px solid #67a5f4; outline-offset: 2px; }
.brand-icon-menu-btn .material-icons { font-size: 19px; margin-top: .25em; }
.brand-icon-menu-btn a span:not(.material-icons) { font-size: .6875em; margin-top: .5em; display: block; width: calc(100% - 1em); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: center; }
.brand-icon-menu-btn[aria-current="page"] a { color: #67a5f4; background: #ebecef; }
.bd-main { flex: 1; min-width: 0; }
.bd-main:focus { outline: none; }
.TheBrandMobileNavShell { display: none; }

.bd-crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0 0 10px; font-size: .82rem; color: var(--text-muted); }
.bd-crumbs li + li::before { content: "/"; margin-right: 6px; color: #b3b9c6; }
.bd-crumbs a { color: var(--text-muted); font-weight: 600; }

/* ---------- hero (dashboard templates-hero) ---------- */
.templates-hero-root { margin-bottom: 18px; }
.templates-hero-root .templates-hero-card { padding: 0; overflow: hidden; border-radius: 16px; box-shadow: 0 18px 45px rgba(15, 23, 42, .14); }
.templates-hero-root .templates-hero-inner, .bd-hero-compact { position: relative; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 22px; padding: 22px; background: var(--grad-hero); border: 1px solid rgba(15, 23, 42, .06); overflow: hidden; }
.bd-hero-compact { display: block; padding: 22px 24px; }
/* compact hero (pages, favorites, profile, 404): the card rule above sets padding:0, so restore it with equal specificity */
.templates-hero-root .templates-hero-card.bd-hero-compact { padding: 24px 26px 26px; }
.bd-hero-compact > .templates-hero-left, .bd-hero-compact > .bd-profile-head { position: relative; z-index: 1; }
/* hero without preview tiles: text uses the full width */
.templates-hero-inner > .templates-hero-left:only-child { grid-column: 1 / -1; }
.templates-hero-root .templates-hero-inner::before, .bd-hero-compact::before { content: ""; position: absolute; inset: -120px -80px auto auto; width: 420px; height: 420px; background: radial-gradient(closest-side, rgba(124, 58, 237, .22), rgba(124, 58, 237, 0)); filter: blur(4px); pointer-events: none; } /* closest-side: the glow fades out fully inside its box (no hard seam in compact heroes) */
.templates-hero-root .templates-hero-inner::after { content: ""; position: absolute; inset: auto auto -160px -120px; width: 520px; height: 520px; background: radial-gradient(closest-side, rgba(6, 182, 212, .18), rgba(6, 182, 212, 0)); filter: blur(6px); pointer-events: none; }
.templates-hero-left { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; min-width: 0; }
.templates-hero-eyebrow { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 999px; background: rgba(255, 255, 255, .75); border: 1px solid rgba(15, 23, 42, .06); backdrop-filter: blur(10px); font-weight: 900; letter-spacing: .02em; font-size: .78rem; color: rgba(15, 23, 42, .75); }
.templates-hero-eyebrow .material-icons { font-size: 17px; }
.templates-hero-title { margin: 0; font-weight: 950; letter-spacing: -.03em; line-height: 1.08; font-size: clamp(1.55rem, 2.1vw + 1rem, 2.15rem); color: var(--ink-92); text-wrap: balance; }
.templates-hero-kicker { margin: 0; font-weight: 850; color: rgba(15, 23, 42, .8); }
.templates-hero-subtitle { margin: 0; font-weight: 750; color: var(--ink-68); font-size: clamp(.95rem, .7vw + .78rem, 1.02rem); line-height: 1.45; max-width: 62ch; }
.templates-hero-subtitle a { font-weight: 800; }
.templates-hero-ctas { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }
.templates-cta { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 14px; border-radius: 12px; font-weight: 950; letter-spacing: .01em; text-decoration: none; user-select: none; border: 1px solid transparent; cursor: pointer; font-size: .95rem; line-height: 1.2; transition: transform .16s ease, box-shadow .16s ease, background .16s; }
.templates-cta:hover { transform: translateY(-1px); box-shadow: 0 26px 70px rgba(10, 20, 30, .16); text-decoration: none; }
.templates-cta .material-icons { font-size: 18px; }
.templates-cta-primary { color: #fff; background: var(--grad-cta); background-size: 140% 100%; box-shadow: 0 18px 48px rgba(10, 20, 30, .16); }
.templates-cta-primary:hover { color: #fff; background-position: 100% 0; }
.templates-cta-secondary { color: rgba(15, 23, 42, .86); background: rgba(255, 255, 255, .76); border-color: rgba(15, 23, 42, .08); backdrop-filter: blur(10px); }
.templates-cta-secondary:hover { color: rgba(15, 23, 42, .92); }
.templates-cta[disabled], .templates-cta.is-busy { opacity: .7; cursor: progress; }
.templates-cta.is-busy .material-icons { animation: bdSpin 1s linear infinite; }
@keyframes bdSpin { to { transform: rotate(360deg); } }
.templates-hero-pills, .bd-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.templates-pill { display: inline-flex; align-items: center; gap: 6px; padding: 6px 11px; border-radius: 999px; background: rgba(255, 255, 255, .66); border: 1px solid rgba(15, 23, 42, .06); font-weight: 850; font-size: .78rem; color: rgba(15, 23, 42, .68); backdrop-filter: blur(10px); transition: background .16s, box-shadow .16s, transform .16s; }
.templates-pill .material-icons { font-size: 15px; opacity: .8; }
.templates-pill:hover { background: #fff; text-decoration: none; color: var(--ink-92); box-shadow: 0 10px 25px rgba(10, 20, 30, .10); transform: translateY(-1px); }
.templates-pill.is-active { background: #1e293b; color: #fff; }
.bd-tags .templates-pill { background: #f4f6fb; }
.templates-hero-right { position: relative; z-index: 1; min-width: 0; }
.templates-preview-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; max-height: 350px; }
.templates-preview-card { position: relative; border-radius: 18px; overflow: hidden; background: rgba(255, 255, 255, .84); border: 1px solid rgba(15, 23, 42, .06); box-shadow: 0 18px 48px rgba(10, 20, 30, .10); max-height: 169px; transition: transform .18s ease, box-shadow .18s ease; }
.templates-preview-badge { position: absolute; top: 10px; left: 10px; z-index: 2; padding: 6px 10px; border-radius: 999px; background: rgba(20, 22, 30, .55); backdrop-filter: blur(10px); color: #fff; font-weight: 900; font-size: .72rem; letter-spacing: .02em; max-width: calc(100% - 20px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.templates-preview-img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: top; aspect-ratio: 1 / 1; background: #eef1f8; }
.th-float-1 { animation: thFloat 7.2s ease-in-out infinite; }
.th-float-2 { animation: thFloat 8.1s ease-in-out infinite; animation-delay: -1.6s; }
.th-float-3 { animation: thFloat 7.6s ease-in-out infinite; animation-delay: -3s; }
.th-float-4 { animation: thFloat 8.6s ease-in-out infinite; animation-delay: -2.2s; }
@keyframes thFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* spec chips (format facts) */
.bd-spec-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 2px 0 0; }
.bd-spec-chips li { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 999px; background: rgba(255, 255, 255, .78); border: 1px solid rgba(15, 23, 42, .08); font-size: .78rem; font-weight: 800; color: rgba(15, 23, 42, .74); }
.bd-spec-chips .material-icons { font-size: 15px; color: rgba(76, 111, 255, .95); }
.bd-spec-chips li.is-green { background: #ecfdf3; color: #067647; border-color: #abefc6; }
.bd-spec-chips li.is-green .material-icons { color: #067647; }
.bd-spec-chips li.is-warn { background: #fff7e6; color: #8a5a00; }

/* format glyph: a tiny outline in the format's real shape */
.bd-glyph { display: inline-block; flex: 0 0 auto; border: 1.6px solid currentColor; border-radius: 2px; opacity: .8; }

/* ---------- promos (the site's slider, in dashboard strips) ---------- */
.bd-promos { display: grid; gap: 14px; margin-bottom: 18px; }
/* image-only slide: shown whole (text is baked into the artwork), sides filled by an ambient blur of itself */
.bd-promo-banner { position: relative; display: flex; align-items: center; justify-content: center; border-radius: 16px; overflow: hidden; background: #eef0f6; box-shadow: var(--shadow-tpl); height: clamp(180px, 22vw, 330px); width: 100%; isolation: isolate; }
.bd-promo-banner::before { content: ""; position: absolute; inset: -40px; z-index: -1; background: var(--bg) center / cover no-repeat; filter: blur(34px) saturate(1.15); opacity: .55; }
.bd-promo-banner img { position: relative; height: 100%; width: auto; max-width: 100%; object-fit: contain; display: block; transition: transform .6s var(--ease); }
.bd-promo-banner:hover img { transform: scale(1.02); }
.bd-promo-banner-cta { position: absolute; right: 16px; bottom: 16px; display: inline-flex; align-items: center; gap: 6px; padding: 9px 14px; border-radius: 999px; background: rgba(255, 255, 255, .92); color: #0f172a; font-weight: 900; font-size: .85rem; box-shadow: 0 12px 30px rgba(15, 23, 42, .25); }
.bd-promo-banner:hover { text-decoration: none; }
.bd-promo-strips { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 14px; }
.bd-promo { position: relative; display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-left: 4px solid rgb(var(--tone, 255, 216, 67)); color: inherit; transition: transform .18s ease, box-shadow .18s ease; }
a.bd-promo:hover { text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow-tpl-hover); }
.bd-promo-media { flex: 0 0 84px; height: 64px; border-radius: 12px; background: #eef1f8 center / cover no-repeat; }
.bd-promo-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.bd-promo-title { font-weight: 900; color: #16181d; font-size: 1.02rem; letter-spacing: -.01em; }
.bd-promo-text { color: #5f6672; font-size: .88rem; line-height: 1.4; }
.bd-promo-go { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 12px; background: var(--grad-cta); color: #fff; font-weight: 900; font-size: .82rem; }
.bd-promo-go .material-icons { font-size: 16px; }

/* ---------- quick-start cards (dashboard teams-quickcard) ---------- */
.teams-quickcards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.teams-quickcard { position: relative; display: flex; flex-direction: column; justify-content: space-between; gap: 14px; min-height: 210px; padding: 20px 20px 18px; border-radius: 18px; border: 1px solid rgba(15, 23, 42, .10); background: #fff; overflow: hidden; text-decoration: none; color: inherit; box-shadow: 0 10px 30px rgba(15, 23, 42, .06); transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
.teams-quickcard:hover { transform: translateY(-2px); box-shadow: 0 22px 60px rgba(15, 23, 42, .12); border-color: rgba(15, 23, 42, .14); text-decoration: none; }
.teams-quickcard::before { content: ''; position: absolute; inset: auto -20% -22% auto; width: 340px; height: 340px; border-radius: 28px; filter: blur(18px); background: radial-gradient(closest-side, rgba(var(--qc1, 76, 111, 255), .28), transparent 72%), radial-gradient(closest-side, rgba(var(--qc2, 124, 58, 237), .22), transparent 72%), radial-gradient(closest-side, rgba(var(--qc3, 6, 182, 212), .22), transparent 72%); transform: rotate(20deg); transition: transform .25s ease; }
.teams-quickcard:hover::before { transform: rotate(16deg) scale(1.06); }
.teams-quickcard-top, .teams-quickcard-bottom { position: relative; z-index: 2; }
.teams-quickcard-kicker { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: rgba(255, 255, 255, .82); border: 1px solid rgba(var(--qc1, 76, 111, 255), .18); font-weight: 900; font-size: .78rem; color: rgba(15, 23, 42, .72); }
.teams-quickcard-kicker .material-icons { font-size: 18px; color: rgba(var(--qc1, 76, 111, 255), .95); }
.teams-quickcard-title { margin: 12px 0 0; font-weight: 950; letter-spacing: -.03em; line-height: 1.08; font-size: 1.3rem; color: var(--ink-92); }
.bd-format-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.bd-format-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border-radius: 999px; background: rgba(255, 255, 255, .8); border: 1px solid rgba(15, 23, 42, .08); font-size: .74rem; font-weight: 800; color: rgba(15, 23, 42, .66); }
.bd-format-chip .bd-glyph { color: rgba(var(--qc1, 76, 111, 255), 1); opacity: 1; }
.bd-format-chip.is-more { background: rgba(var(--qc1, 76, 111, 255), .1); color: rgba(var(--qc1, 76, 111, 255), 1); }
.teams-quickcard-ctaRow { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.teams-quickcard-meta { display: flex; align-items: center; gap: 8px; color: rgba(15, 23, 42, .58); font-weight: 800; font-size: .82rem; }
.teams-quickcard-dot { width: 6px; height: 6px; border-radius: 999px; background: rgba(var(--qc2, 124, 58, 237), .55); }
.teams-quickcard-cta { display: inline-flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 14px; font-weight: 900; font-size: .88rem; color: #fff; background: linear-gradient(135deg, rgba(var(--qc1), .92) 0%, rgba(var(--qc2), .92) 55%, rgba(var(--qc3), .92) 100%); box-shadow: 0 12px 30px rgba(var(--qc1), .25); }
.teams-quickcard-cta .material-icons { color: #fff; font-size: 18px; transition: transform .2s var(--ease); }
.teams-quickcard:hover .teams-quickcard-cta .material-icons { transform: translateX(3px); }
.teams-quickcard.brandkit { --qc1: 76, 111, 255; --qc2: 124, 58, 237; --qc3: 6, 182, 212; }
.teams-quickcard.templates { --qc1: 34, 197, 94; --qc2: 59, 130, 246; --qc3: 245, 158, 11; }
.teams-quickcard.folders { --qc1: 245, 158, 11; --qc2: 59, 130, 246; --qc3: 34, 197, 94; }
.teams-quickcard.share { --qc1: 6, 182, 212; --qc2: 76, 111, 255; --qc3: 124, 58, 237; }
.teams-quickcard.teams-feature { --qc1: 59, 130, 246; --qc2: 76, 111, 255; --qc3: 6, 182, 212; }
.teams-quickcard.governance { --qc1: 15, 23, 42; --qc2: 59, 130, 246; --qc3: 124, 58, 237; }

/* ---------- section heads & glance ---------- */
.bd-section-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.bd-pill-label { display: inline-flex; align-items: center; gap: 8px; padding: 6px 11px; margin: 0; border-radius: 999px; background: rgba(255, 255, 255, .82); border: 1px solid rgba(var(--tone), .22); font-weight: 900; letter-spacing: .02em; font-size: .85rem; color: rgba(15, 23, 42, .8); }
.bd-pill-label .material-icons { font-size: 18px; color: rgba(var(--tone), .95); }
.bd-section-sub { margin: 6px 0 0 4px; color: var(--text-muted); font-size: .86rem; font-weight: 600; }
.bd-glance { background: linear-gradient(135deg, rgba(245, 158, 11, .06), rgba(59, 130, 246, .06)); border-color: rgba(15, 23, 42, .06); }
.brand-glance-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (min-width: 900px) { .brand-glance-grid { grid-template-columns: repeat(4, 1fr); } }
.brand-glance-card { display: flex; gap: 12px; align-items: center; padding: 16px; background: linear-gradient(135deg, #fff 0%, #f8fafc 100%); border: 1px solid rgba(226, 232, 240, .8); border-radius: 12px; color: inherit; transition: all .2s ease; }
.brand-glance-card:hover { transform: translateY(-2px); border-color: rgba(59, 130, 246, .2); box-shadow: 0 4px 12px rgba(0, 0, 0, .03); text-decoration: none; }
.bd-glance-icon { width: 38px; height: 38px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; background: rgba(var(--tone, 100, 116, 139), .1); color: rgba(var(--tone, 100, 116, 139), 1); font-size: 20px; }
.bd-glance-num { font-size: 22px; font-weight: 800; color: var(--text-dark); font-variant-numeric: tabular-nums; }
/* Templates at a Glance: categories → sub-formats with template counts */
.bd-glance-cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.bd-glance-group { display: flex; flex-direction: column; background: linear-gradient(135deg, #fff 0%, #f8fafc 100%); border: 1px solid rgba(226, 232, 240, .9); border-radius: 14px; padding: 12px; transition: box-shadow .2s ease, border-color .2s ease; }
.bd-glance-group:hover { border-color: rgba(var(--tone), .28); box-shadow: 0 10px 26px rgba(15, 23, 42, .06); }
.bd-glance-group-head { display: flex; align-items: center; gap: 10px; padding: 2px 2px 10px; margin-bottom: 6px; border-bottom: 1px solid rgba(15, 23, 42, .06); color: var(--text-dark); }
.bd-glance-group-head:hover { text-decoration: none; }
.bd-glance-group-head .bd-glance-icon { width: 34px; height: 34px; font-size: 19px; background: rgba(var(--tone), .12); color: rgba(var(--tone), 1); }
.bd-glance-group-name { flex: 1; min-width: 0; font-weight: 900; font-size: .95rem; letter-spacing: -.01em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bd-glance-group-count { font-weight: 900; font-size: .95rem; color: var(--text-dark); font-variant-numeric: tabular-nums; }
.bd-glance-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.bd-glance-list a { position: relative; display: flex; align-items: center; gap: 9px; padding: 7px 8px; border-radius: 9px; color: rgba(56, 58, 63, .82); font-size: .84rem; font-weight: 650; overflow: hidden; isolation: isolate; }
.bd-glance-list a:hover { background: rgba(var(--tone), .07); color: var(--ink-92); text-decoration: none; }
.bd-glance-list .bd-glyph { color: rgba(var(--tone), 1); opacity: .9; }
.bd-glance-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bd-glance-count { flex: 0 0 auto; font-weight: 800; font-size: .8rem; color: rgba(56, 58, 63, .7); font-variant-numeric: tabular-nums; }
.bd-glance-bar { position: absolute; left: 8px; right: 8px; bottom: 2px; height: 2px; z-index: -1; }
.bd-glance-bar::before { content: ""; display: block; height: 100%; width: var(--w, 0%); border-radius: 2px; background: rgba(var(--tone), .35); }
.bd-glance-more { display: inline-flex; align-items: center; gap: 4px; margin: 8px 0 0 8px; font-size: .8rem; font-weight: 800; color: rgba(var(--tone), 1); }
.bd-glance-more .material-icons { font-size: 15px; }
.bd-highlights { background: linear-gradient(135deg, rgba(76, 111, 255, .08), rgba(59, 130, 246, .06), rgba(6, 182, 212, .06)); border-color: rgba(15, 23, 42, .06); }
.bd-highlights-text { margin: 0 0 12px; color: var(--ink-68); font-weight: 700; }

/* ---------- template cards (dashboard "mycats" card) ---------- */
.bd-card { position: relative; display: flex; flex-direction: column; border-radius: 18px; overflow: hidden; background: #fff; box-shadow: var(--shadow-tpl); transform: translateZ(0); transition: transform .18s ease, box-shadow .18s ease; isolation: isolate; }
.bd-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-tpl-hover); }
.bd-card:focus-within { box-shadow: 0 0 0 3px rgba(92, 144, 255, .35), 0 20px 55px rgba(10, 20, 30, .12); }
.bd-card-media { position: relative; width: 100%; aspect-ratio: var(--ar, 1); overflow: hidden; background: linear-gradient(135deg, rgba(40, 44, 58, .14), rgba(78, 95, 140, .08)); }
.bd-card-media::before { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, .45) 42%, rgba(255, 255, 255, 0) 54%); background-size: 260% 100%; animation: bdShimmer 1.6s linear infinite; }
.bd-card-media.is-loaded::before, .bd-card-media.is-broken::before { display: none; }
@keyframes bdShimmer { from { background-position: 130% 0; } to { background-position: -130% 0; } }
.bd-card-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top center; display: block; z-index: 1; filter: saturate(1.04) contrast(1.02); transition: transform .45s var(--ease), opacity .35s ease; }
.bd-js .bd-card-media img { opacity: 0; }
.bd-js .bd-card-media.is-loaded img { opacity: 1; }
.bd-card:hover .bd-card-media img { transform: scale(1.035); }
/* extreme formats (e.g. 8:1 leaderboards, 9:32 strips) sit on an artboard instead of becoming slivers */
.bd-card.is-artboard .bd-card-media { background: radial-gradient(rgba(15, 23, 42, .09) 1px, transparent 1.3px) 0 0 / 14px 14px, linear-gradient(135deg, #f3f5fb, #e9edf6); }
.bd-card.is-artboard .bd-card-media img { object-fit: contain; padding: 9%; filter: drop-shadow(0 12px 18px rgba(15, 23, 42, .2)); }
.bd-card.is-artboard:hover .bd-card-media img { transform: scale(1.02); }
.bd-card-fallback { position: absolute; inset: 0; z-index: 0; display: none; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 10px; text-align: center; font-size: .75rem; font-weight: 800; color: rgba(15, 23, 42, .5); }
.bd-card-fallback .material-icons { font-size: 30px; color: rgba(76, 111, 255, .55); }
.bd-card-media.is-broken img { display: none; }
.bd-card-media.is-broken .bd-card-fallback { display: flex; background: radial-gradient(rgba(15, 23, 42, .07) 1px, transparent 1.3px) 0 0 / 14px 14px, var(--grad-hero); }
.bd-ratio-badge { position: absolute; top: 10px; left: 10px; z-index: 2; display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border-radius: 999px; background: rgba(20, 22, 30, .62); color: #fff; font-weight: 800; font-size: .7rem; letter-spacing: .02em; opacity: .95; }
.bd-ratio-badge .bd-glyph { opacity: .9; border-width: 1.4px; }
.bd-card-body { padding: 9px 12px 11px; display: flex; flex-direction: column; gap: 3px; }
/* title stays quiet so the design itself leads; it firms up only when the card is hovered/focused */
.bd-card-title { color: rgba(56, 58, 63, .78); font-weight: 650; font-size: .82rem; line-height: 1.3; letter-spacing: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; transition: color .18s ease; }
.bd-card-title:hover, .bd-card:hover .bd-card-title, .bd-card:focus-within .bd-card-title { text-decoration: none; color: rgba(15, 23, 42, .92); }
.bd-card-title::after { content: ""; position: absolute; inset: 0; z-index: 1; } /* whole card is the link */
.bd-card-meta { display: flex; align-items: center; gap: 6px; font-size: .72rem; font-weight: 600; color: rgba(56, 58, 63, .48); line-height: 1.2; white-space: nowrap; overflow: hidden; }
.bd-card-cat { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.bd-card-size { flex: 0 0 auto; font-variant-numeric: tabular-nums; }
.bd-fav { position: absolute; top: 8px; right: 8px; z-index: 3; width: 36px; height: 36px; border-radius: 999px; border: 0; background: rgba(255, 255, 255, .95); box-shadow: 0 6px 16px rgba(15, 23, 42, .18); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; color: #475467; opacity: 0; transform: scale(.9); transition: opacity .2s, transform .2s var(--ease), color .2s; }
.bd-fav .material-icons { font-size: 19px; }
.bd-card:hover .bd-fav, .bd-fav:focus-visible, .bd-fav.is-active { opacity: 1; transform: scale(1); }
.bd-fav:hover { color: #e11d48; }
.bd-fav.is-active { color: #e11d48; }
.bd-fav.is-popping .material-icons { animation: bdHeart .45s var(--ease); }
@keyframes bdHeart { 0% { transform: scale(1); } 40% { transform: scale(1.35); } 100% { transform: scale(1); } }
@media (hover: none) { .bd-fav { opacity: 1; transform: none; } }

/* grids: even grid for a single format, masonry (dashboard) for mixed formats */
.bd-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(var(--min, 200px), 1fr)); gap: 16px; align-items: start; }
.bd-masonry { column-width: 210px; column-gap: 16px; }
.bd-masonry > .bd-card { break-inside: avoid; margin: 0 0 16px; width: 100%; display: inline-flex; }

/* justified gallery: one height per row, widths from each format, rows span the full width */
.bd-justified { --h: 230px; display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-start; }
.bd-justified > .bd-card { flex: var(--ar, 1) 1 calc(var(--ar, 1) * var(--h)); min-width: 0; }
.bd-justified.is-fill { justify-content: center; }
.bd-justified.is-fill > .bd-card { max-width: calc(var(--ar, 1) * var(--h) * 1.75); }
.bd-justified:not(.is-fill)::after { content: ""; flex: 12 1 0; }

/* rows: one height, width follows the format */
.bd-row { position: relative; margin: 0 -4px; }
.bd-row-track { --row-h: 210px; display: flex; gap: 14px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity; padding: 4px 4px 18px; scrollbar-width: thin; scrollbar-color: rgba(56, 58, 63, .2) transparent; }
.bd-row-track::-webkit-scrollbar { height: 8px; }
.bd-row-track::-webkit-scrollbar-thumb { background: rgba(56, 58, 63, .15); border-radius: 999px; }
.bd-row-track > .bd-card { flex: 0 0 auto; width: max(160px, min(460px, calc(var(--row-h) * var(--ar)))); scroll-snap-align: start; }
.bd-row-track > .bd-card .bd-card-media { aspect-ratio: auto; height: var(--row-h); }
.bd-row-btn { position: absolute; top: calc(4px + 105px - 20px); z-index: 5; width: 40px; height: 40px; border-radius: 999px; border: 1px solid rgba(15, 23, 42, .1); background: rgba(255, 255, 255, .95); backdrop-filter: blur(8px); box-shadow: 0 10px 28px rgba(15, 23, 42, .18); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; color: var(--text-dark); transition: transform .2s var(--ease); }
.bd-row-btn:hover { transform: scale(1.06); }
.bd-row-btn.prev { left: -6px; }
.bd-row-btn.next { right: -6px; }

/* spotlight (few featured designs) */
.bd-spotlight { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 22px; align-items: center; }
.bd-spotlight + .bd-spotlight { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); }
.bd-spotlight-body { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.bd-spotlight-title { margin: 0; font-size: clamp(1.25rem, 1.2vw + 1rem, 1.7rem); font-weight: 950; letter-spacing: -.02em; line-height: 1.12; }
.bd-spotlight-title a { color: var(--ink-92); }
.bd-spotlight-title a:hover { text-decoration: none; color: #111827; }
.bd-spotlight .bd-muted { margin: 0; font-weight: 600; }

/* canvas: the design on an editor-like board at its true shape */
.bd-canvas { position: relative; display: flex; align-items: center; justify-content: center; padding: clamp(18px, 3.5vw, 44px); border-radius: 14px; background: radial-gradient(rgba(15, 23, 42, .10) 1px, transparent 1.3px) 0 0 / 16px 16px, linear-gradient(135deg, #f3f5fb, #eceff7); min-height: 280px; overflow: hidden; }
.bd-canvas img { display: block; width: auto; height: auto; max-width: 100%; max-height: min(68vh, 720px); aspect-ratio: var(--real, 1); object-fit: cover; object-position: top center; border-radius: 6px; background: #fff; box-shadow: 0 30px 60px rgba(15, 23, 42, .18), 0 2px 6px rgba(15, 23, 42, .08); transition: transform .45s var(--ease), opacity .35s ease; }
a.bd-canvas:hover img { transform: translateY(-3px) scale(1.01); }
.bd-canvas-caption { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 10px; font-size: .8rem; font-weight: 800; color: var(--text-muted); }

/* ---------- listing ---------- */
.bd-formatbar { display: flex; gap: 6px; align-items: center; overflow-x: auto; padding: 6px; margin: 0 0 14px; border-radius: 999px; background: rgba(56, 58, 63, .05); border: 1px solid var(--line-soft); scrollbar-width: thin; scrollbar-color: rgba(56, 58, 63, .18) transparent; }
.bd-formatbar::-webkit-scrollbar { height: 6px; }
.bd-formatbar::-webkit-scrollbar-thumb { background: rgba(56, 58, 63, .15); border-radius: 999px; }
.bd-formatbar-tab { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 7px; border-radius: 999px; padding: 8px 13px; font-weight: 900; font-size: .8rem; letter-spacing: .01em; color: rgba(56, 58, 63, .78); white-space: nowrap; transition: background .16s ease, box-shadow .16s ease, transform .16s ease, color .16s; }
.bd-formatbar-tab .material-icons { font-size: 16px; }
.bd-formatbar-tab:hover { background: rgba(255, 255, 255, .85); box-shadow: 0 10px 25px rgba(10, 20, 30, .10); transform: translateY(-1px); text-decoration: none; color: rgba(56, 58, 63, .92); }
.bd-formatbar-tab[aria-current="page"] { background: #fff; color: rgba(56, 58, 63, .95); box-shadow: 0 14px 35px rgba(10, 20, 30, .12); }
.bd-formatbar-tab[aria-current="page"] .bd-glyph, .bd-formatbar-tab[aria-current="page"] .material-icons { color: var(--brand-blue); opacity: 1; }
.bd-toolbar { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 0 2px 14px; }
.bd-results { font-size: .92rem; }
.bd-results strong { color: var(--text-dark); font-weight: 900; font-variant-numeric: tabular-nums; }
.bd-toolbar-actions { display: flex; align-items: center; gap: 8px; }
.bd-sort { position: relative; display: flex; align-items: center; margin: 0; }
.bd-sort > .material-icons { position: absolute; left: 10px; font-size: 17px; color: #667085; pointer-events: none; }
.bd-sort select { appearance: none; -webkit-appearance: none; height: 34px; padding: 0 32px 0 34px; border-radius: 10px; border: 1px solid rgba(15, 23, 42, .1); background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24'%3E%3Cpath fill='%23667085' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E") no-repeat right 10px center; font-weight: 800; font-size: .82rem; color: var(--text-dark); cursor: pointer; }
.bd-filters { position: relative; }
.bd-filters > summary { list-style: none; }
.bd-filters > summary::-webkit-details-marker { display: none; }
.bd-filters[open] > summary { background: #eef4ff; color: #1e3a8a; }
.bd-filter-panel { position: absolute; right: 0; top: calc(100% + 8px); z-index: 50; width: 300px; padding: 14px; box-shadow: 0 28px 80px rgba(15, 23, 42, .18); animation: bdPop .18s var(--ease); }
.bd-filter-block { border: 0; padding: 0; margin: 0 0 14px; }
.bd-filter-title { margin: 0 0 8px; padding: 0; font-size: .74rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); font-weight: 800; }
.bd-check { display: flex; align-items: flex-start; gap: 8px; font-size: .9rem; margin: 6px 0; cursor: pointer; }
.bd-check input { margin-top: 3px; accent-color: var(--brand-blue); }
.bd-price { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.bd-price label { display: flex; flex-direction: column; gap: 4px; font-size: .78rem; color: var(--text-muted); font-weight: 700; }
.bd-chips { display: flex; gap: 8px; flex-wrap: wrap; margin: -4px 2px 14px; }
.bd-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 8px 6px 12px; border-radius: 999px; background: #eef4ff; color: #1e3a8a; font-weight: 800; font-size: .8rem; }
.bd-chip:hover { text-decoration: none; background: #e0eaff; }
.bd-chip .material-icons { font-size: 16px; }
.bd-chip-reset { background: transparent; color: var(--brand-blue); padding-right: 12px; }
.bd-empty { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 44px 16px; text-align: center; color: var(--text-muted); font-weight: 600; }
.bd-empty .material-icons { font-size: 42px; color: #b3b9c6; }
.bd-more { margin-top: 6px; }

.bd-pagination { display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; margin: 22px 0 8px; }
.bd-pagination ol { list-style: none; display: flex; gap: 4px; margin: 0; padding: 4px; border-radius: 999px; background: rgba(56, 58, 63, .05); border: 1px solid var(--line-soft); }
.bd-pagination li a, .bd-pagination li span { display: inline-flex; min-width: 34px; height: 34px; align-items: center; justify-content: center; border-radius: 999px; font-weight: 800; font-size: .86rem; color: var(--text-dark); padding: 0 8px; font-variant-numeric: tabular-nums; }
.bd-pagination li a:hover { background: #fff; text-decoration: none; box-shadow: 0 6px 16px rgba(10, 20, 30, .08); }
.bd-pagination li span[aria-current] { background: #fff; color: var(--brand-blue); box-shadow: 0 10px 24px rgba(10, 20, 30, .12); }
.bd-gap { align-self: center; color: var(--text-muted); padding: 0 4px; }

.bd-prose { color: var(--text-body); line-height: 1.7; max-width: 80ch; }
.bd-prose h2, .bd-prose h3 { font-size: 1.05rem; margin: 1.2em 0 .4em; color: var(--text-dark); }
.bd-prose p { margin: .4em 0 .9em; }
.bd-faq .bd-prose h3 { font-size: 1rem; }
.bd-ad { overflow: hidden; text-align: center; }
.bd-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.bd-tile { display: flex; flex-direction: column; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); color: var(--text-dark); font-weight: 800; background: #fff; transition: transform .18s, box-shadow .18s; }
.bd-tile:hover { text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow-tpl); }
.bd-tile span { padding: 8px 10px; }
.bd-tile .bd-tile-icon { display: flex; align-items: center; justify-content: center; height: 72px; width: 100%; padding: 0; font-size: 28px; color: var(--brand-blue); background: var(--grad-hero); }
.bd-banners { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 12px; }
.bd-banners img { border-radius: 14px; display: block; }
.bd-blog { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.bd-blog-item { display: flex; flex-direction: column; gap: 8px; color: var(--text-dark); font-weight: 800; }
.bd-blog-item img { border-radius: 12px; aspect-ratio: 16 / 9; object-fit: cover; }

/* ---------- design page ---------- */
.bd-design-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(340px, .8fr); gap: 18px; align-items: start; margin-bottom: 18px; }
.bd-gallery { padding: 12px; border-radius: 18px; box-shadow: var(--shadow-tpl); border-color: rgba(15, 23, 42, .06); }
.bd-thumbs { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; }
.bd-thumb { border: 2px solid transparent; border-radius: 10px; padding: 0; background: none; cursor: pointer; }
.bd-thumb.is-active { border-color: var(--brand-blue); }
.bd-thumb img { border-radius: 8px; display: block; object-fit: cover; }
.bd-video { width: 100%; margin-top: 10px; border-radius: 12px; }
.bd-info { position: sticky; top: 10px; padding: 22px; display: flex; flex-direction: column; gap: 14px; border-radius: 18px; box-shadow: var(--shadow-tpl); border-color: rgba(15, 23, 42, .06); background: linear-gradient(180deg, rgba(124, 58, 237, .06), rgba(255, 255, 255, 0) 38%), #fff; }
.bd-info .templates-hero-eyebrow { align-self: flex-start; }
.bd-design-title { margin: 0; font-size: clamp(1.35rem, 1.2vw + 1rem, 1.85rem); font-weight: 950; letter-spacing: -.025em; line-height: 1.12; color: var(--ink-92); text-wrap: balance; }
.bd-about { margin: 0; color: var(--text-body); line-height: 1.6; }
.bd-actions { display: flex; flex-direction: column; gap: 10px; }
.bd-actions .templates-cta { font-size: 1.02rem; padding: 13px 16px; border-radius: 14px; }
.bd-actions .bd-btn-row .brand-btn { flex: 1 1 auto; height: 38px; }
.bd-fav-btn.is-active .material-icons { color: #e11d48; }
.bd-share { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding-top: 12px; border-top: 1px solid var(--line); }
.bd-share .bd-k { margin-right: 4px; }
.bd-share a, .bd-copy { display: inline-flex; width: 36px; height: 36px; border-radius: 10px; align-items: center; justify-content: center; background: #f4f6fb; color: var(--text-dark); border: 0; cursor: pointer; transition: background .16s, transform .16s; }
.bd-share a:hover, .bd-copy:hover { background: #e8edff; text-decoration: none; transform: translateY(-1px); }
.bd-share .material-icons, .bd-copy .material-icons { font-size: 18px; }
.bd-specs { list-style: none; margin: 0 0 14px; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; }
.bd-specs li { display: flex; flex-direction: column; gap: 3px; padding: 11px 13px; border: 1px solid rgba(226, 232, 240, .9); border-radius: 12px; background: linear-gradient(135deg, #fff, #f8fafc); font-weight: 700; color: var(--text-dark); }
.bd-sub-title { font-size: 1.05rem; margin: 16px 0 8px; }
.bd-reviews { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.bd-reviews li { padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; }
.bd-reviews p { margin: 4px 0 0; }

/* ---------- profile ---------- */
.bd-profile-head { position: relative; z-index: 1; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 18px; align-items: center; }
.bd-avatar { border-radius: 20px; object-fit: cover; box-shadow: 0 14px 36px rgba(15, 23, 42, .18); background: #fff; border: 3px solid #fff; }
.bd-profile-head .templates-hero-title { margin: 6px 0 2px; }
.bd-profile-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.bd-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 14px; padding: 6px; border-radius: 999px; background: rgba(56, 58, 63, .05); border: 1px solid var(--line-soft); width: fit-content; max-width: 100%; }
.bd-tabs .templates-pill { background: transparent; border: 0; font-size: .82rem; padding: 8px 13px; backdrop-filter: none; }
.bd-tabs .templates-pill:hover { background: rgba(255, 255, 255, .85); }
.bd-tabs .templates-pill.is-active { background: #fff; color: rgba(56, 58, 63, .95); box-shadow: 0 14px 35px rgba(10, 20, 30, .12); }
.bd-tabs .bd-count { background: rgba(56, 58, 63, .1); color: rgba(56, 58, 63, .75); }
.bd-members { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.bd-member { display: flex; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--line); border-radius: 14px; color: var(--text-dark); font-weight: 800; transition: transform .16s, box-shadow .16s; }
.bd-member:hover { text-decoration: none; transform: translateY(-2px); box-shadow: var(--shadow-tpl); }
.bd-member img { border-radius: 10px; object-fit: cover; }

/* ---------- forms, auth, dialogs ---------- */
.bd-form { display: flex; flex-direction: column; gap: 12px; }
.bd-form label { display: flex; flex-direction: column; gap: 6px; font-weight: 800; font-size: .86rem; color: var(--text-dark); }
.bd-form label.bd-check { flex-direction: row; font-weight: 500; }
.bd-form-row { display: flex; justify-content: flex-end; font-size: .88rem; font-weight: 700; }
.bd-field-error { color: #b42318; font-size: .82rem; margin-top: -6px; font-weight: 600; }
.has-error .brand-form-field { border-color: #f04438; }
.bd-form-msg { padding: 8px 10px; border-radius: 8px; font-size: .88rem; }
.bd-auth { display: grid; place-items: center; padding: 8px 0 28px; }
.bd-auth-card { width: min(480px, 100%); padding: 28px; display: flex; flex-direction: column; gap: 14px; border-radius: 18px; box-shadow: var(--shadow-tpl-hover); background: linear-gradient(180deg, rgba(124, 58, 237, .08), rgba(255, 255, 255, 0) 32%), #fff; }
.bd-auth-card .templates-hero-title { font-size: 1.75rem; }
.bd-auth-card .templates-hero-eyebrow { align-self: flex-start; }
.bd-google { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 44px; padding: 10px 16px; border: 1px solid #dadce0; border-radius: 10px; background: #fff; color: #3c4043; font-weight: 650; font-size: .92rem; text-decoration: none; transition: background .15s, box-shadow .15s; }
.bd-google:hover { background: #f8f9fa; box-shadow: 0 1px 3px rgba(60, 64, 67, .18); }
.bd-google:focus-visible { outline: 2px solid #4C6FFF; outline-offset: 2px; }
.bd-google img { flex: 0 0 auto; }
.bd-or { display: flex; align-items: center; gap: 10px; color: var(--text-muted); font-size: .8rem; }
.bd-or::before, .bd-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.bd-contact { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 14px; }
.bd-dialog { border: 0; border-radius: 18px; padding: 26px; width: min(440px, calc(100vw - 24px)); box-shadow: 0 40px 100px rgba(15, 23, 42, .35); }
.bd-dialog[open] { animation: bdPop .22s var(--ease); }
.bd-dialog::backdrop { background: rgba(15, 23, 42, .45); backdrop-filter: blur(3px); }
.bd-dialog-close { position: absolute; top: 12px; right: 12px; margin: 0; }
.bd-dialog-title { margin: 0 0 4px; font-size: 1.4rem; font-weight: 950; letter-spacing: -.02em; }

/* ---------- footer ---------- */
.bd-footer { margin-top: 26px; padding: 24px; border-radius: 18px; background: linear-gradient(135deg, rgba(15, 23, 42, .03), rgba(59, 130, 246, .04)); border-color: rgba(15, 23, 42, .06); box-shadow: none; }
.bd-footer-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(auto-fit, minmax(160px, 1fr)); gap: 24px; }
.bd-footer-about { color: var(--text-muted); font-size: .9rem; margin-top: 10px; }
.bd-footer-title { font-weight: 900; font-size: .76rem; text-transform: uppercase; letter-spacing: .07em; color: var(--text-dark); margin-bottom: 10px; }
.bd-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.bd-footer ul a { color: var(--text-body); font-size: .92rem; font-weight: 600; }
.bd-newsletter { display: flex; gap: 8px; }
.bd-newsletter .brand-btn { height: auto; }
.bd-social { display: flex; gap: 6px; margin-top: 12px; }
.bd-social a { display: inline-flex; width: 34px; height: 34px; border-radius: 10px; align-items: center; justify-content: center; background: #fff; color: var(--text-dark); border: 1px solid var(--line); transition: transform .16s; }
.bd-social a:hover { transform: translateY(-2px); text-decoration: none; }
.bd-social .material-icons { font-size: 18px; }
.bd-footer-bottom { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); font-size: .84rem; color: var(--text-muted); font-weight: 600; }

/* ---------- colour palette (design page): equal tiles, click to copy ---------- */
.bd-palette { margin: 16px 0 6px; padding-top: 14px; border-top: 1px solid var(--line-soft); }
.bd-palette-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.bd-palette-title { margin: 0; font-size: .72rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--text-muted); }
.bd-palette-tiles { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 12px 10px; }
.bd-color-tile { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; width: 100%; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; border-radius: 12px; }
.bd-color-chip { position: relative; display: block; width: 100%; height: 58px; margin-bottom: 7px; border-radius: 12px; background: var(--sw); box-shadow: 0 6px 16px rgba(15, 23, 42, .12); transition: transform .16s var(--ease), box-shadow .16s var(--ease); }
.bd-color-tile.is-light .bd-color-chip { box-shadow: inset 0 0 0 1px rgba(15, 23, 42, .14), 0 6px 16px rgba(15, 23, 42, .06); }
.bd-color-chip .material-icons { position: absolute; right: 7px; bottom: 7px; font-size: 16px; color: #fff; opacity: 0; transition: opacity .16s; }
.bd-color-tile.is-light .bd-color-chip .material-icons { color: #0b1220; }
.bd-color-tile:hover .bd-color-chip, .bd-color-tile:focus-visible .bd-color-chip { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(15, 23, 42, .18); }
.bd-color-tile.is-light:hover .bd-color-chip, .bd-color-tile.is-light:focus-visible .bd-color-chip { box-shadow: inset 0 0 0 1px rgba(15, 23, 42, .18), 0 10px 22px rgba(15, 23, 42, .12); }
.bd-color-tile:hover .material-icons, .bd-color-tile:focus-visible .material-icons { opacity: .85; }
.bd-color-tile.is-copied .material-icons { opacity: 1; }
.bd-color-tile:focus-visible { outline: 2px solid #4C6FFF; outline-offset: 3px; }
.bd-color-name { font-size: .8rem; font-weight: 750; color: var(--text-dark); line-height: 1.2; }
.bd-color-hex { font: 600 .72rem/1.3 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--text-muted); letter-spacing: .02em; }
.bd-color-role { font-size: .64rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); opacity: .75; }
.bd-preview-pill { position: fixed; right: 16px; bottom: 16px; z-index: 1400; display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 999px; background: #0b1220; color: #fff; font-size: .78rem; font-weight: 650; text-decoration: none; box-shadow: 0 8px 24px rgba(11, 18, 32, .25); }
.bd-preview-pill:hover { background: #1f2937; color: #fff; text-decoration: none; }
.bd-preview-pill .material-icons { font-size: 16px; }
.bd-cookie { position: fixed; left: 16px; bottom: 16px; z-index: 1500; max-width: 400px; display: flex; gap: 12px; align-items: center; padding: 12px 14px; background: rgba(255, 255, 255, .96); backdrop-filter: blur(10px); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 18px 45px rgba(15, 23, 42, .18); font-size: .84rem; animation: bdPop .3s var(--ease); }
.bd-toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 3000; background: #111827; color: #fff; padding: 10px 16px; border-radius: 12px; font-weight: 700; box-shadow: 0 18px 45px rgba(15, 23, 42, .3); animation: bdPop .2s var(--ease); }

/* ---------- account pages: messages, orders, settings ---------- */
.bd-profile-btn { position: relative; }
.bd-profile-badge { position: absolute; top: -6px; right: -6px; box-shadow: 0 0 0 2px #fff; }
.bd-badge { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: #e11d48; color: #fff; font-size: .7rem; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; line-height: 1; }
.bd-pill { display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 999px; background: #eef1f6; color: #414a5a; font-size: .74rem; font-weight: 750; white-space: nowrap; }
.bd-pill.is-green { background: #ecfdf3; color: #067647; }
.bd-pill.is-warn { background: #fff7e6; color: #8a5a00; }
.bd-card-heading { margin: 0 0 6px; font-size: 1.02rem; font-weight: 850; color: var(--text-dark); }
.bd-small { font-size: .8rem; }
.bd-account-head { display: flex; align-items: center; gap: 14px; margin: 4px 0 14px; }
.bd-account-head-avatar { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 3px #fff, 0 6px 16px rgba(15, 23, 42, .12); }
.bd-account-head-title { margin: 0; font-size: 1.55rem; font-weight: 900; letter-spacing: -.01em; color: var(--text-dark); }
.bd-account-head p { margin: 2px 0 0; font-size: .86rem; }
.bd-account-tabs { width: max-content; max-width: 100%; }
.bd-account-tabs .bd-badge { margin-left: 2px; }
.bd-subtabs { display: flex; gap: 18px; margin: 0 0 12px; border-bottom: 1px solid var(--line); }
.bd-subtabs a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 2px 10px; margin-bottom: -1px; border-bottom: 2px solid transparent; color: var(--text-muted); font-weight: 750; text-decoration: none; }
.bd-subtabs a[aria-current="page"] { color: var(--text-dark); border-bottom-color: var(--brand-blue); }
.bd-count { min-width: 22px; padding: 1px 7px; border-radius: 999px; background: #eef1f6; font-size: .72rem; text-align: center; }
.bd-backlink { display: inline-flex; align-items: center; gap: 4px; margin: 0 0 10px; color: var(--text-muted); font-weight: 700; font-size: .86rem; text-decoration: none; }
.bd-backlink .material-icons { font-size: 18px; }

/* messages: list + thread, one at a time on phones */
.bd-inbox { display: grid; grid-template-columns: minmax(260px, 340px) 1fr; gap: 14px; align-items: start; }
.bd-inbox-list { padding: 6px; max-height: calc(100vh - 170px); overflow-y: auto; }
.bd-convo { display: flex; align-items: flex-start; gap: 10px; padding: 10px; border-radius: 12px; color: var(--text-dark); text-decoration: none; position: relative; }
.bd-convo:hover { background: rgba(56, 58, 63, .05); text-decoration: none; }
.bd-convo.is-active { background: #eef4ff; }
.bd-convo-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex: 0 0 auto; }
.bd-convo-body { display: flex; flex-direction: column; gap: 1px; min-width: 0; flex: 1; }
.bd-convo-top { display: flex; justify-content: space-between; gap: 8px; }
.bd-convo-top strong { font-size: .88rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bd-convo-top time { flex: 0 0 auto; font-size: .72rem; color: var(--text-muted); }
.bd-convo-subject { font-size: .8rem; font-weight: 700; color: #414a5a; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bd-convo-last { font-size: .8rem; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bd-convo.is-unread .bd-convo-top strong, .bd-convo.is-unread .bd-convo-last { color: var(--text-dark); font-weight: 800; }
.bd-convo .bd-badge { position: absolute; right: 10px; bottom: 10px; }
.bd-thread { display: flex; flex-direction: column; padding: 0; min-height: 420px; max-height: calc(100vh - 170px); overflow: hidden; }
.bd-thread > .bd-empty { flex: 1; justify-content: center; }
.bd-thread-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--line-soft); }
.bd-thread-head img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.bd-thread-head form { margin: 0 0 0 auto; }
.bd-thread-who { display: flex; flex-direction: column; min-width: 0; }
.bd-thread-who a { color: var(--text-dark); text-decoration: none; }
.bd-thread-who .bd-muted { font-size: .8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bd-thread-back { display: none; }
.bd-thread-messages { list-style: none; margin: 0; padding: 16px 14px; display: flex; flex-direction: column; gap: 10px; overflow-y: auto; flex: 1; background: linear-gradient(180deg, #fbfcfe, #fff); }
.bd-msg { display: flex; flex-direction: column; max-width: 78%; }
.bd-msg.is-mine { align-self: flex-end; align-items: flex-end; }
.bd-msg.is-theirs { align-self: flex-start; }
.bd-msg-bubble { padding: 10px 13px; border-radius: 16px; font-size: .92rem; line-height: 1.45; overflow-wrap: anywhere; }
.bd-msg.is-theirs .bd-msg-bubble { background: #f1f3f7; color: var(--text-dark); border-bottom-left-radius: 5px; }
.bd-msg.is-mine .bd-msg-bubble { background: var(--brand-blue); color: #fff; border-bottom-right-radius: 5px; }
.bd-msg time { margin-top: 3px; font-size: .7rem; color: var(--text-muted); }
.bd-reply { display: flex; gap: 10px; align-items: flex-end; padding: 12px 14px; border-top: 1px solid var(--line-soft); }
.bd-reply textarea { resize: vertical; min-height: 46px; max-height: 200px; }
.bd-reply .templates-cta { flex: 0 0 auto; }

/* orders */
.bd-orders { padding: 6px; }
.bd-orders-row { display: grid; grid-template-columns: 1.1fr 1fr .9fr 1.2fr 1.1fr auto; gap: 12px; align-items: center; padding: 12px 10px; border-radius: 10px; color: var(--text-dark); text-decoration: none; }
a.bd-orders-row:hover { background: rgba(56, 58, 63, .05); text-decoration: none; }
.bd-orders-head { font-size: .72rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--text-muted); padding-top: 8px; padding-bottom: 6px; }
.bd-orders-row + .bd-orders-row:not(.bd-orders-head) { border-top: 1px solid var(--line-soft); }
.bd-orders-num, .bd-orders-total { font-weight: 800; }
.bd-orders-go { display: inline-flex; align-items: center; color: var(--brand-blue); font-weight: 750; font-size: .84rem; }
.bd-simple-pager { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 14px 0; }
.bd-order-grid { display: grid; grid-template-columns: 1fr minmax(260px, 340px); gap: 14px; align-items: start; }
.bd-order-side { display: flex; flex-direction: column; gap: 14px; }
.bd-order-lines { list-style: none; margin: 12px 0 0; padding: 0; }
.bd-order-lines li { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line-soft); }
.bd-order-lines img, .bd-order-noimg { width: 72px; height: 72px; border-radius: 12px; object-fit: cover; background: #eef1f6; flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; color: #b3b9c6; }
.bd-order-line-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.bd-order-line-main a { color: var(--text-dark); }
.bd-order-line-main .bd-muted { font-size: .82rem; }
.bd-order-line-side { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.bd-order-pills { display: flex; gap: 6px; flex-wrap: wrap; margin: 6px 0 10px; }
.bd-order-sum { margin: 0 0 12px; }
.bd-order-sum > div { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; font-size: .88rem; }
.bd-order-sum dt { color: var(--text-muted); }
.bd-order-sum dd { margin: 0; font-weight: 700; text-align: right; }
.bd-order-sum .is-total { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 10px; font-size: 1rem; }
.bd-order-sum .is-total dt { color: var(--text-dark); font-weight: 800; }

/* settings */
.bd-settings { display: grid; grid-template-columns: 220px 1fr; gap: 14px; align-items: start; }
.bd-settings-nav { display: flex; flex-direction: column; padding: 6px; position: sticky; top: 10px; }
.bd-settings-nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; color: var(--text-dark); font-weight: 700; font-size: .9rem; text-decoration: none; }
.bd-settings-nav a:hover { background: rgba(56, 58, 63, .05); text-decoration: none; }
.bd-settings-nav a[aria-current="page"] { background: #eef4ff; color: var(--brand-blue); }
.bd-settings-nav .material-icons { font-size: 19px; }
.bd-settings-ext { margin-left: auto; font-size: 15px !important; color: var(--text-muted); }
.bd-settings-main { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.bd-settings-card { padding: 18px; }
.bd-cover { position: relative; height: 150px; margin: 10px 0 56px; border-radius: 14px; background: linear-gradient(135deg, #e8eeff, #f6f1ff) center / cover no-repeat; }
.bd-cover-avatar { position: absolute; left: 18px; bottom: -44px; width: 96px; height: 96px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 4px #fff, 0 8px 20px rgba(15, 23, 42, .15); background: #fff; }
.bd-upload-row { display: flex; flex-wrap: wrap; gap: 8px; }
.bd-upload { margin: 0; }
.bd-upload label.brand-btn { cursor: pointer; }
.bd-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.bd-span-2 { grid-column: 1 / -1; }
.bd-form-narrow { max-width: 420px; }
.bd-form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.bd-field-error { font-weight: 600; font-size: .8rem; color: #b42318; }
.bd-hint { font-weight: 500; font-size: .78rem; color: var(--text-muted); }
.brand-form-field.has-error { border-color: #f04438; box-shadow: 0 0 0 3px rgba(240, 68, 56, .12); }
.bd-prefixed { display: flex; align-items: stretch; }
.bd-prefix { display: inline-flex; align-items: center; padding: 0 10px; border: 1px solid rgba(15, 23, 42, .16); border-right: 0; border-radius: 10px 0 0 10px; background: #f6f7fb; color: var(--text-muted); font-weight: 600; font-size: .82rem; white-space: nowrap; }
.bd-prefixed .brand-form-field { border-top-left-radius: 0; border-bottom-left-radius: 0; }
.bd-toggles { border: 0; margin: 0; padding: 0; }
.bd-toggles legend { font-weight: 800; font-size: .86rem; color: var(--text-dark); margin-bottom: 4px; }
.bd-label-icon { display: inline-flex; align-items: center; gap: 6px; }
.bd-label-icon .material-icons { font-size: 17px; color: #6b7280; }

/* ---------- responsive (dashboard breakpoints) ---------- */
@media (min-width: 1700px) {
    .bd-masonry { column-width: 230px; }
    .bd-justified { --h: 250px; }
    .teams-quickcards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 1100px) {
    .teams-quickcards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .bd-hide-md { display: none; }
    .bd-search { flex-basis: 260px; }
}
@media (max-width: 980px) {
    .templates-hero-root .templates-hero-inner { grid-template-columns: 1fr; padding: 18px; }
    .templates-hero-root .templates-hero-card.bd-hero-compact { padding: 18px; }
    .templates-hero-right { display: none; }
    .bd-design-grid, .bd-contact, .bd-spotlight { grid-template-columns: 1fr; }
    .bd-info { position: static; }
    .bd-profile-head { grid-template-columns: auto 1fr; }
    .bd-profile-actions { grid-column: 1 / -1; justify-content: flex-start; }
}
@media (max-width: 900px) {
    .bd-inbox { grid-template-columns: 1fr; }
    .bd-inbox.is-thread .bd-inbox-list, .bd-inbox:not(.is-thread) .bd-thread { display: none; }
    .bd-inbox-list, .bd-thread { max-height: none; }
    .bd-thread { min-height: 60vh; }
    .bd-thread-back { display: inline-flex; }
    .bd-order-grid, .bd-settings { grid-template-columns: 1fr; }
    .bd-settings-nav { position: static; flex-direction: row; overflow-x: auto; }
    .bd-settings-nav a { flex: 0 0 auto; }
    .bd-orders-head { display: none; }
    .bd-orders-row { grid-template-columns: 1fr auto; row-gap: 6px; }
    .bd-orders-row > span:nth-child(2), .bd-orders-row > span:nth-child(4) { order: 3; }
    .bd-orders-go { display: none; }
}
@media (max-width: 768px) {
    .bd-form-grid { grid-template-columns: 1fr; }
    .bd-msg { max-width: 88%; }
    .content-gutter { padding: 8px 2px 104px; }
    .teams-ui { padding: 0 8px; }
    .TheBrandNavMain { display: none; }
    .TheBrandMobileNavShell { display: block; position: fixed; left: 0; right: 0; bottom: 0; z-index: 90; background: #fff; box-shadow: 0 -6px 16px rgba(15, 23, 42, .12); padding: 8px 12px calc(10px + env(safe-area-inset-bottom)); overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
    .TheBrandMobileNavShell::-webkit-scrollbar { display: none; }
    .TheBrandMobileNavShell .TheBrandTabList { flex-direction: row; width: auto; gap: 8px; margin: 0; padding: 0 12px; }
    .TheBrandMobileNavShell .brand-icon-menu-btn { flex: 0 0 auto; }
    .TheBrandMobileNavShell .brand-icon-menu-btn a { width: 3.5em; height: 3.5em; padding: 6px; transition: all .2s ease-out; }
    .TheBrandMobileNavShell .brand-icon-menu-btn .material-icons { font-size: 22px; margin-top: .1em; color: #64748b; }
    .TheBrandMobileNavShell .brand-icon-menu-btn[aria-current="page"] a { color: #fff; background: #046bbf; box-shadow: 0 4px 12px rgba(4, 107, 191, .3); }
    .TheBrandMobileNavShell .brand-icon-menu-btn[aria-current="page"] .material-icons { color: #fff; }
    .TheBrandMobileNavShell .brand-icon-menu-btn span:not(.material-icons) { margin-top: .25em; font-size: .6rem; line-height: 1.1; width: auto; max-width: 100%; }
    .teams-header { flex-wrap: wrap; gap: 8px; }
    .bd-logo { --logo-h: 26px; }
    .bd-search { order: 3; flex: 1 1 100%; }
    .teams-quickcards { grid-template-columns: 1fr; }
    .teams-quickcard { min-height: 0; }
    .bd-masonry { column-width: 150px; column-gap: 10px; }
    .bd-masonry > .bd-card { margin-bottom: 10px; }
    .bd-grid { grid-template-columns: repeat(auto-fill, minmax(min(var(--min, 200px), 46%), 1fr)); gap: 10px; }
    .bd-row-track { --row-h: 170px; }
    .bd-justified { --h: 150px; gap: 10px; }
    .bd-hide-sm { display: none; }
    .bd-footer-grid { grid-template-columns: 1fr 1fr; }
    .bd-footer-brand, #newsletter { grid-column: 1 / -1; }
    .bd-cookie { left: 8px; right: 8px; bottom: 92px; max-width: none; }
    .bd-preview-pill { right: 8px; bottom: 96px; }
    .bd-palette-tiles { grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)); }
    .bd-color-chip { height: 50px; }
    .teams-popover { position: fixed; right: 12px; left: 12px; top: 64px; width: auto; }
    .bd-filter-panel { position: fixed; left: 12px; right: 12px; top: auto; bottom: 96px; width: auto; }
    .bd-promo-banner { aspect-ratio: 16 / 7; }
    .bd-card-body { padding: 8px 10px 10px; }
    .bd-card-title { font-size: .8rem; }
}
@media (prefers-reduced-motion: reduce) {
    .th-float-1, .th-float-2, .th-float-3, .th-float-4, .bd-card-media::before { animation: none; }
    *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
