.tab { display: grid; place-items: center; text-decoration: none; }
.tool-shell { min-height: 720px; }
.tool-shell > .back-link {
  display: inline-flex;
  width: auto;
  height: 34px;
  padding-right: 8px;
  place-items: unset;
  align-items: center;
  gap: 10px;
  color: var(--green-dark);
  font-size: 24px;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
}
.tool-shell > .back-link span { color: var(--ink); font-size: 15px; line-height: 1.2; white-space: nowrap; }
.compact-header { margin-top: 24px; }
.tool-choice-card, .tool-form-card, .summary-card, .chart-card {
  margin-top: 14px; padding: 20px; border: 1px solid var(--line); border-radius: 17px;
  background: #fff; box-shadow: 0 8px 24px rgba(16, 22, 18, .045);
}
.tool-choice-card h2 { margin: 9px 0 7px; font-size: 21px; letter-spacing: -.035em; }
.tool-choice-card p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.65; }
.tool-badge { display: inline-block; padding: 6px 10px; border-radius: 7px; color: #fff; background: var(--green); font-size: 12px; font-weight: 700; }
.tool-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 15px 0 12px; }
.tool-tags span { padding: 7px 10px; border: 1px solid var(--line); border-radius: 8px; color: #69726b; font-size: 13px; font-weight: 600; }
.primary-action, .secondary-action {
  display: flex; width: 100%; min-height: 48px; align-items: center; justify-content: center;
  border: 1px solid var(--green); border-radius: 10px; font-size: 15px; font-weight: 700; text-decoration: none;
}
.primary-action { color: #fff; background: linear-gradient(135deg, var(--green), #07964f); }
.primary-action.is-disabled { cursor: not-allowed; color: #8c958f; border-color: var(--line); background: #f3f5f3; }
.secondary-action { margin-top: 9px; color: var(--green-dark); background: #fff; }
.action-button { margin-top: 14px; }
.result-tabs { display: grid; grid-template-columns: repeat(3, 1fr); padding: 3px; border: 1px solid var(--line); border-radius: 12px; background: #f7faf8; }
.result-tabs button, .period-buttons button { min-height: 44px; border: 0; border-radius: 9px; color: #667069; background: transparent; font-size: 14px; font-weight: 650; }
.result-tabs button.is-active, .period-buttons button.is-active { color: #fff; background: var(--green); }
.section-heading h2 { margin: 2px 0 0; font-size: 20px; }
.picker-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin-top: 13px; }
.picker-row select, .picker-row button, .field input, .field select {
  min-width: 0; min-height: 42px; border: 1px solid #dce3de; border-radius: 9px; color: var(--ink); background: #fff; font: inherit;
}
.picker-row select, .field input, .field select { padding: 0 11px; }
.picker-row button { padding: 0 14px; color: var(--green-dark); font-weight: 700; }
.portfolio-rows { margin-top: 11px; }
.portfolio-row { display: grid; grid-template-columns: minmax(0, 1fr) 78px 28px; gap: 7px; align-items: center; min-height: 52px; border-bottom: 1px solid #f0f2f0; }
.portfolio-name { min-width: 0; }
.portfolio-name strong { display: block; overflow: hidden; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.portfolio-name small { color: #929a94; font-size: 12px; }
.portfolio-row input { width: 100%; height: 36px; border: 1px solid #dce3de; border-radius: 8px; text-align: right; }
.remove-etf { border: 0; color: #8c958f; background: transparent; font-size: 19px; }
.allocation-summary { display: flex; gap: 8px; align-items: center; justify-content: center; margin-top: 13px; padding: 13px; border-radius: 10px; background: var(--green-soft); font-size: 14px; }
.allocation-summary b { color: var(--green-dark); font-size: 16px; }
.field { display: grid; grid-template-columns: 120px 1fr; gap: 12px; align-items: center; margin-top: 12px; font-size: 14px; font-weight: 600; }
.field-help { margin: 10px 0 0; color: var(--green-dark); font-size: 13px; line-height: 1.55; }
.follow-setting-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; margin-top: 12px; }
.follow-setting-row .field { display: block; margin-top: 0; }
.follow-setting-row .field span { display: block; margin-bottom: 6px; }
.follow-setting-row .field select { width: 100%; }
.follow-allocation-control { margin-top: 14px; }
.follow-control-label { display: block; margin-bottom: 7px; font-size: 14px; font-weight: 600; }
.follow-weight-buttons { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.follow-weight-buttons button { padding: 0 8px; font-size: 14px; }
.period-buttons { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 12px; }
.period-buttons button { border: 1px solid var(--line); }
.summary-card { text-align: center; }
.summary-card > small { display: block; color: var(--muted); }
.summary-card > strong { display: block; margin-top: 6px; color: var(--positive); font-size: 31px; letter-spacing: -.05em; }
.summary-card > span { display: block; margin-top: 4px; color: var(--positive); font-size: 13px; font-weight: 900; }
.metric-grid { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 17px; padding-top: 14px; border-top: 1px solid var(--line); }
.metric-grid > div { padding: 0 6px; border-right: 1px solid var(--line); }
.metric-grid > div:last-child { border-right: 0; }
.metric-grid small { display: block; color: var(--muted); font-size: 12px; }
.metric-grid b { display: block; margin-top: 5px; font-size: 14px; }
.chart-host { min-height: 230px; margin-top: 10px; }
.chart-host svg { display: block; width: 100%; height: 230px; overflow: visible; }
.component-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; padding: 13px 0; border-bottom: 1px solid #f0f2f0; font-size: 14px; }
.component-row:last-child { border-bottom: 0; }
.signal-row { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 9px; align-items: center; min-height: 58px; border-bottom: 1px solid #f0f2f0; }
.signal-row:last-child { border-bottom: 0; }
.signal-row > div { min-width: 0; }
.signal-row strong, .signal-row small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.signal-row strong { font-size: 14px; }
.signal-row small { margin-top: 3px; color: var(--muted); font-size: 12px; }
.signal-row > b { color: var(--positive); font-size: 14px; text-align: right; }
.component-row small { display: block; margin-top: 3px; color: var(--muted); }
.future-summary .metric-grid { margin-top: 0; padding-top: 0; border-top: 0; }
.future-summary > small { margin-top: 15px; }
.tool-message { min-height: 22px; margin-top: 10px; color: var(--negative); font-size: 13px; text-align: center; }
@media (min-width: 740px) {
  .tool-choice-card { padding: 26px; }
}

@media (max-width: 560px) {
  .tool-choice-card, .tool-form-card, .summary-card, .chart-card { padding: 18px 16px; }
  .tool-choice-card h2 { font-size: 20px; }
  .follow-setting-row { grid-template-columns: 1fr 1fr; }
  .field { grid-template-columns: 105px minmax(0, 1fr); }
  .result-tabs button, .period-buttons button { padding-inline: 6px; }
}

@media (max-width: 380px) {
  .follow-setting-row { grid-template-columns: 1fr; }
  .field { grid-template-columns: 1fr; gap: 6px; }
  .metric-grid b { font-size: 13px; }
}

/* ETF 투자 실험실 */
.investment-lab-shell { padding-bottom: 0; }
.lab-content {
  margin: 0 -12px;
  padding: 38px 30px 42px;
  background: #f5f8f6;
}
.lab-page-header { margin-bottom: 30px; }
.lab-page-header h1 { font-size: clamp(28px, 4vw, 34px); }
.lab-page-header p { margin-top: 11px; font-size: 15px; }
.tool-choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.tool-choice-grid .tool-choice-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 390px;
  margin: 0;
  padding: 26px;
  border-color: #d6dfda;
  border-radius: 20px;
  box-shadow: none;
}
.tool-card-icon {
  display: grid;
  width: 54px;
  height: 54px;
  margin-bottom: 20px;
  place-items: center;
  border-radius: 16px;
  color: var(--green);
  background: #e9f8f1;
}
.tool-card-icon svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}
.tool-choice-grid .tool-choice-card h2 {
  margin: 5px 0 10px;
  font-size: clamp(21px, 2.7vw, 26px);
  font-weight: 680;
  line-height: 1.35;
}
.tool-choice-grid .tool-choice-card > p {
  color: #66736b;
  font-size: 15px;
  line-height: 1.7;
}
.tool-card-details {
  display: grid;
  gap: 9px;
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: #5f6d65;
  font-size: 13px;
}
.tool-card-details strong { color: var(--ink); font-weight: 620; }
.tool-choice-grid .primary-action {
  justify-content: space-between;
  min-height: 48px;
  margin-top: 16px;
  padding: 0 16px;
  border-radius: 11px;
  background: var(--green);
}
.lab-disclaimer {
  margin: 22px 2px 0;
  color: #718078;
  font-size: 12px;
}

/* 상위 ETF가 담은 종목 따라가기 */
.active-follow-shell { padding-bottom: 48px; }
.active-follow-shell > .page-header,
.active-follow-shell > section,
.active-follow-shell > aside,
.active-follow-shell > .follow-actions,
.active-follow-shell > .tool-message { margin-right: 28px; margin-left: 28px; }
.active-follow-shell .compact-header { margin-top: 36px; margin-bottom: 26px; }
.active-follow-shell .compact-header h1 {
  font-size: clamp(28px, 4.4vw, 36px);
  font-weight: 720;
  line-height: 1.3;
}
.active-follow-shell .compact-header > p {
  max-width: 760px;
  margin-top: 12px;
  color: #69766e;
  font-size: 15px;
  line-height: 1.65;
}
.follow-performance-card {
  margin-top: 0;
  padding: 20px 28px 18px;
  border-color: #bfdfcf;
  border-radius: 20px;
  background: #eaf8f1;
  box-shadow: none;
  text-align: left;
}
.follow-performance-card > .follow-section-kicker {
  display: block;
  margin: 0;
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 680;
}
.follow-primary-result { padding: 6px 0 12px; text-align: center; }
.follow-primary-result small {
  display: block;
  color: #607168;
  font-size: 13px;
  font-weight: 600;
}
.follow-primary-result strong {
  display: block;
  margin-top: 2px;
  color: var(--positive);
  font-size: clamp(34px, 5vw, 40px);
  font-weight: 690;
  line-height: 1.1;
  letter-spacing: -.045em;
}
.follow-primary-result span {
  display: block;
  margin-top: 4px;
  color: #63736a;
  font-size: 12px;
}
.follow-performance-card .metric-grid {
  margin-top: 0;
  padding-top: 12px;
  border-color: #c9e1d4;
  text-align: center;
}
.follow-performance-card .metric-grid > div { padding: 0 14px; border-color: #c9e1d4; }
.follow-performance-card .metric-grid small { color: #607168; font-size: 13px; }
.follow-performance-card .metric-grid b {
  margin-top: 2px;
  color: var(--ink);
  font-size: 19px;
  font-weight: 660;
}
.follow-performance-card .metric-grid > div:first-child b { color: var(--negative); }
.follow-performance-card .metric-grid > div:last-child b { color: var(--positive); }
.follow-performance-card .metric-grid span {
  display: block;
  margin-top: 2px;
  color: #718078;
  font-size: 11px;
}
.follow-settings {
  margin-top: 22px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #fff;
}
.follow-settings .section-heading h2 { margin-top: 4px; font-size: 20px; }
.follow-settings-kicker {
  display: block;
  color: #76837c;
  font-size: 12px;
  font-weight: 520;
  letter-spacing: .03em;
  line-height: 1.5;
}
.follow-strategy-query {
  margin: 18px 0 0;
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.6;
}
.follow-strategy-query-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 0;
}
.follow-strategy-query-line > span { word-break: keep-all; }
.follow-strategy-query-line + .follow-strategy-query-line { margin-top: 10px; }
.follow-query-mobile-break { margin-left: -6px; }
.follow-strategy-query select {
  width: auto;
  min-width: 104px;
  height: 44px;
  padding: 0 38px 0 13px;
  border: 1px solid #cfe7d9;
  border-radius: 9px;
  color: var(--ink);
  background-color: #fff;
  font: inherit;
  font-size: 14px;
  font-weight: 650;
}
#follow-momentum { min-width: 112px; }
#follow-frequency { min-width: 120px; }
#follow-weighting { min-width: 190px; }
.follow-strategy-detail {
  margin: 12px 0 0;
  color: #68766e;
  font-size: 12px;
}
@media (min-width: 681px) {
  .follow-strategy-query { padding-left: 85px; }
}
@media (max-width: 560px) {
  .follow-strategy-query-line:first-child {
    display: grid;
    grid-template-columns: auto 104px minmax(0, 1fr);
  }
  .follow-strategy-query-line:first-child > span:last-child { min-width: 0; }
  .follow-strategy-query-line:first-child > .follow-query-mobile-break {
    grid-column: 1 / -1;
    margin: 0;
  }
}
.follow-chart-card,
.follow-result-card {
  margin-top: 22px;
  border-radius: 20px;
  box-shadow: none;
}
.follow-chart-card { padding: 24px 18px 18px; }
.follow-chart-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.follow-chart-heading .card-kicker,
.follow-result-heading .card-kicker {
  color: #76837c;
  font-size: 12px;
  font-weight: 520;
  letter-spacing: .03em;
}
.follow-chart-heading h2,
.follow-result-heading h2,
.follow-result-card > .section-heading h2 { margin-top: 4px; font-size: 22px; }
.follow-chart-note { color: #78857e; font-size: 12px; white-space: nowrap; }
.follow-chart-legend {
  display: flex;
  gap: 18px;
  justify-content: flex-end;
  margin-top: 12px;
  color: #68766e;
  font-size: 12px;
}
.follow-chart-legend span::before {
  display: inline-block;
  width: 18px;
  height: 3px;
  margin-right: 6px;
  border-radius: 99px;
  vertical-align: middle;
  content: "";
}
.follow-chart-legend .strategy::before { background: var(--green); }
.follow-chart-legend .benchmark::before { background: #88958e; }
.follow-chart-card .chart-host { min-height: 262px; margin-top: 4px; }
.follow-chart-card .chart-host svg { height: auto; min-height: 262px; }
@media (max-width: 560px) {
  .follow-chart-card .chart-host,
  .follow-chart-card .chart-host svg { min-height: 390px; }
}
.follow-chart-grid line { stroke: #dce4df; stroke-width: 1; vector-effect: non-scaling-stroke; }
.follow-chart-grid text,
.follow-chart-date { fill: #7a867f; font-size: 10px; }
.follow-strategy-line,
.follow-benchmark-line { fill: none; vector-effect: non-scaling-stroke; }
.follow-strategy-line { stroke: var(--green); stroke-width: 3; }
.follow-benchmark-line { stroke: #8b9690; stroke-width: 2; }
.follow-result-card { padding: 24px; }
.follow-result-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.result-badge {
  flex: 0 0 auto;
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--positive);
  background: #fff0f1;
  font-size: 12px;
  font-weight: 650;
}
.follow-card-description { margin: 10px 0 0; color: #66736b; font-size: 13px; }
.signal-date { display: block; margin-top: 6px; color: #87928c; font-size: 11px; }
.follow-result-list { margin-top: 16px; border-top: 1px solid var(--line); }
.follow-result-list .signal-row {
  grid-template-columns: minmax(0, 1fr) auto;
  min-height: 64px;
  padding: 8px 0;
}
.follow-result-list .signal-row .rank { display: none; }
.follow-result-list .signal-row strong { font-size: 14px; }
.follow-result-list .signal-row > b { font-size: 14px; }
.follow-expand {
  width: 100%;
  min-height: 42px;
  margin-top: 12px;
  border: 0;
  border-radius: 10px;
  color: var(--ink);
  background: #f0f3f1;
  font-size: 13px;
  font-weight: 650;
}
.active-follow-shell > #follow-notices {
  margin-top: 20px;
  border: 0;
  color: #66736b;
  background: #f5f8f6;
  font-size: 12px;
}
.follow-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.follow-actions a,
.follow-actions button {
  display: grid;
  min-height: 46px;
  padding: 0 14px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  background: #fff;
  font-size: 13px;
  font-weight: 650;
  text-align: center;
  text-decoration: none;
}
.follow-actions button { border-color: var(--green); color: #fff; background: var(--green); }

@media (max-width: 680px) {
  .lab-content { padding: 30px 20px 34px; }
  .tool-choice-grid { grid-template-columns: 1fr; }
  .tool-choice-grid .tool-choice-card { min-height: 350px; }
  .active-follow-shell > .page-header,
  .active-follow-shell > section,
  .active-follow-shell > aside,
  .active-follow-shell > .follow-actions,
  .active-follow-shell > .tool-message { margin-right: 16px; margin-left: 16px; }
  .active-follow-shell .compact-header { margin-top: 28px; }
  .follow-setting-row { grid-template-columns: 1fr; }
  .follow-performance-card { padding: 18px 14px 16px; }
  .follow-performance-card .metric-grid > div { padding-inline: 6px; }
  .follow-performance-card .metric-grid b { font-size: 16px; }
  .follow-performance-card .metric-grid small { font-size: 11px; }
  .follow-chart-card { padding-inline: 10px; }
}

@media (max-width: 430px) {
  .lab-content { margin-inline: -12px; padding-inline: 16px; }
  .tool-choice-grid .tool-choice-card { min-height: 330px; padding: 22px; }
  .active-follow-shell .compact-header h1 { font-size: 27px; }
  .active-follow-shell .compact-header > p { font-size: 14px; }
  .follow-performance-card .metric-grid span { font-size: 10px; }
  .follow-settings { padding: 20px 16px; border-radius: 18px; }
  .follow-strategy-query { font-size: 13px; line-height: 1.55; }
  .follow-strategy-query-line { gap: 8px; }
  .follow-strategy-query-line + .follow-strategy-query-line { margin-top: 8px; }
  .follow-strategy-query select { height: 40px; min-width: 92px; padding-right: 32px; font-size: 13px; }
  #follow-momentum { min-width: 104px; }
  #follow-frequency { min-width: 96px; }
  #follow-weighting { min-width: 184px; }
  .follow-chart-note { font-size: 10px; }
  .follow-result-card { padding: 20px 16px; }
  .follow-actions { grid-template-columns: 1fr; }
}

/* ETF 타임머신 */
.time-machine-shell {
  width: min(100%, 920px);
  max-width: 920px;
  padding-bottom: 0;
  background: #f7f9f8;
}
.time-machine-shell .site-header { margin-bottom: 0; }
.time-machine-content {
  width: min(100%, 730px);
  margin: 0 auto;
  padding: 30px 20px 42px;
}
.time-machine-header { margin: 0; }
.time-machine-header .eyebrow {
  margin-bottom: 7px;
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .02em;
}
.time-machine-header h1 {
  font-size: clamp(28px, 5vw, 32px);
  font-weight: 680;
  line-height: 1.22;
}
.time-machine-header > p:last-child {
  margin-top: 10px;
  color: #68736c;
  font-size: 15px;
  line-height: 1.6;
}
.time-machine-shell .result-tabs {
  gap: 5px;
  margin-top: 22px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f0f3f1;
}
.time-machine-shell .result-tabs button {
  min-height: 44px;
  border-radius: 10px;
  font-weight: 620;
}
.time-machine-shell .result-tabs button.is-active {
  background: var(--green);
  box-shadow: 0 5px 14px rgba(0, 184, 107, .16);
}
.time-machine-shell [data-tool-view] > :first-child { margin-top: 14px; }
.time-machine-shell .time-panel,
.time-machine-shell .time-chart-card,
.time-machine-shell .time-result-card,
.time-machine-shell .time-future-summary {
  margin-top: 14px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: none;
}
.time-panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.time-panel-heading h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 660;
  line-height: 1.4;
  letter-spacing: -.03em;
}
.time-panel-heading p {
  margin: 5px 0 0;
  color: #68736c;
  font-size: 14px;
  font-weight: 430;
  line-height: 1.5;
}
.time-badge,
.time-chart-badge {
  flex: 0 0 auto;
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--green-dark);
  background: var(--green-soft);
  font-size: 12px;
  font-weight: 650;
}
.etf-search {
  position: relative;
  z-index: 4;
  margin-top: 17px;
}
.etf-search-control {
  position: relative;
  display: flex;
  min-height: 50px;
  align-items: center;
  border: 2px solid var(--green);
  border-radius: 13px;
  background: #fff;
}
.etf-search-control:focus-within { box-shadow: 0 0 0 3px rgba(0, 184, 107, .12); }
.etf-search-icon {
  position: absolute;
  left: 17px;
  width: 15px;
  height: 15px;
  border: 2px solid var(--green-dark);
  border-radius: 50%;
  pointer-events: none;
}
.etf-search-icon::after {
  position: absolute;
  right: -5px;
  bottom: -3px;
  width: 6px;
  height: 2px;
  border-radius: 99px;
  background: var(--green-dark);
  transform: rotate(45deg);
  content: "";
}
.etf-search-control input {
  width: 100%;
  min-width: 0;
  min-height: 46px;
  padding: 0 47px 0 46px;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
  font: inherit;
  font-size: 15px;
  font-weight: 540;
}
.etf-search-control input::placeholder { color: #8a948e; font-weight: 430; }
.etf-search-control input::-webkit-search-cancel-button { display: none; }
.etf-search-control button {
  position: absolute;
  right: 7px;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 9px;
  color: #77837c;
  background: transparent;
  font-size: 20px;
  cursor: pointer;
}
.etf-search-control button:hover { background: #f0f4f2; }
.etf-search-results {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  z-index: 20;
  max-height: 440px;
  overflow-y: auto;
  border: 1px solid #cfdad4;
  border-radius: 13px;
  background: #fff;
  box-shadow: 0 14px 32px rgba(31, 46, 38, .14);
}
.etf-search-results[hidden] { display: none; }
.etf-search-result-group + .etf-search-result-group { border-top: 7px solid #f4f7f5; }
.etf-search-result-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 34px;
  width: 100%;
  padding: 8px 15px 6px;
  border: 0;
  color: #6f7b74;
  background: #fafcfb;
  font: inherit;
  font-size: 12px;
  font-weight: 620;
  text-align: left;
}
button.etf-search-result-heading { cursor: pointer; }
button.etf-search-result-heading:hover,
button.etf-search-result-heading:focus-visible { color: var(--green-dark); background: #f0f8f4; }
.etf-search-back {
  width: 100%;
  min-height: 38px;
  padding: 8px 15px;
  border: 0;
  color: var(--green-dark);
  background: #f4f8f6;
  font: inherit;
  font-size: 12px;
  font-weight: 650;
  text-align: left;
  cursor: pointer;
}
.etf-search-back:hover,
.etf-search-back:focus-visible { background: #eaf5ef; }
.etf-search-result {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  width: 100%;
  min-height: 65px;
  padding: 10px 15px;
  align-items: center;
  border: 0;
  border-top: 1px solid #edf1ee;
  color: var(--ink);
  background: #fff;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.etf-search-result:hover,
.etf-search-result.is-active { background: #f0f8f4; }
.etf-search-result:disabled { cursor: default; opacity: .66; }
.etf-search-result-description { min-width: 0; }
.etf-search-result-description > strong {
  display: block;
  overflow: hidden;
  font-size: 14px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.etf-search-result-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin-top: 5px;
  color: #7b867f;
  font-size: 11px;
}
.etf-search-reason { color: var(--green-dark); }
.etf-search-reason + .etf-search-reason::before { margin-right: 8px; color: #b2bab5; content: "·"; }
.etf-search-result-action {
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 680;
  white-space: nowrap;
}
.etf-search-empty,
.etf-search-more {
  margin: 0;
  padding: 24px 15px;
  color: #748078;
  font-size: 13px;
  text-align: center;
}
.etf-search-more {
  width: 100%;
  padding: 10px 15px;
  border: 0;
  border-top: 1px solid #edf1ee;
  background: #fafcfb;
  font: inherit;
  font-size: 11px;
  cursor: pointer;
}
.etf-search-more:hover,
.etf-search-more:focus-visible { color: var(--green-dark); background: #f0f8f4; }
.time-machine-shell .picker-row {
  grid-template-columns: minmax(0, 1fr) 74px;
  margin-top: 17px;
}
.time-machine-shell .picker-row select,
.time-machine-shell .picker-row button {
  min-height: 48px;
  border-radius: 12px;
}
.time-machine-shell .picker-row button { border-color: #b9dfcc; }
.portfolio-list-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 78px 34px;
  gap: 8px;
  margin-top: 18px;
  padding: 0 2px 7px;
  color: #68736c;
  font-size: 13px;
}
.portfolio-list-head span:nth-child(2) { text-align: center; }
.time-machine-shell .portfolio-rows { margin-top: 0; }
.time-machine-shell .portfolio-row {
  grid-template-columns: minmax(0, 1fr) 78px 34px;
  gap: 8px;
  min-height: 64px;
  border-color: var(--line);
}
.time-machine-shell .portfolio-name strong { font-size: 15px; font-weight: 620; }
.time-machine-shell .portfolio-name small { display: block; margin-top: 3px; color: #758078; }
.time-machine-shell .portfolio-row input {
  height: 42px;
  padding: 0 8px;
  border-radius: 10px;
  font-variant-numeric: tabular-nums;
}
.time-machine-shell .remove-etf { width: 34px; height: 42px; cursor: pointer; }
.time-machine-shell .allocation-summary {
  display: block;
  margin-top: 12px;
  padding: 14px;
  border-radius: 13px;
  background: var(--green-soft);
}
.time-machine-shell .allocation-summary > div:first-child {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  font-weight: 620;
}
.time-machine-shell .allocation-summary strong { color: var(--green-dark); font-size: 16px; }
.allocation-bar {
  height: 5px;
  margin-top: 10px;
  overflow: hidden;
  border-radius: 99px;
  background: #d4ebe0;
}
.allocation-bar i { display: block; width: 0; height: 100%; border-radius: inherit; background: var(--green); transition: width .18s ease; }
.allocation-summary.is-invalid strong { color: var(--positive); }
.allocation-summary.is-invalid .allocation-bar i { background: var(--positive); }
.time-microcopy { margin: 11px 2px 0; color: #68736c; font-size: 12px; line-height: 1.5; }
.time-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}
.time-fields-capital .field:first-child { grid-column: 1 / -1; }
.time-machine-shell .field {
  display: block;
  margin: 0;
  color: #68736c;
  font-size: 14px;
  font-weight: 570;
}
.time-machine-shell .field > span:first-child { display: block; margin-bottom: 8px; }
.time-machine-shell .field input,
.time-machine-shell .field select {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 570;
}
.money-control { position: relative; display: block; }
.money-control input { padding-right: 38px !important; text-align: right; font-variant-numeric: tabular-nums; }
.money-control input:disabled { color: #99a19c; background: #f2f4f3; cursor: not-allowed; }
.money-control b {
  position: absolute;
  top: 50%;
  right: 14px;
  transform: translateY(-50%);
  color: #68736c;
  font-size: 13px;
  font-weight: 500;
}
.rebalance-layout {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  align-items: end;
  gap: 20px;
  margin-top: 18px;
}
.rebalance-layout p {
  margin: 0;
  padding: 14px;
  border-radius: 13px;
  color: #68736c;
  background: #f3f5f4;
  font-size: 13px;
  line-height: 1.55;
}
.time-machine-shell .field-help { margin: 10px 2px 0; font-weight: 430; }
.selected-etf-start-dates {
  display: grid;
  gap: 3px;
  margin: 6px 2px 0;
  color: #7a857e;
  font-size: 12px;
  font-weight: 430;
  line-height: 1.55;
}
.selected-etf-start-dates[hidden] { display: none; }
.selected-etf-start-dates p { margin: 0; overflow-wrap: anywhere; }
.condition-summary {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 13px;
  background: var(--green-soft);
  font-size: 13px;
  line-height: 1.55;
}
.condition-summary strong { flex: 0 0 auto; color: var(--green-dark); }
.condition-summary span { color: #68736c; }
.time-info-note,
.time-warning {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 12px;
  padding: 14px;
  border-radius: 13px;
  color: #68736c;
  background: #f0f3f1;
  font-size: 13px;
  line-height: 1.55;
}
.time-info-note i,
.time-warning i {
  flex: 0 0 21px;
  height: 21px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--green-dark);
  background: var(--green-soft);
  font-style: normal;
  font-weight: 700;
}
.time-warning { background: #fff9f1; }
.time-warning i { color: #946000; background: #fff0d9; }
.time-warning strong,
.time-warning span { display: block; }
.time-warning strong { margin-bottom: 2px; color: var(--ink); }
.time-warning .time-loss-warning {
  margin-top: 5px;
  color: var(--positive);
  font-size: 14px;
  font-weight: 650;
}
.time-machine-shell .primary-action,
.time-machine-shell .secondary-action {
  min-height: 54px;
  border-radius: 13px;
  font-size: 16px;
  font-weight: 680;
}
.time-machine-shell .primary-action { background: var(--green); box-shadow: 0 9px 20px rgba(0, 184, 107, .16); }
.time-machine-shell .action-button { margin-top: 18px; }
.time-result-card {
  padding: 26px 22px !important;
  border-color: #cdebdc !important;
  background: linear-gradient(180deg, #f5fcf8 0%, #eaf8f1 100%) !important;
  text-align: center;
}
.time-result-card h2 {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 5px;
  max-width: 560px;
  margin: 0 auto;
  font-size: clamp(25px, 4.5vw, 30px);
  font-weight: 660;
  line-height: 1.35;
  letter-spacing: -.045em;
}
.time-result-card h2 .past-value-copy {
  color: var(--ink);
  font-size: .8em;
  font-weight: 540;
  letter-spacing: -.025em;
  white-space: nowrap;
}
.time-result-card h2 strong { color: var(--positive); font-weight: 760; }
.time-result-card > p { margin: 9px 0 0; color: var(--positive); font-size: 16px; font-weight: 650; }
.time-result-card .metric-grid {
  gap: 9px;
  margin-top: 22px;
  padding-top: 18px;
  border-color: #cfe4d9;
  text-align: left;
}
.time-result-card .metric-grid > div {
  padding: 13px 14px;
  border: 0;
  border-radius: 13px;
  background: rgba(255, 255, 255, .82);
}
.time-result-card .metric-grid small { color: #68736c; font-size: 13px; }
.time-result-card .metric-grid b { margin-top: 7px; font-size: 18px; white-space: nowrap; }
.time-result-card .metric-grid .risk b { color: var(--negative); }
.time-chart-card .data-status { margin-top: 12px; }
.time-chart-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 13px;
  margin-top: 14px;
  color: #68736c;
  font-size: 13px;
}
.time-chart-legend span { display: flex; align-items: center; gap: 6px; }
.time-chart-legend i { width: 17px; height: 3px; border-radius: 99px; background: #3f4b45; }
.time-chart-legend i.value { background: var(--green); }
.time-chart-legend i.example { background: #174f3d; }
.time-chart-legend i.range { height: 10px; background: #dcece4; }
.time-chart-legend i.deposit { height: 2px; background: repeating-linear-gradient(90deg, #98a19c 0 4px, transparent 4px 7px); }
.time-chart-card .chart-host {
  min-height: 0;
  margin-top: 10px;
  padding: 10px 8px 4px;
  border-radius: 14px;
  background: #f3f5f4;
}
.time-chart-card .chart-host svg { width: 100%; height: auto; min-height: 0; }
.time-component-results { margin-top: 14px; }
.time-machine-shell .component-row { min-height: 70px; padding: 12px 0; border-color: var(--line); }
.time-machine-shell .component-row strong { font-size: 14px; font-weight: 620; }
.time-machine-shell .component-row small { color: #68736c; }
.time-machine-shell .component-row b { color: var(--positive); font-size: 15px; text-align: right; }
.time-machine-shell .component-row b.negative-value { color: var(--negative); }
.time-actions { display: grid; gap: 9px; margin-top: 18px; }
.time-actions .action-button,
.time-actions .secondary-action { margin-top: 0; }
.time-future-summary {
  padding: 26px 22px !important;
  border-color: #cdebdc !important;
  background: linear-gradient(180deg, #f5fcf8 0%, #eaf8f1 100%) !important;
  text-align: center;
}
.time-future-summary > span { color: var(--green-dark); font-size: 13px; font-weight: 680; }
.time-future-summary h2 {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 4px;
  margin: 10px auto 0;
  font-size: clamp(12px, 2.4vw, 16px);
  font-weight: 430;
  line-height: 1.35;
  letter-spacing: -.025em;
  white-space: nowrap;
}
.time-future-summary h2 strong { color: var(--ink); font-size: clamp(15px, 3.5vw, 25px); font-weight: 760; letter-spacing: -.045em; }
.time-future-summary > p { margin: 12px 0 0; color: #68736c; font-size: 13px; }
.time-future-summary > p strong { color: var(--ink); }
.future-range-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
  margin-top: 14px;
}
.future-range-list > div { padding: 15px 14px; border-radius: 13px; background: #f3f5f4; }
.future-range-list small { display: block; color: #68736c; font-size: 13px; }
.future-range-list b { display: block; margin-top: 7px; font-size: 17px; white-space: nowrap; }
.future-range-list .middle { background: #edf1ef; }
.time-future-return { margin-top: 18px; }

@media (max-width: 700px) {
  .time-machine-shell { width: 100%; }
  .time-machine-content { padding: 26px 15px 34px; }
}

@media (max-width: 520px) {
  .time-machine-header h1 { font-size: 28px; }
  .time-machine-header > p:last-child { font-size: 14px; }
  .time-machine-shell .result-tabs button { padding-inline: 4px; font-size: 13px; }
  .time-machine-shell .time-panel,
  .time-machine-shell .time-chart-card,
  .time-machine-shell .time-result-card,
  .time-machine-shell .time-future-summary { padding: 19px 15px !important; }
  .time-machine-shell .time-future-summary { padding-inline: 8px !important; }
  .time-future-summary h2 { gap: 3px; font-size: 12px; }
  .time-future-summary h2 strong { font-size: clamp(14px, 4vw, 17px); }
  .etf-search-control input { padding-left: 42px; font-size: 16px; }
  .etf-search-icon { left: 15px; }
  .etf-search-results { max-height: 390px; }
  .etf-search-result { min-height: 66px; padding-inline: 12px; }
  .etf-search-result-action { display: none; }
  .etf-search-result-description > strong { font-size: 13px; }
  .time-fields { grid-template-columns: 1fr; }
  .time-fields-capital .field:first-child { grid-column: auto; }
  .selected-etf-start-dates { gap: 4px; font-size: 12px; }
  .rebalance-layout { grid-template-columns: 1fr; gap: 12px; }
  .portfolio-list-head,
  .time-machine-shell .portfolio-row { grid-template-columns: minmax(0, 1fr) 68px 30px; }
  .time-machine-shell .portfolio-name strong { font-size: 13px; }
  .condition-summary { display: grid; gap: 3px; }
  .time-result-card .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .time-result-card .metric-grid .risk { grid-column: 1 / -1; }
  .time-result-card .metric-grid b { font-size: 16px; }
  .time-chart-badge { display: none; }
  .time-chart-legend { justify-content: flex-start; }
  .future-range-list { grid-template-columns: 1fr; gap: 7px; }
  .future-range-list > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px; }
  .future-range-list b { margin-top: 0; font-size: 16px; }
}
