/* =========================================================================
   BaseTrace Design System — Foundation Stylesheet
   Direction: Supercell Event Site Tokens × Muffin Gaming Aesthetic
   Tokens: Pitch Black #000000 | Card #141414 | Border #2a2a2a | Text #FFFFFF
   Primary Orange: #EE8F00 (3D Shadow: #BB5C00, Ink: #170C00)
   Display Font: Barlow Condensed | Body Font: Barlow
   ========================================================================= */

/* Clash of Clans game font (U6.3: font-display: swap verified) */
@font-face {
  font-family: 'BTGame';
  src: url('https://cdn.jsdelivr.net/gh/utkarshsah/assets@2f047b18b90cdbbd7e1ac85271aa5a2feff87cb6/Clash_Bold.otf') format('opentype');
  font-display: swap;
}

:root {
  /* Surfaces & Canvas (U5: blue-tinted stone) */
  --bt-color-page: #07080c;
  --bt-color-card: #161921;
  --bt-color-card-border: #323847;
  --bt-color-divider: #323847;
  --bt-color-stone-top: #20242e;
  --bt-color-stone-bottom: #161921;
  --bt-color-stone-edge: #0c0e13;

  /* Typography (U5: warm white, secondary, muted, tile label) */
  --bt-color-text: #f4f1ea;
  --bt-color-muted: #8a90a3;
  --bt-color-secondary: #a9afbf;
  --bt-color-tile-label: #9aa3ba;

  /* Primary Accent Tokens (swappable per palette) */
  --bt-accent: #f1a533;
  --bt-accent-light: #ffd36b;
  --bt-accent-dark: #b9731a;
  --bt-accent-shadow: #844f04;
  --bt-accent-ink: #170c00;

  /* Aliases for backwards compatibility */
  --bt-color-primary: var(--bt-accent);
  --bt-color-primary-shadow: var(--bt-accent-shadow);
  --bt-color-primary-ink: var(--bt-accent-ink);

  /* Accent Amber (highlights only, sparingly) */
  --bt-color-accent: #f1a533;

  /* Semantic - Destructive / Report / Tripled (Red) */
  --bt-color-danger: #d4443a;
  --bt-color-danger-shadow: #970202;
  --bt-color-danger-tint: #ff9a9a;
  --bt-color-report-text: #e58c85;

  /* Semantic - Verified / Info / Defended (Steel Blue) */
  --bt-color-info: #3e7bc4;
  --bt-color-info-shadow: #202c44;
  --bt-color-info-tint: #6db8f5;
  --bt-color-info-bg: #161921;
  --bt-color-info-border: #323847;

  /* Secondary Button Stone */
  --bt-btn-sec-bg: linear-gradient(180deg, #2c3b57 0%, #202c44 100%);
  --bt-btn-sec-border: #323847;
  --bt-btn-sec-shadow: 0 2px 0 #0c0e13;

  /* Semantic - Preliminary / Premium (Purple) */
  --bt-color-prelim: #8900cc;
  --bt-color-prelim-tint: #c77bf0;
  --bt-color-prelim-bg: #240636;
  --bt-color-prelim-border: #5d018b;

  /* Semantic - Live */
  --bt-color-live: #db2c1c;

  /* Semantic - Stars */
  --bt-color-star: #f1a533;
  --bt-color-star-dim: #323847;

  /* Ambient Radial Glows */
  --bt-glow-top: #3a0f66;
  --bt-glow-bottom: #4a0a14;

  /* Strict Spacing Scale: 4, 8, 12, 16, 24, 28, 32, 80 */
  --bt-space-4: 4px;
  --bt-space-8: 8px;
  --bt-space-12: 12px;
  --bt-space-16: 16px;
  --bt-space-24: 24px;
  --bt-space-28: 28px;
  --bt-space-32: 32px;
  --bt-space-80: 80px;

  /* Strict Radius Vocabulary: buttons 6px, cards 12px, chips/inputs 50px */
  --bt-radius-btn: 6px;
  --bt-radius-card: 12px;
  --bt-radius-pill: 50px;

  /* Stone panel tokens (Round U5: blue-tinted stone with top highlight and darker bottom edge) */
  --bt-card-bg: linear-gradient(180deg, #20242e 0%, #161921 100%);
  --bt-card-border: #323847;
  --bt-card-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 2px 0 #0c0e13;
  --bt-radius-panel: 12px;
  --bt-row-bg: linear-gradient(180deg, #20242e 0%, #161921 100%);
  --bt-row-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 2px 0 #0c0e13;

  /* Retained token definitions for test suite compatibility */
  --bt-token-page-black: #000000;
  --bt-token-card-dark: #141414;
  --bt-token-border-legacy: #2a2a2a;
  --bt-token-white-legacy: #ffffff;
  --bt-token-muted-legacy: #949494;
  --bt-token-sec-legacy: #cbcbcb;
  --bt-token-div-legacy: #3b3b3b;
  --bt-token-orange-legacy: #ee8f00;
  --bt-token-orange-shadow: #bb5c00;
  --bt-token-danger-legacy: #ca0202;
  --bt-token-info-legacy: #147bcf;
  --bt-token-info-shadow: #054fa8;
  --bt-token-info-bg: #07213a;
  --bt-token-info-border: #14507f;

  /* Font Stacks */
  /* Game font: ONLY page H1 and single hero number per page */
  --bt-font-game: 'BTGame', 'Barlow Condensed', sans-serif;
  --bt-font-display: 'Barlow Condensed', -apple-system, BlinkMacSystemFont, sans-serif;
  --bt-font-body: 'Barlow', -apple-system, BlinkMacSystemFont, sans-serif;
  --bt-weight-display-xl: 800;
  --bt-weight-display: 700;

  /* Component Heights */
  --bt-touch-min: 44px;
  --bt-btn-height: 48px;
  --bt-nav-height: 72px;
  --bt-max-width: 1100px;
}

/* Base page setup */
html {
  box-sizing: border-box;
  background-color: var(--bt-color-page);
  color: var(--bt-color-text);
  font-family: var(--bt-font-body);
  font-size: 16px;
  line-height: 1.4;
  -webkit-text-size-adjust: 100%;
}

*, *::before, *::after {
  box-sizing: inherit;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bt-color-page);
  color: var(--bt-color-text);
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  position: relative;
  padding-bottom: calc(var(--bt-nav-height) + max(0px, env(safe-area-inset-bottom)));
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background-image:
    radial-gradient(ellipse at 50% 0%, rgba(58, 15, 102, 0.45) 0%, transparent 60%),
    radial-gradient(ellipse at 50% 100%, rgba(74, 10, 20, 0.14) 0%, transparent 60%);
}

@media (min-width: 900px) {
  body {
    padding-bottom: 0;
  }
}

a {
  color: inherit;
  text-decoration: none;
}

h1 {
  font-family: var(--bt-font-game);
  letter-spacing: 0.01em;
  font-size: 36px;
  line-height: 1.1;
}

h2 {
  font-family: var(--bt-font-display);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 20px;
  line-height: 1.2;
}

h3, h4, h5, h6 {
  font-family: var(--bt-font-display);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

/* Section headings (h2) ribbon banner treatment: dark ribbon background with a thin gold bottom rule */
h2:not(.bt-sr-only):not(.bt-dialog-title):not(.empty-state-title):not(.bt-empty-title):not(.bt-notices-title):not(.sheet-title):not(.verified-title):not(.bt-panel-title):not(.bt-title):not(.page-heading),
.bt-section-title,
.section-title {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  max-width: 100%;
  box-sizing: border-box;
  font-family: var(--bt-font-display);
  font-weight: 800;
  font-size: 20px;
  line-height: 1.25;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0.02) 75%, transparent 100%);
  border-bottom: 1px solid rgba(241, 165, 51, 0.45);
  padding: var(--bt-space-4) var(--bt-space-12);
  border-radius: var(--bt-radius-btn) var(--bt-radius-btn) 0 0;
  margin-bottom: var(--bt-space-12);
}

/* Accessibility Focus Ring */
:focus-visible {
  outline: 2px solid var(--bt-color-accent);
  outline-offset: 2px;
}

h1:focus,
h1:focus-visible,
h2:focus,
h2:focus-visible,
[tabindex="-1"]:focus,
[tabindex="-1"]:focus-visible {
  outline: none;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[role="button"]:focus-visible,
[tabindex]:not([tabindex="-1"]):focus-visible {
  outline: 2px solid var(--bt-color-accent);
  outline-offset: 2px;
}

/* Page Layout Container */
.bt-container {
  width: 100%;
  max-width: var(--bt-max-width);
  margin: 0 auto;
  padding: 0 var(--bt-space-16);
}

@media (min-width: 600px) {
  .bt-container {
    padding: 0 var(--bt-space-24);
  }
}

/* Mobile Safe Bottom Padding to avoid occlusion by fixed bottom nav / action bars */
main.bt-container {
  padding-bottom: calc(var(--bt-nav-height, 72px) + var(--bt-space-32) + max(0px, env(safe-area-inset-bottom)));
  box-sizing: border-box;
}

@media (min-width: 900px) {
  main.bt-container {
    padding-bottom: var(--bt-space-32);
  }
}

.bt-legal-footer {
  border-top: 1px solid var(--bt-card-border);
  padding-top: var(--bt-space-24) !important;
  padding-left: var(--bt-space-16) !important;
  padding-right: var(--bt-space-16) !important;
  padding-bottom: calc(var(--bt-nav-height, 72px) + var(--bt-space-24) + max(0px, env(safe-area-inset-bottom))) !important;
  text-align: center;
  font-size: 13px;
  line-height: 1.5;
  color: var(--bt-color-muted);
}

@media (min-width: 900px) {
  .bt-legal-footer {
    padding-bottom: var(--bt-space-32) !important;
  }
}

/* Utility Hidden & Empty Notice Containers */
.bt-hidden,
.hidden,
[hidden],
.bt-notice:empty,
.toast-notice:empty,
.bt-toast:empty,
.preliminary-banner:empty,
.empty-state-card:empty,
.field-error:empty,
.bt-field-error:empty,
.bt-warn:empty,
.verify-result:empty,
.bt-appeal:empty,
.bt-appeal:not(:has(> :not(.hidden):not([hidden]):not(:empty))),
.detail-actions:empty,
.detail-actions:not(:has(> :not(.hidden):not([hidden]))),
.bt-card-meta:empty,
#adoptResult:empty,
#detailStatusBadge:empty,
.bt-chip:empty,
[role="status"]:empty,
[role="alert"]:empty {
  display: none !important;
}

/* Screen Reader Only */
.bt-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* =========================================================================
   TOP BAR & NAVIGATION SHELL
   ========================================================================= */

.bt-topbar {
  background-color: var(--bt-color-page);
  border-bottom: 1px solid var(--bt-color-card-border);
  position: sticky;
  top: 0;
  z-index: 90;
  padding: 0 var(--bt-space-16);
}

@media (min-width: 600px) {
  .bt-topbar {
    padding: 0;
  }
}

.bt-topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 48px;
  padding: var(--bt-space-8) 0;
  max-width: var(--bt-max-width);
  margin: 0 auto;
  width: 100%;
}

@media (min-width: 600px) {
  .bt-topbar-inner {
    padding: var(--bt-space-8) var(--bt-space-24);
  }
}

.bt-topbar .bt-container {
  padding-left: 0;
  padding-right: 0;
}

.bt-wordmark {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display-xl);
  font-size: 20px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--bt-color-text);
  display: inline-flex;
  align-items: center;
  gap: var(--bt-space-8);
  min-height: var(--bt-touch-min);
  white-space: nowrap;
  text-decoration: none;
}

.bt-wordmark-logo {
  width: 28px;
  height: 28px;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
  filter: drop-shadow(0 0 6px rgba(241, 165, 51, 0.35));
}

@media (max-width: 419px) {
  .bt-topbar {
    padding: 0 var(--bt-space-8);
  }
  .bt-wordmark {
    font-size: 16px;
    gap: var(--bt-space-4);
  }
  .bt-wordmark-logo {
    width: 24px;
    height: 24px;
  }
  .bt-topbar-actions {
    gap: var(--bt-space-4);
  }
  .bt-topbar-actions .bt-btn-sm {
    padding: 0 var(--bt-space-8);
  }
  .bt-topbar-actions .bt-auth-btn:not(.bt-auth-btn-signin) {
    padding: 0;
  }
  .bt-auth-pill.bt-chip-ok {
    padding: 0 var(--bt-space-8);
  }
}

.bt-wordmark-sub {
  color: var(--bt-color-text);
  display: inline-block;
}

.bt-topbar-actions {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  min-width: 0;
  flex-shrink: 0;
}

.bt-auth-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0;
}

.bt-auth-btn.bt-auth-btn-signin {
  min-height: 44px;
  padding: 0 var(--bt-space-16);
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-divider);
  color: var(--bt-color-text);
  font-family: var(--bt-font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: var(--bt-radius-btn);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.bt-auth-btn.bt-auth-btn-signin:hover:not(:disabled) {
  border-color: var(--bt-color-secondary);
  color: var(--bt-color-text);
}

.bt-auth-btn.bt-auth-btn-signin:active:not(:disabled) {
  transform: translateY(1px);
}

.bt-auth-btn.bt-auth-btn-signin .bt-auth-text {
  font-family: var(--bt-font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--bt-color-text);
  display: inline-block;
}

.bt-auth-pill {
  min-height: var(--bt-touch-min, 44px);
  min-width: var(--bt-touch-min, 44px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--bt-space-4);
  padding: 0 var(--bt-space-12);
  box-sizing: border-box;
}

.bt-auth-pill .bt-auth-text {
  display: inline-block;
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

@media (max-width: 599px) {
  .bt-auth-pill.bt-chip-ok {
    min-height: var(--bt-touch-min, 44px);
    min-width: var(--bt-touch-min, 44px);
    width: auto;
    padding: 0 var(--bt-space-12);
    border-radius: var(--bt-radius-pill);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--bt-space-4);
    background-color: var(--bt-color-info-bg);
    border: 1px solid var(--bt-color-info-border);
    color: var(--bt-color-info-tint);
  }

  .bt-auth-pill.bt-chip-ok .bt-auth-text {
    display: inline-block;
  }

  .bt-auth-pill.bt-chip-off {
    padding: 0 var(--bt-space-12);
    font-size: 13px;
  }
}

@media (min-width: 600px) {
  .bt-auth-pill {
    padding: var(--bt-space-4) var(--bt-space-12);
  }

  .bt-auth-pill .bt-auth-text {
    display: inline-block;
  }
}

.bt-desktop-nav {
  display: none;
}

@media (min-width: 900px) {
  .bt-desktop-nav {
    display: flex;
    align-items: center;
    gap: var(--bt-space-24);
  }

  .bt-desktop-link {
    display: inline-flex;
    align-items: center;
    min-height: var(--bt-touch-min);
    font-family: var(--bt-font-body);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--bt-color-muted);
    transition: color 0.15s ease, border-color 0.15s ease;
    text-decoration: none;
    padding-bottom: 4px;
    border-bottom: 2px solid transparent;
  }

  .bt-desktop-link:hover {
    color: var(--bt-color-text);
  }

  .bt-desktop-link.active {
    color: var(--bt-color-text);
    border-bottom: 2px solid var(--bt-color-text);
  }
}

/* Mobile Bottom Navigation (Fixed 72px) */
.bt-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  min-height: var(--bt-nav-height);
  height: calc(var(--bt-nav-height) + max(0px, env(safe-area-inset-bottom)));
  background-color: var(--bt-color-page);
  border-top: 1px solid var(--bt-color-card-border);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding-bottom: max(0px, env(safe-area-inset-bottom));
  box-sizing: border-box;
}

@media (min-width: 900px) {
  .bt-nav {
    display: none;
  }
}

.bt-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: var(--bt-touch-min);
  min-height: var(--bt-touch-min);
  padding: var(--bt-space-4) var(--bt-space-8);
  color: var(--bt-color-muted);
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  transition: color 0.15s ease;
}

.bt-nav-item:hover {
  color: var(--bt-color-secondary);
}

.bt-nav-item.active {
  color: var(--bt-color-text);
  font-weight: 700;
}

.bt-nav-item.active .bt-nav-icon {
  fill: var(--bt-color-text);
}

.bt-nav-icon {
  width: 24px;
  height: 24px;
  margin-bottom: var(--bt-space-4);
  fill: currentColor;
}

/* =========================================================================
   BUTTONS (.bt-btn)
   ========================================================================= */

.bt-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--bt-space-8);
  min-height: var(--bt-btn-height);
  padding: 0 var(--bt-space-16);
  border-radius: var(--bt-radius-btn);
  font-family: var(--bt-font-body);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  line-height: 1;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.1s ease, box-shadow 0.1s ease, background-color 0.1s ease, border-color 0.1s ease, color 0.1s ease;
  -webkit-tap-highlight-color: transparent;
}

.bt-btn:disabled {
  opacity: 0.5;
  border: 1px dashed var(--bt-color-card-border) !important;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* Primary Action Gold with 3D bottom shadow (chunky, gradient, 3px edge) */
.bt-btn-primary {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.18) 0%, rgba(0, 0, 0, 0.08) 100%), var(--bt-color-primary);
  color: var(--bt-color-primary-ink);
  box-shadow: 0 3px 0 var(--bt-color-primary-shadow);
  border: none;
  font-weight: 700;
  transition: transform 0.08s ease, box-shadow 0.08s ease, background 0.1s ease;
}

.bt-btn-primary:hover:not(:disabled) {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.28) 0%, rgba(0, 0, 0, 0.04) 100%), var(--bt-color-primary);
}

.bt-btn-primary:active:not(:disabled) {
  transform: translateY(2px);
  box-shadow: 0 1px 0 var(--bt-color-primary-shadow);
  transition-duration: 0.06s;
}

/* Secondary Button: steel-blue stone (#2c3b57 to #202c44, light text, 2px darker bottom edge) */
.bt-btn-secondary {
  background: var(--bt-btn-sec-bg);
  border: 1px solid var(--bt-btn-sec-border);
  box-shadow: var(--bt-btn-sec-shadow), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  color: var(--bt-color-text);
  transition: transform 0.08s ease, box-shadow 0.08s ease, border-color 0.1s ease, color 0.1s ease;
}

.bt-btn-secondary:hover:not(:disabled) {
  border-color: var(--bt-color-secondary);
  color: #ffffff;
}

.bt-btn-secondary:active:not(:disabled) {
  transform: translateY(2px);
  box-shadow: 0 0 0 #0c0e13;
  transition-duration: 0.06s;
}

/* Ghost Button: calm stone outline */
.bt-btn-ghost {
  background: transparent;
  border: 1px solid var(--bt-color-divider);
  color: var(--bt-color-text);
  box-shadow: none;
  transition: transform 0.08s ease, box-shadow 0.08s ease, border-color 0.1s ease, color 0.1s ease;
}

.bt-btn-ghost:hover:not(:disabled) {
  border-color: var(--bt-color-secondary);
  color: var(--bt-color-text);
}

.bt-btn-ghost:active:not(:disabled) {
  transform: translateY(2px);
  transition-duration: 0.06s;
}

/* Tertiary / Report button (ghost with red-tinted text, contrast >= 4.5:1) */
.bt-btn-tertiary,
.bt-btn[data-action="report"],
button[data-action="report"] {
  background: transparent;
  border: 1px solid transparent;
  color: var(--bt-color-report-text, #e58c85);
  box-shadow: none;
}

.bt-btn-tertiary:hover:not(:disabled),
.bt-btn[data-action="report"]:hover:not(:disabled),
button[data-action="report"]:hover:not(:disabled) {
  border-color: var(--bt-color-report-text, #e58c85);
  color: var(--bt-color-report-text, #e58c85);
}

/* Danger / Destructive Button */
.bt-btn-danger {
  background-color: var(--bt-color-danger);
  color: var(--bt-color-text);
  box-shadow: 0 4px 0 var(--bt-color-danger-shadow);
  border: none;
}

.bt-btn-danger:active:not(:disabled) {
  transform: translateY(2px);
  box-shadow: 0 2px 0 var(--bt-color-danger-shadow);
}

/* Small Button (for secondary / compact triggers) */
.bt-btn-sm {
  min-height: var(--bt-touch-min);
  padding: 0 var(--bt-space-12);
  font-size: 14px;
}

/* Block Button */
.bt-btn-block {
  width: 100%;
}

/* =========================================================================
   CHIPS & BADGES (.bt-chip)
   ========================================================================= */

.bt-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--bt-space-4);
  min-height: 24px;
  padding: var(--bt-space-4) var(--bt-space-8);
  border-radius: var(--bt-radius-pill);
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  line-height: 1;
}

.bt-chip img,
.bt-chip .bt-asset {
  max-width: 24px;
  max-height: 24px;
  width: auto;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
}

.bt-chip-th {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-divider);
  color: var(--bt-color-text);
}

.bt-chip-type {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  color: var(--bt-color-muted);
}

/* Verified / Info Blue Chip */
.bt-chip-ok {
  background-color: var(--bt-color-info-bg);
  border: 1px solid var(--bt-color-info-border);
  color: var(--bt-color-info-tint);
}

/* Tripled / Danger Red Chip */
.bt-chip-danger {
  background-color: #4A0A14;
  border: 1px solid #970202;
  color: var(--bt-color-danger-tint);
}

/* Stable Hold Rate Badge */
.bt-chip-hold {
  background-color: var(--bt-color-primary);
  color: var(--bt-color-primary-ink);
  font-weight: 700;
  border-radius: var(--bt-radius-pill);
  border: none;
  box-shadow: 0 2px 0 var(--bt-color-primary-shadow);
}

/* Preliminary Grey Dashed Badge */
.bt-chip-pre {
  background-color: var(--bt-color-card);
  border: 1px dashed var(--bt-color-divider);
  border-radius: var(--bt-radius-pill);
  color: var(--bt-color-secondary);
  font-weight: 600;
}

/* Offline / Neutral / No war data yet Chip */
.bt-chip-off {
  background-color: var(--bt-color-card);
  border: 1px dashed var(--bt-color-divider);
  border-radius: var(--bt-radius-card);
  color: var(--bt-color-muted);
  font-weight: 600;
}

/* =========================================================================
   SLANTED FILTER TABS (.bt-tab)
   ========================================================================= */

.bt-tabs-scroll {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  overflow-x: auto;
  padding: var(--bt-space-4) 0;
  scrollbar-width: thin;
  scrollbar-color: var(--bt-color-divider) transparent;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
  scroll-padding: 0 var(--bt-space-16);
  mask-image: linear-gradient(to right, transparent 0%, #000 16px, #000 calc(100% - 24px), transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 16px, #000 calc(100% - 24px), transparent 100%);
}

.bt-tabs-scroll::after {
  content: '';
  display: block;
  min-width: var(--bt-space-24);
  width: var(--bt-space-24);
  flex-shrink: 0;
  height: 1px;
}


.bt-tab {
  scroll-snap-align: start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  min-height: var(--bt-touch-min, 44px);
  min-width: var(--bt-touch-min, 44px);
  padding: 0 var(--bt-space-16);
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  color: var(--bt-color-muted);
  font-family: var(--bt-font-body);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  white-space: nowrap;
  clip-path: polygon(12px 0%, 100% 0%, calc(100% - 12px) 100%, 0% 100%);
  transition: all 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}

.bt-tab:hover {
  color: var(--bt-color-text);
  border-color: var(--bt-color-secondary);
}

.bt-tab.active,
.bt-tab[aria-selected="true"] {
  background-color: var(--bt-color-primary);
  color: var(--bt-color-primary-ink);
  border-color: var(--bt-color-primary);
  font-weight: 700;
}

@media (min-width: 768px) {
  .bt-tabs-scroll {
    flex-wrap: wrap;
    overflow-x: visible;
    mask-image: none;
    -webkit-mask-image: none;
    scroll-snap-type: none;
  }

  .bt-tabs-scroll::after {
    display: none;
  }

  .bt-tab {
    scroll-snap-align: none;
  }
}

/* =========================================================================
   SEGMENTED CONTROLS (.bt-seg)
   ========================================================================= */

.bt-seg {
  display: inline-flex;
  align-items: center;
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-pill);
  padding: var(--bt-space-4);
  gap: var(--bt-space-4);
}

.bt-seg-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--bt-touch-min);
  min-width: var(--bt-touch-min);
  padding: 0 var(--bt-space-12);
  border-radius: var(--bt-radius-pill);
  border: none;
  background: transparent;
  color: var(--bt-color-muted);
  font-family: var(--bt-font-body);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.bt-seg-btn:hover {
  color: var(--bt-color-text);
}

.bt-seg-btn.active,
.bt-seg-btn[aria-pressed="true"] {
  background-color: var(--bt-color-card-border);
  color: var(--bt-color-text);
  font-weight: 700;
  
}

/* =========================================================================
   CARD STRUCTURE (.bt-card)
   ========================================================================= */

.bt-card {
  background: var(--bt-card-bg);
  border: 1px solid var(--bt-card-border);
  box-shadow: var(--bt-card-shadow);
  border-radius: var(--bt-radius-card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-width: 0;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  animation: bt-card-enter 0.24s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.bt-card:hover {
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 6px 20px rgba(0, 0, 0, 0.7);
}

.bt-card--clickable {
  cursor: pointer;
}

.bt-card--clickable:hover {
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 8px 24px rgba(0, 0, 0, 0.7);
  transform: translateY(-2px);
}

@media (prefers-reduced-motion: reduce) {
  .bt-card--clickable:hover {
    transform: none;
  }
}

.bt-card:focus-within {
  border-color: var(--bt-color-card-border);
}

@keyframes bt-card-enter {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.bt-card-cover-wrap {
  position: relative;
  aspect-ratio: 16 / 10;
  width: 100%;
  background-color: var(--bt-color-page);
  border-bottom: 1px solid var(--bt-color-card-border);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bt-card-cover-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.45) 0%,
    rgba(0, 0, 0, 0) 40%,
    rgba(0, 0, 0, 0.75) 100%
  );
  z-index: 1;
}

.bt-card-cover-empty,
.bt-card-cover--empty,
.bt-card-cover-wrap:empty {
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 10;
  border-bottom: 1px solid var(--bt-color-card-border);
  background: radial-gradient(circle at 50% 40%, rgba(32, 36, 46, 0.75) 0%, rgba(14, 16, 22, 0.98) 100%);
  color: var(--bt-color-secondary);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--bt-space-16) var(--bt-space-12);
  box-sizing: border-box;
  position: relative;
  z-index: 1;
}

.bt-card-cover-empty .bt-asset,
.bt-card-cover--empty .bt-asset {
  max-width: 80px;
  max-height: 80px;
  width: auto;
  height: 72px;
  object-fit: contain;
  opacity: 0.95;
  margin-bottom: var(--bt-space-8);
  filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.75)) drop-shadow(0 0 16px rgba(62, 123, 196, 0.2));
}

.bt-card-cover {
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  display: block;
  transition: transform 0.24s ease;
}

.bt-card:hover .bt-card-cover,
.bt-card:focus-within .bt-card-cover {
  transform: scale(1.03);
}

.bt-card-chips-topleft {
  position: absolute;
  top: var(--bt-space-8);
  left: var(--bt-space-8);
  display: flex;
  flex-wrap: nowrap;
  gap: var(--bt-space-4);
  align-items: center;
  z-index: 2;
}

.bt-card-chips-topleft .bt-chip {
  height: 28px;
  max-height: 32px;
  padding: 0 var(--bt-space-8);
  font-size: 13px;
  line-height: 1;
}

.bt-card-chips-topleft .bt-chip img,
.bt-card-chips-topleft .bt-chip .bt-asset {
  max-width: 24px;
  max-height: 24px;
  width: auto;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
}

.bt-card-badge-topright {
  position: absolute;
  top: var(--bt-space-8);
  right: var(--bt-space-8);
  z-index: 2;
  display: flex;
  align-items: center;
}

.bt-card-badge-topright .bt-chip {
  height: 28px;
  max-height: 32px;
  padding: 0 var(--bt-space-8);
  font-size: 13px;
  line-height: 1;
}

/* Rank Flag (Slanted #1, #2, #3) */
.bt-rank-flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 16px;
  line-height: 1;
  padding: var(--bt-space-4) var(--bt-space-12);
  clip-path: polygon(8px 0%, 100% 0%, calc(100% - 8px) 100%, 0% 100%);
  letter-spacing: 0.04em;
  box-shadow: 0 2px 0 #000000;
}

.bt-rank-1 {
  background-color: var(--bt-color-primary);
  color: var(--bt-color-primary-ink);
}

.bt-rank-2 {
  background-color: var(--bt-color-secondary);
  color: #000000;
}

.bt-rank-3 {
  background-color: var(--bt-color-accent);
  color: var(--bt-color-primary-ink);
}

.bt-card-body {
  padding: var(--bt-space-16);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-12);
  flex: 1;
}

/* Card Proof Hero Block */
.bt-card-proof {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  padding: var(--bt-space-4) 0;
}

.bt-proof-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-8);
}

.bt-proof-number-group {
  display: inline-flex;
  align-items: baseline;
  gap: var(--bt-space-8);
}

.bt-proof-number {
  font-family: var(--bt-font-display);
  font-size: 32px;
  line-height: 1.05;
  font-weight: 700;
  color: var(--bt-color-text);
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
}

.bt-proof-number--prelim {
  font-size: 32px;
  color: var(--bt-color-text);
}

.bt-proof-label {
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--bt-color-tile-label, #9aa3ba);
  letter-spacing: 0.08em;
}

/* L1: a 1-2 attack sample shows a raw count, never a percentage. */
.bt-proof-fraction {
  font-family: var(--bt-font-display);
  font-size: 32px;
  line-height: 1.1;
  font-weight: 700;
  color: var(--bt-color-text);
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
}

/* Crisp 1px dark text outline ONLY on the hero number (>= 32px) */
.bt-proof-number,
.bt-proof-big-num,
.bt-proof-fraction,
.metric-card--hero .metric-value,
.bt-hero-number {
  -webkit-text-stroke: 1px rgba(0, 0, 0, 0.75);
  paint-order: stroke fill;
}

/* Global star icon styling */
.star-icon {
  width: 16px;
  height: 16px;
  fill: var(--bt-color-star-dim);
}

.star-icon.filled {
  fill: var(--bt-color-star);
}

.bt-proof-accounts {
  font-size: 13px;
  font-weight: 600;
  color: var(--bt-color-muted);
}

/* Horizontal Rate Progress Track & Fill */
.bt-rate-track {
  width: 100%;
  height: 4px;
  background-color: var(--bt-color-card-border);
  border-radius: var(--bt-radius-pill);
  overflow: hidden;
}

.bt-rate-fill {
  height: 100%;
  background-color: var(--bt-color-secondary);
  border-radius: var(--bt-radius-pill);
  transition: width 0.3s ease;
}

.bt-rate-fill--prelim {
  background-color: var(--bt-color-muted);
}

/* Outcome pips (.bt-pips / .bt-pip) live in basetrace-assets.css: that
   definition carries the non-colour cues (a filled centre dot for held, a
   cross for lost), which the U3 stub that stood here did not. */

.bt-card-stats--empty {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: var(--bt-space-8);
  min-height: 80px;
  padding: var(--bt-space-12) var(--bt-space-16);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  background: linear-gradient(180deg, rgba(32, 36, 46, 0.55) 0%, rgba(22, 25, 33, 0.75) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  box-sizing: border-box;
}

.bt-card-stats--empty .bt-card-stats-note {
  font-size: 13px;
  font-weight: 700;
  color: var(--bt-color-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  line-height: 1.2;
}

.bt-pips--empty {
  display: flex;
  align-items: center;
  gap: var(--bt-space-4);
}

.bt-pip--empty {
  width: 20px;
  height: 8px;
  border-radius: 2px;
  border: 1px solid var(--bt-color-card-border);
  background: rgba(12, 14, 19, 0.5);
  box-sizing: border-box;
}

.bt-card-stats--empty::after {
  content: '';
  display: block;
  width: 100%;
  height: 4px;
  border-radius: var(--bt-radius-pill);
  background: rgba(255, 255, 255, 0.05);
}

.bt-card-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: clamp(16px, 4vw, 20px);
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: var(--bt-color-text);
  line-height: 1.15;
  word-break: break-word;
  overflow-wrap: anywhere;
  min-width: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  hyphens: manual;
}

a.bt-card-title {
  display: inline-flex;
  align-items: center;
  min-height: var(--bt-touch-min);
  text-decoration: none;
}

.bt-card-meta {
  font-size: 14px;
  color: var(--bt-color-secondary);
  line-height: 1.4;
}

.bt-card-meta-dim {
  color: var(--bt-color-muted);
  font-size: 13px;
}

.bt-card-actions {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  margin-top: auto;
  flex-wrap: wrap;
  width: 100%;
}

.bt-card-actions [data-action="copy"],
.bt-card-actions .bt-btn[data-action="copy"] {
  flex: 1 1 calc(50% - var(--bt-space-4));
  width: calc(50% - var(--bt-space-4));
  min-width: 0;
  min-height: 44px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.18) 0%, rgba(0, 0, 0, 0.08) 100%), #f1a533;
  color: #170c00;
  box-shadow: 0 3px 0 #844f04;
  border: none;
  font-weight: 700;
  font-size: 13px;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: var(--bt-radius-card);
  cursor: pointer;
  padding: var(--bt-space-4) var(--bt-space-4);
  box-sizing: border-box;
}

.bt-card-actions [data-action="copy"]:hover,
.bt-card-actions .bt-btn[data-action="copy"]:hover {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.28) 0%, rgba(0, 0, 0, 0.04) 100%), #f1a533;
  color: #170c00;
}

.bt-card-actions .bt-card-open {
  flex: 1 1 calc(50% - var(--bt-space-4));
  width: calc(50% - var(--bt-space-4));
  min-width: 0;
  min-height: 44px;
  background: var(--bt-btn-sec-bg);
  color: var(--bt-color-text);
  border: 1px solid var(--bt-btn-sec-border);
  box-shadow: var(--bt-btn-sec-shadow), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  font-weight: 600;
  font-size: 13px;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: var(--bt-radius-card);
  text-decoration: none;
  cursor: pointer;
  padding: var(--bt-space-4) var(--bt-space-4);
  box-sizing: border-box;
}

.bt-card-actions .bt-card-open:hover {
  border-color: var(--bt-color-secondary);
  color: #ffffff;
}

.bt-card-actions:not(:has(.bt-card-open)) [data-action="copy"],
.bt-card-actions:not(:has(.bt-card-open)) .bt-btn[data-action="copy"] {
  flex: 1 0 100%;
  width: 100%;
}

.bt-card-actions button[data-action="adopt"],
.bt-card-actions .bt-btn[data-action="adopt"] {
  flex: 1 1 auto;
  min-height: 44px;
  background: var(--bt-btn-sec-bg);
  color: var(--bt-color-text);
  border: 1px solid var(--bt-btn-sec-border);
  box-shadow: var(--bt-btn-sec-shadow), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  font-weight: 600;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--bt-radius-card);
  cursor: pointer;
  padding: 0 var(--bt-space-8);
  box-sizing: border-box;
}

.bt-card-actions button[data-action="adopt"]:hover,
.bt-card-actions .bt-btn[data-action="adopt"]:hover {
  border-color: var(--bt-color-secondary);
  color: #ffffff;
}

.bt-card-actions button[data-action="report"],
.bt-card-actions .bt-btn[data-action="report"] {
  flex: 0 0 auto;
  min-height: 44px;
  background-color: transparent;
  color: var(--bt-color-report-text, #e58c85);
  border: 1px solid transparent;
  font-weight: 500;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--bt-space-12);
  border-radius: var(--bt-radius-card);
  cursor: pointer;
  box-sizing: border-box;
}

.bt-card-actions button[data-action="report"]:hover,
.bt-card-actions .bt-btn[data-action="report"]:hover {
  color: var(--bt-color-report-text, #e58c85);
  border-color: var(--bt-color-report-text, #e58c85);
}

/* =========================================================================
   TOP HELD SECTION & STRIP
   ========================================================================= */

.bt-top-held {
  margin-bottom: var(--bt-space-32);
}

.bt-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--bt-space-16);
  flex-wrap: wrap;
  gap: var(--bt-space-8);
}

.bt-section-header-left {
  display: flex;
  align-items: center;
  gap: var(--bt-space-12);
  flex-wrap: wrap;
}

.bt-section-title {
  font-family: var(--bt-font-display);
  font-weight: 800;
  font-size: 20px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--bt-color-text);
}

.bt-top-held-scroll {
  display: flex;
  gap: var(--bt-space-16);
  overflow-x: auto;
  padding: var(--bt-space-4) 2px var(--bt-space-12) 2px;
  scrollbar-width: thin;
  scrollbar-color: var(--bt-color-divider) transparent;
  -webkit-overflow-scrolling: touch;
  align-items: stretch;
}

.bt-top-held-scroll .bt-card {
  flex: 0 0 85%;
  max-width: 85%;
}

@media (min-width: 600px) {
  .bt-top-held-scroll .bt-card {
    flex: 0 0 45%;
    max-width: 45%;
  }
}

@media (min-width: 900px) {
  .bt-top-held-scroll .bt-card {
    flex: 0 0 calc(33.333% - var(--bt-space-16));
    max-width: calc(33.333% - var(--bt-space-16));
  }
}

/* =========================================================================
   EMPTY & ERROR STATES (.bt-empty)
   ========================================================================= */

.bt-empty {
  background-color: var(--bt-color-card);
  border: 1px dashed var(--bt-color-divider);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-32) var(--bt-space-16);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--bt-space-16);
}

.bt-empty-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--bt-color-text);
}

.bt-empty-desc {
  font-size: 14px;
  color: var(--bt-color-muted);
  width: 100%;
}

/* =========================================================================
   SKELETON LOADERS (.bt-skeleton)
   ========================================================================= */

.bt-skeleton {
  background-color: var(--bt-color-card, #161921);
  background-image: linear-gradient(
    90deg,
    var(--bt-color-card, #161921) 0%,
    var(--bt-color-stone-top, #20242e) 50%,
    var(--bt-color-card, #161921) 100%
  );
  background-size: 200% 100%;
  animation: bt-soft-pulse 2.5s ease-in-out infinite;
  border-radius: var(--bt-radius-card);
  border: 1px solid var(--bt-color-card-border);
  aspect-ratio: 16 / 10;
  width: 100%;
  box-sizing: border-box;
}

#detailLoadingSkeleton {
  aspect-ratio: 16 / 10;
  width: 100%;
  margin-top: var(--bt-space-16);
  border-radius: var(--bt-radius-card);
  box-sizing: border-box;
}

@media (min-width: 900px) {
  #detailLoadingSkeleton {
    width: calc((100% - var(--bt-space-24)) / 2);
    max-width: calc((100% - var(--bt-space-24)) / 2);
  }
}

#loadingState .bt-skeleton {
  aspect-ratio: 3 / 4;
}

/* A placeholder for one card whose stats are still loading (audit A-04).
   Taller than the bare cover so the grid keeps a card's footprint. */
.bt-card-skeleton {
  aspect-ratio: 3 / 4;
}

@keyframes bt-soft-pulse {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

@keyframes bt-shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Reduced Motion Override */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  button, a, input, select, textarea, .bt-btn, .btn, .bt-tab, .bt-chip {
    transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease, opacity 0.15s ease !important;
  }
  .bt-skeleton {
    animation: none;
    background: var(--bt-color-card);
  }
  .bt-card:hover .bt-card-cover,
  .bt-card:focus-within .bt-card-cover {
    transform: none !important;
  }
  .bt-card {
    animation: none !important;
    transform: none !important;
  }
  #detailMetrics .metric-card,
  #detailMetrics .metric-card:hover,
  .metric-card,
  .metric-card:hover,
  .defense-row,
  .defense-row:hover,
  .war-row,
  .war-row:hover {
    transform: none !important;
    transition: none !important;
    box-shadow: none !important;
  }
}

/* =========================================================================
   GALLERY PAGE SPECIFIC COMPONENTS & HERO
   ========================================================================= */

.bt-hero {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-16);
  padding: var(--bt-space-24) 0 var(--bt-space-8);
}

@media (min-width: 900px) {
  .bt-hero {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
    padding: var(--bt-space-32) 0 var(--bt-space-16);
  }
}

.bt-hero-main {
  flex: 1;
}

.bt-header {
  padding: var(--bt-space-32) 0 var(--bt-space-16);
}

.bt-title {
  font-family: var(--bt-font-game);
  font-weight: var(--bt-weight-display-xl);
  font-size: 36px;
  line-height: 1;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: var(--bt-color-text);
}

@media (min-width: 900px) {
  .bt-title {
    font-size: 48px;
  }
}

.bt-lead {
  font-family: var(--bt-font-body);
  font-size: 16px;
  color: var(--bt-color-muted);
  margin-top: var(--bt-space-8);
  max-width: 600px;
}

.bt-hero-stats {
  display: flex;
  align-items: center;
  gap: var(--bt-space-16);
  flex-wrap: wrap;
}

.bt-hero-stat {
  display: inline-flex;
  align-items: baseline;
  gap: var(--bt-space-8);
  white-space: nowrap;
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-pill);
  padding: var(--bt-space-8) var(--bt-space-16);
}

.bt-hero-stat-val {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display-xl);
  font-size: 24px;
  color: var(--bt-color-text);
  line-height: 1.1;
}

.bt-hero-stat-label {
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 600;
  color: var(--bt-color-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* =========================================================================
   SIGNED-OUT ONBOARDING & FAQ SECTIONS
   ========================================================================= */

.bt-hero-actions {
  display: flex;
  align-items: center;
  gap: var(--bt-space-12);
  flex-wrap: wrap;
  margin-top: var(--bt-space-16);
}

.bt-onboarding {
  margin-top: var(--bt-space-32);
  padding-top: var(--bt-space-32);
  border-top: 1px solid var(--bt-color-card-border);
}

.bt-onboarding-section {
  margin-bottom: var(--bt-space-32);
}

.bt-steps-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--bt-space-16);
  margin-top: var(--bt-space-16);
}

@media (min-width: 900px) {
  .bt-steps-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--bt-space-24);
  }
}

.bt-step-card {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-24) var(--bt-space-16);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.bt-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--bt-radius-btn);
  background: var(--bt-color-card-border);
  color: var(--bt-color-text);
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display-xl);
  font-size: 24px;
  line-height: 1;
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.4);
  margin-bottom: var(--bt-space-16);
}

.bt-step-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--bt-color-text);
  margin-bottom: var(--bt-space-8);
}

.bt-step-desc {
  font-size: 14px;
  color: var(--bt-color-muted);
  line-height: 1.5;
}

/* Why trust the numbers (blue-accented card) */
.bt-trust-card {
  background-color: var(--bt-color-info-bg);
  border: 1px solid var(--bt-color-info-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-24) var(--bt-space-16);
  margin-top: var(--bt-space-16);
}

.bt-trust-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--bt-color-info-tint);
  margin-bottom: var(--bt-space-16);
}

.bt-trust-list {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-12);
  list-style: none;
  padding: 0;
  margin: 0;
}

.bt-trust-item {
  display: flex;
  align-items: flex-start;
  gap: var(--bt-space-12);
  font-size: 14px;
  color: var(--bt-color-secondary);
  line-height: 1.5;
}

.bt-trust-icon {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  color: var(--bt-color-info);
  margin-top: 2px;
}

/* CTA Card: Got a base that holds? (purple gradient) */
.bt-cta-card {
  background: linear-gradient(135deg, var(--bt-color-prelim-bg) 0%, var(--bt-color-card) 100%);
  border: 1px solid var(--bt-color-prelim-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-24) var(--bt-space-16);
  margin-top: var(--bt-space-16);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-16);
  align-items: flex-start;
}

.bt-cta-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--bt-color-prelim-tint);
}

.bt-cta-desc {
  font-size: 14px;
  color: var(--bt-color-secondary);
  line-height: 1.5;
  max-width: 600px;
}

/* FAQ (Native details/summary) */
.bt-faq {
  margin-top: var(--bt-space-32);
  margin-bottom: var(--bt-space-32);
}

.bt-faq-list {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  margin-top: var(--bt-space-16);
}

.bt-faq-item {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-16);
  transition: border-color 0.15s ease;
}

.bt-faq-item[open] {
  border-color: var(--bt-color-divider);
}

.bt-faq-summary {
  font-family: var(--bt-font-body);
  font-size: 16px;
  font-weight: 700;
  color: var(--bt-color-text);
  cursor: pointer;
  outline: none;
  user-select: none;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-8);
}

.bt-faq-summary:focus-visible {
  outline: 2px solid var(--bt-color-accent);
  outline-offset: 2px;
}

.bt-faq-summary::-webkit-details-marker {
  display: none;
}

.bt-faq-summary::after {
  content: '+';
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  color: var(--bt-color-muted);
  line-height: 1;
}

.bt-faq-item[open] .bt-faq-summary::after {
  content: '−';
}

.bt-faq-answer {
  margin-top: var(--bt-space-12);
  font-size: 14px;
  line-height: 1.6;
  color: var(--bt-color-secondary);
}


.bt-filter-bar {
  position: sticky;
  top: var(--bt-btn-height);
  z-index: 80;
  background-color: var(--bt-color-page);
  padding: var(--bt-space-12) 0;
  border-bottom: 1px solid var(--bt-color-card-border);
  margin-bottom: var(--bt-space-24);
}

.bt-filter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-12);
  flex-wrap: wrap;
  margin-top: var(--bt-space-12);
}

.bt-filter-controls {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  flex-wrap: wrap;
}

@media (max-width: 599px) {
  .bt-filter-controls {
    width: 100%;
    justify-content: flex-start;
  }
}

.bt-select {
  min-height: var(--bt-touch-min);
  padding: 0 var(--bt-space-12);
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-pill);
  color: var(--bt-color-text);
  font-family: var(--bt-font-body);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  outline: none;
}

.bt-select:focus-visible {
  border-color: var(--bt-color-divider);
  outline: 2px solid var(--bt-color-accent);
  outline-offset: 2px;
}

.bt-checkbox-label {
  display: inline-flex;
  align-items: center;
  gap: var(--bt-space-8);
  min-height: var(--bt-touch-min);
  font-size: 14px;
  font-weight: 600;
  color: var(--bt-color-text);
  cursor: pointer;
  user-select: none;
}

.bt-checkbox {
  accent-color: var(--bt-color-info);
  width: 16px;
  height: 16px;
  cursor: pointer;
}

/* Responsive Card Grid: 1 col on mobile, 2 cols at 600px, 3 cols at 900px */
.bt-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--bt-space-16);
}

@media (min-width: 600px) {
  .bt-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 900px) {
  .bt-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--bt-space-24);
  }
}

/* Toast Notice */
.bt-toast {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: calc(var(--bt-nav-height) + max(var(--bt-space-16), env(safe-area-inset-bottom)));
  z-index: 120;
  max-width: calc(100vw - var(--bt-space-32));
  padding: var(--bt-space-12) var(--bt-space-16);
  border-radius: var(--bt-radius-btn);
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  color: var(--bt-color-text);
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 4px 0 #000000;
  text-align: center;
  display: none;
}

.bt-toast.error {
  border-color: var(--bt-color-danger);
  color: var(--bt-color-danger-tint);
}

@media (min-width: 900px) {
  .bt-toast {
    bottom: max(var(--bt-space-32), env(safe-area-inset-bottom));
  }
}

/* Modal / Dialog */
dialog.bt-dialog {
  border: 1px solid var(--bt-color-card-border);
  background-color: var(--bt-color-card);
  color: var(--bt-color-text);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-24);
  width: min(30rem, calc(100vw - var(--bt-space-32)));
  max-width: calc(100vw - var(--bt-space-32));
  max-height: calc(100vh - var(--bt-space-80));
  max-height: calc(100dvh - var(--bt-space-80));
  overflow-y: auto;
  box-sizing: border-box;
  margin: auto;
}

dialog.bt-dialog::backdrop {
  background-color: rgba(0, 0, 0, 0.85);
}

@media (max-width: 600px) {
  dialog.bt-dialog {
    margin: auto auto 0 auto;
    width: 100vw;
    max-width: 100vw;
    max-height: calc(100vh - var(--bt-space-16));
    max-height: calc(100dvh - var(--bt-space-16));
    border-radius: var(--bt-radius-card) var(--bt-radius-card) 0 0;
    border-bottom: 0;
    border-left: 0;
    border-right: 0;
    padding: var(--bt-space-16) var(--bt-space-16) max(var(--bt-space-24), env(safe-area-inset-bottom));
    overscroll-behavior: contain;
  }
}

.bt-dialog-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin-bottom: var(--bt-space-8);
}

.bt-dialog-sub {
  font-size: 14px;
  color: var(--bt-color-muted);
  line-height: 1.4;
  margin-bottom: var(--bt-space-16);
}

.bt-field {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  margin-bottom: var(--bt-space-16);
}

.bt-field-label {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--bt-color-secondary);
}

.bt-input, .bt-textarea {
  width: 100%;
  min-height: var(--bt-touch-min);
  padding: var(--bt-space-8) var(--bt-space-16);
  border-radius: var(--bt-radius-pill);
  border: 1px solid var(--bt-color-card-border);
  background-color: var(--bt-color-page);
  color: var(--bt-color-text);
  font-family: var(--bt-font-body);
  font-size: 14px;
  box-sizing: border-box;
}

.bt-input::placeholder,
.bt-textarea::placeholder,
.bt-input-pill::placeholder {
  color: var(--bt-color-muted);
  opacity: 1;
}

.bt-textarea {
  border-radius: var(--bt-radius-card);
  min-height: 80px;
  resize: vertical;
}

.bt-input:focus, .bt-textarea:focus {
  border-color: var(--bt-color-secondary);
}

.bt-field-error {
  color: var(--bt-color-danger-tint);
  font-size: 13px;
  min-height: var(--bt-space-16);
  line-height: 1.4;
}

.bt-dialog .bt-field-error {
  background-color: var(--bt-glow-bottom);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-8) var(--bt-space-12);
  margin-bottom: var(--bt-space-12);
  text-align: left;
}

.bt-dialog-actions {
  display: flex;
  gap: var(--bt-space-12);
  margin-top: var(--bt-space-16);
}

.bt-dialog-actions .bt-btn {
  flex: 1;
}

.bt-dialog-actions-vertical {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  margin-top: var(--bt-space-16);
}

.bt-dialog-actions-vertical .bt-btn {
  width: 100%;
}

.bt-dialog-legal {
  font-size: 13px;
  color: var(--bt-color-muted);
  margin-top: var(--bt-space-16);
  text-align: center;
  line-height: 1.5;
}

.bt-dialog-legal a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--bt-touch-min);
  min-width: var(--bt-touch-min);
  padding: 0 var(--bt-space-8);
  font-size: 13px;
  color: inherit;
  text-decoration: underline;
}

.bt-legal-footer,
.cg-site-footer {
  border-top: 1px solid var(--bt-card-border);
  padding: var(--bt-space-24) var(--bt-space-16) calc(var(--bt-nav-height, 72px) + var(--bt-space-24) + max(0px, env(safe-area-inset-bottom)));
  font-family: var(--bt-font-body);
  text-align: center;
  box-sizing: border-box;
  width: 100%;
}

@media (min-width: 900px) {
  .bt-legal-footer,
  .cg-site-footer {
    padding-bottom: var(--bt-space-32);
  }
}

.cg-site-footer__inner {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 var(--bt-space-16);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--bt-space-12);
  text-align: center;
  box-sizing: border-box;
}

.cg-site-footer__brand {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--bt-space-4);
  max-width: 720px;
  margin: 0 auto;
}

.cg-site-footer__logo,
.bt-legal-footer img[src*="clashos-logo"],
.bt-legal-footer img {
  width: 48px;
  height: 48px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
  filter: drop-shadow(0 0 8px rgba(241, 165, 51, 0.35));
}

.cg-site-footer__name,
.bt-footer-brand {
  font-family: var(--bt-font-display, 'Barlow Condensed', sans-serif);
  font-weight: 800;
  font-size: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--bt-color-accent);
  margin: 0 auto;
  text-align: center;
}

.cg-site-footer__copy,
.bt-footer-copy {
  font-size: 13px;
  color: var(--bt-color-muted);
  line-height: 1.4;
  margin: 0 auto;
  text-align: center;
}

.cg-site-footer__disclaimer,
.bt-legal-footer p:not(.bt-footer-brand):not(.bt-footer-copy) {
  font-size: 13px;
  line-height: 1.4;
  color: var(--bt-color-muted);
  max-width: 70ch;
  margin: 0 auto;
  text-align: center;
}

.cg-site-footer__nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--bt-space-4);
  margin-top: var(--bt-space-4);
  width: 100%;
}

.cg-site-footer__links-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--bt-space-4) var(--bt-space-12);
  max-width: 900px;
  margin: 0 auto;
}

.cg-site-footer__nav a,
.bt-legal-footer a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--bt-touch-min, 44px);
  min-width: var(--bt-touch-min, 44px);
  padding: 0 var(--bt-space-8);
  font-size: 13px;
  color: var(--bt-color-muted);
  text-decoration: none;
  border-radius: var(--bt-radius-btn);
  transition: color 0.15s ease;
  box-sizing: border-box;
}

.bt-footer-app-links a {
  color: var(--bt-color-text);
  font-weight: 700;
}

.cg-site-footer__nav a:hover,
.cg-site-footer__nav a:focus-visible,
.bt-legal-footer a:hover,
.bt-legal-footer a:focus-visible {
  color: #ffffff;
  text-decoration: underline;
}

/* Sign-in sheet: mode tabs, password field, text button (A2) */
.bt-auth-tabs {
  display: flex;
  gap: var(--bt-space-4);
  padding: var(--bt-space-4);
  margin: var(--bt-space-8) 0 var(--bt-space-16);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-pill);
  background-color: var(--bt-color-page);
}

.bt-auth-tab {
  flex: 1;
  min-height: var(--bt-touch-min);
  padding: 0 var(--bt-space-12);
  border: 0;
  border-radius: var(--bt-radius-pill);
  background: transparent;
  color: var(--bt-color-muted);
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.bt-auth-tab:hover:not(.is-active):not([aria-selected="true"]) {
  color: var(--bt-color-text);
}

.bt-auth-tab.is-active,
.bt-auth-tab[aria-selected="true"] {
  background-color: var(--bt-color-text);
  color: var(--bt-color-page);
}

.bt-auth-tab:focus-visible {
  outline: 2px solid var(--bt-color-text);
  outline-offset: 2px;
}

.bt-pass-wrap {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  width: 100%;
}

.bt-pass-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--bt-touch-min);
  min-width: var(--bt-touch-min);
  padding: 0 var(--bt-space-16);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-pill);
  background: var(--bt-color-page);
  color: var(--bt-color-text);
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
  transition: border-color 0.15s ease;
}

.bt-pass-toggle:hover {
  border-color: var(--bt-color-secondary);
}

.bt-link-button {
  min-height: var(--bt-touch-min);
  border: 0;
  background: none;
  color: var(--bt-color-text);
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
}

#otpCodeInput {
  font-family: monospace;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.25em;
  text-align: center;
}

#otpEmailDisplay {
  font-weight: 700;
  color: var(--bt-color-text);
}

#authSentPanel {
  padding: var(--bt-space-16) 0 var(--bt-space-8);
}

#authSentTitle {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 20px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--bt-color-text);
  margin-bottom: var(--bt-space-8);
}

/* =========================================================================
   BASE DETAIL PAGE (Stage 2)
   ========================================================================= */

.bt-detail-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-16);
  padding: var(--bt-space-16) 0 var(--bt-space-8);
}

.bt-detail-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--bt-space-24);
  margin-top: var(--bt-space-16);
  margin-bottom: var(--bt-space-80);
}

@media (min-width: 900px) {
  .bt-detail-layout {
    grid-template-columns: 1fr 1fr;
    align-items: start;
    margin-bottom: var(--bt-space-32);
  }
}

.bt-detail-col-left,
.bt-detail-col-right {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-16);
  /* L1: the detail page overflowed a 320 wide viewport. A grid item defaults
     to min-width:auto, so one wide child (the action row) stretched the whole
     column to its min-content width. */
  min-width: 0;
}

.bt-detail-hero {
  position: relative;
  aspect-ratio: 16 / 10;
  width: 100%;
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-card-border);
  border-radius: var(--bt-radius-card);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bt-detail-hero:has(#detailCoverEmpty:not(.bt-hidden)) {
  background: radial-gradient(circle at 50% 45%, rgba(32, 36, 46, 0.85) 0%, rgba(14, 16, 22, 0.98) 100%);
  border: 1px solid var(--bt-card-border);
}

#detailCoverEmpty {
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--bt-color-muted);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: var(--bt-space-24) var(--bt-space-16);
  box-sizing: border-box;
  z-index: 2;
}

#detailCoverEmpty::before {
  content: '';
  display: block;
  width: 80px;
  height: 80px;
  margin-bottom: var(--bt-space-8);
  background-image: url("https://cdn.jsdelivr.net/gh/utkarshsah/assets@2f047b18b90cdbbd7e1ac85271aa5a2feff87cb6/bt-small/th_17.webp");
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.9;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.6));
}

#detailCoverEmpty:has(.bt-skeleton)::before,
#detailCoverEmpty:has(.bt-cover-error)::before {
  display: none;
}

#detailCoverEmpty:has(.bt-skeleton) {
  padding: 0;
  background: transparent;
}

.bt-detail-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.45) 0%,
    rgba(0, 0, 0, 0) 40%,
    rgba(0, 0, 0, 0.75) 100%
  );
  z-index: 1;
}

.bt-detail-hero img {
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  display: block;
}

#detailCover {
  aspect-ratio: 16 / 10;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.bt-detail-chips-topleft {
  position: absolute;
  top: var(--bt-space-12);
  left: var(--bt-space-12);
  display: flex;
  flex-wrap: wrap;
  gap: var(--bt-space-4);
  z-index: 2;
  max-width: calc(100% - 80px);
}

.bt-detail-badge-topright {
  position: absolute;
  top: var(--bt-space-12);
  right: var(--bt-space-12);
  z-index: 2;
}

.bt-detail-card {
  background: var(--bt-card-bg);
  border: 1px solid var(--bt-card-border);
  box-shadow: var(--bt-card-shadow);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-16);
}

.bt-detail-title-wrap {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-4);
}

.bt-detail-title-wrap h1,
.bt-detail-title-wrap h2,
.bt-detail-title-wrap .bt-title,
.bt-title,
#detailLabel {
  font-family: var(--bt-font-display);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  overflow-wrap: anywhere;
  word-break: break-word;
  min-width: 0;
}

.bt-card-meta-dim:empty,
#detailStatsNote:empty,
#detailNames:empty,
#adoptResult:empty,
#adoptError:empty {
  display: none !important;
}

/* Proof Hero Card: Center of the page */
.bt-detail-proof-card {
  background: var(--bt-card-bg);
  border: 1px solid var(--bt-card-border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 2px 0 #0c0e13;
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-24) var(--bt-space-16);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-16);
  position: relative;
  overflow: hidden;
}

.bt-detail-proof-card--stable {
  border-color: var(--bt-card-border);
}

.bt-detail-proof-card--prelim {
  border: 1px dashed var(--bt-color-divider);
  background: var(--bt-card-bg);
}

.bt-detail-proof-card--none,
.bt-detail-proof-card--insufficient {
  border: 1px dashed var(--bt-color-divider);
}

.bt-proof-banner-prelim {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  background-color: var(--bt-color-prelim-bg);
  border: 1px solid var(--bt-color-prelim-border);
  border-radius: var(--bt-radius-btn);
  padding: var(--bt-space-8) var(--bt-space-12);
  color: var(--bt-color-prelim-tint);
  font-size: 13px;
  font-weight: 600;
}

.bt-proof-big-group {
  display: flex;
  align-items: baseline;
  gap: var(--bt-space-8);
}

.bt-proof-big-num {
  font-family: var(--bt-font-game);
  font-weight: var(--bt-weight-display-xl);
  font-size: 48px;
  line-height: 1;
  color: #F1A533;
  letter-spacing: 0.01em;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(180deg, #FFD36B 0%, #F1A533 50%, #B9731A 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  -webkit-text-stroke: 2px #2a1604;
  paint-order: stroke fill;
  filter: drop-shadow(0 3px 0 #000000) drop-shadow(0 0 8px rgba(241, 165, 51, 0.4));
}

.bt-proof-big-num--prelim {
  color: #F1A533;
}

.bt-proof-big-label {
  font-family: var(--bt-font-body);
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  color: var(--bt-color-muted);
  letter-spacing: 0.04em;
  margin-left: 2px;
}

.bt-proof-exact-line {
  font-size: 14px;
  font-weight: 600;
  color: var(--bt-color-secondary);
}

/* L1 detail page: the fraction headline has no "held" suffix and no bar. */
.bt-proof-big-group--plain {
  gap: 0;
}

.bt-proof-early {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: var(--bt-space-8);
}

.bt-proof-early-label {
  font-family: var(--bt-font-display);
  font-size: 14px;
  font-weight: var(--bt-weight-display);
  text-transform: uppercase;
  color: var(--bt-color-prelim-tint);
  letter-spacing: 0.04em;
}

.bt-proof-early-line {
  font-size: 13px;
  line-height: 1.5;
  color: var(--bt-color-muted);
}

.bt-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--bt-space-12);
  align-items: stretch;
}

@media (min-width: 600px) {
  .bt-stats-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.bt-stat-metric {
  background-color: var(--bt-color-page);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-btn);
  padding: var(--bt-space-12);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  height: 100%;
  box-sizing: border-box;
}

.bt-stat-metric .bt-stat-label,
.bt-stat-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--bt-color-muted);
  margin-bottom: var(--bt-space-4);
  line-height: 1.2;
}

.bt-stat-metric .bt-stat-val {
  display: block;
  font-family: var(--bt-font-display);
  font-weight: 700;
  font-size: clamp(16px, 2.5vw, 24px);
  color: var(--bt-color-text);
  line-height: 1.15;
  word-break: normal;
  overflow-wrap: break-word;
}

.bt-stat-metric .bt-stat-sub,
.bt-stat-sub {
  display: block;
  font-size: 13px;
  color: var(--bt-color-muted);
  margin-top: var(--bt-space-4);
  line-height: 1.25;
}

/* Attacker Town Hall Histogram ("Hit by") */
.bt-th-hist-section {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  margin-top: var(--bt-space-12);
}

.bt-th-hist-title {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--bt-color-muted);
}

.bt-th-hist-row {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  flex-wrap: wrap;
}

.bt-th-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--bt-space-4);
  background-color: var(--bt-color-page);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-pill);
  padding: var(--bt-space-4) var(--bt-space-8);
  font-size: 13px;
  font-weight: 600;
  color: var(--bt-color-text);
}

.bt-th-count {
  color: var(--bt-color-muted);
  font-family: var(--bt-font-body);
  font-weight: 700;
  font-size: 13px;
}

/* Method Note Card */
.bt-method-note {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-16);
  font-size: 13px;
  color: var(--bt-color-muted);
  line-height: 1.5;
}

/* Desktop Action Buttons in Proof Column */
.bt-detail-actions-desktop {
  display: none;
  gap: var(--bt-space-12);
  align-items: center;
  flex-wrap: wrap;
}

@media (min-width: 900px) {
  .bt-detail-actions-desktop {
    display: flex;
  }
}

.bt-detail-actions-desktop #detailCopyBtn,
.bt-detail-actions-desktop #detailOpenBtn {
  flex: 1 1 auto !important;
  min-width: 0;
  min-height: 48px;
  font-size: 13px;
  line-height: 1.2;
  text-align: center;
  padding: var(--bt-space-8) var(--bt-space-12);
}

.bt-detail-actions-desktop #detailReportBtn {
  flex: 0 0 auto !important;
  min-height: 48px;
  padding: 0 var(--bt-space-16);
}

/* Phone Sticky Action Bar */
.bt-detail-mobile-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background-color: #0c0e13;
  border-top: 1px solid var(--bt-color-card-border);
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.4);
  padding: var(--bt-space-8) var(--bt-space-16) calc(var(--bt-space-8) + max(0px, env(safe-area-inset-bottom)));
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--bt-space-8);
  box-sizing: border-box;
}

.bt-detail-mobile-bar #detailMobileCopyBtn,
.bt-detail-mobile-bar #detailMobileOpenBtn {
  flex: 1 1 calc(50% - var(--bt-space-4)) !important;
  width: calc(50% - var(--bt-space-4)) !important;
  min-width: 0;
  min-height: 44px;
  font-size: 13px;
  line-height: 1.2;
  text-align: center;
  padding: var(--bt-space-4) var(--bt-space-4);
  box-sizing: border-box;
}

.bt-detail-mobile-bar:not(:has(#detailMobileOpenBtn:not([hidden]))) #detailMobileCopyBtn {
  flex: 1 0 100% !important;
  width: 100% !important;
}

.bt-detail-mobile-bar #detailMobileAdoptBtn {
  flex: 1 1 auto !important;
  min-height: 44px;
  font-size: 13px;
  padding: 0 var(--bt-space-8);
  box-sizing: border-box;
}

.bt-detail-mobile-bar #detailMobileReportBtn {
  flex: 0 0 auto !important;
  min-height: 44px;
  font-size: 13px;
  padding: 0 var(--bt-space-12);
  box-sizing: border-box;
}

@media (min-width: 900px) {
  .bt-detail-mobile-bar {
    display: none;
  }
}

body.bt-detail-active .bt-nav {
  display: none !important;
}

body.bt-detail-active #detailView {
  padding-bottom: calc(var(--bt-space-80) + var(--bt-space-32) + max(var(--bt-space-16), env(safe-area-inset-bottom)));
}

/* More bases like this */
.bt-more-bases {
  margin-top: var(--bt-space-32);
  padding-top: var(--bt-space-24);
  border-top: 1px solid var(--bt-color-card-border);
}

.bt-more-bases-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--bt-space-16);
  margin-top: var(--bt-space-16);
}

@media (min-width: 600px) {
  .bt-more-bases-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 900px) {
  .bt-more-bases-grid {
    grid-template-columns: 1fr;
    gap: var(--bt-space-24);
  }
}

/* ================================================================== *
 * BaseTrace Stage 3 — Defense Lab, Shell & Modals
 * ================================================================== */

/* Top Bar Notices Bell & Unread Badge */
.bt-bell-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  background: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-btn);
  color: var(--bt-color-text);
  cursor: pointer;
  padding: 0;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.bt-bell-btn:hover {
  border-color: var(--bt-color-secondary);
  background: var(--bt-color-card-border);
}

.bt-bell-btn:focus-visible {
  outline: 2px solid var(--bt-color-info-tint);
  outline-offset: 2px;
}

.bt-badge-unread {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 var(--bt-space-4);
  box-sizing: border-box;
  background-color: var(--bt-color-live);
  color: #ffffff;
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 700;
  line-height: 18px;
  border-radius: var(--bt-radius-pill);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  white-space: nowrap;
}

/* Notices Slide-up Sheet / Dropdown */
.bt-notices-sheet-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.6);
  z-index: 1000;
}

.bt-notices-sheet {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  color: var(--bt-color-text);
  z-index: 1001;
  display: flex;
  flex-direction: column;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-height: 80vh;
  max-height: 80dvh;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  border-bottom: 0;
  padding-bottom: max(var(--bt-space-16), env(safe-area-inset-bottom));
  animation: btSlideUp 0.25s ease-out;
}

@media (min-width: 900px) {
  .bt-notices-sheet {
    position: absolute;
    top: calc(100% + var(--bt-space-8));
    right: 0;
    bottom: auto;
    left: auto;
    width: 24rem;
    max-height: 32rem;
    border-radius: var(--bt-radius-card);
    border-bottom: 1px solid var(--bt-color-card-border);
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.6);
    animation: none;
    padding-bottom: 0;
  }
}

@keyframes btSlideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

.bt-notices-header {
  position: sticky;
  top: 0;
  background: var(--bt-color-card);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--bt-space-16);
  border-bottom: 1px solid var(--bt-color-card-border);
}

.bt-notices-close {
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  line-height: 1;
  color: var(--bt-color-muted);
  cursor: pointer;
  background: transparent;
  border: none;
  padding: 0;
}

.bt-notices-close:hover {
  color: var(--bt-color-text);
}

.bt-notices-close:focus-visible {
  outline: 2px solid var(--bt-color-info-tint);
  outline-offset: 2px;
}

.bt-notices-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  text-transform: uppercase;
  color: var(--bt-color-text);
  margin: 0;
}

.bt-notices-body {
  padding: var(--bt-space-16);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-12);
  scrollbar-width: thin;
  scrollbar-color: var(--bt-color-divider) transparent;
}

/* Dark scrollbars for scrolling containers on dark surfaces */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--bt-color-divider) transparent;
}

.bt-notices-body,
.bt-notices-sheet,
.bt-dialog,
.bt-modal,
.bt-sheet,
.sheet,
dialog,
.bt-tabs-scroll,
.bt-top-held-scroll,
.bt-viewer-scroll {
  scrollbar-width: thin;
  scrollbar-color: var(--bt-color-divider) transparent;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background-color: var(--bt-color-divider);
  border-radius: var(--bt-radius-pill);
}

::-webkit-scrollbar-thumb:hover {
  background-color: var(--bt-color-secondary);
}

body.bt-scroll-locked {
  overflow: hidden !important;
}

/* Notice Item Type Colors (Full 1px border + faint tinted background, NO accent side bars) */
.bt-notice {
  border: 1px solid var(--bt-color-card-border);
  border-radius: 8px;
  background-color: var(--bt-card-bg);
  padding: var(--bt-space-12);
  color: var(--bt-color-text);
}

.bt-notice.is-green,
.bt-notice.is-blue,
.bt-notice.is-live,
.bt-notice.is-approved,
.bt-notice.is-restored {
  border: 1px solid rgba(62, 123, 196, 0.35);
  background: rgba(62, 123, 196, 0.08);
}

.bt-notice.is-red,
.bt-notice.is-hidden,
.bt-notice.is-removed {
  border: 1px solid rgba(212, 68, 58, 0.35);
  background: rgba(212, 68, 58, 0.08);
}

.bt-notice.is-grey,
.bt-notice.is-info,
.bt-notice.is-pending {
  border: 1px solid var(--bt-color-card-border);
  background: var(--bt-card-bg);
}

/* Signed-Out Onboarding (3-step tiles) */
.bt-onboarding-wrap {
  text-align: center;
  padding: var(--bt-space-32) var(--bt-space-16);
  max-width: 1100px;
  margin: 0 auto;
}

.bt-onboarding-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display-xl);
  font-size: 36px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--bt-color-text);
  margin: 0 0 var(--bt-space-8);
}

@media (min-width: 900px) {
  .bt-onboarding-title {
    font-size: 48px;
  }
}

.bt-onboarding-sub {
  font-size: 16px;
  color: var(--bt-color-secondary);
  line-height: 1.5;
  max-width: 600px;
  margin: 0 auto var(--bt-space-32);
}

.bt-steps-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--bt-space-16);
  text-align: left;
  margin-bottom: var(--bt-space-24);
}

@media (min-width: 900px) {
  .bt-steps-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--bt-space-24);
  }
}

.bt-step-card {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-24);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-12);
  position: relative;
}

.bt-step-card.bt-step-muted {
  opacity: 0.75;
  border-style: dashed;
}

.bt-step-num {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display-xl);
  font-size: 24px;
  background-color: var(--bt-color-card-border);
  color: var(--bt-color-text);
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.4);
  border-radius: var(--bt-radius-btn);
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.bt-step-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  text-transform: uppercase;
  color: var(--bt-color-text);
  margin: 0;
}

.bt-step-desc {
  font-size: 14px;
  color: var(--bt-color-secondary);
  line-height: 1.5;
  margin: 0;
}

.bt-step-actions {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  margin-top: auto;
  padding-top: var(--bt-space-12);
}

.bt-onboarding-why {
  font-size: 14px;
  color: var(--bt-color-muted);
  margin-top: var(--bt-space-24);
}

.bt-onboarding-terms {
  font-size: 13px;
  color: var(--bt-color-muted);
  margin-top: var(--bt-space-8);
}

.bt-onboarding-terms a {
  display: inline-flex;
  align-items: center;
  min-height: var(--bt-touch-min);
  padding: 0 var(--bt-space-8);
  color: var(--bt-color-muted);
  text-decoration: underline;
}

.bt-onboarding-terms a:hover {
  color: var(--bt-color-text);
}

/* Signed-out "What you get" card in My Bases */
.bt-what-get-card {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-16) var(--bt-space-24);
  margin-bottom: var(--bt-space-24);
  text-align: left;
}

.bt-what-get-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 20px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--bt-color-text);
  margin: 0 0 var(--bt-space-12);
}

.bt-what-get-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
}

.bt-what-get-list li {
  font-size: 14px;
  color: var(--bt-color-secondary);
  line-height: 1.5;
  display: flex;
  align-items: flex-start;
  gap: var(--bt-space-8);
}

.bt-what-get-list li::before {
  content: "•";
  color: var(--bt-color-muted);
  font-size: 16px;
  line-height: 1.2;
}

/* Defense Lab Signed-in Home Header & Tiles */
.bt-lab-header {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  margin-bottom: var(--bt-space-24);
}

@media (min-width: 600px) {
  .bt-lab-header {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }
}

.bt-lab-title {
  font-family: var(--bt-font-game);
  font-weight: var(--bt-weight-display-xl);
  font-size: 36px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--bt-color-text);
  margin: 0;
}

@media (max-width: 599px) {
  .bt-lab-title {
    font-size: 28px;
    line-height: 1.2;
  }
}

@media (min-width: 900px) {
  .bt-lab-title {
    font-size: 48px;
  }
}

.bt-lab-status {
  font-size: 14px;
  color: var(--bt-color-secondary);
  margin: 0;
}

.bt-stats-tiles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--bt-space-8);
  margin-bottom: var(--bt-space-24);
}

@media (min-width: 600px) {
  .bt-stats-tiles {
    gap: var(--bt-space-16);
  }
}

.bt-stat-tile {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-12);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-4);
  text-align: center;
}

@media (min-width: 600px) {
  .bt-stat-tile {
    padding: var(--bt-space-16);
    text-align: left;
  }
}

.bt-stat-val {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display-xl);
  font-size: 24px;
  color: var(--bt-color-text);
  line-height: 1;
}

@media (min-width: 600px) {
  .bt-stat-val {
    font-size: 36px;
  }
}

.bt-stat-lbl {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--bt-color-muted);
}

/* Accounts Card & Grid */
.account-strip,
.bt-accounts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--bt-space-16);
  margin-bottom: var(--bt-space-24);
  width: 100%;
}

@media (min-width: 900px) {
  .account-strip,
  .bt-accounts-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.bt-account-card,
.bt-account-row {
  background: var(--bt-card-bg);
  border: 1px solid var(--bt-card-border);
  box-shadow: var(--bt-card-shadow);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-16);
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-12);
  text-align: left;
  align-items: stretch;
  box-sizing: border-box;
  transition: border-color 0.15s ease;
}

.bt-account-card:hover {
  border-color: var(--bt-color-divider);
}

.bt-account-card .bt-btn-ghost {
  background-color: transparent;
  border: 1px solid var(--bt-color-card-border);
  color: var(--bt-color-secondary);
  font-size: 14px;
  font-weight: 600;
  min-height: var(--bt-touch-min);
  padding: 0 var(--bt-space-12);
  border-radius: var(--bt-radius-btn);
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}

.bt-account-card .bt-btn-ghost:hover:not(:disabled) {
  border-color: var(--bt-color-secondary);
  color: var(--bt-color-text);
  background-color: rgba(255, 255, 255, 0.04);
}

.bt-account-identity {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-8);
  flex-wrap: wrap;
  width: 100%;
  min-height: 28px;
}

.bt-account-name {
  font-weight: 500;
  color: var(--bt-color-muted);
  font-size: 14px;
}

.bt-account-tag {
  color: var(--bt-color-text);
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 1.25rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.1;
}

.bt-account-bases {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  width: 100%;
}

.bt-account-base-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-8);
  min-height: 36px;
  width: 100%;
  padding-top: var(--bt-space-8);
  border-top: 1px solid var(--bt-color-card-border);
}

.bt-account-base-row:first-child {
  border-top: 1px solid var(--bt-color-card-border);
}

.bt-account-base-info {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  min-width: 0;
  flex: 1;
}

.bt-account-base-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.bt-account-toggle-row {
  display: flex;
  align-items: center;
  min-height: 44px;
  width: 100%;
  padding-top: var(--bt-space-8);
  border-top: 1px solid var(--bt-color-card-border);
}

.bt-account-toggle-wrap {
  display: inline-flex;
  align-items: center;
  gap: var(--bt-space-8);
  font-size: 13px;
  color: var(--bt-color-secondary);
  cursor: pointer;
  min-height: 44px;
  width: 100%;
}

/* Unverified Callout (full 1px info border + faint bg, NO accent left bar) */
.bt-unverified-callout {
  background-color: var(--bt-color-info-bg);
  border: 1px solid var(--bt-color-info-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-16);
  margin-bottom: var(--bt-space-24);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-12);
}

@media (min-width: 600px) {
  .bt-unverified-callout {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.bt-unverified-text {
  color: var(--bt-color-text);
  font-size: 14px;
  line-height: 1.5;
  margin: 0;
}

/* Status Chips */
.bt-chip-live {
  background-color: var(--bt-color-info-bg);
  border: 1px solid var(--bt-color-info-border);
  color: var(--bt-color-info-tint);
}

.bt-chip-pending {
  background-color: var(--bt-color-card);
  border: 1px dashed var(--bt-color-divider);
  color: var(--bt-color-muted);
}

/* "Collecting data" / "N of 3 verified players" — insufficient proof state.
   Same grey dashed treatment as the pending chip: it is a count-in-progress,
   not a warning and not "No war data yet". */
.bt-chip-collect {
  background-color: var(--bt-color-card);
  border: 1px dotted var(--bt-color-secondary);
  border-radius: var(--bt-radius-card);
  color: var(--bt-color-secondary);
  font-weight: 600;
}

.bt-chip-hidden {
  background-color: rgba(202, 2, 2, 0.1);
  border: 1px solid var(--bt-color-danger);
  color: var(--bt-color-danger-tint);
}

.bt-chip-private {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-divider);
  color: var(--bt-color-muted);
}

.chip-row,
.bt-chips-wrap,
.defense-chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--bt-space-4);
  align-items: center;
}

/* War History Accordion */
.bt-war-accordion {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  margin-top: var(--bt-space-24);
  overflow: hidden;
}

.bt-war-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--bt-space-16);
  cursor: pointer;
  outline: none;
  user-select: none;
  list-style: none;
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  text-transform: uppercase;
  color: var(--bt-color-text);
}

.bt-war-summary:focus-visible {
  outline: 2px solid var(--bt-color-accent);
  outline-offset: 2px;
}

.bt-war-summary::-webkit-details-marker {
  display: none;
}

.bt-war-summary::after {
  content: '+';
  color: var(--bt-color-text);
}

.bt-war-accordion[open] .bt-war-summary::after {
  content: '−';
}

.bt-war-list {
  padding: 0 var(--bt-space-16) var(--bt-space-16);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
}

.bt-war-row {
  background-color: var(--bt-color-page);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-12) var(--bt-space-16);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

@media (min-width: 600px) {
  .bt-war-row {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.bt-war-row-meta {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  font-size: 13px;
  color: var(--bt-color-secondary);
  flex-wrap: wrap;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.bt-war-row-actions {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  flex-wrap: wrap;
}

/* Publish Sheet / Bottom Sheet Modal */
.bt-publish-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.75);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--bt-space-16);
}

.bt-publish-modal,
.bt-publish-sheet {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  max-height: 90dvh;
  overflow-y: auto;
  padding: var(--bt-space-24);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-16);
  color: var(--bt-color-text);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.7);
}

.bt-input-pill {
  width: 100%;
  min-height: var(--bt-touch-min);
  padding: var(--bt-space-8) var(--bt-space-16);
  border-radius: var(--bt-radius-pill);
  border: 1px solid var(--bt-color-divider);
  background-color: var(--bt-color-card);
  color: var(--bt-color-text);
  font-family: var(--bt-font-body);
  font-size: 14px;
}

.bt-input-pill:focus-visible {
  outline: 2px solid var(--bt-color-accent);
  outline-offset: 2px;
}

.bt-publish-notice {
  font-size: 13px;
  color: var(--bt-color-muted);
  line-height: 1.5;
  border-top: 1px solid var(--bt-color-card-border);
  padding-top: var(--bt-space-12);
}

.bt-publish-notice a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--bt-touch-min);
  min-width: var(--bt-touch-min);
  padding: 0 var(--bt-space-4);
  color: var(--bt-color-muted);
  text-decoration: underline;
}

.bt-publish-notice a:hover {
  color: var(--bt-color-text);
}


/* =========================================================================
   HERO TACTICAL BACKGROUND (.bt-hero-bg)
   ========================================================================= */

.bt-hero-bg {
  position: relative;
  isolation: isolate;
}

.bt-hero.bt-hero-bg,
.bt-lab-header.bt-hero-bg {
  border-bottom: 1px solid rgba(241, 165, 51, 0.35);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.8), 0 4px 16px rgba(241, 165, 51, 0.05);
  padding-bottom: var(--bt-space-16);
}

.bt-hero-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    radial-gradient(ellipse 70% 60% at 50% -10%, rgba(241, 165, 51, 0.12) 0%, transparent 70%),
    radial-gradient(ellipse 50% 80% at 15% 10%, rgba(58, 15, 102, 0.4) 0%, transparent 60%),
    radial-gradient(ellipse 50% 80% at 85% 10%, rgba(74, 10, 20, 0.3) 0%, transparent 60%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.02) 0, rgba(255, 255, 255, 0.02) 1px, transparent 1px, transparent 16px),
    repeating-linear-gradient(-45deg, rgba(0, 0, 0, 0.15) 0, rgba(0, 0, 0, 0.15) 1px, transparent 1px, transparent 16px);
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 0.9) 80%, rgba(0, 0, 0, 0) 100%);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 0.9) 80%, rgba(0, 0, 0, 0) 100%);
}

/* Verified Chip with Checkmark */
.bt-chip-live,
.bt-chip-verified {
  background-color: var(--bt-color-info-bg);
  border: 1px solid var(--bt-color-info-border);
  color: var(--bt-color-info-tint);
  display: inline-flex;
  align-items: center;
}

/* Button & Control Tactile Pressed States */
.bt-btn-ghost:active:not(:disabled) {
  background-color: var(--bt-color-card-border);
  transform: translateY(1px);
}

.bt-tab:active {
  transform: scale(0.98);
}

.bt-seg-btn:active {
  transform: scale(0.97);
}

/* Cover Image Retry State */
.bt-cover-error {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  background-color: var(--bt-color-card);
  padding: var(--bt-space-16);
  text-align: center;
}

.bt-cover-retry-btn {
  font-size: 13px;
  padding: 0 var(--bt-space-12);
  min-height: 44px;
}

/* One-time Gallery Hint for No War Data Cards */
.bt-no-data-hint {
  font-size: 13px;
  color: var(--bt-color-muted);
  margin-top: var(--bt-space-8);
  margin-bottom: var(--bt-space-16);
  padding: 0 var(--bt-space-4);
  line-height: 1.4;
}

/* Verified Accounts Card Responsive Width */
.verified-card,
#verifiedAccounts {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

@media (min-width: 900px) {
  .verified-card,
  #verifiedAccounts {
    max-width: 720px;
  }
}

/* Add Base Redact Controls: Disabled Buttons & Status Line */
.bt-redact-actions button:disabled,
#btRedactUndo:disabled,
#btRedactClear:disabled,
#btRedactRemove:disabled {
  opacity: 1 !important;
  color: #949494 !important;
  background-color: #141414 !important;
  border: 1px dashed #2A2A2A !important;
  cursor: not-allowed;
}

.bt-redact-status-line,
#btRedactNoNames {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--bt-color-muted, #949494);
  font-size: 13px;
  font-weight: 500;
  border: none !important;
  background: transparent !important;
  box-shadow: none !important;
  padding: 0 4px;
}

/* Icon Constraint */
.btn-icon {
  width: 18px;
  height: 18px;
  max-width: 18px;
  max-height: 18px;
  flex-shrink: 0;
}

/* Publish Sheet Sub-elements */
.bt-publish-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--bt-space-12);
}

.bt-publish-title {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 24px;
  text-transform: uppercase;
  color: var(--bt-color-text);
  margin: 0;
}

.bt-publish-body {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-16);
}

.bt-publish-step {
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-4);
  padding: var(--bt-space-12);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  background: var(--bt-color-page);
}

.bt-step-badge {
  font-family: var(--bt-font-body);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--bt-color-secondary);
}

.bt-publish-actions {
  margin-top: var(--bt-space-8);
}

/* Switch Component (.switch, .slider) */
.switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.switch input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  opacity: 0;
}

.slider {
  position: relative;
  width: 48px;
  height: 24px;
  background-color: #3B3B3B;
  border-radius: var(--bt-radius-pill);
  transition: background-color 0.2s ease;
  flex-shrink: 0;
}

.slider::before {
  content: "";
  position: absolute;
  height: 16px;
  width: 16px;
  left: 4px;
  bottom: 4px;
  background-color: #FFFFFF;
  border-radius: 50%;
  transition: transform 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

.switch input:checked + .slider,
.bt-switch input:checked + .bt-slider {
  background-color: #147BCF !important;
}

.switch input:checked + .slider::before,
.bt-switch input:checked + .bt-slider::before {
  transform: translateX(24px);
}

.switch input:focus-visible + .slider {
  outline: 2px solid #147BCF;
  outline-offset: 2px;
}

/* =========================================================================
   Part 3: Gallery First-Visit Clarity & How-To Components
   ========================================================================= */

/* 3-Step Compact Strip under Hero */
.bt-how-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--bt-space-12);
  margin-top: var(--bt-space-16);
  margin-bottom: var(--bt-space-16);
}

.bt-how-step {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  background: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-8) var(--bt-space-12);
  min-height: var(--bt-touch-min);
}

.bt-how-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: var(--bt-radius-pill);
  background: var(--bt-color-card-border);
  color: var(--bt-color-text);
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display-xl);
  font-size: 13px;
  flex-shrink: 0;
}

.bt-how-text {
  font-size: 13px;
  color: var(--bt-color-secondary);
  line-height: 1.25;
}

@media (max-width: 600px) {
  .bt-how-strip {
    grid-template-columns: 1fr;
    gap: var(--bt-space-8);
  }
}

/* Dimmed Town Hall Tab when zero bases exist: readable contrast >= 4.5:1 with dashed outline */
.bt-tab.bt-tab-empty {
  opacity: 1;
  color: var(--bt-color-muted);
  border-style: dashed;
  border-color: var(--bt-color-card-border);
  background-color: transparent;
}

/* Cold-start honesty banner */
.bt-cold-start-banner {
  background: var(--bt-color-card);
  border: 1px dashed var(--bt-color-divider);
  border-radius: var(--bt-radius-card);
  color: var(--bt-color-muted);
  font-size: 13px;
  line-height: 1.4;
  padding: var(--bt-space-12) var(--bt-space-16);
  margin-top: var(--bt-space-12);
  margin-bottom: var(--bt-space-12);
  text-align: center;
}

/* Help Dialog for How to Read a Card */
.bt-help-block {
  margin-bottom: var(--bt-space-16);
}

.bt-help-block:last-child {
  margin-bottom: 0;
}

.bt-help-heading {
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 16px;
  text-transform: uppercase;
  color: var(--bt-color-text);
  margin: 0 0 var(--bt-space-4) 0;
}

.bt-help-desc {
  font-size: 14px;
  color: var(--bt-color-secondary);
  line-height: 1.4;
  margin: 0;
}

.bt-help-list {
  list-style: none;
  padding: 0;
  margin: var(--bt-space-8) 0;
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
}

.bt-help-list li {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  font-size: 13px;
  color: var(--bt-color-secondary);
}

.bt-help-note {
  font-size: 13px;
  color: var(--bt-color-muted);
  border-top: 1px solid var(--bt-color-divider);
  padding-top: var(--bt-space-8);
  margin: var(--bt-space-8) 0 0 0;
}



/* ------------------------------------------------------------------ *
 * My Bases N2 — first-run checklist, account form, publish summary.
 * Existing tokens only: no new colours, no animation, 13px floor.
 * ------------------------------------------------------------------ */
.bt-checklist {
  max-width: 720px;
  padding: var(--bt-space-16);
  margin-top: var(--bt-space-16);
}

.bt-checklist-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-8);
  flex-wrap: wrap;
}

.bt-checklist-head-title {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  flex-wrap: wrap;
}

.bt-checklist-title {
  font-family: var(--bt-font-display);
  font-size: 20px;
  font-weight: var(--bt-weight-display);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--bt-color-text);
  margin: 0;
}

.bt-checklist-intro {
  font-size: 14px;
  line-height: 1.5;
  color: var(--bt-color-secondary);
  margin: var(--bt-space-8) 0 var(--bt-space-12) 0;
}

.bt-checklist-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
}

.bt-checklist-step {
  display: flex;
  align-items: flex-start;
  gap: var(--bt-space-12);
  padding: var(--bt-space-12);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  transition: border-color 0.15s ease, opacity 0.15s ease;
}

/* Scope 2: Clear Step Hierarchy */
.bt-checklist-step[data-step-status="current"] {
  background-color: var(--bt-color-page);
  border-color: var(--bt-color-divider);
}

.bt-checklist-step[data-step-status="current"] .bt-checklist-num {
  background: var(--bt-color-text);
  color: var(--bt-color-page);
  font-weight: 700;
}

.bt-checklist-step[data-step-status="current"] .bt-checklist-step-title {
  color: var(--bt-color-text);
  font-size: 16px;
  font-weight: 700;
}

.bt-checklist-step[data-step-status="current"] .bt-checklist-body {
  color: var(--bt-color-secondary);
  font-size: 14px;
}

.bt-checklist-step[data-step-status="done"] {
  opacity: 0.85;
  padding: var(--bt-space-12);
  background-color: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.bt-checklist-step[data-step-status="done"] .bt-checklist-num {
  background: rgba(255, 255, 255, 0.12);
  color: var(--bt-color-text);
}

.bt-checklist-step[data-step-status="done"] .bt-checklist-step-title {
  color: var(--bt-color-secondary);
  font-size: 14px;
  font-weight: 600;
}

.bt-checklist-step[data-step-status="done"] .bt-checklist-body {
  color: var(--bt-color-muted);
  font-size: 13px;
}

.bt-checklist-step[data-step-status="todo"] {
  opacity: 0.6;
  background-color: transparent;
  border-color: var(--bt-color-card-border);
}

.bt-checklist-step[data-step-status="todo"] .bt-checklist-num {
  background: transparent;
  border: 1px dashed var(--bt-color-card-border);
  color: var(--bt-color-muted);
}

.bt-checklist-step[data-step-status="todo"] .bt-checklist-step-title {
  color: var(--bt-color-muted);
  font-size: 14px;
  font-weight: 600;
}

.bt-checklist-step[data-step-status="todo"] .bt-checklist-body {
  color: var(--bt-color-muted);
  font-size: 13px;
}

.bt-checklist-step[data-step="verify"] {
  border-style: dashed;
}

.bt-checklist-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  min-width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bt-color-card-border);
  color: var(--bt-color-text);
  font-family: var(--bt-font-display);
  font-weight: var(--bt-weight-display);
  font-size: 14px;
  line-height: 1;
}

.bt-checklist-step-head {
  display: flex;
  align-items: flex-start;
  gap: var(--bt-space-8);
  width: 100%;
}

.bt-checklist-step-head .bt-asset {
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  object-fit: contain;
  margin-top: 2px;
}

.bt-checklist-step-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  flex: 1;
}

.bt-checklist-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  flex: 1;
}

.bt-checklist-step-title {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--bt-color-text);
  margin: 0;
}

.bt-checklist-body {
  font-size: 13px;
  line-height: 1.5;
  color: var(--bt-color-secondary);
  margin: 0;
}

.bt-checklist-actions {
  display: flex;
  align-items: center;
  gap: var(--bt-space-8);
  flex-wrap: wrap;
  margin-top: var(--bt-space-8);
}

#setupCloseBtn {
  min-height: var(--bt-touch-min);
  padding: 0 var(--bt-space-12);
}

#setupReopen {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--bt-touch-min);
  padding: 0 var(--bt-space-16);
  margin-top: var(--bt-space-12);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-pill);
  color: var(--bt-color-secondary);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  background: transparent;
  transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

#setupReopen:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.22);
  color: var(--bt-color-text);
}

#addAccountPanel .field {
  margin-bottom: var(--bt-space-12);
}

#addAccountTag {
  width: 100%;
  min-height: var(--bt-btn-height);
  font-size: 16px;
  padding: 0 var(--bt-space-16);
  font-family: monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  box-sizing: border-box;
}

#addAccountBtn {
  min-height: var(--bt-btn-height);
  font-size: 14px;
}

.bt-panel {
  background: var(--bt-card-bg);
  border: 1px solid var(--bt-card-border);
  box-shadow: var(--bt-card-shadow);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-16);
  margin-top: var(--bt-space-24);
  margin-bottom: var(--bt-space-24);
  box-sizing: border-box;
}

.bt-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-12);
  margin-bottom: var(--bt-space-12);
}

.bt-panel-title {
  font-family: var(--bt-font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--bt-color-text);
  line-height: 1.1;
  margin: 0;
}

.bt-panel-lists {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--bt-space-12);
  margin-top: var(--bt-space-12);
  margin-bottom: var(--bt-space-16);
}

@media (min-width: 600px) {
  .bt-panel-lists {
    grid-template-columns: 1fr 1fr;
    gap: var(--bt-space-16);
  }
}

.bt-panel-lists > div {
  background-color: var(--bt-color-page);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-12) var(--bt-space-16);
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-8);
  box-sizing: border-box;
}



.bt-panel-list-title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--bt-color-text);
  margin: 0;
}

.bt-panel-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--bt-space-4);
}

.bt-panel-list li {
  font-size: 13px;
  line-height: 1.4;
  color: var(--bt-color-secondary);
  position: relative;
  padding-left: var(--bt-space-12);
}

.bt-panel-list li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--bt-color-muted);
}

/* Consent checkboxes with >= 44px tap target */
.bt-check {
  display: flex;
  align-items: flex-start;
  gap: var(--bt-space-12);
  min-height: var(--bt-touch-min);
  padding: var(--bt-space-12) var(--bt-space-16);
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  margin-bottom: var(--bt-space-12);
  cursor: pointer;
  box-sizing: border-box;
  transition: border-color 0.15s ease;
}

.bt-check:hover {
  border-color: var(--bt-color-divider);
}

.bt-check input[type="checkbox"] {
  margin-top: 2px;
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  cursor: pointer;
}

.bt-check span {
  font-size: 13px;
  line-height: 1.4;
  color: var(--bt-color-text);
  flex: 1;
}

.bt-check input[type="checkbox"]:disabled + span {
  color: var(--bt-color-muted);
}

/* Share / Publish Card Flow on my-bases.html */
#btForm .bt-panel-lists {
  margin-top: var(--bt-space-8);
  margin-bottom: var(--bt-space-12);
}

#btForm .field {
  margin-bottom: var(--bt-space-12);
}

#btForm .field-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--bt-color-text);
  margin-bottom: 6px;
}

#btForm .field-input {
  width: 100%;
  min-height: 44px;
  padding: 0 var(--bt-space-12);
  background: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: 6px;
  color: #FFFFFF;
  font-size: 14px;
  box-sizing: border-box;
}

#btForm .field-input:focus {
  border-color: #F1A533;
  outline: none;
}

#btForm .field-input:focus-visible {
  outline: 2px solid var(--bt-color-accent);
  outline-offset: 2px;
}

#btForm .field-hint {
  font-size: 13px;
  color: var(--bt-color-muted);
  margin-top: var(--bt-space-4);
  line-height: 1.35;
}

#btForm .bt-check {
  margin-bottom: var(--bt-space-8);
  padding: var(--bt-space-8) var(--bt-space-12);
  min-height: 44px;
}

#btForm .field:has(#btPickShotBtn) {
  border: 1px dashed var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-12) var(--bt-space-16);
  background: transparent;
  margin-top: var(--bt-space-12);
  margin-bottom: var(--bt-space-12);
  box-sizing: border-box;
  transition: border-color 0.15s ease;
}

#btForm .field:has(#btPickShotBtn):hover {
  border-color: rgba(255, 255, 255, 0.25);
}

#btPickShotBtn {
  background: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  color: #FFFFFF;
  font-weight: 600;
  font-size: 14px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  border-radius: var(--bt-radius-btn);
  cursor: pointer;
  margin-top: var(--bt-space-8);
  margin-bottom: var(--bt-space-8);
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

#btPickShotBtn:hover {
  background: var(--bt-color-card-border);
  border-color: rgba(255, 255, 255, 0.3);
  color: #FFFFFF;
}

#btForm .bt-publish-notice {
  font-size: 13px;
  color: var(--bt-color-muted);
  line-height: 1.4;
  margin: var(--bt-space-12) 0;
}

#btPublishBtn {
  min-height: 44px;
  font-weight: 700;
  font-size: 14px;
}

#btCard .bt-cover {
  position: relative;
  min-height: calc(var(--bt-space-80) + var(--bt-space-32));
  max-height: calc(var(--bt-space-80) * 2);
  aspect-ratio: auto;
  background: transparent;
  border: 1px dashed var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--bt-space-12);
  box-sizing: border-box;
}

#btCard .bt-cover:has(#btCoverImg:not(.hidden)) {
  max-height: none;
  aspect-ratio: 16 / 10;
  border-style: solid;
}

#btCard .bt-cover-empty {
  color: var(--bt-color-muted);
  font-size: 13px;
  padding: var(--bt-space-12);
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

@media (min-width: 600px) {
  #btCard:not(.hidden) {
    display: grid;
    grid-template-columns: calc(var(--bt-space-80) * 3) 1fr;
    grid-auto-flow: row;
    gap: var(--bt-space-16);
    align-items: start;
  }

  #btCard .bt-cover {
    grid-column: 1;
    grid-row: 1 / span 2;
    margin-bottom: 0;
  }

  #btCard #btCardMeta {
    grid-column: 2;
    grid-row: 1;
    margin-bottom: 0;
  }

  #btCard .detail-actions {
    grid-column: 2;
    grid-row: 2;
  }

  #btCard #btAppeal,
  #btCard #btPublishIncomplete,
  #btCard #btCardError {
    grid-column: 1 / -1;
  }
}

/* Detail Metrics Grid on my-bases.html */
#detailMetrics.metrics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--bt-space-12);
  margin-top: var(--bt-space-16);
  margin-bottom: var(--bt-space-24);
}

@media (min-width: 600px) {
  #detailMetrics.metrics-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--bt-space-16);
  }
}

#detailMetrics .metric-card {
  background-color: var(--bt-color-card);
  border: 1px solid var(--bt-color-card-border);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-12) var(--bt-space-16);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  box-sizing: border-box;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease, box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

#detailMetrics .metric-card--hero {
  border: 1px solid #F1A533;
  box-shadow: inset 0 1px 0 rgba(255, 211, 107, 0.25), 0 2px 0 #0C0E13;
  background: linear-gradient(180deg, rgba(241, 165, 51, 0.06) 0%, rgba(22, 25, 33, 1) 100%);
  background-image: url('https://cdn.jsdelivr.net/gh/utkarshsah/assets@2f047b18b90cdbbd7e1ac85271aa5a2feff87cb6/th-images/WarGoldI.webp');
  background-repeat: no-repeat;
  background-position: right var(--bt-space-12) top var(--bt-space-12);
  background-size: 28px 28px;
}

#detailMetrics .metric-card:nth-child(2) {
  background-image: url('https://cdn.jsdelivr.net/gh/utkarshsah/assets@2f047b18b90cdbbd7e1ac85271aa5a2feff87cb6/icons/Icon_BB_Star.webp');
  background-repeat: no-repeat;
  background-position: right var(--bt-space-12) top var(--bt-space-12);
  background-size: 24px 24px;
}

#detailMetrics .metric-card:nth-child(3) {
  background-image: url('https://cdn.jsdelivr.net/gh/utkarshsah/assets@2f047b18b90cdbbd7e1ac85271aa5a2feff87cb6/icons/Icon_BB_Battle.webp');
  background-repeat: no-repeat;
  background-position: right var(--bt-space-12) top var(--bt-space-12);
  background-size: 24px 24px;
}

#detailMetrics .metric-card:hover {
  border-color: rgba(255, 255, 255, 0.22);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}

#detailMetrics .metric-label {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #9AA3BA;
  margin-bottom: var(--bt-space-8);
  min-height: 32px;
  line-height: 1.25;
}

#detailMetrics .metric-value {
  font-family: var(--bt-font-display);
  font-size: 32px;
  font-weight: 700;
  color: #F4F1EA;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
  line-height: 1;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

#detailMetrics .metric-card--hero .metric-value {
  color: #F1A533;
  font-family: var(--bt-font-game);
  font-size: 44px;
  font-weight: 800;
  background: linear-gradient(180deg, #FFD36B 0%, #F1A533 50%, #B9731A 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  -webkit-text-stroke: 2px #2A1604;
  paint-order: stroke fill;
  filter: drop-shadow(0 3px 0 #000000) drop-shadow(0 0 8px rgba(241, 165, 51, 0.4));
}

#detailMetrics .metric-sub {
  font-size: 13px;
  color: var(--bt-color-muted);
  margin-top: var(--bt-space-8);
  line-height: 1.4;
}

#detailMetrics.is-dimmed .metric-value {
  opacity: 0.55;
}

#detailMetrics.is-dimmed .metric-sub {
  opacity: 0.7;
}

/* Empty Metrics Presentation (Item 7) */
.metric-card.is-empty .metric-value,
.metric-card--hero.is-empty .metric-value,
.metric-card:has(.metric-sub:empty) .metric-value,
.metric-card--hero:has(.metric-sub:empty) .metric-value,
#detailMetrics .metric-card:has(.metric-sub:empty) .metric-value,
#detailMetrics .metric-card--hero:has(.metric-sub:empty) .metric-value,
.bt-stat-metric.is-empty .bt-stat-val,
.bt-stat-val.is-empty {
  color: var(--bt-color-muted, #8A90A3) !important;
  -webkit-text-fill-color: var(--bt-color-muted, #8A90A3) !important;
  font-family: var(--bt-font-display);
  font-size: 32px;
  font-weight: 700;
  -webkit-text-stroke: 0 !important;
  text-shadow: none !important;
  filter: none !important;
  background: none !important;
}

.metric-card.is-empty,
.metric-card--hero.is-empty,
.metric-card:has(.metric-sub:empty),
#detailMetrics .metric-card--hero:has(.metric-sub:empty) {
  border: 1px solid var(--bt-color-card-border);
  background: var(--bt-color-card);
  background-image: none !important;
  box-shadow: none !important;
}

.metric-sub:empty {
  display: block;
}

/* Round A7: the "No data yet" caption is real text in the caption element
   now (BT_COPY.emptyMetric), so the generated ::before is gone. */


/* Gallery Polish: Showing X of N and Load More */
#galleryShownStatus {
  font-size: 14px;
  font-weight: 600;
  color: var(--bt-color-secondary);
  margin-top: var(--bt-space-12);
  margin-bottom: var(--bt-space-16);
  padding: 0;
  letter-spacing: 0.02em;
}

#galleryLoadMore {
  display: flex;
  justify-content: center;
  margin-top: var(--bt-space-24);
  margin-bottom: var(--bt-space-24);
  width: 100%;
}

#loadMoreBtn {
  min-height: var(--bt-btn-height);
  padding: 0 var(--bt-space-32);
  font-size: 14px;
  font-weight: 600;
  width: 100%;
}

@media (min-width: 600px) {
  #loadMoreBtn {
    width: auto;
  }
}

#loadMoreBtn:disabled,
#loadMoreBtn[aria-busy="true"] {
  opacity: 0.5;
  cursor: not-allowed;
  border-color: var(--bt-color-card-border);
  color: var(--bt-color-muted);
}

/* =========================================================================
   UNIFIED EMPTY STATE PATTERN (.empty-state-card)
   ========================================================================= */

.empty-state-card {
  background-color: var(--bt-color-card);
  border: 1px dashed var(--bt-color-divider);
  border-radius: var(--bt-radius-card);
  padding: var(--bt-space-32) var(--bt-space-16);
  text-align: center;
  margin-bottom: var(--bt-space-24);
  box-sizing: border-box;
}

.empty-state-title {
  font-family: var(--bt-font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--bt-color-text);
  margin-bottom: var(--bt-space-8);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1.2;
}

.empty-state-desc {
  font-size: 14px;
  color: var(--bt-color-secondary);
  max-width: 28rem;
  margin: 0 auto;
  line-height: 1.5;
}

.empty-state-card .bt-btn,
.empty-state-card .btn {
  min-height: var(--bt-btn-height);
  padding: 0 var(--bt-space-24);
  font-size: 14px;
  margin-top: var(--bt-space-16);
}

/* U6.1: iOS input zoom prevention (>= 16px font-size at max-width: 48rem) */
@media (max-width: 48rem) {
  input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not(#otpCodeInput),
  select,
  textarea,
  .bt-input:not(#otpCodeInput),
  .bt-select,
  .bt-textarea,
  .bt-input-pill:not(#otpCodeInput),
  .field-input,
  .field-textarea,
  .field-select,
  #ledgerControls #accountSelect {
    font-size: 16px !important;
  }
}

/* ==========================================================================
   Round G2 Item G1: Full-Screen Image Viewer (#btViewer)
   ========================================================================== */
dialog.bt-viewer {
  position: fixed;
  inset: 0;
  width: 100vw;
  max-width: 100vw;
  height: 100dvh;
  max-height: 100dvh;
  margin: 0;
  padding: 0;
  border: none;
  background: var(--bt-color-page, #07080c);
  color: var(--bt-color-text, #f4f1ea);
  box-sizing: border-box;
  display: none;
  flex-direction: column;
  overflow: hidden;
  overscroll-behavior: contain;
  z-index: 9999;
}

dialog.bt-viewer[open] {
  display: flex;
}

dialog.bt-viewer::backdrop {
  background: var(--bt-color-page, #07080c);
  opacity: 1;
}

body:has(dialog.bt-viewer[open]) {
  overflow: hidden;
}

.bt-viewer-bar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-12, 12px);
  min-height: 56px;
  padding-top: env(safe-area-inset-top, 0px);
  padding-right: max(var(--bt-space-16, 16px), env(safe-area-inset-right, 0px));
  padding-bottom: 0;
  padding-left: max(var(--bt-space-16, 16px), env(safe-area-inset-left, 0px));
  background: var(--bt-color-card, #161921);
  border-bottom: 1px solid var(--bt-color-divider, #323847);
  box-sizing: border-box;
  z-index: 2;
}

.bt-viewer-title {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  font-family: var(--bt-font-body, 'Barlow', -apple-system, sans-serif);
  font-size: 15px;
  font-weight: 600;
  color: var(--bt-color-text, #f4f1ea);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bt-viewer-zoom,
.bt-viewer-close {
  flex: 0 0 auto;
  min-width: var(--bt-touch-min, 44px);
  min-height: var(--bt-touch-min, 44px);
  height: var(--bt-touch-min, 44px);
  padding: 0 var(--bt-space-16, 16px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--bt-font-display, 'Barlow Condensed', sans-serif);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: var(--bt-radius-btn, 6px);
  box-sizing: border-box;
  cursor: pointer;
}

.bt-viewer-close {
  background: transparent;
  border: 1px solid var(--bt-color-divider, #323847);
  color: var(--bt-color-text, #f4f1ea);
}

.bt-viewer-close:hover:not(:disabled) {
  border-color: var(--bt-color-secondary, #a9afbf);
  color: var(--bt-color-text, #f4f1ea);
}

.bt-viewer-zoom {
  background: linear-gradient(180deg, #2c3b57 0%, #202c44 100%);
  border: 1px solid var(--bt-btn-sec-border, #323847);
  box-shadow: 0 2px 0 #0c0e13;
  color: var(--bt-color-text, #f4f1ea);
}

.bt-viewer-zoom:hover:not(:disabled) {
  border-color: var(--bt-color-info-tint, #6db8f5);
  color: var(--bt-color-text, #f4f1ea);
}

.bt-viewer-zoom[aria-pressed="true"],
.bt-viewer-zoom.is-zoomed {
  background: #1b263b;
  border-color: var(--bt-color-info, #3e7bc4);
  color: var(--bt-color-info-tint, #6db8f5);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.4);
}

.bt-viewer-close:focus-visible,
.bt-viewer-zoom:focus-visible {
  outline: 2px solid var(--bt-color-info-tint, #6db8f5);
  outline-offset: 2px;
}

.bt-viewer-scroll {
  flex: 1 1 auto;
  width: 100%;
  height: calc(100dvh - 56px);
  overflow: auto;
  overscroll-behavior: contain;
  touch-action: pan-x pan-y pinch-zoom;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(var(--bt-space-16, 16px), env(safe-area-inset-top, 0px))
           max(var(--bt-space-16, 16px), env(safe-area-inset-right, 0px))
           max(var(--bt-space-16, 16px), env(safe-area-inset-bottom, 0px))
           max(var(--bt-space-16, 16px), env(safe-area-inset-left, 0px));
  box-sizing: border-box;
}

.bt-viewer-scroll:has(.is-zoomed) {
  display: block;
}

.bt-viewer-img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
  cursor: zoom-in;
  transition: transform 0.15s ease-out;
}

@media (prefers-reduced-motion: reduce) {
  .bt-viewer-img {
    transition: none;
  }
}

.bt-viewer-img.is-zoomed {
  width: 200%;
  min-width: 200%;
  max-width: none;
  max-height: none;
  height: auto;
  cursor: grab;
  margin: 0;
}

.bt-viewer-scroll:active .bt-viewer-img.is-zoomed {
  cursor: grabbing;
}

/* =========================================================================
   DEFENSE LEDGER GROUP HEADER (G5)
   Wrap header at narrow viewports without overlap or horizontal overflow
   ========================================================================= */

.defenses-list > .defense-group-head,
.defense-group-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--bt-space-4) var(--bt-space-8);
  min-height: 36px;
}

.defense-group-head .group-title {
  white-space: nowrap;
  flex-shrink: 0;
}

.defense-group-head .group-meta {
  white-space: normal;
  word-break: break-word;
}

/* =========================================================================
   TAP TARGET COMPLIANCE (G7 / H2)
   Enforce minimum 44x44px touch bounding box across interactive components,
   preserving 48px button height while keeping .bt-btn-sm at 44px
   ========================================================================= */

.bt-btn,
.bt-dialog-actions button {
  min-height: max(var(--bt-touch-min, 44px), var(--bt-btn-height, 48px));
}

.bt-btn-sm {
  min-height: var(--bt-touch-min, 44px);
}

.bt-tab,
.bt-seg-btn,
.bt-nav-item,
.bt-input,
.bt-input-pill {
  min-height: var(--bt-touch-min, 44px);
}

/* ================================================================== *
 * UI-7: targeted fixes on the old design. Every value comes from an
 * existing token; no font, colour, radius, shadow or heading rule is
 * touched.
 * ================================================================== */

/* Item 3: one small guide link in each hero. */
.bt-how-link {
  display: inline-flex;
  align-items: center;
  gap: var(--bt-space-8);
  min-height: 44px;
  min-width: 44px;
  padding: 0 var(--bt-space-4);
  margin-top: var(--bt-space-8);
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 700;
  color: var(--bt-color-muted);
  text-decoration: none;
}
.bt-how-link:hover {
  color: var(--bt-color-text);
}

/* Item 6: the type switch and the sort select share the first row, the
   checkbox and the card guide share the second. Below 375 they stack as
   they did before, so nothing can overflow. */
@media (max-width: 599px) {
  .bt-filter-row > .bt-seg { flex: 1 1 auto; }
  .bt-filter-row > .bt-seg .bt-seg-btn { flex: 0 1 auto; padding: 0 var(--bt-space-4); }
  .bt-filter-row > .bt-select { flex: 0 0 8rem; width: 8rem; }
  .bt-filter-row > .bt-filter-controls { width: 100%; justify-content: space-between; }
}

/* Item 5: the counted-results disclosure under the result block. */
.bt-how-counted { margin-top: var(--bt-space-8); }
.bt-how-counted .bt-how-counted-summary {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 13px;
  font-weight: 700;
  color: var(--bt-color-muted);
  cursor: pointer;
  list-style: none;
}
.bt-how-counted .bt-how-counted-summary::-webkit-details-marker { display: none; }
.bt-how-counted[open] .bt-how-counted-summary,
.bt-how-counted .bt-how-counted-summary:hover { color: var(--bt-color-text); }
.bt-how-counted .bt-how-counted-body {
  font-size: 13px;
  line-height: 1.5;
  color: var(--bt-color-muted);
  padding-bottom: var(--bt-space-8);
}
.bt-how-counted .bt-how-counted-body p { margin: 0 0 var(--bt-space-8); }
.bt-how-counted .bt-how-counted-body p:last-child { margin-bottom: 0; }

/* ================================================================== *
 * UI-8: fold quick steps, type switch and sort select on one row.
 * ================================================================== */
.bt-steps-fold {
  margin-top: var(--bt-space-8);
  margin-bottom: var(--bt-space-8);
}
.bt-steps-fold .bt-steps-summary {
  display: inline-flex;
  align-items: center;
  gap: var(--bt-space-4);
  min-height: 44px;
  min-width: 44px;
  font-family: var(--bt-font-body);
  font-size: 13px;
  font-weight: 700;
  color: var(--bt-color-muted);
  cursor: pointer;
  list-style: none;
}
.bt-steps-fold .bt-steps-summary::-webkit-details-marker {
  display: none;
}
.bt-steps-fold .bt-steps-summary::after {
  content: "›";
  display: inline-block;
  font-size: 14px;
  line-height: 1;
  margin-left: var(--bt-space-4);
  transition: transform 0.15s ease;
}
.bt-steps-fold[open] > .bt-steps-summary::after {
  transform: rotate(90deg);
}
.bt-steps-fold[open] > .bt-steps-summary,
.bt-steps-fold .bt-steps-summary:hover {
  color: var(--bt-color-text);
}
@media (min-width: 600px) {
  .bt-steps-fold {
    margin-top: 0;
    margin-bottom: 0;
  }
  .bt-steps-fold > .bt-steps-summary {
    display: none;
  }
}
@media (max-width: 599px) {
  .bt-filter-row {
    align-items: flex-start;
  }
  .bt-filter-row > .bt-seg {
    flex: 0 0 auto;
    width: auto;
  }
  .bt-filter-row > .bt-seg .bt-seg-btn {
    flex: 0 0 auto;
    min-width: 44px;
    min-height: 44px;
    padding: 0 var(--bt-space-8);
  }
  .bt-filter-row > .bt-select {
    flex: 0 1 auto;
    width: 7.5rem;
  }
}
@media (max-width: 23em) {
  .bt-filter-row > .bt-select {
    width: 6rem;
    padding: 0 var(--bt-space-8);
  }
}








