:root { color-scheme: light; --bg: #FBF7F9; --surface: #FFFFFF; --surface-2: #F5ECF1; --ink: #22111B; --ink-2: #5D4955; --muted: #5D4955; --line: #EADBE3; --field: #8C7484; --brand: #A0156C; --brand-strong: #7B0F53; --brand-soft: #F9E8F2; --brand-ink: #FFFFFF; --panel: #F8F1F5; --panel-ink: #22111B; --panel-muted: #5D4955; --accent: #0E6A70; --up: #0E6A3F; --up-soft: #E3F3EA; --down: #A3261B; --down-soft: #FBEAE7; --warn: #8A4500; --warn-soft: #FFF2DF; --focus: #A0156C; --code-bg: #F5ECF1; --band: #7B0F53; --band-ink: #FFFFFF; --band-muted: #F6E3EE; --foot-bg: #220E1B; --foot-ink: #FFFFFF; --foot-muted: #C6C0C4; }
/* calculatepercentagechange.com. Light only, phone first. Colors come from brand/tokens.json, written above this line by the build. */
@font-face { font-family: Sora; src: url(/fonts/sora-latin.woff2) format("woff2"); font-weight: 100 800; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
body { margin: 0; font-feature-settings: normal; background: var(--bg); color: var(--ink); font: 400 1rem/1.62 Sora, system-ui, -apple-system, "Segoe UI", sans-serif; overflow-x: clip; }
h1, h2, h3 { font-weight: 600; line-height: 1.18; letter-spacing: -.02em; margin: 0; text-wrap: pretty; }
h1 { font-size: clamp(1.7rem, 1.15rem + 2.4vw, 2.85rem); }
h2 { font-size: clamp(1.35rem, 1.15rem + .9vw, 1.85rem); }
h3 { font-size: 1.14rem; }
p { margin: 0 0 1em; }
a { color: var(--brand); text-underline-offset: 2px; }
a:hover { color: var(--brand-strong); }
ul, ol { margin: 0 0 1em; padding-left: 1.3em; } li { margin-bottom: .35em; }
code { font: 600 .92em ui-monospace, "Cascadia Mono", Consolas, monospace; background: var(--code-bg); color: var(--ink); padding: .1em .35em; border-radius: 6px; overflow-wrap: anywhere; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
.wrap { width: min(1160px, 100% - 32px); margin-inline: auto; }
.skip { position: absolute; left: -999px; } .skip:focus { left: 12px; top: 12px; z-index: 60; background: var(--surface); padding: 10px 14px; border-radius: 8px; }
/* Header */
.site-head { position: sticky; top: 0; z-index: 40; background: rgba(247, 248, 252, .96); border-bottom: 1px solid var(--line); }
.site-head .wrap { display: flex; align-items: center; gap: 10px; min-height: 62px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; min-height: 44px; }
.brand img { display: block; height: 40px; width: auto; flex: none; } .brand .lk-c { display: none; } @media (max-width: 419.98px) { .site-head .brand .lk-f { display: none; } .site-head .brand .lk-c { display: block; } }
.site-foot .brand img { height: 44px; } .site-foot .brand { margin-left: -6px; }
.nav { display: none; gap: 2px; margin-left: 14px; } .nav a { color: var(--ink-2); text-decoration: none; font-weight: 600; font-size: .95rem; padding: 10px 11px; border-radius: 10px; } .nav a:hover, .nav a[aria-current] { background: var(--surface-2); color: var(--ink); }
.menu { position: relative; margin-left: auto; } .menu summary { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; list-style: none; color: var(--ink); } .menu summary::-webkit-details-marker { display: none; }
.menu-panel { position: absolute; right: 0; top: 52px; width: min(340px, calc(100vw - 32px)); max-height: calc(100dvh - 90px); overflow: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 10px; box-shadow: 0 14px 36px rgba(22, 26, 51, .18); }
.menu-panel p { margin: 10px 8px 2px; font-size: .76rem; font-weight: 650; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; } .menu-panel a { display: flex; align-items: center; min-height: 44px; padding: 4px 8px; color: var(--ink); text-decoration: none; border-radius: 8px; } .menu-panel a:hover { background: var(--surface-2); }
/* Hero and tool layout */
.hero { padding: 18px 0 26px; background: linear-gradient(var(--surface-2), var(--bg)); }
.crumbs { font-size: .87rem; color: var(--muted); margin-bottom: 8px; } .crumbs a { color: var(--muted); }
.eyebrow { display: block; color: var(--brand); font-weight: 650; font-size: .82rem; letter-spacing: .05em; text-transform: uppercase; margin-bottom: 6px; }
.lead { font-size: 1.1rem; color: var(--ink-2); margin: 10px 0 0; }
.points { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 7px; } .points li { position: relative; padding-left: 24px; margin: 0; color: var(--ink-2); } .points li::before { content: ""; position: absolute; left: 3px; top: .5em; width: 9px; height: 9px; border-radius: 3px; background: var(--brand); transform: rotate(45deg); }
.meta { font-size: .88rem; color: var(--muted); margin: 14px 0 0; } .meta p { margin: 2px 0 0; }
.tool-grid { display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); }
/* Calculator */
.calc { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 14px; box-shadow: 0 12px 32px rgba(22, 26, 51, .08); display: grid; gap: 12px; min-width: 0; }
.calc-in { display: grid; gap: 12px; min-width: 0; }
.field { display: block; min-width: 0; } .lab { display: block; font-size: .87rem; font-weight: 600; color: var(--ink-2); margin-bottom: 4px; padding: 0; }
.inp { display: flex; align-items: center; min-height: 48px; background: var(--surface); border: 1.5px solid var(--field); border-radius: 12px; padding: 0 12px; gap: 6px; } .inp:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.inp i { font-style: normal; font-weight: 700; color: var(--muted); }
.inp input, .inp select, .inp textarea { flex: 1; width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font: 650 1.06rem Sora, system-ui, sans-serif; font-variant-numeric: tabular-nums; min-height: 44px; padding: 0; }
.inp.area { padding: 8px 12px; } .inp textarea { resize: vertical; min-height: 72px; line-height: 1.5; }
.field.big .inp { min-height: 58px; } .field.big input { font-size: 1.5rem; font-weight: 650; }
.help { display: block; font-size: .83rem; color: var(--muted); margin-top: 3px; }
.pair { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 8px; align-items: end; } .pair:not(:has(.swap)) { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.swap { width: 44px; height: 44px; margin-bottom: 7px; border-radius: 50%; border: 1px solid var(--line); background: var(--brand-soft); color: var(--brand); cursor: pointer; display: grid; place-items: center; }
.row2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; align-items: end; }
.seg { border: 0; padding: 0; margin: 0; min-width: 0; } .seg-row { display: grid; gap: 6px; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); }
.seg label { display: block; cursor: pointer; } .seg input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.seg span { display: flex; align-items: center; justify-content: center; text-align: center; min-height: 46px; height: 100%; padding: 4px 8px; border: 1.5px solid var(--field); border-radius: 12px; font-weight: 650; font-size: .93rem; line-height: 1.2; color: var(--ink); background: var(--surface); }
.seg input:checked + span { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); } .seg input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.calc-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.mark { display: inline-flex; align-items: center; gap: 6px; font-size: .84rem; color: var(--muted); } .mark select { min-height: 44px; border: 1px solid var(--field); border-radius: 10px; background: var(--surface); color: var(--ink); font: 600 .9rem Sora, system-ui, sans-serif; padding: 0 8px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 8px 16px; border-radius: 12px; border: 1.5px solid var(--brand); background: var(--brand); color: var(--brand-ink); font: 650 .95rem Sora, system-ui, sans-serif; cursor: pointer; text-decoration: none; } .btn:hover { background: var(--brand-strong); border-color: var(--brand-strong); color: var(--brand-ink); }
.btn.ghost { background: transparent; color: var(--brand); } .btn.ghost:hover { background: var(--brand-soft); color: var(--brand); } .btn.sm { font-size: .88rem; padding: 6px 12px; }
/* Result */
.result { background: var(--panel); color: var(--panel-ink); border-radius: 16px; padding: 14px; display: grid; gap: 12px; min-width: 0; }
.big { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; } .big .k { flex-basis: 100%; font-size: .86rem; font-weight: 600; color: var(--panel-muted); }
.big .v { font-size: clamp(2.1rem, 1.6rem + 2.2vw, 2.9rem); font-weight: 700; line-height: 1.05; letter-spacing: -.03em; color: var(--accent); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.tag { display: inline-flex; align-items: center; min-height: 28px; padding: 2px 10px; border-radius: 99px; font-size: .82rem; font-weight: 650; background: var(--surface); color: var(--ink-2); border: 1px solid var(--line); } .tag.up { background: var(--up-soft); color: var(--up); border-color: transparent; } .tag.down { background: var(--down-soft); color: var(--down); border-color: transparent; }
.say { margin: 0; font-size: 1.04rem; font-weight: 550; line-height: 1.5; }
.tiles { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; } .tile { background: var(--surface); border-radius: 12px; padding: 9px 12px; min-width: 0; } .tiles.n3 .tile:last-child { grid-column: 1 / -1; }
.tile .k { display: block; font-size: .8rem; color: var(--muted); line-height: 1.3; } .tile .v { display: block; font-size: 1.14rem; font-weight: 700; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.box { background: var(--surface); border-radius: 12px; padding: 11px 13px; min-width: 0; } .box p { margin: 0; } .box-h { font-weight: 650; font-size: .92rem; margin: 0 0 6px !important; color: var(--ink); } .box-h span { font-weight: 500; color: var(--muted); font-size: .84rem; margin-left: 4px; }
.work { margin: 0; padding-left: 1.3em; font-variant-numeric: tabular-nums; } .work li { margin: 0 0 3px; }
.fx-row { display: grid; gap: 2px; margin: 6px 0; } .fx-l { font-size: .8rem; color: var(--muted); } .fx-row code { display: block; padding: 6px 8px; font-size: .9rem; }
.fx-setup, .fx-alt, .fx-note { font-size: .86rem; color: var(--ink-2); } .fx-alt { margin-top: 6px !important; } .fx-note { margin-top: 6px !important; }
.notes { display: grid; gap: 6px; } .note { margin: 0; padding: 9px 12px; border-radius: 10px; font-size: .92rem; line-height: 1.45; background: var(--surface); border-left: 4px solid var(--field); } .note.warn { background: var(--warn-soft); border-color: var(--warn); } .note.info { background: var(--brand-soft); border-color: var(--brand); } .note.good { background: var(--up-soft); border-color: var(--up); } .note.hint { background: var(--surface); }
.rtable { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow-x: auto; margin: 0 0 1em; } .result .rtable, .box .rtable { margin: 0; border: 0; }
.rtable table { width: 100%; border-collapse: collapse; font-size: .93rem; font-variant-numeric: tabular-nums; } .rtable caption { text-align: left; padding: 8px 10px; font-weight: 700; font-size: .9rem; }
.rtable th, .rtable td { padding: 7px 10px; text-align: right; border-top: 1px solid var(--line); vertical-align: top; } .rtable thead th { background: var(--surface-2); border-top: 0; font-size: .84rem; } .rtable th:first-child { text-align: left; } .rtable tbody th { font-weight: 650; }
.rtable.left td { text-align: left; }
/* Sections */
.band { padding: 36px 0; } .band.alt { background: var(--surface-2); } .band h2 { margin-bottom: 12px; } .band-lead { color: var(--ink-2); max-width: 70ch; }
.cards { display: grid; gap: 10px; grid-template-columns: minmax(0, 1fr); } .card { display: flex; flex-direction: column; gap: 2px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 13px 16px; color: var(--ink); text-decoration: none; min-height: 72px; justify-content: center; } .card:hover { border-color: var(--brand); color: var(--ink); } .card b { color: var(--brand); font-weight: 650; } .card span { color: var(--muted); font-size: .92rem; line-height: 1.35; }
.article { display: grid; gap: 28px; padding: 28px 0 44px; grid-template-columns: minmax(0, 1fr); }
.prose { min-width: 0; max-width: 76ch; } .prose > section { margin-bottom: 30px; } .prose h2 { margin-bottom: 10px; } .prose h3 { margin: 18px 0 6px; }
.side { display: grid; gap: 14px; align-content: start; } .panel { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; } .panel-title { font-weight: 650; margin: 0 0 8px; } .panel ul { list-style: none; padding: 0; margin: 0; } .panel li { margin: 0; } .panel li a { display: flex; align-items: center; min-height: 40px; text-decoration: none; line-height: 1.25; }
.ex { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--brand); border-radius: 12px; padding: 12px 14px; margin: 0 0 1em; } .ex-h { font-weight: 650; margin: 0 0 6px; } .ex p:last-child, .ex ol:last-child, .ex ul:last-child { margin-bottom: 0; }
.callout { border-radius: 12px; padding: 12px 14px; margin: 0 0 1em; background: var(--surface-2); border-left: 4px solid var(--field); } .callout p:last-child { margin: 0; } .callout.warn { background: var(--warn-soft); border-color: var(--warn); } .callout.info { background: var(--brand-soft); border-color: var(--brand); }
.semi { font-size: .88rem; color: var(--muted); }
.faq h3 { margin: 16px 0 4px; } .srcs ul { font-size: .9rem; } .srcs small { color: var(--muted); }
.q-list li { margin-bottom: .6em; } .answers { font-size: .95rem; }
.trust { background: var(--band); color: var(--band-ink); padding: 32px 0; } .trust h2 { color: var(--band-ink); margin-bottom: 8px; } .trust p { color: var(--band-muted); margin: 0; max-width: 72ch; } .trust a { color: var(--band-ink); }
.print-links { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 1em; }
/* Footer */
.site-foot { background: var(--foot-bg); color: var(--foot-muted); padding: 34px 0 24px; font-size: .94rem; } .site-foot a { color: var(--foot-ink); } .foot-grid { display: grid; gap: 22px; grid-template-columns: repeat(2, minmax(0, 1fr)); } .foot-brand { grid-column: 1 / -1; } 
.site-foot h2 { font: 750 .8rem Sora, system-ui, sans-serif; letter-spacing: .05em; text-transform: uppercase; color: var(--foot-muted); margin-bottom: 6px; } .site-foot ul { list-style: none; padding: 0; margin: 0; } .site-foot li { margin: 0; } .site-foot li a { display: inline-flex; align-items: center; min-height: 40px; padding: 4px 0; line-height: 1.3; text-decoration: none; }
.fine { border-top: 1px solid rgba(255, 255, 255, .14); margin-top: 22px; padding-top: 14px; display: grid; gap: 6px; font-size: .85rem; } .fine p { margin: 0; }
.nf { padding: 50px 0; }
/* Embed and print pages */
body.embed { background: var(--surface); } body.embed main { max-width: 520px; margin: 0 auto; padding: 12px; } body.embed h1 { font-size: 1.3rem; margin-bottom: 10px; } .embed-credit { font-size: .85rem; margin: 10px 0 0; text-align: center; }
body.sheet { background: #fff; } .sheet-page { max-width: 760px; margin: 0 auto; padding: 24px 20px; } .sheet-page h1 { font-size: 1.6rem; } .sheet-head { display: flex; justify-content: space-between; gap: 12px; font-size: .9rem; color: var(--muted); border-bottom: 1px solid var(--line); padding-bottom: 8px; margin-bottom: 16px; } .sheet-page ol li { margin-bottom: 1.6em; } .sheet-page .key li { margin-bottom: .5em; } .sheet-break { break-before: page; page-break-before: always; margin-top: 40px; } .no-print { margin: 0 0 14px; }
@media print { .site-head, .site-foot, .no-print, .ad-slot, .calc-bar { display: none !important; } body { background: #fff; } a { color: inherit; } .rtable { overflow: visible; } }
@media (min-width: 560px) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } .calc { padding: 18px; } .result { padding: 18px; } }
@media (min-width: 900px) {
  .nav { display: flex; }
  .hero-text { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 8px 44px; align-items: end; } .hero-text .hl { grid-column: 1; } .hero-text .hr { grid-column: 2; }
  .calc { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); grid-template-rows: auto 1fr; gap: 14px 22px; align-items: start; padding: 22px; }
  .calc .calc-left { grid-column: 1; grid-row: 1 / span 2; position: sticky; top: 84px; display: grid; gap: 14px; } .calc .result { grid-column: 2; grid-row: 1 / span 2; }
  body.embed .calc { grid-template-columns: minmax(0, 1fr); } body.embed .calc > * { grid-column: 1 !important; grid-row: auto !important; position: static !important; }
  .article { grid-template-columns: minmax(0, 1fr) 280px; gap: 44px; }
  .side { position: sticky; top: 80px; }
  .cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .foot-grid { grid-template-columns: 1.4fr repeat(4, minmax(0, 1fr)); } .foot-brand { grid-column: auto; }
  .hero { padding: 30px 0 34px; }
}
@media (min-width: 1200px) { .cards { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.embed-code { white-space: pre-wrap; overflow-wrap: anywhere; background: var(--code-bg); border-radius: 10px; padding: 10px 12px; } .embed-code code { background: none; padding: 0; }
.sheet-head { flex-wrap: wrap; } .sheet-head span { min-width: 0; overflow-wrap: anywhere; }
.answers summary { cursor: pointer; font-weight: 650; color: var(--brand); min-height: 44px; display: flex; align-items: center; }

.calc-left { display: grid; gap: 12px; min-width: 0; }
@media (max-width: 559.98px) { .hero .points { display: none; } .hero { padding-bottom: 18px; } }


/* AdSense units (adsense-unit.mjs): space reserved, labelled, collapsed when unfilled or off */
.ad-slot { display: block; position: relative; clear: both; min-height: 280px; margin: 40px auto 32px; padding-top: 4px; box-sizing: border-box; grid-column: 1 / -1; flex-basis: 100%; max-width: 100%; contain: layout; }
.ad-slot::before { content: "Advertisement"; position: absolute; top: -20px; left: 0; font-size: .72rem; line-height: 1.4; color: #6b6b6b; letter-spacing: .02em; }
main > .ad-slot { width: min(1100px, calc(100% - 32px)); }
@media (min-width: 900px) { .ad-slot { min-height: 250px; } }
.ads-off .ad-slot, .ad-slot:has(> ins.adsbygoogle[data-ad-status="unfilled"]) { display: none !important; }
@media print { .ad-slot { display: none !important; } }
