/* Site chrome, from mockups/09-candidate (the settled design). The article body
   itself is styled by nbconvert/article.css, published as /assets/article.css. */
:root {
  --blue: #3366cc; --blue-dark: #2a4b8d; --ink: #202122; --muted: #54595d;
  --line: #c8ccd1; --band: #f8f9fa; --bg: #ffffff;
}
* { box-sizing: border-box; margin: 0; }
body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
       color: var(--ink); background: var(--bg); line-height: 1.6; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
.wrap { max-width: 66rem; margin: 0 auto; padding: 0 1.5rem; }
@media (max-width: 480px) { .wrap { padding: 0 1rem; } }

/* Header */
header { border-bottom: 1px solid var(--line); background: #fff; }
.header-in { display: flex; align-items: center; justify-content: space-between; padding-top: .9rem; padding-bottom: .9rem; }
.brand { display: flex; align-items: center; gap: .8rem; color: var(--ink); font-weight: 700; }
.brand:hover { text-decoration: none; }
.logo { width: 2.9rem; height: 2.9rem; border-radius: 6px; display: block; }
.brand-title { line-height: 1.2; }
.bt1 { display: block; font-weight: 700; font-size: 1.18rem; }
.bt2 { display: block; font-weight: 400; font-size: .82rem; color: var(--muted);
       text-align: right; margin-right: -.5rem; }
nav a { color: var(--ink); font-size: .95rem; margin-left: 1.6rem; }
nav a:hover { color: var(--blue); }
nav a[aria-current="page"] { color: var(--blue); font-weight: 600; }
/* The admin's door: findable, but outlined so it doesn't compete with the articles. */
nav a.btn-login { display: inline-block; font-size: .88rem; font-weight: 600; color: var(--blue);
  border: 1px solid var(--line); border-radius: 2px; padding: .28rem .85rem; }
nav a.btn-login:hover { background: var(--blue); border-color: var(--blue); color: #fff; text-decoration: none; }
@media (max-width: 620px) {
  .header-in { flex-wrap: wrap; gap: .7rem 0; }
  nav a { margin-left: 0; margin-right: 1.2rem; }
}

/* Banners: one gradient per swatch in the admin's banner picker */
.banner { color: #fff; display: flex; align-items: center; justify-content: center; }
.banner .glyph { font-weight: 800; opacity: .95; }
.b-indigo { background: linear-gradient(135deg, #4f46e5, #9333ea); }
.b-blue   { background: linear-gradient(135deg, #0ea5e9, #6366f1); }
.b-purple { background: linear-gradient(135deg, #9333ea, #db2777); }
.b-green  { background: linear-gradient(135deg, #059669, #0ea5e9); }
.b-logo   { background: linear-gradient(135deg, #7AC62D, #059669); }  /* About: echoes the logo */
.b-grey   { background: linear-gradient(135deg, #72777d, #a2a9b1); }  /* 404 */
.feature-banner { height: 5.5rem; }                  /* slim, full-bleed under the menu */
.feature-banner .glyph { font-size: 2.4rem; }
.page-banner { height: 7.5rem; }
.page-banner .glyph { font-size: 3rem; }

/* Home: featured article */
.feature { padding: 1.8rem 0 2.6rem; border-bottom: 1px solid var(--line); }
.feature h1 { font-size: 2.2rem; line-height: 1.22; letter-spacing: -0.015em; margin: .5rem 0 .7rem; max-width: 44rem; }
.feature h1 a { color: var(--ink); }
.feature h1 a:hover { color: var(--blue); text-decoration: none; }
.feature .teaser { color: var(--muted); font-size: 1.08rem; max-width: 40rem; }
.feature-slogan { margin-top: 1.1rem; color: var(--muted); font-style: italic; font-size: 1rem; }
.mark { font-style: normal; color: var(--blue); font-weight: 700; margin-right: .5rem; }
@media (max-width: 620px) { .feature h1 { font-size: 1.7rem; } }

/* Home: the article grid, in his order */
section.latest { padding-top: 2.4rem; padding-bottom: 3rem; }  /* keep .wrap's side padding */
.latest-head { display: flex; justify-content: space-between; align-items: flex-start;
               gap: 1rem 2rem; flex-wrap: wrap; margin-bottom: 1.4rem; }
h2.section { font-size: 1.5rem; margin: 1.3rem 0 0; }
.slogan-line { font-style: italic; font-weight: 600; font-size: 1.02rem; text-align: right; margin-left: auto; }
.slogan-attr { display: block; font-style: normal; font-weight: 400; color: var(--muted);
               font-size: .85rem; margin-top: .15rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 1.2rem; }
.card { border: 1px solid var(--line); border-radius: 4px; background: #fff; overflow: hidden;
        transition: box-shadow .15s ease; display: flex; flex-direction: column; }
.card:hover { box-shadow: 0 2px 10px rgba(0,0,0,.1); }
.thumb { height: 6rem; }
.thumb .glyph { font-size: 2.1rem; }
.card-body { padding: 1.1rem 1.3rem 1.2rem; display: flex; flex-direction: column; flex: 1; }
.kicker { font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.card h3 { font-size: 1.05rem; line-height: 1.4; margin: .3rem 0 .45rem; }
.card p { font-size: .92rem; color: var(--muted); margin-bottom: .6rem;
          display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; }
.card .date { font-size: .82rem; color: var(--muted); margin-top: auto; }  /* pinned to the bottom; the
          teaser must not flex-grow, or the clamp shows text past its "…" */
.empty-note { color: var(--muted); }

/* Home: About teaser */
.about { background: var(--band); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.about-in { display: grid; grid-template-columns: 1fr 2fr; gap: 2.5rem; align-items: start; padding: 3rem 1.5rem; }
.about h2 { font-size: 1.5rem; }
.about .motto { font-style: italic; color: var(--muted); margin-bottom: .9rem; }
.about p { margin-bottom: 1rem; max-width: 34rem; }
.contact a { margin-right: 1.4rem; font-weight: 600; font-size: .95rem; }
@media (max-width: 640px) { .about-in { grid-template-columns: 1fr; gap: .8rem; } }

/* Inner pages */
main { max-width: 52rem; margin: 0 auto; padding: 2.6rem 1.5rem 4rem; }
@media (max-width: 480px) { main { padding: 2rem 1rem 3rem; } }
.crumbs { font-size: .88rem; margin-bottom: 1.4rem; color: var(--muted); }
.meta { color: var(--muted); font-size: .88rem; margin-bottom: 1.6rem; }
.backlink { display: inline-block; margin-top: 2.4rem; font-weight: 600; }
.to-top { position: fixed; right: 1rem; bottom: 1rem; background: #fff; border: 1px solid var(--line);
          border-radius: 2px; padding: .3rem .7rem; font-size: .85rem; font-weight: 600;
          box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.to-top:hover { background: var(--blue); border-color: var(--blue); color: #fff; text-decoration: none; }

/* About page */
main.about-page h1 { font-size: 1.9rem; line-height: 1.3; margin: 0 0 .8rem; letter-spacing: -0.01em; }
.about-page .motto { font-style: italic; font-weight: 600; font-size: 1.14rem; margin-bottom: 2.4rem; max-width: 34rem; }
.cols { display: grid; grid-template-columns: 15rem 1fr; gap: 2.6rem; align-items: start; }
.cols.single { grid-template-columns: 1fr; }
.portrait { width: 100%; border-radius: 4px; display: block; margin-bottom: 1.6rem; }
.rail h2 { font-size: .74rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
           color: var(--muted); margin-bottom: .7rem; }
.rail .contact a { display: block; margin: 0 0 .5rem; }
.prose { line-height: 1.65; }
.prose h2 { font-size: 1.25rem; margin: 2rem 0 .7rem; }
.prose h2:first-child { margin-top: 0; }
.prose p { margin-bottom: 1.1rem; max-width: 36rem; }
.ph { color: var(--muted); font-style: italic; }
@media (max-width: 720px) { .cols { grid-template-columns: 1fr; gap: 1.8rem; } .portrait { max-width: 14rem; } }

footer { border-top: 1px solid var(--line); padding: 1.6rem 0 2.2rem; color: var(--muted); font-size: .85rem; }
footer a { color: var(--muted); }
