/* Upper West Side Dad — "Printed Black" theme
   Mirrors uwsdad.com landing page exactly:
   pure black, DM Sans, white solid inputs, zero radius. */

:root {
    --black: #000000;
    --white: #ffffff;
    --white-90: rgba(255, 255, 255, 0.9);
    --white-80: rgba(255, 255, 255, 0.8);
    --white-60: rgba(255, 255, 255, 0.6);
    --white-50: rgba(255, 255, 255, 0.5);
    --white-40: rgba(255, 255, 255, 0.4);
    --white-30: rgba(255, 255, 255, 0.3);
    --white-15: rgba(255, 255, 255, 0.15);
    --sans: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { font-size: 100%; -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--sans);
    background: var(--black);
    color: var(--white);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: inherit; }

::selection { background: var(--white); color: var(--black); }

/* ---- Layout: narrow column, like the landing page ---- */

.container {
    width: 100%;
    max-width: 28rem;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.container-wide {
    max-width: 44rem;
}

.site-main { min-height: 60vh; }

/* ---- Masthead (inner pages; hidden on home) ---- */

.masthead {
    padding: 2rem 0 0;
}

.home-template .masthead { display: none; }

.masthead-title {
    font-family: var(--sans);
    font-weight: 900;
    font-size: 1.5rem;
    letter-spacing: -0.03em;
    text-transform: uppercase;
    text-decoration: none;
    line-height: 1;
    display: inline-block;
}

.masthead-title .tld { color: var(--white-40); }

.masthead-logo { max-height: 44px; width: auto; }

.masthead-nav {
    margin-top: 1rem;
}

.masthead-nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
}

.masthead-nav a {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-decoration: none;
    color: var(--white-50);
}

.masthead-nav a:hover,
.masthead-nav li.nav-current a { color: var(--white); }

/* ---- Home hero — the stacked wordmark ---- */

.hero {
    padding: 3rem 0 1rem;
}

.hero-wordmark {
    font-weight: 900;
    line-height: 0.85;
    letter-spacing: -0.03em;
    font-size: clamp(4.5rem, 24vw, 8rem);
    text-transform: uppercase;
    user-select: none;
    text-decoration: none;
    display: block;
}

.hero-wordmark .tld { color: var(--white-40); }

.hero-sub {
    margin-top: 2rem;
    font-size: 1.125rem;
    line-height: 1.375;
    font-weight: 500;
    color: var(--white-90);
}

.hero-sub strong { color: var(--white); font-weight: 700; }

/* ---- Subscribe form — solid white fields, white block button ---- */

.subscribe { margin-top: 2.5rem; }

.subscribe-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.subscribe-form input[type="text"],
.subscribe-form input[type="email"] {
    width: 100%;
    background: var(--white);
    color: var(--black);
    font-family: var(--sans);
    font-size: 1.125rem;
    font-weight: 600;
    padding: 1rem 1.25rem;
    border: none;
    border-radius: 0;
    outline: none;
    appearance: none;
}

.subscribe-form input::placeholder { color: rgba(0, 0, 0, 0.5); }

.subscribe-form input:focus {
    box-shadow: 0 0 0 4px var(--white-50);
}

.btn,
.subscribe-form button[type="submit"] {
    display: block;
    width: 100%;
    margin-top: 0.5rem;
    background: var(--white);
    color: var(--black);
    font-family: var(--sans);
    font-size: 1.25rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    text-align: center;
    text-decoration: none;
    padding: 1.25rem 1.5rem;
    border: none;
    border-radius: 0;
    cursor: pointer;
    transition: transform 0.1s ease;
}

.btn:active,
.subscribe-form button[type="submit"]:active { transform: scale(0.99); }

.btn-inline {
    display: inline-block;
    width: auto;
    font-size: 1rem;
    padding: 0.875rem 1.75rem;
}

.microcopy {
    font-size: 0.75rem;
    line-height: 1.375;
    color: var(--white-50);
}

.form-message { display: none; font-weight: 600; font-size: 1rem; }
.success[data-members-success] { color: var(--white); }
.error[data-members-error] { color: #f87171; }
.success .form-message.success,
form.success .form-message.success { display: block; }
form.error .form-message.error { display: block; }

/* Confirmation-style box (matches landing "You're on the list.") */
.confirm-box {
    margin-top: 2.5rem;
    border: 4px solid var(--white);
    padding: 1.5rem;
}

.confirm-box .confirm-title {
    font-size: 1.5rem;
    font-weight: 900;
    text-transform: uppercase;
}

.confirm-box p { margin-top: 0.75rem; color: var(--white-80); }

/* ---- Section headings ---- */

.kicker {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--white-50);
    text-decoration: none;
}

.section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.02em;
}

.editions { padding: 4rem 0 2rem; }

/* ---- Edition cards / lists ---- */

.edition-grid {
    display: flex;
    flex-direction: column;
}

.edition-card {
    border-top: 1px solid var(--white-15);
}

.edition-link {
    display: block;
    padding: 1.5rem 0;
    text-decoration: none;
}

.edition-date { margin-bottom: 0.5rem; }

.edition-title {
    font-size: 1.375rem;
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: -0.02em;
}

.edition-link:hover .edition-title { text-decoration: underline; text-underline-offset: 4px; }

.edition-excerpt {
    margin-top: 0.5rem;
    color: var(--white-60);
    font-size: 0.9375rem;
    line-height: 1.5;
}

.archive-list { list-style: none; }

.archive-item { border-top: 1px solid var(--white-15); }

.archive-link {
    display: flex;
    gap: 1.25rem;
    padding: 1.25rem 0;
    text-decoration: none;
    align-items: baseline;
}

.archive-date {
    flex: 0 0 auto;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--white-40);
}

.archive-entry-title { font-weight: 700; }
.archive-link:hover .archive-entry-title { text-decoration: underline; text-underline-offset: 4px; }

.archive-excerpt {
    display: block;
    margin-top: 0.25rem;
    color: var(--white-60);
    font-size: 0.875rem;
}

.empty {
    border: 4px solid var(--white);
    padding: 1.5rem;
    font-weight: 600;
    color: var(--white-80);
}

/* ---- Post / page ---- */

.issue { padding: 3rem 0; }

.issue-header { margin-bottom: 2rem; }

.issue-date { margin-bottom: 1rem; }

.issue-title {
    font-size: clamp(2.25rem, 8vw, 3.25rem);
    font-weight: 900;
    line-height: 0.95;
    letter-spacing: -0.03em;
    text-transform: uppercase;
}

.issue-sub {
    margin-top: 1.25rem;
    font-size: 1.125rem;
    font-weight: 500;
    color: var(--white-90);
}

.byline {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--white-50);
    margin-bottom: 2rem;
}

.byline-rule { flex: 1; height: 1px; background: var(--white-15); }

.issue-feature { margin: 0 0 2rem; }
.issue-feature figcaption {
    margin-top: 0.5rem;
    font-size: 0.75rem;
    color: var(--white-40);
}

.post-content {
    font-size: 1.0625rem;
    line-height: 1.7;
    color: var(--white-90);
}

.post-content > * + * { margin-top: 1.25rem; }

.post-content h2,
.post-content h3 {
    color: var(--white);
    font-weight: 900;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    margin-top: 2.5rem;
}

.post-content h2 { font-size: 1.5rem; }
.post-content h3 { font-size: 1.1875rem; }

.post-content a { color: var(--white); text-underline-offset: 3px; }

.post-content blockquote {
    border-left: 4px solid var(--white);
    padding-left: 1.25rem;
    font-weight: 600;
    color: var(--white);
}

.post-content ul, .post-content ol { padding-left: 1.5rem; }

.post-content hr {
    border: none;
    border-top: 4px solid var(--white);
    margin: 2.5rem 0;
}

.post-content code {
    background: var(--white-15);
    padding: 0.125rem 0.375rem;
    font-size: 0.9em;
}

.post-cta {
    margin-top: 3rem;
    border: 4px solid var(--white);
    padding: 1.5rem;
}

.post-cta-title {
    font-size: 1.375rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.02em;
    margin: 0.5rem 0 1.25rem;
}

.issue-foot { margin-top: 3rem; }

.text-link { color: var(--white); }

/* ---- Tag / author ---- */

.tag-header, .author-header { padding-top: 3rem; }
.tag-name, .author-name {
    font-size: clamp(2rem, 8vw, 3rem);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    line-height: 0.95;
}
.tag-description, .author-bio { margin-top: 1rem; color: var(--white-80); }
.author-avatar { width: 72px; height: 72px; object-fit: cover; margin-bottom: 1rem; }

/* ---- Pagination ---- */

.pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 0;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}
.pagination a { text-decoration: none; color: var(--white); }
.pagination a:hover { text-decoration: underline; }
.page-number { color: var(--white-40); }

/* ---- Footer — matches landing footer ---- */

.site-footer {
    padding: 3rem 0 1.5rem;
}

.footer-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.footer-nav a {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--white-50);
    text-decoration: none;
}

.footer-nav a:hover { color: var(--white); }

.footer-meta {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--white-30);
}

.footer-meta a {
    color: inherit;
    text-underline-offset: 2px;
}

.footer-meta a:hover { color: var(--white-60); }

/* ---- Ghost Portal overrides ---- */

.gh-portal-btn, .gh-post-upgrade-cta a {
    border-radius: 0 !important;
}

/* ---- Archive page ---- */

.archive { padding: 3rem 0; }
.archive-header { margin-bottom: 2rem; }
.archive-page-title {
    font-size: clamp(2.25rem, 10vw, 3.5rem);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    line-height: 0.9;
    margin-top: 0.5rem;
}

/* ---- Accessibility ---- */

.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ---- Error page ---- */

.error-page { padding: 5rem 0; }
.error-code {
    font-size: clamp(4.5rem, 24vw, 8rem);
    font-weight: 900;
    line-height: 0.85;
    letter-spacing: -0.03em;
}
.error-message { margin-top: 1.5rem; font-size: 1.125rem; color: var(--white-90); font-weight: 500; }
