/* Real Rate — a serious data tool, not a landing page.
   The accent is reserved for the answer and for things you can click. Using it
   everywhere is what made the page hard to read. */

:root {
  --bg: #f7f7f6;
  --bg-raised: #ffffff;
  --bg-input: #ffffff;
  --border: #e2e2df;
  --border-strong: #c4c4bf;
  --text: #14161a;
  --text-muted: #4b5159;
  --text-dim: #6c727c;
  --accent: #b45309;
  --accent-dim: #d9a15f;
  --accent-wash: #fdf6ec;
  --domestic: #1f6feb;
  --dollar-linked: #c2410c;
  --good: #14804a;
  --accent-on: #ffffff;
  --radius: 10px;
  --radius-sm: 6px;
  --maxw: 940px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial,
    sans-serif;
  --mono: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c0e12;
    --bg-raised: #15181e;
    --bg-input: #101319;
    --border: #262a33;
    --border-strong: #3a404c;
    --text: #f4f6f8;
    --text-muted: #aab2bf;
    --text-dim: #838b98;
    --accent: #fbbf24;
    --accent-dim: #8a6a1c;
    --accent-wash: #1b1a13;
    --domestic: #58a6ff;
    --dollar-linked: #ff8a5b;
    --good: #3fb950;
    --accent-on: #0c0e12;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  line-height: 1.15;
  margin: 0;
  font-weight: 650;
  letter-spacing: -0.02em;
}

a {
  color: var(--accent);
  text-underline-offset: 3px;
}

em {
  font-style: normal;
  color: var(--accent);
}

/* ---------------------------------------------------------------- chrome */

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 20px 20px 8px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}

.wordmark-mark {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--bg);
  background: var(--accent);
  padding: 3px 7px;
  border-radius: var(--radius-sm);
}

.wordmark-text {
  font-weight: 650;
  letter-spacing: -0.01em;
}

.site-header nav a {
  font-size: 14px;
  color: var(--text-muted);
  text-decoration: none;
}
.site-header nav a:hover {
  color: var(--text);
}

.site-footer {
  max-width: var(--maxw);
  margin: 64px auto 0;
  padding: 24px 20px 48px;
  border-top: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 13px;
}
.site-footer p {
  margin: 4px 0;
}

main {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}

/* ---------------------------------------------------------------- primitives */

.card {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
}

.card-sub {
  color: var(--text-muted);
  font-size: 14px;
  margin: 0;
  max-width: 68ch;
}

label,
.label,
legend {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 7px;
}

input[type='text'],
select {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--text);
  font: inherit;
  padding: 10px 12px;
}

select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-muted) 50%),
    linear-gradient(135deg, var(--text-muted) 50%, transparent 50%);
  background-position: calc(100% - 17px) calc(50% + 1px), calc(100% - 12px) calc(50% + 1px);
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 34px;
}

input:focus-visible,
select:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.input-group {
  display: flex;
  align-items: stretch;
  background: var(--bg-input);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.input-prefix {
  display: flex;
  align-items: center;
  padding: 0 4px 0 12px;
  color: var(--text-muted);
  font-weight: 600;
}

input[type='range'] {
  width: 100%;
  accent-color: var(--accent);
  cursor: pointer;
}

.btn {
  font: inherit;
  font-weight: 600;
  border-radius: var(--radius-sm);
  padding: 11px 20px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: filter 0.15s, border-color 0.15s;
}
.btn-primary {
  background: var(--accent);
  color: var(--accent-on);
}
.btn-primary:hover {
  filter: brightness(1.08);
}
.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border-strong);
}
.btn-ghost:hover {
  border-color: var(--text-dim);
}
.btn-tiny {
  padding: 6px 12px;
  font-size: 12.5px;
  background: transparent;
  color: var(--text-muted);
  border-color: var(--border-strong);
}
.btn-tiny:hover {
  color: var(--text);
  border-color: var(--accent);
}
.btn-block {
  width: 100%;
}

.disclaimer {
  margin-top: 30px;
  font-size: 12.5px;
  color: var(--text-dim);
  max-width: 72ch;
}

.rate-strip {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 12px 0 0;
  font-size: 11.5px;
  color: var(--text-dim);
  line-height: 1.35;
}
.rate-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--good);
  flex: none;
}
.rate-strip.is-fallback .rate-dot {
  background: var(--accent);
}

/* ---------------------------------------------------------------- answer */

.answer-block {
  padding: 26px 0 22px;
}

.sentence {
  font-size: clamp(19px, 3.1vw, 26px);
  font-weight: 550;
  letter-spacing: -0.015em;
  line-height: 1.6;
  margin: 0 0 4px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  color: var(--text-muted);
}
.sentence-part {
  white-space: nowrap;
}

.inline-input {
  display: inline-flex;
  background: var(--bg-input);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 1px 6px 1px 10px;
  align-items: center;
}
.inline-input:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-color: var(--accent);
}
.inline-input .input-prefix {
  padding: 0 2px 0 0;
  color: var(--text-muted);
  font-weight: 600;
}
.inline-input input {
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  padding: 3px 0;
  min-width: 4ch;
}
.inline-input input:focus-visible {
  outline: none;
}

.sentence select,
.answer-where select {
  display: inline-block;
  width: auto;
  font: inherit;
  font-weight: 650;
  color: var(--text);
  background-color: transparent;
  border: 0;
  border-bottom: 2px dotted var(--border-strong);
  border-radius: 0;
  padding: 2px 22px 2px 2px;
  background-position: calc(100% - 8px) calc(50% + 1px), calc(100% - 3px) calc(50% + 1px);
  cursor: pointer;
}
.sentence select:hover,
.answer-where select:hover {
  border-bottom-color: var(--accent);
}

.swap {
  background: var(--bg-input);
  border: 1px solid var(--border-strong);
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  font-size: 16px;
  line-height: 1;
  padding: 6px 9px;
  cursor: pointer;
}
.swap:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.answer-number {
  font-size: clamp(44px, 11vw, 82px);
  font-weight: 720;
  letter-spacing: -0.04em;
  line-height: 1.02;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  margin: 6px 0 0;
}
.answer-where {
  font-size: clamp(19px, 3.1vw, 26px);
  font-weight: 550;
  color: var(--text-muted);
  margin: 2px 0 0;
}
.answer-note {
  font-size: 14.5px;
  color: var(--text-muted);
  margin: 16px 0 0;
  max-width: 60ch;
  line-height: 1.5;
}
.answer-note strong {
  color: var(--text);
  font-weight: 650;
}

.compare-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}
.compare-item {
  flex: 1 1 200px;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
}
.compare-label {
  display: block;
  font-size: 12px;
  color: var(--text-dim);
  margin-bottom: 3px;
}
.compare-value {
  display: block;
  font-size: 18px;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

/* The single most important control on the page: without it the answer is just
   an assertion. It has to read as an invitation, not as fine print. */
.assumption-card {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  text-align: left;
  margin-top: 24px;
  padding: 15px 18px;
  font: inherit;
  color: var(--text);
  cursor: pointer;
  background: var(--bg-raised);
  border: 1px solid var(--border-strong);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.assumption-card:hover {
  border-color: var(--accent);
  box-shadow: 0 1px 6px rgb(0 0 0 / 8%);
}

.assumption-icon {
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-on);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
}

.assumption-body {
  flex: 1 1 auto;
  min-width: 0;
}
.assumption-head {
  display: block;
  font-size: 14.5px;
  font-weight: 650;
  letter-spacing: -0.01em;
}
.assumption-summary {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 3px;
}
.assumption-summary strong {
  color: var(--text);
  font-weight: 600;
}

.assumption-action {
  flex: none;
  font-size: 13.5px;
  font-weight: 650;
  color: var(--accent);
  white-space: nowrap;
}

@media (max-width: 560px) {
  .assumption-card {
    flex-wrap: wrap;
    gap: 10px 12px;
  }
  .assumption-body {
    flex: 1 1 200px;
  }
  .assumption-action {
    width: 100%;
    text-align: right;
  }
}

/* ---------------------------------------------------------------- takeaway */

.takeaway {
  margin-top: 20px;
  padding: 16px 18px;
  background: var(--accent-wash);
  border: 1px solid var(--accent-dim);
  border-radius: var(--radius);
}
.takeaway-line {
  margin: 0;
  font-size: clamp(18px, 2.7vw, 23px);
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--text);
}
.takeaway-line strong {
  color: var(--accent);
  font-weight: 720;
}
.takeaway-sub {
  margin: 6px 0 0;
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.5;
  max-width: 62ch;
}

/* ---------------------------------------------------------------- minibar */

.minibar[hidden] {
  display: none;
}
.minibar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 10px;
  padding: 10px 20px;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.minibar-label {
  color: var(--text-dim);
}
.minibar-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

/* ---------------------------------------------------------------- panel */

.panel {
  background: var(--bg-raised);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 14px;
}
.panel[hidden] {
  display: none;
}
.panel-intro {
  margin: 0 0 16px;
  font-size: 14px;
  color: var(--text-muted);
}

.questions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.question {
  border: 1px solid var(--border);
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 15px 16px 16px;
  margin: 0;
}
.question legend {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0;
  margin-bottom: 2px;
  font-size: 15.5px;
  font-weight: 650;
  letter-spacing: -0.01em;
}
.question-number {
  flex: none;
  width: 21px;
  height: 21px;
  border-radius: 50%;
  background: var(--bg-input);
  border: 1px solid var(--border-strong);
  color: var(--text-dim);
  font-size: 11.5px;
  font-weight: 650;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.question-hint {
  font-size: 12.5px;
  color: var(--text-dim);
  margin: 4px 0 11px 30px;
}
@media (max-width: 520px) {
  .question-hint {
    margin-left: 0;
  }
}

/* auto-fill, not auto-fit: a lone item on the last row keeps its column width
   instead of stretching across the whole row and looking like a mistake. */
.options {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
  gap: 7px;
}
@media (max-width: 420px) {
  .options {
    grid-template-columns: 1fr 1fr;
    gap: 6px;
  }
}

.option {
  text-align: left;
  background: var(--bg-input);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 8px 11px;
  cursor: pointer;
  color: var(--text);
  font: inherit;
  transition: border-color 0.12s, background 0.12s;
}
.option:hover {
  border-color: var(--accent-dim);
}
.option.is-selected {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 12%, var(--bg-input));
}
.option-label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.25;
}
.option.is-selected .option-label {
  color: var(--accent);
}
.option-detail {
  display: block;
  font-size: 11.5px;
  color: var(--text-dim);
  margin-top: 1px;
}

/* ---------------------------------------------------------------- drawers */

.drawer {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-raised);
  margin-bottom: 10px;
}
.drawer summary {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 15px 18px;
  cursor: pointer;
  list-style: none;
}
.drawer summary::-webkit-details-marker {
  display: none;
}
.drawer summary::after {
  content: '+';
  color: var(--text-dim);
  font-size: 18px;
  line-height: 1;
  order: 3;
}
.drawer[open] summary::after {
  content: '−';
}
.drawer-title {
  font-weight: 650;
  font-size: 15.5px;
  flex: 1 1 auto;
}
.drawer-hint {
  font-size: 12.5px;
  color: var(--text-dim);
  font-variant-numeric: tabular-nums;
}

/* Narrow screens: title and marker on one row, hint beneath. Otherwise a long
   hint pushes the +/− onto its own line and the drawers stop lining up. */
@media (max-width: 660px) {
  .drawer summary {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 2px 12px;
    align-items: baseline;
  }
  .drawer-title {
    grid-column: 1;
  }
  .drawer summary::after {
    grid-column: 2;
    grid-row: 1;
  }
  .drawer-hint {
    grid-column: 1;
    grid-row: 2;
  }
}
.drawer-body {
  padding: 0 18px 20px;
}
.drawer-body .card-sub {
  margin-bottom: 16px;
}

/* ---------------------------------------------------------------- tax */

.tax-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 560px) {
  .tax-columns {
    grid-template-columns: 1fr;
  }
}
.tax-col {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 15px 16px;
}
.tax-city {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-dim);
  font-weight: 650;
  margin: 0 0 9px;
}
.tax-gross {
  font-size: 21px;
  font-weight: 680;
  margin: 0;
  font-variant-numeric: tabular-nums;
}
.tax-gross span,
.tax-net span {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-dim);
  letter-spacing: 0;
}
.tax-lines {
  list-style: none;
  padding: 0;
  margin: 10px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
/* India shows two or three deduction lines, the US three. Reserve the taller
   case so take-home and savings line up across the two columns. */
.tax-lines:first-of-type {
  min-height: 84px;
}
@media (max-width: 560px) {
  .tax-lines:first-of-type {
    min-height: 0;
  }
}
.tax-lines li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 12.5px;
  color: var(--text-muted);
  padding: 5px 0;
  font-variant-numeric: tabular-nums;
}
.tax-net {
  font-size: 21px;
  font-weight: 680;
  color: var(--good);
  margin: 0;
  font-variant-numeric: tabular-nums;
}
.tax-left {
  font-size: 21px;
  font-weight: 680;
  color: var(--accent);
  margin: 0;
  font-variant-numeric: tabular-nums;
}
.tax-left.is-short {
  color: var(--dollar-linked);
}
.tax-left span {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-dim);
}
.tax-net {
  font-size: 17px;
}

/* ---------------------------------------------------------------- share cta */

.share-cta {
  margin: 24px 0 8px;
  text-align: center;
}
.share-cta .btn {
  min-width: 220px;
}
.rate-strip {
  justify-content: center;
}

.checkbox {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 400;
  margin: 14px 0 0;
  cursor: pointer;
}
.checkbox input {
  accent-color: var(--accent);
  width: 15px;
  height: 15px;
}

.modal-sub {
  font-size: 13px;
  color: var(--text-dim);
  margin: 0 0 14px;
}

.brief {
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}
.brief h3 {
  font-size: 16px;
  margin-bottom: 8px;
}
.brief-text {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--text-muted);
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 260px;
  overflow-y: auto;
  margin: 0 0 12px;
  font-family: var(--font);
}

/* ---------------------------------------------------------------- breakdown */

.breakdown-rows {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.bd-row {
  display: grid;
  grid-template-columns: minmax(150px, 1.15fr) minmax(90px, 2fr) 138px;
  align-items: center;
  gap: 14px;
  padding: 8px 0;
}
.bd-name {
  font-size: 13.5px;
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  line-height: 1.3;
}
.bd-name span {
  min-width: 0;
}
.bd-track {
  background: var(--bg-input);
  border-radius: 3px;
  height: 20px;
  overflow: hidden;
}
.bd-fill {
  height: 100%;
  border-radius: 3px;
  background: var(--domestic);
  min-width: 2px;
  transition: width 0.2s ease-out;
}
.bd-fill.is-dollar {
  background: var(--dollar-linked);
}
.bd-figures {
  text-align: right;
  font-size: 12.5px;
  color: var(--text-dim);
  white-space: nowrap;
}
.bd-figures b {
  color: var(--text);
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}
.is-dollar-text {
  color: var(--dollar-linked);
  font-weight: 600;
}

.tag-assumed {
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 650;
  color: var(--text-dim);
  border: 1px solid var(--border-strong);
  padding: 0 5px;
  border-radius: 3px;
  cursor: help;
  flex: none;
}

.swatch {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 2px;
  background: var(--domestic);
  vertical-align: baseline;
}
.swatch.is-dollar {
  background: var(--dollar-linked);
}

/* ---------------------------------------------------------------- modal */

.modal[hidden] {
  display: none;
}
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgb(0 0 0 / 62%);
}
.modal-body {
  position: relative;
  max-width: 640px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}
.modal-body h2 {
  font-size: 20px;
  margin-bottom: 16px;
}
.modal-close {
  position: absolute;
  top: 12px;
  right: 14px;
  background: none;
  border: 0;
  color: var(--text-muted);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
}
.modal-close:hover {
  color: var(--text);
}
.share-note {
  font-size: 12.5px;
  color: var(--text-dim);
  margin: 14px 0 0;
}

.confidence-note {
  margin: 16px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  font-size: 12.5px;
  color: var(--text-muted);
}

@media (max-width: 620px) {
  .bd-row {
    grid-template-columns: 1fr;
    gap: 5px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
  }
  .bd-figures {
    text-align: left;
  }
}

/* ---------------------------------------------------------------- projection */

.projection-control {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.projection-control label {
  margin: 0;
  white-space: nowrap;
}
.projection-control input[type='range'] {
  flex: 1 1 190px;
  width: auto;
}
.projection-control output {
  font-family: var(--mono);
  font-weight: 650;
  min-width: 52px;
}

.projection-chart {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  align-items: end;
  min-height: 168px;
  padding-top: 8px;
}
.pj-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  min-width: 0;
}
.pj-bar {
  width: 100%;
  max-width: 62px;
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-dim) 100%);
  border-radius: 4px 4px 0 0;
  min-height: 4px;
  transition: height 0.2s ease-out;
}
.pj-bar.is-loss {
  background: linear-gradient(180deg, var(--dollar-linked) 0%, color-mix(in srgb, var(--dollar-linked) 45%, var(--bg)) 100%);
}
.pj-figure {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 650;
  text-align: center;
}
.pj-year {
  font-size: 11.5px;
  color: var(--text-dim);
}
.projection-summary {
  margin: 20px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--text-muted);
}
.projection-summary strong {
  color: var(--text);
}

/* ---------------------------------------------------------------- share */

.share-preview {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-raised);
  line-height: 0;
}
.share-preview canvas {
  width: 100%;
  height: auto;
  display: block;
}
.share-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
}
.share-url {
  margin: 14px 0 0;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--text-dim);
  word-break: break-all;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
}

.disclaimer {
  margin-top: 30px;
  font-size: 12.5px;
  color: var(--text-dim);
  max-width: 72ch;
}

/* ---------------------------------------------------------------- methodology */

.doc {
  max-width: 760px;
  margin: 0 auto;
  padding: 8px 20px 40px;
}
.doc h1 {
  font-size: clamp(30px, 5vw, 42px);
  margin-bottom: 16px;
}
.doc h2 {
  font-size: 23px;
  margin: 44px 0 14px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}
.doc h3 {
  font-size: 16px;
  margin: 26px 0 8px;
}
.doc p,
.doc li {
  color: var(--text-muted);
  font-size: 15.5px;
}
.doc li {
  margin-bottom: 7px;
}
.doc strong {
  color: var(--text);
}
.doc code {
  font-family: var(--mono);
  font-size: 13.5px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1px 5px;
  color: var(--text);
}
.doc pre {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px;
  overflow-x: auto;
  font-size: 13px;
}
.doc pre code {
  border: 0;
  background: none;
  padding: 0;
}

.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin: 18px 0;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 13.5px;
  min-width: 560px;
}
th,
td {
  text-align: left;
  padding: 10px 13px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
th {
  background: var(--bg-input);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  white-space: nowrap;
}
tr:last-child td {
  border-bottom: 0;
}
td.num {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
td small {
  display: block;
  color: var(--text-dim);
  font-size: 12px;
  margin-top: 3px;
}
td a {
  font-size: 12.5px;
}

.pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 1px 7px;
  border-radius: 3px;
  border: 1px solid;
}
.pill-high {
  color: var(--good);
  border-color: color-mix(in srgb, var(--good) 40%, transparent);
}
.pill-medium {
  color: var(--text-muted);
  border-color: var(--border-strong);
}
.pill-low {
  color: var(--accent);
  border-color: var(--accent-dim);
}
.pill-seed {
  color: var(--accent);
  border-color: var(--accent-dim);
}

.callout {
  border: 1px solid var(--accent-dim);
  background: color-mix(in srgb, var(--accent) 7%, transparent);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  margin: 22px 0;
}
.callout p {
  margin: 0 0 8px;
  color: var(--text);
  font-size: 14.5px;
}
.callout p:last-child {
  margin-bottom: 0;
}
.callout strong {
  color: var(--accent);
}

/* ---------------------------------------------------------------- doc page */

.summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin: 26px 0;
}
.summary-item {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
}
.summary-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-on);
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 8px;
}
.summary-item p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.5;
}

.doc-drawer {
  margin: 14px 0;
}
.doc-drawer > summary {
  padding: 14px 18px;
}
.doc-drawer .drawer-body > *:first-child {
  margin-top: 0;
}
.doc-drawer h3 {
  margin-top: 22px;
}
.doc-drawer .table-scroll {
  margin: 14px 0;
}
