/* Guides (/blog/): layout only. Hero, reading column, "On this page", FAQ, rows and ad slots come from /shared/ui.css. */
.article-hero h1{max-width:22ch}
.article-hero .who a{color:var(--amethyst);text-decoration:none}.article-hero .who a:hover{color:var(--white);text-decoration:underline}
.article-hero .lede b{color:var(--white);font-weight:700}
.article-hero .byline{line-height:1.7}

/* the reading column */
.article-page .prose h2{scroll-margin-top:calc(var(--top) + 24px)}
.article-page .prose h3{scroll-margin-top:calc(var(--top) + 24px)}
.article-page .prose .table-wrap{margin-block:1.4em}
.article-page .prose .table-wrap table{min-width:540px}
.article-page .prose .table-wrap:focus-visible{outline:2px solid var(--violet)}
.article-page .prose .ad-slot+*{margin-top:0}

/* questions, help and sources close the article */
.article-faq{margin-top:3em}
.article-faq .faq{margin-top:1em}
.article-faq .faq details>p{font-size:1rem;line-height:1.7}
.article-cta{margin-top:3em;background:var(--onyx);color:var(--on-dark);border-radius:var(--radius);padding:clamp(24px,3vw,36px)}
.article-cta h2{margin:0;color:var(--white)}
.article-cta p{margin-top:12px;color:var(--on-dark-2)}
.article-cta .actions{margin-top:22px}
.prose .article-cta .btn,.prose .side-cta .btn{text-decoration:none;font-weight:700}
.prose .article-cta .btn-primary,.prose .article-cta .btn-ghost-dark{color:var(--white)}
.article-page .sources{margin-top:3em;padding-top:2em;border-top:1px solid var(--line)}
.article-page .sources h2{font-size:1.3rem;margin-top:0}
.article-page .sources ul{padding-left:1.1em}
.article-page .sources li{word-break:break-word}

/* the index: one section per service */
.article-index .head-col h2{max-width:none}
.article-index .index-more{margin-top:18px}
.article-index .pick a{white-space:nowrap}

@media (max-width:1080px){
  .article-page .doc-side{display:none}
}
@media (max-width:640px){
  .article-cta .actions .btn{width:100%}
}

/* phones and tablets: "On this page" folds out at the top of the article (the sidebar is hidden there) */
.toc-inline{display:none}
@media (max-width:1080px){
  .toc-inline{display:block;margin-bottom:2em;background:var(--paper-2);border-radius:var(--radius);padding:4px 18px}
  .toc-inline summary{cursor:pointer;padding:12px 0;font-weight:700;font-size:1rem;list-style-position:inside}
  .toc-inline ol{margin:0 0 14px;padding:0}
  .prose .toc-inline a{text-decoration:none;font-weight:500}
  .toc-inline+*{margin-top:0}
}

.article-page .grey .head h2{max-width:22ch}
/* phones: a wide table runs to the screen edges, so its cut-off column shows it scrolls sideways */
@media (max-width:640px){
  .article-page .prose .table-wrap{margin-inline:calc(-1 * var(--gutter));padding-inline:var(--gutter)}
}

/* ---------- the magazine (/blog/ and /blog/<topic>/): cards with the featured image (tools/featured_images.py) ---------- */
.mag-top{padding-bottom:clamp(40px,5vw,72px)}
.mag-label{font-size:var(--t-h3);letter-spacing:-.02em;margin:0 0 20px}
.mag-label:not(:first-child){margin-top:clamp(48px,6vw,80px)}
.mag-card a{display:flex;flex-direction:column;height:100%;text-decoration:none;color:inherit}
.mag-shot{display:block;aspect-ratio:1200/630;overflow:hidden;border-radius:var(--radius);background:var(--paper-3)}
.mag-shot img{display:block;width:100%;height:100%;object-fit:cover;transition:transform .5s var(--ease)}
.mag-card a:hover .mag-shot img{transform:scale(1.02)}
.mag-body{display:flex;flex-direction:column;gap:8px;padding-top:16px}
.mag-topic{color:var(--violet);font-size:var(--t-small);font-weight:700}
.mag-card h3,.mag-card h2{margin:0;font-size:1.2rem;line-height:1.3;letter-spacing:-.02em}
.mag-card a:hover h3,.mag-card a:hover h2{color:var(--violet)}
.mag-desc{color:var(--ink-2);font-size:.98rem;line-height:1.55}
.mag-card small{color:var(--ink-3);font-size:var(--t-small);font-weight:600}
.mag-card.lead a{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);gap:clamp(24px,4vw,56px);align-items:center}
.mag-card.lead .mag-body{padding-top:0;gap:14px}
.mag-card.lead h3{font-size:var(--t-h2);line-height:1.08;letter-spacing:-.035em;max-width:18ch}
.mag-card.lead .mag-desc{font-size:var(--t-body);max-width:56ch}
.mag-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:40px 28px}
.mag-grid.four{grid-template-columns:repeat(4,minmax(0,1fr))}
.grey .mag-shot{background:var(--white)}
.mag-services{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:0 28px;border-top:4px solid var(--ink)}
.mag-services a{display:flex;flex-direction:column;gap:4px;padding:20px 0;border-bottom:1px solid var(--line);text-decoration:none;color:inherit}
.mag-services b{font-size:1.1rem;letter-spacing:-.02em}
.mag-services span{color:var(--ink-2);font-size:.95rem}
.mag-services a:hover b{color:var(--violet)}
.mag-actions{margin-top:28px;align-items:center}
.mag-trust p{color:var(--ink-2);max-width:62ch}
.mag-trust p+p{margin-top:16px}
.topic-page .page-hero .byline a{color:var(--amethyst)}

/* the article's featured image, first in the reading column */
.article-image{margin:0 0 2em}
.article-image img{display:block;width:100%;height:auto;border-radius:var(--radius)}

@media (max-width:1080px){
  .mag-grid.four{grid-template-columns:repeat(2,minmax(0,1fr))}
  .mag-services{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width:860px){
  .mag-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .mag-card.lead a{grid-template-columns:minmax(0,1fr)}
  .mag-card.lead h3{font-size:clamp(1.6rem,6vw,2.2rem)}
}
@media (max-width:640px){
  .mag-grid,.mag-grid.four,.mag-services{grid-template-columns:minmax(0,1fr)}
}
@media (prefers-reduced-motion:reduce){.mag-shot img{transition:none}}

/* topic bar ("All guides <n>" first, the page's own topic marked) and the guide search (shared/guides-search.js) */
.topic-bar a .n{margin-left:4px;font-weight:700;color:var(--amethyst)}
.topic-bar a[aria-current="page"]{background:var(--violet);color:var(--white)}
.topic-bar a[aria-current="page"] .n,.topic-bar a:hover .n{color:var(--white)}
.guides-tools{margin-top:22px}
.guides-search{position:relative;display:flex;align-items:center;gap:10px;min-height:52px;padding:0 14px;border-radius:var(--radius);background:var(--onyx-2);color:var(--on-dark-2);border:1px solid var(--line-dark);transition:border-color .2s}
.guides-search:focus-within{border-color:var(--amethyst)}
.guides-search svg{flex:none}
.guides-search input{flex:1;min-width:0;height:50px;border:0;background:none;color:var(--white);font:500 1rem Manrope,sans-serif;outline:none}
.guides-search input::placeholder{color:var(--on-dark-2);opacity:.8}
.guides-search input::-webkit-search-cancel-button{display:none}
.guides-clear{flex:none;width:32px;height:32px;border:0;border-radius:50%;background:var(--onyx-3);color:var(--white);font-size:1.2rem;line-height:1;cursor:pointer}
.guides-clear:hover,.guides-clear:focus-visible{background:var(--violet)}
.guides-status{margin-top:10px;min-height:1.4em;color:var(--on-dark-2);font-weight:600}
.article-index [data-guide][hidden],.article-index .mag-section[hidden],.article-index .mag-top[hidden],.guides-tools[hidden],.guides-clear[hidden]{display:none!important}

/* a topic button was clicked: the list dims until the topic's content is swapped in (shared/guides-search.js) */
.guides-loading main .band{opacity:.55;transition:opacity .15s}
@media (prefers-reduced-motion:reduce){.guides-loading main .band{transition:none}}
