/**
 * SWAMI 777 — UI theme (swami777UIUX colors/layout)
 * Size density matches the OLD polished webapp (compact, readable on 430px),
 * NOT the oversized mock font sizes from the design HTML.
 *
 * Scale reference (old app):
 *   body ~14px, labels 11–13px, titles 14–15px bold, badges 44px, pills 40–44px tall
 */

:root {
  /* ── Palette (design kit) ── */
  --c-gold: #F5C542;
  --c-gold-dark: #E8B530;
  --c-cream: #F5EDE0;
  --c-cream-2: #FAF5EC;
  --c-cream-page: #FDF2DF;
  --c-cream-scroll: #F2E3C9;
  --c-pink: #C27580;
  --c-pink-alt: #C96884;
  --c-pink-dark: #B85572;
  --c-pink-light: #D47E96;
  --c-king: #4A2A2D;
  --c-king-alt: #7A3B3B;
  --c-red: #B8303E;
  --c-danger: #C62828;
  --c-danger-btn: #D32F2F;
  --c-green: #4CAF50;
  --c-green-result: #34B760;
  --c-green-wa: #25D366;
  --c-blue-call: #2196F3;
  --c-text: #1A1A1A;
  --c-text-2: #4A4A4A;
  --c-text-mute: #8A8A8A;
  --c-white: #FFF;
  --c-border: #EDE5D0;

  /* ── Compact density tokens (old webapp feel) ── */
  --ui-pad-x: 12px;
  --ui-pad-y: 10px;
  --ui-gap: 10px;
  --ui-radius-card: 14px;
  --ui-radius-pill: 22px;
  --ui-radius-md: 12px;
  --ui-fs-xs: 11px;
  --ui-fs-sm: 12px;
  --ui-fs-md: 13px;
  --ui-fs-base: 14px;
  --ui-fs-lg: 15px;
  --ui-fs-title: 15px;
  --ui-fs-name: 14px;
  --ui-ctrl-h: 40px;
  --ui-ctrl-h-sm: 36px;
  --ui-icon: 18px;
  --ui-fab: 52px;
  --ui-badge: 44px;
  --ui-tab-pad: 72px; /* bottom safe for tabbar + FAB */

  --shadow-sm: 0 1px 4px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 2px 10px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 6px 18px rgba(0, 0, 0, 0.10);
  --font-ui: Inter, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* Legacy brand bridge → pink theme */
  --brand-primary: var(--c-pink);
  --brand-primary-hover: var(--c-pink-dark);
  --brand-primary-light: rgba(194, 117, 128, 0.12);
  --brand-accent-start: var(--c-pink);
  --brand-accent-end: var(--c-pink-light);
  --brand-accent-solid: var(--c-pink);
  --brand-secondary: var(--c-pink-alt);
  --text-brand: var(--c-pink);
  --bg-body: var(--c-cream-page);
  --bg-card: #FFFFFF;
  --phone-bg: var(--c-cream-page);
  --phone-rail: #C4B59A;
  --success: #16a34a;
  --danger: #dc2626;
}

/* ═══════════════════════════════════════════
   GLOBAL THEME (all app pages)
   ═══════════════════════════════════════════ */
html {
  background: var(--phone-rail) !important;
}
body {
  font-family: var(--font-ui) !important;
  font-size: var(--ui-fs-base) !important;
  line-height: 1.4;
  background: var(--c-cream-page) !important;
  color: var(--c-text);
  -webkit-font-smoothing: antialiased;
}
body > .min-h-dvh,
.min-h-dvh,
.bg-gray-50,
.dark\:bg-gray-900 {
  background-color: var(--c-cream-page) !important;
}

/* Remap leftover maroon utilities → pink (theme consistency) */
.bg-\[\#C27580\],
.text-\[\#C27580\],
.border-\[\#C27580\] {
  /* handled via more specific overrides below */
}
[class*="bg-[#C27580]"],
[style*="#C27580"] {
  /* inline styles still win; PHP pages gradually migrate */
}

/* Common brand solid / text remaps used across pages */
.text-\[\#C27580\] { color: var(--c-pink) !important; }
.bg-\[\#C27580\] { background-color: var(--c-pink) !important; }
.border-\[\#C27580\] { border-color: var(--c-pink) !important; }
.border-\[\#C27580\]\/25 { border-color: rgba(194, 117, 128, 0.25) !important; }
.border-\[\#C27580\]\/20 { border-color: rgba(194, 117, 128, 0.2) !important; }
.border-\[\#C27580\]\/35 { border-color: rgba(194, 117, 128, 0.35) !important; }
.bg-\[\#C27580\]\/08,
.bg-\[\#C27580\]\/10 { background-color: rgba(194, 117, 128, 0.1) !important; }
.from-\[\#C27580\] { --tw-gradient-from: var(--c-pink) !important; }
.to-\[\#C45A6E\],
.to-\[\#C96884\] { --tw-gradient-to: var(--c-pink-light) !important; }

/*
 * UNIFY inner sticky headers → cream chrome (same language as Funds / My Bids hub)
 * Full pink bars looked inconsistent with the cream design system.
 */
body.bg-gray-50,
body.h-full.bg-gray-50,
.min-h-dvh.bg-gray-50,
.bg-gray-50.min-h-dvh,
div.min-h-dvh.bg-gray-50,
div.bg-gray-50 {
  background: var(--c-cream-scroll, #F2E3C9) !important;
}
/* Don't force cream on input fields that use bg-gray-50 intentionally */
input.bg-gray-50,
textarea.bg-gray-50,
button.bg-gray-50,
.star-btn.bg-gray-50 {
  background: #f9fafb !important;
}

header.sticky.top-0.z-40.h-14,
header.sticky.top-0.z-40.min-h-\[56px\],
header[style*="background:#C27580"],
header[style*="background: #C27580"],
header[style*="C27580"]:not(.app-top-header) {
  background: var(--c-cream-scroll, #F2E3C9) !important;
  box-shadow: none !important;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06) !important;
  min-height: 52px !important;
  height: auto !important;
  padding-top: 8px !important;
  padding-bottom: 8px !important;
}
/* Title / subtitle: dark on cream */
header.sticky.top-0.z-40 .text-white,
header[style*="C27580"] .text-white,
header.sticky.top-0.z-40 h1 {
  color: #111 !important;
}
header.sticky.top-0.z-40 .text-white\/70,
header.sticky.top-0.z-40 [class*="text-white/70"] {
  color: #6B6B6B !important;
}
/* Back / icon circles: soft cream chip, dark icon */
header.sticky.top-0.z-40 a.bg-white\/20:not([href="/wallet"]):not([href*="wallet"]),
header.sticky.top-0.z-40 button.bg-white\/20,
header.sticky.top-0.z-40 a.rounded-full.bg-white\/20 {
  background: #EDE0C8 !important;
  color: #111 !important;
}
/* Wallet pill stays pink */
header.sticky.top-0.z-40 a[href="/wallet"].bg-white\/20,
header.sticky.top-0.z-40 a[href="/wallet"],
header.sticky.top-0.z-40 a[href*="wallet"].flex.items-center.gap-1\.5 {
  background: var(--c-pink) !important;
  color: #fff !important;
}
header.sticky.top-0.z-40 .text-sm { font-size: 14px !important; line-height: 1.25 !important; font-weight: 800 !important; }
header.sticky.top-0.z-40 .text-xs { font-size: 11px !important; }
header.sticky.top-0.z-40 .w-9.h-9,
header.sticky.top-0.z-40 .w-8.h-8 {
  width: 36px !important;
  height: 36px !important;
}

/* ═══════════════════════════════════════════
   TOP HEADER — compact pink pills
   ═══════════════════════════════════════════ */
header.app-top-header,
.app-top-header {
  position: sticky !important;
  top: 0;
  z-index: 40;
  background: var(--c-cream-page) !important;
  box-shadow: none !important;
  border: 0 !important;
  padding: 0 !important;
}
.app-header-bar {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px var(--ui-pad-x) 6px !important;
  min-height: 0 !important;
  background: var(--c-cream-page) !important;
}
.app-header-left {
  flex: 1;
  min-width: 0;
  display: flex !important;
  align-items: center;
}
.app-header-menu,
button.app-header-menu {
  flex: 1;
  display: flex !important;
  align-items: center;
  gap: 8px;
  background: var(--c-pink) !important;
  color: #fff !important;
  border: none !important;
  border-radius: var(--ui-radius-pill) !important;
  padding: 0 12px !important;
  min-height: var(--ui-ctrl-h) !important;
  height: var(--ui-ctrl-h) !important;
  width: auto !important;
  max-width: 100%;
  box-shadow: 0 1px 4px rgba(194, 117, 128, 0.28);
  cursor: pointer;
  text-align: left;
}
.app-header-menu svg {
  width: var(--ui-icon) !important;
  height: var(--ui-icon) !important;
  flex-shrink: 0;
  stroke: #fff !important;
  color: #fff !important;
}
.app-header-logo { display: none !important; }
.app-header-brand-text {
  font-size: var(--ui-fs-lg);
  font-weight: 800;
  letter-spacing: 0.3px;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1;
}
.app-header-right {
  display: flex !important;
  align-items: center;
  gap: 6px !important;
  flex-shrink: 0;
}
#headerWalletLink,
a#headerWalletLink {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 2px;
  background: var(--c-pink) !important;
  color: #fff !important;
  border-radius: var(--ui-radius-pill) !important;
  padding: 0 12px !important;
  min-height: var(--ui-ctrl-h) !important;
  height: var(--ui-ctrl-h) !important;
  min-width: 72px;
  max-width: 120px;
  font-size: var(--ui-fs-md) !important;
  font-weight: 800 !important;
  box-shadow: 0 1px 4px rgba(194, 117, 128, 0.28);
  text-decoration: none !important;
}
#headerWalletLink svg { display: none; }
#headerWalletBalance {
  font-size: var(--ui-fs-md);
  font-weight: 800;
  line-height: 1;
  color: #fff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#headerRefreshBtn,
.app-refresh-btn { display: none !important; }

a.app-header-bell,
.app-header-bell {
  width: var(--ui-ctrl-h) !important;
  height: var(--ui-ctrl-h) !important;
  min-width: var(--ui-ctrl-h);
  border-radius: 50% !important;
  background: transparent !important;
  color: var(--c-pink) !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: none !important;
}
.app-header-bell svg {
  width: 22px !important;
  height: 22px !important;
  fill: var(--c-pink) !important;
  stroke: none !important;
}

/* ═══════════════════════════════════════════
   BOTTOM TAB BAR — compact + FAB
   ═══════════════════════════════════════════ */
nav.app-tabbar,
.app-tabbar {
  position: fixed !important;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 40;
  display: flex !important;
  justify-content: space-around;
  align-items: flex-end;
  background: #fff !important;
  border-top: 1px solid var(--c-border) !important;
  padding: 6px 2px max(8px, env(safe-area-inset-bottom, 0px)) !important;
  box-shadow: 0 -1px 8px rgba(0, 0, 0, 0.04);
  min-height: 56px;
}
.app-tabbar .tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 52px;
  padding: 2px 4px 4px;
  color: #8A8A8A;
  font-size: 10px;
  font-weight: 600;
  text-decoration: none !important;
  background: none;
  border: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.app-tabbar .tab svg {
  width: 22px;
  height: 22px;
  /* Solid icons (Material-style paths) + stroke fallback */
  fill: currentColor;
  stroke: currentColor;
  stroke-width: 0.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.app-tabbar .tab.active:not(.tab-center) { color: #333; }
.app-tabbar .tab.tab-center {
  width: var(--ui-fab);
  height: var(--ui-fab);
  min-width: var(--ui-fab);
  border-radius: 50%;
  background: var(--c-pink);
  color: #fff !important;
  transform: translateY(-12px);
  box-shadow: 0 3px 10px rgba(194, 117, 128, 0.4);
  padding: 0;
  gap: 0;
  align-self: flex-end;
}
.app-tabbar .tab.tab-center svg {
  width: 24px;
  height: 24px;
  fill: #fff;
  stroke: #fff;
  stroke-width: 0.5;
}
.app-tabbar .tab.tab-center span { display: none; }
.app-tabbar .tab span {
  font-size: 10px;
  font-weight: 600;
  line-height: 1.1;
}

/* Generic main padding for tabbar on shell pages */
main.flex-1,
main.home-main {
  padding-bottom: calc(var(--ui-tab-pad) + env(safe-area-inset-bottom, 0px)) !important;
}

/* ═══════════════════════════════════════════
   HOME PAGE
   ═══════════════════════════════════════════ */
.home-page main,
main.home-main {
  background: var(--c-cream-scroll) !important;
}
.home-scroll {
  padding: 6px var(--ui-pad-x) 16px;
  background: var(--c-cream-scroll);
}

/* King markets */
.king-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--ui-gap);
  margin-bottom: 12px;
}
.king-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--c-king);
  color: #fff;
  border: 1.5px solid #111;
  border-radius: var(--ui-radius-pill);
  padding: 3px 10px 3px 3px;
  text-decoration: none !important;
  min-height: var(--ui-ctrl-h);
  height: var(--ui-ctrl-h);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.king-play {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}
.king-play::after {
  content: '';
  width: 0;
  height: 0;
  border-left: 10px solid #111;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  margin-left: 2px;
}
.king-label {
  color: #fff;
  font-size: var(--ui-fs-sm);
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: 0.1px;
}

/* Support + actions */
.quick-card {
  background: linear-gradient(180deg, #FFF8D6 0%, #FBEFB0 100%);
  border-radius: var(--ui-radius-card);
  padding: 10px;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(0, 0, 0, 0.04);
}
.support-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 8px;
}
.support-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border-radius: var(--ui-radius-pill);
  padding: 3px 10px 3px 3px;
  text-decoration: none !important;
  color: #111 !important;
  box-shadow: var(--shadow-sm);
  font-size: var(--ui-fs-sm);
  font-weight: 700;
  min-height: var(--ui-ctrl-h-sm);
  height: var(--ui-ctrl-h-sm);
  overflow: hidden;
}
.support-pill .ic {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.support-pill .ic svg {
  width: 15px;
  height: 15px;
  fill: #fff;
}
.support-pill.call .ic { background: var(--c-blue-call); }
.support-pill.wa .ic { background: var(--c-green-wa); }
.support-pill span:last-child {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.action-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.action-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  border: none;
  border-radius: var(--ui-radius-pill);
  padding: 3px 10px 3px 3px;
  color: #fff !important;
  font-size: var(--ui-fs-sm);
  font-weight: 800;
  text-decoration: none !important;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  min-height: var(--ui-ctrl-h);
  height: var(--ui-ctrl-h);
  letter-spacing: 0.2px;
}
.action-btn .ic {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 900;
}
.action-btn.add { background: var(--c-green); }
.action-btn.add .ic { color: var(--c-green); }
.action-btn.withdraw { background: var(--c-danger-btn); }
.action-btn.withdraw .ic { color: var(--c-danger-btn); }
.action-btn.withdraw .ic svg {
  width: 15px;
  height: 15px;
  stroke: var(--c-danger-btn);
  fill: none;
}

/* Search */
.home-market-search { margin-bottom: 12px; }
.home-market-search .market-search-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid rgba(194, 117, 128, 0.3);
  border-radius: 18px;
  padding: 4px 8px 4px 6px;
  box-shadow: var(--shadow-sm);
}
.home-market-search .market-search-icon {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: var(--c-pink);
  flex-shrink: 0;
}
.home-market-search .market-search-icon svg {
  width: 14px;
  height: 14px;
}
.home-market-search .market-search-input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  font-size: var(--ui-fs-sm);
  font-weight: 600;
  color: #111;
  padding: 6px 0;
  font-family: inherit;
}
.home-market-search .market-search-input::placeholder {
  color: #A0A0A0;
  font-weight: 500;
  font-size: var(--ui-fs-sm);
}
.home-market-search .market-search-clear {
  width: 24px;
  height: 24px;
  border: 0;
  border-radius: 999px;
  background: #F3F4F6;
  color: #6B7280;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  line-height: 1;
}

/* Game cards — compact like old market cards */
.home-games {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-bottom: 4px;
}
.tg-game-card {
  background: #fff;
  border-radius: var(--ui-radius-card);
  padding: 12px 12px 10px;
  box-shadow: var(--shadow-sm);
  position: relative;
  border: 1px solid rgba(0, 0, 0, 0.04);
}
.tg-game-card .card-top {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.tg-game-card .card-badge {
  width: var(--ui-badge);
  height: var(--ui-badge);
  background: var(--c-pink);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  font-size: 16px;
  letter-spacing: 0.3px;
  flex-shrink: 0;
}
.tg-game-card .card-title-wrap {
  flex: 1;
  min-width: 0;
  padding-right: 24px;
}
.tg-game-card .card-title {
  font-weight: 800;
  font-size: var(--ui-fs-name);
  color: #111;
  letter-spacing: 0.2px;
  line-height: 1.2;
  text-transform: uppercase;
  word-break: break-word;
}
.tg-game-card .card-result {
  margin-top: 4px;
  color: var(--c-green-result);
  font-weight: 800;
  font-size: var(--ui-fs-md);
  letter-spacing: 1px;
  font-variant-numeric: tabular-nums;
}
/* Single result-chart icon — only next to Play/Closed (no duplicate) */
.tg-chart-btn {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none !important;
  background: rgba(194, 117, 128, 0.1);
  border: 1.5px solid rgba(194, 117, 128, 0.35);
  color: var(--c-pink, #C27580);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  transition: transform 0.12s ease, background 0.12s ease;
}
.tg-chart-btn:active {
  transform: scale(0.95);
  background: rgba(194, 117, 128, 0.18);
}
.tg-chart-btn svg {
  width: 18px;
  height: 18px;
}
.tg-game-card .card-bottom {
  margin-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 8px;
}
.tg-game-card .card-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.tg-game-card .status-text {
  color: var(--c-danger);
  font-weight: 600;
  font-size: var(--ui-fs-sm);
  line-height: 1.25;
}
.tg-game-card .status-text.open { color: var(--c-green); }
.tg-game-card .timing {
  margin-top: 2px;
  color: #333;
  font-weight: 600;
  font-size: var(--ui-fs-xs);
  line-height: 1.3;
}
.tg-game-card .status-pill {
  background: var(--c-danger);
  color: #fff !important;
  border: none;
  border-radius: 16px;
  padding: 6px 14px;
  font-weight: 700;
  font-size: var(--ui-fs-sm);
  cursor: pointer;
  text-decoration: none !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 78px;
  font-family: inherit;
  flex-shrink: 0;
  line-height: 1;
}
.tg-game-card .status-pill.open { background: var(--c-green); }
.tg-game-card .status-pill:disabled {
  opacity: 0.95;
  cursor: not-allowed;
}
.tg-game-card[data-search-hidden="1"] { display: none !important; }
.home-empty {
  text-align: center;
  padding: 20px 14px;
  background: #fff;
  border-radius: var(--ui-radius-card);
  color: var(--c-text-mute);
  font-weight: 600;
  font-size: var(--ui-fs-sm);
  box-shadow: var(--shadow-sm);
}
#marketSearchEmpty {
  display: none;
  text-align: center;
  padding: 18px 12px;
  border-radius: 12px;
  border: 1px dashed rgba(194, 117, 128, 0.35);
  background: #FFF8F0;
  color: var(--c-pink);
  font-weight: 700;
  font-size: var(--ui-fs-sm);
  margin-top: 6px;
}
#marketSearchEmpty.is-visible { display: block; }

/* Closed market modal */
.market-closed-modal__icon { color: var(--c-pink) !important; }
.market-closed-modal__btn {
  background: var(--c-pink) !important;
  font-size: var(--ui-fs-md) !important;
  min-height: 42px !important;
  border-radius: 12px !important;
}
.market-closed-modal__title { font-size: 16px !important; }
.market-closed-modal__body { font-size: var(--ui-fs-sm) !important; }

/* ═══════════════════════════════════════════
   SIDEBAR DRAWER — compact pink icons
   ═══════════════════════════════════════════ */
.sidebar {
  background: #fff !important;
  font-size: var(--ui-fs-base);
}
.sb-top {
  background: #fff !important;
  color: #111 !important;
  border-bottom: 1px solid var(--c-border);
  padding: 14px 14px 12px !important;
  position: relative;
}
.sb-user-row {
  gap: 12px !important;
  padding-right: 32px !important;
}
.sb-avatar {
  width: 48px !important;
  height: 48px !important;
  background: var(--c-pink) !important;
  border: none !important;
  color: #fff !important;
  font-size: 18px !important;
  font-weight: 800 !important;
}
.sb-user-name {
  color: #111 !important;
  font-size: var(--ui-fs-lg) !important;
  font-weight: 800 !important;
  line-height: 1.25 !important;
}
.sb-user-phone {
  color: #6B6B6B !important;
  font-size: var(--ui-fs-sm) !important;
  font-weight: 600 !important;
}
.sb-user-bal {
  color: #6BA3B5 !important;
  font-size: var(--ui-fs-xs) !important;
  font-weight: 600 !important;
}
.sb-close {
  background: transparent !important;
  color: #C53030 !important;
  top: 10px !important;
  right: 10px !important;
  width: 28px !important;
  height: 28px !important;
}
.sb-close svg { stroke: #C53030 !important; width: 16px !important; height: 16px !important; }

.sb-nav {
  padding: 6px 0 12px !important;
  gap: 0 !important;
}
.sb-item {
  display: flex !important;
  align-items: center;
  gap: 12px !important;
  padding: 9px 14px !important;
  color: #111 !important;
  text-decoration: none !important;
  font-weight: 600 !important;
  font-size: var(--ui-fs-md) !important;
  border: 0 !important;
  background: transparent !important;
  min-height: 44px !important;
  border-radius: 0 !important;
}
.sb-item:hover,
.sb-item:active,
.sb-item.is-active {
  background: #FFF5E0 !important;
  color: #111 !important;
}
.sb-item:hover .sb-ico,
.sb-item.is-active .sb-ico {
  color: #fff !important;
}
.sb-ico {
  width: 36px !important;
  height: 36px !important;
  min-width: 36px;
  border-radius: 50% !important;
  background: var(--c-pink) !important;
  color: #fff !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(194, 117, 128, 0.28);
}
.sb-ico svg {
  width: 18px !important;
  height: 18px !important;
  stroke: #fff !important;
  color: #fff !important;
}
.sb-label {
  flex: 1;
  font-weight: 700;
  font-size: var(--ui-fs-md);
  color: #111;
  line-height: 1.25;
}
.sb-chev { display: none !important; }
.sb-bottom {
  border-top: 1px solid #EEE;
  padding: 6px 0 10px;
  box-shadow: none !important;
  background: #fff !important;
}
.sb-logout .sb-ico {
  background: #E53E3E !important;
  box-shadow: 0 2px 6px rgba(229, 62, 62, 0.25);
}
.sb-logout .sb-label { color: #E53E3E !important; }
.sb-logout:hover { background: #FEF2F2 !important; }

/* ═══════════════════════════════════════════
   INNER PAGES — shared cream theme polish
   (wallet / bids / support / settings shells)
   ═══════════════════════════════════════════ */
.page-card,
.card,
.rounded-2xl.bg-white,
.rounded-xl.bg-white,
.bg-white.rounded-2xl,
.bg-white.shadow-sm {
  box-shadow: var(--shadow-sm);
}
/* Primary buttons still using maroon class hooks */
button.bg-\[\#C27580\],
a.bg-\[\#C27580\],
.btn-primary {
  background: var(--c-pink) !important;
}
/* Funds / wallet accent bars */
.h-1.w-full[style*="#C27580"],
.h-0\.5.w-full[style*="#C27580"] {
  background: linear-gradient(to right, var(--c-pink), var(--c-pink-light)) !important;
}

/* Reduce oversized Tailwind text on themed pages */
.home-page .text-base { font-size: var(--ui-fs-base) !important; }
.home-page .text-sm { font-size: var(--ui-fs-sm) !important; }
.home-page .text-xs { font-size: var(--ui-fs-xs) !important; }

@media (max-width: 360px) {
  :root {
    --ui-fs-name: 13px;
    --ui-badge: 40px;
    --ui-ctrl-h: 38px;
    --ui-fab: 48px;
  }
  .king-label { font-size: 11px; }
  .action-btn, .support-pill { font-size: 11px; }
  .app-header-brand-text { font-size: 13px; }
}
