/* ============================================================
   CHAOS CLAN — игровой (esports/HUD) дизайн
   Чёрно-оранжевая тема под эмблему клана: сколотые панели,
   металлические рамки, угольки, свечение.
   ============================================================ */

:root {
  --bg-dark: #0b0704;
  --bg-card: #16100a;
  --bg-card-2: #1c140c;
  --panel-line: #241a10;
  --crimson: #f07018;      /* фирменный оранжевый */
  --orange: #f07018;
  --orange-lo: #b5500e;
  --orange-hi: #ff9a3c;
  --ember: #ff7a1a;
  --gold: #f5c451;
  --green: #5bd17f;
  --steel: #cfc6bd;
  --red-soft: #e0b894;
  --text: #ece0d4;
  --text-dim: #a3907d;
  --border: rgba(240, 112, 24, 0.35);
  --border-soft: rgba(240, 112, 24, 0.18);
  --gold-medal: #ffd700;
  --silver-medal: #d6d6d6;
  --bronze-medal: #cd7f32;

  /* сколотые углы для HUD-панелей */
  --cut: polygon(0 14px, 14px 0, calc(100% - 14px) 0, 100% 14px,
                 100% calc(100% - 14px), calc(100% - 14px) 100%,
                 14px 100%, 0 calc(100% - 14px));
  --cut-sm: polygon(0 8px, 8px 0, calc(100% - 8px) 0, 100% 8px,
                    100% calc(100% - 8px), calc(100% - 8px) 100%,
                    8px 100%, 0 calc(100% - 8px));
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Open Sans', sans-serif;
  background-color: var(--bg-dark);
  background-image:
    /* верхнее оранжевое зарево */
    radial-gradient(ellipse at 50% -8%, rgba(240, 112, 24, 0.22) 0%, transparent 55%),
    /* нижние угли по краям */
    radial-gradient(ellipse at 12% 108%, rgba(181, 80, 14, 0.28) 0%, transparent 46%),
    radial-gradient(ellipse at 88% 108%, rgba(181, 80, 14, 0.20) 0%, transparent 46%),
    /* карбоновая сетка */
    repeating-linear-gradient(0deg, rgba(255,255,255,0.014) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.014) 0 1px, transparent 1px 3px);
  background-attachment: fixed;
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
  position: relative;
  overflow-x: hidden;
}

/* Тлеющие угольки на фоне */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    radial-gradient(2px 2px at 20% 30%, rgba(255, 122, 26, 0.6), transparent),
    radial-gradient(2px 2px at 70% 60%, rgba(255, 122, 26, 0.4), transparent),
    radial-gradient(1px 1px at 40% 80%, rgba(255, 154, 60, 0.5), transparent),
    radial-gradient(1px 1px at 85% 25%, rgba(255, 122, 26, 0.5), transparent),
    radial-gradient(2px 2px at 55% 15%, rgba(255, 122, 26, 0.35), transparent),
    radial-gradient(1px 1px at 10% 70%, rgba(255, 154, 60, 0.4), transparent);
  background-repeat: no-repeat;
  animation: emberDrift 14s ease-in-out infinite alternate;
  opacity: 0.7;
}

@keyframes emberDrift {
  from { transform: translateY(0) scale(1); opacity: 0.5; }
  to   { transform: translateY(-24px) scale(1.05); opacity: 0.85; }
}

.container,
.hero,
.site-header,
.admin-wrap,
.site-footer { position: relative; z-index: 1; }

/* ---------- Шапка ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background:
    linear-gradient(180deg, rgba(28, 18, 8, 0.96) 0%, rgba(11, 7, 4, 0.98) 100%);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 4px 26px rgba(0, 0, 0, 0.85), 0 1px 0 rgba(255, 154, 60, 0.15);
  backdrop-filter: blur(6px);
}

/* тонкая оранжевая «энергополоса» под шапкой */
.site-header::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--orange) 30%, var(--orange-hi) 50%, var(--orange) 70%, transparent);
  box-shadow: 0 0 12px rgba(240, 112, 24, 0.8);
  animation: scanPulse 3.5s ease-in-out infinite;
}

@keyframes scanPulse { 0%,100% { opacity: 0.5; } 50% { opacity: 1; } }

.header-inner {
  max-width: 1140px;
  margin: 0 auto;
  padding: 11px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; }

.logo-img {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 1px solid rgba(240, 112, 24, 0.6);
  box-shadow: 0 0 14px rgba(240, 112, 24, 0.55), 0 3px 10px rgba(0, 0, 0, 0.7);
  transition: transform 0.25s, box-shadow 0.25s;
}
.logo:hover .logo-img {
  transform: rotate(-6deg) scale(1.05);
  box-shadow: 0 0 22px rgba(240, 112, 24, 0.85), 0 3px 10px rgba(0, 0, 0, 0.7);
}

.logo-name {
  font-family: 'Teko', sans-serif;
  font-size: 2.05rem;
  font-weight: 700;
  letter-spacing: 5px;
  color: #fff;
  text-shadow: 0 0 14px rgba(240, 112, 24, 0.85), 0 2px 0 #2a1608;
  line-height: 1;
}
.logo-name span { color: var(--orange); }

.main-nav { display: flex; gap: 2px; flex-wrap: wrap; }

.main-nav a {
  position: relative;
  font-family: 'Teko', sans-serif;
  font-size: 1.25rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--red-soft);
  text-decoration: none;
  padding: 8px 16px;
  transition: color 0.15s, text-shadow 0.15s;
}
.main-nav a::after {
  content: "";
  position: absolute;
  left: 16px; right: 16px; bottom: 4px;
  height: 2px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s;
  box-shadow: 0 0 8px var(--orange);
}
.main-nav a:hover,
.main-nav a.active { color: var(--orange-hi); text-shadow: 0 0 10px rgba(255, 154, 60, 0.7); }
.main-nav a:hover::after { transform: scaleX(1); }

/* Кнопка-гамбургер (скрыта на десктопе) */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 40px;
  padding: 0 9px;
  background: rgba(240, 112, 24, 0.10);
  border: 1px solid var(--border);
  clip-path: var(--cut-sm);
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 3px;
  width: 100%;
  background: var(--orange-hi);
  border-radius: 2px;
  box-shadow: 0 0 6px rgba(240, 112, 24, 0.6);
  transition: transform 0.25s ease, opacity 0.2s ease;
}
/* превращение в крестик */
.site-header.nav-open .nav-toggle span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.site-header.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
.site-header.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

@media (max-width: 760px) {
  .nav-toggle { display: flex; }
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: linear-gradient(180deg, rgba(24, 16, 9, 0.99), rgba(11, 7, 4, 0.99));
    border-bottom: 1px solid var(--border);
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.7);
    padding: 6px 0 10px;
    backdrop-filter: blur(6px);
  }
  .site-header.nav-open .main-nav {
    display: flex;
    animation: navDrop 0.25s ease-out;
  }
  .main-nav a {
    font-size: 1.5rem;
    padding: 12px 22px;
    border-bottom: 1px solid rgba(240, 112, 24, 0.10);
  }
  .main-nav a::after { display: none; }
  .main-nav a:hover { background: rgba(240, 112, 24, 0.12); }
}
@keyframes navDrop { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- Герой с баннером ---------- */

.hero {
  max-width: 1240px;
  margin: 26px auto 0;
  padding: 0 16px;
  text-align: center;
}

.hero-banner {
  position: relative;
  border: 1px solid var(--border);
  clip-path: var(--cut);
  overflow: hidden;
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.7);
  filter: drop-shadow(0 0 26px rgba(240, 112, 24, 0.18));
}

.hero-banner img {
  display: block;
  width: 100%;
  height: auto;
}

/* лёгкая виньетка + затемнение низа под кнопку */
.hero-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 50% 40%, transparent 55%, rgba(11, 7, 4, 0.55) 100%),
    linear-gradient(180deg, transparent 55%, rgba(11, 7, 4, 0.85) 100%);
  pointer-events: none;
}

/* «уголки» HUD поверх баннера */
.hero-banner .corner {
  position: absolute;
  width: 26px; height: 26px;
  border: 2px solid var(--orange);
  z-index: 2;
  opacity: 0.9;
  box-shadow: 0 0 10px rgba(240, 112, 24, 0.6);
}
.hero-banner .corner.tl { top: 12px; left: 12px; border-right: 0; border-bottom: 0; }
.hero-banner .corner.tr { top: 12px; right: 12px; border-left: 0; border-bottom: 0; }
.hero-banner .corner.bl { bottom: 12px; left: 12px; border-right: 0; border-top: 0; }
.hero-banner .corner.br { bottom: 12px; right: 12px; border-left: 0; border-top: 0; }

.hero-cta {
  margin-top: 22px;
  display: flex;
  gap: 14px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}

.hero .sub {
  max-width: 620px;
  margin: 18px auto 0;
  color: var(--text-dim);
  font-size: 1rem;
}
.hero .sub strong { color: var(--orange-hi); }

/* ---------- Кнопки ---------- */

.btn {
  position: relative;
  display: inline-block;
  font-family: 'Teko', sans-serif;
  font-size: 1.3rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-weight: 600;
  color: #fff;
  text-decoration: none;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.85);
  padding: 12px 34px 9px;
  border: none;
  cursor: pointer;
  clip-path: var(--cut-sm);
  background: linear-gradient(180deg, #7a3809 0%, #c25a10 22%, #f07018 50%, #b5500e 78%, #6a3007 100%);
  box-shadow: 0 0 0 1px rgba(255, 154, 60, 0.35) inset, 0 3px 0 #2a1608, 0 8px 18px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  transition: transform 0.1s, filter 0.15s;
}
/* блик-пробег */
.btn::before {
  content: "";
  position: absolute;
  top: 0; left: -60%;
  width: 40%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-20deg);
  transition: left 0.5s;
}
.btn:hover { filter: brightness(1.12); transform: translateY(-1px); }
.btn:hover::before { left: 130%; }
.btn:active { transform: translateY(2px); box-shadow: 0 0 0 1px rgba(255, 154, 60, 0.35) inset, 0 1px 0 #2a1608, 0 3px 8px rgba(0, 0, 0, 0.55); }

.btn-gold {
  background: linear-gradient(180deg, #7a5a10 0%, #b8901f 22%, #f5c451 50%, #b8901f 78%, #5a4008 100%);
  color: #2a1c02;
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 0 1px rgba(255, 230, 150, 0.4) inset, 0 3px 0 #201404, 0 8px 18px rgba(0, 0, 0, 0.55);
}

.btn-ghost {
  background: rgba(240, 112, 24, 0.10);
  color: var(--orange-hi);
  box-shadow: 0 0 0 1px var(--border) inset;
}
.btn-ghost:hover { background: rgba(240, 112, 24, 0.22); filter: none; }

.btn-sm { font-size: 1.02rem; padding: 6px 14px 4px; letter-spacing: 1px; }

.btn-danger {
  background: linear-gradient(180deg, #3a0a0a 0%, #6b1010 40%, #8b1a1a 60%, #2a0606 100%);
  box-shadow: 0 0 0 1px rgba(255, 100, 100, 0.3) inset, 0 3px 0 #1a0404, 0 6px 14px rgba(0,0,0,.5);
}
.btn-green {
  background: linear-gradient(180deg, #0a3a18 0%, #1a7a38 45%, #28a745 60%, #062a10 100%);
  box-shadow: 0 0 0 1px rgba(100, 255, 150, 0.3) inset, 0 3px 0 #04220c, 0 6px 14px rgba(0,0,0,.5);
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; filter: grayscale(0.5); }

/* ---------- Секции ---------- */

.container { max-width: 1140px; margin: 0 auto; padding: 0 20px 70px; }

.section { margin-top: 58px; }

.section-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  font-family: 'Teko', sans-serif;
  font-size: 2.9rem;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  text-align: center;
  color: #fff;
  text-shadow: 0 0 18px rgba(240, 112, 24, 0.75);
  margin-bottom: 4px;
}
/* «клинки» по бокам заголовка */
.section-title::before,
.section-title::after {
  content: "";
  height: 2px;
  width: clamp(24px, 8vw, 90px);
  background: linear-gradient(90deg, transparent, var(--orange));
  box-shadow: 0 0 8px rgba(240, 112, 24, 0.6);
}
.section-title::after { background: linear-gradient(90deg, var(--orange), transparent); }
.section-title .icon { filter: drop-shadow(0 0 8px rgba(240, 112, 24, 0.9)); }

.section-sub {
  text-align: center;
  color: var(--text-dim);
  font-size: 0.95rem;
  margin-bottom: 22px;
}

/* ---------- HUD-панель (сколотые углы + рамка + свечение) ---------- */

.content-card {
  position: relative;
  padding: 24px;
  background:
    linear-gradient(140deg, rgba(240,112,24,0.55) 0%, rgba(240,112,24,0.15) 30%, rgba(60,40,20,0.4) 60%, rgba(240,112,24,0.35) 100%);
  clip-path: var(--cut);
  filter: drop-shadow(0 10px 26px rgba(0, 0, 0, 0.6));
  transition: filter 0.3s ease;
}
.content-card:hover { filter: drop-shadow(0 12px 30px rgba(240, 112, 24, 0.20)); }
/* внутренняя тёмная плоскость — оставляет ~2px оранжевую рамку */
.content-card::before {
  content: "";
  position: absolute;
  inset: 2px;
  z-index: 0;
  background: linear-gradient(180deg, var(--bg-card-2) 0%, var(--bg-card) 100%);
  clip-path: var(--cut);
}
.content-card > * { position: relative; z-index: 1; }

/* ---------- Статы клана ---------- */

.clan-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
@media (max-width: 780px) { .clan-stats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 420px) { .clan-stats { grid-template-columns: 1fr; } }

.stat-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 168px;
  padding: 22px 14px;
  background: linear-gradient(160deg, rgba(240, 112, 24, 0.40), rgba(60, 40, 20, 0.35));
  clip-path: var(--cut-sm);
  transition: transform 0.2s ease, filter 0.2s ease;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5));
  overflow: hidden;
}
.stat-tile::before {
  content: "";
  position: absolute;
  inset: 1px;
  z-index: 0;
  clip-path: var(--cut-sm);
  background: linear-gradient(180deg, rgba(30, 21, 12, 0.97), rgba(15, 10, 6, 0.97));
}
/* блик-пробег при наведении */
.stat-tile::after {
  content: "";
  position: absolute;
  top: 0; left: -70%;
  width: 55%; height: 100%;
  z-index: 2;
  background: linear-gradient(100deg, transparent, rgba(255, 180, 90, 0.16), transparent);
  transform: skewX(-18deg);
  transition: left 0.6s ease;
  pointer-events: none;
}
.stat-tile > * { position: relative; z-index: 1; }
.stat-tile:hover {
  transform: translateY(-6px);
  filter: drop-shadow(0 14px 26px rgba(240, 112, 24, 0.4));
}
.stat-tile:hover::after { left: 120%; }

.tile-icon {
  display: block;
  width: 38px;
  height: 38px;
  color: var(--orange);
  filter: drop-shadow(0 0 8px rgba(240, 112, 24, 0.55));
  transition: transform 0.2s ease, color 0.2s ease;
}
.tile-icon .ic { width: 100%; height: 100%; }
.stat-tile:hover .tile-icon {
  transform: scale(1.15) translateY(-2px);
  color: var(--orange-hi);
}

.stat-value {
  font-family: 'Teko', sans-serif;
  font-size: 2.7rem;
  font-weight: 700;
  line-height: 1;
  color: var(--gold);
  text-shadow: 0 0 14px rgba(245, 196, 81, 0.55);
}
.stat-label {
  font-family: 'Teko', sans-serif;
  font-size: 1rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

/* Champion в плитке ранга: корона + слово */
.rank-champ { display: inline-flex; align-items: center; gap: 6px; }
.rank-champ .ic { width: 30px; height: 30px; color: var(--gold-medal); filter: drop-shadow(0 0 8px rgba(255,215,0,.6)); }

/* ---------- SVG-иконки (общее) ---------- */

.ic { width: 1.05em; height: 1.05em; vertical-align: -0.16em; }

.section-title .icon { display: inline-flex; }
.section-title .icon .ic {
  width: 34px; height: 34px;
  color: var(--orange);
  filter: drop-shadow(0 0 8px rgba(240, 112, 24, 0.85));
}

.btn [data-icon] { display: inline-flex; vertical-align: -0.16em; }
.btn [data-icon] .ic { width: 1.05em; height: 1.05em; }

.rank-cell .champ .ic { width: 26px; height: 26px; color: var(--gold-medal); }

.ic-medal { width: 30px; height: 30px; vertical-align: middle; filter: drop-shadow(0 1px 3px rgba(0,0,0,.6)); }

.role-Master .ic { width: 0.95em; height: 0.95em; vertical-align: -0.15em; }

.site-footer [data-icon] .ic { color: var(--orange); width: 1em; height: 1em; }

/* ---------- Таблицы лидерборда ---------- */

.lb-wrap { overflow-x: auto; }

.lb-table { width: 100%; border-collapse: collapse; min-width: 560px; }

.lb-table thead th {
  font-family: 'Teko', sans-serif;
  font-size: 1.15rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #1c1006;
  padding: 11px 14px;
  text-align: left;
  background: linear-gradient(180deg, #ff9a3c 0%, #f07018 45%, #b5500e 100%);
  border-bottom: 2px solid #2a1608;
}
.lb-table thead th:first-child { text-align: center; }

.lb-table tbody td {
  padding: 11px 14px;
  border-bottom: 1px solid rgba(240, 112, 24, 0.12);
  font-size: 0.95rem;
}
.lb-table tbody tr { background: rgba(22, 16, 10, 0.5); transition: background 0.18s, box-shadow 0.18s, transform 0.18s; }
.lb-table tbody tr:nth-child(even) { background: rgba(28, 20, 12, 0.5); }
.lb-table tbody tr:hover {
  background: rgba(240, 112, 24, 0.18);
  box-shadow: inset 4px 0 0 var(--orange), 0 0 22px rgba(240, 112, 24, 0.16);
  transform: translateX(4px);
}
.lb-table tbody tr:hover .player-name { color: var(--orange-hi); }

.rank-cell {
  font-family: 'Teko', sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  width: 72px;
  text-align: center;
}
tr.rank-1 .rank-cell { color: var(--gold-medal); text-shadow: 0 0 12px rgba(255, 215, 0, 0.7); }
tr.rank-2 .rank-cell { color: var(--silver-medal); text-shadow: 0 0 12px rgba(214, 214, 214, 0.6); }
tr.rank-3 .rank-cell { color: var(--bronze-medal); text-shadow: 0 0 12px rgba(205, 127, 50, 0.6); }
tr.rank-1 { background: linear-gradient(90deg, rgba(255, 215, 0, 0.12), rgba(22, 16, 10, 0.5) 60%) !important; }
tr.rank-2 { background: linear-gradient(90deg, rgba(214, 214, 214, 0.09), rgba(22, 16, 10, 0.5) 60%) !important; }
tr.rank-3 { background: linear-gradient(90deg, rgba(205, 127, 50, 0.10), rgba(22, 16, 10, 0.5) 60%) !important; }

.player-name { font-family: 'Baloo 2', cursive; font-weight: 600; color: #fff; }

.rank-cell .champ { font-size: 1.6rem; filter: drop-shadow(0 0 8px rgba(255, 215, 0, 0.85)); }
.rank-cell .top-label { font-family: 'Teko', sans-serif; font-size: 1.2rem; letter-spacing: 1px; white-space: nowrap; }

/* Топ-10 игроков */
.lb-table tbody tr.t10 { background: linear-gradient(90deg, rgba(240, 112, 24, 0.22), rgba(22, 16, 10, 0.55) 72%); }
.lb-table tbody tr.t10 td:first-child { box-shadow: inset 3px 0 0 var(--orange); }
.lb-table tbody tr.t10 .player-name { text-shadow: 0 0 8px rgba(255, 154, 60, 0.4); }

/* Мастер клана */
.lb-table tbody tr.master-row {
  background: linear-gradient(90deg, rgba(245, 196, 81, 0.16), rgba(22, 16, 10, 0.55) 72%) !important;
}
.lb-table tbody tr.master-row td:first-child { box-shadow: inset 3px 0 0 var(--gold); }

.rating-cell {
  font-family: 'Teko', sans-serif;
  font-size: 1.4rem;
  color: var(--green);
  text-shadow: 0 0 8px rgba(91, 209, 127, 0.4);
}

.role-badge {
  display: inline-block;
  font-family: 'Teko', sans-serif;
  font-size: 0.92rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 2px 12px;
  clip-path: var(--cut-sm);
  border: 1px solid;
}
.role-Master   { color: var(--gold); border-color: rgba(245, 196, 81, 0.6); background: rgba(245, 196, 81, 0.12); text-shadow: 0 0 6px rgba(245, 196, 81, 0.5); }
.role-Leader   { color: var(--gold); border-color: rgba(245, 196, 81, 0.6); background: rgba(245, 196, 81, 0.12); }
.role-Officer  { color: #ff8a8a; border-color: rgba(255, 138, 138, 0.6); background: rgba(255, 138, 138, 0.12); }
.role-Veteran  { color: #c9a0ff; border-color: rgba(201, 160, 255, 0.6); background: rgba(201, 160, 255, 0.12); }
.role-Fighter  { color: var(--green); border-color: rgba(91, 209, 127, 0.6); background: rgba(91, 209, 127, 0.12); }
.role-Recruit  { color: var(--text-dim); border-color: rgba(184, 154, 130, 0.6); background: rgba(184, 154, 130, 0.12); }

/* ---------- Переключатель сезонов ---------- */

.season-bar { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; margin-bottom: 22px; }

.season-chip {
  position: relative;
  font-family: 'Teko', sans-serif;
  font-size: 1.4rem;
  letter-spacing: 2px;
  color: var(--red-soft);
  background: rgba(240, 112, 24, 0.10);
  border: 1px solid var(--border);
  clip-path: var(--cut-sm);
  padding: 7px 24px 4px;
  cursor: pointer;
  transition: color 0.15s, background 0.15s, box-shadow 0.15s;
}
.season-chip:hover { color: var(--orange-hi); background: rgba(240, 112, 24, 0.22); }
.season-chip.active {
  color: #fff;
  background: linear-gradient(180deg, #c25a10 0%, #f07018 55%, #b5500e 100%);
  border-color: rgba(255, 154, 60, 0.5);
  box-shadow: 0 0 16px rgba(240, 112, 24, 0.55);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}
.season-chip .live-tag {
  color: var(--green);
  font-size: 0.95rem;
  letter-spacing: 1px;
  margin-left: 6px;
  text-shadow: 0 0 6px rgba(91, 209, 127, 0.7);
}

/* ---------- Формы ---------- */

.form-card { max-width: 640px; margin: 0 auto; }
.form-group { margin-bottom: 18px; }

.form-group label {
  display: block;
  font-family: 'Teko', sans-serif;
  font-size: 1.15rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--orange-hi);
  margin-bottom: 6px;
}
.form-group label .req { color: var(--orange); }

.form-control {
  width: 100%;
  font-family: 'Open Sans', sans-serif;
  font-size: 0.95rem;
  color: var(--text);
  background: rgba(8, 5, 3, 0.75);
  border: 1px solid var(--border);
  clip-path: var(--cut-sm);
  padding: 11px 14px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5) inset;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.form-control:focus {
  outline: none;
  border-color: var(--orange-hi);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5) inset, 0 0 12px rgba(240, 112, 24, 0.4);
}
.form-control::placeholder { color: rgba(163, 144, 125, 0.5); }
textarea.form-control { resize: vertical; min-height: 92px; }
select.form-control option { background: var(--bg-card); }

.form-msg {
  display: none;
  margin-top: 16px;
  padding: 12px 16px;
  clip-path: var(--cut-sm);
  font-size: 0.92rem;
  animation: fadeIn 0.3s ease-out forwards;
}
.form-msg.success { display: block; color: var(--green); background: rgba(40, 167, 69, 0.14); border: 1px solid rgba(91, 209, 127, 0.4); }
.form-msg.error { display: block; color: #ff9c9c; background: rgba(240, 112, 24, 0.14); border: 1px solid var(--border); }

/* Ошибки валидации полей */
.field-error {
  display: none;
  margin-top: 5px;
  font-size: 0.82rem;
  color: #ff8a6a;
}
.field-error.show { display: block; }
.form-control.invalid {
  border-color: #e0533d;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5) inset, 0 0 10px rgba(224, 83, 61, 0.35);
}

/* Загрузка обложки поста (URL или файл) */
.img-upload-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.img-upload-row .btn { cursor: pointer; }
.img-upload-status { font-size: 0.85rem; color: var(--text-dim); }
.img-upload-status.ok { color: var(--green); }
.img-upload-status.err { color: #ff8a6a; }

.img-preview {
  margin-top: 10px;
  max-width: 320px;
  clip-path: var(--cut-sm);
  border: 1px solid var(--border);
  overflow: hidden;
}
.img-preview img { display: block; width: 100%; height: auto; }

/* Панель «уже подавал заявку» */
.applied-panel {
  text-align: center;
  padding: 30px 20px;
}
.applied-panel .applied-check {
  display: inline-flex;
  width: 62px;
  height: 62px;
  align-items: center;
  justify-content: center;
  color: var(--green);
  background: rgba(40, 167, 69, 0.12);
  border: 1px solid rgba(91, 209, 127, 0.4);
  border-radius: 50%;
  margin-bottom: 14px;
  filter: drop-shadow(0 0 12px rgba(40, 167, 69, 0.3));
}
.applied-panel .applied-check .ic { width: 30px; height: 30px; }
.applied-panel h3 {
  font-family: 'Teko', sans-serif;
  font-size: 2rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 8px;
}
.applied-panel p { color: var(--text-dim); max-width: 440px; margin: 0 auto; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- Футер ---------- */

.site-footer {
  border-top: 1px solid var(--border);
  background: rgba(8, 5, 3, 0.7);
  padding: 26px 20px;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
}
.site-footer a { color: var(--red-soft); text-decoration: none; }
.site-footer a:hover { color: var(--orange-hi); }
.footer-credit { margin-top: 8px; font-size: 0.82rem; opacity: 0.85; }
.footer-credit strong { color: var(--orange-hi); }
.dc-handle {
  color: var(--orange);
  font-family: 'Teko', sans-serif;
  letter-spacing: 1px;
  font-size: 1.05em;
  padding: 1px 8px;
  border: 1px solid var(--border-soft);
  border-radius: 4px;
  background: rgba(240, 112, 24, 0.08);
}

/* ---------- Админка ---------- */

.admin-wrap { max-width: 1140px; margin: 40px auto; padding: 0 20px; }

.admin-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin-bottom: 24px;
}

.admin-table-wrap { overflow-x: auto; }
.admin-table input.form-control,
.admin-table select.form-control { padding: 7px 10px; font-size: 0.88rem; }
.admin-table td { vertical-align: middle; }
.admin-actions { display: flex; gap: 6px; white-space: nowrap; }

.tab-bar { display: flex; gap: 8px; margin-bottom: 20px; flex-wrap: wrap; }

.tab-btn {
  font-family: 'Teko', sans-serif;
  font-size: 1.25rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--red-soft);
  background: rgba(240, 112, 24, 0.10);
  border: 1px solid var(--border);
  clip-path: var(--cut-sm);
  padding: 8px 22px 5px;
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
}
.tab-btn:hover { color: var(--orange-hi); }
.tab-btn.active {
  color: #fff;
  background: linear-gradient(180deg, #c25a10, #b5500e);
  border-color: rgba(255, 154, 60, 0.5);
  box-shadow: 0 0 14px rgba(240, 112, 24, 0.5);
}

.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fadeIn 0.3s ease-out forwards; }

.status-badge {
  display: inline-block;
  font-family: 'Teko', sans-serif;
  font-size: 0.92rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 2px 12px;
  clip-path: var(--cut-sm);
  border: 1px solid;
}
.status-new      { color: var(--gold); border-color: rgba(245, 196, 81, 0.6); background: rgba(245, 196, 81, 0.12); }
.status-accepted { color: var(--green); border-color: rgba(91, 209, 127, 0.6); background: rgba(91, 209, 127, 0.12); }
.status-rejected { color: #ff8a8a; border-color: rgba(255, 138, 138, 0.6); background: rgba(255, 138, 138, 0.12); }

.login-card { max-width: 440px; margin: 80px auto; }
.login-card h2 {
  font-family: 'Teko', sans-serif;
  font-size: 2.3rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  text-align: center;
  color: #fff;
  text-shadow: 0 0 16px rgba(240, 112, 24, 0.8);
  margin-bottom: 18px;
}

.hidden { display: none !important; }

.loading-row td { text-align: center; color: var(--text-dim); padding: 30px !important; }

.pulse-dot {
  display: inline-block;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px #28a745;
  margin-right: 6px;
  animation: dotPulse 2s ease-in-out infinite;
}
@keyframes dotPulse { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.4; transform: scale(0.8); } }

/* ---------- Живое обновление очков ---------- */

.rating-cell { position: relative; }

/* число во время «докрутки» */
.live-num.ticking {
  color: #fff;
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.7), 0 0 18px rgba(240, 112, 24, 0.6);
}

/* вспышка строки (через inset-тень на ячейках — не конфликтует с фоном) */
tr.live-flash td { animation: liveFlashUp 1.6s ease-out; }
tr.live-flash-down td { animation: liveFlashDown 1.6s ease-out; }
@keyframes liveFlashUp {
  0%   { box-shadow: inset 0 0 0 999px rgba(91, 209, 127, 0.28); }
  100% { box-shadow: inset 0 0 0 999px rgba(91, 209, 127, 0); }
}
@keyframes liveFlashDown {
  0%   { box-shadow: inset 0 0 0 999px rgba(240, 90, 90, 0.28); }
  100% { box-shadow: inset 0 0 0 999px rgba(240, 90, 90, 0); }
}

/* колонки Gain / Total Gain */
.gain-cell, .total-cell { white-space: nowrap; }
.gain-num, .total-num {
  display: inline-block;
  font-family: 'Teko', sans-serif;
  font-size: 1.3rem;
  letter-spacing: 0.5px;
  color: #5f8a6e; /* приглушённый зелёный для нуля */
}
.gain-num.up, .total-num.up {
  color: var(--green);
  text-shadow: 0 0 8px rgba(91, 209, 127, 0.55);
}
.gain-num.down, .total-num.down {
  color: #ff8a8a;
  text-shadow: 0 0 8px rgba(255, 120, 120, 0.55);
}
.total-num.up { font-weight: 600; }
.gain-num.pop { animation: gainPop 0.6s ease-out; }
@keyframes gainPop {
  0%   { transform: scale(1.6); }
  60%  { transform: scale(1); }
  100% { transform: scale(1); }
}

/* кнопка звука */
.sound-toggle {
  margin-left: 10px;
  background: rgba(240, 112, 24, 0.12);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0 8px;
  cursor: pointer;
  font-size: 0.95rem;
  line-height: 1.5;
  vertical-align: middle;
  transition: background 0.15s, opacity 0.15s;
}
.sound-toggle:hover { background: rgba(240, 112, 24, 0.28); }
.sound-toggle.muted { opacity: 0.55; }

.live-note-row { display: flex; align-items: center; flex-wrap: wrap; gap: 2px; justify-content: center !important; }

@media (prefers-reduced-motion: reduce) {
  tr.live-flash td, tr.live-flash-down td { animation: none; }
}

/* ---------- Таймер сезона ---------- */
.countdown-card {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 20px;
  padding: 14px 20px;
  background: linear-gradient(180deg, rgba(240,112,24,0.14), rgba(26,10,10,0.5));
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: inset 0 0 0 1px rgba(255,160,90,0.06);
}
.countdown-label {
  font-family: 'Teko', sans-serif;
  font-size: 1.25rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--orange-hi);
}
.countdown { display: flex; gap: 12px; }
.cd-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 56px;
  padding: 6px 8px;
  background: rgba(8,5,3,0.55);
  border: 1px solid var(--border-soft);
  border-radius: 8px;
}
.cd-unit b {
  font-family: 'Teko', sans-serif;
  font-size: 1.9rem;
  line-height: 1;
  color: #fff;
  text-shadow: 0 0 10px rgba(240,112,24,0.5);
}
.cd-unit span {
  font-family: 'Teko', sans-serif;
  font-size: 0.8rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* ---------- График роста репутации ---------- */
.chart-card { padding: 20px 22px 16px; }
.chart-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.chart-title {
  font-family: 'Teko', sans-serif;
  font-size: 1.5rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #fff;
}
.chart-title span { color: var(--orange-hi); }
.chart-latest {
  font-family: 'Teko', sans-serif;
  font-size: 1.4rem;
  color: var(--green);
  text-shadow: 0 0 8px rgba(91,209,127,0.4);
}
.chart-wrap { width: 100%; }
.rep-chart { display: block; width: 100%; height: auto; }
.chart-empty { text-align: center; color: var(--text-dim); padding: 30px 10px; font-size: 0.92rem; }

/* ---------- Top Gainers (ранкинг-список) ---------- */
.gainers-grid { display: flex; flex-direction: column; gap: 8px; }
.gainers-empty { text-align: center; color: var(--text-dim); padding: 24px 10px; font-size: 0.92rem; }
.gainer-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  background: rgba(26, 10, 10, 0.5);
  clip-path: var(--cut-sm);
  box-shadow: inset 0 0 0 1px var(--border-soft);
  transition: transform 0.15s, box-shadow 0.15s;
}
.gainer-row:nth-child(even) { background: rgba(42, 12, 10, 0.5); }
.gainer-row:hover { transform: translateX(4px); box-shadow: inset 0 0 0 1px var(--border), inset 3px 0 0 var(--orange); }
.gainer-row.top {
  background: linear-gradient(90deg, rgba(245, 196, 81, 0.14), rgba(26, 10, 10, 0.5) 62%);
  box-shadow: inset 0 0 0 1px rgba(245, 196, 81, 0.5);
}
.gainer-place {
  font-family: 'Teko', sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  min-width: 36px;
  text-align: center;
  color: var(--red-soft);
}
.gainer-ava {
  width: 42px; height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(240, 112, 24, 0.5);
  box-shadow: 0 0 8px rgba(240, 112, 24, 0.3);
  flex-shrink: 0;
}
.gainer-info { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.gainer-name { font-family: 'Baloo 2', cursive; font-weight: 600; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gainer-lvl { font-size: 0.8rem; color: var(--text-dim); }
.gainer-gain {
  font-family: 'Teko', sans-serif;
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1;
  color: var(--green);
  text-shadow: 0 0 10px rgba(91, 209, 127, 0.5);
  white-space: nowrap;
}
.gainer-gain small { font-size: 0.55em; color: var(--text-dim); margin-left: 4px; text-shadow: none; letter-spacing: 1px; text-transform: uppercase; }

/* ---------- Блог: список карточек ---------- */

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 22px;
}

.blog-empty {
  text-align: center;
  color: var(--text-dim);
  padding: 50px 20px;
  font-size: 1.05rem;
}

.blog-card {
  position: relative;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  background: linear-gradient(160deg, rgba(240, 112, 24, 0.38), rgba(60, 40, 20, 0.32));
  clip-path: var(--cut);
  filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.55));
  transition: transform 0.2s ease, filter 0.25s ease;
  overflow: hidden;
}
.blog-card::before {
  content: "";
  position: absolute;
  inset: 2px;
  z-index: 0;
  clip-path: var(--cut);
  background: linear-gradient(180deg, var(--bg-card-2), var(--bg-card));
}
.blog-card > * { position: relative; z-index: 1; }
.blog-card:hover {
  transform: translateY(-6px);
  filter: drop-shadow(0 14px 30px rgba(240, 112, 24, 0.35));
}

.blog-card-img {
  height: 172px;
  overflow: hidden;
  background: linear-gradient(135deg, #201509, #120c06);
}
.blog-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.blog-card:hover .blog-card-img img { transform: scale(1.07); }
/* заглушка, если картинки нет/не загрузилась */
.blog-card-img.no-img {
  display: flex;
  align-items: center;
  justify-content: center;
}
.blog-card-img.no-img img { display: none; }
.blog-card-img.no-img::after {
  content: "⚔";
  font-size: 3rem;
  color: rgba(240, 112, 24, 0.35);
}

.blog-card-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.blog-card-date {
  font-family: 'Teko', sans-serif;
  font-size: 0.95rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-dim);
}
.blog-card-title {
  font-family: 'Teko', sans-serif;
  font-size: 1.65rem;
  line-height: 1.05;
  letter-spacing: 0.5px;
  color: #fff;
}
.blog-card:hover .blog-card-title { color: var(--orange-hi); }
.blog-card-desc {
  font-size: 0.92rem;
  color: var(--text-dim);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}
.blog-card-more {
  font-family: 'Teko', sans-serif;
  font-size: 1.1rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--orange);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.blog-card-more .ic { width: 1em; height: 1em; }

/* ---------- Блог: страница поста ---------- */

.post { max-width: 820px; margin: 30px auto 24px; }

.post-cover {
  margin-bottom: 22px;
  clip-path: var(--cut);
  border: 1px solid var(--border);
  overflow: hidden;
  filter: drop-shadow(0 10px 26px rgba(0, 0, 0, 0.6));
}
.post-cover img { display: block; width: 100%; height: auto; }

.post-meta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Teko', sans-serif;
  font-size: 1.05rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 8px;
}
.post-meta .ic { width: 1.05em; height: 1.05em; color: var(--orange); }

.post-title {
  font-family: 'Teko', sans-serif;
  font-size: clamp(2.2rem, 6vw, 3.4rem);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: 1px;
  color: #fff;
  text-shadow: 0 0 18px rgba(240, 112, 24, 0.4);
  margin-bottom: 12px;
}
.post-lead {
  font-size: 1.12rem;
  color: var(--red-soft);
  border-left: 3px solid var(--orange);
  padding-left: 14px;
  margin-bottom: 22px;
}
.post-body { font-size: 1.02rem; color: var(--text); line-height: 1.75; }
.post-body p { margin-bottom: 16px; }

/* ---------- Экран загрузки ---------- */

#loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 26px;
  background:
    radial-gradient(ellipse at 50% 42%, #1b0f06 0%, #0b0704 68%);
  transition: opacity 0.55s ease, visibility 0.55s ease;
}
#loader::before {
  /* тлеющие угли на сплэше */
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(2px 2px at 30% 30%, rgba(255,122,26,0.5), transparent),
    radial-gradient(2px 2px at 70% 65%, rgba(255,122,26,0.4), transparent),
    radial-gradient(1px 1px at 50% 80%, rgba(255,154,60,0.5), transparent);
  animation: emberDrift 12s ease-in-out infinite alternate;
}
#loader.hide { opacity: 0; visibility: hidden; }

.loader-ring {
  position: relative;
  width: 160px;
  height: 160px;
  display: grid;
  place-items: center;
}
/* вращающееся оранжевое кольцо */
.loader-ring::before {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0 60%, var(--orange-hi) 82%, var(--orange) 100%);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 5px));
          mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 5px));
  animation: spin 1.1s linear infinite;
  filter: drop-shadow(0 0 8px rgba(240, 112, 24, 0.8));
}
@keyframes spin { to { transform: rotate(360deg); } }

.loader-emblem {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  animation: emblemPulse 1.6s ease-in-out infinite;
}
@keyframes emblemPulse {
  0%, 100% { filter: drop-shadow(0 0 12px rgba(240, 112, 24, 0.5)); transform: scale(1); }
  50%      { filter: drop-shadow(0 0 26px rgba(240, 112, 24, 0.9)); transform: scale(1.04); }
}

.loader-text {
  font-family: 'Teko', sans-serif;
  font-size: 1.5rem;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: var(--orange-hi);
  text-shadow: 0 0 12px rgba(240, 112, 24, 0.6);
  animation: textBlink 1.6s ease-in-out infinite;
}
@keyframes textBlink { 0%,100% { opacity: 0.55; } 50% { opacity: 1; } }

.loader-bar {
  position: relative;
  width: 230px;
  height: 4px;
  background: rgba(240, 112, 24, 0.18);
  overflow: hidden;
  clip-path: var(--cut-sm);
}
.loader-bar span {
  position: absolute;
  left: -40%;
  width: 40%;
  height: 100%;
  background: linear-gradient(90deg, transparent, var(--orange-hi), transparent);
  box-shadow: 0 0 10px var(--orange);
  animation: barSweep 1.1s ease-in-out infinite;
}
@keyframes barSweep { to { left: 100%; } }

/* ---------- Адаптив ---------- */

@media (max-width: 640px) {
  .logo-name { font-size: 1.6rem; letter-spacing: 3px; }
  .logo-img { width: 42px; height: 42px; }
  .main-nav a { padding: 6px 10px; font-size: 1.05rem; }
  .content-card { padding: 16px; }
  .section-title { font-size: 2.1rem; }
  .section { margin-top: 44px; }
  .hero { margin-top: 16px; }
}

/* ---- Accounts / auth ---- */
.auth-main { max-width: 520px; margin: 0 auto; }
.auth-tabs { display: flex; gap: 8px; margin-bottom: 14px; }
.auth-tab { flex: 1; padding: 10px; background: rgba(42,12,10,0.5); color: var(--text-dim); border: 1px solid var(--border); border-radius: 8px; font-weight: 700; cursor: pointer; }
.auth-tab.active { color: #fff; border-color: var(--orange); box-shadow: inset 0 -2px 0 var(--orange); }
.auth-form label { display: block; margin: 10px 0 4px; font-weight: 600; color: var(--text-dim); }
.auth-form .btn { margin-top: 14px; width: 100%; }
.field-err, .form-err { color: #ff6b5e; font-size: 0.85rem; min-height: 1em; margin-top: 2px; }
.form-err { margin-top: 8px; }
.pf-sep { border: none; border-top: 1px solid var(--border); margin: 16px 0; }
.text-dim { color: var(--text-dim); }
.chip-row { display: inline-flex; flex-wrap: wrap; gap: 6px; vertical-align: middle; }
.role-chip { display: inline-flex; align-items: center; padding: 2px 10px; border-radius: 999px; font-size: 0.78rem; font-weight: 700; color: #fff; background: var(--chip, #8a8a8a); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.15); }

/* ---- Header auth control ---- */
.header-auth { display: flex; align-items: center; margin-left: 14px; }
.header-login { color: var(--orange-hi); font-weight: 700; text-decoration: none; }
.header-login:hover { text-shadow: 0 0 10px rgba(255,154,60,0.7); }
.header-user { display: flex; align-items: center; gap: 8px; }
.header-user-name { color: #fff; font-weight: 700; text-decoration: none; }
.header-logout { background: transparent; border: 1px solid var(--border); color: var(--text-dim); border-radius: 6px; padding: 2px 8px; cursor: pointer; }
.header-logout:hover { color: #fff; border-color: var(--orange); }

.chip-wrap { display: inline-flex; align-items: center; gap: 2px; }
.chip-x { background: transparent; border: none; color: var(--text-dim); cursor: pointer; font-size: 1rem; line-height: 1; padding: 0 2px; }
.chip-x:hover { color: #ff6b5e; }
