/* JopaSlona site chrome */

:root {
  --site-accent: #d43e14;
  --site-sand: #fcd48a;
  --site-ink: #051f45;
  --site-dust: #a45c5c;
  --site-cream: #d0d0b4;
  --site-slate: #314354;
  --site-forest: #051f45;
  --site-forest-mid: #0a2a56;
  --site-moss: #314354;
  --site-leaf: #d43e14;
  --site-gold: #fcd48a;
  --site-muted: rgba(208, 208, 180, 0.72);
  --site-chrome-h: 110px;
  --site-ip-h: 38px;
  --site-nav-h: 72px;
  --site-font-display: "Segoe UI", "Trebuchet MS", sans-serif;
  --site-font-body: "Segoe UI", "Trebuchet MS", sans-serif;
  --site-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --site-fade: 180ms var(--site-ease);
}

body.site-page {
  margin: 0;
  font-family: var(--site-font-body);
  color: var(--site-cream);
  background-color: var(--site-ink);
  background-image:
    radial-gradient(900px 420px at 85% -8%, rgba(212, 62, 20, 0.16), transparent 55%),
    radial-gradient(720px 340px at 0% 18%, rgba(252, 212, 138, 0.09), transparent 50%),
    linear-gradient(180deg, #0a2a56 0%, #051f45 42%, #071a38 100%);
  background-attachment: fixed;
  overflow-x: hidden;
  min-height: 100%;
}

html {
  overflow-x: hidden;
  max-width: 100%;
}

/* Текст для поисковиков: в начале документа, не clip (Яндекс clip часто игнорирует) */
.site-seo {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  max-width: 100%;
  padding: 8px 12px;
  box-sizing: border-box;
  z-index: 0;
  overflow: hidden;
  height: 1px;
  opacity: 0.01;
  pointer-events: none;
  color: var(--site-cream);
  font-size: 14px;
  line-height: 1.4;
}

.site-seo h1 {
  margin: 0 0 4px;
  font-size: 16px;
}

.site-seo p {
  margin: 0;
}

.site-seo a {
  color: inherit;
}

body.site-page--map {
  overflow: hidden;
  height: 100%;
}

html:has(body.site-page--map),
body.site-page--map {
  height: 100%;
  max-height: 100%;
}

/* Map lives strictly below the site chrome — never under the header */
body.site-page--map #map.map {
  position: fixed !important;
  top: var(--site-chrome-h) !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100% !important;
  height: auto !important;
  max-height: none !important;
  z-index: 1 !important;
}

/* Pl3xMap sizes controls to the viewport; bind them to the map box instead */
body.site-page--map .leaflet-control-container {
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
}

body.site-page--map #sidebar #sidebar__content {
  height: 100% !important;
  max-height: 100% !important;
}

body.site-page--map.map-ui-enhanced #sidebar #sidebar__content {
  height: fit-content !important;
  max-height: min(58vh, 520px) !important;
}

body.site-page--map .leaflet-control-attribution {
  background: rgba(5, 31, 69, 0.75) !important;
  color: rgba(208, 208, 180, 0.85) !important;
  font-size: 11px !important;
  padding: 2px 6px !important;
}

#site-chrome {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  max-width: 100vw;
  z-index: 10000;
  height: var(--site-chrome-h);
  max-height: var(--site-chrome-h);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
  pointer-events: none;
  background: var(--site-ink);
  isolation: isolate;
  transform: translateZ(0);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

#site-chrome > * {
  pointer-events: auto;
}

/* Override Pl3xMap global `button { ... }` styles */
#site-chrome button,
.site-ip-bar {
  appearance: none;
  -webkit-appearance: none;
  box-shadow: none;
  border-radius: 0;
  border: none;
  margin: 0;
  padding: 0;
  line-height: normal;
  font: inherit;
  color: inherit;
  background: transparent;
  width: auto;
  min-width: 0;
  min-height: 0;
  position: static;
  white-space: normal;
}

.site-ip-bar {
  flex: 0 0 var(--site-ip-h);
  width: 100%;
  height: var(--site-ip-h);
  max-height: var(--site-ip-h);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background:
    linear-gradient(90deg, rgba(252, 212, 138, 0.08), transparent 28%, transparent 72%, rgba(252, 212, 138, 0.08)),
    linear-gradient(90deg, #031633 0%, #0a2a56 38%, #3a4f63 50%, #0a2a56 62%, #031633 100%);
  border-bottom: 1px solid rgba(252, 212, 138, 0.38);
  cursor: pointer;
  user-select: none;
  transition: filter var(--site-fade), background var(--site-fade);
}

.site-ip-bar > svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  display: block;
  color: var(--site-sand);
  opacity: 0.9;
}

.site-ip-bar:hover {
  filter: brightness(1.08);
}

.site-ip-bar:active {
  filter: brightness(0.95);
}

.site-ip-bar__label {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--site-muted);
}

.site-ip-bar__ip {
  font-family: var(--site-font-display);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.04em;
  color: var(--site-sand);
}

.site-ip-bar__hint {
  font-size: 12px;
  color: rgba(208, 208, 180, 0.5);
}

.site-ip-bar__icon {
  width: 14px;
  height: 14px;
  opacity: 0.75;
  color: var(--site-sand);
}

.site-nav {
  flex: 0 0 var(--site-nav-h);
  height: var(--site-nav-h);
  max-height: var(--site-nav-h);
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  background:
    radial-gradient(900px 90px at 12% 0%, rgba(212, 62, 20, 0.16), transparent 58%),
    radial-gradient(700px 80px at 88% 100%, rgba(252, 212, 138, 0.08), transparent 55%),
    linear-gradient(180deg, #3a4f63 0%, #243647 48%, #0c2244 100%);
  border-bottom: 1px solid rgba(252, 212, 138, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.site-nav__inner {
  width: 100%;
  max-width: 1400px;
  height: 100%;
  margin: 0 auto;
  padding: 0 22px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.site-nav__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--site-cream);
  flex: 0 0 auto;
  transition: opacity var(--site-fade), color var(--site-fade);
}

.site-nav__brand:hover {
  opacity: 1;
  color: var(--site-sand);
}

.site-nav__mark {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(145deg, #4a6176, #243647);
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(252, 212, 138, 0.45);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    0 6px 14px rgba(0, 0, 0, 0.28);
  image-rendering: pixelated;
  flex-shrink: 0;
}

.site-nav__mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.site-nav__mark svg {
  width: 20px;
  height: 20px;
}

.site-nav__name {
  font-family: var(--site-font-display);
  font-weight: 750;
  font-size: 17px;
  letter-spacing: 0.01em;
}

.site-nav__links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
}

.site-nav__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  min-height: 44px;
  border-radius: 11px;
  text-decoration: none;
  color: var(--site-muted);
  font-size: 14px;
  font-weight: 650;
  white-space: nowrap;
  border: 1px solid transparent;
  transition: color var(--site-fade), background var(--site-fade), border-color var(--site-fade), transform var(--site-fade), box-shadow var(--site-fade);
}

.site-nav__link svg {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  opacity: 0.9;
}

.site-nav__link:hover {
  color: var(--site-cream);
  background: rgba(252, 212, 138, 0.1);
  border-color: rgba(252, 212, 138, 0.18);
}

.site-nav__link.is-active {
  color: #fff8f0;
  background: linear-gradient(180deg, rgba(226, 74, 28, 0.42), rgba(212, 62, 20, 0.22));
  border-color: rgba(252, 212, 138, 0.35);
  box-shadow: 0 6px 16px rgba(212, 62, 20, 0.18);
}

.site-nav__link--ideas {
  color: #f5d76e;
  border-color: rgba(245, 215, 110, 0.4);
  background: linear-gradient(180deg, rgba(212, 62, 20, 0.28), rgba(245, 215, 110, 0.12));
  box-shadow: inset 0 0 0 1px rgba(245, 215, 110, 0.12);
  font-weight: 700;
}

.site-nav__link--ideas:hover,
.site-nav__link--ideas.is-active {
  color: #fff4c8;
  background: linear-gradient(180deg, rgba(212, 62, 20, 0.42), rgba(245, 215, 110, 0.2));
  border-color: rgba(245, 215, 110, 0.7);
}

.site-nav__link--with-badge {
  position: relative;
}

.site-nav__badge {
  position: absolute;
  top: -4px;
  right: -4px;
  z-index: 2;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  border: 1px solid rgba(252, 212, 138, 0.55);
  background: linear-gradient(180deg, #e25a2e, #d43e14);
  color: #fff8ec;
  font-size: 11px;
  font-weight: 800;
  line-height: 16px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 4px 10px rgba(212, 62, 20, 0.45);
  pointer-events: none;
}

.site-nav__badge[hidden] {
  display: none !important;
}

.site-nav__auth {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  min-width: 0;
}

.site-nav__donate {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 42px;
  padding: 8px 16px;
  border-radius: 11px;
  text-decoration: none;
  color: #3a2a08;
  font-size: 14px;
  font-weight: 750;
  white-space: nowrap;
  border: 1px solid rgba(255, 236, 170, 0.85);
  background: linear-gradient(180deg, #ffe7a0 0%, #f0c14b 42%, #d4a017 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    0 6px 16px rgba(212, 160, 30, 0.35);
  transition: filter var(--site-fade), transform 120ms var(--site-ease), box-shadow var(--site-fade);
}

.site-nav__donate > svg,
.site-nav__donate > span:not(.site-nav__donate-coins) {
  position: relative;
  z-index: 2;
}

.site-nav__donate > svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.site-nav__donate:hover {
  filter: brightness(1.06);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.6),
    0 8px 20px rgba(212, 160, 30, 0.45);
}

.site-nav__donate:active {
  transform: translateY(1px);
}

.site-nav__donate.is-active {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    0 0 0 2px rgba(252, 212, 138, 0.45),
    0 8px 20px rgba(212, 160, 30, 0.4);
}

.site-nav__donate-coins {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.site-nav__donate-coins i {
  position: absolute;
  top: -14px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 30% 30%, #fff6c8, #f0c14b 45%, #b8860b 78%, #8a6508 100%);
  box-shadow:
    inset 0 -1px 0 rgba(0, 0, 0, 0.25),
    0 0 0 1px rgba(140, 100, 20, 0.35);
  opacity: 0;
  animation: siteDonateCoinFall 2.4s linear infinite;
}

.site-nav__donate-coins i:nth-child(1) {
  left: 12%;
  animation-delay: 0s;
  animation-duration: 2.1s;
}

.site-nav__donate-coins i:nth-child(2) {
  left: 28%;
  width: 8px;
  height: 8px;
  animation-delay: 0.45s;
  animation-duration: 2.5s;
}

.site-nav__donate-coins i:nth-child(3) {
  left: 46%;
  animation-delay: 0.9s;
  animation-duration: 2.2s;
}

.site-nav__donate-coins i:nth-child(4) {
  left: 62%;
  width: 9px;
  height: 9px;
  animation-delay: 0.2s;
  animation-duration: 2.7s;
}

.site-nav__donate-coins i:nth-child(5) {
  left: 78%;
  width: 7px;
  height: 7px;
  animation-delay: 1.15s;
  animation-duration: 2.3s;
}

.site-nav__donate-coins i:nth-child(6) {
  left: 88%;
  animation-delay: 1.55s;
  animation-duration: 2.6s;
}

@keyframes siteDonateCoinFall {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 0;
  }
  12% {
    opacity: 0.95;
  }
  80% {
    opacity: 0.85;
  }
  100% {
    transform: translateY(56px) rotate(220deg);
    opacity: 0;
  }
}

.site-nav__balance {
  font-weight: 700;
  font-size: 13px;
  color: var(--site-sand);
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(252, 212, 138, 0.12);
  border: 1px solid rgba(252, 212, 138, 0.28);
  display: none;
}

.site-nav__balance.is-visible {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.site-nav__user {
  font-size: 13px;
  color: var(--site-muted);
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-btn {
  appearance: none !important;
  -webkit-appearance: none !important;
  box-shadow: none !important;
  border: 1px solid rgba(212, 62, 20, 0.55) !important;
  background: linear-gradient(180deg, #e24a1c, #b83410) !important;
  color: #fff8f0 !important;
  font: inherit !important;
  font-weight: 650 !important;
  font-size: 13px !important;
  line-height: 1.2 !important;
  padding: 8px 14px !important;
  min-height: 40px !important;
  border-radius: 10px !important;
  cursor: pointer;
  display: inline-flex !important;
  align-items: center;
  gap: 7px;
  width: auto !important;
  height: auto !important;
  min-width: 0 !important;
  position: relative;
  white-space: nowrap;
  transition: filter var(--site-fade), transform 120ms var(--site-ease), background var(--site-fade);
}

.site-btn > svg {
  position: static !important;
  width: 15px !important;
  height: 15px !important;
  margin: 0 !important;
  flex-shrink: 0;
}

.site-btn:hover {
  filter: brightness(1.08);
}

.site-btn:active {
  transform: translateY(1px);
}

.site-btn.is-hidden,
#site-login-btn.is-hidden,
#site-logout-btn.is-hidden {
  display: none !important;
}

.site-btn--ghost {
  background: transparent !important;
  border-color: rgba(208, 208, 180, 0.28) !important;
  color: var(--site-muted) !important;
}

.site-btn--ghost:hover {
  color: var(--site-cream);
  background: rgba(252, 212, 138, 0.08);
  filter: none;
}

.site-toast {
  position: fixed;
  top: calc(var(--site-chrome-h) + 14px);
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  z-index: 10050;
  background: rgba(49, 67, 84, 0.96);
  color: var(--site-cream);
  border: 1px solid rgba(252, 212, 138, 0.45);
  padding: 10px 16px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  box-shadow: 0 10px 30px rgba(5, 31, 69, 0.45);
}

.site-toast.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Login modal (shared) */
.site-login-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10100;
  background: rgba(5, 31, 69, 0.78);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.site-login-backdrop.is-open {
  display: flex;
}

.site-login-modal {
  width: min(380px, 100%);
  background: linear-gradient(180deg, #314354, #051f45);
  border: 1px solid rgba(252, 212, 138, 0.28);
  border-radius: 16px;
  padding: 22px;
  box-shadow: 0 24px 60px rgba(5, 31, 69, 0.55);
}

.site-login-modal h2 {
  margin: 0 0 6px;
  font-size: 20px;
}

.site-login-modal p.site-login-lead {
  margin: 0 0 16px;
  color: var(--site-muted);
  font-size: 13px;
}

.site-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.site-field label {
  font-size: 12px;
  color: var(--site-muted);
}

.site-field input {
  border-radius: 10px;
  border: 1px solid rgba(232, 240, 228, 0.18);
  background: rgba(0, 0, 0, 0.28);
  color: var(--site-cream);
  padding: 10px 12px;
  font: inherit;
}

.site-field input:focus {
  outline: 1px solid rgba(107, 191, 110, 0.55);
  border-color: rgba(107, 191, 110, 0.55);
}

.site-login-error {
  color: #ff8f8f;
  min-height: 1.2em;
  font-size: 13px;
  margin: 0 0 10px;
}

.site-login-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

/* Content pages */
.site-main {
  padding: calc(var(--site-chrome-h) + 28px) 20px 48px;
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
  min-height: 100vh;
  box-sizing: border-box;
  background: transparent;
}

.site-hero {
  margin-bottom: 28px;
}

.site-hero--server {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1.2rem 1.6rem;
  align-items: center;
  margin-bottom: 2rem;
  padding: 1.35rem 1.25rem;
  border-radius: 18px;
  border: 1px solid rgba(252, 212, 138, 0.18);
  background:
    radial-gradient(700px 220px at 92% 12%, rgba(212, 62, 20, 0.16), transparent 58%),
    radial-gradient(520px 180px at 8% 90%, rgba(252, 212, 138, 0.1), transparent 55%),
    rgba(5, 28, 48, 0.55);
}

.site-hero__copy {
  min-width: 0;
}

.site-hero__art {
  width: min(260px, 36vw);
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 12px 20px rgba(0, 0, 0, 0.4));
  justify-self: end;
}

.site-hero__brand {
  margin: 0 0 6px !important;
  font-family: var(--site-font-display);
  font-size: clamp(28px, 5vw, 44px) !important;
  font-weight: 750;
  letter-spacing: -0.03em;
  color: var(--site-cream) !important;
  line-height: 1.1;
  max-width: none !important;
}

.site-hero h1 {
  margin: 0 0 8px;
  font-family: var(--site-font-display);
  font-size: clamp(22px, 3.2vw, 30px);
  letter-spacing: -0.02em;
  font-weight: 650;
}

.site-hero p {
  margin: 0;
  max-width: 54ch;
  color: var(--site-muted);
  font-size: 15px;
  line-height: 1.5;
}

.site-hero__ip {
  margin-top: 14px !important;
  font-size: 14px !important;
}

.site-hero__ip strong {
  color: var(--site-sand);
  font-weight: 700;
}

.site-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.site-features {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px 22px;
  margin: 8px 0 36px;
}

.site-features__center-row {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  gap: 18px 22px;
  width: min(100%, calc((100% - 44px) * 2 / 3 + 22px));
  justify-self: center;
  margin-inline: auto;
}

.site-feature {
  padding-top: 14px;
  border-top: 1px solid rgba(232, 240, 228, 0.1);
}

.site-feature h2 {
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 650;
}

.site-feature p {
  margin: 0;
  color: var(--site-muted);
  line-height: 1.55;
  font-size: 14px;
}

.site-stream {
  margin: 10px 0 36px;
  padding: 18px 0 4px;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.site-stream::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 55% 40% at 50% 35%, rgba(212, 62, 20, 0.14), transparent 70%),
    radial-gradient(ellipse 45% 35% at 50% 70%, rgba(252, 212, 138, 0.08), transparent 70%);
  opacity: 0.95;
}

.site-stream__head {
  position: relative;
  width: min(50vw, 920px);
  max-width: 100%;
  margin: 0 auto 18px;
  text-align: center;
}

.site-stream__brand {
  margin: 0 0 6px;
  font-family: var(--site-font-display);
  font-size: clamp(26px, 4.2vw, 38px);
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--site-cream);
}

.site-stream h2 {
  margin: 0 0 10px;
  font-family: var(--site-font-display);
  font-size: clamp(20px, 2.8vw, 26px);
  font-weight: 650;
  letter-spacing: -0.02em;
}

.site-stream__lead {
  margin: 0 auto;
  max-width: 52ch;
  color: var(--site-muted);
  font-size: 15px;
  line-height: 1.55;
}

.site-stream__lead strong {
  color: var(--site-sand);
  font-weight: 650;
}

.site-stream__player-shell {
  position: relative;
  width: min(50vw, 920px);
  max-width: 100%;
  margin: 0 auto 20px;
  z-index: 1;
}

.site-stream__player-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: transparent;
  filter: drop-shadow(0 16px 36px rgba(0, 0, 0, 0.45));
}

.site-stream__player-inner {
  position: absolute;
  z-index: 1;
  inset: 12% 10% 13% 10%;
  overflow: hidden;
  background: #031633;
  border-radius: 2px;
}

.site-stream__player {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #031633;
}

.site-stream__frame {
  position: absolute;
  z-index: 2;
  inset: 0;
  pointer-events: none;
  background: url("images/stream-player-frame.png") center / 100% 100% no-repeat;
}

.site-stream__side {
  position: relative;
  z-index: 1;
  width: min(50vw, 920px);
  max-width: 100%;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 18px 24px;
  align-items: start;
}

.site-stream__steps {
  margin: 0;
  padding-left: 1.2em;
  color: var(--site-muted);
  font-size: 14px;
  line-height: 1.65;
  text-align: left;
}

.site-stream__steps li + li {
  margin-top: 10px;
}

.site-stream__steps strong {
  color: var(--site-sand);
}

.site-stream__cmd {
  display: inline-block;
  margin: 0 2px;
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid rgba(252, 212, 138, 0.35);
  background: rgba(212, 62, 20, 0.14);
  color: var(--site-sand);
  font-family: ui-monospace, "Cascadia Code", "Consolas", monospace;
  font-size: 0.92em;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.site-stream__hint {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: rgba(208, 208, 180, 0.55);
}

.site-stream__perks {
  display: grid;
  gap: 12px;
}

.site-stream__perk {
  padding-top: 12px;
  border-top: 1px solid rgba(232, 240, 228, 0.1);
}

.site-stream__perk h3 {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 650;
  color: var(--site-cream);
}

.site-stream__perk p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--site-muted);
}

.site-stream__perk strong {
  color: var(--site-sand);
}

.site-stream__twitch {
  justify-self: start;
  text-decoration: none;
  margin-top: 4px;
}

@media (max-width: 900px) {
  .site-stream__head,
  .site-stream__player-shell,
  .site-stream__side {
    width: 100%;
  }

  .site-stream__side {
    grid-template-columns: 1fr;
  }

  .site-stream__player-inner {
    inset: 12.5% 10.5% 13.5% 10.5%;
  }
}

@media (max-width: 560px) {
  .site-stream__player-inner {
    inset: 13.5% 11.5% 14.5% 11.5%;
  }
}

.site-join {
  padding-top: 8px;
  border-top: 1px solid rgba(232, 240, 228, 0.12);
}

.site-join h2 {
  margin: 0 0 12px;
  font-size: 22px;
}

.site-join__steps {
  margin: 0 0 14px;
  padding-left: 1.2em;
  color: var(--site-muted);
  line-height: 1.65;
  font-size: 14px;
}

.site-join__steps strong {
  color: var(--site-sand);
}

.site-join a {
  color: var(--site-accent);
}

.site-join p {
  margin: 0;
  color: var(--site-muted);
  font-size: 14px;
  line-height: 1.55;
}

.site-rules {
  display: grid;
  gap: 18px;
}

.site-rule {
  padding: 18px 0;
  border-top: 1px solid rgba(232, 240, 228, 0.1);
}

.site-rule:first-child {
  border-top: none;
  padding-top: 0;
}

.site-rule__num {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--site-sand);
  margin-bottom: 6px;
}

.site-rule h2 {
  margin: 0 0 8px;
  font-size: 20px;
}

.site-rule p {
  margin: 0;
  color: var(--site-muted);
  line-height: 1.55;
  font-size: 14px;
}

.site-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 8px 0 32px;
}

.site-gallery__item {
  margin: 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(252, 212, 138, 0.2);
  background: rgba(49, 67, 84, 0.45);
  opacity: 0;
  transform: translateY(10px);
  animation: siteFadeUp 0.55s var(--site-ease) forwards;
}

.site-gallery__item:nth-child(2) { animation-delay: 0.08s; }
.site-gallery__item:nth-child(3) { animation-delay: 0.16s; }

.site-gallery__item img {
  display: block;
  width: 100%;
  height: 160px;
  object-fit: cover;
  transition: transform 0.45s var(--site-ease);
}

.site-gallery__item:hover img {
  transform: scale(1.03);
}

.site-gallery figcaption {
  padding: 8px 10px 10px;
  font-size: 12px;
  color: var(--site-muted);
  line-height: 1.35;
}

@keyframes siteFadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-gallery__item,
  .site-feature,
  .site-hero {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}

@media (max-width: 1100px) {
  .site-nav__inner {
    gap: 12px;
    padding: 0 14px;
  }

  .site-nav__link {
    padding: 9px 10px;
    font-size: 13px;
    gap: 6px;
  }

  .site-nav__user {
    max-width: 96px;
  }
}

@media (max-width: 820px) {
  :root {
    --site-chrome-h: 92px;
    --site-ip-h: 34px;
    --site-nav-h: 58px;
  }

  .site-nav__inner {
    padding: 0 10px;
    gap: 8px;
  }

  .site-nav__name {
    display: none;
  }

  .site-nav__mark {
    width: 32px;
    height: 32px;
    border-radius: 8px;
  }

  .site-nav__links {
    justify-content: space-evenly;
    gap: 2px;
    overflow: hidden;
  }

  .site-nav__link span {
    display: none;
  }

  .site-nav__link {
    flex: 1 1 0;
    min-width: 0;
    max-width: 48px;
    padding: 8px 4px;
    min-height: 42px;
  }

  .site-nav__link svg {
    width: 18px;
    height: 18px;
  }

  .site-nav__auth {
    gap: 6px;
  }

  .site-nav__donate {
    min-width: 42px;
    width: 42px;
    padding: 8px;
    gap: 0;
  }

  .site-nav__donate > span:not(.site-nav__donate-coins) {
    display: none;
  }

  .site-nav__user,
  .site-nav__balance {
    display: none !important;
  }

  #site-login-btn span,
  #site-logout-btn span {
    display: none;
  }

  .site-btn#site-login-btn,
  .site-btn#site-logout-btn {
    min-width: 40px !important;
    width: 40px !important;
    padding: 8px !important;
    justify-content: center;
  }

  .site-ip-bar {
    gap: 8px;
    padding: 0 10px;
  }

  .site-ip-bar__hint,
  .site-ip-bar__label {
    display: none;
  }

  .site-main {
    padding-left: 14px;
    padding-right: 14px;
    padding-bottom: 40px;
    max-width: 100%;
  }

  .site-gallery {
    grid-template-columns: 1fr;
  }

  .site-gallery__item img {
    height: 180px;
  }

  .site-features {
    grid-template-columns: 1fr;
  }

  .site-features__center-row {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .site-cta {
    width: 100%;
  }

  .site-cta .site-btn {
    flex: 1;
    justify-content: center;
  }
}

/* Cookie consent banner — compact bottom bar */
.site-cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 12000;
  display: flex;
  justify-content: center;
  padding: 0 14px calc(14px + env(safe-area-inset-bottom, 0px));
  pointer-events: none;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 200ms var(--site-ease), transform 200ms var(--site-ease);
}

.site-cookie-banner.is-visible {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.site-cookie-banner__inner {
  width: 100%;
  max-width: 520px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(252, 212, 138, 0.28);
  background: rgba(5, 31, 69, 0.96);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
}

.site-cookie-banner__text {
  margin: 0;
  font-size: 0.86rem;
  line-height: 1.45;
  color: var(--site-cream);
}

.site-cookie-banner__text a {
  color: var(--site-sand);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.site-cookie-banner__actions {
  display: flex;
  gap: 0.55rem;
  justify-content: flex-end;
}

.site-cookie-banner__actions .site-btn {
  min-height: 36px;
  padding: 0.35rem 0.85rem;
  font-size: 0.86rem;
}

@media (max-width: 480px) {
  .site-cookie-banner__actions {
    flex-direction: column-reverse;
  }

  .site-cookie-banner__actions .site-btn {
    width: 100%;
    justify-content: center;
  }
}

/* ——— Map UI enhancements ——— */

/* Hide legacy Pl3xMap chrome immediately (before map-ui.js) to avoid FOUC */
body.site-page--map .leaflet-control-zoom {
  display: none !important;
}

body.site-page--map #sidebar {
  visibility: hidden;
  pointer-events: none;
}

body.site-page--map.map-ui-enhanced #sidebar {
  visibility: visible;
}

body.map-ui-enhanced #sidebar__buttons button[aria-controls="sidebar__layers"],
body.map-ui-enhanced #sidebar__buttons button[aria-controls="sidebar__worlds"],
body.map-ui-enhanced #sidebar__layers {
  display: none !important;
}

/* Keep world radios in DOM (display:none / [hidden] breaks .click() on mobile) */
body.map-ui-enhanced #sidebar__worlds,
body.map-ui-enhanced #sidebar__worlds[hidden] {
  position: fixed !important;
  left: -10000px !important;
  top: 0 !important;
  width: 240px !important;
  height: auto !important;
  max-height: none !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  opacity: 0 !important;
  display: block !important;
  visibility: visible !important;
  pointer-events: none !important;
  z-index: -1 !important;
}

body.map-ui-enhanced #sidebar {
  transform: none !important;
  margin: 0 !important;
  pointer-events: none;
  height: auto !important;
  max-height: none !important;
}

body.map-ui-enhanced #sidebar > * {
  pointer-events: auto;
}

body.map-ui-enhanced #sidebar__buttons {
  display: none;
  grid-gap: 0;
}

body.map-ui-enhanced #sidebar__content,
body.site-page--map.map-ui-enhanced #sidebar #sidebar__content {
  position: relative !important;
  top: 0 !important;
  left: 0 !important;
  width: min(300px, calc(100vw - 28px)) !important;
  height: fit-content !important;
  max-height: min(58vh, 520px) !important;
  padding: 0.75rem 0.85rem !important;
  margin: 0 0 0 auto;
  border-radius: 14px !important;
  border: 1px solid rgba(252, 212, 138, 0.28);
  background: linear-gradient(165deg, rgba(8, 34, 70, 0.94), rgba(5, 22, 48, 0.96)) !important;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.45);
  color: rgba(245, 236, 214, 0.92);
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

body.map-ui-enhanced #sidebar__content h2 {
  margin: 0 0 0.55rem;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  color: var(--site-sand);
}

body.map-ui-enhanced #sidebar__players {
  display: block !important;
}

body.map-ui-enhanced #sidebar__players > p[hidden],
body.map-ui-enhanced #sidebar__players > p[aria-hidden="true"] {
  display: none !important;
  margin: 0 !important;
  height: 0 !important;
}

body.map-ui-enhanced #sidebar__players .menu {
  border: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  min-height: 0;
}

body.map-ui-enhanced #sidebar__players .menu input.players {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

body.map-ui-enhanced #sidebar__players .menu input.players + label,
body.map-ui-enhanced .map-player-chip {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem;
  width: 100%;
  min-height: 40px;
  margin: 0 !important;
  padding: 0.3rem 0.5rem 0.3rem 42px !important;
  border-radius: 10px !important;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background-color: rgba(255, 255, 255, 0.06) !important;
  background-repeat: no-repeat;
  background-size: 28px 28px;
  background-position: 8px center;
  color: rgba(245, 236, 214, 0.95) !important;
  font-weight: 600;
  font-size: 1.15rem;
  line-height: 1.2;
  box-sizing: border-box;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

body.map-ui-enhanced #sidebar__players .menu input.players:checked + label {
  background-color: rgba(212, 62, 20, 0.22) !important;
  border-color: rgba(252, 212, 138, 0.55);
}

.map-player-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
  flex: 1;
}

.map-player-time {
  flex: 0 0 auto;
  font-variant-numeric: tabular-nums;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--site-sand);
  opacity: 0.95;
}

body.map-ui-enhanced .map-tier-5 {
  border-color: rgba(120, 180, 255, 0.55) !important;
  box-shadow: inset 0 0 0 1px rgba(120, 180, 255, 0.25);
}
body.map-ui-enhanced .map-tier-10 {
  border-color: rgba(90, 220, 170, 0.6) !important;
  box-shadow: inset 0 0 0 1px rgba(90, 220, 170, 0.28);
}
body.map-ui-enhanced .map-tier-20 {
  border-color: rgba(252, 212, 138, 0.7) !important;
  box-shadow: 0 0 0 1px rgba(252, 212, 138, 0.25), inset 0 0 12px rgba(252, 212, 138, 0.08);
}
body.map-ui-enhanced .map-tier-30 {
  border-color: rgba(255, 170, 70, 0.75) !important;
  box-shadow: 0 0 0 1px rgba(255, 170, 70, 0.3), inset 0 0 14px rgba(255, 140, 40, 0.1);
}
body.map-ui-enhanced .map-tier-40 {
  border-color: rgba(255, 110, 90, 0.8) !important;
  box-shadow: 0 0 0 1px rgba(255, 110, 90, 0.35), inset 0 0 16px rgba(212, 62, 20, 0.12);
}
body.map-ui-enhanced .map-tier-50 {
  border-color: rgba(220, 120, 255, 0.8) !important;
  box-shadow: 0 0 10px rgba(180, 80, 255, 0.25), inset 0 0 16px rgba(180, 80, 255, 0.12);
}
body.map-ui-enhanced .map-tier-100 {
  border-image: linear-gradient(120deg, #fcd48a, #d43e14, #7ad8ff, #fcd48a) 1;
  border-width: 2px !important;
  border-style: solid !important;
  box-shadow: 0 0 14px rgba(252, 212, 138, 0.35), inset 0 0 18px rgba(212, 62, 20, 0.15);
}

.map-ui-dock {
  position: fixed;
  top: calc(var(--site-chrome-h, 96px) + 12px);
  right: 12px;
  z-index: 9000;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  pointer-events: none;
  max-width: min(320px, calc(100vw - 24px));
}

.map-ui-dock > * {
  pointer-events: auto;
}

.map-worlds-bar {
  position: relative;
  top: auto;
  right: auto;
  z-index: 1;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.45rem;
  padding: 0.4rem 0.45rem;
  border-radius: 14px;
  border: 1px solid rgba(252, 212, 138, 0.3);
  background: linear-gradient(165deg, rgba(8, 34, 70, 0.94), rgba(5, 22, 48, 0.96));
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4);
  pointer-events: auto;
  touch-action: manipulation;
}

.map-worlds-bar__btn {
  appearance: none;
  -webkit-appearance: none;
  width: 42px;
  height: 42px;
  margin: 0;
  padding: 0;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background-color: rgba(255, 255, 255, 0.06);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  cursor: pointer;
  touch-action: manipulation;
  transition: transform 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

.map-ui-dock .map-worlds-bar__btn,
.map-ui-dock .map-players-toggle {
  /* Beat Pl3xMap global `button { ... }` rules from styles.css */
  display: grid !important;
  width: 42px !important;
  height: 42px !important;
  min-width: 42px !important;
  min-height: 42px !important;
  padding: 0 !important;
  line-height: 1 !important;
  white-space: normal !important;
}

.map-ui-dock .map-players-toggle {
  width: 48px !important;
  height: 48px !important;
  min-width: 48px !important;
  min-height: 48px !important;
  place-items: center;
}

.map-worlds-bar__btn:hover {
  border-color: rgba(252, 212, 138, 0.55);
  background-color: rgba(255, 255, 255, 0.12) !important;
}

.map-worlds-bar__btn.is-active {
  border-color: var(--site-sand) !important;
  box-shadow: 0 0 0 2px rgba(212, 62, 20, 0.45) !important;
  background-color: rgba(212, 62, 20, 0.2) !important;
}

.map-ui-dock .map-worlds-bar__btn:hover,
.map-ui-dock .map-players-toggle:hover {
  transform: none !important;
  background-color: rgba(255, 255, 255, 0.12) !important;
  color: #ffe3a8 !important;
}

.map-players-toggle {
  appearance: none;
  -webkit-appearance: none;
  position: relative;
  width: 48px;
  height: 48px;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(252, 212, 138, 0.35);
  border-radius: 14px;
  background:
    radial-gradient(circle at 30% 25%, rgba(252, 212, 138, 0.22), transparent 55%),
    linear-gradient(165deg, rgba(12, 42, 84, 0.96), rgba(5, 22, 48, 0.98));
  box-shadow:
    0 10px 26px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  color: var(--site-sand);
  cursor: pointer;
  display: grid;
  place-items: center;
  touch-action: manipulation;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease, color 160ms ease;
}

.map-players-toggle__glow {
  position: absolute;
  inset: 3px;
  border-radius: 11px;
  background: radial-gradient(circle at 50% 40%, rgba(212, 62, 20, 0.2), transparent 70%);
  opacity: 0;
  transition: opacity 160ms ease;
  pointer-events: none;
}

.map-players-toggle__icon {
  width: 24px;
  height: 24px;
  position: relative;
  z-index: 1;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.35));
}

.map-players-toggle__badge {
  position: absolute;
  top: -5px;
  right: -5px;
  z-index: 2;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  border: 1px solid rgba(252, 212, 138, 0.55);
  background: linear-gradient(180deg, #e25a2e, #d43e14);
  color: #fff8ec;
  font-size: 11px;
  font-weight: 800;
  line-height: 16px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 4px 10px rgba(212, 62, 20, 0.45);
}

.map-players-toggle:hover {
  border-color: rgba(252, 212, 138, 0.7);
  color: #ffe3a8;
  background:
    radial-gradient(circle at 30% 25%, rgba(252, 212, 138, 0.28), transparent 55%),
    linear-gradient(165deg, rgba(14, 48, 94, 0.98), rgba(5, 22, 48, 0.98)) !important;
}

.map-players-toggle:hover .map-players-toggle__glow {
  opacity: 1;
}

.map-players-toggle.is-open {
  border-color: rgba(252, 212, 138, 0.85);
  color: #fff1cc;
  box-shadow:
    0 0 0 2px rgba(212, 62, 20, 0.35),
    0 12px 28px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.map-players-toggle.is-open .map-players-toggle__glow {
  opacity: 1;
}

.map-players-toggle:focus-visible {
  outline: 2px solid rgba(252, 212, 138, 0.85);
  outline-offset: 2px;
}

/* Sidebar lives inside dock — ignore Leaflet corner positioning */
body.map-ui-enhanced .leaflet-top.leaflet-right {
  position: static !important;
  top: auto !important;
  right: auto !important;
  bottom: auto !important;
  left: auto !important;
  height: auto !important;
  transform: none !important;
}

body.map-ui-enhanced #sidebar {
  position: relative !important;
  top: auto !important;
  right: auto !important;
  transform: none !important;
  margin: 0 !important;
  pointer-events: none;
  height: auto !important;
  max-height: none !important;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

body.map-ui-enhanced #sidebar > * {
  pointer-events: auto;
}

/* Always hide Pl3xMap tab buttons — we use custom players toggle */
body.map-ui-enhanced #sidebar__buttons {
  display: none !important;
}

body.map-ui-enhanced #sidebar:not(.map-ui-players-open) #sidebar__content,
body.site-page--map.map-ui-enhanced #sidebar:not(.map-ui-players-open) #sidebar__content {
  display: none !important;
}

body.map-ui-enhanced #sidebar.map-ui-players-open #sidebar__content,
body.site-page--map.map-ui-enhanced #sidebar.map-ui-players-open #sidebar__content {
  display: block !important;
  position: relative !important;
  top: auto !important;
  left: auto !important;
  height: fit-content !important;
  max-height: min(58vh, calc(100vh - var(--site-chrome-h, 96px) - 140px)) !important;
  width: min(300px, calc(100vw - 28px)) !important;
}

@media (max-width: 820px) {
  .map-ui-dock {
    top: calc(var(--site-chrome-h, 96px) + 10px);
    right: 10px;
    gap: 8px;
  }

  .map-players-toggle {
    width: 46px;
    height: 46px;
    border-radius: 13px;
  }

  body.map-ui-enhanced #sidebar.map-ui-players-open #sidebar__content,
  body.site-page--map.map-ui-enhanced #sidebar.map-ui-players-open #sidebar__content {
    max-height: min(45vh, 320px) !important;
    width: min(280px, calc(100vw - 24px)) !important;
  }
}

/* ——— Mines & swords shop (left of map) ——— */
.map-mines-dock {
  position: fixed;
  top: calc(var(--site-chrome-h, 96px) + 12px);
  left: 12px;
  z-index: 9000;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 8px;
  width: auto;
  max-width: min(360px, calc(100vw - 24px));
  max-height: calc(100vh - var(--site-chrome-h, 96px) - 28px);
  pointer-events: none;
}

.map-mines-dock > * {
  pointer-events: auto;
}

.map-mines-toggle {
  appearance: none;
  -webkit-appearance: none;
  flex-shrink: 0;
  display: flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 52px !important;
  min-width: 52px !important;
  height: auto !important;
  min-height: 72px !important;
  margin: 0;
  padding: 8px 6px !important;
  border-radius: 14px !important;
  border: 1px solid rgba(252, 212, 138, 0.4) !important;
  background: linear-gradient(165deg, rgba(8, 34, 70, 0.96), rgba(5, 18, 40, 0.98)) !important;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4);
  cursor: pointer;
  color: #fcd48a !important;
  line-height: 1 !important;
  white-space: normal !important;
}

.map-mines-toggle:hover {
  filter: brightness(1.08);
}

.map-mines-toggle__icons {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.map-mines-toggle__thumb {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: cover;
  display: block;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.map-mines-toggle__chev {
  width: 10px;
  height: 10px;
  border-right: 2px solid #fcd48a;
  border-bottom: 2px solid #fcd48a;
  transform: rotate(-45deg);
  margin: 2px 0 0;
  transition: transform 160ms ease;
}

.map-mines-dock.is-collapsed .map-mines-toggle__chev {
  transform: rotate(135deg);
  margin-top: 4px;
}

.map-mines-dock__panel {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: min(340px, calc(100vw - 88px));
  max-height: calc(100vh - var(--site-chrome-h, 96px) - 28px);
  overflow: auto;
  scrollbar-width: thin;
  transition: opacity 160ms ease, transform 160ms ease;
}

.map-mines-dock.is-collapsed .map-mines-dock__panel {
  display: none;
}

.map-mines-card {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 0.85rem;
  padding: 0.95rem 1rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(252, 212, 138, 0.28);
  background:
    radial-gradient(120% 80% at 0% 0%, rgba(252, 212, 138, 0.12), transparent 55%),
    linear-gradient(165deg, rgba(8, 34, 70, 0.96), rgba(5, 18, 40, 0.98));
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.42);
  color: #f5ecd6;
}

.map-mines-card--sword {
  border-color: rgba(212, 62, 20, 0.4);
  background:
    radial-gradient(120% 80% at 100% 0%, rgba(212, 62, 20, 0.16), transparent 55%),
    linear-gradient(165deg, rgba(8, 34, 70, 0.96), rgba(5, 18, 40, 0.98));
}

.map-mines-card__icon {
  display: grid;
  place-items: center;
  align-self: start;
  width: 72px;
  height: 72px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
  flex-shrink: 0;
}

.map-mines-card__art {
  width: 72px;
  height: 72px;
  display: block;
}

.map-mines-card__art img {
  width: 72px;
  height: 72px;
  display: block;
  object-fit: cover;
  border-radius: 12px;
}

.map-mines-card__title {
  font-family: "Segoe UI", system-ui, sans-serif;
  font-weight: 800;
  font-size: 1.22rem;
  letter-spacing: 0.01em;
  color: #ffe2a8;
  line-height: 1.2;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
}

.map-mines-card--sword .map-mines-card__title {
  color: #ffc4ad;
}

.map-mines-card__price {
  margin-top: 0.2rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: #9ae4ff;
  font-size: 1.12rem;
  letter-spacing: 0.02em;
}

.map-mines-card__rules {
  list-style: none;
  margin: 0.55rem 0 0.55rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.28rem;
  font-size: 0.92rem;
  line-height: 1.35;
  color: rgba(255, 246, 230, 0.92);
  font-weight: 550;
}

.map-mines-card__rules li {
  position: relative;
  padding-left: 0.95rem;
}

.map-mines-card__rules li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 50%;
  background: #fcd48a;
}

.map-mines-card--sword .map-mines-card__rules li::before {
  background: #ff7a4d;
}

.map-mines-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.75rem;
  font-size: 0.9rem;
  color: rgba(255, 246, 230, 0.78);
  margin-bottom: 0.55rem;
  font-weight: 600;
}

.map-mines-card__meta b {
  color: #fff;
  font-weight: 800;
  font-size: 1em;
}

.map-mines-card__btn {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  margin: 0;
  padding: 0.65rem 0.7rem !important;
  border-radius: 12px !important;
  border: 1px solid rgba(252, 212, 138, 0.55) !important;
  background: linear-gradient(180deg, rgba(252, 212, 138, 0.28), rgba(212, 62, 20, 0.22)) !important;
  color: #fff !important;
  font-weight: 800 !important;
  font-size: 0.98rem !important;
  line-height: 1.25 !important;
  cursor: pointer;
  white-space: normal !important;
  min-height: 0 !important;
  height: auto !important;
  display: block !important;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.35);
}

.map-mines-card__btn:hover:not(:disabled) {
  filter: brightness(1.08);
}

.map-mines-dock.is-busy {
  opacity: 0.85;
}

.map-mines-dock.is-busy .map-mines-card__btn {
  cursor: wait;
}

.map-mine-divicon {
  background: transparent !important;
  border: none !important;
}

.map-mine-marker {
  position: relative;
  width: 52px;
  height: 64px;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: auto;
  cursor: pointer;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.55));
}

.map-mine-marker__img {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  border: 2px solid rgba(252, 212, 138, 0.75);
  object-fit: cover;
  display: block;
  background: #0a1830;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

.map-mine-marker--empty .map-mine-marker__img {
  border-color: rgba(122, 216, 255, 0.85);
}

.map-mine-marker.is-own .map-mine-marker__img {
  border-color: #7ad8ff;
}

.map-mine-marker.is-ready .map-mine-marker__img {
  border-color: #fcd48a;
  animation: map-mine-pulse 1.6s ease-in-out infinite;
}

.map-mine-marker__label {
  margin-top: 2px;
  padding: 2px 6px;
  border-radius: 6px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
  white-space: nowrap;
  color: #fff;
  background: rgba(0, 0, 0, 0.78);
  border: 1px solid rgba(252, 212, 138, 0.4);
}

.map-mine-marker.is-ready .map-mine-marker__label {
  color: #fcd48a;
  border-color: rgba(252, 212, 138, 0.75);
}

.map-mine-marker__label--timer {
  color: #9ae4ff;
  border-color: rgba(122, 216, 255, 0.55);
  font-variant-numeric: tabular-nums;
  min-width: 3.2rem;
  text-align: center;
}

@keyframes map-mine-pulse {
  0%,
  100% {
    transform: translateY(0);
    filter: brightness(1);
  }
  50% {
    transform: translateY(-2px);
    filter: brightness(1.15);
  }
}

.map-mines-modal {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: grid;
  place-items: center;
}

.map-mines-modal[hidden] {
  display: none !important;
}

.map-mines-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 10, 24, 0.62);
}

.map-mines-modal__panel {
  position: relative;
  z-index: 1;
  width: min(360px, calc(100vw - 28px));
  padding: 1rem 1.05rem 1.1rem;
  border-radius: 16px;
  border: 1px solid rgba(252, 212, 138, 0.35);
  background: linear-gradient(165deg, rgba(10, 36, 72, 0.98), rgba(5, 18, 40, 0.99));
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.5);
  color: #f5ecd6;
}

.map-mines-modal__title {
  font-weight: 800;
  font-size: 1.15rem;
  color: #fcd48a;
}

.map-mines-modal__hint {
  margin: 0.4rem 0 0.8rem;
  font-size: 0.82rem;
  line-height: 1.4;
  color: rgba(245, 236, 214, 0.75);
}

.map-mines-modal__ores {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem;
}

.map-mines-modal__ore {
  appearance: none;
  -webkit-appearance: none;
  margin: 0;
  padding: 0.55rem 0.45rem !important;
  border-radius: 10px !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  background: rgba(255, 255, 255, 0.06) !important;
  color: #fff !important;
  font-weight: 650 !important;
  font-size: 0.85rem !important;
  line-height: 1.2 !important;
  height: auto !important;
  min-height: 0 !important;
  width: 100% !important;
  white-space: normal !important;
  cursor: pointer;
}

.map-mines-modal__ore:hover {
  border-color: rgba(252, 212, 138, 0.55) !important;
  background: rgba(252, 212, 138, 0.12) !important;
}

.map-mines-modal__cancel {
  appearance: none;
  -webkit-appearance: none;
  display: block !important;
  width: 100% !important;
  margin: 0.75rem 0 0 !important;
  padding: 0.5rem !important;
  border-radius: 10px !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  background: transparent !important;
  color: rgba(245, 236, 214, 0.8) !important;
  font-size: 0.85rem !important;
  height: auto !important;
  cursor: pointer;
}

@media (max-width: 820px) {
  .map-mines-dock {
    top: 50%;
    left: 8px;
    bottom: auto;
    right: auto;
    transform: translateY(-50%);
    max-height: min(70vh, calc(100vh - 140px));
    z-index: 9050;
  }

  .map-mines-toggle {
    width: 48px !important;
    min-width: 48px !important;
    min-height: 64px !important;
    padding: 6px 5px !important;
  }

  .map-mines-toggle__thumb {
    width: 28px;
    height: 28px;
  }

  .map-mines-dock__panel {
    width: min(270px, calc(100vw - 68px));
    max-height: min(70vh, calc(100vh - 140px));
  }

  .map-mines-card {
    grid-template-columns: 52px 1fr;
    gap: 0.65rem;
    padding: 0.7rem 0.75rem 0.8rem;
  }

  .map-mines-card__icon {
    width: 52px;
    height: 52px;
  }

  .map-mines-card__art,
  .map-mines-card__art img {
    width: 52px;
    height: 52px;
  }

  .map-mines-card__rules {
    display: none;
  }

  .map-mines-card__title {
    font-size: 1.05rem;
  }

  .map-mines-card__price {
    font-size: 1rem;
  }

  .map-mines-card__meta {
    font-size: 0.84rem;
    margin-bottom: 0.45rem;
  }

  .map-mines-card__btn {
    padding: 0.55rem 0.6rem !important;
    font-size: 0.9rem !important;
  }
}

/* ——— Valuable players (server.html) ——— */
.site-valuable {
  margin: 2.5rem 0 1.5rem;
}

.site-valuable__intro {
  max-width: 42rem;
  margin: 0 0 1.4rem;
  color: rgba(245, 236, 214, 0.88);
  font-size: 1.05rem;
  line-height: 1.55;
}

.site-valuable__tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 1rem;
}

.site-valuable__tab {
  appearance: none;
  border: 1px solid rgba(252, 212, 138, 0.28);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(245, 236, 214, 0.88);
  font: inherit;
  font-weight: 700;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  cursor: pointer;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.site-valuable__tab:hover {
  border-color: rgba(252, 212, 138, 0.55);
  color: #fff;
}

.site-valuable__tab.is-active {
  background: rgba(212, 62, 20, 0.35);
  border-color: rgba(252, 212, 138, 0.7);
  color: #fff;
}

.site-valuable__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.site-valuable__pager {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  margin: 1rem 0 0;
}

.site-valuable__page-btn {
  appearance: none;
  min-width: 2.2rem;
  height: 2.2rem;
  padding: 0 0.65rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.05);
  color: rgba(245, 236, 214, 0.9);
  font: inherit;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}

.site-valuable__page-btn:hover:not(:disabled) {
  border-color: rgba(252, 212, 138, 0.5);
  color: #fff;
}

.site-valuable__page-btn.is-active {
  background: rgba(212, 62, 20, 0.4);
  border-color: rgba(252, 212, 138, 0.65);
  color: #fff;
}

.site-valuable__page-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

.site-valuable__row {
  display: grid;
  grid-template-columns: 2.4rem 2.6rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0.9rem;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
}

.site-valuable__rank {
  font-weight: 800;
  color: var(--site-sand);
  font-variant-numeric: tabular-nums;
}

.site-valuable__skin {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.25) center / cover no-repeat;
}

.site-valuable__name {
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-valuable__time {
  display: inline-flex;
  align-items: baseline;
  gap: 0.55rem;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  color: var(--site-sand);
  white-space: nowrap;
}

.site-valuable__dur {
  display: inline-flex;
  align-items: baseline;
  gap: 0.18rem;
}

.site-valuable__dur-n {
  font-size: 1.05em;
  letter-spacing: 0.02em;
}

.site-valuable__dur-u {
  font-size: 0.72em;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: rgba(245, 236, 214, 0.62);
  text-transform: none;
}

.site-valuable__row.map-tier-5 { border-color: rgba(120, 180, 255, 0.45); }
.site-valuable__row.map-tier-10 { border-color: rgba(90, 220, 170, 0.5); }
.site-valuable__row.map-tier-20 { border-color: rgba(252, 212, 138, 0.55); }
.site-valuable__row.map-tier-30 { border-color: rgba(255, 170, 70, 0.6); }
.site-valuable__row.map-tier-40 { border-color: rgba(255, 110, 90, 0.65); }
.site-valuable__row.map-tier-50 { border-color: rgba(220, 120, 255, 0.65); }
.site-valuable__row.map-tier-100 {
  border-color: rgba(252, 212, 138, 0.75);
  box-shadow: 0 0 16px rgba(212, 62, 20, 0.18);
}

.site-valuable__empty,
.site-valuable__error {
  color: rgba(245, 236, 214, 0.7);
  margin: 0.5rem 0 0;
}

.site-playtime-admin {
  margin-top: 2rem;
  padding: 1.1rem 1.15rem;
  border-radius: 14px;
  border: 1px solid rgba(212, 62, 20, 0.35);
  background: rgba(8, 28, 58, 0.65);
}

.site-playtime-admin h3 {
  margin: 0 0 0.4rem;
  color: var(--site-sand);
}

.site-playtime-admin__lead {
  margin: 0 0 1rem;
  color: rgba(245, 236, 214, 0.75);
  font-size: 0.95rem;
}

.site-playtime-admin__list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  max-height: 420px;
  overflow: auto;
}

.site-playtime-admin__row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 7.5rem auto;
  gap: 0.5rem;
  align-items: center;
}

.site-playtime-admin__row input {
  width: 100%;
  min-height: 38px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(0, 0, 0, 0.25);
  color: #f5ecd6;
  padding: 0.35rem 0.55rem;
  font-variant-numeric: tabular-nums;
}

.site-playtime-admin__name {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-playtime-admin__status {
  margin: 0.75rem 0 0;
  min-height: 1.2em;
  color: var(--site-sand);
  font-size: 0.92rem;
}

@media (max-width: 820px) {
  .site-playtime-admin__row {
    grid-template-columns: 1fr;
  }
}

/* —— Server guide: hero CTA + fullscreen modal —— */
.server-guide-btn {
  appearance: none;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(252, 212, 138, 0.65);
  background: linear-gradient(135deg, #e24a1c 0%, #b83410 48%, #8f2a0c 100%);
  color: #fff8f0;
  font: inherit;
  font-weight: 750;
  font-size: 14px;
  line-height: 1.2;
  padding: 10px 18px;
  min-height: 42px;
  border-radius: 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  isolation: isolate;
  box-shadow:
    0 0 0 0 rgba(252, 212, 138, 0.45),
    0 10px 28px rgba(212, 62, 20, 0.35);
  animation: serverGuidePulse 2.4s var(--site-ease) infinite;
  transition: filter var(--site-fade), transform 120ms var(--site-ease);
}

.server-guide-btn__glow {
  position: absolute;
  inset: -40%;
  background: linear-gradient(
    115deg,
    transparent 35%,
    rgba(252, 212, 138, 0.45) 50%,
    transparent 65%
  );
  transform: translateX(-60%);
  animation: serverGuideShimmer 3.2s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}

.server-guide-btn__label {
  position: relative;
  z-index: 1;
  letter-spacing: 0.01em;
}

.server-guide-btn:hover {
  filter: brightness(1.1);
}

.server-guide-btn:active {
  transform: translateY(1px);
}

@keyframes serverGuidePulse {
  0%,
  100% {
    box-shadow:
      0 0 0 0 rgba(252, 212, 138, 0.42),
      0 10px 28px rgba(212, 62, 20, 0.35);
  }
  50% {
    box-shadow:
      0 0 0 10px rgba(252, 212, 138, 0),
      0 14px 34px rgba(212, 62, 20, 0.48);
  }
}

@keyframes serverGuideShimmer {
  0%,
  35% {
    transform: translateX(-70%);
  }
  65%,
  100% {
    transform: translateX(70%);
  }
}

.server-guide-lock {
  overflow: hidden;
}

.server-guide-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(12px, env(safe-area-inset-top)) 14px max(12px, env(safe-area-inset-bottom));
  background: rgba(3, 18, 42, 0);
  opacity: 0;
  pointer-events: none;
  transition: opacity 280ms var(--site-ease), background 280ms var(--site-ease);
}

.server-guide-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
  background: rgba(3, 18, 42, 0.82);
}

.server-guide-backdrop[hidden] {
  display: none !important;
}

.server-guide-backdrop.is-open[hidden] {
  display: flex !important;
}

.server-guide-panel {
  width: min(1100px, 94vw);
  height: min(92vh, 920px);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(ellipse at top right, rgba(212, 62, 20, 0.18), transparent 42%),
    radial-gradient(ellipse at bottom left, rgba(252, 212, 138, 0.12), transparent 46%),
    linear-gradient(180deg, #314354 0%, #0a274f 55%, #051f45 100%);
  border: 1px solid rgba(252, 212, 138, 0.32);
  border-radius: 20px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  transform: translateY(18px) scale(0.96);
  opacity: 0;
  transition: transform 320ms var(--site-ease), opacity 280ms var(--site-ease);
}

.server-guide-backdrop.is-open .server-guide-panel {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.server-guide-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px 12px;
  border-bottom: 1px solid rgba(232, 240, 228, 0.1);
  flex-shrink: 0;
}

.server-guide-kicker {
  margin: 0 0 4px;
  color: var(--site-gold);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.server-guide-header h2 {
  margin: 0;
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 750;
  color: var(--site-cream);
}

.server-guide-close {
  appearance: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid rgba(208, 208, 180, 0.22);
  background: rgba(5, 31, 69, 0.45);
  color: var(--site-cream);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background var(--site-fade), border-color var(--site-fade);
}

.server-guide-close:hover {
  background: rgba(212, 62, 20, 0.28);
  border-color: rgba(252, 212, 138, 0.4);
}

.server-guide-nav {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  padding: 12px 16px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  border-bottom: 1px solid rgba(232, 240, 228, 0.08);
  flex-shrink: 0;
  scrollbar-width: thin;
}

.server-guide-nav button {
  appearance: none;
  flex: 0 0 auto;
  border: 1px solid rgba(252, 212, 138, 0.22);
  background: rgba(5, 31, 69, 0.35);
  color: var(--site-cream);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--site-fade), border-color var(--site-fade), color var(--site-fade);
}

.server-guide-nav button:hover {
  background: rgba(212, 62, 20, 0.22);
  border-color: rgba(252, 212, 138, 0.45);
  color: #fff8f0;
}

.server-guide-body {
  flex: 1;
  overflow: auto;
  padding: 8px 20px 28px;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.server-guide-body::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

.server-guide-section {
  padding: 22px 0 10px;
  border-top: 1px solid rgba(232, 240, 228, 0.08);
  scroll-margin-top: 12px;
}

.server-guide-section:first-child {
  border-top: none;
  padding-top: 16px;
}

.server-guide-section h3 {
  margin: 0 0 12px;
  font-size: clamp(20px, 2.4vw, 24px);
  font-weight: 750;
  color: var(--site-sand);
}

.server-guide-section h4 {
  margin: 18px 0 8px;
  font-size: 16px;
  font-weight: 700;
  color: var(--site-cream);
}

.server-guide-section p,
.server-guide-list,
.server-guide-steps {
  margin: 0 0 12px;
  color: rgba(208, 208, 180, 0.92);
  font-size: 15px;
  line-height: 1.6;
}

.server-guide-list,
.server-guide-steps {
  padding-left: 1.2em;
}

.server-guide-list li + li,
.server-guide-steps li + li {
  margin-top: 6px;
}

.server-guide-section code {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 6px;
  background: rgba(5, 31, 69, 0.55);
  border: 1px solid rgba(252, 212, 138, 0.22);
  color: var(--site-gold);
  font-size: 0.92em;
}

.server-guide-section a {
  color: var(--site-gold);
  text-decoration: underline;
  text-decoration-color: rgba(252, 212, 138, 0.35);
  text-underline-offset: 2px;
}

.server-guide-section a:hover {
  color: #ffe4a8;
}

.server-guide-art {
  display: block;
  width: min(320px, 72%);
  height: auto;
  margin: 0 auto;
  object-fit: contain;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.35));
}

.server-guide-art--side {
  width: min(200px, 42vw);
  margin: 0;
}

.server-guide-art-caption {
  margin: 8px 0 0 !important;
  color: var(--site-muted) !important;
  font-size: 13px !important;
  line-height: 1.45 !important;
  text-align: center;
}

.server-guide-split {
  margin: 14px 0 8px;
  text-align: center;
}

.server-guide-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 1rem 1.25rem;
  align-items: center;
  margin: 14px 0 8px;
}

.server-guide-row--flip {
  grid-template-columns: minmax(0, 1fr) auto;
}

.server-guide-row--flip .server-guide-art--side {
  order: 2;
}

.server-guide-row h4 {
  margin-top: 0;
}

.server-guide-closing {
  margin-top: 18px !important;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(212, 62, 20, 0.35);
  background: rgba(212, 62, 20, 0.12);
  color: var(--site-cream) !important;
  font-weight: 600;
}

@media (max-width: 820px) {
  .server-guide-panel {
    width: 100%;
    height: min(94vh, 100%);
    border-radius: 16px;
  }

  .server-guide-header {
    padding: 14px 14px 10px;
  }

  .server-guide-body {
    padding: 4px 14px 22px;
  }

  .server-guide-btn {
    width: 100%;
  }

  .site-cta .server-guide-btn {
    flex: 1 1 100%;
  }

  .site-hero--server {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .site-hero__art {
    width: min(200px, 56vw);
    justify-self: center;
    order: -1;
  }

  .server-guide-row,
  .server-guide-row--flip {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .server-guide-row--flip .server-guide-art--side {
    order: 0;
  }

  .server-guide-list,
  .server-guide-steps {
    text-align: left;
  }

  .server-guide-art--side {
    width: min(180px, 50vw);
    margin: 0 auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .server-guide-btn,
  .server-guide-btn__glow {
    animation: none;
  }

  .server-guide-backdrop,
  .server-guide-panel {
    transition: none;
  }

  .server-guide-body {
    scroll-behavior: auto;
  }

  .site-nav__donate-coins i {
    animation: none;
    opacity: 0;
  }
}

/* —— Server chronicle (летопись) —— */
.server-chronicle-btn {
  appearance: none;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 10px 16px;
  border-radius: 12px;
  border: 1px solid rgba(252, 212, 138, 0.55);
  background:
    linear-gradient(180deg, rgba(252, 212, 138, 0.22), rgba(49, 67, 84, 0.55)),
    linear-gradient(135deg, #3a4f63, #1a3048);
  color: var(--site-sand);
  font: inherit;
  font-weight: 750;
  font-size: 14px;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(5, 31, 69, 0.35);
  transition: filter var(--site-fade), transform 120ms var(--site-ease), border-color var(--site-fade);
}

.server-chronicle-btn__icon {
  width: 28px;
  height: 28px;
  object-fit: contain;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
}

.server-chronicle-btn:hover {
  filter: brightness(1.08);
  border-color: rgba(252, 212, 138, 0.85);
}

.server-chronicle-btn:active {
  transform: translateY(1px);
}

.server-chronicle-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10210;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(12px, env(safe-area-inset-top)) 14px max(12px, env(safe-area-inset-bottom));
  background: rgba(3, 18, 42, 0);
  opacity: 0;
  pointer-events: none;
  transition: opacity 280ms var(--site-ease), background 280ms var(--site-ease);
}

.server-chronicle-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
  background: rgba(3, 18, 42, 0.84);
}

.server-chronicle-backdrop[hidden] {
  display: none !important;
}

.server-chronicle-backdrop.is-open[hidden] {
  display: flex !important;
}

.server-chronicle-panel {
  width: min(1100px, 94vw);
  height: min(92vh, 920px);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 20px;
  border: 1px solid rgba(252, 212, 138, 0.34);
  background:
    radial-gradient(ellipse at top left, rgba(252, 212, 138, 0.12), transparent 42%),
    radial-gradient(ellipse at bottom right, rgba(212, 62, 20, 0.12), transparent 46%),
    linear-gradient(180deg, #3a4f63 0%, #1a3048 45%, #051f45 100%);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.55);
  transform: translateY(18px) scale(0.96);
  opacity: 0;
  transition: transform 320ms var(--site-ease), opacity 280ms var(--site-ease);
}

.server-chronicle-backdrop.is-open .server-chronicle-panel {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.server-chronicle-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px 12px;
  border-bottom: 1px solid rgba(232, 240, 228, 0.1);
  flex-shrink: 0;
}

.server-chronicle-kicker {
  margin: 0 0 4px;
  color: var(--site-gold);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.server-chronicle-header h2 {
  margin: 0;
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 750;
  color: var(--site-cream);
}

.server-chronicle-header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.server-chronicle-close {
  appearance: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid rgba(208, 208, 180, 0.22);
  background: rgba(5, 31, 69, 0.45);
  color: var(--site-cream);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.server-chronicle-close:hover {
  background: rgba(212, 62, 20, 0.28);
  border-color: rgba(252, 212, 138, 0.4);
}

.server-chronicle-nav {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
  padding: 10px 14px;
  overflow-x: auto;
  border-bottom: 1px solid rgba(232, 240, 228, 0.08);
  flex-shrink: 0;
  scrollbar-width: none;
}

.server-chronicle-nav::-webkit-scrollbar {
  display: none;
}

.server-chronicle-nav button {
  appearance: none;
  flex: 0 0 auto;
  min-width: 40px;
  border: 1px solid rgba(252, 212, 138, 0.22);
  background: rgba(5, 31, 69, 0.35);
  color: var(--site-cream);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  padding: 7px 11px;
  border-radius: 999px;
  cursor: pointer;
}

.server-chronicle-nav button:hover {
  background: rgba(252, 212, 138, 0.14);
  border-color: rgba(252, 212, 138, 0.45);
}

.server-chronicle-body {
  flex: 1;
  overflow: auto;
  padding: 10px 22px 32px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.server-chronicle-body::-webkit-scrollbar {
  display: none;
}

.server-chronicle-intro {
  margin: 8px 0 18px;
  padding: 16px 18px;
  border-radius: 16px;
  border: 1px solid rgba(252, 212, 138, 0.22);
  background: rgba(5, 31, 69, 0.28);
  text-align: center;
}

.server-chronicle-book-title {
  margin: 0 0 8px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(18px, 2.4vw, 24px);
  color: var(--site-sand);
  letter-spacing: 0.02em;
}

.server-chronicle-book-sub {
  margin: 0 0 4px;
  color: var(--site-muted);
  font-size: 14px;
  line-height: 1.5;
}

.server-chronicle-chapter {
  margin: 0 0 8px;
  padding: 22px 0 18px;
  border-top: 1px solid rgba(232, 240, 228, 0.1);
  scroll-margin-top: 12px;
}

.server-chronicle-chapter::after {
  content: "";
  display: table;
  clear: both;
}

.server-chronicle-chapter:first-of-type {
  border-top: none;
}

.server-chronicle-chapter__head {
  display: contents;
}

.server-chronicle-art {
  float: right;
  width: min(260px, 42%);
  max-width: 280px;
  height: auto;
  margin: 4px 0 18px 28px;
  object-fit: contain;
  filter: drop-shadow(0 12px 20px rgba(0, 0, 0, 0.4));
  shape-outside: margin-box;
}

.server-chronicle-chapter:nth-of-type(even) .server-chronicle-art {
  float: left;
  margin: 4px 28px 18px 0;
}

.server-chronicle-chapter:nth-of-type(3n) .server-chronicle-art {
  width: min(320px, 48%);
  max-width: 340px;
}

.server-chronicle-chapter__head > div {
  display: block;
  margin: 0 0 10px;
}

.server-chronicle-chapter h3 {
  margin: 0 0 6px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(20px, 2.5vw, 26px);
  color: var(--site-sand);
  line-height: 1.2;
}

.server-chronicle-period {
  margin: 0;
  color: rgba(252, 212, 138, 0.75);
  font-size: 13px;
  font-style: italic;
}

.server-chronicle-prose {
  max-width: none;
  overflow: auto;
}

.server-chronicle-prose::after {
  content: "";
  display: table;
  clear: both;
}

.server-chronicle-prose p {
  margin: 0 0 12px;
  color: rgba(208, 208, 180, 0.94);
  font-size: 15px;
  line-height: 1.7;
}

.server-chronicle-drop::first-letter {
  float: left;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 3.1em;
  line-height: 0.82;
  padding: 6px 10px 0 0;
  font-weight: 700;
  color: var(--site-gold);
}

.server-chronicle-saga {
  margin: 18px 0 12px !important;
  text-align: center;
  color: var(--site-sand) !important;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 15px !important;
  font-style: italic;
  letter-spacing: 0.02em;
}

.server-chronicle-listhead {
  margin: 14px 0 8px !important;
  color: var(--site-cream) !important;
  font-weight: 700;
}

.server-chronicle-bullets {
  margin: 0 0 14px;
  padding-left: 1.2em;
  color: rgba(208, 208, 180, 0.94);
  font-size: 15px;
  line-height: 1.65;
}

.server-chronicle-bullets li + li {
  margin-top: 6px;
}

.server-chronicle-names {
  margin: 0 0 14px;
  padding-left: 1.15em;
  columns: 2;
  column-gap: 1.5rem;
  color: rgba(208, 208, 180, 0.94);
  font-size: 14px;
  line-height: 1.55;
  list-style: disc;
}

.server-chronicle-names li {
  break-inside: avoid;
  margin: 0 0 4px;
}

.server-chronicle-end {
  margin-top: 20px !important;
  text-align: center;
  color: var(--site-muted) !important;
  font-style: italic;
}

.server-chronicle-chapter#letopis-xiii .server-chronicle-prose p:last-of-type,
.server-chronicle-chapter#letopis-xiii .server-chronicle-prose p:nth-last-of-type(2) {
  text-align: center;
  color: var(--site-sand);
  font-family: Georgia, "Times New Roman", serif;
}

@media (max-width: 820px) {
  .server-chronicle-panel {
    width: 100%;
    height: min(94vh, 100%);
    border-radius: 16px;
  }

  .server-chronicle-header {
    padding: 12px 12px 10px;
    flex-wrap: wrap;
  }

  .server-chronicle-body {
    padding: 6px 14px 24px;
  }

  .server-chronicle-art,
  .server-chronicle-chapter:nth-of-type(even) .server-chronicle-art,
  .server-chronicle-chapter:nth-of-type(3n) .server-chronicle-art {
    float: none;
    display: block;
    width: min(220px, 70%);
    max-width: 240px;
    margin: 0 auto 14px;
  }

  .server-chronicle-chapter__head > div {
    text-align: center;
  }

  .server-chronicle-prose {
    max-width: none;
  }

  .server-chronicle-names {
    columns: 1;
  }

  .server-chronicle-btn {
    width: 100%;
  }

  .site-cta .server-chronicle-btn {
    flex: 1 1 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .server-chronicle-backdrop,
  .server-chronicle-panel {
    transition: none;
  }

  .server-chronicle-body {
    scroll-behavior: auto;
  }
}

/* —— Server upgrades guide —— */
.server-upgrades-btn {
  appearance: none;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 10px 16px;
  border-radius: 12px;
  border: 1px solid rgba(180, 210, 230, 0.45);
  background:
    linear-gradient(180deg, rgba(140, 180, 210, 0.28), rgba(40, 70, 100, 0.7)),
    linear-gradient(135deg, #4a6578, #1e3348);
  color: #e8f2f8;
  font: inherit;
  font-weight: 750;
  font-size: 14px;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(5, 31, 69, 0.35);
  transition: filter var(--site-fade), transform 120ms var(--site-ease), border-color var(--site-fade);
}

.server-upgrades-btn__icon {
  width: 28px;
  height: 28px;
  object-fit: contain;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
}

.server-upgrades-btn:hover {
  filter: brightness(1.08);
  border-color: rgba(220, 235, 245, 0.7);
}

.server-upgrades-btn:active {
  transform: translateY(1px);
}

.server-upgrades-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10205;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(12px, env(safe-area-inset-top)) 14px max(12px, env(safe-area-inset-bottom));
  background: rgba(3, 18, 42, 0);
  opacity: 0;
  pointer-events: none;
  transition: opacity 280ms var(--site-ease), background 280ms var(--site-ease);
}

.server-upgrades-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
  background: rgba(3, 18, 42, 0.84);
}

.server-upgrades-backdrop[hidden] {
  display: none !important;
}

.server-upgrades-backdrop.is-open[hidden] {
  display: flex !important;
}

.server-upgrades-panel {
  width: min(1100px, 94vw);
  height: min(92vh, 920px);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 20px;
  border: 1px solid rgba(180, 210, 230, 0.32);
  background:
    radial-gradient(ellipse at top right, rgba(100, 170, 210, 0.16), transparent 42%),
    radial-gradient(ellipse at bottom left, rgba(252, 212, 138, 0.1), transparent 46%),
    linear-gradient(180deg, #3a5266 0%, #1a3348 48%, #051f45 100%);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.55);
  transform: translateY(18px) scale(0.96);
  opacity: 0;
  transition: transform 320ms var(--site-ease), opacity 280ms var(--site-ease);
}

.server-upgrades-backdrop.is-open .server-upgrades-panel {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.server-upgrades-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px 12px;
  border-bottom: 1px solid rgba(232, 240, 228, 0.1);
  flex-shrink: 0;
}

.server-upgrades-kicker {
  margin: 0 0 4px;
  color: #9fd0ea;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.server-upgrades-header h2 {
  margin: 0;
  font-size: clamp(20px, 2.8vw, 26px);
  font-weight: 750;
  color: var(--site-cream);
}

.server-upgrades-close {
  appearance: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid rgba(208, 208, 180, 0.22);
  background: rgba(5, 31, 69, 0.45);
  color: var(--site-cream);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.server-upgrades-close:hover {
  background: rgba(100, 170, 210, 0.28);
  border-color: rgba(180, 210, 230, 0.45);
}

.server-upgrades-nav {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  padding: 10px 14px;
  overflow-x: auto;
  border-bottom: 1px solid rgba(232, 240, 228, 0.08);
  flex-shrink: 0;
  scrollbar-width: none;
}

.server-upgrades-nav::-webkit-scrollbar {
  display: none;
}

.server-upgrades-nav button {
  appearance: none;
  flex: 0 0 auto;
  border: 1px solid rgba(180, 210, 230, 0.28);
  background: rgba(5, 31, 69, 0.35);
  color: var(--site-cream);
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
}

.server-upgrades-nav button:hover {
  background: rgba(100, 170, 210, 0.2);
  border-color: rgba(180, 210, 230, 0.5);
}

.server-upgrades-body {
  flex: 1;
  overflow: auto;
  padding: 12px 22px 32px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.server-upgrades-body::-webkit-scrollbar {
  display: none;
}

.server-upgrades-intro {
  margin: 4px 0 18px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(180, 210, 230, 0.22);
  background: rgba(5, 31, 69, 0.3);
}

.server-upgrades-intro p {
  margin: 0 0 8px;
  color: rgba(208, 208, 180, 0.92);
  font-size: 15px;
  line-height: 1.6;
}

.server-upgrades-intro p:last-child {
  margin-bottom: 0;
}

.server-upgrades-intro code {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 6px;
  background: rgba(5, 31, 69, 0.55);
  border: 1px solid rgba(180, 210, 230, 0.28);
  color: #9fd0ea;
  font-size: 0.92em;
}

.server-upgrades-section {
  margin: 0 0 10px;
  padding: 20px 0 14px;
  border-top: 1px solid rgba(232, 240, 228, 0.1);
  scroll-margin-top: 12px;
}

.server-upgrades-section::after {
  content: "";
  display: table;
  clear: both;
}

.server-upgrades-section__head {
  display: contents;
}

.server-upgrades-art {
  float: right;
  width: min(240px, 40%);
  max-width: 260px;
  height: auto;
  margin: 4px 0 16px 24px;
  object-fit: contain;
  filter: drop-shadow(0 12px 18px rgba(0, 0, 0, 0.4));
}

.server-upgrades-art--flip {
  float: left;
  margin: 4px 24px 16px 0;
}

.server-upgrades-section__head > div {
  display: block;
  margin: 0 0 10px;
}

.server-upgrades-section h3 {
  margin: 0 0 4px;
  font-size: clamp(20px, 2.4vw, 24px);
  font-weight: 750;
  color: var(--site-sand);
}

.server-upgrades-lead {
  margin: 0;
  color: #9fd0ea;
  font-size: 13px;
  font-style: italic;
}

.server-upgrades-prose {
  max-width: none;
}

.server-upgrades-prose h4 {
  margin: 18px 0 8px;
  clear: both;
  font-size: 16px;
  font-weight: 700;
  color: var(--site-cream);
}

.server-upgrades-prose p,
.server-upgrades-prose li {
  color: rgba(208, 208, 180, 0.94);
  font-size: 15px;
  line-height: 1.65;
}

.server-upgrades-prose p {
  margin: 0 0 12px;
}

.server-upgrades-prose ul,
.server-upgrades-prose ol {
  margin: 0 0 14px;
  padding-left: 1.25em;
}

.server-upgrades-prose li + li {
  margin-top: 5px;
}

.server-upgrades-drop::first-letter {
  float: left;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2.8em;
  line-height: 0.85;
  padding: 4px 8px 0 0;
  font-weight: 700;
  color: #9fd0ea;
}

.server-upgrades-table-wrap {
  clear: both;
  overflow-x: auto;
  margin: 0 0 16px;
  border-radius: 12px;
  border: 1px solid rgba(180, 210, 230, 0.22);
  background: rgba(5, 31, 69, 0.35);
}

.server-upgrades-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}

.server-upgrades-table th,
.server-upgrades-table td {
  padding: 9px 12px;
  text-align: left;
  border-bottom: 1px solid rgba(232, 240, 228, 0.08);
  vertical-align: top;
}

.server-upgrades-table th {
  color: var(--site-sand);
  font-weight: 700;
  background: rgba(252, 212, 138, 0.06);
  white-space: nowrap;
}

.server-upgrades-table td {
  color: rgba(208, 208, 180, 0.92);
}

.server-upgrades-table tr:last-child td {
  border-bottom: none;
}

.server-upgrades-tip {
  margin-top: 16px !important;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(252, 212, 138, 0.28);
  background: rgba(252, 212, 138, 0.08);
  color: var(--site-cream) !important;
  font-weight: 600;
}

@media (max-width: 820px) {
  .server-upgrades-panel {
    width: 100%;
    height: min(94vh, 100%);
    border-radius: 16px;
  }

  .server-upgrades-body {
    padding: 8px 14px 24px;
  }

  .server-upgrades-art,
  .server-upgrades-art--flip {
    float: none;
    display: block;
    width: min(200px, 68%);
    max-width: 220px;
    margin: 0 auto 14px;
  }

  .server-upgrades-section__head > div {
    text-align: center;
  }

  .server-upgrades-btn {
    width: 100%;
  }

  .site-cta .server-upgrades-btn {
    flex: 1 1 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .server-upgrades-backdrop,
  .server-upgrades-panel {
    transition: none;
  }

  .server-upgrades-body {
    scroll-behavior: auto;
  }
}
