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

:root {
  --bg: #07030f;
  --surface: rgba(14, 6, 30, 0.82);
  --surface2: rgba(20, 9, 42, 0.6);
  --border: rgba(100, 60, 200, 0.18);
  --border-h: rgba(167, 139, 250, 0.4);
  --acc: #7c3aed;
  --acc2: #a78bfa;
  --acc3: #c4b5fd;
  --pink: #e879f9;
  --text: #d4cbe8;
  --text-dim: #7060a0;
  --text-bright: #f0ecff;
  --ok: #34d399;
  --err: #f87171;
  --warn: #fbbf24;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Exo 2', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

.nebula {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 55% 45% at 15% 25%, rgba(76,29,149,0.28) 0%, transparent 70%),
    radial-gradient(ellipse 40% 50% at 85% 75%, rgba(232,121,249,0.08) 0%, transparent 60%),
    radial-gradient(ellipse 35% 55% at 55% 5%, rgba(99,102,241,0.1) 0%, transparent 60%);
}

nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 40px;
  padding: 0 48px;
  height: 58px;
  background: rgba(7, 3, 15, 0.88);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-family: 'Cinzel', serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.2em;
  background: linear-gradient(90deg, var(--acc3), var(--pink));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  gap: 28px;
  flex: 1;
}

.nav-links a {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  text-transform: uppercase;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--acc2); }

.nav-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-dim);
  letter-spacing: 0.06em;
}

.status-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #4b5563;
  transition: all 0.4s;
}

.status-dot.online { background: var(--ok); box-shadow: 0 0 6px var(--ok); }
.status-dot.offline { background: var(--err); }

#hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(124,58,237,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124,58,237,0.06) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black, transparent);
}

.hero-glow {
  position: absolute; top: 40%; left: 50%;
  transform: translate(-50%, -50%);
  width: 700px; height: 500px; pointer-events: none;
  background: radial-gradient(ellipse, rgba(124,58,237,0.15) 0%, transparent 70%);
}

.hero-content {
  position: relative;
  text-align: center;
  padding: 0 24px;
  animation: fadeUp 1s ease both;
}

.hero-eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 24px;
}

.hero-title {
  font-family: 'Cinzel', serif;
  font-size: clamp(52px, 10vw, 110px);
  font-weight: 700;
  line-height: 0.92;
  letter-spacing: -0.01em;
  margin-bottom: 28px;
}

.hero-terra {
  display: block;
  color: var(--text-bright);
}

.hero-divina {
  display: block;
  background: linear-gradient(90deg, var(--acc2), var(--pink));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 40px rgba(124,58,237,0.4));
}

.hero-sub {
  font-size: 18px;
  font-weight: 300;
  color: var(--text-dim);
  max-width: 500px;
  margin: 0 auto 40px;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-primary {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 13px 36px;
  background: linear-gradient(135deg, #5b21b6, var(--acc), #9333ea);
  color: #fff;
  border: none;
  cursor: pointer;
  border-radius: 6px;
  box-shadow: 0 0 24px rgba(124,58,237,0.45);
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 36px rgba(124,58,237,0.7);
}

.btn-ghost {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 13px 36px;
  background: rgba(124,58,237,0.08);
  color: var(--acc2);
  border: 1px solid var(--border-h);
  cursor: pointer;
  border-radius: 6px;
  transition: background 0.2s, transform 0.2s;
}

.btn-ghost:hover {
  background: rgba(124,58,237,0.2);
  transform: translateY(-2px);
}

.hero-scroll {
  position: absolute;
  bottom: 32px; left: 50%;
  transform: translateX(-50%);
  color: var(--text-dim);
  animation: bounce 2s ease-in-out infinite;
}

section { padding: 110px 0; position: relative; z-index: 1; }

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 48px;
}

.section-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--acc2);
  margin-bottom: 14px;
}

.section-title {
  font-family: 'Cinzel', serif;
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 700;
  color: var(--text-bright);
  line-height: 1.15;
  margin-bottom: 56px;
}

#about {
  background: linear-gradient(180deg, var(--bg) 0%, rgba(14,6,30,0.95) 100%);
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 8px;
}

.feature {
  padding: 32px 28px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
}

.feature:hover {
  border-color: rgba(124,58,237,0.4);
  transform: translateY(-4px);
  box-shadow: 0 0 24px rgba(124,58,237,0.15);
}

.feature-icon { margin-bottom: 18px; }

.feature h3 {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--acc2);
  margin-bottom: 10px;
}

.feature p {
  font-size: 14px;
  font-weight: 300;
  color: var(--text-dim);
  line-height: 1.75;
}

#mods { background: var(--bg); }

.mods-count-label {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin-top: -40px;
  margin-bottom: 40px;
}

.mods-controls { margin-bottom: 32px; }

.mods-search {
  width: 100%;
  max-width: 380px;
  padding: 10px 18px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-bright);
  font-family: 'Exo 2', sans-serif;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.mods-search::placeholder { color: var(--text-dim); }
.mods-search:focus {
  border-color: var(--acc2);
  box-shadow: 0 0 10px rgba(124,58,237,0.25);
}

.mods-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 8px;
}

.mods-loading {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 80px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--text-dim);
}

.mod-card {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
  animation: fadeUp 0.3s ease both;
}

.mod-card:hover {
  border-color: rgba(124,58,237,0.4);
  transform: translateY(-3px);
  box-shadow: 0 0 16px rgba(124,58,237,0.12);
}

.mod-icon {
  width: 40px; height: 40px;
  border-radius: 6px;
  object-fit: cover;
  image-rendering: pixelated;
  background: rgba(124,58,237,0.15);
}

.mod-icon-placeholder {
  width: 40px; height: 40px;
  border-radius: 6px;
  background: linear-gradient(135deg, rgba(124,58,237,0.3), rgba(232,121,249,0.15));
  border: 1px solid rgba(124,58,237,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}

.mod-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-bright);
  line-height: 1.3;
}

.mod-file {
  font-size: 11px;
  color: var(--text-dim);
  font-family: monospace;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mods-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px;
  color: var(--text-dim);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
}

#gallery {
  background: linear-gradient(180deg, var(--bg) 0%, rgba(14,6,30,0.95) 100%);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 4px;
  border-radius: 8px;
  overflow: hidden;
}

.gallery-item {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
  cursor: pointer;
  border: 1px solid var(--border);
}

.gallery-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.gallery-item:hover img { transform: scale(1.06); }

.gallery-item::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(7,3,15,0.7), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.gallery-item:hover::after { opacity: 1; }

.gallery-zoom {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  opacity: 0;
  z-index: 1;
  transition: all 0.3s;
  color: var(--acc2);
}

.gallery-item:hover .gallery-zoom {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.gallery-empty {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 80px;
  color: var(--text-dim);
  text-align: center;
  font-size: 14px;
}

.gallery-empty code {
  font-size: 13px;
  background: var(--surface2);
  padding: 2px 8px;
  border-radius: 4px;
  color: var(--acc2);
  border: 1px solid var(--border);
}

#contacts { background: var(--bg); }

.contacts-sub {
  font-size: 16px;
  font-weight: 300;
  color: var(--text-dim);
  margin-bottom: 48px;
  margin-top: -36px;
  max-width: 560px;
  line-height: 1.8;
}

.contacts-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 48px;
  max-width: 600px;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 20px 24px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  cursor: pointer;
}

.contact-card:hover {
  border-color: var(--border-h);
  background: rgba(124,58,237,0.12);
  box-shadow: 0 0 18px rgba(124,58,237,0.15);
}

.contact-icon {
  flex-shrink: 0;
  width: 44px; height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(124,58,237,0.15);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.contact-name {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-bright);
  margin-bottom: 3px;
}

.contact-desc {
  font-size: 13px;
  color: var(--text-dim);
}

.contact-arrow {
  margin-left: auto;
  flex-shrink: 0;
  color: var(--text-dim);
  transition: transform 0.2s, color 0.2s;
}

.contact-card:hover .contact-arrow {
  transform: translateX(4px);
  color: var(--acc2);
}

.server-address {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 18px 24px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 8px;
  max-width: 600px;
}

.server-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.server-ip {
  font-family: monospace;
  font-size: 15px;
  color: var(--acc2);
  letter-spacing: 0.05em;
}

.copy-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
  padding: 7px 16px;
  background: rgba(124,58,237,0.1);
  border: 1px solid var(--border);
  color: var(--text-dim);
  font-family: 'Exo 2', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  border-radius: 5px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.copy-btn:hover {
  border-color: var(--border-h);
  color: var(--acc2);
  background: rgba(124,58,237,0.2);
}

footer {
  border-top: 1px solid var(--border);
  padding: 28px 48px;
  position: relative;
  z-index: 1;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.footer-logo {
  font-family: 'Cinzel', serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.2em;
  background: linear-gradient(90deg, var(--acc3), var(--pink));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer-copy {
  font-size: 12px;
  color: var(--text-dim);
  letter-spacing: 0.06em;
}

.lightbox {
  display: none;
  position: fixed; inset: 0;
  z-index: 1000;
  background: rgba(7,3,15,0.96);
  backdrop-filter: blur(6px);
  align-items: center;
  justify-content: center;
}

.lightbox.open { display: flex; }

.lightbox-img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border: 1px solid var(--border-h);
  border-radius: 4px;
  box-shadow: 0 0 60px rgba(124,58,237,0.3);
}

.lightbox-close {
  position: absolute;
  top: 20px; right: 20px;
  background: rgba(124,58,237,0.1);
  border: 1px solid var(--border-h);
  color: var(--text-dim);
  width: 38px; height: 38px;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.lightbox-close:hover {
  border-color: var(--acc2);
  color: var(--acc2);
  background: rgba(124,58,237,0.2);
}

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

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50%       { transform: translateX(-50%) translateY(7px); }
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

.spin { animation: spin 2s linear infinite; }

@media (max-width: 768px) {
  nav { padding: 0 20px; gap: 20px; }
  .nav-links { display: none; }
  .container { padding: 0 20px; }
  section { padding: 80px 0; }
  .features { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; text-align: center; }
  footer { padding: 24px 20px; }
}
