/* Open Weights Weekly — a blue signup field, white reading pages, serif for reading, sans for interface.
   Mobile first. */
:root {
  --blue: #1d3fd8;
  --blue-deep: #1631b0;
  --blue-wash: #eef1fd;
  --paper: #f6f7fb;
  --white: #ffffff;
  --ink: #172033;
  --dim: #5b6478;
  --rule: #e1e5ee;
  --ok: #0b8457;
  --err: #b42318;
  --sans: 'Instrument Sans', system-ui, sans-serif;
  --serif: 'Newsreader', Georgia, serif;
  --wrap: 60rem;
  --radius: 14px;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { background: var(--paper); color: var(--ink); -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--sans); font-size: 1rem; line-height: 1.55; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; }
a { color: var(--blue); text-underline-offset: 0.16em; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 1.15rem; }

/* ---------- Header ---------- */
.top { background: var(--blue); color: var(--white); }
.top .wrap { display: flex; justify-content: space-between; align-items: center; min-height: 3.75rem; }
.brand { color: var(--white); text-decoration: none; font-weight: 700; font-size: 1.05rem; font-variation-settings: 'wdth' 85; letter-spacing: 0.01em; padding: 0.5rem 0; }
.brand span { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: 1.15em; margin-left: 0.15em; }
.top-link { color: var(--white); text-decoration: none; padding: 0.6rem 0.75rem; margin-right: -0.75rem; border-radius: 8px; }
.top-link:hover { background: var(--blue-deep); }
.top-light { background: var(--white); border-bottom: 1px solid var(--rule); }
.top-light .brand, .top-light .top-link { color: var(--blue); }
.top-light .top-link:hover { background: var(--blue-wash); }

/* ---------- Hero: the blue field ---------- */
.hero { background: var(--blue); color: var(--white); padding: 1.75rem 0 4.5rem; }
.hero h1 { font-family: var(--serif); font-weight: 600; font-size: 2.6rem; line-height: 1.02; letter-spacing: -0.02em; margin: 0 0 1rem; max-width: 14ch; }
.hero-sub { font-size: 1.08rem; line-height: 1.5; margin: 0 0 1.75rem; max-width: 46ch; color: #dfe5ff; }

/* ---------- Signup form ---------- */
.signup { display: grid; gap: 0.75rem; max-width: 34rem; }
.signup input[type='email'] {
  font: inherit; font-size: 1.05rem; width: 100%; min-height: 3.5rem; padding: 0 1rem;
  border: 2px solid transparent; border-radius: var(--radius); background: var(--white); color: var(--ink);
}
.signup input[type='email']:focus { outline: none; border-color: #9fb0ff; box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.25); }
.signup button {
  font: inherit; font-size: 1.05rem; font-weight: 700; min-height: 3.5rem; padding: 0 1.5rem;
  border: 0; border-radius: var(--radius); cursor: pointer;
  background: #ffd84d; color: #1b1f2e;
}
.signup button:hover { background: #ffe27a; }
.signup button:active { transform: translateY(1px); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.fine { margin: 0; font-size: 0.85rem; color: #cdd6ff; }
.fine a { color: var(--white); }
.form-msg { margin: 0; padding: 0.8rem 1rem; border-radius: 10px; font-weight: 600; }
.form-msg.ok { background: #e7f7ef; color: var(--ok); }
.form-msg.err { background: #fdecea; color: var(--err); }

/* ---------- Home ---------- */
.latest { margin-top: -2.75rem; }
.kicker { margin: 0 0 0.6rem; font-size: 0.9rem; font-weight: 600; color: var(--white); }
.latest-card {
  display: grid; gap: 0.5rem; padding: 1.4rem; text-decoration: none; color: var(--ink);
  background: var(--white); border: 1px solid var(--rule); border-radius: 18px;
  box-shadow: 0 1px 0 rgba(23, 32, 51, 0.04), 0 12px 28px -18px rgba(23, 32, 51, 0.35);
}
.latest-card:hover .latest-title { color: var(--blue); }
.latest-title { font-family: var(--serif); font-weight: 600; font-size: 1.6rem; line-height: 1.15; letter-spacing: -0.01em; }
.issue-meta { font-size: 0.85rem; color: var(--dim); font-weight: 500; }
.issue-sum { color: var(--dim); font-size: 0.98rem; }
.read { margin-top: 0.4rem; font-weight: 700; color: var(--blue); }

.what { padding: 2.5rem 0 1rem; }
.what h2, .archive h2 { font-family: var(--serif); font-weight: 600; font-size: 1.6rem; margin: 0 0 1rem; letter-spacing: -0.01em; }
.what-grid { display: grid; gap: 0.75rem; margin: 0; }
.what-grid div { background: var(--white); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem 1.1rem; }
.what-grid dt { font-weight: 700; color: var(--blue); }
.what-grid dd { margin: 0.25rem 0 0; color: var(--ink); }

.archive { padding: 1.5rem 0 2.5rem; }
.issue-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.issue-list a { display: grid; gap: 0.3rem; padding: 1.1rem 0; text-decoration: none; color: var(--ink); border-bottom: 1px solid var(--rule); }
.issue-list .issue-title { font-family: var(--serif); font-weight: 600; font-size: 1.25rem; line-height: 1.2; }
.issue-list a:hover .issue-title { color: var(--blue); }

/* ---------- Issue page ---------- */
.issue { background: var(--white); margin: 0 -1.15rem; padding: 1.5rem 1.15rem 2rem; border-bottom: 1px solid var(--rule); }
.issue h1 { font-family: var(--serif); font-weight: 600; font-size: 2.1rem; line-height: 1.08; letter-spacing: -0.015em; margin: 0.4rem 0 1.25rem; max-width: 22ch; }
.prose { font-family: var(--serif); font-size: 1.18rem; line-height: 1.65; max-width: 65ch; }
.prose h2 { font-family: var(--sans); font-size: 1.15rem; font-weight: 700; margin: 2rem 0 0.4rem; line-height: 1.3; }
.prose h3 { font-family: var(--sans); font-size: 1rem; font-weight: 700; margin: 2rem 0 0.3rem; color: var(--dim); }
.prose p { margin: 0 0 1rem; }
.prose ul { padding-left: 1.2rem; margin: 0 0 1rem; }
.prose li { margin: 0.35rem 0; }
.prose .sources { font-family: var(--sans); font-size: 0.92rem; color: var(--dim); }
.page .prose { margin-bottom: 1rem; }
.signup-plain input[type='email'] { border-color: var(--rule); background: var(--paper); }
.signup-plain button { background: var(--blue); color: var(--white); }
.signup-plain button:hover { background: var(--blue-deep); }

.issue-signup { background: var(--blue); color: var(--white); margin: 0 -1.15rem; padding: 1.75rem 1.15rem 2rem; }
.issue-signup h2 { font-family: var(--serif); font-weight: 600; font-size: 1.5rem; margin: 0 0 1rem; }
.older { padding: 1.5rem 0; margin: 0; }

/* ---------- Footer ---------- */
.foot { border-top: 1px solid var(--rule); padding: 2rem 0 2.5rem; color: var(--dim); font-size: 0.9rem; }
.foot p { margin: 0.4rem 0; max-width: 60ch; }
.foot-brand { font-weight: 700; color: var(--ink); }
.foot nav { display: flex; flex-wrap: wrap; gap: 0.2rem 1.1rem; margin: 0.75rem 0; }
.foot nav a { padding: 0.35rem 0; }

/* ---------- Wider screens ---------- */
@media (min-width: 720px) {
  .wrap { padding: 0 2rem; }
  .hero { padding: 3rem 0 6rem; }
  .hero h1 { font-size: 4.4rem; }
  .hero-sub { font-size: 1.2rem; }
  .signup { grid-template-columns: 1fr auto; }
  .signup .fine, .signup .form-msg { grid-column: 1 / -1; }
  .latest { margin-top: -3.75rem; }
  .latest-card { padding: 2rem 2.25rem; }
  .latest-title { font-size: 2.1rem; max-width: 26ch; }
  .what-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }
  .issue { margin: 2rem 0 0; padding: 2.5rem 3rem 3rem; border: 1px solid var(--rule); border-radius: 18px; }
  .issue h1 { font-size: 3rem; }
  .issue-signup { margin: 1.5rem 0 0; padding: 2rem 3rem; border-radius: 18px; }
}
