:root {
  color-scheme: dark;
  --bg: #070a10;
  --bg-soft: #0b1018;
  --panel: #111827;
  --panel-2: #162033;
  --panel-3: #1d2a3e;
  --text: #eef4ff;
  --muted: #93a3bd;
  --line: #26344b;
  --accent: #f3b45d;
  --accent-2: #58d59a;
  --danger: #ff647c;
  --warning: #f3d96b;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(243, 180, 93, 0.14), transparent 34rem),
    radial-gradient(circle at top right, rgba(88, 213, 154, 0.08), transparent 28rem),
    var(--bg);
  color: var(--text);
}

button, input { font: inherit; }

button {
  border: 1px solid rgba(243, 180, 93, 0.45);
  border-radius: 10px;
  background: rgba(243, 180, 93, 0.12);
  color: var(--text);
  padding: 10px 14px;
  transition: 160ms ease;
}

button:hover:not(:disabled) {
  transform: translateY(-1px);
  border-color: var(--accent);
  background: rgba(243, 180, 93, 0.2);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

button.ghost {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.03);
}

button.danger-soft {
  border-color: rgba(255, 100, 124, 0.5);
  background: rgba(255, 100, 124, 0.12);
}

button.full { width: 100%; }
button.small { padding: 6px 10px; font-size: 12px; }

input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #0b111d;
  color: var(--text);
  padding: 11px 12px;
}

label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 12px; font-size: clamp(38px, 6vw, 76px); line-height: 0.92; letter-spacing: -0.06em; }
h2 { margin-bottom: 0; font-size: 18px; }

.app-shell {
  width: min(1360px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 40px;
}

.hero {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: start;
  gap: 20px;
  margin-bottom: 18px;
}

.hero-copy { max-width: 860px; }
.eyebrow { margin: 0 0 8px; color: var(--accent); font-size: 12px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; }
.subcopy, .panel p { color: var(--muted); line-height: 1.55; }
.hero-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.hero-tags span, .badge, .sport-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  padding: 7px 10px;
  font-size: 12px;
}

.panel, .session-card, .tab {
  border: 1px solid var(--line);
  background: rgba(17, 24, 39, 0.86);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
}

.panel { border-radius: 18px; padding: 18px; }
.session-card { display: flex; align-items: center; gap: 12px; min-width: 220px; border-radius: 16px; padding: 14px; color: var(--muted); }
.session-card strong { display: block; color: var(--text); font-size: 13px; }
.status-dot { width: 11px; height: 11px; border-radius: 999px; background: var(--danger); box-shadow: 0 0 0 4px rgba(255, 100, 124, 0.1); }
.status-dot.active { background: var(--accent-2); box-shadow: 0 0 0 4px rgba(88, 213, 154, 0.12); }

.control-center { margin-bottom: 14px; }
.section-title { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 14px; }
.login-grid { display: grid; grid-template-columns: 280px 1fr; gap: 14px; align-items: end; }
.quick-logins, .row, .settings-row { display: flex; flex-wrap: wrap; gap: 10px; }
.form-inline { display: grid; grid-template-columns: 1fr 1fr auto; gap: 12px; align-items: end; }
.stack-form { display: grid; gap: 12px; }
.compact button { padding: 8px 10px; }

.role-tabs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 14px 0; }
.tab { color: var(--muted); }
.tab.active { border-color: var(--accent); color: var(--text); background: rgba(243, 180, 93, 0.16); }
.role-view { display: none; }
.role-view.active { display: block; }

.dashboard-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 14px; }
.dashboard-grid.two-col { grid-template-columns: 1fr 1fr; }
.metric-panel { min-height: 260px; }
.metrics-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.metric-card, .user-card, .event-card, .market-card, .slip-item {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  padding: 12px;
}
.metric-card span, .metric-card small, .user-card span, .user-card small, .event-head span, .market-card small, .slip-item span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.metric-card strong { display: block; margin: 5px 0; font-size: 22px; }
.action-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.cards-list { display: grid; gap: 10px; }
.user-card { width: 100%; text-align: left; border-color: var(--line); background: rgba(255,255,255,.03); }

.sportsbook-layout { display: grid; grid-template-columns: 240px 1fr 340px; gap: 14px; align-items: start; }
.sports-sidebar, .bet-slip { position: sticky; top: 16px; }
.sports-list { display: grid; gap: 8px; margin-bottom: 12px; }
.event-list { display: grid; gap: 12px; }
.event-head { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.market-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.market-card.is-disabled { opacity: 0.58; }
.odds-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-top: 8px; }
.odds-button { display: flex; justify-content: space-between; gap: 8px; align-items: center; text-align: left; }
.odds-button span { font-size: 12px; color: var(--muted); }
.odds-button strong { color: var(--text); }
.stream-status { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; color: var(--muted); background: #0d121c; margin-top: 10px; }
.stream-status.connected { color: var(--accent-2); }
.summary-line { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; color: var(--muted); background: rgba(255,255,255,.03); margin: 12px 0; }
.slip-item { display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center; }
.divider { height: 1px; background: var(--line); margin: 14px 0; }
.empty-state { color: var(--muted); border: 1px dashed var(--line); border-radius: 14px; padding: 14px; }
.checklist { display: grid; gap: 10px; color: var(--muted); line-height: 1.45; }
.output-panel { margin-top: 14px; }
pre { overflow: auto; min-height: 260px; margin: 0; border-radius: 14px; border: 1px solid var(--line); background: #05070c; padding: 16px; color: #d9e8ff; }

body[data-role="guest"] .role-view { opacity: 0.86; }

@media (max-width: 1100px) {
  .dashboard-grid, .dashboard-grid.two-col, .sportsbook-layout { grid-template-columns: 1fr; }
  .sports-sidebar, .bet-slip { position: static; }
  .metrics-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
  .app-shell { width: min(100% - 20px, 1360px); padding-top: 20px; }
  .hero, .login-grid, .form-inline, .role-tabs, .market-grid, .odds-grid { grid-template-columns: 1fr; }
  h1 { font-size: 42px; }
  .section-title { align-items: flex-start; flex-direction: column; }
  .metrics-grid, .action-grid { grid-template-columns: 1fr; }
}

/* Sprint 17: mobile-first sportsbook betting board */
.mobile-betting-shell {
  --book-blue: #2f80cf;
  --book-blue-dark: #244988;
  --book-blue-deep: #18366d;
  --book-white: #f4f8fd;
  --book-ink: #193565;
  --book-muted: #6e7d98;
  --book-line: #d7e0ec;
  --book-yellow: #ffd21e;
  --book-green: #19a974;
  max-width: 980px;
  margin: 0 auto;
  color: var(--book-ink);
}

.mobile-book-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 22px 22px 0 0;
  background: linear-gradient(135deg, var(--book-blue), #337bc4 68%, #276db2);
  box-shadow: 0 14px 34px rgba(12, 36, 73, 0.28);
}

.book-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  min-width: 178px;
}

.book-brand strong {
  display: block;
  font-size: 23px;
  letter-spacing: 0.06em;
  color: #ffdc28;
  line-height: 0.9;
}

.book-brand small {
  display: block;
  color: rgba(255, 255, 255, 0.86);
  letter-spacing: 0.46em;
  font-size: 9px;
  margin-top: 4px;
}

.brand-gem {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.18);
  color: white;
  font-size: 26px;
}

.book-search {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  padding: 0 13px;
  background: rgba(234, 242, 255, 0.74);
  color: white;
}

.book-search input {
  border: 0;
  background: transparent;
  color: #163769;
  padding: 12px 0;
  min-width: 0;
}

.book-search input::placeholder { color: rgba(34, 67, 118, 0.48); }
.book-search span { color: rgba(25, 53, 101, 0.62); font-size: 23px; }

.profile-circle {
  width: 48px;
  height: 48px;
  border-radius: 999px;
  border: 0;
  display: grid;
  place-items: center;
  color: var(--book-blue-dark);
  background: rgba(255, 255, 255, 0.85);
  font-weight: 900;
}

.bet-mode-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  background: var(--book-white);
  padding: 12px 10px 0;
  border-left: 1px solid rgba(255,255,255,.32);
  border-right: 1px solid rgba(255,255,255,.32);
}

.bet-mode {
  position: relative;
  border: 0;
  background: transparent;
  color: var(--book-ink);
  border-radius: 0;
  padding: 12px 6px 15px;
  font-size: 18px;
  font-weight: 500;
}

.bet-mode.active::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  width: 46px;
  height: 7px;
  transform: translateX(-50%);
  border-radius: 999px;
  background: var(--book-yellow);
}

.mobile-status-strip {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 16px;
  background: #eef4fb;
  color: var(--book-muted);
  font-size: 12px;
  border-bottom: 1px solid var(--book-line);
}

.mobile-status-strip .connected,
.mobile-status-strip #stream-status.connected { color: var(--book-green); }

.sportsbook-phone-grid {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr) 300px;
  gap: 12px;
  align-items: start;
  background: var(--book-white);
  padding: 14px;
  border-radius: 0 0 24px 24px;
}

.book-lobby, .betting-board-card, .mobile-bet-slip {
  background: #ffffff;
  color: var(--book-ink);
  border: 1px solid var(--book-line);
  border-radius: 20px;
  padding: 12px;
  box-shadow: 0 12px 26px rgba(20, 52, 98, 0.08);
}

.book-pill-list { display: grid; gap: 10px; margin: 10px 0 12px; }
.book-pill {
  width: 100%;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 999px;
  background: var(--book-blue-dark);
  color: white;
  padding: 14px 17px;
  font-size: 19px;
  text-align: left;
}

.book-pill.featured { background: #21417f; }

.board-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
}

.board-toolbar h2 { color: var(--book-ink); }

.odds-board { display: grid; gap: 12px; }
.league-board { overflow: hidden; border-radius: 16px; border: 1px solid var(--book-line); background: #f7fbff; }
.league-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  background: var(--book-blue-deep);
  color: white;
  padding: 10px 14px;
  font-size: 18px;
}
.league-header span { color: rgba(255,255,255,.78); font-size: 13px; }

.odds-event-card { border-top: 4px solid var(--book-yellow); background: #f8fbff; }
.odds-event-card.is-live .event-date-row span { color: var(--book-green); }
.event-date-row {
  display: flex;
  justify-content: space-between;
  background: #4b86c8;
  color: white;
  padding: 7px 12px;
  font-size: 13px;
}
.event-matchup {
  background: #3268aa;
  color: white;
  padding: 10px 12px;
  text-align: center;
  font-size: 18px;
  font-weight: 700;
}
.board-column-head, .odds-board-row {
  display: grid;
  grid-template-columns: minmax(130px, 1.1fr) repeat(3, minmax(100px, 1fr));
}
.board-column-head {
  color: var(--book-muted);
  text-align: center;
  font-size: 12px;
  font-weight: 800;
  padding: 8px 0;
  background: #eef4fb;
}
.team-name {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--book-line);
  border-right: 1px solid var(--book-line);
  padding: 13px 12px;
  color: var(--book-ink);
  background: white;
}
.team-name span { color: var(--book-muted); font-weight: 800; }
.board-odd {
  min-height: 64px;
  display: grid;
  gap: 2px;
  place-items: center;
  border: 0;
  border-top: 1px solid var(--book-line);
  border-right: 1px solid var(--book-line);
  border-radius: 0;
  background: #fbfdff;
  color: var(--book-ink);
  padding: 8px;
}
.board-odd:hover:not(:disabled) { transform: none; background: #eaf4ff; }
.board-odd span { color: var(--book-muted); font-size: 11px; font-weight: 800; }
.board-odd em { min-height: 14px; color: var(--book-ink); font-style: normal; font-size: 15px; }
.board-odd strong { font-size: 17px; }
.board-odd-empty { opacity: .48; }
.draw-row { display: block; text-align: center; border-top: 1px solid var(--book-line); }
.draw-odd { width: 100%; border-right: 0; }

.mobile-bet-slip { position: sticky; top: 14px; }
.slip-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.slip-head h2 { color: var(--book-ink); }
.slip-head span { border-radius: 999px; padding: 5px 9px; background: #e9f1fb; color: var(--book-blue-dark); font-size: 12px; font-weight: 800; }
.mobile-bet-slip .empty-state,
.book-lobby .empty-state { color: var(--book-muted); border-color: var(--book-line); background: #f6f9fd; }
.mobile-bet-slip input { background: white; color: var(--book-ink); border-color: var(--book-line); }
.mobile-bet-slip .summary-line { background: #f7fbff; border-color: var(--book-line); color: var(--book-muted); }

.mobile-bottom-nav {
  display: none;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  background: #ffffff;
  border: 1px solid var(--book-line);
  border-radius: 24px;
  padding: 8px;
  margin-top: 12px;
}
.mobile-bottom-nav button {
  border: 0;
  background: transparent;
  color: var(--book-blue-dark);
  display: grid;
  gap: 3px;
  place-items: center;
  font-size: 22px;
}
.mobile-bottom-nav span { font-size: 12px; }
.mobile-bottom-nav button.active { color: #174080; background: #eef4fb; }

@media (max-width: 1020px) {
  .sportsbook-phone-grid { grid-template-columns: 1fr; }
  .book-lobby { order: 1; }
  .betting-board-card { order: 2; }
  .mobile-bet-slip { order: 3; position: static; }
  .mobile-bottom-nav { display: grid; position: sticky; bottom: 10px; z-index: 4; }
}

@media (max-width: 640px) {
  .mobile-betting-shell { margin-inline: -10px; }
  .mobile-book-header { grid-template-columns: auto 1fr auto; border-radius: 0; padding: 12px 10px; }
  .book-brand { min-width: 110px; gap: 6px; }
  .brand-gem { width: 34px; height: 34px; font-size: 20px; }
  .book-brand strong { font-size: 18px; }
  .book-brand small { font-size: 7px; letter-spacing: .28em; }
  .profile-circle { width: 42px; height: 42px; }
  .bet-mode-tabs { padding-inline: 0; }
  .bet-mode { font-size: 15px; }
  .sportsbook-phone-grid { border-radius: 0; padding: 8px; }
  .book-lobby, .betting-board-card, .mobile-bet-slip { border-radius: 14px; padding: 8px; }
  .board-toolbar { flex-direction: column; }
  .board-column-head, .odds-board-row { grid-template-columns: minmax(86px, .9fr) repeat(3, minmax(70px, 1fr)); }
  .event-matchup { font-size: 16px; }
  .team-name { padding: 10px 8px; font-size: 13px; }
  .board-odd { min-height: 58px; padding: 5px 3px; }
  .board-odd strong { font-size: 14px; }
  .board-odd em { font-size: 12px; }
  .board-odd span { font-size: 9px; }
}

/* Sprint 18: betting board polish + provider mapping prep */
.odds-format-toggle {
  display: inline-flex;
  gap: 4px;
  border: 1px solid #cbd7e6;
  border-radius: 999px;
  padding: 3px;
  background: #ffffff;
}
.odds-format-toggle button {
  border: 0;
  border-radius: 999px;
  padding: 5px 8px;
  color: var(--book-blue-dark);
  background: transparent;
  font-size: 11px;
  font-weight: 800;
}
.odds-format-toggle button.active { background: #dfeaf8; }
.book-pill.active { outline: 3px solid rgba(255, 210, 30, .85); background: #173a79; }
.favorite-toggle {
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.35);
  background: rgba(255,255,255,.12);
  color: white;
  margin-right: 8px;
  vertical-align: middle;
}
.favorite-toggle.active { color: var(--book-yellow); background: rgba(255, 210, 30, .18); }
.event-matchup { display: flex; align-items: center; justify-content: center; gap: 3px; }
.mobile-status-strip { flex-wrap: wrap; }
@media (max-width: 640px) {
  .odds-format-toggle { width: 100%; justify-content: center; }
  .odds-format-toggle button { flex: 1; }
}


/* Sprint 19: production polish for bet slip drawer + confirmation UX */
.board-odd.selected {
  outline: 3px solid rgba(255, 210, 30, .95);
  background: linear-gradient(180deg, #fff8d7, #ffffff);
  box-shadow: 0 0 0 1px rgba(19, 63, 128, .24), 0 12px 22px rgba(12, 36, 73, .18);
}
.bet-slip-fab {
  display: none;
  position: sticky;
  bottom: 76px;
  left: 100%;
  z-index: 6;
  width: max-content;
  margin-left: auto;
  border-radius: 999px;
  box-shadow: 0 16px 32px rgba(12, 36, 73, .25);
  background: #ffd21e;
  color: #082c63;
}
.bet-slip-fab span {
  display: inline-grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  margin-left: 6px;
  border-radius: 999px;
  background: #113b7c;
  color: white;
}
.odds-warning {
  display: grid;
  gap: 5px;
  padding: 10px;
  border-radius: 14px;
  border: 1px solid rgba(201, 129, 0, .28);
  background: #fff5cf;
  color: #744800;
  font-size: 12px;
}
.odds-warning.strong { margin: 8px 0; font-weight: 800; }
.odds-warning button { width: fit-content; padding: 7px 10px; }
.slip-item.odds-changed {
  border-color: rgba(201, 129, 0, .36);
  background: #fffaf0;
}
.slip-item small { display: block; color: #a15c00; margin-top: 4px; }
.modal-backdrop {
  position: fixed;
  inset: 0;
  display: none;
  place-items: center;
  z-index: 30;
  padding: 18px;
  background: rgba(4, 18, 42, .62);
  backdrop-filter: blur(8px);
}
.modal-backdrop.active { display: grid; }
.confirm-modal {
  width: min(520px, 100%);
  border-radius: 24px;
  padding: 18px;
  background: #ffffff;
  color: #082c63;
  box-shadow: 0 26px 70px rgba(0, 0, 0, .36);
}
.confirm-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.confirm-header h2 { margin: 0; }
.confirm-details { display: grid; gap: 10px; margin: 14px 0; }
.confirm-summary-card, .confirm-line {
  display: grid;
  gap: 3px;
  padding: 12px;
  border: 1px solid #d7e1ec;
  border-radius: 16px;
  background: #f7fbff;
}
.confirm-line { grid-template-columns: 1fr auto; align-items: center; }
.confirm-line small { grid-column: 1 / -1; color: #627086; }
.confirm-warning { font-size: 12px; color: #627086; }
.confirm-actions { justify-content: flex-end; margin-top: 14px; }
@media (max-width: 1020px) {
  .bet-slip-fab { display: inline-flex; align-items: center; }
  .mobile-bet-slip {
    position: fixed !important;
    left: 10px;
    right: 10px;
    bottom: 82px;
    z-index: 20;
    max-height: 74vh;
    overflow: auto;
    transform: translateY(calc(100% + 120px));
    opacity: 0;
    pointer-events: none;
    transition: transform .22s ease, opacity .22s ease;
    border: 2px solid #ffd21e;
    box-shadow: 0 24px 60px rgba(5, 22, 54, .35);
  }
  .mobile-bet-slip.drawer-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  body.bet-slip-open .mobile-bottom-nav { opacity: .92; }
}

/* Sprint 20: ticket history and user demo journey polish */
.ticket-history-panel {
  margin-top: 18px;
  padding: 14px;
  border: 1px solid var(--book-line);
  border-radius: 20px;
  background: rgba(255,255,255,0.78);
  box-shadow: 0 14px 30px rgba(15, 49, 91, 0.08);
}
.ticket-history-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.ticket-history-head h2 { margin: 0; color: var(--book-ink); }
.ticket-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 12px 0;
}
.ticket-summary-grid .metric-card {
  background: linear-gradient(180deg, #ffffff, #edf5ff);
  border-color: #c9d9ea;
  color: var(--book-ink);
}
.ticket-summary-grid .metric-card span,
.ticket-summary-grid .metric-card small { color: var(--book-muted); }
.ticket-summary-grid .metric-card strong { color: var(--book-blue-deep); }
.ticket-history-list {
  display: grid;
  gap: 12px;
}
.ticket-card {
  border: 1px solid #cddbea;
  border-radius: 18px;
  background: #fff;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(21, 54, 92, 0.08);
}
.ticket-card-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border-bottom: 1px solid #e3ecf7;
}
.ticket-status-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  font-weight: 900;
  background: #e8f2ff;
  color: var(--book-blue-deep);
}
.ticket-card-head strong { color: var(--book-ink); }
.ticket-card-head span,
.ticket-card-head small,
.ticket-line small,
.ticket-ledger-links span { color: var(--book-muted); }
.ticket-meta { text-align: right; display: grid; gap: 2px; }
.ticket-lines { display: grid; gap: 8px; padding: 12px; }
.ticket-line {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2px 10px;
  padding: 10px;
  border-radius: 14px;
  background: #f3f7fc;
}
.ticket-line small { grid-column: 1 / -1; }
.ticket-financials,
.ticket-ledger-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0 12px 12px;
}
.ticket-financials span {
  padding: 8px 10px;
  border-radius: 12px;
  background: #edf5ff;
  color: var(--book-muted);
}
.ticket-financials strong { color: var(--book-ink); }
.ticket-ledger-links button,
.ticket-ledger-links span {
  font-size: 12px;
}
.ticket-card.status-won .ticket-status-mark { background: rgba(25,169,116,0.16); color: #0f8f5d; }
.ticket-card.status-lost .ticket-status-mark { background: rgba(239,68,68,0.12); color: #cb2a2a; }
.ticket-card.status-void .ticket-status-mark { background: rgba(255,210,30,0.23); color: #946f00; }
.ticket-card.status-rejected .ticket-status-mark { background: rgba(255,125,64,0.16); color: #b9551d; }
.ticket-card.status-open .ticket-status-mark { background: rgba(47,128,207,0.16); color: var(--book-blue-deep); }

@media (max-width: 760px) {
  .ticket-history-head { align-items: stretch; flex-direction: column; }
  .ticket-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ticket-card-head { grid-template-columns: auto 1fr; }
  .ticket-meta { grid-column: 1 / -1; text-align: left; }
}

.language-lock {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary, #f7fafc);
  font-weight: 800;
  letter-spacing: 0.04em;
}

/* Sprint 23: unified role-aware login portal */
body[data-shell="login"] {
  background: #05080c;
}

.login-portal {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px 18px;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(rgba(3, 7, 11, 0.48), rgba(3, 7, 11, 0.88)),
    radial-gradient(ellipse at 50% 74%, rgba(255, 255, 255, 0.09) 0 6%, transparent 7%),
    radial-gradient(ellipse at 50% 66%, rgba(255, 255, 255, 0.12) 0 1%, transparent 2%),
    radial-gradient(ellipse at 50% 70%, rgba(255, 255, 255, 0.08) 0 28%, transparent 29%),
    linear-gradient(180deg, #1a2732 0%, #111921 44%, #05070a 100%);
}

.login-portal::before {
  content: "";
  position: absolute;
  inset: auto -12% -16% -12%;
  height: 52vh;
  background:
    repeating-radial-gradient(ellipse at center bottom, rgba(255,255,255,0.08) 0 1px, transparent 1px 12px),
    radial-gradient(ellipse at center bottom, rgba(255,255,255,0.1), transparent 58%);
  opacity: 0.55;
  filter: grayscale(1);
}

.login-portal::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, transparent 0 6%, rgba(255,255,255,0.06) 6.2% 6.5%, transparent 6.7% 93%, rgba(255,255,255,0.06) 93.2% 93.5%, transparent 93.7%),
    radial-gradient(circle at 18% 38%, rgba(255,255,255,0.18), transparent 2px),
    radial-gradient(circle at 82% 38%, rgba(255,255,255,0.18), transparent 2px);
  pointer-events: none;
}

.stadium-login-card {
  position: relative;
  z-index: 1;
  width: min(620px, 100%);
  display: grid;
  justify-items: center;
  gap: 28px;
  margin-top: -5vh;
}

.apex-login-brand,
.apex-mini-brand,
.dashboard-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: white;
}

.apex-login-brand strong,
.apex-mini-brand strong,
.dashboard-brand strong {
  display: block;
  color: #ffd21e;
  font-size: clamp(40px, 8vw, 72px);
  letter-spacing: 0.12em;
  line-height: 0.86;
  text-shadow: 0 8px 24px rgba(0,0,0,0.45);
}

.apex-login-brand small,
.apex-mini-brand small,
.dashboard-brand small {
  display: block;
  margin-top: 10px;
  color: rgba(255, 255, 255, 0.88);
  font-weight: 800;
  letter-spacing: 0.56em;
  font-size: clamp(10px, 1.8vw, 18px);
  text-shadow: 0 8px 24px rgba(0,0,0,0.45);
}

.login-gem {
  display: grid;
  place-items: center;
  width: clamp(54px, 9vw, 86px);
  height: clamp(54px, 9vw, 86px);
  color: #fff;
  font-size: clamp(42px, 7vw, 72px);
  text-shadow: 0 8px 24px rgba(0,0,0,0.45);
}

.portal-login-form {
  width: min(520px, 100%);
  display: grid;
  gap: 16px;
}

.portal-welcome {
  border: 1px solid rgba(255,255,255,0.28);
  border-radius: 14px;
  padding: 22px 18px;
  color: #158cff;
  background: rgba(0, 0, 0, 0.44);
  text-align: center;
  font-weight: 800;
  box-shadow: 0 18px 36px rgba(0,0,0,0.24);
}

.portal-login-form label {
  color: #ffffff;
  font-weight: 800;
  font-size: 16px;
}

.portal-login-form input {
  height: 54px;
  border: 2px solid rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.10);
  border-radius: 8px;
  color: white;
  font-weight: 700;
}

.portal-login-form input:focus {
  outline: none;
  border-color: #1e8cff;
  box-shadow: 0 0 0 4px rgba(30, 140, 255, 0.22);
}

.portal-login-form button[type="submit"] {
  height: 58px;
  border: 0;
  border-radius: 8px;
  background: #128cff;
  color: white;
  font-size: 18px;
  font-weight: 900;
  box-shadow: 0 18px 34px rgba(0,0,0,0.28);
}

.portal-login-note {
  margin: 56px auto 0;
  max-width: 380px;
  text-align: center;
  color: rgba(255,255,255,0.76);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.5;
}

.dashboard-shell[hidden],
.login-portal[hidden],
.password-gate[hidden] { display: none !important; }

.password-gate {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at top, rgba(18, 140, 255, 0.18), transparent 30rem),
    #070a10;
}

.password-gate-card {
  width: min(520px, 100%);
}

.apex-mini-brand {
  justify-content: flex-start;
  margin-bottom: 20px;
}
.apex-mini-brand .login-gem { width: 40px; height: 40px; font-size: 36px; }
.apex-mini-brand strong { font-size: 26px; }
.apex-mini-brand small { font-size: 8px; letter-spacing: 0.4em; margin-top: 4px; }

.dashboard-header {
  display: grid;
  grid-template-columns: auto minmax(220px, 1fr) auto;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 14px 16px;
  background: rgba(17, 24, 39, 0.92);
  box-shadow: 0 18px 48px rgba(0,0,0,0.18);
}

.dashboard-brand { justify-content: flex-start; }
.dashboard-brand .brand-gem { width: 38px; height: 38px; font-size: 28px; border-radius: 10px; }
.dashboard-brand strong { font-size: 24px; }
.dashboard-brand small { font-size: 8px; letter-spacing: 0.42em; margin-top: 4px; }
.dashboard-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; }

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

body[data-shell="dashboard"] .role-view:not(.active) { display: none !important; }
body[data-shell="login"] .output-panel,
body[data-shell="password"] .output-panel { display: none; }

@media (max-width: 760px) {
  .stadium-login-card { margin-top: -2vh; gap: 22px; }
  .apex-login-brand { transform: scale(0.88); }
  .portal-login-note { margin-top: 32px; font-size: 14px; }
  .dashboard-header { grid-template-columns: 1fr; }
  .dashboard-actions { justify-content: flex-start; }
}
body[data-shell="login"] .dashboard-shell,
body[data-shell="login"] .password-gate,
body[data-shell="password"] .login-portal,
body[data-shell="password"] .dashboard-shell,
body[data-shell="dashboard"] .login-portal,
body[data-shell="dashboard"] .password-gate {
  display: none !important;
}

/* Sprint 24: client demo freeze polish */
.client-demo-ready {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(25, 169, 116, 0.32);
  border-radius: 999px;
  background: rgba(25, 169, 116, 0.10);
  color: #0f7f58;
  font-weight: 800;
  font-size: 12px;
  padding: 7px 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
body[data-role="user"] .output-panel { display: none; }
body[data-role="user"] .mobile-betting-shell { padding-bottom: 88px; }
body[data-role="user"] .dashboard-header { display: none; }

/* Sprint 25: user-visible logout for sportsbook role */
.book-user-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}
.book-logout {
  height: 44px;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 999px;
  background: rgba(255, 255, 255, .14);
  color: #ffffff;
  padding: 0 13px;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .02em;
  box-shadow: none;
}
.book-logout:hover:not(:disabled) {
  background: rgba(255, 210, 30, .22);
  border-color: rgba(255, 210, 30, .75);
  transform: translateY(-1px);
}
@media (max-width: 640px) {
  .book-logout { width: 44px; padding: 0; overflow: hidden; color: transparent; position: relative; }
  .book-logout::after { content: "↪"; color: #ffffff; position: absolute; inset: 0; display: grid; place-items: center; font-size: 18px; }
}

/* Sprint 27.1: User Layout Cleanup */
body[data-role="user"] {
  background:
    radial-gradient(circle at top left, rgba(47,128,207,0.12), transparent 28rem),
    linear-gradient(180deg, #071429 0%, #0c1728 46%, #07101f 100%);
}

body[data-role="user"] .app-shell {
  max-width: 1120px;
  padding-inline: 14px;
}

.mobile-betting-shell {
  --book-navy: #102c62;
  --book-panel-shadow: 0 18px 44px rgba(7, 24, 56, 0.18);
  border-radius: 26px;
  background: linear-gradient(180deg, #f3f8fe 0%, #eaf1fa 100%);
  box-shadow: 0 30px 80px rgba(2, 8, 23, 0.34);
  overflow: hidden;
}

.mobile-book-header.user-layout-v27 {
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "brand actions"
    "search search";
  gap: 12px;
  border-radius: 0;
  padding: 16px;
  background:
    radial-gradient(circle at 18% 0%, rgba(255,255,255,.22), transparent 18rem),
    linear-gradient(135deg, #1b4f9b 0%, #2f80cf 56%, #17407d 100%);
}
.mobile-book-header.user-layout-v27 .book-brand { grid-area: brand; }
.mobile-book-header.user-layout-v27 .book-user-actions { grid-area: actions; }
.mobile-book-header.user-layout-v27 .book-search { grid-area: search; }

.mobile-book-header.user-layout-v27 .book-search {
  background: rgba(255,255,255,0.92);
  box-shadow: inset 0 0 0 1px rgba(19, 55, 105, .08);
}
.mobile-book-header.user-layout-v27 .book-search input {
  font-size: 15px;
  font-weight: 700;
}
.mobile-book-header.user-layout-v27 .book-search span { color: #1b4f9b; }

.player-home-summary {
  display: grid;
  grid-template-columns: 1.2fr .85fr .85fr;
  gap: 10px;
  padding: 12px 14px;
  background: #f3f8fe;
  border-bottom: 1px solid var(--book-line);
}
.player-summary-card {
  display: grid;
  gap: 4px;
  min-height: 68px;
  align-content: center;
  border: 1px solid #d5e3f2;
  border-radius: 18px;
  background: #ffffff;
  color: var(--book-ink);
  padding: 12px;
  box-shadow: 0 8px 20px rgba(20, 52, 98, .06);
  text-align: left;
}
.player-summary-card span {
  color: var(--book-muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.player-summary-card strong {
  color: var(--book-navy);
  font-size: 18px;
  line-height: 1;
}
.player-summary-card.primary {
  background: linear-gradient(135deg, #fff 0%, #eff6ff 100%);
}
.player-summary-card.action {
  border-color: rgba(255, 210, 30, .72);
  background: linear-gradient(135deg, #fffaf0 0%, #fff4bf 100%);
}
.player-summary-card.action:hover { transform: translateY(-1px); }

.mobile-status-strip {
  align-items: center;
  padding: 10px 14px;
  background: #e7f0fa;
}
.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  border: 1px solid #ccdced;
  border-radius: 999px;
  background: #ffffff;
  color: #49617f;
  padding: 5px 9px;
  font-weight: 800;
}
.status-chip#stream-status::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #9aa7b8;
}
.status-chip#stream-status.connected::before { background: var(--book-green); }
.market-note { flex: 1; justify-content: center; }

.book-lobby, .betting-board-card, .mobile-bet-slip {
  box-shadow: var(--book-panel-shadow);
}
.lobby-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.lobby-head h2 {
  color: var(--book-ink);
  font-size: 20px;
  letter-spacing: -.02em;
}
.lobby-live-dot {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  background: rgba(25, 169, 116, .12);
  color: #0f7f58;
  font-size: 12px;
  font-weight: 900;
  padding: 7px 9px;
}
.lobby-live-dot::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #19a974;
}
.lobby-filter-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
}
.lobby-filter-grid .book-pill {
  border-radius: 17px;
  padding: 14px 15px;
}
.lobby-filter-grid .book-pill span { font-size: 18px; }
.lobby-filter-grid .book-pill strong { font-size: 16px; }
.book-pill-list .book-pill {
  background: #f6f9fe;
  color: var(--book-ink);
  border: 1px solid #d6e3f2;
  box-shadow: none;
}
.book-pill-list .book-pill.active {
  color: white;
  border-color: transparent;
  background: #173a79;
}
.lobby-actions {
  display: grid;
  gap: 8px;
}
.board-subtitle {
  display: block;
  margin-top: 4px;
  color: var(--book-muted);
  font-size: 13px;
  font-weight: 700;
}
.client-demo-ready {
  white-space: nowrap;
}

@media (min-width: 1021px) {
  .book-lobby { position: sticky; top: 14px; }
}

@media (max-width: 1020px) {
  .sportsbook-phone-grid {
    gap: 10px;
  }
  .book-lobby {
    display: grid;
    gap: 10px;
  }
  .lobby-filter-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .book-pill-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .lobby-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  body[data-role="user"] .app-shell { padding: 0; }
  .mobile-betting-shell { border-radius: 0; box-shadow: none; }
  .mobile-book-header.user-layout-v27 {
    padding: 12px 10px 10px;
  }
  .player-home-summary {
    grid-template-columns: 1fr 1fr;
    padding: 10px;
  }
  .player-summary-card.primary { grid-column: span 2; }
  .player-summary-card {
    min-height: 62px;
    border-radius: 15px;
    padding: 11px;
  }
  .player-summary-card strong { font-size: 16px; }
  .mobile-status-strip {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 9px 10px;
  }
  .status-chip {
    justify-content: center;
    font-size: 11px;
  }
  .market-note { grid-column: span 2; }
  .lobby-filter-grid {
    grid-template-columns: 1fr;
  }
  .book-pill-list {
    grid-template-columns: 1fr;
  }
  .lobby-actions {
    grid-template-columns: 1fr;
  }
  .client-demo-ready {
    align-self: flex-start;
  }
}

/* Sprint 27.2: Betting Board + Odds Grid Polish */
.league-board.board-polish-v27-2 {
  border-radius: 20px;
  background: #ffffff;
  border: 1px solid #cdddec;
  box-shadow: 0 16px 36px rgba(12, 36, 73, .10);
}
.league-header-v2 {
  align-items: center;
  padding: 13px 14px;
  background: linear-gradient(135deg, #102c62 0%, #1f5aa3 100%);
}
.league-title-block {
  display: grid;
  gap: 4px;
}
.league-title-block strong {
  font-size: 18px;
  letter-spacing: -.01em;
}
.league-title-block small {
  color: rgba(255,255,255,.76);
  font-size: 12px;
  font-weight: 800;
}
.league-sport-chip {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  background: rgba(255,255,255,.14);
  color: #fff6bf;
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.league-stat-block {
  display: grid;
  gap: 6px;
  justify-items: end;
}
.league-stat-block span {
  border-radius: 999px;
  background: rgba(255,255,255,.12);
  color: rgba(255,255,255,.9);
  padding: 5px 8px;
  font-size: 11px;
  font-weight: 900;
}
.odds-event-card-v2 {
  border-top: 0;
  background: #fbfdff;
}
.odds-event-card-v2 + .odds-event-card-v2 {
  border-top: 8px solid #edf4fb;
}
.event-date-row-v2 {
  background: #eaf2fb;
  color: #183a6d;
  align-items: center;
  font-weight: 900;
}
.event-date-row-v2 span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.event-status-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #ffffff;
  border: 1px solid #cfdeee;
  color: #49617f;
  padding: 4px 8px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.event-status-pill.status-live {
  color: #0f7f58;
  border-color: rgba(25,169,116,.35);
  background: rgba(25,169,116,.10);
}
.event-status-pill.status-suspended,
.event-status-pill.status-cancelled {
  color: #9b1c1c;
  border-color: rgba(185, 28, 28, .26);
  background: rgba(185, 28, 28, .08);
}
.event-matchup-v2 {
  justify-content: flex-start;
  text-align: left;
  padding: 12px;
  background: linear-gradient(135deg, #2460a7 0%, #347dc8 100%);
}
.event-matchup-v2 .favorite-toggle {
  flex: 0 0 auto;
  margin-right: 6px;
}
.matchup-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.matchup-copy strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 17px;
}
.matchup-copy small {
  color: rgba(255,255,255,.78);
  font-size: 12px;
  font-weight: 800;
}
.odds-grid-head {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f1f6fc;
  border-bottom: 1px solid #d5e3f2;
}
.odds-grid-head span {
  padding: 1px 4px;
}
.odds-board-row {
  min-height: 66px;
}
.team-row.side-home .team-name,
.team-row.side-away .team-name,
.draw-row-v2 .team-name {
  display: grid;
  justify-content: initial;
  align-content: center;
  gap: 2px;
}
.team-name span {
  font-size: 10px;
  color: #7890ab;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.team-name strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14px;
}
.draw-row-v2 {
  display: grid;
  grid-template-columns: minmax(130px, 1.1fr) repeat(3, minmax(100px, 1fr));
}
.draw-row-v2 .draw-name strong { color: #163c78; }
.board-odd {
  transition: background .15s ease, box-shadow .15s ease, transform .15s ease;
}
.board-odd:hover:not(:disabled):not(.board-odd-empty) {
  transform: translateY(-1px);
  background: #eaf4ff;
  box-shadow: inset 0 -3px 0 rgba(255, 210, 30, .88);
}
.board-odd.market-moneyline strong { color: #0d3b78; }
.board-odd.market-spread strong,
.board-odd.market-total strong { color: #153b69; }
.board-odd.draw-odd strong { color: #1d4f95; }
.board-odd small {
  color: #9b1c1c;
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}
.board-odd.is-disabled {
  cursor: not-allowed;
  background: #f4f6f8;
  color: #8392a6;
}
.board-odd.is-disabled span,
.board-odd.is-disabled em,
.board-odd.is-disabled strong {
  color: #8392a6;
}
.board-odd-empty {
  cursor: default;
  background: #f7f9fc;
}
.board-odd.selected::after {
  content: "Selected";
  display: inline-flex;
  border-radius: 999px;
  background: #113b7c;
  color: #ffffff;
  padding: 2px 6px;
  font-size: 9px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.board-empty-state {
  display: grid;
  gap: 5px;
  color: #49617f;
  background: #f6f9fd;
  border: 1px dashed #cbd9ea;
}
.board-empty-state strong { color: #183a6d; }
.board-empty-state span { font-size: 13px; }
.book-pill-list .book-pill {
  display: grid;
  grid-template-columns: auto 1fr auto;
}
.book-pill-list .book-pill small {
  color: inherit;
  opacity: .72;
  font-size: 11px;
  font-weight: 900;
}

@media (max-width: 640px) {
  .league-header-v2 {
    align-items: flex-start;
    flex-direction: column;
  }
  .league-stat-block {
    width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    justify-items: stretch;
  }
  .league-stat-block span { text-align: center; }
  .event-date-row-v2 {
    padding: 8px 9px;
    font-size: 11px;
  }
  .event-status-pill { font-size: 9px; padding: 3px 6px; }
  .event-matchup-v2 { padding: 10px 9px; }
  .matchup-copy strong { font-size: 15px; }
  .matchup-copy small { font-size: 11px; }
  .draw-row-v2,
  .board-column-head,
  .odds-board-row {
    grid-template-columns: minmax(82px, .9fr) repeat(3, minmax(64px, 1fr));
  }
  .team-name strong { font-size: 12px; white-space: normal; line-height: 1.15; }
  .team-name span { font-size: 8px; }
  .board-odd { min-height: 62px; }
  .board-odd span { font-size: 8px; }
  .board-odd strong { font-size: 13px; }
  .board-odd small { font-size: 8px; }
  .board-odd.selected::after { font-size: 7px; padding: 1px 4px; }
}


/* Sprint 27.2: Betting Board + Odds Grid polish */
.board-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 10px;
}
.board-stats span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  border: 1px solid #d6e3f1;
  border-radius: 999px;
  background: linear-gradient(180deg, #ffffff, #eef6ff);
  color: #234d86;
  font-size: 12px;
  font-weight: 900;
}
.market-legend {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}
.market-legend span {
  display: inline-flex;
  justify-content: center;
  border: 1px solid #cbdced;
  border-radius: 12px;
  background: #f4f9ff;
  color: #536b89;
  padding: 8px 6px;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.league-header {
  align-items: center;
}
.league-header div {
  display: grid;
  gap: 3px;
}
.league-header strong {
  line-height: 1.1;
}
.league-header small {
  align-self: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, .15);
  color: rgba(255,255,255,.88);
  padding: 6px 9px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}
.odds-event-card {
  border-radius: 0;
  overflow: hidden;
}
.odds-event-card + .odds-event-card {
  border-top: 1px solid #c8d8eb;
}
.event-date-row {
  align-items: center;
  font-weight: 800;
}
.event-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  background: rgba(255,255,255,.18);
  padding: 5px 9px;
  color: #ffffff;
  font-size: 11px;
  letter-spacing: .03em;
  text-transform: uppercase;
}
.event-status-badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #ffffff;
}
.event-status-badge.status-live::before { background: #28e69b; box-shadow: 0 0 0 4px rgba(40,230,155,.14); }
.event-status-badge.status-suspended::before { background: #ffd21e; }
.event-status-badge.status-finished::before,
.event-status-badge.status-settled::before { background: #a9b7c8; }
.event-matchup {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
  text-align: left;
}
.matchup-main {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 0;
}
.matchup-main strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.matchup-main span {
  opacity: .72;
  font-size: 12px;
  font-weight: 900;
}
.matchup-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}
.matchup-tags span {
  border-radius: 999px;
  background: rgba(255,255,255,.14);
  color: rgba(255,255,255,.92);
  padding: 5px 8px;
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
}
.board-column-head {
  position: sticky;
  top: 0;
  z-index: 1;
  border-bottom: 1px solid #d9e5f1;
}
.board-column-head span {
  padding-inline: 4px;
}
.team-name {
  min-width: 0;
}
.team-name strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.team-name span {
  flex: 0 0 auto;
  margin-left: 8px;
}
.draw-team {
  background: #f8fbff;
}
.board-odd {
  position: relative;
  min-width: 0;
  isolation: isolate;
}
.board-odd[data-market-kind="moneyline"] .odd-price,
.board-odd[data-market-kind="draw"] .odd-price {
  color: #103f83;
}
.board-odd[data-market-kind="spread"] .odd-line,
.board-odd[data-market-kind="total"] .odd-line {
  color: #102c62;
  font-weight: 900;
}
.board-odd .odd-state {
  display: inline-flex;
  min-height: 18px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(47,128,207,.09);
  color: #42658c;
  padding: 2px 6px;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .04em;
}
.board-odd:not(:disabled):active {
  transform: scale(.98);
}
.board-odd.is-suspended,
.odds-event-card.status-suspended .board-odd {
  background: repeating-linear-gradient(135deg, #f7f9fc 0 7px, #eef3f9 7px 14px);
  color: #7a899b;
}
.board-odd.is-suspended .odd-state,
.odds-event-card.status-suspended .board-odd .odd-state {
  background: rgba(255,210,30,.28);
  color: #8a6500;
}
.draw-row-grid .board-odd-empty {
  background: #f3f7fc;
}
.odds-board[data-board-mode="parlay"] .board-odd.selected::after {
  content: "PARLAY";
  position: absolute;
  top: 5px;
  right: 5px;
  border-radius: 999px;
  background: #102c62;
  color: #ffd21e;
  padding: 2px 5px;
  font-size: 8px;
  font-weight: 900;
}
.odds-board[data-board-mode="live"] .odds-event-card:not(.is-live) {
  display: none;
}
.betting-board-card {
  overflow: hidden;
}
@media (max-width: 720px) {
  .board-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .market-legend { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .event-matchup { grid-template-columns: auto 1fr; }
  .matchup-tags { grid-column: 1 / -1; justify-content: center; }
  .matchup-main { justify-content: flex-start; }
}
@media (max-width: 460px) {
  .board-column-head, .odds-board-row {
    grid-template-columns: minmax(76px, .85fr) repeat(3, minmax(64px, 1fr));
  }
  .team-name { padding: 8px 6px; }
  .team-name span { display: none; }
  .board-odd { min-height: 62px; }
  .board-odd .odd-state { display: none; }
}

/* Sprint 27.2: Betting Board + Odds Grid polish */
.board-summary-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}
.board-summary-strip span {
  display: grid;
  gap: 2px;
  min-height: 54px;
  align-content: center;
  border: 1px solid #d2dfef;
  border-radius: 15px;
  background: linear-gradient(180deg, #ffffff, #f1f7ff);
  color: var(--book-muted);
  text-align: center;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.board-summary-strip strong {
  color: var(--book-navy);
  font-size: 18px;
  line-height: 1;
}
.league-header {
  align-items: center;
  border-radius: 18px 18px 0 0;
}
.league-header div {
  display: grid;
  gap: 3px;
}
.league-header small {
  color: rgba(255,255,255,.7);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.odds-event-card {
  border: 1px solid #d0dceb;
  border-top: 0;
  border-radius: 0 0 18px 18px;
  margin-bottom: 14px;
  overflow: hidden;
  box-shadow: 0 12px 26px rgba(22, 58, 104, .08);
}
.odds-event-card + .odds-event-card {
  border-radius: 18px;
  border-top: 1px solid #d0dceb;
}
.event-date-row {
  align-items: center;
  background: linear-gradient(90deg, #3979bd, #2c68aa);
}
.event-time {
  display: flex;
  align-items: baseline;
  gap: 9px;
}
.event-time strong { font-size: 13px; }
.event-time small { color: rgba(255,255,255,.78); font-weight: 800; }
.event-status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 78px;
  border-radius: 999px;
  padding: 5px 8px;
  background: rgba(255,255,255,.16);
  color: #ffffff;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .06em;
}
.event-status-pill.status-live {
  background: rgba(25, 169, 116, .92);
  box-shadow: 0 0 0 3px rgba(25, 169, 116, .18);
}
.event-status-pill.status-scheduled { background: rgba(255,255,255,.2); }
.event-status-pill.status-suspended { background: rgba(255, 100, 124, .88); }
.event-matchup {
  justify-content: flex-start;
  text-align: left;
  padding: 12px;
  gap: 9px;
}
.event-matchup > div {
  display: grid;
  gap: 3px;
}
.event-matchup strong { line-height: 1.15; }
.event-matchup small {
  color: rgba(255,255,255,.72);
  font-size: 12px;
  font-weight: 800;
}
.board-column-head {
  grid-template-columns: minmax(130px, 1.1fr) repeat(3, minmax(100px, 1fr));
  border-bottom: 1px solid #dce6f2;
  padding: 0;
}
.board-column-head span {
  padding: 9px 6px;
  border-right: 1px solid #dce6f2;
}
.board-column-head span:first-child { text-align: left; padding-left: 12px; }
.team-name {
  min-height: 68px;
  gap: 8px;
}
.team-name div {
  display: grid;
  gap: 4px;
}
.team-name strong {
  line-height: 1.12;
}
.team-name b {
  display: grid;
  place-items: center;
  min-width: 30px;
  height: 30px;
  border-radius: 999px;
  background: #eef4fb;
  color: #336aa9;
  font-size: 11px;
}
.team-name.draw-label b { background: #fff2b5; color: #8b6800; }
.board-odd {
  position: relative;
  min-height: 68px;
  grid-template-rows: auto auto auto;
  overflow: hidden;
}
.board-odd::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background: linear-gradient(135deg, rgba(47,128,207,.12), transparent 52%);
}
.board-odd:hover:not(:disabled)::after,
.board-odd.selected::after { opacity: 1; }
.board-odd.market-moneyline .odd-label { color: #1c5f9d; }
.board-odd.market-spread .odd-label { color: #7d4f00; }
.board-odd.market-total .odd-label { color: #0f7f58; }
.odd-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.odd-line {
  min-height: 16px;
  font-weight: 900;
}
.odd-price {
  color: #0b3d7a;
  font-size: 18px;
}
.odd-state {
  position: absolute;
  right: 5px;
  bottom: 4px;
  border-radius: 999px;
  padding: 2px 6px;
  background: rgba(255, 100, 124, .12);
  color: #b72740;
  font-size: 9px;
  font-weight: 900;
}
.board-odd:disabled {
  background: #eef2f7;
  color: #8392a8;
  opacity: .82;
}
.board-odd:disabled .odd-price { color: #8392a8; }
.draw-row {
  display: grid;
  grid-template-columns: minmax(130px, 1.1fr) repeat(3, minmax(100px, 1fr));
  text-align: initial;
}
.draw-row .draw-odd { width: auto; }
.betting-board-empty {
  background: #ffffff;
  color: var(--book-muted);
  border-color: #d2dfef;
}

@media (max-width: 640px) {
  .board-summary-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .event-time {
    display: grid;
    gap: 1px;
  }
  .event-status-pill {
    min-width: 66px;
    font-size: 10px;
  }
  .event-matchup {
    padding: 10px 8px;
    font-size: 15px;
  }
  .event-matchup small {
    font-size: 11px;
  }
  .board-column-head,
  .odds-board-row,
  .draw-row {
    grid-template-columns: minmax(86px, .92fr) repeat(3, minmax(70px, 1fr));
  }
  .team-name {
    min-height: 60px;
    gap: 5px;
  }
  .team-name b {
    min-width: 24px;
    height: 24px;
    font-size: 10px;
  }
  .board-odd {
    min-height: 60px;
  }
  .odd-label { font-size: 8px; }
  .odd-line { font-size: 11px; }
  .odd-price { font-size: 14px; }
}

/* Sprint 27.3: Bet Slip + My Bets UX Polish */
.bet-slip-v27-3 {
  display: grid;
  gap: 12px;
}
.slip-head-v27-3 {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid #d7e3f0;
}
.slip-head-v27-3 h2 { margin: 0; }
.slip-head-v27-3 small {
  display: block;
  color: var(--book-muted);
  font-size: 12px;
  font-weight: 800;
  margin-top: 2px;
}
.slip-head-actions {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.close-slip {
  display: none;
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 999px;
  font-size: 20px;
  line-height: 1;
}
.quick-stake-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 7px;
}
.quick-stake-row button {
  min-height: 36px;
  padding: 0 6px;
  border-radius: 12px;
  border: 1px solid #cbdced;
  background: #f4f9ff;
  color: #103f83;
  font-size: 12px;
  font-weight: 900;
}
.stake-field-v27-3 {
  display: grid;
  gap: 6px;
}
.slip-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.slip-summary-grid span {
  display: grid;
  gap: 2px;
  min-height: 58px;
  align-content: center;
  border: 1px solid #d2dfef;
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff, #f2f8ff);
  padding: 9px;
}
.slip-summary-grid small {
  color: var(--book-muted);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.slip-summary-grid strong {
  color: var(--book-navy);
  font-size: 16px;
}
.slip-validation {
  display: grid;
  gap: 6px;
  font-size: 12px;
  font-weight: 900;
}
.slip-validation span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  border-radius: 12px;
  padding: 7px 9px;
  background: #edf5ff;
  color: #49617f;
}
.slip-validation .tone-ok { background: rgba(25,169,116,.12); color: #0f7f58; }
.slip-validation .tone-warning { background: #fff5cf; color: #8a6500; }
.slip-validation .tone-error { background: rgba(239,68,68,.11); color: #b72740; }
.slip-empty-v27-3 {
  display: grid;
  gap: 4px;
  min-height: 84px;
  place-content: center;
  text-align: center;
}
.slip-empty-v27-3 strong { color: var(--book-ink); }
.slip-empty-v27-3 span { color: var(--book-muted); font-size: 12px; }
.parlay-note-v27-3 {
  display: grid;
  gap: 3px;
  border-radius: 14px;
  border: 1px solid #d8e5f3;
  background: #f6faff;
  color: #244d80;
  padding: 10px;
  font-size: 12px;
}
.parlay-note-v27-3 strong { color: var(--book-navy); }
.slip-item-v27-3 {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 9px;
  border: 1px solid #d6e3f2;
  border-radius: 16px;
  background: #ffffff;
  padding: 10px;
}
.slip-selection-rank {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: #123d7d;
  color: #ffd21e;
  font-size: 12px;
  font-weight: 900;
}
.slip-selection-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}
.slip-selection-copy strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--book-ink);
}
.slip-selection-copy span,
.slip-selection-copy small {
  color: var(--book-muted);
  font-size: 11px;
  font-weight: 800;
}
.slip-price-block {
  display: grid;
  justify-items: end;
  gap: 2px;
}
.slip-price-block span {
  color: var(--book-muted);
  font-size: 9px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.slip-price-block strong {
  color: #0b3d7a;
  font-size: 17px;
}
.remove-selection-v27-3 {
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 999px;
  font-size: 18px;
}
.slip-actions-v27-3 button:disabled {
  opacity: .45;
  cursor: not-allowed;
}
.odds-warning-v27-3 {
  border-width: 2px;
}
.confirm-summary-v27-3 small,
.confirm-line-v27-3 small {
  color: #627086;
  font-size: 12px;
  font-weight: 800;
}
.confirm-line-v27-3 b {
  color: #2f80cf;
  margin-right: 5px;
}
.ticket-filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 8px 0 12px;
}
.ticket-filter-bar button {
  border: 1px solid #cbdced;
  border-radius: 999px;
  background: #f4f9ff;
  color: #244d80;
  padding: 8px 11px;
  font-size: 12px;
  font-weight: 900;
}
.ticket-filter-bar button.active {
  background: #123d7d;
  color: #ffd21e;
  border-color: #123d7d;
}
.ticket-summary-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
.ticket-card-v27-3 {
  border-radius: 20px;
  box-shadow: 0 14px 30px rgba(21,54,92,.10);
}
.ticket-card-head-v27-3 {
  background: linear-gradient(180deg, #ffffff, #f6faff);
}
.ticket-card-head-v27-3 small {
  display: block;
  color: var(--book-muted);
  font-size: 11px;
  font-weight: 800;
  margin-top: 3px;
}
.ticket-lines-v27-3 {
  gap: 9px;
}
.ticket-line-v27-3 {
  grid-template-columns: minmax(0, 1fr) auto;
  border: 1px solid #dfe8f3;
  background: #f8fbff;
}
.ticket-line-v27-3 b {
  color: #2f80cf;
  margin-right: 4px;
}
.ticket-financials-v27-3 span {
  display: grid;
  gap: 2px;
}
.ticket-ledger-links-v27-3 {
  border-top: 1px solid #e3ecf7;
  padding-top: 12px;
}
.ticket-card.status-won { border-color: rgba(25,169,116,.35); }
.ticket-card.status-lost { border-color: rgba(239,68,68,.24); }
.ticket-card.status-void { border-color: rgba(255,210,30,.45); }
.ticket-card.status-rejected { border-color: rgba(255,125,64,.32); }
.ticket-card.status-open,
.ticket-card.status-accepted { border-color: rgba(47,128,207,.28); }

@media (max-width: 1020px) {
  .close-slip { display: inline-grid; place-items: center; }
}
@media (max-width: 640px) {
  .slip-item-v27-3 {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }
  .remove-selection-v27-3 {
    grid-column: 3;
  }
  .slip-price-block {
    grid-column: 2 / 3;
    justify-items: start;
  }
  .quick-stake-row {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
  .quick-stake-row button { font-size: 11px; }
  .ticket-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ticket-filter-bar button { flex: 1 1 auto; }
}

/* Sprint 27.3 additive compatibility for ticket builder note + rules */
.slip-guidance {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border: 1px solid #d6e4f3;
  border-radius: 14px;
  background: #edf6ff;
  color: #315f95;
  font-size: 12px;
  font-weight: 850;
}
.ticket-rules-card {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px dashed #c5d5e8;
  background: #f8fbff;
  color: var(--book-muted);
  font-size: 12px;
}
.ticket-rules-card strong { color: var(--book-ink); }
.bet-submit-feedback {
  min-height: 0;
  font-size: 12px;
  font-weight: 850;
}
.drawer-close { display: none; }
@media (max-width: 1020px) {
  .drawer-close { display: inline-grid; place-items: center; }
}
.ticket-feed-note {
  margin-bottom: 10px;
  color: var(--book-muted);
  font-size: 12px;
  font-weight: 800;
}

/* Sprint 27.3: final Bet Slip feedback states */
.slip-guidance.tone-ok { background: rgba(25,169,116,.12); border-color: rgba(25,169,116,.28); color: #0f7f58; }
.slip-guidance.tone-warning { background: #fff5cf; border-color: rgba(201,129,0,.28); color: #8a6500; }
.slip-guidance.tone-error { background: rgba(239,68,68,.10); border-color: rgba(239,68,68,.22); color: #b72740; }
.bet-submit-feedback.success,
.bet-submit-feedback.info,
.bet-submit-feedback.error {
  display: block;
  padding: 9px 11px;
  border-radius: 13px;
  border: 1px solid #d6e4f3;
  background: #edf6ff;
}
.bet-submit-feedback.success { background: rgba(25,169,116,.12); border-color: rgba(25,169,116,.28); color: #0f7f58; }
.bet-submit-feedback.info { color: #315f95; }
.bet-submit-feedback.error { background: rgba(239,68,68,.10); border-color: rgba(239,68,68,.22); color: #b72740; }


/* Sprint 27.4: Wallet + Profile UX Polish */
.account-panel-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  align-items: end;
  justify-content: center;
  padding: 16px;
  background: rgba(2, 12, 27, .46);
  backdrop-filter: blur(5px);
}
.account-panel-backdrop.active { display: flex; }
.account-panel-v27-4 {
  width: min(100%, 540px);
  max-height: min(86vh, 760px);
  overflow: auto;
  display: grid;
  gap: 14px;
  border-radius: 28px 28px 0 0;
  border: 1px solid rgba(212, 226, 244, .95);
  background: #ffffff;
  box-shadow: 0 -24px 70px rgba(4, 21, 48, .34);
  padding: 18px;
}
.account-panel-head-v27-4,
.account-section-head-v27-4 {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.account-panel-head-v27-4 h2 {
  margin: 2px 0 0;
  color: var(--book-ink);
  font-size: 24px;
}
.account-tabs-v27-4 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  border-radius: 16px;
  padding: 5px;
  background: #eaf2fc;
}
.account-tabs-v27-4 button {
  border: 0;
  border-radius: 12px;
  padding: 10px 12px;
  background: transparent;
  color: #41658f;
  font-weight: 950;
}
.account-tabs-v27-4 button.active {
  background: #123d7d;
  color: #ffd21e;
  box-shadow: 0 9px 18px rgba(18, 61, 125, .22);
}
.account-panel-content-v27-4 { display: grid; gap: 12px; }
.wallet-balance-hero-v27-4 {
  display: grid;
  gap: 5px;
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(135deg, #0e3573, #1b66b2);
  color: #ffffff;
  box-shadow: 0 16px 35px rgba(18, 61, 125, .22);
}
.wallet-balance-hero-v27-4 span,
.wallet-balance-hero-v27-4 small {
  color: rgba(255, 255, 255, .78);
  font-size: 12px;
  font-weight: 850;
}
.wallet-balance-hero-v27-4 strong { font-size: 36px; line-height: 1; color: #ffd21e; }
.wallet-quick-facts-v27-4,
.account-info-grid-v27-4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.account-info-grid-v27-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.wallet-quick-facts-v27-4 span,
.account-info-grid-v27-4 span {
  display: grid;
  gap: 3px;
  border: 1px solid #d9e6f4;
  border-radius: 16px;
  background: #f7fbff;
  padding: 11px;
}
.wallet-quick-facts-v27-4 small,
.account-info-grid-v27-4 small {
  color: var(--book-muted);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.wallet-quick-facts-v27-4 strong,
.account-info-grid-v27-4 strong { color: var(--book-ink); font-size: 14px; }
.account-note-card-v27-4 {
  display: grid;
  gap: 5px;
  padding: 13px;
  border-radius: 17px;
  border: 1px solid #d9e6f4;
  background: #fffdf2;
  color: #596a7e;
}
.account-note-card-v27-4 strong { color: #123d7d; }
.account-note-card-v27-4 p { margin: 0; font-size: 12px; font-weight: 750; line-height: 1.45; }
.account-ledger-list-v27-4 { display: grid; gap: 8px; }
.account-ledger-row-v27-4 {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid #e2edf8;
  border-left-width: 4px;
  border-radius: 15px;
  background: #ffffff;
  padding: 10px 12px;
  color: var(--book-ink);
  text-align: left;
}
.account-ledger-row-v27-4:hover { transform: none; background: #f2f8ff; }
.account-ledger-row-v27-4.selected { box-shadow: 0 0 0 3px rgba(47,128,207,.12); }
.account-ledger-row-v27-4.tone-credit { border-left-color: #19a974; }
.account-ledger-row-v27-4.tone-debit { border-left-color: #d94b5f; }
.ledger-symbol {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  font-weight: 1000;
  background: #edf6ff;
  color: #123d7d;
}
.tone-credit .ledger-symbol { background: rgba(25,169,116,.14); color: #0f8a5e; }
.tone-debit .ledger-symbol { background: rgba(239,68,68,.10); color: #c0344a; }
.ledger-main { display: grid; gap: 2px; }
.ledger-main strong { color: var(--book-ink); font-size: 13px; }
.ledger-main small { color: var(--book-muted); font-size: 11px; font-weight: 800; }
.ledger-amount { font-weight: 950; color: #123d7d; white-space: nowrap; }
.account-ledger-detail-v27-4 {
  display: grid;
  gap: 3px;
  border: 1px solid #dbe8f5;
  border-radius: 15px;
  background: #f8fbff;
  padding: 10px 12px;
  color: var(--book-muted);
  font-size: 12px;
  font-weight: 800;
}
.account-ledger-detail-v27-4 strong { color: var(--book-ink); }
.account-ledger-detail-v27-4 span { color: #315f95; }
.profile-card-v27-4 {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: 20px;
  background: linear-gradient(180deg, #f8fbff, #edf6ff);
  border: 1px solid #d9e6f4;
}
.profile-avatar-v27-4 {
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #123d7d;
  color: #ffd21e;
  font-size: 22px;
  font-weight: 950;
}
.profile-card-v27-4 strong { display: block; color: var(--book-ink); font-size: 18px; }
.profile-card-v27-4 span { color: var(--book-muted); font-size: 12px; font-weight: 850; text-transform: capitalize; }
.account-empty-v27-4 { border: 1px dashed #c9d9eb; background: #f8fbff; }
body.account-panel-open .bet-slip-fab { opacity: .28; pointer-events: none; }
@media (min-width: 760px) {
  .account-panel-backdrop { align-items: center; }
  .account-panel-v27-4 { border-radius: 28px; }
}
@media (max-width: 640px) {
  .wallet-quick-facts-v27-4,
  .account-info-grid-v27-4 { grid-template-columns: 1fr; }
  .wallet-balance-hero-v27-4 strong { font-size: 30px; }
  .account-ledger-row-v27-4 { grid-template-columns: auto minmax(0, 1fr); }
  .ledger-amount { grid-column: 2; }
}

/* Sprint 27.5: Mobile Browser QA + User Interaction Polish */
html { scroll-behavior: smooth; }
body[data-role="user"] {
  overscroll-behavior-y: contain;
  -webkit-tap-highlight-color: transparent;
}
body[data-role="user"] button,
body[data-role="user"] input {
  font-size: 16px;
}
body[data-role="user"] button:focus-visible,
body[data-role="user"] input:focus-visible {
  outline: 3px solid rgba(255, 210, 30, .75);
  outline-offset: 2px;
}
.search-v27-5 {
  position: relative;
}
.search-clear-v27-5 {
  position: absolute;
  right: 38px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  min-height: 28px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(19, 61, 125, .10);
  color: #174080;
  font-size: 18px;
  line-height: 1;
  font-weight: 950;
}
.search-clear-v27-5[hidden] { display: none; }
.state-chip-v27-5 {
  color: #123d7d;
  background: #fff8d6;
  border-color: rgba(255, 210, 30, .75);
}
body[data-role="user"] .bet-mode-tabs,
body[data-role="user"] .mobile-status-strip,
body[data-role="user"] .board-column-head,
body[data-role="user"] .mobile-bottom-nav {
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
body[data-role="user"] .book-pill,
body[data-role="user"] .board-odd,
body[data-role="user"] .bet-mode,
body[data-role="user"] .mobile-bottom-nav button,
body[data-role="user"] .quick-stake-row button,
body[data-role="user"] .ticket-filter-bar button {
  min-height: 44px;
  touch-action: manipulation;
}
body[data-role="user"] .board-odd {
  min-width: 64px;
}
body[data-role="user"] .mobile-bottom-nav {
  padding-bottom: max(8px, env(safe-area-inset-bottom));
}
body[data-role="user"].bet-slip-open,
body[data-role="user"].account-panel-open {
  overflow: hidden;
}
body[data-role="user"] .modal-backdrop[aria-hidden="false"],
body[data-role="user"] .account-panel-backdrop.active {
  touch-action: none;
}
body[data-role="user"] .bet-slip-fab {
  bottom: calc(88px + env(safe-area-inset-bottom));
}
@media (max-width: 640px) {
  body[data-role="user"] .mobile-betting-shell {
    min-height: 100dvh;
  }
  body[data-role="user"] .mobile-status-strip {
    position: sticky;
    top: 0;
    z-index: 5;
    background: rgba(244, 248, 253, .92);
  }
  body[data-role="user"] .bet-mode-tabs {
    position: sticky;
    top: 0;
    z-index: 6;
    background: rgba(255, 255, 255, .92);
  }
  body[data-role="user"] .book-search input {
    padding-right: 72px;
  }
  body[data-role="user"] .mobile-bottom-nav button {
    min-height: 54px;
  }
  body[data-role="user"] .mobile-bet-slip.drawer-open {
    max-height: calc(100dvh - 24px - env(safe-area-inset-bottom));
  }
  body[data-role="user"] .account-panel-v27-4 {
    max-height: calc(92dvh - env(safe-area-inset-bottom));
    padding-bottom: max(18px, calc(18px + env(safe-area-inset-bottom)));
  }
  body[data-role="user"] .board-odd.selected {
    box-shadow: inset 0 -4px 0 #ffd21e, 0 0 0 2px rgba(18, 61, 125, .18);
  }
}
@media (max-width: 390px) {
  body[data-role="user"] .board-column-head,
  body[data-role="user"] .odds-board-row,
  body[data-role="user"] .draw-row,
  body[data-role="user"] .draw-row-v2 {
    grid-template-columns: minmax(74px, .9fr) repeat(3, minmax(58px, 1fr));
  }
  body[data-role="user"] .odd-price { font-size: 13px; }
  body[data-role="user"] .book-brand strong { font-size: 17px; }
  body[data-role="user"] .book-user-actions { gap: 5px; }
  body[data-role="user"] .book-logout { padding-inline: 9px; }
}

/* Sprint 27.5: User Journey Rail + Loading State Polish */
.user-flow-rail-v27-5 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 0 16px;
}
.user-flow-rail-v27-5 button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 44px;
  border: 1px solid rgba(18, 61, 125, .14);
  border-radius: 999px;
  background: rgba(255, 255, 255, .86);
  color: #315f95;
  font-weight: 950;
  box-shadow: 0 8px 18px rgba(11, 33, 70, .08);
}
.user-flow-rail-v27-5 button b {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #eaf2fc;
  color: #123d7d;
  font-size: 11px;
}
.user-flow-rail-v27-5 button.active {
  background: #123d7d;
  color: #ffd21e;
  border-color: #123d7d;
}
.user-flow-rail-v27-5 button.active b {
  background: #ffd21e;
  color: #123d7d;
}
.board-loading-state-v27-5 {
  display: grid;
  gap: 5px;
  place-items: center;
  min-height: 180px;
  border: 1px dashed #c9d9eb;
  border-radius: 20px;
  background: linear-gradient(180deg, #f8fbff, #edf6ff);
  color: #315f95;
  text-align: center;
  padding: 24px;
}
.board-loading-state-v27-5 strong {
  color: #123d7d;
  font-size: 18px;
}
.board-loading-state-v27-5 span {
  color: var(--book-muted);
  font-size: 12px;
  font-weight: 850;
}
.betting-board-loading-v27-5 {
  pointer-events: none;
  opacity: .92;
}
@media (max-width: 640px) {
  .user-flow-rail-v27-5 {
    position: sticky;
    top: 0;
    z-index: 7;
    overflow-x: auto;
    display: flex;
    padding: 8px 16px;
    background: rgba(244, 248, 253, .95);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    scroll-snap-type: x proximity;
  }
  .user-flow-rail-v27-5 button {
    min-width: 126px;
    scroll-snap-align: start;
  }
}
@media (max-width: 390px) {
  .user-flow-rail-v27-5 button {
    min-width: 112px;
    font-size: 12px;
  }
  .user-flow-rail-v27-5 button b {
    width: 20px;
    height: 20px;
  }
}

/* Sprint 27.6: User Toasts + Empty State + Final Feedback Polish */
.last-updated-v27-6 {
  color: #315f95;
  background: rgba(255, 255, 255, .72);
}
.board-summary-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}
.board-summary-strip span {
  display: grid;
  gap: 2px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(18, 61, 125, .11);
  background: #fff;
  color: #315f95;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: .02em;
}
.board-summary-strip strong {
  color: #123d7d;
  font-size: 17px;
  line-height: 1;
}
.betting-board-empty-v27-6 {
  display: grid;
  gap: 10px;
  min-height: 220px;
  place-items: center;
  text-align: center;
  border: 1px dashed rgba(18, 61, 125, .2);
  border-radius: 22px;
  background: linear-gradient(180deg, #ffffff, #f0f7ff);
  color: #315f95;
  padding: 26px;
}
.betting-board-empty-v27-6 strong {
  color: #123d7d;
  font-size: 20px;
}
.betting-board-empty-v27-6 span {
  max-width: 280px;
  color: var(--book-muted);
  font-weight: 850;
}
.empty-actions-v27-6 {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.user-toast-stack-v27-6 {
  position: fixed;
  right: 16px;
  bottom: calc(86px + env(safe-area-inset-bottom));
  z-index: 90;
  display: grid;
  gap: 10px;
  width: min(360px, calc(100vw - 28px));
  pointer-events: none;
}
.user-toast-v27-6 {
  pointer-events: auto;
  display: grid;
  grid-template-columns: 30px 1fr 28px;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border-radius: 18px;
  background: rgba(8, 22, 50, .94);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .12);
  box-shadow: 0 16px 40px rgba(5, 13, 32, .26);
  transform: translateY(0);
  transition: opacity .18s ease, transform .18s ease;
}
.user-toast-v27-6.leaving {
  opacity: 0;
  transform: translateY(10px) scale(.98);
}
.toast-icon-v27-6 {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, .12);
  color: #ffd21e;
  font-weight: 1000;
}
.user-toast-v27-6.tone-success .toast-icon-v27-6 { background: rgba(51, 190, 125, .18); color: #68ffb3; }
.user-toast-v27-6.tone-warning .toast-icon-v27-6 { background: rgba(255, 210, 30, .18); color: #ffd21e; }
.user-toast-v27-6.tone-error .toast-icon-v27-6 { background: rgba(255, 91, 91, .18); color: #ff9d9d; }
.toast-copy-v27-6 {
  display: grid;
  gap: 2px;
}
.toast-copy-v27-6 strong {
  font-size: 13px;
  line-height: 1.15;
}
.toast-copy-v27-6 small {
  color: rgba(255, 255, 255, .76);
  font-size: 12px;
  line-height: 1.25;
}
.user-toast-v27-6 button {
  width: 28px;
  height: 28px;
  padding: 0;
  border-radius: 999px;
  background: rgba(255,255,255,.12);
  color: #fff;
  border: 0;
}
@media (max-width: 640px) {
  .board-summary-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .user-toast-stack-v27-6 {
    left: 12px;
    right: 12px;
    width: auto;
    bottom: calc(78px + env(safe-area-inset-bottom));
  }
}

/* Sprint 27.7: User UX Freeze + Density + Accessibility Polish */
.user-skip-link-v27-7 {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 120;
  padding: 10px 14px;
  border-radius: 999px;
  background: #ffd21e;
  color: #123d7d;
  font-weight: 1000;
  box-shadow: 0 14px 28px rgba(0,0,0,.18);
  transition: top .18s ease;
}
.user-skip-link-v27-7:focus {
  top: calc(10px + env(safe-area-inset-top));
  outline: 3px solid rgba(18, 61, 125, .35);
}
.density-toggle-v27-7 {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .74);
  border: 1px solid rgba(18, 61, 125, .12);
}
.density-toggle-v27-7 button {
  min-height: 32px;
  border: 0;
  border-radius: 999px;
  padding: 6px 10px;
  background: transparent;
  color: #315f95;
  font-weight: 950;
}
.density-toggle-v27-7 button.active,
.density-toggle-v27-7 button[aria-pressed="true"] {
  background: #123d7d;
  color: #ffd21e;
}
.board-summary-strip-v27-7 {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
body[data-board-density="compact"] .league-board {
  gap: 8px;
}
body[data-board-density="compact"] .odds-event-card {
  padding: 10px;
  border-radius: 16px;
}
body[data-board-density="compact"] .event-date-row,
body[data-board-density="compact"] .event-matchup,
body[data-board-density="compact"] .board-column-head,
body[data-board-density="compact"] .odds-row {
  gap: 6px;
  padding: 6px 8px;
}
body[data-board-density="compact"] .matchup-main strong {
  font-size: 14px;
}
body[data-board-density="compact"] .board-odd {
  min-height: 54px;
  padding: 7px 6px;
  border-radius: 12px;
}
body[data-board-density="compact"] .odd-label,
body[data-board-density="compact"] .odd-line {
  font-size: 10px;
}
body[data-board-density="compact"] .odd-price {
  font-size: 14px;
}
.user-ux-freeze-note-v27-7 {
  margin: 10px 0 12px;
  padding: 10px 12px;
  border: 1px solid rgba(18, 61, 125, .12);
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff, #f3f8ff);
  color: #315f95;
  font-size: 12px;
  font-weight: 850;
}
.user-scroll-top-v27-7 {
  position: fixed;
  right: 18px;
  bottom: calc(144px + env(safe-area-inset-bottom));
  z-index: 70;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 999px;
  background: #123d7d;
  color: #ffd21e;
  border: 1px solid rgba(255,255,255,.24);
  box-shadow: 0 14px 34px rgba(6, 23, 56, .25);
  font-size: 18px;
  font-weight: 1000;
}
body[data-role="user"] button:focus-visible,
body[data-role="user"] input:focus-visible,
body[data-role="user"] a:focus-visible {
  outline: 3px solid rgba(255, 210, 30, .85);
  outline-offset: 3px;
}
@media (max-width: 640px) {
  .board-summary-strip-v27-7 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .board-summary-strip-v27-7 span:last-child {
    grid-column: 1 / -1;
  }
  .density-toggle-v27-7 {
    width: 100%;
    justify-content: space-between;
  }
  .density-toggle-v27-7 button {
    flex: 1;
  }
  .user-scroll-top-v27-7 {
    right: 12px;
    bottom: calc(132px + env(safe-area-inset-bottom));
  }
}
@media (prefers-reduced-motion: reduce) {
  .user-toast-v27-6,
  .user-skip-link-v27-7 {
    transition: none;
  }
  html:focus-within {
    scroll-behavior: auto;
  }
}

.board-odd[aria-pressed="true"]::after {
  content: "Selected";
  position: absolute;
  top: 6px;
  right: 7px;
  padding: 2px 6px;
  border-radius: 999px;
  background: rgba(255, 210, 30, .95);
  color: #061735;
  font-size: 9px;
  font-weight: 1000;
  letter-spacing: .03em;
  text-transform: uppercase;
}
.board-odd[aria-disabled="true"] {
  cursor: not-allowed;
}
#events-board:focus-visible {
  outline: 3px solid rgba(255, 210, 30, .95);
  outline-offset: 6px;
  border-radius: 22px;
}

/* Sprint 27.8: User Help Center + Betting Rules UX */
.help-circle-v27-8 {
  font-size: 17px;
  font-weight: 1000;
  color: #123d7d;
  background: #ffd21e;
}
.user-help-backdrop-v27-8 {
  position: fixed;
  inset: 0;
  z-index: 96;
  display: none;
  align-items: flex-end;
  justify-content: center;
  padding: 18px;
  background: rgba(6, 23, 56, .54);
  backdrop-filter: blur(10px);
}
.user-help-backdrop-v27-8.active {
  display: flex;
}
.user-help-panel-v27-8 {
  width: min(760px, 100%);
  max-height: min(82vh, 760px);
  overflow: auto;
  border-radius: 26px;
  background: linear-gradient(180deg, #ffffff, #f3f8ff);
  color: #061735;
  border: 1px solid rgba(255,255,255,.62);
  box-shadow: 0 28px 80px rgba(0,0,0,.34);
  padding: 18px;
}
.user-help-head-v27-8 {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(18, 61, 125, .12);
}
.user-help-head-v27-8 h2 {
  margin: 2px 0 0;
  font-size: 21px;
  color: #123d7d;
}
.help-rule-grid-v27-8 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
.help-rule-grid-v27-8 section,
.market-help-list-v27-8 div,
.funding-help-card-v27-8 {
  border: 1px solid rgba(18, 61, 125, .12);
  border-radius: 18px;
  background: #fff;
  padding: 12px;
  box-shadow: 0 12px 26px rgba(18, 61, 125, .07);
}
.help-rule-grid-v27-8 strong,
.market-help-list-v27-8 b,
.funding-help-card-v27-8 strong {
  color: #123d7d;
  font-weight: 1000;
}
.help-rule-grid-v27-8 span,
.market-help-list-v27-8 span,
.funding-help-card-v27-8 p {
  display: block;
  margin-top: 4px;
  color: #456b94;
  font-size: 13px;
  line-height: 1.35;
}
.market-help-list-v27-8 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}
.funding-help-card-v27-8 {
  margin-top: 10px;
  background: linear-gradient(180deg, #fff8d7, #fff);
}
.help-action-row-v27-8 {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}
.help-action-row-v27-8 button {
  min-height: 44px;
}
body.user-help-open .mobile-bottom-nav,
body.user-help-open .bet-slip-fab,
body.user-help-open .user-scroll-top-v27-7 {
  pointer-events: none;
  opacity: .45;
}
@media (max-width: 640px) {
  .user-help-backdrop-v27-8 {
    align-items: flex-end;
    padding: 10px;
  }
  .user-help-panel-v27-8 {
    max-height: min(86vh, 760px);
    border-radius: 24px 24px 18px 18px;
    padding: 14px;
  }
  .help-rule-grid-v27-8,
  .market-help-list-v27-8,
  .help-action-row-v27-8 {
    grid-template-columns: 1fr;
  }
}

/* Sprint 27.9: Event Detail Quick Preview + Market Actions */
.matchup-open-v27-9 {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  text-align: left;
  color: inherit;
  border-radius: 12px;
}
.matchup-open-v27-9:hover strong,
.matchup-open-v27-9:focus-visible strong {
  color: #ffd21e;
}
.event-detail-backdrop-v27-9 {
  position: fixed;
  inset: 0;
  z-index: 97;
  display: none;
  align-items: flex-end;
  justify-content: center;
  padding: 18px;
  background: rgba(6, 23, 56, .58);
  backdrop-filter: blur(12px);
}
.event-detail-backdrop-v27-9.active {
  display: flex;
}
.event-detail-panel-v27-9 {
  width: min(820px, 100%);
  max-height: min(84vh, 780px);
  overflow: auto;
  border-radius: 28px;
  background: linear-gradient(180deg, #ffffff, #f3f8ff);
  color: #061735;
  border: 1px solid rgba(255,255,255,.62);
  box-shadow: 0 32px 88px rgba(0,0,0,.36);
  padding: 18px;
}
.event-detail-head-v27-9 {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(18, 61, 125, .12);
}
.event-detail-head-v27-9 h2 {
  margin: 2px 0 0;
  font-size: 22px;
  color: #123d7d;
}
.event-preview-hero-v27-9 {
  margin-top: 14px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px;
  border-radius: 20px;
  background: linear-gradient(135deg, #123d7d, #0b2753);
  color: #fff;
  box-shadow: 0 16px 34px rgba(18, 61, 125, .22);
}
.event-preview-time-v27-9 {
  min-width: 86px;
  display: grid;
  gap: 2px;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255,255,255,.12);
}
.event-preview-time-v27-9 span,
.event-preview-matchup-v27-9 span {
  font-size: 12px;
  opacity: .78;
}
.event-preview-matchup-v27-9 strong {
  display: block;
  font-size: 18px;
  line-height: 1.2;
}
.event-preview-stats-v27-9 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.event-preview-stats-v27-9 span,
.event-market-preview-v27-9 span,
.event-quick-odds-v27-9 button {
  border: 1px solid rgba(18, 61, 125, .12);
  border-radius: 18px;
  background: #fff;
  padding: 12px;
  box-shadow: 0 12px 26px rgba(18, 61, 125, .07);
}
.event-preview-stats-v27-9 strong {
  display: block;
  color: #123d7d;
  font-size: 18px;
}
.event-preview-actions-v27-9 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}
.event-preview-actions-v27-9 button {
  min-height: 46px;
}
.event-market-preview-v27-9 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.event-market-preview-v27-9 b,
.event-market-preview-v27-9 small {
  display: block;
}
.event-market-preview-v27-9 b {
  color: #123d7d;
  font-size: 13px;
}
.event-market-preview-v27-9 small {
  margin-top: 3px;
  color: #56779d;
  font-size: 11px;
}
.event-quick-odds-v27-9 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.event-quick-odds-v27-9 button {
  text-align: left;
  min-height: 82px;
}
.event-quick-odds-v27-9 button:hover:not(:disabled),
.event-quick-odds-v27-9 button:focus-visible:not(:disabled) {
  border-color: #ffd21e;
  transform: translateY(-1px);
}
.event-quick-odds-v27-9 button span,
.event-quick-odds-v27-9 button small {
  display: block;
  color: #56779d;
  font-size: 12px;
}
.event-quick-odds-v27-9 button strong {
  display: block;
  margin: 4px 0;
  color: #123d7d;
  font-size: 20px;
}
.event-quick-odds-v27-9 button.is-disabled {
  opacity: .48;
  cursor: not-allowed;
}
body.event-detail-open .mobile-bottom-nav,
body.event-detail-open .bet-slip-fab,
body.event-detail-open .user-scroll-top-v27-7 {
  pointer-events: none;
  opacity: .45;
}
@media (max-width: 640px) {
  .event-detail-backdrop-v27-9 {
    align-items: flex-end;
    padding: 10px;
  }
  .event-detail-panel-v27-9 {
    max-height: min(88vh, 780px);
    border-radius: 24px 24px 18px 18px;
    padding: 14px;
  }
  .event-preview-hero-v27-9,
  .event-preview-stats-v27-9,
  .event-preview-actions-v27-9,
  .event-market-preview-v27-9,
  .event-quick-odds-v27-9 {
    grid-template-columns: 1fr;
  }
}

/* Sprint 27.9: Bet acceptance receipt + final ticket feedback */
.receipt-backdrop-v27-9 {
  position: fixed;
  inset: 0;
  z-index: 98;
  display: none;
  align-items: flex-end;
  justify-content: center;
  padding: 18px;
  background: rgba(6, 23, 56, .56);
  backdrop-filter: blur(10px);
}
.receipt-backdrop-v27-9.active {
  display: flex;
}
.receipt-modal-v27-9 {
  width: min(720px, 100%);
  max-height: min(84vh, 760px);
  overflow: auto;
  border-radius: 28px;
  padding: 18px;
  color: #061735;
  background: linear-gradient(180deg, #ffffff, #f5f9ff);
  border: 1px solid rgba(255,255,255,.74);
  box-shadow: 0 28px 90px rgba(0,0,0,.34);
}
.receipt-head-v27-9 {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(18,61,125,.12);
}
.receipt-head-v27-9 h2 {
  margin: 2px 0 0;
  color: #123d7d;
  font-size: 22px;
}
.receipt-hero-v27-9 {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 14px 0;
  padding: 14px;
  border-radius: 22px;
  background: linear-gradient(135deg, #e9fff3, #ffffff);
  border: 1px solid rgba(22,163,74,.20);
}
.receipt-check-v27-9 {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  background: #16a34a;
  color: #fff;
  font-weight: 1000;
  font-size: 24px;
  box-shadow: 0 14px 26px rgba(22,163,74,.22);
}
.receipt-hero-v27-9 strong {
  display: block;
  color: #0f7a38;
  font-size: 18px;
  font-weight: 1000;
}
.receipt-hero-v27-9 small,
.receipt-note-v27-9 {
  color: #456b94;
}
.receipt-summary-grid-v27-9 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.receipt-summary-grid-v27-9 span,
.receipt-selection-v27-9,
.receipt-note-v27-9 {
  border: 1px solid rgba(18,61,125,.12);
  border-radius: 18px;
  padding: 12px;
  background: #fff;
  box-shadow: 0 12px 26px rgba(18,61,125,.07);
}
.receipt-summary-grid-v27-9 small {
  display: block;
  color: #6b87a8;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 900;
}
.receipt-summary-grid-v27-9 strong {
  display: block;
  margin-top: 3px;
  color: #123d7d;
  font-size: 15px;
}
.receipt-selection-list-v27-9 {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}
.receipt-selection-v27-9 {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.receipt-selection-v27-9 strong,
.receipt-selection-v27-9 b {
  color: #123d7d;
  font-weight: 1000;
}
.receipt-selection-v27-9 small {
  display: block;
  margin-top: 3px;
  color: #6b87a8;
  font-size: 12px;
}
.receipt-note-v27-9 {
  margin-top: 12px;
  background: linear-gradient(180deg, #fff8d7, #fff);
  line-height: 1.35;
}
.receipt-actions-v27-9 {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 10px;
  margin-top: 14px;
}
.receipt-actions-v27-9 button {
  min-height: 46px;
}
body.bet-slip-open .receipt-backdrop-v27-9.active ~ .mobile-bottom-nav {
  pointer-events: none;
}
@media (max-width: 640px) {
  .receipt-backdrop-v27-9 {
    padding: 10px;
  }
  .receipt-modal-v27-9 {
    border-radius: 24px 24px 18px 18px;
    padding: 14px;
  }
  .receipt-summary-grid-v27-9,
  .receipt-actions-v27-9 {
    grid-template-columns: 1fr;
  }
}

/* Sprint 27.10 — User noise reduction + settings consolidation */
.player-home-summary-single-v27-10 {
  grid-template-columns: 1fr;
  margin-top: 0.9rem;
}
.player-home-summary-single-v27-10 .balance-only-v27-10 {
  min-height: 76px;
}
.mobile-settings-row-v27-10 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0.75rem 0 0.85rem;
  padding: 0.72rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 16px;
  background: rgba(5, 17, 36, 0.68);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.14);
}
.sportsbook-settings-button-v27-10 {
  border: 1px solid rgba(106, 169, 255, 0.32);
  background: rgba(59, 130, 246, 0.16);
  color: #e8f2ff;
  border-radius: 999px;
  padding: 0.68rem 0.95rem;
  min-height: 42px;
  font-weight: 900;
}
.settings-summary-v27-10 {
  color: rgba(231, 240, 255, 0.74);
  font-size: 0.82rem;
  text-align: right;
}
.settings-circle-v27-10 {
  font-size: 1rem;
}
.user-settings-backdrop-v27-10 {
  position: fixed;
  inset: 0;
  z-index: 85;
  background: rgba(3, 10, 21, 0.52);
  display: none;
  align-items: flex-end;
  justify-content: center;
  padding: 1rem;
}
.user-settings-backdrop-v27-10.active {
  display: flex;
}
.user-settings-panel-v27-10 {
  width: min(520px, 100%);
  border-radius: 24px 24px 18px 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(180deg, #0b2346 0%, #06152d 100%);
  color: #f7fbff;
  box-shadow: 0 -24px 80px rgba(0, 0, 0, 0.35);
  padding: 1rem;
}
.user-settings-head-v27-10 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
.user-settings-head-v27-10 h2 {
  margin: 0.15rem 0 0;
}
.settings-section-v27-10 {
  display: grid;
  gap: 0.7rem;
  padding: 0.9rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 0.8rem;
}
.settings-section-v27-10 strong {
  font-size: 0.9rem;
}
.settings-toggle-group-v27-10 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.55rem;
}
.settings-toggle-group-v27-10 button {
  min-height: 44px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.06);
  color: #eaf3ff;
  font-weight: 900;
}
.settings-toggle-group-v27-10 button.active,
.settings-toggle-group-v27-10 button[aria-pressed="true"] {
  background: linear-gradient(135deg, #f7c948, #f59e0b);
  color: #071424;
  border-color: transparent;
}
.settings-note-v27-10 {
  color: rgba(233, 241, 255, 0.72);
  line-height: 1.45;
  font-size: 0.84rem;
  padding: 0.25rem 0.1rem 0;
}
body.user-settings-open {
  overflow: hidden;
}
@media (max-width: 520px) {
  .mobile-settings-row-v27-10 {
    align-items: stretch;
    flex-direction: column;
  }
  .settings-summary-v27-10 {
    text-align: left;
  }
}

/* Sprint 27.11 — App-like page separation + sticky bottom nav */
body[data-role="user"] {
  padding-bottom: calc(92px + env(safe-area-inset-bottom));
}
body[data-role="user"] .mobile-betting-shell {
  padding-bottom: calc(90px + env(safe-area-inset-bottom));
}
.user-page-v27-11[hidden] {
  display: none !important;
}
.user-page-v27-11.active {
  display: block;
}
.user-page-lobby-v27-11,
.user-page-lobby.active {
  max-width: 760px;
  margin: 0 auto;
}
.book-lobby-page-v27-11 {
  margin-top: 0.85rem;
}
.user-page-board-v27-11 {
  max-width: 980px;
  margin: 0 auto;
}
.betting-board-card-v27-11 {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}
body[data-role="user"] #events-board {
  display: grid;
  gap: 0.85rem;
}
body[data-role="user"] .league-board {
  display: grid;
  gap: 0.75rem;
}
body[data-role="user"] .league-header {
  margin: 0 0.1rem;
  border-radius: 16px;
}
.sportsbook-overlays-grid-v27-11 {
  display: contents;
}
body[data-role="user"] .mobile-bet-slip {
  position: fixed !important;
  left: 50%;
  right: auto;
  bottom: calc(86px + env(safe-area-inset-bottom));
  width: min(560px, calc(100vw - 18px));
  max-height: min(76dvh, 760px);
  overflow: auto;
  transform: translate(-50%, calc(100% + 130px));
  opacity: 0;
  pointer-events: none;
  z-index: 78;
  border: 2px solid #ffd21e;
  box-shadow: 0 24px 70px rgba(5, 22, 54, .35);
}
body[data-role="user"] .mobile-bet-slip.drawer-open {
  transform: translate(-50%, 0);
  opacity: 1;
  pointer-events: auto;
}
body[data-role="user"] .mobile-bottom-nav {
  display: grid !important;
  position: fixed !important;
  left: 50%;
  right: auto;
  bottom: max(10px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  width: min(560px, calc(100vw - 16px));
  z-index: 95;
  grid-template-columns: repeat(5, 1fr);
  padding: 8px;
  border-radius: 24px;
  background: rgba(255, 255, 255, .94);
  border: 1px solid rgba(19, 61, 125, .12);
  box-shadow: 0 18px 50px rgba(5, 22, 54, .24);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}
body[data-role="user"] .mobile-bottom-nav button {
  min-height: 54px;
  border-radius: 18px;
  font-weight: 950;
  color: #335b91;
}
body[data-role="user"] .mobile-bottom-nav button.active {
  background: linear-gradient(180deg, #eef6ff, #dcecff);
  color: #123d7d;
  box-shadow: inset 0 0 0 1px rgba(23, 64, 128, .08);
}
.ticket-history-backdrop-v27-11 {
  position: fixed;
  inset: 0;
  z-index: 88;
  background: rgba(3, 10, 21, .54);
  display: none;
  align-items: flex-end;
  justify-content: center;
  padding: 1rem;
}
.ticket-history-backdrop-v27-11.active {
  display: flex;
}
.ticket-history-modal-v27-11 {
  width: min(680px, 100%);
  max-height: calc(86dvh - env(safe-area-inset-bottom));
  overflow: auto;
  margin: 0;
  border-radius: 24px 24px 18px 18px;
  background: linear-gradient(180deg, #ffffff, #f4f8ff);
  box-shadow: 0 -24px 80px rgba(0, 0, 0, .34);
  padding-bottom: max(16px, env(safe-area-inset-bottom));
}
body.ticket-history-open {
  overflow: hidden;
}
body.ticket-history-open .bet-slip-fab,
body.account-panel-open .bet-slip-fab,
body.user-settings-open .bet-slip-fab,
body.user-help-open .bet-slip-fab,
body.event-detail-open .bet-slip-fab {
  opacity: .24;
  pointer-events: none;
}
@media (max-width: 640px) {
  body[data-role="user"] .mobile-book-header {
    position: sticky;
    top: 0;
    z-index: 30;
  }
  body[data-role="user"] .player-home-summary-single-v27-10 {
    margin-inline: 0.65rem;
  }
  .user-page-v27-11 {
    padding-inline: 0.65rem;
  }
  body[data-role="user"] .book-lobby,
  body[data-role="user"] .odds-event-card {
    border-radius: 18px;
  }
  body[data-role="user"] .mobile-bottom-nav {
    width: min(540px, calc(100vw - 12px));
    border-radius: 22px;
  }
  body[data-role="user"] .mobile-bottom-nav span {
    font-size: 11px;
  }
  body[data-role="user"] .bet-slip-fab {
    bottom: calc(92px + env(safe-area-inset-bottom));
  }
}

/* Sprint 27.12 — User home declutter, sticky topbar, play mode, and theme settings */
body[data-role="user"] .mobile-betting-shell {
  overflow: visible;
  padding-bottom: calc(92px + env(safe-area-inset-bottom));
}

body[data-role="user"] .mobile-book-header.user-layout-v27 {
  position: sticky;
  top: 0;
  z-index: 96;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "brand actions"
    "search search";
  transition: transform 180ms ease, box-shadow 180ms ease, opacity 180ms ease;
  will-change: transform;
}

body[data-role="user"] .mobile-book-header.user-layout-v27.is-hidden-on-scroll-v27-12 {
  transform: translateY(calc(-100% - 8px));
  opacity: 0.98;
}

body[data-role="user"] .mobile-book-header.user-layout-v27 .book-search-row-v27-12 {
  grid-area: search;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
}

body[data-role="user"] .mobile-book-header.user-layout-v27 .book-search-row-v27-12 .book-search {
  grid-area: auto;
  min-width: 0;
}

.header-balance-card-v27-12 {
  display: grid;
  align-content: center;
  justify-items: end;
  min-width: 96px;
  height: 46px;
  border-radius: 16px;
  padding: 7px 10px;
  background: rgba(255, 255, 255, .94);
  color: #14396f;
  box-shadow: inset 0 0 0 1px rgba(19, 55, 105, .08), 0 8px 18px rgba(6, 23, 54, .12);
}
.header-balance-card-v27-12 span {
  font-size: 10px;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #6b7f9c;
  font-weight: 900;
}
.header-balance-card-v27-12 strong {
  font-size: 15px;
  line-height: 1.12;
  color: #123d7d;
}

.play-mode-bar-v27-12 {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: #f4f8fd;
  border-bottom: 1px solid #d7e0ec;
}
.play-mode-label-v27-12 {
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: #667a96;
  white-space: nowrap;
}
.play-mode-tabs-v27-12 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  padding: 4px;
  border-radius: 999px;
  background: #e4eef8;
  box-shadow: inset 0 0 0 1px rgba(18, 61, 125, .06);
}
.play-mode-tabs-v27-12 .bet-mode {
  border-radius: 999px;
  padding: 10px 8px;
  font-size: 14px;
  font-weight: 950;
  color: #315b90;
}
.play-mode-tabs-v27-12 .bet-mode.active {
  background: #ffffff;
  color: #123d7d;
  box-shadow: 0 8px 18px rgba(12, 45, 93, .12);
}
.play-mode-tabs-v27-12 .bet-mode.active::before { display: none; }

body[data-role="user"] .mobile-settings-row-v27-10,
body[data-role="user"] .player-home-summary,
body[data-role="user"] .player-home-summary-single-v27-10 {
  display: none !important;
}

body[data-role="user"] .book-user-actions .book-logout { display: none !important; }

body[data-role="user"][data-user-theme="dark"] .mobile-betting-shell {
  --book-white: #121c2b;
  --book-ink: #e9f2ff;
  --book-muted: #9fb2ca;
  --book-line: rgba(166, 195, 232, .18);
  background: linear-gradient(180deg, #07111f 0%, #0d1728 100%);
  color: #e9f2ff;
}
body[data-role="user"][data-user-theme="dark"] .mobile-book-header.user-layout-v27 {
  background:
    radial-gradient(circle at 18% 0%, rgba(93, 153, 255, .24), transparent 18rem),
    linear-gradient(135deg, #071b35 0%, #123d7d 58%, #061327 100%);
  box-shadow: 0 18px 42px rgba(0, 0, 0, .42);
}
body[data-role="user"][data-user-theme="dark"] .mobile-book-header.user-layout-v27 .book-search {
  background: rgba(10, 25, 47, .94);
  box-shadow: inset 0 0 0 1px rgba(130, 180, 255, .18);
}
body[data-role="user"][data-user-theme="dark"] .mobile-book-header.user-layout-v27 .book-search input {
  color: #f4f8ff;
}
body[data-role="user"][data-user-theme="dark"] .mobile-book-header.user-layout-v27 .book-search input::placeholder {
  color: rgba(209, 224, 247, .54);
}
body[data-role="user"][data-user-theme="dark"] .header-balance-card-v27-12,
body[data-role="user"][data-user-theme="dark"] .profile-circle {
  background: rgba(11, 28, 52, .94);
  color: #e9f2ff;
  box-shadow: inset 0 0 0 1px rgba(130, 180, 255, .18), 0 8px 20px rgba(0, 0, 0, .26);
}
body[data-role="user"][data-user-theme="dark"] .header-balance-card-v27-12 span { color: #9fb2ca; }
body[data-role="user"][data-user-theme="dark"] .header-balance-card-v27-12 strong { color: #ffffff; }
body[data-role="user"][data-user-theme="dark"] .play-mode-bar-v27-12,
body[data-role="user"][data-user-theme="dark"] .book-lobby,
body[data-role="user"][data-user-theme="dark"] .betting-board-card,
body[data-role="user"][data-user-theme="dark"] .league-board,
body[data-role="user"][data-user-theme="dark"] .event-board-card,
body[data-role="user"][data-user-theme="dark"] .mobile-bet-slip,
body[data-role="user"][data-user-theme="dark"] .account-panel,
body[data-role="user"][data-user-theme="dark"] .ticket-history-panel-v27-11,
body[data-role="user"][data-user-theme="dark"] .user-settings-panel,
body[data-role="user"][data-user-theme="dark"] .user-help-panel,
body[data-role="user"][data-user-theme="dark"] .event-detail-panel,
body[data-role="user"][data-user-theme="dark"] .receipt-modal {
  background: #0f1b2d;
  color: #e9f2ff;
  border-color: rgba(163, 195, 238, .16);
}
body[data-role="user"][data-user-theme="dark"] .play-mode-label-v27-12,
body[data-role="user"][data-user-theme="dark"] .eyebrow,
body[data-role="user"][data-user-theme="dark"] .subcopy,
body[data-role="user"][data-user-theme="dark"] .empty-state,
body[data-role="user"][data-user-theme="dark"] small,
body[data-role="user"][data-user-theme="dark"] .odd-label,
body[data-role="user"][data-user-theme="dark"] .odd-line {
  color: #9fb2ca;
}
body[data-role="user"][data-user-theme="dark"] .play-mode-tabs-v27-12 {
  background: #081326;
  box-shadow: inset 0 0 0 1px rgba(130, 180, 255, .14);
}
body[data-role="user"][data-user-theme="dark"] .play-mode-tabs-v27-12 .bet-mode {
  color: #b9d2f4;
}
body[data-role="user"][data-user-theme="dark"] .play-mode-tabs-v27-12 .bet-mode.active {
  background: #1d4f95;
  color: #ffffff;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .26);
}
body[data-role="user"][data-user-theme="dark"] .book-pill,
body[data-role="user"][data-user-theme="dark"] .board-odd,
body[data-role="user"][data-user-theme="dark"] .ticket-card,
body[data-role="user"][data-user-theme="dark"] .wallet-activity-row,
body[data-role="user"][data-user-theme="dark"] .settings-section-v27-10,
body[data-role="user"][data-user-theme="dark"] .help-rule-grid-v27-8 section,
body[data-role="user"][data-user-theme="dark"] .market-help-list-v27-8 div {
  background: #121f33;
  color: #e9f2ff;
  border-color: rgba(163, 195, 238, .16);
}
body[data-role="user"][data-user-theme="dark"] .board-odd.selected {
  background: linear-gradient(180deg, #1c4f94, #133868);
  border-color: #ffd21e;
}
body[data-role="user"][data-user-theme="dark"] .mobile-bottom-nav {
  background: rgba(11, 25, 45, .94);
  border-color: rgba(163, 195, 238, .18);
}
body[data-role="user"][data-user-theme="dark"] .mobile-bottom-nav button {
  color: #b9d2f4;
}
body[data-role="user"][data-user-theme="dark"] .mobile-bottom-nav button.active {
  background: #193b6b;
  color: #ffffff;
}

@media (max-width: 420px) {
  body[data-role="user"] .mobile-book-header.user-layout-v27 .book-search-row-v27-12 {
    grid-template-columns: minmax(0, 1fr) 84px;
  }
  .header-balance-card-v27-12 {
    min-width: 84px;
    padding-inline: 8px;
  }
  .header-balance-card-v27-12 strong { font-size: 13px; }
  .play-mode-bar-v27-12 {
    grid-template-columns: 1fr;
    gap: 7px;
  }
}

/* Sprint 27.13 — overlay topbar hiding + unified bet placement */
body[data-role="user"] .mobile-book-header.user-layout-v27.is-hidden-for-overlay-v27-13,
body[data-role="user"].user-overlay-open-v27-13 .mobile-book-header.user-layout-v27,
body[data-role="user"].bet-slip-open .mobile-book-header.user-layout-v27,
body[data-role="user"].ticket-history-open .mobile-book-header.user-layout-v27,
body[data-role="user"].account-panel-open .mobile-book-header.user-layout-v27,
body[data-role="user"].user-settings-open .mobile-book-header.user-layout-v27,
body[data-role="user"].user-help-open .mobile-book-header.user-layout-v27,
body[data-role="user"].event-detail-open .mobile-book-header.user-layout-v27,
body[data-role="user"].confirm-bet-open-v27-13 .mobile-book-header.user-layout-v27,
body[data-role="user"].receipt-open-v27-13 .mobile-book-header.user-layout-v27 {
  transform: translateY(calc(-100% - 12px));
  opacity: 0;
  pointer-events: none;
}

body[data-role="user"].confirm-bet-open-v27-13 .modal-backdrop.active {
  z-index: 130;
}

body[data-role="user"].receipt-open-v27-13 .receipt-backdrop.active {
  z-index: 132;
}

body[data-role="user"].confirm-bet-open-v27-13 .mobile-bet-slip.drawer-open {
  transform: translateY(18px) scale(.985);
  opacity: .16;
  pointer-events: none;
  filter: blur(1px);
}

.slip-actions-v27-13 {
  display: grid;
  gap: 8px;
}

.place-bet-full-v27-13 {
  width: 100%;
  min-height: 52px;
  border-radius: 16px;
  font-size: 14px;
  font-weight: 950;
  letter-spacing: .08em;
  background: linear-gradient(180deg, #ffd94a, #f2bd12);
  color: #082c63;
  box-shadow: 0 14px 28px rgba(139, 91, 0, .2);
}

.place-bet-full-v27-13:disabled {
  opacity: .54;
  box-shadow: none;
  cursor: not-allowed;
}

body[data-user-theme="dark"] .place-bet-full-v27-13 {
  background: linear-gradient(180deg, #ffe16c, #d7a90e);
  color: #06152e;
}

/* Sprint 27.14: bottom-sheet slide motion + tappable nav toggles */
@keyframes sheetSlideUpV27_14 {
  from { transform: translateY(calc(100% + 36px)); opacity: 0.2; }
  to { transform: translateY(0); opacity: 1; }
}
@keyframes sheetSlideDownV27_14 {
  from { transform: translateY(0); opacity: 1; }
  to { transform: translateY(calc(100% + 36px)); opacity: 0; }
}
@keyframes sheetBackdropInV27_14 {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes sheetBackdropOutV27_14 {
  from { opacity: 1; }
  to { opacity: 0; }
}
body[data-role="user"] .account-panel-backdrop.active,
body[data-role="user"] .ticket-history-backdrop-v27-11.active,
body[data-role="user"] .user-settings-backdrop-v27-10.active,
body[data-role="user"] .user-help-backdrop-v27-8.active,
body[data-role="user"] .event-detail-backdrop-v27-9.active {
  animation: sheetBackdropInV27_14 .18s ease-out both;
}
body[data-role="user"] .account-panel-backdrop.sheet-closing-v27-14,
body[data-role="user"] .ticket-history-backdrop-v27-11.sheet-closing-v27-14,
body[data-role="user"] .user-settings-backdrop-v27-10.sheet-closing-v27-14,
body[data-role="user"] .user-help-backdrop-v27-8.sheet-closing-v27-14,
body[data-role="user"] .event-detail-backdrop-v27-9.sheet-closing-v27-14 {
  display: flex !important;
  animation: sheetBackdropOutV27_14 .20s ease-in both;
  pointer-events: none;
}
body[data-role="user"] .account-panel-backdrop.active .account-panel-v27-4,
body[data-role="user"] .ticket-history-backdrop-v27-11.active .ticket-history-modal-v27-11,
body[data-role="user"] .user-settings-backdrop-v27-10.active .user-settings-panel-v27-10,
body[data-role="user"] .user-help-backdrop-v27-8.active .user-help-panel-v27-8,
body[data-role="user"] .event-detail-backdrop-v27-9.active .event-detail-panel-v27-9 {
  animation: sheetSlideUpV27_14 .24s cubic-bezier(.2,.85,.25,1) both;
  will-change: transform, opacity;
}
body[data-role="user"] .account-panel-backdrop.sheet-closing-v27-14 .account-panel-v27-4,
body[data-role="user"] .ticket-history-backdrop-v27-11.sheet-closing-v27-14 .ticket-history-modal-v27-11,
body[data-role="user"] .user-settings-backdrop-v27-10.sheet-closing-v27-14 .user-settings-panel-v27-10,
body[data-role="user"] .user-help-backdrop-v27-8.sheet-closing-v27-14 .user-help-panel-v27-8,
body[data-role="user"] .event-detail-backdrop-v27-9.sheet-closing-v27-14 .event-detail-panel-v27-9 {
  animation: sheetSlideDownV27_14 .20s ease-in both;
  will-change: transform, opacity;
}
body[data-role="user"] .mobile-bet-slip {
  transition: transform .24s cubic-bezier(.2,.85,.25,1), opacity .20s ease, filter .20s ease;
}
body[data-role="user"] .mobile-bottom-nav button.active {
  position: relative;
}
body[data-role="user"] .mobile-bottom-nav button.active::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 7px;
  width: 18px;
  height: 3px;
  border-radius: 99px;
  background: #ffd21e;
  transform: translateX(-50%);
}
body[data-role="user"] .mobile-bottom-nav button:active {
  transform: translateY(1px) scale(.99);
}
@media (prefers-reduced-motion: reduce) {
  body[data-role="user"] .account-panel-backdrop.active,
  body[data-role="user"] .ticket-history-backdrop-v27-11.active,
  body[data-role="user"] .user-settings-backdrop-v27-10.active,
  body[data-role="user"] .user-help-backdrop-v27-8.active,
  body[data-role="user"] .event-detail-backdrop-v27-9.active,
  body[data-role="user"] .account-panel-backdrop.active .account-panel-v27-4,
  body[data-role="user"] .ticket-history-backdrop-v27-11.active .ticket-history-modal-v27-11,
  body[data-role="user"] .user-settings-backdrop-v27-10.active .user-settings-panel-v27-10,
  body[data-role="user"] .user-help-backdrop-v27-8.active .user-help-panel-v27-8,
  body[data-role="user"] .event-detail-backdrop-v27-9.active .event-detail-panel-v27-9,
  body[data-role="user"] .account-panel-backdrop.sheet-closing-v27-14,
  body[data-role="user"] .ticket-history-backdrop-v27-11.sheet-closing-v27-14,
  body[data-role="user"] .user-settings-backdrop-v27-10.sheet-closing-v27-14,
  body[data-role="user"] .user-help-backdrop-v27-8.sheet-closing-v27-14,
  body[data-role="user"] .event-detail-backdrop-v27-9.sheet-closing-v27-14,
  body[data-role="user"] .account-panel-backdrop.sheet-closing-v27-14 .account-panel-v27-4,
  body[data-role="user"] .ticket-history-backdrop-v27-11.sheet-closing-v27-14 .ticket-history-modal-v27-11,
  body[data-role="user"] .user-settings-backdrop-v27-10.sheet-closing-v27-14 .user-settings-panel-v27-10,
  body[data-role="user"] .user-help-backdrop-v27-8.sheet-closing-v27-14 .user-help-panel-v27-8,
  body[data-role="user"] .event-detail-backdrop-v27-9.sheet-closing-v27-14 .event-detail-panel-v27-9 {
    animation: none !important;
  }
}

/* Sprint 27.15 - Ticket builder play mode and simplified ticket history */
.ticket-play-mode-v27-15 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(16, 47, 91, 0.10);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,0.92), rgba(245,248,252,0.92));
  box-shadow: 0 8px 18px rgba(9, 30, 66, 0.06);
}
.ticket-play-mode-v27-15 > span {
  color: var(--book-muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}
.ticket-play-mode-tabs-v27-15 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(16, 47, 91, 0.08);
  min-width: 168px;
}
.ticket-play-mode-tabs-v27-15 .bet-mode {
  border: 0;
  border-radius: 999px;
  min-height: 36px;
  padding: 8px 14px;
  background: transparent;
  color: var(--book-muted);
  font-size: 12px;
  font-weight: 950;
  box-shadow: none;
}
.ticket-play-mode-tabs-v27-15 .bet-mode.active {
  background: var(--book-yellow);
  color: var(--book-blue-deep);
  box-shadow: 0 8px 16px rgba(244, 194, 43, 0.22);
}
.ticket-history-modal-v27-11.simplified-v27-15 .ticket-history-head {
  margin-bottom: 8px;
}
.ticket-history-note-v27-15 {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(16, 47, 91, 0.06);
  color: var(--book-muted);
  font-size: 12px;
  line-height: 1.35;
}
.ticket-history-list-v27-15 {
  gap: 10px;
}
.ticket-card-v27-15 {
  margin-bottom: 10px;
}
body[data-role="user"][data-user-theme="dark"] .ticket-play-mode-v27-15 {
  background: rgba(8, 19, 36, 0.92);
  border-color: rgba(255,255,255,0.10);
}
body[data-role="user"][data-user-theme="dark"] .ticket-play-mode-tabs-v27-15 {
  background: rgba(255,255,255,0.08);
}
body[data-role="user"][data-user-theme="dark"] .ticket-play-mode-tabs-v27-15 .bet-mode:not(.active) {
  color: #a8b4c7;
}
body[data-role="user"][data-user-theme="dark"] .ticket-history-note-v27-15 {
  background: rgba(255,255,255,0.07);
  color: #a8b4c7;
}
@media (max-width: 420px) {
  .ticket-play-mode-v27-15 {
    align-items: stretch;
    flex-direction: column;
  }
  .ticket-play-mode-tabs-v27-15 {
    min-width: 0;
    width: 100%;
  }
}

/* Sprint 27.16 — true compact game cards for Board Density */
.compact-event-meta-v27-16 {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .compact-event-meta-v27-16 {
  display: block;
  color: rgba(255,255,255,.72);
  font-size: 10px;
  font-weight: 850;
  line-height: 1.05;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
body[data-role="user"][data-board-density="compact"] .board-stats,
body[data-role="user"][data-board-density="compact"] .market-legend,
body[data-role="user"][data-board-density="compact"] .board-summary-strip {
  display: none !important;
}
body[data-role="user"][data-board-density="compact"] #events-board {
  gap: 0.38rem;
}
body[data-role="user"][data-board-density="compact"] .league-board {
  gap: 0.35rem;
}
body[data-role="user"][data-board-density="compact"] .league-header {
  min-height: 0;
  margin: 0;
  padding: 6px 9px;
  border-radius: 10px;
  font-size: 12px;
}
body[data-role="user"][data-board-density="compact"] .league-header div {
  gap: 1px;
}
body[data-role="user"][data-board-density="compact"] .league-header strong {
  font-size: 13px;
  line-height: 1;
}
body[data-role="user"][data-board-density="compact"] .league-header small {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .league-header > span {
  font-size: 10px;
  line-height: 1;
}
body[data-role="user"][data-board-density="compact"] .odds-event-card {
  margin-bottom: 6px;
  padding: 0;
  border-radius: 10px !important;
  box-shadow: 0 4px 10px rgba(22, 58, 104, .06);
}
body[data-role="user"][data-board-density="compact"] .odds-event-card + .odds-event-card {
  border-radius: 10px !important;
}
body[data-role="user"][data-board-density="compact"] .event-date-row {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .event-matchup {
  grid-template-columns: 24px 1fr;
  gap: 6px;
  padding: 5px 7px;
  min-height: 34px;
  font-size: 12px;
}
body[data-role="user"][data-board-density="compact"] .favorite-toggle {
  width: 24px;
  height: 24px;
  min-height: 24px;
  padding: 0;
  font-size: 13px;
}
body[data-role="user"][data-board-density="compact"] .matchup-main {
  display: grid;
  justify-content: start;
  gap: 1px;
  text-align: left;
}
body[data-role="user"][data-board-density="compact"] .matchup-main strong {
  max-width: 100%;
  font-size: 12px;
  line-height: 1.05;
}
body[data-role="user"][data-board-density="compact"] .matchup-main > span {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .matchup-tags {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .board-column-head,
body[data-role="user"][data-board-density="compact"] .odds-board-row,
body[data-role="user"][data-board-density="compact"] .draw-row,
body[data-role="user"][data-board-density="compact"] .draw-row-v2 {
  grid-template-columns: minmax(58px, .78fr) repeat(3, minmax(48px, 1fr));
}
body[data-role="user"][data-board-density="compact"] .board-column-head {
  position: static;
  padding: 0;
  min-height: 20px;
  font-size: 9px;
  line-height: 1;
}
body[data-role="user"][data-board-density="compact"] .board-column-head span {
  padding: 4px 3px;
}
body[data-role="user"][data-board-density="compact"] .board-column-head span:first-child {
  padding-left: 6px;
}
body[data-role="user"][data-board-density="compact"] .team-name {
  min-height: 34px;
  padding: 3px 5px;
  gap: 0;
}
body[data-role="user"][data-board-density="compact"] .team-name div {
  gap: 0;
}
body[data-role="user"][data-board-density="compact"] .team-name strong {
  font-size: 11px;
  line-height: 1.05;
}
body[data-role="user"][data-board-density="compact"] .team-name span,
body[data-role="user"][data-board-density="compact"] .team-name b {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .board-odd,
body[data-role="user"][data-board-density="compact"] .board-odd-empty {
  min-height: 34px;
  padding: 3px 4px;
  border-radius: 0;
  grid-template-rows: auto auto;
}
body[data-role="user"][data-board-density="compact"] .board-odd .odd-label,
body[data-role="user"][data-board-density="compact"] .board-odd-empty span {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .odd-line {
  min-height: 11px;
  font-size: 9px;
  line-height: 1;
}
body[data-role="user"][data-board-density="compact"] .odd-price,
body[data-role="user"][data-board-density="compact"] .board-odd-empty strong {
  font-size: 12px;
  line-height: 1;
}
body[data-role="user"][data-board-density="compact"] .board-odd .odd-state {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .board-odd.selected,
body[data-role="user"][data-board-density="compact"] .board-odd[aria-pressed="true"] {
  box-shadow: inset 0 -3px 0 #ffd21e, inset 0 0 0 1px rgba(18, 61, 125, .20);
}
body[data-role="user"][data-board-density="compact"] .board-odd.selected::after,
body[data-role="user"][data-board-density="compact"] .odds-board[data-board-mode="parlay"] .board-odd.selected::after {
  content: "";
  position: absolute;
  top: 4px;
  right: 4px;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  padding: 0;
  background: #ffd21e;
  opacity: 1;
}
body[data-role="user"][data-board-density="compact"] .draw-row-grid {
  min-height: 32px;
}
body[data-role="user"][data-board-density="compact"] .draw-row-grid .board-odd-empty {
  background: #f5f8fc;
}
body[data-role="user"][data-board-density="compact"] .betting-board-empty {
  padding: 14px;
}
body[data-role="user"][data-user-theme="dark"][data-board-density="compact"] .board-odd-empty,
body[data-role="user"][data-user-theme="dark"][data-board-density="compact"] .draw-row-grid .board-odd-empty {
  background: rgba(255,255,255,.04);
}
@media (max-width: 390px) {
  body[data-role="user"][data-board-density="compact"] .board-column-head,
  body[data-role="user"][data-board-density="compact"] .odds-board-row,
  body[data-role="user"][data-board-density="compact"] .draw-row,
  body[data-role="user"][data-board-density="compact"] .draw-row-v2 {
    grid-template-columns: minmax(52px, .72fr) repeat(3, minmax(44px, 1fr));
  }
  body[data-role="user"][data-board-density="compact"] .team-name strong {
    font-size: 10px;
  }
  body[data-role="user"][data-board-density="compact"] .odd-price,
  body[data-role="user"][data-board-density="compact"] .board-odd-empty strong {
    font-size: 11px;
  }
}

/* Sprint 28 — Prop Bet Foundation */
.prop-market-section-v28 {
  border-top: 1px solid rgba(35, 84, 145, .12);
  background: linear-gradient(180deg, rgba(247, 251, 255, .96), rgba(238, 246, 255, .92));
  padding: 8px;
  display: grid;
  gap: 7px;
}
.prop-market-head-v28 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 2px;
}
.prop-market-head-v28 span {
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: #123d7d;
}
.prop-market-head-v28 small {
  color: #6b7f99;
  font-size: 10px;
  font-weight: 850;
}
.prop-market-grid-v28 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}
.prop-odd-button {
  min-height: 56px;
  border-radius: 10px !important;
  align-content: center;
  gap: 2px;
  text-align: left;
  padding: 7px 9px !important;
}
.prop-odd-button .odd-label {
  color: #704b00;
}
.prop-odd-button .odd-line {
  min-height: 0;
  color: #1d324b;
  font-size: 12px;
  line-height: 1.15;
  white-space: normal;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.prop-odd-button .odd-price {
  color: #133d7c;
  justify-self: end;
}
.board-odd.market-prop .odd-price,
.board-odd[data-market-kind="prop"] .odd-price {
  color: #7a4e00;
}
body[data-role="user"][data-user-theme="dark"] .prop-market-section-v28 {
  background: rgba(255,255,255,.045);
  border-top-color: rgba(255,255,255,.08);
}
body[data-role="user"][data-user-theme="dark"] .prop-market-head-v28 span,
body[data-role="user"][data-user-theme="dark"] .prop-odd-button .odd-line {
  color: #f4f7ff;
}
body[data-role="user"][data-user-theme="dark"] .prop-market-head-v28 small {
  color: rgba(255,255,255,.62);
}
body[data-role="user"][data-board-density="compact"] .prop-market-section-v28 {
  padding: 4px 5px 5px;
  gap: 3px;
}
body[data-role="user"][data-board-density="compact"] .prop-market-head-v28 {
  padding: 0;
}
body[data-role="user"][data-board-density="compact"] .prop-market-head-v28 span {
  font-size: 9px;
}
body[data-role="user"][data-board-density="compact"] .prop-market-head-v28 small {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .prop-market-grid-v28 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 3px;
}
body[data-role="user"][data-board-density="compact"] .prop-odd-button {
  min-height: 30px;
  padding: 3px 5px !important;
  border-radius: 6px !important;
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto;
  column-gap: 5px;
}
body[data-role="user"][data-board-density="compact"] .prop-odd-button .odd-label {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .prop-odd-button .odd-line {
  font-size: 9px;
  line-height: 1.05;
  -webkit-line-clamp: 1;
}
body[data-role="user"][data-board-density="compact"] .prop-odd-button .odd-price {
  font-size: 11px;
  align-self: center;
}
@media (max-width: 390px) {
  .prop-market-grid-v28 { grid-template-columns: 1fr; }
  body[data-role="user"][data-board-density="compact"] .prop-market-grid-v28 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Sprint 28.1 — bottom-sheet nav clearance + left go-to-top shortcut */
body[data-role="user"] {
  --apex-nav-height-v28-1: 78px;
  --apex-nav-gap-v28-1: 12px;
  --apex-bottom-sheet-clearance-v28-1: calc(var(--apex-nav-height-v28-1) + var(--apex-nav-gap-v28-1) + env(safe-area-inset-bottom));
  --apex-floating-bottom-v28-1: calc(var(--apex-bottom-sheet-clearance-v28-1) + 10px);
  --apex-floating-side-v28-1: max(14px, calc((100vw - min(560px, calc(100vw - 16px))) / 2 + 8px));
}

body[data-role="user"] .mobile-bottom-nav {
  z-index: 120;
}

body[data-role="user"] .bet-slip-fab,
body[data-role="user"] .user-scroll-top-v28-1 {
  position: fixed !important;
  bottom: var(--apex-floating-bottom-v28-1) !important;
  z-index: 74;
}

body[data-role="user"] .bet-slip-fab {
  right: var(--apex-floating-side-v28-1) !important;
  left: auto !important;
  margin-left: 0 !important;
}

body[data-role="user"] .user-scroll-top-v28-1 {
  left: var(--apex-floating-side-v28-1) !important;
  right: auto !important;
  display: grid;
  place-items: center;
}

body[data-role="user"] .mobile-bet-slip {
  bottom: var(--apex-bottom-sheet-clearance-v28-1) !important;
  max-height: min(72dvh, calc(100dvh - var(--apex-bottom-sheet-clearance-v28-1) - 22px)) !important;
}

body[data-role="user"] .account-panel-backdrop,
body[data-role="user"] .ticket-history-backdrop-v27-11,
body[data-role="user"] .user-settings-backdrop-v27-10,
body[data-role="user"] .user-help-backdrop-v27-8,
body[data-role="user"] .event-detail-backdrop-v27-9 {
  z-index: 90;
  padding: 14px 14px var(--apex-bottom-sheet-clearance-v28-1) !important;
}

body[data-role="user"] .account-panel-v27-4,
body[data-role="user"] .ticket-history-modal-v27-11,
body[data-role="user"] .user-settings-panel-v27-10,
body[data-role="user"] .user-help-panel-v27-8,
body[data-role="user"] .event-detail-panel-v27-9 {
  max-height: min(74dvh, calc(100dvh - var(--apex-bottom-sheet-clearance-v28-1) - 24px)) !important;
  margin-bottom: 0 !important;
}

body[data-role="user"] .ticket-history-modal-v27-11,
body[data-role="user"] .user-settings-panel-v27-10,
body[data-role="user"] .user-help-panel-v27-8,
body[data-role="user"] .event-detail-panel-v27-9 {
  border-radius: 24px 24px 18px 18px;
}

body[data-role="user"].bet-slip-open .bet-slip-fab,
body[data-role="user"].ticket-history-open .bet-slip-fab,
body[data-role="user"].account-panel-open .bet-slip-fab,
body[data-role="user"].user-settings-open .bet-slip-fab,
body[data-role="user"].user-help-open .bet-slip-fab,
body[data-role="user"].event-detail-open .bet-slip-fab,
body[data-role="user"].confirm-bet-open-v27-13 .bet-slip-fab,
body[data-role="user"].receipt-open-v27-13 .bet-slip-fab,
body[data-role="user"].bet-slip-open .user-scroll-top-v28-1,
body[data-role="user"].ticket-history-open .user-scroll-top-v28-1,
body[data-role="user"].account-panel-open .user-scroll-top-v28-1,
body[data-role="user"].user-settings-open .user-scroll-top-v28-1,
body[data-role="user"].user-help-open .user-scroll-top-v28-1,
body[data-role="user"].event-detail-open .user-scroll-top-v28-1,
body[data-role="user"].confirm-bet-open-v27-13 .user-scroll-top-v28-1,
body[data-role="user"].receipt-open-v27-13 .user-scroll-top-v28-1 {
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px) scale(.96);
}

body[data-role="user"] .modal-backdrop.active,
body[data-role="user"] .receipt-backdrop.active {
  z-index: 140;
}

@media (max-width: 420px) {
  body[data-role="user"] {
    --apex-nav-height-v28-1: 74px;
    --apex-floating-side-v28-1: 12px;
  }
  body[data-role="user"] .bet-slip-fab {
    max-width: 42vw;
    overflow: hidden;
    white-space: nowrap;
  }
}


/* Sprint 28.2 — Sports lobby available game counts */
body[data-role="user"] .game-count-badge-v28-2 {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 34px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(14, 32, 66, 0.08);
  border: 1px solid rgba(14, 32, 66, 0.12);
  color: rgba(14, 32, 66, 0.74);
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

body[data-role="user"] .book-pill.active .game-count-badge-v28-2,
body[data-role="user"] .book-pill.featured .game-count-badge-v28-2 {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.2);
  color: inherit;
}

body[data-role="user"] .book-pill-list .book-pill .game-count-badge-v28-2 {
  margin-left: auto;
}

body[data-role="user"] .game-count-badge-v28-2 span {
  font-size: 10px;
}

body[data-role="user"][data-user-theme="dark"] .game-count-badge-v28-2 {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.74);
}

body[data-role="user"][data-user-theme="dark"] .book-pill.active .game-count-badge-v28-2,
body[data-role="user"][data-user-theme="dark"] .book-pill.featured .game-count-badge-v28-2 {
  background: rgba(255, 212, 77, 0.14);
  border-color: rgba(255, 212, 77, 0.26);
  color: #ffd44d;
}

@media (max-width: 390px) {
  body[data-role="user"] .game-count-badge-v28-2 {
    min-width: 30px;
    padding: 3px 6px;
    font-size: 10px;
  }
}

/* Sprint 28.3 — Ticket builder height + account panel refinements */
body[data-role="user"] {
  --apex-ticket-builder-clearance-v28-3: calc(var(--apex-nav-height-v28-1) + 4px + env(safe-area-inset-bottom));
}

body[data-role="user"] .mobile-bet-slip {
  bottom: var(--apex-ticket-builder-clearance-v28-3) !important;
  max-height: min(84dvh, calc(100dvh - var(--apex-ticket-builder-clearance-v28-3) - 10px)) !important;
}

body[data-role="user"] .mobile-bet-slip.drawer-open {
  border-radius: 24px 24px 14px 14px;
}

body[data-role="user"] .wallet-quick-facts-v27-4 {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

body[data-role="user"] .wallet-quick-facts-v27-4 span {
  min-height: 78px;
  align-content: center;
}

body[data-role="user"] .profile-info-grid-v28-3 {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

@media (max-width: 1024px) {
  body[data-role="user"] .wallet-quick-facts-v27-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 420px) {
  body[data-role="user"] .wallet-quick-facts-v27-4 {
    gap: 7px;
  }
  body[data-role="user"] .wallet-quick-facts-v27-4 span {
    min-height: 70px;
    padding: 9px;
  }
  body[data-role="user"] .wallet-quick-facts-v27-4 strong {
    font-size: 13px;
  }
  body[data-role="user"] .profile-info-grid-v28-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

/* Sprint 28.4 — profile grid, smart Max stake, and tighter compact board */
body[data-role="user"] .profile-info-grid-v28-4 {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}
body[data-role="user"] .profile-info-grid-v28-4 span {
  min-height: 76px;
  align-content: center;
}
body[data-role="user"] .board-odd.market-moneyline.no-odd-line {
  grid-template-rows: auto;
  align-content: center;
}
body[data-role="user"] .board-odd.market-moneyline.no-odd-line .odd-price {
  margin-top: 0;
}
body[data-role="user"] .board-odd.market-moneyline .odd-line {
  display: none !important;
}
body[data-role="user"] .slip-head-actions .close-slip,
body[data-role="user"] #close-bet-slip-drawer {
  display: none !important;
}

body[data-role="user"][data-board-density="compact"] #events-board {
  gap: 0.24rem;
}
body[data-role="user"][data-board-density="compact"] .league-board {
  gap: 0.22rem;
}
body[data-role="user"][data-board-density="compact"] .league-header {
  padding: 4px 7px;
  border-radius: 8px;
}
body[data-role="user"][data-board-density="compact"] .league-header strong {
  font-size: 12px;
}
body[data-role="user"][data-board-density="compact"] .league-header > span {
  font-size: 9px;
}
body[data-role="user"][data-board-density="compact"] .odds-event-card {
  margin-bottom: 3px;
  border-radius: 8px !important;
  overflow: hidden;
}
body[data-role="user"][data-board-density="compact"] .event-matchup {
  min-height: 28px;
  padding: 3px 5px;
  grid-template-columns: 22px 1fr;
}
body[data-role="user"][data-board-density="compact"] .favorite-toggle {
  width: 21px;
  height: 21px;
  min-height: 21px;
  font-size: 12px;
}
body[data-role="user"][data-board-density="compact"] .matchup-main strong {
  font-size: 11px;
  line-height: 1;
}
body[data-role="user"][data-board-density="compact"] .compact-event-meta-v27-16 {
  font-size: 9px;
}
body[data-role="user"][data-board-density="compact"] .board-column-head {
  display: none;
}
body[data-role="user"][data-board-density="compact"] .odds-board-row,
body[data-role="user"][data-board-density="compact"] .draw-row,
body[data-role="user"][data-board-density="compact"] .draw-row-v2 {
  grid-template-columns: minmax(50px, .66fr) repeat(3, minmax(42px, 1fr));
}
body[data-role="user"][data-board-density="compact"] .team-name {
  min-height: 28px;
  padding: 2px 4px;
}
body[data-role="user"][data-board-density="compact"] .team-name strong {
  font-size: 10px;
  line-height: .98;
}
body[data-role="user"][data-board-density="compact"] .board-odd,
body[data-role="user"][data-board-density="compact"] .board-odd-empty {
  min-height: 28px;
  padding: 2px 3px;
}
body[data-role="user"][data-board-density="compact"] .odd-line {
  min-height: 9px;
  font-size: 8px;
}
body[data-role="user"][data-board-density="compact"] .odd-price,
body[data-role="user"][data-board-density="compact"] .board-odd-empty strong {
  font-size: 11px;
}
body[data-role="user"][data-board-density="compact"] .prop-market-section-v28 {
  padding: 3px 4px 5px;
}
body[data-role="user"][data-board-density="compact"] .prop-market-head-v28 {
  margin-bottom: 3px;
}
body[data-role="user"][data-board-density="compact"] .prop-odd-button {
  min-height: 30px;
  padding: 3px 4px;
}
body[data-role="user"][data-board-density="compact"] .prop-odd-button .odd-line {
  max-height: 18px;
  -webkit-line-clamp: 1;
}
@media (max-width: 390px) {
  body[data-role="user"][data-board-density="compact"] .odds-board-row,
  body[data-role="user"][data-board-density="compact"] .draw-row,
  body[data-role="user"][data-board-density="compact"] .draw-row-v2 {
    grid-template-columns: minmax(46px, .62fr) repeat(3, minmax(39px, 1fr));
  }
  body[data-role="user"] .profile-info-grid-v28-4 span {
    min-height: 68px;
  }
}

/* Sprint 28.5 — Sports-page header behavior + floating help/profile entry */
body[data-role="user"][data-user-page="lobby"] .mobile-book-header.user-layout-v27 {
  transform: translateY(0) !important;
  opacity: 1 !important;
}

body[data-role="user"][data-user-page="lobby"] .mobile-book-header.user-layout-v27.is-hidden-on-scroll-v27-12 {
  transform: translateY(0) !important;
  opacity: 1 !important;
}

body[data-role="user"][data-user-page="lobby"] .mobile-book-header.user-layout-v27 .book-search-row-v27-12 {
  display: none !important;
}

body[data-role="user"] .user-floating-help-v28-5 {
  font-weight: 950;
  font-size: 18px;
  color: #19457f;
  background: linear-gradient(180deg, #ffffff, #edf5ff);
  box-shadow: 0 18px 38px rgba(16, 55, 105, .24), inset 0 0 0 1px rgba(28, 85, 150, .12);
}

body[data-role="user"] .avatar-circle-v28-5 {
  font-size: 16px;
  line-height: 1;
}

body[data-role="user"][data-user-theme="dark"] .user-floating-help-v28-5,
body[data-role="user"][data-user-theme="dark"] .avatar-circle-v28-5 {
  background: rgba(11, 28, 52, .94);
  color: #e9f2ff;
  box-shadow: inset 0 0 0 1px rgba(130, 180, 255, .18), 0 14px 30px rgba(0, 0, 0, .34);
}

body[data-role="user"][data-user-page="lobby"].user-overlay-open-v27-13 .mobile-book-header.user-layout-v27,
body[data-role="user"][data-user-page="lobby"].bet-slip-open .mobile-book-header.user-layout-v27,
body[data-role="user"][data-user-page="lobby"].ticket-history-open .mobile-book-header.user-layout-v27,
body[data-role="user"][data-user-page="lobby"].account-panel-open .mobile-book-header.user-layout-v27,
body[data-role="user"][data-user-page="lobby"].user-settings-open .mobile-book-header.user-layout-v27,
body[data-role="user"][data-user-page="lobby"].user-help-open .mobile-book-header.user-layout-v27,
body[data-role="user"][data-user-page="lobby"].event-detail-open .mobile-book-header.user-layout-v27,
body[data-role="user"][data-user-page="lobby"].confirm-bet-open-v27-13 .mobile-book-header.user-layout-v27,
body[data-role="user"][data-user-page="lobby"].receipt-open-v27-13 .mobile-book-header.user-layout-v27 {
  transform: translateY(calc(-100% - 12px)) !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Sprint 39 — UX/UI Completion v1 for Admin, Handler, and User */
.sprint39-login-hints {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.6rem;
  margin-top: 1rem;
}

.sprint39-login-hints .role-guide-card-v39 {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
  padding: 0.75rem;
  background: rgba(255, 255, 255, 0.08);
  color: inherit;
  text-align: left;
}

.sprint39-login-hints strong,
.sprint39-login-hints small {
  display: block;
}

.sprint39-login-hints small {
  margin-top: 0.2rem;
  font-size: 0.72rem;
  opacity: 0.78;
}

.sprint39-uat-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: 1rem 0;
  padding: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(19, 28, 54, 0.94), rgba(27, 44, 82, 0.82));
  color: #fff;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.16);
}

.sprint39-uat-strip h1 {
  margin: 0.15rem 0;
  font-size: clamp(1.35rem, 2.4vw, 2rem);
}

.sprint39-uat-strip p {
  margin: 0;
  max-width: 760px;
  opacity: 0.86;
}

.role-api-state-v39,
.status-chip-v39 {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.25rem;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
}

.admin-command-center-v39,
.handler-command-center-v39 {
  display: grid;
  grid-template-columns: 1fr 1.2fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.admin-command-center-v39 .panel,
.handler-command-center-v39 .panel {
  min-height: 100%;
}

.readiness-list-v39,
.guardrail-list-v39,
.workbench-body-v39,
.handler-selected-user-v39,
.handler-cash-feedback-v39,
.cash-report-list-v39 {
  display: grid;
  gap: 0.75rem;
}

.readiness-item-v39,
.guardrail-list-v39 > div,
.workbench-row-v39,
.cash-row-v39 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.72rem 0.8rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  background: rgba(248, 250, 252, 0.78);
}

.readiness-item-v39,
.cash-row-v39 {
  align-items: flex-start;
}

.readiness-item-v39 strong,
.readiness-item-v39 span,
.cash-row-v39 strong,
.cash-row-v39 small {
  display: block;
}

.readiness-item-v39 span,
.workbench-note-v39,
.cash-row-v39 small,
.handler-selected-user-v39 span,
.handler-selected-user-v39 small,
.handler-cash-feedback-v39 span {
  color: #64748b;
  font-size: 0.82rem;
}

.workbench-row-v39 span,
.guardrail-list-v39 span {
  color: #64748b;
  text-transform: capitalize;
}

.workbench-row-v39 strong {
  max-width: 70%;
  text-align: right;
  overflow-wrap: anywhere;
}

.handler-selected-user-v39,
.handler-cash-feedback-v39 {
  padding: 0.8rem;
  border-radius: 16px;
  background: rgba(248, 250, 252, 0.86);
}

.handler-selected-user-v39 strong,
.handler-cash-feedback-v39 strong {
  display: block;
  margin-bottom: 0.25rem;
}

.task-steps-v39 {
  margin: 0;
  padding-left: 1.25rem;
  color: #334155;
}

.task-steps-v39 li + li {
  margin-top: 0.45rem;
}

.user-uat-console-v39 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 0.75rem 0;
}

.user-uat-console-v39 article {
  display: grid;
  gap: 0.25rem;
  padding: 0.8rem 0.9rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
}

.user-uat-console-v39 span {
  color: #64748b;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.user-uat-console-v39 strong {
  font-size: 0.92rem;
}

.user-state-guide-v39 {
  display: flex;
  gap: 0.45rem;
  margin-bottom: 0.85rem;
  overflow-x: auto;
  padding-bottom: 0.1rem;
}

.user-state-guide-v39 span {
  flex: 0 0 auto;
  padding: 0.42rem 0.62rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.06);
  color: #334155;
  font-size: 0.73rem;
  font-weight: 800;
}

.tone-loading { color: #0369a1; }
.tone-success { color: #047857; }
.tone-warning { color: #b45309; }
.tone-error,
.tone-insufficient_balance { color: #b91c1c; }
.tone-empty,
.tone-info { color: #64748b; }

.handler-cash-feedback-v39.tone-loading {
  background: rgba(224, 242, 254, 0.68);
}

.handler-cash-feedback-v39.tone-success {
  background: rgba(220, 252, 231, 0.68);
}

.handler-cash-feedback-v39.tone-error {
  background: rgba(254, 226, 226, 0.74);
}

body[data-shell="login"] .sprint39-uat-strip,
body[data-shell="password"] .sprint39-uat-strip {
  display: none;
}

@media (max-width: 980px) {
  .admin-command-center-v39,
  .handler-command-center-v39 {
    grid-template-columns: 1fr;
  }

  .sprint39-uat-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .role-api-state-v39 {
    white-space: normal;
  }
}

@media (max-width: 620px) {
  .sprint39-login-hints,
  .user-uat-console-v39 {
    grid-template-columns: 1fr;
  }

  .workbench-row-v39,
  .guardrail-list-v39 > div,
  .cash-row-v39 {
    align-items: flex-start;
    flex-direction: column;
  }

  .workbench-row-v39 strong {
    max-width: 100%;
    text-align: left;
  }
}
