/* Blog post pages only — the layout api/_lib/post-render.js writes.
   Design: blog-post-mockup-ar.html. Uses the site's colour tokens and the
   self-hosted fonts; the nav, footer and floating WhatsApp button are the
   site's own. Directional rules use logical properties, so one sheet serves
   /blog (LTR) and /ar/blog (RTL).

   The block between the critical markers is inlined into blog/post.html by
   tools/bake-layout.mjs; the whole file then loads without blocking. */

/*! critical */
.post{--post-line:#E3E9F2;--post-gold-soft:#F4ECD6;padding:5.75rem 0 0;overflow-wrap:break-word}
.post picture{display:contents}
.post-crumbs{font-size:.875rem;color:var(--body);padding-top:.5rem}
.post-crumbs ol{list-style:none;display:flex;flex-wrap:wrap;align-items:center;column-gap:.375rem;margin:0;padding:0}
.post-crumbs li{display:inline-flex;align-items:center;min-height:2.75rem;min-width:0}
.post-crumbs li+li::before{content:"›";margin-inline-end:.375rem;color:#A9B4C4}
body[dir="rtl"] .post-crumbs li+li::before{content:"‹"}
.post-crumbs a{color:var(--body)}
.post-crumbs [aria-current]{color:var(--heading);font-weight:500}
.post-hero{padding:.25rem 0 2rem;min-width:0}
.post-chip{display:inline-flex;align-items:center;min-height:2rem;background:var(--post-gold-soft);color:#7A5E14;font-weight:700;font-size:.8125rem;line-height:1.3;padding:.25rem .875rem;border-radius:999px}
.post h1{font-size:clamp(1.875rem,4.4vw,3rem);line-height:1.22;color:var(--heading);margin:.875rem 0;font-weight:600}
body[dir="rtl"] .post h1{line-height:1.45;font-weight:700}
.post-lead{font-size:clamp(1.0625rem,1.8vw,1.25rem);color:var(--body);max-width:51rem;margin:0;line-height:1.7;font-weight:300}
body[dir="rtl"] .post-lead{font-weight:400;line-height:1.85}
.post-meta{display:flex;flex-wrap:wrap;gap:.25rem 1.25rem;margin:1.125rem 0 0;font-size:.9375rem;color:var(--body);text-transform:none;letter-spacing:0}
.post-cover{position:relative;margin:1.75rem 0 0;border-radius:1.5rem;overflow:hidden;background:var(--sky);aspect-ratio:2/1}
.post-cover img{width:100%;height:100%;object-fit:cover}
.post-video{aspect-ratio:16/9;background:var(--navy)}
.post-layout{display:grid;grid-template-columns:minmax(0,1fr);gap:1.5rem;padding:0 0 3.5rem}
.post-main,.post-article{min-width:0}
.post-toc-m{margin-bottom:1.5rem}
.post-side{display:none}
@media (min-width:1024px){.post{padding-top:6.25rem}}
@media (min-width:1061px){
  .post-layout{grid-template-columns:minmax(0,1fr) 20rem;column-gap:3rem}
  .post-toc-m{display:none}
  .post-side{display:block}
}
@media (max-width:767px){.post-cover{border-radius:1rem;margin-top:1.375rem}}
/*! /critical */

/* ── Article typography ─────────────────────────────────────────────── */
.post .article-body{font-size:1.0625rem;line-height:1.85;color:var(--body)}
body[dir="rtl"] .post .article-body{font-size:1.125rem;line-height:1.95}
.post .article-body h2{font-size:clamp(1.5rem,2.6vw,1.875rem);line-height:1.35;color:var(--heading);margin:3rem 0 .875rem;font-weight:600}
.post .article-body h2::before{content:"";display:block;width:48px;height:3px;background:var(--gold);margin-bottom:.875rem;border-radius:2px}
.post .article-body > :first-child,.post .article-body > h2:first-child{margin-top:0}
.post .article-body h3{font-size:clamp(1.1875rem,2vw,1.375rem);line-height:1.45;color:var(--heading);margin:2rem 0 .5rem;font-weight:600}
.post .article-body h4,.post .article-body h5,.post .article-body h6{font-size:1.0625rem;color:var(--heading);margin:1.5rem 0 .5rem}
body[dir="rtl"] .post .article-body h2,body[dir="rtl"] .post .article-body h3{line-height:1.55;font-weight:700}
.post .article-body p{margin:0 0 1.125rem}
.post .article-body ul,.post .article-body ol{margin:0 0 1.25rem;padding-inline-start:1.5rem}
.post .article-body li{margin-bottom:.375rem;padding-inline-start:.25rem}
.post .article-body li::marker{color:var(--gold)}
.post .article-body ol > li::marker{font-weight:700}
.post .article-body strong{color:var(--heading);font-weight:600}
.post .article-body a{color:var(--navy);text-decoration:underline;text-decoration-color:var(--gold);text-decoration-thickness:1px;text-underline-offset:4px}
.post .article-body a:hover{color:var(--gold-dark)}
.post .article-body img{width:100%;height:auto;border-radius:.75rem;margin:1.5rem 0}
.post .article-body hr{border:0;border-top:1px solid var(--post-line);margin:2.25rem 0}
.post .article-body code{background:var(--sky);border-radius:4px;padding:.1em .35em;font-size:.9em}

/* Key takeaways at the top */
.post .takeaways{background:var(--navy);color:#E8EEF7;border-radius:1rem;padding:1.5rem 1.75rem;margin:0 0 1.75rem}
.post .article-body .takeaways h2{color:var(--gold);font-size:1.25rem;margin:0 0 .625rem}
.post .article-body .takeaways h2::before{display:none}
.post .article-body .takeaways strong,.post .article-body .takeaways a{color:#fff}
.post .takeaways ul,.post .takeaways ol,.post .takeaways p:last-child{margin-bottom:0}
.post .takeaways .t{color:var(--gold);font-weight:700;font-size:1.25rem;line-height:1.4;margin:0 0 .625rem}

/* Tables */
.post .table-wrap{overflow-x:auto;-webkit-overflow-scrolling:touch;border:1px solid var(--post-line);border-radius:1rem;margin:.75rem 0 1.625rem;background:var(--white)}
.post .table-wrap:focus-visible{outline:2px solid var(--gold);outline-offset:2px}
.post table{border-collapse:collapse;width:100%;min-width:34rem;font-size:1rem;line-height:1.6}
.post caption{caption-side:top;text-align:start;padding:.875rem 1.125rem;font-weight:700;color:var(--heading)}
.post th,.post td{padding:.875rem 1.125rem;text-align:start;border-top:1px solid var(--post-line);vertical-align:top}
.post thead th{background:var(--sky);color:var(--heading);border-top:0;font-weight:700}
.post tbody th{color:var(--heading);font-weight:600}

/* Notes (markdown blockquotes) */
.post .article-body blockquote.note,.post .note{border:0;border-inline-start:4px solid var(--gold);background:var(--white);border-radius:.75rem;padding:1rem 1.25rem;margin:1.375rem 0;box-shadow:0 2px 0 var(--post-line);font-style:normal;font-family:inherit;color:var(--body)}
.post .note p{margin:0}
.post .note p + p{margin-top:.5rem}
.post .note.warn{border-color:#E0A300;background:#FFF9EA}
.post .note strong{color:var(--heading)}

/* FAQ accordion */
.post .faq details{background:var(--white);border:1px solid var(--post-line);border-radius:.75rem;margin-bottom:.625rem}
.post .faq summary{cursor:pointer;list-style:none;padding:.625rem 1.25rem;display:flex;justify-content:space-between;align-items:center;gap:.75rem;min-height:2.75rem}
.post .faq summary::-webkit-details-marker{display:none}
.post .faq summary::after{content:"+";color:var(--gold);font-size:1.625rem;line-height:1;flex:none}
.post .faq details[open] summary::after{content:"–"}
.post .article-body .faq summary h3{margin:0;font-size:1.0625rem;line-height:1.5}
.post .faq details > div{padding:0 1.25rem 1rem}
.post .faq details > div > :last-child{margin-bottom:0}
.post .faq summary:focus-visible{outline:2px solid var(--gold);outline-offset:2px;border-radius:.75rem}

/* ── Content blocks, ready for rewritten articles ───────────────────── */
/* Treatment card */
.post .tcard{display:grid;grid-template-columns:140px 1fr auto;gap:1.125rem;align-items:center;background:var(--white);border:1px solid var(--post-line);border-radius:1rem;padding:.75rem;margin:1.625rem 0;text-decoration:none;color:inherit;transition:border-color .2s,box-shadow .2s}
.post .tcard:hover{border-color:var(--gold);box-shadow:0 10px 26px rgba(11,29,58,.08)}
.post .tcard img{width:140px;height:100px;object-fit:cover;border-radius:.625rem;margin:0}
.post .tcard small{color:#8A6D1E;font-weight:700}
.post .tcard strong{display:block;color:var(--heading);font-size:1.1875rem}
.post .tcard .go{color:var(--heading);font-weight:700;white-space:nowrap;padding-inline-end:.625rem}
@media (max-width:560px){.post .tcard{grid-template-columns:96px 1fr}.post .tcard img{width:96px;height:80px}.post .tcard .go{display:none}}
/* The whole card is the link: no underline on it or on any link inside it (beats .article-body a) */
.post .article-body a.tcard,.post .article-body a.card,.post .article-body .tcard a,.post .article-body .card a{text-decoration:none}
/* Before / after pair */
.post .ba{margin:1.125rem 0 .5rem;background:var(--white);border:1px solid var(--post-line);border-radius:1rem;padding:.75rem}
.post .ba-pair{display:grid;grid-template-columns:1fr 1fr;gap:.5rem}
.post .ba-pair div{position:relative}
.post .ba-pair img{width:100%;height:auto;aspect-ratio:4/5;object-fit:cover;border-radius:.625rem;background:var(--sky);margin:0}
.post .ba-pair span{position:absolute;top:.625rem;inset-inline-start:.625rem;padding:.125rem .75rem;border-radius:999px;font-size:.8125rem;font-weight:700;background:rgba(11,29,58,.8);color:#fff}
.post .ba-pair div:last-child span{background:var(--gold);color:var(--navy)}
.post .ba figcaption{font-size:.875rem;color:var(--body);padding:.75rem .25rem .125rem}
.post .ba figcaption b{color:var(--heading)}
.post .consent{font-size:.8125rem;color:var(--body);background:var(--sky);border-radius:.625rem;padding:.625rem .875rem;margin:.625rem 0 1.5rem}
/* Lite video (vertical short) */
.post .video-wrap{display:grid;grid-template-columns:300px 1fr;gap:1.5rem;align-items:center;margin:1rem 0 .625rem}
@media (max-width:640px){.post .video-wrap{grid-template-columns:1fr}}
.post .video{position:relative;aspect-ratio:9/16;border-radius:1rem;overflow:hidden;background:#000;max-width:300px}
.post .video img{width:100%;height:100%;object-fit:cover;margin:0;border-radius:0}
/* Gallery */
.post .gallery{display:grid;grid-template-columns:repeat(3,1fr);gap:.75rem;margin:.875rem 0 .375rem}
.post .gallery figure{margin:0}
.post .gallery img{width:100%;aspect-ratio:1;object-fit:cover;border-radius:.75rem;margin:0}
.post .gallery figcaption{font-size:.8125rem;padding-top:.375rem}
@media (max-width:560px){.post .gallery{grid-template-columns:repeat(2,1fr)}}
/* Numbered steps */
.post .article-body .steps{counter-reset:s;list-style:none;padding:0}
.post .steps li{counter-increment:s;position:relative;padding:.875rem 1.125rem;padding-inline-start:4rem;background:var(--white);border:1px solid var(--post-line);border-radius:.75rem;margin-bottom:.625rem}
.post .steps li::before{content:counter(s);position:absolute;inset-inline-start:1rem;top:.875rem;width:34px;height:34px;border-radius:50%;background:var(--navy);color:var(--gold);display:grid;place-items:center;font-weight:700}

/* Click-to-play video: the hero video and .video blocks */
.post .post-video button,.post .video button{position:absolute;inset:0;width:100%;height:100%;padding:0;border:0;background:none;cursor:pointer}
.post .play{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:72px;height:72px;border-radius:50%;background:var(--gold);display:grid;place-items:center;box-shadow:0 10px 30px rgba(0,0,0,.35);transition:transform .2s}
.post .play::after{content:"";border-style:solid;border-width:12px 0 12px 20px;border-color:transparent transparent transparent var(--navy);margin-left:6px}
.post button:hover .play{transform:translate(-50%,-50%) scale(1.08)}
.post .post-video iframe,.post .video iframe{position:absolute;inset:0;width:100%;height:100%;border:0}
.post button:focus-visible{outline:3px solid var(--gold);outline-offset:-3px}

/* The clinic-tour gallery sits inside the article column here, not full-bleed */
.post .post-article .bts-gallery-section{left:auto;right:auto;transform:none;width:auto;margin-top:2.5rem}

/* Share + disclaimer */
.post-share{display:flex;flex-wrap:wrap;gap:.625rem;align-items:center;margin:2.25rem 0 0;color:var(--body)}
.post-share a{min-height:2.75rem;padding:0 1.125rem;display:inline-flex;align-items:center;border:1px solid var(--post-line);border-radius:999px;background:var(--white);color:var(--heading);font-size:.9375rem;font-weight:500;transition:border-color .2s}
.post-share a:hover{border-color:var(--gold)}
.post-disclaimer{font-size:.875rem;color:var(--body);border-top:1px solid var(--post-line);padding-top:1rem;margin:1.5rem 0 0}

/* ── Contents (mobile: collapsed above the article) ────────────────── */
.post-toc-m{background:var(--white);border:1px solid var(--post-line);border-radius:1rem}
.post-toc-m summary{min-height:3rem;padding:0 1.25rem;display:flex;align-items:center;justify-content:space-between;gap:.75rem;font-weight:700;color:var(--heading);cursor:pointer;list-style:none}
.post-toc-m summary::-webkit-details-marker{display:none}
.post-toc-m summary::after{content:"+";color:var(--gold);font-size:1.5rem;line-height:1}
.post-toc-m[open] summary::after{content:"–"}
.post-toc-m .toc{padding:0 .75rem .75rem}
.post .toc ol{list-style:none;margin:0;padding:0;font-size:.9375rem;line-height:1.55}
.post .toc a{display:flex;align-items:center;min-height:2.75rem;padding:.375rem .75rem;border-radius:.5rem;color:var(--body);border-inline-start:2px solid transparent;transition:background .2s,color .2s}
.post .toc a:hover,.post .toc a.active{background:var(--sky);color:var(--heading);border-color:var(--gold)}

/* ── Sidebar (desktop) ─────────────────────────────────────────────── */
.post-side-in{position:sticky;top:6rem;padding-top:.25rem;display:grid;gap:1.125rem;max-height:calc(100vh - 7rem);overflow-y:auto;scrollbar-width:thin}
.post .box{background:var(--white);border:1px solid var(--post-line);border-radius:1rem;padding:1.25rem}
.post .box-title{font-weight:700;color:var(--heading);font-size:1.0625rem;margin:0 0 .625rem}
.post .book{background:linear-gradient(160deg,var(--navy),var(--navy-light));color:#E8EEF7;border:0}
.post .book .box-title{color:var(--white);font-size:1.25rem}
.post .book p{font-size:.9375rem;margin:0 0 .875rem;line-height:1.6}
.post .book .btn{width:100%;margin-top:.5rem;min-height:3rem;font-size:.875rem}
.post .btn-wa{background:#25D366;color:#06371B}
.post .btn-wa:hover{background:#1FBF5B}
.post .side-links{list-style:none;padding:0;margin:0}
.post .side-links a{display:flex;justify-content:space-between;align-items:center;gap:.75rem;min-height:2.75rem;padding:.375rem 0;border-bottom:1px solid var(--post-line);font-size:.9375rem;color:var(--heading)}
.post .side-links a:hover{color:var(--gold-dark)}
.post .side-links li:last-child a{border:0}
.post .side-links span{color:var(--gold)}

/* ── After the article ─────────────────────────────────────────────── */
.post-cta{background:var(--navy);color:var(--white);border-radius:1.75rem;padding:2.75rem;display:grid;grid-template-columns:1fr auto;gap:1.75rem;align-items:center;margin:1.25rem 0 3.5rem}
.post-cta h2{margin:0 0 .375rem;font-size:clamp(1.5rem,3vw,1.875rem);color:var(--white)}
.post-cta p{margin:0;color:#C9D4E5;line-height:1.7}
.post-cta .btns{display:flex;gap:.75rem;flex-wrap:wrap}
.post-cta .btn{min-height:3rem;font-size:.875rem}
@media (max-width:780px){.post-cta{grid-template-columns:1fr;padding:1.875rem;border-radius:1.25rem}}
@media (max-width:480px){.post-cta .btn{flex:1 1 100%}}

.post-related h2{font-size:clamp(1.5rem,3vw,1.875rem);margin:0 0 1.25rem}
.post-cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1.375rem}
@media (max-width:900px){.post-cards{grid-template-columns:minmax(0,1fr)}}
.post-card{background:var(--white);border:1px solid var(--post-line);border-radius:1rem;overflow:hidden;display:flex;flex-direction:column;color:inherit;transition:transform .2s,box-shadow .2s}
.post-card:hover{transform:translateY(-3px);box-shadow:0 16px 34px rgba(11,29,58,.1)}
.post-card img,.post-card-ph{display:block;width:100%;height:auto;aspect-ratio:2/1;object-fit:cover;background:var(--sky)}
.post-card > div{padding:1.125rem}
.post-card-meta{display:flex;flex-wrap:wrap;align-items:center;gap:.5rem .75rem;margin:0;font-size:.8125rem;color:var(--body)}
.post-card-meta .post-chip{min-height:1.625rem;font-size:.75rem;padding:.125rem .75rem}
.post-card h3{margin:.5rem 0 .375rem;font-size:1.1875rem;line-height:1.45;color:var(--heading)}
.post-card-ex{margin:0;font-size:.9375rem;line-height:1.6;color:var(--body);display:-webkit-box;-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}

.post-nav{display:grid;grid-template-columns:1fr 1fr;gap:1rem;margin:2.5rem 0 4.5rem}
.post-nav a{display:block;background:var(--white);border:1px solid var(--post-line);border-radius:.875rem;padding:1rem 1.25rem;color:var(--heading);font-weight:600;line-height:1.5;transition:border-color .2s}
.post-nav a:hover{border-color:var(--gold)}
.post-nav .prev{grid-column:1}
.post-nav .next{grid-column:2;text-align:end}
.post-nav small{display:block;color:var(--body);font-weight:400;font-size:.8125rem;margin-bottom:.25rem}
@media (max-width:560px){.post-nav{grid-template-columns:minmax(0,1fr)}.post-nav .next{grid-column:1}}
.post-related + .post-nav{margin-top:2.5rem}
.post > .container > :last-child{margin-bottom:4.5rem}

.post-message{text-align:center;padding:3rem 0 6rem;color:var(--body)}
.post-message a{color:var(--gold-dark);text-decoration:underline}

@media (prefers-reduced-motion:reduce){.post-card,.post-card:hover{transition:none;transform:none}.post .play{transition:none}}
.post-side .toc ol{max-height:min(22rem,40vh);overflow-y:auto;scrollbar-width:thin}
