/* Firm Name site. Values come from the Figma file "Wealth advisor site - draft":
   phone frames are 390 wide, desktop frames 1440 wide with a 1200px column.
   Below 1080px the phone layout is used, centred at up to 720px wide. */

:root {
  --page: #f6f4ee;
  --alt: #eeebe3;
  --card: #fcfbf7;
  --ink: #131715;
  --muted: #5a645f;
  --accent: #1d5b70;
  --accent-deep: #123f4f;
  --accent-tint: #e2ecee;
  --line: rgba(19, 23, 21, 0.1);
  --serif: "Fraunces", Georgia, serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --body: 16px;
  --section-y: 56px;
  --section-gap: 28px;
}

@media (min-width: 1080px) {
  :root {
    --body: 17px;
    --section-y: 88px;
    --section-gap: 40px;
  }
}

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

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

body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.menu-open { overflow: hidden; }

h1, h2, h3, h4, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
svg { display: block; flex: none; }
button, input, select, textarea { font: inherit; color: inherit; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.wrap {
  width: min(720px, 100% - 32px);
  margin-inline: auto;
}

@media (min-width: 1080px) {
  .wrap { width: min(1200px, 100% - 80px); }
}

/* Type */

.eyebrow {
  font: 700 12px/1.6 var(--sans);
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--accent);
}

.h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 40px;
  line-height: 1.08;
  letter-spacing: -1px;
}

.h1--page {
  line-height: 1.1;
  letter-spacing: -1.5px;
}

.h1-accent {
  display: block;
  color: var(--accent);
}

.h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 30px;
  line-height: 1.1;
  letter-spacing: -0.8px;
}

@media (min-width: 1080px) {
  .h1 { font-size: 64px; letter-spacing: -1.8px; }
  .h1--page { letter-spacing: -1.5px; }
  .h2 { font-size: 44px; }
}

.card-title {
  font: 600 26px/1.23 var(--serif);
}

.muted { color: var(--muted); }

.small {
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border: 1px solid transparent;
  border-radius: 100px;
  font: 700 14px/1.35 var(--sans);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s;
}

.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-deep);
  border-color: var(--accent-deep);
}

.btn-secondary {
  background: var(--card);
  border-color: var(--line);
  color: var(--ink);
}

.btn-secondary:hover { border-color: rgba(19, 23, 21, 0.3); }

.btn-block { width: 100%; }

/* Header */

.draft-bar {
  padding: 7px 16px;
  background: var(--ink);
  color: #fff;
  font-size: 13px;
  line-height: 18px;
  text-align: center;
}

.nav-bar {
  position: relative;
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 87px; /* 88 with the bottom border */
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  font: 700 13px/1 var(--sans);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.brand-name { font: 600 19px/1.2 var(--serif); }

.brand-tag {
  font: 700 10px/1.4 var(--sans);
  letter-spacing: 0.9px;
  color: var(--accent);
}

.nav { display: none; }

.nav-links a {
  font-size: 14px;
  line-height: 1.35;
  text-decoration: none;
}

.nav-links a:hover { text-decoration: underline; text-underline-offset: 4px; }

.menu-button {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 100px;
  background: transparent;
  cursor: pointer;
}

.menu-button .icon-close,
.menu-button[aria-expanded="true"] .icon-menu { display: none; }
.menu-button[aria-expanded="true"] .icon-close { display: block; }

/* Covers the rest of the screen below the header; site.js sets --menu-top on opening. */
.menu {
  position: fixed;
  top: var(--menu-top, 120px);
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 20;
  overflow-y: auto;
  padding: 16px 0 24px;
  background: var(--page);
}

.menu[hidden] { display: none; }

.menu .wrap {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.menu-links li { border-bottom: 1px solid var(--line); }

.menu-links a {
  display: flex;
  align-items: center;
  min-height: 64px;
  font: 600 20px/1.4 var(--sans);
  text-decoration: none;
}

.menu-cta { font-weight: 600; }

@media (min-width: 1080px) {
  .nav-inner { min-height: 95px; }
  .nav { display: flex; align-items: center; gap: 24px; }
  .nav-links { display: flex; gap: 24px; }
  .menu-button, .menu { display: none !important; }
}

/* Sections */

.section { padding-block: var(--section-y); }
.section--alt { background: var(--alt); }

.section > .wrap {
  display: flex;
  flex-direction: column;
  gap: var(--section-gap);
}

.intro {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* An inset shadow, not a border: Figma draws strokes inside the frame, so they take
   no room from the padding. */
.card {
  background: var(--card);
  border-radius: 18px;
  box-shadow: inset 0 0 0 1px var(--line);
}

/* Home: hero */

.hero { padding: 48px 0; }

.hero .wrap {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 800px;
}

.callout {
  padding: 4px 0 4px 17px;
  border-left: 3px solid var(--accent);
  color: var(--muted);
}

.callout strong { color: var(--ink); }

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.stats {
  display: grid;
  /* The phone frame's card widths; "30 min" may run into the third card's padding, as in Figma. */
  grid-template-columns: minmax(0, 104fr) minmax(0, 104fr) minmax(0, 134fr);
  gap: 8px;
  padding-top: 8px;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
}

.stat-value {
  font: 600 36px/1.22 var(--serif);
  letter-spacing: -1px;
  color: var(--accent);
  white-space: nowrap;
}

/* Below the phone frame's width, "30 min" would run out of its card. */
@media (max-width: 374px) {
  .stat-value { font-size: 26px; }
}

.stat-label {
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
}

@media (min-width: 1080px) {
  .hero { padding: 80px 0 64px; }
  .hero .wrap { gap: 36px; }
  .stats { grid-template-columns: repeat(3, 1fr); gap: 20px; padding-top: 12px; }
  .stat { padding: 24px; }
  .stat-label { font-size: 14px; }
}

/* Home: approach */

.approach {
  display: grid;
  gap: 32px;
}

.approach-item {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

@media (min-width: 1080px) {
  .approach { grid-template-columns: repeat(3, 1fr); gap: 48px; }
}

/* Home: services */

.service-grid {
  display: grid;
  gap: 20px;
}

.service {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 215px;
  padding: 24px;
}

.service-number {
  font: 600 30px/1.23 var(--serif);
  color: var(--accent);
}

.service-detail {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

@media (min-width: 1080px) {
  .service-grid { grid-template-columns: repeat(3, 1fr); }
  .service { min-height: 244px; padding: 28px; }
}

/* Home: process. Phone: a vertical track; desktop: five columns. */

.steps {
  display: flex;
  flex-direction: column;
}

.step {
  display: flex;
  gap: 20px;
}

.step-marker {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: none;
  width: 40px;
}

.step-number {
  display: grid;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font: 700 14px/1 var(--sans);
}

.step-line {
  flex: 1;
  width: 1px;
  background: var(--line);
}

.step:last-child .step-line { display: none; }

.step-detail {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 5px 0 32px;
}

.step:last-child .step-detail { padding-bottom: 0; }

.step-title { font: 600 24px/1.25 var(--serif); }

@media (min-width: 1080px) {
  .steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 24px; }
  .step { flex-direction: column; gap: 20px; }
  .step-marker { flex-direction: row; gap: 16px; width: auto; }
  .step-line { width: auto; height: 1px; }
  .step-detail { gap: 20px; padding: 0; }
}

/* Home: fees */

.fee-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 24px;
  color: var(--muted);
}

@media (min-width: 1080px) {
  .fee-card { padding: 36px; }
}

/* Home: about */

.profiles {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.profile {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.monogram {
  display: grid;
  place-items: center;
  flex: none;
  width: 72px;
  height: 72px;
  border-radius: 12px;
  background: var(--accent-tint);
  color: var(--accent);
  font: 600 30px/1 var(--serif);
}

.bio {
  display: flex;
  flex-direction: column;
  gap: 12px;
  color: var(--muted);
}

.bio-name {
  font: 600 24px/1.25 var(--serif);
  color: var(--ink);
}

.bio-block {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 8px 0;
}

.bio-block--list { gap: 6px; }

.bio-heading {
  font: 700 14px/19px var(--sans);
  color: var(--ink);
}

.bio-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 15px;
}

.bio-contact {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 8px;
}

.bio-contact a,
.contact-detail a { text-decoration: none; }

@media (min-width: 1080px) {
  .profiles { gap: 48px; }
  .profile { flex-direction: row; gap: 32px; }
  .monogram { width: 96px; height: 96px; border-radius: 18px; font-size: 36px; }
  .bio { flex: 1; gap: 16px; }
  .bio-name { font-size: 28px; }
  .bio-block { gap: 8px; padding: 0; }
  .bio-block--list { gap: 12px; }
  .bio-heading { font: 600 18px/22px var(--serif); }
  .bio-list { gap: 8px; font-size: 17px; }
  .bio-contact { gap: 12px; padding-top: 0; }
}

/* Home: FAQ */

.faq-list { border-bottom: 1px solid var(--line); }

/* Figma draws the dividers inside each 24px-padded row, so the padding gives up 1px to each line. */
.faq {
  padding: 23px 0 24px;
  border-top: 1px solid var(--line);
}

.faq:last-child { padding-bottom: 23px; }

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  font: 600 16px/1.5 var(--sans);
  list-style: none;
  cursor: pointer;
}

.faq summary::-webkit-details-marker { display: none; }

.faq .icon-minus,
.faq[open] .icon-plus { display: none; }
.faq[open] .icon-minus { display: block; }

.faq-answer {
  max-width: 900px;
  margin-top: 16px;
  color: var(--muted);
}

@media (min-width: 1080px) {
  .faq summary { font-size: 18px; }
}

/* Home: contact */

.contact-grid {
  display: grid;
  gap: 32px;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.contact-detail {
  display: flex;
  gap: 14px;
  color: var(--muted);
}

.form-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 24px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field label { font: 600 14px/1.5 var(--sans); }

.input {
  width: 100%;
  height: 48px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--card);
  font-size: 16px;
  line-height: 1.4;
}

textarea.input {
  height: 112px;
  resize: vertical;
}

select.input {
  padding-right: 40px;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' fill='none'%3E%3Cpath d='M3 5.5L8 10.5L13 5.5' stroke='%235A645F' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px;
}

.form-note {
  font-size: 14px;
  color: var(--muted);
}

@media (min-width: 1080px) {
  .contact-grid {
    grid-template-columns: minmax(0, 540fr) minmax(0, 580fr);
    justify-content: space-between;
    align-items: start;
    gap: 80px;
  }
  .form-card { padding: 32px; }
}

/* Footer */

.site-footer {
  padding: 48px 0 32px;
  background: var(--ink);
  color: var(--card);
}

.site-footer .wrap {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.footer-cols {
  display: flex;
  flex-direction: column;
  gap: 36px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.footer-brand .brand-tag { color: var(--accent-tint); }

.footer-nav ul {
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 14px;
  line-height: 1.35;
}

.footer-nav a,
.legal a {
  text-decoration: none;
}

.footer-nav a:hover,
.legal a:hover { text-decoration: underline; text-underline-offset: 3px; }

.legal {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 13px;
  line-height: 1.4;
}

.legal ul {
  display: flex;
  gap: 24px;
}

@media (min-width: 1080px) {
  .site-footer { padding-top: 64px; }
  .footer-cols { flex-direction: row; gap: 64px; }
  .footer-brand { width: 340px; }
  .footer-nav { width: 220px; }
}

/* Calculator and Insights page intros */

/* Only the paragraph is held to Figma's intro width: browsers set Fraunces a little
   wider than Figma, and the headings are meant to stay on one line on desktop. */
.page-intro {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.page-intro .muted { max-width: 880px; }
.page-intro--wide .muted { max-width: 920px; }

/* Calculator page */

.calc-workspace {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.calc-help {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.calc-help h2 { font: 600 26px/1.23 var(--serif); }

.help-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  color: var(--muted);
}

.help-list li {
  position: relative;
  padding-left: 16px;
}

.help-list li::before {
  content: "";
  position: absolute;
  top: calc(0.8em - 2px);
  left: 0;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent);
}

@media (min-width: 1080px) {
  .calc-help h2 { font-size: 30px; }
}

/* Finance calculator. Phone values first; the desktop frame's differences follow. */

.fin {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 16px;
}

.fin-main,
.fin-output {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.fin-inputs {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.fin-strong { font: 700 14px/1.35 var(--sans); }

.fin-solve {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.fin-fields {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.fin-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.fin-field[hidden] { display: none; }

.fin-field label,
.fin-label { font: 700 13px/18px var(--sans); }

.fin-input {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 48px;
  padding: 0 14px;
  border-radius: 12px;
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--line);
}

.fin-input:focus-within { box-shadow: inset 0 0 0 2px var(--accent); }

.fin-input input {
  flex: 1;
  min-width: 0;
  height: 100%;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font: 600 16px/1.5 var(--sans);
}

.fin-affix {
  color: var(--muted);
  font: 600 16px/1.5 var(--sans);
}

.fin-affix--end { margin-left: auto; }

/* Drop-down lists: the contact form's arrow on the calculator's white input boxes. */
.fin-select {
  width: 100%;
  height: 48px;
  padding: 0 40px 0 14px;
  border: 0;
  border-radius: 12px;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16' fill='none'%3E%3Cpath d='M3 5.5L8 10.5L13 5.5' stroke='%235A645F' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 12px center / 16px;
  box-shadow: inset 0 0 0 1px var(--line);
  color: var(--ink);
  font: 600 16px/1.5 var(--sans);
  appearance: none;
  cursor: pointer;
}

.fin-select:focus-visible {
  outline: 0;
  box-shadow: inset 0 0 0 2px var(--accent);
}

/* Settings and Schedule open and close like the FAQ. */
.fin-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  border-radius: 12px;
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--line);
  font: 700 16px/22px var(--sans);
  list-style: none;
  cursor: pointer;
}

.fin-toggle::-webkit-details-marker { display: none; }

.fin-toggle .icon-minus,
details[open] > .fin-toggle .icon-plus { display: none; }
details[open] > .fin-toggle .icon-minus { display: block; }

.fin-settings-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 12px;
}

.fin-field--setting { gap: 12px; }

.fin-field--setting .fin-input { background: var(--card); }

.fin-switch {
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: 22px;
  background: var(--alt);
}

.fin-switch button {
  flex: 1;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 18px;
  background: transparent;
  color: var(--muted);
  font: 600 13px/1.5 var(--sans);
  cursor: pointer;
}

.fin-switch button[aria-pressed="true"] {
  background: var(--accent);
  color: #fff;
}

.fin-actions {
  display: flex;
  gap: 12px;
}

.fin-actions .btn { flex: 1; }

.fin-actions .btn-secondary { background: #fff; }

.fin-results,
.fin-chart {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.fin-heading { font: 700 18px/25px var(--sans); }

.fin-answer {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border-radius: 12px;
  background: var(--accent-deep);
  color: #fff;
}

.fin-answer[hidden] { display: none; }

.fin-answer--rates { gap: 20px; }

.fin-answer-line {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.fin-answer-value {
  font: 600 26px/1.2 var(--serif);
  overflow-wrap: anywhere;
}

.fin-answer-note {
  color: var(--accent-tint);
  font-size: 13px;
  line-height: 1.5;
}

.fin-error { line-height: 1.6; }

.fin-totals {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0;
  font-size: 14px;
  line-height: 19px;
}

.fin-totals[hidden] { display: none; }

.fin-total {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.fin-total dt { color: var(--muted); }

.fin-total dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
}

.fin-chart[hidden] { display: none; }

.fin-chart-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  border-radius: 12px;
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--line);
}

.fin-legend {
  display: flex;
  flex-direction: column;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 18px;
}

.fin-legend li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.fin-legend line { stroke-width: 2; }

.fin-plot svg { overflow: visible; }

.fin-grid { stroke: var(--line); stroke-width: 1; }

.fin-zero { stroke: rgba(90, 100, 95, 0.6); stroke-width: 1; }

.fin-tick {
  fill: var(--muted);
  font: 600 9px var(--sans);
}

.fin-tick-y { dominant-baseline: middle; }

.fin-tick-x {
  text-anchor: middle;
  dominant-baseline: hanging;
}

.fin-line {
  fill: none;
  stroke-width: 2;
  stroke-linejoin: round;
}

.fin-line--balance { stroke: #1d5b70; }
.fin-line--paid { stroke: #d55e00; stroke-dasharray: 7 4; }

.fin-schedule[hidden] { display: none; }

/* On a phone the table scrolls sideways with the Period column held in place. */
.fin-table-wrap {
  margin-top: 12px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.fin-table {
  width: max-content;
  min-width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  line-height: 20px;
  white-space: nowrap;
}

.fin-table th,
.fin-table td {
  width: 144px;
  padding: 14px 0 13px 24px;
  border-bottom: 1px solid var(--line);
  text-align: right;
}

.fin-table th {
  padding-top: 11px;
  padding-bottom: 10px;
  color: var(--muted);
  font-weight: 700;
}

.fin-table th:nth-child(2),
.fin-table td:nth-child(2) {
  width: 128px;
  padding-left: 8px;
}

.fin-table th:first-child,
.fin-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  width: 64px;
  padding: 14px 8px 13px 0;
  background: var(--card);
  box-shadow: inset -1px 0 0 var(--line);
}

.fin-table th:first-child {
  padding-top: 11px;
  padding-bottom: 10px;
  text-align: left;
}

.fin-table tbody tr:last-child td { border-bottom: 0; }

.fin-table tfoot td {
  border-top: 1px solid var(--line);
  border-bottom: 0;
  font-weight: 700;
}

.fin-table .fin-year td {
  position: static;
  padding: 10px 12px;
  background: var(--accent-tint);
  box-shadow: none;
  color: var(--accent-deep);
  font-size: 12px;
  font-weight: 700;
  line-height: 18px;
  text-align: left;
}

.fin-year span {
  position: sticky;
  left: 12px;
}

@media (min-width: 1080px) {
  .fin { padding: 32px; }

  .fin-main {
    flex-direction: row;
    align-items: flex-start;
  }

  .fin-inputs {
    flex: none;
    width: 396px;
    gap: 20px;
  }

  .fin-output { flex: 1; min-width: 0; }

  .fin-solve { gap: 12px; }

  .fin-input,
  .fin-select { border-radius: 10px; }

  .fin-select { font-size: 15px; }

  .fin-input input { font-size: 15px; }

  .fin-affix { font-size: 15px; }

  .fin-affix--end { color: var(--ink); }

  .fin-results {
    gap: 16px;
    padding: 20px;
    border-radius: 12px;
    background: #fff;
    box-shadow: inset 0 0 0 1px var(--line);
  }

  .fin-answer-value { font-size: 34px; }

  .fin-answer--rates .fin-answer-value { font-size: 30px; }

  .fin-total dt { color: var(--ink); font-weight: 600; }

  .fin-chart {
    gap: 20px;
    padding: 24px;
    border-radius: 12px;
    background: #fff;
    box-shadow: inset 0 0 0 1px var(--line);
  }

  .fin-chart-card {
    gap: 20px;
    padding: 0;
    box-shadow: none;
  }

  .fin-legend {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px 24px;
    color: var(--ink);
    line-height: 24px;
  }

  .fin-legend line,
  .fin-line { stroke-width: 2.5; }

  .fin-tick { font-size: 11px; }

  .fin-schedule {
    padding: 24px;
    border-radius: 12px;
    background: #fff;
    box-shadow: inset 0 0 0 1px var(--line);
  }

  .fin-schedule > .fin-toggle {
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    font-size: 14px;
    line-height: 19px;
  }

  .fin-table-wrap {
    margin-top: 16px;
    overflow: visible;
  }

  .fin-table {
    width: 100%;
    table-layout: fixed;
    font-size: 14px;
    line-height: 19px;
  }

  .fin-table th,
  .fin-table td,
  .fin-table th:nth-child(2),
  .fin-table td:nth-child(2) {
    width: auto;
    padding: 12px 0 11px 16px;
  }

  .fin-table th,
  .fin-table th:nth-child(2) {
    padding-top: 0;
    padding-bottom: 11px;
    font-size: 12px;
    line-height: 16px;
  }

  .fin-table th:first-child,
  .fin-table td:first-child {
    position: static;
    width: 80px;
    padding: 12px 0 11px;
    background: none;
    box-shadow: none;
    text-align: right;
  }

  .fin-table th:first-child { padding: 0 0 11px; }

  .fin-table .fin-year td:first-child {
    padding: 10px 12px;
    background: var(--accent-tint);
    text-align: left;
  }
}

/* Insights */

.article-grid {
  display: grid;
  gap: 24px;
}

.article {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-height: 240px;
  padding: 28px;
}

.tag {
  align-self: flex-start;
  padding: 6px 12px;
  border-radius: 100px;
  background: var(--accent-tint);
  color: var(--accent);
  font: 600 12px/16px var(--sans);
}

.article-detail {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.article-title {
  font: 600 22px/1.25 var(--serif);
  letter-spacing: -0.3px;
}

@media (min-width: 1080px) {
  .article-grid { grid-template-columns: repeat(3, 1fr); }
  .article { min-height: 270px; }
}

/* Insights cards open their article: the title link stretches over the card. */
.article { position: relative; }

.article-link {
  color: inherit;
  text-decoration: none;
}

.article-link::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.article:hover .article-link { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.article:focus-within { box-shadow: inset 0 0 0 2px var(--accent); }
.article-link:focus-visible { outline: none; }

.article-more {
  margin-top: auto;
  color: var(--accent);
  font: 700 14px/1.35 var(--sans);
}

/* Insights article pages */

.post {
  display: flex;
  flex-direction: column;
  gap: var(--section-gap);
  max-width: 760px;
}

.back-link {
  align-self: flex-start;
  color: var(--accent);
  font: 700 14px/1.35 var(--sans);
  text-decoration: none;
}

.back-link:hover { text-decoration: underline; text-underline-offset: 3px; }

.post-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.post-body h2 {
  margin-top: 16px;
  font: 600 26px/1.23 var(--serif);
}

.post-body .help-list { color: inherit; }

.post-cta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  padding: 28px;
}

@media (min-width: 1080px) {
  .post-body h2 { font-size: 30px; }
}

/* Booking: Vishal's Google booking page inside the site. The popup keeps one size,
   like Calendly's popup: 80% x 90% of the window, at most 1000 x 700, centred; on
   screens under 975px it fills the width from 50px below the top. */

.bk-cal { overflow: hidden; border-radius: 12px; background: #fff; box-shadow: inset 0 0 0 1px var(--line); }
.bk-cal iframe { display: block; width: 100%; height: 700px; border: 0; }

.bk-dialog {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  overflow: hidden;
}
.bk-dialog::backdrop { background: rgba(31, 31, 31, 0.4); }

.bk-popup {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80%;
  min-width: 900px;
  max-width: 1000px;
  height: 90%;
  max-height: 700px;
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
}
.bk-popup .bk-cal { height: 100%; border-radius: 0; box-shadow: none; }
.bk-popup .bk-cal iframe { height: 100%; }

.bk-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 32px;
  line-height: 1;
  cursor: pointer;
}
body.bk-open { overflow: hidden; }

@media (max-width: 975px) {
  .bk-popup { position: fixed; top: 50px; right: 0; bottom: 0; left: 0; width: 100%; min-width: 0; height: auto; max-height: none; transform: none; border-radius: 12px 12px 0 0; }
  .bk-close { top: 7px; right: 10px; }
  .bk-cal iframe { height: 75vh; }
  .bk-popup .bk-cal iframe { height: 100%; }
}

/* Home: the "Book a call" button in the contact section keeps its own width. */
.contact-info > .btn { align-self: flex-start; }
