/*
Theme Name: MEMEX
Theme URI: https://memex-marketing.ru
Author: МЕМЕКС
Description: Фирменная тема МЕМЕКС — внешний отдел маркетинга. Navy #0B1422 + growth lime #B6F23D + gold #E8B84A.
Version: 1.9
Requires PHP: 8.0
Text Domain: memex
*/

:root {
  --ink: #0B1422;
  --lime: #B6F23D;
  --milk: #F5F5F0;
  --graphite: #1B2635;
  --graphite-border: #293548;
  --slate: #8C98A8;
  --text-on-dark: #F7F8F6;
  --text-soft-dark: #C7CDD6;
  --text-soft-darker: #A7B0BC;
  --text-on-light: #0B1422;
  --text-soft-light: #55606E;
  --light-border: #E1E4DD;
  --link: #5B8CFF;
  --danger: #E85D5D;
  --gold: #E8B84A;
  --good: #4ADE80;
}

@font-face {
  font-family: 'EurostileExt';
  src: url('eurostile-bold-ext.woff2') format('woff2');
  font-weight: 400 800;
  font-display: swap;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Manrope', 'Segoe UI', system-ui, sans-serif;
  background: var(--ink);
  color: var(--text-on-dark);
  font-size: 16px;
  line-height: 1.6;
}
img { max-width: 100%; height: auto; }
a { color: var(--link); text-decoration: none; }
a:hover { color: #7FA5FF; }

/* Заголовки и цифры — гротеск (финансовый отчёт, не постер). */
.h, h1, h2, h3 { font-family: 'Manrope', 'Segoe UI', system-ui, sans-serif; font-weight: 800; margin: 0; }
/* Фирменный Eurostile — только бренд-зоны: логотип, H1, финальный CTA. */
.hero-title, .cta-title, .brand-logo, .footer-logo { font-family: 'EurostileExt', 'Russo One', 'Arial Black', sans-serif; font-weight: 400; }

.wrap { max-width: 1320px; margin: 0 auto; padding: 0 60px; }

/* ---------- BUTTONS ---------- */
.btn { display: inline-block; border-radius: 12px; font-weight: 800; font-size: 17px; padding: 17px 34px; cursor: pointer; border: none; transition: transform .15s ease, box-shadow .15s ease; }
.btn:hover { transform: translateY(-2px); }
.btn-lime { background: var(--lime); color: var(--ink); }
.btn-lime:hover { color: var(--ink); box-shadow: 0 10px 30px rgba(182, 242, 61, .25); }
.btn-ghost { border: 1px solid #2A3444; color: var(--text-on-dark); background: transparent; }
.btn-ghost:hover { color: var(--text-on-dark); border-color: #3A4658; }

/* ---------- NAV ---------- */
.site-nav { display: flex; align-items: center; justify-content: space-between; padding: 22px 60px; border-bottom: 1px solid var(--graphite); }
.brand { display: flex; align-items: baseline; gap: 14px; }
.brand-logo { font-size: 26px; letter-spacing: .06em; color: var(--text-on-dark); }
.brand-logo span { color: var(--lime); }
.brand-tag { font-size: 13px; letter-spacing: .2em; color: var(--text-soft-dark); font-weight: 700; }
.nav-links { display: flex; align-items: center; gap: 32px; font-size: 15px; font-weight: 600; color: var(--text-soft-dark); }
.nav-links a { color: var(--text-soft-dark); }
.nav-links a:hover { color: var(--text-on-dark); }
.nav-cta { background: var(--lime); color: var(--ink) !important; padding: 11px 22px; border-radius: 10px; font-weight: 800; }

/* ---------- SECTIONS ---------- */
.sec { padding: 96px 0; }
.sec-dark { background: var(--ink); color: var(--text-on-dark); }
.sec-light { background: var(--milk); color: var(--text-on-light); }
.sec-graphite { background: var(--graphite); color: var(--text-on-dark); }
.sec-title { font-size: 38px; line-height: 1.15; }
.sec-sub { color: var(--text-soft-light); font-size: 16px; margin-top: 10px; }

/* ---------- HERO ---------- */
.hero { display: flex; gap: 48px; align-items: center; padding: 88px 0 96px; }
.hero-main { flex: 1.25; }
.hero-title { font-size: 60px; line-height: 1.08; letter-spacing: .01em; }
.hero-title2 { font-size: 30px; line-height: 1.25; color: var(--text-soft-dark); margin-top: 14px; }
.hero-p { font-size: 19px; line-height: 1.6; color: var(--text-soft-dark); margin: 28px 0 0; max-width: 620px; }
.hero-p + .hero-p { margin-top: 14px; }
.hero-p strong { color: var(--text-on-dark); font-weight: 800; }
.hero-accent { font-weight: 800; color: var(--lime); font-size: 21px; letter-spacing: .02em; }
.hero-ctas { display: flex; gap: 16px; margin-top: 40px; align-items: center; flex-wrap: wrap; }
.hero-proof { display: flex; gap: 26px; margin-top: 44px; font-size: 15.5px; color: var(--text-soft-dark); font-weight: 700; flex-wrap: wrap; }
.hero-proof .dot { color: #2A3444; }
.gold { color: var(--gold); }

.report-card { flex: 1; background: var(--graphite); border: 1px solid var(--graphite-border); border-radius: 18px; padding: 32px 34px; box-shadow: 0 24px 60px rgba(0,0,0,.35); }
.report-label { font-size: 13px; letter-spacing: .14em; color: var(--slate); font-weight: 700; }
.report-row { display: flex; justify-content: space-between; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--graphite-border); }
.report-row:last-of-type { border-bottom: none; }
.report-row .k { color: var(--text-soft-dark); font-size: 15.5px; }
.report-row .v { font-weight: 800; font-size: 23px; color: var(--text-on-dark); letter-spacing: .01em; }
.report-row .v.lime { color: var(--lime); }
.report-note { margin-top: 14px; font-size: 12.5px; color: var(--slate); }

/* ---------- CARD GRIDS ---------- */
.grid { display: grid; gap: 24px; margin-top: 44px; }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }

.card { background: #fff; border: 1px solid var(--light-border); border-radius: 16px; padding: 26px; transition: border-color .15s ease; }
.card:hover { border-color: var(--lime); }
.card-cat { font-size: 11px; letter-spacing: .16em; font-weight: 700; color: var(--slate); margin-bottom: 12px; }
.card-t { font-weight: 800; font-size: 18px; line-height: 1.4; }
.card-p { color: var(--text-soft-light); font-size: 15.5px; line-height: 1.6; margin-top: 12px; }
.card .loss { color: inherit; font-weight: 800; }
.after-grid-note { margin-top: 28px; color: var(--text-soft-light); font-size: 15px; }

.icon-chip { width: 44px; height: 44px; border-radius: 12px; background: var(--lime); display: flex; align-items: center; justify-content: center; }

/* ---------- SYSTEM BAND (перестроили работу) ---------- */
.sys-band { margin-top: 40px; background: var(--ink); border-radius: 18px; padding: 34px 38px; color: var(--text-on-dark); }
.sys-head { font-weight: 800; font-size: 22px; }
.sys-p { color: var(--text-soft-dark); font-size: 15.5px; line-height: 1.6; margin: 14px 0 0; max-width: 880px; }
.sys-points { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 24px; font-size: 14.5px; color: var(--text-soft-dark); line-height: 1.55; }
.sys-points strong { color: var(--text-on-dark); display: block; margin-bottom: 4px; }
.sys-motto { margin-top: 26px; font-weight: 800; font-size: 16px; color: var(--lime); letter-spacing: .01em; }

/* ---------- STORY (долгий горизонт) ---------- */
.story { display: flex; gap: 44px; margin-top: 40px; align-items: flex-start; }
.story-main { flex: 1.2; }
.tl-row { display: flex; gap: 20px; padding: 15px 0; border-bottom: 1px solid var(--light-border); align-items: baseline; }
.tl-row:last-child { border-bottom: none; }
.tl-year { font-weight: 800; font-size: 20px; min-width: 64px; color: var(--text-on-light); }
.tl-t { color: var(--text-soft-light); font-size: 15.5px; line-height: 1.55; }
.tl-t strong { color: var(--text-on-light); }
.story-more { margin-top: 18px; color: var(--text-soft-light); font-size: 14.5px; line-height: 1.6; }
.map-card { flex: .8; background: #fff; border: 1px solid var(--light-border); border-radius: 18px; padding: 30px 32px; display: flex; flex-direction: column; gap: 10px; }
.map-label { font-size: 12px; letter-spacing: .14em; color: var(--slate); font-weight: 700; }
.map-name { font-weight: 800; font-size: 26px; }
.map-score { display: flex; align-items: center; gap: 12px; }
.map-rating { font-weight: 800; font-size: 36px; }
.map-meta { color: var(--text-soft-light); font-size: 14.5px; }
.map-tags { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--text-soft-light); }
.map-link { font-weight: 700; font-size: 14.5px; margin-top: 8px; }
.story-quote { margin-top: 36px; font-weight: 800; font-size: 22px; line-height: 1.45; max-width: 760px; border-left: 4px solid var(--lime); padding-left: 20px; }
.svc-t { font-weight: 800; font-size: 17px; margin-top: 16px; }
.svc-p { color: var(--text-soft-light); font-size: 14.5px; line-height: 1.55; margin-top: 8px; }

/* ---------- CASES: мини-отчёты, визуальный код МЕМЕКС ---------- */
.cases-head { display: flex; justify-content: space-between; align-items: baseline; }
.case-card { background: var(--graphite); border: 1px solid var(--graphite-border); border-radius: 16px; padding: 24px; display: flex; flex-direction: column; }
.case-label { font-size: 12px; letter-spacing: .14em; color: var(--slate); font-weight: 700; }
.case-rows { margin-top: 12px; }
.case-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--graphite-border); font-size: 13.5px; flex-wrap: wrap; }
.case-row:last-child { border-bottom: none; }
.case-row .ck { color: var(--text-soft-dark); }
.case-row .cv { font-weight: 800; font-size: 15.5px; color: var(--text-on-dark); white-space: nowrap; }
.case-row .cv.lime { color: var(--lime); }
.case-row.final { display: block; }
.case-row.final .ck { display: block; font-size: 12px; letter-spacing: .06em; }
.case-row.final .cv { display: block; font-size: 27px; margin-top: 4px; white-space: normal; letter-spacing: .01em; }
.case-p { color: var(--slate); font-size: 13px; line-height: 1.55; margin-top: 12px; margin-bottom: 0; }

/* ---------- STEPS ---------- */
.step-label { font-size: 13px; font-weight: 800; letter-spacing: .12em; color: var(--slate); }
.step-t { font-weight: 800; font-size: 18px; margin-top: 10px; }
.step-p { color: var(--text-soft-light); font-size: 14.5px; line-height: 1.55; margin-top: 10px; }
.mark { background: var(--lime); padding: 2px 8px; border-radius: 6px; color: var(--ink); white-space: nowrap; }
.step-final { background: var(--ink); border-radius: 16px; padding: 26px; color: var(--text-on-dark); }
.step-final .step-p { color: var(--text-soft-darker); }
.price-lime { font-weight: 800; color: var(--lime); }
.step-price { font-size: 21px; margin-top: 8px; font-weight: 800; }
.honesty { display: flex; gap: 28px; margin-top: 30px; background: #fff; border: 1px solid var(--light-border); border-radius: 14px; padding: 20px 26px; font-size: 14.5px; color: var(--text-soft-light); font-weight: 600; flex-wrap: wrap; }

/* ---------- FRANCHISE ---------- */
.fr { display: flex; gap: 64px; }
.fr-main { flex: 1; }
.fr-label { font-size: 13px; letter-spacing: .18em; font-weight: 800; color: var(--lime); }
.fr-title { font-size: 36px; margin-top: 14px; line-height: 1.2; }
.fr-p { color: var(--text-soft-darker); font-size: 17px; line-height: 1.6; margin-top: 18px; }
.fr-cards { flex: 1; display: flex; flex-direction: column; gap: 16px; }
.fr-card { background: var(--ink); border: 1px solid var(--graphite-border); border-radius: 14px; padding: 20px 24px; }
.fr-card .t { font-weight: 800; font-size: 16px; }
.fr-card .p { color: var(--slate); font-size: 14px; margin-top: 6px; }

/* ---------- WHY ---------- */
.why-card .h-num { font-weight: 800; font-size: 22px; }
/* Золото — только репутация: звёзды, рейтинги, награды, годы. Лайм — только деньги и действие. */
.stars { color: var(--gold); font-size: 16px; letter-spacing: 2px; }
.review-band { margin-top: 26px; background: var(--ink); border-radius: 16px; padding: 28px 34px; display: flex; align-items: center; gap: 26px; color: var(--text-on-dark); flex-wrap: wrap; }
.review-band .score { font-weight: 800; font-size: 26px; color: var(--gold); }
.review-band .quote { flex: 1; min-width: 280px; color: var(--text-soft-dark); font-size: 16px; line-height: 1.55; margin: 0; }

/* ---------- ABOUT ---------- */
.about-card { background: #fff; border: 1px solid var(--light-border); border-radius: 18px; padding: 32px 36px; display: flex; align-items: center; gap: 32px; }
.about-ava { width: 96px; height: 96px; border-radius: 50%; background: var(--ink); color: var(--lime); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 34px; flex-shrink: 0; overflow: hidden; }
.about-ava img { width: 100%; height: 100%; object-fit: cover; }
.about-contact { text-align: right; font-weight: 700; font-size: 15px; }
.about-contact a { display: block; margin-top: 6px; }

/* ---------- FAQ ---------- */
.faq-card { background: #fff; border: 1px solid var(--light-border); border-radius: 14px; padding: 22px 26px; }
.faq-q { font-weight: 800; font-size: 16px; }
.faq-a { color: var(--text-soft-light); font-size: 14.5px; line-height: 1.6; margin-top: 8px; }

/* ---------- CTA / FORM ---------- */
.cta-final { text-align: center; }
.cta-title { font-size: 44px; }
.cta-sub { font-size: 20px; color: var(--text-soft-dark); margin-top: 14px; }
.lead-form { display: flex; gap: 14px; justify-content: center; margin-top: 40px; flex-wrap: wrap; }
.lead-form input { background: var(--graphite); border: 1px solid var(--graphite-border); border-radius: 12px; padding: 16px 22px; color: var(--text-on-dark); font-size: 15px; font-family: inherit; outline: none; }
.lead-form input::placeholder { color: var(--slate); }
.lead-form input:focus { border-color: var(--lime); }
.lead-form .f-name { width: 220px; }
.lead-form .f-phone { width: 260px; }
.lead-form .f-niche { width: 260px; }
.form-note { color: var(--slate); font-size: 13.5px; margin-top: 18px; }
.form-msg { margin-top: 16px; font-weight: 700; }
.form-msg.ok { color: var(--good); }
.form-msg.err { color: var(--danger); }
.pd-consent { color: var(--slate); font-size: 12px; margin-top: 10px; }
.pd-consent a { color: var(--slate); text-decoration: underline; }

/* ---------- MODAL (попап заявки) ---------- */
.modal-overlay { position: fixed; inset: 0; background: rgba(11, 20, 34, .74); backdrop-filter: blur(4px); z-index: 100; display: flex; align-items: center; justify-content: center; padding: 20px; }
.modal-overlay[hidden] { display: none !important; }
.modal-card { background: var(--graphite); border: 1px solid var(--graphite-border); border-radius: 18px; padding: 34px 36px; width: 100%; max-width: 460px; position: relative; color: var(--text-on-dark); box-shadow: 0 30px 80px rgba(0, 0, 0, .5); }
.modal-close { position: absolute; top: 12px; right: 14px; background: none; border: none; color: var(--slate); font-size: 28px; cursor: pointer; line-height: 1; padding: 6px; }
.modal-close:hover { color: var(--text-on-dark); }
.modal-t { font-weight: 800; font-size: 24px; }
.modal-sub { color: var(--text-soft-dark); margin-top: 8px; font-size: 15.5px; }
.modal-form { display: flex; flex-direction: column; gap: 12px; margin-top: 22px; }
.modal-form input { background: var(--ink); border: 1px solid var(--graphite-border); border-radius: 12px; padding: 15px 18px; color: var(--text-on-dark); font-size: 15px; font-family: inherit; outline: none; width: 100%; }
.modal-form input::placeholder { color: var(--slate); }
.modal-form input:focus { border-color: var(--lime); }
.modal-form .btn { width: 100%; margin-top: 4px; }
.modal-note { margin-top: 14px; font-size: 13px; color: var(--slate); }
.modal-card .pd-consent { margin-top: 8px; }

/* ---------- COOKIE BAR ---------- */
.cookie-bar { position: fixed; left: 20px; bottom: 20px; z-index: 90; background: var(--graphite); border: 1px solid var(--graphite-border); border-radius: 14px; padding: 16px 20px; max-width: 420px; display: flex; align-items: center; gap: 16px; box-shadow: 0 16px 48px rgba(0, 0, 0, .4); }
.cookie-bar[hidden] { display: none !important; }
.cookie-text { color: var(--text-soft-dark); font-size: 13px; line-height: 1.5; }
.cookie-text a { color: var(--text-soft-dark); text-decoration: underline; }
.cookie-ok { background: var(--lime); color: var(--ink); border: none; border-radius: 10px; padding: 10px 18px; font-weight: 800; font-size: 13.5px; cursor: pointer; font-family: inherit; flex-shrink: 0; }
.cookie-ok:hover { box-shadow: 0 6px 18px rgba(182, 242, 61, .25); }

/* ---------- FOOTER ---------- */
.site-footer { background: var(--ink); border-top: 1px solid var(--graphite); padding: 28px 60px; display: flex; justify-content: space-between; align-items: center; font-size: 13.5px; color: var(--slate); flex-wrap: wrap; gap: 12px; }
.footer-brand { display: flex; align-items: baseline; gap: 12px; }
.footer-logo { font-size: 17px; color: var(--text-on-dark); }
.footer-logo span { color: var(--lime); }
.footer-links { display: flex; gap: 18px; font-weight: 700; }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1100px) {
  .wrap { padding: 0 32px; }
  .site-nav { padding: 18px 32px; }
  .nav-links { gap: 20px; }
  .nav-links .nav-item { display: none; }
  .hero { flex-direction: column; gap: 44px; padding: 56px 0 64px; }
  .hero-title { font-size: 42px; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fr { flex-direction: column; gap: 36px; }
  .story { flex-direction: column; gap: 28px; }
  .map-card { width: 100%; }
  .sys-points { grid-template-columns: 1fr; gap: 14px; }
  .site-footer { padding: 24px 32px; }
}
@media (max-width: 640px) {
  .wrap { padding: 0 20px; }
  .site-nav { padding: 14px 20px; }
  .brand-tag { display: none; }
  .sec { padding: 64px 0; }
  .sec-title { font-size: 28px; }
  .hero-title { font-size: 32px; }
  .hero-title2 { font-size: 20px; }
  .hero-p { font-size: 17px; }
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .about-card { flex-direction: column; text-align: center; }
  .about-contact { text-align: center; }
  .cta-title { font-size: 30px; }
  .lead-form { flex-direction: column; align-items: stretch; }
  .lead-form .f-name, .lead-form .f-phone, .lead-form .f-niche { width: 100%; }
  .honesty { flex-direction: column; gap: 10px; }
  .report-card { width: 100%; }
  .sys-band { padding: 26px 22px; }
  .story-quote { font-size: 18px; }
  .cookie-bar { left: 12px; right: 12px; bottom: 12px; max-width: none; flex-direction: column; align-items: stretch; gap: 10px; text-align: center; }
}
