/* ===== Кнопка бота в шапке (contact-widget.php) ===== */
.fx-botbtn {
  order: 1; flex: none; align-self: center; display: inline-flex; align-items: center; gap: 8px; margin-left: 14px;
  height: 40px; padding: 0 14px 0 10px; border-radius: 40px; text-decoration: none !important;
  background: color-mix(in srgb, var(--blue, #2f8cff) 14%, transparent); border: 1px solid color-mix(in srgb, var(--blue, #2f8cff) 45%, transparent);
  color: var(--text, #e9edf3) !important; transition: background .2s, border-color .2s, transform .2s;
}
.fx-botbtn:hover { background: color-mix(in srgb, var(--blue, #2f8cff) 26%, transparent); border-color: var(--blue, #2f8cff); transform: translateY(-1px); }
.fx-botbtn__ico { position: relative; width: 22px; height: 22px; color: #29a9eb; flex: none; }
.fx-botbtn__ico svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.fx-botbtn__txt { font-family: "Courier New", ui-monospace, monospace; font-weight: 800; font-size: 14px; letter-spacing: 2px; }
/* превращение: значок Telegram ⇄ пиксельный бот (цикл 6 с) */
.fx-botbtn:not(.is-plain) .fx-botbtn__tg  { animation: fx-bot-a 6s ease-in-out infinite; }
.fx-botbtn:not(.is-plain) .fx-botbtn__bot { animation: fx-bot-b 6s ease-in-out infinite; color: var(--blue, #2f8cff); --fx-bot-eye: var(--surface, #1b2230); }
@keyframes fx-bot-a {
  0%, 38%  { opacity: 1; transform: none; filter: none; }
  46%      { opacity: 0; transform: scale(.4) rotate(-90deg); filter: blur(2px); }
  50%, 88% { opacity: 0; transform: scale(.4) rotate(-90deg); }
  96%,100% { opacity: 1; transform: none; filter: none; }
}
@keyframes fx-bot-b {
  0%, 38%  { opacity: 0; transform: scale(.3) translateY(4px); }
  48%      { opacity: 1; transform: scale(1.12); }
  52%, 86% { opacity: 1; transform: none; }
  60%      { transform: translateY(-1px); } 66% { transform: none; }   /* лёгкий «кивок» */
  94%,100% { opacity: 0; transform: scale(.3) translateY(4px); }
}
@media (prefers-reduced-motion: reduce) { .fx-botbtn__tg, .fx-botbtn__bot { animation: none !important; } .fx-botbtn__bot { opacity: 0; } }
@media (max-width: 1249px) {
  .fx-botbtn { height: 36px; padding: 0 10px 0 8px; margin-left: 10px; }
  .fx-botbtn__ico { width: 20px; height: 20px; }
  .fx-botbtn__txt { font-size: 12px; }
}

/* ===== Облачко связи справа внизу ===== */
.fx-chat { position: fixed; right: 22px; bottom: 22px; z-index: 9990; display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
.fx-chat__btn {
  position: relative; width: 60px; height: 60px; border: 0; padding: 0; cursor: pointer; color: #fff;
  border-radius: 50% 50% 50% 12%; /* облачко с «хвостиком» снизу слева */
  background: linear-gradient(135deg, var(--blue, #2f8cff), var(--blue-2, #1a5cd8)); box-shadow: 0 10px 28px -6px var(--blue, #2f8cff), 0 2px 8px rgba(0,0,0,.35);
  transition: transform .2s, border-radius .25s;
}
body.mode-games .fx-chat__btn { color: var(--on-accent, #071018); }
.fx-chat__btn:hover { transform: translateY(-2px) scale(1.04); }
.fx-chat__btn::after { content: ""; position: absolute; inset: -6px; border-radius: inherit; border: 2px solid var(--blue, #2f8cff); opacity: 0; animation: fx-chat-ping 3.2s ease-out infinite; }
@keyframes fx-chat-ping { 0% { opacity: .55; transform: scale(.9); } 70%, 100% { opacity: 0; transform: scale(1.25); } }
.fx-chat__btn svg { position: absolute; left: 50%; top: 50%; width: 28px; height: 28px; margin: -14px 0 0 -14px; transition: opacity .2s, transform .25s; }
.fx-chat__ic-close { opacity: 0; transform: rotate(-90deg); }
.fx-chat.is-open .fx-chat__btn { border-radius: 50%; }
.fx-chat.is-open .fx-chat__btn::after { animation: none; }
.fx-chat.is-open .fx-chat__ic-open { opacity: 0; transform: rotate(90deg); }
.fx-chat.is-open .fx-chat__ic-close { opacity: 1; transform: none; }

.fx-chat__menu {
  width: 270px; padding: 10px; border-radius: 18px; background: var(--surface, #1b2230); border: 1px solid var(--border, #2f3b57);
  box-shadow: 0 18px 50px -10px rgba(0,0,0,.55); transform-origin: bottom right;
  opacity: 0; transform: translateY(8px) scale(.96); transition: opacity .18s, transform .18s;
}
.fx-chat.is-open .fx-chat__menu { opacity: 1; transform: none; }
.fx-chat__head { padding: 6px 8px 10px; font-weight: 800; font-size: 15px; color: var(--text, #e9edf3); }
.fx-chat__head span { display: block; font-weight: 400; font-size: 12px; color: var(--dim, #8a93a3); margin-top: 2px; }
.fx-chat__item { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 12px; font-size: 14px; font-weight: 600; color: var(--text, #e9edf3) !important; text-decoration: none !important; transition: background .15s; }
.fx-chat__item:hover { background: color-mix(in srgb, var(--text, #fff) 7%, transparent); }
.fx-chat__item i { flex: none; width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; font-style: normal; color: #fff; background: #3a4458; }
.fx-chat__item i svg { width: 18px; height: 18px; }
.fx-chat__item.is-telegram i { background: #29a9eb; } .fx-chat__item.is-whatsapp i { background: #25d366; } .fx-chat__item.is-vk i { background: #0077ff; }
.fx-chat__item.is-mail i { background: #7a8496; }
.fx-chat__item.is-idea i { background: #f5b301; } .fx-chat__item.is-all i { background: #4b5568; }
.fx-chat__sep { height: 1px; margin: 6px 4px; background: var(--border, #2f3b57); }

@media (max-width: 1249px) { .fx-chat { bottom: 88px; right: 14px; } .fx-chat__btn { width: 54px; height: 54px; } }   /* над нижней панелью телефона */
body.fx-pay .fx-chat { bottom: 22px; }   /* на страницах оплаты нижней панели нет */
/* 2026-10-19: кнопка бота без рамки и фона — просто значок + BOT; компактнее, чтобы шапка GAMES (с корзиной) помещалась */
.fx-botbtn, .fx-botbtn:hover { background: none !important; border: 0 !important; box-shadow: none !important; }
.fx-botbtn { height: 36px; padding: 0 4px; margin-left: 8px; gap: 6px; }
.fx-botbtn:hover { transform: none; opacity: .85; }
.fx-botbtn__txt { font-size: 13px; letter-spacing: 1.5px; }
@media (max-width: 1249px) { .fx-botbtn { margin-left: 6px; padding: 0 2px; } }
/* шапка GAMES (5 разделов + корзина) с кнопкой бота не помещалась — корзина уезжала за край: меню чуть плотнее */
@media (min-width: 1250px) {
  html body.mode-games .main-navigation ul.menu { gap: 6px !important; }
  html body.mode-games .main-navigation ul.menu > li > a { font-size: 14px !important; letter-spacing: .1px; }
  html body.mode-games .fantom-header-actions { gap: 4px !important; }
  html body.mode-games .fx-botbtn { margin-left: 4px; }
}
/* 2026-10-20: разделы меню равномерно заполняют место между кнопкой BOT и переключателем GSM|GAMES (обе стороны, широкий экран) */
@media (min-width: 1250px) {
  html body .site-header .main-navigation { flex: 1 1 auto !important; min-width: 0; margin-right: 24px !important; width: auto !important; }
  html body .site-header .main-navigation > .primary-navigation, html body .site-header .main-navigation ul.menu { width: 100% !important; max-width: none !important; }
  html body .site-header .main-navigation ul.menu { display: flex !important; justify-content: space-evenly; flex-wrap: nowrap; }
  html body .site-header .fantom-header-actions { margin-left: 0 !important; }
}

/* 2026-10-20: выпадающие списки (сортировка и др.) в тёмных темах — тёмные, иначе белый фон и светлые буквы сливаются */
html.fantom-games-dark body.mode-games select, body.mode-gsm select, body.fx-pay select, body.fx-home select { color-scheme: dark; }
html.fantom-games-dark body.mode-games select option, body.mode-gsm select option, body.fx-pay select option, body.fx-home select option { background: var(--surface, #1b2230); color: var(--text, #e9edf3); }
html:not(.fantom-games-dark) body.mode-games select option { background: #fff; color: #151a21; }

/* 2026-10-20 (3): шапка ниже на обеих сторонах (была 72px) */
@media (min-width: 1250px) {
  html body .site-header { padding-top: 3px !important; padding-bottom: 3px !important; }
}
/* GAMES: подпись BOT — светлая тема: шапка тёмно-серая, тёмные буквы терялись → как у меню; тёмная тема — светлая */
html:not(.fantom-games-dark) body.mode-games .fx-botbtn, html:not(.fantom-games-dark) body.mode-games .fx-botbtn__txt { color: #fafafa !important; }
html.fantom-games-dark body.mode-games .fx-botbtn, html.fantom-games-dark body.mode-games .fx-botbtn__txt { color: #e6eaef !important; }
/* меньше пустоты между последним блоком страницы («О сервисе …») и подвалом */
html body .site-main > article.page:last-child, html body .site-main > article.page:last-child .entry-content > :last-child { margin-bottom: 0 !important; }
html body .content-area, html body .site-main { margin-bottom: 18px !important; }
@media (min-width: 1250px) { html body .site-header .site-branding { display: flex; align-items: center; } html body .site-header .custom-logo-link { line-height: 0; } }

/* 2026-10-20: веер вариантов связи вокруг облачка при наведении (ПК) */
.fx-chat__fan { position: absolute; right: 0; bottom: 0; width: 240px; height: 240px; pointer-events: none; border-top-left-radius: 100%; }
.fx-chat.is-fan .fx-chat__fan { pointer-events: auto; }   /* невидимая зона: курсор между значками не закрывает веер */
.fx-chat__fi {
  --r: 150px; position: absolute; right: 8px; bottom: 8px; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  color: #fff !important; text-decoration: none !important; box-shadow: 0 6px 18px -4px rgba(0,0,0,.55); background: #4b5568;
  opacity: 0; transform: scale(.3); translate: 0 0; pointer-events: none;
  transition: translate .38s cubic-bezier(.3,1.4,.5,1) var(--d), transform .3s ease var(--d), opacity .2s ease var(--d);
}
.fx-chat.is-fan .fx-chat__fi { opacity: 1; transform: none; pointer-events: auto; translate: calc(cos(var(--a)) * var(--r) * -1) calc(sin(var(--a)) * var(--r) * -1); }
.fx-chat__fi:hover { transform: scale(1.12) !important; }
.fx-chat__fi i { font-style: normal; font-size: 18px; line-height: 1; display: grid; place-items: center; }
.fx-chat__fi i svg { width: 20px; height: 20px; }
.fx-chat__fi.is-telegram { background: #29a9eb; } .fx-chat__fi.is-whatsapp { background: #25d366; } .fx-chat__fi.is-vk { background: #0077ff; }
.fx-chat__fi.is-mail { background: #7a8496; } .fx-chat__fi.is-idea { background: #f5b301; } .fx-chat__fi.is-all { background: #4b5568; }
/* Лампочка «Пожелания» — горит: яркий жёлтый круг со свечением и мягкой пульсацией (2026-10-23) */
html body .fx-chat__fi.is-idea,
html body .fx-chat__item.is-idea i {
  background: radial-gradient(circle at 50% 40%, #ffe58a 0%, #f5b301 70%, #e0a000 100%) !important;
  box-shadow: 0 0 8px 1px rgba(255,200,40,.45) !important;
  animation: fx-lamp 3s ease-in-out infinite;
}
html body .fx-chat__fi.is-idea i, html body .fx-chat__item.is-idea i { filter: none; font-size: 0 !important; color: #5a3a00; }
/* чёткий тёмный контур лампочки (SVG) вместо бледного эмодзи */
html body .fx-chat__fi.is-idea i::before, html body .fx-chat__item.is-idea i::before {
  content: ""; display: block; width: 22px; height: 22px; background: #a9741a;
  -webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M9 18h6M10 21h4M12 3a6 6 0 0 0-3.6 10.8c.7.6 1.1 1.4 1.1 2.2h5c0-.8.4-1.6 1.1-2.2A6 6 0 0 0 12 3z'/></svg>") center/contain no-repeat;
          mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M9 18h6M10 21h4M12 3a6 6 0 0 0-3.6 10.8c.7.6 1.1 1.4 1.1 2.2h5c0-.8.4-1.6 1.1-2.2A6 6 0 0 0 12 3z'/></svg>") center/contain no-repeat;
}
html body .fx-chat__item.is-idea i::before { width: 20px; height: 20px; }
@keyframes fx-lamp {
  0%,100% { box-shadow: 0 0 6px 1px rgba(255,200,40,.3); }
  50%     { box-shadow: 0 0 11px 2px rgba(255,205,50,.55); }
}
@media (prefers-reduced-motion: reduce) { html body .fx-chat__fi.is-idea, html body .fx-chat__item.is-idea i { animation: none; } }
.fx-chat__tip {
  position: absolute; right: calc(100% + 10px); top: 50%; transform: translateY(-50%); white-space: nowrap; pointer-events: none;
  padding: 6px 10px; border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--text, #e9edf3); background: var(--surface, #1b2230);
  border: 1px solid var(--border, #2f3b57); box-shadow: 0 8px 20px -8px rgba(0,0,0,.6); opacity: 0; transition: opacity .15s;
}
.fx-chat__fi:hover .fx-chat__tip { opacity: 1; }
.fx-chat.is-fan .fx-chat__btn::after { animation: none; }
@media (hover: none), (pointer: coarse) { .fx-chat__fan { display: none; } }

/* ===== 2026-10-20: МОБИЛЬНАЯ ВЕРСИЯ (≤767px) — порядок в шапке и нижней панели ===== */
@media (max-width: 767px) {
  /* шапка в 2 ряда: 1) логотип слева, BOT справа; 2) GSM|GAMES, поиск, язык, тема, меню. «Мой аккаунт» — в нижней панели */
  html body:not(.fx-pay) .site-header .fantom-header-actions .fantom-login { display: none !important; }
  html body .site-header .site-branding { margin-right: auto !important; margin-left: 0 !important; }
  html body .site-header .custom-logo-link { justify-content: flex-start; }
  html body .site-header .fx-botbtn { margin-left: 8px !important; order: 1 !important; }
  html body .site-header > .col-full { row-gap: 8px; padding-top: 6px; padding-bottom: 8px; }
  /* нижняя панель на тёмных страницах — тёмная, а не белая */
  html body.mode-gsm .storefront-handheld-footer-bar, html body.fx-home .storefront-handheld-footer-bar {
    background: color-mix(in srgb, var(--surface, #1f2940) 92%, transparent) !important; border-top: 1px solid var(--border, #2f3b57);
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); box-shadow: 0 -8px 24px -12px rgba(0,0,0,.6);
  }
  html body.mode-gsm .storefront-handheld-footer-bar ul li > a, html body.fx-home .storefront-handheld-footer-bar ul li > a { background: transparent !important; color: var(--text, #e9edf3) !important; border: 0 !important; }
  html body.mode-gsm .storefront-handheld-footer-bar ul li > a::before, html body.fx-home .storefront-handheld-footer-bar ul li > a::before { color: var(--text, #e9edf3) !important; }
  html body.mode-gsm .storefront-handheld-footer-bar ul li, html body.fx-home .storefront-handheld-footer-bar ul li { border: 0 !important; }
  /* облачко связи поменьше, чтобы меньше закрывало карточки */
  .fx-chat { right: 12px; } .fx-chat__btn { width: 50px !important; height: 50px !important; } .fx-chat__btn svg { width: 24px; height: 24px; margin: -12px 0 0 -12px; }
}
@media (max-width: 767px) {   /* фон панели — сплошной: под ней прячется поле поиска Storefront, сквозь полупрозрачный фон оно просвечивало */
  html body.mode-gsm .storefront-handheld-footer-bar, html body.fx-home .storefront-handheld-footer-bar { background: var(--surface, #1f2940) !important; -webkit-backdrop-filter: none; backdrop-filter: none; }
  html body.fx-home .storefront-handheld-footer-bar { background: #1b2030 !important; }
  html body.mode-gsm .storefront-handheld-footer-bar > ul, html body.fx-home .storefront-handheld-footer-bar > ul { position: relative; z-index: 2; background: inherit; }
}
@media (max-width: 767px) {
  html body.mode-gsm .storefront-handheld-footer-bar ul li > a { background: var(--surface, #1f2940) !important; position: relative; z-index: 2; }
  html body.fx-home .storefront-handheld-footer-bar ul li > a { background: #1b2030 !important; position: relative; z-index: 2; }
  html body.mode-gsm .storefront-handheld-footer-bar.active .site-search, html body.fx-home .storefront-handheld-footer-bar.active .site-search { z-index: 3; }
}
@media (max-width: 767px) {   /* поле поиска нижней панели — только когда нажали «Поиск» */
  html body .storefront-handheld-footer-bar li.search:not(.active) .site-search { visibility: hidden !important; opacity: 0; pointer-events: none; }
  html body .storefront-handheld-footer-bar li.search.active .site-search { visibility: visible !important; opacity: 1; z-index: 3; }
  html body.mode-gsm .storefront-handheld-footer-bar li.search.active .site-search, html body.fx-home .storefront-handheld-footer-bar li.search.active .site-search { background: var(--surface, #1f2940) !important; }
}
@media (max-width: 767px) {
  /* подвал: строка продавца — реквизиты и ссылки отдельными строками; запас снизу под облачко связи и нижнюю панель */
  .fantom-footer__seller > span { display: block; } .fantom-footer__sep { display: none !important; }
  .fantom-footer__seller { line-height: 1.7; }
  html body .fantom-footer.fx-foot2 { padding-bottom: calc(69px + 70px + env(safe-area-inset-bottom, 0px)) !important; }
  /* «Мы на связи»: три кнопки в один ряд */
  html body .fantom-footer.fx-foot2 .fx-foot2__blk:first-child .fantom-footer__social { display: grid !important; grid-template-columns: repeat(3, 1fr); gap: 6px; }
  html body .fantom-footer.fx-foot2 .fx-foot2__blk:first-child .fantom-footer__social a.button { padding: 0 6px !important; font-size: 12px !important; justify-content: center; gap: 5px !important; }
  /* страница товара: кнопка «Оформить / В корзину» на всю ширину */
  html body.single-product .summary .single_add_to_cart_button { width: 100% !important; float: none !important; margin-left: 0 !important; }
}
/* 2026-10-20 (2): нижняя панель телефона — отдельные кнопки поменьше и с отступами от краёв (боковые обрезались);
   цвет — по стороне: GAMES зелёный (как было), GSM синий, главная фиолетовый */
@media (max-width: 767px) {
  html body .storefront-handheld-footer-bar { box-sizing: border-box !important; left: 0 !important; right: 0 !important; width: 100% !important; }
  html body.mode-games .storefront-handheld-footer-bar, html body.mode-gsm .storefront-handheld-footer-bar, html body.fx-home .storefront-handheld-footer-bar {
    background: transparent !important; border: 0 !important; box-shadow: none !important;
    padding: 6px 16px calc(8px + env(safe-area-inset-bottom, 0px)) !important; pointer-events: none;
  }
  html body.mode-games .storefront-handheld-footer-bar ul, html body.mode-gsm .storefront-handheld-footer-bar ul, html body.fx-home .storefront-handheld-footer-bar ul {
    display: flex !important; justify-content: center; gap: 10px; background: transparent !important; margin: 0 !important; padding: 0 !important; pointer-events: none;
  }
  html body.mode-games .storefront-handheld-footer-bar ul li, html body.mode-gsm .storefront-handheld-footer-bar ul li, html body.fx-home .storefront-handheld-footer-bar ul li {
    flex: 0 1 96px !important; width: auto !important; min-width: 0; border: 0 !important; background: transparent !important; pointer-events: auto;
  }
  html body.mode-games .storefront-handheld-footer-bar ul li > a, html body.mode-gsm .storefront-handheld-footer-bar ul li > a, html body.fx-home .storefront-handheld-footer-bar ul li > a {
    height: 46px !important; border-radius: 14px !important; border: 0 !important;
  }
  html body.mode-games .storefront-handheld-footer-bar ul li > a::before, html body.mode-gsm .storefront-handheld-footer-bar ul li > a::before, html body.fx-home .storefront-handheld-footer-bar ul li > a::before {
    line-height: 46px !important; font-size: 19px !important;
  }
  html body.mode-gsm .storefront-handheld-footer-bar ul li > a { background: linear-gradient(135deg, #2f8cff 0%, #216be9 100%) !important; color: #fff !important; box-shadow: 0 6px 16px -4px rgba(33,107,233,.6) !important; }
  html body.fx-home .storefront-handheld-footer-bar ul li > a { background: linear-gradient(135deg, #b56cff 0%, #7c3aed 100%) !important; color: #fff !important; box-shadow: 0 6px 16px -4px rgba(168,85,247,.6) !important; }
  html body.mode-gsm .storefront-handheld-footer-bar ul li > a::before, html body.fx-home .storefront-handheld-footer-bar ul li > a::before { color: #fff !important; }
  html body .storefront-handheld-footer-bar ul li.cart .count { top: 4px !important; }
  html body .storefront-handheld-footer-bar li.search.active .site-search { pointer-events: auto; }
  .fx-chat { bottom: 74px !important; }   /* облачко — сразу над кнопками */
}
/* 2026-10-20 (3): на главной нижней панели нет; на GSM две кнопки той же общей ширины, что три кнопки GAMES */
@media (max-width: 767px) {
  html body.fx-home .storefront-handheld-footer-bar { display: none !important; }
  html body.fx-home .fx-chat { bottom: 18px !important; }
  html body.fx-home .fantom-footer.fx-foot2 { padding-bottom: calc(80px + env(safe-area-inset-bottom, 0px)) !important; }
  html body.mode-gsm:not(.fx-home) .storefront-handheld-footer-bar ul li { flex: 0 1 149px !important; }
}
@media (max-width: 767px) {   /* на главной нижней панели нет — «Мой аккаунт» возвращается в шапку, во второй ряд к поиску/языку/теме */
  html body.fx-home .site-header .fantom-header-actions .fantom-login { display: inline-flex !important; align-items: center; order: 6 !important; height: 38px !important; padding: 0 16px !important; font-size: 14px !important; margin: 0 0 0 4px !important; }
}
/* 2026-10-20 (4): телефон — «Написать нам» кнопкой в шапке между логотипом и BOT, облачко внизу скрыто (список открывается под шапкой);
   подвал без лишнего отступа внизу; кнопки GSM на подложке как у GAMES */
.fx-msgbtn { display: none; }
@media (max-width: 767px) {
  .fx-msgbtn { display: inline-grid; place-items: center; order: 1; flex: none; width: 36px; height: 36px; margin-left: 6px; padding: 0; border: 0; border-radius: 50%;
    background: var(--blue, #216be9); color: var(--on-accent, #fff); box-shadow: 0 4px 12px -4px var(--blue, #216be9); cursor: pointer; }
  body.mode-gsm .fx-msgbtn { color: #fff; }
  body.fx-home .fx-msgbtn { background: linear-gradient(135deg, #b56cff, #7c3aed); color: #fff; box-shadow: 0 4px 12px -4px #a855f7; }
  .fx-msgbtn svg { width: 20px; height: 20px; }
  html body .site-header .site-branding { margin-right: auto !important; }
  html body .site-header .fx-botbtn { margin-left: 4px !important; }
  .fx-chat { top: 60px !important; bottom: auto !important; right: 12px !important; flex-direction: column-reverse; }
  .fx-chat .fx-chat__btn { display: none !important; }
  .fx-chat__menu { transform-origin: top right; }
  /* подвал: внизу только место под кнопки панели */
  html body .fantom-footer.fx-foot2 { padding-bottom: calc(66px + env(safe-area-inset-bottom, 0px)) !important; }
  html body.fx-home .fantom-footer.fx-foot2 { padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px)) !important; }
  html body .site-footer { padding-bottom: 0 !important; margin-bottom: 0 !important; }
}
@media (max-width: 767px) {   /* GSM: кнопки на подложке — полоса в цвет шапки под кнопками */
  html body.mode-gsm:not(.fx-home) .storefront-handheld-footer-bar {
    background: color-mix(in srgb, var(--surface, #1f2940) 94%, transparent) !important; border-top: 1px solid var(--border, #2f3b57) !important;
    box-shadow: 0 -10px 26px -14px rgba(0,0,0,.8) !important; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); pointer-events: auto;
  }
}
@media (max-width: 767px) {   /* «Написать нам» и BOT — сразу за логотипом, а не у правого края */
  html body .site-header .site-branding { margin-right: 0 !important; }
  html body .site-header .fx-msgbtn { margin-left: 10px !important; }
  html body .site-header .fx-botbtn { margin-left: 2px !important; margin-right: auto !important; }
}
@media (max-width: 767px) { html body .site-header .fx-msgbtn { margin-left: 2px !important; } html body .site-header .fx-botbtn { margin-left: 0 !important; } }
@media (max-width: 767px) {   /* первый ряд (логотип + «Написать нам» + BOT) — по центру, как кнопки второго ряда */
  html body .site-header > .col-full { justify-content: center !important; }
  html body .site-header .site-branding { margin-left: 0 !important; margin-right: 0 !important; }
  html body .site-header .fx-botbtn { margin-right: 0 !important; }
}
@media (max-width: 767px) { html body.mode-gsm .fx-quick { justify-content: center; justify-content: safe center; } }   /* GSM: «Аренда / Лицензии / Авторки» по центру */
/* 2026-10-20: заголовок «О сервисе …» на /gsm и /games — по центру (ПК и телефон) */
html body .fx-about__label { display: table !important; width: auto; margin-left: auto !important; margin-right: auto !important; text-align: center; }   /* плашка по ширине текста, по центру */
/* 2026-10-20 (5): телефон — шапка ниже на всех страницах (было ~130px): меньше отступы и кнопки */
@media (max-width: 767px) {
  html body .site-header > .col-full { row-gap: 4px !important; padding-top: 4px !important; padding-bottom: 6px !important; }
  html body .site-header { padding-top: 0 !important; padding-bottom: 0 !important; }
  html body .site-header .site-branding { margin-top: 0 !important; margin-bottom: 0 !important; }
  html body .site-header .custom-logo { max-height: 30px !important; width: auto !important; }
  html body .site-header .fx-botbtn { height: 32px !important; }
  html body .site-header .fx-msgbtn { width: 32px; height: 32px; } html body .site-header .fx-msgbtn svg { width: 18px; height: 18px; }
  html body .site-header .fantom-header-actions .fantom-icon, html body .site-header .menu-toggle { width: 34px !important; height: 34px !important; min-height: 34px !important; }
  html body .site-header .fx-side-tabs { height: 34px !important; } html body .site-header .fx-side-tabs a { padding-top: 3px !important; padding-bottom: 3px !important; }
  html body.fx-home .site-header .fantom-header-actions .fantom-login { height: 34px !important; }
}
/* 2026-10-20 (6): ГЛАВНАЯ — кнопки BOT нет (бот у каждой стороны свой, на GSM/GAMES остаётся); вместо неё «Написать нам» рядом с логотипом.
   Телефон: логотип + кнопка по центру. ПК: кнопка сразу за логотипом, список открывается под ней */
html body.fx-home .site-header .fx-botbtn { display: none !important; }
@media (min-width: 768px) {
  html body.fx-home .site-header .fx-msgbtn { display: inline-grid; place-items: center; order: 1; flex: none; align-self: center; width: 38px; height: 38px; margin-left: 12px; padding: 0; border: 0; border-radius: 50%; cursor: pointer;
    background: linear-gradient(135deg, #b56cff, #7c3aed); color: #fff; box-shadow: 0 4px 14px -4px #a855f7; transition: transform .2s, filter .2s; }
  html body.fx-home .site-header .fx-msgbtn:hover { transform: translateY(-1px); filter: brightness(1.1); }
  html body.fx-home .site-header .fx-msgbtn svg { width: 20px; height: 20px; }
  html body.fx-home .site-header .fantom-header-actions { margin-left: auto !important; }
  .fx-chat.is-hdr .fx-chat__menu { position: fixed; top: var(--fx-mt, 70px); left: var(--fx-ml, 20px); transform-origin: top left; }
}
@media (min-width: 768px) { html body.fx-home .site-header .site-branding { margin-right: 0 !important; } }
/* 2026-10-20 (7): разделы в шапке — больше воздуха между пунктами (после добавления «🔥 Акции» стало плотно) */
@media (min-width: 1250px) {
  html body .site-header .main-navigation ul.menu { gap: 18px !important; justify-content: center !important; }
  html body.mode-games .site-header .main-navigation ul.menu { gap: 14px !important; }
  html body .site-header .main-navigation ul.menu > li > a { padding-left: 2px !important; padding-right: 2px !important; }
}
@media (min-width: 1250px) and (max-width: 1365px) {
  html body.mode-games .site-header .main-navigation ul.menu { gap: 11px !important; }
  html body.mode-games .site-header .main-navigation ul.menu > li > a { font-size: 13.5px !important; letter-spacing: 0 !important; }
  html body.mode-games .site-header .fx-botbtn { margin-left: 2px !important; }
  html body.mode-games .site-header .main-navigation { margin-right: 14px !important; }
}
@media (min-width: 1600px) { html body .site-header .main-navigation ul.menu { gap: 26px !important; } }
@media (min-width: 1250px) and (max-width: 1365px) { html body.mode-games .site-header .main-navigation ul.menu { gap: 13px !important; } }
@media (min-width: 1600px) { html body.mode-games .site-header .main-navigation ul.menu { gap: 24px !important; } }
/* 2026-10-20 (8): разделы меню — равномерно по свободному месту (space-evenly), минимальный зазор 8px; меню не сжимается меньше своих пунктов,
   поэтому «🔥 Акции» больше не налезает на GSM|GAMES (фиксированные зазоры 14–26px на части ширин давали наложение) */
@media (min-width: 1250px) {
  html body .site-header .main-navigation ul.menu, html body.mode-games .site-header .main-navigation ul.menu { gap: 8px !important; justify-content: space-evenly !important; }
  html body .site-header .main-navigation { min-width: max-content !important; flex: 1 0 auto !important; margin-right: 16px !important; }
}
@media (min-width: 1250px) and (max-width: 1365px) {
  html body.mode-games .site-header .main-navigation ul.menu { gap: 6px !important; }
  html body.mode-games .site-header .main-navigation ul.menu > li > a { font-size: 13px !important; }
  html body.mode-games .site-header .fantom-header-actions { gap: 3px !important; }
}
/* значки скидок «−N%» скрывали 2026-10-20 — вернули 2026-10-21 по просьбе Романа (у «Акции недели» своя плашка «Скидка») */
@media (min-width: 1441px) { html body.mode-games .site-header .main-navigation ul.menu > li > a { font-size: 14px !important; } }
@media (min-width: 1441px) {   /* GAMES, широкий экран: логотип, GSM|GAMES и «Мой аккаунт» как на 1440 — больше места разделам меню */
  html body.mode-games .site-header .custom-logo { max-width: 214px !important; height: auto !important; }
  html body.mode-games .site-header .fx-side-tabs a { padding-left: 11px !important; padding-right: 11px !important; }
  html body.mode-games .site-header .fantom-login { padding-left: 16px !important; padding-right: 16px !important; }
  html body.mode-games .site-header .main-navigation { margin-right: 12px !important; }
}


/* ===== 2026-10-25 (Роман): шапка ПК — «Мой аккаунт» крайний справа на всех страницах; бот — круглый значок рядом с поиском ===== */
.fx-boticon { display: none; }
.fx-boticon .fx-botbtn__ico { width: 20px; height: 20px; }
.fx-boticon:not(.is-plain) .fx-botbtn__tg  { animation: fx-bot-a 6s ease-in-out infinite; }
.fx-boticon:not(.is-plain) .fx-botbtn__bot { animation: fx-bot-b 6s ease-in-out infinite; color: var(--blue, #2f8cff); --fx-bot-eye: var(--surface, #1b2230); }
@media (min-width: 1250px) {
  html body .site-header .fx-botbtn { display: none !important; }
  html body .site-header .fantom-header-actions > .fx-boticon { display: inline-flex; align-items: center; justify-content: center; }
  html body .site-header .fantom-header-actions > .fantom-search { order: 1 !important; }
  html body .site-header .fantom-header-actions > .fx-boticon { order: 2 !important; }
  html body .site-header .fantom-header-actions > .fantom-lang { order: 3 !important; }
  html body .site-header .fantom-header-actions > .fantom-theme-toggle { order: 4 !important; }
  html body .site-header .fantom-header-actions > .fx-bell { order: 5 !important; }
  html body .site-header .fantom-header-actions > .fx-cart { order: 6 !important; }
  html body.mode-gsm .site-header .fantom-header-actions::after { order: 6 !important; }   /* место под корзину на GSM — тоже перед аккаунтом */
  html body .site-header .fantom-header-actions > .fantom-login { order: 99 !important; }
  html body.fx-pay .site-header .fx-boticon { display: none !important; }
}
@media (min-width: 1250px) {
  /* главная и общие «Акции»/«Отзывы»: кнопки «Отзывы» и «Акции» — перед значками, «Мой аккаунт» по-прежнему крайний справа */
  html body .site-header > .col-full > .fx-deals-btn, html body.fx-home .site-header > .col-full > .fx-deals-btn { order: 2 !important; margin-left: auto !important; }
  html body .site-header > .col-full > .fx-rv-btn { order: 2 !important; margin-left: 10px !important; }
  html body .site-header > .col-full > .fx-rv-btn:first-of-type:not(.fx-deals-btn ~ .fx-rv-btn) { margin-left: auto !important; }   /* страница без «Акций» — «Отзывы» сами прижимаются вправо */
  html body .site-header > .col-full > .fx-rv-btn ~ .fantom-header-actions,
  html body .site-header > .col-full > .fx-deals-btn ~ .fantom-header-actions { margin-left: 10px !important; }
  html body.fx-home .site-header .fx-boticon { display: none !important; }   /* на главной бота нет (решение Романа 2026-10-20) */
}


/* ===== 2026-10-25 (Роман): телефон и планшет (<1250px) — бот круглым значком, как на ПК, рядом с «Написать нам»;
   переключатель GSM | GAMES — во втором ряду рядом с поиском ===== */
@media (max-width: 1249px) {
  html body .site-header .fx-botbtn { display: none !important; }
  html body .site-header .fantom-header-actions > .fx-boticon {
    display: inline-flex !important; align-items: center; justify-content: center; order: 1 !important; align-self: center;
    width: 32px !important; height: 32px !important; min-height: 32px !important; flex: none !important; margin: 0 !important; padding: 0 !important; border-radius: 50%;
  }
  html body .site-header .fantom-header-actions > .fx-boticon .fx-botbtn__ico { width: 18px; height: 18px; }
  html body.fx-home .site-header .fx-boticon, html body.fx-pay .site-header .fx-boticon { display: none !important; }   /* на главной и страницах оплаты бота нет */
}
@media (max-width: 767px) {
  /* телефон: два ряда примерно одной ширины — логотип чуть крупнее (ряд 1: логотип, «Написать нам», бот; ряд 2: GSM|GAMES, поиск, язык, тема, меню) */
  html body:not(.fx-home):not(.fx-pay) .site-header > .col-full > .site-branding { flex: none !important; width: var(--fx-logo-m, 186px) !important; max-width: 186px !important; }
  html body:not(.fx-home):not(.fx-pay) .site-header > .col-full > .site-branding .custom-logo-link { display: block !important; width: 100% !important; }
  html body:not(.fx-home):not(.fx-pay) .site-header > .col-full > .site-branding img { width: 100% !important; max-width: 100% !important; height: auto !important; }
}
@media (max-width: 767px) {
  /* 2026-10-25 (Роман): колокольчик уведомлений (у вошедших) — в первом ряду сразу за ботом; логотип уже, чтобы ряды остались одной ширины */
  html body .site-header .fantom-header-actions > .fx-bell { order: 1 !important; align-self: center; flex: none; margin: 0 !important; }
  html body .site-header .fantom-header-actions > .fx-bell .fx-bell__btn { width: 32px !important; height: 32px !important; min-height: 32px !important; padding: 0 !important; }
  html body:not(.fx-home):not(.fx-pay) .site-header > .col-full:has(.fx-bell) > .site-branding { width: 157px !important; max-width: 157px !important; }
}
