/* ==========================================================================
   Blog
   Overview, pagination and article page. Loaded on the blog pages only.
   The --storm-* tokens and the generated cover (.storm-cover) come from the
   main stylesheet.

   1. Overview
   2. Cards
   3. Pagination
   4. Article page layout
   5. Article header
   6. Table of contents
   7. Article typography
   8. Share
   9. Author, previous and next, related, call to action
   10. Reading progress
   11. Focus and reduced motion
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Overview
   -------------------------------------------------------------------------- */

.blog-index {
    padding: 40px 0 88px;
}

.blog-index-summary {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 4px 24px;
    margin: 0 0 20px;
    font-size: 15px;
    line-height: 24px;
    font-variant-numeric: tabular-nums;
    color: var(--storm-muted);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 40px 28px;
}

.blog-empty {
    max-width: 520px;
    margin: 24px auto 0;
    text-align: center;
}

/* Three dots, the smallest piece of the dot field */
.blog-empty::before {
    content: '';
    display: block;
    width: 72px;
    height: 8px;
    margin: 0 auto 24px;
    background: radial-gradient(circle, var(--storm-faint) 3px, transparent 3.5px) 0 0 / 24px 8px repeat-x;
}

.blog-empty-title {
    margin: 0 0 8px;
    font-size: 28px;
    font-weight: 700;
    line-height: 36px;
    letter-spacing: -.01em;
}

.blog-empty-text {
    margin: 0 0 24px;
    font-size: 17px;
    line-height: 28px;
    color: var(--storm-text);
}

@media (min-width: 1100px) {
    .blog-index {
        padding: 48px 0 112px;
    }

    .blog-grid {
        gap: 56px 32px;
    }
}

/* --------------------------------------------------------------------------
   2. Cards
   The title inside the cover is the link. It fills the cover, the
   "Read article" line fills the text below, so the whole card can be clicked.
   -------------------------------------------------------------------------- */

.blog-card {
    display: flex;
    flex-direction: column;
    grid-column: span 6;
    min-width: 0;
    border-radius: var(--storm-radius-m);
}

.blog-cover-link {
    color: inherit;
    text-decoration: none;
}

.blog-cover-link::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1;
}

.blog-card-body {
    position: relative;
    display: flex;
    flex: 1;
    flex-direction: column;
    padding-top: 14px;
}

.blog-card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 2px 14px;
    margin: 0 0 6px;
    font-size: 14px;
    line-height: 22px;
    font-variant-numeric: tabular-nums;
    color: var(--storm-muted);
}

.blog-card-flag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--storm-purple-deep);
}

.blog-card-flag::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--storm-purple);
}

.blog-card-excerpt {
    display: -webkit-box;
    margin: 0 0 6px;
    overflow: hidden;
    font-size: 16px;
    line-height: 26px;
    color: var(--storm-text);
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
}

.blog-card-more {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    gap: 8px;
    min-height: 44px;
    margin-top: auto;
    font-size: 15px;
    font-weight: 600;
    line-height: 24px;
    color: var(--storm-purple-deep);
    text-decoration: none;
    transition: color var(--storm-hover) ease;
}

.blog-card-more::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
}

.blog-card-more span,
.article-related-all span {
    position: relative;
}

/* A dotted trail runs under the words, like under the links in the header */
.blog-card-more span::after,
.article-related-all span::after {
    content: '';
    position: absolute;
    right: 0;
    bottom: -4px;
    left: 0;
    height: 4px;
    background: radial-gradient(circle, currentColor 1.4px, transparent 1.9px) 0 0 / 8px 4px repeat-x;
    clip-path: inset(0 100% 0 0);
    transition: clip-path var(--storm-move) var(--storm-ease);
}

.blog-card-more svg,
.article-related-all svg {
    flex: none;
    transition: transform var(--storm-state) var(--storm-ease);
}

.blog-card:hover .blog-card-more,
.article-related-all:hover {
    color: var(--storm-ink);
    text-decoration: none;
}

.blog-card:hover .blog-card-more span::after,
.article-related-all:hover span::after,
.article-related-all:focus-visible span::after {
    clip-path: inset(0 0 0 0);
}

.blog-card:hover .blog-card-more svg,
.article-related-all:hover svg {
    transform: translateX(4px);
}

.blog-card:active .blog-card-more svg,
.article-related-all:active svg {
    transform: translateX(8px);
    transition-duration: var(--storm-press);
}

/* Keyboard focus sits on the title link, the ring is drawn around the card */
.blog-cover-link:focus-visible::after {
    outline: 2px solid var(--storm-purple);
    outline-offset: -4px;
    border-radius: var(--storm-radius-m);
}

@supports selector(:has(a)) {
    .blog-cover-link:focus-visible::after {
        outline: none;
    }

    .blog-card:has(.blog-cover-link:focus-visible) {
        outline: 2px solid var(--storm-purple);
        outline-offset: 2px;
    }

    .blog-card:has(.blog-cover-link:focus-visible) .blog-card-more span::after {
        clip-path: inset(0 0 0 0);
    }
}

@media (min-width: 641px) {
    .blog-card {
        grid-column: span 3;
    }

    .blog-card--featured {
        grid-column: span 6;
    }

    .blog-card--featured .blog-card-excerpt {
        font-size: 18px;
        line-height: 29px;
        color: var(--storm-ink);
    }

    /* Three related articles: two next to each other, the third in a row */
    .blog-grid--related .blog-card:nth-child(3):last-child {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        grid-column: span 6;
        align-items: center;
        gap: 28px;
    }

    .blog-grid--related .blog-card:nth-child(3):last-child .blog-card-body {
        flex: none;
        padding-top: 0;
    }
}

@media (min-width: 1100px) {
    .blog-card {
        grid-column: span 2;
    }

    .blog-card--wide {
        grid-column: span 3;
    }

    /* The latest article: cover on the left, text on the right */
    .blog-card--featured {
        display: grid;
        grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
        grid-column: span 6;
        align-items: center;
        gap: 48px;
    }

    .blog-card--featured .blog-card-body {
        flex: none;
        padding-top: 0;
    }

    .blog-card--featured .blog-card-meta {
        margin-bottom: 12px;
    }

    .blog-card--featured .blog-card-excerpt {
        margin-bottom: 14px;
        font-size: 21px;
        line-height: 33px;
        -webkit-line-clamp: 6;
        line-clamp: 6;
    }

    .blog-grid--related .blog-card:nth-child(3):last-child {
        display: flex;
        grid-column: span 2;
        gap: 0;
    }

    .blog-grid--related .blog-card:nth-child(3):last-child .blog-card-body {
        flex: 1;
        padding-top: 14px;
    }
}

/* --------------------------------------------------------------------------
   3. Pagination
   -------------------------------------------------------------------------- */

.blog-pagination {
    margin-top: 56px;
}

.blog-pagination-list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.blog-pagination-list li {
    margin: 0;
}

.blog-pagination-page,
.blog-pagination-step,
.blog-pagination-gap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    font-size: 16px;
    font-weight: 600;
    line-height: 1;
    font-variant-numeric: tabular-nums;
    color: var(--storm-text);
}

.blog-pagination-page,
.blog-pagination-step {
    padding: 0 10px;
    text-decoration: none;
    border-radius: 22px;
    transition: background-color var(--storm-hover) ease, color var(--storm-hover) ease, transform var(--storm-hover) var(--storm-ease);
}

.blog-pagination-gap {
    min-width: 28px;
    color: var(--storm-faint);
}

.blog-pagination-step--back svg {
    transform: scaleX(-1);
}

a.blog-pagination-page:hover,
a.blog-pagination-step:hover {
    color: var(--storm-ink);
    text-decoration: none;
    background-color: var(--storm-base);
}

a.blog-pagination-page:active,
a.blog-pagination-step:active {
    transform: scale(.92);
    transition-duration: var(--storm-press);
}

.blog-pagination-page[aria-current="page"],
.blog-pagination-page[aria-current="page"]:hover {
    color: var(--storm-white);
    background-color: var(--storm-ink);
}

.blog-pagination-step.is-disabled {
    color: var(--storm-faint);
    opacity: .45;
}

@media (max-width: 480px) {
    /* The numbers already hold the first and the last page */
    .blog-pagination-edge {
        display: none;
    }
}

/* --------------------------------------------------------------------------
   4. Article page layout
   -------------------------------------------------------------------------- */

/* The page wrapper clips its overflow. As a scroll container it would hold
   the sticky table of contents in place, "clip" cuts the same way without
   becoming one. */
.body-wrap:has(.article-rail) {
    overflow: clip;
}

.article-page {
    padding-top: 76px;
}

/* 68 characters of body text (18px) set the measure of the article */
.article-layout {
    max-width: 68ch;
    margin: 0 auto;
    font-size: 18px;
}

.article-main {
    min-width: 0;
}

.article-rail {
    margin-top: 40px;
}

.article-breadcrumb ol {
    display: flex;
    align-items: center;
    min-width: 0;
    margin: 0 0 8px;
    padding: 0;
    font-size: 14px;
    line-height: 22px;
    color: var(--storm-muted);
    list-style: none;
}

.article-breadcrumb li {
    flex: none;
    margin: 0;
}

.article-breadcrumb li + li::before {
    content: '/';
    margin: 0 10px;
    color: var(--storm-faint);
}

.article-breadcrumb li:last-child {
    flex: 0 1 auto;
    min-width: 0;
    overflow: hidden;
    color: var(--storm-text);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.article-breadcrumb a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    color: var(--storm-muted);
    text-decoration: none;
    transition: color var(--storm-hover) ease;
}

.article-breadcrumb a:hover {
    color: var(--storm-ink);
    text-decoration: underline;
}

.article-breadcrumb a:active {
    color: var(--storm-purple-deep);
}

@media (min-width: 1100px) {
    .article-page {
        padding-top: 134px;
    }

    .article-layout {
        display: grid;
        grid-template-columns: minmax(0, 68ch) 280px;
        align-items: start;
        justify-content: space-between;
        max-width: none;
    }

    .article-breadcrumb {
        grid-column: 1 / -1;
    }

    .article-breadcrumb ol {
        margin-bottom: 12px;
    }

    .article-breadcrumb a {
        min-height: 32px;
    }

    .article-rail {
        position: sticky;
        top: 134px;
        max-height: calc(100vh - 158px);
        margin-top: 0;
        padding: 4px;
        overflow-y: auto;
        scrollbar-width: thin;
    }
}

/* --------------------------------------------------------------------------
   5. Article header
   -------------------------------------------------------------------------- */

.article-header {
    margin-bottom: 28px;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 2px 14px;
    margin: 16px 0 0;
    padding: 0;
    font-size: 15px;
    line-height: 26px;
    font-variant-numeric: tabular-nums;
    color: var(--storm-muted);
    list-style: none;
}

.article-meta li {
    margin: 0;
}

/* A dot closes every entry but the last one */
.article-meta li:not(:last-child)::after {
    content: '';
    display: inline-block;
    width: 4px;
    height: 4px;
    margin-left: 14px;
    vertical-align: middle;
    border-radius: 50%;
    background: var(--storm-faint);
}

.article-meta strong {
    font-weight: 600;
    color: var(--storm-ink);
}

@media (min-width: 1100px) {
    .article-header {
        margin-bottom: 36px;
    }
}

/* --------------------------------------------------------------------------
   6. Table of contents
   Below 1100px it is a closed <details> above the text, from 1100px on a
   sticky list next to it.
   -------------------------------------------------------------------------- */

.article-toc--rail {
    display: none;
}

.article-toc--inline {
    margin: 0 0 32px;
    background: var(--storm-base);
    border-radius: var(--storm-radius-m);
}

.article-toc summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 52px;
    padding: 0 18px;
    font-family: var(--storm-font-display);
    font-size: 17px;
    font-weight: 700;
    line-height: 24px;
    color: var(--storm-ink);
    list-style: none;
    cursor: pointer;
    border-radius: var(--storm-radius-m);
    -webkit-tap-highlight-color: transparent;
}

.article-toc summary::-webkit-details-marker {
    display: none;
}

.article-toc summary svg {
    flex: none;
    color: var(--storm-muted);
    transition: transform var(--storm-state) var(--storm-ease), color var(--storm-hover) ease;
}

.article-toc summary:hover svg {
    color: var(--storm-ink);
    transform: translateY(2px);
}

.article-toc summary:active svg {
    transform: translateY(4px);
    transition-duration: var(--storm-press);
}

.article-toc details[open] summary svg,
.article-toc details[open] summary:hover svg {
    transform: rotate(180deg);
}

.article-toc--inline .article-toc-list {
    padding: 0 18px 10px;
}

.article-toc-title {
    margin: 0 0 6px;
    font-family: var(--storm-font-display);
    font-size: 16px;
    font-weight: 700;
    line-height: 24px;
    color: var(--storm-ink);
}

.article-toc-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.article-toc-item {
    margin: 0;
}

.article-toc-item a {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 6px 0 6px 20px;
    font-size: 15px;
    line-height: 22px;
    color: var(--storm-muted);
    text-decoration: none;
    transition: color var(--storm-hover) ease;
}

/* Every entry has a dot, the dot of the current section lights up */
.article-toc-item a::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 2px;
    width: 6px;
    height: 6px;
    margin-top: -3px;
    border-radius: 50%;
    background-color: var(--storm-faint);
    opacity: .5;
    transform: scale(.67);
    transition: transform var(--storm-state) var(--storm-ease), background-color var(--storm-state) ease, opacity var(--storm-state) ease;
}

.article-toc-item--sub a {
    padding-left: 38px;
}

.article-toc-item--sub a::before {
    left: 20px;
}

.article-toc-item a:hover {
    color: var(--storm-ink);
    text-decoration: none;
}

.article-toc-item a:hover::before {
    opacity: 1;
    transform: scale(1);
}

.article-toc-item a:active {
    color: var(--storm-purple-deep);
}

.article-toc-item a.is-active {
    color: var(--storm-ink);
}

.article-toc-item a.is-active::before {
    background-color: var(--storm-purple);
    opacity: 1;
    transform: scale(1.34);
}

@media (min-width: 1100px) {
    .article-toc--inline {
        display: none;
    }

    .article-toc--rail {
        display: block;
    }

    .article-toc-item a {
        min-height: 36px;
        padding-top: 5px;
        padding-bottom: 5px;
        font-size: 14px;
        line-height: 20px;
    }
}

/* --------------------------------------------------------------------------
   7. Article typography
   One scale for every article: 18px text, headings in Mukta.
   -------------------------------------------------------------------------- */

.article-body {
    font-size: 18px;
    line-height: 1.75;
    letter-spacing: 0;
    color: var(--storm-text);
    overflow-wrap: break-word;
}

.article-body > :first-child {
    margin-top: 0;
}

.article-body > :last-child {
    margin-bottom: 0;
}

.article-body p {
    margin: 0 0 1.35em;
}

/* The opening paragraph is set a little larger */
.article-body > p:first-child {
    font-size: 20px;
    line-height: 1.65;
    color: var(--storm-ink);
}

.article-body h2,
.article-body h3,
.article-body h4 {
    font-family: var(--storm-font-display);
    font-weight: 700;
    color: var(--storm-ink);
    text-wrap: balance;
}

.article-body h2 {
    margin: 1.9em 0 .55em;
    font-size: 26px;
    line-height: 1.22;
    letter-spacing: -.01em;
}

.article-body h3 {
    margin: 1.7em 0 .5em;
    font-size: 21px;
    line-height: 1.3;
    letter-spacing: -.005em;
}

.article-body h4 {
    margin: 1.5em 0 .4em;
    font-size: 18px;
    line-height: 1.4;
    letter-spacing: 0;
}

.article-body h5,
.article-body h6 {
    margin: 1.4em 0 .3em;
    font-family: var(--storm-font-body);
    font-size: 16px;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: 0;
    color: var(--storm-ink);
}

/* A heading right below another heading keeps close to it */
.article-body :is(h2, h3, h4) + :is(h3, h4, h5) {
    margin-top: .7em;
}

/* Headings are bold already, bold text inside them stays the same weight */
.article-body :is(h2, h3, h4, h5, h6) :is(strong, b) {
    font-weight: inherit;
    color: inherit;
}

/* Room for the fixed header when a heading is opened from the table of contents */
.article-body :is(h2, h3, h4)[id] {
    scroll-margin-top: 84px;
}

.article-body :is(h2, h3)[tabindex]:focus:not(:focus-visible) {
    outline: none;
}

.article-body strong,
.article-body b {
    font-weight: 600;
    color: var(--storm-ink);
}

.article-body a {
    color: var(--storm-purple-deep);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
    transition: color var(--storm-hover) ease;
}

.article-body a:hover {
    color: var(--storm-ink);
    text-decoration: underline;
}

.article-body a:active {
    color: var(--storm-purple);
}

.article-body ul,
.article-body ol {
    margin: 0 0 1.35em;
    padding-left: 1.35em;
}

.article-body ul {
    list-style: disc;
}

.article-body ol {
    list-style: decimal;
}

.article-body li {
    margin: 0 0 .5em;
    padding-left: .2em;
}

.article-body li::marker {
    color: var(--storm-purple);
}

.article-body ol > li::marker {
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: var(--storm-muted);
}

.article-body li > ul,
.article-body li > ol {
    margin: .5em 0 0;
}

/* A quote is marked by the three rising dots of the growth curve, not by a
   coloured bar down its side */
.article-body blockquote {
    position: relative;
    margin: 1.8em 0;
    padding: 26px 0 0;
    font-size: 20px;
    font-style: normal;
    line-height: 1.6;
    letter-spacing: 0;
    color: var(--storm-ink);
}

.article-body blockquote::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 36px;
    height: 14px;
    background:
        radial-gradient(circle at 4px 10px, var(--storm-cyan) 3px, transparent 3.5px),
        radial-gradient(circle at 16px 7px, var(--storm-mid) 3px, transparent 3.5px),
        radial-gradient(circle at 28px 4px, var(--storm-purple) 3.5px, transparent 4px);
}

.article-body blockquote > :last-child {
    margin-bottom: 0;
}

.article-body blockquote cite {
    display: block;
    margin-top: .6em;
    font-size: 15px;
    font-style: normal;
    color: var(--storm-muted);
}

.article-body img {
    max-width: 100%;
    height: auto;
    border-radius: var(--storm-radius-s);
}

.article-body figure,
.article-body .article-media {
    margin: 2em 0;
}

.article-body figure img,
.article-body .article-media img {
    display: block;
    margin: 0 auto;
    border-radius: var(--storm-radius-m);
}

.article-body figcaption {
    margin-top: 10px;
    font-size: 14px;
    line-height: 22px;
    color: var(--storm-muted);
    text-align: center;
}

.article-embed {
    margin: 2em 0;
}

.article-embed iframe {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    border: 0;
    border-radius: var(--storm-radius-m);
}

/* Wide tables scroll inside their own box */
.article-table {
    margin: 2em 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.article-table table {
    width: 100%;
    min-width: 480px;
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
    border-collapse: collapse;
}

.article-table th,
.article-table td {
    padding: 12px 16px;
    text-align: left;
    vertical-align: top;
    border: 0;
    border-bottom: 1px solid var(--storm-line);
}

.article-table th:first-child,
.article-table td:first-child {
    padding-left: 0;
}

.article-table th:last-child,
.article-table td:last-child {
    padding-right: 0;
}

.article-table th {
    font-weight: 600;
    color: var(--storm-ink);
    border-bottom-color: var(--storm-faint);
}

.article-table tr:last-child td {
    border-bottom: 0;
}

.article-body code,
.article-body kbd,
.article-body samp {
    padding: .15em .4em;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
    font-size: .88em;
    color: var(--storm-ink);
    background: var(--storm-base);
    border-radius: 6px;
}

.article-body pre {
    margin: 2em 0;
    padding: 18px 20px;
    overflow-x: auto;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
    font-size: 15px;
    line-height: 1.6;
    tab-size: 4;
    white-space: pre;
    color: var(--storm-ink);
    background: var(--storm-base);
    border-radius: var(--storm-radius-s);
}

.article-body pre code {
    padding: 0;
    font-size: inherit;
    background: none;
    border-radius: 0;
}

.article-body mark {
    padding: 0 .2em;
    color: var(--storm-ink);
    background: var(--storm-paper-0);
    border-radius: 4px;
}

.article-body small,
.article-body sub,
.article-body sup {
    font-size: .78em;
}

/* A section break: three dots */
.article-body hr {
    width: 72px;
    height: 6px;
    margin: 2.6em auto;
    background: radial-gradient(circle, var(--storm-faint) 2.5px, transparent 3px) 0 0 / 24px 6px repeat-x;
    border: 0;
}

@media (min-width: 641px) {
    .article-body h2 {
        font-size: 30px;
        line-height: 1.2;
    }

    .article-body h3 {
        font-size: 23px;
    }

    .article-body h4 {
        font-size: 19px;
    }
}

@media (min-width: 1100px) {
    .article-body :is(h2, h3, h4)[id] {
        scroll-margin-top: 134px;
    }
}

/* --------------------------------------------------------------------------
   8. Share
   -------------------------------------------------------------------------- */

.article-share-title {
    margin: 0 0 12px;
    font-family: var(--storm-font-display);
    font-size: 16px;
    font-weight: 700;
    line-height: 24px;
    color: var(--storm-ink);
}

/* A trail of dots separates the share buttons from the table of contents */
.article-toc--rail + .article-share {
    margin-top: 22px;
    padding-top: 25px;
    background: radial-gradient(circle, var(--storm-line) 1.5px, transparent 2px) 0 0 / 9px 4px repeat-x;
}

.article-share-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.article-share-list li {
    margin: 0;
}

.article-share-list li[hidden] {
    display: none;
}

.article-share-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    font: inherit;
    color: var(--storm-ink);
    text-decoration: none;
    background-color: var(--storm-base);
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: background-color var(--storm-hover) ease, color var(--storm-hover) ease, transform var(--storm-hover) var(--storm-ease);
}

.article-share-button:hover {
    color: var(--storm-white);
    text-decoration: none;
    background-color: var(--storm-ink);
    transform: translateY(-2px);
}

.article-share-button:active {
    transform: scale(.92);
    transition-duration: var(--storm-press);
}

.article-share-button svg {
    transition: opacity var(--storm-state) ease, transform var(--storm-state) var(--storm-ease);
}

/* Copy link: the chain makes way for a check mark */
.article-share-icon-done {
    position: absolute;
    top: 12px;
    left: 12px;
    opacity: 0;
    transform: scale(.5);
}

.article-share-button--copy.is-copied,
.article-share-button--copy.is-copied:hover {
    color: var(--storm-positive, #13824B);
    background-color: var(--storm-positive-bg, #E8F7EF);
}

.article-share-button--copy.is-copied .article-share-icon-link {
    opacity: 0;
    transform: scale(.5);
}

.article-share-button--copy.is-copied .article-share-icon-done {
    opacity: 1;
    transform: none;
}

.article-share-status {
    min-height: 22px;
    margin: 8px 0 0;
    font-size: 14px;
    line-height: 22px;
    color: var(--storm-muted);
}

/* --------------------------------------------------------------------------
   9. Author, previous and next, related, call to action
   -------------------------------------------------------------------------- */

.article-author {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 44px;
    padding-top: 32px;
    background: radial-gradient(circle, var(--storm-line) 1.5px, transparent 2px) 0 0 / 9px 4px repeat-x;
}

.article-author-mark {
    display: flex;
    flex: none;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    font-family: var(--storm-font-display);
    font-size: 22px;
    font-weight: 700;
    line-height: 1;
    color: var(--storm-ink);
    background: var(--storm-base);
    border-radius: 50%;
}

.article-author-text {
    display: flex;
    flex-direction: column;
    margin: 0;
    font-size: 14px;
    line-height: 22px;
    color: var(--storm-muted);
}

.article-author-name {
    font-family: var(--storm-font-display);
    font-size: 19px;
    font-weight: 700;
    line-height: 26px;
    color: var(--storm-ink);
}

.article-more {
    margin-top: 64px;
    padding: 48px 0 80px;
    background: var(--storm-base);
}

.article-pager {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    margin-bottom: 56px;
}

.article-pager-link {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    padding: 18px 22px;
    color: var(--storm-ink);
    text-decoration: none;
    background: var(--storm-surface);
    border-radius: var(--storm-radius-m);
    transition: transform var(--storm-hover) var(--storm-ease);
}

.article-pager-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    line-height: 22px;
    color: var(--storm-muted);
    transition: color var(--storm-hover) ease;
}

.article-pager-label svg {
    flex: none;
    transition: transform var(--storm-state) var(--storm-ease);
}

.article-pager-title {
    font-family: var(--storm-font-display);
    font-size: 18px;
    font-weight: 700;
    line-height: 24px;
    text-wrap: balance;
}

.article-pager-link:hover {
    text-decoration: none;
}

.article-pager-link:hover .article-pager-label {
    color: var(--storm-purple-deep);
}

.article-pager-link--previous:hover .article-pager-label svg {
    transform: translateX(-4px);
}

.article-pager-link--next:hover .article-pager-label svg {
    transform: translateX(4px);
}

.article-pager-link:active {
    transform: scale(.985);
    transition-duration: var(--storm-press);
}

.article-related-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0 24px;
    margin-bottom: 20px;
}

.article-related-title {
    margin: 0;
    font-size: 28px;
    font-weight: 700;
    line-height: 36px;
    letter-spacing: -.01em;
}

.article-related-all {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    font-size: 15px;
    font-weight: 600;
    line-height: 24px;
    color: var(--storm-purple-deep);
    text-decoration: none;
    transition: color var(--storm-hover) ease;
}

/* One quiet offer at the end, with a corner of the dot field */
.article-cta {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    margin-top: 64px;
    padding: 28px 24px;
    overflow: hidden;
    background: var(--storm-surface);
    border-radius: var(--storm-radius-l);
    box-shadow: var(--storm-shadow);
    isolation: isolate;
}

.article-cta::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: -1;
    width: 44%;
    background: radial-gradient(circle, var(--storm-purple) 1.5px, transparent 2px) 0 0 / 14px 14px;
    opacity: .3;
    -webkit-mask-image: linear-gradient(to left, var(--storm-mask) 0%, transparent 100%);
    mask-image: linear-gradient(to left, var(--storm-mask) 0%, transparent 100%);
    pointer-events: none;
}

.article-cta-title {
    margin: 0 0 6px;
    font-size: 24px;
    font-weight: 700;
    line-height: 30px;
    letter-spacing: -.01em;
}

.article-cta-text p {
    max-width: 52ch;
    margin: 0;
    font-size: 17px;
    line-height: 28px;
    color: var(--storm-text);
}

.article-cta .button {
    flex: none;
}

@media (min-width: 641px) {
    .article-pager {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 24px;
    }

    .article-pager-link--next {
        grid-column: 2;
        align-items: flex-end;
        text-align: right;
    }
}

@media (min-width: 900px) {
    .article-cta {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 40px;
        padding: 40px 48px;
    }

    .article-cta-title {
        font-size: 28px;
        line-height: 34px;
    }
}

@media (min-width: 1100px) {
    .article-more {
        margin-top: 88px;
        padding: 64px 0 104px;
    }
}

/* --------------------------------------------------------------------------
   10. Reading progress (added by blog.js)
   -------------------------------------------------------------------------- */

.article-progress {
    position: fixed;
    top: 0;
    left: 50%;
    z-index: 1000;
    width: 100%;
    max-width: 1440px;
    height: 3px;
    pointer-events: none;
    transform: translateX(-50%);
}

.article-progress span {
    display: block;
    height: 100%;
    background: var(--storm-gradient);
    transform: scaleX(0);
    transform-origin: 0 50%;
}

/* --------------------------------------------------------------------------
   11. Focus and reduced motion
   -------------------------------------------------------------------------- */

.blog-pagination a:focus-visible,
.article-breadcrumb a:focus-visible,
.article-toc a:focus-visible,
.article-toc summary:focus-visible,
.article-body a:focus-visible,
.article-table:focus-visible,
.article-share-button:focus-visible,
.article-pager-link:focus-visible,
.article-related-all:focus-visible {
    outline: 2px solid var(--storm-purple);
    outline-offset: 2px;
}

.article-toc a:focus-visible,
.article-body a:focus-visible,
.article-related-all:focus-visible {
    border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
    .blog-index *,
    .blog-index *::before,
    .blog-index *::after,
    .article-page *,
    .article-page *::before,
    .article-page *::after {
        transition-duration: .01ms !important;
        transition-delay: 0s !important;
    }

    .blog-card:hover .blog-card-more svg,
    .blog-card:active .blog-card-more svg,
    .article-related-all:hover svg,
    .article-related-all:active svg,
    .article-pager-link:hover .article-pager-label svg,
    .article-share-button:hover,
    .article-toc summary:hover svg {
        transform: none;
    }

    .article-toc details[open] summary svg,
    .article-toc details[open] summary:hover svg {
        transform: rotate(180deg);
    }
}


/* --------------------------------------------------------------------------
   Review fixes
   -------------------------------------------------------------------------- */

/* Meta line: spacing instead of separator dots (the HTML minifier removes the
   spaces between the label and the value, so the gap is set here) */
.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 22px;
}

.article-meta li:not(:last-child)::after {
    content: none;
}

.article-meta li > strong,
.article-meta li > time {
    margin-left: .35em;
}

/* Links carry no arrow and flags no dot */
.blog-card-more svg,
.article-related-all svg {
    display: none;
}

.blog-card-flag::before {
    content: none;
}

/* The article title is the page's headline: set it large on the cover */
.article-header .storm-cover {
    aspect-ratio: auto;
    min-height: clamp(240px, 30vw, 340px);
    padding: clamp(20px, 3vw, 36px);
}

.article-header .storm-cover-title {
    max-width: 22ch;
    font-size: clamp(28px, 3.6vw, 44px);
    line-height: 1.1;
    letter-spacing: -.015em;
}

.article-header .storm-cover-kicker {
    display: none;
}

.blog-card--featured .storm-cover-title {
    font-size: clamp(22px, 2.6vw, 32px);
}

/* --------------------------------------------------------------------------
   9. Cards as boxes
   Every article sits in its own white card, so cover, date and excerpt read
   as one piece and neighbouring articles are clearly apart.
   -------------------------------------------------------------------------- */

.blog-grid {
    gap: 24px;
}

.blog-card {
    padding: 12px 12px 6px;
    background: var(--storm-surface);
    border-radius: var(--storm-radius-l);
    box-shadow: var(--storm-shadow), inset 0 0 0 1px var(--storm-shade-06);
    transition: box-shadow var(--storm-state) ease;
}

.blog-card .storm-cover {
    border-radius: var(--storm-radius-m);
}

.blog-card-body {
    padding: 16px 10px 4px;
}

.blog-card-meta {
    margin-bottom: 8px;
}

.blog-card-excerpt {
    margin-bottom: 8px;
}

/* Hover: the outline answers, the card stays where it is */
@media (hover: hover) {
    .blog-card:hover {
        box-shadow: var(--storm-shadow), inset 0 0 0 1.5px var(--storm-outline-hover);
    }
}

@media (min-width: 641px) {
    .blog-grid--related .blog-card:nth-child(3):last-child .blog-card-body {
        padding: 4px 16px 4px 0;
    }
}

@media (min-width: 1100px) {
    .blog-grid {
        gap: 32px;
    }

    .blog-card {
        padding: 14px 14px 8px;
    }

    .blog-card-body {
        padding: 18px 12px 4px;
    }

    /* The latest article: cover and text side by side inside one card */
    .blog-card--featured {
        gap: 12px;
        padding: 14px;
    }

    .blog-card--featured .blog-card-body {
        padding: 12px 30px 12px 26px;
    }

    .blog-grid--related .blog-card:nth-child(3):last-child .blog-card-body {
        padding: 18px 12px 4px;
    }
}
