/*
 * News & Diary (1 Oct 2026). Loaded on an article, the News page, a category, and any page holding
 * the homepage's Latest news band (inc/assets.php), and on the editor canvas (inc/setup.php).
 *
 * kcc.css styles the approved article: meta line, opening line, paragraphs, h2, figure, share row.
 * An article is now written freely in the editor, so the rest of what an editor can type (h3,
 * lists, quotes, links, bold) is set here in the same voice as the site's other prose (.prose).
 * The cards gain the date and the author, both read from the post.
 */

/* ---------- the article ----------
   One column of text, 780px (about 75 characters of the body face), with photographs that break
   out wider than it. Everything the editor can type has a style: opening line, paragraphs, h2, h3,
   bulleted and numbered lists, quotes, bold, italic, links and photographs. */
section.section > article.article{--measure:780px;max-width:var(--measure)}

/* the byline: who, when, how long, and where it is filed */
.article-byline{display:flex;align-items:center;gap:1.1rem;padding-bottom:1.6rem;margin-bottom:2.6rem;border-bottom:1px solid var(--line-light)}
.article-byline .mark{flex:none;width:3rem;height:3rem;border-radius:50%;border:1px solid var(--kcc-blue);display:grid;place-items:center;font-family:'Cormorant Garamond',serif;font-size:1.15rem;font-weight:500;letter-spacing:.06em;color:var(--navy);background:var(--cream)}
.article-byline .who{display:flex;flex-direction:column;gap:.2rem;min-width:0}
.article-byline .by{font-family:'Cormorant Garamond',serif;font-size:1.3rem;line-height:1.2;color:var(--navy)}
.article-byline .when{font-size:.8rem;color:var(--muted);font-weight:400;letter-spacing:.02em}
.article-byline .read::before{content:"";display:inline-block;width:3px;height:3px;border-radius:50%;background:var(--kcc-blue);vertical-align:middle;margin:0 .7rem}
.article-byline .filed{margin-left:auto;align-self:center;font-size:.8rem;font-weight:500;letter-spacing:.02em;color:var(--navy);text-decoration:none;padding:.45rem 1rem;border:1px solid var(--line-light);border-radius:999px;transition:border-color .3s,color .3s;white-space:nowrap}
.article-byline .filed:hover,.article-byline .filed:focus-visible{border-color:var(--kcc-blue);color:var(--kcc-blue)}

/* the opening line */
.article p.intro-p{font-size:clamp(1.45rem,2.2vw,1.75rem);line-height:1.45;margin-bottom:2.4rem;font-weight:400}

/* paragraphs, bold, italic, links */
.article p{font-size:1.1rem;line-height:1.9}
.article strong,.article b{font-weight:600;color:var(--navy)}
.article em,.article i{font-style:italic}
.article p a,.article li a{color:var(--navy);text-decoration:underline;text-decoration-color:var(--kcc-blue);text-decoration-thickness:1px;text-underline-offset:.24em;transition:color .3s,text-decoration-thickness .3s}
.article p a:hover,.article li a:hover,.article p a:focus-visible,.article li a:focus-visible{color:var(--kcc-blue);text-decoration-thickness:2px}

/* headings: h2 opens a new part of the story, h3 a step within it */
.article h2{font-size:clamp(1.8rem,3vw,2.3rem);line-height:1.15;margin:3.4rem 0 1.1rem}
.article h2::before{content:"";display:block;width:2.5rem;height:1px;background:var(--kcc-blue);margin-bottom:1.3rem}
.article h3{font-size:1.55rem;font-style:italic;font-weight:400;color:var(--navy);margin:2.4rem 0 .7rem;line-height:1.25}
.article h2 + h3{margin-top:1.2rem}
.article > :is(p,ul,ol) + :is(ul,ol){margin-top:-.4rem}

/* lists */
.article ul,.article ol{list-style:none;margin:0 0 1.8rem;padding:0}
.article li{position:relative;padding-left:1.8rem;color:#3f5360;font-weight:300;line-height:1.85;font-size:1.1rem;margin-bottom:.55rem}
.article ul > li::before{content:"";position:absolute;left:0;top:.92em;width:.75rem;height:1px;background:var(--kcc-blue)}
.article ol{counter-reset:step}
.article ol > li{padding-left:2.4rem;counter-increment:step}
.article ol > li::before{content:counter(step) ".";position:absolute;left:0;top:-.08em;font-family:'Cormorant Garamond',serif;font-size:1.45rem;font-weight:500;color:var(--kcc-blue);line-height:1.5}
.article li :is(ul,ol){margin:.55rem 0 0}

/* quotes: a pull quote, the one large gesture in the column */
.article blockquote{position:relative;margin:3.2rem 0;padding:.4rem 0 0 3.6rem;border:0}
.article blockquote::before{content:"\201C";position:absolute;left:-.2rem;top:-.9rem;font-family:'Cormorant Garamond',serif;font-size:6rem;line-height:1;color:var(--kcc-blue)}
.article blockquote p{font-family:'Cormorant Garamond',serif;font-size:clamp(1.55rem,2.6vw,2.05rem);font-style:italic;font-weight:400;color:var(--navy);line-height:1.38;margin-bottom:.7rem}
.article blockquote cite{display:flex;align-items:center;gap:.8rem;font-style:normal;font-size:.8rem;letter-spacing:.02em;font-weight:500;color:var(--muted);margin-top:1rem}
.article blockquote cite::before{content:"";width:1.6rem;height:1px;background:var(--kcc-blue)}

/* photographs reach past the column, up to 1080px, never past the page's side margins */
.article > figure{margin:3.2rem calc(50% - min(540px, 50vw - var(--pad-x)))}
.article > figure .img{aspect-ratio:16/9}
.article > figure figcaption{display:flex;gap:.8rem;align-items:baseline;max-width:var(--measure,780px);margin:1rem auto 0;font-size:.8rem;letter-spacing:.02em;line-height:1.6;color:var(--muted)}
.article > figure figcaption::before{content:"";flex:none;width:1.6rem;height:1px;background:var(--kcc-blue);transform:translateY(-.25em)}

/* sharing */
.article-share{flex-wrap:wrap;row-gap:.8rem;margin-top:3.4rem}
.article-share a{transition:color .3s}
.article-share a:hover,.article-share a:focus-visible{color:var(--kcc-blue)}

@media (max-width:640px){
  .article > figure .img{aspect-ratio:3/2}
  .article-byline{flex-wrap:wrap;row-gap:1rem}
  .article-byline .filed{margin-left:0}
  .article-byline:has(.mark) .filed{margin-left:4.1rem}
  .article blockquote{padding-left:2.4rem}
  .article blockquote::before{font-size:4.4rem;top:-.5rem}
}

/* ---------- the cards: date beside the category, author underneath ---------- */
.news-card{display:flex;flex-direction:column}
.news-card .c{flex:1;display:flex;flex-direction:column}
.news-card .date{display:flex;flex-wrap:wrap;align-items:center;gap:.35rem 0}
.news-card .date time{color:var(--muted);font-weight:500}
.news-card .date .cat + time::before{content:"";display:inline-block;width:14px;height:1px;background:var(--line-light);vertical-align:middle;margin:0 .8rem}
.news-card .by{margin-top:auto;padding-top:1.4rem;font-size:.62rem;letter-spacing:.18em;text-transform:uppercase;color:var(--navy);font-weight:500}
.news-card .by::before{content:"";display:inline-block;width:18px;height:1px;background:var(--kcc-blue);vertical-align:middle;margin-right:.75rem}

.card .meta .by::before{content:"\00b7";margin:0 .6em}

@media (prefers-reduced-motion:reduce){
  .article-byline .filed,.article p a,.article li a,.article-share a{transition:none}
}
