/* Native article blocks and the WordPress editor share the same defaults.
 * Explicit block colors, sizes and inline author styles take precedence. */
:is(.article-content, .editor-styles-wrapper) {
    --article-link: var(--blue-hover);
    line-height: 1.85;
}
[data-theme="dark"] .article-content { --article-link: #69b7ff; }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme]) .article-content { --article-link: #69b7ff; }
}
:is(.article-content, .editor-styles-wrapper) :where(p, ul, ol, dl) { margin-block: 0 1.3em; }
:is(.article-content, .editor-styles-wrapper) :where(h2, h3, h4, h5, h6) {
    margin-block: 1.8em .7em;
    line-height: 1.3;
    font-weight: 600;
    letter-spacing: -.035em;
    scroll-margin-top: 110px;
}
:is(.article-content, .editor-styles-wrapper) :where(h4) { font-size: 1.15em; }
:is(.article-content, .editor-styles-wrapper) :where(h5) { font-size: 1em; }
:is(.article-content, .editor-styles-wrapper) :where(h6) { font-size: .9em; }
.article-shell .article-content > h1 { font-size: clamp(28px, 3.2vw, 40px); line-height: 1.25; font-weight: 600; }
:is(.article-content, .editor-styles-wrapper) h2 { font-size: 24px; }
:is(.article-content, .editor-styles-wrapper) h3 { font-size: 20px; }
.post-card .post-title, .post-card h2, .post-card h3 { font-size: 17px; line-height: 1.5; font-weight: 600; letter-spacing: -.025em; }
:is(.article-content, .editor-styles-wrapper) :is(.wp-block-column, .wp-block-group) > :is(h2, h3, h4):first-child { margin-top: 0; }
:is(.article-content, .editor-styles-wrapper) :where(a:not(.button, .cta-button, .wp-element-button, .wp-block-button__link, .wp-block-file__button)) {
    color: var(--article-link);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: .18em;
}
:is(.article-content, .editor-styles-wrapper) :where(ul, ol) { padding-inline-start: 1.5em; }
:is(.article-content, .editor-styles-wrapper) :where(li) { margin-block: .4em; padding-inline-start: .15em; }
:is(.article-content, .editor-styles-wrapper) :where(li > ul, li > ol) { margin-block: .5em 0; }
:is(.article-content, .editor-styles-wrapper) :where(li > p:last-child) { margin-bottom: 0; }
:is(.article-content, .editor-styles-wrapper) :where(dt) { font-weight: 600; }
:is(.article-content, .editor-styles-wrapper) :where(dd) { margin: .3em 0 1em 1.5em; }
:is(.article-content, .editor-styles-wrapper) hr {
    border: 0;
    border-top: 1px solid var(--line);
    margin-block: 2.5em;
    color: var(--line);
}
/* More specific than article links and WordPress's default gray buttons. */
:is(.article-content, .editor-styles-wrapper) .wp-block-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-block: 1.4em;
}
:is(.article-content, .editor-styles-wrapper) .wp-block-button { max-width: 100%; }
.article-content a.button { text-decoration: none; }
.article-content a.button-primary { color: #fff; }
.article-content a.button-secondary { color: var(--text); }
:is(.article-content, .editor-styles-wrapper) :is(.wp-block-button__link, .wp-element-button, .wp-block-file__button),
:is(.article-shell, .editor-styles-wrapper) :is(button[type="submit"], input[type="submit"], input[type="button"], input[type="reset"]) {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 48px;
    max-width: 100%;
    padding: 12px 21px;
    border: 1px solid transparent;
    border-radius: 10px;
    font: 600 14px/1.5 "Poppins", sans-serif;
    text-decoration: none;
    text-align: center;
    overflow-wrap: anywhere;
    white-space: normal;
    cursor: pointer;
    box-shadow: 0 5px 15px #0276db20;
    transition: background-color .2s, box-shadow .2s, transform .2s;
}
:is(.article-content, .editor-styles-wrapper) :is(.wp-block-button__link, .wp-element-button, .wp-block-file__button):not(.has-background),
:is(.article-shell, .editor-styles-wrapper) :is(button[type="submit"], input[type="submit"], input[type="button"], input[type="reset"]) {
    background-color: var(--button-blue, #0276db);
}
:is(.article-content, .editor-styles-wrapper) :is(.wp-block-button__link, .wp-element-button, .wp-block-file__button):not(.has-text-color),
:is(.article-shell, .editor-styles-wrapper) :is(button[type="submit"], input[type="submit"], input[type="button"], input[type="reset"]) {
    color: #fff;
}
:is(.article-content, .editor-styles-wrapper) .is-style-outline > .wp-block-button__link {
    border-color: currentColor;
    box-shadow: none;
}
:is(.article-content, .editor-styles-wrapper) .is-style-outline > .wp-block-button__link:not(.has-background) { background-color: transparent; }
:is(.article-content, .editor-styles-wrapper) .is-style-outline > .wp-block-button__link:not(.has-text-color) { color: var(--article-link); }
:is(.article-content, .editor-styles-wrapper) :is(.wp-block-button__link, .wp-element-button, .wp-block-file__button):hover,
:is(.article-shell, .editor-styles-wrapper) :is(button[type="submit"], input[type="submit"]):hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px #0276db30;
}
:is(.article-content, .editor-styles-wrapper) :is(.wp-block-button__link, .wp-element-button, .wp-block-file__button):not(.has-background):hover,
:is(.article-shell, .editor-styles-wrapper) :is(button[type="submit"], input[type="submit"]):hover { background-color: var(--button-blue-hover, #0064bc); }
:is(.article-content, .editor-styles-wrapper) .is-style-outline > .wp-block-button__link:not(.has-background):hover { background-color: var(--soft-blue); }
/* Quotes, code, media and tables remain readable in both appearances. */
:is(.article-content, .editor-styles-wrapper) blockquote {
    margin: 1.8em 0;
    padding: 20px 24px;
    border: 1px solid var(--line);
    border-inline-start: 3px solid var(--blue);
    border-radius: 0 12px 12px 0;
    background: var(--surface);
}
:is(.article-content, .editor-styles-wrapper) blockquote > p:last-of-type { margin-bottom: 0; }
:is(.article-content, .editor-styles-wrapper) :where(cite, figcaption) { font-size: .8em; line-height: 1.6; color: var(--muted); }
:is(.article-content, .editor-styles-wrapper) cite { display: block; margin-top: 12px; font-style: normal; }
:is(.article-content, .editor-styles-wrapper) :where(code, kbd, samp, pre) {
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    font-size: .85em;
}
:is(.article-content, .editor-styles-wrapper) :where(code, kbd, samp) { background: var(--surface); border-radius: 5px; padding: .15em .4em; }
:is(.article-content, .editor-styles-wrapper) pre {
    max-width: 100%;
    overflow: auto;
    padding: 20px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface);
    color: var(--text);
    line-height: 1.75;
    tab-size: 4;
}
:is(.article-content, .editor-styles-wrapper) pre code { padding: 0; font-size: inherit; background: transparent; }
:is(.article-content, .editor-styles-wrapper) :where(figure) { margin-inline: 0; }
:is(.article-content, .editor-styles-wrapper) :where(img, video, iframe) { max-width: 100%; border-radius: 12px; }
:is(.article-content, .editor-styles-wrapper) .wp-block-image img { margin-block: 0; }
:is(.article-content, .editor-styles-wrapper) figcaption { margin-top: 10px; text-align: center; }
:is(.article-content, .editor-styles-wrapper) .wp-block-table { max-width: 100%; overflow-x: auto; margin-block: 1.8em; }
:is(.article-content, .editor-styles-wrapper) table { border-collapse: collapse; width: 100%; font-size: .85em; line-height: 1.65; }
:is(.article-content, .editor-styles-wrapper) > table { display: block; overflow-x: auto; }
:is(.article-content, .editor-styles-wrapper) :is(th, td) { padding: 13px 16px; border: 1px solid var(--line); text-align: start; }
:is(.article-content, .editor-styles-wrapper) th { font-weight: 600; background: var(--surface); }
:is(.article-content, .editor-styles-wrapper) .is-style-stripes tbody tr:nth-child(odd) { background: var(--surface); }
:is(.article-content, .editor-styles-wrapper) details { border: 1px solid var(--line); border-radius: 12px; padding: 16px 20px; margin-block: 1.5em; }
:is(.article-content, .editor-styles-wrapper) summary { font-weight: 600; cursor: pointer; }
:is(.article-content, .editor-styles-wrapper) details[open] summary { margin-bottom: 12px; }
/* Native comments and search forms, with visible keyboard focus. */
.article-comments { margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--line); }
.article-comments h2 { margin-bottom: 24px; font-size: 24px; }
.article-comments label { display: block; font-weight: 500; font-size: 14px; margin-bottom: 8px; }
:is(.article-shell, .editor-styles-wrapper) :is(input:not([type="submit"], [type="button"], [type="reset"], [type="checkbox"], [type="radio"], [type="hidden"]), textarea, select) {
    width: 100%;
    max-width: 100%;
    min-height: 46px;
    padding: 11px 14px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: var(--surface-raised);
    color: var(--text);
    font: inherit;
}
.article-comments textarea { min-height: 150px; resize: vertical; }
.article-comments .comment-form-cookies-consent { display: flex; align-items: flex-start; gap: 10px; }
.article-comments .comment-form-cookies-consent input { margin-top: 6px; accent-color: var(--blue); }
.article-comments .comment-form-cookies-consent label { font-weight: 400; }
:is(.article-shell, .editor-styles-wrapper) :is(a, button, input, textarea, select, summary):focus-visible { outline: 3px solid var(--blue); outline-offset: 4px; }
@media (max-width: 600px) {
    :is(.article-content, .editor-styles-wrapper) h2 { font-size: 21px; }
    :is(.article-content, .editor-styles-wrapper) h3 { font-size: 18px; }
    :is(.article-content, .editor-styles-wrapper) .wp-block-buttons { gap: 10px; }
    :is(.article-content, .editor-styles-wrapper) blockquote { padding: 16px 18px; }
    :is(.article-content, .editor-styles-wrapper) :is(th, td) { padding: 10px 12px; }
}
@media (prefers-reduced-motion: reduce) {
    :is(.article-content, .editor-styles-wrapper) :is(.wp-block-button__link, .wp-element-button, .wp-block-file__button),
    .article-shell :is(button[type="submit"], input[type="submit"]) { transition: none; transform: none; }
}
