/* ==========================================================================
   EndRock website styles
   Colours/typography follow EndRock_Website_Claude_Kit/design_tokens.json
   ========================================================================== */

:root {
  --bg: #08050D;
  --bg-alt: #12081C;
  --panel: #171020;
  --panel-glass: rgba(20, 10, 31, .78);
  --purple-deep: #4E148C;
  --purple: #8B2BFF;
  --purple-glow: #C34BFF;
  --purple-light: #E1B2FF;
  --endstone: #E8D9AE;
  --text: #F8F5FF;
  --muted: #B9AEC8;
  --success: #55FF88;
  --danger: #FF6B8A;
  --border: rgba(181, 72, 255, .55);
  --border-soft: rgba(181, 72, 255, .22);

  --font-display: "Orbitron", "Segoe UI", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --maxw: 1280px;
  --header-h: 76px;
  --radius: 14px;
  --glow: 0 0 18px rgba(195, 75, 255, .45);
  color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  background:
    radial-gradient(1100px 600px at 85% -5%, rgba(139, 43, 255, .16), transparent 60%),
    radial-gradient(900px 600px at -10% 40%, rgba(78, 20, 140, .22), transparent 60%),
    var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--font-body);
}
main { flex: 1 0 auto; }
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--purple-light); text-underline-offset: 3px; }
a:hover { color: #fff; }
h1, h2, h3 { line-height: 1.2; }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--endstone); outline-offset: 3px; }
::selection { background: rgba(195, 75, 255, .45); color: #fff; }

.container { width: min(100% - 32px, var(--maxw)); margin-inline: auto; }
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 16px; top: -80px; z-index: 200;
  padding: 12px 18px; border-radius: 10px;
  background: var(--endstone); color: #140a24; font-weight: 700; text-decoration: none;
}
.skip-link:focus { top: 12px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 12px 26px; min-width: 176px;
  border-radius: 12px; border: 1px solid var(--border);
  font: 700 16px/1 var(--font-body); letter-spacing: .01em;
  color: var(--text); text-decoration: none; cursor: pointer;
  background: rgba(12, 6, 20, .72);
  transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease, border-color .2s ease;
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn:hover { color: #fff; border-color: var(--purple-glow); box-shadow: var(--glow); transform: translateY(-1px); }
.btn-primary {
  border-color: #d59bff;
  background: linear-gradient(180deg, #a64dff 0%, #7a1fe6 100%);
  box-shadow: 0 0 22px rgba(195, 75, 255, .5), inset 0 1px 0 rgba(255, 255, 255, .28);
}
.btn-primary:hover { background: linear-gradient(180deg, #b563ff 0%, #8a2bf5 100%); box-shadow: 0 0 30px rgba(195, 75, 255, .7), inset 0 1px 0 rgba(255, 255, 255, .3); }
.btn[aria-disabled="true"] { opacity: .62; cursor: not-allowed; box-shadow: none; transform: none; border-color: var(--border-soft); }
.btn .soon { font-weight: 600; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--endstone); }
.btn-sm { min-height: 44px; min-width: 0; padding: 10px 18px; font-size: 15px; }

.icon-btn {
  display: inline-grid; place-items: center;
  width: 44px; height: 44px; flex-shrink: 0;
  border-radius: 10px; border: 1px solid var(--border-soft);
  background: rgba(139, 43, 255, .08); color: var(--purple-light); cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s;
}
.icon-btn:hover { background: var(--purple); color: #fff; border-color: var(--purple-glow); }
.icon-btn svg { width: 20px; height: 20px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(8, 5, 13, .74);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid rgba(181, 72, 255, .32);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .35);
}
.site-header::after {
  content: ""; position: absolute; left: 8%; right: 8%; bottom: -1px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--purple-glow), transparent);
  pointer-events: none;
}
.header-inner { display: flex; align-items: center; gap: 20px; height: var(--header-h); }
.brand { display: flex; align-items: center; flex-shrink: 0; border-radius: 12px; }
.brand img { width: 64px; height: 64px; filter: drop-shadow(0 0 10px rgba(195, 75, 255, .45)); }

.main-nav { margin-inline: auto; }
.main-nav ul { display: flex; gap: 4px; margin: 0; padding: 0; list-style: none; }
.main-nav a {
  position: relative; display: flex; align-items: center; gap: 6px; padding: 10px 16px; border-radius: 10px;
  color: var(--text); font-weight: 500; font-size: 15px; text-decoration: none;
  transition: background-color .2s, color .2s;
}
.main-nav a:hover { background: rgba(139, 43, 255, .14); }
.main-nav a svg { width: 13px; height: 13px; opacity: .75; flex-shrink: 0; }
.main-nav a[aria-current="page"] { color: #fff; }
.main-nav a[aria-current="page"]::after {
  content: ""; position: absolute; left: 16px; right: 16px; bottom: 3px; height: 2px; border-radius: 2px;
  background: var(--purple-glow); box-shadow: 0 0 10px var(--purple-glow);
}

.ip-pill {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 44px; padding: 8px 12px 8px 14px;
  border: 1px solid var(--border); border-radius: 12px;
  background: rgba(18, 8, 28, .82); color: var(--text);
  font: 600 15px var(--font-body); cursor: pointer;
  box-shadow: inset 0 0 14px rgba(139, 43, 255, .16), 0 0 14px rgba(139, 43, 255, .18);
  transition: border-color .2s, box-shadow .2s;
}
.ip-pill:hover { border-color: var(--purple-glow); box-shadow: inset 0 0 14px rgba(139, 43, 255, .22), var(--glow); }
.ip-pill svg { width: 18px; height: 18px; color: var(--purple-light); }

.status-dot { width: 9px; height: 9px; border-radius: 50%; background: #6d6479; flex-shrink: 0; }
.status-dot[data-state="checking"] { background: #8a7f99; animation: blink 1.4s ease-in-out infinite; }
.status-dot[data-state="online"] { background: var(--success); box-shadow: 0 0 8px var(--success); }
.status-dot[data-state="offline"] { background: #ff5d73; box-shadow: 0 0 8px rgba(255, 93, 115, .6); }
.status-dot[data-state="unknown"] { background: #6d6479; }

.nav-toggle { display: none; }

@media (max-width: 1000px) {
  .nav-toggle { display: inline-grid; }
  .ip-pill { margin-left: auto; }
  .main-nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    padding: 8px 16px 18px; margin: 0;
    background: #0b0712; border-bottom: 1px solid var(--border);
    box-shadow: 0 20px 40px rgba(0, 0, 0, .5);
  }
  .main-nav.is-open { display: block; }
  .main-nav ul { flex-direction: column; gap: 2px; width: min(100%, var(--maxw)); margin-inline: auto; }
  .main-nav a { padding: 14px 12px; font-size: 17px; }
  .main-nav a[aria-current="page"] { background: rgba(139, 43, 255, .16); }
  .main-nav a[aria-current="page"]::after { left: 0; right: auto; top: 12px; bottom: 12px; width: 3px; height: auto; }
}
@media (max-width: 480px) {
  :root { --header-h: 68px; }
  .header-inner { gap: 10px; }
  .brand img { width: 54px; height: 54px; }
  .ip-pill { gap: 8px; padding: 8px 10px; font-size: 14px; }
}
@media (max-width: 350px) {
  .ip-pill .ip-text { display: none; }
}

/* ---------- Hero (home) ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; align-items: center;
  min-height: min(780px, calc(100vh - var(--header-h)));
  padding: 48px 0 56px;
}
.hero-bg { position: absolute; inset: 0; z-index: -4; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; opacity: .3; filter: saturate(1.1); }
.hero-art { position: absolute; top: 0; right: 0; bottom: 0; z-index: -3; width: min(66%, 1060px); }
.hero-art img {
  width: 100%; height: 100%; object-fit: cover; object-position: 50% 38%;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 32%), linear-gradient(180deg, #000 72%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(90deg, transparent 0%, #000 32%), linear-gradient(180deg, #000 72%, transparent 100%);
  mask-composite: intersect;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(8, 5, 13, .92) 0%, rgba(8, 5, 13, .7) 34%, rgba(8, 5, 13, .08) 64%, rgba(8, 5, 13, 0) 100%),
    linear-gradient(180deg, rgba(8, 5, 13, .35) 0%, transparent 18%, transparent 75%, var(--bg) 100%);
}
.hero-glow {
  position: absolute; z-index: -2; pointer-events: none;
  width: 520px; height: 520px; right: 20%; top: 8%;
  background: radial-gradient(circle, rgba(195, 75, 255, .32), rgba(139, 43, 255, .1) 45%, transparent 70%);
  animation: portal 6s ease-in-out infinite;
}
.particles { position: absolute; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.particles span {
  position: absolute; bottom: -20px; width: 6px; height: 6px;
  background: var(--purple-glow); box-shadow: 0 0 10px var(--purple-glow);
  opacity: 0; animation: rise 14s linear infinite;
}
.particles span:nth-child(1)  { left: 6%;  animation-delay: 0s;   animation-duration: 16s; }
.particles span:nth-child(2)  { left: 14%; animation-delay: 5s;   width: 4px; height: 4px; }
.particles span:nth-child(3)  { left: 24%; animation-delay: 9s;   animation-duration: 18s; }
.particles span:nth-child(4)  { left: 36%; animation-delay: 2s;   width: 5px; height: 5px; }
.particles span:nth-child(5)  { left: 47%; animation-delay: 11s;  animation-duration: 12s; }
.particles span:nth-child(6)  { left: 55%; animation-delay: 6s;   width: 8px; height: 8px; }
.particles span:nth-child(7)  { left: 63%; animation-delay: 1s;   animation-duration: 15s; }
.particles span:nth-child(8)  { left: 71%; animation-delay: 8s;   width: 4px; height: 4px; }
.particles span:nth-child(9)  { left: 79%; animation-delay: 3s;   animation-duration: 17s; }
.particles span:nth-child(10) { left: 86%; animation-delay: 12s;  width: 5px; height: 5px; }
.particles span:nth-child(11) { left: 92%; animation-delay: 7s;   animation-duration: 13s; }
.particles span:nth-child(12) { left: 98%; animation-delay: 10s;  width: 7px; height: 7px; }

.hero-inner { position: relative; }
.hero-content {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  width: min(100%, 680px);
}
.hero-logo { width: clamp(190px, 22vw, 300px); margin-bottom: -6px; filter: drop-shadow(0 0 26px rgba(195, 75, 255, .45)); }
.hero-title { margin: 0; font-family: var(--font-display); text-transform: uppercase; }
.hero-title .eyebrow {
  display: block; font-size: clamp(20px, 2.3vw, 30px); font-weight: 800; letter-spacing: .14em;
  color: var(--endstone); text-shadow: 0 0 16px rgba(232, 217, 174, .25);
}
.hero-title .big {
  display: block; margin-top: 4px;
  font-size: clamp(28px, 3.5vw, 50px); font-weight: 900; letter-spacing: .02em; line-height: 1.08;
  background: linear-gradient(180deg, #ffffff 0%, #f1ddff 42%, #c77dff 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 18px rgba(195, 75, 255, .55));
}
.hero-sub {
  margin: 12px 0 0; color: var(--muted);
  font: 600 clamp(12px, 1.15vw, 15px) var(--font-body); letter-spacing: .36em; text-transform: uppercase;
}
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 28px; }

.address-card {
  display: flex; align-items: center; gap: 14px;
  width: min(100%, 384px); margin-top: 18px; padding: 12px 12px 12px 16px;
  border: 1px solid var(--border); border-radius: 14px;
  background: var(--panel-glass);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  text-align: left;
}
.address-card > img { width: 38px; height: 38px; }
.address-meta { min-width: 0; }
.address-meta small { display: block; font: 600 11px var(--font-display); letter-spacing: .22em; color: var(--muted); text-transform: uppercase; }
.address-meta strong { display: block; font: 600 19px/1.35 var(--font-body); letter-spacing: .04em; overflow-wrap: anywhere; }
.address-card .icon-btn { margin-left: auto; }

.hero-meta { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px 18px; margin-top: 14px; font-size: 14px; color: var(--muted); }
.status-inline { display: inline-flex; align-items: center; gap: 8px; }

.notice-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px;
  border: 1px solid rgba(232, 217, 174, .35); background: rgba(232, 217, 174, .08);
  color: var(--endstone); font-size: 13px; font-weight: 500;
}
.notice-pill::before { content: ""; width: 7px; height: 7px; background: var(--endstone); transform: rotate(45deg); }
.is-live .testing-only { display: none !important; }
.live-only { display: none !important; }
.is-live .live-only { display: revert !important; }

@media (max-width: 900px) {
  .hero { flex-direction: column; align-items: stretch; min-height: 0; padding: 36px 0 0; }
  .hero-content { margin-inline: auto; }
  .hero-art { position: relative; z-index: -1; order: 2; width: 100%; height: clamp(220px, 62vw, 400px); margin-top: 20px; }
  .hero-art img {
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 22%, #000 70%, transparent 100%);
    mask-image: linear-gradient(180deg, transparent 0%, #000 22%, #000 70%, transparent 100%);
  }
  .hero::before { background: linear-gradient(180deg, rgba(8, 5, 13, .55) 0%, rgba(8, 5, 13, .35) 50%, var(--bg) 100%); }
  .hero-glow { right: -120px; top: auto; bottom: 0; }
}
@media (max-width: 420px) {
  .hero-actions .btn { width: 100%; }
  .hero-sub { letter-spacing: .22em; }
}

/* ---------- Sections ---------- */
.section { padding: 56px 0; }
.section-tight { padding: 28px 0 56px; }
.section-head { margin-bottom: 30px; text-align: center; }
.section-title {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  margin: 0; color: #fff;
  font: 900 clamp(22px, 2.6vw, 30px) var(--font-display); letter-spacing: .12em; text-transform: uppercase;
  text-shadow: 0 0 18px rgba(195, 75, 255, .6);
}
.section-title::before, .section-title::after {
  content: ""; flex: 0 1 200px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--purple-glow));
}
.section-title::after { transform: scaleX(-1); }
.section-title .dia {
  flex-shrink: 0; width: 9px; height: 9px; transform: rotate(45deg);
  border: 1.5px solid var(--purple-light); box-shadow: 0 0 8px var(--purple-glow);
}
.section-sub { margin: 10px 0 0; color: var(--muted); font: 600 12px var(--font-body); letter-spacing: .28em; text-transform: uppercase; }
@media (max-width: 560px) {
  .section-title::before, .section-title::after { display: none; }
  .section-sub { letter-spacing: .16em; }
}

/* ---------- Icon tiles ---------- */
.icon-tile {
  display: grid; place-items: center; flex-shrink: 0;
  width: 64px; height: 64px; border-radius: 12px;
  border: 1px solid var(--border);
  background: radial-gradient(circle at 50% 35%, rgba(139, 43, 255, .34), rgba(12, 7, 20, .96) 72%);
  box-shadow: inset 0 0 14px rgba(195, 75, 255, .22);
}
.icon-tile img { width: 40px; height: 40px; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .6)); }
.arrow-box {
  display: grid; place-items: center; flex-shrink: 0;
  width: 40px; height: 40px; border-radius: 10px;
  border: 1px solid var(--border); background: rgba(139, 43, 255, .08); color: var(--purple-light);
  transition: background-color .2s, color .2s, box-shadow .2s;
}
.arrow-box svg { width: 18px; height: 18px; }

/* ---------- Game-mode cards ---------- */
.modes-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.mode-card {
  position: relative; overflow: hidden;
  border: 1px solid var(--border-soft); border-radius: 18px;
  background: linear-gradient(180deg, rgba(23, 16, 32, .94), rgba(12, 7, 20, .96));
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.mode-card:hover, .mode-card:focus-within {
  transform: translateY(-4px); border-color: var(--border);
  box-shadow: 0 14px 40px rgba(0, 0, 0, .45), 0 0 26px rgba(139, 43, 255, .3);
}
.mode-media { position: relative; aspect-ratio: 3 / 1; overflow: hidden; background: var(--bg-alt); }
.mode-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.mode-card:hover .mode-media img { transform: scale(1.04); }
.mode-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 35%, rgba(12, 7, 20, .96) 100%); }
.mode-card.is-soon .mode-media img { filter: saturate(.55) brightness(.72); }
.badge {
  position: absolute; top: 12px; right: 12px; z-index: 2;
  padding: 5px 10px; border-radius: 8px;
  border: 1px solid var(--border); background: rgba(8, 5, 13, .82);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  color: var(--purple-light); font: 700 11px var(--font-display); letter-spacing: .12em; text-transform: uppercase;
}
.badge-live { color: var(--success); border-color: rgba(85, 255, 136, .5); }
.badge-testing { color: var(--endstone); border-color: rgba(232, 217, 174, .45); }
.mode-body {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 64px 1fr 40px; align-items: center; gap: 14px;
  margin-top: -26px; padding: 0 16px 18px;
}
.mode-title { margin: 0; font: 800 19px var(--font-display); letter-spacing: .06em; text-transform: uppercase; }
.mode-title a { color: #fff; text-decoration: none; }
.mode-title a::after { content: ""; position: absolute; inset: 0; z-index: 3; }
.mode-title a:focus-visible { outline: none; }
.mode-card:has(a:focus-visible) { outline: 2px solid var(--endstone); outline-offset: 3px; }
.mode-text { margin: 4px 0 0; color: var(--muted); font-size: 14.5px; line-height: 1.45; }
.mode-card:hover .arrow-box, .explore-card:hover .arrow-box { background: var(--purple); color: #fff; box-shadow: var(--glow); }
@media (max-width: 960px) {
  .modes-grid { grid-template-columns: 1fr; max-width: 600px; margin-inline: auto; }
}

/* ---------- Explore cards ---------- */
.explore-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.explore-card {
  display: grid; grid-template-columns: 56px 1fr 36px; align-items: center; gap: 14px;
  padding: 16px; border-radius: 16px;
  border: 1px solid var(--border-soft); background: rgba(20, 10, 31, .74);
  color: var(--text); text-decoration: none;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.explore-card:hover { color: var(--text); transform: translateY(-3px); border-color: var(--border); box-shadow: 0 12px 30px rgba(0, 0, 0, .4), 0 0 20px rgba(139, 43, 255, .25); }
.explore-card .icon-tile { width: 56px; height: 56px; }
.explore-card .icon-tile img { width: 34px; height: 34px; }
.explore-card .arrow-box { width: 36px; height: 36px; }
.explore-card h3 { margin: 0; font: 800 13.5px var(--font-display); letter-spacing: .08em; text-transform: uppercase; }
.explore-card p { margin: 4px 0 0; color: var(--muted); font-size: 13.5px; line-height: 1.4; }
@media (max-width: 1150px) { .explore-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .explore-grid { grid-template-columns: 1fr; } }

/* ---------- Sub-page hero ---------- */
.page-hero {
  position: relative; isolation: isolate; overflow: hidden;
  padding: 72px 0 52px; border-bottom: 1px solid var(--border-soft);
}
.page-hero .bg { position: absolute; inset: 0; z-index: -2; }
.page-hero .bg img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; opacity: .42; }
.page-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, rgba(8, 5, 13, .94) 0%, rgba(8, 5, 13, .72) 55%, rgba(8, 5, 13, .45) 100%),
              linear-gradient(180deg, transparent 60%, var(--bg) 100%);
}
.kicker { margin: 0 0 10px; color: var(--purple-light); font: 700 12px var(--font-display); letter-spacing: .24em; text-transform: uppercase; }
.page-hero h1 {
  margin: 0; font: 900 clamp(28px, 4.2vw, 48px) var(--font-display); letter-spacing: .05em; text-transform: uppercase;
  text-shadow: 0 0 22px rgba(195, 75, 255, .5);
}
.page-hero .lead { max-width: 680px; margin: 14px 0 0; color: var(--muted); font-size: 17.5px; }
.page-hero .hero-actions { justify-content: flex-start; }

/* ---------- Content layout ---------- */
.panel {
  padding: 28px; border-radius: 18px;
  border: 1px solid var(--border-soft); background: var(--panel-glass);
}
.panel > :last-child { margin-bottom: 0; }
.panel h2, .prose h2 { margin: 0 0 12px; font: 800 20px var(--font-display); letter-spacing: .06em; text-transform: uppercase; }
.panel h3, .prose h3 { margin: 22px 0 8px; font: 700 17px var(--font-body); color: #fff; }
.prose p, .prose li { color: #e2dbee; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin: 6px 0; }
.muted { color: var(--muted); }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.layout-aside { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.stack > * + * { margin-top: 20px; }
@media (max-width: 900px) {
  .grid-2, .grid-3, .layout-aside { grid-template-columns: 1fr; }
  .panel { padding: 22px; }
}

.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; }
.steps li { position: relative; padding: 4px 0 14px 52px; color: #e2dbee; }
.steps li::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0;
  display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px;
  border: 1px solid var(--border); background: rgba(139, 43, 255, .14);
  color: #fff; font: 800 15px var(--font-display);
}
.steps strong { color: #fff; }

.info-list { display: grid; grid-template-columns: auto 1fr; gap: 10px 18px; margin: 0; }
.info-list dt { color: var(--muted); font-weight: 500; }
.info-list dd { margin: 0; color: #fff; font-weight: 600; }

.tag {
  display: inline-block; padding: 3px 9px; border-radius: 7px; vertical-align: middle;
  border: 1px solid var(--border); color: var(--purple-light);
  font: 700 10.5px var(--font-display); letter-spacing: .12em; text-transform: uppercase;
}
.tag-soon { color: var(--endstone); border-color: rgba(232, 217, 174, .45); }

.callout {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 16px 18px; border-radius: 14px;
  border: 1px solid rgba(232, 217, 174, .3); background: rgba(232, 217, 174, .06);
  color: #efe6c9; font-size: 15px;
}
.callout p { margin: 0; }

.narrow { width: min(100% - 32px, 900px); }
.center-text { text-align: center; margin-top: 18px; }
.mode-body-static { margin-top: 0; padding: 0; grid-template-columns: 64px 1fr; }
.mode-title .tag { margin-left: 8px; }
.panel picture img { border-radius: 12px; border: 1px solid var(--border-soft); }
.panel .address-card { width: 100%; margin: 4px 0 14px; }
.panel .panel-title { margin-top: 16px; font-size: 17px; }
.showcase { margin: 28px 0 0; }
.showcase img { width: 100%; border-radius: 18px; border: 1px solid var(--border-soft); box-shadow: 0 20px 50px rgba(0, 0, 0, .45), 0 0 30px rgba(139, 43, 255, .2); }
/* ---------- Accordions (rules + FAQ) ---------- */
.accordion { display: grid; gap: 12px; }
.accordion details {
  border: 1px solid var(--border-soft); border-radius: 14px;
  background: rgba(20, 10, 31, .74);
  transition: border-color .2s;
}
.accordion details[open] { border-color: var(--border); }
.accordion summary {
  display: flex; align-items: center; gap: 14px;
  min-height: 58px; padding: 14px 20px; cursor: pointer; list-style: none;
  font: 700 16px var(--font-body); color: #fff; border-radius: 14px;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after {
  content: ""; flex-shrink: 0; margin-left: auto; width: 10px; height: 10px;
  border-right: 2px solid var(--purple-light); border-bottom: 2px solid var(--purple-light);
  transform: rotate(45deg) translate(-2px, -2px); transition: transform .2s;
}
.accordion details[open] > summary::after { transform: rotate(-135deg) translate(-2px, -2px); }
.accordion summary:hover { background: rgba(139, 43, 255, .08); }
.accordion .acc-body { padding: 2px 20px 18px; color: #e2dbee; }
.accordion .acc-body > :last-child { margin-bottom: 0; }
.rules summary { font: 800 16px var(--font-display); letter-spacing: .06em; text-transform: uppercase; }
.rules summary .num { color: var(--purple-light); font-size: 13px; letter-spacing: .1em; }
.rules ol { margin: 0; padding-left: 1.3em; }
.rules li { margin: 8px 0; }

/* ---------- Forms ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; margin-bottom: 6px; font-weight: 600; font-size: 14px; color: #fff; }
.field .opt { color: var(--muted); font-weight: 400; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: 11px 14px;
  border-radius: 10px; border: 1px solid rgba(181, 72, 255, .36);
  background: rgba(8, 5, 13, .82); color: var(--text);
  font: 400 16px/1.4 var(--font-body);
  transition: border-color .2s, box-shadow .2s;
}
.field select { appearance: none; -webkit-appearance: none; padding-right: 40px; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--purple-light) 50%), linear-gradient(135deg, var(--purple-light) 50%, transparent 50%);
  background-position: calc(100% - 20px) 21px, calc(100% - 15px) 21px; background-size: 5px 5px; background-repeat: no-repeat; }
.field select option { background: var(--bg-alt); color: var(--text); }
.field textarea { min-height: 150px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #7f7490; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--purple-glow); box-shadow: 0 0 0 3px rgba(195, 75, 255, .35);
}
.field [aria-invalid="true"] { border-color: var(--danger); }
.field-error { margin-top: 6px; color: #ffb3c3; font-size: 13.5px; }
.field-error:empty { display: none; }
.field-hint { margin-top: 6px; color: var(--muted); font-size: 13px; }
.hp-field { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 18px; }
.form-foot .privacy { margin: 0; color: var(--muted); font-size: 13px; flex: 1 1 220px; }
.form-status { margin-top: 14px; padding: 12px 14px; border-radius: 10px; font-size: 14.5px; }
.form-status:empty { display: none; }
.form-status.is-success { border: 1px solid rgba(85, 255, 136, .4); background: rgba(85, 255, 136, .08); color: #c3ffd6; }
.form-status.is-error { border: 1px solid rgba(255, 107, 138, .45); background: rgba(255, 107, 138, .08); color: #ffc9d4; }
.btn.is-loading { opacity: .75; cursor: progress; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer {
  position: relative; margin-top: 48px;
  border-top: 1px solid rgba(181, 72, 255, .32);
  background: linear-gradient(180deg, rgba(18, 8, 28, .92), #07040b);
}
.site-footer::before {
  content: ""; position: absolute; left: 10%; right: 10%; top: -1px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--purple-glow), transparent);
}
.footer-grid { display: flex; flex-wrap: wrap; gap: 32px 40px; padding: 40px 0 30px; }
.footer-grid > * { flex: 1 1 200px; }
.footer-grid > .footer-brand { flex: 1.6 1 300px; }
.footer-brand { display: flex; align-items: center; gap: 18px; }
.footer-brand img { width: 92px; height: 92px; filter: drop-shadow(0 0 12px rgba(195, 75, 255, .4)); }
.footer-brand strong { display: block; font: 800 18px var(--font-display); letter-spacing: .06em; }
.footer-brand p { margin: 2px 0 0; color: var(--muted); font-size: 14px; }
.footer-brand .motto { margin-top: 6px; color: #8f84a0; font-size: 13px; letter-spacing: .06em; }
.site-footer h2 { margin: 0 0 12px; font: 700 13px var(--font-display); letter-spacing: .16em; text-transform: uppercase; color: #fff; }
.footer-links ul { columns: 2; column-gap: 24px; margin: 0; padding: 0; list-style: none; }
.footer-links a { display: inline-block; padding: 5px 0; color: var(--muted); text-decoration: none; font-size: 14.5px; }
.footer-links a:hover { color: #fff; }
.social-list { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; list-style: none; }
.social-list a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px;
  border-radius: 10px; border: 1px solid var(--border-soft); color: var(--text); text-decoration: none; font-size: 14px;
}
.social-list a:hover { border-color: var(--purple-glow); box-shadow: var(--glow); }
.footer-status .status-line { display: flex; align-items: center; gap: 8px; margin: 0 0 4px; font-weight: 700; }
.footer-status p { margin: 0 0 2px; color: var(--muted); font-size: 14px; }
.footer-bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
  padding: 16px 96px 24px 0; border-top: 1px solid rgba(181, 72, 255, .14);
  color: #8f84a0; font-size: 13px;
}
.footer-bottom p { margin: 0; }
@media (max-width: 640px) {
  .footer-bottom { padding: 16px 0 104px; }
  .footer-brand img { width: 72px; height: 72px; }
}

/* ---------- Support widget ---------- */
.support {
  position: fixed; z-index: 60;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
}
.support-launcher {
  position: relative; display: grid; place-items: center;
  width: 66px; height: 66px; padding: 0; border-radius: 50%; cursor: pointer;
  border: 2px solid #b44cff;
  background: radial-gradient(circle at 50% 40%, #2d1349, #0c0614 72%);
  box-shadow: 0 0 0 4px rgba(139, 43, 255, .16), 0 0 22px rgba(195, 75, 255, .55), 0 10px 26px rgba(0, 0, 0, .5);
  animation: ring 3.2s ease-in-out infinite;
  transition: transform .2s;
}
.support-launcher:hover { transform: scale(1.06); }
.support-launcher img { width: 36px; height: 36px; filter: drop-shadow(0 0 6px rgba(195, 75, 255, .8)); }
.support-dot {
  position: absolute; top: 1px; right: 1px; width: 14px; height: 14px; border-radius: 50%;
  background: var(--purple-light); border: 2px solid #0c0614; box-shadow: 0 0 10px var(--purple-glow);
}
.support-launcher[aria-expanded="true"] .support-dot { display: none; }
.support-panel {
  position: absolute; right: 0; bottom: calc(100% + 16px);
  width: min(370px, calc(100vw - 32px));
  max-height: calc(100vh - var(--header-h) - 120px);
  max-height: calc(100dvh - var(--header-h) - 120px);
  overflow: auto; overscroll-behavior: contain;
  padding: 20px; border-radius: 18px;
  border: 1px solid var(--border);
  background: rgba(16, 8, 26, .97);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  box-shadow: 0 20px 50px rgba(0, 0, 0, .6), 0 0 30px rgba(139, 43, 255, .32);
  transform-origin: bottom right; animation: pop .2s ease-out;
}
.support-panel[hidden] { display: none; }
.support-panel:focus { outline: none; }
.support-close { position: absolute; top: 10px; right: 10px; width: 40px; height: 40px; border: 0; background: transparent; }
.support-intro { display: grid; grid-template-columns: 78px 1fr; gap: 14px; align-items: start; padding-right: 26px; }
.support-avatar {
  display: grid; place-items: center; width: 78px; height: 78px; border-radius: 14px;
  border: 1px solid var(--border);
  background: radial-gradient(circle at 50% 42%, rgba(139, 43, 255, .5), #0c0614 72%);
}
.support-avatar img { width: 52px; height: 52px; filter: drop-shadow(0 0 8px rgba(195, 75, 255, .7)); }
.support-panel h2 { margin: 2px 0 0; font: 800 20px var(--font-body); }
.support-sub { margin: 2px 0 6px; color: var(--purple-light); font-weight: 600; font-size: 14px; }
.support-text { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.support-start { width: 100%; margin-top: 16px; }
.support-panel .form-grid { grid-template-columns: 1fr; gap: 12px; margin-top: 16px; }
.support-panel .field textarea { min-height: 110px; }
.support-panel .form-foot .btn { width: 100%; }
.support-alt { margin: 12px 0 0; color: var(--muted); font-size: 13px; text-align: center; }
.nav-open .support { display: none; }
@media (max-width: 560px) {
  .support-launcher { width: 60px; height: 60px; }
  .support-panel {
    position: fixed; left: 12px; right: 12px; width: auto;
    bottom: calc(92px + env(safe-area-inset-bottom));
    max-height: calc(100vh - 92px - 84px);
    max-height: calc(100dvh - 92px - 84px);
  }
}

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 80;
  width: max-content; max-width: min(92vw, 480px);
  padding: 12px 18px; border-radius: 12px;
  border: 1px solid var(--border); background: rgba(16, 8, 26, .97);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .5), var(--glow);
  color: #fff; font-size: 14.5px; text-align: center;
  opacity: 0; transform: translate(-50%, 16px); pointer-events: none;
  transition: opacity .25s, transform .25s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 404 ---------- */
.lost { padding: 96px 0; text-align: center; }
.lost img { width: 120px; height: 120px; margin: 0 auto 18px; filter: drop-shadow(0 0 22px rgba(195, 75, 255, .7)); }
.lost h1 { margin: 0; font: 900 clamp(30px, 5vw, 56px) var(--font-display); letter-spacing: .06em; text-transform: uppercase; }
.lost p { max-width: 520px; margin: 14px auto 0; color: var(--muted); font-size: 17px; }
.lost .hero-actions { margin-top: 26px; }

/* ---------- Animations ---------- */
@keyframes blink { 50% { opacity: .35; } }
@keyframes portal { 0%, 100% { opacity: .75; transform: scale(1); } 50% { opacity: 1; transform: scale(1.08); } }
@keyframes rise {
  0% { transform: translateY(0) rotate(0deg); opacity: 0; }
  10% { opacity: .9; }
  80% { opacity: .6; }
  100% { transform: translateY(-110vh) rotate(180deg); opacity: 0; }
}
@keyframes ring {
  0%, 100% { box-shadow: 0 0 0 4px rgba(139, 43, 255, .16), 0 0 18px rgba(195, 75, 255, .45), 0 10px 26px rgba(0, 0, 0, .5); }
  50% { box-shadow: 0 0 0 7px rgba(139, 43, 255, .1), 0 0 30px rgba(195, 75, 255, .7), 0 10px 26px rgba(0, 0, 0, .5); }
}
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.97); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .particles { display: none; }
}
