/*
Theme Name: Stanislav Golodnov
Description: Личный сайт — эксперт по бизнесу и маркетингу. Дизайн в стилистике Linear/Stripe.
Author: Stanislav Golodnov
Version: 1.0.0
*/

:root {
  --bg: #f7f7f5;
  --surface: #ffffff;
  --border: #dcdcd8;
  --border-soft: #e8e8e5;
  --text: #16171a;
  --text-muted: #63646a;
  --text-faint: #9b9c9f;
  --measure: 65ch;
  --accent: #D81F5E;
  --accent-soft: #FDEEF3;
}

* { box-sizing: border-box; }

@media (prefers-reduced-motion: no-preference) {
  .reveal { animation: rise 0.7s cubic-bezier(0.16, 1, 0.3, 1) both; }
  .reveal:nth-child(2) { animation-delay: 0.08s; }
  .reveal:nth-child(3) { animation-delay: 0.16s; }
  @keyframes rise {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
  }
}

html { background: var(--bg); color-scheme: light; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, "SF Pro Text", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.mono { font-family: ui-monospace, "SF Mono", "JetBrains Mono", "Fira Code", Menlo, Consolas, monospace; }

a { color: inherit; }

a:focus-visible, button:focus-visible {
  outline: 2px solid var(--text-muted);
  outline-offset: 3px;
  border-radius: 2px;
}

.shell { max-width: 1120px; margin: 0 auto; padding: 0 40px; }

@media (max-width: 640px) { .shell { padding: 0 20px; } }

/* ---------- Nav ---------- */

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0;
  border-bottom: 1px solid var(--border-soft);
}

.nav-id { display: flex; align-items: baseline; gap: 10px; min-width: 0; text-decoration: none; color: inherit; }
.nav-name { font-size: 28px; font-weight: 600; letter-spacing: 0.01em; white-space: nowrap; }
.nav-tagline { font-size: 15px; color: var(--text-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

@media (max-width: 560px) { .nav-tagline { display: none; } }

.nav-links { display: flex; align-items: center; gap: 28px; list-style: none; margin: 0; padding: 0; }

.nav-icon { display: inline-flex; align-items: center; color: var(--text-muted); transition: color 0.15s ease; }
.nav-icon:hover { color: var(--accent); }
.nav-icon svg { display: block; }

.nav-links a { text-decoration: none; font-size: 13px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-muted); transition: color 0.15s ease; }
.nav-links a:hover { color: var(--accent); }
.nav-links a[aria-current="page"] { color: var(--text); }

@media (max-width: 560px) { .nav-links { gap: 18px; } }

/* ---------- Hero / page head ---------- */

.hero { padding: 88px 0 72px; }
.page-head { padding: 64px 0 40px; }

@media (max-width: 640px) { .hero, .page-head { padding: 56px 0 40px; } }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-faint);
  margin: 0 0 24px;
}

.eyebrow::before { content: ""; width: 6px; height: 6px; background: var(--accent); border-radius: 50%; flex: none; }

h1 {
  font-size: clamp(30px, 4.5vw, 44px);
  line-height: 1.18;
  font-weight: 650;
  letter-spacing: -0.02em;
  margin: 0 0 18px;
  text-wrap: balance;
}

.hero h1 { max-width: 15ch; }

.hero-sub, .page-sub {
  max-width: var(--measure);
  font-size: 18px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0;
}

.hero-sub strong { color: var(--text); font-weight: 600; }

/* ---------- About (front page) ---------- */

.about-grid {
  display: flex;
  gap: 44px;
  align-items: flex-start;
  padding-bottom: 64px;
  margin-bottom: 64px;
  border-bottom: 1px solid var(--border-soft);
}

.about-photo { flex: none; width: 200px; border-radius: 3px; overflow: hidden; border: 1px solid var(--border); }
.about-photo img { display: block; width: 100%; height: auto; }

.about { max-width: var(--measure); display: flex; flex-direction: column; gap: 18px; }
.about p { font-size: 16px; line-height: 1.7; color: var(--text); margin: 0; }
.about p.dim { color: var(--text-muted); }

@media (max-width: 640px) {
  .about-grid { flex-direction: column; gap: 28px; }
  .about-photo { width: 148px; }
}

/* ---------- Subscribe module ---------- */

.subscribe {
  display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  background: var(--surface); border: 1px solid var(--border); border-radius: 3px;
  padding: 22px 26px; margin: 0 0 80px;
}

.subscribe-text { display: flex; flex-direction: column; gap: 4px; }
.subscribe-label { font-size: 11px; letter-spacing: 0.1em; color: var(--text-faint); }
.subscribe-copy { font-size: 15px; color: var(--text-muted); }

.btn {
  flex: none; display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px; border: 1px solid var(--border); border-radius: 3px;
  background: transparent; color: var(--text); text-decoration: none;
  font-size: 14px; font-weight: 500;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.btn:hover { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); }
.btn::after { content: "→"; }

@media (max-width: 560px) { .subscribe { flex-direction: column; align-items: flex-start; } }

/* ---------- Section heading ---------- */

.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 0 0 8px; }
.section-title { font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-faint); }
.section-count { font-size: 13px; color: var(--text-faint); text-decoration: none; }

/* ---------- Article list (teasers + blog + related) ---------- */

.articles { border-top: 1px solid var(--border-soft); margin-bottom: 96px; }

.article {
  display: block; text-decoration: none;
  padding: 26px 0; border-bottom: 1px solid var(--border-soft);
  transition: padding-left 0.2s ease;
}

.article:hover { padding-left: 6px; }
.article[hidden] { display: none; }

.article-meta {
  display: flex; align-items: center; gap: 10px;
  font-size: 12px; color: var(--text-faint); margin-bottom: 10px;
  font-variant-numeric: tabular-nums;
}

.tag { color: var(--text-muted); }
.dot { width: 3px; height: 3px; border-radius: 50%; background: var(--text-faint); flex: none; }

.article-title {
  font-size: 19px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.4;
  margin: 0 0 8px; max-width: 42ch; text-wrap: balance;
  transition: color 0.15s ease;
}

.article:hover .article-title { color: var(--accent); }

.article-dek { font-size: 15px; color: var(--text-muted); max-width: var(--measure); margin: 0; }

.related .article-title { font-size: 18px; margin: 0; }

/* ---------- Filters (blog) ---------- */

.filters {
  display: flex; flex-direction: column; gap: 14px;
  padding: 28px 0 32px; border-top: 1px solid var(--border-soft); border-bottom: 1px solid var(--border-soft);
  margin-bottom: 48px;
}

.filter-row { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.filter-label { flex: none; width: 84px; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-faint); }
.filter-pills { display: flex; flex-wrap: wrap; gap: 8px; }

.pill {
  font: inherit; font-size: 13px; color: var(--text-muted);
  background: transparent; border: 1px solid var(--border); border-radius: 3px;
  padding: 6px 12px; cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.pill:hover { border-color: var(--text-muted); color: var(--text); }
.pill[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #ffffff; }

.filter-status { font-size: 13px; color: var(--text-faint); margin-top: 2px; }

.empty-state { padding: 48px 0; color: var(--text-faint); font-size: 15px; text-align: center; display: none; }

@media (max-width: 640px) {
  .filter-label { width: auto; margin-bottom: 2px; }
  .filter-row { flex-direction: column; align-items: flex-start; gap: 8px; }
}

/* ---------- Breadcrumbs ---------- */

.crumbs { display: flex; align-items: center; gap: 8px; padding: 24px 0 0; font-size: 13px; color: var(--text-faint); }
.crumbs a { text-decoration: none; color: var(--text-faint); transition: color 0.15s ease; }
.crumbs a:hover { color: var(--accent); }
.crumbs span[aria-current] { color: var(--text-muted); }

/* ---------- Single article ---------- */

.article-head { max-width: var(--measure); padding: 24px 0 40px; }
.article-head h1 { font-size: clamp(28px, 4.2vw, 38px); max-width: none; }
.lead { font-size: 19px; line-height: 1.6; color: var(--text-muted); margin: 0; }

.byline {
  display: flex; align-items: center; gap: 12px; padding: 24px 0; margin-bottom: 8px;
  border-top: 1px solid var(--border-soft); border-bottom: 1px solid var(--border-soft);
}

.byline img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; border: 1px solid var(--border); }
.byline-name { font-size: 14px; font-weight: 600; transition: color 0.15s ease; }
.byline-role { font-size: 13px; color: var(--text-faint); }
.byline a { text-decoration: none; }
.byline-text:hover .byline-name { color: var(--accent); }

.prose { max-width: var(--measure); padding: 40px 0 24px; font-size: 17px; line-height: 1.75; }
.prose p { margin: 0 0 22px; }
.prose h2 { font-size: 24px; font-weight: 650; letter-spacing: -0.01em; margin: 44px 0 18px; text-wrap: balance; }
.prose ul { margin: 0 0 22px; padding-left: 22px; }
.prose li { margin-bottom: 10px; }

.callout {
  border-left: 3px solid var(--accent);
  padding: 4px 0 4px 20px; margin: 32px 0;
  font-size: 18px; line-height: 1.6; color: var(--text);
}

.related { border-top: 1px solid var(--border-soft); margin: 48px 0 96px; }
.related .section-title { margin: 32px 0 8px; }

/* ---------- Footer ---------- */

footer {
  padding: 40px 0 64px;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px;
  color: var(--text-faint); font-size: 13px;
}

footer a { color: var(--text-muted); text-decoration: none; }
footer a:hover { color: var(--text); }
.footer-links { display: flex; gap: 20px; }
