/* =========================================================================
   "МИР БЕСПИЛОТНИКОВ" — СИСТЕМНЫЕ СТИЛИ И СЕТКА (MAIN.CSS)
   =========================================================================
   Этот файл содержит базовые сбросы, сетку, компоненты и анимации.
   Шрифты, цвета и акценты настраиваются в css/designer.css.
   ========================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* --- 1. БАЗОВЫЕ СБРОСЫ И СТАНДАРТЫ --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  color-scheme: light;
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-family-body);
  background-color: var(--color-bg-primary);
  color: var(--color-text-main);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
  font-size-adjust: from-font;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family-title);
  color: var(--color-text-white);
  font-weight: 700;
  line-height: 1.25;
  font-size-adjust: cap-height from-font;
}

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color var(--transition-speed) var(--transition-ease);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
  transition: all var(--transition-speed) var(--transition-ease);
}

/* Настройки скроллбара */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--color-bg-primary);
}
::-webkit-scrollbar-thumb {
  background: var(--color-bg-tertiary);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-accent);
}

/* --- 2. СЕТКА И КОНТЕЙНЕРЫ --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 5rem 0;
}

@media (max-width: 768px) {
  .section {
    padding: 3.5rem 0;
  }
}

/* --- 3. ШАПКА САЙТА (HEADER) --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--glass-border);
  transition: all var(--transition-speed) var(--transition-ease);
}

.header--scrolled {
  padding: 0.5rem 0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-family-title);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--color-text-white);
  letter-spacing: -0.5px;
}

.logo-icon {
  width: 32px;
  height: 32px;
  fill: var(--color-accent);
}

.header-partners {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-shrink: 0;
}

.logo-partner-fasie {
  height: 45px;
  width: auto;
  display: block;
  transition: all 0.3s ease;
}

.logo-partner-innopolis {
  height: 25px;
  width: auto;
  display: block;
  transition: all 0.3s ease;
}

.logo-partner-artek {
  height: 33px;
  width: auto;
  display: block;
  transition: all 0.3s ease;
}

.logo-partner-fasie:hover,
.logo-partner-innopolis:hover,
.logo-partner-artek:hover {
  transform: scale(1.03);
}

@media (max-width: 480px) {
  .header-partners {
    gap: 12px;
  }
  .logo-partner-fasie {
    height: 32px;
  }
  .logo-partner-innopolis {
    height: 18px;
  }
  .logo-partner-artek {
    height: 20px;
  }
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-list {
  display: flex;
  list-style: none;
  gap: 1.25rem;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-text-muted);
  position: relative;
  padding: 0.25rem 0;
  white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
  color: var(--color-text-white);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width var(--transition-speed) var(--transition-ease);
}

.nav-link:hover::after, .nav-link.active::after {
  width: 100%;
}

.nav-btn {
  padding: 0.6rem 1.5rem;
  border-radius: var(--border-radius-btn);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-text-white);
  background: var(--gradient-primary);
  box-shadow: 0 4px 15px rgba(0, 240, 255, 0.2);
}

.nav-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 240, 255, 0.4);
}

/* Мобильное меню гамбургер */
.menu-toggle {
  display: none;
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: pointer;
  z-index: 101;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.menu-toggle:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
  transform: scale(1.05);
}

.menu-toggle:active {
  transform: scale(0.95);
}

.menu-toggle span {
  position: absolute;
  left: 13px;
  height: 2px;
  background-color: var(--color-text-white);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 2px;
}

.menu-toggle span:nth-child(1) {
  top: 16px;
  width: 18px;
}

.menu-toggle span:nth-child(2) {
  top: 21px;
  width: 12px;
  left: 19px;
}

.menu-toggle span:nth-child(3) {
  top: 26px;
  width: 18px;
}

.nav-auth-container {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.nav-login-link {
  color: var(--color-text-white);
  font-weight: 600;
  font-size: 0.95rem;
  transition: color var(--transition-speed) var(--transition-ease);
  text-decoration: none;
}

.nav-login-link:hover {
  color: var(--color-accent);
}

.nav-logout-btn {
  color: var(--color-text-muted);
  font-weight: 500;
  font-size: 0.9rem;
  transition: color var(--transition-speed) var(--transition-ease);
  text-decoration: none;
}

.nav-logout-btn:hover {
  color: var(--color-text-white);
}

.nav-menu-footer {
  display: none;
}

@media (max-width: 1200px) {
  .header .container {
    padding: 0 1rem;
  }
  .header-partners {
    gap: 15px;
  }
  .logo-partner-fasie {
    height: 38px;
  }
  .logo-partner-innopolis {
    height: 22px;
  }
  .logo-partner-artek {
    height: 28px;
  }
  .nav {
    gap: 1rem;
  }
  .nav-list {
    gap: 0.8rem;
  }
  .nav-link {
    font-size: 0.85rem;
  }
  .nav-btn {
    padding: 0.5rem 1.25rem;
    font-size: 0.85rem;
  }
  .nav-login-link {
    font-size: 0.85rem;
  }
}

@media (max-width: 1150px) {
  .menu-toggle {
    display: block;
  }
  
  .nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 320px;
    height: 100dvh;
    height: 100vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-left: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: -15px 0 40px rgba(0, 0, 0, 0.4);
    flex-direction: column;
    justify-content: flex-start;
    padding: 5.5rem 2rem 2.5rem;
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 99;
  }
  
  .nav--open {
    right: 0;
  }
  
  .nav-list {
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    flex-shrink: 0;
    width: 100%;
  }
  
  .nav-link {
    font-size: 1.2rem;
  }

  .nav-btn {
    width: 100%;
    text-align: center;
  }

  .nav-login-link {
    font-size: 1.1rem;
  }

  .nav-auth-container {
    flex-direction: column;
    width: 100%;
    gap: 1.25rem;
    margin-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 1.5rem;
    flex-shrink: 0;
  }
  
  .nav-logout-btn {
    font-size: 1.1rem;
  }

  .nav-menu-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    margin-top: auto;
    padding-top: 2rem;
    width: 100%;
    flex-shrink: 0;
  }

  .nav-menu-divider {
    width: 40px;
    height: 2px;
    background: var(--color-accent);
    border-radius: 1px;
    margin-bottom: 0.5rem;
    opacity: 0.8;
  }

  .nav-menu-email {
    color: var(--color-text-muted);
    font-size: 0.9rem;
    text-decoration: none;
    transition: color var(--transition-speed) var(--transition-ease);
  }

  .nav-menu-email:hover {
    color: var(--color-text-white);
  }

  .nav-menu-copyright {
    color: rgba(255, 255, 255, 0.25);
    font-size: 0.75rem;
    letter-spacing: 0.05em;
  }

  /* Анимация кнопки меню */
  .menu-toggle.open span:nth-child(1) {
    transform: translateY(5px) rotate(45deg);
    width: 18px;
    left: 13px;
  }
  .menu-toggle.open span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
  }
  .menu-toggle.open span:nth-child(3) {
    transform: translateY(-5px) rotate(-45deg);
    width: 18px;
    left: 13px;
  }

  /* Каскадное появление элементов меню */
  @keyframes slideInRight {
    from {
      opacity: 0;
      transform: translateX(30px);
    }
    to {
      opacity: 1;
      transform: translateX(0);
    }
  }

  .nav--open .nav-list li {
    animation: slideInRight 0.5s cubic-bezier(0.4, 0, 0.2, 1) both;
  }
  .nav--open .nav-list li:nth-child(1) { animation-delay: 0.1s; }
  .nav--open .nav-list li:nth-child(2) { animation-delay: 0.15s; }
  .nav--open .nav-list li:nth-child(3) { animation-delay: 0.2s; }
  .nav--open .nav-list li:nth-child(4) { animation-delay: 0.25s; }
  .nav--open .nav-list li:nth-child(5) { animation-delay: 0.3s; }

  .nav--open .nav-auth-container {
    animation: slideInRight 0.5s cubic-bezier(0.4, 0, 0.2, 1) both;
    animation-delay: 0.35s;
  }

  .nav--open .nav-menu-footer {
    animation: slideInRight 0.5s cubic-bezier(0.4, 0, 0.2, 1) both;
    animation-delay: 0.4s;
  }
}

/* --- 4. ГЕРОЙ-СЕКЦИЯ (HERO) --- */
.hero {
  position: relative;
  min-height: 100vh;
  padding-top: 120px;
  display: flex;
  align-items: center;
  background-size: var(--bg-grid-size) var(--bg-grid-size);
  background-image: 
    linear-gradient(to right, var(--bg-grid-line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--bg-grid-line) 1px, transparent 1px);
  overflow: hidden;
}

.hero .container {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 3rem;
  align-items: center;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.badge {
  display: inline-block;
  padding: 0.4rem 1rem;
  background: rgba(0, 240, 255, 0.1);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: var(--border-radius-badge);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-accent);
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  line-height: 1.1;
  margin-bottom: 2rem;
  letter-spacing: -1px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
}

.hero-title-img {
  height: clamp(6.75rem, 13.5vw, 9.75rem);
  width: auto;
  display: block;
}

.hero-title span {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-text {
  font-size: clamp(1.1rem, 2vw, 1.25rem);
  color: var(--color-text-muted);
  margin-bottom: 2.5rem;
  max-width: 600px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1.1rem 2.5rem;
  border-radius: var(--border-radius-btn);
  font-weight: 700;
  font-size: 1.1rem;
  text-align: center;
  transition: all var(--transition-speed) var(--transition-ease);
}

.btn-primary {
  background: var(--gradient-primary);
  color: var(--color-text-white);
  box-shadow: 0 8px 30px rgba(0, 240, 255, 0.3);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 35px rgba(0, 240, 255, 0.5);
}

.btn-outline {
  border: 2px solid var(--color-bg-tertiary);
  color: var(--color-text-main);
  background: transparent;
}

.btn-outline:hover {
  border-color: var(--color-accent);
  color: var(--color-text-white);
  transform: translateY(-3px);
}

.btn-outline--danger {
  border: 2px solid rgba(239, 68, 68, 0.4);
  color: #ef4444;
  background: transparent;
}

.btn-outline--danger:hover {
  border-color: #ef4444;
  color: var(--color-text-white);
  box-shadow: 0 0 15px rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.1);
}

.btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.drone-container {
  width: 100%;
  max-width: 450px;
  position: relative;
  animation: float 6s ease-in-out infinite;
}

.drone-glow {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 240, 255, 0.2) 0%, transparent 70%);
  filter: blur(20px);
  z-index: -1;
}

.drone-svg {
  width: 100%;
  height: auto;
  fill: none;
  stroke: var(--color-accent);
  stroke-width: 1.5;
  filter: drop-shadow(0 0 15px rgba(0, 240, 255, 0.6));
}

@keyframes float {
  0% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(2deg); }
  100% { transform: translateY(0px) rotate(0deg); }
}

@media (max-width: 992px) {
  .hero {
    padding-top: 100px;
    min-height: auto;
    padding-bottom: 4rem;
  }
  .hero .container {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 4rem;
  }
  .hero-content {
    align-items: center;
  }
  .hero-title {
    align-items: center;
    text-align: center;
  }
  .hero-title-img {
    height: auto;
    width: auto;
    max-width: 90%;
    max-height: 6.75rem;
  }
  .btn-group {
    justify-content: center;
  }
  .drone-container {
    max-width: 320px;
  }
}

@media (max-width: 576px) {
  .hero-title-img {
    width: 100%;
    max-width: 100%;
    height: auto;
    max-height: none;
  }
}

/* --- 5. О ПРОЕКТЕ (ABOUT SECTION) --- */
.section-title {
  text-align: center;
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  margin-bottom: 1rem;
}

.section-subtitle {
  text-align: center;
  color: var(--color-text-muted);
  max-width: 700px;
  margin: 0 auto 4rem;
  font-size: 1.1rem;
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.about-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-card);
  padding: 2.5rem 2rem;
  transition: all var(--transition-speed) var(--transition-ease);
  position: relative;
  overflow: hidden;
}

.about-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity var(--transition-speed) var(--transition-ease);
}

.about-card:hover {
  transform: translateY(-10px);
  border-color: rgba(0, 240, 255, 0.3);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
}

.about-card:hover::before {
  opacity: 1;
}

.about-icon-box {
  width: 60px;
  height: 60px;
  border-radius: 12px;
  background: rgba(0, 240, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.about-icon {
  width: 32px;
  height: 32px;
  fill: var(--color-accent);
}

.about-card-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.about-card-text {
  color: var(--color-text-muted);
  font-size: 0.95rem;
}

/* Статистика */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-card);
  padding: 3rem 2rem;
  text-align: center;
}

.stat-item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.stat-number {
  font-family: var(--font-family-title);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  color: var(--color-accent);
}

.stat-label {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

@media (max-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem 1rem;
    padding: 2rem 1.5rem;
  }
}

@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

/* --- 6. ПОЛОЖЕНИЕ (REGULATIONS SECTION) --- */
.rules-container {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
  align-items: center;
}

.rules-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.rules-text {
  color: var(--color-text-muted);
  margin-bottom: 2rem;
  font-size: 1.1rem;
}

.rules-list {
  list-style: none;
  margin-bottom: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.rules-list-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.rules-check {
  width: 24px;
  height: 24px;
  fill: var(--color-accent);
  flex-shrink: 0;
  margin-top: 0.15rem;
}

.rules-list-text {
  color: var(--color-text-main);
  font-weight: 500;
}

.rules-card-preview {
  background: var(--color-bg-secondary);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-card);
  padding: 3rem 2rem;
  text-align: center;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

.rules-card-icon {
  width: 80px;
  height: 80px;
  fill: var(--color-accent-secondary);
  filter: drop-shadow(0 0 10px rgba(173, 0, 255, 0.4));
}

.rules-card-title {
  font-size: 1.2rem;
  font-weight: 600;
}

.rules-card-meta {
  color: var(--color-text-muted);
  font-size: 0.85rem;
}

@media (max-width: 992px) {
  .rules-container {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

/* --- 7. ВИДЕО-БЛОК (VIDEO SECTION) --- */
.video-wrapper {
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  border-radius: var(--border-radius-card);
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  border: 1px solid var(--glass-border);
  background: var(--color-bg-secondary);
  aspect-ratio: 16 / 9;
}

/* Обложка видео */
.video-cover {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 3;
  transition: transform var(--transition-speed) var(--transition-ease);
}

.video-cover::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(8, 11, 17, 0.5);
  transition: background var(--transition-speed) var(--transition-ease);
}

.video-cover:hover::before {
  background: rgba(8, 11, 17, 0.3);
}

.video-cover:hover .play-btn {
  transform: scale(1.1);
  box-shadow: 0 0 40px rgba(0, 240, 255, 0.7);
}

.play-btn {
  position: relative;
  width: 80px;
  height: 80px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-speed) var(--transition-ease);
  box-shadow: 0 0 25px rgba(0, 240, 255, 0.4);
}

.play-icon {
  width: 30px;
  height: 30px;
  fill: var(--color-text-white);
  transform: translateX(3px);
}

.video-iframe {
  width: 100%;
  height: 100%;
  border: none;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}

.video-iframe.loaded {
  opacity: 1;
}

/* --- 8. РЕГИСТРАЦИЯ (CTA BANNER) --- */
.cta-banner {
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.05) 0%, rgba(173, 0, 255, 0.05) 100%);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-card);
  padding: 4rem 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-banner::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(0, 240, 255, 0.05) 0%, transparent 60%);
  z-index: -1;
  pointer-events: none;
}

.cta-banner h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 1.5rem;
}

.cta-banner p {
  color: var(--color-text-muted);
  max-width: 600px;
  margin: 0 auto 2.5rem;
  font-size: 1.15rem;
}

@media (max-width: 768px) {
  .cta-banner {
    padding: 3rem 1.5rem;
  }
}

/* --- 9. ПОДВАЛ (FOOTER) --- */
.footer {
  background: var(--color-bg-secondary);
  border-top: 1px solid var(--glass-border);
  padding: 4rem 0 2rem;
}

.footer-top {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-column {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.footer-logo {
  font-family: var(--font-family-title);
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--color-text-white);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-logo-icon {
  width: 28px;
  height: 28px;
  fill: var(--color-accent);
}

.footer-text {
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.footer-title {
  font-size: 1.1rem;
  position: relative;
  padding-bottom: 0.5rem;
}

.footer-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 35px;
  height: 2px;
  background: var(--color-accent);
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-link {
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.footer-link:hover {
  color: var(--color-text-white);
  padding-left: 5px;
}

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.footer-contact-icon {
  width: 18px;
  height: 18px;
  fill: var(--color-accent);
}

.footer-bottom {
  border-top: 1px solid var(--glass-border);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  color: var(--color-text-muted);
  font-size: 0.85rem;
}

@media (max-width: 768px) {
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
}

/* --- 10. НАТИВНЫЙ ДИАЛОГ (DIALOG) --- */
dialog {
  margin: auto;
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-card);
  background: var(--color-bg-secondary);
  color: var(--color-text-main);
  padding: 3rem 2.5rem;
  max-width: 800px;
  width: 90%;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8);
  outline: none;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
}

dialog::backdrop {
  background: rgba(8, 11, 17, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

dialog:not([open]) {
  display: none;
}

.dialog-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--glass-border);
  padding-bottom: 1.25rem;
  flex-shrink: 0;
}

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

.dialog-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--color-bg-tertiary);
  color: var(--color-text-muted);
  border: 1px solid var(--glass-border);
}

.dialog-close:hover {
  background: var(--color-accent);
  color: var(--color-text-white);
  transform: rotate(90deg);
}

.dialog-close-icon {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.dialog-body {
  overflow-y: auto;
  padding-right: 1rem;
  flex-grow: 1;
}

.dialog-body h3 {
  font-size: 1.2rem;
  margin: 1.5rem 0 0.75rem;
}

.dialog-body p {
  color: var(--color-text-muted);
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.dialog-body ol {
  padding-left: 1.5rem;
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
}

.dialog-body li {
  margin-bottom: 0.5rem;
}

/* --- 11. АНИМАЦИИ ПРИ СКРОЛЛЕ --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
  will-change: opacity, transform;
}

.reveal--visible {
  opacity: 1;
  transform: translateY(0);
}

/* Фокусировка для доступности (Accessibility) */
*:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 4px;
}

/* --- 12. КАБИНЕТ УЧАСТНИКА И АДМИН-ПАНЕЛЬ (DASHBOARD & CAB STYLES) --- */
.cabinet-wrapper {
  padding-top: 120px;
  min-height: calc(100vh - 100px);
}

.cabinet-grid {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 2.5rem;
  align-items: start;
  margin-bottom: 4rem;
}

@media (max-width: 992px) {
  .cabinet-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

/* Карточки Личного Кабинета */
.cab-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-card);
  padding: 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.cab-profile-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1rem;
}

.cab-avatar {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--color-text-white);
  box-shadow: 0 0 25px rgba(0, 240, 255, 0.3);
}

/* Бейджи Статусов */
.status-badge {
  display: inline-block;
  padding: 0.35rem 0.9rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid transparent;
}

/* 5 Новых Статусов модерации */
.status-badge--registered {
  background: rgba(224, 33, 138, 0.08) !important;
  border: 1px solid rgba(224, 33, 138, 0.2) !important;
  color: var(--color-accent) !important;
}

.status-badge--submitted {
  background: rgba(245, 158, 11, 0.08) !important;
  border: 1px solid rgba(245, 158, 11, 0.2) !important;
  color: #f59e0b !important;
}

.status-badge--finalist {
  background: rgba(16, 185, 129, 0.08) !important;
  border: 1px solid rgba(16, 185, 129, 0.2) !important;
  color: #10b981 !important;
}

.status-badge--participant {
  background: rgba(99, 102, 241, 0.08) !important;
  border: 1px solid rgba(99, 102, 241, 0.2) !important;
  color: #818cf8 !important;
}

.status-badge--disqualified {
  background: rgba(239, 68, 68, 0.08) !important;
  border: 1px solid rgba(239, 68, 68, 0.2) !important;
  color: #ef4444 !important;
}

/* Обратная совместимость */
.status-badge--pending {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.3);
  color: #f59e0b;
}

.status-badge--approved {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #10b981;
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.15);
}

.status-badge--rejected {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #ef4444;
}

.status-badge--info {
  background: rgba(0, 240, 255, 0.15);
  border: 1px solid rgba(0, 240, 255, 0.3);
  color: var(--color-accent);
}

/* Формы ввода */
.form-title {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--glass-border);
  padding-bottom: 0.75rem;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

@media (max-width: 576px) {
  .form-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group--full {
  grid-column: 1 / -1;
}

.form-label {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  font-weight: 500;
}

.form-control {
  background: var(--color-bg-tertiary);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  color: var(--color-text-main);
  font-family: inherit;
  font-size: 1rem;
  transition: all var(--transition-speed) var(--transition-ease);
}

.form-control:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}

.form-control::placeholder {
  color: #55627a;
}

/* Страницы авторизации (Login/Register) */
.auth-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
  background-size: var(--bg-grid-size) var(--bg-grid-size);
  background-image: 
    linear-gradient(to right, var(--bg-grid-line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--bg-grid-line) 1px, transparent 1px);
}

.auth-card {
  width: 100%;
  max-width: 550px;
  background: var(--glass-bg);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-card);
  padding: 3rem;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.auth-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.auth-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-family-title);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--color-text-white);
  margin-bottom: 1.5rem;
}

.auth-logo-icon {
  width: 32px;
  height: 32px;
  fill: var(--color-accent);
}

.auth-subtitle {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  margin-top: 0.5rem;
}

.auth-footer {
  text-align: center;
  margin-top: 2rem;
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.auth-footer a {
  color: var(--color-accent);
  font-weight: 600;
}

@media (max-width: 576px) {
  .auth-card {
    padding: 2rem 1.5rem;
  }
}

/* Списки загрузок */
.upload-zone {
  border: 2px dashed var(--glass-border);
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-speed) var(--transition-ease);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.upload-zone:hover {
  border-color: var(--color-accent);
  background: rgba(0, 240, 255, 0.02);
}

.upload-icon {
  width: 48px;
  height: 48px;
  fill: var(--color-text-muted);
}

.uploaded-docs-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.uploaded-doc-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--color-bg-tertiary);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 0.75rem 1rem;
}

.uploaded-doc-name {
  font-weight: 500;
  color: var(--color-text-white);
  font-size: 0.95rem;
}

.uploaded-doc-type {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

/* Сообщения флеша (Alerts) */
.flash-container {
  position: fixed;
  top: 90px;
  right: 20px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 400px;
  width: calc(100% - 40px);
}

.alert {
  padding: 1rem 1.25rem;
  border-radius: 8px;
  font-weight: 500;
  font-size: 0.95rem;
  box-shadow: 0 10px 25px rgba(0,0,0,0.3);
  display: flex;
  justify-content: space-between;
  align-items: center;
  animation: slideIn 0.3s ease forwards;
}

.alert--error {
  background: rgba(239, 68, 68, 0.95);
  color: #fff;
  border-left: 5px solid #b91c1c;
}

.alert--success {
  background: rgba(16, 185, 129, 0.95);
  color: #fff;
  border-left: 5px solid #047857;
}

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* --- 13. ПРЕМИАЛЬНАЯ АДМИН-ТАБЛИЦА (ADMIN VIEWS) --- */
.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

@media (max-width: 992px) {
  .admin-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 576px) {
  .admin-stats-grid {
    grid-template-columns: 1fr;
  }
}

.admin-stat-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-card);
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.admin-stat-icon-box {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.admin-stat-val {
  font-family: var(--font-family-title);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--color-text-white);
  line-height: 1.2;
}

.admin-stat-lbl {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.admin-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.admin-filters {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  flex-grow: 1;
}

.table-wrapper {
  background: var(--color-bg-secondary);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-card);
  width: 100%;
  max-width: 100%;
  display: block;
  overflow-x: auto;
  box-shadow: 0 15px 40px rgba(0,0,0,0.4);
  margin-bottom: 3rem;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.95rem;
}

.admin-table th {
  background: var(--color-bg-tertiary);
  padding: 1.25rem 1.5rem;
  color: var(--color-text-white);
  font-weight: 600;
  border-bottom: 1px solid var(--glass-border);
}

.admin-table td {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.03);
  color: var(--color-text-main);
  vertical-align: middle;
}

.admin-table-row:hover {
  background: rgba(255,255,255,0.01);
}

.admin-docs-list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.admin-doc-link {
  font-size: 0.85rem;
  color: var(--color-accent);
  text-decoration: underline;
}

.admin-doc-link:hover {
  color: var(--color-text-white);
}

/* Статус-диалог администратора */
.admin-dialog {
  max-width: 500px;
}

.admin-dialog .form-group {
  margin-bottom: 1.25rem;
}

/* Сброс цвета для опций в datalist и select для контрастного отображения в системных темах */
option {
  color: #1e293b !important;
  background-color: #ffffff !important;
}

