/* UTILITY CLASSES - Replaces all inline styles from PHP files */
.error-msg, .error-inline {
  color: red;
}

.error-msg-full {
  background: #f8d7da;
  color: #721c24;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid #f5c6cb;
  margin-bottom: 20px;
}

.success-msg, .profile-msg {
  background: #d4edda;
  color: #155724;
  padding: 15px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.profile-error-msg {
  background: #f8d7da;
  color: #721c24;
  padding: 15px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.profile-success-msg {
  background: #d4edda;
  color: #155724;
  padding: 15px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.modal-overlay {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
}

.modal-content-box {
  background: white;
  margin: 10% auto;
  padding: 30px;
  border-radius: 12px;
  max-width: 400px;
  position: relative;
}

.modal-close-btn {
  position: absolute;
  right: 15px;
  top: 15px;
  font-size: 24px;
  cursor: pointer;
}

.modal-close-large {
  position: absolute;
  right: 20px;
  top: 15px;
  font-size: 28px;
  cursor: pointer;
}

.password-toggle-label {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  font-size: 14px;
  color: #666;
}

.password-input-wide {
  padding-right: 120px;
}

.photo-preview-img {
  max-width: 150px;
  max-height: 150px;
  border-radius: 8px;
}

.star-icon {
  color: #ffc107;
  cursor: pointer;
  font-size: 18px;
  margin-left: 8px;
}

.star-icon-large {
  color: #ffc107;
  cursor: pointer;
  font-size: 20px;
}

.small-text-tip {
  margin-top:6px;
  color:#555;
  font-size:13px;
}

.mt-20 {
  margin-top: 20px;
}

.mt-80 {
  margin-top: 80px;
}

.mt-100 {
  margin-top: 100px;
}

.btn-copy {
  margin-left: 8px;
  padding: 6px 10px;
  background: #4169e1;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 700;
  font-size: 12px;
}

.learn-more-large {
  font-size: 18px;
  padding: 15px 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.btn-green {
  background: #28a745 !important;
}

.btn-cyan {
  background: #17a2b8 !important;
}

.edit-link-inline {
  color: #4169e1;
  font-weight: 700;
  margin-right: 10px;
}

.cancel-link-inline {
  margin-left: 15px;
  color: #666;
}

/* Menu-style logout link - matches .dropdown-menu a */
.logout-link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white !important;
  padding: 12px 20px !important;
  text-decoration: none !important;
  font-weight: 600 !important;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  white-space: nowrap;
  transition: background 0.3s, color 0.3s !important;
  background: transparent;
  border-radius: 6px;
}

.logout-link:hover {
  background: rgba(255,255,255,0.15) !important;
  color: #cea66a !important;
}

/* Menu style for profile/logout - NEW CLASSES */
.profile-menu-link,
.logout-menu-link {
  display: inline-block !important;
  color: white !important;
  font-weight: 600 !important;
  font-size: 16px !important;
  padding: 8px 12px !important;
  border-radius: 6px !important;
  white-space: nowrap !important;
  transition: background-color 0.3s ease !important;
  text-decoration: none !important;
}

.profile-menu-link:hover,
.profile-menu-link:active,
.logout-menu-link:hover,
.logout-menu-link:active {
  color: #0a4a60 !important;
  background-color: #cea66a !important;
}

/* Webkit override */
a:-webkit-any-link.profile-menu-link,
a:-webkit-any-link.logout-menu-link {
  color: white !important;
  text-decoration: none !important;
}

/* Override Webkit defaults for profile/logout links */
a:-webkit-any-link.profile-link,
a:-webkit-any-link.logout-link,
a:-webkit-any-link.dropdown-link {
  color: inherit !important;
  cursor: pointer !important;
  text-decoration: none !important;
}

.logout-link i {
  font-size: 16px;
}

.user-dropdown {
  position: relative;
  display: inline-block;
}

.user-greeting {
  color: white;
  font-weight: 700;
  font-size: 14px;
  white-space: nowrap;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.15);
  transition: background 0.3s, color 0.3s;
}

.user-greeting:hover {
  background: rgba(206, 166, 106, 0.2);
  color: #0a4a60;
}

.user-greeting i {
  font-size: 16px;
}

.dropdown-menu {
  position: absolute !important;
  right: 0 !important;
  top: calc(100% + 8px) !important;
  background: #0a4a60 !important;
  border-radius: 10px !important;
  min-width: 150px !important;
  box-shadow: 0 12px 24px rgba(0,0,0,0.25) !important;
  padding: 8px 0 !important;
  opacity: 0 !important;
  visibility: hidden !important;
  transform: translateY(-10px) !important;
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease !important;
  z-index: 1001 !important;
  display: none !important;
}

.dropdown-menu.show {
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
  transform: translateY(0) !important;
}

.dropdown-menu a,
.dropdown-menu .dropdown-link {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  color: white !important;
  padding: 12px 20px !important;
  text-decoration: none !important;
  font-weight: 600 !important;
  border-bottom: 1px solid rgba(255,255,255,0.1) !important;
  white-space: nowrap !important;
  transition: background 0.3s, color 0.3s !important;
}

.dropdown-menu a:hover,
.dropdown-menu .dropdown-link:hover {
  background: rgba(255,255,255,0.15) !important;
  color: #cea66a !important;
}

.dropdown-menu a:last-child,
.dropdown-menu .dropdown-link:last-child {
  border-bottom: none !important;
}

.dropdown-menu i {
  font-size: 16px !important;
  width: 20px !important;
}

.dropdown-menu .dropdown-link i {
  font-size: 16px;
  width: 20px;
}

.tab-btn {
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 700;
  color: white;
  text-decoration: none;
  display: inline-block;
}

.tab-btn-blue {
  background: #17a2b8;
}

.tab-btn-purple {
  background: #4169e1;
}

.tab-btn-red {
  background: #dc3545;
}

.form-field {
  padding: 12px;
  border: 2px solid #ddd;
  border-radius: 8px;
  box-sizing: border-box;
  width: 100%;
}

.form-field:focus {
  border-color: #4169e1;
  outline: none;
  box-shadow: 0 0 0 3px rgba(65,105,225,0.1);
}

.nav-links-inline {
  margin-bottom: 15px;
}

.hr-divider {
  margin: 40px 0;
  border: none;
  height: 2px;
  background: #eee;
}

.back-link {
  display: inline-block;
  padding: 12px 24px;
  background: #4169e1;
  color: white;
  text-decoration: none;
  border-radius: 8px;
}

.form-required {
  color: red;
}

/* Navigation consistency - nav-link class */
.navbar {
  list-style: none;
  display: flex;
  gap: 20px;
}

.nav-link {
  text-decoration: none;
  color: #333;
  font-weight: 500;
  transition: color 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.nav-link:hover {
  color: #0077cc;
}

/* Override for existing navbar theme compatibility */
.nav-menu .nav-link,
.sub-menu .nav-link {
  color: white;
  font-weight: 600;
  padding: 12px 18px;
  border-radius: 6px;
  display: inline-block;
  white-space: nowrap;
}

.nav-menu .nav-link.active,
.nav-menu .nav-link:hover,
.sub-menu .nav-link:hover {
  background-color: #cea66a;
  color: #0a4a60;
}

/* Error message styling */
.error-message {
  color: red;
}

/* Nav links margin */
.nav-links {
  margin-bottom: 15px;
}

/* Photo preview styling */
.photo-preview {
  max-width: 150px;
  max-height: 150px;
  border-radius: 8px;
}

/* Edit link styling */
.edit-link {
  color: #4169e1;
  font-weight: 700;
  margin-right: 10px;
}

/* Cancel link styling */
.cancel-link {
  margin-left: 15px;
  color: #666;
}

/* Job date styling */
.job-date {
  margin-top: 6px;
  color: #555;
  font-size: 13px;
}

/* Forgot form container */
.forgot-form {
  max-width: 400px;
  margin: 100px auto;
  padding: 20px;
}

/* Success message styling */
.success-message {
  padding: 15px;
  background: #d4edda;
  color: #155724;
  border-radius: 8px;
  margin-bottom: 20px;
}

/* Knowledge page styling */
.knowledge-title {
  margin: 0;
}

.knowledge-description {
  margin: 5px 0 0 0;
  color: #666;
}

.star-icon {
  color: #ffc107;
  cursor: pointer;
  font-size: 20px;
}

/* Subject page styling */
.content {
  margin-top: 80px;
}

/* Profile page styling */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

.inline-form {
  display: inline;
}

.settings-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  max-width: 400px;
}

.close {
  position: absolute;
  right: 20px;
  top: 15px;
  font-size: 28px;
  cursor: pointer;
}

.cv-preview-content {
  text-align: center;
}

.cv-preview-margin {
  margin-top: 20px;
}

/* Login page styling */
.password-container {
  position: relative;
}

.show-password-checkbox {
  margin-right: 5px;
}

.forgot-link {
  color: #4169e1;
  text-decoration: none;
}

/* Register page styling */
.register-content {
  margin-top: 100px;
}

/* Export PDF button */
.export-pdf-btn {
  background: #dc3545;
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 6px;
  margin-left: 20px;
}

.cv-preview-modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
}

.cv-preview-content {
  background: white;
  margin: 5% auto;
  padding: 20px;
  border-radius: 12px;
  width: 90%;
  max-width: 900px;
  max-height: 80vh;
  overflow-y: auto;
  position: relative;
}

.template-btn {
  background: #4169e1;
  color: white;
  border: none;
  padding: 10px;
  border-radius: 50%;
  margin: 0 10px;
  cursor: pointer;
  font-size: 18px;
}

/* News page styling */
.news-container {
  margin-top: 20px;
}

.news-title {
  margin-top: 0;
}
