/* GasBillCheck.pk — single stylesheet, mobile-first */
:root {
  --green: #176B3A;
  --green-dark: #0F4F2A;
  --green-light: #EAF5ED;
  --bg: #FFFFFF;
  --text: #263238;
  --muted: #64748B;
  --border: #D9E2DC;
  --surface: #F7FAF8;
  --warn-bg: #FFF7E6;
  --warn-border: #F0C36D;
  --error: #B42318;
  --error-bg: #FEF3F2;
  --focus: #1D4ED8;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .06), 0 1px 3px rgba(16, 24, 40, .08);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  --max: 1120px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
}
img, svg { max-width: 100%; height: auto; }
a { color: var(--green); text-underline-offset: 2px; }
a:hover { color: var(--green-dark); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { line-height: 1.25; color: #17252b; }
h1 { font-size: clamp(1.6rem, 4.5vw, 2.4rem); margin: .25rem 0 1rem; letter-spacing: -.01em; }
h2 { font-size: clamp(1.3rem, 3vw, 1.65rem); margin: 2.25rem 0 .75rem; }
h3 { font-size: 1.12rem; margin: 1.5rem 0 .5rem; }
p, ul, ol { margin: 0 0 1rem; }
ul, ol { padding-left: 1.3rem; }
li { margin-bottom: .35rem; }
small, .muted { color: var(--muted); }
.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 16px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 8px; top: -60px; background: var(--green); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { top: 8px; color: #fff; }

/* Notice bar */
.notice-bar { background: var(--green-light); color: var(--green-dark); font-size: .85rem; text-align: center; padding: 6px 16px; line-height: 1.4; }

/* Header */
.site-header { background: #fff; border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 50; }
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 60px; gap: 12px; }
.brand { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--green-dark); font-weight: 800; font-size: 1.15rem; }
.brand svg { width: 30px; height: 30px; flex: none; }
.brand span b { color: var(--green); }
.nav-toggle { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 1px solid var(--border); background: #fff; border-radius: 10px; cursor: pointer; color: var(--text); }
.nav-toggle svg { width: 22px; height: 22px; }
.site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--border); box-shadow: var(--shadow); }
.site-nav.open { display: block; }
.site-nav ul { list-style: none; margin: 0; padding: 8px 16px 12px; }
.site-nav li { margin: 0; }
.site-nav a { display: block; padding: 11px 8px; text-decoration: none; color: var(--text); font-weight: 600; border-radius: 8px; }
.site-nav a:hover, .site-nav a[aria-current="page"] { background: var(--green-light); color: var(--green-dark); }
@media (min-width: 900px) {
  .nav-toggle { display: none; }
  .site-nav { display: block; position: static; border: 0; box-shadow: none; }
  .site-nav ul { display: flex; gap: 2px; padding: 0; }
  .site-nav a { padding: 8px 11px; font-size: .95rem; }
}

/* Breadcrumbs */
.breadcrumbs { font-size: .88rem; color: var(--muted); padding: 14px 0 0; }
.breadcrumbs ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 4px; }
.breadcrumbs li { margin: 0; }
.breadcrumbs li + li::before { content: "›"; margin: 0 6px 0 2px; color: #9aa7b4; }
.breadcrumbs a { color: var(--muted); }

/* Layout */
main { padding-bottom: 40px; }
.page-intro { max-width: 760px; }
.lead { font-size: 1.08rem; color: #3d4b53; }
.content { max-width: 780px; }
.content-wide { max-width: var(--max); }
.updated { font-size: .85rem; color: var(--muted); margin-bottom: 1.25rem; }

/* Hero */
.hero { background: linear-gradient(180deg, var(--green-light), #fff); border-bottom: 1px solid var(--border); padding: 28px 0 32px; margin-bottom: 8px; }
.hero h1 { margin-top: 0; }

/* Cards & grids */
.grid { display: grid; gap: 16px; }
@media (min-width: 720px) { .grid-2 { grid-template-columns: 1fr 1fr; } .grid-3 { grid-template-columns: repeat(3, 1fr); } }
.card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card h2, .card h3 { margin-top: 0; }
.card-link { display: block; text-decoration: none; color: inherit; transition: border-color .15s; }
.card-link:hover { border-color: var(--green); color: inherit; }
.card-link h3 { color: var(--green-dark); margin-bottom: .35rem; }
.card-link p { margin: 0; color: var(--muted); font-size: .95rem; }
.icon { width: 24px; height: 24px; flex: none; }
.card-icon { display: inline-flex; width: 42px; height: 42px; border-radius: 10px; background: var(--green-light); color: var(--green); align-items: center; justify-content: center; margin-bottom: 10px; }
.card h3 > .icon { vertical-align: -5px; color: var(--green); margin-right: 4px; }
.tag { display: inline-block; font-size: .75rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; color: var(--green-dark); background: var(--green-light); padding: 2px 8px; border-radius: 999px; }

/* Checker */
.checker { border-top: 4px solid var(--green); }
.checker .company { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.checker .company h2, .checker .company h3 { margin: 0; font-size: 1.2rem; }
.checker .regions { color: var(--muted); font-size: .9rem; margin-bottom: 14px; }
.field { margin-bottom: 14px; }
.field label, .field .label { display: block; font-weight: 600; margin-bottom: 6px; }
.field .hint { display: block; font-size: .85rem; color: var(--muted); margin-top: 4px; }
input[type="text"], input[type="number"], input[type="email"], input[type="date"], select, textarea {
  width: 100%; font: inherit; color: var(--text); background: #fff; border: 1.5px solid #B8C4BD; border-radius: 10px; padding: 11px 12px; min-height: 46px;
}
textarea { min-height: 120px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--green); outline: 3px solid rgba(23, 107, 58, .25); outline-offset: 0; }
input[aria-invalid="true"] { border-color: var(--error); background: var(--error-bg); }
.input-number { font-size: 1.2rem; letter-spacing: .08em; font-variant-numeric: tabular-nums; }
.digit-count { font-size: .85rem; color: var(--muted); float: right; font-weight: 500; }
.error-msg { color: var(--error); font-size: .9rem; margin-top: 6px; min-height: 0; }
.error-msg:empty { display: none; }
.success-box { background: var(--green-light); border: 1px solid #b9dcc5; border-radius: 10px; padding: 14px; margin-top: 12px; }
.success-box[hidden] { display: none; }
.success-box p { margin-bottom: .6rem; }
.success-box ol { margin-bottom: .75rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 18px; border-radius: 10px; font: inherit; font-weight: 700; cursor: pointer; text-decoration: none; border: 2px solid var(--green); background: var(--green); color: #fff; line-height: 1.2;
}
.btn:hover { background: var(--green-dark); border-color: var(--green-dark); color: #fff; }
.btn-outline { background: #fff; color: var(--green); }
.btn-outline:hover { background: var(--green-light); color: var(--green-dark); }
.btn svg { width: 18px; height: 18px; }
.btn-block { width: 100%; }
.official-link { font-size: .9rem; margin-top: 12px; }
.ext::after { content: " ↗"; }

/* Live SNGPL form */
.captcha-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.captcha-box { width: 170px; height: 52px; border: 1.5px dashed #B8C4BD; border-radius: 10px; display: flex; align-items: center; justify-content: center; background: #fff; overflow: hidden; flex: none; }
.captcha-box img { display: block; width: 150px; height: 40px; object-fit: contain; }
.captcha-box img[hidden] { display: none; }
.captcha-box span { font-size: .78rem; color: var(--muted); text-align: center; padding: 0 6px; line-height: 1.3; }
.btn-icon { min-width: 46px; padding: 8px 12px; font-size: 1.2rem; }
.linklike { background: none; border: 0; padding: 0; font: inherit; color: var(--green); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.btn[disabled] { opacity: .7; cursor: progress; }
.bill-dialog { width: min(980px, calc(100% - 16px)); height: min(92vh, 1200px); max-width: none; max-height: none; padding: 0; border: 0; border-radius: 14px; box-shadow: 0 20px 60px rgba(0,0,0,.35); }
.bill-dialog[open] { display: flex; flex-direction: column; }
.bill-dialog::backdrop { background: rgba(15, 42, 27, .55); }
.bill-dialog-bar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; padding: 12px 16px; border-bottom: 1px solid var(--border); background: var(--green-light); }
.bill-dialog-bar h2 { margin: 0; font-size: 1.15rem; }
.bill-source { margin: 0; padding: 6px 16px; font-size: .8rem; color: var(--muted); border-bottom: 1px solid var(--border); }
.bill-dialog iframe { flex: 1; width: 100%; border: 0; background: #fff; }

/* Exit page */
.go-card { margin: 20px 0; border-top: 4px solid var(--green); }
.go-dest { margin-bottom: 12px; word-break: break-all; }
.go-url { font-size: .85rem; }
.go-progress { height: 8px; border-radius: 999px; background: var(--green-light); overflow: hidden; margin-bottom: 10px; }
.go-progress span { display: block; height: 100%; width: 0; background: var(--green); transition: width 1s linear; }
.go-timer { font-weight: 600; }
.btn[aria-disabled="true"] { background: #9fb3a7; border-color: #9fb3a7; cursor: not-allowed; }

/* Notes */
.note { background: var(--surface); border-left: 4px solid var(--green); padding: 12px 16px; border-radius: 0 10px 10px 0; margin: 1.25rem 0; }
.note p:last-child { margin-bottom: 0; }
.warn { background: var(--warn-bg); border-left-color: var(--warn-border); }
.disclaimer-box { background: var(--warn-bg); border: 1px solid var(--warn-border); border-radius: 10px; padding: 12px 16px; font-size: .92rem; margin: 1.25rem 0; }

/* Steps */
.steps { counter-reset: step; list-style: none; padding: 0; }
.steps > li { counter-increment: step; position: relative; padding-left: 44px; margin-bottom: 14px; }
.steps > li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 30px; height: 30px; border-radius: 50%; background: var(--green); color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center; font-size: .9rem; }

/* Tables */
.table-wrap { overflow-x: auto; margin: 1rem 0 1.25rem; border: 1px solid var(--border); border-radius: 10px; }
table { border-collapse: collapse; width: 100%; font-size: .95rem; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
thead th { background: var(--green-light); color: var(--green-dark); font-weight: 700; white-space: nowrap; }
tbody tr:last-child td, tbody tr:last-child th { border-bottom: 0; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
tr.is-current td, tr.is-current th { background: #FFF4CC; font-weight: 700; }
caption { caption-side: bottom; text-align: left; padding: 8px 12px; font-size: .85rem; color: var(--muted); }

/* Tools */
.tool { border-top: 4px solid var(--green); }
.tool-grid { display: grid; gap: 0 16px; }
@media (min-width: 640px) { .tool-grid { grid-template-columns: 1fr 1fr; } }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.tabs button { font: inherit; font-weight: 600; padding: 8px 14px; min-height: 42px; border-radius: 999px; border: 1.5px solid var(--border); background: #fff; color: var(--text); cursor: pointer; }
.tabs button[aria-selected="true"] { background: var(--green); border-color: var(--green); color: #fff; }
.result { margin-top: 16px; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); padding: 16px; }
.result[hidden] { display: none; }
.result-total { font-size: 1.6rem; font-weight: 800; color: var(--green-dark); margin: 0 0 .25rem; font-variant-numeric: tabular-nums; }
.result dl { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; margin: 12px 0 0; }
.result dt { color: #3d4b53; }
.result dd { margin: 0; text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.result dt.total, .result dd.total { border-top: 1px solid var(--border); padding-top: 8px; font-weight: 800; }
.explain { font-size: .9rem; color: #3d4b53; margin-top: 12px; }
.explain summary { cursor: pointer; font-weight: 600; color: var(--green-dark); }
.appliance-row { display: grid; grid-template-columns: 1fr; gap: 8px; padding: 12px; border: 1px solid var(--border); border-radius: 10px; margin-bottom: 10px; background: #fff; }
@media (min-width: 640px) { .appliance-row { grid-template-columns: 2fr 1fr 1fr 1fr; align-items: end; } }
.appliance-row label { font-size: .85rem; font-weight: 600; display: block; margin-bottom: 4px; }
.check { display: flex; gap: 8px; align-items: flex-start; font-weight: 500; }
.check input { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--green); }

/* FAQ */
.faq { border: 1px solid var(--border); border-radius: 10px; margin-bottom: 10px; background: #fff; }
.faq summary { cursor: pointer; padding: 14px 16px; font-weight: 700; list-style: none; position: relative; padding-right: 44px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 16px; top: 10px; font-size: 1.4rem; color: var(--green); font-weight: 400; }
.faq[open] summary::after { content: "−"; }
.faq .faq-a { padding: 0 16px 6px; }

/* Ads — clearly labelled, never inside tools */
.ad-slot { margin: 28px auto; padding: 8px 0 4px; border-top: 1px dashed #cbd5d0; border-bottom: 1px dashed #cbd5d0; text-align: center; min-height: 120px; max-width: 780px; clear: both; }
.ad-slot[hidden] { display: none; }
.ad-label { display: block; font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; color: #8a97a3; margin-bottom: 4px; }
.ad-slot ins { display: block; }

/* Related */
.related { margin-top: 2.5rem; }
.related ul { list-style: none; padding: 0; display: grid; gap: 8px; }
@media (min-width: 640px) { .related ul { grid-template-columns: 1fr 1fr; } }
.related a { display: block; padding: 10px 14px; border: 1px solid var(--border); border-radius: 10px; text-decoration: none; font-weight: 600; }
.related a:hover { border-color: var(--green); background: var(--green-light); }

/* Footer */
.site-footer { background: #0F2A1B; color: #CFE3D6; margin-top: 40px; padding: 36px 0 20px; font-size: .93rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.footer-grid { display: grid; gap: 24px; grid-template-columns: 1fr 1fr; }
@media (min-width: 900px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr 1fr; } }
.footer-grid .about { grid-column: 1 / -1; }
@media (min-width: 900px) { .footer-grid .about { grid-column: auto; } }
.site-footer h2 { color: #fff; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; margin: 0 0 10px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 7px; }
.footer-bottom { border-top: 1px solid #24503a; margin-top: 28px; padding-top: 16px; font-size: .85rem; color: #A9C7B4; }
.footer-bottom p { margin: 0 0 6px; }

/* 404 */
.error-page { text-align: center; padding: 48px 0; }
.error-page .code { font-size: 4rem; font-weight: 800; color: var(--green); margin: 0; line-height: 1; }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); background: #17252b; color: #fff; padding: 10px 16px; border-radius: 10px; font-size: .92rem; z-index: 200; max-width: calc(100% - 32px); }
.toast[hidden] { display: none; }

@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
@media print {
  .site-header, .notice-bar, .site-footer, .ad-slot, .nav-toggle, .related, .breadcrumbs { display: none !important; }
  body { font-size: 12pt; }
  a { color: #000; }
}
