/* ============================================
   НПО АГРАРИУМ — Дизайн-система
   ============================================ */

/* --- CSS Variables --- */
:root {
  --primary: #1B4332;
  --primary-light: #2D6A4F;
  --primary-lighter: #52B788;
  --primary-pale: #D8F3DC;
  --primary-bg: #F0F7F4;

  --accent: #E76F51;
  --accent-light: #F4A261;
  --accent-bg: #FFF3E0;

  --text: #1A1A2E;
  --text-secondary: #4A4A5A;
  --text-muted: #6C757D;
  --border: #D0D5DD;
  --bg-light: #F8F9FA;
  --bg-white: #FFFFFF;

  --success: #2D6A4F;
  --error: #D32F2F;

  --beef: #7F5539;
  --poultry: #E76F51;

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --max-width: 1200px;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 2px 12px rgba(0,0,0,0.06);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.1);
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--font);
  color: var(--text);
  line-height: 1.6;
  background: var(--bg-white);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary-light); text-decoration: none; }
a:hover { text-decoration: underline; }

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

/* --- Typography --- */
h1 { font-size: 2.75rem; font-weight: 700; line-height: 1.15; letter-spacing: -0.02em; color: var(--text); }
h2 { font-size: 2rem; font-weight: 700; line-height: 1.2; letter-spacing: -0.01em; margin-bottom: 16px; }
h3 { font-size: 1.35rem; font-weight: 600; line-height: 1.3; margin-bottom: 8px; }
p { margin-bottom: 16px; }

/* --- Buttons --- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font); font-size: 1rem; font-weight: 600;
  border: none; border-radius: var(--radius-sm); cursor: pointer;
  padding: 14px 32px; transition: all 0.2s ease; text-decoration: none;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }

.btn-primary {
  background: var(--primary-light); color: #fff;
  box-shadow: 0 2px 8px rgba(45,106,79,0.2);
}
.btn-primary:hover { background: var(--primary); box-shadow: 0 4px 16px rgba(45,106,79,0.3); }

.btn-accent {
  background: var(--accent); color: #fff;
  box-shadow: 0 2px 8px rgba(231,111,81,0.25);
}
.btn-accent:hover { background: #C85A3E; box-shadow: 0 4px 16px rgba(231,111,81,0.35); }

.btn-outline {
  background: transparent; color: var(--primary-light);
  border: 2px solid var(--primary-light);
}
.btn-outline:hover { background: var(--primary-bg); }

.btn-white { background: #fff; color: var(--primary); }
.btn-white:hover { background: #f0f0f0; }

.btn-lg { padding: 16px 40px; font-size: 1.05rem; }
.btn-block { width: 100%; }

/* --- Header --- */
.header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,0.97); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  padding: 0 24px; height: 72px;
}
.header-inner {
  max-width: var(--max-width); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  height: 100%;
}
.header-logo {
  font-size: 1.15rem; font-weight: 700; color: var(--primary);
  display: flex; align-items: center; gap: 10px;
}
.header-logo span { color: var(--primary-lighter); font-weight: 400; font-size: 0.85rem; }
.header-nav { display: flex; align-items: center; gap: 28px; }
.header-nav a { color: var(--text-secondary); font-size: 0.95rem; font-weight: 500; }
.header-nav a:hover { color: var(--primary); text-decoration: none; }
.header-phone {
  display: flex; align-items: center; gap: 8px;
  color: var(--primary); font-weight: 600; font-size: 0.95rem;
}
.header-cta { margin-left: 16px; }
.burger { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.burger svg { width: 28px; height: 28px; stroke: var(--text); }

/* Mobile menu */
.mobile-menu {
  display: none; position: fixed; top: 72px; left: 0; right: 0; bottom: 0;
  background: #fff; z-index: 99; padding: 24px; flex-direction: column; gap: 16px;
  overflow-y: auto;
}
.mobile-menu.active { display: flex; }
.mobile-menu a {
  font-size: 1.1rem; padding: 12px 0; border-bottom: 1px solid var(--border);
  color: var(--text); display: block;
}

/* --- Hero --- */
.hero {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--primary) 0%, #1a3c2e 100%);
  color: #fff; padding: 80px 0 88px;
}
.hero-content { position: relative; z-index: 2; max-width: 680px; }
.hero h1 { color: #fff; margin-bottom: 20px; }
.hero p { font-size: 1.15rem; line-height: 1.7; opacity: 0.92; margin-bottom: 32px; }
.hero-stats {
  display: flex; gap: 40px; margin-top: 40px;
}
.hero-stat { text-align: center; }
.hero-stat-number { font-size: 2.5rem; font-weight: 700; color: var(--accent-light); }
.hero-stat-label { font-size: 0.85rem; opacity: 0.8; margin-top: 4px; }
.hero-badges {
  display: flex; align-items: center; gap: 12px; margin-top: 32px;
  font-size: 0.85rem; opacity: 0.75;
}
.hero-badges svg { width: 20px; height: 20px; fill: var(--accent-light); }
.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; }

/* --- Sections --- */
.section { padding: 80px 0; }
.section-light { background: var(--bg-light); }
.section-dark { background: var(--primary); color: #fff; }
.section-header { text-align: center; max-width: 700px; margin: 0 auto 48px; }
.section-header p { color: var(--text-secondary); font-size: 1.05rem; }

/* --- Problem Cards --- */
.problem-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.problem-card {
  background: var(--bg-white); border-radius: var(--radius); padding: 32px;
  box-shadow: var(--shadow); border-top: 4px solid var(--accent);
}
.problem-card-icon {
  width: 56px; height: 56px; border-radius: 12px;
  background: var(--accent-bg); display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px; font-size: 1.5rem;
}
.problem-card h3 { font-size: 1.1rem; margin-bottom: 8px; }
.problem-card p { color: var(--text-secondary); font-size: 0.95rem; margin-bottom: 0; }

/* --- Product (Solution) --- */
.solution-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.solution-features { list-style: none; }
.solution-features li {
  padding: 12px 0; padding-left: 32px; position: relative;
  border-bottom: 1px solid var(--border);
}
.solution-features li::before {
  content: '✓'; position: absolute; left: 0; color: var(--primary-lighter);
  font-weight: 700; font-size: 1.1rem;
}
.solution-features li:last-child { border-bottom: none; }
.solution-features li strong { color: var(--primary); }
.solution-img {
  background: var(--bg-light); border-radius: var(--radius);
  height: 400px; display: flex; align-items: center; justify-content: center;
  font-size: 4rem; color: var(--primary-lighter);
}

/* --- Stats --- */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; text-align: center; }
.stat-number {
  font-size: 3rem; font-weight: 700; color: var(--accent-light);
  line-height: 1;
}
.stat-label { font-size: 0.95rem; opacity: 0.85; margin-top: 8px; }

/* --- Case Study --- */
.case-card {
  background: var(--bg-white); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); overflow: hidden;
}
.case-header {
  background: var(--primary); color: #fff; padding: 32px;
}
.case-header h3 { font-size: 1.35rem; color: #fff; margin-bottom: 4px; }
.case-header p { opacity: 0.8; margin-bottom: 0; font-size: 0.95rem; }
.case-body { padding: 32px; }
.case-table { width: 100%; border-collapse: collapse; margin-bottom: 24px; }
.case-table th, .case-table td {
  padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--border);
  font-size: 0.95rem;
}
.case-table th { color: var(--text-muted); font-weight: 500; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.05em; }
.case-table .highlight { color: var(--primary-light); font-weight: 700; font-size: 1.1rem; }
.case-economics {
  background: var(--primary-bg); border-radius: var(--radius-sm); padding: 24px;
  border-left: 4px solid var(--primary-light);
}
.case-economics h4 { color: var(--primary); margin-bottom: 12px; }
.case-economics .big-number {
  font-size: 2rem; font-weight: 700; color: var(--primary);
}
.case-quote {
  margin-top: 24px; padding: 20px; background: var(--bg-light);
  border-radius: var(--radius-sm); font-style: italic; color: var(--text-secondary);
  position: relative; padding-left: 40px;
}
.case-quote::before { content: '"'; position: absolute; left: 12px; top: 8px; font-size: 2.5rem; color: var(--primary-pale); font-style: normal; }

/* --- Calculator --- */
.calc-wrapper {
  background: var(--bg-white); border-radius: var(--radius); padding: 40px;
  box-shadow: var(--shadow-lg); max-width: 800px; margin: 0 auto;
}
.calc-tabs { display: flex; gap: 8px; margin-bottom: 32px; }
.calc-tab {
  flex: 1; padding: 14px 16px; border: 2px solid var(--border);
  border-radius: var(--radius-sm); background: #fff; cursor: pointer;
  text-align: center; font-weight: 500; font-size: 0.95rem;
  font-family: var(--font); transition: all 0.2s;
}
.calc-tab:hover { border-color: var(--primary-lighter); }
.calc-tab.active {
  border-color: var(--primary-light); background: var(--primary-bg);
  color: var(--primary); font-weight: 600;
}
.calc-tab-icon { font-size: 1.5rem; display: block; margin-bottom: 4px; }
.calc-input-group { margin-bottom: 24px; }
.calc-input-group label {
  display: block; font-size: 0.9rem; font-weight: 500;
  color: var(--text-secondary); margin-bottom: 8px;
}
.calc-input {
  width: 100%; height: 52px; padding: 0 16px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: 1.1rem; font-family: var(--font); color: var(--text);
  transition: border 0.2s;
}
.calc-input:focus { outline: none; border: 2px solid var(--primary-light); box-shadow: 0 0 0 4px rgba(45,106,79,0.1); }
.calc-result {
  display: none; margin-top: 32px; padding: 32px;
  background: var(--primary-bg); border-radius: var(--radius);
  border-left: 4px solid var(--primary-light);
}
.calc-result.show { display: block; animation: fadeIn 0.4s ease; }
.calc-result-row {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 8px 0; border-bottom: 1px solid rgba(45,106,79,0.15);
}
.calc-result-row:last-child { border-bottom: none; }
.calc-result-label { color: var(--text-secondary); }
.calc-result-value { font-weight: 600; font-size: 1.1rem; color: var(--primary); }
.calc-result-total {
  margin-top: 16px; padding-top: 16px; border-top: 2px solid var(--primary-light);
}
.calc-result-total .calc-result-value { font-size: 1.8rem; color: var(--primary); }
.calc-disclaimer {
  font-size: 0.8rem; color: var(--text-muted); margin-top: 16px;
  line-height: 1.5;
}

/* --- Comparison Table --- */
.comparison-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.comparison-table th, .comparison-table td { padding: 14px 20px; text-align: left; border-bottom: 1px solid var(--border); font-size: 0.95rem; }
.comparison-table thead th { background: var(--bg-light); color: var(--text-muted); font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; }
.comparison-table .col-pusk { background: var(--primary-bg); font-weight: 600; color: var(--primary); }
.comparison-table .check { color: var(--success); }
.comparison-table .cross { color: var(--error); }
.comparison-table .warn { color: var(--accent-light); }

/* --- Objections / FAQ --- */
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-question {
  width: 100%; padding: 20px 0; background: none; border: none;
  font-family: var(--font); font-size: 1.05rem; font-weight: 600;
  color: var(--text); cursor: pointer; text-align: left;
  display: flex; justify-content: space-between; align-items: center;
}
.faq-question:hover { color: var(--primary-light); }
.faq-icon {
  width: 24px; height: 24px; flex-shrink: 0; transition: transform 0.3s;
  stroke: var(--text-muted);
}
.faq-item.open .faq-icon { transform: rotate(45deg); }
.faq-answer {
  max-height: 0; overflow: hidden; transition: max-height 0.3s ease;
}
.faq-answer-inner {
  padding-bottom: 20px; color: var(--text-secondary);
  font-size: 0.95rem; line-height: 1.7;
}

/* --- CTA Section --- */
.cta-section {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  color: #fff; text-align: center; padding: 80px 0;
}
.cta-section h2 { color: #fff; margin-bottom: 16px; }
.cta-section p { opacity: 0.9; font-size: 1.1rem; max-width: 600px; margin: 0 auto 32px; }

/* --- Form --- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.form-group { display: flex; flex-direction: column; }
.form-group.full { grid-column: 1 / -1; }
.form-label { font-size: 0.9rem; font-weight: 500; color: var(--text-secondary); margin-bottom: 6px; }
.form-input {
  height: 48px; padding: 0 16px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); font-size: 1rem; font-family: var(--font);
  color: var(--text); background: #fff; transition: border 0.2s;
}
.form-input:focus { outline: none; border: 2px solid var(--primary-light); box-shadow: 0 0 0 4px rgba(45,106,79,0.1); }
.form-input::placeholder { color: var(--text-muted); }
.form-consent { display: flex; align-items: flex-start; gap: 10px; font-size: 0.85rem; color: var(--text-muted); margin-bottom: 20px; }
.form-consent input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--primary-light); }
.form-consent a { color: var(--primary-lighter); }

/* --- Footer --- */
.footer { background: var(--primary); color: #fff; padding: 48px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-brand p { opacity: 0.7; font-size: 0.9rem; margin-top: 8px; }
.footer h4 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.08em; opacity: 0.5; margin-bottom: 16px; }
.footer a { color: rgba(255,255,255,0.8); font-size: 0.95rem; }
.footer a:hover { color: #fff; }
.footer ul { list-style: none; }
.footer ul li { margin-bottom: 10px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15); padding-top: 24px;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 0.85rem; opacity: 0.6;
}
.footer-disclaimer { font-size: 0.75rem; opacity: 0.5; margin-top: 16px; line-height: 1.5; }

/* --- WhatsApp Float --- */
.wa-float {
  position: fixed; bottom: 24px; right: 24px; z-index: 90;
  width: 56px; height: 56px; border-radius: 50%;
  background: #25D366; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 16px rgba(37,211,102,0.4);
  transition: transform 0.2s; text-decoration: none;
}
.wa-float:hover { transform: scale(1.1); text-decoration: none; }
.wa-float svg { width: 28px; height: 28px; fill: #fff; }

/* --- Cookie Banner --- */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 100;
  background: var(--text); color: #fff; padding: 16px 24px;
  display: flex; align-items: center; justify-content: center; gap: 16px;
  font-size: 0.9rem;
}
.cookie-banner.hidden { display: none; }
.cookie-btn {
  background: var(--primary-light); color: #fff; border: none;
  padding: 8px 20px; border-radius: var(--radius-sm); cursor: pointer;
  font-family: var(--font); font-size: 0.85rem; font-weight: 500;
}

/* --- Animations --- */
@keyframes fadeIn { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
.fade-in { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* --- Responsive --- */
@media (max-width: 1024px) {
  .header-nav { display: none; }
  .header-cta { display: none; }
  .burger { display: block; }
  .hero h1 { font-size: 2rem; }
  .hero-stats { gap: 24px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  h1 { font-size: 1.85rem; }
  h2 { font-size: 1.5rem; }
  .section { padding: 56px 0; }
  .hero { padding: 56px 0 64px; }
  .hero-stats { flex-wrap: wrap; gap: 16px; }
  .hero-stat { flex: 0 0 calc(50% - 8px); }
  .hero-stat-number { font-size: 2rem; }
  .hero-cta { flex-direction: column; }
  .hero-cta .btn { width: 100%; }
  .problem-grid { grid-template-columns: 1fr; }
  .solution-grid { grid-template-columns: 1fr; }
  .solution-img { height: 250px; order: -1; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
  .calc-tabs { flex-direction: column; }
  .comparison-table { font-size: 0.85rem; }
  .comparison-table th, .comparison-table td { padding: 10px 12px; }
  div[style*="grid-template-columns:repeat(4"] { grid-template-columns: repeat(2, 1fr) !important; }
}
