/* Devlog pages: same tokens and components as the home page (index.html) */
:root {
  --bg: #151311;
  --bg-2: #1e1b18;
  --bg-3: #27231f;
  --ink: #ece8e1;
  --muted: #a8a096;
  --blood: #a3221b;
  --blood-hi: #c42d24;
  --glow: #ffe2bd;

  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: Inter, system-ui, sans-serif;
  --margin: clamp(16px, 4vw, 56px);
  --max: 1240px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}
*, *::before, *::after { box-sizing: border-box; }
html { color-scheme: dark; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.65 var(--sans); }
img { display: block; max-width: 100%; height: auto; }
figure { margin: 0; }
a { color: inherit; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-family: var(--serif); font-weight: 700; letter-spacing: 0.005em; text-wrap: balance; }
.lead { font-size: clamp(18px, 1.5vw, 21px); color: #d8d2c8; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--margin); }
.narrow { max-width: calc(720px + 2 * var(--margin)); }
:focus-visible { outline: 2px solid var(--glow); outline-offset: 3px; }
a, button { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 0 26px; border-radius: 3px; border: 1px solid transparent;
  background: var(--blood); color: #fff; text-decoration: none; cursor: pointer;
  font: 600 15px/1 var(--sans); letter-spacing: 0.02em;
  transition: background 0.2s ease, transform 0.14s ease;
}
.btn:hover { background: var(--blood-hi); }
.btn:active { transform: scale(0.98); }
.ico { width: 18px; height: 18px; flex: none; }
.skip { position: absolute; left: 16px; top: -100px; z-index: 50; }
.skip:focus { top: 12px; }

/* nav */
.nav {
  position: sticky; top: 0; z-index: 20;
  display: flex; justify-content: space-between; align-items: center; gap: 20px;
  padding: max(14px, env(safe-area-inset-top)) max(var(--margin), env(safe-area-inset-right)) 14px max(var(--margin), env(safe-area-inset-left));
  background: rgba(21, 19, 17, 0.92);
}
.nav .mark { font: 700 21px var(--serif); letter-spacing: 0.1em; text-decoration: none; }
.nav .links { display: flex; align-items: center; gap: 26px; font-size: 14px; }
.nav .links a:not(.btn) { text-decoration: none; color: #cfc8bd; transition: color 0.2s ease; }
.nav .links a:not(.btn):hover { color: var(--ink); }
.nav .btn { min-height: 38px; padding: 0 16px; font-size: 13px; }
@media (max-width: 560px) { .nav .links a:not(.btn) { display: none; } }

/* article */
.article { padding-top: clamp(48px, 7vw, 96px); }
.crumbs { font-size: 14px; color: var(--muted); margin-bottom: 18px; }
.crumbs a { text-decoration: none; color: #cfc8bd; }
.crumbs a:hover { color: var(--ink); }
.article h1 { font-size: clamp(40px, 5.6vw, 68px); line-height: 1.02; }
.article header .lead { margin-top: 20px; }
.hero-img { margin-top: clamp(32px, 5vw, 56px); }
.hero-img img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 4px; }
.body { margin-top: clamp(32px, 5vw, 56px); font-size: 18px; line-height: 1.75; color: #e2ddd5; }
.body > * + * { margin-top: 1.1em; }
.body h2 { font-size: clamp(30px, 3vw, 38px); line-height: 1.1; margin-top: 1.6em; color: var(--ink); }
.body h3 { font-size: 26px; margin-top: 1.4em; color: var(--ink); }
.body a { text-decoration-color: rgba(236, 232, 225, 0.4); text-underline-offset: 3px; }
.body a:hover { text-decoration-color: var(--ink); }
.body ul { padding-left: 1.2em; }
.body li + li { margin-top: 0.4em; }
.body blockquote { margin-left: 0; padding-left: 20px; border-left: 3px solid var(--blood); font-family: var(--serif); font-size: 24px; line-height: 1.35; color: var(--ink); }
.body figure { margin-top: 1.8em; margin-bottom: 1.8em; }
.body figure img { border-radius: 4px; width: 100%; }
.body figcaption { margin-top: 10px; font-size: 14px; color: var(--muted); }

/* wishlist call */
.cta {
  margin: clamp(56px, 8vw, 96px) 0 0; padding: 28px 30px; border-radius: 6px; background: var(--bg-3);
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.cta p { max-width: 42ch; color: #d8d2c8; }

/* lists of posts */
.list-head { padding-top: clamp(48px, 7vw, 96px); margin-bottom: 40px; }
.list-head h1 { font-size: clamp(48px, 6vw, 80px); line-height: 1; }
.list-head .lead { margin-top: 16px; max-width: 52ch; }
.more { margin-top: clamp(72px, 10vw, 140px); }
.more h2 { font-size: clamp(32px, 3.6vw, 48px); margin-bottom: 28px; }
.posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(16px, 2.4vw, 28px); }
.more .posts { grid-template-columns: repeat(2, 1fr); }
.post { display: block; text-decoration: none; background: var(--bg-2); border-radius: 6px; overflow: hidden; transition: transform 0.4s var(--ease), background 0.3s ease; }
.post:hover { transform: translateY(-6px); background: var(--bg-3); }
.post img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; filter: brightness(1.08); }
.post > div { padding: 20px 22px 26px; }
.post .when { font-size: 13px; color: var(--muted); }
.post h3 { font-size: 26px; line-height: 1.1; margin: 6px 0 10px; }
.post p:last-child { color: #cfc8bd; font-size: 16px; }
@media (max-width: 900px) { .posts, .more .posts { grid-template-columns: 1fr; } }

/* footer */
footer { margin-top: clamp(72px, 10vw, 140px); padding: 48px 0; font-size: 14px; color: var(--muted); }
footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center; }
footer a { text-decoration: none; }
footer a:hover { color: var(--ink); }
footer span:last-child { display: inline-flex; gap: 6px; align-items: center; }
footer .fi { display: inline-flex; padding: 6px; }
footer .fi svg { width: 20px; height: 20px; }
