/* ============================================================
   HEADER
   ============================================================ */

#main-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  height: var(--nav-h);
  background: rgba(13,11,14,.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: border-color .3s;
  /* Let Server Info flyout extend below the bar (avoid clip + dead clicks) */
  overflow: visible;
}

#main-header.scrolled {
  border-bottom-color: var(--accent-border);
}

/* Grid: logo | nav (hugs logo) | actions — avoids a dead zone between logo and links */
.header-inner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  column-gap: clamp(16px, 2.2vw, 26px);
  height: 100%;
  overflow: visible;
}

.header-inner.header-container {
  width: 100%;
  max-width: 100%;
}

#main-header .header-inner.header-container.container {
  padding-inline: clamp(22px, 4.5vw, 40px);
}

/* Logo */
.header-logo,
.footer-logo {
  font-family: var(--font-display);
  font-weight: 900;
  letter-spacing: .06em;
  display: flex;
  align-items: center;
  gap: 2px;
  white-space: nowrap;
  flex-shrink: 0;
}

.logo-mu     { color: var(--accent); font-size: 1.4rem; }
.logo-dot    { color: var(--text-dim); font-size: 1rem; margin: 0 1px; }
.logo-online { color: var(--text-primary); font-size: 1.1rem; letter-spacing: .12em; }

/* Default brand: MuAlein logo-1..6 via --theme-brand-logo-image (when brand.logo absent in public info) */
#main-header a.header-logo.theme-brand-logo {
  display: block;
  width: clamp(148px, 28vw, 232px);
  height: clamp(44px, 7.5vw, 58px);
  max-height: calc(var(--nav-h) - 20px);
  flex-shrink: 0;
  background-image: var(--theme-brand-logo-image);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: left center;
  filter: drop-shadow(0 4px 14px rgba(0, 0, 0, 0.45));
  transition: filter 0.2s ease, transform 0.2s ease;
}
#main-header a.header-logo.theme-brand-logo:hover {
  filter: drop-shadow(0 6px 20px rgba(0, 0, 0, 0.5)) drop-shadow(0 0 14px var(--accent-glow));
}

.footer-brand a.footer-logo.theme-brand-logo {
  display: block;
  width: min(248px, 72vw);
  height: 68px;
  margin-bottom: 14px;
  background-image: var(--theme-brand-logo-image);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: left center;
  filter: drop-shadow(0 6px 18px rgba(0, 0, 0, 0.4));
}

.auth-logo.theme-brand-logo {
  display: block;
  width: min(272px, 86vw);
  height: clamp(70px, 13vh, 96px);
  margin: 0 auto 6px;
  background-image: var(--theme-brand-logo-image);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center center;
  filter: drop-shadow(0 8px 26px rgba(0, 0, 0, 0.5));
}

/* Desktop Nav — above .header-right so flyout receives clicks at the corner */
.desktop-nav {
  display: flex;
  align-items: center;
  justify-self: start;
  min-width: 0;
  position: relative;
  z-index: 10020;
}

.desktop-nav > ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.6vw, 22px);
}

.desktop-nav > ul > li {
  margin: 0;
}

.nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 18px;
  min-height: 48px;
  font-size: clamp(0.88rem, 1.05vw, 0.98rem);
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  transition: color .2s, background .2s;
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1.2;
}

.nav-link > i {
  font-size: 0.92em;
  opacity: 0.88;
  width: 1.15em;
  text-align: center;
  flex-shrink: 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 6px; left: 16px; right: 16px;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transition: transform .2s;
  transform-origin: left;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
  transform: scaleX(1);
}

.nav-caret {
  font-size: .7rem;
  transition: transform .2s;
}

/* Dropdown */
.nav-dropdown {
  position: relative;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown:focus-within .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-dropdown:hover .nav-caret {
  transform: rotate(180deg);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  min-width: 200px;
  background: var(--bg-card2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity .2s, visibility .2s, transform .2s;
  box-shadow: var(--shadow-card);
}

.dropdown-menu a {
  display: block;
  padding: 9px 14px;
  font-size: .87rem;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  transition: color .15s, background .15s;
}
.dropdown-menu a:hover {
  color: var(--accent);
  background: var(--accent-dim);
}

/* v2-style Server Info flyout (same markup as moderver v2 / style.css) */
.nav-dd {
  position: relative;
}
/* Invisible hit area: closes the gap between button and menu so hover isn’t lost
   (menu had pointer-events:none until hover — cursor fell through the gap and the flyout vanished). */
.nav-dd::before {
  content: '';
  position: absolute;
  left: 0;
  width: 100%;
  top: 100%;
  height: 16px;
  z-index: 0;
}
.nav-dd-btn {
  font: inherit;
  cursor: pointer;
  text-transform: uppercase;
  font-size: clamp(0.88rem, 1.05vw, 0.98rem);
  font-weight: 600;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  min-height: 48px;
  border-radius: var(--radius-sm);
  border: 0;
  background: transparent;
  transition: color 0.2s, background 0.2s;
  line-height: 1.2;
}

.nav-dd-btn > i:first-of-type {
  font-size: 0.92em;
  opacity: 0.88;
  width: 1.15em;
  text-align: center;
  flex-shrink: 0;
}
.nav-dd-btn:hover {
  color: var(--text-primary);
  background: var(--accent-dim);
}
.nav-dd-chevron {
  font-size: 0.76rem;
  color: var(--text-dim);
  transition: transform 0.2s;
  margin-left: 2px;
  flex-shrink: 0;
}
.nav-dd:hover .nav-dd-chevron,
.nav-dd:focus-within .nav-dd-chevron {
  transform: rotate(180deg);
}
.nav-dd-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 220px;
  background: var(--bg-card2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-4px);
  transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
  z-index: 10030;
  box-shadow: var(--shadow-card);
}
.nav-dd:hover .nav-dd-menu,
.nav-dd:focus-within .nav-dd-menu,
.nav-dd.is-open .nav-dd-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}
.nav-dd.is-open .nav-dd-chevron {
  transform: rotate(180deg);
}
.nav-dd-menu a {
  display: block;
  padding: 10px 16px;
  font-size: 0.93rem;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  transition: color 0.15s, background 0.15s;
  text-decoration: none;
  cursor: pointer;
  position: relative;
  z-index: 1;
}
.nav-dd-menu a:hover {
  color: var(--accent);
  background: var(--accent-dim);
}
.nav-dd-menu a::after {
  display: none !important;
}
.nav-dd-sep {
  height: 1px;
  background: var(--border);
  margin: 6px 4px;
}

/* Right area */
.header-right {
  display: flex;
  align-items: center;
  gap: 16px;
  justify-self: end;
  flex-shrink: 0;
}

.header-auth {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-sm {
  padding: 8px 18px !important;
  font-size: .8rem !important;
}

/* Gold CTA in header (style.css uses .btn-gold; keep parity on theme/layout pages) */
.btn-gold {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 700;
}
.btn-gold:hover {
  background: transparent;
  color: var(--accent);
  box-shadow: var(--shadow-glow);
}

.header-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* Server select */
.server-select {
  background: var(--bg-input);
  color: var(--text-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 7px 12px;
  font-size: .83rem;
  font-weight: 500;
  cursor: pointer;
  outline: none;
  transition: border-color .2s;
}
.server-select:hover,
.server-select:focus {
  border-color: var(--accent-border);
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px; height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.hamburger span {
  display: block;
  height: 2px;
  background: var(--text-primary);
  border-radius: 1px;
  transition: transform .25s, opacity .25s;
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav */
.mobile-nav {
  display: none;
  flex-direction: column;
  gap: 2px;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
  padding: 16px 24px 20px;
}

.mobile-nav.open { display: flex; }

.mobile-nav a {
  padding: 10px 14px;
  font-size: .9rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  transition: color .15s, background .15s;
}
.mobile-nav a:hover { color: var(--accent); background: var(--accent-dim); }

.mobile-nav-auth {
  display: flex;
  gap: 10px;
  padding: 10px 14px 0;
}

/* ── USER CHIP (logged-in state) ── */
.user-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .84rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  transition: border-color .2s;
}
.user-chip:hover { border-color: var(--accent-border); }
.user-chip-avatar {
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--accent-dim);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
  font-size: .8rem;
}

/* ============================================================
   FOOTER
   ============================================================ */

#main-footer {
  background: var(--bg-void);
  border-top: 1px solid var(--border);
  padding: 64px 0 32px;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1.15fr;
  gap: 40px;
  padding-bottom: 48px;
  border-bottom: 1px solid var(--border);
}

.footer-col--legal ul a.footer-terms-all {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent);
  font-weight: 600;
}

.footer-col--legal ul a.footer-terms-all i {
  font-size: 0.75rem;
  transition: transform 0.2s;
}

.footer-col--legal ul a.footer-terms-all:hover i {
  transform: translateX(3px);
}

.footer-legal-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px 4px;
  padding: 20px 0 8px;
  margin-bottom: 8px;
}

.footer-legal-bar a {
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  transition: color 0.15s, background 0.15s;
}

.footer-legal-bar a:hover {
  color: var(--accent);
  background: var(--accent-dim);
}

.footer-legal-sep {
  color: var(--text-dim);
  font-size: 0.82rem;
  user-select: none;
}

.footer-brand .footer-logo {
  font-size: 1.2rem;
  margin-bottom: 14px;
  display: inline-flex;
}

.footer-tagline {
  color: var(--text-muted);
  font-size: .88rem;
  line-height: 1.7;
  margin-bottom: 20px;
  max-width: 280px;
}

.footer-socials {
  display: flex;
  gap: 10px;
}

.social-btn {
  width: 38px; height: 38px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: .9rem;
  transition: color .2s, border-color .2s, background .2s;
}
.social-btn:hover {
  color: var(--accent);
  border-color: var(--accent-border);
  background: var(--accent-dim);
}

.footer-heading {
  font-family: var(--font-display);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 18px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col ul a {
  color: var(--text-muted);
  font-size: .88rem;
  transition: color .15s;
}
.footer-col ul a:hover { color: var(--accent); }

.footer-bottom {
  padding-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: center;
}

.footer-copy,
.footer-disclaimer {
  color: var(--text-dim);
  font-size: .8rem;
}

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
  .desktop-nav > ul { gap: 6px; }
  .nav-link { padding: 10px 14px; min-height: 44px; font-size: 0.84rem; gap: 8px; }
  .nav-dd-btn { padding: 10px 14px; min-height: 44px; font-size: 0.84rem; gap: 8px; }
}

@media (max-width: 768px) {
  .desktop-nav { display: none; }
  /* Ultimul în flex era tăiat pe telefon — îl punem la începutul grupului header-right */
  .hamburger,
  #main-header .hamburger,
  #mobile-menu-toggle {
    display: flex !important;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    order: -20;
    flex: 0 0 auto;
    flex-shrink: 0;
    position: relative;
    z-index: 10040;
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    padding: 10px;
    box-sizing: border-box;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: rgba(0, 0, 0, 0.42);
    box-shadow: 0 2px 14px rgba(0, 0, 0, 0.35);
  }
  .hamburger span,
  #main-header .hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text-primary);
    border-radius: 1px;
    opacity: 0.92;
  }
  .header-auth { display: none; }
  .server-selector { display: none; }
  /* Bară dreapta: fără START ADVENTURE aici — e în meniul mobil (evită overlap cu hamburger) */
  #header-cta {
    display: none !important;
  }
  .header-right {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 6px;
    min-width: 0;
    max-width: 100%;
    justify-content: flex-end;
    overflow: visible;
  }
  #header-server-dd .dd-label,
  #header-lang-dd .dd-label {
    max-width: min(120px, 28vw);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .footer-brand { grid-column: 1 / -1; }
  .footer-col--legal { grid-column: 1 / -1; }
  .footer-legal-bar { gap: 4px 2px; padding: 16px 0 4px; }
}

@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
  .footer-legal-sep { display: none; }
  .footer-legal-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }
  .footer-legal-bar a { text-align: center; }
}

/* ── PAGE HERO (shared across all pages) ── */
.page-hero {
  width: 100%;
  background: rgba(19, 17, 23, 0.42);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  padding: 56px 0 48px;
  min-height: min(22rem, 52vh);
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 70% 100% at 50% 150%, var(--accent-glow), transparent 70%);
  pointer-events: none;
  z-index: 0;
}
/* hero-bage-1 … 6 — per theme (--theme-page-hero-badge-image în theme.css) */
.page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: var(--theme-page-hero-badge-image, url("../icon/hero-bage-1.png"));
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  opacity: 0.42;
  filter: saturate(1.05) contrast(1.06);
}
/* theme variants removed (single orange theme) */
.page-hero .container {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.page-hero .badge {
  margin-bottom: 18px;
}
.page-hero-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 900;
  letter-spacing: .04em;
  color: var(--text-primary);
  margin-bottom: 10px;
  max-width: min(48rem, 100%);
  width: 100%;
}
.page-hero-title span { color: var(--accent); }
.page-hero-sub {
  color: var(--text-muted);
  font-size: .95rem;
  line-height: 1.55;
  max-width: 36rem;
  width: 100%;
  margin: 0 auto;
}


/* ── HEADER DROPDOWNS ── */
.header-dd {
  position: relative;
}

.header-dd-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: clamp(0.86rem, 1vw, 0.94rem);
  font-weight: 600;
  cursor: pointer;
  transition: border-color .2s, color .2s;
  white-space: nowrap;
}
.header-dd-btn:hover { border-color: var(--accent-border); color: var(--text-primary); }

.dd-caret {
  font-size: .65rem;
  transition: transform .2s;
}
.header-dd-btn[aria-expanded="true"] .dd-caret { transform: rotate(180deg); }

.header-dd-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 160px;
  background: var(--bg-card2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 6px;
  box-shadow: var(--shadow-card);
  z-index: 500;
}

.dd-opt {
  padding: 9px 12px;
  font-size: .87rem;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: color .15s, background .15s;
}
.dd-opt:hover { color: var(--accent); background: var(--accent-dim); }
.dd-opt.active { color: var(--accent); font-weight: 700; }

/* Language dropdown: flags from /assets/images/flags/4x3/ */
.dd-label.dd-label--lang {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.dd-lang-code {
  font-weight: 800;
  letter-spacing: 0.06em;
  font-size: 0.78rem;
}
.dd-lang-flag {
  width: 22px;
  height: 16px;
  object-fit: cover;
  border-radius: 3px;
  flex-shrink: 0;
  box-shadow: 0 1px 4px color-mix(in srgb, var(--text-primary) 18%, transparent);
  border: 1px solid color-mix(in srgb, var(--border) 70%, var(--text-primary));
}
.dd-lang-flag--btn {
  width: 18px;
  height: 13px;
}
.dd-opt.dd-opt--lang {
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: none;
}
.dd-opt.dd-opt--lang .dd-lang-name {
  min-width: 0;
  flex: 1;
}

/* ── MOBILE MENU OVERLAY ── */
.mobile-menu-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
}

.mobile-menu-overlay.open {
  display: block;
  pointer-events: all;
}

.mobile-menu-inner {
  position: absolute;
  top: 0; right: 0;
  width: min(320px, 92vw);
  height: 100%;
  background: var(--bg-surface);
  border-left: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 0 16px 32px;
  overflow-y: auto;
  animation: slideInRight .25s ease;
}

@keyframes slideInRight {
  from { transform: translateX(100%); }
  to   { transform: translateX(0); }
}

.mm-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0 16px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 8px;
}

.mm-title {
  font-family: var(--font-display);
  font-size: .85rem;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--text-dim);
}

.mm-close {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 1.2rem;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
}
.mm-close:hover { color: var(--accent); border-color: var(--accent-border); }

.mm-link {
  display: block;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-decoration: none;
  transition: color .15s, background .15s;
  cursor: pointer;
}
.mm-link:hover, .mm-link.active { color: var(--accent); background: var(--accent-dim); }

.mm-group { display: flex; flex-direction: column; gap: 2px; }
.mm-sub { padding-left: 14px; display: flex; flex-direction: column; gap: 2px; }
.mm-sub .mm-link { font-size: .83rem; text-transform: none; letter-spacing: .02em; }

.mm-sep { height: 1px; background: var(--border); margin: 8px 0; }

.mm-cta-wrap {
  padding: 6px 0 4px;
}
.mm-cta-wrap .mm-cta-adventure {
  width: 100%;
  justify-content: center;
}

/* ── PROMPT / GENERIC MODAL ── */
.modal {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: none;
  align-items: center;
  justify-content: center;
}
.modal.show { display: flex; }

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.7);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.modal-content {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px 32px 28px;
  width: 100%;
  max-width: 440px;
  margin: 0 16px;
  box-shadow: var(--shadow-card);
  animation: fadeInUp .2s ease;
}

@keyframes fadeInUp {
  from { transform: translateY(16px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.modal-close {
  position: absolute;
  top: 14px; right: 16px;
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 1.1rem;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
}
.modal-close:hover { color: var(--accent); }

.modal-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.modal-message {
  color: var(--text-muted);
  font-size: .9rem;
  margin-bottom: 20px;
}

.modal-input-group { margin-bottom: 24px; }

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* ── RESPONSIVE: server/lang stay visible when multi-server (parity with moderver v2) ── */
@media (max-width: 768px) {
  #header-server-dd.header-dd,
  #header-lang-dd.header-dd {
    flex: 0 1 auto;
    min-width: 0;
  }
  #header-server-dd .header-dd-btn,
  #header-lang-dd .header-dd-btn {
    max-width: min(140px, 32vw);
    min-width: 0;
    padding-inline: 8px 10px;
  }
  .theme-switcher {
    flex-shrink: 0;
  }
}
