* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", "Poppins", "Orbitron", "Courier New", monospace;
}

body {
  background: radial-gradient(circle at 20% 30%, #0a0f1e, #03050b);
  color: #eef5ff;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container {
  max-width: 1300px;
  margin: 0 auto;
  padding: 20px 30px;
  position: relative;
  z-index: 2;
  flex: 1;
}

/* Шапка */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  background: rgba(10, 20, 30, 0.7);
  backdrop-filter: blur(12px);
  border-radius: 50px;
  padding: 12px 30px;
  margin-bottom: 40px;
  border: 1px solid rgba(0, 255, 255, 0.3);
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.2);
}

.logo {
  font-size: 1.8rem;
  font-weight: bold;
  letter-spacing: 2px;
  background: linear-gradient(135deg, #0ff, #f0f);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 5px rgba(0, 255, 255, 0.5);
}

.nav-buttons {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.nav-btn {
  background: rgba(20, 30, 45, 0.9);
  border: 1px solid #0ff;
  padding: 8px 18px;
  border-radius: 40px;
  color: #0ff;
  font-weight: bold;
  cursor: pointer;
  transition: 0.2s;
  font-size: 0.9rem;
}

.nav-btn:hover {
  background: #0ff;
  color: #0a0f1e;
  box-shadow: 0 0 12px #0ff;
  transform: scale(1.02);
}

/* Профиль с аватаркой */
.profile-area {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(0, 0, 0, 0.5);
  padding: 5px 15px 5px 5px;
  border-radius: 60px;
  border: 1px solid rgba(0, 255, 255, 0.4);
}
.avatar-small {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #0ff;
  background: #1e2a3a;
  cursor: pointer;
  transition: 0.2s;
}
.avatar-small:hover {
  transform: scale(1.05);
  box-shadow: 0 0 8px #0ff;
}
.profile-trigger {
  background: linear-gradient(95deg, #ff416c, #ff4b2b);
  border: none;
  padding: 8px 20px;
  border-radius: 40px;
  font-weight: bold;
  color: white;
  cursor: pointer;
  transition: 0.2s;
  box-shadow: 0 0 8px rgba(255, 75, 43, 0.5);
  font-size: 0.9rem;
}
.profile-trigger:hover {
  transform: scale(1.03);
  box-shadow: 0 0 18px #ff4b2b;
}

/* Контент страниц */
.page {
  background: rgba(12, 18, 28, 0.65);
  backdrop-filter: blur(8px);
  border-radius: 40px;
  padding: 30px 35px;
  border: 1px solid rgba(0, 255, 255, 0.4);
  transition: 0.2s;
  margin-top: 10px;
  box-shadow: 0 20px 35px rgba(0, 0, 0, 0.5);
}

.page h1 {
  font-size: 2.8rem;
  margin-bottom: 20px;
  background: linear-gradient(145deg, #fff, #0ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.page p,
.page li {
  font-size: 1.2rem;
  line-height: 1.5;
  margin-bottom: 12px;
}

.cards {
  display: flex;
  flex-wrap: wrap;
  gap: 25px;
  margin-top: 30px;
}

.card {
  background: rgba(0, 0, 0, 0.55);
  border-left: 5px solid #0ff;
  border-radius: 24px;
  padding: 20px;
  flex: 1 1 220px;
  transition: 0.2s;
}

.card h3 {
  color: #0ff;
  margin-bottom: 10px;
}

/* Модальное окно для профиля */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-content {
  background: #0f172ad9;
  border-radius: 40px;
  max-width: 550px;
  width: 90%;
  padding: 30px;
  border: 2px solid #0ff;
  box-shadow: 0 0 35px #0ff4;
  color: white;
}

.modal-content h2 {
  text-align: center;
  margin-bottom: 20px;
  color: #0ff;
}

/* Блок аватара в модалке */
.avatar-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 32px;
}
.avatar-preview {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #0ff;
  background: #1e2a3a;
  margin-bottom: 12px;
  box-shadow: 0 0 12px rgba(0, 255, 255, 0.4);
}
.avatar-upload-btn {
  background: #0ff22c;
  background: linear-gradient(135deg, #0ff, #0a9);
  border: none;
  padding: 8px 20px;
  border-radius: 60px;
  font-weight: bold;
  cursor: pointer;
  color: #0a0f1e;
  transition: 0.2s;
  font-size: 0.8rem;
}
.avatar-upload-btn:hover {
  background: #f0f;
  color: white;
  box-shadow: 0 0 8px #f0f;
}
.remove-avatar-btn {
  background: #ff4b2b99;
  border: none;
  padding: 6px 16px;
  border-radius: 60px;
  margin-top: 8px;
  font-size: 0.7rem;
  cursor: pointer;
  color: white;
}

/* Кнопка выхода */
.logout-btn {
  background: linear-gradient(135deg, #ff416c, #ff4b2b);
  border: none;
  padding: 10px 24px;
  border-radius: 60px;
  font-weight: bold;
  font-size: 0.95rem;
  cursor: pointer;
  color: white;
  transition: 0.2s;
  box-shadow: 0 0 10px rgba(255, 75, 43, 0.4);
  width: 100%;
}

.logout-btn:hover {
  background: linear-gradient(135deg, #ff6b6b, #ff0000);
  box-shadow: 0 0 18px #ff4b2b;
  transform: scale(1.02);
}

.toggle-auth {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-bottom: 25px;
}

.toggle-btn {
  background: transparent;
  border: none;
  font-size: 1.2rem;
  font-weight: bold;
  padding: 6px 20px;
  border-radius: 40px;
  cursor: pointer;
  color: #ccc;
  transition: 0.2s;
}

.toggle-btn.active {
  background: #0ff;
  color: #0a0f1e;
  box-shadow: 0 0 10px #0ff;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.auth-form input,
.auth-form select {
  background: #1e2a3a;
  border: 1px solid #0ff7;
  padding: 12px 15px;
  border-radius: 60px;
  color: white;
  font-size: 1rem;
  outline: none;
}

.auth-form input::placeholder {
  color: #aac8e0;
}

.auth-form button {
  background: #0ff;
  border: none;
  padding: 12px;
  border-radius: 60px;
  font-weight: bold;
  font-size: 1rem;
  cursor: pointer;
  transition: 0.2s;
  color: #0a0f1e;
}

.auth-form button:hover {
  background: #f0f;
  color: white;
  box-shadow: 0 0 12px #f0f;
}

.close-modal {
  margin-top: 20px;
  text-align: center;
  background: #ff4b2b80;
  display: inline-block;
  width: 100%;
  padding: 8px;
  border-radius: 60px;
  cursor: pointer;
  text-align: center;
  font-weight: bold;
}

.user-greeting {
  background: #0ff22a;
  background: linear-gradient(95deg, #0ff3, #f0f3);
  padding: 8px 16px;
  border-radius: 60px;
  font-size: 0.9rem;
  font-weight: bold;
}

footer {
  text-align: center;
  padding: 20px;
  font-size: 0.8rem;
  color: #0ff8;
  margin-top: 30px;
}

@media (max-width: 750px) {
  .navbar {
    flex-direction: column;
    gap: 15px;
    border-radius: 30px;
  }
  .nav-buttons {
    justify-content: center;
  }
  .page h1 {
    font-size: 2rem;
  }
  .profile-area {
    margin-top: 8px;
  }
}