:root {
  --bg: #f5f7fa;
  --paper: #ffffff;
  --ink: #17212f;
  --text: #2b3645;
  --muted: #5d6878;
  --navy: #14325c;
  --navy-2: #1e477d;
  --gold: #a8843a;
  --gold-soft: #f4ecdb;
  --line: #e1e6ed;
  --soft: #eef2f7;
  --radius: 10px;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 17px/1.75 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--navy-2); }

.wrap { width: 100%; max-width: 760px; margin: 0 auto; padding: 0 16px; }
.wrap--wide { max-width: 1040px; }

.skip { position: absolute; left: -9999px; top: 0; background: var(--navy); color: #fff; padding: 8px 14px; z-index: 100; }
.skip:focus { left: 8px; top: 8px; }

/* Top bar */
.topbar { background: var(--navy); color: #dfe7f3; font-size: 13px; letter-spacing: .01em; }
.topbar__row { max-width: 1160px; display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 36px; flex-wrap: wrap; }
.topbar time { color: #fff; font-weight: 600; }

/* Header */
.header { background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; box-shadow: 0 1px 0 rgba(20, 50, 92, .03); }
.header::after { content: ""; display: block; height: 3px; background: linear-gradient(90deg, var(--navy) 0 70%, var(--gold) 70% 100%); }
.header__row { max-width: 1160px; display: flex; align-items: center; gap: 20px; padding-top: 14px; padding-bottom: 14px; flex-wrap: wrap; }

.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); margin-right: auto; }
.logo__mark {
  width: 42px; height: 42px; border-radius: 8px; display: grid; place-items: center;
  background: var(--navy); color: #fff; font: 700 16px/1 var(--serif); letter-spacing: .04em;
  box-shadow: inset 0 -3px 0 var(--gold);
}
.logo__text { font: 700 20px/1.1 var(--serif); letter-spacing: .01em; }
.logo__text small { display: block; font: 500 11px/1.4 var(--sans); color: var(--muted); text-transform: uppercase; letter-spacing: .12em; margin-top: 3px; }

.nav, .footer__nav { display: flex; flex-wrap: wrap; gap: 8px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 38px; padding: 7px 16px;
  border: 1px solid var(--line); border-radius: 6px; background: var(--paper);
  color: var(--navy); font: 600 14px/1.2 var(--sans); text-decoration: none; white-space: nowrap;
  transition: background .15s, color .15s, border-color .15s;
}
a.btn:hover, a.btn:focus-visible { background: var(--navy); border-color: var(--navy); color: #fff; }
.btn[aria-disabled="true"] { cursor: default; user-select: none; }

.langs { display: inline-flex; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; background: var(--paper); }
.langs a { padding: 7px 11px; font: 600 13px/1.4 var(--sans); color: var(--muted); text-decoration: none; letter-spacing: .04em; }
.langs a + a { border-left: 1px solid var(--line); }
.langs a:hover { color: var(--navy); background: var(--soft); }
.langs a.is-active { background: var(--navy); color: #fff; }

/* Hero */
.article { background: var(--paper); padding-bottom: 64px; }
.hero { padding-top: 48px; padding-bottom: 28px; }
.kicker { margin: 0 0 14px; color: var(--gold); font: 700 12px/1.4 var(--sans); text-transform: uppercase; letter-spacing: .14em; }
h1 { margin: 0; font: 700 clamp(28px, 4.4vw, 42px)/1.18 var(--serif); color: var(--ink); letter-spacing: -.01em; }
.meta { margin: 18px 0 0; padding-top: 16px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; display: flex; gap: 6px; flex-wrap: wrap; }
.meta time { color: var(--ink); font-weight: 600; }

/* Framed images */
.frame {
  margin: 32px 0; padding: 10px;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 10px 30px -18px rgba(20, 50, 92, .35);
}
.frame__inner {
  aspect-ratio: var(--ratio, 16/9); width: 100%;
  overflow: hidden; border-radius: 6px; background: var(--soft);
  display: flex; align-items: center; justify-content: center;
}
.frame__inner img { width: 100%; height: 100%; object-fit: cover; object-position: center; }
.frame--cover { margin-top: 0; }

/* Prose */
.prose { color: var(--text); }
.prose p { margin: 0 0 1.25em; }
.prose .lead { font-size: 19px; line-height: 1.7; color: var(--ink); }
.prose h2 {
  margin: 2em 0 .8em; padding-top: .2em;
  font: 700 clamp(22px, 3vw, 28px)/1.25 var(--serif); color: var(--ink);
}
.prose h2::before { content: ""; display: block; width: 48px; height: 3px; background: var(--gold); margin-bottom: 14px; }
.prose blockquote {
  margin: 1.8em 0; padding: 22px 26px;
  background: var(--gold-soft); border-left: 4px solid var(--gold); border-radius: 0 var(--radius) var(--radius) 0;
  font: 600 italic 20px/1.55 var(--serif); color: var(--ink);
}
.prose blockquote p { margin: 0; }
.checklist { list-style: none; margin: 0 0 1.5em; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); background: #fafbfd; }
.checklist li { position: relative; padding: 14px 18px 14px 52px; }
.checklist li + li { border-top: 1px solid var(--line); }
.checklist li::before {
  content: ""; position: absolute; left: 18px; top: 18px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--navy) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/100% no-repeat;
}

/* Footer */
.footer { background: #eef2f7; border-top: 1px solid var(--line); padding: 48px 0 24px; scroll-margin-top: 90px; }
.footer__grid { max-width: 1160px; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.footer h2 { margin: 0 0 10px; font: 700 22px/1.3 var(--serif); color: var(--ink); }
.footer__about p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.7; max-width: 560px; }
.footer__nav { justify-content: flex-end; }
.footer__bottom {
  max-width: 1160px; margin-top: 36px; padding-top: 18px; border-top: 1px solid #d9e0ea;
  display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap;
  font-size: 13px; color: var(--muted);
}

@media (max-width: 860px) {
  .footer__grid { grid-template-columns: 1fr; }
  .footer__nav { justify-content: flex-start; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .header { position: static; }
  .header__row { gap: 12px; }
  .nav { order: 3; width: 100%; }
  .nav .btn { flex: 1 1 auto; padding: 7px 10px; }
  .hero { padding-top: 32px; }
  .frame { padding: 6px; margin: 24px 0; }
  .prose .lead { font-size: 17px; }
  .prose blockquote { padding: 16px 18px; font-size: 18px; }
  .footer__nav .btn { white-space: normal; }
}
