    :root {
      --sticky-main-top: 0px;
      --sticky-main-h: 72px;
      --sticky-search-h: 52px;
    }

    * {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
    }

    body {
      position: relative;
      overflow: hidden;
      overflow-x: hidden;
    }

    html.embedded-shell .sidebar {
      display: none !important;
    }

    html.embedded-shell body {
      overflow-y: auto;
      overflow-x: hidden;
      min-height: 100vh;
    }

    html.embedded-shell .app {
      display: block;
      height: auto;
      min-height: 100vh;
      overflow: visible;
    }

    html.embedded-shell .main {
      width: 100%;
      min-width: 0;
      min-height: 100vh;
      overflow: visible;
    }

    html.embedded-shell .asset-view {
      min-height: 0;
      overflow: visible;
    }

    html.embedded-shell .table-wrapper {
      flex: 0 1 auto;
      min-height: 0;
      overflow: auto;
      max-height: calc(100vh - var(--sticky-main-h) - var(--sticky-search-h));
    }

    .app {
      display: flex;
      height: 100vh;
      overflow: hidden;
    }

    .menu-icon {
      width: 16px;
      height: 16px;
      flex: 0 0 16px;
      opacity: 0.95;
      color: currentColor;
    }

    .menu-label {
      flex: 1 1 auto;
    }

    .logo-pages .subpage-side-btn {
      appearance: none;
    }

    .subpage-side-btn,
    .subpage-side-link {
      cursor: pointer;
    }

    .sidebar-section-btn {
      width: calc(100% - 24px);
      margin: 8px 12px 0;
      padding: 9px 10px;
      font-size: 10px;
      text-transform: uppercase;
      letter-spacing: 1.6px;
      color: var(--text2);
      background: rgba(255, 255, 255, 0.02);
      border: 1px solid var(--border);
      border-radius: 8px;
      text-align: left;
      cursor: pointer;
      transition: all 0.15s;
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    }

    .sidebar-section-btn:hover,
    .sidebar-section-btn.open {
      color: var(--accent);
      border-color: var(--border2);
    }

    .sidebar-filter-launch {
      width: 100%;
      display: inline-flex;
      align-items: center;
      justify-content: space-between;
      gap: 8px;
      padding: 9px 10px;
      font-size: 11px;
      letter-spacing: 1.1px;
      color: var(--text2);
      background: rgba(255, 255, 255, 0.02);
      border: 1px solid var(--border);
      border-radius: 8px;
      text-align: left;
      cursor: pointer;
      transition: all 0.15s;
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    }

    .sidebar-filter-launch:hover {
      color: var(--accent);
      border-color: var(--border2);
      background: rgba(129, 201, 149, 0.1);
    }

    .sidebar-filter-copy {
      min-width: 0;
    }

    .sidebar-filter-reset {
      display: none;
      align-items: center;
      justify-content: center;
      width: 20px;
      height: 20px;
      border: 1px solid rgba(76, 175, 114, 0.64);
      border-radius: 5px;
      background: rgba(16, 185, 129, 0.16);
      color: #4CAF72;
      font-size: 13px;
      font-weight: 900;
      line-height: 1;
      letter-spacing: 0;
      cursor: pointer;
      flex: 0 0 auto;
    }

    .sidebar-filter-launch.has-active-filters .sidebar-filter-reset {
      display: inline-flex;
    }

    .sidebar-filter-reset:hover {
      background: rgba(16, 185, 129, 0.26);
      border-color: rgba(76, 175, 114, 0.9);
    }

    .filter-group {
      padding: 6px;
    }

    .sidebar-panel {
      display: none;
      margin: 6px 12px 8px;
      border: 1px solid var(--border);
      border-radius: 8px;
      background: rgba(255, 255, 255, 0.025);
    }

    .sidebar-panel.open {
      display: block;
    }

    .sidebar-panel .filter-group + .filter-group {
      border-top: 1px solid var(--border);
    }

    .filter-btn {
      display: block;
      width: 100%;
      text-align: left;
      background: none;
      border: none;
      color: var(--text2);
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
      font-size: 12px;
      padding: 6px 8px;
      border-radius: 4px;
      cursor: pointer;
      transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .filter-btn:hover {
      background: var(--surface-2);
      color: var(--text);
      transform: none;
      box-shadow: none;
    }

    .filter-btn.active {
      background: var(--surface2);
      color: var(--accent);
    }

    .filter-btn:active {
      transform: translateY(0);
      box-shadow: none;
    }

    .filter-btn .count {
      float: right;
      font-size: 10px;
      color: var(--text3);
    }

    .geo-filter-tree {
      display: flex;
      flex-direction: column;
      gap: 6px;
      padding: 6px;
    }

    .geo-filter-all {
      margin-bottom: 4px;
    }

    .geo-filter-continent {
      border: 1px solid var(--border);
      border-radius: 8px;
      background: rgba(255, 255, 255, 0.02);
      overflow: hidden;
    }

    .geo-filter-toggle {
      width: 100%;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
      padding: 9px 10px;
      border: none;
      background: transparent;
      color: var(--text);
      font: inherit;
      font-size: 12px;
      cursor: pointer;
    }

    .geo-filter-toggle:hover {
      background: rgba(255, 255, 255, 0.03);
    }

    .geo-filter-toggle-label {
      font-weight: 600;
    }

    .geo-filter-toggle-meta {
      font-size: 10px;
      color: var(--text3);
      text-transform: uppercase;
      letter-spacing: 0.08em;
    }

    .geo-filter-chevron {
      width: 12px;
      height: 12px;
      flex: 0 0 12px;
      color: var(--text3);
      transition: transform 0.18s ease;
    }

    .geo-filter-continent.is-open .geo-filter-chevron {
      transform: rotate(180deg);
    }

    .geo-filter-options {
      display: none;
      padding: 0 6px 6px;
      border-top: 1px solid var(--border);
    }

    .geo-filter-continent.is-open .geo-filter-options {
      display: block;
    }

    .geo-filter-options .filter-btn {
      margin-top: 4px;
    }

    .geo-filter-options .filter-btn[data-geo-kind="country"] {
      padding-left: 14px;
      color: var(--text2);
    }
    .score-range-group {
      padding: 8px 8px 10px;
      border-top: 1px solid var(--border);
    }

    .score-range-group:first-child {
      border-top: 0;
    }

    .score-range-head {
      display: flex;
      justify-content: space-between;
      align-items: baseline;
      gap: 8px;
      margin-bottom: 6px;
    }

    .score-range-label {
      font-size: 10px;
      color: var(--text2);
      letter-spacing: 1px;
      text-transform: uppercase;
    }

    .score-range-value {
      font-size: 11px;
      color: var(--text);
      font-variant-numeric: tabular-nums;
      display: inline-flex;
      align-items: center;
      gap: 4px;
    }

    .range-slider {
      position: relative;
      height: 28px;
    }

    .range-track,
    .range-fill {
      position: absolute;
      top: 12px;
      height: 4px;
      border-radius: 999px;
      pointer-events: none;
    }

    .range-track {
      left: 0;
      right: 0;
      background: #2d3240;
    }

    .range-fill {
      background: var(--accent);
    }

    .range-ticks {
      position: absolute;
      left: 0;
      right: 0;
      top: 9px;
      height: 10px;
      pointer-events: none;
    }

    .range-tick {
      position: absolute;
      width: 1px;
      height: 10px;
      background: rgba(154, 161, 179, 0.6);
      transform: translateX(-0.5px);
    }

    .range-slider input[type="range"] {
      position: absolute;
      left: 0;
      top: 0;
      width: 100%;
      height: 28px;
      margin: 0;
      background: transparent;
      -webkit-appearance: none;
      appearance: none;
      pointer-events: none;
    }

    .range-slider input[type="range"]::-webkit-slider-runnable-track {
      height: 4px;
      background: transparent;
    }

    .range-slider input[type="range"]::-moz-range-track {
      height: 4px;
      background: transparent;
      border: 0;
    }

    .range-slider input[type="range"]::-webkit-slider-thumb {
      -webkit-appearance: none;
      appearance: none;
      width: 16px;
      height: 16px;
      border-radius: 50%;
      background: var(--accent);
      border: 2px solid var(--accent);
      box-shadow: 0 0 0 2px rgba(10, 10, 15, 0.9);
      margin-top: -6px;
      cursor: pointer;
      pointer-events: auto;
    }

    .range-slider input[type="range"]::-moz-range-thumb {
      width: 16px;
      height: 16px;
      border-radius: 50%;
      background: var(--accent);
      border: 2px solid var(--accent);
      box-shadow: 0 0 0 2px rgba(10, 10, 15, 0.9);
      cursor: pointer;
      pointer-events: auto;
    }

    .score-head-input {
      width: 54px;
      background: var(--surface2);
      border: 1px solid var(--border2);
      color: var(--text);
      border-radius: 4px;
      padding: 2px 4px;
      font-size: 10px;
      font-family: 'DM Mono', monospace;
      outline: none;
      text-align: right;
    }

    .top-search {
      padding: 10px 20px 8px;
      border-bottom: 1px solid var(--border);
      flex-shrink: 0;
      display: flex;
      align-items: center;
      gap: 10px;
      position: sticky;
      top: calc(var(--sticky-main-top) + var(--sticky-main-h));
      z-index: 1150;
      background: var(--surface);
    }

    .overview-category-tabs {
      display: flex;
      align-items: center;
      gap: 6px;
      flex-wrap: wrap;
    }

    .overview-category-tab {
      border: 1px solid var(--border);
      background: transparent;
      color: var(--text2);
      border-radius: 999px;
      padding: 5px 10px;
      font-family: 'DM Mono', monospace;
      font-size: 11px;
      cursor: pointer;
      transition: all 0.15s;
    }

    .overview-category-tab:hover {
      border-color: var(--accent2);
      color: var(--accent);
    }

    .overview-category-tab.active {
      border-color: var(--accent2);
      background: rgba(129, 201, 149, 0.14);
      color: var(--accent);
    }

    .overview-category-tab .count {
      color: var(--text3);
      margin-left: 4px;
    }

    .search-input {
      flex: 1;
      background: var(--surface2);
      border: 1px solid var(--border);
      border-radius: 6px;
      color: var(--text);
      font-family: 'DM Mono', monospace;
      font-size: 12px;
      padding: 8px 10px;
      outline: none;
      transition: border-color 0.15s;
    }

    .search-input:focus {
      border-color: var(--accent2);
    }

    .search-input::placeholder {
      color: var(--text3);
    }

    /* ── MAIN ────────────────────────────────────────────────── */
    .main {
      flex: 1;
      display: flex;
      flex-direction: column;
      overflow: hidden;
      min-width: 0;
      min-height: 0;
    }

    .main-header {
      padding: 16px 20px;
      border-bottom: 1px solid var(--border);
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      flex-shrink: 0;
      background: rgba(18, 22, 31, 0.86);
      position: sticky;
      top: var(--sticky-main-top);
      backdrop-filter: blur(6px);
      z-index: 1200;
    }

    .view-title {
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
      font-size: 22px;
      font-weight: 700;
      letter-spacing: -0.02em;
      color: var(--text);
    }

    .view-head {
      display: flex;
      align-items: baseline;
      gap: 10px;
      min-width: 0;
    }

    .view-count {
      font-size: 12px;
      color: var(--accent);
      letter-spacing: 0.01em;
      white-space: nowrap;
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    }


    .header-actions {
      display: flex;
      align-items: center;
      justify-content: flex-end;
      gap: 14px;
      flex: 1 1 auto;
      min-width: 0;
    }

    .header-refresh-group {
      display: inline-flex;
      align-items: center;
      justify-content: flex-end;
      gap: 10px;
      min-width: 0;
      margin-left: auto;
    }

    .header-refresh-status {
      font-size: 11px;
      line-height: 1.25;
      color: var(--text3);
      text-align: right;
      white-space: nowrap;
    }

    .refresh-btn {
      background: none;
      border: 1px solid var(--border);
      color: var(--text3);
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
      font-size: 10px;
      padding: 4px 12px;
      border-radius: 4px;
      cursor: pointer;
      transition: all 0.15s;
    }

    .refresh-btn:hover {
      border-color: var(--accent2);
      color: var(--accent);
    }

    .refresh-btn.is-busy {
      opacity: 0.7;
      cursor: wait;
    }

    #colsBtn {
      min-width: 110px;
      padding: 9px 10px;
      font-size: 11px;
      letter-spacing: 1.1px;
      color: var(--text2);
      background: var(--surface2);
      border-radius: 8px;
      text-align: left;
    }

    #colsBtn:hover {
      color: var(--accent);
      border-color: var(--border2);
      background: rgba(129, 201, 149, 0.08);
    }

    /* ── TABLE ───────────────────────────────────────────────── */
    .table-wrapper {
      flex: 1;
      min-height: 0;
      overflow-y: auto;
      overflow-x: auto;
      background: rgba(21, 26, 35, 0.96);
      border: 1px solid rgba(160, 178, 208, 0.12);
      border-radius: 14px;
      box-shadow: 0 24px 48px rgba(0, 0, 0, 0.22);
    }

    .asset-view {
      flex: 1;
      min-height: 0;
      display: flex;
      flex-direction: column;
      background: var(--surface);
    }

    .asset-view.hidden {
      display: none;
    }

    html[data-initial-view="framework"] #assetView {
      display: none;
    }

    .framework-view {
      display: none;
      flex: 1;
      min-height: 0;
      overflow-y: auto;
      padding: 8px 28px 22px;
      background: rgba(0, 0, 0, 0.78);
    }

    .framework-view.active {
      display: block;
    }

    html[data-initial-view="framework"] #frameworkView {
      display: block;
    }

    .framework-top {
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 12px;
      margin-bottom: 14px;
    }

    .framework-meta {
      color: var(--text2);
      font-size: 11px;
    }

    .performance-shell {
      width: 100%;
      max-width: none;
      margin: 0;
    }

    .performance-control-panel {
      border: 1px solid var(--border2);
      border-radius: 10px;
      background: linear-gradient(180deg, rgba(21, 26, 35, 0.98), rgba(12, 16, 24, 0.98));
      box-shadow: 0 22px 48px rgba(0, 0, 0, 0.34);
      margin-bottom: 12px;
      overflow: hidden;
    }

    .performance-control-head {
      display: flex;
      justify-content: space-between;
      gap: 16px;
      align-items: center;
      padding: 10px 20px 8px;
      border-bottom: 1px solid var(--border);
    }

    .performance-kicker {
      font-size: 10px;
      text-transform: uppercase;
      letter-spacing: 1.4px;
      color: var(--accent);
      margin-bottom: 6px;
      font-weight: 700;
    }

    .performance-control-title {
      font-family: 'Fraunces', serif;
      color: var(--text);
      font-size: 20px;
      line-height: 1.1;
      margin: 0;
    }

    .performance-control-copy {
      color: var(--text2);
      margin: 0;
      max-width: 860px;
      font-size: 11px;
      line-height: 1.4;
    }

    .performance-refresh {
      flex: 0 0 auto;
      border: 1px solid var(--border2);
      background: rgba(129, 201, 149, 0.08);
      color: var(--accent);
      border-radius: 8px;
      padding: 8px 12px;
      font-size: 11px;
      font-family: 'DM Mono', monospace;
      cursor: pointer;
      transition: all 0.15s;
      white-space: nowrap;
    }

    .performance-refresh:hover {
      background: rgba(129, 201, 149, 0.16);
      border-color: var(--accent2);
    }

    .performance-control-grid {
      display: grid;
      grid-template-columns: minmax(220px, 0.48fr) minmax(520px, 1.52fr);
      gap: 30px;
      padding: 14px 22px 18px;
    }

    .strategy-label,
    .slider-label-row {
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 10px;
      font-size: 10px;
      letter-spacing: 1.2px;
      text-transform: uppercase;
      color: var(--text2);
      margin-bottom: 8px;
    }

    .strategy-buttons {
      display: grid;
      grid-template-columns: 1fr;
      gap: 14px;
    }

    .strategy-btn {
      text-align: left;
      border: 1px solid var(--border);
      background: rgba(8, 12, 18, 0.8);
      color: var(--text2);
      border-radius: 8px;
      padding: 15px 16px;
      cursor: pointer;
      transition: border-color 0.15s, background 0.15s, color 0.15s, box-shadow 0.15s;
      font-family: 'DM Mono', monospace;
      min-height: 108px;
    }

    .strategy-btn:hover,
    .strategy-btn.active {
      border-color: rgba(129, 201, 149, 0.48);
      background: rgba(129, 201, 149, 0.1);
      color: var(--text);
    }

    .strategy-btn.active {
      box-shadow: inset 0 0 0 1px rgba(129, 201, 149, 0.12);
    }

    .strategy-btn strong {
      display: flex;
      align-items: center;
      gap: 8px;
      color: inherit;
      font-size: 18px;
      margin-bottom: 6px;
    }

    .strategy-icon {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 22px;
      flex: 0 0 22px;
      font-size: 19px;
      line-height: 1;
    }

    .strategy-btn span {
      display: block;
      color: var(--text3);
      font-size: 12px;
      line-height: 1.38;
    }

    .performance-sliders {
      display: grid;
      gap: 24px;
      align-content: center;
      width: 100%;
    }

    .slider-value {
      color: var(--accent);
      border: 1px solid rgba(129, 201, 149, 0.32);
      background: rgba(129, 201, 149, 0.08);
      border-radius: 5px;
      padding: 2px 7px;
      font-size: 10px;
    }

    .performance-range {
      width: 100%;
      accent-color: var(--accent);
      appearance: none;
      height: 14px;
      border-radius: 999px;
      background: linear-gradient(90deg, rgba(239, 154, 154, 0.38), rgba(255, 249, 196, 0.34), rgba(129, 201, 149, 0.52));
      outline: none;
    }

    .performance-range::-webkit-slider-thumb {
      appearance: none;
      width: 24px;
      height: 24px;
      border-radius: 50%;
      background: var(--accent);
      border: 3px solid #101720;
      box-shadow: 0 0 0 1px rgba(129, 201, 149, 0.8), 0 8px 18px rgba(0, 0, 0, 0.4);
      cursor: pointer;
    }

    .performance-range::-moz-range-thumb {
      width: 20px;
      height: 20px;
      border-radius: 50%;
      background: var(--accent);
      border: 3px solid #101720;
      box-shadow: 0 0 0 1px rgba(129, 201, 149, 0.8), 0 8px 18px rgba(0, 0, 0, 0.4);
      cursor: pointer;
    }

    .range-scale {
      display: flex;
      justify-content: space-between;
      color: var(--text3);
      font-size: 9px;
      margin-top: 5px;
    }

    .framework-metrics-row {
      display: grid;
      grid-template-columns: 170px minmax(0, 1fr);
      gap: 12px;
      align-items: stretch;
      margin-bottom: 12px;
    }

    .framework-horizon-context {
      border: 1px solid rgba(255, 255, 255, 0.74);
      border-radius: 8px;
      background: rgba(255, 255, 255, 0.045);
      box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.13);
      padding: 13px 14px;
      display: flex;
      flex-direction: column;
      justify-content: center;
      gap: 7px;
      min-height: 88px;
    }

    .framework-horizon-kicker {
      color: var(--text2);
      font-size: 9px;
      letter-spacing: 1.2px;
      text-transform: uppercase;
    }

    .framework-horizon-value {
      color: #ffffff;
      font-family: 'DM Mono', monospace;
      font-size: 26px;
      font-weight: 800;
      line-height: 1;
    }

    .framework-horizon-copy {
      color: var(--text2);
      font-size: 11px;
      line-height: 1.25;
    }

    .framework-cards {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 12px;
    }

    .framework-card {
      border: 1px solid var(--border);
      border-radius: 8px;
      background: rgba(21, 26, 35, 0.96);
      padding: 13px 14px;
      box-shadow: 0 14px 28px rgba(0, 0, 0, 0.26);
      min-height: 88px;
    }

    .framework-card.is-selected-horizon {
      background: rgba(25, 30, 39, 0.98);
    }

    .framework-card-score {
      display: flex;
      flex-direction: column;
      justify-content: flex-start;
      gap: 10px;
    }

    .framework-card.is-filtered {
      border-color: rgba(129, 201, 149, 0.36);
      background: linear-gradient(180deg, rgba(21, 34, 27, 0.96), rgba(16, 24, 22, 0.96));
    }

    .framework-card.is-advantage {
      border-color: rgba(255, 255, 255, 0.72);
      background: linear-gradient(180deg, rgba(28, 34, 44, 0.98), rgba(16, 20, 28, 0.98));
      box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.18),
        0 16px 34px rgba(0, 0, 0, 0.34),
        0 0 22px rgba(255, 255, 255, 0.08);
    }

    .framework-card.is-advantage .framework-card-label {
      color: #ffffff;
    }

    .framework-card.is-advantage .framework-card-threshold {
      color: #ffffff;
      border-color: rgba(255, 255, 255, 0.42);
      background: rgba(255, 255, 255, 0.09);
    }

    .framework-card-headline {
      display: flex;
      align-items: center;
      justify-content: flex-start;
      gap: 8px;
    }

    .framework-card-threshold {
      color: var(--text);
      border: 1px solid rgba(255, 255, 255, 0.28);
      background: rgba(255, 255, 255, 0.04);
      border-radius: 4px;
      padding: 3px 7px;
      font-size: 11px;
      font-weight: 750;
      line-height: 1.2;
      white-space: nowrap;
    }

    .framework-card-label {
      font-size: 12px;
      font-weight: 800;
      text-transform: uppercase;
      letter-spacing: 0.8px;
      color: var(--text);
      margin-bottom: 0;
    }

    .framework-card-metric {
      display: flex;
      align-items: baseline;
      gap: 8px;
    }

    .framework-card-value {
      font-family: 'DM Mono', monospace;
      font-size: 28px;
      font-weight: 800;
      color: var(--text);
      line-height: 1.1;
      margin-bottom: 0;
    }

    .framework-card-value.positive {
      color: var(--accent);
    }

    .framework-card-value.negative {
      color: #EF9A9A;
    }

    .framework-card-sub {
      color: var(--text2);
      font-size: 11px;
      line-height: 1.2;
      white-space: nowrap;
    }

    .framework-card-sub.is-hidden {
      display: none;
    }

    .framework-block {
      border: 1px solid var(--border);
      border-radius: 8px;
      background: rgba(21, 26, 35, 0.96);
      box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
      margin-bottom: 12px;
      overflow: hidden;
    }

    .framework-block-title {
      font-size: 10px;
      letter-spacing: 1.2px;
      text-transform: uppercase;
      color: var(--text2);
      padding: 10px 12px;
      border-bottom: 1px solid var(--border);
      background: var(--surface2);
    }

    .framework-filter-row {
      display: flex;
      flex-wrap: wrap;
      gap: 10px;
      align-items: center;
      justify-content: center;
      padding: 10px 12px;
      border-bottom: 1px solid var(--border);
      background: #0a0a0f;
    }

    .framework-band-title-main {
      text-align: center;
      font-size: 16px;
      letter-spacing: 0.9px;
      color: var(--text);
      font-family: 'Fraunces', serif;
      text-transform: none;
      font-weight: 600;
    }

    .framework-title-action-row {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
    }

    .framework-data-badge {
      border: 1px solid rgba(129, 201, 149, 0.32);
      background: rgba(129, 201, 149, 0.08);
      color: var(--accent);
      border-radius: 4px;
      padding: 4px 8px;
      font-size: 10px;
      font-family: 'DM Mono', monospace;
      white-space: nowrap;
    }

    .framework-asset-btn {
      border: 1px solid var(--border2);
      background: rgba(129, 201, 149, 0.08);
      color: var(--accent);
      border-radius: 6px;
      padding: 6px 10px;
      font-size: 11px;
      font-family: 'DM Mono', monospace;
      cursor: pointer;
      transition: all 0.15s;
      white-space: nowrap;
    }

    .framework-asset-btn:hover {
      background: rgba(129, 201, 149, 0.16);
      border-color: var(--accent2);
    }

    .framework-fixed-filter {
      color: var(--text);
      font-size: 12px;
      letter-spacing: 0.4px;
      text-transform: uppercase;
      text-align: center;
    }

    .framework-block-title-toggle {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
    }

    .framework-filter-group {
      display: flex;
      align-items: center;
      gap: 6px;
    }

    .framework-filter-group label {
      font-size: 10px;
      color: var(--text2);
      text-transform: uppercase;
      letter-spacing: 1px;
      white-space: nowrap;
    }

    .framework-filter-input {
      width: 58px;
      background: var(--surface2);
      border: 1px solid var(--border2);
      color: var(--text);
      border-radius: 6px;
      padding: 5px 6px;
      font-size: 11px;
      font-family: 'DM Mono', monospace;
      outline: none;
    }

    .asset-filters-backdrop {
      position: fixed;
      inset: 0;
      background: rgba(0, 0, 0, 0.58);
      z-index: 1250;
      opacity: 0;
      pointer-events: none;
      transition: opacity 0.2s ease;
    }

    .asset-filters-backdrop.open {
      opacity: 1;
      pointer-events: auto;
    }

    .asset-filters-modal {
      position: fixed;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -48%) scale(0.985);
      width: min(1040px, 94vw);
      max-height: min(760px, 92vh);
      background: linear-gradient(180deg, #0b1019 0%, #090d15 100%);
      border: 1px solid var(--border2);
      border-radius: 24px;
      box-shadow: 0 28px 64px rgba(0, 0, 0, 0.62);
      z-index: 1260;
      opacity: 0;
      pointer-events: none;
      transition: transform 0.2s ease, opacity 0.2s ease;
      display: flex;
      flex-direction: column;
      overflow: hidden;
    }

    .asset-filters-modal.open {
      opacity: 1;
      pointer-events: auto;
      transform: translate(-50%, -50%) scale(1);
    }

    .asset-filters-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      padding: 24px 28px 18px;
      border-bottom: 1px solid var(--border);
      background: rgba(10, 14, 23, 0.92);
    }

    .asset-filters-title {
      display: flex;
      flex-direction: column;
      gap: 6px;
    }

    .asset-filters-title strong {
      font-size: 20px;
      line-height: 1.1;
      color: var(--text);
      font-weight: 700;
    }

    .asset-filters-title span {
      color: var(--text3);
      font-size: 14px;
    }

    .asset-filters-close {
      width: 34px;
      height: 34px;
      border-radius: 999px;
      border: 1px solid transparent;
      background: transparent;
      color: var(--text2);
      cursor: pointer;
      transition: all 0.15s;
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
      font-size: 22px;
      line-height: 1;
    }

    .asset-filters-close:hover {
      color: var(--accent);
      border-color: rgba(129, 201, 149, 0.2);
      background: rgba(129, 201, 149, 0.06);
    }

    .asset-filters-body {
      display: grid;
      grid-template-columns: 230px minmax(0, 1fr);
      min-height: 0;
      flex: 1 1 auto;
    }

    .asset-filters-nav {
      display: flex;
      flex-direction: column;
      gap: 6px;
      padding: 20px 16px;
      background: rgba(6, 10, 17, 0.88);
      border-right: 1px solid var(--border);
    }

    .asset-filter-nav-btn {
      position: relative;
      display: flex;
      align-items: center;
      gap: 12px;
      width: 100%;
      padding: 12px 14px;
      border: 1px solid transparent;
      border-radius: 14px;
      background: transparent;
      color: var(--text2);
      text-align: left;
      cursor: pointer;
      transition: all 0.18s ease;
    }

    .asset-filter-nav-btn::after {
      content: "";
      position: absolute;
      right: -17px;
      top: 12px;
      bottom: 12px;
      width: 3px;
      border-radius: 999px;
      background: transparent;
      transition: background 0.18s ease;
    }

    .asset-filter-nav-btn::before {
      content: attr(data-filter-count);
      position: absolute;
      top: 7px;
      right: 8px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-width: 16px;
      height: 16px;
      border-radius: 999px;
      border: 1px solid rgba(255, 255, 255, 0.14);
      background: rgba(255, 255, 255, 0.05);
      color: var(--text3);
      font-family: 'DM Mono', monospace;
      font-size: 9px;
      line-height: 1;
    }

    .asset-filter-nav-btn.has-active-filters::before {
      border-color: rgba(129, 201, 149, 0.5);
      background: rgba(129, 201, 149, 0.16);
      color: var(--accent);
    }

    .asset-filter-nav-btn:hover {
      color: var(--text);
      background: rgba(255, 255, 255, 0.03);
    }

    .asset-filter-nav-btn.is-active {
      color: var(--accent);
      background: rgba(18, 44, 42, 0.5);
      border-color: rgba(76, 175, 114, 0.22);
    }

    .asset-filter-nav-btn.is-active::after {
      background: linear-gradient(180deg, var(--accent) 0%, #10b981 100%);
      box-shadow: 0 0 14px rgba(76, 175, 114, 0.36);
    }

    .asset-filter-nav-icon {
      width: 18px;
      height: 18px;
      flex: 0 0 18px;
      color: currentColor;
      opacity: 0.95;
    }

    .asset-filter-nav-copy {
      display: flex;
      flex-direction: column;
      gap: 3px;
      min-width: 0;
    }

    .asset-filter-nav-label {
      font-size: 16px;
      font-weight: 600;
      line-height: 1.1;
    }

    .asset-filter-nav-meta {
      color: var(--text3);
      font-size: 10px;
      letter-spacing: 0.14em;
      text-transform: uppercase;
    }

    .asset-filters-content {
      min-width: 0;
      min-height: 0;
      padding: 26px 28px 18px;
      display: flex;
      flex-direction: column;
      overflow: hidden;
      background: rgba(17, 22, 33, 0.92);
    }

    .asset-filter-panel {
      display: none;
      flex-direction: column;
      min-height: 0;
      flex: 1 1 auto;
    }

    .asset-filter-panel.is-active {
      display: flex;
    }

    .asset-filter-panel-head {
      display: flex;
      flex-direction: column;
      gap: 6px;
      padding-bottom: 18px;
    }

    .asset-filter-panel-head h3 {
      font-size: 12px;
      letter-spacing: 0.18em;
      text-transform: uppercase;
      color: var(--text2);
      font-weight: 700;
    }

    .asset-filter-panel-head p {
      color: var(--text3);
      font-size: 13px;
    }

    .asset-filter-section {
      min-height: 0;
      flex: 1 1 auto;
      overflow: auto;
    }

    #scoreFilters {
      display: block;
      padding: 2px 0 0;
    }

    #scoreFilters .score-range-group {
      border: 1px solid var(--border);
      border-radius: 16px;
      background: rgba(255, 255, 255, 0.02);
      padding: 14px 16px;
      margin-bottom: 12px;
    }

    #borsaFilters,
    #continenteFilters,
    #nazioneFilters,
    #settoreFilters {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 12px;
      padding: 0;
    }

    .asset-filter-panel .filter-btn {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
      min-height: 54px;
      padding: 14px 16px;
      border: 1px solid rgba(160, 178, 208, 0.12);
      border-radius: 14px;
      background: rgba(255, 255, 255, 0.035);
      color: var(--text2);
      font-size: 14px;
      font-weight: 500;
      box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.02);
    }

    .asset-filter-panel .filter-btn:hover {
      background: rgba(255, 255, 255, 0.06);
      border-color: rgba(160, 178, 208, 0.2);
      color: var(--text);
      transform: translateY(0);
      box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    }

    .asset-filter-panel .filter-btn.active {
      background: rgba(19, 63, 54, 0.6);
      border-color: rgba(76, 175, 114, 0.42);
      color: #ddfff3;
    }

    .asset-filter-panel .filter-btn .count {
      float: none;
      flex: 0 0 auto;
      min-width: 22px;
      padding: 3px 8px;
      border-radius: 999px;
      background: rgba(11, 15, 22, 0.52);
      color: var(--text3);
      font-size: 11px;
      text-align: center;
    }

    .asset-filter-panel .filter-btn-meta,
    .sector-industry-option .filter-btn-meta {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      flex: 0 0 auto;
    }

    .filter-check {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 20px;
      height: 20px;
      border: 1px solid rgba(76, 175, 114, 0.56);
      border-radius: 5px;
      background: rgba(11, 15, 22, 0.38);
      position: relative;
      flex: 0 0 auto;
    }

    .filter-check.is-clickable {
      cursor: pointer;
    }

    .filter-check.is-checked {
      background: rgba(16, 185, 129, 0.2);
      border-color: rgba(76, 175, 114, 0.78);
    }

    .filter-check.is-checked::after {
      content: "";
      width: 6px;
      height: 11px;
      border-right: 2px solid #4CAF72;
      border-bottom: 2px solid #4CAF72;
      transform: rotate(42deg) translate(-1px, -1px);
      transform-origin: center;
    }

    .sector-filter-row {
      cursor: default;
    }

    .sector-open-btn {
      flex: 1 1 auto;
      min-width: 0;
      border: none;
      background: transparent;
      color: inherit;
      font: inherit;
      font-weight: inherit;
      text-align: left;
      cursor: pointer;
    }

    .asset-filter-panel .filter-btn.active .count {
      color: var(--accent);
      background: rgba(8, 18, 18, 0.66);
    }

    .asset-filter-panel .filter-btn.is-industry {
      margin-left: 14px;
      min-height: 46px;
      font-size: 12px;
      color: var(--text2);
    }

    .sector-industry-popup {
      position: absolute;
      inset: 0;
      z-index: 4;
      display: none;
      align-items: center;
      justify-content: center;
      padding: 28px;
      background: rgba(6, 10, 17, 0.72);
    }

    .sector-industry-popup.open {
      display: flex;
    }

    .sector-industry-card {
      width: min(620px, 100%);
      max-height: min(620px, 82vh);
      display: flex;
      flex-direction: column;
      overflow: hidden;
      border: 1px solid var(--border2);
      border-radius: 8px;
      background: #0d1420;
      box-shadow: 0 24px 60px rgba(0, 0, 0, 0.52);
    }

    .sector-industry-head {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 16px;
      padding: 18px 20px;
      border-bottom: 1px solid var(--border);
    }

    .sector-industry-title {
      display: flex;
      flex-direction: column;
      gap: 5px;
      min-width: 0;
    }

    .sector-industry-title strong {
      color: var(--text);
      font-size: 17px;
    }

    .sector-industry-title span {
      color: var(--text3);
      font-size: 13px;
    }

    .sector-industry-close {
      border: 1px solid var(--border);
      border-radius: 8px;
      background: rgba(255, 255, 255, 0.04);
      color: var(--text2);
      width: 34px;
      height: 34px;
      cursor: pointer;
      font-weight: 800;
    }

    .sector-industry-options {
      display: grid;
      grid-template-columns: 1fr;
      gap: 10px;
      padding: 16px;
      overflow: auto;
    }

    .sector-industry-option {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 14px;
      min-height: 48px;
      padding: 12px 14px;
      border: 1px solid rgba(160, 178, 208, 0.12);
      border-radius: 8px;
      background: rgba(255, 255, 255, 0.035);
      color: var(--text2);
      font-size: 14px;
      font-weight: 600;
      text-align: left;
      cursor: pointer;
    }

    .sector-industry-option:hover {
      border-color: rgba(160, 178, 208, 0.22);
      background: rgba(255, 255, 255, 0.06);
      color: var(--text);
    }

    .sector-industry-option.active {
      border-color: rgba(76, 175, 114, 0.46);
      background: rgba(19, 63, 54, 0.58);
      color: #ddfff3;
    }

    .sector-industry-option .count {
      min-width: 22px;
      padding: 3px 8px;
      border-radius: 999px;
      background: rgba(11, 15, 22, 0.52);
      color: var(--text3);
      font-size: 11px;
      text-align: center;
    }

    .asset-filter-footer {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 14px;
      padding: 18px 28px 22px;
      border-top: 1px solid var(--border);
      background: rgba(6, 10, 17, 0.94);
    }

    .asset-filters-reset {
      border: none;
      background: transparent;
      color: var(--text3);
      font-size: 14px;
      cursor: pointer;
      transition: color 0.18s ease;
    }

    .asset-filters-reset:hover {
      color: var(--text2);
    }

    .asset-filters-apply {
      min-width: 236px;
      border: 1px solid rgba(16, 185, 129, 0.44);
      border-radius: 14px;
      background: linear-gradient(180deg, #10b981 0%, #0f9b72 100%);
      color: #effff8;
      font-size: 16px;
      font-weight: 700;
      padding: 14px 18px;
      cursor: pointer;
      transition: transform 0.18s ease, box-shadow 0.18s ease;
      box-shadow: 0 16px 32px rgba(16, 185, 129, 0.2);
    }

    .asset-filters-apply:hover {
      transform: translateY(-1px);
      box-shadow: 0 18px 34px rgba(16, 185, 129, 0.24);
    }

    .asset-filters-apply:active {
      transform: translateY(0);
    }

    @media (max-width: 860px) {
      .asset-filters-modal {
        width: min(96vw, 720px);
        max-height: 94vh;
      }

      .asset-filters-body {
        grid-template-columns: 1fr;
      }

      .asset-filters-nav {
        border-right: none;
        border-bottom: 1px solid var(--border);
        padding: 14px;
        overflow-x: auto;
        flex-direction: row;
      }

      .asset-filter-nav-btn {
        min-width: 180px;
      }

      .asset-filter-nav-btn::after {
        display: none;
      }

      .asset-filters-content {
        padding: 20px 18px 14px;
      }

      #borsaFilters,
      #continenteFilters,
      #nazioneFilters,
      #settoreFilters {
        grid-template-columns: 1fr;
      }

      .asset-filter-footer {
        padding: 16px 18px 18px;
        flex-direction: column;
        align-items: stretch;
      }

      .asset-filters-apply {
        width: 100%;
        min-width: 0;
      }
    }

    .framework-table-wrap {
      overflow: auto;
      background: transparent;
      box-shadow: none;
    }

    .framework-sample-note {
      margin: 10px 2px 0;
      color: var(--text2);
      font-size: 11px;
      line-height: 1.45;
    }

    .framework-table {
      width: 100%;
      min-width: 760px;
      border-collapse: collapse;
    }

    .framework-table th {
      position: static;
      cursor: default;
      text-align: center;
      font-size: 10px;
      color: var(--text2);
      padding: 12px 14px;
      border-bottom: 1px solid var(--border2);
      text-transform: uppercase;
      letter-spacing: 1px;
      background: var(--bg);
    }

    .framework-table th[data-fsort] {
      cursor: pointer;
      user-select: none;
    }

    .framework-table th[data-fsort].sorted {
      color: var(--accent);
    }

    .framework-table th[data-fsort].sorted::after {
      content: attr(data-sort-arrow);
      margin-left: 4px;
      color: var(--accent);
      font-family: 'DM Mono', monospace;
    }

    .framework-table td {
      text-align: center;
      padding: 12px 14px;
      border-bottom: 1px solid var(--border);
      font-size: 12px;
      color: var(--text);
      white-space: nowrap;
    }

    .framework-table tbody tr:hover td {
      background: var(--surface2);
    }

    .framework-table td:first-child,
    .framework-table th:first-child {
      text-align: left;
      padding-left: 12px;
    }

    #frameworkBandTable {
      min-width: 1040px;
      table-layout: fixed;
    }

    #frameworkBandTable th,
    #frameworkBandTable td {
      text-align: center;
      padding-left: 10px;
      padding-right: 10px;
    }

    #frameworkBandTable th:first-child,
    #frameworkBandTable td:first-child {
      width: 170px;
      text-align: left;
      padding-left: 20px;
      font-weight: 800;
    }

    .heat-cell {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-width: 118px;
      border: 1px solid transparent;
      border-radius: 4px;
      padding: 8px 10px;
      font-weight: 800;
    }

    .heat-cell-empty {
      color: #666;
      font-weight: 500;
    }

    .bg-green-strong {
      color: #d9ffe5;
      background: rgba(29, 131, 62, 0.54);
      border-color: rgba(66, 211, 107, 0.42);
    }

    .bg-green {
      color: #81C995;
      background: rgba(22, 84, 48, 0.44);
      border-color: rgba(129, 201, 149, 0.24);
    }

    .bg-green-soft {
      color: #81C995;
      background: rgba(28, 65, 45, 0.3);
    }

    .bg-red-strong {
      color: #ffd7d7;
      background: rgba(127, 38, 46, 0.58);
      border-color: rgba(239, 83, 80, 0.42);
    }

    .bg-red {
      color: #EF9A9A;
      background: rgba(101, 39, 45, 0.42);
      border-color: rgba(239, 154, 154, 0.22);
    }

    .bg-red-soft {
      color: #EF9A9A;
      background: rgba(74, 42, 44, 0.3);
    }

    .bg-neutral {
      color: #FFF9C4;
      background: rgba(107, 99, 42, 0.18);
    }

    .framework-band-count {
      color: var(--text2);
      font-size: 11px;
    }

    .framework-band-row-active td:first-child {
      box-shadow: inset 3px 0 0 var(--accent);
    }

    @media (max-width: 900px) {
      .framework-view {
        padding: 14px 12px 22px;
      }

      .performance-control-head,
      .performance-control-grid {
        grid-template-columns: 1fr;
      }

      .performance-control-head {
        flex-direction: column;
      }

      .framework-metrics-row,
      .framework-cards {
        grid-template-columns: 1fr;
      }

      .strategy-buttons {
        grid-template-columns: 1fr;
      }
    }

    .framework-assets-backdrop {
      position: fixed;
      inset: 0;
      background: rgba(0, 0, 0, 0.58);
      z-index: 1270;
      opacity: 0;
      pointer-events: none;
      transition: opacity 0.2s ease;
    }

    .framework-assets-backdrop.open {
      opacity: 1;
      pointer-events: auto;
    }

    .framework-assets-modal {
      position: fixed;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -48%) scale(0.985);
      width: min(1320px, 96vw);
      max-height: min(760px, 92vh);
      background: #060609;
      border: 1px solid var(--border2);
      border-radius: 12px;
      box-shadow: 0 28px 64px rgba(0, 0, 0, 0.62);
      z-index: 1280;
      opacity: 0;
      pointer-events: none;
      transition: transform 0.2s ease, opacity 0.2s ease;
      display: flex;
      flex-direction: column;
      overflow: hidden;
    }

    .framework-assets-modal.open {
      opacity: 1;
      pointer-events: auto;
      transform: translate(-50%, -50%) scale(1);
    }

    .framework-assets-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
      padding: 12px 14px;
      border-bottom: 1px solid var(--border);
      background: var(--surface2);
    }

    .framework-assets-title {
      font-size: 12px;
      letter-spacing: 0.6px;
      color: var(--text);
      text-transform: uppercase;
    }

    .framework-assets-close {
      width: 28px;
      height: 28px;
      border-radius: 6px;
      border: 1px solid var(--border2);
      background: transparent;
      color: var(--text2);
      cursor: pointer;
      font-family: 'DM Mono', monospace;
      transition: all 0.15s;
    }

    .framework-assets-close:hover {
      color: var(--accent);
      border-color: var(--accent2);
    }

    .framework-assets-wrap {
      overflow: auto;
      padding: 8px 10px 12px;
    }

    #frameworkAssetsTable {
      min-width: 980px;
    }

    #frameworkAssetsTable th,
    #frameworkAssetsTable td {
      white-space: nowrap;
      vertical-align: middle;
    }

    .framework-asset-link {
      appearance: none;
      border: 0;
      background: transparent;
      color: inherit;
      cursor: pointer;
      padding: 0;
      text-align: left;
      min-width: 138px;
      max-width: 185px;
      white-space: normal;
    }

    .framework-asset-link:hover .framework-asset-ticker,
    .framework-asset-link:focus-visible .framework-asset-ticker {
      color: var(--accent);
      text-decoration: underline;
      text-underline-offset: 3px;
    }

    .framework-asset-ticker {
      display: block;
      color: var(--text);
      font-family: 'DM Mono', monospace;
      font-size: 12px;
      font-weight: 800;
      line-height: 1.2;
    }

    .framework-asset-company {
      display: block;
      margin-top: 2px;
      color: var(--text2);
      font-size: 10px;
      line-height: 1.2;
    }

    .framework-price-cell {
      font-family: 'DM Mono', monospace;
      color: var(--text);
      font-size: 11px;
      text-align: right;
    }

    .framework-perf-cell {
      display: inline-flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      gap: 2px;
      min-width: 82px;
      border: 1px solid transparent;
      border-radius: 4px;
      padding: 5px 7px;
      line-height: 1.1;
    }

    .framework-table th.is-selected-horizon,
    .framework-table td.is-selected-horizon {
      background: rgba(255, 255, 255, 0.075);
    }

    .framework-table th[data-framework-horizon] {
      cursor: pointer;
      user-select: none;
    }

    .framework-table th[data-framework-horizon]:hover {
      color: #ffffff;
      background: rgba(255, 255, 255, 0.05);
    }

    .framework-table th.is-selected-horizon {
      color: #ffffff;
    }

    .framework-perf-pct {
      font-weight: 800;
      font-size: 11px;
      font-family: 'DM Mono', monospace;
    }

    .framework-perf-price {
      color: var(--text2);
      font-size: 10px;
      font-family: 'DM Mono', monospace;
    }

    .pill-hit {
      display: inline-block;
      border-radius: 999px;
      padding: 3px 8px;
      font-size: 10px;
      font-weight: 600;
      letter-spacing: 0.4px;
      text-transform: uppercase;
    }

    .table-wrapper::-webkit-scrollbar {
      width: 6px;
      height: 6px;
    }

    .table-wrapper::-webkit-scrollbar-track {
      background: var(--surface);
    }

    .table-wrapper::-webkit-scrollbar-thumb {
      background: var(--border2);
      border-radius: 3px;
    }

    table {
      width: 100%;
      border-collapse: collapse;
      min-width: 860px;
      font-variant-numeric: tabular-nums;
    }

    #mainTable thead th {
      position: sticky;
      top: 0;
      z-index: 50;
      background: #141923;
      padding: 12px 14px;
      line-height: 1.15;
      height: 56px;
      vertical-align: middle;
    }

    html.embedded-shell #mainTable thead th { top: 0; }


    thead th {
      background: #141923;
      border-bottom: 1px solid var(--border2);
      padding: 14px 14px 13px;
      text-align: left;
      font-size: 10px;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      color: var(--text2);
      font-weight: 600;
      white-space: normal;
      line-height: 1.3;
      vertical-align: middle;
      cursor: pointer;
      user-select: none;
      transition: color 0.15s;
    }

    thead th:hover {
      color: var(--text2);
    }

    thead th.sorted {
      color: var(--accent);
    }

    thead th.center {
      text-align: center;
    }

    #mainTable thead th.col-unlocked {
      padding-right: 18px;
      position: relative;
    }

    .col-resizer {
      position: absolute;
      top: 0;
      right: -2px;
      width: 8px;
      height: 100%;
      cursor: col-resize;
      z-index: 20;
      touch-action: none;
    }

    .col-resizer::after {
      content: "";
      position: absolute;
      top: 20%;
      bottom: 20%;
      left: 3px;
      width: 2px;
      border-radius: 2px;
      background: rgba(129, 201, 149, 0.85);
      transition: background 0.15s;
    }

    .col-resizer:hover::after {
      background: rgba(129, 201, 149, 0.9);
    }

    tbody tr {
      border-bottom: 1px solid rgba(160, 178, 208, 0.1);
      transition: background 0.1s;
      cursor: pointer;
    }

    tbody tr:hover {
      background: rgba(255, 255, 255, 0.018);
    }

    tbody tr.selected {
      background: rgba(129, 201, 149, 0.06);
    }

    .holding-dot {
      display: inline-block;
      width: 10px;
      height: 10px;
      border-radius: 50%;
      border: 1px solid var(--border2);
      background: rgba(255, 255, 255, 0.08);
      vertical-align: middle;
    }

    .holding-dot.on {
      background: #4CAF72;
      border-color: #81C995;
      box-shadow: 0 0 8px rgba(129, 201, 149, 0.7);
    }

    .holding-dot.off {
      opacity: 0.35;
      box-shadow: none;
    }

    tbody td {
      padding: 12px 14px;
      font-size: 12px;
      border-bottom: 1px solid var(--border);
    }

    #mainTable tbody td {
      padding: 12px 14px;
      line-height: 1.15;
    }

    td {
      padding: 10px 12px;
      vertical-align: middle;
      white-space: normal;
      line-height: 1.25;
      max-width: 100%;
      text-align: center;
    }

    /* ── CELLE TABELLA ───────────────────────────────────────── */
    .td-azienda {
      min-width: 220px;
      width: 220px;
      max-width: 220px;
      text-align: left;
    }

    .azienda-cell {
      display: flex;
      align-items: center;
      gap: 10px;
      min-width: 0;
    }

    .asset-logo {
      width: 34px;
      height: 34px;
      border-radius: 999px;
      background: #20293a;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      color: #dbe6ff;
      font-size: 10px;
      font-weight: 700;
      text-transform: uppercase;
      overflow: hidden;
      flex: 0 0 34px;
      border: 1px solid rgba(160, 178, 208, 0.16);
    }

    .asset-logo img {
      width: 100%;
      height: 100%;
      object-fit: contain;
      display: block;
      padding: 2px;
    }

    .azienda-main {
      display: flex;
      flex-direction: column;
      min-width: 0;
      flex: 1;
    }

    .azienda-ticker {
      font-size: 15px;
      font-weight: 700;
      color: #ffffff;
      letter-spacing: -0.01em;
      line-height: 1.05;
    }

    .azienda-nome {
      display: block;
      font-size: 12px;
      color: var(--text3);
      margin-top: 3px;
      white-space: nowrap;
      line-height: 1.05;
      max-width: 100%;
      width: 100%;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .td-settore {
      font-size: 10px;
      color: var(--text);
      min-width: 80px;
    }

    .td-prezzo {
      min-width: 102px;
    }

    .prezzo-val {
      color: #f7f9fd;
      font-size: 14px;
      font-weight: 600;
    }

    .prezzo-data {
      font-size: 10px;
      color: var(--text3);
      margin-top: 4px;
    }

    .td-fv {
      color: var(--text);
      font-size: 12px;
      min-width: 68px;
    }

    .td-target {
      color: var(--text);
      font-size: 12px;
      min-width: 68px;
    }

    /* Score badges */
    .score-badge {
      display: inline-block;
      padding: 3px 8px;
      border-radius: 4px;
      font-size: 12px;
      font-weight: 500;
      text-align: center;
      min-width: 44px;
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
      font-variant-numeric: tabular-nums;
    }

    .th-num {
      text-align: center !important;
    }

    .td-num {
      text-align: center !important;
      font-variant-numeric: tabular-nums;
    }

    .td-num .prezzo-val,
    .td-num .prezzo-data,
    .td-num .obj-row {
      text-align: center;
      justify-content: center;
    }

    .td-score {
      min-width: 96px;
    }

    .asset-score {
      background: none !important;
      border: none !important;
      box-shadow: none !important;
      padding: 0 !important;
      min-width: 0 !important;
      border-radius: 0 !important;
      font-size: 16px;
      font-weight: 600;
      letter-spacing: -0.01em;
      line-height: 1;
    }

    .asset-score--focus {
      padding: 7px 12px !important;
      min-width: 68px !important;
      border-radius: 6px !important;
      box-shadow: inset 0 0 0 1.7px rgba(129, 201, 149, 0.14) !important;
    }

    .th-total-live,
    .td-total-live {
      background: rgba(255, 255, 255, 0.052);
    }

    .th-total-live {
      color: #eefaf3 !important;
      background: #2f3642 !important;
      box-shadow: inset 0 -1px 0 rgba(160, 178, 208, 0.16);
    }

    .score3-colhead {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-height: 24px;
      line-height: 1;
    }

    .score3-colhead img {
      width: 84px;
      height: 30px;
      object-fit: contain;
      opacity: 1;
      filter: brightness(1.12) drop-shadow(0 0 8px rgba(114, 225, 163, 0.14));
      vertical-align: middle;
    }

    .score-badge[data-tip] {
      position: relative;
      cursor: default;
    }
    .score-badge[data-tip]:hover::after { display: none; }

/* Giudizio */
    .giudizio-badge {
      display: inline-block;
      padding: 3px 8px;
      border-radius: 4px;
      font-size: 9px;
      font-weight: 600;
      text-align: center;
      white-space: normal;
      line-height: 1.25;
      max-width: 100%;
      font-family: 'DM Mono', monospace;
      text-transform: uppercase;
      letter-spacing: 0.5px;
    }

    th[data-sort="giudizio"],
    .td-giudizio {
      width: 120px;
      max-width: 120px;
    }

    .td-giudizio {
      text-align: center;
      white-space: normal;
      word-break: break-word;
    }

    /* Obiettivi */
    .td-obiettivo {
      font-size: 11px;
      min-width: 95px;
      text-align: center;
    }

    .obj-row {
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 5px;
      margin-bottom: 3px;
      line-height: 1.3;
    }

    .obj-stars {
      width: 12px;
      height: 12px;
      flex: 0 0 12px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      opacity: 0.96;
    }

    .obj-stars svg {
      width: 12px;
      height: 12px;
      display: block;
    }

    .obj-stars.balloon {
      color: #ef7b88;
    }

    .obj-stars.scale {
      color: #e0c86f;
    }

    .obj-stars.diamond {
      color: #63d89a;
    }

    .obj-suf {
      color: #f7f9fd;
      font-size: 12px;
      font-weight: 500;
    }

    .obj-int {
      color: #f7f9fd;
      font-size: 12px;
      font-weight: 500;
    }

    .score-hover-tip {
      position: fixed;
      display: none;
      white-space: pre-line;
      background: #111118;
      color: #e8e8f0;
      border: 1px solid #2e2e3e;
      border-radius: 8px;
      padding: 8px 10px;
      font-size: 11px;
      line-height: 1.35;
      min-width: 220px;
      max-width: 320px;
      text-align: left;
      z-index: 9999;
      box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
      pointer-events: none;
    }

    /* ── REPORT PANEL ────────────────────────────────────────── */
    .report-panel {
      width: 0;
      min-width: 0;
      background: var(--surface);
      border-left: 1px solid var(--border);
      box-shadow: -14px 0 34px rgba(0, 0, 0, 0.45);
      overflow-y: auto;
      transition: width 0.3s ease, min-width 0.3s ease;
    }

    .report-panel.open {
      width: 580px;
      min-width: 580px;
    }

    #reportBackdrop {
      position: fixed;
      inset: 0;
      background: rgba(0, 0, 0, 0.56);
      backdrop-filter: blur(1.5px);
      z-index: 1100;
      opacity: 0;
      pointer-events: none;
      transition: opacity 0.2s ease;
    }

    #reportBackdrop.active {
      opacity: 1;
      pointer-events: auto;
    }

    body.report-popup-mode .report-panel {
      position: fixed;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -48%) scale(0.985);
      width: min(1100px, 92vw) !important;
      min-width: 0 !important;
      height: min(88vh, 920px);
      border: 1px solid var(--border2);
      border-radius: 14px;
      box-shadow: 0 34px 80px rgba(0, 0, 0, 0.62);
      z-index: 1200;
      opacity: 0;
      pointer-events: none;
      transition: transform 0.2s ease, opacity 0.2s ease;
      overflow-y: auto;
      overflow-x: auto;
    }

    body.report-popup-mode .report-content {
      overflow-x: auto;
    }

    body.report-popup-mode .report-panel.open {
      opacity: 1;
      pointer-events: auto;
      transform: translate(-50%, -50%) scale(1);
    }

    .report-panel.is-loading #rpLiveHeaderLabel,
    .report-panel.is-loading #rpScores,
    .report-panel.is-loading #rpLeadDescription,
    .report-panel.is-loading #rpQuickData,
    .report-panel.is-loading #rpAnalysisDivider,
    .report-panel.is-loading #rpAnalysisSnapshot {
      display: none !important;
    }

    .report-panel.is-loading .report-header {
      border-bottom: 0;
    }

    .report-panel.is-loading .report-content {
      padding: 10px 24px 22px;
      min-height: 96px;
      display: flex;
      align-items: center;
      justify-content: center;
    }

    body.report-popup-mode .report-panel.analysis-collapsed {
      height: auto;
      max-height: min(560px, 78vh);
    }

    body.report-only .app {
      visibility: hidden;
    }

    body.report-only .report-panel {
      visibility: visible;
    }

    body.report-only #reportBackdrop {
      background: rgba(0, 0, 0, 0.68);
      opacity: 1;
      pointer-events: none;
    }

    .report-header {
      padding: 20px 24px 16px;
      border-bottom: 1px solid var(--border);
      position: sticky;
      top: 0;
      background: var(--surface);
      z-index: 10;
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
    }

    .report-head-actions {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-shrink: 0;
    }

    .report-head-actions .report-tool-btn,
    .report-head-actions .report-tool-link {
      display: none;
    }

    .report-header-live {
      display: inline-flex;
      align-items: center;
      gap: 10px;
      min-height: 34px;
      padding: 7px 12px;
      border: 1px solid rgba(129, 201, 149, 0.18);
      border-radius: 9px;
      background: linear-gradient(180deg, rgba(36, 57, 45, 0.5), rgba(20, 34, 28, 0.74));
      margin-right: 4px;
    }

    .report-header-live.is-empty {
      display: none;
    }

    .report-header-live .liveband-dot {
      width: 9px;
      height: 9px;
      box-shadow: 0 0 0 2px rgba(97, 217, 132, 0.1), 0 0 10px rgba(97, 217, 132, 0.4);
    }

    .report-header-live-tag {
      font-size: 10px;
      text-transform: uppercase;
      letter-spacing: 1.4px;
      font-weight: 700;
      color: #bff0cb;
    }

    .report-header-live-price {
      font-family: 'Fraunces', serif;
      font-size: 22px;
      line-height: 1;
      color: #ffffff;
      white-space: nowrap;
    }

    .report-header-live-stack {
      display: inline-flex;
      flex-direction: column;
      align-items: flex-end;
      gap: 4px;
      min-width: 0;
    }

    .report-header-live-earnings {
      font-size: 10px;
      line-height: 1.2;
      letter-spacing: 0.04em;
      color: #b9c7bd;
      white-space: nowrap;
      text-align: right;
    }

    .report-tool-btn {
      border: 1px solid var(--border);
      background: var(--surface2);
      color: var(--text2);
      border-radius: 6px;
      padding: 6px 10px;
      font-size: 11px;
      letter-spacing: 0.3px;
      cursor: pointer;
      transition: all 0.15s;
    }

    .report-tool-btn:hover,
    .report-tool-btn.active {
      border-color: var(--border2);
      color: var(--text);
    }

    .report-tool-link {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      text-decoration: none;
    }

    .report-ticker {
      font-family: 'Fraunces', serif;
      font-size: 24px;
      font-weight: 700;
      color: var(--text);
      line-height: 1;
    }

    .report-title-wrap {
      display: flex;
      align-items: center;
      gap: 12px;
      min-width: 0;
    }

    .report-logo {
      width: 40px;
      height: 40px;
      border-radius: 8px;
      background: #1a1f2c;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      color: #dbe6ff;
      font-size: 10px;
      font-weight: 700;
      text-transform: uppercase;
      overflow: hidden;
      flex: 0 0 40px;
      border: 1px solid var(--border2);
    }

    .report-logo img {
      width: 100%;
      height: 100%;
      object-fit: contain;
      display: block;
      padding: 2px;
    }

    .report-azienda {
      font-size: 11px;
      color: var(--text3);
      margin-top: 4px;
    }

    .close-btn {
      background: none;
      border: 1px solid var(--border);
      color: var(--text3);
      font-size: 16px;
      width: 28px;
      height: 28px;
      border-radius: 4px;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      transition: all 0.15s;
      flex-shrink: 0;
    }

    .close-btn:hover {
      border-color: var(--border2);
      color: var(--text);
    }

    /* Score bar */
    .live-header-label {
      font-size: 0.70rem;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: rgba(74, 222, 128, 0.55);
      text-align: center;
      padding: 6px 0 2px 0;
    }

    .live-dot {
      color: #4ade80;
      font-size: 0.55rem;
      margin-right: 5px;
      vertical-align: middle;
    }

    .report-scores {
      display: grid;
      grid-template-columns: 1fr 1fr 1fr 1.33fr;
      border-bottom: 1px solid var(--border);
    }

    .rscore {
      min-width: 0;
      text-align: center;
      padding: 9px 5px 8px;
      background: rgba(255, 255, 255, 0.01);
    }

    .rscore+.rscore {
      border-left: 1px solid var(--border);
    }

    .rscore-label {
      font-size: 8px;
      text-transform: uppercase;
      letter-spacing: 1.1px;
      color: rgba(196, 214, 255, 0.78);
      line-height: 1.25;
    }

    .rscore-val {
      font-family: 'Fraunces', serif;
      font-size: 20px;
      font-weight: 600;
      margin-top: 3px;
      line-height: 1;
    }

    .rscore:not(.is-total) .rscore-val {
      font-size: 16px;
    }

    .rscore.is-total {
      background: rgba(255, 255, 255, 0.055);
      box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.92);
    }

    .rscore-foot {
      margin-top: 7px;
      padding-top: 6px;
      border-top: 1px solid rgba(160, 178, 208, 0.1);
      font-size: 9px;
      line-height: 1.25;
      color: var(--text3);
    }

    .rscore-foot strong {
      color: rgba(220, 229, 245, 0.86);
      font-weight: 600;
    }

    .rscore-target-card {
      text-align: left;
      padding: 9px 10px 8px;
      border: 1px solid rgba(160, 178, 208, 0.14);
      border-radius: 8px;
      background: rgba(10, 16, 25, 0.68);
      min-width: 0;
    }

    .rscore-target-list {
      margin-top: 6px;
      display: grid;
      gap: 6px;
    }

    .rscore-target-list.single {
      min-height: 74px;
      align-items: center;
    }

    .rscore-target-item {
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      gap: 8px 12px;
      padding: 8px 10px 9px;
      border-radius: 6px;
      border: 1px solid rgba(160, 178, 208, 0.14);
      background: rgba(255, 255, 255, 0.03);
      align-items: center;
    }

    .rscore-target-item.up {
      border-color: rgba(224, 200, 111, 0.24);
      background: rgba(224, 200, 111, 0.08);
    }

    .rscore-target-item.down {
      border-color: rgba(239, 123, 136, 0.24);
      background: rgba(239, 123, 136, 0.08);
    }

    .rscore-target-item.top {
      border-color: rgba(99, 216, 154, 0.24);
      background: rgba(99, 216, 154, 0.08);
    }

    .rscore-target-key {
      color: rgba(196, 214, 255, 0.9);
      display: inline-flex;
      align-items: center;
      gap: 6px;
      min-width: 0;
      grid-column: 2;
      grid-row: 1 / span 2;
      justify-self: end;
      align-self: center;
      max-width: 150px;
      text-align: right;
      font-size: 10px;
      line-height: 1.25;
      text-transform: uppercase;
      letter-spacing: 0.05em;
    }

    .rscore-target-main {
      grid-column: 1;
      grid-row: 1 / span 2;
      display: inline-flex;
      align-items: center;
      gap: 8px;
      min-width: 0;
    }

    .rscore-target-value {
      color: #ffffff;
      font-family: 'DM Mono', monospace;
      font-size: 20px;
      font-weight: 700;
      text-align: left;
      line-height: 1.05;
    }

    .rscore-target-list.single .rscore-target-value {
      font-size: 23px;
    }

    .rscore-target-meta {
      display: inline-flex;
      align-items: center;
      color: #ff9a2f;
    }

    .rscore-target-icon {
      width: 14px;
      height: 14px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      flex: 0 0 14px;
    }

    .rscore-target-icon svg {
      width: 14px;
      height: 14px;
      display: block;
    }

    .rscore-target-item.up .rscore-target-icon {
      color: #e0c86f;
    }

    .rscore-target-item.down .rscore-target-icon {
      color: #ef7b88;
    }

    .rscore-target-item.top .rscore-target-icon {
      color: #63d89a;
    }

    .rscore-target-empty {
      margin-top: 8px;
      color: var(--text3);
      font-size: 11px;
      text-align: center;
    }

    .report-liveband {
      display: grid;
      grid-template-columns: auto 1fr 1fr 1fr;
      align-items: stretch;
      gap: 0;
      border-bottom: 1px solid var(--border);
      border-top: 1px solid rgba(129, 201, 149, 0.18);
      background:
        linear-gradient(180deg, rgba(36, 57, 45, 0.72), rgba(20, 34, 28, 0.94));
    }

    .liveband-tag {
      display: flex;
      align-items: center;
      gap: 10px;
      padding: 14px 16px;
      border-right: 1px solid rgba(129, 201, 149, 0.14);
      color: #bff0cb;
      font-size: 11px;
      letter-spacing: 1.8px;
      font-weight: 700;
      text-transform: uppercase;
      white-space: nowrap;
    }

    .liveband-dot {
      width: 10px;
      height: 10px;
      border-radius: 50%;
      background: #61d984;
      box-shadow: 0 0 0 3px rgba(97, 217, 132, 0.12), 0 0 14px rgba(97, 217, 132, 0.7);
      animation: livePulse 1.8s ease-in-out infinite;
      flex: 0 0 auto;
    }

    @keyframes livePulse {
      0%, 100% {
        transform: scale(1);
        opacity: 0.9;
      }
      50% {
        transform: scale(1.12);
        opacity: 1;
      }
    }

    .liveband-item {
      padding: 10px 14px 11px;
      border-left: 1px solid rgba(129, 201, 149, 0.1);
      display: flex;
      flex-direction: column;
      justify-content: center;
      align-items: center;
      text-align: center;
      min-width: 0;
    }

    .liveband-label {
      font-size: 9px;
      line-height: 1;
      text-transform: uppercase;
      letter-spacing: 1.35px;
      color: rgba(191, 240, 203, 0.74);
      margin-bottom: 6px;
    }

    .liveband-main {
      font-family: 'Fraunces', serif;
      font-size: 24px;
      line-height: 1;
      font-weight: 600;
      color: #ffffff;
      display: flex;
      align-items: baseline;
      justify-content: center;
      gap: 8px;
      flex-wrap: wrap;
    }

    .liveband-main .score-badge {
      font-size: 15px;
      min-width: 58px;
      padding: 5px 10px;
    }

    .liveband-change {
      font-family: 'DM Mono', monospace;
      font-size: 11px;
      line-height: 1;
      letter-spacing: 0.2px;
      color: var(--text2);
    }

    /* Scheda dati rapida */
    .report-quickdata {
      padding: 18px 24px;
      border-bottom: 1px solid var(--border);
      display: grid;
      grid-template-columns: 1fr 1fr 1fr;
      gap: 16px 12px;
      width: 100%;
    }

    .qd-item:nth-child(3n+1) { text-align: left; }
    .qd-item:nth-child(3n+2) { text-align: center; }
    .qd-item:nth-child(3n+3) { text-align: right; }
    .qd-item { width: 100%; }
    .qd-span-3 { grid-column: 1 / -1; }

    .qd-label {
      font-size: 9px;
      text-transform: uppercase;
      letter-spacing: 1.5px;
      color: var(--text3);
    }

    .qd-val {
      font-size: 12px;
      color: var(--text2);
      margin-top: 3px;
    }

    .report-lead-description {
      padding: 16px 24px 18px;
      border-bottom: 1px solid var(--border);
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(240px, 30.7%);
      gap: 16px;
      align-items: start;
    }

    .report-lead-description.is-empty {
      display: none;
    }

    .report-lead-copy {
      min-width: 0;
    }

    .report-lead-title {
      margin: 0 0 8px;
      color: var(--text);
      font-size: 13px;
      font-weight: 700;
      line-height: 1.3;
    }

    .report-lead-description p {
      margin: 0;
      color: var(--text2);
      font-size: 12px;
      line-height: 1.72;
    }

    @media (max-width: 760px) {
      .report-lead-description {
        grid-template-columns: 1fr;
      }
    }

    .lead-skeleton {
      display: grid;
      gap: 8px;
    }

    .lead-skeleton-line {
      height: 10px;
      border-radius: 999px;
      background: linear-gradient(90deg, rgba(255,255,255,0.05), rgba(255,255,255,0.12), rgba(255,255,255,0.05));
      background-size: 200% 100%;
      animation: leadShimmer 1.4s linear infinite;
    }

    .lead-skeleton-line.w-100 { width: 100%; }
    .lead-skeleton-line.w-92 { width: 92%; }
    .lead-skeleton-line.w-84 { width: 84%; }

    @keyframes leadShimmer {
      from { background-position: 200% 0; }
      to { background-position: -200% 0; }
    }

    .report-note-section {
      display: none;
    }

    .report-analysis-divider {
      padding: 22px 24px 20px;
      border-bottom: 1px solid var(--border);
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      user-select: none;
      background: linear-gradient(180deg, rgba(255,255,255,0.012), rgba(255,255,255,0.004));
    }

    .report-analysis-divider-label {
      display: block;
      width: 100%;
    }

    .btn-analisi {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      width: 100%;
      max-width: 560px;
      margin: 0 auto;
      padding: 14px 24px;
      background: linear-gradient(135deg, rgba(0,200,100,0.15), rgba(0,200,100,0.05));
      border: 1px solid rgba(0,200,100,0.35);
      border-radius: 8px;
      transition: all 0.2s ease;
    }

    .report-analysis-divider:hover .btn-analisi {
      background: linear-gradient(135deg, rgba(0,200,100,0.25), rgba(0,200,100,0.10));
      border-color: rgba(0,200,100,0.60);
      transform: translateY(-1px);
    }

    .btn-analisi__titolo {
      font-size: 1rem;
      font-weight: 600;
      color: #4ade80;
      letter-spacing: 0.04em;
      text-transform: uppercase;
    }

    .btn-analisi__sub {
      font-size: 0.75rem;
      color: rgba(255,255,255,0.45);
      margin-top: 4px;
      letter-spacing: 0.02em;
    }

    .report-analysis-section-hidden {
      display: none;
    }

    .analysis-snapshot {
      margin-top: 2px;
      padding: 14px 16px;
      border: 1px solid var(--border);
      border-radius: 10px;
      background: linear-gradient(180deg, rgba(255,255,255,0.028), rgba(255,255,255,0.016));
      display: grid;
      grid-template-columns: minmax(180px, 240px) 1fr;
      gap: 16px;
      align-items: start;
    }

    .analysis-snapshot-meta {
      display: flex;
      flex-direction: column;
      gap: 8px;
      text-align: left;
    }

    .analysis-snapshot-price {
      font-family: 'Fraunces', serif;
      font-size: 26px;
      line-height: 1;
      color: #ffffff;
    }

    .analysis-snapshot-caption {
      font-size: 10px;
      line-height: 1.45;
      letter-spacing: 0.3px;
      color: var(--text3);
    }

    .analysis-score-grid {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 10px;
    }

    .analysis-score-card {
      border: 1px solid var(--border);
      border-radius: 8px;
      background: rgba(255,255,255,0.02);
      padding: 10px 10px 9px;
      text-align: center;
    }

    .analysis-score-card.is-total {
      background: rgba(255,255,255,0.055);
      border-color: rgba(255,255,255,0.18);
    }

    .analysis-score-label {
      font-size: 9px;
      line-height: 1.1;
      text-transform: uppercase;
      letter-spacing: 1.2px;
      color: rgba(196, 214, 255, 0.76);
    }

    .analysis-score-value {
      margin-top: 7px;
      font-family: 'Fraunces', serif;
      font-size: 23px;
      line-height: 1;
      font-weight: 600;
    }

    #rpAnalysisSnapshot {
      padding: 0 24px 18px;
      border-bottom: 1px solid var(--border);
    }

    .storico-analisi {
      font-size: 0.75rem;
      color: rgba(255, 255, 255, 0.42);
      text-align: center;
      padding: 8px 16px 12px 16px;
      line-height: 1.6;
      border-top: 1px solid rgba(255, 255, 255, 0.06);
    }

    .storico-valori {
      display: block;
      color: rgba(255, 255, 255, 0.62);
      font-family: monospace;
      font-size: 0.78rem;
      margin-top: 2px;
    }

    .analysis-date {
      padding: 8px 24px 10px;
      border-bottom: 1px solid var(--border);
      text-align: center;
      font-size: 10px;
      color: var(--text3);
      letter-spacing: 0.6px;
      text-transform: uppercase;
    }

    .report-archive-popover {
      position: absolute;
      top: 58px;
      right: 24px;
      width: min(860px, calc(100vw - 88px));
      max-height: 320px;
      border: 1px solid var(--border2);
      border-radius: 10px;
      background: var(--surface);
      box-shadow: 0 18px 36px rgba(0, 0, 0, 0.42);
      overflow: auto;
      display: none;
      z-index: 30;
    }

    .report-archive-popover.open {
      display: block;
    }

    .report-archive-table {
      width: 100%;
      border-collapse: collapse;
      font-size: 11px;
    }

    .report-archive-table thead th {
      position: sticky;
      top: 0;
      background: var(--surface2);
      border-bottom: 1px solid var(--border2);
      color: var(--text2);
      text-transform: uppercase;
      letter-spacing: 0.8px;
      padding: 8px 9px;
      text-align: left;
      font-size: 10px;
    }

    .report-archive-table tbody td {
      border-bottom: 1px solid var(--border);
      padding: 8px 9px;
      color: var(--text);
      vertical-align: middle;
    }

    .report-archive-table tbody tr.active td {
      background: rgba(129, 201, 149, 0.09);
    }

    .archive-view-btn {
      border: 1px solid var(--border2);
      background: transparent;
      color: var(--text);
      border-radius: 6px;
      width: 28px;
      height: 24px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: all 0.15s;
      font-size: 13px;
      line-height: 1;
    }

    .archive-view-btn:hover {
      border-color: var(--accent2);
      color: var(--accent);
    }

    .report-stale-alert {
      display: none;
      margin: 10px 24px 0;
      border: 1px solid rgba(239, 154, 154, 0.5);
      background: rgba(239, 154, 154, 0.14);
      color: #ffd8d8;
      border-radius: 8px;
      padding: 8px 10px;
      font-size: 11px;
      line-height: 1.4;
      font-weight: 500;
    }

    .report-stale-alert.open {
      display: block;
    }

    /* Content */
    .report-content {
      padding: 24px;
      line-height: 1.7;
    }

    .report-content h2 {
      font-family: 'Fraunces', serif;
      font-size: 14px;
      font-weight: 600;
      color: var(--accent);
      margin: 24px 0 10px;
      padding-bottom: 6px;
      border-bottom: 1px solid var(--border);
      text-transform: uppercase;
      letter-spacing: 1px;
    }

    .report-content h2:first-child {
      margin-top: 0;
    }

    .report-content h3 {
      font-size: 12px;
      font-weight: 500;
      color: var(--text2);
      margin: 16px 0 6px;
    }

    .report-content p {
      color: var(--text2);
      font-size: 12px;
      margin-bottom: 10px;
    }

    .report-content strong {
      color: var(--text);
    }

    .report-content table {
      width: 100%;
      min-width: unset;
      margin: 10px 0;
      font-size: 12px;
    }

    .report-content thead th {
      background: var(--bg);
      font-size: 10px;
      padding: 12px 14px;
      position: static;
      cursor: default;
      border-bottom: 1px solid var(--border2);
    }

    .report-content thead th:hover {
      color: var(--text3);
    }

    .report-content tbody td {
      padding: 12px 14px;
      color: var(--text2);
      font-size: 12px;
      white-space: normal;
      border-bottom: 1px solid var(--border);
    }

    .report-content tbody tr:hover td {
      background: var(--surface2);
    }

    .report-content pre,
    .report-content code {
      background: var(--surface2);
      border: 1px solid var(--border);
      border-radius: 4px;
      padding: 10px 12px;
      font-family: 'DM Mono', monospace;
      font-size: 11px;
      color: var(--text2);
      overflow-x: auto;
      margin: 8px 0;
      white-space: pre-wrap;
    }

    .report-content hr {
      border: none;
      border-top: 1px solid var(--border);
      margin: 20px 0;
    }

    .report-content ul,
    .report-content ol {
      padding-left: 20px;
      color: var(--text2);
      font-size: 12px;
      margin-bottom: 10px;
    }

    .report-content li {
      margin-bottom: 4px;
    }

    .report-disclaimer {
      background: var(--surface2);
      border: 1px solid var(--border);
      border-radius: 6px;
      padding: 12px 16px;
      font-size: 11px;
      color: var(--text3);
      margin-top: 24px;
      line-height: 1.6;
    }

    /* ── LOADING / EMPTY ─────────────────────────────────────── */
    .loading {
      display: flex;
      align-items: center;
      justify-content: center;
      height: auto;
      min-height: 0;
      color: rgba(223, 232, 251, 0.7);
      font-size: 12px;
      padding: 12px 16px;
      border: 1px solid rgba(164, 184, 220, 0.18);
      border-radius: 10px;
      background: rgba(255,255,255,0.02);
      min-width: 180px;
    }

    .empty-state {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      height: 300px;
      color: var(--text3);
      gap: 8px;
    }

    .empty-icon {
      font-size: 32px;
      opacity: 0.3;
    }

    .empty-text {
      font-size: 12px;
    }

    .report-panel::-webkit-scrollbar {
      width: 4px;
    }

    .report-panel::-webkit-scrollbar-track {
      background: var(--surface);
    }

    .report-panel::-webkit-scrollbar-thumb {
      background: var(--border2);
    }

    @keyframes fadeIn {
      from {
        opacity: 0;
        transform: translateY(4px);
      }

      to {
        opacity: 1;
        transform: translateY(0);
      }
    }

    tbody tr {
      animation: fadeIn 0.2s ease backwards;
    }

    /* ── COLUMNS PANEL ───────────────────────────────────────── */
    .cols-panel {
      position: absolute;
      top: 60px;
      right: 20px;
      width: 320px;
      max-height: calc(100vh - 90px);
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: 10px;
      box-shadow: 0 14px 30px rgba(0, 0, 0, 0.5);
      z-index: 1405;
      display: none;
      flex-direction: column;
      overflow: hidden;
    }

    .cols-panel.open {
      display: flex;
    }

    .cols-header {
      padding: 12px 16px;
      border-bottom: 1px solid var(--border);
      font-weight: 500;
      color: var(--text);
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 10px;
      flex-wrap: wrap;
    }

    .cols-title {
      white-space: nowrap;
    }

    .cols-actions {
      display: flex;
      align-items: center;
      gap: 6px;
      margin-left: auto;
    }

    .cols-tool-btn {
      background: transparent;
      border: 1px solid var(--border2);
      color: var(--text2);
      font-family: 'DM Mono', monospace;
      font-size: 10px;
      letter-spacing: 0.5px;
      padding: 5px 8px;
      border-radius: 6px;
      cursor: pointer;
      transition: all 0.15s;
      white-space: nowrap;
    }

    .cols-tool-btn:hover {
      border-color: var(--accent2);
      color: var(--accent);
    }

    .cols-tool-btn.active {
      border-color: var(--accent2);
      color: var(--accent);
      background: rgba(129, 201, 149, 0.08);
    }

    .cols-tool-btn:disabled {
      opacity: 0.45;
      cursor: default;
    }

    .cols-close {
      background: none;
      border: none;
      color: var(--text3);
      cursor: pointer;
      font-size: 14px;
    }

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

    .cols-list {
      padding: 10px;
      max-height: calc(100vh - 170px);
      overflow-y: auto;
    }

    .col-item {
      display: flex;
      align-items: center;
      flex-wrap: wrap;
      padding: 6px 10px;
      gap: 10px;
      background: var(--surface2);
      margin-bottom: 4px;
      border-radius: 8px;
      border: 1px solid var(--border);
      transition: border-color 0.15s, transform 0.15s, background 0.15s, box-shadow 0.15s;
      cursor: grab;
      user-select: none;
    }

    .col-width-wrap {
      width: 100%;
      display: flex;
      justify-content: flex-end;
      align-items: center;
      gap: 6px;
      margin-top: 4px;
    }

    .col-width-label {
      font-size: 10px;
      color: var(--text3);
      letter-spacing: 0.3px;
    }

    .col-width-input {
      width: 72px;
      background: var(--surface);
      border: 1px solid var(--border2);
      color: var(--text);
      border-radius: 6px;
      padding: 4px 6px;
      font-size: 11px;
      font-family: 'DM Mono', monospace;
      text-align: right;
      outline: none;
    }

    .col-item:hover {
      border-color: var(--border2);
    }

    .col-item.dragging {
      opacity: 0.5;
      transform: scale(0.99);
      cursor: grabbing;
    }

    .col-item.drag-over-top {
      box-shadow: inset 0 2px 0 var(--accent2);
    }

    .col-item.drag-over-bottom {
      box-shadow: inset 0 -2px 0 var(--accent2);
    }

    .col-grip {
      color: var(--text3);
      font-size: 14px;
      line-height: 1;
      letter-spacing: -1px;
    }

    .col-label {
      flex: 1;
      font-size: 11px;
      line-height: 1.15;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .col-toggle {
      cursor: pointer;
    }

    /* ── NOTE ────────────────────────────────────────────────── */
    .td-note {
      max-width: 160px;
      overflow: hidden;
    }

    .note-preview {
      font-size: 11px;
      color: var(--text3);
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
      max-width: 150px;
      font-style: italic;
    }

    .note-preview.has-note {
      color: var(--text2);
    }

    .note-add {
      font-size: 10px;
      color: var(--text3);
      cursor: pointer;
      border: 1px dashed var(--border2);
      border-radius: 3px;
      padding: 2px 6px;
      display: inline-block;
      transition: all 0.15s;
    }

    .note-add:hover {
      border-color: var(--accent2);
      color: var(--accent);
    }

    /* Note section nel panel */
    .report-note-section {
      padding: 14px 24px;
      border-bottom: 1px solid var(--border);
    }

    .note-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
    }

    .note-toggle-btn {
      width: 26px;
      height: 26px;
      border-radius: 7px;
      border: 1px solid var(--border2);
      background: transparent;
      color: var(--accent);
      font-family: 'DM Mono', monospace;
      font-size: 16px;
      line-height: 1;
      cursor: pointer;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      transition: all 0.15s;
    }

    .note-toggle-btn.plus {
      color: var(--accent);
      border-color: var(--accent2);
    }

    .note-toggle-btn.edit {
      color: #f9a825;
      border-color: #f9a825;
      font-size: 14px;
    }

    .note-body {
      display: none;
      margin-top: 10px;
    }

    .report-note-section.open .note-body {
      display: block;
    }

    .note-section-label {
      font-size: 9px;
      text-transform: uppercase;
      letter-spacing: 1.5px;
      color: var(--text3);
      margin-bottom: 8px;
    }

    .note-textarea {
      width: 100%;
      background: var(--surface2);
      border: 1px solid var(--border);
      border-radius: 6px;
      color: var(--text);
      font-family: 'DM Mono', monospace;
      font-size: 12px;
      padding: 10px 12px;
      outline: none;
      resize: vertical;
      min-height: 72px;
      line-height: 1.6;
      transition: border-color 0.15s;
    }

    .note-textarea:focus {
      border-color: var(--accent2);
    }

    .note-textarea::placeholder {
      color: var(--text3);
      font-style: italic;
    }

    .note-actions {
      display: flex;
      gap: 6px;
      margin-top: 8px;
      justify-content: flex-end;
    }

    .note-save-btn {
      background: var(--accent2);
      border: none;
      color: #fff;
      font-family: 'DM Mono', monospace;
      font-size: 10px;
      padding: 5px 14px;
      border-radius: 4px;
      cursor: pointer;
      transition: opacity 0.15s;
      text-transform: uppercase;
      letter-spacing: 1px;
    }

    .note-save-btn:hover {
      opacity: 0.85;
    }

    .note-save-btn.saved {
      background: #2E7D4F;
    }

    .note-delete-btn {
      background: none;
      border: 1px solid var(--border);
      color: var(--text3);
      font-family: 'DM Mono', monospace;
      font-size: 10px;
      padding: 5px 10px;
      border-radius: 4px;
      cursor: pointer;
      transition: all 0.15s;
    }

    .note-delete-btn:hover {
      border-color: #E53935;
      color: #E53935;
    }

    @media (max-width: 1080px) {
      .sidebar {
        display: none;
      }

      .main-header {
        padding: 14px 14px;
      }

      .header-actions {
        gap: 10px;
      }

      .header-controls,
      .top-search {
        flex-wrap: wrap;
      }

      .search-input {
        min-width: 100%;
      }
    }

    @media (max-width: 760px) {
      .main-header {
        gap: 10px;
        flex-wrap: wrap;
      }

      .header-actions {
        width: 100%;
      }

      .header-refresh-group {
        width: 100%;
        justify-content: space-between;
      }

      .header-refresh-status {
        text-align: left;
        white-space: normal;
      }

      .title-wrap h1 {
        font-size: 18px;
      }

      .table-wrapper {
        font-size: 12px;
      }
    }

    /* ── Report: Analisi / Dati finanziari ─────────────────── */
    .report-view-tabs {
      position: sticky;
      top: 72px;
      z-index: 8;
      display: flex;
      gap: 6px;
      padding: 10px 24px 0;
      background: color-mix(in srgb, var(--bg) 94%, transparent);
      border-bottom: 1px solid var(--border);
      backdrop-filter: blur(12px);
    }

    .report-view-tab {
      appearance: none;
      border: 0;
      border-bottom: 2px solid transparent;
      background: transparent;
      color: var(--text2);
      cursor: pointer;
      font: inherit;
      font-size: 13px;
      font-weight: 650;
      padding: 10px 14px 11px;
      transition: color .16s ease, border-color .16s ease, background .16s ease;
    }

    .report-view-tab:hover {
      color: var(--text);
      background: rgba(129, 201, 149, .06);
    }

    .report-view-tab.active {
      color: var(--accent);
      border-bottom-color: var(--accent);
    }

    .report-financials-view { padding: 22px 24px 34px; }
    .report-financials-view[hidden], #rpAnalysisView[hidden] { display: none !important; }
    body.report-popup-mode .report-panel.financials-active { height: min(88vh, 920px); max-height: none; }

    .financials-toolbar {
      display: flex;
      align-items: flex-end;
      justify-content: space-between;
      gap: 18px;
      margin-bottom: 14px;
    }

    .financials-eyebrow {
      color: var(--accent);
      font-size: 11px;
      font-weight: 750;
      letter-spacing: .08em;
      margin-bottom: 5px;
      text-transform: uppercase;
    }

    .financials-toolbar h2 { color: var(--text); font-size: 20px; margin: 0; }

    .financials-period-toggle {
      display: inline-flex;
      padding: 3px;
      border: 1px solid var(--border);
      border-radius: 10px;
      background: rgba(255, 255, 255, .025);
    }

    .financials-period-toggle button {
      border: 0;
      border-radius: 7px;
      background: transparent;
      color: var(--text2);
      cursor: pointer;
      font: inherit;
      font-size: 12px;
      font-weight: 650;
      padding: 7px 11px;
    }

    .financials-period-toggle button.active { background: rgba(129, 201, 149, .15); color: var(--accent); }
    .financials-status { color: var(--text3); font-size: 11px; min-height: 18px; margin-bottom: 14px; }
    .financials-status.warning { color: #fbbf24; }
    .financials-status.error { color: #fca5a5; }

    .financials-metrics {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 10px;
      margin-bottom: 16px;
    }

    .financial-metric {
      min-width: 0;
      padding: 13px 14px;
      border: 1px solid var(--border);
      border-radius: 11px;
      background: rgba(255, 255, 255, .025);
    }

    .financial-metric-label {
      color: var(--text3);
      font-size: 10px;
      font-weight: 650;
      letter-spacing: .045em;
      margin-bottom: 5px;
      text-transform: uppercase;
    }

    .financial-metric-value {
      color: var(--text);
      font-size: 15px;
      font-weight: 720;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .financials-charts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }

    .financial-chart-card {
      min-width: 0;
      padding: 15px 14px 9px;
      border: 1px solid var(--border);
      border-radius: 13px;
      background: rgba(255, 255, 255, .02);
    }

    .financial-chart-title { color: var(--text); font-size: 13px; font-weight: 700; margin: 0 0 5px 5px; }
    .financial-chart-svg { display: block; width: 100%; height: auto; min-height: 220px; }
    .financial-chart-grid { stroke: rgba(160, 178, 208, .11); stroke-width: 1; }
    .financial-chart-zero { stroke: rgba(160, 178, 208, .34); stroke-width: 1; }
    .financial-chart-axis, .financial-chart-missing { fill: var(--text3); font-size: 10px; }
    .financial-chart-missing { fill: #fbbf24; }
    .financial-chart-bar { opacity: .88; transition: opacity .15s ease; }
    .financial-chart-bar:hover { opacity: 1; }

    .financial-chart-empty {
      display: grid;
      min-height: 220px;
      place-items: center;
      color: var(--text3);
      font-size: 12px;
    }

    .financials-footnote { color: var(--text3); font-size: 10.5px; line-height: 1.55; margin-top: 12px; }

    @media (max-width: 900px) {
      .financials-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
      .financials-charts { grid-template-columns: 1fr; }
    }

    @media (max-width: 620px) {
      .report-view-tabs { top: 64px; padding-left: 14px; padding-right: 14px; }
      .report-financials-view { padding: 18px 14px 28px; }
      .financials-toolbar { align-items: flex-start; flex-direction: column; }
      .financial-metrics { grid-template-columns: 1fr 1fr; }
      .financial-metric { padding: 11px; }
    }
