/* Rep and Ration landing page. Ledger paper, ink and one red pencil. */
:root { --paper:#EDF3EB; --sheet:#F7FAF4; --ink:#11241D; --ink-2:#33473E; --muted:#4A5F55; --rule:#BCD3C4; --rule-soft:#CFE0D3; --pencil:#B42D19; --margin:#C2402C; --serif:Besley,Georgia,"Times New Roman",serif; --sans:Archivo,Arial,sans-serif; --hand:"Nanum Pen Script","Segoe Print",cursive; }
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 18px/1.55 var(--sans); }
a { color: var(--ink); }
a:hover { color: var(--pencil); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--pencil); outline-offset: 3px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.page { position: relative; overflow: hidden; }
.wrap { max-width: 1280px; margin: 0 auto; padding-left: clamp(20px, 6vw, 96px); padding-right: clamp(20px, 6vw, 64px); }
.margin-rule { position: absolute; top: 0; bottom: 0; width: 4px; left: calc(max(0px, (100% - 1280px) / 2) + clamp(8px, 3vw, 48px)); border-left: 1px solid var(--margin); border-right: 1px solid var(--margin); opacity: 0.55; pointer-events: none; }

.site-head { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 22px; padding-bottom: 22px; }
.wordmark { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-family: var(--serif); font-size: 23px; font-weight: 600; letter-spacing: -0.01em; text-decoration: none; }
.wordmark i { font-weight: 400; }
.site-head nav { display: flex; align-items: center; gap: 28px; font-size: 16px; font-weight: 500; }
.site-head nav a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.nav-menu { display: none; }
.nav-menu summary { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 1px solid var(--ink); cursor: pointer; list-style: none; font-weight: 600; }
.nav-menu summary::-webkit-details-marker { display: none; }
.nav-menu summary svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.nav-menu[open] summary { background: var(--ink); color: var(--sheet); }
.nav-panel { position: absolute; z-index: 30; top: calc(100% - 10px); left: clamp(20px, 6vw, 96px); right: clamp(20px, 6vw, 64px); display: flex; flex-direction: column; padding: 8px 20px 20px; background: var(--sheet); border: 1px solid var(--ink); box-shadow: 0 24px 48px -24px rgba(17, 36, 29, 0.45); }
.site-head .nav-panel a:not(.btn) { min-height: 52px; border-bottom: 1px solid var(--rule-soft); font-size: 18px; }
.nav-panel .btn { margin-top: 16px; }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 26px; background: var(--ink); border: 1px solid var(--ink); color: var(--sheet); font-size: 16px; font-weight: 600; text-decoration: none; }
.btn:hover { background: var(--pencil); border-color: var(--pencil); color: #fff; }

.hero-section { position: relative; padding-top: clamp(32px, 6vw, 84px); }
.hero { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 56px; align-items: end; }
.hero h1 { margin: 0; font-family: var(--serif); font-weight: 500; font-size: clamp(50px, 7.9vw, 112px); line-height: 1.02; letter-spacing: -0.025em; text-wrap: balance; }
.hero-side { display: flex; flex-direction: column; align-items: flex-start; gap: 24px; padding-bottom: 8px; }
.hero-side p { margin: 0; font-size: 20px; line-height: 1.5; text-wrap: pretty; }

.ledger { margin: clamp(40px, 6vw, 72px) 0 0; background: var(--sheet); box-shadow: 0 0 0 1px var(--rule-soft), 0 22px 48px -18px rgba(17, 36, 29, 0.28); }
.ledger figcaption { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 32px; padding: 14px 24px; border-bottom: 1px solid var(--ink); font-size: 14px; font-weight: 500; }
.quiet { color: var(--muted); font-size: 14px; font-weight: 400; }
.pair { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.pair-col { padding: 24px 24px 20px; }
.pair-right { border-left: 3px double var(--margin); }
.col-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 12px; }
.col-head h2 { margin: 0; font-family: var(--serif); font-size: 32px; font-weight: 500; letter-spacing: -0.015em; }
.col-head span { color: var(--muted); font-size: 14px; }

table { border-collapse: collapse; width: 100%; font-variant-numeric: tabular-nums; }
.log, .invoice { font-size: 16px; }
.log th, .log td, .invoice th, .invoice td { padding: 10px 0; text-align: left; vertical-align: top; }
.log thead th, .invoice thead th { padding: 6px 0; border-bottom: 1px solid var(--ink); color: var(--muted); font-size: 13px; font-weight: 600; }
.log tbody td { border-bottom: 1px solid var(--rule-soft); }
.log tbody tr:last-child td { border-bottom: 1px solid var(--ink); }
.pair-col:first-child .log tbody tr:last-child td { border-bottom: 0; }
.log tfoot th, .log tfoot td { padding: 10px 0 8px; border-bottom: 3px double var(--ink); font-weight: 600; }
.num { text-align: right !important; white-space: nowrap; padding-left: 16px !important; }
.log .edited td { border-bottom: 0; padding-bottom: 6px; }
.log .note-row td { padding: 0 0 8px; }

.struck { position: relative; display: inline-block; }
.struck del { text-decoration: none; }
.strike { position: absolute; left: -4px; top: 50%; width: calc(100% + 8px); height: 10px; margin-top: -5px; overflow: visible; }
.strike path { fill: none; stroke: var(--pencil); stroke-width: 2.2; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.hand { display: inline-block; font-family: var(--hand); font-size: 29px; line-height: 1; color: var(--pencil); }
.hand-lg { display: inline-flex; align-items: center; gap: 8px; font-size: 32px; }
.hand svg path { fill: none; stroke: var(--pencil); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.tilt-l { transform: rotate(-0.8deg); transform-origin: left center; }
.tilt-r { transform: rotate(0.6deg); transform-origin: left center; }
.ledger-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 32px; padding: 12px 24px 14px; border-top: 1px solid var(--ink); }

.wipe { animation: wipe 0.55s cubic-bezier(0.6, 0, 0.2, 1) both; }
.d1 { animation-delay: 0.5s; } .d2 { animation-delay: 0.95s; } .d3 { animation-delay: 1.5s; } .d4 { animation-delay: 1.95s; } .d5 { animation-delay: 2.5s; }
@keyframes wipe { from { clip-path: inset(-30% 100% -30% -2%); } to { clip-path: inset(-30% -4% -30% -2%); } }

.band { position: relative; padding-top: clamp(80px, 11vw, 148px); }
.section-title { margin: 0 0 20px; font-family: var(--serif); font-weight: 500; font-size: clamp(36px, 4.6vw, 60px); line-height: 1.08; letter-spacing: -0.02em; text-wrap: balance; }
.measure { margin: 0 0 28px; max-width: 34em; text-wrap: pretty; }

.steps { list-style: none; counter-reset: step; margin: 40px 0 0; padding: 0; border-bottom: 1px solid var(--rule); }
.steps li { counter-increment: step; display: grid; grid-template-columns: 96px minmax(0, 4fr) minmax(0, 7fr); gap: 24px; padding: 32px 0; border-top: 1px solid var(--rule); }
.steps li::before { content: counter(step); font-family: var(--serif); font-size: 34px; line-height: 1.15; }
.steps .step-mark::before { color: var(--pencil); }
.steps h3 { margin: 0; font-size: 22px; font-weight: 600; line-height: 1.3; }
.steps p { margin: 0; text-wrap: pretty; }

.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 72px; align-items: center; }
.split-top { align-items: start; }
.sheet-card { background: var(--sheet); box-shadow: 0 0 0 1px var(--rule-soft); padding: clamp(16px, 3vw, 32px); }
.calendar-figure { margin: 0; }
.calendar th, .calendar td { padding: 0; text-align: center; }
.calendar thead th { padding-bottom: 10px; border-bottom: 1px solid var(--ink); color: var(--muted); font-size: 13px; font-weight: 600; }
.calendar thead th:first-child, .calendar tbody th { text-align: left; }
.calendar tbody th { width: 72px; font-size: 14px; font-weight: 400; }
.calendar tbody tr { height: 58px; border-bottom: 1px solid var(--rule-soft); }
.calendar .m { margin: 0 auto; }
.m { display: block; position: relative; flex: none; width: 20px; height: 20px; border-radius: 50%; }
.m-done { background: var(--ink); }
.m-part { border: 2px solid var(--ink); background: linear-gradient(90deg, var(--ink) 50%, transparent 50%); }
.m-up { border: 2px solid #5F7F70; }
.m-miss { border-radius: 0; }
.m-miss::before, .m-miss::after { content: ""; position: absolute; left: 0; right: 0; top: 9px; height: 2.5px; background: var(--pencil); }
.m-miss::before { transform: rotate(45deg); }
.m-miss::after { transform: rotate(-45deg); }
.legend { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 14px; color: var(--ink-2); font-size: 14px; }
.legend > span { display: inline-flex; align-items: center; gap: 8px; }

.dark { position: relative; margin-top: clamp(80px, 11vw, 148px); background: var(--ink); color: var(--paper); }
.dark .wrap { padding-top: clamp(72px, 10vw, 128px); padding-bottom: clamp(72px, 10vw, 128px); }
.dark h2 { margin: 0; max-width: 15em; font-family: var(--serif); font-weight: 400; font-size: clamp(36px, 5.4vw, 72px); line-height: 1.1; letter-spacing: -0.02em; text-wrap: balance; }
.dark p { margin: 28px 0 0; max-width: 38em; color: #CFDDD2; text-wrap: pretty; }

.invoice { font-size: 17px; }
.invoice tbody td { padding: 13px 0; border-bottom: 1px solid var(--rule-soft); }
.invoice tbody tr:last-child td { border-bottom: 1px solid var(--ink); }
.invoice tfoot th, .invoice tfoot td { padding: 16px 0 12px; border-bottom: 3px double var(--ink); font-weight: 600; vertical-align: baseline; }
.price { font-family: var(--serif); font-size: 44px; font-weight: 500 !important; letter-spacing: -0.02em; line-height: 1; }

.site-foot { position: relative; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 32px; margin-top: clamp(80px, 11vw, 148px); padding-top: 18px; padding-bottom: 26px; font-size: 15px; }
.foot-links { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 24px; }
.foot-links a, .foot-links button { display: inline-flex; align-items: center; min-height: 44px; padding: 0; background: none; border: 0; color: var(--ink); font: inherit; text-decoration: underline; cursor: pointer; }
.foot-links button:hover { color: var(--pencil); }

dialog { width: min(720px, calc(100vw - 32px)); max-height: 80vh; padding: 0; background: var(--sheet); border: 0; color: var(--ink); box-shadow: 0 0 0 1px var(--rule), 0 24px 48px -18px rgba(17, 36, 29, 0.4); }
dialog::backdrop { background: rgba(17, 36, 29, 0.5); }
.dialog-head { position: sticky; top: 0; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 24px; background: var(--sheet); border-bottom: 1px solid var(--ink); }
.dialog-head h2 { margin: 0; font-family: var(--serif); font-size: 24px; font-weight: 500; }
.dialog-head button { min-height: 44px; padding: 0 14px; background: none; border: 1px solid var(--rule); color: var(--ink); font: inherit; font-weight: 600; cursor: pointer; }
.dialog-body { padding: 8px 24px 24px; font-size: 16px; }
.dialog-body h6 { margin: 20px 0 6px; font-size: 17px; }

@media (max-width: 980px) {
    .hero { grid-template-columns: minmax(0, 1fr); gap: 28px; }
    .pair { grid-template-columns: minmax(0, 1fr); }
    .pair-right { border-left: 0; border-top: 3px double var(--margin); }
    .pair-col:first-child .log tbody tr:last-child td { border-bottom: 0; }
    .split { grid-template-columns: minmax(0, 1fr); gap: 48px; }
    .steps li { grid-template-columns: 56px minmax(0, 1fr); gap: 8px 16px; }
    .steps p { grid-column: 2; }
}
@media (max-width: 760px) {
    .margin-rule, .nav-extra { display: none !important; }
    .nav-menu { display: block; }
    .nav-signin { display: none !important; }
    .site-head nav { gap: 16px; }
}
@media (prefers-reduced-motion: reduce) {
    .wipe { animation: none; }
    html { scroll-behavior: auto; }
}

.audience { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; margin-top: 32px; }
.audience > div { padding-top: 20px; border-top: 1px solid var(--ink); }
.audience h3 { margin: 0 0 8px; font-size: 22px; font-weight: 600; line-height: 1.3; }
.audience p { margin: 0; text-wrap: pretty; }
@media (max-width: 980px) { .audience { grid-template-columns: minmax(0, 1fr); gap: 24px; } }

/* Free calculators: lists, forms and results */
.tool-list { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 40px; margin: 0; padding: 0; }
.tool-list a { display: flex; flex-direction: column; gap: 2px; padding: 18px 0; border-top: 1px solid var(--ink); text-decoration: none; }
.tool-list strong { font-size: 20px; font-weight: 600; }
.tool-list span { color: var(--muted); font-size: 16px; }
.tool-list a:hover strong { color: var(--pencil); }
@media (max-width: 760px) { .tool-list { grid-template-columns: minmax(0, 1fr); } }

.crumbs { margin: 0 0 18px; color: var(--muted); font-size: 14px; }
.crumbs a { color: var(--muted); }
.page-title { margin: 0; max-width: 18em; font-family: var(--serif); font-weight: 500; font-size: clamp(38px, 5.6vw, 72px); line-height: 1.05; letter-spacing: -0.02em; text-wrap: balance; }
.page-lede { margin: 20px 0 0; max-width: 36em; font-size: 20px; text-wrap: pretty; }

.calc { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 32px; margin-top: clamp(32px, 5vw, 56px); align-items: start; }
.calc-form { display: grid; gap: 18px; }
.calc fieldset { margin: 0; padding: 0; border: 0; }
.calc legend, .calc label.field-label { display: block; margin-bottom: 6px; font-size: 14px; font-weight: 600; }
.calc input[type=number], .calc select { width: 100%; min-height: 48px; padding: 0 12px; background: #fff; border: 1px solid var(--rule); border-bottom: 2px solid var(--ink); color: var(--ink); font: inherit; font-size: 18px; border-radius: 0; }
.calc input:focus, .calc select:focus { outline: 2px solid var(--pencil); outline-offset: 1px; }
.calc .row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.calc .unit { display: flex; align-items: stretch; }
.calc .unit input { flex: 1; min-width: 0; }
.calc .unit span { display: inline-flex; align-items: center; padding: 0 12px; border: 1px solid var(--rule); border-left: 0; border-bottom: 2px solid var(--ink); background: var(--sheet); color: var(--muted); font-size: 15px; }
.seg { display: inline-flex; border: 1px solid var(--ink); }
.seg label { position: relative; }
.seg input { position: absolute; opacity: 0; inset: 0; }
.seg span { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; font-size: 15px; font-weight: 600; cursor: pointer; }
.seg input:checked + span { background: var(--ink); color: var(--sheet); }
.seg input:focus-visible + span { outline: 2px solid var(--pencil); outline-offset: 2px; }
.hint { margin: 4px 0 0; color: var(--muted); font-size: 14px; }

.result { position: sticky; top: 16px; }
.result .big { margin: 4px 0 0; font-family: var(--serif); font-size: clamp(44px, 6vw, 72px); font-weight: 500; line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.result .big small { font-family: var(--sans); font-size: 18px; font-weight: 500; letter-spacing: 0; color: var(--muted); }
.result-label { margin: 0; color: var(--muted); font-size: 14px; font-weight: 600; }
.result .invoice { margin-top: 20px; }
.result-empty { color: var(--muted); }
.bar { display: flex; height: 12px; margin-top: 16px; background: var(--rule-soft); }
.bar i { display: block; height: 100%; }
.bar .p { background: var(--ink); } .bar .c { background: #5F7F70; } .bar .f { background: var(--pencil); }
.key { display: inline-block; width: 10px; height: 10px; margin-right: 8px; vertical-align: 0; }

.cta-card { margin-top: 24px; padding: 20px 22px; background: var(--ink); color: var(--paper); }
.cta-card p { margin: 0 0 14px; color: #CFDDD2; font-size: 16px; }
.cta-card strong { display: block; margin-bottom: 4px; color: var(--paper); font-family: var(--serif); font-size: 22px; font-weight: 500; }
.cta-card .btn { min-height: 46px; background: var(--paper); border-color: var(--paper); color: var(--ink); }
.cta-card .btn:hover { background: var(--pencil); border-color: var(--pencil); color: #fff; }

.prose { max-width: 40em; }
.prose h2 { margin: 48px 0 12px; font-family: var(--serif); font-size: clamp(28px, 3.4vw, 40px); font-weight: 500; line-height: 1.15; letter-spacing: -0.015em; }
.prose h3 { margin: 28px 0 8px; font-size: 20px; font-weight: 600; }
.prose p, .prose li { text-wrap: pretty; }
.prose table { margin: 16px 0; font-size: 16px; }
.prose th, .prose td { padding: 10px 12px 10px 0; text-align: left; border-bottom: 1px solid var(--rule-soft); vertical-align: top; }
.prose thead th { border-bottom: 1px solid var(--ink); color: var(--muted); font-size: 13px; }
.formula { padding: 12px 16px; background: var(--sheet); box-shadow: 0 0 0 1px var(--rule-soft); font-size: 16px; }
.small-print { color: var(--muted); font-size: 15px; }
.more-tools { margin-top: 56px; }
@media (max-width: 980px) {
    .calc { grid-template-columns: minmax(0, 1fr); }
    .result { position: static; }
}
.key.kp { background: var(--ink); } .key.kc { background: #5F7F70; } .key.kf { background: var(--pencil); }
.calc [hidden] { display: none !important; }
.units { display: flex; justify-content: flex-end; margin-bottom: -6px; }
.seg-sm span { min-height: 36px; padding: 0 12px; font-size: 14px; }
.result-empty { margin: 16px 0 0; }
.optional summary { display: inline-flex; align-items: center; min-height: 44px; color: var(--ink-2); font-size: 15px; text-decoration: underline; cursor: pointer; }
.optional[open] summary { margin-bottom: 8px; }

/* Audience pages */
.eyebrow { margin: 0 0 18px; color: var(--pencil); font-size: 14px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 32px 0 0; }
.point-title { margin: 0 0 8px; font-size: 22px; font-weight: 600; line-height: 1.3; }
.faq details { border-top: 1px solid var(--ink); }
.faq details:last-child { border-bottom: 1px solid var(--ink); }
.faq summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 64px; font-size: 19px; font-weight: 600; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--serif); font-size: 28px; font-weight: 400; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0 0 20px; max-width: 36em; text-wrap: pretty; }
.also { margin: 28px 0 0; color: var(--muted); font-size: 16px; }
.also a { color: var(--ink-2); }
.audience h3 a { text-decoration: none; } .audience h3 a:hover { color: var(--pencil); }

/* Guides */
.byline { margin: 18px 0 0; color: var(--muted); font-size: 14px; }
.guide-body { padding-top: clamp(40px, 6vw, 72px); }
.guide-body .prose { max-width: 42em; font-size: 19px; line-height: 1.65; }
.guide-body .prose h2:first-child { margin-top: 0; }
.guide-body .prose li { margin-bottom: 6px; }
.callout { margin: 24px 0; padding: 16px 20px; border-left: 3px solid var(--pencil); background: var(--sheet); font-size: 17px; }
.callout p { margin: 0; }
.cta-wide { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px 32px; margin-top: 0; padding: 28px 32px; }
.cta-wide strong, .cta-wide p { grid-column: 1; }
.cta-wide p { margin: 0; }
.cta-wide .btn { grid-column: 2; grid-row: 1 / span 2; }
@media (max-width: 760px) { .cta-wide { grid-template-columns: minmax(0, 1fr); } .cta-wide .btn { grid-column: 1; grid-row: auto; justify-self: start; margin-top: 8px; } }
.guide-list { list-style: none; margin: 40px 0 0; padding: 0; border-bottom: 1px solid var(--ink); }
.guide-list a { display: grid; gap: 6px; padding: 26px 0; border-top: 1px solid var(--ink); text-decoration: none; }
.guide-list strong { max-width: 28em; font-family: var(--serif); font-size: clamp(24px, 2.6vw, 32px); font-weight: 500; line-height: 1.2; letter-spacing: -0.01em; }
.guide-list span { max-width: 40em; color: var(--ink-2); }
.guide-list small { color: var(--muted); font-size: 14px; }
.guide-list a:hover strong { color: var(--pencil); }

/* The comparison table: four columns on wide screens, one card per row on phones. */
.compare { width: 100%; border-collapse: collapse; font-size: 16px; }
.compare th, .compare td { padding: 16px 16px 16px 0; text-align: left; vertical-align: top; border-bottom: 1px solid var(--rule-soft); }
.compare thead th { padding-top: 0; border-bottom: 1px solid var(--ink); color: var(--muted); font-size: 14px; font-weight: 600; }
.compare tbody th { width: 22%; font-weight: 600; }
.compare .us { background: var(--sheet); padding-left: 16px; }
.compare thead .us { color: var(--ink); box-shadow: inset 0 3px 0 var(--pencil); padding-top: 12px; }
@media (max-width: 760px) {
    .compare thead { display: none; }
    .compare, .compare tbody, .compare tr, .compare th, .compare td { display: block; width: auto; }
    .compare tr { padding: 20px 0; border-top: 1px solid var(--ink); }
    .compare tbody th { width: auto; padding: 0 0 8px; border: 0; font-size: 18px; }
    .compare td { padding: 6px 0; border: 0; }
    .compare td::before { content: attr(data-label); display: block; color: var(--muted); font-size: 13px; font-weight: 600; }
    .compare .us { margin-top: 6px; padding: 10px 12px; box-shadow: inset 3px 0 0 var(--pencil); }
}
