/* Shared font aliases use the same bundled faces on the homepage and magazine. */
@font-face { font-family: HudsonText; src: url('/assets/HudsonText50.woff') format('woff'); font-weight: 400; font-display: swap; }
@font-face { font-family: HudsonText; src: url('/assets/HudsonText75.woff') format('woff'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Hudson Text 50'; src: url('/assets/HudsonText50.woff') format('woff'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Hudson Text 75'; src: url('/assets/HudsonText75.woff') format('woff'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Hudson Display 50'; src: url('/assets/HudsonDisplay50.woff') format('woff'); font-weight: 400; font-display: swap; }
@font-face { font-family: HudsonDisplay; src: url('/assets/HudsonDisplay50.woff') format('woff'); font-weight: 400; font-display: swap; }

/* Public feed cards have no dividing rules; keep section flags and footers intact. */
body:not(.studio-screen) :is(.article-item,.index-entry,.profile-story,.continuation-story) {
    border-top: 0 !important;
    border-bottom: 0 !important;
}
/* Numeric prefixes are hidden, but the homepage category labels (div) remain. */
body :is(a.post-number,p.post-number,.daily-number) { display: none !important; }
/* Existing archive/access emblem: thin outlined circle, black artwork. */
body .editra-lock-icon {
    box-sizing: border-box;
    background: transparent;
    border: 1px solid #cccccc;
}
body .editra-lock-icon svg,
body .editra-lock-icon svg path { fill: #000; stroke: none; }

/* Related content is a separate section, including dynamically appended flags. */
body .article-continuation > .edition-flag,
body .notes-continuation > .edition-flag,
body .reading-magazine > :is(.article-continuation,.notes-continuation) > .edition-flag:first-child,
body .reading-magazine > .article-continuation > .edition-flag.category-continuation-flag:first-child {
    margin-block: 80px 40px !important;
}

/* Related section labels use the same appearance when linked. */
body .article-continuation > .edition-flag > a { color: inherit; font: inherit; letter-spacing: inherit; text-decoration: none; }
body .article-continuation > .edition-flag > a:hover { text-decoration: underline; }
body .daily-magazine .daily-note > .daily-recent { margin-block-end: 128px; }

/* Match article caption typography on every public post, independent of reading size. */
body:not(.studio-screen) :is(.public-magazine,#content) :is(.article-item,.index-entry,.article-body,.story-images,.photo-view,.profile-story) :is(figcaption,.image-credit,.single-image-credit,.wp-element-caption,.figcap),
body:not(.studio-screen) :is(.public-magazine,#content) :is(.article-item,.index-entry,.article-body,.story-images,.photo-view,.profile-story) :is(figcaption,.image-credit,.single-image-credit,.wp-element-caption,.figcap) :is(p,a,span) {
    font: normal 400 11px/19px HudsonText, sans-serif !important;
    letter-spacing: 1px !important;
}

/* Add 20px between posts, without adding space to the first card or to section flags.
   Padding adds the same spacing even when the existing vertical margins collapse. */
body:not(.studio-screen) #content .post-group > .article-item + .article-item,
body .public-magazine .notes-continuation [data-continuation-entries] > .article-item + .article-item,
body .public-magazine .category-designed .category-story + .category-story,
body .category-designed .post-group > .category-story + .category-story,
body .article-continuation [data-continuation-entries] > .continuation-story + .continuation-story,
body .public-magazine:not(.daily-magazine) .article-item + .article-item {
    padding-block-start: 20px;
}
body .daily-magazine .daily-articles > .article-item + .article-item { padding-block-start: 40px; }
body .public-magazine .index-entry + .index-entry { margin-block-start: calc(clamp(24px,5vw,38px) + 20px); }
body .profile-page .profile-publications .profile-story + .profile-story,
body.profile-page .profile-publications .profile-story + .profile-story { padding-block-start: 37px; }
/* Continuation cards already gain their 20px through the index-entry margin. */
body .article-continuation [data-continuation-entries] > .continuation-story + .continuation-story { padding-block-start: 0; margin-block-start: 0; }
body .article-continuation .continuation-story:has(+ .continuation-story) { margin-block-end: calc(clamp(48px,8vw,64px) + 20px); }

body .search-sections { display:flex; gap:0; flex-wrap:nowrap; border-bottom:1px solid #ccc; margin-block: 16px 56px; }
body .search-sections > a { display:inline-flex; flex:1 1 0; justify-content:center; align-items:center; min-height:36px; font:400 16px/24px 'Hudson Text 50',HudsonText,serif !important; letter-spacing:.6px !important; text-decoration:none; border-bottom:1px solid transparent; margin-bottom:-1px; }
body .search-sections > a[aria-current="page"] { text-decoration:none; border-bottom-color:currentColor; }
body .search-sections > a:hover { text-decoration:none; }
body:not(.studio-screen) .post-start-byline { display:flex; flex-wrap:wrap; align-items:center; gap:6px; margin:12px 0 10px !important; padding:0; text-align:left; }
body:not(.studio-screen) .post-start-byline,
body:not(.studio-screen) .post-start-byline :is(a,span) { font:400 15px/1.5 'Hudson Text 75',HudsonText,sans-serif !important; letter-spacing:.6px !important; font-style:normal !important; }
body:not(.studio-screen) .post-start-byline a { display:inline-flex !important; align-items:center; gap:6px; text-decoration:none; }
body:not(.studio-screen) .post-start-byline img.author-avatar-inline { display:inline-block; width:20px; height:20px; max-width:20px; object-fit:cover; margin:0; border-radius:50%; }
body .supporter-notice form { margin:0; }

/* Keep editorial photographs level; do not alter covers, spinning records or avatars. */
body:not(.studio-screen) :is(.post-featured-image,.post-image-wrapper .back-photo,.story-stack img,.category-stack img,.editra-tilted-image,.issue-image-frame) {
    transform: none !important;
    rotate: none !important;
}
/* Captions belong below the image, not inside a negative-margin overlap. */
body:not(.studio-screen) :is(.public-magazine,#content) :is(.article-item,.profile-story) > a:has(+ .post-excerpt > .image-credit:first-child) > :is(.post-image-wrapper,.recent-note-image-wrapper) {
    margin-block-end: 0;
}
body:not(.studio-screen) :is(.public-magazine,#content) :is(.article-item,.profile-story) > a:has(> :is(.post-image-wrapper,.recent-note-image-wrapper)) + .post-excerpt:has(> .image-credit:first-child) {
    margin-block-start: 10px;
    padding-block-start: 0;
}
body:not(.studio-screen) :is(.public-magazine,#content) .post-excerpt > p.image-credit {
    margin-block: 0 10px;
    padding-block: 0;
}
body:not(.studio-screen) :is(.public-magazine,#content) figure > figcaption.image-credit {
    margin-block-start: 0;
    padding-block-start: 10px;
}
/* Notes need more breathing room, while category photos sit closer to their bylines. */
body:not(.studio-screen) :is(.notes-magazine,.notes-continuation) .post-start-byline:has(+ .post-link-container > .post-image-wrapper) {
    margin-block-end: 20px !important;
}
body:not(.studio-screen) .category-magazine .post-start-byline:has(+ figure) {
    margin-block-end: 0 !important;
}

/* Match the profile dropdown links while submitting logout securely. */
body #header #menu_column .public-profile-menu nav > form.public-profile-logout {
    display:block; margin:0; padding:0; border:0; background:transparent;
}
body #header #menu_column .public-profile-menu nav > form.public-profile-logout > button {
    display:block; box-sizing:border-box; width:100%; min-height:0; height:auto;
    margin:0; padding:5px 8px; border:0; border-radius:0; box-shadow:none;
    background:transparent; color:inherit; font:14px/1.4 "Hudson Text 50",HudsonText,serif;
    letter-spacing:.6px; text-transform:none; text-align:inherit; cursor:pointer;
}
body #header #menu_column .public-profile-menu nav > form.public-profile-logout > button:is(:hover,:focus-visible) {
    text-decoration:underline; background:transparent;
}

/* Keep the About copy centered and reserve its actions' space throughout typing. */
body.about-page main.public-magazine {
    display:grid; align-items:center; box-sizing:border-box;
    min-height:100vh; min-height:100svh;
    width:100%; margin:0 auto; padding:76px 20px;
}
body.about-page main.public-magazine > .about-editra {
    box-sizing:border-box; width:100%; max-width:500px; margin:0 auto;
}
body.about-page .about-editra > p { margin:0; }
body.about-page > .publication-footer { display:none; }
body.about-page .about-editra.is-typing .colophon-actions { visibility:hidden; }
@media (prefers-reduced-motion:no-preference) {
    body.about-page .about-editra.typing-complete .colophon-actions > * {
        animation:editra-about-action-in .35s ease both;
    }
    body.about-page .about-editra.typing-complete .colophon-actions > :nth-child(2) { animation-delay:.12s; }
    body.about-page .about-editra.typing-complete .colophon-actions > :nth-child(3) { animation-delay:.24s; }
}
@keyframes editra-about-action-in { from {opacity:0;transform:translateY(5px)} to {opacity:1;transform:translateY(0)} }
@media (max-width:545px) {
    body.about-page main.public-magazine { min-height:calc(100svh - 40px); padding:64px 0; }
}
/* Login's secondary action uses the existing outlined control treatment. */
body.account-screen .account-login a.account-apply-link {
    display:inline-flex; width:100%; min-height:35px; margin-top:16px;
    font:400 15px/1.2 HudsonText,serif; letter-spacing:.6px;
}
