/* PareiginėAlga.lt v2 — „atsiskaitymo lapelio“ pasaulis: šiltas popierius, gilus žalsvai mėlynas rašalas, plaukinės linijos, lentelių skaitmenys. */
@font-face { font-family: "Source Sans 3"; src: url(/assets/fonts/source-sans-3-latin-wght-normal.woff2) format("woff2"); font-weight: 200 900; 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; }
@font-face { font-family: "Source Sans 3"; src: url(/assets/fonts/source-sans-3-latin-ext-wght-normal.woff2) format("woff2"); font-weight: 200 900; font-display: swap; unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Source Serif 4"; src: url(/assets/fonts/source-serif-4-latin-wght-normal.woff2) format("woff2"); font-weight: 200 900; 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; }
@font-face { font-family: "Source Serif 4"; src: url(/assets/fonts/source-serif-4-latin-ext-wght-normal.woff2) format("woff2"); font-weight: 200 900; font-display: swap; unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --paper: oklch(97.6% 0.008 85);
  --sheet: oklch(99.4% 0.004 85);
  --ink: oklch(25% 0.03 195);
  --ink-2: oklch(42% 0.03 195);
  --ink-3: oklch(52% 0.025 195);
  --brand: oklch(38% 0.07 190);
  --brand-2: oklch(47% 0.08 188);
  --brand-wash: oklch(94.5% 0.025 188);
  --accent: oklch(58% 0.13 60);
  --accent-wash: oklch(95% 0.035 75);
  --line: oklch(88% 0.012 85);
  --line-2: oklch(80% 0.015 85);
  --warn: oklch(52% 0.16 35);
  --warn-wash: oklch(95.5% 0.03 40);
  --ok: oklch(45% 0.1 160);
  --shadow: 0 1px 2px oklch(30% 0.03 195 / .06), 0 8px 24px -12px oklch(30% 0.03 195 / .18);
  --r: 10px;
  --serif: "Source Serif 4", Georgia, serif;
  --sans: "Source Sans 3", system-ui, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: oklch(19% 0.015 200); --sheet: oklch(23% 0.016 200); --ink: oklch(93% 0.01 90); --ink-2: oklch(80% 0.015 190); --ink-3: oklch(70% 0.015 190);
    --brand: oklch(80% 0.09 185); --brand-2: oklch(84% 0.08 185); --brand-wash: oklch(28% 0.04 190); --accent: oklch(78% 0.12 70); --accent-wash: oklch(29% 0.04 70);
    --line: oklch(32% 0.015 200); --line-2: oklch(40% 0.02 200); --warn: oklch(78% 0.12 40); --warn-wash: oklch(30% 0.05 40); --ok: oklch(78% 0.1 160);
    --shadow: 0 1px 2px #0004, 0 10px 30px -14px #000a; color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 16px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 1.0625rem/1.6 var(--sans); font-feature-settings: "tnum" 0; text-rendering: optimizeLegibility; }
::selection { background: var(--brand); color: var(--paper); }
:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
a { color: var(--brand); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--brand-2); text-decoration-thickness: 2px; }
img, svg { display: block; }
.i { width: 1.1em; height: 1.1em; flex: none; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 14px; z-index: 50; }
.skip:focus { left: 8px; }
.num, .t td, .big strong, .formula { font-variant-numeric: tabular-nums lining-nums; }
h1, h2, h3 { font-family: var(--serif); font-weight: 650; letter-spacing: -0.015em; line-height: 1.18; text-wrap: balance; color: var(--ink); }
h1 { font-size: clamp(1.75rem, 1.2rem + 2.4vw, 2.6rem); margin: .4em 0 .45em; letter-spacing: -0.025em; }
h2 { font-size: clamp(1.3rem, 1.1rem + .9vw, 1.65rem); margin: 2.4em 0 .6em; }
h3 { font-size: 1.12rem; margin: 0; }
p { margin: 0 0 1em; }

/* ---------- Viršus ---------- */
.top { background: var(--sheet); border-bottom: 1px solid var(--line); position: relative; z-index: 5; }
.top__in { max-width: 1200px; margin: 0 auto; padding: 10px 16px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--brand); }
.brand__mark { width: 30px; height: 30px; }
.brand__name { font: 600 1.15rem/1 var(--serif); color: var(--ink); letter-spacing: -0.01em; }
.brand__name b { color: var(--brand); font-weight: 700; }
.menu { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; background: none; border: 1px solid var(--line-2); border-radius: 8px; padding: 7px 12px; font: 600 .95rem var(--sans); color: var(--ink); cursor: pointer; }
.nav { display: none; width: 100%; flex-direction: column; padding: 6px 0 4px; }
.nav.is-open { display: flex; }
.nav a { padding: 11px 4px; border-top: 1px solid var(--line); color: var(--ink-2); text-decoration: none; font-weight: 600; }
.nav a[aria-current] { color: var(--brand); }
@media (min-width: 1180px) {
  .menu { display: none; }
  .nav { display: flex; flex-direction: row; flex-wrap: nowrap; width: auto; margin-left: auto; padding: 0; gap: 2px; }
  .nav a { border: 0; padding: 8px 9px; border-radius: 6px; font-size: .97rem; white-space: nowrap; }
  .nav a:hover { background: var(--brand-wash); color: var(--brand); }
  .nav a[aria-current] { box-shadow: inset 0 -2px 0 var(--brand); border-radius: 0; }
}

/* ---------- Maketas ---------- */
.layout { max-width: 1200px; margin: 0 auto; padding: 0 16px 48px; display: grid; gap: 40px; }
.content { min-width: 0; max-width: 780px; }
.rail { display: none; }
@media (min-width: 1180px) {
  .layout { grid-template-columns: minmax(0, 1fr) 300px; }
  .rail { display: block; padding-top: 28px; }
  .rail .toc { margin-bottom: 20px; }
  .rail .ad--rail { position: sticky; top: 16px; }
}
.crumbs { display: flex; align-items: center; gap: 6px; font-size: .9rem; color: var(--ink-3); margin-top: 18px; }
.crumbs a { color: var(--ink-3); }
.crumbs .i { width: 14px; height: 14px; }
.lead { font-size: 1.14rem; color: var(--ink-2); max-width: 68ch; }
.meta { font-size: .88rem; color: var(--ink-3); margin: -.2em 0 1.4em; }
.answer { display: flex; gap: 12px; align-items: flex-start; background: var(--brand-wash); border-radius: var(--r); padding: 14px 16px; margin: 0 0 1em; }
.answer .i { color: var(--brand); margin-top: .25em; }
.answer p { margin: 0; }

/* ---------- Skaičiuoklė ---------- */
.calc { background: var(--sheet); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); padding: 18px 16px 16px; margin: 1.2em 0 1.6em; display: grid; gap: 18px; }
.calc__title { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 1.2rem; }
.calc__title .i { color: var(--brand); }
@media (min-width: 760px) {
  .calc { grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr); padding: 22px; column-gap: 26px; }
  .calc__title { grid-column: 1 / -1; }
}
.field { margin-bottom: 14px; }
.field label, .seg legend { display: block; font-weight: 650; margin-bottom: 6px; font-size: .98rem; }
input[type=text], select { width: 100%; font: 500 1.05rem var(--sans); color: var(--ink); background: var(--paper); border: 1.5px solid var(--line-2); border-radius: 8px; padding: 10px 12px; min-height: 46px; caret-color: var(--accent); }
.field--coef input { font-size: 1.45rem; font-weight: 650; font-variant-numeric: tabular-nums; }
input:hover, select:hover { border-color: var(--ink-3); }
input:focus, select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-wash); }
input[aria-invalid=true] { border-color: var(--warn); }
input::placeholder { color: var(--ink-3); }
.affix { position: relative; }
.affix span { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--ink-3); font-weight: 600; pointer-events: none; }
.affix input { padding-right: 34px; }
.hint { font-size: .88rem; color: var(--ink-3); margin: 6px 0 0; }
.err { font-size: .9rem; color: var(--warn); margin: 6px 0 0; font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.chip { font: 600 .95rem var(--sans); font-variant-numeric: tabular-nums; color: var(--brand); background: transparent; border: 1px solid var(--line-2); border-radius: 6px; padding: 6px 11px; cursor: pointer; min-height: 36px; }
.chip:hover { border-color: var(--brand); background: var(--brand-wash); }
.more { border-top: 1px solid var(--line); padding-top: 10px; }
.more summary { cursor: pointer; font-weight: 650; color: var(--brand); padding: 4px 0 10px; }
.check { display: flex; gap: 8px; align-items: center; font-size: .97rem; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--brand); }
.seg { border: 0; padding: 0; margin: 0 0 14px; display: flex; flex-wrap: wrap; gap: 6px 14px; }
.seg legend { width: 100%; }
.seg label { display: flex; gap: 6px; align-items: center; cursor: pointer; }
.seg input { accent-color: var(--brand); width: 17px; height: 17px; }
.calc__out { min-width: 0; }
.big { margin: 0 0 12px; display: grid; gap: 2px; padding-bottom: 12px; border-bottom: 1px dashed var(--line-2); }
.big__label { font-size: .92rem; color: var(--ink-3); font-weight: 600; }
.big strong { font: 700 clamp(2rem, 1.5rem + 2vw, 2.6rem)/1.1 var(--serif); color: var(--brand); letter-spacing: -0.02em; }
.big__sub { color: var(--ink-2); font-size: .95rem; }
.warn { display: flex; gap: 8px; background: var(--warn-wash); color: var(--warn); padding: 10px 12px; border-radius: 8px; font-size: .92rem; font-weight: 600; }
.warn .i { margin-top: .2em; }
.bar { display: flex; height: 12px; border-radius: 6px; overflow: hidden; background: var(--line); margin: 4px 0 6px; }
.bar span { transition: width .45s cubic-bezier(.16, 1, .3, 1); }
.bar__net { background: var(--brand); } .bar__soc { background: var(--accent); } .bar__tax { background: var(--ink-3); }
.legend { display: flex; gap: 14px; font-size: .85rem; color: var(--ink-2); margin: 0 0 10px; }
.lg::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
.lg--net::before { background: var(--brand); } .lg--soc::before { background: var(--accent); } .lg--tax::before { background: var(--ink-3); }
.cmp { margin-top: 14px; }
.cmp__title { font-weight: 650; font-size: .93rem; margin: 0 0 4px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.btn { display: inline-flex; align-items: center; gap: 6px; font: 600 .92rem var(--sans); color: var(--ink); background: var(--sheet); border: 1px solid var(--line-2); border-radius: 8px; padding: 8px 12px; min-height: 40px; cursor: pointer; }
.btn:hover { border-color: var(--brand); color: var(--brand); }
.btn--primary { background: var(--brand); border-color: var(--brand); color: var(--paper); }
.btn--primary:hover { background: var(--brand-2); color: var(--paper); }
.btn--quiet { background: transparent; }
.btn .i { width: 16px; height: 16px; }
.toast { margin: 10px 0 0; color: var(--ok); font-weight: 650; font-size: .92rem; }

/* ---------- Lentelės ---------- */
.table-wrap { margin: 1em 0 .6em; border: 1px solid var(--line); border-radius: var(--r); background: var(--sheet); overflow: hidden; }
.table-wrap--scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
#coef-lookup { max-height: 560px; overflow: auto; }
.t { width: 100%; border-collapse: collapse; font-size: .97rem; }
.t caption { text-align: left; font-weight: 650; padding: 12px 14px 8px; font-size: .95rem; color: var(--ink-2); caption-side: top; }
.t th, .t td { padding: 9px 14px; text-align: left; border-top: 1px solid var(--line); white-space: nowrap; }
.t thead th { font-size: .82rem; text-transform: none; color: var(--ink-3); font-weight: 650; background: var(--paper); position: sticky; top: 0; z-index: 1; }
.t .num { text-align: right; }
.t tbody th { font-weight: 650; }
.t td { white-space: nowrap; }
.t td:not(.num) { white-space: normal; }
.t tr.is-current th, .t tr.is-current td { background: var(--accent-wash); }
.t--fill tbody tr { cursor: pointer; }
.t--fill tbody tr:hover th, .t--fill tbody tr:hover td, .t--fill tbody tr:focus-visible th, .t--fill tbody tr:focus-visible td { background: var(--brand-wash); }
.t--fill tbody tr:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.t tr.is-hit th, .t tr.is-hit td { background: var(--accent-wash); font-weight: 700; }
.t--compare td { line-height: 1.25; }
.t--compare .g { display: block; color: var(--ink-3); font-size: .86rem; }
.t--compare .n { display: block; font-weight: 650; }
.t .diff { color: var(--ok); font-weight: 650; }
.t--dense th, .t--dense td { padding: 7px 12px; }
.t--result th { font-weight: 500; color: var(--ink-2); }
.t--result td { text-align: right; }
.t--result tr.sum th, .t--result tr.sum td { font-weight: 700; color: var(--ink); }
.t--result tr.total th, .t--result tr.total td { font-weight: 750; color: var(--brand); border-top: 1.5px solid var(--ink-3); font-size: 1.05rem; }
.t--result tr.muted th, .t--result tr.muted td { color: var(--ink-3); font-size: .9rem; }
.t--result th, .t--result td, .t--mini th, .t--mini td { padding: 7px 2px; }
.t--mini { font-size: .93rem; }
.t--mini thead th { background: transparent; position: static; }
.note { font-size: .86rem; color: var(--ink-3); max-width: 75ch; }
.filter { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 1em 0 .4em; }
.filter label { font-weight: 650; }
.filter input { max-width: 180px; }

/* ---------- Turinys ---------- */
.sec p, .sec li { max-width: 72ch; }
.steps, .list { padding-left: 1.3em; margin: 0 0 1em; }
.steps li, .list li { margin-bottom: .55em; padding-left: .2em; }
.steps li::marker { font-weight: 700; color: var(--brand); font-family: var(--serif); }
.list li::marker { color: var(--brand); }
.formula { display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 6px; font-family: var(--serif); font-size: 1.15rem; background: var(--sheet); border: 1px solid var(--line); border-radius: 8px; padding: 6px 12px; margin: 6px 0 0; }
.formula strong { color: var(--brand); }
.examples h2 { margin-top: 1.6em; }
.ex-list { list-style: none; padding: 0; margin: 0; counter-reset: ex; display: grid; gap: 0; }
.ex { counter-increment: ex; padding: 18px 0; border-top: 1px solid var(--line); display: grid; gap: 6px; }
.ex h3::before { content: counter(ex) ". "; color: var(--brand); }
.ex__note { color: var(--ink-3); margin: 0; font-size: .95rem; }
.ex dl { margin: 4px 0; display: grid; gap: 2px; max-width: 460px; }
.ex dl div { display: flex; justify-content: space-between; gap: 12px; font-variant-numeric: tabular-nums; }
.ex dt { color: var(--ink-2); }
.ex dd { margin: 0; font-weight: 600; }
.ex__total { border-top: 1px dashed var(--line-2); padding-top: 4px; margin-top: 2px; color: var(--brand); }
.ex__total dt, .ex__total dd { color: var(--brand); font-weight: 750; }
.ex__go { display: inline-flex; gap: 6px; align-items: center; font-weight: 650; width: fit-content; }
.ex__go .i { width: 16px; height: 16px; }

.faq h2 { margin-bottom: .4em; }
.faq__item { border-top: 1px solid var(--line); }
.faq__item:last-child { border-bottom: 1px solid var(--line); }
.faq__item summary { cursor: pointer; list-style: none; padding: 14px 32px 14px 0; position: relative; }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 9px; height: 9px; border-right: 2px solid var(--brand); border-bottom: 2px solid var(--brand); transform: translateY(-70%) rotate(45deg); transition: transform .25s cubic-bezier(.16, 1, .3, 1); }
.faq__item[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq__item h3 { font-family: var(--sans); font-weight: 650; font-size: 1.04rem; letter-spacing: 0; }
.faq__a p { color: var(--ink-2); max-width: 72ch; }

.share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 2.4em 0 0; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: .95rem; }
.share span { color: var(--ink-3); font-weight: 600; }
.related ul { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.related li a { display: flex; align-items: center; gap: 12px; padding: 13px 4px; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.related li a:hover { background: var(--brand-wash); }
.related li a > .i { color: var(--brand); width: 22px; height: 22px; }
.related b { display: block; }
.related small { color: var(--ink-3); font-size: .88rem; }
.related .i--go { margin-left: auto; color: var(--ink-3); width: 18px; height: 18px; }
.sources { margin-top: 2em; font-size: .92rem; color: var(--ink-2); }
.sources h2 { font-size: 1.1rem; }
.sources ul { padding-left: 1.2em; }
.toc { border-left: 1px solid var(--line-2); padding-left: 14px; font-size: .92rem; }
.toc__t { font-weight: 700; margin: 0 0 6px; color: var(--ink-2); }
.toc ol { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.toc a { color: var(--ink-2); text-decoration: none; }
.toc a:hover { color: var(--brand); text-decoration: underline; }

/* ---------- Reklama ---------- */
.ad { margin: 1.6em 0; min-height: 300px; display: grid; align-content: start; gap: 4px; }
.ad__label { font-size: .72rem; letter-spacing: .04em; color: var(--ink-3); text-align: center; }
.ad ins { min-height: 280px; background: repeating-linear-gradient(135deg, transparent 0 10px, oklch(50% 0.01 85 / .035) 10px 11px); border-radius: 6px; }
.ad--rail { min-height: 620px; margin: 0; }
.ad--rail ins { min-height: 600px; }
.ad--empty { display: none; }
@media (min-width: 760px) { .ad { min-height: 270px; } .ad ins { min-height: 250px; } }

/* ---------- Apačia, sutikimas ---------- */
.foot { background: var(--sheet); border-top: 1px solid var(--line); font-size: .95rem; color: var(--ink-2); }
.foot__in { max-width: 1200px; margin: 0 auto; padding: 32px 16px 12px; display: grid; gap: 24px; }
@media (min-width: 760px) { .foot__in { grid-template-columns: 1.4fr 1fr 1fr; } }
.foot a, .linkbtn { display: block; color: var(--ink-2); padding: 3px 0; }
.foot__brand { font: 650 1.1rem var(--serif); color: var(--ink); margin-bottom: 6px; }
.foot__h { font-weight: 700; color: var(--ink); margin-bottom: 6px; }
.foot__small { max-width: 1200px; margin: 0 auto; padding: 12px 16px 24px; font-size: .82rem; color: var(--ink-3); }
.linkbtn { background: none; border: 0; font: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; padding: 3px 0; text-align: left; }
.consent { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 40; max-width: 640px; margin: 0 auto; background: var(--sheet); border: 1px solid var(--line-2); border-radius: 12px; box-shadow: 0 14px 40px -12px oklch(20% 0.03 195 / .35); padding: 14px 16px; display: grid; gap: 10px; font-size: .94rem; }
.consent[hidden] { display: none; }
.consent__t { margin: 0; }
.consent__opts { display: flex; gap: 18px; }
.consent__opts[hidden] { display: none; }
.consent__a { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }
@media print {
  .top, .rail, .ad, .share, .related, .foot, .consent, .actions, .chips, .faq, .sources, .crumbs { display: none !important; }
  body { background: #fff; color: #000; }
  .calc { box-shadow: none; border-color: #999; }
}
[hidden] { display: none !important; }
/* Reklamos vietos rezervuojamos tik gavus sutikimą reklamai (kitaip – jokio tuščio ploto). */
.noads .ad { display: none; }

/* ---------- Reklama karštoje zonoje (v2.3) ---------- */
.calc__left { min-width: 0; }
.ad--calc-side, .ad--calc-in { margin: 0; min-height: 0; }
.ad--calc-side { display: none; }
.ad--calc-in { border-top: 1px dashed var(--line-2); padding-top: 12px; margin: 14px 0 4px; }
.ad--calc-in ins { min-height: 250px; }
.ad--aftercalc { display: none; }
@media (min-width: 760px) {
  .ad--calc-in { display: none; }
  .ad--calc-side { display: grid; margin-top: 22px; padding-top: 14px; border-top: 1px dashed var(--line-2); }
  .ad--calc-side ins { min-height: 250px; }
  .ad--aftercalc { display: grid; }
}
.ad.ad--empty, .noads .ad { display: none !important; }
/* Fiksuoto dydžio 336×280 vienetas: centruotas, be juostinio fono pločio problemų. */
.ad ins.adsbygoogle--fixed { justify-self: center; min-height: 280px; }
