/* Страницы котов. Переменные темы скопированы из index.html (make_cats.py). */
:root {
  --bg: #e8edf1;
  --surface: #f6f8fa;
  --panel: #dbe4ec;
  --ink: #16222d;
  --muted: #4f5e6b;
  --line: #c2cdd7;
  --accent: #e8a010;
  --accent-ink: #1d1400;
  --link: #1b6a70;
  --cat-line: #16222d;
  --screen: #0f1a22;
  --screen-ink: #f2f6f9;
  --screen-mute: #93a8b8;
  --glow: #f0b030;
  --font-display: 'Bricolage Grotesque', 'Arial Narrow', Arial, sans-serif;
  --font-body: 'Figtree', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e171e;
    --surface: #16232d;
    --panel: #1f3240;
    --ink: #e7eef3;
    --muted: #9db0bf;
    --line: #2c4150;
    --accent: #f0b030;
    --link: #6fcdd2;
    --cat-line: #060b10;
    --screen: #091117;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e171e;
  --surface: #16232d;
  --panel: #1f3240;
  --ink: #e7eef3;
  --muted: #9db0bf;
  --line: #2c4150;
  --accent: #f0b030;
  --link: #6fcdd2;
  --cat-line: #060b10;
  --screen: #091117;
  color-scheme: dark;
}


* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.6; padding: 20px max(16px, env(safe-area-inset-right, 0px)) 56px max(16px, env(safe-area-inset-left, 0px)); }
.wrap { max-width: 980px; margin: 0 auto; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.08; margin: 0; text-wrap: balance; }
p { margin: 0; }
a { color: var(--link); }
:focus-visible { outline: 3px solid var(--link); outline-offset: 2px; }
.mono { font-family: var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; font-size: 12px; }
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; padding-bottom: 22px; }
.brand { font-family: var(--font-display); font-weight: 800; font-size: 1.25rem; color: var(--ink); text-decoration: none; }
.top nav { display: flex; gap: 16px; flex-wrap: wrap; }
.top nav a { color: var(--ink); text-decoration: none; padding-block: 6px; border-bottom: 2px solid transparent; }
.top nav a:hover { border-bottom-color: var(--accent); }
.hero { display: grid; grid-template-columns: minmax(0, 320px) minmax(0, 1fr); gap: 32px; align-items: center; margin-top: 8px; }
.hero-art { background: var(--panel); border-radius: 16px; padding: 16px 16px 6px; }
.hero-art svg { display: block; width: 100%; height: auto; }
.tag { display: inline-block; background: var(--accent); color: var(--accent-ink); border-radius: 999px; padding: 3px 12px; margin-bottom: 12px; }
h1 { font-weight: 800; font-size: clamp(2.4rem, 7vw, 4rem); letter-spacing: -0.03em; }
.lead { font-size: 1.15rem; color: var(--muted); margin-top: 12px; max-width: 40ch; }
.quote { margin-top: 18px; padding: 12px 16px; border-left: 4px solid var(--accent); background: var(--surface); border-radius: 0 12px 12px 0; font-style: italic; }
section { margin-top: 56px; }
section h2 { font-weight: 800; font-size: clamp(1.6rem, 4vw, 2.2rem); letter-spacing: -0.02em; margin-bottom: 18px; }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin: 0; }
.facts div { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.facts dt { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 4px 0 0; font-weight: 600; }
.story p + p { margin-top: 14px; }
.story { max-width: 62ch; }
.day { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; }
.day li { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.day b { display: block; font-family: var(--font-mono); font-weight: 500; color: var(--accent); }
.album { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 20px; }
.shot { margin: 0; background: #fff; color: #1b2630; border-radius: 6px; padding: 10px 10px 12px; box-shadow: 0 6px 18px rgba(0,0,0,0.22); transform: rotate(var(--r, 0deg)); transition: transform 200ms ease; }
.shot:hover { transform: rotate(0deg) scale(1.02); }
.shot .pic { position: relative; border-radius: 3px; overflow: hidden; aspect-ratio: 1; }
.shot .pic svg { position: absolute; inset: 8% 6% 0; width: 88%; height: 92%; }
.shot .prop { position: absolute; right: 8%; top: 6%; font-size: 30px; line-height: 1; }
.shot figcaption { margin-top: 8px; font-size: 14px; text-align: center; }
.bg-sun { background: linear-gradient(#fbe7a8, #f6c96a); }
.bg-warm { background: linear-gradient(#f9d4b5, #eaa77a); }
.bg-mint { background: linear-gradient(#cfeede, #8fcfb4); }
.bg-night { background: linear-gradient(#3b4f78, #1c2740); }
.pager { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 56px; }
.pager a { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 18px; border: 1.5px solid var(--ink); border-radius: 999px; color: var(--ink); text-decoration: none; font-weight: 600; }
.pager a:hover { background: var(--panel); }
footer { margin-top: 40px; color: var(--muted); font-size: 13px; }
@media (max-width: 720px) { .hero { grid-template-columns: minmax(0, 1fr); } .hero-art { max-width: 320px; } }
@media (prefers-reduced-motion: no-preference) { .hero-art svg { animation: breathe 4.5s ease-in-out infinite; transform-origin: 50% 90%; } }
@keyframes breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.02); } }
