/* ════════════════════════════════════════════════════════════════════════
   FUNDING SCREENER · v2 — большая таблица с горизонтальным скроллом и
   sticky-колонками слева. Cinematic язык + та же текстура что у radar2.
   ════════════════════════════════════════════════════════════════════════ */

.fund2-page-content { max-width: none; padding: 14px 24px 14px; }

/* Compact page-head на Funding/TradFi — чтобы дать таблице больше места */
.fund2-page-head { margin-bottom: 12px !important; }
.fund2-page-head .cine-page-title { font-size: 22px !important; margin-bottom: 4px !important; }
.fund2-page-head .cine-page-eyebrow { margin-bottom: 4px; }
.fund2-page-head .cine-page-sub { font-size: 11px; line-height: 1.4; }

/* Page head meta (right column on hero) — shared with TradFi tf-meta */
.fund2-page-head .tf-head-meta {
  display: flex; gap: 24px;
}
.fund2-page-head .tf-meta-row { display: flex; flex-direction: column; gap: 4px; align-items: flex-end; }

/* Compact TradFi splash strip — категории помещаются в одну тонкую полосу */
body.tradfi-mode .tf-cats {
  grid-template-columns: repeat(5, 1fr);
  gap: 8px !important;
  margin-bottom: 10px !important;
}
body.tradfi-mode .tf-cat {
  padding: 8px 12px !important;
  gap: 2px !important;
  flex-direction: row !important;
  align-items: center !important;
  flex-wrap: wrap;
}
body.tradfi-mode .tf-cat-glyph { font-size: 14px !important; margin-right: 6px; }
body.tradfi-mode .tf-cat-lbl { font-size: 10px !important; letter-spacing: 0.16em !important; }
body.tradfi-mode .tf-cat-count { font-size: 12px !important; margin-left: auto; }
body.tradfi-mode .tf-cat-desc { display: none !important; }

/* Compact TradFi ticker — тонкая полоска */
body.tradfi-mode .tf-ticker {
  height: 22px !important;
  margin-bottom: 8px !important;
}
body.tradfi-mode .tf-ticker-item { font-size: 10px !important; }

/* ───────── Toolbar — depth-texture (общая cinematic, см. cine_pages.css L1697) ───────── */
.fund2-toolbar {
  position: relative;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px 14px;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.012) 0 2px, transparent 2px 5px),
    linear-gradient(180deg, rgba(255,255,255,0.045) 0%, rgba(255,255,255,0.018) 28%, rgba(255,255,255,0.008) 100%),
    #131318;
  border: 1px solid rgba(255,255,255,0.18);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    0 1px 0 rgba(0,0,0,0.6),
    0 6px 14px -8px rgba(0,0,0,0.9);
  margin-bottom: 14px;
}

.fund2-tb-checkbox {
  display: inline-flex; align-items: center; gap: 8px;
  cursor: pointer; user-select: none;
  font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase;
  color: rgba(255,255,255,0.75);
}
.fund2-tb-checkbox:hover { color: #fff; }
.fund2-tb-checkbox-box {
  width: 14px; height: 14px;
  border: 1px solid rgba(255,255,255,0.4);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 10px; color: #fff;
  background: transparent;
}
.fund2-tb-checkbox-box.empty { color: transparent; }
.fund2-tb-checkbox.star .fund2-tb-checkbox-box { color: #ffd84d; border-color: rgba(255,216,77,0.55); }

.fund2-tb-divider { width: 1px; height: 18px; background: rgba(255,255,255,0.12); }

.fund2-tb-grp { display: inline-flex; align-items: center; gap: 8px; }
.fund2-tb-lbl {
  font-size: 9px; letter-spacing: 0.22em; text-transform: uppercase;
  color: rgba(255,255,255,0.5); white-space: nowrap;
}

.fund2-tb-num {
  display: inline-flex; align-items: center; gap: 4px;
  height: 28px; padding: 0 8px;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.22);
  font-family: 'Space Mono', ui-monospace, monospace;
  font-size: 11px; color: #fff; letter-spacing: 0.04em;
  min-width: 60px;
  transition: border-color 140ms ease;
}
.fund2-tb-num:hover, .fund2-tb-num:focus-within { border-color: rgba(255,255,255,0.5); }
.fund2-tb-num-spinner {
  display: inline-flex; flex-direction: column; gap: 1px;
  margin-left: auto;
}
.fund2-tb-num-spinner span {
  font-size: 7px; line-height: 1;
  color: rgba(255,255,255,0.5); cursor: pointer;
}

.fund2-tb-search {
  display: inline-flex; align-items: center; gap: 6px;
  height: 28px; padding: 0 10px;
  width: 240px;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.22);
  font-size: 11px; color: #fff;
  transition: border-color 140ms ease;
}
.fund2-tb-search:hover, .fund2-tb-search:focus-within { border-color: rgba(255,255,255,0.5); }
.fund2-tb-search-glyph { color: rgba(255,255,255,0.45); font-size: 11px; }
.fund2-tb-search-ph { color: rgba(255,255,255,0.32); }

.fund2-tb-select {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 12px;
  height: 28px; padding: 0 10px;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.22);
  font-size: 11px; color: #fff; letter-spacing: 0.04em;
  cursor: pointer; white-space: nowrap;
  transition: border-color 140ms ease;
}
.fund2-tb-select:hover { border-color: rgba(255,255,255,0.5); }
.fund2-tb-select.lg { min-width: 200px; }
.fund2-tb-select-caret { color: rgba(255,255,255,0.5); font-size: 9px; }

.fund2-tb-spacer { flex: 1; }

/* Toolbar buttons — flat, по образцу .ml-filt-chip */
.fund2-tb-btn {
  height: 28px;
  padding: 0 12px;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.22);
  color: rgba(255,255,255,0.75);
  font-family: inherit; font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
  transition: all 140ms ease;
}
.fund2-tb-btn:hover { color: #fff; border-color: rgba(255,255,255,0.5); }
.fund2-tb-btn.on,
.fund2-tb-btn.active {
  background: #fff; color: #000; border-color: #fff;
}
.fund2-tb-btn.prism {
  border-color: rgba(255,255,255,0.6);
  color: #fff;
}
.fund2-tb-btn.prism:hover { background: rgba(255,255,255,0.06); }
.fund2-tb-btn.cinematic { border-color: rgba(255,255,255,0.5); color: #fff; }
.fund2-tb-btn.cinematic:hover { background: rgba(255,255,255,0.06); }

.fund2-tb-lang {
  height: 28px; padding: 0 12px;
  border: 1px solid rgba(255,255,255,0.22);
  background: transparent; color: rgba(255,255,255,0.7);
  font-family: inherit; font-size: 10px; letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 140ms ease;
}
.fund2-tb-lang:hover { color: #fff; border-color: rgba(255,255,255,0.5); }

/* ───────── News ribbon ───────── */
.fund2-tb-news {
  display: inline-flex; align-items: center; gap: 8px;
  height: 28px; padding: 0 12px;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.22);
  color: rgba(255,255,255,0.75);
  font-size: 10px; letter-spacing: 0.04em;
  text-transform: none;
  max-width: 420px; overflow: hidden;
}
.fund2-tb-news b {
  color: #fff;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 1px 5px;
  background: #fff;
  color: #000;
  font-size: 9px;
}

/* ───────── Splash cards (ONLY tradfi) ───────── */
.fund2-cats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}
.fund2-cat {
  position: relative;
  padding: 14px 16px;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.012) 0 2px, transparent 2px 5px),
    linear-gradient(180deg, rgba(255,255,255,0.045) 0%, rgba(255,255,255,0.008) 100%),
    #131318;
  border: 1px solid rgba(255,255,255,0.14);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06), 0 6px 14px -10px rgba(0,0,0,0.9);
  cursor: pointer;
  transition: border-color 140ms ease;
}
.fund2-cat:hover { border-color: rgba(255,255,255,0.4); }
.fund2-cat.on { border-color: rgba(255,255,255,0.55); background-color: #1a1a22; }
.fund2-cat-glyph { font-size: 22px; color: rgba(255,255,255,0.7); margin-bottom: 6px; }
.fund2-cat-name {
  font-size: 12px; font-weight: 700; letter-spacing: 0.22em;
  text-transform: uppercase; color: #fff; margin-bottom: 4px;
}
.fund2-cat-meta {
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 10px; color: rgba(255,255,255,0.55); letter-spacing: 0.04em;
}
.fund2-cat-meta b { color: #fff; font-family: 'Space Mono', ui-monospace, monospace; font-weight: 700; }

/* ───────── Table shell — depth-texture ───────── */
.fund2-shell {
  position: relative;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.012) 0 2px, transparent 2px 5px),
    linear-gradient(180deg, rgba(255,255,255,0.045) 0%, rgba(255,255,255,0.018) 28%, rgba(255,255,255,0.008) 100%),
    #131318;
  border: 1px solid rgba(255,255,255,0.18);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    0 1px 0 rgba(0,0,0,0.6),
    0 6px 14px -8px rgba(0,0,0,0.9);
  overflow: hidden;
}

.fund2-scroll {
  position: relative;
  overflow-x: scroll;
  overflow-y: auto;
  scrollbar-width: auto;
  scrollbar-color: rgba(255,255,255,0.55) rgba(255,255,255,0.06);
}
.fund2-scroll::-webkit-scrollbar { width: 14px; height: 14px; }
.fund2-scroll::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
}
.fund2-scroll::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.45);
  border: 2px solid rgba(0,0,0,0.6);
  background-clip: padding-box;
  min-height: 40px;
  min-width: 40px;
}
.fund2-scroll::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.7); background-clip: padding-box; }
.fund2-scroll::-webkit-scrollbar-corner { background: rgba(255,255,255,0.06); }

.fund2-table {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
  min-width: max-content;
  font-family: 'Space Mono', ui-monospace, monospace;
  font-size: 11px;
  color: rgba(255,255,255,0.85);
  table-layout: auto;
}

/* ───────── Header ───────── */
.fund2-table thead th {
  position: sticky; top: 0;
  z-index: 5;
  height: 32px;
  padding: 0 12px;
  background: #0a0a0a;
  border-bottom: 1px solid rgba(255,255,255,0.18);
  border-right: 1px solid rgba(255,255,255,0.04);
  font-size: 9px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  text-align: right;
  white-space: nowrap;
  color: rgba(255,255,255,0.65);
  font-weight: 700;
  user-select: none;
  cursor: pointer;
}
.fund2-table thead th.left { text-align: left; }
.fund2-table thead th.center { text-align: center; }
.fund2-table thead th .fund2-th-info {
  display: inline-block;
  width: 12px; height: 12px;
  margin-left: 4px;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  font-size: 8px; line-height: 10px;
  text-align: center;
  color: rgba(255,255,255,0.5);
  font-weight: 400;
  letter-spacing: 0;
}

/* sticky left columns */
.fund2-table th.sticky-l, .fund2-table td.sticky-l {
  position: sticky;
  z-index: 4;
  background-color: #0a0a0a;
}
.fund2-table thead th.sticky-l { z-index: 6; background-color: #0a0a0a; }
/* mark right edge of last sticky group */
.fund2-table th.sticky-l-last, .fund2-table td.sticky-l-last {
  border-right: 1px solid rgba(255,255,255,0.14);
}

/* ───────── Body rows ───────── */
.fund2-table tbody tr {
  transition: background-color 100ms ease;
}
.fund2-table tbody tr:hover td {
  background-color: rgba(255,255,255,0.04) !important;
}
.fund2-table tbody tr.selected td { background-color: rgba(255,255,255,0.06) !important; }
.fund2-table tbody tr.selected td.sticky-l { background-color: rgba(255,255,255,0.08) !important; }

.fund2-table tbody td {
  height: 30px;
  padding: 0 12px;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  border-right: none;
  text-align: right;
  white-space: nowrap;
  vertical-align: middle;
}
.fund2-table tbody td.left { text-align: left; }
.fund2-table tbody td.center { text-align: center; }

/* ───────── Cell variants ───────── */
.fund2-cell-pos { color: #6bff9a; font-weight: 700; }
.fund2-cell-neg { color: #ff7b7b; font-weight: 700; }
.fund2-cell-zero { color: rgba(255,255,255,0.7); font-weight: 700; }
.fund2-cell-mute { color: rgba(255,255,255,0.3); font-weight: 400; }

.fund2-symbol { font-weight: 700; color: #fff; letter-spacing: 0.04em; font-size: 12px; }
.fund2-symbol-sub {
  display: inline-block;
  width: 12px; height: 12px;
  margin-left: 4px;
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 50%;
  font-size: 8px; line-height: 10px;
  text-align: center; color: rgba(255,255,255,0.4);
  font-weight: 400;
}
.fund2-cat-tag {
  font-size: 10px;
  color: rgba(255,255,255,0.6);
  letter-spacing: 0.04em;
}
.fund2-cat-tag.fx { color: #b9c8ff; }
.fund2-cat-tag.stock { color: rgba(255,255,255,0.7); }
.fund2-cat-tag.commodity { color: #ffd58a; }
.fund2-cat-tag.index { color: #c0a8ff; }

.fund2-exch {
  text-decoration: underline;
  text-decoration-color: rgba(255,255,255,0.3);
  text-underline-offset: 3px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  font-weight: 700;
  cursor: pointer;
}
.fund2-exch:hover { text-decoration-color: rgba(255,255,255,0.7); color: #fff; }

.fund2-star {
  cursor: pointer;
  font-size: 13px;
  color: rgba(255,255,255,0.25);
  line-height: 1;
}
.fund2-star.on { color: #ffd84d; text-shadow: 0 0 6px rgba(255,216,77,0.5); }

.fund2-spark {
  display: inline-block;
  width: 60px;
  height: 18px;
  vertical-align: middle;
}

/* row click state */
.fund2-table tbody tr { cursor: pointer; }

/* ───────── Status bar — depth-texture ───────── */
.fund2-statusbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.012) 0 2px, transparent 2px 5px),
    linear-gradient(180deg, rgba(255,255,255,0.045) 0%, rgba(255,255,255,0.018) 28%, rgba(255,255,255,0.008) 100%),
    #131318;
  border: 1px solid rgba(255,255,255,0.18);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    0 1px 0 rgba(0,0,0,0.6),
    0 6px 14px -8px rgba(0,0,0,0.9);
  font-size: 9px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.5);
  margin-top: 10px;
}
.fund2-status-l, .fund2-status-r, .fund2-status-c { display: flex; align-items: center; gap: 8px; }
.fund2-status-dot { width: 6px; height: 6px; background: #fff; }
.fund2-status-c { color: rgba(255,255,255,0.4); letter-spacing: 0.08em; text-transform: none; font-size: 10px; }
.fund2-status-c b { color: rgba(255,255,255,0.7); font-weight: 400; }

/* ───────── Exchanges popup — depth-texture ───────── */
.fund2-exch-popup {
  position: absolute;
  top: 56px;
  right: 220px;
  z-index: 30;
  width: 320px;
  padding: 14px 16px 12px;
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,0.012) 0 2px, transparent 2px 5px),
    linear-gradient(180deg, rgba(255,255,255,0.045) 0%, rgba(255,255,255,0.018) 28%, rgba(255,255,255,0.008) 100%),
    #131318;
  border: 1px solid rgba(255,255,255,0.25);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.06),
    0 14px 28px -8px rgba(0,0,0,0.9);
}
.fund2-exch-popup-title {
  font-size: 10px; letter-spacing: 0.28em; text-transform: uppercase;
  color: rgba(255,255,255,0.55); margin-bottom: 10px;
}
.fund2-exch-popup-list {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 6px 12px;
  max-height: 280px; overflow-y: auto;
}
.fund2-exch-popup-row {
  display: flex; align-items: center; gap: 8px;
  font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase;
  cursor: pointer; user-select: none;
  padding: 4px 0;
  color: rgba(255,255,255,0.85);
}
.fund2-exch-popup-row:hover { color: #fff; }
.fund2-exch-popup-box {
  width: 12px; height: 12px;
  border: 1px solid rgba(255,255,255,0.45);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 9px; color: #fff;
}
.fund2-exch-popup-foot {
  display: flex; justify-content: space-between; gap: 8px;
  margin-top: 12px; padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,0.1);
}
.fund2-exch-popup-foot button {
  flex: 1;
  height: 26px;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.3);
  color: rgba(255,255,255,0.85);
  font-family: inherit; font-size: 10px;
  letter-spacing: 0.22em; text-transform: uppercase;
  cursor: pointer;
}
.fund2-exch-popup-foot button:hover { color: #fff; border-color: rgba(255,255,255,0.7); background: rgba(255,255,255,0.05); }
.fund2-exch-popup-foot button.primary {
  border-color: rgba(107,255,154,0.55); color: #6bff9a; background: rgba(107,255,154,0.05);
}
.fund2-exch-popup-foot button.primary:hover { background: rgba(107,255,154,0.12); }

/* ───────── Mobile ───────── */
@media (max-width: 1280px) {
  .fund2-cats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .fund2-cats { grid-template-columns: 1fr; }
}
