/* style.css */
:root {
  --bg: #0f1220;
  --panel: #161a2f;
  --panel2: #141a33;
  --text: #e8eaf6;
  --muted: #a6accd;
  --line: #2a2f55;
  --accent: #7aa2ff;
}

* {
  box-sizing: border-box;
}

body {
  background-image: url(../images/body-bg-top.webp);
  background-repeat: no-repeat;
  background-position: center top;
  background-size: cover;
  background-attachment: fixed;
  background-color: #000;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: var(--text);
  letter-spacing: 0;
  line-height: 1.6;
  font-size: 14px;
  margin: 0;
  padding: 0;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

b,
strong {
  font-family: 'Orbitron', sans-serif;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

/* Header */
header {
  padding: 14px 18px;
  background: linear-gradient(180deg, rgba(22, 26, 47, .92), rgba(22, 26, 47, .82));
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: none;
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

/* Мобильная кнопка меню */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  padding: 5px;
  z-index: 1001;
}

.mobile-menu-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.9);
  z-index: 9998;
  backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.mobile-menu-overlay.active {
  display: block;
  opacity: 1;
}

.mobile-menu-content {
  position: fixed;
  top: 0;
  left: 0;
  width: 280px;
  height: 100%;
  background: rgba(10, 14, 28, 0.98);
  border-right: 1px solid rgba(255,255,255,0.1);
  z-index: 9999;
  overflow-y: auto;
  padding: 20px;
  transform: translateX(-100%);
  transition: transform 0.3s ease;
}

.mobile-menu-content.active {
  transform: translateX(0);
}

.mobile-menu-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: none;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  z-index: 10000;
}

.mobile-srvBadge {
  margin-bottom: 20px;
  padding: 15px;
  background: rgba(0,0,0,0.3);
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.1);
}

/* Левая панель (для десктопа) */
.left-panels {
  position: fixed;
  top: 122px; /* отступ от шапки */
  left: 16px;
  width: 220px;
  z-index: 999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Бейдж сервера */
.srvBadge {
  padding: 10px 12px;
  background: rgba(0, 0, 0, .55);
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 10px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  font-family: inherit;
  line-height: 1.15;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-family: 'Orbitron', sans-serif;
  letter-spacing: 0.3px;
font-size: 12px; /* можно уменьшить, если нужно */
}

.srvBadge__title {
  font-size: 13px;
  font-weight: 800;
  color: #f0c674;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 6px;
}

.srvBadge__meta {
  font-size: 12px;
  color: rgba(255, 255, 255, .85);
  margin-bottom: 8px;
}

.srvBadge__metaLabel {
  opacity: .75;
  margin-right: 6px;
}

.srvBadge__metaValue {
  font-weight: 700;
}

.srvBadge__row {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.srvBadge__count {
  font-size: 22px;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: .5px;
}

.srvBadge__status {
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
}

/* Side Menu */
.sideMenu {
  background: rgba(0, 0, 0, .55);
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 10px;
  padding: 10px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.sideMenu__list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-family: 'Orbitron', sans-serif;
  letter-spacing: 0.3px;
font-size: 12px; /* можно уменьшить, если нужно */
}

.sideMenu__list li {
  margin-bottom: 6px;
}

.sideMenu__list a {
  display: block;
  padding: 8px 10px;
  font-size: 13px;
  color: #ddd;
  text-decoration: none;
  border-radius: 6px;
  transition: background .2s, color .2s;
}

.sideMenu__list a:hover {
  background: rgba(255, 255, 255, .08);
  color: #fff;
}

/* Categories Menu */
.catMenu {
  background: rgba(0, 0, 0, .55);
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 10px;
  padding: 10px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.catMenu__list {
  list-style: none;
  margin: 0;
  padding: 0;
    font-family: 'Orbitron', sans-serif;
  letter-spacing: 0.3px;
font-size: 12px; /* можно уменьшить, если нужно */
}

.catMenu__list li {
  margin-bottom: 6px;
}

.catMenu__list a {
  display: block;
  padding: 8px 10px;
  font-size: 13px;
  color: #ddd;
  text-decoration: none;
  border-radius: 6px;
  transition: background .2s, color .2s;
}

.catMenu__list a:hover {
  background: rgba(255, 255, 255, .08);
  color: #fff;
}

.catMenu__list a.active {
  background: rgba(255, 255, 255, .10);
  color: #fff;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .15) inset;
}

/* Основной контент */
main {
  max-width: 1400px;
  margin: 0 auto;
  padding: 120px 16px 16px 16px;
  margin-left: 250px; /* 220px + 30px отступ */
  min-height: 100vh;
  transition: margin-left 0.3s ease;
}

/* Статья */
article {
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
  background: rgba(0, 0, 0, .55);
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 10px;
  padding: 22px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

article h1,
article h2,
article h3 {
  font-family: 'Orbitron', sans-serif;
  letter-spacing: .5px;
  text-transform: uppercase;
  margin: 0 0 12px;
}

article h1 {
  font-size: 20px;
}

article h2 {
  font-size: 15px;
  margin-top: 22px;
}

article h3 {
  font-size: 13px;
  margin-top: 18px;
}

article p {
  color: var(--text);
  max-width: 980px;
  margin: 10px 0;
}

article li {
  max-width: 980px;
}

article .meta {
  color: var(--muted);
  font-size: 12px;
}

/* Формы */
input,
textarea,
button {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #0b0e1a;
  color: #fff;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  margin-bottom: 10px;
}

textarea {
  min-height: 320px;
  line-height: 1.5;
  resize: vertical;
}

button {
  cursor: pointer;
  margin-top: 10px;
  font-family: 'Orbitron', sans-serif;
  letter-spacing: .4px;
  text-transform: uppercase;
  background: rgba(122, 162, 255, .14);
  border: none;
  transition: background .2s;
}

button:hover {
  background: rgba(122, 162, 255, .22);
}

/* Таблицы */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 15px 0;
  text-align: center;
}

table th,
table td {
  padding: 8px 12px;
  vertical-align: middle;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, .1);
}

table[border="0"],
table[border="0"] th,
table[border="0"] td {
  border: none !important;
}

/* Админ таблица страниц */
.pages-table {
  width: 100%;
  border-collapse: collapse;
}

.pages-table td {
  vertical-align: top;
  padding: 12px 18px 16px 0;
  border: none;
}

.pages-table b {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
  opacity: .95;
}

.pages-table ul {
  margin: 0;
  padding-left: 16px;
}

.pages-table li {
  margin: 5px 0;
  font-size: 13px;
  line-height: 1.25;
}

/* Категории верхние ссылки */
.cat-top-links {
  margin: 0 0 20px 0;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, .15);
  border-radius: 12px;
  background: rgba(0, 0, 0, .15);
}

.cat-top-links.centered {
  text-align: center;
}

.cat-top-links .cat-links {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.cat-top-links .cat-links a {
  padding: 6px 10px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, .15);
  text-decoration: none;
  transition: all .2s;
}

.cat-top-links .cat-links a:hover,
.cat-top-links .cat-links a.active {
  background: rgba(255, 255, 255, .1);
  border-color: rgba(255, 255, 255, .3);
}

/* Админ FAB кнопка */
.admin-fab {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 1000;
}

.admin-fab a {
  display: inline-flex;
  background: rgba(0, 0, 0, .7);
  border-radius: 50%;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, .1);
  transition: all .2s;
}

.admin-fab a:hover {
  background: rgba(0, 0, 0, .9);
  border-color: var(--accent);
}

.admin-fab img {
  width: 24px;
  height: 24px;
  cursor: pointer;
}

/* Tooltip */
#tooltip {
  position: fixed;
  z-index: 99999;
  display: none;
  opacity: 0;
  transition: opacity .12s ease;
  pointer-events: none;
}

#tooltip .tooltip-inner {
  min-width: 220px;
  max-width: 320px;
  padding: 20px 12px 12px;
  border-radius: 12px;
  border: 1px solid rgba(42, 47, 85, .9);
  background: rgba(10, 14, 28, .96);
  box-shadow: 0 16px 40px rgba(0, 0, 0, .5);
  text-align: center;
  position: relative;
  overflow: hidden;
}

#tooltip .tooltip-icon img {
  width: auto;
  height: auto;
  image-rendering: pixelated;
  border-radius: 0;
  border: none;
  background: none;
  max-width: 64px;
  margin: 0 auto 10px;
}

#tooltip .tooltip-body b {
  display: block;
  font-family: 'Orbitron', sans-serif;
  text-transform: uppercase;
  letter-spacing: .5px;
  font-size: 12px;
  margin-bottom: 6px;
}

#tooltip .tooltip-body small {
  display: block;
  font-size: 12px;
  line-height: 1.35;
  color: var(--muted);
}

/* ================== Mobile / Tablet ================== */
@media (max-width: 980px) {
  /* Показываем кнопку мобильного меню */
  .mobile-menu-btn {
    display: block;
  }
  
  /* Скрываем левую панель на мобильных */
  .left-panels {
    display: none !important;
  }
  
  /* Основной контент занимает всю ширину */
  main {
    margin-left: 0 !important;
    padding: 80px 12px 12px 12px !important;
    width: 100%;
  }
  
  /* Статья адаптируется */
  article {
    padding: 16px;
    width: 100%;
  }
  
  article h1 {
    font-size: 18px;
  }
  
  article h2 {
    font-size: 14px;
    margin-top: 18px;
  }
  
  article h3 {
    font-size: 12px;
    margin-top: 14px;
  }
  
  /* Категории в мобильном меню */
  .mobile-menu-content .sideMenu,
  .mobile-menu-content .catMenu {
    background: transparent;
    border: none;
    padding: 0;
    backdrop-filter: none;
  }
  
  .mobile-menu-content .sideMenu__list,
  .mobile-menu-content .catMenu__list {
    padding-left: 0;
  }
  
  .mobile-menu-content .sideMenu__list li,
  .mobile-menu-content .catMenu__list li {
    margin-bottom: 8px;
  }
  
  .mobile-menu-content .sideMenu__list a,
  .mobile-menu-content .catMenu__list a {
    padding: 10px 12px;
    font-size: 14px;
    background: rgba(255, 255, 255, 0.05);
  }
  
  .mobile-menu-content .catMenu__list a.active {
    background: rgba(255, 255, 255, 0.1);
  }
  
  /* Категории верхние ссылки - по центру */
  .cat-top-links .cat-links {
    justify-content: center;
  }
  
  /* Формы */
  input, textarea, button {
    padding: 10px 12px;
  }
  
  textarea {
    min-height: 260px;
  }
  
  /* Tooltip меньше */
  #tooltip .tooltip-inner {
    min-width: 200px;
    max-width: 280px;
    padding: 30px 10px 10px;
  }
  
  #tooltip .tooltip-body b {
    font-size: 11px;
  }
  
  #tooltip .tooltip-body small {
    font-size: 11px;
  }
}

/* Очень узкие экраны */
@media (max-width: 520px) {
  main {
    padding: 60px 12px 12px 12px !important;
    display: block;
  }
  
  article {
    padding: 14px;
  }
  
  article p,
  article li,
  article td {
    font-size: 13px;
  }
  
  /* Админ таблица страниц: в одну колонку */
  .pages-table,
  .pages-table tr,
  .pages-table td {
    display: block;
    width: 100%;
  }
  
  .pages-table td {
    padding: 10px 0 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .pages-table td:last-child {
    border-bottom: none;
  }
  
  /* Категории верхние ссылки - вертикально */
  .cat-top-links .cat-links {
    flex-direction: column;
    gap: 6px;
  }
  
  .cat-top-links .cat-links a {
    text-align: center;
    padding: 8px 12px;
  }
  
  /* Мобильное меню уже */
  .mobile-menu-content {
    width: 250px;
  }
}

/* Очень высокие экраны - ограничиваем высоту меню */
@media (min-height: 800px) {
  .mobile-menu-content {
    padding-top: 40px;
  }
}

/* Дополнительные утилиты */
.centered {
  text-align: center;
}

.mt-20 { margin-top: 20px; }
.mb-20 { margin-bottom: 20px; }
.ml-10 { margin-left: 10px; }
.mr-10 { margin-right: 10px; }

/* Скрытие скроллбаров */
*::-webkit-scrollbar {
  width: 0;
  height: 0;
}

* {
  scrollbar-width: none;
}

img {
  vertical-align: middle;
}

.discordBadge{
  position: fixed;
  top: -32px;        /* вместо -32px */
  left: 14px;
  width: 220px;
  padding: 10px 12px;

  display: flex;
  justify-content: center;
  align-items: center;

  z-index: 1002;    /* не 100000 */
}

.discordBadge img{
  display: block;
  max-width: 100%;
  height: auto;
}

.visitCounter{
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);

    font-size: 18px;
    font-weight: bold;
    color: red;

    z-index: 9999;
}