/* =========================================================
   Hypnotic 2 – Stylesheet
   ========================================================= */
:root {
  --abyss: #040a18;
  --deep: #0a1430;
  --steel: #16264c;
  --line: rgba(159, 216, 255, .14);
  --blue: #3a8dff;
  --blue-hi: #6aaeff;
  --ice: #9fd8ff;
  --text: #e6eeff;
  --muted: #8d9cc4;
  --ok: #4fe3a2;
  --bad: #ff6b7d;

  --font-display: "Cinzel", "Trajan Pro", Georgia, serif;
  --font-body: "Manrope", "Segoe UI", system-ui, -apple-system, sans-serif;

  --wrap: 1180px;
  --radius-s: 6px;
  --radius-m: 12px;
  --header-h: 72px;

  color-scheme: dark;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
*, *::before, *::after { box-sizing: inherit; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + env(safe-area-inset-top, 0px)); }
body {
  margin: 0;
  background: var(--abyss);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--ice); text-decoration: none; }
a:hover { color: #fff; }
:focus-visible { outline: 2px solid var(--ice); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; line-height: 1.15; margin: 0; letter-spacing: .01em; }
p { margin: 0; }

.wrap { width: min(var(--wrap), 100% - 2.5rem); margin-inline: auto; }

.skip { position: absolute; left: -999px; top: 0; background: var(--blue); color: #fff; padding: .6rem 1rem; z-index: 100; }
.skip:focus { left: 1rem; top: 1rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: .5rem; border: 1px solid transparent; cursor: pointer;
  font: 600 .95rem/1 var(--font-body);
  padding: .8rem 1.3rem; border-radius: var(--radius-s);
  transition: background .2s, border-color .2s, color .2s, box-shadow .2s;
  color: var(--text); background: none; white-space: nowrap;
}
.btn-lg { padding: 1rem 1.7rem; font-size: 1rem; }
.btn-sm { padding: .55rem .95rem; font-size: .88rem; }
.btn-block { width: 100%; }
.btn-primary {
  background: linear-gradient(180deg, #4b9bff, #2a6fe0);
  border-color: #6aaeff;
  color: #fff;
  box-shadow: 0 0 0 1px rgba(58,141,255,.25), 0 8px 30px -8px rgba(58,141,255,.7);
}
.btn-primary:hover { background: linear-gradient(180deg, #62a9ff, #3a80f0); color: #fff; box-shadow: 0 0 0 1px rgba(159,216,255,.4), 0 10px 36px -6px rgba(58,141,255,.9); }
.btn-ghost { border-color: var(--line); background: rgba(10,20,48,.5); }
.btn-ghost:hover { border-color: var(--ice); color: #fff; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  height: var(--header-h);
  background: rgba(4,10,24,.55);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: background .3s, border-color .3s;
}
body::before {
  content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px);
  z-index: 51; background: rgba(4,10,24,.9);
}
.site-header.is-scrolled { background: rgba(4,10,24,.88); border-color: var(--line); }
.header-inner { height: 100%; display: flex; align-items: center; gap: 2rem; }

.brand { white-space: nowrap; display: inline-flex; align-items: center; gap: .6rem; color: var(--text); font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; letter-spacing: .04em; }
.brand b { color: var(--ice); }
.brand-mark { width: 42px; height: 42px; filter: drop-shadow(0 0 8px rgba(58,141,255,.6)); }
.footer-emblem { width: 64px; height: 64px; filter: drop-shadow(0 0 12px rgba(58,141,255,.5)); }
.modal-emblem { display: block; width: 84px; height: 84px; margin: -.5rem auto 1rem; filter: drop-shadow(0 0 16px rgba(58,141,255,.7)); }

.main-nav { display: flex; gap: 1.5rem; margin-left: .5rem; }
.main-nav a { color: var(--muted); font-weight: 600; font-size: .95rem; position: relative; padding: .3rem 0; }
.main-nav a:hover, .main-nav a.is-active { color: var(--text); }
.main-nav a.is-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px; background: var(--blue); box-shadow: 0 0 10px var(--blue); }

.header-tools { margin-left: auto; display: flex; align-items: center; gap: .8rem; }

.lang { position: relative; }
.lang-btn { display: flex; align-items: center; gap: .35rem; background: none; border: 1px solid var(--line); color: var(--text); border-radius: var(--radius-s); padding: .5rem .7rem; font: 600 .85rem var(--font-body); cursor: pointer; }
.lang-btn svg { width: 12px; height: 12px; }
.lang-btn:hover { border-color: var(--ice); }
.lang-menu { position: absolute; right: 0; top: calc(100% + 8px); list-style: none; margin: 0; padding: .35rem; min-width: 150px; background: var(--deep); border: 1px solid var(--line); border-radius: var(--radius-m); box-shadow: 0 20px 50px -10px rgba(0,0,0,.7); }
.lang-menu button { width: 100%; text-align: left; background: none; border: 0; color: var(--text); padding: .55rem .75rem; border-radius: var(--radius-s); font: 500 .92rem var(--font-body); cursor: pointer; }
.lang-menu button:hover, .lang-menu button[aria-selected="true"] { background: var(--steel); }

.account-in { display: flex; align-items: center; gap: .8rem; }
.account-name { font-size: .88rem; color: var(--muted); }
.account-name b { color: var(--text); }

.nav-toggle { display: none; width: 42px; height: 42px; background: none; border: 1px solid var(--line); border-radius: var(--radius-s); cursor: pointer; flex-direction: column; justify-content: center; align-items: center; gap: 5px; }
.nav-toggle span { display: block; width: 18px; height: 1.5px; background: var(--text); transition: transform .25s, opacity .25s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  min-height: min(100vh, 920px);
  margin-top: calc(var(--header-h) * -1);
  padding-top: var(--header-h);
  display: grid; align-items: center;
  background: #06142e;
}
.hero-bg { position: absolute; inset: 0; }
.hero-art {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: 20% 30%;
}
.hero-bg::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(90deg, transparent 35%, rgba(4,10,24,.35) 60%, rgba(4,10,24,.7) 100%),
    linear-gradient(180deg, rgba(4,10,24,.5) 0%, transparent 18%, transparent 70%, var(--abyss) 100%);
}
#sparks { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; }

.hero-content { position: relative; z-index: 2; display: flex; justify-content: flex-end; padding-block: 4rem 5rem; }
.hero-panel { width: min(560px, 100%); text-align: center; }

/* Logo */
.logo { margin: 0; display: flex; justify-content: center; }
.logo-anim { display: block; width: min(560px, 100%); height: auto; }

.hero-tagline { text-wrap: balance; margin-top: 1.6rem; font-family: var(--font-display); font-size: clamp(1.1rem, 2vw, 1.4rem); font-weight: 600; color: var(--ice); text-shadow: 0 2px 12px rgba(0,0,0,.7); }
.hero-sub { text-wrap: pretty; margin: .9rem auto 0; max-width: 46ch; color: #b8c6e6; font-size: 1.02rem; text-shadow: 0 1px 10px rgba(0,0,0,.8); }
.hero-cta { margin-top: 2rem; display: flex; gap: .9rem; justify-content: center; flex-wrap: wrap; }

.live {
  margin: 2.4rem auto 0; display: inline-flex; align-items: baseline; gap: .55rem;
  padding: .7rem 1.2rem; border-radius: 999px;
  background: rgba(10,20,48,.7); border: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--muted); align-self: center; }
.live-num { font-family: var(--font-display); font-weight: 700; font-size: 1.35rem; font-variant-numeric: tabular-nums; }
.live-label { color: var(--muted); font-size: .92rem; }
.live[data-state="online"] .live-dot { background: var(--ok); box-shadow: 0 0 0 0 rgba(79,227,162,.6); animation: pulse 2s infinite; }
.live[data-state="offline"] .live-dot { background: var(--bad); }
.live[data-state="offline"] .live-num, .live[data-state="unknown"] .live-num, .live[data-state="loading"] .live-num { display: none; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(79,227,162,0); } 100% { box-shadow: 0 0 0 0 rgba(79,227,162,0); } }

/* ---------- Stats ---------- */
.stats { border-block: 1px solid var(--line); background: linear-gradient(90deg, rgba(58,141,255,.06), rgba(58,141,255,.02), rgba(58,141,255,.06)); }
.stats-row { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 1.6rem 1rem; text-align: center; display: flex; flex-direction: column; gap: .2rem; }
.stat + .stat { border-left: 1px solid var(--line); }
.stat-num { font-family: var(--font-display); font-size: 1.7rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat-label { color: var(--muted); font-size: .88rem; }

/* ---------- Sections ---------- */
.section { padding-block: clamp(4rem, 9vw, 7rem); }
.section-alt { background: linear-gradient(180deg, var(--deep), var(--abyss)); }
.section-head { margin-bottom: 2.8rem; max-width: 62ch; }
.section-head h2 { font-size: clamp(2rem, 4vw, 2.9rem); }
.section-head p { margin-top: .7rem; color: var(--muted); font-size: 1.05rem; }

/* ---------- Servers ---------- */
.servers { display: grid; grid-template-columns: 1.35fr 1fr; gap: 1.5rem; align-items: stretch; }
.server {
  position: relative; padding: 2.2rem; border-radius: var(--radius-m);
  border: 1px solid var(--line);
  background: linear-gradient(160deg, rgba(22,38,76,.9), rgba(10,20,48,.9));
  display: flex; flex-direction: column; gap: 1.1rem; overflow: hidden;
}
.server.is-live { border-color: rgba(106,174,255,.45); box-shadow: 0 30px 80px -40px rgba(58,141,255,.8); }
.server.is-live::before {
  content: ""; position: absolute; right: -120px; top: -120px; width: 320px; height: 320px; border-radius: 50%;
  border: 1px dashed rgba(159,216,255,.25); box-shadow: inset 0 0 0 40px rgba(58,141,255,.04);
}
.server.is-soon { border-style: dashed; background: rgba(10,20,48,.55); }
.server.has-art { border-style: solid; border-color: rgba(95,212,255,.3); background: linear-gradient(180deg, rgba(10,24,52,.95), rgba(10,20,48,.8)); }
.server-art { position: relative; margin: -2.2rem -2.2rem .2rem; height: 190px; overflow: hidden; border-bottom: 1px solid rgba(95,212,255,.25); }
.server-art img { width: 100%; height: 100%; object-fit: cover; object-position: 55% 40%; transition: transform .6s; }
.server-art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(10,24,52,.95)); }
.server.has-art:hover .server-art img { transform: scale(1.04); }
.server.has-art .badge { position: absolute; top: 1rem; right: 1rem; z-index: 1; background: rgba(4,10,24,.75); backdrop-filter: blur(6px); }
.server-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; }
.server h3 { font-size: 1.7rem; }
.server-type { color: var(--ice); font-weight: 600; margin-top: .3rem; font-size: .95rem; }
.server-desc { color: var(--muted); max-width: 54ch; }
.badge { display: inline-flex; align-items: center; gap: .4rem; padding: .3rem .7rem; border-radius: 999px; font-size: .8rem; font-weight: 700; border: 1px solid var(--line); white-space: nowrap; }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.badge.on { color: var(--ok); border-color: rgba(79,227,162,.35); }
.badge.off { color: var(--bad); border-color: rgba(255,107,125,.35); }
.badge.soon, .badge.unknown { color: var(--muted); }
.rates { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-s); overflow: hidden; margin: 0; }
.rates div { background: rgba(4,10,24,.6); padding: .8rem 1rem; }
.rates dt { color: var(--muted); font-size: .8rem; }
.rates dd { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; }
.server .btn { align-self: flex-start; margin-top: auto; }



/* ---------- Classes ---------- */
.classes { position: relative; overflow: hidden; background: radial-gradient(ellipse at 50% 60%, rgba(58,141,255,.12), transparent 60%); }
.cls { display: grid; grid-template-columns: 220px 1fr 1fr; gap: 2.5rem; align-items: center; }
.cls-tabs { display: flex; flex-direction: column; gap: .5rem; }
.cls-tab {
  display: flex; align-items: center; gap: .9rem; width: 100%;
  padding: .6rem .9rem .6rem .6rem; border-radius: var(--radius-m);
  border: 1px solid var(--line); background: rgba(10,20,48,.5);
  color: var(--muted); font: 700 1.05rem var(--font-display); text-align: left; cursor: pointer;
  transition: border-color .2s, background .2s, color .2s;
}
.cls-tab:hover { color: var(--text); border-color: rgba(159,216,255,.35); }
.cls-tab[aria-selected="true"] { color: var(--text); border-color: var(--blue); background: linear-gradient(90deg, rgba(58,141,255,.22), rgba(10,20,48,.5)); box-shadow: 0 0 24px -8px rgba(58,141,255,.8); }
.cls-thumb { width: 46px; height: 46px; border-radius: 50%; flex: none; overflow: hidden; background: var(--steel); border: 1px solid var(--line); }
.cls-thumb img { width: 220%; max-width: none; height: auto; margin-left: -60%; margin-top: 2px; }
.cls-stage { position: relative; height: 440px; display: flex; justify-content: center; align-items: flex-end; gap: 0; }
.cls-pedestal { position: absolute; left: 50%; bottom: 0; width: min(440px, 100%); transform: translateX(-50%); }
.cls-fig { position: relative; height: 400px; width: auto; margin-bottom: 30px; filter: drop-shadow(0 10px 30px rgba(58,141,255,.5)); transition: opacity .3s, transform .3s; }
.cls-fig-m { margin-right: -36px; z-index: 1; }
.cls-fig-f { margin-left: -36px; }
.cls-stage.is-swapping .cls-fig { opacity: 0; transform: translateY(10px); }
.cls-stage.is-single .cls-fig-m { margin-right: 0; }
.cls-role { color: var(--ice); font-weight: 600; }
.cls-info h3 { font-size: clamp(2rem, 4vw, 3rem); margin: .3rem 0 1rem; }
.cls-desc { color: var(--muted); max-width: 46ch; }
.cls-info h4 { margin: 1.8rem 0 .8rem; font-size: 1rem; }
.cls-paths { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; }
.cls-paths li { padding: .75rem 1rem; border: 1px solid var(--line); border-left: 2px solid var(--blue); border-radius: var(--radius-s); background: rgba(10,20,48,.5); }
.cls-paths b { display: block; font-family: var(--font-display); }
.cls-paths span { color: var(--muted); font-size: .92rem; }

@media (max-width: 1060px) {
  .cls { grid-template-columns: 1fr 1fr; }
  .cls-tabs { grid-column: 1 / -1; flex-direction: row; overflow-x: auto; padding-bottom: .3rem; }
  .cls-tab { width: auto; flex: none; }
}
@media (max-width: 720px) {
  .cls { grid-template-columns: 1fr; gap: 1.5rem; }
  .cls-stage { height: 330px; }
  .cls-fig { height: 290px; margin-bottom: 22px; }
}


/* ---------- Sprite button (login) ---------- */
.btn-sprite {
  width: 150px; height: 30px; flex: none; border: 0; cursor: pointer;
  background: url("../img/ui/login-button.jpg") 0 0 / 150px 90px no-repeat;
  display: inline-grid; place-items: center; color: #0a1a3a; font: 800 .86rem/1 var(--font-body); letter-spacing: .02em;
  text-shadow: 0 1px 0 rgba(255,255,255,.55);
  border-radius: 3px; padding: 0 38px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.btn-sprite:hover { background-position: 0 -30px; }
.btn-sprite:active { background-position: 0 -60px; }
@media (max-width: 520px) { .btn-sprite { width: 120px; background-size: 120px 72px; height: 24px; padding: 0 28px; font-size: .74rem; } .btn-sprite:hover { background-position: 0 -24px; } .btn-sprite:active { background-position: 0 -48px; } }

/* ---------- Empires ---------- */
.empires { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.empire {
  --emp: #3a8dff;
  position: relative; padding: 2rem; border-radius: var(--radius-m);
  border: 1px solid var(--line); border-top: 3px solid var(--emp);
  background: linear-gradient(180deg, color-mix(in srgb, var(--emp) 14%, transparent), rgba(10,20,48,.6) 55%);
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: .9rem;
}
.empire.red { --emp: #e0393e; }
.empire.yellow { --emp: #e8b730; }
.empire.blue { --emp: #3a8dff; }
.empire-flag {
  width: 186px; aspect-ratio: 128 / 79; border-radius: 4px; overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--emp) 60%, white 10%);
  box-shadow: 0 0 40px -6px var(--emp);
  background: linear-gradient(160deg, color-mix(in srgb, var(--emp) 85%, white 10%), color-mix(in srgb, var(--emp) 55%, black));
}
.empire-flag img { width: 100%; height: 100%; object-fit: cover; }
.empire h3 { font-size: 1.6rem; margin-top: .4rem; }
.empire p { color: var(--muted); max-width: 34ch; margin-top: .4rem; }

/* ---------- News images ---------- */
.news-banner { margin: -1.8rem -1.8rem .4rem; height: 120px; overflow: hidden; border-radius: var(--radius-m) var(--radius-m) 0 0; border-bottom: 1px solid var(--line); }
.news-banner img { width: 100%; height: 100%; object-fit: cover; }
.news-item.has-side { display: grid; grid-template-columns: 94px 1fr; column-gap: 1.2rem; align-items: start; }
.news-item.has-side > :not(.news-side) { grid-column: 2; }
.news-side { grid-column: 1; grid-row: 1 / span 5; width: 94px; border-radius: var(--radius-s); overflow: hidden; border: 1px solid var(--line); box-shadow: 0 10px 30px -10px rgba(58,141,255,.6); }

@media (max-width: 960px) { .empires { grid-template-columns: 1fr; } .empire { flex-direction: row; text-align: left; align-items: center; } .empire-flag { width: 120px; flex: none; } .empire-text { display: grid; gap: .3rem; } .empire h3 { margin: 0; } }
@media (max-width: 520px) { .empire { flex-direction: column; text-align: center; } .news-banner { height: 80px; } }

/* ---------- Features ---------- */
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2.5rem 2.2rem; }
.features-outro { margin-top: 3rem; font-family: var(--font-display); font-size: clamp(1.1rem, 2vw, 1.35rem); color: var(--ice); max-width: 60ch; }
.feature { padding-left: 1.4rem; border-left: 2px solid rgba(58,141,255,.5); }
.feature svg { width: 34px; height: 34px; color: var(--ice); margin-bottom: .9rem; }
.feature h3 { font-size: 1.3rem; margin-bottom: .5rem; }
.feature p { color: var(--muted); max-width: 46ch; font-size: .96rem; }
.feature h3 { font-size: 1.15rem; }

/* ---------- Gallery ---------- */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; }
.gallery figure { margin: 0; border-radius: var(--radius-s); overflow: hidden; border: 1px solid var(--line); aspect-ratio: 16 / 10; background: var(--deep); }
.gallery figure:first-child { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.gallery figure:hover img { transform: scale(1.04); }

/* ---------- News ---------- */
.news { display: grid; grid-template-columns: 1.4fr 1fr; gap: 1.5rem; }
.news-item { padding: 1.8rem; border-radius: var(--radius-m); border: 1px solid var(--line); background: rgba(10,20,48,.6); display: flex; flex-direction: column; gap: .7rem; }
.news-item:first-child { grid-row: span 2; background: linear-gradient(160deg, rgba(22,38,76,.95), rgba(10,20,48,.8)); }
.news-item:first-child h3 { font-size: 1.7rem; }
.news-meta { display: flex; gap: .8rem; align-items: center; font-size: .85rem; color: var(--muted); }
.news-tag { color: var(--ice); font-weight: 700; padding: .15rem .55rem; border-radius: 4px; background: rgba(58,141,255,.15); }
.news-item h3 { font-size: 1.25rem; }
.news-text { color: var(--muted); }
.news-text p + p { margin-top: .7rem; }
.news-item.is-collapsed .news-text { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.news-toggle { align-self: flex-start; background: none; border: 0; color: var(--ice); font: 600 .9rem var(--font-body); cursor: pointer; padding: 0; margin-top: auto; }
.news-toggle:hover { color: #fff; }

/* ---------- Download ---------- */
.download { display: grid; grid-template-columns: 1.5fr 1fr; gap: 1.5rem; }
.dl-main, .dl-req { padding: 2.2rem; border-radius: var(--radius-m); border: 1px solid var(--line); background: rgba(10,20,48,.6); }
.dl-main h3, .dl-req h3 { font-size: 1.5rem; margin-bottom: .6rem; }
.dl-main > p { color: var(--muted); max-width: 52ch; }
.dl-meta { display: flex; gap: 2.5rem; margin: 1.4rem 0 0; }
.dl-meta dt { color: var(--muted); font-size: .82rem; }
.dl-meta dd { margin: 0; font-weight: 700; }
.dl-buttons { display: flex; gap: .8rem; flex-wrap: wrap; margin-top: 1.4rem; }
.btn.is-soon { background: rgba(58,141,255,.12); border: 1px dashed rgba(159,216,255,.4); color: var(--ice); box-shadow: none; cursor: default; }
.dl-soon-note { margin-top: 1rem; color: var(--muted); max-width: 52ch; }
.dl-main h4 { margin: 2.2rem 0 1rem; font-size: 1.1rem; }
.steps { list-style: none; counter-reset: s; margin: 0; padding: 0; display: grid; gap: .8rem; }
.steps li { counter-increment: s; display: flex; gap: .9rem; align-items: baseline; color: var(--muted); }
.steps li::before { content: counter(s); flex: none; width: 1.8rem; height: 1.8rem; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--blue); color: var(--ice); font: 700 .85rem var(--font-display); transform: translateY(-.1rem); }
.dl-req table { width: 100%; border-collapse: collapse; }
.dl-req th, .dl-req td { text-align: left; padding: .75rem 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.dl-req th { color: var(--muted); font-weight: 500; font-size: .9rem; width: 40%; padding-right: 1rem; }
.dl-req td { font-weight: 600; }

/* ---------- Shop ---------- */
.shop { position: relative; overflow: hidden; padding-block: clamp(4rem, 8vw, 6rem); border-block: 1px solid var(--line); background: radial-gradient(ellipse at 80% 50%, rgba(58,141,255,.22), transparent 60%), var(--deep); }
.shop-rings { position: absolute; right: -60px; top: 50%; width: 520px; transform: translateY(-50%); animation: spin 120s linear infinite; }
.shop-inner { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.shop h2 { font-size: clamp(2rem, 4vw, 2.8rem); }
.shop p { margin-top: .7rem; color: var(--muted); max-width: 58ch; font-size: 1.05rem; }
.shop .shop-pledge { margin-top: 1.1rem; padding: .9rem 1.1rem; border-left: 2px solid var(--ok); background: rgba(79,227,162,.07); border-radius: 0 var(--radius-s) var(--radius-s) 0; color: var(--text); font-weight: 600; }

/* ---------- Footer ---------- */
.site-footer { padding-block: 3.5rem 2rem; }
.footer-inner { display: flex; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.footer-brand p { margin-top: .7rem; color: var(--muted); font-size: .88rem; max-width: 48ch; }
.footer-links { display: flex; gap: 1.6rem; flex-wrap: wrap; }
.footer-links a { color: var(--muted); font-size: .92rem; }
.footer-links a:hover { color: var(--text); }
.footer-copy { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .82rem; }

/* ---------- Modal ---------- */
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 1rem; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(2,6,16,.75); backdrop-filter: blur(6px); }
.modal-box {
  position: relative; width: min(460px, 100%); max-height: calc(100% - 2rem); overflow-y: auto;
  padding: 2rem; border-radius: var(--radius-m);
  background: linear-gradient(170deg, var(--steel), var(--deep));
  border: 1px solid rgba(106,174,255,.35);
  box-shadow: 0 40px 100px -30px rgba(58,141,255,.6);
  animation: rise .25s ease-out;
}
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }
.modal-close { position: absolute; right: 1rem; top: 1rem; width: 34px; height: 34px; display: grid; place-items: center; background: none; border: 0; color: var(--muted); cursor: pointer; border-radius: var(--radius-s); }
.modal-close:hover { color: #fff; background: rgba(255,255,255,.06); }
.modal-close svg { width: 16px; height: 16px; }
.tabs { display: flex; gap: 1.5rem; margin-bottom: 1.6rem; border-bottom: 1px solid var(--line); }
.tab { background: none; border: 0; padding: 0 0 .8rem; color: var(--muted); font: 700 1.15rem var(--font-display); cursor: pointer; position: relative; }
.tab.is-active { color: var(--text); }
.tab.is-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--blue); box-shadow: 0 0 10px var(--blue); }
.auth-form { display: grid; gap: 1rem; }
.auth-form[hidden] { display: none; }
.auth-form label { display: grid; gap: .35rem; font-size: .88rem; color: var(--muted); font-weight: 600; }
.auth-form input { width: 100%; padding: .8rem .9rem; border-radius: var(--radius-s); border: 1px solid var(--line); background: rgba(4,10,24,.7); color: var(--text); font: 500 1rem var(--font-body); }
.auth-form input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(58,141,255,.25); }
.auth-form small { font-weight: 400; font-size: .8rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-msg { min-height: 1.3em; font-size: .9rem; }
.form-msg.err { color: var(--bad); }
.form-msg.ok { color: var(--ok); }
.auth-note { margin-top: 1.3rem; color: var(--muted); font-size: .84rem; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero { align-items: end; min-height: auto; }
  .hero-art { top: var(--header-h); height: min(88vw, 620px); object-position: 18% 8%; }
  .hero-bg::after { background: linear-gradient(180deg, transparent 0%, transparent calc(var(--header-h) + min(50vw, 360px)), rgba(4,10,24,.9) calc(var(--header-h) + min(80vw, 560px)), var(--abyss) calc(var(--header-h) + min(88vw, 620px))); }
  .hero-content { justify-content: center; padding-top: min(66vw, 470px); padding-bottom: 3.5rem; }
}
@media (max-width: 960px) {
  .servers, .news, .download { grid-template-columns: 1fr; }
  .news-item:first-child { grid-row: auto; }
  .features { gap: 2rem; grid-template-columns: repeat(2, 1fr); }
  .account-name { display: none; }
}
@media (max-width: 1100px) {
  .nav-toggle { display: flex; }
  .main-nav {
    position: fixed; left: 0; right: 0; top: calc(var(--header-h) + env(safe-area-inset-top, 0px));
    flex-direction: column; gap: 0; margin: 0; padding: .5rem 1.25rem 1.5rem;
    background: rgba(4,10,24,.97); border-bottom: 1px solid var(--line);
    transform: translateY(-8px); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
  }
  .main-nav.is-open { opacity: 1; transform: none; pointer-events: auto; }
  .main-nav a { padding: .9rem 0; border-bottom: 1px solid var(--line); font-size: 1.05rem; }
  .main-nav a.is-active::after { display: none; }
}
@media (max-width: 820px) {
  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .features { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .header-inner { gap: .8rem; }
  .brand span { font-size: 1rem; }
  .header-tools { gap: .5rem; }
  .lang-btn { padding: .45rem .5rem; }
  .brand-mark { width: 34px; height: 34px; }
  #loginBtn { padding: .5rem .7rem; }
  .server, .dl-main, .dl-req { padding: 1.5rem; }
  .server-art { margin: -1.5rem -1.5rem .2rem; height: 150px; }
  .form-row { grid-template-columns: 1fr; }
  .hero-cta .btn { width: 100%; }
  .gallery { grid-template-columns: 1fr; }
  .gallery figure:first-child { grid-column: auto; grid-row: auto; aspect-ratio: 16 / 10; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
