﻿/* ==========================================================================
   TIGER TIME SPORTS LOUNGE // THEME LAYER
   - The Tiger Sheet: sovereign bearer certificate (zero radii, mitered frame)
   - Ambient artwork in negative space (watermark opacity never above 0.20)
     IMG_4357 (head-on gaze behind bars)  -> Tiger Vision dial well
     IMG_4362 (impasto stalking tiger)    -> Tiger Sheet ledger + SGP chamber
   ========================================================================== */

:root {
  --frame-gold: #d4af37;
  --obsidian: rgba(18, 22, 28, 0.88);
  --rivet: radial-gradient(circle at 42% 35%, #fff1ae 0 12%, #d4af37 28%, #79551e 52%, #33220f 65%, transparent 74%);
  --corner-rivets: var(--rivet) left 2px top 2px / 5px 5px no-repeat,
    var(--rivet) right 2px top 2px / 5px 5px no-repeat,
    var(--rivet) left 2px bottom 2px / 5px 5px no-repeat,
    var(--rivet) right 2px bottom 2px / 5px 5px no-repeat;
  --engraving: repeating-radial-gradient(ellipse at 30% 50%, transparent 0 8px, #d4af37 9px, transparent 10px),
    repeating-radial-gradient(ellipse at 70% 50%, transparent 0 9px, #f4d98d 10px, transparent 11px);
}

/* Keep engraving below content, independent of scroll position and hit testing. */
.theme-loaded .admin-shell,
.theme-loaded .workspace-deck {
  position: relative;
  isolation: isolate;
}
.theme-loaded body::after,
.theme-loaded .admin-shell::before,
.theme-loaded .workspace-deck::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: none;
  background-size: 180px 100px, 180px 100px, cover;
  background-position: center, center, center 42%;
  opacity: 0.09;
  mix-blend-mode: screen;
}
.theme-loaded body::after { position: fixed; z-index: 1; }
.theme-loaded .workspace-deck { background-color: transparent; background-image: url('../assets/IMG_4494.png'); background-size: cover; background-position: center 22%; background-attachment: fixed; }

/* Rivets are background layers: card pseudo-elements remain available for coachlines. */
.theme-loaded #app-root :is(.coachline-card, .radar-card, .prop-card, .sgp-slot-card, .zoetrope-leg-card, .zoe-float-card, .intel-panel, .alt-ladder-panel, .prop-ladder-panel, .zoetrope-chamber, .zoetrope-floating-deck, .docket-ticket-shell, .chron-drawer, .filter-bar, .cmd-header, .folder-tab-rail, .telemetry-footer, .tiger-sheet) {
  border: 3px double var(--frame-gold);
  border-image: none;
  background: var(--corner-rivets), var(--obsidian);
  box-shadow: inset 1px 1px 0 #ffe6a066, inset -1px -1px 0 #604419, 0 2px 8px #0008;
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
.theme-loaded #app-root :is(.docket-state-blue, .docket-state-green, .coachline-watchlist, .zoetrope-leg-card.is-watchlist, .coachline-lock) {
  box-shadow: inset 0 0 0 1px var(--state-edge), inset 0 0 14px color-mix(in srgb, var(--state-edge) 18%, transparent);
}
.docket-state-blue { --state-edge: var(--sapphire-blue); }
.docket-state-green { --state-edge: var(--neon-profit); }
.coachline-watchlist, .zoetrope-leg-card.is-watchlist { --state-edge: var(--cyan-watchlist); }
.coachline-lock { --state-edge: var(--tiger-orange); }

/* ---------- TIGER VISION DIAL WELL: IMG_4357 ---------- */
.zoetrope-wheel-wrap::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: url("../assets/IMG_4357.jpeg");
  background-size: cover;
  background-position: 74% 38%; /* centers the tiger's face behind the hub */
  background-repeat: no-repeat;
  opacity: 0.11;
  mix-blend-mode: screen;
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 28%, transparent 72%);
  mask-image: radial-gradient(circle at 50% 50%, #000 28%, transparent 72%);
}

.zoetrope-wheel-wrap::after {
  /* deep chiaroscuro vignette in #070b19 */
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(circle at 50% 50%, transparent 38%, rgba(7, 11, 25, 0.82) 78%);
}

.zoetrope-wheel-wrap .zoetrope-svg {
  position: relative;
  z-index: 1;
}

/* The chamber engraving replaces only the top coachline, not the rivets. */
.theme-loaded .sgp-layout > .coachline-card { isolation: isolate; }
.theme-loaded .sgp-layout > .coachline-card::before {
  inset: 0;
  height: auto;
  z-index: -1;
  background: var(--engraving), url('../assets/IMG_4362.jpeg') center 42% / cover no-repeat;
  opacity: 0.08;
  mix-blend-mode: screen;
}

/* ---------- THE TIGER SHEET ---------- */
.tiger-sheet-actions {
  border-radius: 0;
}

.sheet-title-cluster {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.sheet-sub {
  font-size: 11px;
  color: var(--text-secondary);
  letter-spacing: 0.06em;
}

.sheet-action-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.sheet-download-btn {
  font-size: 12px;
  padding: 8px 14px;
  border-radius: 0;
  box-shadow: 0 0 0 1px #d4af37, 0 4px 18px rgba(255, 136, 0, 0.4), inset 0 1px 0 rgba(255, 240, 210, 0.55);
}

.sheet-fmt-group {
  display: inline-flex;
  border: 1px solid #d4af37;
}

.sheet-fmt {
  background: #0b1020;
  color: var(--tiger-cream);
  border: none;
  border-right: 1px solid rgba(212, 175, 55, 0.5);
  padding: 7px 9px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.06em;
  cursor: pointer;
  border-radius: 0;
}

.sheet-fmt:last-child {
  border-right: none;
}

.sheet-fmt.is-active {
  background: linear-gradient(135deg, #ffb347 0%, #ff8800 50%, #d46b08 100%);
  color: #070b19;
}

.tiger-sheet-wrap {
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  overflow: hidden;
}

.tiger-sheet {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  background:
    radial-gradient(ellipse 70% 60% at 50% 42%, #0e1530 0%, #070b19 72%),
    #070b19;
  box-shadow: inset 0 0 70px rgba(0, 0, 0, 0.75), 0 10px 40px rgba(0, 0, 0, 0.6);
}

/* Sovereign certificate discipline: zero rounded corners anywhere on the sheet */
.tiger-sheet,
.tiger-sheet * {
  border-radius: 0 !important;
}

.bond-frame-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

.tiger-sheet-watermark {
  position: absolute;
  inset: 10% 8%;
  z-index: 0;
  pointer-events: none;
  background-image: url("../assets/IMG_4362.jpeg");
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.10;
  mix-blend-mode: screen;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 38%, transparent 76%);
  mask-image: radial-gradient(ellipse at center, #000 38%, transparent 76%);
}

.tiger-sheet-inner {
  position: relative;
  z-index: 2;
  height: 100%;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 74px; /* replaced at runtime with the exact frame inset */
}

.sheet-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  flex-wrap: wrap;
  padding-bottom: 10px;
  border-bottom: 1.5px solid #d4af37;
  box-shadow: 0 4px 0 -3px #ff8800;
}

.sheet-house {
  font-family: var(--font-serif);
  font-size: clamp(18px, 2vw, 28px);
  letter-spacing: 0.08em;
}

.sheet-house-sub {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.16em;
  color: #d4af37;
  margin-top: 4px;
}

.sheet-serial {
  text-align: right;
  font-family: var(--font-mono);
}

.sheet-serial-no {
  font-size: 14px;
  font-weight: 700;
  color: var(--tiger-orange);
}

.sheet-serial-issued {
  font-size: 10px;
  color: var(--text-muted);
}

.tiger-sheet .banknote-table td {
  white-space: normal;
  word-break: break-word;
  vertical-align: top;
}

.tiger-sheet .banknote-table th {
  border-bottom: 0.75px solid #d4af37;
}

.sheet-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.sheet-cell {
  padding: 9px 11px;
  background: rgba(8, 11, 24, 0.86);
  border: 0.75px solid #d4af37;
  outline: 0.5px solid rgba(255, 136, 0, 0.6);
  outline-offset: -4px;
}

.sheet-cell-value {
  font-size: 18px;
  margin-top: 3px;
}

.sheet-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.sheet-microprint {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.16em;
  color: #d4af37;
  line-height: 1.6;
}

.sheet-microprint span {
  display: block;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  font-family: var(--font-sans);
  font-size: 10.5px;
}

.sheet-seal {
  flex: 0 0 auto;
  width: 104px;
  height: 104px;
  padding: 0;
  background: none;
  border: none;
  cursor: pointer;
  filter: drop-shadow(0 0 10px rgba(255, 136, 0, 0.35));
  transition: transform 0.12s ease, filter 0.12s ease;
}

.sheet-seal:hover:not(:disabled) {
  transform: scale(1.05);
  filter: drop-shadow(0 0 16px rgba(255, 136, 0, 0.6));
}

.sheet-seal:focus-visible {
  outline: 1px dashed #d4af37;
  outline-offset: 2px;
}

.sheet-seal:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.sheet-seal svg {
  width: 100%;
  height: 100%;
  display: block;
}

@media (max-width: 960px) {
  .sheet-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .sheet-download-btn {
    width: 100%;
  }
  .sheet-seal {
    width: 78px;
    height: 78px;
  }
}

@media print {
  .tiger-sheet {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    background: #070b19 !important;
    height: auto !important;
  }
  .tiger-sheet-inner {
    height: auto !important;
    overflow: visible !important;
  }
}

/* ==========================================================================
   SCRAMBLED TIGER-FACE MOSAIC (hub of the Tiger Vision bezel)
   Tiles sit displaced + rotated at rest; they snap home while spinning and on
   lock-in, then a fresh scramble is dealt for the next spin.
   ========================================================================== */
.zoe-face {
  opacity: 0.4;
  filter: grayscale(0.65) contrast(1.1);
  transition: opacity 0.45s ease, filter 0.45s ease;
}

.zoe-tile {
  transform-box: view-box; /* per-tile origin (tile centre) is set inline */
  transform: translate(var(--dx), var(--dy)) rotate(var(--rot));
  transition: transform 0.72s cubic-bezier(0.2, 0.9, 0.25, 1.15) var(--d);
}

.zoetrope-svg.is-spinning .zoe-tile,
.zoetrope-svg.is-revealed .zoe-tile {
  transform: none;
}

.zoetrope-svg.is-spinning .zoe-face,
.zoetrope-svg.is-revealed .zoe-face {
  opacity: 1;
  filter: none;
}

.zoetrope-svg.is-revealed .zoe-face {
  filter: drop-shadow(0 0 10px rgba(255, 136, 0, 0.85)) saturate(1.15);
}

.zoe-hub-text {
  transition: opacity 0.3s ease;
}

.zoetrope-svg.is-spinning .zoe-hub-text,
.zoetrope-svg.is-revealed .zoe-hub-text {
  opacity: 0;
}

.zoe-locked-flash {
  animation: lockedFlash 0.65s ease-in-out infinite alternate;
}

@keyframes lockedFlash {
  from { opacity: 0.55; }
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .zoe-tile { transition: none; }
  .zoe-locked-flash { animation: none; }
}

/* Same-Game Strobe Parlay banner */
.sgp-banner {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 8px 10px;
  border: 1px solid rgba(255, 136, 0, 0.6);
  background: radial-gradient(ellipse at 10% 0%, rgba(255, 150, 40, 0.18), rgba(8, 10, 20, 0.9) 70%);
  font-size: 11px;
  flex: 0 0 auto;
}

.sgp-banner strong {
  font-size: 13px;
  color: #f6efe2;
}

/* ==========================================================================
   MONEYLINE (BOTH TEAMS) ON RADAR CARDS
   ========================================================================== */
.ml-box {
  cursor: default;
}

.ml-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px;
}

.ml-side {
  padding: 2px 4px;
  background: rgba(255, 136, 0, 0.08);
  border: 1px solid rgba(255, 136, 0, 0.3);
  color: var(--text-primary);
  font-size: 10.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ml-side:hover {
  border-color: var(--tiger-orange);
  background: rgba(255, 136, 0, 0.18);
}

/* ==========================================================================
   MARKET INTEL DESK
   ========================================================================== */
.intel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 10px;
  align-content: start;
}

.intel-panel {
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.intel-wide {
  grid-column: span 2;
}

.intel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 6px;
}

.intel-title {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--tiger-cream);
  text-transform: uppercase;
}

.intel-muted {
  font-size: 10px;
  color: var(--text-muted);
}

.intel-stat-line {
  font-size: 11px;
  color: var(--text-secondary);
}

.intel-mode {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.intel-chart {
  width: 100%;
  height: auto;
  display: block;
}

.intel-wide .intel-chart {
  max-height: 210px;
}

.src-pill {
  font-size: 8.5px;
  font-weight: 800;
  letter-spacing: 0.1em;
  padding: 2px 6px;
  border: 1px dashed rgba(165, 180, 212, 0.5);
  color: var(--text-muted);
  white-space: nowrap;
}

.src-pill.is-feed {
  border-style: solid;
  border-color: var(--neon-profit);
  color: var(--neon-profit);
}

.hbar {
  flex: 1 1 auto;
  height: 7px;
  min-width: 36px;
  position: relative;
  background: rgba(255, 255, 255, 0.06);
}

.hbar > span {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  background: linear-gradient(90deg, #d46b08, #ff8800, #ffb347);
}

.hbar.is-public > span {
  background: linear-gradient(90deg, #4b608e, #7c96cc);
}

.hbar.is-volume > span {
  background: linear-gradient(90deg, #0b6f78, #00f0ff);
}

.dual-bar {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 60px;
}

.dual-bar .hbar {
  height: 5px;
}

.legend-row {
  display: flex;
  gap: 10px;
  font-size: 9.5px;
  color: var(--text-muted);
}

.lg-pub { color: #7c96cc; }
.lg-hdl { color: #ff8800; }

.lb-row,
.book-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  padding: 2px 3px;
}

.lb-row {
  cursor: pointer;
}

.lb-row:hover {
  background: rgba(255, 136, 0, 0.06);
}

.lb-row.is-current {
  background: rgba(255, 136, 0, 0.1);
  outline: 1px solid rgba(255, 136, 0, 0.4);
}

.lb-name {
  flex: 0 0 120px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lb-name small {
  color: var(--text-muted);
}

.vol-amt {
  flex: 0 0 62px;
  text-align: right;
}

.steam-dot {
  width: 7px;
  height: 7px;
  background: #ff8800;
  transform: rotate(45deg);
  box-shadow: 0 0 8px #ff8800;
  animation: pulseDot 1.4s infinite ease-in-out;
}

.move-chips,
.prop-books {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.chip-move,
.prop-book {
  font-size: 9.5px;
  padding: 2px 6px;
  border: 1px solid rgba(0, 240, 255, 0.4);
  color: var(--text-secondary);
}

.chip-move.is-steam {
  border-color: #ff8800;
  color: #ffb347;
}

.prop-book.is-best {
  border-color: var(--neon-profit);
  color: var(--neon-profit);
}

.price-board-wrap {
  overflow-x: auto;
}

.price-board {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

.price-board th {
  text-align: left;
  padding: 4px 5px;
  font-size: 9.5px;
  letter-spacing: 0.06em;
  color: var(--tiger-cream);
  border-bottom: 1px solid rgba(255, 136, 0, 0.4);
  white-space: nowrap;
}

.price-board td {
  padding: 4px 5px;
  border-bottom: 1px solid rgba(140, 165, 220, 0.12);
  white-space: nowrap;
  cursor: pointer;
}

.price-board td:hover {
  background: rgba(255, 136, 0, 0.1);
}

.price-board td.is-best {
  background: rgba(0, 255, 136, 0.1);
  outline: 1px solid rgba(0, 255, 136, 0.55);
  outline-offset: -1px;
}

.price-board td.book-cell {
  cursor: default;
  font-weight: 700;
}

.price-board td.book-cell:hover {
  background: none;
}

.price-board .fair-row td {
  border-top: 1px solid rgba(255, 210, 125, 0.4);
}

.cohort {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.cohort-head {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  font-weight: 700;
}

.split-bar {
  display: flex;
  height: 16px;
  font-size: 9.5px;
  font-weight: 800;
}

.split-bar span {
  display: flex;
  align-items: center;
  padding: 0 5px;
  white-space: nowrap;
  overflow: hidden;
}

.split-bar .fav {
  background: linear-gradient(90deg, #d46b08, #ff8800);
  color: #070b19;
}

.split-bar .dog {
  background: linear-gradient(90deg, #2a3a63, #4b608e);
  color: #eef2ff;
  justify-content: flex-end;
}

.ml-row {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) auto minmax(0, 1.4fr) auto auto;
  gap: 8px;
  align-items: center;
  padding: 5px 0;
  border-bottom: 1px solid rgba(140, 165, 220, 0.12);
}

.ml-team {
  display: flex;
  flex-direction: column;
  font-size: 12px;
  min-width: 0;
}

.ml-price {
  font-size: 16px;
}

.ml-probs {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ml-probs .hbar {
  height: 5px;
}

.prop-stats {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 6px;
  padding: 6px;
  background: rgba(4, 7, 17, 0.7);
  border: 0.5px solid rgba(255, 210, 125, 0.3);
}

@media (max-width: 960px) {
  .intel-wide {
    grid-column: span 1;
  }
  .prop-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .ml-row {
    grid-template-columns: 1fr auto auto;
  }
  .ml-probs {
    grid-column: 1 / -1;
  }
}

/* === FINAL CASCADE LOCK: EXCLUSIVE .tiger-sheet ENGRAVING + APPLE LIQUID GLASS === */


.theme-loaded #app-root :is(
  .coachline-card, .radar-card, .prop-card, .sgp-slot-card, .zoetrope-leg-card,
  .zoe-float-card, .intel-panel, .alt-ladder-panel, .prop-ladder-panel,
  .zoetrope-chamber, .zoetrope-floating-deck, .docket-ticket-shell, .chron-drawer
) {
  background: rgba(12, 15, 22, 0.64) !important;
  -webkit-backdrop-filter: blur(18px) saturate(160%) !important;
  backdrop-filter: blur(18px) saturate(160%) !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 22px 46px rgba(0, 0, 0, 0.82) !important;
}

.cmd-header h1 {
  font-family: "Playfair Display", Georgia, serif !important;
  font-style: italic !important;
  transform: skewX(-7deg);
  display: inline-block;
}

/* === EXACT PER-TAB SAMPLE DOSSIER PLATES (IMG_4496 EXCLUDED FOR COMMERCIAL) === */
body[data-tts-tab="vision"] .workspace-deck { background-image: url('../assets/IMG_4396.png') !important; background-position: center 18% !important; }
body[data-tts-tab="props"] .workspace-deck { background-image: url('../assets/IMG_4460.png') !important; background-position: center 22% !important; }
body[data-tts-tab="radar"] .workspace-deck,
body[data-tts-tab="intel"] .workspace-deck { background-image: url('../assets/IMG_4494.png') !important; background-position: center 22% !important; }
body[data-tts-tab="chat"] .workspace-deck,
body[data-tts-tab="chronicle"] .workspace-deck { background-image: url('../assets/IMG_4445.png') !important; background-position: center 22% !important; }
