/* =====================================================================
   MeraMushee — one stylesheet, no framework, no webfont.
   Mobile-first: the median visitor is on Android over 3G/4G.
   ===================================================================== */

:root {
  /* Brand — deep emerald with a warm brass accent */
  --brand-950: #052e21;
  --brand-900: #073d2b;
  --brand-800: #0a4f38;
  --brand-700: #0d6b4c;
  --brand-600: #10875f;
  --brand-500: #16a473;
  --brand-400: #2fbe8b;
  --brand-300: #6ed7b0;
  --brand-100: #d9f2e7;
  --brand-050: #f0faf6;

  --brass-600: #b4802a;
  --brass-500: #d99a34;
  --brass-100: #fdf1dc;

  --ink-900: #0a1714;
  --ink-800: #14312a;
  --ink-700: #2c463f;
  --ink-500: #5f7b72;
  --ink-400: #7d968d;
  --ink-300: #a6b8b1;

  --line: #e2ece8;
  --line-strong: #cddcd6;
  --bg: #ffffff;
  --bg-alt: #f5faf8;
  --bg-sunk: #eef6f2;
  --card: #ffffff;

  --amber: #a8710f;
  --amber-bg: #fdf6e7;
  --red: #b42318;
  --red-bg: #fef3f2;
  --blue: #1d4ed8;
  --blue-bg: #eff4ff;

  --radius-lg: 20px;
  --radius: 14px;
  --radius-sm: 10px;

  --shadow-sm: 0 1px 2px rgba(6, 40, 30, .05);
  --shadow: 0 1px 2px rgba(6, 40, 30, .05), 0 6px 18px -6px rgba(6, 40, 30, .10);
  --shadow-lg: 0 2px 4px rgba(6, 40, 30, .05), 0 18px 40px -12px rgba(6, 40, 30, .18);

  --maxw: 1140px;

  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial,
          "Noto Sans", "Noto Nastaliq Urdu", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --ease: cubic-bezier(.22, .61, .36, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink-900: #e9f3ef;
    --ink-800: #d6e5df;
    --ink-700: #bccec7;
    --ink-500: #8ea69d;
    --ink-400: #7a918a;
    --ink-300: #62786f;

    --line: #1c322b;
    --line-strong: #27423a;
    --bg: #060f0d;
    --bg-alt: #0b1815;
    --bg-sunk: #0a1512;
    --card: #0c1a16;

    --brand-100: #12352a;
    --brand-050: #0d251d;

    --brass-100: #2b2113;
    --amber-bg: #2a2113;
    --red-bg: #2b1614;
    --blue-bg: #131f38;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .5);
    --shadow: 0 1px 2px rgba(0, 0, 0, .5), 0 6px 18px -6px rgba(0, 0, 0, .55);
    --shadow-lg: 0 2px 4px rgba(0, 0, 0, .5), 0 18px 40px -12px rgba(0, 0, 0, .7);
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.62;
  color: var(--ink-800);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  line-height: 1.18;
  margin: 0 0 .5em;
  font-weight: 750;
  letter-spacing: -.022em;
  color: var(--ink-900);
  text-wrap: balance;
}
h1 { font-size: 2.1rem; letter-spacing: -.032em; }
h2 { font-size: 1.45rem; margin-top: 2.4rem; }
h3 { font-size: 1.1rem; margin-top: 1.6rem; }
p { margin: 0 0 1rem; }

a { color: var(--brand-600); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--brand-700); }

@media (min-width: 768px) {
  h1 { font-size: 2.9rem; }
  h2 { font-size: 1.8rem; }
  h3 { font-size: 1.2rem; }
}

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 18px; }
.narrow { max-width: 760px; }

::selection { background: var(--brand-300); color: var(--brand-950); }

/* ---------------------------------------------------------------- */
/* Header                                                            */
/* ---------------------------------------------------------------- */

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--brand-700); color: #fff; padding: 10px 16px; border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; }

.site-header {
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(1.6) blur(12px);
  -webkit-backdrop-filter: saturate(1.6) blur(12px);
  position: sticky; top: 0; z-index: 40;
}
.site-header .wrap { display: flex; align-items: center; gap: 12px; height: 64px; }

.brand {
  display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.1rem;
  color: var(--ink-900); text-decoration: none; letter-spacing: -.03em; white-space: nowrap;
}
.brand:hover { color: var(--ink-900); }
.brand-mark {
  width: 32px; height: 32px; border-radius: 9px; flex: none;
  background: linear-gradient(145deg, var(--brand-400), var(--brand-700));
  box-shadow: 0 2px 8px -2px rgba(16, 135, 95, .55), inset 0 1px 0 rgba(255,255,255,.28);
  display: grid; place-items: center; color: #fff;
}
.brand-mark svg { display: block; }

.nav-toggle {
  margin-left: auto; display: inline-flex; align-items: center; gap: 7px;
  background: var(--bg-alt); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 8px 12px; font: inherit; font-size: .88rem; font-weight: 600;
  color: var(--ink-700); cursor: pointer; transition: background .15s var(--ease);
}
.nav-toggle:hover { background: var(--bg-sunk); }

.site-nav { display: none; }
.site-nav.open {
  display: block; position: absolute; top: 64px; left: 0; right: 0;
  background: var(--bg); border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow-lg); padding: 8px 18px 16px;
}
.site-nav a {
  display: block; padding: 12px 4px; color: var(--ink-700);
  text-decoration: none; border-bottom: 1px solid var(--line); font-size: .97rem; font-weight: 500;
}
.site-nav a:last-child { border-bottom: 0; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--brand-600); }

@media (min-width: 940px) {
  .nav-toggle { display: none; }
  .site-nav, .site-nav.open {
    display: flex; position: static; margin-left: auto; gap: 2px;
    background: none; border: 0; box-shadow: none; padding: 0;
  }
  .site-nav a {
    border: 0; padding: 8px 13px; border-radius: 99px; font-size: .92rem; font-weight: 550;
    transition: background .15s var(--ease), color .15s var(--ease);
  }
  .site-nav a:hover { background: var(--bg-alt); color: var(--ink-900); }
  .site-nav a[aria-current="page"] { background: var(--brand-100); color: var(--brand-700); font-weight: 650; }
}

/* ---------------------------------------------------------------- */
/* Layout                                                            */
/* ---------------------------------------------------------------- */

main { display: block; padding: 24px 0 56px; }

.layout { display: grid; gap: 30px; grid-template-columns: minmax(0, 1fr); }

/* Grid items default to min-width:auto, so a wide table inside one refuses
   to shrink and pushes the whole page sideways on phones. */
.layout > * { min-width: 0; }

@media (min-width: 1000px) {
  .layout { grid-template-columns: minmax(0, 1fr) 300px; align-items: start; }
  .layout aside { position: sticky; top: 84px; }
}

.breadcrumb { font-size: .84rem; color: var(--ink-400); margin-bottom: 12px; }
.breadcrumb a { color: var(--ink-400); text-decoration: none; }
.breadcrumb a:hover { color: var(--brand-600); text-decoration: underline; }

.lede { font-size: 1.1rem; line-height: 1.6; color: var(--ink-700); max-width: 66ch; }

/* ---------------------------------------------------------------- */
/* Hero                                                              */
/* ---------------------------------------------------------------- */

.hero {
  position: relative; overflow: hidden;
  border-radius: var(--radius-lg);
  padding: 40px 24px 44px;
  margin: 6px 0 30px;
  background:
    radial-gradient(120% 140% at 88% -10%, rgba(47, 190, 139, .22), transparent 58%),
    radial-gradient(90% 120% at 0% 0%, rgba(217, 154, 52, .12), transparent 55%),
    linear-gradient(168deg, var(--bg-alt), var(--bg));
  border: 1px solid var(--line);
}
@media (min-width: 720px) { .hero { padding: 60px 48px 64px; } }

.hero h1 { max-width: 17ch; margin-bottom: .35em; }
.hero .lede { font-size: 1.14rem; max-width: 56ch; }

.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .8rem; font-weight: 650; letter-spacing: .01em;
  background: var(--brand-100); color: var(--brand-700);
  padding: 7px 14px; border-radius: 99px; margin-bottom: 18px;
}
.hero-badge .dot {
  width: 7px; height: 7px; border-radius: 99px; background: var(--brand-500); flex: none;
}

/* ---------------------------------------------------------------- */
/* Cards                                                             */
/* ---------------------------------------------------------------- */

.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow);
}
@media (min-width: 640px) { .card { padding: 26px; } }
.card + .card { margin-top: 20px; }

/* ---------------------------------------------------------------- */
/* Forms                                                             */
/* ---------------------------------------------------------------- */

.field { margin-bottom: 18px; }
.field label, .field-label {
  display: block; font-weight: 650; font-size: .9rem; margin-bottom: 7px; color: var(--ink-900);
  letter-spacing: -.005em;
}
.hint { font-size: .83rem; line-height: 1.5; color: var(--ink-500); margin-top: 6px; }

input[type=text], input[type=number], input[type=email], input[type=date],
input[type=month], select, textarea {
  width: 100%; padding: 13px 14px; font: inherit; font-size: 1rem;
  border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  background: var(--bg); color: var(--ink-900); -webkit-appearance: none; appearance: none;
  transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
}
input[type=text]:hover, input[type=number]:hover, select:hover { border-color: var(--ink-300); }
select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'><path d='M2 4.5l4 4 4-4' fill='none' stroke='%235f7b72' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat; background-position: right 13px center; padding-right: 38px;
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--brand-500);
  box-shadow: 0 0 0 3.5px color-mix(in srgb, var(--brand-500) 20%, transparent);
}
input[type=number] { -moz-appearance: textfield; }
input[type=number]::-webkit-outer-spin-button,
input[type=number]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
input[type=file] { font-size: .9rem; }

.input-prefix { position: relative; }
.input-prefix > span {
  position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
  color: var(--ink-400); font-size: .95rem; font-weight: 600; pointer-events: none;
}
.input-prefix input { padding-left: 44px; }

/* Big money input — the primary interaction on most pages */
.input-hero input { font-size: 1.35rem; font-weight: 700; padding-top: 16px; padding-bottom: 16px;
                    letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.input-hero.input-prefix > span { font-size: 1.05rem; }
.input-hero.input-prefix input { padding-left: 50px; }

.grid-2 { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 560px) { .grid-2 { grid-template-columns: 1fr 1fr; } }
.grid-3 { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }

/* Segmented control */
.segment {
  display: flex; border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  overflow: hidden; background: var(--bg-alt); padding: 3px; gap: 3px;
}
.segment input { position: absolute; opacity: 0; pointer-events: none; }
.segment label {
  flex: 1; text-align: center; padding: 10px 8px; margin: 0; cursor: pointer;
  font-size: .91rem; font-weight: 650; color: var(--ink-500); background: transparent;
  border-radius: 7px; transition: background .18s var(--ease), color .18s var(--ease), box-shadow .18s var(--ease);
}
.segment label:hover { color: var(--ink-900); }
.segment input:checked + label {
  background: var(--bg); color: var(--brand-700); box-shadow: var(--shadow-sm);
}
@media (prefers-color-scheme: dark) {
  .segment input:checked + label { background: var(--brand-700); color: #fff; }
}
.segment input:focus-visible + label { outline: 2px solid var(--brand-500); outline-offset: -2px; }

/* Switch rows */
.switch-row {
  display: flex; align-items: flex-start; gap: 12px; padding: 13px 0;
  border-top: 1px solid var(--line);
}
.switch-row:first-of-type { border-top: 0; }
.switch-row input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--brand-600); flex: none; }
.switch-row .t { font-weight: 650; font-size: .93rem; display: block; color: var(--ink-900); }
.switch-row .d { font-size: .83rem; color: var(--ink-500); display: block; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 22px; font: inherit; font-size: .96rem; font-weight: 650;
  border-radius: var(--radius-sm); border: 1px solid transparent; cursor: pointer;
  background: linear-gradient(180deg, var(--brand-500), var(--brand-700));
  color: #fff; text-decoration: none; letter-spacing: -.01em;
  box-shadow: 0 1px 2px rgba(6,40,30,.14), inset 0 1px 0 rgba(255,255,255,.18);
  transition: transform .12s var(--ease), box-shadow .18s var(--ease), filter .15s var(--ease);
}
.btn:hover { color: #fff; filter: brightness(1.06); box-shadow: 0 4px 14px -3px rgba(16,135,95,.5), inset 0 1px 0 rgba(255,255,255,.2); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; filter: none; transform: none; }
.btn:focus-visible { outline: 2px solid var(--brand-500); outline-offset: 2px; }

.btn-ghost {
  background: var(--bg); color: var(--ink-700); border-color: var(--line-strong);
  box-shadow: var(--shadow-sm);
}
.btn-ghost:hover { background: var(--bg-alt); color: var(--ink-900); filter: none; box-shadow: var(--shadow); }
.btn-sm { padding: 9px 14px; font-size: .87rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* ---------------------------------------------------------------- */
/* Results                                                           */
/* ---------------------------------------------------------------- */

.result {
  position: relative; overflow: hidden;
  background:
    radial-gradient(110% 130% at 92% -20%, rgba(47,190,139,.20), transparent 60%),
    linear-gradient(165deg, var(--brand-050), var(--bg-alt));
  border: 1px solid var(--brand-100);
  border-radius: var(--radius-lg);
  padding: 24px 22px; margin-top: 20px;
}
@media (prefers-color-scheme: dark) { .result { border-color: #1b4032; } }

.result-headline {
  font-size: .78rem; color: var(--ink-500); font-weight: 700;
  text-transform: uppercase; letter-spacing: .09em; margin: 0;
}
.result-big {
  font-size: 2.4rem; font-weight: 800; letter-spacing: -.042em;
  line-height: 1.08; margin: 6px 0 0; font-variant-numeric: tabular-nums;
  background: linear-gradient(160deg, var(--brand-600), var(--brand-800));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
@media (min-width: 640px) { .result-big { font-size: 3.1rem; } }
@media (prefers-color-scheme: dark) {
  .result-big { background: linear-gradient(160deg, var(--brand-300), var(--brand-500));
                -webkit-background-clip: text; background-clip: text; color: transparent; }
}

.stat-grid { display: grid; gap: 12px; grid-template-columns: 1fr 1fr; margin-top: 20px; }
@media (min-width: 700px) { .stat-grid { grid-template-columns: repeat(4, 1fr); } }
.stat {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 13px 14px; box-shadow: var(--shadow-sm);
}
.stat .k { font-size: .76rem; color: var(--ink-500); font-weight: 600; letter-spacing: .01em; }
.stat .v {
  font-size: 1.14rem; font-weight: 750; font-variant-numeric: tabular-nums;
  letter-spacing: -.028em; margin-top: 3px; color: var(--ink-900);
}

/* ---------------------------------------------------------------- */
/* Slab band visualisation                                           */
/* ---------------------------------------------------------------- */

.bandbar {
  display: flex; width: 100%; height: 42px; border-radius: 10px; overflow: hidden;
  background: var(--bg-sunk); border: 1px solid var(--line); margin: 6px 0 14px;
}
.bandbar span {
  display: block; height: 100%; position: relative;
  transition: width .4s var(--ease);
  border-right: 1px solid rgba(255, 255, 255, .35);
}
.bandbar span:last-child { border-right: 0; }
.bandbar .b0 { background: var(--brand-100); }
.bandbar .b1 { background: var(--brand-300); }
.bandbar .b2 { background: var(--brand-400); }
.bandbar .b3 { background: var(--brand-500); }
.bandbar .b4 { background: var(--brand-600); }
.bandbar .b5 { background: var(--brand-700); }
.bandbar .b6 { background: var(--brand-800); }
.bandbar .b7 { background: var(--brand-950); }

.bandkey { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: .8rem; color: var(--ink-500); }
.bandkey i {
  width: 10px; height: 10px; border-radius: 3px; display: inline-block;
  margin-right: 6px; vertical-align: -1px;
}

/* ---------------------------------------------------------------- */
/* Tables                                                            */
/* ---------------------------------------------------------------- */

.table-scroll {
  overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 16px 0;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--card);
}
table { width: 100%; border-collapse: collapse; font-size: .92rem; min-width: 460px; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); }
tr:last-child td { border-bottom: 0; }
th {
  font-weight: 700; font-size: .74rem; text-transform: uppercase;
  letter-spacing: .07em; color: var(--ink-500); background: var(--bg-alt);
  position: sticky; top: 0;
}
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
tbody tr.active { background: var(--brand-050); }
tbody tr.active td { font-weight: 650; color: var(--ink-900); }
tfoot td { font-weight: 750; border-top: 2px solid var(--line-strong); background: var(--bg-alt); }

/* Tables inside a card shouldn't double up borders */
.card .table-scroll { border: 0; border-radius: 0; margin: 14px 0 0; }
.card .table-scroll table { border-top: 1px solid var(--line); }

/* ---------------------------------------------------------------- */
/* Callouts                                                          */
/* ---------------------------------------------------------------- */

.note {
  border-left: 3px solid var(--blue); background: var(--blue-bg);
  padding: 14px 16px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: .9rem; margin: 18px 0; color: var(--ink-800);
}
.note.warn { border-color: var(--amber); background: var(--amber-bg); }
.note.err { border-color: var(--red); background: var(--red-bg); }
.note p:last-child { margin-bottom: 0; }
.note strong { display: block; margin-bottom: 4px; color: var(--ink-900); }

.pill {
  display: inline-block; padding: 3px 10px; border-radius: 99px;
  font-size: .74rem; font-weight: 700; background: var(--brand-100); color: var(--brand-700);
  letter-spacing: .01em;
}
.pill.grey { background: var(--bg-sunk); color: var(--ink-500); }

/* ---------------------------------------------------------------- */
/* Tool cards                                                        */
/* ---------------------------------------------------------------- */

.tool-grid { display: grid; gap: 16px; grid-template-columns: 1fr; margin: 20px 0; }
@media (min-width: 620px) { .tool-grid { grid-template-columns: 1fr 1fr; } }

.tool-card {
  position: relative; display: block; text-decoration: none; color: inherit;
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px;
  box-shadow: var(--shadow-sm);
  transition: border-color .18s var(--ease), transform .18s var(--ease), box-shadow .18s var(--ease);
}
.tool-card:hover {
  border-color: var(--brand-400); color: inherit;
  transform: translateY(-2px); box-shadow: var(--shadow-lg);
}
.tool-card .ic {
  width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center;
  background: linear-gradient(150deg, var(--brand-100), var(--brand-050));
  color: var(--brand-700); margin-bottom: 14px;
  border: 1px solid color-mix(in srgb, var(--brand-400) 28%, transparent);
  transition: background .18s var(--ease), color .18s var(--ease);
}
.tool-card:hover .ic {
  background: linear-gradient(150deg, var(--brand-500), var(--brand-700)); color: #fff;
}
.tool-card .ic svg { width: 22px; height: 22px; }
.tool-card h3 { margin: 0 0 5px; font-size: 1.05rem; }
.tool-card p { margin: 0; font-size: .89rem; color: var(--ink-500); line-height: 1.55; }
.tool-card::after {
  content: "→"; position: absolute; top: 22px; right: 22px;
  color: var(--ink-300); font-size: 1.05rem;
  transition: transform .18s var(--ease), color .18s var(--ease);
}
.tool-card:hover::after { color: var(--brand-600); transform: translateX(3px); }

/* ---------------------------------------------------------------- */
/* FAQ                                                               */
/* ---------------------------------------------------------------- */

details.faq { border-bottom: 1px solid var(--line); padding: 2px 0; }
details.faq summary {
  cursor: pointer; padding: 15px 0; font-weight: 650; font-size: .99rem;
  list-style: none; display: flex; justify-content: space-between; gap: 14px;
  align-items: center; color: var(--ink-900);
  transition: color .15s var(--ease);
}
details.faq summary:hover { color: var(--brand-600); }
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after {
  content: "+"; color: var(--brand-600); font-size: 1.4rem; font-weight: 400; flex: none;
  line-height: 1; transition: transform .2s var(--ease);
}
details.faq[open] summary::after { content: "\2212"; transform: rotate(180deg); }
details.faq .a { padding: 0 0 16px; font-size: .93rem; color: var(--ink-700); max-width: 68ch; }
details.faq .a p:last-child { margin-bottom: 0; }

/* ---------------------------------------------------------------- */
/* Ads — reserved boxes so layout never shifts (CLS is money here)    */
/* ---------------------------------------------------------------- */

.ad-slot { margin: 30px 0; text-align: center; overflow: hidden; clear: both; }
.ad-slot::before {
  content: "Advertisement"; display: block; font-size: .64rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--ink-300); margin-bottom: 6px;
}
.ad-slot.empty { display: none; }
.ad-slot ins { display: block; }
.ad-inarticle { min-height: 280px; }
.ad-sidebar { min-height: 600px; margin: 0; }
.ad-placeholder {
  border: 1px dashed var(--line-strong); border-radius: var(--radius);
  display: grid; place-items: center; color: var(--ink-300); font-size: .82rem;
  background: var(--bg-alt); min-height: inherit; padding: 20px;
}

/* ---------------------------------------------------------------- */
/* Drop zones (browser-only tools)                                   */
/* ---------------------------------------------------------------- */

.dropzone {
  border: 2px dashed var(--line-strong); border-radius: var(--radius);
  padding: 40px 20px; text-align: center; background: var(--bg-alt);
  cursor: pointer; transition: border-color .18s var(--ease), background .18s var(--ease);
  display: block;
}
.dropzone:hover, .dropzone.drag { border-color: var(--brand-500); background: var(--brand-050); }
.dropzone .big {
  width: 56px; height: 56px; margin: 0 auto 12px; border-radius: 16px;
  display: grid; place-items: center; color: var(--brand-700);
  background: linear-gradient(150deg, var(--brand-100), var(--brand-050));
  border: 1px solid color-mix(in srgb, var(--brand-400) 28%, transparent);
}
.dropzone .big svg { width: 26px; height: 26px; }
.dropzone h3 { margin: 0 0 5px; font-size: 1.06rem; }
.dropzone p { margin: 0; font-size: .87rem; color: var(--ink-500); }
.dropzone input[type=file] { display: none; }

.file-list { list-style: none; margin: 18px 0 0; padding: 0; }
.file-item {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px;
  border: 1px solid var(--line); border-radius: var(--radius-sm); margin-bottom: 9px;
  background: var(--card); font-size: .9rem; box-shadow: var(--shadow-sm);
}
.file-item .nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-item .sz { color: var(--ink-500); font-size: .82rem; font-variant-numeric: tabular-nums; flex: none; }
.file-item .handle { cursor: grab; color: var(--ink-300); flex: none; user-select: none; }
.icon-btn {
  background: none; border: 0; cursor: pointer; color: var(--ink-400);
  font-size: 1.05rem; line-height: 1; padding: 6px 8px; border-radius: 7px; flex: none;
  transition: background .15s var(--ease), color .15s var(--ease);
}
.icon-btn:hover { background: var(--bg-alt); color: var(--brand-600); }
.icon-btn[data-del]:hover { color: var(--red); }
.icon-btn:disabled { opacity: .3; cursor: not-allowed; }

.progress {
  height: 8px; background: var(--bg-sunk); border-radius: 99px; overflow: hidden; margin: 16px 0;
}
.progress i {
  display: block; height: 100%; width: 0; border-radius: 99px;
  background: linear-gradient(90deg, var(--brand-400), var(--brand-600));
  transition: width .25s var(--ease);
}

.preview-grid { display: grid; gap: 16px; grid-template-columns: 1fr; margin-top: 18px; }
@media (min-width: 620px) { .preview-grid { grid-template-columns: 1fr 1fr; } }
.preview-grid figure { margin: 0; }
.preview-grid img {
  width: 100%; height: auto; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--bg-alt); display: block;
}
.preview-grid figcaption { font-size: .82rem; color: var(--ink-500); margin-top: 8px; }

.privacy-badge {
  display: inline-flex; align-items: center; gap: 8px; font-size: .84rem;
  background: var(--brand-100); color: var(--brand-700); font-weight: 650;
  padding: 8px 14px; border-radius: 99px; margin: 0 0 4px;
}
.privacy-badge svg { width: 15px; height: 15px; flex: none; }

/* ---------------------------------------------------------------- */
/* Payslip                                                           */
/* ---------------------------------------------------------------- */

.payslip {
  background: #fff; color: #111; border: 1px solid #e3e3e3;
  border-radius: var(--radius); padding: 26px; font-size: 14px; box-shadow: var(--shadow);
}
.payslip h2, .payslip h3 { color: #111; }
.payslip-head {
  display: flex; justify-content: space-between; gap: 16px;
  border-bottom: 2px solid #111; padding-bottom: 14px; margin-bottom: 18px; flex-wrap: wrap;
}
.payslip-co { font-size: 1.3rem; font-weight: 800; margin: 0; letter-spacing: -.02em; }
.payslip-meta { font-size: 12px; color: #555; text-align: right; }
.payslip .table-scroll { border: 0; border-radius: 0; margin: 0; background: none; }
.payslip table { min-width: 0; font-size: 13px; }
.payslip th, .payslip td { border-bottom: 1px solid #ececec; padding: 8px 9px; }
.payslip th { background: #f5f5f5; color: #333; position: static; }
.payslip .net-row { background: #eef8f3; font-size: 15px; font-weight: 800; }
.payslip-foot { margin-top: 22px; font-size: 11px; color: #666; border-top: 1px solid #e3e3e3; padding-top: 11px; }
.payslip-sign { display: flex; justify-content: space-between; margin-top: 36px; gap: 24px; }
.payslip-sign div { flex: 1; border-top: 1px solid #999; padding-top: 6px; font-size: 11px; color: #555; text-align: center; }

/* ---------------------------------------------------------------- */
/* Footer                                                            */
/* ---------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, var(--bg-alt), var(--bg-sunk));
  padding: 40px 0 32px; font-size: .88rem; color: var(--ink-500); margin-top: 40px;
}
.footer-grid { display: grid; gap: 26px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.site-footer h4 {
  font-size: .76rem; text-transform: uppercase; letter-spacing: .08em;
  color: var(--ink-700); margin-bottom: 10px;
}
.site-footer a { color: var(--ink-500); text-decoration: none; display: block; padding: 4px 0; }
.site-footer a:hover { color: var(--brand-600); }
.site-footer .brand { margin-bottom: 12px; }
.footer-legal {
  margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--line); font-size: .8rem;
  line-height: 1.6;
}

.disclaimer {
  font-size: .85rem; color: var(--ink-500); background: var(--bg-alt);
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px; margin-top: 26px; line-height: 1.6;
}

.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;
}

/* ---------------------------------------------------------------- */
/* Print — payslip only                                              */
/* ---------------------------------------------------------------- */

@media print {
  .site-header, .site-footer, .ad-slot, .no-print, aside, .breadcrumb { display: none !important; }
  body { background: #fff; font-size: 12pt; }
  main { padding: 0; }
  .layout { grid-template-columns: 1fr; }
  .payslip { border: 0; box-shadow: none; padding: 0; border-radius: 0; }
  a[href]::after { content: ""; }
  @page { margin: 14mm; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
