:root {
  color-scheme: light;
  --ink: #172b36;
  --ink-soft: #52656b;
  --paper: #faf9f5;
  --surface: #fffefa;
  --line: #deded4;
  --forest: #1e5146;
  --forest-dark: #153e35;
  --moss: #dce8d8;
  --clay: #bc633c;
  --sun: #f2c66d;
  --shadow: 0 20px 60px rgba(27, 51, 44, .09);
  --radius: 18px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); line-height: 1.6; }
a { color: var(--forest-dark); text-underline-offset: .2em; }
a:hover { color: var(--clay); }
button, input, select { font: inherit; }
button, a, input, select { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid var(--clay); outline-offset: 3px; }
.skip-link { position: absolute; left: -9999px; top: 1rem; z-index: 5; padding: .7rem 1rem; background: white; }
.skip-link:focus { left: 1rem; }
.shell { width: min(1160px, calc(100% - 40px)); margin-inline: auto; }
.site-header { border-bottom: 1px solid var(--line); background: rgba(250,249,245,.95); }
.nav-row { min-height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.brand { display: inline-flex; gap: .65rem; align-items: center; font-weight: 760; letter-spacing: -.03em; text-decoration: none; color: var(--ink); }
.brand-mark { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 11px; color: white; background: var(--forest); }
.brand-mark svg { width: 21px; height: 21px; }
.nav-links { display: flex; flex-wrap: wrap; gap: 1.55rem; align-items: center; }
.nav-links a { color: var(--ink-soft); text-decoration: none; font-size: .92rem; font-weight: 600; }
.nav-links a[aria-current="page"] { color: var(--forest); }
.nav-cta { color: white !important; padding: .65rem .95rem; border-radius: 999px; background: var(--forest); }
.nav-cta:hover { background: var(--forest-dark); color: white; }
main { min-height: 68vh; }
.hero { position: relative; overflow: hidden; padding: clamp(4rem, 9vw, 7.25rem) 0 5rem; }
.hero::after { content: ""; position: absolute; z-index: -1; right: -6rem; top: 2.7rem; width: min(40vw, 460px); aspect-ratio: 1; border: 1px solid #d9e1d4; border-radius: 47% 53% 54% 46%; box-shadow: 0 0 0 36px rgba(220,232,216,.33), 0 0 0 74px rgba(220,232,216,.17); transform: rotate(-15deg); }
.eyebrow { display: inline-flex; align-items: center; gap: .5rem; color: var(--forest); font-size: .77rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.eyebrow::before { content: ""; width: 21px; height: 2px; background: var(--clay); }
h1, h2, h3 { line-height: 1.12; letter-spacing: -.045em; }
h1 { max-width: 760px; margin: 1rem 0 1.2rem; font-size: clamp(2.8rem, 6vw, 5.25rem); font-weight: 720; }
.hero-copy { max-width: 600px; color: var(--ink-soft); font-size: clamp(1.05rem, 2vw, 1.25rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: .5rem; min-height: 48px; border: 1px solid var(--forest); border-radius: 999px; padding: .7rem 1.2rem; background: var(--forest); color: white; font-weight: 700; text-decoration: none; cursor: pointer; transition: transform .15s ease, background .15s ease; }
.button:hover { transform: translateY(-1px); background: var(--forest-dark); color: white; }
.button.secondary { color: var(--forest); background: transparent; }
.button.secondary:hover { background: var(--moss); }
.button.small { min-height: 40px; padding: .5rem .9rem; font-size: .9rem; }
.proof-row { display: flex; flex-wrap: wrap; gap: .8rem 1.6rem; margin-top: 2.6rem; color: var(--ink-soft); font-size: .88rem; }
.proof-row span { display: inline-flex; align-items: center; gap: .5rem; }
.proof-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--clay); }
.section { padding: 4.5rem 0; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 2rem; margin-bottom: 1.8rem; }
.section-head h2 { max-width: 650px; margin: .55rem 0 0; font-size: clamp(2rem, 4vw, 3rem); }
.section-head p { max-width: 390px; margin: 0; color: var(--ink-soft); }
.card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.tool-card { min-height: 275px; display: flex; flex-direction: column; justify-content: space-between; padding: 1.55rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.tool-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 15px; background: var(--moss); color: var(--forest); }
.tool-icon svg { width: 23px; height: 23px; }
.tool-card h3 { margin: 1.25rem 0 .55rem; font-size: 1.5rem; }
.tool-card p { max-width: 440px; color: var(--ink-soft); margin: 0 0 1.1rem; }
.text-link { display: inline-flex; gap: .45rem; align-items: center; font-weight: 760; text-decoration: none; }
.split { display: grid; grid-template-columns: .9fr 1.1fr; gap: 3rem; align-items: start; }
.panel { padding: clamp(1.4rem, 4vw, 2.4rem); border-radius: var(--radius); background: #e8efe5; }
.panel h2 { margin: .5rem 0 1rem; font-size: clamp(1.8rem, 3.2vw, 2.65rem); }
.panel p { color: #465e58; }
.check-list { list-style: none; padding: 0; margin: 1.4rem 0 0; }
.check-list li { position: relative; padding: .55rem 0 .55rem 1.7rem; }
.check-list li::before { content: "✓"; position: absolute; left: 0; color: var(--forest); font-weight: 900; }
.note-box { padding: 1rem 1.1rem; border-left: 3px solid var(--clay); background: #fbf0e5; color: #59483f; font-size: .93rem; }
.page-hero { padding: 4rem 0 2.25rem; }
.page-hero h1 { max-width: 820px; margin: .75rem 0 1rem; font-size: clamp(2.5rem, 5vw, 4rem); }
.page-hero p { max-width: 720px; margin: 0; color: var(--ink-soft); font-size: 1.1rem; }
.tool-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(285px, .65fr); gap: 1.2rem; align-items: start; padding: 1rem 0 4.5rem; }
.form-card, .result-card, .content-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.form-card { padding: clamp(1.15rem, 3vw, 2rem); }
.result-card { position: sticky; top: 1.25rem; overflow: hidden; }
.result-top { padding: 1.45rem; background: var(--forest); color: white; }
.result-top .eyebrow { color: #e0ebe1; }
.result-top .eyebrow::before { background: var(--sun); }
.result-top h2 { margin: .7rem 0 .2rem; font-size: 1.45rem; }
.result-body { padding: 1.35rem; }
.result-total { font-size: clamp(2rem, 4vw, 3rem); font-weight: 780; letter-spacing: -.06em; color: var(--forest-dark); }
.result-label { margin: .25rem 0 .9rem; color: var(--ink-soft); font-size: .9rem; }
.result-line { display: flex; justify-content: space-between; gap: 1rem; padding: .7rem 0; border-top: 1px solid var(--line); font-size: .95rem; }
.result-line strong { text-align: right; }
.result-message { min-height: 3rem; margin-top: .7rem; color: var(--ink-soft); font-size: .9rem; }
.form-heading { display: flex; justify-content: space-between; align-items: start; gap: 1rem; margin: 0 0 1rem; }
.form-heading h2 { margin: .1rem 0; font-size: 1.35rem; }
.form-heading p { color: var(--ink-soft); margin: .35rem 0 0; font-size: .92rem; }
.fields { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 1rem; }
.field { min-width: 0; }
.field.full { grid-column: 1 / -1; }
.field label, .field-label { display: block; margin-bottom: .35rem; color: var(--ink); font-size: .9rem; font-weight: 700; }
.field small { display: block; margin-top: .28rem; color: var(--ink-soft); font-size: .82rem; }
input, select { width: 100%; min-height: 46px; padding: .65rem .75rem; border: 1px solid #b9c2bc; border-radius: 10px; background: white; color: var(--ink); }
input::placeholder { color: #78857f; }
.field input[aria-invalid="true"] { border-color: #a43e2a; }
.table-wrap { overflow-x: auto; margin: 1rem 0; border: 1px solid var(--line); border-radius: 12px; }
.input-table { width: 100%; min-width: 640px; border-collapse: collapse; }
.input-table th { padding: .7rem; background: #eff2ec; text-align: left; font-size: .78rem; letter-spacing: .035em; }
.input-table td { padding: .55rem; border-top: 1px solid var(--line); vertical-align: top; }
.input-table input { min-width: 85px; }
.input-table .item-name { min-width: 150px; }
.remove-row { display: inline-grid; place-items: center; width: 38px; height: 42px; border: 1px solid var(--line); border-radius: 9px; color: #704333; background: #fff; cursor: pointer; }
.actions-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .7rem; margin-top: 1.2rem; }
.secondary-action { border: 0; padding: .5rem .1rem; background: transparent; color: var(--forest); font-weight: 750; text-decoration: underline; text-underline-offset: .2em; cursor: pointer; }
.inline-status { min-height: 1.5rem; margin: .65rem 0 0; color: #8b3321; font-size: .9rem; }
.formula { margin: 1.2rem 0 0; padding: 1rem; border-radius: 12px; background: #f0f3ed; color: #43534e; font-size: .9rem; }
.formula code { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; color: var(--forest-dark); }
.content-wrap { padding: 0 0 4.5rem; }
.content-card { padding: clamp(1.25rem, 4vw, 2.5rem); }
.content-card h2 { margin: 2rem 0 .7rem; font-size: 1.7rem; }
.content-card h2:first-child { margin-top: 0; }
.content-card p, .content-card li { color: #46575b; }
.content-card p { max-width: 800px; }
.content-card li { padding: .2rem 0; }
.content-card code { padding: .12rem .35rem; border-radius: 5px; background: #edf1eb; }
.source-card { margin: 1rem 0; padding: 1rem; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.source-card strong { display: block; }
.source-card p { margin: .3rem 0 0; font-size: .92rem; }
.site-footer { border-top: 1px solid var(--line); padding: 2.5rem 0; background: #f3f2ec; }
.footer-grid { display: grid; grid-template-columns: 1fr auto; gap: 2rem; align-items: start; }
.footer-brand { font-weight: 750; }
.footer-grid p { max-width: 570px; margin: .5rem 0 0; color: var(--ink-soft); font-size: .88rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: .7rem 1.1rem; }
.footer-links a { color: var(--ink-soft); font-size: .88rem; }
.copyright { margin-top: 1.4rem; color: var(--ink-soft); font-size: .8rem; }
.muted { color: var(--ink-soft); }
.badge { display: inline-flex; align-items: center; gap: .4rem; padding: .33rem .65rem; border-radius: 999px; background: #f8ead7; color: #704a28; font-size: .78rem; font-weight: 750; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

@media (max-width: 820px) {
  .hero::after { right: -9rem; opacity: .5; }
  .section-head { display: block; }
  .section-head p { margin-top: .8rem; }
  .split { grid-template-columns: 1fr; gap: 1.3rem; }
  .tool-layout { grid-template-columns: 1fr; }
  .result-card { position: static; grid-row: 1; }
}
@media (max-width: 620px) {
  .shell { width: min(100% - 28px, 1160px); }
  .nav-row { min-height: 68px; flex-wrap: wrap; gap: .8rem; padding: .8rem 0; }
  .nav-links { width: 100%; justify-content: space-between; gap: .6rem; }
  .nav-links a { font-size: .82rem; }
  .nav-cta { padding: .45rem .7rem; }
  .hero { padding: 3.4rem 0 3.3rem; }
  .hero::after { width: 250px; top: 5rem; right: -11rem; }
  .hero-actions { align-items: stretch; }
  .hero-actions .button { flex: 1 1 100%; }
  .section { padding: 3.2rem 0; }
  .card-grid { grid-template-columns: 1fr; }
  .tool-card { min-height: 235px; }
  .page-hero { padding: 3rem 0 1.6rem; }
  .fields { grid-template-columns: 1fr; }
  .field.full { grid-column: auto; }
  .footer-grid { grid-template-columns: 1fr; }
  .result-body { padding: 1.15rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
