/* AEPS Agri — Marquee, Elevator stocks, "live" pulse. */

/* --------- Marquee товаров --------- */
.marquee {
  overflow: hidden;
  padding: 12px 0;
  background: linear-gradient(90deg,
    rgba(255,255,255,0.65) 0%,
    rgba(250,235,215,0.85) 50%,
    rgba(255,255,255,0.65) 100%);
  border-top: 1px solid rgba(207,90,44,0.12);
  border-bottom: 1px solid rgba(207,90,44,0.12);
  position: relative;
  z-index: 1;
}
.marquee::before, .marquee::after {
  content: "";
  position: absolute;
  top: 0; bottom: 0;
  width: 90px;
  z-index: 2;
  pointer-events: none;
}
.marquee::before { left: 0;  background: linear-gradient(90deg, var(--paper) 0%, transparent 100%); }
.marquee::after  { right: 0; background: linear-gradient(-90deg, var(--paper) 0%, transparent 100%); }
.marquee-track {
  display: inline-flex;
  gap: 24px;
  padding-left: 100%;
  white-space: nowrap;
  animation: marqueeScroll 60s linear infinite;
  will-change: transform;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-item {
  font-family: var(--f-display);
  font-size: 15px;
  color: var(--ink);
  font-weight: 500;
  letter-spacing: -0.005em;
}
.marquee-sep {
  color: var(--terra);
  font-size: 14px;
  opacity: 0.7;
}
@keyframes marqueeScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
[dir="rtl"] .marquee-track { animation-direction: reverse; }

/* --------- LIVE pulse dot --------- */
.dot.pulse {
  position: relative;
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 0 rgba(34,197,94,0.6);
  animation: livePulse 2s ease-out infinite;
}
@keyframes livePulse {
  0%   { box-shadow: 0 0 0 0 rgba(34,197,94,0.55); }
  70%  { box-shadow: 0 0 0 14px rgba(34,197,94,0); }
  100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); }
}
.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(34,197,94,0.10);
  border: 1px solid rgba(34,197,94,0.25);
  color: #15803d;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* --------- Elevator stocks --------- */
.stocks-band {
  padding: 80px 0 40px;
  background: linear-gradient(180deg, rgba(255,255,255,0) 0%, rgba(250,235,215,0.35) 100%);
}
.stocks-head {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 32px;
  align-items: end;
  margin-bottom: 28px;
}
.stocks-head .eyebrow {
  font-size: 12px;
  color: var(--terra);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0 0 8px;
}
.stocks-head h3 {
  font-family: var(--f-display);
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.15;
  margin: 0 0 12px;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.stocks-head h3 em {
  font-style: normal;
  background: linear-gradient(90deg, var(--terra), var(--amber));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stocks-lede {
  max-width: 560px;
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}
.stocks-meta {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: flex-end;
  font-size: 13px;
  color: var(--muted);
}
.stocks-meta b { color: var(--ink); font-weight: 600; margin-left: 4px; }

.stocks-table-wrap {
  background: var(--white);
  border-radius: var(--r-lg);
  padding: 8px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--line);
  overflow: hidden;
}
.stocks-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.stocks-table thead th {
  text-align: right;
  padding: 14px 12px;
  color: var(--muted);
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid var(--line);
  background: rgba(250,235,215,0.35);
}
.stocks-table thead th:first-child,
.stocks-table thead th:nth-child(2) {
  text-align: left;
}
.stock-row td {
  padding: 12px;
  border-bottom: 1px solid rgba(139,92,50,0.06);
  text-align: right;
  vertical-align: middle;
}
.stock-row:last-child td { border-bottom: none; }
.stock-row td:first-child { text-align: left; }
.stock-row td:nth-child(2) { text-align: left; color: var(--muted); font-size: 13px; }
.col-region {
  display: flex;
  align-items: center;
  gap: 10px;
}
.region-flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  min-width: 38px;
  height: 22px;
  border-radius: 4px;
  background: linear-gradient(135deg, var(--terra), var(--amber));
  color: var(--white);
  font-family: var(--f-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  box-shadow: 0 4px 8px -4px rgba(207,90,44,0.4);
}
.region-name {
  font-weight: 500;
  color: var(--ink);
}
.col-num b { font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.col-total { border-left: 1px solid rgba(139,92,50,0.06); }
.col-total b { color: var(--terra); font-size: 15px; }
.stock-row:hover td { background: rgba(250,235,215,0.4); transition: background .2s ease; }
.stock-foot td {
  background: rgba(250,235,215,0.55) !important;
  border-top: 2px solid var(--terra-soft);
  font-weight: 700;
}
.stock-foot .region-name { font-weight: 700; text-transform: uppercase; font-size: 12px; letter-spacing: 0.06em; }
.stocks-loading {
  text-align: center;
  color: var(--muted);
  padding: 40px 20px;
  font-style: italic;
}
.stocks-unit {
  margin: 14px 4px 0;
  color: var(--muted);
  font-size: 12px;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  flex-wrap: wrap;
}

/* --------- RTL --------- */
[dir="rtl"] .stocks-table thead th { text-align: left; }
[dir="rtl"] .stocks-table thead th:first-child,
[dir="rtl"] .stocks-table thead th:nth-child(2) { text-align: right; }
[dir="rtl"] .stock-row td { text-align: left; }
[dir="rtl"] .stock-row td:first-child { text-align: right; }
[dir="rtl"] .stock-row td:nth-child(2) { text-align: right; }
[dir="rtl"] .stocks-head { grid-template-columns: 1fr 1.4fr; }
[dir="rtl"] .stocks-meta { align-items: flex-start; }
[dir="rtl"] .col-total { border-left: none; border-right: 1px solid rgba(139,92,50,0.06); }

/* --------- Responsive --------- */
@media (max-width: 900px) {
  .stocks-head { grid-template-columns: 1fr; gap: 16px; align-items: start; }
  .stocks-meta { align-items: flex-start; }
  .stocks-table-wrap { overflow-x: auto; }
  .stocks-table { min-width: 720px; }
}

/* --------- Crop card top photo band --------- */
.crop { min-height: 420px; }
.crop.has-photo { padding-top: 0; }
.crop.has-photo .crop-glyph { display: none; }
.crop.has-photo .crop-head { grid-template-columns: 1fr; padding-top: 20px; }
.crop-photo {
  position: relative;
  height: 140px;
  margin: -1px -25px 22px;
  background-size: cover;
  background-position: center;
  border-radius: var(--r) var(--r) 0 0;
  overflow: hidden;
  transform: translateZ(0);
  transition: transform .6s cubic-bezier(0.16,1,0.3,1);
}
.crop-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0) 60%, rgba(255,255,255,0.55) 100%);
}
.crop:hover .crop-photo { transform: scale(1.05); }

/* --------- Supply chain 4-step gallery --------- */
.chain-band {
  padding: 100px 0;
  background: linear-gradient(180deg, var(--white) 0%, var(--cream) 100%);
  position: relative;
  overflow: hidden;
}
.chain-head {
  text-align: center;
  max-width: 780px;
  margin: 0 auto 56px;
}
.chain-head .eyebrow {
  font-size: 12px;
  color: var(--terra);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin: 0 0 12px;
}
.chain-head h2 {
  font-family: var(--f-display);
  font-size: clamp(32px, 3.6vw, 46px);
  line-height: 1.1;
  margin: 0 0 18px;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.chain-head h2 em {
  font-style: normal;
  background: linear-gradient(90deg, var(--terra), var(--amber));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.chain-lede {
  max-width: 640px;
  margin: 0 auto;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}
.chain-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.chain-step {
  position: relative;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: all .4s cubic-bezier(0.16,1,0.3,1);
  display: flex;
  flex-direction: column;
}
.chain-step:hover {
  transform: translateY(-6px);
  border-color: var(--terra-soft);
  box-shadow: var(--shadow-lg);
}
.chain-photo {
  aspect-ratio: 4/3;
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
  transform: translateZ(0);
  transition: transform .6s cubic-bezier(0.16,1,0.3,1);
}
.chain-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 55%, rgba(0,0,0,0.25) 100%);
}
.chain-step:hover .chain-photo { transform: scale(1.08); }
.chain-body {
  padding: 22px 22px 26px;
  position: relative;
}
.chain-num {
  position: absolute;
  top: -22px;
  left: 22px;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--terra), var(--amber));
  color: var(--white);
  font-family: var(--f-display);
  font-weight: 700;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 24px -8px rgba(207,90,44,0.4);
}
.chain-body h3 {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: 20px;
  margin: 26px 0 10px;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.chain-body p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
  margin: 0;
}
@media (max-width: 1100px) { .chain-steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px)  { .chain-steps { grid-template-columns: 1fr; } .chain-band { padding: 70px 0; } }

/* --------- Hero luxury 2-column layout --------- */
.hero {
  padding: 140px 0 120px !important;
  min-height: auto;
  display: block !important;
  overflow: hidden;
  position: relative;
  background: linear-gradient(180deg, #faf6ee 0%, #f5eddc 100%);
}
.hero::before { content: none !important; }
.hero::after  { content: none !important; }

.hero .wrap {
  position: relative;
  z-index: 2;
  max-width: 1280px !important;
  padding: 0 32px;
}

.hero-wrap {
  display: grid !important;
  grid-template-columns: 1.05fr 1fr;
  gap: 72px;
  align-items: center;
}

/* Photo becomes right column card, not full-bleed */
.hero-photo {
  position: relative !important;
  grid-column: 2;
  z-index: 1;
  inset: auto !important;
  opacity: 0;
  transition: opacity 1.4s ease;
  height: 580px;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 40px 80px -30px rgba(60, 40, 25, 0.35),
              0 20px 40px -20px rgba(60, 40, 25, 0.15);
  order: 2;
}
.hero-photo.loaded { opacity: 1; }
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 60%;
  filter: saturate(1.05) contrast(1.02);
  transform: scale(1.02);
  animation: heroSlow 26s ease-in-out infinite alternate;
}
@keyframes heroSlow {
  from { transform: scale(1.02); }
  to   { transform: scale(1.08); }
}

/* Copy — left column */
.hero-copy {
  max-width: none !important;
  margin: 0 !important;
  text-align: left !important;
  grid-column: 1;
  order: 1;
}

/* Luxury eyebrow — тонкая линия + мелкий caps */
.hero .eyebrow {
  display: inline-flex !important;
  align-items: center;
  gap: 16px;
  padding: 0 !important;
  background: transparent !important;
  backdrop-filter: none !important;
  border-radius: 0 !important;
  color: rgba(60, 40, 25, 0.72);
  font-family: var(--f-sans);
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  font-weight: 600;
  margin: 0 0 28px;
}
.hero .eyebrow::before { content: none !important; }
.hero .eyebrow-line {
  display: inline-block;
  width: 40px;
  height: 1px;
  background: currentColor;
  opacity: 0.5;
}

/* H1 — крупнее, серьёзнее */
.hero-copy { max-width: 880px; }
.hero h1 {
  font-size: clamp(38px, 4.4vw, 62px) !important;
  line-height: 1.06 !important;
  letter-spacing: -0.02em !important;
  margin: 0 0 28px !important;
  color: #2a1e12 !important;
  font-weight: 400 !important;
}
.hero h1 em {
  font-style: italic;
  font-weight: 400 !important;
  color: #a83b15 !important;
  background: none !important;
  -webkit-background-clip: initial !important;
  background-clip: initial !important;
  -webkit-text-fill-color: currentColor !important;
}

/* Lede — читабельный, контрастный */
.hero .lede {
  max-width: none !important;
  margin: 0 0 40px !important;
  font-size: 17px;
  line-height: 1.7;
  color: rgba(42, 30, 18, 0.78) !important;
  font-weight: 400;
}

/* CTA — luxury тонкие рамки, свои линии */
.hero-cta { justify-content: flex-start !important; gap: 16px; }
.hero .btn {
  padding: 15px 30px !important;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  border-radius: 999px;
  transition: all .3s ease;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.hero .btn-primary {
  background: linear-gradient(120deg, #cf5a2c, #a83b15) !important;
  color: #fff !important;
  border: none;
  box-shadow: 0 12px 32px -12px rgba(207, 90, 44, 0.55);
}
.hero .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 40px -14px rgba(207, 90, 44, 0.7);
}
.hero .btn-outline {
  background: transparent !important;
  color: #2a1e12 !important;
  border: 1px solid rgba(60, 40, 25, 0.28) !important;
}
.hero .btn-outline:hover {
  border-color: #2a1e12 !important;
  background: rgba(42, 30, 18, 0.05) !important;
  transform: translateY(-2px);
}
.hero .btn-outline svg { transition: transform .3s ease; }
.hero .btn-outline:hover svg { transform: translateX(3px); }

@media (max-width: 900px) {
  .hero { padding: 100px 0 70px !important; }
  .hero-wrap { grid-template-columns: 1fr !important; gap: 40px; }
  .hero-photo { grid-column: 1; height: 320px; order: 2; }
  .hero-copy { grid-column: 1; order: 1; }
  .hero .eyebrow { font-size: 10px; letter-spacing: 0.22em; }
  .hero .eyebrow-line { width: 24px; }
  .hero h1 { font-size: clamp(32px, 7vw, 44px) !important; }
  .hero .lede { font-size: 15.5px; }
  .hero-cta { flex-direction: column; align-items: stretch; }
  .hero .btn { justify-content: center; }
}
