/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg-primary: #0a0a0a;
  --bg-secondary: #1a1a1a;
  --bg-tertiary: #252525;
  --yellow-primary: #ffd700;
  --yellow-secondary: #ffed4e;
  --yellow-dark: #ccaa00;
  --text-primary: #ffffff;
  --text-secondary: #cccccc;
  --text-muted: #999999;
  --border-color: #333333;
  --hover-bg: #2a2a2a;
  --transition: all 0.3s ease;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header Styles */
header {
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
  border-bottom: 2px solid var(--yellow-primary);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 4px 20px rgba(255, 215, 0, 0.1);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  font-weight: 700;
  transition: var(--transition);
}

.logo:hover {
  color: var(--yellow-primary);
  transform: scale(1.05);
}

.logo-icon {
  width: 55px;
  height: 55px;
  border-radius: 8px;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.6)) drop-shadow(0 0 15px rgba(255, 255, 255, 0.4));
  transition: var(--transition);
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
  align-items: center;
  flex-wrap: wrap;
}

.nav-menu a {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  transition: var(--transition);
  position: relative;
}

.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background: var(--yellow-primary);
  transition: var(--transition);
}

.nav-menu a:hover {
  color: var(--yellow-primary);
  background: var(--hover-bg);
}

.nav-menu a:hover::after {
  width: 80%;
}

.mobile-menu-toggle {
  display: none;
  background: transparent;
  border: 2px solid var(--yellow-primary);
  color: var(--yellow-primary);
  padding: 0.5rem 1rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1.2rem;
  transition: var(--transition);
  margin-left: auto;
}

.mobile-menu-toggle:hover {
  background: var(--yellow-primary);
  color: var(--bg-primary);
}

/* Sidebar Styles */
.sidebar {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  width: 220px;
  z-index: 100;
  pointer-events: none;
}

.sidebar-content {
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
  border: 2px solid var(--yellow-primary);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 8px 30px rgba(255, 215, 0, 0.3);
  pointer-events: all;
  max-height: 80vh;
  overflow-y: auto;
}

.sidebar-left {
  left: 20px;
}

.sidebar-right {
  right: 20px;
}

.sidebar-section {
  margin-bottom: 1.5rem;
}

.sidebar-section:last-child {
  margin-bottom: 0;
}

.sidebar-title {
  color: var(--yellow-primary);
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.sidebar-links {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sidebar-links li {
  margin-bottom: 0.5rem;
}

.sidebar-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  display: block;
  padding: 0.5rem;
  border-radius: 6px;
  transition: var(--transition);
}

.sidebar-links a:hover {
  color: var(--yellow-primary);
  background: var(--hover-bg);
  transform: translateX(5px);
}

.sidebar-register-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: linear-gradient(135deg, var(--yellow-primary), var(--yellow-secondary));
  color: var(--bg-primary);
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
  text-align: center;
}

.sidebar-register-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(255, 215, 0, 0.6);
  background: linear-gradient(135deg, var(--yellow-secondary), var(--yellow-primary));
}

.sidebar-register-btn .btn-icon {
  font-size: 1.2rem;
}

.sidebar-contact,
.sidebar-info {
  color: var(--text-secondary);
  font-size: 0.85rem;
  line-height: 1.6;
}

.sidebar-contact p,
.sidebar-info p {
  margin: 0.5rem 0;
  color: var(--text-secondary);
}

/* Sidebar Scrollbar */
.sidebar-content::-webkit-scrollbar {
  width: 6px;
}

.sidebar-content::-webkit-scrollbar-track {
  background: var(--bg-primary);
  border-radius: 3px;
}

.sidebar-content::-webkit-scrollbar-thumb {
  background: var(--yellow-primary);
  border-radius: 3px;
}

.sidebar-content::-webkit-scrollbar-thumb:hover {
  background: var(--yellow-secondary);
}

/* Main Content */
main {
  flex: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 3rem 2rem;
  width: 100%;
}

section {
  margin-bottom: 3rem;
}

section h1 {
  color: var(--yellow-primary);
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  line-height: 1.2;
  text-shadow: 0 2px 10px rgba(255, 215, 0, 0.3);
}

section h2 {
  color: var(--yellow-secondary);
  font-size: 2rem;
  margin-top: 2.5rem;
  margin-bottom: 1.5rem;
  line-height: 1.3;
}

section h3 {
  color: var(--yellow-primary);
  font-size: 1.5rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

p {
  margin-bottom: 1.25rem;
  color: var(--text-secondary);
  font-size: 1.1rem;
}

ul, ol {
  margin-left: 2rem;
  margin-bottom: 1.5rem;
  color: var(--text-secondary);
}

nav > ul, ol {
  margin-left: 0;
  margin-bottom: 0;
}

li {
  margin-bottom: 0.75rem;
  line-height: 1.7;
}

.nav-menu li {
  margin-bottom: 0;
}

strong {
  color: var(--yellow-primary);
  font-weight: 600;
}

/* Banner Styles */
.banner {
  width: 100%;
  margin: 2.5rem 0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(255, 215, 0, 0.2);
  border: 2px solid var(--yellow-primary);
  display: block;
  text-decoration: none;
  transition: var(--transition);
  cursor: pointer;
}

.banner:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 40px rgba(255, 215, 0, 0.4);
  border-color: var(--yellow-secondary);
}

.banner img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  pointer-events: none;
}

.banner-first {
  margin-top: 0;
  margin-bottom: 3rem;
}

.banner-middle {
  margin: 4rem 0;
}

/* Table Styles */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  background: var(--bg-secondary);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

thead {
  background: linear-gradient(135deg, var(--yellow-primary), var(--yellow-dark));
}

th {
  padding: 1rem;
  text-align: left;
  color: var(--bg-primary);
  font-weight: 700;
  font-size: 1.1rem;
}

tbody tr {
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

tbody tr:hover {
  background: var(--hover-bg);
}

tbody tr:last-child {
  border-bottom: none;
}

td {
  padding: 1rem;
  color: var(--text-secondary);
}

/* FAQ Accordion Styles */
.faq-accordion {
  margin: 2rem 0;
}

.faq-item {
  margin-bottom: 1rem;
  background: var(--bg-secondary);
  border-radius: 8px;
  border: 1px solid var(--border-color);
  overflow: hidden;
  transition: var(--transition);
}

.faq-item:hover {
  border-color: var(--yellow-primary);
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.1);
}

.faq-question {
  width: 100%;
  padding: 1.25rem 1.5rem;
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 1.1rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  transition: var(--transition);
}

.faq-question:hover {
  background: var(--hover-bg);
  color: var(--yellow-primary);
}

.faq-question[aria-expanded="true"] {
  color: var(--yellow-primary);
  background: var(--hover-bg);
}

.faq-icon {
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--yellow-primary);
  transition: var(--transition);
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.faq-question[aria-expanded="true"] .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 1.5rem;
}

.faq-question[aria-expanded="true"] + .faq-answer {
  max-height: 500px;
  padding: 0 1.5rem 1.5rem 1.5rem;
}

.faq-answer p {
  color: var(--text-secondary);
  margin: 0;
  padding-top: 1rem;
  line-height: 1.7;
}

/* Footer Styles */
footer {
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
  border-top: 2px solid var(--yellow-primary);
  padding: 3rem 0 0 0;
  margin-top: 4rem;
  box-shadow: 0 -4px 20px rgba(255, 215, 0, 0.1);
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.footer-main {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2.5rem;
  padding-bottom: 2.5rem;
}

.footer-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer-logo {
  margin-bottom: 0.5rem;
}

.footer-logo-img {
  width: 50px;
  height: 50px;
  object-fit: contain;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.6)) drop-shadow(0 0 15px rgba(255, 255, 255, 0.4));
}

.footer-description {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin: 0;
}

.footer-title {
  color: var(--yellow-primary);
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.footer-nav {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-nav li {
  margin: 0;
}

.footer-nav a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition);
  font-size: 0.95rem;
  display: inline-block;
}

.footer-nav a:hover {
  color: var(--yellow-primary);
  transform: translateX(5px);
}

.footer-text {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin: 0.25rem 0;
  line-height: 1.6;
}

.footer-warning {
  background: rgba(255, 215, 0, 0.1);
  border-top: 1px solid var(--yellow-primary);
  border-bottom: 1px solid var(--yellow-primary);
  padding: 1.5rem 2rem;
  margin: 0;
}

.footer-warning p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  margin: 0;
  text-align: center;
}

.footer-warning strong {
  color: var(--yellow-primary);
  font-size: 1.1rem;
}

.footer-copyright {
  text-align: center;
  padding: 1.5rem 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  border-top: 1px solid var(--border-color);
  margin-top: 0;
}

.footer-copyright p {
  margin: 0;
}

/* Responsive Design */
/* Скрываем боковые панели, если не хватает места */
@media (max-width: 1600px) {
  .sidebar {
    display: none;
  }
}

@media (max-width: 768px) {
  .header-container {
    padding: 0 1rem;
    justify-content: space-between;
  }

  .logo {
    flex-shrink: 0;
  }

  .mobile-menu-toggle {
    display: block;
    margin-left: auto;
  }

  .header-container {
    position: relative;
  }

  nav {
    position: absolute;
    top: 67px;
    left: 0;
    right: 0;
    width: 100%;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    border-top: 2px solid var(--yellow-primary);
    box-shadow: 0 4px 20px rgba(255, 215, 0, 0.2);
    z-index: 999;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.3s ease;
  }

  nav.menu-open {
    max-height: 500px;
    opacity: 1;
  }

  .nav-menu {
    display: flex;
    width: 100%;
    flex-direction: column;
    gap: 0;
    margin: 0;
    padding: 1rem;
    list-style: none;
  }

  .nav-menu li {
    width: 100%;
    margin: 0;
    padding: 0;
  }

  .nav-menu a {
    display: block;
    width: 100%;
    text-align: center;
    padding: 1rem;
    margin: 0;
    border-radius: 0;
    border-bottom: 1px solid var(--border-color);
  }

  .nav-menu a::after {
    display: none;
  }

  .nav-menu a:hover {
    background: var(--hover-bg);
    color: var(--yellow-primary);
  }

  .nav-menu li:last-child a {
    border-bottom: none;
  }

  main {
    padding: 2rem 1rem;
  }

  section h1 {
    font-size: 2rem;
  }

  section h2 {
    font-size: 1.75rem;
  }

  section h3 {
    font-size: 1.25rem;
  }

  p {
    font-size: 1rem;
  }

  .footer-main {
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
  }

  .footer-section {
    align-items: center;
    text-align: center;
  }

  .footer-logo {
    display: flex;
    justify-content: center;
  }

  .footer-nav {
    align-items: center;
  }

  .footer-nav a {
    text-align: center;
  }

  .footer-warning {
    padding: 1.25rem 1.5rem;
  }

  .footer-warning p {
    font-size: 0.85rem;
  }

  .sticky-banner {
    padding: 0.5rem 1rem;
    flex-direction: column;
    gap: 0.75rem;
  }

  .sticky-banner-text {
    font-size: 0.85rem;
    text-align: center;
  }

  .sticky-banner-text strong {
    font-size: 0.95rem;
    display: block;
    margin-bottom: 0.25rem;
  }

  .sticky-banner-btn {
    width: 100%;
    padding: 0.625rem 1.25rem;
    font-size: 0.9rem;
  }

  .scroll-to-top {
    bottom: 1.5rem;
    right: 1.5rem;
    width: 45px;
    height: 45px;
  }

  .scroll-to-top svg {
    width: 20px;
    height: 20px;
  }

  table {
    font-size: 0.9rem;
  }

  th, td {
    padding: 0.75rem 0.5rem;
  }
}

@media (max-width: 480px) {
  .logo {
    font-size: 1.25rem;
  }

  .logo-icon {
    width: 50px;
    height: 50px;
  }

  section h1 {
    font-size: 1.75rem;
  }

  section h2 {
    font-size: 1.5rem;
  }

  table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

/* Smooth Scroll */
html {
  scroll-behavior: smooth;
}

/* Scroll to Top Button */
.scroll-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--yellow-primary), var(--yellow-secondary));
  border: 2px solid var(--yellow-primary);
  border-radius: 50%;
  color: var(--bg-primary);
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1001;
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
  transition: var(--transition);
  opacity: 0;
  transform: translateY(20px);
}

/* Sticky Bottom Banner */
.sticky-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
  border-top: 2px solid var(--yellow-primary);
  padding: 0.625rem 1.5rem;
  z-index: 1000;
  box-shadow: 0 -4px 20px rgba(255, 215, 0, 0.3);
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  animation: slideUp 0.3s ease;
}

.sticky-banner.show {
  display: flex;
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

.sticky-banner-text {
  color: var(--text-primary);
  font-size: 0.9rem;
  font-weight: 600;
  flex: 1;
  text-align: center;
  line-height: 1.3;
}

.sticky-banner-text strong {
  color: var(--yellow-primary);
  font-size: 1rem;
}

.sticky-banner-btn {
  background: linear-gradient(135deg, var(--yellow-primary), var(--yellow-secondary));
  color: var(--bg-primary);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.625rem 1.5rem;
  border-radius: 6px;
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
  white-space: nowrap;
  flex-shrink: 0;
}

.sticky-banner-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 215, 0, 0.6);
  background: linear-gradient(135deg, var(--yellow-secondary), var(--yellow-primary));
}

.scroll-to-top.show {
  display: flex;
  opacity: 1;
  transform: translateY(0);
}

.scroll-to-top:hover {
  background: linear-gradient(135deg, var(--yellow-secondary), var(--yellow-primary));
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(255, 215, 0, 0.6);
}

.scroll-to-top svg {
  width: 24px;
  height: 24px;
}

/* Error 404 Page */
.error-404 {
  text-align: center;
  padding: 4rem 2rem;
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.error-404 h1 {
  color: var(--yellow-primary);
  font-size: 3rem;
  margin-bottom: 1.5rem;
}

.error-404 p {
  font-size: 1.2rem;
  margin-bottom: 1rem;
  max-width: 600px;
}

.error-404 a {
  color: var(--yellow-primary);
  text-decoration: none;
  font-weight: 600;
  border-bottom: 2px solid var(--yellow-primary);
  transition: var(--transition);
}

.error-404 a:hover {
  color: var(--yellow-secondary);
  border-color: var(--yellow-secondary);
}

/* Selection */
::selection {
  background: var(--yellow-primary);
  color: var(--bg-primary);
}

::-moz-selection {
  background: var(--yellow-primary);
  color: var(--bg-primary);
}

