:root {
  --bg-main: #050612;
  --bg-alt: #0c0f1f;
  --bg-card: #101425;
  --accent: #8b5cf6;
  --accent-soft: rgba(139, 92, 246, 0.2);
  --accent-2: #22d3ee;
  --text-main: #f9fafb;
  --text-muted: #9ca3af;
  --border-subtle: #1f2933;
  --danger: #f97373;
  --radius-xl: 24px;
  --shadow-soft: 0 22px 45px rgba(0, 0, 0, 0.6);
  --max-width: 1120px;
}

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

html,
body {
  height: 100%;
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: radial-gradient(circle at top, #111827 0, #020617 55%, #000 100%);
  color: var(--text-main);
  -webkit-font-smoothing: antialiased;
}

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

.page-wrap {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(18px);
  background: linear-gradient(to bottom, rgba(5, 6, 18, 0.95), rgba(5, 6, 18, 0.86));
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-logo {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: conic-gradient(from 210deg, #22d3ee, #6366f1, #a855f7, #22d3ee);
  padding: 2px;
  box-shadow: 0 0 32px rgba(56, 189, 248, 0.55);
  position: relative;
  overflow: hidden;
}

.brand-logo-inner {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  background: radial-gradient(circle at 30% 20%, #111827, #020617 65%, #000);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #e5e7eb;
}

.brand-text-title {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.brand-text-sub {
  font-size: 11px;
  color: var(--text-muted);
}

nav {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 13px;
}

.nav-links {
  display: flex;
  gap: 14px;
  align-items: center;
}

.nav-link {
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--text-muted);
  transition: all 0.18s ease-out;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  background: transparent;
}

.nav-link:hover {
  color: var(--text-main);
  border-color: rgba(148, 163, 184, 0.4);
  background: rgba(15, 23, 42, 0.9);
}

.nav-cta {
  padding: 7px 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  color: #f9fafb;
  font-size: 13px;
  font-weight: 500;
  box-shadow: 0 12px 32px rgba(87, 83, 255, 0.55);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.13s ease-out, box-shadow 0.13s ease-out, opacity 0.13s ease-out;
}

.nav-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 36px rgba(87, 83, 255, 0.75);
  opacity: 0.96;
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.85);
}

.lang-btn {
  border-radius: 999px;
  border: none;
  padding: 4px 8px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
  background: transparent;
  color: var(--text-muted);
  transition: all 0.16s ease-out;
}

.lang-btn.active {
  background: rgba(99, 102, 241, 0.18);
  color: #e5e7eb;
}

/* ===== MAIN LAYOUT ===== */

main {
  flex: 1;
}

.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 40px 20px;
}

/* ===== HERO ===== */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 2.5fr);
  gap: 32px;
  padding-top: 40px;
  padding-bottom: 32px;
  align-items: center;
}

.hero-left-eyebrow {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent-2);
  margin-bottom: 12px;
}

.hero-title {
  font-size: clamp(30px, 4vw, 40px);
  line-height: 1.1;
  margin-bottom: 14px;
}

.hero-gradient {
  background: linear-gradient(135deg, #e5e7eb, #a5b4fc, #67e8f9);
  -webkit-background-clip: text;
  color: transparent;
}

.hero-subtitle {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}

.btn-primary {
  padding: 10px 18px;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  color: #f9fafb;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 18px 40px rgba(88, 80, 236, 0.6);
  transition: transform 0.15s ease-out, box-shadow 0.15s ease-out, opacity 0.15s ease-out;
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 22px 48px rgba(88, 80, 236, 0.8);
  opacity: 0.97;
}

.btn-ghost {
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  font-size: 13px;
  color: var(--text-muted);
  background: rgba(15, 23, 42, 0.8);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.15s ease-out;
}

.btn-ghost:hover {
  color: var(--text-main);
  border-color: rgba(148, 163, 184, 0.9);
  background: rgba(15, 23, 42, 1);
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 11px;
  color: var(--text-muted);
}

.meta-pill {
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.35);
}

.hero-right {
  position: relative;
  min-height: 260px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===== SPHERE CARD ===== */

.sphere-card {
  position: relative;
  width: 100%;
  max-width: 380px;
  border-radius: 999px;
  padding: 24px 18px;
  background: radial-gradient(circle at top, #1f2937, #020617 68%);
  border: 1px solid rgba(148, 163, 184, 0.45);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.sphere-orbit {
  width: 210px;
  height: 210px;
  border-radius: 999px;
  border: 1px dashed rgba(148, 163, 184, 0.45);
  margin: 0 auto 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.sphere-core {
  width: 118px;
  height: 118px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 15%, #e5e7eb, #4f46e5, #0f172a 65%);
  box-shadow: 0 0 45px rgba(59, 130, 246, 0.85);
  position: relative;
  overflow: hidden;
}

.sphere-layer {
  position: absolute;
  inset: 16px;
  border-radius: inherit;
  border: 1px solid rgba(248, 250, 252, 0.2);
  mix-blend-mode: screen;
}

.sphere-layer:nth-child(1) {
  inset: 10px;
  opacity: 0.45;
}
.sphere-layer:nth-child(2) {
  inset: 20px;
  opacity: 0.35;
}
.sphere-layer:nth-child(3) {
  inset: 30px;
  opacity: 0.25;
}

.sphere-caption {
  text-align: center;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.sphere-label {
  text-align: center;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 4px;
}

.sphere-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-top: 8px;
  margin-bottom: 4px;
  font-size: 10px;
}

.sphere-badge {
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.95);
}

.sphere-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--accent-2);
  margin-top: 8px;
  justify-content: center;
}

/* ===== GENERIC SECTIONS / GRID / CARDS ===== */

.section-title {
  font-size: 20px;
  margin-bottom: 10px;
}

.section-kicker {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent-2);
  margin-bottom: 6px;
}

.section-text {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-muted);
  max-width: 720px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.card {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-subtle);
  padding: 16px 16px 14px;
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.65);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.card-title {
  font-size: 14px;
  font-weight: 500;
}

.card-tag {
  font-size: 10px;
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(31, 41, 55, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.5);
  color: var(--text-muted);
}

.card-body {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-muted);
}

/* ===== TOKENOMICS TABLE ===== */

.tokenomics-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.1fr);
  gap: 18px;
  margin-top: 18px;
  align-items: flex-start;
}

.token-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin-top: 6px;
}

.token-table th,
.token-table td {
  padding: 6px 4px;
  border-bottom: 1px solid rgba(31, 41, 55, 0.85);
}

.token-table th {
  text-align: left;
  font-weight: 500;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.token-table tbody tr:last-child td {
  border-bottom: none;
}

.token-highlight {
  font-weight: 500;
  color: #e5e7eb;
}

.badge-inline {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.9);
  margin-top: 4px;
}

.legal-note {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 8px;
}

.legal-note strong {
  color: #e5e7eb;
}

.roadmap-list {
  list-style: none;
  margin-top: 10px;
  font-size: 13px;
  color: var(--text-muted);
}

.roadmap-item {
  position: relative;
  padding-left: 18px;
  margin-bottom: 4px;
}

.roadmap-item::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 7px;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: var(--accent);
}

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

footer {
  border-top: 1px solid rgba(15, 23, 42, 0.95);
  background: #020617;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 20px;
  font-size: 12px;
  color: var(--text-muted);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

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

.footer-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 12px;
}

.footer-link:hover {
  color: var(--accent-2);
}

/* ===== LANGUAGE SWITCHING ===== */

.lang {
  display: none;
}

body.lang-ru .lang.lang-ru {
  display: block;
}
body.lang-en .lang.lang-en {
  display: block;
}

/* =========================================
   СТИЛИ КАТЕГОРИЙ (новости, галерея, видео, эксперименты)
   ========================================= */

/* Новости: более вытянутая колонка, “журналистский” акцент */
.section--news {
  max-width: 800px;
}

.section--news .news-list {
  margin-top: 24px;
}

.section--news .news-item {
  margin-bottom: 18px;
}

.section--news .card {
  border-left: 3px solid var(--accent-2);
}

/* Галерея: сетка под картинки */
.section--gallery .gallery-list {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.section--gallery .gallery-item {
  /* при необходимости можно добавить отступы */
}

.section--gallery .card img {
  display: block;
  max-width: 100%;
  border-radius: 18px;
  margin-top: 10px;
}

/* Видео: акцент на плеер */
.section--video .video-list {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 18px;
}

.section--video .video-item {
}

.section--video iframe,
.section--video video {
  border-radius: 18px;
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.7);
}

/* Эксперименты: строгие карточки, вертикальный список */
.section--experiments .experiments-list {
  margin-top: 24px;
  max-width: 860px;
}

.section--experiments .experiment-item {
  margin-bottom: 22px;
}

.section--experiments .card {
  border-style: dashed;
}

/* ===== Кликабельные карточки в списках (новости и др.) ===== */

.news-card-link {
  display: block;
  text-decoration: none;
}

.news-card-link article.card {
  transition: transform 0.16s ease-out, box-shadow 0.16s ease-out, border-color 0.16s ease-out;
}

.news-card-link:hover article.card {
  transform: translateY(-2px);
  box-shadow: 0 22px 40px rgba(0, 0, 0, 0.8);
  border-color: rgba(139, 92, 246, 0.8);
}

/* Можно использовать те же стили для других категорий, если нужно:
.gallery-card-link, .video-card-link и т.д.
*/

/* ===== ПАГИНАЦИЯ ===== */

.pagination {
  margin-top: 24px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  font-size: 12px;
}

.pagination-page,
.pagination-arrow {
  min-width: 26px;
  height: 26px;
  padding: 0 8px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.9);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  text-decoration: none;
  transition: all 0.15s ease-out;
}

.pagination-page.current {
  background: linear-gradient(135deg, #6366f1, #a855f7);
  border-color: transparent;
  color: #f9fafb;
  font-weight: 500;
  cursor: default;
}

.pagination-page:not(.current):hover,
.pagination-arrow:not(.disabled):hover {
  color: var(--text-main);
  border-color: rgba(148, 163, 184, 0.9);
  background: rgba(15, 23, 42, 1);
}

.pagination-arrow.disabled {
  opacity: 0.35;
  cursor: default;
  border-style: dashed;
}

/* ===== ПОРТАЛ (страница-хаб категорий) ===== */

.section--portal {
  max-width: var(--max-width);
}

.section--portal .portal-grid {
  margin-top: 20px;
}

.portal-card-link {
  display: block;
  text-decoration: none;
}

.portal-card-link article.card {
  transition: transform 0.16s ease-out, box-shadow 0.16s ease-out, border-color 0.16s ease-out;
}

.portal-card-link:hover article.card {
  transform: translateY(-2px);
  box-shadow: 0 22px 40px rgba(0, 0, 0, 0.8);
  border-color: rgba(139, 92, 246, 0.8);
}

/* ===== АДАПТИВ ===== */

@media (max-width: 880px) {
  .hero {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-right {
    order: -1;
  }
}

@media (max-width: 640px) {
  .nav-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav-links {
    width: 100%;
    justify-content: space-between;
  }

  .hero {
    padding-top: 26px;
  }

  .section--gallery .gallery-list,
  .section--video .video-list {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ===== Портал (страница-хаб категорий) ===== */

.section--portal {
  max-width: var(--max-width);
}

.portal-grid {
  margin-top: 20px;
}

.portal-card-link {
  display: block;
  text-decoration: none;
}

.portal-card-link article.card {
  transition: transform 0.16s ease-out, box-shadow 0.16s ease-out, border-color 0.16s ease-out;
}

.portal-card-link:hover article.card {
  transform: translateY(-2px);
  box-shadow: 0 22px 40px rgba(0, 0, 0, 0.8);
  border-color: rgba(139, 92, 246, 0.8);
}

/* Унифицированный контейнер категорий */
.category-list-wrapper {
    text-align: left !important;
    margin: 0 auto;
    max-width: 960px;
}

/* Сообщение "нет публикаций" всегда слева */
.category-empty {
    text-align: left !important;
    margin-top: 20px;
    font-size: 18px;
    opacity: 0.8;
}


/* === Thumbnails inside category cards === */
.news-card-body {
  display: flex;
  gap: 16px;
}

.news-card-thumb img {
  display: block;
  max-width: 160px;
  max-height: 120px;
  object-fit: cover;
  border-radius: 8px;
}

/* If no thumb, text takes full width — flex handles it */

/* === Simple pager for category lists === */
.pager {
  margin-top: 24px;
  text-align: center;
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pager-page {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border-subtle);
  font-size: 14px;
  text-decoration: none;
  color: var(--text-main);
}

.pager-page--active {
  background: var(--accent-main);
  color: #fff;
  border-color: var(--accent-main);
}


/* Category list cards */
.news-category-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.news-card {
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 16px 18px;
  background: rgba(8, 8, 16, 0.9);
}

.news-card-header {
  margin-bottom: 8px;
}

.news-card-title a {
  color: var(--text-main);
  text-decoration: none;
}

.news-card-title a:hover {
  text-decoration: underline;
}

.news-card-meta {
  font-size: 13px;
  opacity: 0.8;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 4px;
}


/* Breadcrumbs */
.breadcrumbs {
  max-width: var(--max-width);
  margin: 0 auto 12px auto;
  padding: 0 20px;
  font-size: 13px;
  opacity: 0.9;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.breadcrumbs-link {
  color: var(--link);
  text-decoration: none;
}

.breadcrumbs-link:hover {
  text-decoration: underline;
}

.breadcrumbs-sep {
  opacity: 0.6;
}

.breadcrumbs-current {
  font-weight: 500;
}


/* Active nav link */
.nav-link--active {
  border-color: rgba(255, 255, 255, 0.35);
  background: radial-gradient(circle at top left, rgba(255,255,255,0.07), transparent);
}


/* Popular block */
.news-popular {
  max-width: var(--max-width);
  margin: 24px auto 0 auto;
  padding: 0 20px 8px 20px;
}

.news-popular--below-list {
  margin-top: 32px;
}

.news-popular-title {
  font-size: 18px;
  margin-bottom: 12px;
}

.news-popular-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.news-popular-item a {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
  text-decoration: none;
  color: var(--text-main);
  padding: 6px 8px;
  border-radius: 8px;
  background: rgba(8, 8, 16, 0.7);
  border: 1px solid rgba(255,255,255,0.04);
}

.news-popular-item a:hover {
  background: rgba(20, 20, 40, 0.9);
}

.news-popular-item-title {
  flex: 1;
}

.news-popular-item-meta {
  white-space: nowrap;
  font-size: 12px;
  opacity: 0.8;
}

.news-popular-empty {
  font-size: 13px;
  opacity: 0.8;
}
