/* ============================================================
   Кнопка «Меню» в шапке (Glassmorphic Trigger)
   ============================================================ */
.pbtop-row { 
  position: relative; 
}

.pbg-menu-trigger-wrap {
  display: inline-flex;
  align-items: center;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
}

.pbg-menu-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 18px;
  height: 36px;
  background: rgba(18, 20, 29, 0.45) !important;
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(79, 234, 159, 0.35);
  border-radius: 12px;
  color: #4fea9f;
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: .3px;
  cursor: pointer;
  transition: all 0.22s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.35);
}

.pbg-menu-trigger i { 
  font-size: 17px; 
  line-height: 0; 
}

.pbg-menu-trigger:hover {
  border-color: rgba(79, 234, 159, 0.65);
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(79, 234, 159, 0.25);
  transform: translateY(-1px);
}

.pbg-menu-trigger[aria-expanded="true"] {
  background: linear-gradient(135deg, rgba(79, 234, 159, 0.2) 0%, rgba(34, 184, 119, 0.2) 100%) !important;
  border-color: #4fea9f;
  color: #ffffff;
  box-shadow: 0 0 18px rgba(79, 234, 159, 0.35);
}

@media (max-width: 991.98px) {
  .pbg-menu-trigger-wrap {
    position: static;
    transform: none;
    margin-left: auto;
  }
}

@media (max-width: 767.98px) {
  html body .wapper .header.pbtop .header-logo.pbtop-logo {
    display: none;
  }
  .pbg-menu-trigger-wrap {
    margin-left: 0;
  }
}

@media (max-width: 575.98px) {
  .pbg-menu-trigger span { display: none; }
  .pbg-menu-trigger { padding: 0 11px; gap: 0; }
}

/* ============================================================
   Панель «Меню» — Ultra-Glassmorphic Top Drawer & Neon Border
   ============================================================ */
.pbg-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 10, 14, 0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1299;
  opacity: 0;
  pointer-events: none;
  transition: opacity .28s ease;
}

.pbg-menu-overlay.is-open { 
  opacity: 1; 
  pointer-events: all; 
}

/* --- Анимация бегущего неонового градиента --- */
@keyframes pbg-menu-border-glow {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.pbg-menu-panel {
  position: fixed;
  top: 0; left: 0; right: 0;
  max-height: 88vh;
  overflow-y: auto;
  z-index: 1300;
  /* Увеличенная прозрачность меню */
  background: rgba(18, 20, 29, 0.55);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border-bottom: none;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6), 0 0 30px rgba(79, 234, 159, 0.15);
  transform: translateY(-100%);
  transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Красивая живая зеленая обводка снизу панели */
.pbg-menu-panel::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #22b877, #4fea9f, #a8ffdb, #4fea9f, #22b877);
  background-size: 200% 100%;
  animation: pbg-menu-border-glow 4s linear infinite;
  box-shadow: 0 0 12px rgba(79, 234, 159, 0.8), 0 0 24px rgba(79, 234, 159, 0.4);
  z-index: 10;
}

.pbg-menu-panel.is-open { 
  transform: translateY(0); 
}

body.pbg-menu-active { 
  overflow: hidden; 
}

.pbg-menu-panel::-webkit-scrollbar { 
  width: 4px; 
}

.pbg-menu-panel::-webkit-scrollbar-thumb { 
  background: rgba(79, 234, 159, 0.3); 
  border-radius: 10px; 
}

.pbg-menu-panel__head {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 24px;
  /* Повышенная прозрачность липкой шапки */
  background: rgba(18, 20, 29, 0.65);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.pbg-menu-panel__title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  flex: 1 1 0;
  min-width: 0;
}

.pbg-menu-panel__title i { 
  font-size: 20px; 
  color: #4fea9f; 
  filter: drop-shadow(0 0 8px rgba(79, 234, 159, 0.7));
}

.pbg-menu-home-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 34px;
  padding: 0 16px;
  border-radius: 10px;
  background: rgba(79, 234, 159, 0.12);
  border: 1px solid rgba(79, 234, 159, 0.35);
  color: #4fea9f;
  font-size: 12.5px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.pbg-menu-home-btn i { 
  font-size: 16px; 
  line-height: 0; 
}

.pbg-menu-home-btn:hover {
  background: rgba(79, 234, 159, 0.22);
  border-color: rgba(79, 234, 159, 0.65);
  color: #fff;
  text-decoration: none;
  box-shadow: 0 0 14px rgba(79, 234, 159, 0.35);
}

.pbg-menu-panel__actions {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.pbg-menu-panel__close {
  flex: 0 0 auto;
  width: 34px; 
  height: 34px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #aeb6d2;
  font-size: 19px;
  display: flex; 
  align-items: center; 
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.pbg-menu-panel__close:hover { 
  background: rgba(255, 255, 255, 0.12); 
  color: #fff; 
  border-color: rgba(79, 234, 159, 0.4);
}

.pbg-menu-panel__body {
  padding: 20px 24px 26px;
}

.pbg-menu-loading, .pbg-menu-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  color: #707893;
  font-size: 24px;
}

.pbg-menu-empty { 
  font-size: 13px; 
}

/* ---- Одиночные пункты (без категории) ---- */
.pbg-menu-singles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
  gap: 12px;
  padding-bottom: 20px;
  margin-bottom: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.pbg-menu-singles .pbg-menu-item {
  position: relative;
  height: 64px;
  padding: 0 16px;
  gap: 13px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  overflow: hidden;
  transition: all 0.22s ease;
}

.pbg-menu-singles .pbg-menu-item::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--pbg-item-icon, #4fea9f) 18%, transparent), transparent 60%);
  opacity: .8;
  pointer-events: none;
}

.pbg-menu-singles .pbg-menu-item:has(.pbg-menu-item__icon--img)::before {
  display: none;
}

.pbg-menu-singles .pbg-menu-item:hover {
  border-color: color-mix(in srgb, var(--pbg-item-glow, var(--pbg-item-icon, #4fea9f)) 50%, transparent);
  background: rgba(255, 255, 255, 0.06);
  transform: translateY(-2px);
}

.pbg-menu-singles .pbg-menu-item--glow:hover {
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--pbg-item-glow, #4fea9f) 30%, transparent),
    0 10px 26px -6px color-mix(in srgb, var(--pbg-item-glow, #4fea9f) 60%, transparent),
    0 0 28px -4px color-mix(in srgb, var(--pbg-item-glow, #4fea9f) 55%, transparent);
}

.pbg-menu-singles .pbg-menu-item__icon {
  position: relative;
  z-index: 1;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  font-size: 20px;
  background: color-mix(in srgb, var(--pbg-item-icon, #4fea9f) 15%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--pbg-item-icon, #4fea9f) 25%, transparent);
}

.pbg-menu-singles .pbg-menu-item__icon--img {
  background: transparent;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1);
}

.pbg-menu-singles .pbg-menu-item__text {
  position: relative;
  z-index: 1;
}

.pbg-menu-singles .pbg-menu-item__title {
  font-size: 13.5px;
  font-weight: 800;
}

/* ---- Сетка категорий ---- */
.pbg-menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 20px;
}

.pbg-menu-col {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.pbg-menu-col__head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: #ffffff;
  font-size: 13.5px;
  font-weight: 800;
  letter-spacing: .01em;
}

.pbg-menu-col__head i {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--pbg-cat-icon, #4fea9f) 16%, transparent);
  color: var(--pbg-cat-icon, #4fea9f);
  font-size: 16px;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--pbg-cat-icon, #4fea9f) 25%, transparent);
}

.pbg-menu-col__dot { display: none; }

.pbg-menu-col__items {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.pbg-menu-col__items--grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

/* ---- Карточка пункта ---- */
.pbg-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  height: 52px;
  padding: 0 12px;
  box-sizing: border-box;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(255, 255, 255, 0.03);
  text-decoration: none;
  transition: all 0.2s ease;
}

.pbg-menu-item:hover {
  text-decoration: none;
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.12);
  transform: translateY(-1px);
}

.pbg-menu-item--glow:hover {
  border-color: color-mix(in srgb, var(--pbg-item-glow, #4fea9f) 55%, transparent);
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--pbg-item-glow, #4fea9f) 25%, transparent),
    0 6px 20px -4px color-mix(in srgb, var(--pbg-item-glow, #4fea9f) 55%, transparent),
    0 0 24px -6px color-mix(in srgb, var(--pbg-item-glow, #4fea9f) 65%, transparent);
}

.pbg-menu-item--glow:hover .pbg-menu-item__icon:not(.pbg-menu-item__icon--img) {
  background: color-mix(in srgb, var(--pbg-item-glow, var(--pbg-item-icon, #4fea9f)) 22%, transparent);
  box-shadow: 0 0 14px -2px color-mix(in srgb, var(--pbg-item-glow, #4fea9f) 70%, transparent);
}

.pbg-menu-item__icon {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px; 
  height: 34px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--pbg-item-icon, #4fea9f);
  font-size: 17px;
  transition: all 0.2s ease;
}

.pbg-menu-item__icon--img {
  background: transparent;
  overflow: hidden;
  padding: 0;
  border-radius: 9px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.pbg-menu-item__icon--img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: inherit;
}

.pbg-menu-item__text {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.pbg-menu-item__title {
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pbg-menu-item__subtitle {
  color: #707893;
  font-size: 11px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ---- Вариант «2 в ряд» внутри категорий ---- */
.pbg-menu-col__items--grid2 .pbg-menu-item {
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: auto;
  min-height: 92px;
  padding: 14px 10px;
  text-align: center;
}

.pbg-menu-col__items--grid2 .pbg-menu-item__icon {
  width: 38px;
  height: 38px;
  font-size: 19px;
}

.pbg-menu-col__items--grid2 .pbg-menu-item__text {
  align-items: center;
  width: 100%;
}

.pbg-menu-col__items--grid2 .pbg-menu-item__title,
.pbg-menu-col__items--grid2 .pbg-menu-item__subtitle {
  max-width: 100%;
  white-space: normal;
  text-align: center;
}

/* ============================================================
   Мобильная адаптация
   ============================================================ */
@media (max-width: 767.98px) {
  .pbg-menu-panel { max-height: 100vh; }
  .pbg-menu-panel__head { padding: 14px 16px; }
  .pbg-menu-panel__body { padding: 16px 16px 22px; }
  .pbg-menu-grid { grid-template-columns: 1fr 1fr; gap: 16px; }
  .pbg-menu-singles { grid-template-columns: 1fr; }
  .pbg-menu-home-btn span { display: none; }
  .pbg-menu-home-btn { padding: 0 10px; }
}

@media (max-width: 480px) {
  .pbg-menu-grid { grid-template-columns: 1fr; }
}