/* logiX site shell: оформление блога в стиле основного сайта (logix-delivery.ru).
   Графитовая шапка/подвал, молочный фон страницы, оранжевый акцент, шрифт Onest,
   контейнер 1240px. Всё привязано к body.lx-shell и только перекрывает стили
   темы — разметка, рубрики, адреса и SEO статей не меняются. */

:root {
  --lx-ink: #11110f;
  --lx-milk: #f1eee7;
  --lx-paper: #fbfaf6;
  --lx-text: #191815;
  --lx-muted: #5e5952;
  --lx-orange: #e08a3e;
  --lx-orange-hover: #e59e5e;
  --lx-orange-text: #8f4a10;
  --lx-line: rgba(247, 244, 237, .16);
  --lx-line-light: rgba(25, 24, 21, .16);
  --lx-max: 1240px;
}

/* ---------- Палитра темы -> палитра сайта ---------- */
body.lx-shell {
  --wp--preset--color--base: #f1eee7;
  --wp--preset--color--base-midtone: #fbfaf6;
  --wp--preset--color--contrast: #191815;
  --wp--preset--color--contrast-midtone: #5e5952;
  --wp--preset--color--accent-1: #191815;
  --wp--preset--color--accent-2: #8f4a10;
  --wp--preset--color--accent-3: #191815;
  --wp--preset--color--accent-4: #5e5952;
  --wp--preset--color--accent-5: #e08a3e;
  --wp--preset--color--accent-6: #f1eee7;
  --wp--style--global--content-size: 1240px;
  --wp--style--global--wide-size: 1240px;
  font-family: Onest, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif !important;
  background-color: var(--lx-milk) !important;
  background-image: none !important;
  color: var(--lx-text);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
body.lx-shell.single, body.lx-shell.page { --wp--style--global--content-size: 780px; }

body.lx-shell :is(h1, h2, h3, h4, h5, h6, .wp-block-heading, .wp-block-post-title, .wp-block-site-title, .wp-block-button__link) {
  font-family: Onest, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif !important;
}
body.lx-shell :is(h1, h2, h3, h4) { letter-spacing: -.035em; line-height: 1.05; text-wrap: balance; }
body.lx-shell p { text-wrap: pretty; }
/* заголовки в тёмных блоках (hero, подвал) остаются светлыми */
body.lx-shell .has-background.has-text-color :is(h1, h2, h3, h4, h5, h6) { color: inherit; }
body.lx-shell a { text-underline-offset: 3px; }
body.lx-shell .wp-site-blocks a:focus-visible { outline: 2px solid var(--lx-orange); outline-offset: 3px; border-radius: 4px; }

/* ---------- Шапка темы скрыта: вместо неё шапка основного сайта ---------- */
body.lx-shell .wp-site-blocks > header.wp-block-template-part { display: none !important; }

.lx-header {
  position: sticky; top: 0; z-index: 100; border-bottom: 1px solid var(--lx-line);
  background: rgba(17, 17, 15, .94); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px);
  color: #f7f4ed; font-family: Onest, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 16px; line-height: 1.4;
}
.admin-bar .lx-header { top: 32px; }
.lx-header, .lx-header * { box-sizing: border-box; }
.lx-wrap { width: min(var(--lx-max), calc(100% - 48px)); margin: 0 auto; }
.lx-header-inner { min-height: 76px; display: flex; align-items: center; gap: 28px; }
.lx-brand { flex-shrink: 0; width: 122px; height: 64px; display: flex; align-items: center; }
.lx-brand img { display: block; width: 100%; height: 100%; object-fit: contain; }
.lx-nav { display: flex; gap: 28px; margin-left: auto; }
.lx-header a { text-decoration: none; }
.lx-nav a, .lx-login { color: #d2cec6; font-size: 14px; font-weight: 650; transition: color .2s; }
.lx-nav a:hover, .lx-login:hover, .lx-nav a[aria-current="page"] { color: var(--lx-orange); }
.lx-actions { display: flex; align-items: center; gap: 14px; }
.lx-btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 17px;
  border: 1px solid var(--lx-orange); border-radius: 8px; background: var(--lx-orange); color: #1a110c;
  font-size: 14px; font-weight: 800; transition: background .2s, transform .2s;
}
.lx-btn:hover { background: var(--lx-orange-hover); transform: translateY(-2px); }
.lx-header a:focus-visible, .lx-menu-btn:focus-visible { outline: 2px solid var(--lx-orange); outline-offset: 3px; border-radius: 6px; }
.lx-menu-btn {
  display: none; width: 44px; height: 44px; padding: 0; border: 1px solid var(--lx-line); border-radius: 7px;
  background: transparent; color: inherit; font: inherit; font-size: 18px; cursor: pointer; place-items: center;
}
.lx-menu-btn::before { content: "\2630"; }
.lx-menu-btn[aria-expanded="true"]::before { content: "\2715"; }
.lx-mobile { display: none; }

/* ---------- Первый блок страницы: ниже и компактнее ---------- */
body.lx-shell .wp-site-blocks > section.wp-block-group.alignfull:first-of-type {
  padding-top: 44px !important; padding-bottom: 44px !important;
  background-color: var(--lx-ink) !important;
}
body.lx-shell .wp-site-blocks > section.wp-block-group.alignfull:first-of-type h1 {
  max-width: 900px; font-size: clamp(34px, 4.6vw, 60px) !important; line-height: 1 !important; letter-spacing: -.04em;
}
body.lx-shell .wp-site-blocks > section.wp-block-group.alignfull:first-of-type p.has-large-font-size {
  max-width: 720px; font-size: clamp(17px, 1.6vw, 20px) !important; line-height: 1.55; color: #c9c5bd;
}
body.lx-shell p[style*="ff7a00"] {
  color: var(--lx-orange) !important; font-size: 13px; letter-spacing: .12em; text-transform: uppercase;
}

/* ---------- Кнопки и их состояния ---------- */
body.lx-shell .wp-block-button .wp-block-button__link {
  display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px;
  border-radius: 8px !important; font-size: 15px; font-weight: 800; text-decoration: none;
  transition: background .2s, border-color .2s, color .2s, transform .2s;
}
body.lx-shell .wp-block-button:not(.is-style-outline) .wp-block-button__link {
  background-color: var(--lx-orange) !important; border: 1px solid var(--lx-orange); color: #1a110c !important;
}
body.lx-shell .wp-block-button:not(.is-style-outline) .wp-block-button__link:hover {
  background-color: var(--lx-orange-hover) !important; transform: translateY(-2px);
}
body.lx-shell .wp-block-button.is-style-outline .wp-block-button__link {
  background: transparent !important; border: 1px solid rgba(25, 24, 21, .28); color: var(--lx-text) !important;
}
body.lx-shell .wp-block-button.is-style-outline .wp-block-button__link:hover {
  border-color: var(--lx-orange); background: rgba(224, 138, 62, .1) !important; color: var(--lx-text) !important;
}
body.lx-shell .wp-block-button__link:focus-visible { outline: 3px solid rgba(224, 138, 62, .6); outline-offset: 2px; }

/* ---------- Карточки статей ---------- */
body.lx-shell .wp-block-post > article {
  border: 1px solid var(--lx-line-light) !important; border-radius: 20px !important; background: var(--lx-paper);
  transition: border-color .25s, transform .25s, box-shadow .25s;
}
body.lx-shell .wp-block-post > article:hover {
  border-color: rgba(224, 138, 62, .8) !important; transform: translateY(-3px); box-shadow: 0 14px 34px rgba(25, 24, 21, .08);
}
body.lx-shell .wp-block-post-featured-image img { border-radius: 14px !important; }
body.lx-shell .wp-block-post-title { font-size: clamp(22px, 2vw, 28px); line-height: 1.12; }
body.lx-shell .wp-block-post-title a { color: var(--lx-text); text-decoration: none; }
body.lx-shell .wp-block-post-title a:hover { color: var(--lx-orange-text); }
body.lx-shell.single .wp-block-post-title { font-size: clamp(32px, 4.2vw, 54px); line-height: 1.02; }
body.lx-shell .taxonomy-category a, body.lx-shell .wp-block-post-terms a { color: var(--lx-orange-text) !important; text-decoration: none; }
body.lx-shell .wp-block-post-date, body.lx-shell .wp-block-post-date time { color: #6b665e !important; }

/* ---------- Текст статьи ---------- */
body.lx-shell .wp-block-post-content a { color: var(--lx-orange-text); text-decoration-color: rgba(224, 138, 62, .6); }
body.lx-shell .wp-block-post-content a:hover { color: var(--lx-orange); }
body.lx-shell .wp-block-post-content :is(h2, h3) { margin-top: 1.6em; }
body.lx-shell .wp-block-post-content img { border-radius: 14px; height: auto; max-width: 100%; }

/* ---------- Хлебные крошки и услуги по теме (статья) ---------- */
.lx-crumbs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; color: #6b665e; font-size: 13px; line-height: 1.4; }
body.lx-shell .lx-crumbs a { color: var(--lx-muted); text-decoration: none; }
body.lx-shell .lx-crumbs a:hover { color: var(--lx-orange-text); }
.lx-services {
  margin: 2.4em 0 0; padding: 22px 24px; border: 1px solid var(--lx-line-light); border-radius: 16px;
  background: var(--lx-paper);
}
.lx-services-title { margin: 0 0 10px; color: var(--lx-text); font-size: 13px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.lx-services ul { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
body.lx-shell .lx-services a { color: var(--lx-text); font-weight: 700; text-decoration: none; }
body.lx-shell .lx-services a::after { content: " \2192"; color: var(--lx-orange); }
body.lx-shell .lx-services a:hover { color: var(--lx-orange-text); }

/* ---------- Подвал ---------- */
body.lx-shell .wp-site-blocks > footer.wp-block-template-part > footer { background-color: var(--lx-ink) !important; }
body.lx-shell .wp-site-blocks > footer a { color: #d2cec6; text-decoration: none; }
body.lx-shell .wp-site-blocks > footer a:hover { color: var(--lx-orange); }
.lx-site-logo { margin: 0 0 16px; }
.lx-site-logo .lx-logo-link { display: inline-flex; width: 122px; height: 64px; }
.lx-site-logo img { width: 100%; height: 100%; object-fit: contain; display: block; }

/* ---------- Адаптив ---------- */
@media (max-width: 1000px) {
  .lx-nav, .lx-login { display: none; }
  .lx-actions { margin-left: auto; }
  .lx-menu-btn { display: grid; }
  .lx-mobile:not([hidden]) {
    position: fixed; top: 77px; left: 0; right: 0; z-index: 99; display: flex; flex-direction: column;
    max-height: calc(100vh - 77px); overflow-y: auto; padding: 20px 24px 28px;
    background: #11110f; border-bottom: 1px solid var(--lx-line);
  }
  .lx-mobile a {
    padding: 14px 0; border-bottom: 1px solid var(--lx-line); color: #f7f4ed; font-size: 17px; font-weight: 650;
  }
  .admin-bar .lx-mobile:not([hidden]) { top: 123px; }
}
@media (max-width: 782px) { .admin-bar .lx-header { top: 46px; } }
@media (max-width: 680px) {
  .lx-wrap { width: calc(100% - 28px); }
  .lx-header-inner { min-height: 70px; }
  .lx-brand { width: 96px; height: 50px; }
  .lx-btn { display: none; }
  .lx-mobile:not([hidden]) { top: 71px; max-height: calc(100vh - 71px); }
  body.lx-shell { font-size: 16px; }
  body.lx-shell .wp-site-blocks > section.wp-block-group.alignfull:first-of-type { padding-top: 34px !important; padding-bottom: 34px !important; }
  body.lx-shell .wp-block-button .wp-block-button__link { min-height: 46px; }
}
@media (prefers-reduced-motion: reduce) {
  body.lx-shell *, .lx-header * { transition: none !important; }
}
