
/* Phase report visual polish overrides */
.seasonality-analyzer-main-header-phase-report {
  --seasonality-phase-report-surface: #ffffff;
  --seasonality-phase-report-surface-soft: #f6f8fb;
  --seasonality-phase-report-border: #d7e0ec;
  --seasonality-phase-report-border-strong: #c5d3e6;
  --seasonality-phase-report-grid-h: #e6edf5;
  --seasonality-phase-report-grid-v: #edf2f8;
  --seasonality-phase-report-text: #0f172a;
  --seasonality-phase-report-muted: #5a6b80;
  --seasonality-phase-report-accent: #0059ff;
  --seasonality-phase-report-selected-bg: #f6f9ff;
  --seasonality-phase-report-hover: #f4f7fb;
  --seasonality-phase-report-row-active-bg: #eef4ff;
  --seasonality-phase-report-row-active-line: rgba(0, 89, 255, 0.28);
  --seasonality-phase-report-row-active-glow: rgba(0, 89, 255, 0.1);
  --seasonality-phase-report-cycle-min-width: 462px;
  --seasonality-phase-report-phase-min-width: 800px;
  --seasonality-phase-report-month-min-width: 620px;
  --seasonality-phase-cycle-col-1-width: 5ch;
  --seasonality-phase-cycle-col-2-width: 8ch;
  --seasonality-phase-cycle-col-3-width: 13ch;
  --seasonality-phase-cycle-col-4-width: 7ch;
  --seasonality-phase-cycle-col-5-width: 7ch;
  --seasonality-phase-cycle-col-6-width: 7ch;
  --seasonality-phase-cycle-col-7-width: 10ch;
  --seasonality-phase-cycle-col-8-width: 4.2ch;
  --seasonality-phase-cand-col-1-width: 3ch;
  --seasonality-phase-cand-col-2-width: 10ch;
  --seasonality-phase-cand-col-3-width: 6ch;
  --seasonality-phase-cand-col-4-width: 7ch;
  --seasonality-phase-cand-col-5-width: 7ch;
  --seasonality-phase-cand-col-6-width: 7ch;
  --seasonality-phase-cand-col-7-width: 6ch;
  --seasonality-phase-cand-col-8-width: 8ch;
  --seasonality-phase-cand-col-9-width: 12ch;
  --seasonality-phase-cand-col-10-width: 8ch;
  --seasonality-phase-cand-col-11-width: 13ch;
  --seasonality-phase-cand-col-12-width: 4.2ch;
  --seasonality-phase-month-col-1-width: 3ch;
  --seasonality-phase-month-col-2-width: 7ch;
  --seasonality-phase-month-col-3-width: 6ch;
  --seasonality-phase-month-col-4-width: 7ch;
  --seasonality-phase-month-col-5-width: 7ch;
  --seasonality-phase-month-col-6-width: 7ch;
  --seasonality-phase-month-col-7-width: 6ch;
  --seasonality-phase-month-col-8-width: 8ch;
  --seasonality-phase-month-col-9-width: 20ch;
  --seasonality-phase-month-col-10-width: 8ch;
  --seasonality-phase-month-col-11-width: 15ch;
  gap: 8px;
  margin-bottom: 8px;
  width: 100%;
}

.seasonality-phase-report-wrap {
  gap: 9px;
}

.seasonality-phase-report-block {
  border: 1px solid var(--seasonality-phase-report-border);
  border-radius: 5px;
  background: var(--seasonality-phase-report-surface);
  padding: 10px;
}

.seasonality-phase-report-block--selected {
  border-color: var(--seasonality-phase-report-border-strong);
  background: var(--seasonality-phase-report-selected-bg);
}

.seasonality-phase-report-block__title {
  font-size: 0.82rem;
  color: var(--seasonality-phase-report-text);
}

.seasonality-phase-report-block__subtitle {
  margin-top: 2px;
  line-height: 1.35;
  color: var(--seasonality-phase-report-muted);
}

.seasonality-phase-report-block__summary {
  margin-top: 6px;
  padding: 6px 8px;
  border: 1px solid var(--seasonality-phase-report-grid-h);
  border-radius: 4px;
  background: #fbfcfe;
  line-height: 1.3;
  font-variant-numeric: tabular-nums;
}

.seasonality-phase-report-block--selected .seasonality-phase-report-block__summary {
  border-color: #d5e0f1;
  background: #f2f6fd;
}

.seasonality-phase-report-tables {
  margin-top: 8px;
  gap: 8px;
}

.seasonality-phase-report-table-wrap {
  position: relative;
  border: 1px solid var(--seasonality-phase-report-border);
  border-radius: 5px;
  background: #ffffff;
  overflow-x: auto;
  overflow-y: hidden;
  container-type: inline-size;
}

.seasonality-phase-report-table-wrap--cycle {
  width: 100%;
}

.seasonality-phase-report-table-wrap--cycle .seasonality-phase-report-table {
  min-width: var(--seasonality-phase-report-cycle-min-width);
  width: max(100%, max-content);
}

.seasonality-phase-report-table-wrap--phase {
  width: 100%;
}

.seasonality-phase-report-table-wrap--phase .seasonality-phase-report-table {
  min-width: var(--seasonality-phase-report-phase-min-width);
  width: max(100%, max-content);
}

.seasonality-phase-report-table-wrap--month {
  width: 100%;
  grid-column: 1 / -1;
}

.seasonality-phase-report-table-wrap--month .seasonality-phase-report-table {
  min-width: var(--seasonality-phase-report-month-min-width);
  width: max(100%, max-content);
}

.seasonality-phase-report-table-wrap::-webkit-scrollbar {
  height: 8px;
}

.seasonality-phase-report-table-wrap::-webkit-scrollbar-track {
  background: #f3f6fa;
}

.seasonality-phase-report-table-wrap::-webkit-scrollbar-thumb {
  background: #c3cfdf;
  border-radius: 999px;
}

.seasonality-phase-report-table-wrap::-webkit-scrollbar-thumb:hover {
  background: #a7b8cf;
}

.seasonality-phase-report-table-title {
  position: sticky;
  left: 0;
  padding: 6px 8px;
  min-width: 100%;
  box-sizing: border-box;
  border-bottom: 1px solid var(--seasonality-phase-report-grid-h);
  background: #fbfcfe;
  color: #2b3b50;
  font-size: 0.71rem;
  letter-spacing: 0.03em;
  z-index: 2;
}

.seasonality-phase-report-table {
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
  width: 100%;
  min-width: 0;
}

.seasonality-phase-report-table--cycle {
  width: 100%;
  table-layout: auto;
}

.seasonality-phase-report-table--phase {
  width: 100%;
  table-layout: auto;
}

.seasonality-phase-report-table--month {
  width: 100%;
  table-layout: auto;
}

.seasonality-phase-report-table th,
.seasonality-phase-report-table td {
  border: 0;
  border-bottom: 1px solid var(--seasonality-phase-report-grid-h);
  padding: 4px 6px;
  line-height: 1.24;
  background: #ffffff;
}

.seasonality-phase-report-table.seasonality-phase-report-table--cycle th,
.seasonality-phase-report-table.seasonality-phase-report-table--cycle td,
.seasonality-phase-report-table.seasonality-phase-report-table--phase th,
.seasonality-phase-report-table.seasonality-phase-report-table--phase td,
.seasonality-phase-report-table.seasonality-phase-report-table--month th,
.seasonality-phase-report-table.seasonality-phase-report-table--month td {
  padding: 3px 5px;
  white-space: nowrap;
}

@container (max-width: 860px) {
  .seasonality-phase-report-table-wrap--cycle .seasonality-phase-report-table--cycle {
    --seasonality-phase-report-cycle-min-width: 382px;
    --seasonality-phase-cycle-col-1-width: 4.1ch;
    --seasonality-phase-cycle-col-2-width: 6.1ch;
    --seasonality-phase-cycle-col-3-width: 8.8ch;
    --seasonality-phase-cycle-col-4-width: 4.9ch;
    --seasonality-phase-cycle-col-5-width: 4.9ch;
    --seasonality-phase-cycle-col-6-width: 4.9ch;
    --seasonality-phase-cycle-col-7-width: 6.8ch;
    --seasonality-phase-cycle-col-8-width: 3.5ch;
  }

  .seasonality-phase-report-table-wrap--phase .seasonality-phase-report-table--phase {
    --seasonality-phase-report-phase-min-width: 600px;
    --seasonality-phase-cand-col-1-width: 2.6ch;
    --seasonality-phase-cand-col-2-width: 8.2ch;
    --seasonality-phase-cand-col-3-width: 4.8ch;
    --seasonality-phase-cand-col-4-width: 5.4ch;
    --seasonality-phase-cand-col-5-width: 5.4ch;
    --seasonality-phase-cand-col-6-width: 5.4ch;
    --seasonality-phase-cand-col-7-width: 4.5ch;
    --seasonality-phase-cand-col-8-width: 5.8ch;
    --seasonality-phase-cand-col-9-width: 8.8ch;
    --seasonality-phase-cand-col-10-width: 6ch;
    --seasonality-phase-cand-col-11-width: 8.8ch;
    --seasonality-phase-cand-col-12-width: 3.5ch;
  }

  .seasonality-phase-report-table-wrap--month .seasonality-phase-report-table--month {
    --seasonality-phase-report-month-min-width: 520px;
    --seasonality-phase-month-col-1-width: 2.6ch;
    --seasonality-phase-month-col-2-width: 5.7ch;
    --seasonality-phase-month-col-3-width: 4.8ch;
    --seasonality-phase-month-col-4-width: 5.4ch;
    --seasonality-phase-month-col-5-width: 5.4ch;
    --seasonality-phase-month-col-6-width: 5.4ch;
    --seasonality-phase-month-col-7-width: 4.5ch;
    --seasonality-phase-month-col-8-width: 5.8ch;
    --seasonality-phase-month-col-9-width: 15.8ch;
    --seasonality-phase-month-col-10-width: 6ch;
    --seasonality-phase-month-col-11-width: 11.8ch;
  }

  .seasonality-phase-report-table-wrap--cycle .seasonality-phase-report-table,
  .seasonality-phase-report-table-wrap--phase .seasonality-phase-report-table,
  .seasonality-phase-report-table-wrap--month .seasonality-phase-report-table {
    width: max(100%, max-content);
    table-layout: auto;
  }
}

.seasonality-phase-report-table thead th + th,
.seasonality-phase-report-table tbody td + td {
  border-left: 1px solid var(--seasonality-phase-report-grid-v);
}

.seasonality-phase-report-table thead,
.seasonality-phase-report-table thead tr,
.seasonality-phase-report-table thead th {
  background-color: #fbfcfe !important;
  color: #2d3b50;
  font-weight: 600;
}

.seasonality-phase-report-table thead th {
  border-bottom: 1px solid #e2e8f0;
}

.seasonality-phase-report-table tbody tr:nth-child(even) td {
  background: #fbfcfe;
}

.seasonality-phase-report-table tbody tr:hover td {
  background: var(--seasonality-phase-report-hover);
}

.seasonality-phase-report-table tbody tr.seasonality-phase-report-row--active td {
  box-shadow:
    inset 0 1px 0 var(--seasonality-phase-report-row-active-glow),
    inset 0 -1px 0 var(--seasonality-phase-report-row-active-glow);
}

.seasonality-phase-report-table tbody tr.seasonality-phase-report-row--active td:not(.seasonality-phase-report-cell--heatmap) {
  background: var(--seasonality-phase-report-row-active-bg);
}

.seasonality-phase-report-table tbody tr.seasonality-phase-report-row--active td:first-child {
  box-shadow:
    inset 2px 0 0 var(--seasonality-phase-report-row-active-line),
    inset 0 1px 0 var(--seasonality-phase-report-row-active-glow),
    inset 0 -1px 0 var(--seasonality-phase-report-row-active-glow);
}

.seasonality-phase-report-table tbody tr.seasonality-phase-report-row--active:hover td:not(.seasonality-phase-report-cell--heatmap) {
  background: var(--seasonality-phase-report-row-active-bg);
}

.seasonality-phase-report-cell--heatmap {
  font-weight: 500;
  background-clip: padding-box;
  transition: filter 120ms ease;
}

.seasonality-phase-report-table tbody tr.seasonality-phase-report-row--active .seasonality-phase-report-cell--heatmap {
  filter: saturate(1.03);
}

.seasonality-phase-report-table tbody tr:hover .seasonality-phase-report-cell--heatmap {
  filter: saturate(1.04);
}

.seasonality-phase-report-cell--heatmap.seasonality-phase-report-cell--flat {
  font-weight: 400;
}

.seasonality-phase-report-table tbody tr:last-child td {
  border-bottom: 0;
}

.seasonality-phase-report-jump {
  border: 0;
  padding: 0;
  margin: 0;
  background: transparent;
  color: var(--seasonality-phase-report-accent);
  font: inherit;
  line-height: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

.seasonality-phase-report-jump:hover {
  text-decoration-color: currentColor;
}

.seasonality-phase-report-jump:focus-visible {
  outline: 1px solid var(--seasonality-phase-report-accent);
  outline-offset: 2px;
  border-radius: 2px;
}

.seasonality-phase-report-month-jump {
  border: 0;
  padding: 0;
  margin: 0;
  background: transparent;
  color: var(--seasonality-phase-report-accent);
  font: inherit;
  line-height: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}

.seasonality-phase-report-month-jump:hover {
  text-decoration-color: currentColor;
}

.seasonality-phase-report-month-jump:focus-visible {
  outline: 1px solid var(--seasonality-phase-report-accent);
  outline-offset: 2px;
  border-radius: 2px;
}

.seasonality-phase-report-filter-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  padding: 0;
  margin: 0;
  border: 1px solid #d7e0ec;
  border-radius: 4px;
  background: #ffffff;
  cursor: pointer;
}

.seasonality-phase-report-filter-action:hover {
  border-color: #b7c7dc;
  background: #f7faff;
}

.seasonality-phase-report-filter-action:focus-visible {
  outline: 1px solid var(--seasonality-phase-report-accent);
  outline-offset: 1px;
}

.seasonality-phase-report-filter-action__icon {
  width: 11px;
  height: 11px;
  display: block;
  opacity: 0.92;
}

.seasonality-phase-report-table--cycle th:nth-child(2),
.seasonality-phase-report-table--cycle td:nth-child(2),
.seasonality-phase-report-table--cycle th:nth-child(4),
.seasonality-phase-report-table--cycle td:nth-child(4),
.seasonality-phase-report-table--cycle th:nth-child(5),
.seasonality-phase-report-table--cycle td:nth-child(5),
.seasonality-phase-report-table--cycle th:nth-child(6),
.seasonality-phase-report-table--cycle td:nth-child(6) {
  text-align: right;
}

.seasonality-phase-report-table--cycle th:nth-child(8),
.seasonality-phase-report-table--cycle td:nth-child(8) {
  text-align: center;
}

.seasonality-phase-report-table--phase th:nth-child(1),
.seasonality-phase-report-table--phase td:nth-child(1),
.seasonality-phase-report-table--phase th:nth-child(4),
.seasonality-phase-report-table--phase td:nth-child(4),
.seasonality-phase-report-table--phase th:nth-child(5),
.seasonality-phase-report-table--phase td:nth-child(5),
.seasonality-phase-report-table--phase th:nth-child(6),
.seasonality-phase-report-table--phase td:nth-child(6),
.seasonality-phase-report-table--phase th:nth-child(7),
.seasonality-phase-report-table--phase td:nth-child(7),
.seasonality-phase-report-table--phase th:nth-child(10),
.seasonality-phase-report-table--phase td:nth-child(10) {
  text-align: right;
}

.seasonality-phase-report-table--phase th:nth-child(3),
.seasonality-phase-report-table--phase td:nth-child(3),
.seasonality-phase-report-table--phase th:nth-child(8),
.seasonality-phase-report-table--phase td:nth-child(8),
.seasonality-phase-report-table--phase th:nth-child(12),
.seasonality-phase-report-table--phase td:nth-child(12) {
  text-align: center;
}

.seasonality-phase-report-table--month th:nth-child(1),
.seasonality-phase-report-table--month td:nth-child(1),
.seasonality-phase-report-table--month th:nth-child(4),
.seasonality-phase-report-table--month td:nth-child(4),
.seasonality-phase-report-table--month th:nth-child(5),
.seasonality-phase-report-table--month td:nth-child(5),
.seasonality-phase-report-table--month th:nth-child(6),
.seasonality-phase-report-table--month td:nth-child(6),
.seasonality-phase-report-table--month th:nth-child(7),
.seasonality-phase-report-table--month td:nth-child(7),
.seasonality-phase-report-table--month th:nth-child(10),
.seasonality-phase-report-table--month td:nth-child(10) {
  text-align: right;
}

.seasonality-phase-report-table--month th:nth-child(3),
.seasonality-phase-report-table--month td:nth-child(3),
.seasonality-phase-report-table--month th:nth-child(8),
.seasonality-phase-report-table--month td:nth-child(8) {
  text-align: center;
}

.seasonality-phase-report-month-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px;
}

.seasonality-phase-report-month-links__sep {
  color: #64748b;
}

.seasonality-phase-report-empty {
  margin-top: 8px;
  padding: 8px 9px;
  line-height: 1.35;
  border: 1px solid var(--seasonality-phase-report-grid-h);
  border-radius: 5px;
  background: #fbfcfe;
}

.seasonality-phase-report-block .seasonality-phase-report-empty {
  margin-bottom: 0;
}

.seasonality-phase-tutorial {
  --phase-space-xs: 6px;
  --phase-space-sm: 10px;
  --phase-space-md: 14px;
  --phase-space-lg: 18px;
  color: #111827;
}

.seasonality-phase-tutorial__markdown,
.seasonality-phase-tutorial__content {
  margin: 0;
  padding: 0;
}

.seasonality-phase-tutorial__hero,
.seasonality-phase-tutorial__card,
.seasonality-phase-tutorial__warning {
  margin: 0 0 var(--phase-space-lg);
}

.seasonality-phase-tutorial__content > :last-child {
  margin-bottom: 0;
}

.seasonality-phase-tutorial__hero > *,
.seasonality-phase-tutorial__card > *,
.seasonality-phase-tutorial__warning > * {
  margin: 0;
}

.seasonality-phase-tutorial__hero > * + *,
.seasonality-phase-tutorial__card > * + *,
.seasonality-phase-tutorial__warning > * + * {
  margin-top: var(--phase-space-sm);
}

.seasonality-phase-tutorial__hero {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
  padding: 12px 14px;
}

.seasonality-phase-tutorial__card {
  padding: 0;
}

.seasonality-phase-tutorial__card--value-guide {
  margin-top: 24px;
}

.seasonality-phase-tutorial__warning {
  position: relative;
  border: 1px solid #f1d7aa;
  border-left: 4px solid #d97706;
  border-radius: 10px;
  background: linear-gradient(180deg, #fffdf8 0%, #fff8eb 100%);
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04);
  padding: 12px 14px;
}

.seasonality-phase-tutorial .seasonality-phase-tutorial__warning h4 {
  margin: 0 0 var(--phase-space-md);
  color: #92400e;
  display: flex;
  align-items: center;
  gap: 8px;
}

.seasonality-phase-tutorial .seasonality-phase-tutorial__warning h4::before {
  content: "!";
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: #fed7aa;
  color: #9a3412;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.74rem;
  font-weight: 800;
  line-height: 1;
  flex: 0 0 18px;
}

.seasonality-phase-tutorial .seasonality-phase-tutorial__warning li {
  color: #3f2f17;
}

.seasonality-phase-tutorial li + li {
  margin-top: 4px;
}

.seasonality-phase-tutorial h3 {
  margin: 0;
  font-size: 1rem;
  color: #0f172a;
}

.seasonality-phase-tutorial h4 {
  margin: 0 0 var(--phase-space-md);
  font-size: 0.94rem;
  color: #1e293b;
}

.seasonality-phase-tutorial p,
.seasonality-phase-tutorial li {
  font-size: 0.9rem;
  line-height: 1.45;
}

.seasonality-phase-tutorial p {
  color: #111827;
}

.seasonality-phase-tutorial p.seasonality-phase-tutorial__lead {
  margin-bottom: var(--phase-space-lg);
}

.seasonality-phase-tutorial ul,
.seasonality-phase-tutorial ol {
  margin: 0;
  padding-left: 20px;
}

.seasonality-phase-tutorial__example {
  border: 1px solid #e5e7eb;
  border-left: 3px solid #94a3b8;
  border-radius: 8px;
  background: #f8fafc;
  padding: 10px 12px;
}

.seasonality-phase-tutorial__example > * {
  margin: 0;
}

.seasonality-phase-tutorial__example > * + * {
  margin-top: var(--phase-space-xs);
}

.seasonality-phase-tutorial__mini-table-wrap {
  margin-top: var(--phase-space-sm);
  overflow-x: auto;
  border: 1px solid #dbe2ea;
  border-radius: 7px;
  background: #ffffff;
}

.seasonality-phase-tutorial__mini-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  border-spacing: 0;
  font-size: 0.82rem;
  line-height: 1.35;
  color: #0f172a;
}

.seasonality-phase-tutorial__mini-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  text-align: left;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: #334155;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  padding: 8px 10px;
  white-space: nowrap;
}

.seasonality-phase-tutorial__mini-table tbody td {
  padding: 7px 10px;
  border-bottom: 1px solid #eef2f7;
  color: #1f2937;
  white-space: nowrap;
}

.seasonality-phase-tutorial__mini-table--macro-raw tbody td:nth-child(2),
.seasonality-phase-tutorial__mini-table--density-events tbody td:nth-child(3),
.seasonality-phase-tutorial__mini-table--policy-events tbody td:nth-child(3),
.seasonality-phase-tutorial__mini-table--policy-event-density tbody td:nth-child(3),
.seasonality-phase-tutorial__mini-table--momentum-vectors tbody td:nth-child(1),
.seasonality-phase-tutorial__mini-table--momentum-vectors tbody td:nth-child(5),
.seasonality-phase-tutorial__mini-table--feature-selection tbody td:nth-child(1),
.seasonality-phase-tutorial__mini-table--feature-selection tbody td:nth-child(4),
.seasonality-phase-tutorial__mini-table--score-raw tbody td:nth-child(1) {
  white-space: normal;
  min-width: 220px;
}

.seasonality-phase-tutorial__mini-table--macro-raw tbody td:nth-child(3),
.seasonality-phase-tutorial__mini-table--macro-raw tbody td:nth-child(4),
.seasonality-phase-tutorial__mini-table--macro-raw tbody td:nth-child(5),
.seasonality-phase-tutorial__mini-table--surprise-breakdown tbody td:nth-child(n+2),
.seasonality-phase-tutorial__mini-table--high-impact tbody td:nth-child(4),
.seasonality-phase-tutorial__mini-table--high-impact tbody td:nth-child(5),
.seasonality-phase-tutorial__mini-table--high-impact tbody td:nth-child(7),
.seasonality-phase-tutorial__mini-table--high-impact tbody td:nth-child(8),
.seasonality-phase-tutorial__mini-table--cot-positioning tbody td:nth-child(n+3),
.seasonality-phase-tutorial__mini-table--cot-flow tbody td:nth-child(3),
.seasonality-phase-tutorial__mini-table--cot-flow tbody td:nth-child(4),
.seasonality-phase-tutorial__mini-table--cot-flow tbody td:nth-child(5),
.seasonality-phase-tutorial__mini-table--cot-flow tbody td:nth-child(6),
.seasonality-phase-tutorial__mini-table--realized-vol tbody td:nth-child(2),
.seasonality-phase-tutorial__mini-table--realized-vol tbody td:nth-child(3),
.seasonality-phase-tutorial__mini-table--feature-selection tbody td:nth-child(2),
.seasonality-phase-tutorial__mini-table--feature-selection tbody td:nth-child(3),
.seasonality-phase-tutorial__mini-table--score-raw tbody td:nth-child(2),
.seasonality-phase-tutorial__mini-table--score-raw tbody td:nth-child(3),
.seasonality-phase-tutorial__mini-table--score-raw tbody td:nth-child(4),
.seasonality-phase-tutorial__mini-table--score-raw tbody td:nth-child(5),
.seasonality-phase-tutorial__mini-table--momentum-vectors tbody td:nth-child(2),
.seasonality-phase-tutorial__mini-table--momentum-vectors tbody td:nth-child(3),
.seasonality-phase-tutorial__mini-table--momentum-vectors tbody td:nth-child(4),
.seasonality-phase-tutorial__mini-table--policy-events tbody td:nth-child(4),
.seasonality-phase-tutorial__mini-table--policy-events tbody td:nth-child(5),
.seasonality-phase-tutorial__mini-table--policy-events tbody td:nth-child(6),
.seasonality-phase-tutorial__mini-table--policy-events tbody td:nth-child(7),
.seasonality-phase-tutorial__mini-table--policy-rates tbody td:nth-child(n+2) {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.seasonality-phase-tutorial__mini-table--high-impact thead th:nth-child(2),
.seasonality-phase-tutorial__mini-table--high-impact tbody td:nth-child(2) {
  width: 62px;
  min-width: 62px;
  max-width: 62px;
  white-space: nowrap;
}

.seasonality-phase-tutorial__mini-table--high-impact tbody td:nth-child(3) {
  white-space: normal;
  min-width: 220px;
}

.seasonality-phase-tutorial__mini-table--cot-positioning tbody td:nth-child(1) {
  width: 54px;
  min-width: 54px;
  max-width: 54px;
}

.seasonality-phase-tutorial__mini-table--cot-flow tbody td:nth-child(1) {
  width: 54px;
  min-width: 54px;
  max-width: 54px;
}

.seasonality-phase-tutorial__mini-table--realized-vol tbody td:nth-child(1) {
  width: 96px;
  min-width: 96px;
  max-width: 96px;
  white-space: nowrap;
}

.seasonality-phase-tutorial__mini-table--realized-vol thead th:nth-child(2),
.seasonality-phase-tutorial__mini-table--realized-vol thead th:nth-child(3) {
  text-align: right;
}

.seasonality-phase-tutorial__mini-table tbody tr:nth-child(even) {
  background: #fcfdff;
}

.seasonality-phase-tutorial__mini-table tbody tr:hover {
  background: #f7fafc;
}

.seasonality-phase-tutorial__mini-table tbody tr:last-child td {
  border-bottom: 0;
}

.seasonality-phase-tutorial__formula {
  display: block;
  margin: var(--phase-space-sm) 0;
  padding: 8px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #ffffff;
  overflow-x: auto;
}

.seasonality-phase-tutorial__formula + .seasonality-phase-tutorial__formula {
  margin-top: var(--phase-space-xs);
}

.seasonality-phase-tutorial__hero > .seasonality-phase-tutorial__formula:first-child,
.seasonality-phase-tutorial__card > .seasonality-phase-tutorial__formula:first-child,
.seasonality-phase-tutorial__warning > .seasonality-phase-tutorial__formula:first-child {
  margin-top: 0;
}

.seasonality-phase-tutorial__hero > .seasonality-phase-tutorial__formula:last-child,
.seasonality-phase-tutorial__card > .seasonality-phase-tutorial__formula:last-child,
.seasonality-phase-tutorial__warning > .seasonality-phase-tutorial__formula:last-child {
  margin-bottom: 0;
}

.seasonality-phase-tutorial__math {
  font-family: "Cambria Math", "Times New Roman", Georgia, serif;
  font-size: 0.94rem;
  line-height: 1.35;
  color: #0f172a;
  white-space: nowrap;
}

.seasonality-phase-tutorial__math sub,
.seasonality-phase-tutorial__math sup {
  font-size: 0.78em;
}

.seasonality-phase-tutorial__frac {
  display: inline-flex;
  flex-direction: column;
  vertical-align: middle;
  text-align: center;
  line-height: 1.08;
  margin: 0 0.14rem;
}

.seasonality-phase-tutorial__frac-top {
  display: block;
  padding: 0 0.2rem 1px;
  border-bottom: 1px solid #334155;
}

.seasonality-phase-tutorial__frac-bottom {
  display: block;
  padding: 1px 0.2rem 0;
}

.seasonality-phase-tutorial .appTable.seasonality-phase-tutorial__table {
  width: 100%;
  margin: var(--phase-space-md) 0 var(--phase-space-md);
}

.seasonality-phase-tutorial__hero > .appTable.seasonality-phase-tutorial__table:last-child,
.seasonality-phase-tutorial__card > .appTable.seasonality-phase-tutorial__table:last-child,
.seasonality-phase-tutorial__warning > .appTable.seasonality-phase-tutorial__table:last-child {
  margin-bottom: 0;
}

@media (min-width: 1160px) {
  .seasonality-phase-report-tables {
    grid-template-columns: minmax(300px, 0.92fr) minmax(420px, 1.08fr);
    align-items: start;
  }
}

#seasonality-analyzer-main-header-phase-heatmap-table .seasonality-heatmap-row--gap .seasonality-heatmap-gap-cell {
  height: 28px;
  position: relative;
  border: 0;
  border-left: 1px solid #e2e8f0;
  border-right: 1px solid #e2e8f0;
  padding: 0;
  background: #ffffff;
  box-shadow: inset 0 1px 0 rgba(194, 209, 228, 0.4), inset 0 -1px 0 rgba(194, 209, 228, 0.4);
  overflow: hidden;
}

#seasonality-analyzer-main-header-phase-heatmap-table .seasonality-heatmap-row--gap .seasonality-heatmap-gap-cell::before {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  top: 50%;
  border-top: 1px solid #c2d1e4;
  transform: translateY(-50%);
  pointer-events: none;
}

#seasonality-analyzer-main-header-phase-heatmap-table .seasonality-heatmap-row--gap .seasonality-heatmap-gap-cell::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 8px;
  height: 8px;
  border: 1px solid #c2d1e4;
  border-radius: 50%;
  background: #c2d1e4;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 3px #ffffff;
  pointer-events: none;
}

.seasonality-heatmap-row--gap .seasonality-heatmap-gap-cell {
  height: 14px;
  border: 0;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

.seasonality-heatmap-empty {
  padding: 18px 14px;
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.35;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
}

.seasonality-analyzer-main-header-chart-graph .js-plotly-plot,
.seasonality-analyzer-main-header-chart-graph .plot-container,
.seasonality-analyzer-main-header-chart-graph .svg-container {
  height: 100% !important;
}

.seasonality-analyzer-main-header-bias-graph .js-plotly-plot,
.seasonality-analyzer-main-header-bias-graph .plot-container,
.seasonality-analyzer-main-header-bias-graph .svg-container {
  height: 100% !important;
}

#seasonality-analyzer-main-header-chart-graph .hoverlayer .hovertext .bg,
#seasonality-analyzer-main-header-chart-line-graph .hoverlayer .hovertext .bg,
#seasonality-analyzer-main-header-bias-graph .hoverlayer .hovertext .bg {
  fill: #ffffff !important;
  stroke: #d0d9e8 !important;
}

#seasonality-analyzer-main-header-chart-graph .hoverlayer .hovertext text,
#seasonality-analyzer-main-header-chart-line-graph .hoverlayer .hovertext text,
#seasonality-analyzer-main-header-bias-graph .hoverlayer .hovertext text {
  fill: #000000 !important;
}

@media (max-width: 980px) {
  .seasonality-period-control {
    width: fit-content;
    max-width: calc(100vw - 24px);
  }

  .seasonality-period-control__summary-value {
    max-width: calc(100% - 110px);
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .seasonality-period-control__dropdown {
    width: min(calc(var(--seasonality-range-block-width) + 20px), calc(100vw - 24px));
  }

  .seasonality-tab-content--analyzer {
    grid-template-columns: minmax(0, 1fr);
    grid-auto-rows: minmax(240px, 1fr);
  }

  .seasonality-analyzer-curve-controls {
    gap: 6px;
  }

  .seasonality-analyzer-main-header-phase-report {
    gap: 10px;
    margin-bottom: 10px;
  }

  .seasonality-phase-report-wrap {
    gap: 10px;
  }

  .seasonality-phase-report-block {
    padding: 10px;
    border-radius: 5px;
  }

  .seasonality-analyzer-main-header-phase-report {
    --seasonality-phase-report-cycle-min-width: 410px;
    --seasonality-phase-report-phase-min-width: 700px;
    --seasonality-phase-report-month-min-width: 600px;
  }

}

@media (max-width: 760px) {
  .seasonality-period-control {
    width: 100%;
    max-width: 100%;
    --seasonality-range-month-width: min(272px, calc(100vw - 72px));
    --seasonality-range-gap: 10px;
    --seasonality-range-block-width: var(--seasonality-range-month-width);
  }

  .seasonality-period-control__dropdown {
    width: calc(100vw - 24px);
  }

  .seasonality-period-control__summary {
    width: 100%;
    justify-content: space-between;
  }

  .seasonality-period-control__range.journaling-date-range-picker {
    width: 100%;
  }

  #seasonality-analyzer-period-range-wrap .journaling-date-range-headings,
  #seasonality-analyzer-period-range-wrap .journaling-date-range-calendar,
  #seasonality-analyzer-period-range-wrap .mantine-DatePicker-calendar {
    grid-template-columns: minmax(0, var(--seasonality-range-month-width));
    max-width: 100%;
    justify-content: center;
  }

  #seasonality-analyzer-period-range-wrap .journaling-date-range-headings {
    gap: 8px;
  }

  #seasonality-analyzer-period-range-wrap .journaling-date-range-month,
  #seasonality-analyzer-period-range-wrap .mantine-DatePicker-month {
    max-width: 100%;
  }

  .seasonality-playbook-window-control {
    --seasonality-playbook-range-month-width: min(272px, calc(100vw - 72px));
    --seasonality-playbook-range-gap: 10px;
    --seasonality-playbook-range-block-width: var(--seasonality-playbook-range-month-width);
  }

  .seasonality-playbook-window-control__dropdown {
    width: calc(100vw - 24px);
  }

  #seasonality-analyzer-playbook-window-range-wrap .journaling-date-range-headings,
  #seasonality-analyzer-playbook-window-range-wrap .journaling-date-range-calendar,
  #seasonality-analyzer-playbook-window-range-wrap .mantine-DatePicker-calendar {
    grid-template-columns: minmax(0, var(--seasonality-playbook-range-month-width));
    max-width: 100%;
    justify-content: center;
  }

  #seasonality-analyzer-playbook-window-range-wrap .journaling-date-range-headings {
    gap: 8px;
  }

  #seasonality-analyzer-playbook-window-range-wrap .journaling-date-range-month,
  #seasonality-analyzer-playbook-window-range-wrap .mantine-DatePicker-month {
    max-width: 100%;
  }

  .seasonality-playbook-hero {
    grid-template-columns: minmax(0, 1fr);
  }

  .seasonality-tab-toolbar__actions {
    margin-left: 0;
  }

  .seasonality-analyzer-curve-controls {
    width: 100%;
    justify-content: flex-start;
  }

  .seasonality-analyzer-line-years-dropdown {
    width: 128px;
    min-width: 128px;
  }

  .seasonality-analyzer-main-header-toolbar-content {
    align-items: stretch;
  }

  #seasonality-analyzer-main-header-toolbar-advanced-wrap {
    width: 100%;
  }

  #seasonality-analyzer-main-header-toolbar-advanced-wrap .seasonality-period-control__field--advanced {
    flex: 1 1 100%;
    min-width: 0;
  }

  .seasonality-analyzer-main-header-toolbar-content .seasonality-period-control__field--toolbar-apply {
    width: 100%;
    justify-content: flex-start;
    margin-left: 0;
  }

  .seasonality-analyzer-main-header-phase-report {
    gap: 8px;
    margin-bottom: 8px;
    --seasonality-phase-report-cycle-min-width: 360px;
    --seasonality-phase-report-phase-min-width: 620px;
    --seasonality-phase-report-month-min-width: 540px;
  }

  .seasonality-phase-report-wrap {
    gap: 9px;
  }

  .seasonality-phase-report-block {
    padding: 9px;
    border-radius: 5px;
  }

  .seasonality-phase-report-block__title {
    font-size: 0.82rem;
  }

  .seasonality-phase-report-block__subtitle {
    font-size: 0.73rem;
  }

  .seasonality-phase-report-block__summary {
    padding: 7px 8px;
    font-size: 0.72rem;
  }

  .seasonality-phase-report-table-title {
    padding: 7px 8px;
    font-size: 0.69rem;
  }

  .seasonality-phase-report-table th,
  .seasonality-phase-report-table td {
    padding: 4px 6px;
    font-size: 0.69rem;
  }
}
