/*
Theme Name:   The READ
Theme URI:    https://theread.online
Description:  Newspaper child theme for The READ. Built on GeneratePress. Customizations live
              here so they survive parent theme updates.
Author:       The READ
Template:     generatepress
Version:      1.0.0
Text Domain:  theread
*/

/* ==========================================================================
   Typography — a newspaper reads serif for headlines, sans for furniture
   ========================================================================== */

:root {
    --read-ink:        #16150f;
    --read-ink-soft:   #55524a;
    --read-rule:       #d8d4c8;
    --read-paper:      #fdfcf8;
    --read-accent:     #8c2f1e;   /* section flags, category labels */
    --read-serif:      Georgia, "Iowan Old Style", "Times New Roman", serif;
    --read-sans:       "Helvetica Neue", Helvetica, Arial, sans-serif;
}

body {
    background: var(--read-paper);
    color: var(--read-ink);
}

h1, h2, h3, h4,
.entry-title,
.site-title {
    font-family: var(--read-serif);
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.15;
}

/* ==========================================================================
   Masthead
   ========================================================================== */

.site-header {
    border-bottom: 3px double var(--read-ink);
}

.site-title {
    font-size: clamp(2rem, 6vw, 3.5rem);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.site-description {
    font-family: var(--read-sans);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--read-ink-soft);
}

/* ==========================================================================
   Article furniture — dek, byline, photo credit
   These are output by the theread-core plugin.
   ========================================================================== */

.read-dek {
    font-family: var(--read-serif);
    font-size: 1.25rem;
    line-height: 1.45;
    color: var(--read-ink-soft);
    margin: 0.4em 0 0.8em;
    font-style: italic;
}

.read-byline {
    font-family: var(--read-sans);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    color: var(--read-ink-soft);
    padding: 0.5em 0;
    border-top: 1px solid var(--read-rule);
    border-bottom: 1px solid var(--read-rule);
    display: inline-block;
}

.read-byline .read-byline-name {
    color: var(--read-ink);
    font-weight: 700;
}

.read-photo-credit,
.wp-caption .wp-caption-text {
    font-family: var(--read-sans);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--read-ink-soft);
}

/* Section flag / category label above a headline */
.read-flag {
    font-family: var(--read-sans);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: var(--read-accent);
    display: block;
    margin-bottom: 0.35em;
}

/* Issue badge — e.g. "September 2026" */
.read-issue-badge {
    font-family: var(--read-sans);
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--read-ink-soft);
    border: 1px solid var(--read-rule);
    padding: 0.2em 0.55em;
    border-radius: 2px;
    display: inline-block;
}

/* ==========================================================================
   Body copy — measure and rhythm matter more than anything else here
   ========================================================================== */

.entry-content {
    font-family: var(--read-serif);
    font-size: 1.0625rem;
    line-height: 1.65;
}

.entry-content p {
    margin-bottom: 1.15em;
}

/* Drop the first paragraph's indent, indent the rest — newspaper convention */
.entry-content > p + p {
    text-indent: 1.2em;
}

.entry-content blockquote {
    font-family: var(--read-serif);
    font-size: 1.35rem;
    line-height: 1.35;
    font-style: italic;
    border: none;
    border-top: 2px solid var(--read-ink);
    border-bottom: 2px solid var(--read-ink);
    padding: 0.7em 0;
    margin: 1.6em 0;
    text-align: center;
    text-indent: 0;
}

.entry-content blockquote p { text-indent: 0; }

/* ==========================================================================
   Archive / front page listing
   ========================================================================== */

.generate-columns .inside-article {
    border-bottom: 1px solid var(--read-rule);
    padding-bottom: 1.2em;
}

.entry-title a { text-decoration: none; }
.entry-title a:hover { text-decoration: underline; }

/* ==========================================================================
   Editions grid — used by the network landing page shortcode
   ========================================================================== */

.read-editions {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.75rem;
    margin: 2rem 0;
    padding: 0;
    list-style: none;
}

.read-edition {
    border: 1px solid var(--read-rule);
    background: #fff;
    display: flex;
    flex-direction: column;
}

.read-edition__cover {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: var(--read-rule);
}

.read-edition__cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.read-edition__body { padding: 1rem 1.1rem 1.3rem; }

.read-edition__name {
    font-family: var(--read-serif);
    font-size: 1.3rem;
    margin: 0 0 0.15em;
}

.read-edition__name a { text-decoration: none; color: var(--read-ink); }
.read-edition__name a:hover { text-decoration: underline; }

.read-edition__region {
    font-family: var(--read-sans);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--read-accent);
    display: block;
    margin-bottom: 0.6em;
}

.read-edition__blurb {
    font-family: var(--read-serif);
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--read-ink-soft);
    margin: 0 0 1em;
}

.read-edition__link {
    font-family: var(--read-sans);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    text-decoration: none;
    color: var(--read-accent);
}

.read-edition__link:hover { text-decoration: underline; }

/* ==========================================================================
   Forms — event submission and contact
   ========================================================================== */

.read-event-form,
.fluentform {
    max-width: 44rem;
    margin: 1.5rem 0;
}

.read-form-intro,
.read-field-note {
    font-family: var(--read-sans);
    font-size: 0.85rem;
    color: var(--read-ink-soft);
}

.read-field { margin: 0 0 1.1rem; }

.read-field label {
    display: block;
    font-family: var(--read-sans);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.3em;
}

.read-field input,
.read-field textarea {
    width: 100%;
    font-family: var(--read-sans);
    font-size: 1rem;
    padding: 0.55em 0.65em;
    border: 1px solid var(--read-rule);
    background: #fff;
    border-radius: 2px;
}

.read-field input:focus,
.read-field textarea:focus {
    outline: 2px solid var(--read-accent);
    outline-offset: 1px;
    border-color: var(--read-accent);
}

/* Two fields side by side on wider screens, stacked on phones */
.read-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 1rem;
}

@media (max-width: 600px) {
    .read-field-row { grid-template-columns: 1fr; }
}

.read-fieldset {
    border: 1px solid var(--read-rule);
    padding: 1rem 1.1rem 0.4rem;
    margin: 0 0 1.2rem;
}

.read-fieldset legend {
    font-family: var(--read-sans);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 0 0.5em;
}

.read-submit button {
    font-family: var(--read-sans);
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    background: var(--read-ink);
    color: #fff;
    border: none;
    padding: 0.85em 1.8em;
    cursor: pointer;
    border-radius: 2px;
}

.read-submit button:hover { background: var(--read-accent); }

/* The honeypot must be invisible to humans but still reachable by bots —
   display:none is sometimes skipped by bots, so move it out of view instead. */
.read-hp {
    position: absolute !important;
    left: -9999px !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.read-form-notice {
    padding: 0.9em 1.1em;
    margin: 0 0 1.2rem;
    border-left: 4px solid var(--read-rule);
    font-family: var(--read-sans);
    font-size: 0.95rem;
}

.read-form-notice--ok    { border-left-color: #106b21; background: #f2f9f3; }
.read-form-notice--error { border-left-color: #a3211a; background: #fdf3f2; }

.read-turnstile { margin-bottom: 1.1rem; }

/* ==========================================================================
   Print — readers do print articles
   ========================================================================== */

@media print {
    .site-header nav,
    .sidebar,
    .site-footer,
    .read-edition__link { display: none !important; }

    body { background: #fff; font-size: 11pt; }
    .entry-content { font-size: 11pt; }
}
