:root,
:root[data-theme="pastel"] {
  --kb-ink: #29322e;
  --kb-muted: #66716b;
  --kb-forest: #315d49;
  --kb-forest-deep: #244838;
  --kb-orange: #df7b43;
  --kb-sky: #e9f0f1;
  --kb-sage: #e7ece4;
  --kb-apricot: #f2e7dc;
  --kb-porcelain: #fffdf8;
  --kb-paper: #faf7ef;
  --kb-canvas: #f3efe6;
  --kb-portrait: #eef1e9;
  --kb-portrait-line: rgba(48, 76, 62, .22);
  --kb-portrait-shadow: 0 2px 8px rgba(50, 69, 58, .08);
  --kb-line: rgba(48, 76, 62, .16);
  --kb-line-strong: rgba(48, 76, 62, .28);
  --kb-shadow: 0 18px 50px rgba(50, 69, 58, .11);
  --kb-good: #286246;
  --kb-good-soft: #dfece2;
  --kb-warn: #865021;
  --kb-warn-soft: #f7e5cf;
  --kb-bad: #873b35;
  --kb-bad-soft: #f3d9d4;
  --kb-info: #315f70;
  --kb-info-soft: #dcecf1;
  color-scheme: light;
}

html { background: var(--kb-canvas); }
body.theme-pastel {
  color: var(--kb-ink);
  background:
    radial-gradient(ellipse 42% 34% at 0 0, rgba(223, 238, 241, .3), transparent 74%),
    radial-gradient(ellipse 38% 32% at 100% 4%, rgba(244, 223, 207, .24), transparent 76%),
    linear-gradient(135deg, #f4f0e7 0%, #f8f4ec 54%, #f2eee5 100%);
  background-attachment: fixed;
}
.theme-pastel button:focus-visible,
.theme-pastel input:focus-visible,
.theme-pastel select:focus-visible,
.theme-pastel textarea:focus-visible,
.theme-pastel a:focus-visible {
  outline: 3px solid rgba(223, 123, 67, .45);
  outline-offset: 2px;
}

/* Shared V2/legacy contract */
.theme-pastel:not(.v3) {
  --bg: var(--kb-canvas);
  --surface: var(--kb-porcelain);
  --surface-2: var(--kb-paper);
  --text: var(--kb-ink);
  --muted: var(--kb-muted);
  --line: var(--kb-line);
  --accent: var(--kb-forest);
  --accent-soft: var(--kb-sage);
  --good: var(--kb-good);
  --good-soft: var(--kb-good-soft);
  --warn: var(--kb-warn);
  --warn-soft: var(--kb-warn-soft);
  --bad: var(--kb-bad);
  --bad-soft: var(--kb-bad-soft);
  --basis: #f4f1e9;
  --form: #f2eee8;
  --value: #edf3ec;
  --minutes: #edf2f2;
  --risk: #f7ece7;
  --shadow: var(--kb-shadow);
}
.theme-pastel:not(.v3) .sidebar {
  color: var(--kb-ink);
  border-right: 1px solid var(--kb-line);
  background: rgba(255, 253, 248, .94);
  box-shadow: 0 12px 34px rgba(56, 75, 64, .07);
}
.theme-pastel:not(.v3) .brand,
.theme-pastel:not(.v3) .legacy-link { color: var(--kb-ink); }
.theme-pastel:not(.v3) .brand-mark {
  color: #fff;
  background: linear-gradient(145deg, #4f735b, var(--kb-forest-deep));
  box-shadow: 0 5px 13px rgba(36, 72, 56, .2);
}
.theme-pastel:not(.v3) .brand small,
.theme-pastel:not(.v3) .sidebar-foot,
.theme-pastel:not(.v3) .league-picker label,
.theme-pastel:not(.v3) .league-picker small { color: var(--kb-muted); }
.theme-pastel:not(.v3) .sidebar-foot,
.theme-pastel:not(.v3) .league-picker { border-color: var(--kb-line); }
.theme-pastel:not(.v3) .league-picker,
.theme-pastel:not(.v3) .league-picker select,
.theme-pastel:not(.v3) .topbar,
.theme-pastel:not(.v3) .sub-nav {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: rgba(255, 253, 248, .94);
}
.theme-pastel:not(.v3) .nav-link { color: #56635c; }
.theme-pastel:not(.v3) .nav-link:hover,
.theme-pastel:not(.v3) .nav-link.active {
  color: var(--kb-forest-deep);
  background: var(--kb-sage);
}
.theme-pastel:not(.v3) .nav-link.active { box-shadow: inset 3px 0 var(--kb-forest); }
.theme-pastel:not(.v3) .data-table thead th,
.theme-pastel:not(.v3) .points-table .rank-cell,
.theme-pastel:not(.v3) .data-table th:first-child {
  color: #59655f;
  background: #f4f1e9;
}
.theme-pastel:not(.v3) .data-table tbody td,
.theme-pastel:not(.v3) .data-table td:first-child,
.theme-pastel:not(.v3) .points-table tbody .rank-cell {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: rgba(255, 253, 248, .94);
}
.theme-pastel:not(.v3) .data-table tbody tr:hover td {
  background: #f8f5ed;
  filter: none;
}
.theme-pastel:not(.v3) .toast {
  color: var(--kb-ink);
  border: 1px solid var(--kb-line-strong);
  background: var(--kb-porcelain);
}

/* V3 shell and component contract */
:root[data-theme="pastel"] {
  --v3-bg: var(--kb-canvas);
  --v3-sidebar: var(--kb-porcelain);
  --v3-surface: var(--kb-porcelain);
  --v3-surface-2: var(--kb-paper);
  --v3-surface-3: var(--kb-sage);
  --v3-line: var(--kb-line);
  --v3-text: var(--kb-ink);
  --v3-muted: var(--kb-muted);
  --v3-violet: var(--kb-forest);
  --v3-violet-light: var(--kb-forest);
  --v3-violet-soft: var(--kb-sage);
  --v3-good: var(--kb-good);
  --v3-warn: var(--kb-warn);
  --v3-bad: var(--kb-bad);
}
:root[data-theme="pastel"] body.v3 {
  --good-soft: var(--kb-good-soft);
  --warn-soft: var(--kb-warn-soft);
  --bad-soft: var(--kb-bad-soft);
  --basis: #f4f1e9;
  --form: #f2eee8;
  --value: #edf3ec;
  --minutes: #edf2f2;
  --risk: #f7ece7;
  --shadow: var(--kb-shadow);
}
.theme-pastel.v3 .v3-sidebar,
.theme-pastel.v3 .v3-topbar,
.theme-pastel.v3 .v3-workspace,
.theme-pastel.v3 .v3-page {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background-color: transparent;
}
.theme-pastel.v3 .v3-sidebar {
  background: rgba(255, 253, 248, .91);
  box-shadow: 0 12px 34px rgba(56, 75, 64, .07);
}
.theme-pastel.v3 .v3-topbar {
  border-bottom-color: var(--kb-line);
  background: rgba(255, 253, 248, .94);
  box-shadow: 0 12px 38px rgba(63, 79, 69, .1);
}
.theme-pastel.v3 .v3-brand {
  border: 1px solid var(--kb-line);
  border-radius: 9px;
  background: linear-gradient(145deg, var(--kb-porcelain), #f0ece3);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .72), 0 5px 16px rgba(50, 69, 58, .08);
}
.theme-pastel.v3 .v3-brand-logo {
  mix-blend-mode: multiply;
  filter: invert(1) grayscale(1) contrast(1.55);
}
.theme-pastel.v3 .v3-page h1,
.theme-pastel.v3 .v3-card-value {
  color: var(--kb-ink);
}
.theme-pastel.v3 .v3-club-rail {
  border-color: var(--kb-line);
  background: rgba(255, 253, 248, .88);
}
.theme-pastel.v3 .v3-nav-link,
.theme-pastel.v3 .v3-collapse,
.theme-pastel.v3 .v3-legacy-link { color: #56635c; }
.theme-pastel.v3 .v3-nav-link:hover,
.theme-pastel.v3 .v3-nav-link.active,
.theme-pastel.v3 .v3-collapse:hover,
.theme-pastel.v3 .v3-legacy-link:hover,
.theme-pastel.v3 .v3-club-button:hover,
.theme-pastel.v3 .v3-club-button.active {
  color: var(--kb-forest-deep);
  border-color: rgba(49, 93, 73, .16);
  background: var(--kb-sage);
}
.theme-pastel.v3 .club-filter-button.active {
  color: var(--kb-forest-deep);
  border-color: #91ad9a;
  background: var(--kb-sage);
  box-shadow: 0 5px 12px rgba(49, 93, 73, .11);
}
.theme-pastel.v3 .v3-club-rail > .club-filter .club-filter-button {
  width: 64px;
  height: 64px;
  flex-basis: 64px;
}
.theme-pastel.v3 .v3-club-rail > .club-filter .club-filter-button img {
  width: 54px;
  height: 54px;
}
.theme-pastel.v3 .v3-card,
.theme-pastel.v3 .v3-card.control-card,
.theme-pastel.v3 .panel,
.theme-pastel.v3 .table-panel,
.theme-pastel.v3 .filter-panel,
.theme-pastel.v3 .player-filter-panel,
.theme-pastel.v3 .compact-planner,
.theme-pastel.v3 .scout-decision,
.theme-pastel.v3 .scout-market,
.theme-pastel.v3 .loading-card,
.theme-pastel.v3 .empty-state,
.theme-pastel.v3 .v3-help-dialog,
.theme-pastel.v3 .mobile-filter-sheet {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: rgba(255, 253, 248, .95);
  box-shadow: var(--kb-shadow);
}
.theme-pastel.v3 .v3-popover,
.theme-pastel.v3 .v3-search-results,
.theme-pastel.v3 .v3-search-result,
.theme-pastel.v3 .v3-league-control,
.theme-pastel.v3 .v3-search,
.theme-pastel.v3 .v3-icon-button,
.theme-pastel.v3 .v3-profile,
.theme-pastel.v3 .control,
.theme-pastel.v3 select,
.theme-pastel.v3 input,
.theme-pastel.v3 textarea,
.theme-pastel.v3 option,
.theme-pastel.v3 .seller-filter,
.theme-pastel.v3 .factor-switch,
.theme-pastel.v3 .finance-kpi,
.theme-pastel.v3 .deadline-kpi,
.theme-pastel.v3 .finance-input,
.theme-pastel.v3 .opponent,
.theme-pastel.v3 .challenge-remove {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: var(--kb-porcelain);
}
.theme-pastel.v3 .v3-search-result:hover,
.theme-pastel.v3 .v3-quick-filter:hover,
.theme-pastel.v3 .v3-quick-filter.active,
.theme-pastel.v3 .position-chips button.active,
.theme-pastel.v3 .seller-filter button.active,
.theme-pastel.v3 .segment.active,
.theme-pastel.v3 .planner-tabs button.active {
  color: var(--kb-forest-deep);
  border-color: #9bb5a4;
  background: var(--kb-sage);
}
.theme-pastel.v3 .v3-card-controls button.active {
  color: var(--kb-forest-deep);
  border-color: #91ad9a;
  background: var(--kb-sage);
}
.theme-pastel.v3 .v3-card-controls button:not(.active) {
  color: var(--kb-muted);
  border-color: var(--kb-line);
  background: var(--kb-porcelain);
}
.theme-pastel.v3 .factor-switch button.active {
  color: #fff;
  border-color: var(--kb-forest-deep);
  background: var(--kb-forest);
}
.theme-pastel.v3 .v3-action.primary,
.theme-pastel.v3 .button.primary {
  color: #fff;
  border-color: var(--kb-forest-deep);
  background: linear-gradient(145deg, #4f735b, var(--kb-forest-deep));
  box-shadow: 0 8px 22px rgba(36, 72, 56, .18);
}
.theme-pastel.v3 .matchup-opponent b {
  color: #fff;
  background: var(--kb-forest-deep);
}
.theme-pastel.v3 .v3 .data-table,
.theme-pastel.v3 .data-table { color: var(--kb-ink); }
.theme-pastel.v3 .data-table thead th,
.theme-pastel.v3 .data-table th:first-child,
.theme-pastel.v3 .points-table .rank-cell,
.theme-pastel.v3 .position-divider td {
  color: #59655f;
  border-color: var(--kb-line);
  background: #f4f1e9 !important;
}
.theme-pastel.v3 .data-table tbody td,
.theme-pastel.v3 .data-table td:first-child,
.theme-pastel.v3 .points-table tbody .rank-cell {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: rgba(255, 253, 248, .94);
}
.theme-pastel.v3 .data-table tbody tr:nth-child(even) td { background: rgba(250, 247, 239, .9); }
.theme-pastel.v3 .data-table tbody tr:hover td,
.theme-pastel.v3 .data-table tbody tr:focus-within td {
  background: #f8f5ed;
  filter: none;
}
.theme-pastel.v3 .group-basis { background: #f4f1e9 !important; }
.theme-pastel.v3 .group-form { background: #f2eee8 !important; }
.theme-pastel.v3 .group-value { background: #edf3ec !important; }
.theme-pastel.v3 .group-minutes { background: #edf2f2 !important; }
.theme-pastel.v3 .group-risk { background: #f7ece7 !important; }
.theme-pastel.v3 .season-card { background: linear-gradient(145deg, var(--kb-porcelain), var(--kb-apricot)); }
.theme-pastel.v3 .status-badge,
.theme-pastel.v3 .signal.good,
.theme-pastel.v3 .mobile-signal.good {
  color: var(--kb-good);
  border-color: color-mix(in srgb, var(--kb-good) 28%, transparent);
  background: var(--kb-good-soft);
}
.theme-pastel.v3 .signal.warn,
.theme-pastel.v3 .mobile-signal.warn {
  color: var(--kb-warn);
  border-color: color-mix(in srgb, var(--kb-warn) 28%, transparent);
  background: var(--kb-warn-soft);
}
.theme-pastel.v3 .signal.bad,
.theme-pastel.v3 .mobile-signal.bad {
  color: var(--kb-bad);
  border-color: color-mix(in srgb, var(--kb-bad) 28%, transparent);
  background: var(--kb-bad-soft);
}
.theme-pastel.v3 .toast,
.theme-pastel.v3 .toast-root > * {
  color: var(--kb-ink);
  border: 1px solid var(--kb-line-strong);
  background: var(--kb-porcelain);
  box-shadow: var(--kb-shadow);
}
.theme-pastel.v3 .mobile-filter-backdrop,
.theme-pastel.v3 dialog::backdrop { background: rgba(41, 50, 46, .36); }

/* Transfer metadata stays legible as a quiet, independent surface family. */
.theme-pastel.v3 .transfer-position button,
.theme-pastel.v3 .transfer-club,
.theme-pastel.v3 .expiry,
.theme-pastel.v3 .mobile-row-meta > span:first-child,
.theme-pastel.v3 .mobile-expiry {
  color: #43544c;
  border-color: var(--kb-line);
  background: var(--kb-sage);
  box-shadow: inset 0 0 0 1px var(--kb-line);
}
.theme-pastel.v3 .transfer-position button,
.theme-pastel.v3 .transfer-club,
.theme-pastel.v3 .expiry,
.theme-pastel.v3 .mobile-row-meta > span:first-child,
.theme-pastel.v3 .mobile-expiry,
.theme-pastel.v3 .mobile-player-club {
  border-radius: 8px;
}
.theme-pastel.v3 .transfer-position button:hover {
  color: var(--kb-forest-deep);
  background: #dfe8df;
}
.theme-pastel.v3 .transfer-club strong,
.theme-pastel.v3 .expiry strong,
.theme-pastel.v3 .mobile-expiry strong {
  color: var(--kb-ink);
}
.theme-pastel.v3 .expiry small,
.theme-pastel.v3 .mobile-expiry small,
.theme-pastel.v3 .mobile-expiry.urgent {
  color: var(--kb-warn);
}
.theme-pastel.v3 .mobile-player-club {
  border-color: var(--kb-line-strong);
  background: rgba(255, 253, 248, .94);
  box-shadow: 0 3px 10px rgba(50, 69, 58, .12);
}
.theme-pastel.v3 .rank-result small,
.theme-pastel:not(.v3) .rank-result small {
  padding: 3px 6px;
  display: inline-flex;
  color: #3e5349;
  border: 1px solid rgba(49, 93, 73, .24);
  border-radius: 999px;
  background: #e7ece4;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .5);
}

/* Right-hand insight and information surfaces share the same paper contract. */
.theme-pastel.v3 .v3-insight-card {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: linear-gradient(145deg, var(--kb-porcelain), #f7f3ea);
  box-shadow: 0 8px 24px rgba(50, 69, 58, .08);
}
.theme-pastel.v3 .v3-insight-card h3,
.theme-pastel.v3 .v3-insight-row strong {
  color: var(--kb-ink);
}
.theme-pastel.v3 .v3-insight-row {
  color: var(--kb-muted);
  border-radius: 7px;
}
.theme-pastel.v3 .v3-insight-row:hover {
  background: var(--kb-paper);
}
.theme-pastel.v3 .v3-insight-row > span:first-child {
  color: var(--kb-forest-deep);
  border-radius: 999px;
  background: var(--kb-sage);
}
.theme-pastel.v3 .v3-insight-row em { color: var(--kb-good); }
.theme-pastel.v3 .v3-insight-row em.bad { color: var(--kb-bad); }
.theme-pastel.v3 .v3-quick-filter {
  color: var(--kb-forest-deep);
  border-color: var(--kb-line);
  background: var(--kb-sage);
}
.theme-pastel.v3 .v3-quick-filter:hover,
.theme-pastel.v3 .v3-quick-filter.active {
  color: #fff;
  border-color: var(--kb-forest-deep);
  background: var(--kb-forest);
}
.theme-pastel:not(.v3) .detail,
.theme-pastel:not(.v3) .watchlistSide,
.theme-pastel:not(.v3) .watchlistDetail,
.theme-pastel:not(.v3) .challengeSide,
.theme-pastel:not(.v3) .ligenSide,
.theme-pastel:not(.v3) .odds-import-side {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: var(--kb-porcelain);
}
.theme-pastel:not(.v3) .metric,
.theme-pastel:not(.v3) .watchMetricGrid > span,
.theme-pastel:not(.v3) .watchlistStats,
.theme-pastel:not(.v3) .ligenMeta,
.theme-pastel:not(.v3) .preview-list {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: var(--kb-paper);
}
.theme-pastel:not(.v3) .metric:hover,
.theme-pastel:not(.v3) .watchMetricGrid > span:hover {
  border-color: var(--kb-line-strong);
  background: #f4f1e9;
}

/* Product tier colors remain independent; S+ is the restrained dream tier. */
.theme-pastel .tier-button {
  flex-shrink: 0;
  color: var(--tier-color);
  border-color: var(--tier-color);
  background: color-mix(in srgb, var(--tier-color) 8%, var(--kb-paper));
}
.theme-pastel .player-tier { width: max-content; }
.theme-pastel .tier-s-plus { --tier-color: #8f1f2b; }
.theme-pastel .tier-s { --tier-color: #ff685f; }
.theme-pastel .tier-a { --tier-color: #ff993d; }
.theme-pastel .tier-b { --tier-color: #f2c84b; }
.theme-pastel .tier-c { --tier-color: #50bf78; }
.theme-pastel .tier-d { --tier-color: #7d8796; }
.theme-pastel .tier-button.active {
  color: #11141a;
  background: var(--tier-color);
}
.theme-pastel .tier-s-plus:hover:not(.active) {
  color: #6f1621;
  background: color-mix(in srgb, #8f1f2b 15%, var(--kb-paper));
  box-shadow: 0 3px 9px rgba(111, 22, 33, .14);
}
.theme-pastel .tier-s-plus.active {
  color: #fff;
  border-color: #68131d;
  background: linear-gradient(115deg, #5f1019 0%, #8f1f2b 34%, #bd4650 49%, #7c1824 66%, #551018 100%);
  box-shadow: 0 0 0 2px rgba(143, 31, 43, .22), 0 4px 12px rgba(95, 16, 25, .2);
}
.theme-pastel .tier-s-plus:focus-visible {
  outline: 3px solid #8f1f2b;
  outline-offset: 2px;
}

/* Quiet scouting-tape filter rail for the shared player-list contract. */
.theme-pastel.v3 .player-list-filter-rail {
  border-color: var(--kb-line);
  background: linear-gradient(100deg, var(--kb-porcelain), var(--kb-paper));
  box-shadow: 0 5px 16px rgba(49, 76, 62, .06);
}
.theme-pastel.v3 .player-list-filter-group legend { color: var(--kb-muted); }
.theme-pastel.v3 .player-list-filter-button:not(.tier-button) {
  color: var(--kb-muted);
  border-color: var(--kb-line);
  background: var(--kb-porcelain);
}
.theme-pastel.v3 .player-list-filter-button:not(.tier-button):hover {
  color: var(--kb-forest-deep);
  border-color: #91ad9a;
  background: #f4f5ef;
}
.theme-pastel.v3 .player-list-filter-button.active:not(.tier-button) {
  color: var(--kb-forest-deep);
  border-color: #75947f;
  background: var(--kb-sage);
  box-shadow: 0 3px 9px rgba(49, 93, 73, .1);
}
.theme-pastel.v3 .player-tier-head,
.theme-pastel.v3 .player-tier-cell {
  border-left-color: var(--kb-line);
  background: var(--kb-porcelain);
  box-shadow: none;
}
.theme-pastel.v3 .data-table th:first-child,
.theme-pastel.v3 .data-table td:first-child {
  border-right-color: var(--kb-line);
  box-shadow: none;
}
.theme-pastel.v3 .data-table tbody tr:hover .player-tier-cell { background: #f4f1e9; }

/* Standalone mobile app: preserve geometry, replace dark surfaces only. */
.theme-pastel.mobile-app {
  --bg: var(--kb-canvas);
  --panel: var(--kb-porcelain);
  --panel2: var(--kb-paper);
  --line: var(--kb-line);
  --text: var(--kb-ink);
  --muted: var(--kb-muted);
  --purple: var(--kb-forest);
  --green: var(--kb-good);
  --red: var(--kb-bad);
  --yellow: #a96326;
  --blue: var(--kb-info);
}
.theme-pastel.mobile-app .app-shell,
.theme-pastel.mobile-app .app-header,
.theme-pastel.mobile-app .club-rail,
.theme-pastel.mobile-app .league-rail,
.theme-pastel.mobile-app .bottom-nav {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: rgba(255, 253, 248, .95);
}
.theme-pastel.mobile-app .league-chip,
.theme-pastel.mobile-app .filter-button,
.theme-pastel.mobile-app .player-card,
.theme-pastel.mobile-app .panel,
.theme-pastel.mobile-app .segment,
.theme-pastel.mobile-app .sticky-summary,
.theme-pastel.mobile-app .squad-row,
.theme-pastel.mobile-app .formation-select,
.theme-pastel.mobile-app .matchup-tabs button,
.theme-pastel.mobile-app .game,
.theme-pastel.mobile-app .ranking-tabs button,
.theme-pastel.mobile-app .compact-row img,
.theme-pastel.mobile-app .stat,
.theme-pastel.mobile-app .settings-league input,
.theme-pastel.mobile-app .sale-input,
.theme-pastel.mobile-app .search-box,
.theme-pastel.mobile-app .secondary,
.theme-pastel.mobile-app .action {
  color: var(--kb-ink);
  border-color: var(--kb-line);
  background: var(--kb-porcelain);
  box-shadow: none;
}
.theme-pastel.mobile-app .club-button {
  flex-basis: 56px;
}
.theme-pastel.mobile-app .club-button img {
  width: 40px;
  height: 40px;
}
.theme-pastel.mobile-app .league-chip.active,
.theme-pastel.mobile-app .filter-button.active,
.theme-pastel.mobile-app .segment button.active,
.theme-pastel.mobile-app .matchup-tabs button.active,
.theme-pastel.mobile-app .ranking-tabs button.active,
.theme-pastel.mobile-app .lineup-pick.selected {
  color: var(--kb-forest-deep);
  border-color: #91ad9a;
  background: var(--kb-sage);
  box-shadow: 0 5px 12px rgba(49, 93, 73, .11);
}
.theme-pastel.mobile-app .signal {
  color: var(--kb-good);
  border-color: color-mix(in srgb, var(--kb-good) 28%, transparent);
  background: var(--kb-good-soft);
}
.theme-pastel.mobile-app .eyebrow,
.theme-pastel.mobile-app .bottom-nav button.active {
  color: var(--kb-forest);
}
.theme-pastel.mobile-app .bottom-nav button.active {
  background: var(--kb-sage);
}
.theme-pastel.mobile-app .primary {
  color: #fff;
  border-color: var(--kb-forest-deep);
  background: linear-gradient(145deg, #4f735b, var(--kb-forest-deep));
}
.theme-pastel.mobile-app .offline { color: #fff; background: var(--kb-bad); }
.theme-pastel.mobile-app .toast {
  color: var(--kb-ink);
  border: 1px solid var(--kb-line-strong);
  background: var(--kb-porcelain);
  box-shadow: var(--kb-shadow);
}

/*
 * Player portrait carrier contract.
 * This changes only our CSS backing surface and contour; image rendering,
 * cropping and source assets remain owned by the active component styles.
 */
.theme-pastel:not(.v3) .avatar,
.theme-pastel:not(.v3) .playerAvatar,
.theme-pastel.v3 .avatar,
.theme-pastel.v3 .challenge-player-cell > img:first-child,
.theme-pastel.v3 .challenge-avatar-placeholder,
.theme-pastel.v3 .v3-insight-avatar,
.theme-pastel.v3 .v3-insight-placeholder,
.theme-pastel.v3 .mobile-player-portrait-wrap,
.theme-pastel.v3 .mobile-player-portrait,
.theme-pastel.v3 .available-player-main > img,
.theme-pastel.v3 .available-avatar,
.theme-pastel.v3 .pool-player-image,
.theme-pastel.v3 .player-image-fallback,
.theme-pastel.mobile-app .pitch-player img,
.theme-pastel.mobile-app .compact-row > img,
.theme-pastel.mobile-app .squad-row > img {
  background: var(--kb-portrait);
  box-shadow: inset 0 0 0 1px var(--kb-portrait-line), var(--kb-portrait-shadow);
}
.theme-pastel.mobile-app .pitch-player img {
  border-color: var(--kb-portrait-line);
}

/* Integrated login */
.theme-pastel.login-page {
  --bg: var(--kb-canvas);
  --panel: var(--kb-porcelain);
  --panel-soft: var(--kb-paper);
  --line: var(--kb-line);
  --text: var(--kb-ink);
  --muted: var(--kb-muted);
  --violet: var(--kb-forest);
  --violet-light: var(--kb-forest);
  --violet-soft: var(--kb-sage);
  --danger: var(--kb-bad);
  --danger-soft: var(--kb-bad-soft);
}
.theme-pastel.login-page .brand-panel {
  color: var(--kb-ink);
  background:
    radial-gradient(circle at 20% 18%, rgba(233, 240, 241, .72), transparent 34%),
    linear-gradient(145deg, #f4f0e7 0%, #faf7ef 56%, #f2eee5 100%);
}
.theme-pastel.login-page .brand-panel::before,
.theme-pastel.login-page .brand-panel::after { border-color: var(--kb-line-strong); }
.theme-pastel.login-page .pitch-mark,
.theme-pastel.login-page .submit-button {
  color: #fff;
  background: linear-gradient(145deg, #4f735b, var(--kb-forest-deep));
  box-shadow: 0 14px 34px rgba(36, 72, 56, .2);
}
.theme-pastel.login-page .brand-copy > p:last-child,
.theme-pastel.login-page .privacy-note { color: var(--kb-muted); }
.theme-pastel.login-page .privacy-note span { color: var(--kb-good); }
.theme-pastel.login-page .form-panel {
  background:
    radial-gradient(circle at 85% 12%, rgba(242, 231, 220, .55), transparent 28%),
    var(--kb-porcelain);
}
.theme-pastel.login-page .theme-toggle { display: none !important; }

@media (max-width: 720px) {
  body.theme-pastel { background-attachment: scroll; }
  .theme-pastel.v3 .v3-club-rail > .club-filter .club-filter-button {
    width: 58px;
    height: 58px;
    flex-basis: 58px;
  }
  .theme-pastel.v3 .v3-club-rail > .club-filter .club-filter-button img {
    width: 48px;
    height: 48px;
  }
}

/* The compact transfer-market layout keeps its geometry, but shares Pastell. */
@media (max-width: 767px) {
  body.theme-pastel.v3.mobile-transfer-reference {
    color: var(--kb-ink);
    background: var(--kb-canvas);
  }
  .theme-pastel.mobile-transfer-reference .v3-workspace,
  .theme-pastel.mobile-transfer-reference .v3-page { background: var(--kb-canvas); }
  .theme-pastel.mobile-transfer-reference .v3-topbar,
  .theme-pastel.mobile-transfer-reference .v3-club-rail,
  .theme-pastel.mobile-transfer-reference .mobile-bottom-nav {
    color: var(--kb-ink);
    border-color: var(--kb-line);
    background: rgba(255, 253, 248, .96);
  }
  .theme-pastel.mobile-transfer-reference .v3-league-control,
  .theme-pastel.mobile-transfer-reference .mobile-icon-action {
    color: var(--kb-ink);
    border-color: var(--kb-line);
    background: var(--kb-porcelain);
  }
  .theme-pastel.mobile-transfer-reference .v3-eyebrow { color: var(--kb-forest); }
  .theme-pastel.mobile-transfer-reference .v3-page h1,
  .theme-pastel.mobile-transfer-reference .mobile-market-toolbar strong,
  .theme-pastel.mobile-transfer-reference .mobile-row-player h2,
  .theme-pastel.mobile-transfer-reference .mobile-row-market .mobile-market-price > strong,
  .theme-pastel.mobile-transfer-reference .mobile-row-market .mobile-expiry strong {
    color: var(--kb-ink);
  }
  .theme-pastel.mobile-transfer-reference .v3-subtitle,
  .theme-pastel.mobile-transfer-reference .mobile-market-toolbar > div span,
  .theme-pastel.mobile-transfer-reference .mobile-row-meta > span:first-child,
  .theme-pastel.mobile-transfer-reference .mobile-market-row .mobile-card-details summary {
    color: var(--kb-muted);
  }
  .theme-pastel.mobile-transfer-reference .mobile-filter-button {
    color: var(--kb-forest-deep);
    border-color: #91ad9a;
    background: var(--kb-sage);
    box-shadow: 0 5px 12px rgba(49, 93, 73, .1);
  }
  .theme-pastel.mobile-transfer-reference .mobile-market-list {
    border-color: var(--kb-line);
    background: var(--kb-porcelain);
    box-shadow: var(--kb-shadow-soft);
  }
  .theme-pastel.mobile-transfer-reference .mobile-market-card,
  .theme-pastel.mobile-transfer-reference .mobile-market-card.top-pick,
  .theme-pastel.mobile-transfer-reference .mobile-market-card.bigboy {
    color: var(--kb-ink);
    border-color: var(--kb-line);
    background: transparent;
  }
  .theme-pastel.mobile-transfer-reference .mobile-market-card.top-pick { box-shadow: inset 2px 0 #9aac9e; }
  .theme-pastel.mobile-transfer-reference .mobile-market-card.bigboy { box-shadow: inset 2px 0 #b18a2d; }
  .theme-pastel.mobile-transfer-reference .mobile-row-stats.mobile-card-metrics,
  .theme-pastel.mobile-transfer-reference .mobile-row-stats.mobile-card-metrics > div,
  .theme-pastel.mobile-transfer-reference .mobile-market-row .mobile-card-details summary,
  .theme-pastel.mobile-transfer-reference .player-tier-footer {
    border-color: var(--kb-line);
  }
  .theme-pastel.mobile-transfer-reference .mobile-row-main .mobile-icon-action {
    color: var(--kb-muted);
    background: var(--kb-paper);
  }
  .theme-pastel.mobile-transfer-reference .mobile-bottom-nav button { color: var(--kb-muted); }
  .theme-pastel.mobile-transfer-reference .mobile-bottom-nav button.active {
    color: var(--kb-forest-deep);
    background: var(--kb-sage);
  }
  .theme-pastel.mobile-transfer-reference .mobile-bottom-nav button.active svg { filter: none; }
}
