/* ============================================
   cashflowa.ru — Global Stylesheet
   Стиль: Modern Finance / Fintech Editorial
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Manrope:wght@300;400;500;600;700;800&display=swap');

/* ─── Variables ─── */
:root {
  --forest:      #0b3d2e;
  --forest-mid:  #165c43;
  --forest-lt:   #e8f5ef;
  --emerald:     #1a7a53;
  --mint:        #34c98a;
  --mint-lt:     #d5f5e8;
  --gold:        #d4a017;
  --gold-lt:     #fdf3d0;
  --charcoal:    #111918;
  --ink:         #1e2b25;
  --slate:       #4a5c55;
  --mist:        #8a9e97;
  --fog:         #c4d0cb;
  --bg:          #f4f7f5;
  --bg-card:     #ffffff;
  --rule:        #dde7e2;
  --shadow-sm:   0 1px 8px rgba(11,61,46,.07);
  --shadow-md:   0 6px 24px rgba(11,61,46,.11);
  --shadow-lg:   0 14px 44px rgba(11,61,46,.17);
  --r:           6px;
  --r-lg:        14px;
  --font-serif:  'DM Serif Display', Georgia, serif;
  --font-sans:   'Manrope', system-ui, sans-serif;
  --max-w:       1180px;
  --t:           .22s ease;
}

/* ─── Reset ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.72;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }

/* ─── AD ZONES ─── */
.ad-zone {
  background: #eef2f0;
  border: 1px dashed var(--fog);
  text-align: center;
  padding: 10px;
  margin: 18px 0;
  font-size: .7rem;
  color: var(--mist);
  letter-spacing: .5px;
}
.ad-zone-header { margin: 0; border-left: none; border-right: none; }

/* ─── HEADER ─── */
.site-header {
  background: var(--forest);
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: 0 2px 20px rgba(0,0,0,.25);
}
.header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
  height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.logo-mark {
  width: 36px; height: 36px;
  background: var(--mint);
  border-radius: var(--r);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
  font-size: 1rem;
  color: var(--forest);
  letter-spacing: -1px;
  flex-shrink: 0;
}
.logo-text {
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: 1.22rem;
  color: #fff;
  letter-spacing: -.5px;
}
.logo-text span { color: var(--mint); }
.site-nav { display: flex; align-items: center; gap: 2px; }
.site-nav a {
  color: rgba(255,255,255,.65);
  font-size: .83rem;
  font-weight: 500;
  padding: 8px 13px;
  border-radius: var(--r);
  white-space: nowrap;
  transition: background var(--t), color var(--t);
}
.site-nav a:hover, .site-nav a.active {
  background: rgba(255,255,255,.1);
  color: #fff;
}

/* ─── HERO ─── */
.hero {
  background: linear-gradient(135deg, var(--forest) 0%, var(--forest-mid) 55%, #1b6b4a 100%);
  padding: 80px 24px 88px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -120px; right: -80px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(52,201,138,.13) 0%, transparent 65%);
  pointer-events: none;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: -80px; left: 5%;
  width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(212,160,23,.1) 0%, transparent 65%);
  pointer-events: none;
}
.hero-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative; z-index: 1;
}
.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(52,201,138,.15);
  border: 1px solid rgba(52,201,138,.3);
  color: var(--mint);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 40px;
  margin-bottom: 20px;
}
.hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 4.5vw, 3.6rem);
  color: #fff;
  line-height: 1.12;
  letter-spacing: -.5px;
  margin-bottom: 18px;
}
.hero h1 em { font-style: italic; color: var(--mint); }
.hero-sub {
  color: rgba(255,255,255,.65);
  font-size: 1rem;
  line-height: 1.65;
  max-width: 420px;
  margin-bottom: 32px;
}
.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--mint);
  color: var(--forest);
  font-weight: 700;
  font-size: .9rem;
  padding: 14px 28px;
  border-radius: var(--r);
  transition: background var(--t), transform var(--t);
}
.hero-cta:hover { background: #2dbb7c; transform: translateY(-2px); }
.hero-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.hero-stat-card {
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--r-lg);
  padding: 22px 22px;
  backdrop-filter: blur(8px);
  transition: background var(--t);
}
.hero-stat-card:hover { background: rgba(255,255,255,.11); }
.hsc-icon { font-size: 1.5rem; margin-bottom: 10px; }
.hsc-val {
  font-family: var(--font-serif);
  font-size: 2rem;
  color: var(--mint);
  line-height: 1;
  margin-bottom: 4px;
}
.hsc-label { font-size: .78rem; color: rgba(255,255,255,.5); font-weight: 500; }

/* ─── TOPICS STRIP ─── */
.topics-strip { background: var(--bg-card); border-bottom: 1px solid var(--rule); }
.topics-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.topics-inner::-webkit-scrollbar { display: none; }
.topics-inner a {
  white-space: nowrap;
  font-size: .8rem;
  font-weight: 600;
  color: var(--slate);
  padding: 14px 18px;
  border-bottom: 2px solid transparent;
  transition: color var(--t), border-color var(--t);
}
.topics-inner a:hover {
  color: var(--forest);
  border-bottom-color: var(--emerald);
}

/* ─── SECTION HEADING ─── */
.sec-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 28px;
}
.sec-eyebrow {
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--emerald);
  margin-bottom: 4px;
}
.sec-title {
  font-family: var(--font-serif);
  font-size: 1.85rem;
  color: var(--charcoal);
  letter-spacing: -.2px;
}
.sec-all {
  font-size: .77rem;
  font-weight: 700;
  letter-spacing: .8px;
  text-transform: uppercase;
  color: var(--emerald);
  border-bottom: 1px solid currentColor;
  padding-bottom: 1px;
  transition: opacity var(--t);
  white-space: nowrap;
}
.sec-all:hover { opacity: .6; }

/* ─── ARTICLE GRID ─── */
.articles-section { padding: 60px 0; }
.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.article-card {
  background: var(--bg-card);
  border-radius: var(--r-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--rule);
  box-shadow: var(--shadow-sm);
  transition: transform var(--t), box-shadow var(--t);
}
.article-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}
.card-thumb {
  overflow: hidden;
  height: 196px;
  position: relative;
}
.card-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .45s ease;
}
.article-card:hover .card-thumb img { transform: scale(1.06); }
.card-tag {
  position: absolute;
  bottom: 12px; left: 14px;
  background: var(--forest);
  color: rgba(255,255,255,.9);
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 3px;
}
.card-body { padding: 20px 22px 24px; flex: 1; display: flex; flex-direction: column; }
.card-meta { font-size: .72rem; color: var(--mist); margin-bottom: 8px; }
.card-title {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  line-height: 1.32;
  color: var(--charcoal);
  margin-bottom: 10px;
  transition: color var(--t);
}
.article-card:hover .card-title { color: var(--emerald); }
.card-desc { font-size: .86rem; color: var(--slate); line-height: 1.6; flex: 1; margin-bottom: 16px; }
.card-read {
  font-size: .73rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .8px;
  color: var(--emerald);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: gap var(--t);
}
.article-card:hover .card-read { gap: 10px; }

/* ─── ARTICLE PAGE ─── */
.page-wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 48px 24px 72px;
  display: grid;
  grid-template-columns: 1fr 308px;
  gap: 44px;
  align-items: start;
}
.article-header { margin-bottom: 28px; padding-bottom: 24px; border-bottom: 2px solid var(--rule); }
.article-kicker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--forest-lt);
  color: var(--emerald);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 40px;
  margin-bottom: 14px;
}
.article-title {
  font-family: var(--font-serif);
  font-size: clamp(1.7rem, 3.5vw, 2.6rem);
  font-weight: 400;
  line-height: 1.16;
  letter-spacing: -.3px;
  color: var(--charcoal);
  margin-bottom: 16px;
}
.article-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: .78rem;
  color: var(--mist);
  flex-wrap: wrap;
}
.article-body {
  font-size: 1.01rem;
  line-height: 1.8;
  color: var(--slate);
}
.article-body > p:first-of-type { font-size: 1.1rem; color: var(--ink); font-weight: 400; }
.article-body h2 {
  font-family: var(--font-serif);
  font-size: 1.55rem;
  font-weight: 400;
  color: var(--charcoal);
  margin: 38px 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--rule);
}
.article-body h3 {
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
  margin: 26px 0 10px;
}
.article-body p { margin-bottom: 16px; }
.article-body ul, .article-body ol {
  margin: 14px 0 20px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.article-body ul li {
  padding-left: 22px;
  position: relative;
}
.article-body ul li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--mint);
  font-size: .75rem;
  top: 4px;
}
.article-body ol { counter-reset: li; }
.article-body ol li {
  counter-increment: li;
  padding-left: 36px;
  position: relative;
}
.article-body ol li::before {
  content: counter(li);
  position: absolute;
  left: 0; top: 0;
  width: 24px; height: 24px;
  background: var(--forest);
  color: #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: .7rem;
  font-weight: 700;
  line-height: 24px;
  text-align: center;
}
.article-img { margin: 26px 0; border-radius: var(--r-lg); overflow: hidden; }
.article-img img { width: 100%; height: 360px; object-fit: cover; }
.article-img figcaption {
  font-size: .78rem;
  color: var(--mist);
  padding: 10px 14px 4px;
  font-style: italic;
}
.highlight-box {
  background: var(--forest-lt);
  border-left: 4px solid var(--emerald);
  border-radius: 0 var(--r) var(--r) 0;
  padding: 18px 22px;
  margin: 22px 0;
  font-size: .93rem;
}
.highlight-box strong { color: var(--forest); }
.warn-box {
  background: var(--gold-lt);
  border-left: 4px solid var(--gold);
  border-radius: 0 var(--r) var(--r) 0;
  padding: 18px 22px;
  margin: 22px 0;
  font-size: .93rem;
}
.warn-box strong { color: #8a6400; }
.formula-box {
  background: var(--charcoal);
  color: var(--mint);
  border-radius: var(--r-lg);
  padding: 20px 24px;
  margin: 24px 0;
  font-family: monospace;
  font-size: 1rem;
  line-height: 1.7;
}
.formula-box .formula-label {
  font-family: var(--font-sans);
  font-size: .68rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255,255,255,.35);
  margin-bottom: 8px;
}

/* ─── BREADCRUMB ─── */
.breadcrumb {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 16px 24px 0;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .78rem;
  color: var(--mist);
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--slate); transition: color var(--t); }
.breadcrumb a:hover { color: var(--emerald); }

/* ─── SIDEBAR ─── */
.sidebar { position: sticky; top: 82px; }
.sw {
  background: var(--bg-card);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  overflow: hidden;
  margin-bottom: 20px;
  box-shadow: var(--shadow-sm);
}
.sw-title {
  background: var(--forest);
  color: rgba(255,255,255,.85);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 11px 18px;
}
.sw-links { padding: 8px 0; }
.sw-links a {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 11px 18px;
  border-left: 3px solid transparent;
  transition: background var(--t), border-color var(--t), color var(--t);
  font-size: .86rem;
  color: var(--slate);
  line-height: 1.38;
}
.sw-links a:hover {
  background: var(--forest-lt);
  border-left-color: var(--emerald);
  color: var(--forest);
}
.sw-links a .n {
  flex-shrink: 0;
  font-size: .72rem;
  font-weight: 800;
  color: var(--mint);
  margin-top: 2px;
  font-family: var(--font-sans);
}
.sw-inner { padding: 18px; }
.sw-inner p { font-size: .84rem; color: var(--slate); line-height: 1.6; margin-bottom: 8px; }
.sw-inner strong { color: var(--charcoal); font-size: 1.1rem; }

/* ─── FOOTER ─── */
.site-footer { background: var(--charcoal); color: rgba(255,255,255,.45); margin-top: 72px; }
.footer-top {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 52px 24px 40px;
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1fr;
  gap: 40px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}
.footer-brand .logo { margin-bottom: 14px; }
.footer-brand p { font-size: .85rem; line-height: 1.7; max-width: 260px; }
.footer-col h4 {
  font-size: .67rem;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: rgba(255,255,255,.28);
  margin-bottom: 14px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 9px; }
.footer-col a { font-size: .83rem; transition: color var(--t); }
.footer-col a:hover { color: var(--mint); }
.footer-bottom {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 18px 24px;
  display: flex;
  justify-content: space-between;
  font-size: .77rem;
  flex-wrap: wrap;
  gap: 8px;
}
.footer-disc { font-size: .74rem; color: rgba(255,255,255,.22); max-width: 600px; }

/* ─── RESPONSIVE ─── */
@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-stats-grid { grid-template-columns: repeat(4, 1fr); }
  .articles-grid { grid-template-columns: repeat(2, 1fr); }
  .page-wrap { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .articles-grid { grid-template-columns: 1fr; }
  .hero-stats-grid { grid-template-columns: 1fr 1fr; }
  .site-nav a { padding: 8px 8px; font-size: .76rem; }
  .footer-top { grid-template-columns: 1fr; }
}
