/* newhomewarranty.ca — visual language follows addpersonai.com:
   flat, light, Google-blue accent, 12px cards, Segoe UI system stack. */
:root {
  --ink: #18181b; --ink-2: #35353a; --muted: #57575f; --faint: #626269;
  --line: #e5e5e8; --line-2: #c9c9cf;
  --bg: #f8fafd; --panel: #fff; --soft: #f0f4f9;
  --brand: #0b57d0; --brand-d: #0842a0; --brand-l: #e8f0fe;
  --ok: #137333; --ok-l: #e6f4ea;
  --warn: #8a6100; --warn-bg: #fef7e0;
  --bad: #b3261e; --bad-l: #fce8e6;
  --r: 12px; --r-sm: 8px;
  --font: "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --mono: Consolas, "SFMono-Regular", Menlo, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font: 16px/1.6 var(--font); color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: var(--brand); }
a:hover { color: var(--brand-d); }
img { max-width: 100%; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -0.02em; margin: 0 0 .5em; }
h2 { font-size: 1.4rem; margin-top: 1.6em; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }
.small { font-size: .88rem; }
.mono { font-family: var(--mono); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { max-width: 1440px; margin: 0 auto; padding: 0 48px; }
.wrap-narrow { max-width: 860px; margin: 0 auto; padding: 0 48px; }
@media (max-width: 640px) { .wrap, .wrap-narrow { padding: 0 20px; } }

/* Top bar */
.topbar { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.topbar-row { display: flex; align-items: center; gap: 20px; min-height: 66px; position: relative; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-size: 20px; font-weight: 700; letter-spacing: -0.6px; margin-inline-end: auto; }
.brand:hover { color: var(--ink); }
.brand small { color: var(--brand); font-weight: 600; font-size: 15px; letter-spacing: 0; }
.brand-mark { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 8px; background: var(--brand); color: #fff; }
#primary-nav { display: flex; align-items: center; gap: 4px; }
#primary-nav a { color: var(--ink-2); text-decoration: none; font-size: .95rem; padding: .4em .75em; border-radius: 6px; }
#primary-nav a:hover { background: var(--soft); color: var(--ink); }
#primary-nav a[aria-current="page"] { background: var(--soft); color: var(--ink); font-weight: 600; }
#primary-nav .btn { margin-inline-start: 8px; color: #fff; }
#primary-nav .btn:hover { background: var(--brand-d); color: #fff; }
.nav-toggle { display: none; background: none; border: 1px solid var(--line-2); border-radius: 6px; padding: .4em .7em; font: inherit; cursor: pointer; }
@media (max-width: 860px) {
  .topbar-row { min-height: 60px; }
  .brand { font-size: 17px; }
  .brand small { display: none; }
  .nav-toggle { display: block; }
  #primary-nav { display: none; position: absolute; left: -20px; right: -20px; top: 60px; background: #fff; border-bottom: 1px solid var(--line); flex-direction: column; align-items: stretch; padding: 10px 20px 16px; }
  #primary-nav.open { display: flex; }
  #primary-nav .btn { margin: 6px 0 0; }
}

/* Language menu: a native <details> dropdown, works without JavaScript and on touch screens */
.lang-menu { position: relative; order: 1; }
.lang-menu summary { list-style: none; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; padding: .4em .7em; border: 1px solid var(--line-2); border-radius: 6px; font-size: .9rem; color: var(--ink-2); white-space: nowrap; user-select: none; }
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary:hover, .lang-menu[open] summary { background: var(--soft); color: var(--ink); }
.lang-menu .lang-code { display: none; font-weight: 600; font-size: .8rem; }
.lang-menu ul { position: absolute; inset-inline-end: 0; top: calc(100% + 6px); z-index: 30; list-style: none; margin: 0; padding: 6px; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 10px 30px rgba(35, 57, 90, .14); display: grid; grid-template-columns: repeat(2, minmax(118px, 1fr)); gap: 2px; width: max-content; max-width: calc(100vw - 32px); }
.lang-menu li a { display: block; padding: .45em .75em; border-radius: 6px; color: var(--ink-2); text-decoration: none; font-size: .92rem; text-align: start; }
.lang-menu li a:hover { background: var(--soft); color: var(--ink); }
.lang-menu li a[aria-current] { background: var(--brand-l); color: var(--brand); font-weight: 600; }
@media (max-width: 860px) { .topbar-row { gap: 10px; } }
@media (max-width: 520px) {
  /* A long translated "Menu" label must not push the row wider than the screen */
  .brand { min-width: 0; }
  .brand > span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  /* The brand name absorbs the squeeze (it ellipsizes); the menu button keeps its label unless it is longer than 34vw */
  .nav-toggle { max-width: 34vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex-shrink: 0; }
  .lang-menu { flex-shrink: 0; }
  .lang-menu .lang-name { display: none; }
  .lang-menu .lang-code { display: inline; }
}
.mt-notice { background: #fff; border: 1px solid var(--line); border-radius: var(--r-sm); padding: .6em .8em; color: var(--muted); }
.english-note { margin: 0 0 14px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .45em; border: 1px solid var(--brand); background: var(--brand); color: #fff; font: 600 .95rem/1 var(--font); padding: .75em 1.25em; border-radius: 6px; cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { background: var(--brand-d); border-color: var(--brand-d); color: #fff; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn-outline { background: #fff; color: var(--ink); border-color: var(--line-2); }
.btn-outline:hover { background: var(--soft); border-color: var(--faint); color: var(--ink); }
.btn-danger { background: #fff; color: var(--bad); border-color: var(--line-2); }
.btn-danger:hover { background: var(--bad-l); border-color: var(--bad); color: var(--bad); }
.btn-lg { padding: .9em 1.5em; font-size: 16px; }
.btn-sm { padding: .55em .95em; font-size: 14px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* Hero */
.hero { padding: 56px 0 24px; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 700; letter-spacing: .11em; text-transform: uppercase; color: var(--brand); margin: 0 0 14px; }
.eyebrow::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--brand); }
.hero h1 { font-size: clamp(32px, 4vw, 54px); line-height: 1.1; letter-spacing: -0.045em; font-weight: 700; max-width: 900px; margin: 0 0 16px; }
.hero h1 .accent { color: var(--brand); }
.lead { font-size: 18px; line-height: 1.6; color: #444746; max-width: 760px; margin-bottom: 18px; }
.hero-points { display: flex; flex-wrap: wrap; gap: 8px 22px; list-style: none; padding: 0; margin: 0 0 22px; color: var(--ink-2); font-size: 13.5px; }
.hero-points li { display: flex; align-items: center; gap: 6px; }
.hero-points .ic { color: var(--ok); font-weight: 700; }
@media (max-width: 640px) { .hero { padding: 36px 0 16px; } .lead { font-size: 16.5px; } }

/* Panels and cards */
.tool { background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 6px 24px rgba(35, 57, 90, .08); overflow: hidden; }
.tool-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 14px 22px; border-bottom: 1px solid var(--line); }
.tool-head h2 { margin: 0; font-size: 1.05rem; }
.tool-grid { display: grid; grid-template-columns: 360px 1fr; }
.panel { padding: 20px 22px; }
.panel-input { border-inline-end: 1px solid var(--line); }
.panel-preview { background: var(--bg); min-height: 260px; }
@media (max-width: 900px) {
  .tool-grid { grid-template-columns: 1fr; }
  .panel-input { border-inline-end: 0; border-bottom: 1px solid var(--line); }
}
@media (max-width: 640px) { .panel, .tool-head { padding: 14px; } }

.card { display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 1em 1.15em; color: var(--ink); text-decoration: none; }
a.card:hover { border-color: var(--brand); color: var(--ink); }
.card strong { display: block; margin-bottom: 2px; }
.card .muted { font-size: .88rem; line-height: 1.45; display: block; }
.cards { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }

.section { padding: 32px 0 8px; }
.section > h2:first-child, .section-head h2 { margin-top: 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }

.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); counter-reset: step; }
.steps li { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 1em 1.15em; counter-increment: step; }
.steps li::before { content: counter(step); display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--brand-l); color: var(--brand); font-weight: 700; font-size: .85rem; margin-bottom: 8px; }
.steps strong { display: block; }
.steps span { color: var(--muted); font-size: .9rem; }

/* Forms */
.field { margin-bottom: 12px; min-width: 0; }
.field label, .field .label { display: block; font-weight: 600; font-size: .86rem; margin-bottom: 4px; color: var(--ink-2); }
.field .hint { font-size: .8rem; color: var(--muted); margin-top: 3px; }
input[type="text"], input[type="date"], input[type="number"], input:not([type]), select, textarea {
  width: 100%; font: inherit; font-size: .95rem; color: var(--ink); background: #fff;
  border: 1px solid var(--line-2); border-radius: var(--r-sm); padding: .55em .7em;
}
textarea { resize: vertical; min-height: 4.5em; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-l); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
@media (max-width: 520px) { .row2 { grid-template-columns: 1fr; } }
.check { display: flex; gap: 8px; align-items: flex-start; font-size: .9rem; color: var(--ink-2); margin-bottom: 12px; }
.check input { margin-top: .3em; accent-color: var(--brand); }

/* Pills, badges, alerts */
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: .78rem; font-weight: 600; border-radius: 999px; padding: .3em .75em; white-space: nowrap; }
.pill-ok { color: var(--ok); background: var(--ok-l); }
.pill-warn { color: var(--warn); background: var(--warn-bg); }
.pill-bad { color: var(--bad); background: var(--bad-l); }
.pill-info { color: var(--brand); background: var(--brand-l); }
.pill-muted { color: var(--faint); background: var(--soft); }
.alert { border-radius: var(--r-sm); padding: .7em .9em; font-size: .9rem; margin-bottom: 12px; }
.alert-bad { background: var(--bad-l); color: var(--bad); }
.alert-ok { background: var(--ok-l); color: var(--ok); }
.alert-warn { background: var(--warn-bg); color: var(--warn); }
.alert-info { background: var(--brand-l); color: var(--brand-d); }
.warnings { list-style: none; padding: 0; margin: 0 0 12px; }
.warnings li { font-size: .86rem; background: var(--warn-bg); color: var(--warn); border-radius: 6px; padding: .45em .7em; margin-bottom: 6px; }

/* Deadline timeline */
.windows { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.win { background: #fff; border: 1px solid var(--line); border-inline-start: 4px solid var(--line-2); border-radius: var(--r-sm); padding: .85em 1em; }
.win-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.win-head h3 { margin: 0; font-size: 1rem; }
.win-dates { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: .9rem; margin-top: 4px; }
.win-dates b { font-variant-numeric: tabular-nums; }
.win-days { font-size: 1.6rem; font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; line-height: 1; }
.win-days small { font-size: .8rem; font-weight: 600; color: var(--muted); letter-spacing: 0; margin-inline-start: 4px; }
.win p { font-size: .86rem; color: var(--muted); margin: 6px 0 0; }
.win.s-normal { border-inline-start-color: var(--ok); }
.win.s-reminder { border-inline-start-color: #e0a100; }
.win.s-urgent { border-inline-start-color: var(--bad); background: #fffafa; }
.win.s-urgent .win-days { color: var(--bad); }
.win.s-closed { border-inline-start-color: var(--line-2); background: var(--soft); }
.win.s-closed h3, .win.s-closed .win-dates { color: var(--faint); }
.win.s-notopen { border-inline-start-color: var(--brand); }
.empty { display: grid; place-items: center; text-align: center; color: var(--muted); min-height: 220px; font-size: .95rem; }
.empty .big { font-size: 2.6rem; margin-bottom: 6px; }

/* Stats */
.stats { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 1em 1.15em; }
.stat b { display: block; font-size: 1.9rem; letter-spacing: -0.04em; line-height: 1.1; color: var(--brand); }
.stat span { font-size: .88rem; color: var(--muted); }

/* Tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: .92rem; }
th, td { text-align: start; padding: .7em 1em; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--faint); background: var(--soft); font-weight: 700; }
tr:last-child td { border-bottom: 0; }

/* Defect list */
.defects { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.defect { background: #fff; border: 1px solid var(--line); border-radius: var(--r-sm); padding: .75em .9em; display: flex; gap: 12px; justify-content: space-between; align-items: flex-start; }
.defect-main { min-width: 0; }
.defect-main strong { display: block; }
.defect-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.group-h { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); font-weight: 700; margin: 16px 0 8px; }
.group-h:first-child { margin-top: 0; }

/* Access code box */
.code-box { background: var(--soft); border: 1px dashed var(--line-2); border-radius: var(--r-sm); padding: .7em .9em; font-family: var(--mono); font-size: .88rem; word-break: break-all; }

/* Price card */
.price-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 24px; box-shadow: 0 6px 24px rgba(35, 57, 90, .08); }
.price-card.featured { border-color: var(--brand); }
.price { font-size: 2.6rem; font-weight: 700; letter-spacing: -0.04em; line-height: 1; margin: 8px 0 4px; }
.price small { font-size: .95rem; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.ticks { list-style: none; padding: 0; margin: 16px 0; }
.ticks li { padding-block: .3em; padding-inline: 1.6em 0; position: relative; font-size: .95rem; }
.ticks li::before { content: "✓"; position: absolute; inset-inline-start: 0; color: var(--ok); font-weight: 700; }
.ticks.no li::before { content: "✕"; color: var(--faint); }
.price-grid { display: grid; gap: 16px; grid-template-columns: 1fr 1fr; align-items: start; }
@media (max-width: 760px) { .price-grid { grid-template-columns: 1fr; } }

/* FAQ */
.faq details { border: 1px solid var(--line); background: #fff; border-radius: 12px; padding: .85em 1.1em; margin-bottom: 8px; }
.faq summary { cursor: pointer; font-weight: 600; }
.faq details p { margin: .6em 0 0; color: var(--ink-2); }

/* Article */
.article { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 28px 32px; }
.article p { color: var(--ink-2); font-size: 1.02rem; }
.article ul { padding-inline-start: 1.2em; color: var(--ink-2); }
.article li { margin-bottom: .4em; }
.crumbs { font-size: .88rem; margin-bottom: 14px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--brand); }
@media (max-width: 640px) { .article { padding: 20px; } }

.cta-band { background: var(--brand-l); border-radius: 14px; padding: 28px 32px; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 32px; }
.cta-band h2 { margin: 0 0 4px; font-size: 1.3rem; }
.cta-band p { margin: 0; color: var(--ink-2); }

/* Footer */
.footer { background: var(--soft); border-top: 1px solid var(--line); padding: 48px 0 36px; margin-top: 56px; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 28px; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-brand { font-weight: 700; font-size: 18px; letter-spacing: -0.4px; margin-bottom: .3em; }
.footer-h { font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); margin-bottom: 12px; }
.footer-col a { display: block; color: var(--muted); text-decoration: none; font-size: 14.5px; padding: 3px 0; }
.footer-col a:hover { color: var(--ink); }
.footer .fine { border-top: 1px solid var(--line); padding-top: 20px; color: var(--faint); font-size: 13px; }
.footer .fine p { margin: 0 0 .5em; }

/* Translated pages: long words and labels must wrap instead of widening the page */
h1, h2, h3, p, li, summary { overflow-wrap: break-word; }
@media (max-width: 640px) {
  .btn { white-space: normal; text-align: center; line-height: 1.25; }
  .pill { white-space: normal; }
}

/* Right-to-left (ar, fa, ur). Layout uses logical properties; these are the few extras. */
[dir="rtl"] .arrow { display: inline-block; transform: scaleX(-1); }
[dir="rtl"] .footer-col a, [dir="rtl"] .card { text-align: start; }
[dir="rtl"] body { font-family: "Segoe UI", Tahoma, "Noto Sans Arabic", system-ui, sans-serif; }
:lang(ur) body { font-family: "Segoe UI", "Noto Nastaliq Urdu", "Urdu Typesetting", Tahoma, system-ui, sans-serif; line-height: 1.85; }
/* Tight negative tracking breaks joined (Arabic) and stacked (Indic) scripts and crowds CJK */
html:is(:lang(ar), :lang(fa), :lang(ur), :lang(hi), :lang(pa), :lang(ta), :lang(zh), :lang(ko)) * { letter-spacing: 0 !important; }

/* Print: the claim pack page prints as a clean PDF */
@media print {
  .topbar, .footer, .no-print { display: none !important; }
  body { background: #fff; }
  .article, .tool, .card, .win { box-shadow: none; }
  .wrap, .wrap-narrow { padding: 0; max-width: none; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* Home photography and responsive editorial layout. */
.home-hero { background: #eef3f0; padding: 64px 0 84px; }
.home-hero > .wrap { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.home-hero h1 { font-size: clamp(2.2rem, 3.8vw, 3.8rem); line-height: 1.08; max-width: 720px; letter-spacing: -.045em; }
.home-hero .accent { color: #235e50; }
.home-hero .lead { font-size: 1.05rem; max-width: 620px; color: #46544e; }
.hero-photo { margin: 0; position: relative; }
.hero-photo img { display: block; width: 100%; height: 540px; object-fit: cover; border-radius: 24px; border-end-end-radius: 80px; }
.hero-photo figcaption { position: absolute; bottom: 24px; left: 24px; right: 24px; padding: 16px 20px; background: #fffffff0; border-radius: 12px; color: #25483d; font-size: .95rem; }
.home-hero .hero-points { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 24px 0; }
.home-hero .ic { color: #235e50; }
.home-hero .btn { background: #235e50; border-color: #235e50; }
.home-hero .btn-outline { background: transparent; color: #235e50; }
.home-hero .btn:hover { background: #174638; color: white; }
#checker { scroll-margin-top: 85px; }
#checker .tool { box-shadow: 0 12px 44px #203a2810; border-radius: 20px; overflow: hidden; }
.process-photo { margin: 24px 0; }
.process-photo img { width: 100%; height: 320px; object-fit: cover; border-radius: 20px; display: block; }
@media (max-width: 960px) {
 .home-hero > .wrap { grid-template-columns: 1fr; gap: 32px; }
 .hero-photo img { height: 380px; }
 .home-hero { padding: 40px 0; }
}
@media (max-width: 540px) {
 .home-hero .hero-points { grid-template-columns: 1fr; }
 .hero-photo img { height: 300px; border-radius: 18px; }
 .hero-photo figcaption { left: 14px; right: 14px; bottom: 14px; font-size: .85rem; }
 .process-photo img { height: 230px; }
}

/* Sister-site cross-promotion (Cluster A): result-page box and footer line. Same look on all three sites. */
.related-tools { margin: 32px 0; padding: 20px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg); text-align: start; }
.related-tools h2 { margin: 0 0 8px; font-size: 20px; line-height: 1.3; }
.related-tools-lead { margin: 0 0 16px; color: var(--muted); }
.related-tools-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.related-tools-card { min-width: 0; padding: 16px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--panel); }
.related-tools-card h3 { margin: 0 0 4px; font-size: 17px; line-height: 1.35; overflow-wrap: anywhere; }
.related-tools-card p { margin: 0; color: var(--muted); }
.more-tools { margin: 0 0 20px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 14px; line-height: 1.6; color: var(--muted); }
.more-tools p { margin: 0 0 6px; }
.more-tools .more-tools-h { margin-bottom: 8px; }
.more-tools strong { color: var(--ink); }
.more-tools a { overflow-wrap: anywhere; }
@media print { .related-tools, .more-tools { display: none !important; } }
