/* John Antle Mortgages, mortgage-alberta.com: shared stylesheet v6 (v2 layout; mobile-first, system fonts, no JS, no framework) */
:root{
  --navy:#0f2a43; --teal:#0d7c74; --teal-dark:#09605a; --gold:#f2b632; --pineapple:#036fa0;
  --ink:#1d2731; --muted:#4f5d6b; --line:#e1e8ee; --soft:#f5f8fa; --radius:14px; --max:1120px;
  --font:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif;
}
*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%;scroll-behavior:smooth}
@media (prefers-reduced-motion:reduce){html{scroll-behavior:auto}}
body{margin:0;font-family:var(--font);font-size:1.0625rem;line-height:1.7;color:var(--ink);background:#fff}
img,svg{max-width:100%;height:auto}
a{color:var(--teal-dark);text-underline-offset:3px}
a:hover{color:var(--navy)}
:focus-visible{outline:3px solid var(--gold);outline-offset:2px}
h1,h2,h3{line-height:1.2;color:var(--navy);margin:0 0 .5em;letter-spacing:-.01em}
h1{font-size:clamp(2rem,5.2vw,3.1rem);font-weight:800}
h2{font-size:clamp(1.5rem,3.2vw,2rem);font-weight:750}
h3{font-size:1.15rem}
p,ul,ol{margin:0 0 1em}
.wrap{max-width:var(--max);margin:0 auto;padding:0 1.25rem}
.narrow>*{max-width:46rem}
.skip{position:absolute;left:-999px;top:0;background:var(--gold);color:var(--navy);padding:.6rem 1rem;z-index:100;font-weight:700}
.skip:focus{left:0}
.visually-hidden{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.icon{width:18px;height:18px;flex:none}

/* Header: brand, 5 links, one Call button */
.hd{background:#fff;border-bottom:1px solid var(--line)}
.hd-in{display:flex;align-items:center;flex-wrap:wrap;gap:.35rem .75rem;padding-top:.6rem;padding-bottom:.6rem}
.brand{display:flex;align-items:center;gap:.6rem;text-decoration:none;color:var(--navy);margin-right:auto}
.brand svg{width:36px;height:36px;flex:none}
.brand{min-width:0}
.brand-text{display:flex;flex-direction:column;line-height:1.2}
.brand-name{font-weight:800;font-size:1.05rem}
.brand-sub{font-size:.76rem;color:var(--muted);font-weight:600}
.nav{order:3;width:100%}
.nav ul{list-style:none;margin:0 -.25rem;padding:0;display:flex;justify-content:space-between;gap:0;overflow-x:auto}
.nav a{display:block;padding:.5rem .15rem;color:var(--ink);text-decoration:none;font-weight:600;font-size:clamp(.7rem,3.15vw,.86rem);border-radius:8px;white-space:nowrap}
.nav a:hover,.nav a[aria-current="page"]{color:var(--teal-dark);background:var(--soft)}
.btn-call{background:var(--navy);color:#fff;min-height:44px;padding:.5rem .9rem;border-radius:999px}
.btn-call:hover{background:var(--teal-dark);color:#fff}
.call-long{display:none}
@media (min-width:900px){
  .nav{order:0;width:auto}
  .nav ul{gap:.35rem}
  .nav ul{margin:0;overflow:visible}
  .nav a{padding:.5rem .7rem;font-size:.97rem}
  .brand svg{width:40px;height:40px}.brand-sub{font-size:.8rem}
  .call-long{display:inline}.call-short{display:none}
  .hd{position:sticky;top:0;z-index:50}
}

/* Buttons */
.btns{display:flex;flex-wrap:wrap;gap:.75rem;margin:1.5rem 0 1rem}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:.5rem;min-height:50px;padding:.75rem 1.35rem;border-radius:999px;font-weight:700;text-decoration:none;border:2px solid transparent;font-size:1rem;line-height:1.2}
.btn-primary{background:var(--teal-dark);color:#fff}
.btn-primary:hover{background:var(--navy);color:#fff}
.btn-ghost{border-color:var(--navy);color:var(--navy);background:#fff}
.btn-ghost:hover{background:var(--soft);color:var(--navy)}
.btn-ghost-light{border-color:#fff;color:#fff;background:transparent}
.btn-ghost-light:hover{background:rgba(255,255,255,.12);color:#fff}
.btn-block{display:flex;width:100%;margin-top:.6rem}

/* Hero: one headline, one sentence, two buttons */
.hero{background:linear-gradient(180deg,#eef5f8 0%,#fff 100%);padding:2.75rem 0 2.5rem}
.hero-in{display:grid;gap:2rem;align-items:center}
.hero-lead{font-size:clamp(1.1rem,2.2vw,1.3rem);color:var(--muted);max-width:36rem}
.hero-trust{font-size:.9rem;color:var(--muted);margin:0}
.hero-art{display:none}
@media (min-width:900px){.hero{padding:4.5rem 0 4rem}.hero-in{grid-template-columns:1.25fr 1fr}.hero-art{display:block;width:100%;max-width:440px;justify-self:end}}

/* Sections */
.sec{padding:3rem 0}
@media (min-width:900px){.sec{padding:3.75rem 0}}
.sec-soft{background:var(--soft)}
.sec-head{display:flex;flex-wrap:wrap;align-items:baseline;justify-content:space-between;gap:.25rem 1rem;margin-bottom:1.5rem}
.sec-head h2{margin:0}
.more-link{margin:0;font-weight:700}
.link-strong{font-weight:700}

/* 3 steps */
.steps3{list-style:none;margin:0;padding:0;display:grid;gap:1.5rem}
@media (min-width:760px){.steps3{grid-template-columns:repeat(3,1fr);gap:2rem}}
.steps3 .n{display:flex;align-items:center;justify-content:center;width:2.6rem;height:2.6rem;border-radius:50%;background:#e3f1ef;color:var(--teal-dark);font-weight:800;font-size:1.1rem;margin-bottom:.8rem}
.steps3 h3{margin-bottom:.3rem}
.steps3 p{color:var(--muted);margin:0}

/* Service tiles */
.tiles{list-style:none;margin:1.5rem 0 0;padding:0;display:grid;gap:.9rem;grid-template-columns:repeat(2,1fr)}
@media (min-width:900px){.tiles{grid-template-columns:repeat(3,1fr);gap:1.1rem}}
.tile{display:flex;flex-direction:column;height:100%;padding:1.1rem;border-radius:var(--radius);background:#fff;border:1px solid var(--line);text-decoration:none;color:var(--ink);transition:border-color .15s,box-shadow .15s}
.tile:hover{border-color:var(--teal);box-shadow:0 6px 18px rgba(15,42,67,.08);color:var(--ink)}
.tile-ico{display:flex;align-items:center;justify-content:center;width:2.6rem;height:2.6rem;border-radius:12px;background:#e3f1ef;color:var(--teal-dark);margin-bottom:.7rem}
.tile-ico .icon{width:22px;height:22px}
.tile-name{font-weight:800;color:var(--navy);font-size:1.05rem}
.tile-txt{display:none;color:var(--muted);font-size:.95rem;line-height:1.5;margin-top:.25rem}
@media (min-width:640px){.tile{padding:1.4rem}.tile-txt{display:block}}
.also{margin:1.4rem 0 0;color:var(--muted);font-size:.97rem}

/* About strip */
.about{display:grid;gap:1.5rem;align-items:center}
@media (min-width:760px){.about{grid-template-columns:160px 1fr;gap:3rem}}
.photo-slot{width:160px;aspect-ratio:1;border-radius:50%;background:linear-gradient(135deg,#dbe9f1,#c4dce9);display:flex;align-items:center;justify-content:center;color:var(--navy);font-weight:800;font-size:2.4rem;border:4px solid #fff;box-shadow:0 0 0 1px var(--line)}
@media (min-width:760px){.photo-slot{width:220px}}
.about p{max-width:40rem}

/* Article cards (home recent, related articles) */
.acards{list-style:none;margin:0;padding:0;display:grid;gap:1.25rem}
@media (min-width:640px){.acards{grid-template-columns:repeat(3,1fr)}}
.acard a{display:flex;gap:1rem;align-items:center;text-decoration:none;color:var(--ink)}
.acard picture{flex:0 0 96px}
.acard img{display:block;width:96px;height:96px;border-radius:12px;object-fit:cover}
.acard-body{display:flex;flex-direction:column}
.acard time{font-size:.85rem;color:var(--muted)}
.acard-title{font-weight:700;color:var(--navy);line-height:1.35}
.acard a:hover .acard-title{color:var(--teal-dark);text-decoration:underline}
@media (min-width:640px){.acard a{flex-direction:column;align-items:stretch}.acard picture{flex:none}.acard img{width:100%;height:auto;aspect-ratio:1}}

/* Collapsibles */
details{border-bottom:1px solid var(--line)}
details:first-of-type{border-top:1px solid var(--line)}
summary{cursor:pointer;padding:1rem 2rem 1rem 0;font-weight:700;color:var(--navy);list-style:none;position:relative}
summary::-webkit-details-marker{display:none}
summary::after{content:"+";position:absolute;right:.25rem;top:.85rem;font-size:1.4rem;line-height:1;color:var(--teal-dark)}
details[open] summary::after{content:"–"}
.answer{padding:0 0 .6rem;color:var(--ink)}

/* CTA */
.cta{background:var(--navy);color:#e8f0f6;padding:3rem 0}
.cta-in{display:grid;gap:1rem;align-items:center}
.cta h2{color:#fff;margin-bottom:.3rem}
.cta p{margin:0}
.cta-btns{display:flex;flex-wrap:wrap;gap:.75rem}
.cta .btn-primary{background:var(--gold);color:var(--navy)}
.cta .btn-primary:hover{background:#ffc94d;color:var(--navy)}
.cta-alt{font-size:.95rem}
.cta-alt a{color:#fff}
@media (min-width:900px){.cta-in{grid-template-columns:1fr auto}.cta-alt{grid-column:1/-1}}

/* Footer */
.ft{background:#0b2034;color:#d6e1ea;font-size:.95rem;padding:3rem 0 2rem}
.ft a{color:#fff}
.ft ul{list-style:none;margin:0;padding:0}
.ft li{margin:0 0 .35rem}
.ft-grid{display:grid;gap:2rem}
@media (min-width:760px){.ft-grid{grid-template-columns:1.3fr 1fr 1fr}}
.ft-name,.ft-h{color:#fff;font-weight:800;margin-bottom:.6rem}
.social{display:flex;flex-wrap:wrap;gap:.5rem}
.social a{display:inline-flex;align-items:center;gap:.4rem;min-height:44px;padding:.4rem .85rem;border:1px solid #3a5873;border-radius:999px;text-decoration:none;font-weight:600}
.social a:hover{background:#163552}
.social .icon{width:20px;height:20px}
.ft-comp{display:grid;gap:1rem;align-items:center;border-top:1px solid #23415c;margin-top:2rem;padding-top:1.5rem}
@media (min-width:760px){.ft-comp{grid-template-columns:200px 1fr;gap:1.5rem}}
.ft-logo{display:block;width:200px;height:auto;background:#fff;border-radius:10px;padding:.5rem .7rem}
.ft-comp p{margin:0}
.ft-fine{font-size:.85rem;color:#b9c8d5;margin:1rem 0 0}

/* Inner page */
.page-head{background:linear-gradient(180deg,#eef5f8 0%,#fff 100%);padding:0 0 2rem}
.crumbs{font-size:.88rem;color:var(--muted);padding-top:1rem;padding-bottom:.75rem}
.crumbs ol{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:.25rem}
.crumbs li{margin:0}
.crumbs li+li::before{content:"›";margin:0 .35rem}
.crumbs a{color:var(--muted)}
.ph-in{display:grid;gap:1.5rem;align-items:start}
@media (min-width:900px){.ph-has-aside{grid-template-columns:1fr 340px;gap:3rem;padding-top:1rem}}
.lead{font-size:1.2rem;color:var(--muted);max-width:38rem;margin:0}
.apply-card{background:#fff;border:1px solid var(--line);border-radius:var(--radius);padding:1.4rem;box-shadow:0 8px 24px rgba(15,42,67,.07)}
.apply-card h2{font-size:1.2rem;margin-bottom:.3rem}
.apply-card p{font-size:.95rem;color:var(--muted);margin:0 0 .4rem}
.apply-card .ac-fine{font-size:.82rem;margin:.8rem 0 0}
.with-toc{display:grid;gap:1.25rem;padding-top:1.5rem}
@media (min-width:900px){.with-toc{grid-template-columns:210px minmax(0,46rem);gap:3rem;padding-top:2rem}}
.toc{display:none;font-size:.95rem}
@media (min-width:900px){.toc{display:block;position:sticky;top:5.5rem;align-self:start}.toc-m{display:none}}
.toc-h{font-weight:800;color:var(--navy);margin-bottom:.4rem}
.toc ul,.toc-m ul{list-style:none;margin:0;padding:0}
.toc a{display:block;padding:.35rem .9rem;border-left:2px solid var(--line);text-decoration:none;color:var(--ink);line-height:1.35}
.toc a:hover{border-left-color:var(--teal);color:var(--teal-dark)}
.toc-m{border:1px solid var(--line);border-radius:12px;padding:0 1rem;background:#fff}
.toc-m summary{padding:.8rem 2rem .8rem 0}
.toc-m summary::after{top:.65rem}
.toc-m ul{padding:0 0 .8rem}
.toc-m li{margin:0 0 .35rem}
.toc-m a{text-decoration:none;font-weight:600}
details.toc-m:first-of-type{border-top:1px solid var(--line)}
.prose{max-width:46rem;padding:1.5rem 0 1rem}
.with-toc .prose{padding-top:0}
.prose-wide{max-width:none}
.prose section{padding:0 0 1.75rem}
.prose h2{margin-top:.75rem;scroll-margin-top:6rem}
.prose h3{margin-top:1.4rem}
.prose li{margin-bottom:.4rem}
h2[id],section[id]{scroll-margin-top:6rem}
.sec-tight{padding:2rem 0}
@media (min-width:900px){.sec-tight{padding:2.5rem 0}}
.h-small{font-size:1.25rem}
.chips{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:.5rem}
.chips li{margin:0}
.chips a{display:inline-block;padding:.5rem .95rem;border:1px solid var(--line);border-radius:999px;text-decoration:none;font-weight:600}
.chips a:hover{border-color:var(--teal)}
.cta-fine{font-size:.85rem;color:#b9c8d5}
@media (min-width:900px){.cta-fine{grid-column:1/-1}}
.ft-contact{margin:0 0 .25rem!important}
.ft-comp strong{color:#fff}

/* Content components used inside page bodies */
.btn-teal{background:var(--teal-dark);color:#fff}
.btn-teal:hover{background:var(--navy);color:#fff}
.btn-outline{border-color:currentColor;color:var(--navy);background:#fff}
button.btn{cursor:pointer}
.grid{display:grid;gap:1rem;grid-template-columns:1fr;margin:1rem 0}
@media (min-width:640px){.grid-2,.grid-3{grid-template-columns:repeat(2,1fr)}}
.card{border:1px solid var(--line);border-radius:var(--radius);padding:1.2rem 1.25rem;background:#fff}
.card h3{margin-top:0}
.card p:last-child{margin-bottom:0}
.card a.more{font-weight:700}
.steps{counter-reset:step;list-style:none;padding:0}
.steps li{position:relative;padding:0 0 1rem 3.1rem;margin:0}
.steps li::before{counter-increment:step;content:counter(step);position:absolute;left:0;top:0;width:2.2rem;height:2.2rem;border-radius:50%;background:#e3f1ef;color:var(--teal-dark);font-weight:800;display:flex;align-items:center;justify-content:center}
.note{border-left:4px solid var(--gold);background:#fffaf0;padding:.9rem 1rem;border-radius:0 8px 8px 0;margin:1.25rem 0}
.todo{border:2px dashed #b54708;background:#fff6ed;color:#7a2e0e;padding:.9rem 1rem;border-radius:8px;margin:1rem 0}
table{border-collapse:collapse;width:100%;margin:1rem 0;font-size:.97rem}
th,td{border:1px solid var(--line);padding:.6rem .7rem;text-align:left;vertical-align:top}
th{background:var(--soft);color:var(--navy)}
.table-wrap{overflow-x:auto}
.faq details,.prose .faq details{background:transparent}
.apply-online{border:1px solid var(--line);border-left:4px solid var(--teal);border-radius:0 var(--radius) var(--radius) 0;padding:1rem 1.1rem;margin:1.5rem 0;background:#fff}
.apply-online h3{margin-top:0}
.apply-online p:last-child{margin-bottom:0}
/* Forms */
form .field{margin-bottom:1rem}
label{display:block;font-weight:700;margin-bottom:.3rem;color:var(--navy)}
input,select,textarea{width:100%;font:inherit;padding:.7rem .8rem;border:1px solid #9aa9b7;border-radius:8px;background:#fff;color:var(--ink)}
textarea{min-height:8rem}
.check{display:flex;gap:.6rem;align-items:flex-start}
.check input{width:auto;margin-top:.35rem}
.check label{font-weight:400;color:var(--ink)}
/* Social (inline on About/Contact; footer variant) */
.social{list-style:none;margin:.75rem 0 0;padding:0}
.social li{margin:0}
.social-inline a{color:var(--pineapple);border-color:#9fd2ea;background:#fff}
.social-inline a:hover{border-color:var(--pineapple);background:#f2f9fd;color:#025a82}
.social-footer a{color:#fff}
/* About: headshot placeholder */
.profile{display:grid;gap:1.25rem;align-items:start}
@media (min-width:700px){.profile{grid-template-columns:200px 1fr}}
.headshot-placeholder{width:200px;max-width:100%;aspect-ratio:1/1;border-radius:50%;background:linear-gradient(135deg,#dbe9f1,#c4dce9);display:flex;flex-direction:column;align-items:center;justify-content:center;color:var(--navy);font-size:.85rem;text-align:center;border:4px solid #fff;box-shadow:0 0 0 1px var(--line)}
.headshot-placeholder svg{width:90px;height:90px}
/* Blog */
.post{max-width:46rem}
.byline{color:var(--muted);font-size:.95rem;margin:0 0 1rem}
.notice{border-left:4px solid var(--pineapple);background:#eef7fc;padding:.9rem 1rem;border-radius:0 8px 8px 0;margin:1rem 0 1.25rem}
.post-hero{margin:1.25rem 0 1.5rem;max-width:560px}
.post-hero img{width:100%;height:auto;border-radius:var(--radius);border:1px solid var(--line)}
.post-hero figcaption{font-size:.85rem;color:var(--muted);margin-top:.5rem}
.post-body h2{margin-top:2rem}
.post-body h3{margin-top:1.25rem}
.signoff{font-weight:700;color:var(--navy);margin-top:2rem}
.post-disclaimer{font-size:.9rem;color:var(--muted);background:var(--soft);border-radius:8px;padding:.8rem 1rem;margin:1rem 0 1.5rem}
.post-disclaimer p{margin:0}
.sources{max-width:46rem;margin:0 0 1rem;font-size:.93rem}
.sources ol{padding-left:1.25rem}
.sources li{overflow-wrap:anywhere}
.post-meta{color:var(--muted);font-size:.9rem}
.intro-note{max-width:46rem}
.post-list{list-style:none;padding:0;margin:0 0 1.5rem;display:grid;gap:1.25rem}
@media (min-width:900px){.post-list{grid-template-columns:repeat(2,1fr)}}
.post-card{display:grid;gap:1rem;grid-template-columns:96px 1fr;border:1px solid var(--line);border-radius:var(--radius);padding:1rem;background:#fff;align-items:start}
.post-card h2{font-size:1.15rem;margin:0 0 .25rem}
.post-card h2 a{text-decoration:none;color:var(--navy)}
.post-card h2 a:hover{text-decoration:underline}
.post-card p{margin:.25rem 0}
.post-thumb{width:100%;height:auto;border-radius:10px;display:block}
@media (min-width:640px){.post-card{grid-template-columns:160px 1fr;padding:1.25rem}}
/* About: closing "Let's chat" card */
.chat-card{background:var(--soft);border:1px solid var(--line);border-radius:var(--radius);padding:1.4rem 1.4rem 1rem;margin:1rem 0 1.5rem}
.chat-card h2{margin-top:0}
.chat-card .btns{margin:1rem 0}
.chat-social{margin-bottom:0}
.profile section h2{margin-top:1.6rem}
.about .btns{align-items:center}
/* Headshot (home strip + About). Source is 200x200; shown at max 160px so it is never upscaled */
.headshot{display:block;width:160px;max-width:100%;flex:none}
.headshot img{display:block;width:160px;height:160px;border-radius:50%;object-fit:cover;object-position:50% 30%;border:4px solid #fff;box-shadow:0 0 0 1px var(--line);background:var(--soft)}
.profile .headshot{margin-top:1.6rem}
@media (min-width:700px){.profile{grid-template-columns:160px 1fr;gap:2rem}}
/* Booking buttons */
.book-line{margin:.25rem 0 .5rem}
.book-box{border:1px solid var(--line);border-radius:var(--radius);padding:1rem 1.1rem;margin:1.5rem 0;background:#fff}
.book-box h3{margin-top:0}
.book-box .btns{margin:.5rem 0 0}
.book-compact{margin:.75rem 0 .5rem;font-weight:600}
/* Contact form: honeypot, status messages (shown via #err-* fragment, no JS needed), note */
.hp{position:absolute!important;left:-9999px;width:1px;height:1px;overflow:hidden}
.form-error{display:none;border:2px solid #b42318;background:#fef3f2;color:#7a271a;padding:.9rem 1rem;border-radius:8px;margin:1rem 0}
.form-error:target{display:block}
.form-note{font-size:.92rem;color:var(--muted);margin-top:1rem}
.form-error{scroll-margin-top:6rem}
