/* Color Variables */
:root {
  --white: rgb(255, 255, 255);
  --yellow-accent: rgb(250, 195, 17);
  --dark-bg: rgb(28, 30, 31);
  --dark-text: rgb(30, 30, 30);
  --secondary-text: rgb(100, 100, 100);
}

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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: var(--dark-text);
  background-color: var(--white);
  line-height: 1.6;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* Topbar */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding: 1rem 0;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  animation: slideDown 0.8s ease-out;
  transition: all 0.3s ease;
}



.topbar.scrolled {
  padding: 0.5rem 0;
  background: rgba(255, 255, 255, 0.8);
}

.topbar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--dark-bg);
  text-decoration: none;
  transition: all 0.3s ease;
}

.logo:hover {
  transform: scale(1.05);
  text-shadow: 0 0 10px rgba(250, 195, 17, 0.5);
}

.topbar-nav {
  display: none;
  gap: 1.5rem;
}

.topbar-link {
  color: var(--dark-bg);
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  transition: all 0.3s ease;
  opacity: 0;
  animation: fadeInSlide 0.5s ease-out forwards;
}

.topbar-link:nth-child(1) {
  animation-delay: 0.1s;
}

.topbar-link:nth-child(2) {
  animation-delay: 0.2s;
}

.topbar-link:hover {
  background-color: var(--yellow-accent);
  color: var(--dark-bg);
}

/* Стили бургер-кнопки */
.mobile-menu-toggle {
  display: none; /* скрываем на десктопе */
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 22px;
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
}

.mobile-menu-toggle span {
  display: block;
  height: 3px;
  width: 100%;
  background: var(--dark-bg);
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* Анимация бургер-меню */
.mobile-menu-toggle.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-toggle.open span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Показываем бургер на мобильных */
@media (max-width: 768px) {
  .mobile-menu-toggle {
    display: flex;
    z-index: 1001; /* Ensure it's above the nav */
  }
  
  .topbar-nav {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--white);
    width: 200px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border-radius: 8px;
    padding: 1rem;
    z-index: 1000;
    margin-top: 0.5rem;
  }

  .topbar-nav.active {
    display: flex;
  }
  
  .topbar-link {
    padding: 0.75rem 1rem;
    text-align: center;
    border-radius: 4px;
    margin-bottom: 0.5rem;
  }
  
  .topbar-link:last-child {
    margin-bottom: 0;
  }
}

.topbar-login {
  background: none;
  border: none;
  padding: 0.5rem 0.75rem;

  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;

  color: var(--dark-bg);
  cursor: pointer;

  position: relative;
  border-radius: 4px;

  transition:
    color 0.25s ease,
    background-color 0.25s ease;
}

/* Hover — жёлтый акцент как у ссылок */
.topbar-login:hover {
  background-color: var(--yellow-accent);
  color: var(--dark-bg);
}

/* Active */
.topbar-login:active {
  transform: translateY(1px);
}

/* Focus (доступность) */
.topbar-login:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px rgba(250, 195, 17, 0.6);
}

/* Анимация появления как у ссылок */
.topbar-login {
  opacity: 0;
  animation: fadeInSlide 0.5s ease-out forwards;
  animation-delay: 0.3s;
}

/* Login Modal Styles */
        .modal {
            display: none;
            position: fixed;
            z-index: 1001;
            left: 0;
            top: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.5);
            overflow: auto;
        }

        .modal-content {
            background-color: #fff;
            margin: 5% auto;
            padding: 20px;
            border-radius: 8px;
            width: 90%;
            max-width: 400px;
            position: relative;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
        }

        .close {
            color: #aaa;
            float: right;
            font-size: 28px;
            font-weight: bold;
            cursor: pointer;
            line-height: 1;
        }

        .close:hover,
        .close:focus {
            color: #000;
        }

        .tabs {
            display: flex;
            margin-bottom: 20px;
            border-bottom: 1px solid #eee;
        }

        .tab-button {
            background: none;
            border: none;
            padding: 10px 20px;
            cursor: pointer;
            font-size: 16px;
            color: #666;
            border-bottom: 3px solid transparent;
        }

        .tab-button.active {
            color: #262829;
            border-bottom: 3px solid #FCCC0F;
        }

        .tab-content {
            display: none;
        }

        .tab-content.active {
            display: block;
        }

        .form-group {
            margin-bottom: 15px;
        }

        .form-group label {
            display: block;
            margin-bottom: 5px;
            font-weight: bold;
            color: #333;
        }

        .form-group input {
            width: 100%;
            padding: 10px;
            border: 1px solid #ddd;
            border-radius: 4px;
            font-size: 16px;
            box-sizing: border-box;
        }

        .form-group input:focus {
            border-color: #FCCC0F;
            outline: none;
        }

        .submit-btn {
            width: 100%;
            padding: 12px;
            background-color: #262829;
            color: #FCCC0F;
            border: none;
            border-radius: 4px;
            font-size: 16px;
            font-weight: bold;
            cursor: pointer;
            transition: background-color 0.3s;
        }

        .submit-btn:hover {
            background-color: #000;
        }

        .login-button {
            background-color: #262829;
            color: #FCCC0F;
            border: none;
            padding: 10px 15px;
            border-radius: 4px;
            cursor: pointer;
            font-weight: bold;
            transition: background-color 0.3s;
            margin: 10px 0;
        }

        .login-button:hover {
            background-color: #000;
        }

        @media (max-width: 768px) {
            .modal-content {
                width: 95%;
                margin: 10% auto;
            }
        }
.forgot-password {
    display: block;
    text-align: center;
    margin: 15px 0;
    color: #262829;
    text-decoration: none;
    font-weight: bold;
}

.forgot-password:hover {
    text-decoration: underline;
}


/* Десктопное меню */
@media (min-width: 769px) {
  .topbar-nav {
    display: flex;
    gap: 1.5rem;
  }
}
