/* Shared styles for Loonwise calculator hub pages (mortgage/credit-card/loan/gic/insurance). Tokens live in each page :root. */
:root{--brand:#0D5BE1;--brand-dark:#0A46B8;--brand-soft:#E8F0FE;--ink:#0F1B33;--slate:#5C6A85;
    --line:#E2E8F2;--bg:#FFFFFF;--bg-soft:#F3F7FE;--amber:#F78E1E;--amber-soft:#FEF0DD;--navy:#0A1630;
    --green:#1B8A5A;--green-soft:#E3F4EC;
    --radius:14px;--shadow:0 1px 2px rgba(13,27,58,.06),0 10px 30px rgba(13,27,58,.08);--max:1080px;}
  *{box-sizing:border-box;margin:0;padding:0}html{scroll-behavior:smooth}
  body{font-family:'Inter',system-ui,sans-serif;color:var(--ink);background:var(--bg-soft);line-height:1.6;-webkit-font-smoothing:antialiased}
  h1,h2,h3,h4{font-family:'Inter Tight','Manrope','Inter',sans-serif;line-height:1.18;letter-spacing:-.02em}
  a{color:inherit;text-decoration:none}
  .wrap{max-width:var(--max);margin:0 auto;padding:0 24px}
  .btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;font-family:inherit;font-weight:600;font-size:15px;padding:12px 22px;border-radius:8px;border:1px solid transparent;cursor:pointer;transition:.15s}
  .btn-primary{background:var(--brand);color:#fff}.btn-primary:hover{background:var(--brand-dark)}
  .btn-ghost{background:#fff;border:1px solid var(--line);color:var(--ink)}.btn-ghost:hover{border-color:var(--brand);color:var(--brand)}

  /* shared header */
  .promo2{position:sticky;top:0;z-index:60;background:linear-gradient(90deg,#0A1630,#10254C 55%,#143061);color:#fff}
  .promo2 .pwrap2{position:relative;max-width:1120px;margin:0 auto;display:flex;align-items:center;justify-content:center;gap:12px;height:42px;padding:0 46px;font-size:13.5px}
  .promo2 b{color:#FFC069;font-weight:700;white-space:nowrap}
  .promo2 .pmsg2{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;opacity:.95}
  .promo2 .pbtn2{background:#fff;color:#0A1630;font-weight:700;font-size:12.5px;padding:6px 14px;border-radius:8px;flex-shrink:0;transition:.15s}
  .promo2 .pbtn2:hover{background:var(--amber-soft)}
  .promo2 .pclose2{position:absolute;right:6px;top:50%;transform:translateY(-50%);background:none;border:0;color:rgba(255,255,255,.8);font-size:22px;line-height:1;cursor:pointer;padding:4px 10px}
  .promo2 .pclose2:hover{color:#fff}
  @media(max-width:820px){.promo2 .pmsg2{display:none}}
  .hdr2{position:relative;z-index:50;background:#fff;border-bottom:1px solid var(--line)}
  .hdr2 .nav2{max-width:1120px;margin:0 auto;padding:0 24px;display:flex;align-items:center;justify-content:space-between;gap:14px;height:64px}
  .hdr2 .lg2{flex-shrink:1;min-width:0}.hdr2 .lg2 img{height:28px;width:auto;display:block}
  .hdr2 .lnk2{display:flex;gap:22px;font-size:14.5px;font-weight:500;flex-wrap:nowrap}
  .hdr2 .lnk2 a{white-space:nowrap}.hdr2 .lnk2 a:hover{color:var(--brand)}
  .hdr2 .rt2{display:flex;align-items:center;gap:12px;flex-shrink:0}
  .hdr2 .cmp2{display:inline-flex;align-items:center;white-space:nowrap;font-weight:600;font-size:14px;padding:10px 20px;border-radius:999px;background:var(--brand);color:#fff;transition:.15s}
  .hdr2 .cmp2:hover{background:var(--brand-dark)}
.hdr2 .hlink2{font-size:14px;font-weight:600;color:var(--ink);white-space:nowrap;transition:.15s}
.hdr2 .hlink2:hover{color:var(--brand);text-decoration:underline;text-underline-offset:3px}
.hdr2 .lang2{display:inline-flex;align-items:center;gap:7px;font-size:13px;font-weight:700;letter-spacing:.03em;color:var(--ink);background:#fff;border:1px solid var(--line);border-radius:999px;padding:8px 14px;transition:.15s;text-decoration:none}
.hdr2 .lang2 svg{width:18px;height:18px;flex-shrink:0;stroke:currentColor;fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.hdr2 .lang2:hover{border-color:var(--brand);color:var(--brand)}
@media(max-width:560px){.hdr2 .hlink2{display:none}.hdr2 .lang2{padding:8px 11px;gap:5px}}
  .hdr2 .acct2{display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;border-radius:50%;border:1px solid var(--line);background:#fff;color:var(--ink);transition:.15s}
  .hdr2 .acct2:hover{border-color:var(--brand);color:var(--brand)}
  @media(max-width:1180px){.hdr2 .lnk2{display:none}}
  @media(max-width:560px){.hdr2 .cmp2{padding:9px 14px;font-size:13px}.hdr2 .lg2 img{height:24px}}

  /* hero */
  .chero{background:linear-gradient(180deg,#E9F0FF,var(--bg-soft));padding:44px 0 8px;text-align:center}
  .chero .eyebrow{font-size:13px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--brand)}
  .chero h1{font-size:clamp(28px,4.4vw,44px);font-weight:800;margin:8px 0 12px}
  .chero p{color:var(--slate);font-size:clamp(15px,2vw,18px);max-width:620px;margin:0 auto}
  .crumbs{font-size:12.5px;color:var(--slate);margin-bottom:14px}
  .crumbs a{color:var(--brand);font-weight:600}

  /* pill nav */
  .calcnav{position:sticky;top:0;z-index:40;background:rgba(255,255,255,.94);backdrop-filter:blur(8px);border-bottom:1px solid var(--line)}
  .calcnav .row{display:flex;gap:9px;overflow-x:auto;padding:14px 24px;max-width:var(--max);margin:0 auto;scrollbar-width:none}
  .calcnav .row::-webkit-scrollbar{display:none}
  .cpill{display:inline-flex;align-items:center;gap:8px;white-space:nowrap;font-family:inherit;font-weight:600;font-size:14px;color:var(--ink);background:#fff;border:1px solid var(--line);border-radius:999px;padding:10px 17px;cursor:pointer;transition:.15s}
  .cpill:hover{border-color:var(--brand);color:var(--brand)}
  .cpill.active{background:var(--brand);border-color:var(--brand);color:#fff}
  .cpill svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}

  /* calculator panels */
  main{padding:30px 0 10px}
  .panel{display:none}.panel.on{display:block}
  .phead{margin-bottom:18px}
  .phead h2{font-size:clamp(22px,3vw,30px);font-weight:800}
  .phead p{color:var(--slate);font-size:15px;margin-top:6px;max-width:640px}
  .calc{display:grid;grid-template-columns:1fr .92fr;gap:22px;align-items:start}
  .cin{background:#fff;border:1px solid var(--line);border-radius:18px;padding:24px}
  .cout{background:var(--navy);color:#fff;border-radius:18px;padding:26px;position:sticky;top:78px}
  .fld{margin-bottom:16px}
  .fld:last-child{margin-bottom:0}
  .fld label{display:block;font-size:13px;font-weight:600;color:var(--slate);margin-bottom:6px}
  .fld .hint{font-weight:400;color:var(--slate);font-size:11.5px}
  .fld input,.fld select{width:100%;font-family:inherit;font-size:15px;padding:12px 14px;border:1px solid var(--line);border-radius:10px;outline:none;background:#fff;color:var(--ink)}
  .fld input:focus,.fld select:focus{border-color:var(--brand)}
  .fld2{display:grid;grid-template-columns:1fr 1fr;gap:12px}
  .seg{display:flex;gap:6px;flex-wrap:wrap}
  .seg button{font-family:inherit;font-size:13px;font-weight:600;color:var(--slate);background:var(--bg-soft);border:1px solid var(--line);border-radius:9px;padding:9px 13px;cursor:pointer;transition:.12s}
  .seg button.on{background:var(--brand-soft);border-color:var(--brand);color:var(--brand-dark)}
  .cout .lbl{font-size:13px;color:#C2CEE6;text-transform:uppercase;letter-spacing:.05em}
  .cout .big{font-family:'Inter Tight','Manrope';font-size:44px;font-weight:800;line-height:1.05;margin:6px 0 4px}
  .cout .big small{font-size:17px;font-weight:600;color:#C2CEE6}
  .cout .sub{font-size:13px;color:#C2CEE6;margin-bottom:18px}
  .orow{display:flex;justify-content:space-between;gap:12px;font-size:14px;padding:9px 0;border-top:1px solid rgba(255,255,255,.13)}
  .orow span{color:#C2CEE6}.orow b{font-weight:700;text-align:right}
  .orow b.pos{color:#6EE7A8}.orow b.neg{color:#FF9BA6}
  .obadge{display:inline-flex;align-items:center;gap:7px;font-size:12.5px;font-weight:700;border-radius:999px;padding:6px 13px;margin-top:14px}
  .obadge.ok{background:var(--green-soft);color:var(--green)}
  .obadge.no{background:#FCE1E4;color:#B3261E}
  .cout .cta{display:flex;width:100%;justify-content:center;align-items:center;gap:8px;margin-top:20px;background:#fff;color:var(--navy);font-weight:700;font-size:14.5px;padding:12px;border-radius:10px}
  .cout .cta:hover{background:var(--amber-soft)}
  .cnote{font-size:11.5px;color:var(--slate);margin-top:14px;line-height:1.5}

  /* SEO content */
  .seo{background:#fff;border-top:1px solid var(--line);margin-top:36px;padding:48px 0 20px}
  .seo h2{font-size:clamp(22px,3vw,30px);font-weight:800;margin:34px 0 12px}
  .seo h2:first-child{margin-top:0}
  .seo h3{font-size:19px;font-weight:700;margin:22px 0 8px}
  .seo p{color:#33415C;font-size:15.5px;margin-bottom:12px;max-width:760px}
  .seo ul{margin:0 0 14px 20px;color:#33415C;font-size:15.5px}
  .seo li{margin-bottom:6px}
  .seo table{width:100%;border-collapse:collapse;margin:8px 0 18px;font-size:14px}
  .seo th,.seo td{border:1px solid var(--line);padding:9px 12px;text-align:left}
  .seo th{background:var(--bg-soft);font-weight:700}
  .seo .lead{font-size:17px;color:var(--slate);max-width:760px}
  .related{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin:20px 0 8px}
  .related a{display:block;background:var(--bg-soft);border:1px solid var(--line);border-radius:12px;padding:16px;transition:.15s}
  .related a:hover{border-color:var(--brand)}
  .related b{display:block;font-weight:700;color:var(--ink);margin-bottom:2px}
  .related span{font-size:13px;color:var(--slate)}
  .faq{max-width:820px;margin-top:8px}
  .qa{border-bottom:1px solid var(--line)}
  .qa button{width:100%;text-align:left;background:none;border:0;font-family:'Inter Tight','Manrope';font-size:16.5px;font-weight:700;color:var(--ink);padding:16px 0;cursor:pointer;display:flex;justify-content:space-between;gap:14px;align-items:center}
  .qa .ans{display:none;padding:0 0 16px;color:#33415C;font-size:15px}
  .qa.open .ans{display:block}
  .qa .chev{transition:.2s;flex-shrink:0;color:var(--brand)}
  .qa.open .chev{transform:rotate(180deg)}

  footer{border-top:1px solid var(--line);background:#fff;padding:24px 0;font-size:12.5px;color:var(--slate)}
  footer .disc{margin-top:8px;max-width:900px}
  footer a{color:var(--brand);font-weight:600}

  @media(max-width:820px){.calc{grid-template-columns:1fr}.cout{position:static}.related{grid-template-columns:1fr}}

/* best-rates sidebar widget (injected per page) */
.bestrates{grid-column:2;background:#fff;border:1px solid var(--line);border-radius:16px;padding:18px 20px;margin-top:16px}
.bestrates h4{font-family:'Inter Tight','Manrope','Inter',sans-serif;font-size:14.5px;font-weight:800;margin-bottom:2px}
.bestrates .brsub{font-size:11.5px;color:var(--slate);margin-bottom:8px}
.bestrates .brrow{display:flex;justify-content:space-between;gap:10px;font-size:13.5px;padding:8px 0;border-top:1px solid var(--line)}
.bestrates .brrow b{font-family:'Inter Tight','Manrope','Inter',sans-serif;font-weight:800}
.bestrates .btn.btn-primary{width:100%;justify-content:center;margin-top:12px;font-size:14px;padding:11px;text-decoration:none}
.bestrates .brmatch{font-size:11px;color:var(--slate);text-align:center;margin-top:8px}
@media(max-width:820px){.bestrates{grid-column:1}}
