:root, .light {
  color-scheme: light;
  --accent:#3e44f5; --ink:#111111; --muted:#777777; --line:#e6e6e6;
  --bg:#ffffff; --bg2:#ffffff; --bg3:#f5f6fb; --head:#111111; --text:#252525; --text2:#777777;
  --lime:#c6f24e; --orange:#f15f2c; --green:#1e8e3e; --red:#d93025;
  --shadow:0 18px 38px rgba(17,24,39,.07);
}
.dark {
  color-scheme: dark;
  --ink:#f4f5fb; --muted:#a8adbf; --line:#303548;
  --bg:#111522; --bg2:#171b2b; --bg3:#20263a; --head:#f4f5fb; --text:#e9ebf4; --text2:#9299af;
  --green:#67d391; --red:#ff7a70; --shadow:0 18px 38px rgba(0,0,0,.24);
}
* { box-sizing:border-box; }
html { scroll-behavior:smooth; -webkit-text-size-adjust:100%; }
body { margin:0; background:var(--bg); color:var(--text); font-family:Montserrat,Arial,sans-serif; overflow-x:hidden; padding-bottom:env(safe-area-inset-bottom); }
a { color:var(--accent); text-decoration:none; }
button { cursor:pointer; font-family:inherit; }
.wrap { max-width:1312px; margin:0 auto; padding:0 16px; }
.brandband { height:60px; background:#111 linear-gradient(135deg,#111 0%,#171b2b 48%,#3e44f5 100%); }
.site-header { border-bottom:1px solid var(--line); background:var(--bg); }
.headbar { min-height:80px; display:flex; align-items:center; gap:28px; }
.brand { display:flex; align-items:center; gap:13px; color:var(--ink); flex:none; }
.mark { width:46px; height:46px; border-radius:50%; background:var(--accent); color:#fff; display:grid; place-items:center; position:relative; font:700 13px Unbounded,Montserrat,sans-serif; }
.mark i { position:absolute; bottom:9px; width:21px; height:2px; background:#fff; border-radius:4px; }
.brand-name { font:700 21px/1 Unbounded,Montserrat,sans-serif; letter-spacing:0; }
.brand-sub { display:flex; align-items:center; gap:7px; margin-top:6px; color:var(--muted); font-size:9px; letter-spacing:.14em; }
.brand-sub b { width:20px; height:2px; background:var(--accent); border-radius:2px; }
.nav, .mobile-nav { display:flex; gap:8px; align-items:center; }
.mobile-nav { display:none; }
.head-actions { display:flex; align-items:center; gap:8px; margin-left:auto; }
.pill, .chip, .theme-toggle, #loginBtn, #passwordLoginBtn, .primaryBtn, .outline {
  border:1px solid var(--line); background:var(--bg2); color:#444; border-radius:999px;
  padding:10px 17px; font-size:13px; font-weight:500; line-height:1; transition:.18s ease;
}
.dark .pill, .dark .chip, .dark .theme-toggle, .dark #loginBtn, .dark #passwordLoginBtn, .dark .outline { color:var(--text); }
.pill:hover, .pill.active, .chip.active { color:#fff; background:var(--accent); border-color:var(--accent); }
.chip { padding:8px 13px; font-size:12px; }
.chip:hover, .theme-toggle:hover, .outline:hover { border-color:var(--accent); color:var(--accent); }
.chip:disabled { opacity:.45; cursor:default; }
#themeBtn { white-space:nowrap; }
#userBadge { color:var(--text2); font-size:12px; max-width:230px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
#loginBtn { background:var(--accent); border-color:var(--accent); color:#fff; }
#passwordLoginBtn { background:var(--bg2); }
main.wrap { padding-top:34px; padding-bottom:42px; }
h1 { margin:0; color:var(--head); font:600 30px/1.2 Unbounded,Montserrat,sans-serif; }
h2 { margin:0 0 14px; color:var(--head); font:600 19px/1.25 Unbounded,Montserrat,sans-serif; }
.intro { padding:0 0 27px; display:flex; justify-content:space-between; gap:24px; align-items:flex-end; }
.intro p { color:var(--muted); font-size:14px; line-height:1.5; margin:10px 0 0; }
.status { font-size:12px; color:var(--muted); white-space:nowrap; }
.status span { display:inline-block; width:8px; height:8px; border-radius:50%; background:#23a04b; margin-right:6px; }
.status strong { color:#258846; }
.spinner { color:var(--text2); font-size:14px; padding:24px 0; }
.error { color:var(--red); padding:14px 16px; border:1px solid #ffd0d0; background:#fff4f2; border-radius:14px; }
.dark .error { border-color:#5c2b2b; background:#24181f; }

.widgets { display:grid; grid-template-columns:repeat(auto-fill,minmax(170px,1fr)); gap:10px; margin-bottom:30px; }
.wcard { border:1px solid var(--line); border-radius:14px; padding:16px 17px; min-height:116px; background:var(--bg2); box-shadow:var(--shadow); }
.wcard:first-child { background:var(--accent); border-color:var(--accent); color:#fff; }
.wcard .title { color:var(--muted); margin-bottom:16px; font-size:11px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.wcard:first-child .title { color:#d8d9ff; }
.wcard .value { color:var(--head); font:600 22px/1 Unbounded,Montserrat,sans-serif; letter-spacing:-.03em; white-space:nowrap; }
.wcard:first-child .value { color:#fff; }
.wcard .change { margin-top:9px; font-size:11px; font-weight:600; color:var(--text2); }
.wcard:first-child .change, .wcard:first-child .up { color:var(--lime); }
.up, .green { color:var(--green); }
.down { color:var(--red); }

table { border-collapse:separate; border-spacing:0; width:100%; min-width:650px; font-size:12px; background:var(--bg2); }
th, td { padding:12px; border-bottom:1px solid var(--line); text-align:right; font-variant-numeric:tabular-nums; }
th { color:var(--text2); font-size:10px; text-transform:uppercase; letter-spacing:.05em; font-weight:700; background:var(--bg2); position:sticky; top:0; z-index:1; user-select:none; }
th:first-child, td:first-child { text-align:left; }
td:first-child { font-weight:600; }
tr:hover td { background:var(--bg3); }
td.n, th.n { text-align:right; }
#macrotbl, .table-wrap { max-width:100%; border:1px solid var(--line); border-radius:14px; overflow-x:auto; overflow-y:hidden; -webkit-overflow-scrolling:touch; overscroll-behavior-x:contain; background:var(--bg2); box-shadow:var(--shadow); }
.table-scroll-hint { display:none; color:var(--text2); font-size:10px; padding:8px 12px 0; }

.macro-list-head { display:flex; justify-content:space-between; gap:24px; align-items:flex-end; padding:0 0 24px; }
.macro-list-head h2 { font-size:30px; margin:0; }
.macro-list-head p { margin:10px 0 0; color:var(--muted); font-size:14px; line-height:1.5; }
.macro-actions, .macro-toolbar { display:flex; align-items:center; flex-wrap:wrap; gap:10px; color:var(--text2); font-size:12px; }
.macro-action-group { display:flex; align-items:center; gap:6px; padding:5px; border:1px solid var(--line); border-radius:12px; background:var(--bg2); box-shadow:var(--shadow); }
.macro-action-label { padding:0 5px; color:var(--head); font-size:10px; font-weight:700; white-space:nowrap; }
.macro-search-group { flex:1 1 220px; }
.macro-search { min-width:0; width:100%; cursor:text; border-radius:999px; outline:none; }
.macro-search:focus { border-color:var(--accent); box-shadow:0 0 0 3px rgba(62,68,245,.12); }
.primaryBtn { background:var(--accent); border-color:var(--accent); color:#fff; padding:10px 17px; }
.macro-progress { display:none; position:relative; height:26px; margin:10px 0 14px; border:1px solid var(--line); border-radius:999px; background:var(--bg2); overflow:hidden; box-shadow:inset 0 1px 3px rgba(0,0,0,0.2); }
.macro-progress i { display:block; height:100%; width:0; background:linear-gradient(90deg, var(--accent), #6366f1, #8b5cf6); background-size:200% 100%; animation:macroProgressPulse 2s ease infinite; transition:width .25s ease; border-radius:999px; }
.macro-progress.is-error i { background:var(--red) !important; animation:none !important; }
.macro-progress span { position:absolute; inset:0; display:flex; align-items:center; justify-content:center; padding:0 12px; color:var(--head); font-size:12px; font-weight:600; letter-spacing:0.2px; text-shadow:0 1px 3px rgba(0,0,0,0.4); }
@keyframes macroProgressPulse { 0% { background-position:0% 50%; } 50% { background-position:100% 50%; } 100% { background-position:0% 50%; } }
.global-snapshot { margin:0 0 14px; border:1px solid var(--line); border-radius:14px; background:var(--bg2); padding:14px 16px; box-shadow:var(--shadow); }
.snapshot-empty { color:var(--text2); font-size:12px; }
.snapshot-head { display:flex; justify-content:space-between; gap:12px; align-items:flex-start; margin-bottom:8px; }
.snapshot-head strong { display:block; color:var(--head); font-size:14px; }
.snapshot-head small, .snapshot-head span { display:block; color:var(--text2); font-size:11px; margin-top:3px; }
.global-snapshot p { margin:0 0 10px; font-size:13px; line-height:1.5; color:var(--text); }
.snapshot-summary { padding:10px 12px; border:1px solid var(--line); border-radius:10px; background:var(--bg3); }
.snapshot-summary strong, .snapshot-regime > strong { display:block; margin-bottom:6px; color:var(--head); font-size:12px; }
.snapshot-grid { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:8px; }
.snapshot-grid > div { border:1px solid var(--line); border-radius:10px; padding:9px 10px; background:var(--bg3); min-height:78px; }
.snapshot-card { display:flex; flex-direction:column; }
.snapshot-grid b { display:block; color:var(--head); font-size:11px; margin-bottom:5px; }
.snapshot-grid .snapshot-view { display:block; color:var(--text2); font-size:11px; line-height:1.35; }
.snapshot-card-meta { display:flex; flex-wrap:wrap; gap:4px 8px; margin-top:8px; }
.snapshot-card-meta span { color:var(--text2); font-size:10px; line-height:1.3; }
.snapshot-card-meta .snapshot-trend { font-weight:700; }
.snapshot-card-meta .bullish { color:var(--green); }
.snapshot-card-meta .bearish { color:var(--red); }
.snapshot-card-meta .sideways, .snapshot-card-meta .mixed { color:var(--accent); }
.snapshot-card-meta .snapshot-warning { color:var(--red); font-weight:700; }
.snapshot-evidence { margin-top:8px; padding-top:7px; border-top:1px solid var(--line); }
.snapshot-evidence strong { color:var(--head); font-size:10px; }
.snapshot-evidence ul { margin:4px 0 0 14px; padding:0; color:var(--text2); font-size:10px; line-height:1.35; }
.snapshot-regime { margin:10px 0; }
.snapshot-regime-grid { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:8px; }
.snapshot-regime-grid > div { padding:8px 10px; border:1px solid var(--line); border-radius:10px; background:var(--bg2); }
.snapshot-regime-grid b, .snapshot-regime-grid span { display:block; }
.snapshot-regime-grid b { color:var(--head); font-size:10px; margin-bottom:4px; }
.snapshot-regime-grid span { color:var(--text2); font-size:10px; line-height:1.35; }
.snapshot-lists h4 { margin:12px 0 6px; color:var(--head); font-size:12px; }
.snapshot-lists ul { margin:0 0 4px 18px; padding:0; color:var(--text2); font-size:12px; line-height:1.45; }
.macro-table td:nth-child(2) small { display:block; color:var(--text2); font-size:11px; margin-top:4px; max-width:680px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.macro-table td span { color:var(--text2); font-size:11px; }
.macro-table th.pick, .macro-table td.pick { width:34px; padding-right:4px; text-align:center; }
.statusPill { display:inline-flex; align-items:center; justify-content:center; min-width:78px; border:1px solid var(--line); border-radius:999px; padding:4px 9px; color:var(--text2); font-size:11px; }
.statusPill.good { color:var(--green); border-color:#b7e4c7; background:#eefcf3; }
.statusPill.bad { color:var(--red); border-color:#ffc1c1; background:#fff1f1; }
.dark .statusPill.good { background:#12251b; border-color:#2b6842; }
.dark .statusPill.bad { background:#2a171b; border-color:#7a3434; }
.macro-table th[data-sort]::after, .rgbi-table th[data-sort]::after { content:"↕"; margin-left:4px; color:var(--text2); font-size:10px; }

.macro-toolbar { margin-bottom:10px; }
.macro-toolbar .spacer { flex:1; }
.macro-chart-tabs { display:flex; gap:6px; flex-wrap:wrap; max-width:720px; }
.macro-chart-tabs .active { color:#fff; background:var(--accent); border-color:var(--accent); }
.macro-chart-tabs select { max-width:320px; }
.macro-share-actions { display:flex; align-items:center; flex-wrap:wrap; gap:6px; margin:0 0 14px; }
.macro-share-actions .chip { font-weight:600; }
.export-menu { position:relative; margin-left:auto; }
.export-menu summary { list-style:none; display:inline-block; }
.export-menu summary::-webkit-details-marker { display:none; }
.export-menu[open] .export-menu-list { position:absolute; z-index:4; right:0; top:calc(100% + 6px); display:flex; flex-wrap:wrap; gap:6px; min-width:170px; padding:8px; border:1px solid var(--line); border-radius:12px; background:var(--bg2); box-shadow:var(--shadow); }
.export-menu-list .chip { white-space:nowrap; }
.macro-detail-line { display:flex; align-items:baseline; gap:12px; margin:6px 0 14px; color:var(--text2); }
.macro-detail-line strong { color:var(--head); font-size:18px; }

.telegram-slide { --slide-bg:#f8fafc; --slide-card:#fff; --slide-card-primary:#fffafa; --slide-border:#e2e8f0; --slide-text:#111827; --slide-muted:#64748b; position:relative; background:var(--slide-bg); color:var(--slide-text); border:1px solid var(--slide-border); border-radius:16px; padding:28px 32px 22px; min-height:660px; box-shadow:var(--shadow); }
.dark .telegram-slide { --slide-bg:#0d1117; --slide-card:#161b22; --slide-card-primary:#1a1215; --slide-border:#30363d; --slide-text:#e5e9f0; --slide-muted:#8b949e; }
.slide-accent { width:188px; height:5px; background:#ef3b31; margin-bottom:12px; }
.slide-date { position:absolute; top:30px; right:34px; color:var(--slide-muted); font-size:15px; font-weight:700; }
.slide-title { margin:0 150px 24px 0; color:var(--slide-text); font:700 34px/1.08 Unbounded,Montserrat,sans-serif; letter-spacing:0; }
.summary-cards { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; margin:0 0 24px; }
.summary-card { position:relative; min-height:96px; border:1px solid var(--slide-border); border-radius:14px; background:var(--slide-card); padding:14px 18px; }
.summary-card.primary { border-color:#ffd7d7; background:var(--slide-card-primary); }
.dark .summary-card.primary { border-color:#7f1d1d; }
.summary-card i { display:block; width:38px; height:4px; margin-bottom:8px; }
.summary-card strong { display:block; font-size:12px; line-height:1.15; }
.summary-card b { display:block; color:var(--slide-text); font:700 24px/1 Unbounded,Montserrat,sans-serif; margin-top:6px; }
.summary-card span { display:block; color:var(--slide-muted); font-size:12px; margin-top:6px; font-weight:700; }
.summary-card .up { color:#16a34a; }
.summary-card .down { color:#ef3b31; }
.slide-chart { height:430px; position:relative; border:0; background:var(--slide-bg); }
#chartwrap.slide-chart { height:430px; display:block; align-items:initial; justify-content:initial; border:0; background:var(--slide-bg); }
.slide-chart canvas { width:100% !important; height:100% !important; }
.expert-views-wrap { height:430px; overflow:auto; }
.expert-view-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; padding:2px; }
.expert-view-card { border:1px solid var(--slide-border); border-radius:12px; background:var(--slide-card); padding:12px 14px; }
.expert-view-meta { display:flex; justify-content:space-between; gap:12px; color:var(--slide-muted); font-size:12px; }
.expert-view-meta b { color:var(--accent); }
.expert-view-card p { margin:8px 0; color:var(--slide-text); font-size:13px; line-height:1.45; white-space:pre-wrap; }
.expert-view-card a { color:var(--accent); font-size:12px; }
.slide-footer { display:flex; justify-content:space-between; color:var(--slide-muted); font-size:14px; margin-top:18px; }
.slide-footer a { color:inherit; text-decoration:underline; text-underline-offset:3px; }
.slide-footer a.is-disabled { pointer-events:none; text-decoration:none; }

.macro-text, #analysisText, .market-section { margin-top:14px; background:var(--bg2); border:1px solid var(--line); border-radius:14px; padding:16px; color:var(--text); font-size:13px; line-height:1.6; box-shadow:var(--shadow); }
.macro-text { overflow:visible; }
.macro-text h3, .market-text h3 { margin:14px 0 8px; color:var(--head); font-size:15px; }
.macro-text h3:first-child { margin-top:0; color:var(--accent); }
.macro-text p, .market-text p { margin:7px 0; color:var(--text); }
.macro-text .kv, .macro-text .bullet { padding:8px 10px; border-left:3px solid var(--accent); border-radius:10px; background:var(--bg3); }

.rgbi-table { min-width:100%; color:var(--text); background:var(--bg2); border-collapse:collapse; }
.rgbi-table th { position:static; background:var(--bg3); color:var(--text2); padding:10px 12px; font-size:12px; }
.rgbi-table td { border-bottom:1px solid var(--line); text-align:center; padding:10px 12px; font-size:13px; }
.rgbi-table tr:hover { background:var(--bg3); }
.table-caption { margin:12px 14px 8px; color:var(--text2); font-weight:700; }
.futoi-table td:first-child { text-align:left; font-weight:600; }

.heatmap-wrap { display:block; width:100%; max-width:100%; min-width:0; overflow:auto; padding-right:4px; }
.heat-section { margin-bottom:16px; }
.heat-section h3 { margin:0 0 9px; color:var(--slide-text,var(--head)); font-size:13px; }
.heat-grid { display:grid; width:100%; max-width:100%; min-width:0; grid-template-columns:repeat(auto-fit,minmax(124px,1fr)); gap:7px; }
.heat-tile { min-height:76px; border-radius:10px; padding:11px 12px; display:flex; flex-direction:column; justify-content:space-between; color:#121212; }
.heat-tile.pos { background:#bce9ae; }
.heat-tile.neg { background:#f2b9b0; }
.heat-tile strong { font:700 13px Unbounded,Montserrat,sans-serif; }
.heat-tile span { font-size:17px; font-weight:800; }
.heat-tile .heat-price { font-size:11px; font-weight:600; color:#334155; opacity:0.92; margin-top:2px; font-family:Montserrat,sans-serif; }
.heat-tile small { opacity:.72; font-size:10px; }
.market-link { display:inline-block; margin:14px 12px 0 0; font-size:13px; }
.market-heat .heat-tile { min-height:72px; }

.chat-head { display:flex; align-items:flex-end; justify-content:space-between; gap:16px; margin-bottom:14px; }
.chat-head h1 { font-size:30px; }
.chat-head p { margin:10px 0 0; color:var(--muted); font-size:14px; }
.chat-empty, .chat-panel { background:var(--bg2); border:1px solid var(--line); border-radius:14px; padding:16px; box-shadow:var(--shadow); }
.chat-empty { color:var(--text2); }
.chat-toolbar { display:flex; flex-wrap:wrap; gap:8px; margin-bottom:10px; }
.chat-messages { min-height:360px; max-height:60vh; overflow:auto; display:flex; flex-direction:column; gap:8px; padding:10px; border:1px solid var(--line); border-radius:12px; background:var(--bg3); }
.chat-welcome { padding:20px; color:var(--text2); text-align:center; white-space:pre-wrap; }
.chat-message { max-width:88%; padding:10px 12px; border-radius:12px; font-size:13px; line-height:1.5; white-space:pre-wrap; }
.chat-message.user { align-self:flex-end; color:#fff; background:var(--accent); }
.chat-message.assistant { align-self:flex-start; color:var(--text); background:var(--bg2); border:1px solid var(--line); }
.chat-form { display:flex; align-items:flex-end; gap:8px; margin-top:10px; }
.chat-form textarea { flex:1; min-height:76px; resize:vertical; border:1px solid var(--line); border-radius:12px; padding:10px 12px; color:var(--text); background:var(--bg2); font:inherit; }
.chat-form textarea:focus { outline:none; border-color:var(--accent); box-shadow:0 0 0 3px rgba(62,68,245,.12); }
.chat-status { min-height:18px; margin-top:6px; color:var(--text2); font-size:11px; }

/* Fund Flows Dashboard */
.fund-flows-container { padding:20px; }
.flows-header h3 { margin:0 0 4px; color:var(--head); font-size:18px; }
.flows-desc { margin:0 0 16px; color:var(--text2); font-size:13px; }
.flows-cards-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(210px,1fr)); gap:10px; margin-bottom:20px; }
.flow-card { background:var(--bg3); border:1px solid var(--line); border-radius:12px; padding:14px; display:flex; flex-direction:column; justify-content:space-between; }
.flow-card.main-card { border-color:var(--accent); background:var(--bg2); box-shadow:0 2px 8px rgba(0,0,0,0.1); }
.flow-card .card-title { font-size:13px; font-weight:700; color:var(--head); margin-bottom:6px; }
.flow-card .card-main-metric { font:800 20px Unbounded,Montserrat,sans-serif; margin-bottom:8px; }
.flow-card.pos .card-main-metric { color:#16a34a; }
.flow-card.neg .card-main-metric { color:#ef3b31; }
.flow-card .card-main-metric small { font-size:11px; font-weight:600; color:var(--text2); }
.flow-card .card-sub-metrics { font-size:11px; color:var(--text2); display:flex; flex-wrap:wrap; gap:8px; }
.flow-card .card-sub-metrics b { color:var(--text); }
.flow-card .nav-tag { width:100%; margin-top:2px; color:var(--accent); font-weight:600; }
.flows-chart-box { background:var(--bg3); border:1px solid var(--line); border-radius:12px; padding:16px; margin-bottom:12px; }
.flows-chart-box h4 { margin:0 0 12px; font-size:13px; color:var(--head); }
.rgbi-toolbar button.chip { font-weight:600; transition:all 0.15s; }
.rgbi-toolbar button.chip:hover { border-color:var(--accent); color:var(--accent); }

@media (max-width:900px) {
  .nav { gap:5px; }
  .pill { padding:9px 12px; }
  .widgets, .summary-cards { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .snapshot-grid, .snapshot-regime-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
}
@media (max-width:650px) {
  .brandband { height:40px; }
  .headbar { min-height:67px; padding-top:13px; padding-bottom:13px; gap:10px; }
  .wrap { padding-left:12px; padding-right:12px; }
  .brand { min-width:0; flex:1 1 auto; gap:8px; }
  .mark { width:35px; height:35px; font-size:10px; }
  .mark i { bottom:7px; width:16px; }
  .brand-name { min-width:0; font-size:13px; white-space:nowrap; }
  .brand-sub { display:none; }
  .nav { display:none; }
  .mobile-nav { display:flex; gap:7px; overflow-x:auto; padding-bottom:12px; }
  .mobile-nav .pill { font-size:11px; padding:8px 12px; flex:none; }
  .head-actions { gap:4px; min-width:0; }
  #themeBtn { display:none; }
  #loginBtn, #passwordLoginBtn { max-width:66px; padding:7px 8px; font-size:9px; line-height:1.05; white-space:normal; text-align:center; }
  #userBadge { display:none !important; }
  main.wrap { padding-top:22px; }
  .intro { display:block; padding-bottom:20px; }
  .intro h1 { font-size:21px; }
  .intro p { font-size:12px; margin-top:8px; }
  .status { margin-top:15px; font-size:10px; }
  .widgets, .summary-cards { grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
  .wcard { min-height:101px; padding:13px; }
  .wcard .value { font-size:17px; }
  .macro-list-head { display:block; padding-bottom:18px; }
  .macro-list-head h2 { font-size:21px; }
  .macro-actions { margin-top:14px; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); }
  .macro-action-group { min-width:0; overflow:hidden; }
  .macro-action-group > * { min-width:0; }
  .macro-search-group { grid-column:1 / -1; }
  .macro-search { min-width:0; width:100%; }
  .macro-toolbar { align-items:stretch; gap:6px; }
  .macro-toolbar .spacer { display:none; }
  .macro-toolbar > .chip, .macro-toolbar > select { min-height:40px; }
  .macro-chart-tabs { order:10; width:100%; max-width:none; overflow-x:auto; flex-wrap:nowrap; padding-bottom:2px; }
  .macro-chart-tabs .chip { flex:none; }
  .macro-share-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); }
  .macro-share-actions .chip { min-height:40px; }
  .table-scroll-hint { display:block; }
  .macro-overview-table table { min-width:560px; }
  .macro-table th:first-child, .macro-table td:first-child, .rgbi-table th:first-child, .rgbi-table td:first-child { position:sticky; left:0; z-index:2; background:var(--bg2); }
  .macro-table th:first-child, .rgbi-table th:first-child { background:var(--bg3); }
  .export-menu { margin-left:0; }
  .export-menu > summary { min-height:40px; }
  .export-menu[open] .export-menu-list { left:0; right:auto; }
  .snapshot-grid { grid-template-columns:1fr; }
  .snapshot-regime-grid { grid-template-columns:1fr; }
  .telegram-slide { padding:20px 16px; min-height:560px; }
  .slide-date { position:static; margin-bottom:8px; }
  .slide-title { margin-right:0; font-size:25px; }
  .slide-chart, #chartwrap.slide-chart { height:340px; }
  .slide-footer { gap:10px; align-items:flex-start; font-size:11px; line-height:1.35; }
  .heat-grid { grid-template-columns:repeat(3,minmax(0,1fr)); gap:5px; }
  .heat-tile { min-height:59px; padding:10px; }
  .heat-tile strong, .heat-tile span { font-size:10px; }
  .chat-head { align-items:flex-start; }
  .chat-head h1 { font-size:21px; }
  .chat-head p { font-size:12px; }
  .chat-panel { padding:10px; }
  .chat-messages { min-height:300px; max-height:none; }
  .chat-form { flex-direction:column; align-items:stretch; }
  .chat-form .primaryBtn { width:100%; min-height:42px; }
}
