/* ===== Reset & Base ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

body {
  color: white;
  overflow-x: hidden;
  transition: background 0.3s, color 0.3s;
  background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 50%, #1e40af 100%);
  min-height: 100vh;
}

/* ===== Floating Particles Background ===== */
#particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
}

/* ===== Navbar ===== */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 60px;
  background: rgba(0, 0, 0, 0.6);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(10px);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.3rem;
  font-weight: bold;
  color: gold;
}

.nav-links {
  display: flex;
  gap: 25px;
  list-style: none;
}

.nav-links a {
  color: white;
  text-decoration: none;
  font-size: 1rem;
  transition: color 0.3s;
  font-weight: 500;
}

.nav-links a:hover,
.nav-links a.active {
  color: gold;
}

.login-btn {
  background: gold;
  border: none;
  padding: 8px 18px;
  border-radius: 20px;
  cursor: pointer;
  font-weight: bold;
  transition: transform 0.3s, background 0.3s;
  color: black;
}

.login-btn:hover {
  background: orange;
  transform: scale(1.05);
}

/* ===== Profile Section ===== */
.profile-section {
  padding: 120px 20px 80px;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.profile-container {
  max-width: 800px;
  width: 100%;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  padding: 40px;
  border-radius: 20px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.2);
  animation: slideUp 0.6s ease-out;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== Profile Header ===== */
.profile-container h2 {
  color: gold;
  font-size: 2.2rem;
  margin-bottom: 10px;
  text-align: center;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.profile-container p {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 30px;
  text-align: center;
  font-size: 1.1rem;
}

/* ===== Form Elements ===== */
.profile-container label {
  display: block;
  margin-bottom: 8px;
  color: gold;
  font-weight: 600;
  font-size: 1rem;
}

.profile-container input,
.profile-container textarea {
  width: 100%;
  padding: 14px 16px;
  margin-bottom: 20px;
  border-radius: 12px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.1);
  color: white;
  font-size: 1rem;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  font-family: "Poppins", sans-serif;
}

.profile-container input:focus,
.profile-container textarea:focus {
  outline: none;
  border-color: gold;
  background: rgba(255, 255, 255, 0.15);
  box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.2);
}

.profile-container input::placeholder,
.profile-container textarea::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.profile-container textarea {
  resize: vertical;
  min-height: 100px;
}

/* ===== Save Button ===== */
#saveProfile {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, gold 0%, orange 100%);
  border: none;
  border-radius: 12px;
  color: black;
  font-weight: bold;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 10px;
  margin-bottom: 30px;
}

#saveProfile:hover {
  background: linear-gradient(135deg, orange 0%, #ff6b35 100%);
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(255, 165, 0, 0.3);
}

#saveProfile:active {
  transform: translateY(0);
}

/* ===== Profile Preview ===== */
.profile-preview {
  margin-top: 30px;
  padding: 25px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 15px;
  border: 1px solid rgba(255, 215, 0, 0.3);
  backdrop-filter: blur(10px);
}

.profile-preview h3 {
  color: gold;
  font-size: 1.4rem;
  margin-bottom: 15px;
  text-align: center;
  text-shadow: 0 0 8px rgba(255, 215, 0, 0.5);
}

.profile-preview p {
  margin-bottom: 10px;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.6;
}

.profile-preview strong {
  color: gold;
  font-weight: 600;
}

/* ===== Success Message Animation ===== */
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(100px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideOut {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(100px);
  }
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
  .navbar {
    flex-direction: column;
    padding: 15px 20px;
    gap: 15px;
  }

  .nav-links {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }

  .profile-section {
    padding: 100px 15px 60px;
  }

  .profile-container {
    padding: 25px;
    margin: 0 10px;
  }

  .profile-container h2 {
    font-size: 1.8rem;
  }

  .profile-container input,
  .profile-container textarea {
    padding: 12px 14px;
    font-size: 0.95rem;
  }
}

@media (max-width: 480px) {
  .profile-container {
    padding: 20px;
  }

  .profile-container h2 {
    font-size: 1.6rem;
  }

  .profile-container input,
  .profile-container textarea {
    padding: 10px 12px;
    font-size: 0.9rem;
  }

  #saveProfile {
    padding: 14px;
    font-size: 1rem;
  }
}

/* ===== Light Mode Support ===== */
body.light {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 50%, #bae6fd 100%);
  color: #1e40af;
}

body.light .navbar {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(10px);
}

body.light .nav-links a {
  color: #1e40af;
}

body.light .nav-links a:hover,
body.light .nav-links a.active {
  color: orange;
}

body.light .profile-container {
  background: rgba(255, 255, 255, 0.9);
  color: #1e40af;
  border: 1px solid rgba(255, 165, 0, 0.3);
}

body.light .profile-container h2 {
  color: orange;
}

body.light .profile-container label {
  color: orange;
}

body.light .profile-container input,
body.light .profile-container textarea {
  background: rgba(255, 255, 255, 0.8);
  color: #1e40af;
  border: 2px solid rgba(255, 165, 0, 0.3);
}

body.light .profile-container input:focus,
body.light .profile-container textarea:focus {
  border-color: orange;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 0 0 3px rgba(255, 165, 0, 0.2);
}

body.light .profile-preview {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 165, 0, 0.4);
}

body.light .profile-preview h3 {
  color: orange;
}

body.light .profile-preview strong {
  color: orange;
}
