.etf-finder {
  --etf-border: #d9dee5;
  --etf-text: #111827;
  --etf-muted: #4b5563;
  --etf-accent: #dc2626;
  --etf-positive: #008c3a;
  --etf-cta-bg: #065f46;
  --etf-cta-hover: #0f766e;
  --etf-cta-text: #fff;
  color: var(--etf-text);
  font-family: inherit;
}

.etf-finder * {
  box-sizing: border-box;
}

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

.etf-finder__header h2 {
  font-size: 28px;
  line-height: 1.15;
  margin: 0 0 6px;
}

.etf-finder__header p,
.etf-card p,
.etf-finder__meta {
  color: var(--etf-muted);
}

.etf-finder button,
.etf-finder select,
.etf-finder input {
  border: 1px solid var(--etf-border);
  border-radius: 8px;
  font: inherit;
}

.etf-finder button {
  appearance: none;
  background: #fff !important;
  color: var(--etf-text) !important;
  cursor: pointer;
  font-weight: 600;
  padding: 10px 14px;
}

.etf-finder button:hover {
  background: #fff !important;
  border-color: var(--etf-accent);
  color: var(--etf-accent) !important;
}

.etf-finder button:focus-visible {
  border-color: var(--etf-accent);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.18);
  outline: none;
}

.etf-finder__controls {
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(220px, 2fr) repeat(5, minmax(135px, 1fr));
  margin-bottom: 14px;
}

.etf-finder__field,
.etf-finder__search {
  display: grid;
  gap: 6px;
}

.etf-finder__field span,
.etf-finder__search span {
  color: var(--etf-muted);
  font-size: 13px;
}

.etf-finder input,
.etf-finder select {
  background: #fff;
  min-height: 42px;
  padding: 9px 12px;
  width: 100%;
}

.etf-finder__meta {
  font-size: 14px;
  margin: 0 0 14px;
}

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

.etf-card {
  background: #fff;
  border: 1px solid var(--etf-border);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  padding: 18px;
}

.etf-card__top {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
}

.etf-card__actions,
.etf-table__actions {
  align-items: stretch;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.etf-card__compare-corner {
  display: flex;
  justify-content: flex-end;
  margin-top: auto;
  padding-top: 14px;
}

.etf-compare-toggle {
  align-items: center;
  background: #fff !important;
  border: 1px solid var(--etf-border);
  border-radius: 7px;
  display: inline-flex;
  height: 34px;
  justify-content: center;
  min-height: 34px;
  padding: 0 !important;
  width: 34px;
}

.etf-compare-toggle span {
  border: 2px solid #9ca3af;
  border-radius: 4px;
  display: block;
  height: 16px;
  position: relative;
  width: 16px;
}

.etf-compare-toggle[aria-pressed="true"] {
  background: #e7f4ef !important;
  border-color: var(--etf-cta-bg);
}

.etf-compare-toggle[aria-pressed="true"] span {
  background: var(--etf-cta-bg);
  border-color: var(--etf-cta-bg);
}

.etf-compare-toggle[aria-pressed="true"] span::after {
  border: solid var(--etf-cta-text);
  border-width: 0 2px 2px 0;
  content: "";
  height: 8px;
  left: 5px;
  position: absolute;
  top: 1px;
  transform: rotate(45deg);
  width: 4px;
}

.etf-card__top strong {
  display: block;
  font-size: 18px;
}

.etf-card__top span,
.etf-card small {
  color: var(--etf-muted);
  font-size: 12px;
}

.etf-card h3 {
  font-size: 16px;
  line-height: 1.35;
  margin: 12px 0 4px;
}

.etf-card__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0;
}

.etf-card__chips span,
.etf-table__chip {
  background: #f3f4f6;
  border-radius: 8px;
  color: #111827;
  display: inline-block;
  font-size: 12px;
  padding: 5px 8px;
}

.etf-card__metrics,
.etf-detail__grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(4, 1fr);
  margin: 0;
}

.etf-card__metrics div,
.etf-detail__grid div {
  min-width: 0;
}

.etf-card dt,
.etf-detail dt {
  color: var(--etf-muted);
  font-size: 12px;
}

.etf-card dd,
.etf-detail dd {
  font-weight: 700;
  margin: 3px 0 0;
}

.etf-card__metrics dd {
  color: var(--etf-positive);
}

.etf-table-wrap {
  border: 1px solid var(--etf-border);
  border-radius: 8px;
  overflow-x: auto;
}

.etf-table {
  border-collapse: collapse;
  min-width: 860px;
  table-layout: fixed;
  width: 100%;
}

.etf-table th,
.etf-table td {
  border-bottom: 1px solid var(--etf-border);
  padding: 12px;
  text-align: left;
  vertical-align: middle;
}

.etf-table th {
  color: var(--etf-muted);
  font-size: 13px;
  font-weight: 600;
}

.etf-table__select {
  text-align: center !important;
  width: 54px;
}

.etf-table__etf {
  width: 330px;
}

.etf-table__category {
  width: 145px;
}

.etf-table__actions-heading,
.etf-table__actions-cell {
  width: 64px;
}

.etf-table__etf strong,
.etf-table__etf small,
.etf-table__name {
  display: block;
}

.etf-table__etf strong {
  font-size: 15px;
  margin-bottom: 3px;
}

.etf-table__name {
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 4px;
  overflow-wrap: anywhere;
}

.etf-table__etf small {
  color: var(--etf-muted);
  font-size: 12px;
  line-height: 1.3;
}

.etf-table__metric {
  font-variant-numeric: tabular-nums;
  text-align: right !important;
  white-space: nowrap;
  width: 72px;
}

.etf-table__metric--positive {
  color: var(--etf-positive);
  font-weight: 700;
}

.etf-table__metric--cost {
  font-weight: 700;
}

.etf-table__chip {
  line-height: 1.25;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.etf-table__actions {
  justify-content: flex-end;
}

.etf-table__actions button {
  font-size: 12px;
  min-height: 34px;
  padding: 6px 9px;
}

.etf-detail {
  background: rgba(17, 24, 39, 0.48);
  inset: 0;
  position: fixed;
  z-index: 9999;
}

.etf-detail__panel {
  background: #fff;
  border-left: 1px solid var(--etf-border);
  height: 100%;
  margin-left: auto;
  max-width: 560px;
  overflow: auto;
  padding: 28px;
  width: min(100%, 560px);
}

.etf-detail__close {
  float: right;
}

.etf-detail h2 {
  font-size: 32px;
  margin: 18px 0 6px;
}

.etf-detail__summary {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 22px 0;
}

.etf-detail__highlight {
  background: #f8fafc;
  border: 1px solid var(--etf-border);
  border-radius: 8px;
  padding: 14px;
}

.etf-detail__highlight span {
  color: var(--etf-muted);
  display: block;
  font-size: 12px;
  margin-bottom: 6px;
}

.etf-detail__highlight strong {
  color: var(--etf-text);
  display: block;
  font-size: 15px;
  line-height: 1.35;
}

.etf-detail__highlight strong span {
  color: var(--etf-positive);
  display: inline;
  font-size: inherit;
  margin: 0;
}

.etf-detail__grid {
  grid-template-columns: repeat(2, 1fr);
  margin-top: 22px;
}

.etf-detail__holdings {
  border-top: 1px solid var(--etf-border);
  margin-top: 22px;
  padding-top: 18px;
}

.etf-detail__holdings h3 {
  font-size: 18px;
  line-height: 1.3;
  margin: 0 0 12px;
}

.etf-detail__holdings ol {
  display: grid;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.etf-detail__holdings li {
  align-items: center;
  border: 1px solid var(--etf-border);
  border-radius: 8px;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  padding: 11px 12px;
}

.etf-detail__holdings li span {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.etf-detail__holdings li strong {
  font-size: 14px;
  line-height: 1.3;
}

.etf-detail__holdings li small {
  color: var(--etf-muted);
  font-size: 12px;
}

.etf-detail__holdings li b {
  color: var(--etf-positive);
  white-space: nowrap;
}

.etf-detail__profile-link {
  align-items: center;
  border: 1px solid var(--etf-border);
  border-radius: 8px;
  color: var(--etf-text);
  display: flex;
  font-weight: 700;
  justify-content: center;
  margin: 24px 0 12px;
  min-height: 42px;
  padding: 9px 12px;
  text-decoration: none;
}

.etf-detail__profile-link:hover,
.etf-detail__profile-link:focus {
  border-color: var(--etf-accent);
  color: var(--etf-accent);
  text-decoration: none;
}

.etf-detail__cta {
  align-items: center;
  background: var(--etf-cta-bg);
  border: 1px solid var(--etf-cta-bg);
  border-radius: 8px;
  color: var(--etf-cta-text) !important;
  display: flex;
  font-weight: 700;
  justify-content: center;
  margin-top: 0;
  min-height: 44px;
  padding: 11px 16px;
  text-decoration: none;
  width: 100%;
}

.etf-detail__cta:hover,
.etf-detail__cta:focus {
  background: var(--etf-cta-hover);
  border-color: var(--etf-cta-hover);
  color: var(--etf-cta-text) !important;
  text-decoration: none;
}

.etf-detail__risk {
  color: var(--etf-muted);
  font-size: 12px;
  line-height: 1.45;
  margin: 10px 0 0;
  max-width: 460px;
}

.etf-compare-tray {
  background: #fff;
  border: 1px solid var(--etf-border);
  border-radius: 8px;
  bottom: 16px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.16);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  left: 50%;
  max-width: min(760px, calc(100% - 32px));
  padding: 10px 12px;
  position: fixed;
  transform: translateX(-50%);
  width: auto;
  z-index: 9998;
}

.etf-compare-tray > strong {
  white-space: nowrap;
}

.etf-compare-tray > strong span {
  color: var(--etf-muted);
  font-size: 12px;
}

.etf-compare-tray ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.etf-compare-tray li {
  align-items: center;
  background: #f3f4f6;
  border-radius: 8px;
  display: flex;
  gap: 8px;
  padding: 5px 6px 5px 10px;
}

.etf-compare-tray li button {
  min-height: 28px;
  padding: 2px 8px;
}

.etf-compare-tray__actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-left: auto;
}

.etf-compare-tray__actions a {
  background: var(--etf-cta-bg);
  border-radius: 8px;
  color: var(--etf-cta-text);
  font-weight: 700;
  padding: 10px 14px;
  text-decoration: none;
}

.etf-compare-tray__actions a:hover,
.etf-compare-tray__actions a:focus {
  background: var(--etf-cta-hover);
  color: var(--etf-cta-text);
  text-decoration: none;
}

.stock-compare-template-shell {
  box-sizing: border-box;
  margin-left: auto !important;
  margin-right: auto !important;
  max-width: 1040px !important;
  width: min(100%, 1040px) !important;
}

.etf-compare-page {
  box-sizing: border-box;
  color: #111827;
  margin-left: auto !important;
  margin-right: auto !important;
  max-width: 1120px !important;
  padding: 32px 20px 56px;
  width: min(100%, 1120px) !important;
}

.stock-compare-page {
  max-width: 1040px !important;
  width: min(100%, 1040px) !important;
}

.etf-compare-page *,
.etf-compare-page *::before,
.etf-compare-page *::after {
  box-sizing: border-box;
}

.etf-compare__header {
  border-bottom: 1px solid #d9dee5;
  margin-bottom: 24px;
  padding-bottom: 18px;
}

.etf-compare__header h1 {
  font-size: 38px;
  line-height: 1.15;
  margin: 0 0 10px;
}

.etf-compare__cards,
.etf-compare__holdings-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin: 0 0 24px;
}

.etf-compare__card,
.etf-compare__holdings article {
  border: 1px solid #d9dee5;
  border-radius: 8px;
  padding: 16px;
}

.etf-compare__card h2,
.etf-compare__holdings h3 {
  margin: 0 0 8px;
}

.etf-compare__table-wrap {
  border: 1px solid #d9dee5;
  border-radius: 8px;
  margin: 0 0 28px;
  overflow-x: auto;
}

.etf-compare__table {
  border-collapse: collapse;
  min-width: 760px;
  width: 100%;
}

.etf-compare__table th,
.etf-compare__table td {
  border-bottom: 1px solid #e5e7eb;
  padding: 13px 14px;
  text-align: left;
}

.etf-compare__table th {
  color: #4b5563;
  font-weight: 700;
}

.etf-compare__table td {
  font-weight: 700;
}

.etf-compare__holdings ol {
  display: grid;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.etf-compare__holdings li {
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  padding: 9px 10px;
}

.etf-compare__holdings b {
  color: var(--etf-positive);
  white-space: nowrap;
}

.etf-compare__summary,
.stock-compare__summary,
.stock-analysis-page section {
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 24px;
  padding-bottom: 22px;
}

.stock-analysis-template-shell {
  box-sizing: border-box;
  margin-left: auto !important;
  margin-right: auto !important;
  max-width: 1040px !important;
  width: min(100%, 1040px) !important;
}

.stock-analysis-page {
  box-sizing: border-box;
  color: #111827;
  display: block;
  margin-left: auto !important;
  margin-right: auto !important;
  max-width: 1040px !important;
  padding: 30px 20px 54px;
  width: min(100%, 1040px) !important;
}

.stock-analysis-page *,
.stock-analysis-page *::before,
.stock-analysis-page *::after {
  box-sizing: border-box;
}

.stock-analysis-header {
  border-bottom: 1px solid #d9dee5;
  margin-bottom: 22px;
  padding-bottom: 20px;
}

.stock-analysis-kicker,
.stock-analysis-eyebrow {
  color: #b91c1c;
  display: block;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
  margin: 0 0 8px;
  text-transform: uppercase;
}

.stock-analysis-header h1 {
  font-size: 40px;
  line-height: 1.12;
  margin: 0 0 12px;
}

.stock-analysis-lede {
  color: #374151;
  font-size: 17px;
  line-height: 1.6;
  margin: 0 0 12px;
  max-width: 860px;
}

.stock-analysis-back-link {
  color: #b91c1c;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.stock-analysis-back-link:hover,
.stock-analysis-back-link:focus-visible {
  text-decoration: underline;
}

.stock-analysis-page .stock-analysis-hero {
  background: #f8fafc;
  border: 1px solid #d9dee5;
  border-radius: 8px;
  margin-bottom: 28px;
  padding: 16px;
}

.stock-analysis-hero__grid,
.stock-analysis-metric-grid,
.stock-analysis-module-grid {
  display: grid;
  gap: 14px;
}

.stock-analysis-hero__grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.stock-analysis-metric-grid {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  margin: 0 0 18px;
}

.stock-analysis-module-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.stock-analysis-metric {
  background: #fff;
  border: 1px solid #d9dee5;
  border-radius: 8px;
  display: grid;
  gap: 6px;
  padding: 14px;
}

.stock-analysis-metric.is-primary {
  border-color: #cbd5e1;
}

.stock-analysis-metric__label {
  color: #4b5563;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.stock-analysis-metric__value {
  color: #111827;
  font-size: 24px;
  font-variant-numeric: tabular-nums;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.stock-analysis-metric__meta {
  color: #4b5563;
  font-size: 13px;
  line-height: 1.45;
}

.stock-analysis-metric.is-positive .stock-analysis-metric__value {
  color: var(--etf-positive, #047857);
}

.stock-analysis-metric.is-negative .stock-analysis-metric__value {
  color: #b91c1c;
}

.stock-analysis-page .stock-analysis-section {
  background: #fff;
  border: 1px solid #d9dee5;
  border-radius: 8px;
  margin-bottom: 24px;
  padding: 18px;
}

.stock-analysis-page .etf-profile-facts {
  background: #fff;
  border: 1px solid #d9dee5 !important;
  border-radius: 8px;
  overflow: hidden;
}

.stock-analysis-page .etf-profile-facts table {
  border: 0 !important;
  border-collapse: collapse !important;
  margin: 0 !important;
  table-layout: fixed;
  width: 100% !important;
}

.stock-analysis-page .etf-profile-facts th,
.stock-analysis-page .etf-profile-facts td {
  border: 0 !important;
  border-bottom: 1px solid #e5e7eb !important;
  font-size: 14px !important;
  line-height: 1.45;
  padding: 12px 14px !important;
  text-align: left !important;
  vertical-align: top;
}

.stock-analysis-page .etf-profile-facts th {
  background: #f8fafc;
  color: #4b5563;
  font-weight: 700;
  width: 42%;
}

.stock-analysis-page .etf-profile-facts td {
  color: #111827;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.stock-analysis-page .etf-profile-facts tr:last-child th,
.stock-analysis-page .etf-profile-facts tr:last-child td {
  border-bottom: 0 !important;
}

.stock-analysis-section__head {
  margin: 0 0 16px;
}

.stock-analysis-section h2 {
  font-size: 24px;
  line-height: 1.25;
  margin: 0 0 12px;
}

.stock-analysis-section__head h2 {
  margin-bottom: 8px;
}

.stock-analysis-section__head p,
.stock-analysis-section p {
  color: #374151;
  line-height: 1.65;
}

.stock-analysis-distribution {
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  margin: 0 0 18px;
  padding: 14px;
}

.stock-analysis-distribution__bar {
  background: #e5e7eb;
  border-radius: 8px;
  display: flex;
  height: 12px;
  overflow: hidden;
}

.stock-analysis-distribution__bar span {
  display: block;
}

.stock-analysis-distribution .is-strong-buy,
.stock-analysis-distribution__bar .is-strong-buy {
  background: #047857;
}

.stock-analysis-distribution .is-buy,
.stock-analysis-distribution__bar .is-buy {
  background: #10b981;
}

.stock-analysis-distribution .is-hold,
.stock-analysis-distribution__bar .is-hold {
  background: #f59e0b;
}

.stock-analysis-distribution .is-sell,
.stock-analysis-distribution__bar .is-sell {
  background: #ef4444;
}

.stock-analysis-distribution .is-strong-sell,
.stock-analysis-distribution__bar .is-strong-sell {
  background: #991b1b;
}

.stock-analysis-distribution__legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 12px;
}

.stock-analysis-distribution__legend span {
  color: #374151;
  display: inline-flex;
  font-size: 13px;
  gap: 6px;
  line-height: 1.35;
}

.stock-analysis-distribution__legend i {
  border-radius: 999px;
  display: inline-block;
  height: 10px;
  margin-top: 3px;
  width: 10px;
}

.stock-analysis-faq__items {
  display: grid;
  gap: 12px;
}

.stock-analysis-faq__item {
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 14px;
}

.stock-analysis-faq__item h3 {
  font-size: 17px;
  line-height: 1.35;
  margin: 0 0 8px;
}

.stock-analysis-faq__item p {
  margin: 0;
}

.stock-collection-table-wrap {
  margin: 22px 0;
}

.stock-collection-table strong {
  color: #111827;
}

.stock-collection-table td:nth-child(n+5) {
  color: var(--etf-positive);
  font-weight: 700;
}

.stock-collection-table td:last-child {
  color: inherit;
  font-weight: 600;
}

.etf-finder__loading,
.etf-finder__error {
  border: 1px solid var(--etf-border);
  border-radius: 8px;
  padding: 18px;
}

@media (max-width: 900px) {
  .etf-finder__header {
    display: grid;
  }

  .etf-finder__controls,
  .etf-grid {
    grid-template-columns: 1fr;
  }

  .etf-card__metrics {
    grid-template-columns: repeat(2, 1fr);
  }

  .etf-detail__summary,
  .etf-detail__grid {
    grid-template-columns: 1fr;
  }

  .etf-table-wrap,
  .etf-finder [data-view-toggle] {
    display: none;
  }

  .etf-compare-tray {
    bottom: 10px;
    max-width: calc(100% - 20px);
    width: calc(100% - 20px);
  }
}

.etf-profile-page {
  color: #111827;
  margin: 0 auto;
  max-width: 1040px;
  padding: 32px 20px 56px;
}

.etf-profile-hero {
  border-bottom: 1px solid #d9dee5;
  margin-bottom: 28px;
  padding-bottom: 22px;
}

.etf-profile-kicker,
.etf-profile-data-date {
  color: #4b5563;
  font-size: 14px;
  margin: 0 0 8px;
}

.etf-profile-hero h1 {
  font-size: 38px;
  line-height: 1.15;
  margin: 0 0 10px;
}

.etf-profile-hero__actions {
  display: grid;
  gap: 10px;
  margin-top: 16px;
  max-width: 360px;
}

.etf-profile-hero__risk {
  color: #4b5563;
  font-size: 13px;
  margin: 0;
}

.etf-profile-cta-section {
  padding-top: 2px;
}

.etf-profile-cta-block {
  display: grid;
  gap: 10px;
  max-width: 420px;
}

.etf-profile-cta-risk {
  color: #4b5563;
  font-size: 13px;
  line-height: 1.5;
  margin: 0;
}

.etf-profile-content section {
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 24px;
  padding-bottom: 22px;
}

.etf-profile-nav {
  background: #f3f4f6;
  border: 1px solid #d9dee5;
  border-radius: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  margin: 0 0 24px;
  padding: 6px;
  position: sticky;
  top: 0;
  z-index: 2;
}

.etf-profile-nav a {
  border-radius: 6px;
  color: #111827;
  font-weight: 700;
  padding: 9px 12px;
  text-decoration: none;
}

.etf-profile-nav a:hover,
.etf-profile-nav a:focus {
  background: #fff;
  color: #dc2626;
}

.etf-profile-content h2 {
  font-size: 24px;
  line-height: 1.25;
  margin: 0 0 14px;
}

.etf-profile-content h3 {
  font-size: 18px;
  line-height: 1.3;
  margin: 18px 0 6px;
}

.etf-profile-lede {
  font-size: 18px;
  line-height: 1.6;
}

.etf-profile-facts,
.etf-profile-table-wrap {
  border: 1px solid #d9dee5;
  border-radius: 8px;
  overflow-x: auto;
}

.etf-profile-facts table,
.etf-profile-table {
  border-collapse: collapse;
  width: 100%;
}

.etf-profile-facts th,
.etf-profile-facts td,
.etf-profile-table th,
.etf-profile-table td {
  border-bottom: 1px solid #e5e7eb;
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
}

.etf-profile-facts th,
.etf-profile-table th {
  color: #4b5563;
  font-size: 13px;
  font-weight: 700;
  width: 38%;
}

.etf-profile-facts td,
.etf-profile-table td {
  color: #111827;
  font-weight: 700;
}

.etf-profile-facts tr:last-child th,
.etf-profile-facts tr:last-child td,
.etf-profile-table tr:last-child th,
.etf-profile-table tr:last-child td {
  border-bottom: 0;
}

.etf-profile-breakdown td:last-child,
.etf-profile-breakdown th:last-child {
  text-align: right;
}

.etf-profile-disclaimer {
  color: #374151;
  font-size: 14px;
  line-height: 1.6;
  margin: 0;
}

.etf-profile-disclaimer em {
  color: #4b5563;
  display: block;
  font-style: italic;
}

.etf-profile-similar ul,
.etf-profile-sources ul {
  display: grid;
  gap: 10px;
  list-style: none;
  margin: 12px 0;
  padding: 0;
}

.etf-profile-similar li {
  border: 1px solid #d9dee5;
  border-radius: 8px;
  display: grid;
  gap: 5px;
  padding: 12px 14px;
}

.etf-profile-similar li strong {
  color: #111827;
}

.etf-profile-similar a {
  color: #065f46;
  font-weight: 700;
  text-decoration: none;
}

.etf-profile-similar a:hover,
.etf-profile-similar a:focus {
  color: #dc2626;
  text-decoration: underline;
}

.etf-profile-similar li span,
.etf-profile-muted {
  color: #4b5563;
  font-size: 14px;
  line-height: 1.45;
}

.etf-profile-sources a {
  color: #065f46;
  font-weight: 700;
  text-decoration: none;
}

.etf-profile-sources a:hover,
.etf-profile-sources a:focus {
  color: #dc2626;
  text-decoration: underline;
}

.etf-profile-related,
.etf-profile-related-links {
  margin-top: 18px;
}

.etf-profile-related ul,
.etf-profile-related-links {
  display: grid;
  gap: 10px;
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
}

.etf-profile-related li,
.etf-profile-related-links li {
  border: 1px solid #d9dee5;
  border-radius: 8px;
  display: grid;
  gap: 4px;
  padding: 12px 14px;
}

.etf-profile-related li span {
  color: #4b5563;
  font-size: 12px;
}

.etf-profile-related a,
.etf-profile-related-links a,
.etf-landing-table a {
  color: #065f46;
  font-weight: 700;
  text-decoration: none;
}

.etf-profile-related a:hover,
.etf-profile-related a:focus,
.etf-profile-related-links a:hover,
.etf-profile-related-links a:focus,
.etf-landing-table a:hover,
.etf-landing-table a:focus {
  color: #dc2626;
  text-decoration: underline;
}

.etf-landing-content section {
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 24px;
  padding-bottom: 22px;
}

.etf-landing-table td,
.etf-landing-table th {
  vertical-align: top;
}

@media (max-width: 760px) {
  .etf-profile-hero h1 {
    font-size: 30px;
  }

  .etf-profile-nav {
    position: static;
  }

  .etf-profile-facts th,
  .etf-profile-facts td {
    display: block;
    width: 100%;
  }
}

.stock-finder {
  color: var(--etf-text, #111827);
}

.stock-finder__header {
  border-bottom: 1px solid var(--etf-border, #d9dee5);
  margin-bottom: 20px;
  padding-bottom: 16px;
}

.stock-finder__header h2 {
  font-size: 28px;
  line-height: 1.15;
  margin: 0 0 6px;
}

.stock-finder__header p,
.stock-finder__meta,
.stock-finder__empty {
  color: var(--etf-muted, #4b5563);
}

.stock-finder__controls {
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(220px, 2fr) repeat(5, minmax(140px, 1fr));
  margin-bottom: 14px;
}

.stock-finder__field {
  display: grid;
  gap: 6px;
}

.stock-finder__field span {
  color: var(--etf-muted, #4b5563);
  font-size: 13px;
}

.stock-finder__field input,
.stock-finder__field select {
  background: #fff;
  border: 1px solid var(--etf-border, #d9dee5);
  border-radius: 8px;
  min-height: 42px;
  padding: 9px 12px;
  width: 100%;
}

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

.stock-card {
  background: #fff;
  border: 1px solid var(--etf-border, #d9dee5);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 100%;
  padding: 18px;
}

.stock-card__head {
  align-items: flex-start;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  min-width: 0;
}

.stock-card__head > div {
  min-width: 0;
}

.stock-card__head strong {
  display: block;
  font-size: 18px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.stock-card__head span,
.stock-card__isin {
  color: var(--etf-muted, #4b5563);
  font-size: 12px;
  line-height: 1.35;
}

.stock-card__isin {
  margin: 0;
  overflow-wrap: anywhere;
}

.stock-card__button {
  background: #fff;
  border: 1px solid var(--etf-border, #d9dee5);
  border-radius: 8px;
  color: var(--etf-text, #111827);
  cursor: pointer;
  display: inline-flex;
  font-size: 13px;
  font-weight: 600;
  min-height: 34px;
  padding: 8px 12px;
  text-decoration: none;
}

.stock-card__button:hover,
.stock-card__button:focus-visible {
  border-color: var(--etf-accent, #dc2626);
  color: var(--etf-accent, #dc2626);
  outline: none;
}

.stock-card h3 {
  font-size: 17px;
  line-height: 1.35;
  margin: 0;
  overflow-wrap: anywhere;
}

.stock-card__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 2px 0;
}

.stock-card__chips span {
  background: #f3f4f6;
  border-radius: 8px;
  font-size: 12px;
  padding: 5px 8px;
}

.stock-card__metrics {
  display: grid;
  gap: 12px 16px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
}

.stock-card__metrics > div {
  min-width: 0;
}

.stock-card__metrics dt {
  color: var(--etf-muted, #4b5563);
  font-size: 12px;
  line-height: 1.25;
  margin: 0;
}

.stock-card__metrics dd {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
  margin: 3px 0 0;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.stock-card__currency {
  color: inherit;
  display: inline-block;
  font-size: inherit;
  font-weight: inherit;
  line-height: 1;
}

.etf-finder .etf-card,
.stock-finder .stock-card {
  box-sizing: border-box;
  color: var(--etf-text, #111827);
  font-size: 14px !important;
  line-height: 1.45;
  min-width: 0;
  overflow: hidden;
}

.etf-finder .etf-card *,
.stock-finder .stock-card * {
  box-sizing: border-box;
}

.etf-finder .etf-card__top strong,
.stock-finder .stock-card__head strong {
  font-size: 17px !important;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.etf-finder .etf-card h3,
.stock-finder .stock-card h3 {
  color: var(--etf-text, #111827);
  font-size: 15px !important;
  font-weight: 700;
  line-height: 1.35 !important;
  overflow-wrap: anywhere;
}

.etf-finder .etf-card p,
.stock-finder .stock-card__isin {
  font-size: 12px !important;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.etf-finder .etf-card__chips span,
.stock-finder .stock-card__chips span {
  color: var(--etf-text, #111827);
  font-size: 11px !important;
  line-height: 1.25;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.etf-finder .etf-card__metrics,
.stock-finder .stock-card__metrics {
  gap: 10px 14px;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  width: 100%;
}

.etf-finder .etf-card__metrics dt,
.stock-finder .stock-card__metrics dt {
  color: var(--etf-muted, #4b5563);
  font-size: 11px !important;
  font-weight: 600;
  letter-spacing: normal;
  line-height: 1.25;
  margin: 0;
}

.etf-finder .etf-card__metrics dd,
.stock-finder .stock-card__metrics dd {
  color: var(--etf-positive, #007a3d);
  font-size: 15px !important;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  line-height: 1.25 !important;
  margin: 3px 0 0;
  max-width: 100%;
  overflow-wrap: anywhere;
  word-break: normal;
}

.etf-finder .etf-card__metrics dd.is-empty,
.stock-finder .stock-card__metrics dd.is-empty {
  color: var(--etf-muted, #4b5563);
  font-weight: 700;
}

.etf-finder .etf-card__actions button,
.stock-finder .stock-card__button {
  font-size: 13px !important;
  line-height: 1.2;
  white-space: nowrap;
}

.stock-detail {
  background: rgba(17, 24, 39, 0.48);
  inset: 0;
  position: fixed;
  z-index: 9999;
}

.stock-detail__panel {
  background: #fff;
  border-left: 1px solid var(--etf-border, #d9dee5);
  height: 100%;
  margin-left: auto;
  max-width: 560px;
  overflow: auto;
  padding: 28px;
  width: min(100%, 560px);
}

.stock-detail__close {
  float: right;
}

.stock-detail h2 {
  font-size: 32px;
  line-height: 1.15;
  margin: 18px 0 6px;
}

.stock-detail__name {
  font-size: 15px;
  line-height: 1.45;
  margin: 0 0 14px;
}

.stock-detail__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
}

.stock-detail__chips span {
  background: #f3f4f6;
  border-radius: 8px;
  color: var(--etf-text, #111827);
  font-size: 12px;
  line-height: 1.25;
  padding: 5px 8px;
}

.stock-detail__summary {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 22px 0;
}

.stock-detail__highlight {
  background: #f8fafc;
  border: 1px solid var(--etf-border, #d9dee5);
  border-radius: 8px;
  padding: 14px;
}

.stock-detail__highlight span,
.stock-detail dt {
  color: var(--etf-muted, #4b5563);
  display: block;
  font-size: 12px;
  line-height: 1.35;
  margin-bottom: 6px;
}

.stock-detail__highlight strong,
.stock-detail dd {
  color: var(--etf-text, #111827);
  display: block;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.35;
  margin: 0;
  overflow-wrap: anywhere;
}

.stock-detail__grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 22px 0 0;
}

.stock-detail__grid div {
  border-bottom: 1px solid var(--etf-border, #d9dee5);
  min-width: 0;
  padding: 0 0 10px;
}

.stock-detail__profile-link {
  align-items: center;
  border: 1px solid var(--etf-border, #d9dee5);
  border-radius: 8px;
  color: var(--etf-text, #111827);
  display: flex;
  font-weight: 700;
  justify-content: center;
  margin: 24px 0 12px;
  min-height: 42px;
  padding: 9px 12px;
  text-decoration: none;
}

.stock-detail__profile-link:hover,
.stock-detail__profile-link:focus {
  border-color: var(--etf-accent, #dc2626);
  color: var(--etf-accent, #dc2626);
  text-decoration: none;
}

.stock-detail__cta {
  align-items: center;
  background: var(--etf-cta-bg, #005f56);
  border: 1px solid var(--etf-cta-bg, #005f56);
  border-radius: 8px;
  color: var(--etf-cta-text, #fff) !important;
  display: flex;
  font-weight: 700;
  justify-content: center;
  margin-top: 0;
  min-height: 44px;
  padding: 11px 16px;
  text-decoration: none;
  width: 100%;
}

.stock-detail__cta:hover,
.stock-detail__cta:focus {
  background: var(--etf-cta-hover, #00453f);
  border-color: var(--etf-cta-hover, #00453f);
  color: var(--etf-cta-text, #fff) !important;
  text-decoration: none;
}

.stock-detail__risk {
  color: var(--etf-muted, #4b5563);
  font-size: 12px;
  line-height: 1.45;
  margin: 10px 0 0;
  max-width: 460px;
}

.stock-finder__pager {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 18px;
}

.stock-finder__pager button {
  background: #fff;
  border: 1px solid var(--etf-border, #d9dee5);
  border-radius: 8px;
  color: var(--etf-text, #111827);
  font-size: 13px;
  font-weight: 600;
  padding: 9px 12px;
}

.stock-finder__pager button[disabled] {
  cursor: not-allowed;
  opacity: 0.45;
}

.stock-profile-quote-strip {
  background: #f8fafc;
  border: 1px solid #d9dee5;
  border-radius: 8px;
  margin: 0 0 22px;
  padding: 16px;
}

.stock-profile-quote-grid,
.stock-profile-analyst-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.stock-profile-quote-card,
.stock-profile-analyst-card {
  background: #fff;
  border: 1px solid #d9dee5;
  border-radius: 8px;
  display: grid;
  gap: 5px;
  padding: 14px;
}

.stock-profile-quote-label,
.stock-profile-analyst-label {
  color: #4b5563;
  font-size: 12px;
  line-height: 1.35;
}

.stock-profile-quote-value,
.stock-profile-analyst-value {
  color: #111827;
  display: block;
  font-size: 22px;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.stock-profile-quote-meta,
.stock-profile-analyst-meta {
  color: #4b5563;
  font-size: 13px;
  line-height: 1.45;
}

.stock-profile-analyst-grid {
  margin: 0 0 16px;
}

.stock-profile-widget-block {
  border-top: 1px solid #d9dee5;
  display: grid;
  gap: 16px;
  margin: 20px 0 0;
  padding-top: 18px;
}

.stock-profile-company-news ul {
  display: grid;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.stock-profile-company-news li {
  border: 1px solid #d9dee5;
  border-radius: 8px;
  padding: 12px 14px;
}

.stock-profile-company-news a {
  color: var(--etf-text, #111827);
  display: block;
  font-weight: 700;
  text-decoration: none;
}

.stock-profile-company-news a:hover,
.stock-profile-company-news a:focus-visible {
  color: var(--etf-accent, #dc2626);
  text-decoration: underline;
}

.stock-profile-company-news span {
  color: var(--etf-muted, #4b5563);
  display: block;
  font-size: 12px;
  margin-top: 4px;
}

.stock-profile-related-posts-shortcode {
  margin: 24px 0;
}

@media (max-width: 1100px) {
  .stock-finder__controls {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stock-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .stock-analysis-page {
    padding-left: 14px;
    padding-right: 14px;
  }

  .stock-finder__controls,
  .stock-grid,
  .stock-profile-quote-grid,
  .stock-profile-analyst-grid,
  .stock-analysis-hero__grid,
  .stock-analysis-metric-grid,
  .stock-analysis-module-grid,
  .stock-detail__summary,
  .stock-detail__grid {
    grid-template-columns: 1fr;
  }

  .stock-analysis-header h1 {
    font-size: 30px;
  }

  .stock-analysis-metric__value {
    font-size: 21px;
  }

  .stock-card__head {
    flex-direction: column;
  }
}
