/**
 * ExploreX User System Styles
 * Space Travel Experience Recommendation System
 * 
 * Comprehensive styling for user account system including:
 * - User navigation and authentication buttons
 * - Login, register, and password reset modals
 * - User profile and preferences interfaces
 * - Saved experiences management
 * - User dashboard and statistics
 */

/* =============================================================================
   USER NAVIGATION STYLES
   ============================================================================= */

.user-navigation {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
}

.user-nav-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-menu {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-menu.guest {
  display: flex;
}

.user-menu.authenticated {
  display: none;
  position: relative;
}

.auth-button {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
}

.auth-button.login-button {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.auth-button.login-button:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.auth-button.register-button {
  background: linear-gradient(135deg, #64b5f6, #42a5f5);
  color: #ffffff;
}

.auth-button.register-button:hover {
  background: linear-gradient(135deg, #42a5f5, #1e88e5);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(66, 165, 245, 0.3);
}.us
er-profile-summary {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.user-profile-summary:hover {
  background: rgba(255, 255, 255, 0.15);
}

.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, 0.3);
}

.user-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.user-name {
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
  line-height: 1;
}

.user-status {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1;
}

.user-menu-dropdown {
  position: relative;
}

.user-menu-toggle {
  background: none;
  border: none;
  color: #ffffff;
  font-size: 16px;
  cursor: pointer;
  padding: 8px;
  border-radius: 4px;
  transition: background-color 0.3s ease;
}

.user-menu-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
}

.user-dropdown-menu {
  position: absolute;
  top: 100%;
  right: 0;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  min-width: 200px;
  z-index: 1000;
  overflow: hidden;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  color: #333333;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: background-color 0.3s ease;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  cursor: pointer;
}

.dropdown-item:hover {
  background: #f8f9fa;
}

.item-icon {
  font-size: 16px;
  width: 20px;
  text-align: center;
}

.dropdown-divider {
  height: 1px;
  background: #e0e0e0;
  margin: 4px 0;
}

/* =============================================================================
   AUTHENTICATION MODAL STYLES
   ============================================================================= */

.auth-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  animation: fadeIn 0.3s ease;
}

.auth-modal {
  background: #ffffff;
  border-radius: 12px;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: slideUp 0.3s ease;
}

.auth-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 24px 0 24px;
}

.auth-modal-title {
  font-size: 24px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0;
}

.auth-modal-close {
  background: none;
  border: none;
  font-size: 24px;
  color: #666666;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.auth-modal-close:hover {
  background: #f0f0f0;
  color: #333333;
}

.auth-modal-body {
  padding: 24px;
}

.auth-modal-footer {
  padding: 0 24px 24px 24px;
  text-align: center;
}

.auth-footer-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 14px;
}

.auth-link {
  color: #64b5f6;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
}

.auth-link:hover {
  color: #42a5f5;
  text-decoration: underline;
}

.auth-separator {
  color: #cccccc;
}

.auth-text {
  color: #666666;
}

/* =============================================================================
   FORM STYLES
   ============================================================================= */

.auth-form {
  display: grid;
  gap: 20px;
}

.form-error {
  background: #fee2e2;
  border: 1px solid #fca5a5;
  color: #991b1b;
  padding: 12px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
}

.form-success {
  background: #d1fae5;
  border: 1px solid #a7f3d0;
  color: #065f46;
  padding: 12px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 14px;
  font-weight: 600;
  color: #333333;
}

.form-input,
.form-select {
  padding: 12px;
  border: 2px solid #e0e0e0;
  border-radius: 6px;
  font-size: 14px;
  transition: border-color 0.3s ease;
}

.form-input:focus,
.form-select:focus {
  outline: none;
  border-color: #64b5f6;
  box-shadow: 0 0 0 3px rgba(100, 181, 246, 0.1);
}

.form-help {
  font-size: 12px;
  color: #666666;
  margin-top: 4px;
}

.form-checkbox-group {
  flex-direction: row;
  align-items: center;
  gap: 8px;
}

.form-checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 14px;
  color: #333333;
}

.form-checkbox {
  width: 16px;
  height: 16px;
  accent-color: #64b5f6;
}

.checkbox-text {
  line-height: 1.4;
}

.checkbox-group,
.checkbox-grid {
  display: grid;
  gap: 8px;
}

.checkbox-grid {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.form-range {
  width: 100%;
  height: 6px;
  background: #e0e0e0;
  border-radius: 3px;
  outline: none;
  -webkit-appearance: none;
}

.form-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  background: #64b5f6;
  border-radius: 50%;
  cursor: pointer;
}

.form-range::-moz-range-thumb {
  width: 20px;
  height: 20px;
  background: #64b5f6;
  border-radius: 50%;
  cursor: pointer;
  border: none;
}

.range-value {
  text-align: center;
  font-size: 14px;
  font-weight: 600;
  color: #64b5f6;
  margin-top: 8px;
}

.auth-submit-button,
.form-submit-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  background: linear-gradient(135deg, #64b5f6, #42a5f5);
  color: #ffffff;
  border: none;
  border-radius: 6px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.auth-submit-button:hover,
.form-submit-button:hover {
  background: linear-gradient(135deg, #42a5f5, #1e88e5);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(66, 165, 245, 0.3);
}

.auth-submit-button:disabled,
.form-submit-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.form-description {
  color: #666666;
  font-size: 14px;
  line-height: 1.5;
  margin-bottom: 16px;
}

/* =============================================================================
   USER MODAL STYLES
   ============================================================================= */

.user-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  animation: fadeIn 0.3s ease;
}

.user-modal {
  background: #ffffff;
  border-radius: 12px;
  width: 100%;
  max-width: 800px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: slideUp 0.3s ease;
}

.user-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 24px 0 24px;
  border-bottom: 1px solid #e0e0e0;
  margin-bottom: 24px;
}

.user-modal-title {
  font-size: 24px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0;
}

.user-modal-close {
  background: none;
  border: none;
  font-size: 24px;
  color: #666666;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.user-modal-close:hover {
  background: #f0f0f0;
  color: #333333;
}

.user-modal-body {
  padding: 0 24px 24px 24px;
}

/* =============================================================================
   PROFILE CONTENT STYLES
   ============================================================================= */

.profile-content {
  display: grid;
  gap: 24px;
}

.profile-avatar-section {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}

.avatar-container {
  position: relative;
  display: inline-block;
}

.profile-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #e0e0e0;
}

.avatar-upload-button {
  position: absolute;
  bottom: 0;
  right: 0;
  background: #64b5f6;
  color: #ffffff;
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.avatar-upload-button:hover {
  background: #42a5f5;
  transform: scale(1.1);
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
  margin: 24px 0;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 8px;
}

.stat-item {
  text-align: center;
}

.stat-label {
  display: block;
  font-size: 12px;
  color: #666666;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.stat-value {
  display: block;
  font-size: 18px;
  font-weight: 700;
  color: #1a1a2e;
}

.form-actions {
  display: flex;
  justify-content: center;
  margin-top: 24px;
}

/* =============================================================================
   PREFERENCES CONTENT STYLES
   ============================================================================= */

.preferences-content {
  display: grid;
  gap: 32px;
}

.preferences-section {
  background: #f8f9fa;
  border-radius: 8px;
  padding: 24px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 600;
  color: #1a1a2e;
  margin: 0 0 20px 0;
  padding-bottom: 8px;
  border-bottom: 2px solid #64b5f6;
}

.title-icon {
  font-size: 20px;
}

.notification-list {
  display: grid;
  gap: 12px;
}

.notification-item {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 16px;
}

.notification-label {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  cursor: pointer;
}

.notification-content {
  flex: 1;
}

.notification-title {
  font-size: 14px;
  font-weight: 600;
  color: #333333;
  margin-bottom: 4px;
}

.notification-description {
  font-size: 13px;
  color: #666666;
  line-height: 1.4;
}

/* =============================================================================
   SAVED EXPERIENCES STYLES
   ============================================================================= */

.saved-experiences-content {
  display: grid;
  gap: 24px;
}

.saved-experiences-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 16px;
  border-bottom: 1px solid #e0e0e0;
}

.saved-count {
  font-size: 18px;
  font-weight: 600;
  color: #1a1a2e;
}

.saved-actions {
  display: flex;
  gap: 8px;
}

.action-button {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: #ffffff;
  border: 2px solid #64b5f6;
  border-radius: 6px;
  color: #64b5f6;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.action-button:hover {
  background: #64b5f6;
  color: #ffffff;
  transform: translateY(-1px);
}

.saved-experiences-list {
  display: grid;
  gap: 16px;
}

.saved-experience-card {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 20px;
  transition: all 0.3s ease;
}

.saved-experience-card:hover {
  border-color: #64b5f6;
  box-shadow: 0 4px 12px rgba(100, 181, 246, 0.1);
}

.saved-card-content {
  display: grid;
  gap: 12px;
}

.saved-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.saved-card-title {
  font-size: 16px;
  font-weight: 600;
  color: #1a1a2e;
  margin: 0;
}

.saved-card-actions {
  display: flex;
  gap: 4px;
}

.card-action-button {
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: background-color 0.3s ease;
}

.card-action-button:hover {
  background: #f0f0f0;
}

.saved-card-details {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
}

.saved-detail {
  font-size: 14px;
}

.detail-label {
  color: #666666;
  font-weight: 500;
}

.detail-value {
  color: #333333;
  font-weight: 600;
}

.saved-card-notes {
  background: #f8f9fa;
  border-radius: 6px;
  padding: 12px;
}

.notes-label {
  font-size: 12px;
  color: #666666;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.notes-content {
  font-size: 14px;
  color: #333333;
  line-height: 1.4;
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
}

.empty-icon {
  font-size: 64px;
  margin-bottom: 16px;
  opacity: 0.5;
}

.empty-title {
  font-size: 20px;
  font-weight: 600;
  color: #333333;
  margin: 0 0 8px 0;
}

.empty-description {
  font-size: 16px;
  color: #666666;
  line-height: 1.5;
  max-width: 400px;
  margin: 0 auto;
}

/* =============================================================================
   DASHBOARD STYLES
   ============================================================================= */

.dashboard-content {
  display: grid;
  gap: 32px;
}

.dashboard-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
}

.stat-card {
  background: linear-gradient(135deg, #f8f9fa, #e3f2fd);
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 20px;
  text-align: center;
  transition: all 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.stat-card .stat-icon {
  font-size: 32px;
  margin-bottom: 8px;
}

.stat-card .stat-number {
  font-size: 24px;
  font-weight: 700;
  color: #1a1a2e;
  margin-bottom: 4px;
}

.stat-card .stat-label {
  font-size: 12px;
  color: #666666;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.dashboard-sections {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.dashboard-section {
  background: #f8f9fa;
  border-radius: 8px;
  padding: 24px;
}

.dashboard-section .section-title {
  font-size: 16px;
  font-weight: 600;
  color: #1a1a2e;
  margin: 0 0 16px 0;
  padding-bottom: 8px;
  border-bottom: 1px solid #e0e0e0;
}

.activity-list,
.recommendations-list {
  display: grid;
  gap: 12px;
}

.activity-item,
.recommendation-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px;
  background: #ffffff;
  border-radius: 6px;
  border: 1px solid #e0e0e0;
}

.activity-icon,
.recommendation-icon {
  font-size: 16px;
  margin-top: 2px;
}

.activity-content,
.recommendation-content {
  flex: 1;
}

.activity-text,
.recommendation-text {
  font-size: 14px;
  color: #333333;
  margin-bottom: 4px;
}

.activity-time {
  font-size: 12px;
  color: #666666;
}

.recommendation-action {
  margin-top: 8px;
}

.recommendation-button {
  padding: 4px 12px;
  background: #64b5f6;
  color: #ffffff;
  border: none;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.recommendation-button:hover {
  background: #42a5f5;
}

.empty-activity {
  text-align: center;
  color: #666666;
  font-style: italic;
  padding: 20px;
}

/* =============================================================================
   RESPONSIVE DESIGN
   ============================================================================= */

@media (max-width: 768px) {
  .user-navigation {
    gap: 8px;
  }

  .user-nav-content {
    gap: 8px;
  }

  .auth-button {
    padding: 6px 12px;
    font-size: 13px;
  }

  .user-profile-summary {
    padding: 6px 8px;
  }

  .user-avatar {
    width: 28px;
    height: 28px;
  }

  .user-name {
    font-size: 13px;
  }

  .user-status {
    font-size: 11px;
  }

  .auth-modal,
  .user-modal {
    margin: 20px;
    max-width: calc(100vw - 40px);
  }

  .auth-modal-header,
  .user-modal-header {
    padding: 16px 16px 0 16px;
  }

  .auth-modal-body,
  .user-modal-body {
    padding: 16px;
  }

  .auth-modal-footer {
    padding: 0 16px 16px 16px;
  }

  .form-row {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .checkbox-grid {
    grid-template-columns: 1fr;
  }

  .profile-avatar {
    width: 80px;
    height: 80px;
  }

  .avatar-upload-button {
    width: 28px;
    height: 28px;
  }

  .profile-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 16px;
  }

  .dashboard-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .dashboard-sections {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .saved-experiences-header {
    flex-direction: column;
    gap: 12px;
    align-items: flex-start;
  }

  .saved-card-details {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .user-menu.guest {
    flex-direction: column;
    gap: 6px;
  }

  .auth-button {
    padding: 8px 12px;
    font-size: 12px;
  }

  .user-dropdown-menu {
    right: -20px;
    min-width: 180px;
  }

  .auth-modal-title,
  .user-modal-title {
    font-size: 20px;
  }

  .profile-stats {
    grid-template-columns: 1fr;
  }

  .dashboard-stats {
    grid-template-columns: 1fr;
  }

  .preferences-section {
    padding: 16px;
  }

  .saved-experience-card {
    padding: 16px;
  }
}

/* =============================================================================
   ANIMATIONS
   ============================================================================= */

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =============================================================================
   ACCESSIBILITY ENHANCEMENTS
   ============================================================================= */

.auth-button:focus,
.user-menu-toggle:focus,
.dropdown-item:focus,
.form-input:focus,
.form-select:focus,
.form-checkbox:focus,
.auth-submit-button:focus,
.form-submit-button:focus {
  outline: 3px solid #64b5f6;
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* =============================================================================
   PRINT STYLES
   ============================================================================= */

@media print {
  .user-navigation,
  .auth-modal-overlay,
  .user-modal-overlay {
    display: none !important;
  }
}