/* base.css */

/* =============================================
   Рубеж Времён — Global Stylesheet
   Подключается через base.html, используется
   на всех страницах проекта.
   ============================================= */

/* ---------- Reset & Base ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  min-width: 0;
}

html {
  overflow-x: hidden;
}



body {
  --current-bg: var(--bg-accent-rgba, 201, 184, 150);
  background:
    radial-gradient(circle at 20% 20%, rgba(var(--current-bg), 0.15) 0, transparent 32%),
    radial-gradient(circle at 80% 70%, rgba(var(--current-bg), 0.07) 0, transparent 28%),
    linear-gradient(180deg, #0a0a0a 0%, #070707 100%);
  background-attachment: fixed;
  transition: background 0.5s ease;
  font-family: 'Raleway', sans-serif;
  overflow-x: hidden;
}

/* ---------- CSS Variables ---------- */
:root {
  --gold: #c9b896;
  --gold-dark: #8b7355;
  --crimson: #8b3a3a;
  --bg-dark: #0a0a0alogin;
  --bg-panel: rgba(26, 26, 26, 0.9);
  --bg-block: rgba(26, 26, 26, 0.8);
  --border: #2a2a2a;
  --text-muted: #b0b0b0;
  --text-dim: #a0a0a0;
  --font-serif: 'Cinzel', serif;
  --font-body: 'Raleway', sans-serif;
}

/* ---------- Layout ---------- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 30px;
  position: relative;
  z-index: 2;
}

/* ---------- Navbar ---------- */
.navbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(10, 10, 10, 0.9);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(6px);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 15px 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-title {
  font-family: 'Old Standard TT', serif;
  font-size: 1.2rem;
  letter-spacing: 2px;
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 50%, var(--gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  position: relative;
}

.nav-title::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--crimson), transparent);
}

.nav-link {
  padding: 8px 20px;
  border: 1px solid rgba(184, 166, 122, 0.6);
  color: #d8ccb0;
  text-decoration: none;
  font-family: 'Libre Baskerville', serif;
  font-size: 0.85rem;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  background: transparent;
}

.nav-link:hover {
  background: rgba(232, 220, 192, 0.15);
  border-color: rgba(184, 166, 122, 0.9);
  color: #e8dcc0;
}

/* ---------- Ambient Effects ---------- */
.smoke {
  position: fixed;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(ellipse at 20% 30%, rgba(139, 58, 58, 0.15) 0%, rgba(139, 58, 58, 0.03) 25%, transparent 60%),
    radial-gradient(ellipse at 80% 70%, rgba(201, 184, 150, 0.10) 0%, rgba(201, 184, 150, 0.02) 30%, transparent 65%);
  pointer-events: none;
  z-index: 1;
  will-change: transform;

  /* 🔑 Ключевые улучшения: */
  filter: blur(24px);
  /* размывает градиенты → убирает banding */
  opacity: 0.9;
  /* чуть приглушаем, чтобы не перетягивало */
  background-blend-mode: screen;
  /* мягкое наложение слоёв */
}

/* 🎲 Добавляем микро-шум, чтобы окончательно «разбить» полосы */
.smoke::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.95' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.03;
  pointer-events: none;
  mix-blend-mode: overlay;
}

.particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.particle {
  position: absolute;
  width: 2px;
  height: 2px;
  background: rgba(201, 184, 150, 0.5);
  border-radius: 50%;
  animation: float 15s infinite;
}

/* ---------- Page Header ---------- */
.main-header {
  text-align: center;
  padding: 60px 0 40px;
  position: relative;
  z-index: 3;
}

.title {
  font-family: var(--font-serif);
  font-size: 4rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 15px;
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 50%, var(--gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  position: relative;
  display: inline-block;
}

.title::after {
  content: '';
  position: absolute;
  bottom: -20%;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--crimson), transparent);
}

.tagline {
  margin-top: 40px;
  font-size: 1.2rem;
  color: var(--crimson);
  letter-spacing: 8px;
  text-transform: uppercase;
}

.hero-section {
  position: relative;
  height: 500px;
  margin: 40px 0 80px;
  border: 3px solid var(--border);
  box-shadow:
    0 0 0 1px #1a1a1a,
    0 0 60px rgba(139, 58, 58, 0.3);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(10, 10, 10, 0.7) 0%, rgba(26, 26, 26, 0.4) 50%, rgba(10, 10, 10, 0.8) 100%),
    url('../images/hero-section.jpg') center/cover no-repeat;
  filter: grayscale(40%) contrast(1.2) brightness(0.85);
  transition: filter 0.5s ease;
  z-index: 1;
}

.hero-section:hover .hero-bg {
  filter: grayscale(20%) contrast(1.3) brightness(0.9);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle, transparent 30%, rgba(0, 0, 0, 0.85) 100%);
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 3;
  text-align: center;
}

.year-display {
  font-family: var(--font-serif);
  font-size: 8rem;
  font-weight: 900;
  color: rgba(201, 184, 150, 0.15);
  text-shadow: 0 0 60px rgba(139, 58, 58, 0.6);
  letter-spacing: 10px;
  line-height: 1;
  margin-bottom: 10px;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: 2rem;
  color: var(--gold);
  letter-spacing: 8px;
  text-transform: uppercase;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.8);
}

.content-block {
  background: linear-gradient(135deg, rgba(26, 26, 26, 0.8) 0%, rgba(15, 15, 15, 0.9) 100%);
  border: 1px solid var(--border);
  padding: 60px;
  margin: 60px 0;
  position: relative;
}

.content-block::before,
.content-block::after {
  content: '';
  position: absolute;
  width: 60px;
  height: 60px;
  border: 2px solid var(--crimson);
}

.content-block::before {
  top: 20px;
  left: 20px;
  border-right: none;
  border-bottom: none;
}

.content-block::after {
  bottom: 20px;
  right: 20px;
  border-left: none;
  border-top: none;
}

.welcome {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  color: var(--gold);
  margin-bottom: 30px;
  text-align: center;
  letter-spacing: 5px;
}

.main-text {
  font-size: 1.15rem;
  line-height: 2;
  color: var(--text-muted);
  text-align: center;
}

.main-text p {
  margin-bottom: 25px;
}

.main-text strong {
  color: var(--gold);
  font-weight: 600;
}

.dramatic-line {
  font-size: 1.4rem;
  color: var(--crimson);
  text-align: center;
  margin-top: 40px;
  padding-top: 40px;
  border-top: 1px solid rgba(139, 58, 58, 0.3);
  font-style: italic;
  letter-spacing: 2px;
}

/* ---------- Side Panel ---------- */
.side-panel {
  max-width: 400px;
  margin: 0 auto 60px;
  background: linear-gradient(135deg, var(--bg-panel) 0%, rgba(15, 15, 15, 0.95) 100%);
  border: 1px solid var(--border);
  padding: 40px 30px;
  position: relative;
  overflow: hidden;
}

.side-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--crimson), var(--gold));
}

.side-title {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  color: var(--gold);
  margin-bottom: 25px;
  letter-spacing: 3px;
  text-transform: uppercase;
  text-align: center;
}

.nation-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 8px 15px;
}

.nation-list li {
  padding: 10px 5px 10px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  color: var(--text-dim);
  font-size: 0.9rem;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  text-align: center;
}

.nation-list li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--crimson);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.nation-list li:hover {
  color: var(--gold);
  padding-left: 23px;
}

.nation-list li:hover::before {
  opacity: 1;
}

/* ---------- Nation Chips ---------- */
.standalone-block {
  margin: 80px 0;
  padding: 0 20px;
  position: relative;
  z-index: 2;
}

.block-frame {
  position: relative;
  background: linear-gradient(135deg, rgba(20, 20, 20, 0.95) 0%, rgba(12, 12, 12, 0.98) 100%);
  border: 1px solid var(--border);
  padding: 40px 30px;
  max-width: 1000px;
  margin: 0 auto;
  box-shadow:
    0 0 0 1px #1a1a1a,
    0 10px 60px rgba(0, 0, 0, 0.5),
    inset 0 0 80px rgba(139, 58, 58, 0.05);
}

.frame-corner {
  position: absolute;
  width: 30px;
  height: 30px;
  border: 2px solid var(--crimson);
  pointer-events: none;
  z-index: 3;
}

.frame-corner.tl {
  top: 15px;
  left: 15px;
  border-right: none;
  border-bottom: none;
}

.frame-corner.tr {
  top: 15px;
  right: 15px;
  border-left: none;
  border-bottom: none;
}

.frame-corner.bl {
  bottom: 15px;
  left: 15px;
  border-right: none;
  border-top: none;
}

.frame-corner.br {
  bottom: 15px;
  right: 15px;
  border-left: none;
  border-top: none;
}

.block-content {
  position: relative;
  z-index: 2;
}

.block-title {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  color: var(--gold);
  text-align: center;
  margin-bottom: 35px;
  letter-spacing: 6px;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
}

.title-decoration {
  color: var(--crimson);
  font-size: 1.2rem;
  animation: pulse 2s ease-in-out infinite;
}

.chips-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  padding: 10px 5px;
}

.nation-chip {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  background: linear-gradient(135deg, rgba(35, 35, 35, 0.9) 0%, rgba(25, 25, 25, 0.95) 100%);
  border: 1px solid #3a3a3a;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  min-width: fit-content;
}

.nation-chip::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(201, 184, 150, 0.1), transparent);
  transition: left 0.5s ease;
}

.nation-chip:hover::before {
  left: 100%;
}

.nation-chip:hover {
  border-color: var(--gold);
  transform: translateY(-3px);
  box-shadow:
    0 5px 25px rgba(139, 58, 58, 0.3),
    0 0 0 1px rgba(201, 184, 150, 0.2);
}

.chip-flag {
  font-size: 1.3rem;
  filter: grayscale(40%);
  transition: filter 0.3s ease;
  line-height: 1;
}

.nation-chip:hover .chip-flag {
  filter: grayscale(0%);
}

.chip-label {
  font-size: 0.9rem;
  color: var(--text-muted);
  letter-spacing: 1px;
  white-space: nowrap;
  transition: color 0.3s ease;
}

.nation-chip:hover .chip-label {
  color: var(--gold);
}

.nation-chip.active {
  border-color: var(--gold);
  background: linear-gradient(135deg, rgba(139, 58, 58, 0.2) 0%, rgba(26, 26, 26, 0.95) 100%);
  box-shadow: 0 0 0 1px rgba(201, 184, 150, 0.4), 0 5px 30px rgba(139, 58, 58, 0.4);
}

.nation-chip.active .chip-label {
  color: var(--gold);
  font-weight: 600;
}

/* ---------- Action Button ---------- */
.action-button {
  display: block;
  width: fit-content;
  margin: auto;
  padding: 20px 60px;
  background: transparent;
  border: 2px solid var(--crimson);
  color: var(--gold);
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 5px;
  text-transform: uppercase;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 0.4s ease;
  text-decoration: none;
}

.action-button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(139, 58, 58, 0.4), transparent);
  transition: left 0.6s ease;
}

.action-button:hover::before {
  left: 100%;
}

.action-button:hover {
  background: rgba(139, 58, 58, 0.2);
  box-shadow: 0 0 40px rgba(139, 58, 58, 0.4);
  transform: translateY(-3px);
}

/* ---------- Stats / Report ---------- */
.stats-block {
  margin: 80px 0 60px;
  padding: 40px;
  background: linear-gradient(135deg, rgba(30, 26, 20, 0.9), rgba(20, 18, 14, 0.95));
  border: 1px solid #b8a67a;
}

.stats-title {
  text-align: center;
  font-family: 'Old Standard TT', serif;
  font-size: 1.4rem;
  color: #e8dcc0;
  margin-bottom: 30px;
  letter-spacing: 3px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px 40px;
}

.stat-item {
  padding: 10px 0;
  border-bottom: 1px solid rgba(184, 166, 122, 0.3);
}

.stat-label {
  font-size: 0.9rem;
  color: #b8a67a;
  margin-bottom: 5px;
}

.stat-value {
  font-size: 1.2rem;
  color: #e8dcc0;
  font-weight: 600;
}

.stats-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid rgba(201, 184, 150, 0.12);
  font-size: 1.05rem;
  color: var(--text-muted);
}

.stats-row span:first-child {
  color: var(--gold);
}

.stats-row span:last-child {
  color: #e0e0e0;
  font-weight: 500;
}

.stats-row:last-child {
  border-bottom: none;
}

.gov-report {
  position: relative;
}

.report-subtitle {
  text-align: center;
  font-size: 0.95rem;
  color: rgba(201, 184, 150, 0.7);
  margin-bottom: 30px;
  letter-spacing: 2px;
}

.report-table {
  border: 1px solid rgba(201, 184, 150, 0.25);
  padding: 20px 30px;
  background: rgba(10, 10, 10, 0.2);
}

.report-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding: 12px 0;
  border-bottom: 1px dashed rgba(201, 184, 150, 0.15);
  font-family: 'Old Standard TT', serif;
  font-weight: 600;
  font-size: 1.2rem;
}

.col-left {
  color: var(--gold);
}

.col-right {
  text-align: right;
  color: var(--text-muted);
}

.report-row:last-child {
  border-bottom: none;
}

.gov-stamp {
  position: absolute;
  right: 30px;
  bottom: 30px;
  transform: rotate(-12deg);
  border: 2px solid rgba(139, 58, 58, 0.6);
  color: rgba(139, 58, 58, 0.7);
  padding: 10px 14px;
  font-size: 0.8rem;
  letter-spacing: 2px;
  font-weight: bold;
  opacity: 0.9;
}

/* ---------- Divider ---------- */
.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 60px 0;
  color: #404040;
  letter-spacing: 30px;
  font-size: 1.5rem;
}

/* ---------- Footer ---------- */
footer {
  text-align: center;
  padding: 40px 0;
  border-top: 1px solid var(--border);
  color: #505050;
  font-size: 0.9rem;
  margin-top: 80px;
}

footer a {
  color: var(--gold);
  text-decoration: none;
}

footer a:hover {
  color: var(--gold-dark);
  text-decoration: underline;
}

/* ---------- Keyframes ---------- */
@keyframes smokeMove {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }

  33% {
    transform: translate(30px, -30px) scale(1.1);
  }

  66% {
    transform: translate(-20px, 20px) scale(0.9);
  }
}

@keyframes float {

  0%,
  100% {
    transform: translateY(100vh) rotate(0deg);
    opacity: 0;
  }

  10% {
    opacity: 1;
  }

  90% {
    opacity: 1;
  }

  100% {
    transform: translateY(-100vh) rotate(720deg);
    opacity: 0;
  }
}

@keyframes pulse {

  0%,
  100% {
    opacity: 0.6;
  }

  50% {
    opacity: 1;
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 968px) {
  .hero-section {
    height: 400px;
  }

  .year-display {
    font-size: 6rem;
  }

  .hero-title {
    font-size: 1.5rem;
  }

  .title {
    font-size: 2.5rem;
    letter-spacing: 8px;
  }

  .content-block {
    padding: 40px 30px;
  }
}

@media (max-width: 768px) {
  .hero-section {
    height: 350px;
  }

  .year-display {
    font-size: 4.5rem;
  }

  .hero-title {
    font-size: 1.2rem;
    letter-spacing: 4px;
  }

  .title {
    font-size: 2rem;
    letter-spacing: 5px;
  }

  .welcome {
    font-size: 1.5rem;
  }

  .main-text {
    font-size: 1rem;
  }

  .nation-list {
    grid-template-columns: 1fr;
  }

  .standalone-block {
    margin: 60px 0;
  }

  .block-frame {
    padding: 30px 20px;
  }

  .block-title {
    font-size: 1.3rem;
    letter-spacing: 4px;
    gap: 10px;
  }

  .chips-container {
    gap: 10px;
  }

  .nation-chip {
    padding: 10px 16px;
  }

  .chip-flag {
    font-size: 1.1rem;
  }

  .chip-label {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .chips-container {
    flex-direction: column;
    align-items: center;
  }

  .nation-chip {
    width: 100%;
    max-width: 280px;
    justify-content: center;
  }

  .nav-title::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 30%;
    transform: translateX(-50%);
    width: 80%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--crimson), transparent);
  }


}








p {
  line-height: 1.6;
  /* Увеличенный межстрочный интервал для легкого чтения */
  margin-bottom: 1.2rem;
  /* Отступ снизу, чтобы текст не слипался */
  color: var(--muted, rgba(201, 184, 150, 0.8));
  /* Приглушенный цвет из ваших переменных */
  font-size: 0.95rem;
  /* Оптимальный размер для игрового интерфейса */
  font-weight: 400;
}

/* Убираем отступ у последнего абзаца в любом контейнере */
p:last-child {
  margin-bottom: 0;
}

/* Специфические стили для блока описания в "Hero" секции */
.description p {
  text-align: left;
  hyphens: auto;
  word-break: break-word;
  overflow-wrap: break-word;
}

/* Особый стиль для заметок (у вас в HTML есть класс .note) */
p.note {
  font-style: italic;
  font-size: 0.9rem;
  border-left: 2px solid var(--accent-color, var(--gold));
  padding-left: 15px;
  margin-top: 20px;
  text-indent: 0;
  /* У заметок красная строка не нужна */
  opacity: 0.9;
}

@media (max-width: 760px) {
  .nav-container {
    padding: 12px 16px;
  }

  .container {
    padding: 0 16px;
  }

  .nav-title {
    font-size: 1rem;
    letter-spacing: 1px;
  }

  .nav-link {
    padding: 6px 12px;
    font-size: 0.78rem;
    letter-spacing: 0.5px;
  }
}

@media (max-width: 480px) {
  .nav-container {
    padding: 10px 12px;
  }

  .nav-link {
    padding: 5px 10px;
    font-size: 0.75rem;
  }
}
