html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin: 0;
  padding: 0;
  font-family: sans-serif;
}

/* App Layout with Sidebar */
.app-layout {
  display: flex;
  min-height: 100vh;
  background: #f5f6fa;
}

/* Sidebar Styles */
.sidebar {
  width: 280px;
  background: #1e3c72;
  color: white;
  display: flex;
  flex-direction: column;
  position: fixed;
  height: 100vh;
  left: 0;
  top: 0;
  z-index: 1000;
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
}

.sidebar-brand {
  padding: 1.75rem 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  background: rgba(255, 255, 255, 0.03);
}

.sidebar-logo {
  width: 90px;
  height: 90px;
  object-fit: contain;
  margin-bottom: 1rem;
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.3));
  transition: transform 0.3s ease;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 0.75rem;
  backdrop-filter: blur(10px);
  border: 2px solid rgba(255, 255, 255, 0.15);
}

.sidebar-logo:hover {
  transform: scale(1.08);
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.4));
}

/* Logo glow effect for sidebar */
.sidebar-brand::before {
  content: '';
  position: absolute;
  top: 1.75rem;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 120px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
  border-radius: 50%;
  z-index: 1;
  opacity: 0.6;
}

.brand-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.25rem 0;
  color: white;
  line-height: 1.4;
}

.brand-subtitle {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
  font-weight: 400;
}

.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 0;
}

.nav-menu {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-item {
  margin: 0.25rem 0;
}

.nav-link {
  display: flex;
  align-items: center;
  padding: 0.875rem 1.25rem;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 400;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

.nav-link i {
  width: 20px;
  margin-right: 0.75rem;
  font-size: 1rem;
  text-align: center;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.08);
  color: white;
  border-left-color: rgba(255, 255, 255, 0.3);
}

.nav-link.active {
  background: rgba(255, 255, 255, 0.15);
  color: white;
  border-left-color: white;
  font-weight: 500;
}

/* Nav Item with Children */
.nav-item-has-children {
  position: relative;
}

.nav-link-parent {
  justify-content: space-between;
}

.nav-link-parent .nav-arrow {
  margin-left: auto;
  margin-right: 0;
  font-size: 0.75rem;
  transition: transform 0.3s ease;
  width: auto;
}

.nav-item-has-children.open .nav-arrow {
  transform: rotate(180deg);
}

/* Submenu Styles */
.nav-submenu {
  list-style: none;
  padding: 0;
  margin: 0;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  background: rgba(0, 0, 0, 0.2);
}

/* Only show submenu when direct parent has 'open' class */
.nav-item-has-children.open > .nav-submenu {
  max-height: 500px;
}

/* Nested submenus (3rd level) - only show when their direct parent is open */
.nav-submenu .nav-item-has-children.open > .nav-submenu {
  max-height: 500px;
}

/* IMPORTANT: Ensure nested submenus are hidden by default */
.nav-submenu .nav-submenu {
  max-height: 0 !important;
}

/* Only show nested submenu when its direct parent has 'open' class */
.nav-submenu .nav-item-has-children.open > .nav-submenu {
  max-height: 500px !important;
}

.nav-submenu-item {
  margin: 0;
}

.nav-submenu-link {
  display: flex;
  align-items: center;
  padding: 0.75rem 1.25rem 0.75rem 3.5rem;
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 400;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

.nav-submenu-link i {
  width: 16px;
  margin-right: 0.75rem;
  font-size: 0.875rem;
  text-align: center;
}

.nav-submenu-link:hover {
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border-left-color: rgba(255, 255, 255, 0.3);
  padding-left: 3.75rem;
}

.nav-submenu-link.active {
  background: rgba(255, 255, 255, 0.12);
  color: white;
  border-left-color: rgba(255, 255, 255, 0.5);
  font-weight: 500;
}

/* Nested submenu (submenu within submenu - 3rd level) */
.nav-submenu .nav-submenu {
  background: rgba(0, 0, 0, 0.3);
  margin-left: 0;
}

/* 3rd level menu items ONLY - more indentation to show as children of 2nd level */
/* This targets links inside nested submenus (3rd level), not 2nd level */
.nav-submenu .nav-submenu .nav-submenu-link {
  padding-left: 5.5rem !important;
  font-size: 0.8125rem;
}

.nav-submenu .nav-submenu .nav-submenu-link:hover {
  padding-left: 5.75rem !important;
  background: rgba(255, 255, 255, 0.12);
}

.nav-submenu .nav-submenu .nav-submenu-link.active {
  background: rgba(255, 255, 255, 0.15);
  border-left-color: rgba(255, 255, 255, 0.6);
}

/* Additional visual indicator for 3rd level - smaller icon and text */
.nav-submenu .nav-submenu .nav-submenu-link i {
  font-size: 0.75rem;
  width: 14px;
}

.nav-submenu .nav-submenu .nav-submenu-link span {
  font-size: 0.8125rem;
}

/* Ensure parent items don't look like links when they're just toggles */
.nav-link-parent[href="#"] {
  cursor: pointer;
}

.nav-link-parent[href="#"]:hover {
  background: rgba(255, 255, 255, 0.1);
}

.sidebar-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1rem 0;
}

.user-menu {
  padding: 0 1.25rem;
}

.user-info {
  display: flex;
  align-items: center;
  padding: 0.75rem 0;
  margin-bottom: 0.5rem;
}

.user-info i {
  font-size: 2rem;
  margin-right: 0.75rem;
  color: rgba(255, 255, 255, 0.9);
}

.user-details {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.user-name {
  font-size: 0.9375rem;
  font-weight: 500;
  color: white;
  line-height: 1.4;
}

.user-email {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.4;
}

.user-roles {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 500;
  line-height: 1.4;
  margin-top: 2px;
}

.user-actions {
  list-style: none;
  padding: 0;
  margin: 0;
}

.user-actions li {
  margin: 0.25rem 0;
}

.user-action-link {
  display: flex;
  align-items: center;
  padding: 0.625rem 0;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  font-size: 0.875rem;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
}

.user-action-link i {
  width: 18px;
  margin-right: 0.75rem;
  font-size: 0.875rem;
}

.user-action-link:hover {
  color: white;
}

.logout-btn {
  color: rgba(255, 255, 255, 0.85);
}

.logout-btn:hover {
  color: #ff6b6b;
}

/* Main Content Area */
.main-content {
  margin-left: 280px;
  flex: 1;
  min-height: 100vh;
  background: #f5f6fa;
  display: flex;
  flex-direction: column;
}

/* Top Header Bar */
.top-header {
  background: white;
  border-bottom: 1px solid #e0e0e0;
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.top-header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
}

.header-left {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.notification-bell {
  position: relative;
}

.notification-bell-btn {
  position: relative;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: #fdecea;
  color: #e53935;
  cursor: pointer;
  font-size: 1.15rem;
  transition: background .2s ease, color .2s ease, box-shadow .2s ease;
}

.notification-bell-btn:hover {
  background: #f8d7da;
  color: #c62828;
}

.notification-bell-btn.has-unread {
  background: #e53935;
  color: #fff;
  box-shadow: 0 0 0 4px rgba(229, 57, 53, 0.22);
  animation: bell-ring 1.8s ease-in-out infinite;
}

.notification-bell-btn.has-unread:hover {
  background: #d32f2f;
  color: #fff;
}

.notification-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: #b71c1c;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  border: 2px solid #fff;
  animation: badge-pulse 1.6s ease-in-out infinite;
}

@keyframes bell-ring {
  0%, 70%, 100% { transform: rotate(0deg); }
  74% { transform: rotate(14deg); }
  78% { transform: rotate(-12deg); }
  82% { transform: rotate(10deg); }
  86% { transform: rotate(-8deg); }
  90% { transform: rotate(4deg); }
  94% { transform: rotate(0deg); }
}

@keyframes badge-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}

.notification-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 360px;
  max-width: min(360px, 90vw);
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  z-index: 2000;
}

.notification-dropdown-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #eee;
  font-weight: 600;
  color: #1e3c72;
}

.notification-mark-all {
  border: none;
  background: none;
  color: #1976D2;
  font-size: 0.8rem;
  cursor: pointer;
}

.notification-dropdown-list {
  max-height: 380px;
  overflow-y: auto;
}

.notification-empty {
  padding: 1.25rem;
  text-align: center;
  color: #888;
  font-size: 0.9rem;
}

.notification-item {
  display: block;
  padding: 0.75rem 1rem;
  text-decoration: none;
  color: #333;
  border-bottom: 1px solid #f0f0f0;
}

.notification-item:hover {
  background: #f7f9fc;
}

.notification-item.unread {
  background: #eef4ff;
}

.notification-item-title {
  font-weight: 600;
  font-size: 0.85rem;
  color: #1e3c72;
}

.notification-item-msg {
  font-size: 0.8rem;
  color: #555;
  margin-top: 0.2rem;
}

.notification-item-time {
  font-size: 0.72rem;
  color: #888;
  margin-top: 0.2rem;
}

.notification-view-all {
  display: block;
  text-align: center;
  padding: 0.7rem 1rem;
  border-top: 1px solid #eee;
  color: #1976D2;
  font-weight: 600;
  font-size: 0.85rem;
  text-decoration: none;
}

.notification-view-all:hover {
  background: #f7f9fc;
}

/* Financial Year Dropdown Styles */
.financial-year-dropdown {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.financial-year-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: #1e3c72;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
}

.financial-year-label i {
  color: #667eea;
  font-size: 1rem;
}

.financial-year-select {
  min-width: 150px;
  max-width: 200px;
  font-size: 0.9rem;
  font-weight: 500;
  border: 2px solid #dee2e6;
  background: white;
  color: #1e3c72;
  padding: 0.5rem 2rem 0.5rem 0.75rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.financial-year-select:hover {
  background: #f8f9fa;
  border-color: #667eea;
}

.financial-year-select:focus {
  background: white;
  border-color: #667eea;
  outline: none;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.financial-year-select option {
  background: white;
  color: #1e3c72;
  padding: 0.5rem;
}

/* User Profile Dropdown */
.user-profile-dropdown {
  position: relative;
}

.user-profile-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 1rem;
  background: white;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  color: inherit;
  font-family: sans-serif;
}

.user-profile-btn:hover {
  background: #f8f9fa;
  border-color: #d0d0d0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.user-profile-btn:focus,
.user-profile-btn:active {
  outline: none;
  box-shadow: 0 0 0 3px rgba(30, 60, 114, 0.1);
  border-color: #1e3c72;
}

.profile-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #1e3c72;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.125rem;
  flex-shrink: 0;
}

.profile-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  min-width: 0;
}

.profile-name {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #1e3c72;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.profile-email {
  font-size: 0.8125rem;
  color: #6c757d;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.profile-roles {
  font-size: 0.75rem;
  color: #1976D2;
  font-weight: 500;
  line-height: 1.4;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.dropdown-arrow {
  font-size: 0.75rem;
  color: #6c757d;
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.user-profile-btn[aria-expanded="true"] .dropdown-arrow {
  transform: rotate(180deg);
}

.user-profile-btn[aria-expanded="true"] {
  background: #f8f9fa;
  border-color: #1e3c72;
}

/* Dropdown Menu */
.user-dropdown-menu {
  min-width: 220px;
  padding: 0.5rem 0;
  margin-top: 0.5rem;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  list-style: none;
  background: white;
  display: none;
  position: absolute;
  right: 0;
  top: 100%;
  z-index: 1000;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.user-dropdown-menu.show {
  display: block;
  opacity: 1;
  transform: translateY(0);
}

.user-dropdown-menu li {
  list-style: none;
  margin: 0;
  padding: 0;
}

.user-dropdown-menu .dropdown-item {
  padding: 0.75rem 1.25rem;
  font-size: 0.9375rem;
  color: #495057;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transition: all 0.2s ease;
  text-decoration: none;
  border: none;
  background: transparent;
  width: 100%;
  text-align: left;
  cursor: pointer;
  font-family: sans-serif;
}

.user-dropdown-menu .dropdown-item:hover {
  background: #f8f9fa;
  color: #1e3c72;
}

.user-dropdown-menu .dropdown-item i {
  width: 18px;
  text-align: center;
  font-size: 0.9375rem;
  color: #6c757d;
  transition: color 0.2s ease;
}

.user-dropdown-menu .dropdown-item:hover i {
  color: #1e3c72;
}

.user-dropdown-menu .dropdown-item span {
  flex: 1;
}

.logout-item {
  color: #dc3545 !important;
  margin: 0;
  padding: 0.75rem 1.25rem;
}

.logout-item:hover {
  background: #fee !important;
  color: #c33 !important;
}

.logout-item:hover i {
  color: #c33 !important;
}

.logout-item:focus {
  outline: none;
  box-shadow: none;
}

.user-dropdown-menu .dropdown-divider {
  margin: 0.5rem 0;
  border-color: #e0e0e0;
  border-top: 1px solid #e0e0e0;
  opacity: 1;
}

.main-content main {
  padding: 1rem;
  flex: 1;
}

/* App footer (post-login pages) - same background as left sidebar, sticky to bottom */
.app-footer {
  position: sticky;
  bottom: 0;
  z-index: 50;
  padding: 0.5rem 1rem;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.9);
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: #1e3c72;
  margin-top: auto;
}
.app-footer a {
  color: #fff;
  text-decoration: none;
  font-weight: 600;
}
.app-footer a:hover {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: underline;
}

.card {
  transition: transform 0.2s;
}

.card:hover {
  transform: translateY(-5px);
}

/* Responsive */
@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.3s ease;
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .main-content {
    margin-left: 0;
  }

  .sidebar-logo {
    width: 70px;
    height: 70px;
    margin-bottom: 0.75rem;
    padding: 0.5rem;
  }

  .sidebar-brand::before {
    width: 100px;
    height: 100px;
    top: 1.5rem;
  }

  .brand-title {
    font-size: 1rem;
  }

  .brand-subtitle {
    font-size: 0.7rem;
  }
}

/* ============================================
   Profile Page Styles
   ============================================ */

.profile-page-container {
    font-family: sans-serif;
}

/* Profile Header Card - Scoped to profile-page-container */
.profile-page-container .profile-header-card {
    position: relative;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    border-radius: 16px;
    padding: 3rem 2rem 4rem;
    margin-bottom: 2rem;
    box-shadow: 0 8px 24px rgba(30, 60, 114, 0.15);
    overflow: hidden;
}

.profile-page-container .profile-header-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(255, 255, 255, 0.08) 0%, transparent 50%);
    pointer-events: none;
}

.profile-page-container .profile-header-content {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.profile-page-container .profile-avatar-wrapper {
    position: relative;
    flex-shrink: 0;
}

.profile-page-container .profile-avatar-wrapper .profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: 4px solid rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.profile-page-container .profile-avatar-wrapper .profile-avatar:hover {
    transform: scale(1.05);
}

.profile-page-container .avatar-initials {
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
    letter-spacing: 2px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.profile-page-container .avatar-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
    background: #4caf50;
    border-radius: 50%;
    border: 3px solid white;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.profile-page-container .avatar-badge i {
    color: white;
    font-size: 0.875rem;
}

.profile-page-container .profile-header-info {
    flex: 1;
    min-width: 200px;
}

.profile-page-container .profile-header-info .profile-name {
    font-size: 2rem;
    font-weight: 700;
    color: white;
    margin: 0 0 0.5rem 0;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    letter-spacing: -0.5px;
}

.profile-page-container .profile-header-info .profile-email {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.profile-page-container .profile-header-info .profile-email i {
    font-size: 1rem;
    opacity: 0.8;
}

/* Profile Form Card - Scoped to profile-page-container */
.profile-page-container .profile-form-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    margin-bottom: 2rem;
}

.profile-page-container .card-header-section {
    background: linear-gradient(to right, #f8f9fa, #ffffff);
    padding: 2rem 2.5rem;
    border-bottom: 1px solid #e9ecef;
}

.profile-page-container .card-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1e3c72;
    margin: 0 0 0.5rem 0;
    display: flex;
    align-items: center;
    letter-spacing: -0.3px;
}

.profile-page-container .card-title i {
    color: #2a5298;
}

.profile-page-container .card-subtitle {
    font-size: 0.9375rem;
    color: #6c757d;
    margin: 0;
    font-weight: 400;
}

.profile-page-container .card-body-section {
    padding: 2.5rem;
}

/* Form Sections - Scoped to profile-page-container */
.profile-page-container .form-section {
    margin-bottom: 2.5rem;
}

.profile-page-container .form-section:last-of-type {
    margin-bottom: 0;
}

.profile-page-container .section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #f0f0f0;
}

.profile-page-container .section-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
    display: flex;
    align-items: center;
    letter-spacing: -0.2px;
}

.profile-page-container .section-title i {
    color: #1e3c72;
    margin-right: 0.5rem;
}

.profile-page-container .section-badge {
    background: #e3f2fd;
    color: #1976d2;
    padding: 0.375rem 0.875rem;
    border-radius: 20px;
    font-size: 0.8125rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.profile-page-container .section-description {
    font-size: 0.9375rem;
    color: #6c757d;
    margin: -0.75rem 0 1.5rem 0;
    line-height: 1.6;
}

/* Form Groups - Scoped to profile-page-container */
.profile-page-container .form-group-modern {
    margin-bottom: 1.5rem;
}

.profile-page-container .form-label-modern {
    display: block;
    font-size: 0.9375rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    letter-spacing: -0.1px;
}

.profile-page-container .form-label-modern i {
    color: #1e3c72;
    margin-right: 0.5rem;
    font-size: 0.875rem;
}

.profile-page-container .input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.profile-page-container .input-wrapper .input-icon {
    position: absolute;
    left: 1rem;
    color: #6c757d;
    pointer-events: none;
    z-index: 2;
    font-size: 0.9375rem;
}

.profile-page-container .form-control-modern {
    width: 100%;
    padding: 0.875rem 1rem 0.875rem 3rem;
    font-size: 0.9375rem;
    font-family: sans-serif;
    color: #2c3e50;
    background: #ffffff;
    border: 2px solid #e1e8ed;
    border-radius: 10px;
    transition: all 0.3s ease;
    outline: none;
}

.profile-page-container .form-control-modern::placeholder {
    color: #adb5bd;
    font-weight: 400;
}

.profile-page-container .form-control-modern:focus {
    border-color: #1e3c72;
    box-shadow: 0 0 0 4px rgba(30, 60, 114, 0.1);
    background: #ffffff;
}

.profile-page-container .form-control-modern:hover:not(:focus) {
    border-color: #cbd5e0;
}

.profile-page-container .password-input-wrapper {
    position: relative;
}

.profile-page-container .password-toggle {
    position: absolute;
    right: 1rem;
    background: none;
    border: none;
    color: #6c757d;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: color 0.2s ease;
    outline: none;
}

.profile-page-container .password-toggle:hover {
    color: #1e3c72;
}

.profile-page-container .password-input-wrapper .form-control-modern {
    padding-right: 3.5rem;
}

.profile-page-container .form-text {
    display: block;
    font-size: 0.8125rem;
    color: #6c757d;
    margin-top: 0.5rem;
    line-height: 1.5;
}

.profile-page-container .validation-error {
    display: block;
    font-size: 0.8125rem;
    color: #dc3545;
    margin-top: 0.5rem;
    font-weight: 500;
}

/* Alert Styles - Scoped to profile-page-container */
.profile-page-container .alert-custom {
    background: #fff5f5;
    border: 1px solid #feb2b2;
    border-left: 4px solid #dc3545;
    border-radius: 10px;
    padding: 1rem 1.25rem;
    margin-bottom: 2rem;
    color: #c53030;
    font-size: 0.9375rem;
    line-height: 1.6;
}

.profile-page-container .alert-custom i {
    color: #dc3545;
}

/* Action Buttons - Scoped to profile-page-container */
.profile-page-container .form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid #e9ecef;
}

.profile-page-container .btn-secondary-modern,
.profile-page-container .btn-primary-modern {
    padding: 0.875rem 2rem;
    font-size: 0.9375rem;
    font-weight: 600;
    font-family: sans-serif;
    border-radius: 10px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    letter-spacing: -0.1px;
    outline: none;
}

.profile-page-container .btn-secondary-modern {
    background: #f8f9fa;
    color: #495057;
    border: 2px solid #e9ecef;
}

.profile-page-container .btn-secondary-modern:hover {
    background: #e9ecef;
    border-color: #dee2e6;
    color: #212529;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.profile-page-container .btn-primary-modern {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(30, 60, 114, 0.3);
}

.profile-page-container .btn-primary-modern:hover {
    background: linear-gradient(135deg, #2a5298 0%, #1e3c72 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(30, 60, 114, 0.4);
}

.profile-page-container .btn-primary-modern:active,
.profile-page-container .btn-secondary-modern:active {
    transform: translateY(0);
}

.profile-page-container .btn-secondary-modern i,
.profile-page-container .btn-primary-modern i {
    font-size: 0.875rem;
}

/* Password Section Special Styling - Scoped to profile-page-container */
.profile-page-container .password-section {
    background: #f8f9fa;
    padding: 2rem;
    border-radius: 12px;
    margin-top: 1rem;
}

.profile-page-container .password-section .section-header {
    border-bottom-color: #e1e8ed;
}

/* Profile Page Responsive Design */
@media (max-width: 768px) {
    .profile-page-container {
        padding: 1rem;
    }

    .profile-page-container .profile-header-card {
        padding: 2rem 1.5rem 3rem;
        margin-bottom: 1.5rem;
    }

    .profile-page-container .profile-header-content {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }

    .profile-page-container .profile-avatar {
        width: 100px;
        height: 100px;
    }

    .profile-page-container .avatar-initials {
        font-size: 2rem;
    }

    .profile-page-container .profile-name {
        font-size: 1.5rem;
    }

    .profile-page-container .profile-email {
        font-size: 1rem;
        justify-content: center;
    }

    .profile-page-container .card-header-section {
        padding: 1.5rem;
    }

    .profile-page-container .card-title {
        font-size: 1.5rem;
    }

    .profile-page-container .card-body-section {
        padding: 1.5rem;
    }

    .profile-page-container .form-actions {
        flex-direction: column-reverse;
    }

    .profile-page-container .btn-secondary-modern,
    .profile-page-container .btn-primary-modern {
        width: 100%;
    }

    .profile-page-container .password-section {
        padding: 1.5rem;
    }
}

@media (max-width: 576px) {
    .profile-page-container .profile-header-card {
        border-radius: 12px;
        padding: 1.5rem 1rem 2.5rem;
    }

    .profile-page-container .profile-form-card {
        border-radius: 12px;
    }

    .profile-page-container .card-header-section,
    .profile-page-container .card-body-section {
        padding: 1.25rem;
    }

    .profile-page-container .section-title {
        font-size: 1.125rem;
    }
}

