/* ==============================================================
   PROgress / FIET - Modern Personnel Operations & Progress Design
   Matches exact UI/UX design specifications
   ============================================================== */

@import url('https://fonts.googleapis.com/css2?family=Prompt:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&family=Sarabun:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  --primary: #e11d48;
  --primary-hover: #be123c;
  --primary-subtle: #ffe4e6;

  /* Crimson / Ruby Brand Colors (as in screenshot) */
  --primary-red: #e11d48;
  --primary-red-hover: #be123c;
  --primary-red-light: #ffe4e6;
  --primary-red-dark: #9f1239;

  /* Dark Navy Sidebar */
  --sidebar-bg: #141724;
  --sidebar-hover: #1e2337;
  --sidebar-text: #94a3b8;
  --sidebar-text-hover: #ffffff;
  --sidebar-active-pill: #e11d48;

  /* App Backgrounds */
  --bg-body: #f4f6fb;
  --bg-card: #ffffff;
  --bg-subtle: #f8fafc;

  /* Text Colors */
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-subtle: #94a3b8;

  /* Borders */
  --border-color: #e2e8f0;
  --border-light: #f1f5f9;

  /* Status Colors from design */
  --status-pending-bg: #fffbeb;
  --status-pending-text: #d97706;
  --status-pending-border: #fde68a;

  --status-done-bg: #ecfdf5;
  --status-done-text: #059669;
  --status-done-border: #a7f3d0;

  --status-wait-bg: #f5f3ff;
  --status-wait-text: #7c3aed;
  --status-wait-border: #ddd6fe;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.04);
  --shadow-card: 0 4px 12px -2px rgba(15, 23, 42, 0.05), 0 2px 6px -1px rgba(15, 23, 42, 0.02);

  --font-heading: 'Prompt', 'Plus Jakarta Sans', sans-serif;
  --font-body: 'Sarabun', 'Plus Jakarta Sans', sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-body);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6, .font-heading {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.3;
}

/* ==============================================================
   Layout: Sidebar + Main Area
   ============================================================== */
.app-layout {
  display: flex;
  width: 100%;
  min-height: 100vh;
}

/* Sidebar */
.app-sidebar {
  width: 250px;
  background-color: var(--sidebar-bg);
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  color: #fff;
  z-index: 100;
  transition: transform 0.25s ease;
}

.sidebar-brand {
  padding: 1.5rem 1.25rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.brand-logo-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #e11d48 0%, #be123c 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.15rem;
  box-shadow: 0 4px 10px rgba(225, 29, 72, 0.4);
}

.brand-title-wrap {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.brand-desc {
  font-size: 0.68rem;
  color: #94a3b8;
  line-height: 1.25;
  margin-top: 3px;
}

.sidebar-menu {
  list-style: none;
  padding: 1.25rem 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1;
}

.sidebar-item a {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.7rem 1rem;
  border-radius: var(--radius-md);
  color: var(--sidebar-text);
  text-decoration: none;
  font-family: var(--font-heading);
  font-size: 0.925rem;
  font-weight: 500;
  transition: all 0.15s ease;
}

.sidebar-item a:hover {
  background-color: var(--sidebar-hover);
  color: var(--sidebar-text-hover);
}

.sidebar-item.active a {
  background-color: var(--sidebar-active-pill);
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(225, 29, 72, 0.35);
}

.sidebar-item a i {
  font-size: 1rem;
  width: 20px;
  text-align: center;
}

/* Main Content Area */
.app-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background-color: var(--bg-body);
}

/* Top Navbar */
.app-topbar {
  background-color: #ffffff;
  border-bottom: 1px solid var(--border-color);
  padding: 0.85rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 90;
}

.topbar-search {
  position: relative;
  width: 380px;
  max-width: 100%;
}

.topbar-search input {
  width: 100%;
  padding: 0.55rem 1rem 0.55rem 2.5rem;
  font-family: var(--font-body);
  font-size: 0.875rem;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-full);
  background-color: #f8fafc;
  color: var(--text-main);
  transition: all 0.15s ease;
}

.topbar-search input:focus {
  outline: none;
  background-color: #ffffff;
  border-color: var(--primary-red);
  box-shadow: 0 0 0 3px rgba(225, 29, 72, 0.12);
}

.topbar-search .search-icon {
  position: absolute;
  left: 0.95rem;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 0.85rem;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.btn-icon-notify {
  position: relative;
  background: transparent;
  border: none;
  color: #64748b;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 0.35rem;
  border-radius: 50%;
  transition: color 0.15s;
}

.btn-icon-notify:hover {
  color: var(--primary-red);
}

.notify-badge {
  position: absolute;
  top: 0;
  right: 0;
  width: 17px;
  height: 17px;
  background-color: var(--primary-red);
  color: #fff;
  border-radius: 50%;
  font-size: 0.65rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 1px rgba(225, 29, 72, 0.4);
  animation: pulseNotifyBadge 2s infinite;
}

@keyframes pulseNotifyBadge {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

/* Notification Dropdown Panel */
.notify-dropdown-wrapper {
  position: relative;
}

.notify-dropdown-panel {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: -10px;
  width: 350px;
  max-width: 90vw;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.15), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
  z-index: 1000;
  overflow: hidden;
  animation: notifyDropdownFade 0.18s ease-out;
}

.notify-dropdown-panel.show {
  display: block;
}

@keyframes notifyDropdownFade {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.notify-dropdown-header {
  padding: 10px 14px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.notify-count-pill {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 9999px;
  background: #f1f5f9;
  color: #475569;
}

.notify-count-pill.notify-count-urgent {
  background: #fee2e2;
  color: #dc2626;
  border: 1px solid #fecaca;
}

.notify-dropdown-body {
  max-height: 360px;
  overflow-y: auto;
}

.notify-item-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid #f1f5f9;
  text-decoration: none;
  transition: background 0.15s ease;
}

.notify-item-row:hover {
  background: #f8fafc;
}

.notify-item-row.item-overdue {
  background: #fff5f5;
}

.notify-item-row.item-overdue:hover {
  background: #fee2e2;
}

.notify-item-row.item-warning {
  background: #fffbeb;
}

.notify-item-row.item-warning:hover {
  background: #fef3c7;
}

.notify-item-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.88rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.notify-item-details {
  flex: 1;
  min-width: 0;
}

.notify-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 2px;
}

.notify-item-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: #1e293b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notify-target-badge {
  font-size: 0.7rem;
  font-weight: 700;
  color: #2563eb;
  background: #eff6ff;
  padding: 1px 6px;
  border-radius: 4px;
  flex-shrink: 0;
}

.notify-item-desc {
  font-size: 0.74rem;
  color: #64748b;
  line-height: 1.3;
}

.notify-time-status {
  font-weight: 500;
  color: #334155;
}

.item-overdue .notify-time-status {
  color: #dc2626;
  font-weight: 600;
}

.item-warning .notify-time-status {
  color: #d97706;
  font-weight: 600;
}

.notify-deadline {
  font-size: 0.7rem;
  color: #94a3b8;
  display: block;
}

.notify-empty-state {
  text-align: center;
  padding: 2rem 1rem;
  color: #94a3b8;
  font-size: 0.82rem;
}

.notify-empty-state i {
  font-size: 1.8rem;
  margin-bottom: 0.4rem;
  display: block;
  color: #cbd5e1;
}

.notify-dropdown-footer {
  padding: 9px 14px;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  text-align: center;
}

.notify-footer-link {
  color: var(--primary-red);
  font-size: 0.79rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.notify-footer-link:hover {
  text-decoration: underline;
}


.topbar-user {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  padding: 0.25rem 0.5rem;
  border-radius: var(--radius-md);
  transition: background-color 0.15s;
}

.topbar-user:hover {
  background-color: #f1f5f9;
}

.user-avatar-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  background: #fecdd3;
  border: 1.5px solid #fff;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.user-info-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.user-name {
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-main);
}

.user-role {
  font-size: 0.725rem;
  color: var(--text-muted);
}

.btn-mobile-sidebar {
  display: none;
  background: transparent;
  border: 1px solid var(--border-color);
  padding: 0.45rem 0.75rem;
  border-radius: var(--radius-sm);
  color: var(--text-main);
  cursor: pointer;
}

/* Page Container */
.page-container {
  padding: 1.75rem 2rem;
  flex: 1;
}

/* ==============================================================
   Banner / Hero Card (as in screenshot)
   ============================================================== */
.hero-banner-card {
  background: #ffffff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-card);
  padding: 1.75rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  gap: 1.5rem;
  position: relative;
  overflow: hidden;
}

.hero-banner-left {
  max-width: 580px;
}

.hero-greeting {
  font-size: 1.5rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 0.4rem;
}

.hero-desc {
  font-size: 0.95rem;
  color: #475569;
  line-height: 1.5;
  margin-bottom: 1.25rem;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.hero-banner-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-illustration {
  height: 130px;
  width: auto;
  object-fit: contain;
}

.hero-banner-right {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 140px;
}

/* Circular Radial Progress */
.radial-progress-wrap {
  position: relative;
  width: 90px;
  height: 90px;
}

.radial-progress-wrap svg {
  transform: rotate(-90deg);
  width: 90px;
  height: 90px;
}

.radial-progress-wrap circle {
  fill: none;
  stroke-width: 8;
  stroke-linecap: round;
}

.radial-bg {
  stroke: #ffe4e6;
}

.radial-bar {
  stroke: var(--primary-red);
  transition: stroke-dashoffset 0.8s ease;
}

.radial-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: #0f172a;
}

.radial-label {
  font-size: 0.775rem;
  color: #64748b;
  text-align: center;
  margin-top: 0.5rem;
  line-height: 1.25;
}

/* ==============================================================
   4 Stat Cards (as in screenshot)
   ============================================================== */
.stats-row-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.stat-box {
  background: #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-box:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
}

.stat-box-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

.stat-box-icon.blue {
  background: #eff6ff;
  color: #2563eb;
}

.stat-box-icon.orange {
  background: #fff7ed;
  color: #ea580c;
}

.stat-box-icon.green {
  background: #ecfdf5;
  color: #059669;
}

.stat-box-icon.purple {
  background: #f5f3ff;
  color: #7c3aed;
}

.stat-box-content {
  display: flex;
  flex-direction: column;
}

.stat-box-title {
  font-size: 0.85rem;
  color: #64748b;
  font-weight: 500;
}

.stat-box-num {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.1;
}

.stat-box-unit {
  font-size: 0.75rem;
  color: #94a3b8;
}

/* ==============================================================
   Middle Section: 3-column Widget Grid
   ============================================================== */
.dashboard-middle-grid {
  display: grid;
  grid-template-columns: 1.3fr 1.1fr 0.8fr;
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.widget-card {
  background: #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow-sm);
}

.widget-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.widget-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: #0f172a;
}

.widget-link {
  font-size: 0.825rem;
  color: var(--primary-red);
  text-decoration: none;
  font-weight: 500;
}

.widget-link:hover {
  text-decoration: underline;
}

/* Milestone Stepper */
.milestone-stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  margin: 1.5rem 0 1.25rem;
}

.milestone-stepper::before {
  content: '';
  position: absolute;
  top: 14px;
  left: 20px;
  right: 20px;
  height: 2px;
  background: #e2e8f0;
  z-index: 1;
}

.step-node {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.step-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: #64748b;
  margin-bottom: 0.4rem;
}

.step-node.completed .step-circle {
  background: #10b981;
  border-color: #10b981;
  color: #fff;
}

.step-label {
  font-size: 0.775rem;
  font-weight: 600;
  color: #334155;
}

.step-subtext {
  font-size: 0.7rem;
  color: #94a3b8;
}

/* Horizontal Progress Bars */
.progress-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
}

.progress-item-head {
  display: flex;
  justify-content: space-between;
  font-size: 0.825rem;
  color: #475569;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.progress-track {
  height: 7px;
  background: #f1f5f9;
  border-radius: var(--radius-full);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: var(--radius-full);
}

.fill-red { background: #e11d48; }
.fill-pink { background: #db2777; }
.fill-blue { background: #3b82f6; }
.fill-purple { background: #8b5cf6; }
.fill-green { background: #10b981; }
.fill-amber { background: #f59e0b; }

/* Recent Tasks List */
.task-mini-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.task-mini-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.65rem 0.5rem;
  border-bottom: 1px solid #f1f5f9;
  gap: 0.75rem;
}

.task-mini-item:last-child {
  border-bottom: none;
}

.task-mini-title {
  font-size: 0.875rem;
  font-weight: 500;
  color: #1e293b;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.task-mini-title i {
  color: #ef4444;
  font-size: 0.8rem;
}

.task-mini-date {
  font-size: 0.775rem;
  color: #94a3b8;
  white-space: nowrap;
}

/* Mini Calendar */
.mini-calendar {
  width: 100%;
}

.calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  text-align: center;
  gap: 4px;
}

.cal-day-name {
  font-size: 0.725rem;
  color: #94a3b8;
  font-weight: 600;
  padding: 4px 0;
}

.cal-date {
  font-size: 0.775rem;
  color: #334155;
  padding: 6px 0;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 28px;
  width: 28px;
  margin: 0 auto;
}

.cal-date.active {
  background-color: var(--primary-red);
  color: #ffffff;
  font-weight: 700;
}

.cal-date.muted {
  color: #cbd5e1;
}

/* ==============================================================
   Status Pills (Badge)
   ============================================================== */
.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.775rem;
  font-weight: 500;
  white-space: nowrap;
}

.pill-pending {
  background: var(--status-pending-bg);
  color: var(--status-pending-text);
  border: 1px solid var(--status-pending-border);
}

.pill-done {
  background: var(--status-done-bg);
  color: var(--status-done-text);
  border: 1px solid var(--status-done-border);
}

.pill-wait {
  background: var(--status-wait-bg);
  color: var(--status-wait-text);
  border: 1px solid var(--status-wait-border);
}

/* ==============================================================
   Buttons & Form Controls
   ============================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.55rem 1.15rem;
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.btn-primary-red {
  background-color: var(--primary-red);
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(225, 29, 72, 0.25);
}

.btn-primary-red:hover {
  background-color: var(--primary-red-hover);
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-outline {
  background-color: #ffffff;
  border: 1px solid #cbd5e1;
  color: #334155;
}

.btn-outline:hover {
  background-color: #f8fafc;
  border-color: #94a3b8;
}

.btn-outline-pill {
  border-radius: var(--radius-full);
  padding: 0.35rem 0.85rem;
  font-size: 0.8rem;
  color: #e11d48;
  border: 1px solid #fecdd3;
  background: #fff;
}

.btn-outline-pill:hover {
  background: #ffe4e6;
  border-color: #fda4af;
}

.btn-icon-red {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: #fee2e2;
  color: #ef4444;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
}

.btn-icon-red:hover {
  background: #ef4444;
  color: #fff;
}

/* Filter Card */
.filter-bar-card {
  background: #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  padding: 1rem 1.5rem;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.filter-select {
  padding: 0.5rem 1rem;
  font-family: var(--font-body);
  font-size: 0.875rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  background-color: #fff;
  color: #334155;
  cursor: pointer;
}

/* Tabs */
.nav-tab-list {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
  overflow-x: auto;
}

.nav-tab-btn {
  padding: 0.5rem 1.15rem;
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 500;
  color: #64748b;
  text-decoration: none;
  border-radius: var(--radius-full);
  transition: all 0.15s ease;
  white-space: nowrap;
}

.nav-tab-btn.active {
  background-color: #fee2e2;
  color: var(--primary-red);
  font-weight: 600;
}

/* Clean Data Table */
.data-table-card {
  background: #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 1.5rem;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.data-table thead th {
  background-color: #f8fafc;
  color: #475569;
  font-family: var(--font-heading);
  font-weight: 600;
  padding: 0.85rem 1.25rem;
  border-bottom: 1px solid var(--border-color);
}

.data-table tbody tr {
  border-bottom: 1px solid #f1f5f9;
  transition: background-color 0.15s ease;
}

.data-table tbody tr:hover {
  background-color: #f8fafc;
}

.data-table tbody td {
  padding: 0.85rem 1.25rem;
  vertical-align: middle;
}

/* ==============================================================
   Responsive Breakpoints
   ============================================================== */
@media (max-width: 1200px) {
  .dashboard-middle-grid {
    grid-template-columns: 1fr 1fr;
  }
  .stats-row-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 992px) {
  .app-sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    transform: translateX(-100%);
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
  }
  .app-sidebar.show {
    transform: translateX(0);
  }
  .btn-mobile-sidebar {
    display: block;
  }
  .hero-banner-card {
    flex-direction: column;
    align-items: flex-start;
  }
  .hero-banner-right {
    align-self: center;
  }
  .dashboard-middle-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .page-container {
    padding: 1rem;
  }
  .stats-row-grid {
    grid-template-columns: 1fr;
  }
}

/* ==============================================================
   Landing / Portal Home Page (Index) Styles
   Matches latest screenshot
   ============================================================== */
.landing-navbar {
  background: #ffffff;
  border-bottom: 1px solid #f1f5f9;
  padding: 0.75rem 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
  gap: 1.5rem;
}

.landing-brand {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.landing-brand-img {
  height: 42px;
  max-width: 100%;
  width: auto;
  object-fit: contain;
  display: block;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.landing-brand-img:hover {
  opacity: 0.95;
  transform: translateY(-1px);
}

.landing-brand-logo {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: linear-gradient(135deg, #e11d48 0%, #be123c 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.35rem;
  box-shadow: 0 4px 12px rgba(225, 29, 72, 0.35);
}

.landing-brand-text h2 {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
  margin: 0;
  line-height: 1;
}

.landing-brand-text p {
  font-size: 0.775rem;
  color: #64748b;
  margin: 3px 0 0;
}

.landing-nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
}

.landing-nav-links a {
  color: #475569;
  text-decoration: none;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.15s;
}

.landing-nav-links a:hover {
  color: var(--primary-red);
}

.landing-hero {
  position: relative;
  background-color: #ffffff;
  background-image: url('../images/hero01.jpg');
  background-position: center right;
  background-size: cover;
  background-repeat: no-repeat;
  min-height: 560px;
  display: flex;
  align-items: center;
  overflow: hidden;
  border-bottom: 1px solid #f1f5f9;
}

/* hero01.jpg already includes diagonal accents and modern graphics */
.landing-hero::before {
  display: none;
}

.landing-hero-content {
  position: relative;
  z-index: 5;
  width: 58%;
  max-width: 720px;
  padding: 4.5rem 3rem 4.5rem 4rem;
}

.landing-greeting {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  color: #1e293b;
  display: inline-block;
}

.landing-red-bar {
  width: 48px;
  height: 4px;
  background-color: #e11d48;
  border-radius: 2px;
  margin: 8px 0 18px;
}

.landing-main-title {
  font-family: var(--font-heading);
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1.25rem;
  color: #0f172a;
  letter-spacing: -0.02em;
}

.landing-main-title span {
  color: #e11d48;
  display: block;
}

.landing-description {
  font-size: 1.1rem;
  color: #334155;
  line-height: 1.65;
  margin-bottom: 2.25rem;
  max-width: 540px;
}

.landing-btn-group {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.btn-landing-primary {
  background-color: #e11d48;
  color: #ffffff;
  padding: 0.85rem 2.25rem;
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.35);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-landing-primary:hover {
  background-color: #be123c;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(225, 29, 72, 0.45);
  color: #ffffff;
}

.btn-landing-outline {
  background-color: #ffffff;
  color: #0f172a;
  padding: 0.85rem 2.25rem;
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 2px solid #e11d48;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-landing-outline:hover {
  background-color: #fff1f2;
  border-color: #be123c;
  color: #0f172a;
}

.btn-landing-outline i {
  color: #e11d48;
}


.landing-bottom-bar {
  background: #700c1e;
  color: #ffffff;
  padding: 1.15rem 3rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
}

.landing-bottom-bar a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
}

.landing-bottom-bar a:hover {
  color: #ffffff;
  text-decoration: underline;
}

@media (max-width: 992px) {
  .landing-navbar {
    padding: 0.75rem 1.25rem;
    flex-wrap: wrap;
    gap: 0.75rem;
  }
  .landing-brand-img {
    height: 32px;
  }
  .landing-nav-links {
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    font-size: 0.85rem;
  }
  .landing-hero {
    min-height: 520px;
    background-position: 70% center;
  }
  .landing-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.94) 0%, rgba(255, 255, 255, 0.88) 60%, rgba(255, 255, 255, 0.55) 100%);
    backdrop-filter: blur(1px);
    z-index: 1;
    display: block;
    width: 100%;
    height: 100%;
  }
  .landing-hero-content {
    width: 100%;
    max-width: 100%;
    padding: 3rem 1.5rem;
  }
  .landing-main-title {
    font-size: 2.1rem;
  }
}

/* ==============================================================
   Login Page Styles (matching Mockup)
   ============================================================== */
.login-page-body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  height: 100vh;
  background-color: #ffffff;
  overflow: hidden;
  margin: 0;
}

.login-navbar {
  background: #ffffff;
  border-bottom: 1px solid #f1f5f9;
  padding: 0.85rem clamp(2.5rem, 7vw, 8rem);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-shrink: 0;
  z-index: 50;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.login-navbar .landing-brand {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  max-width: 100%;
}

.login-navbar .landing-brand-img {
  height: 58px;
  max-height: 62px;
  max-width: 90vw;
  width: auto;
  object-fit: contain;
}

.login-hero {
  flex: 1;
  position: relative;
  background: #ffffff url('../images/hero01.jpg') no-repeat center right / cover;
  display: flex;
  align-items: center;
  padding: 2.5rem clamp(2.5rem, 7vw, 8rem);
  overflow: hidden;
}

.login-hero-content {
  position: relative;
  z-index: 5;
  max-width: 680px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.login-hero-title {
  font-family: var(--font-heading);
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1.3;
  margin: 0 0 2.25rem 0;
  letter-spacing: -0.02em;
  text-align: center;
}

.login-hero-title .title-line1 {
  display: block;
  color: #0f172a;
  white-space: nowrap;
}

.login-hero-title .title-line2 {
  color: #e11d48;
  display: block;
  white-space: nowrap;
}

/* Login Actions Container (matching user screenshot) */
.login-actions-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
}

.btn-dashboard-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.85rem 1.5rem;
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  color: #E22440;
  background-color: #ffffff;
  border: 2px solid #E22440;
  border-radius: 14px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: 0 2px 6px rgba(226, 36, 64, 0.08);
}

.btn-dashboard-outline:hover {
  background-color: #fff1f2;
  border-color: #be123c;
  color: #be123c;
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(226, 36, 64, 0.16);
}

.btn-epassport-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  width: 100%;
  padding: 0.85rem 1.5rem;
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
  background-color: #E22440;
  border: 2px solid #E22440;
  border-radius: 14px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: 0 4px 14px rgba(226, 36, 64, 0.35);
}

.btn-epassport-primary:hover {
  background-color: #be123c;
  border-color: #be123c;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(226, 36, 64, 0.45);
}

.link-admin-login {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  color: #64748b;
  font-family: var(--font-heading);
  font-size: 0.925rem;
  font-weight: 500;
  text-decoration: none;
  margin-top: 0.35rem;
  cursor: pointer;
  background: transparent;
  border: none;
  padding: 0.25rem 0.5rem;
  transition: color 0.2s ease, transform 0.2s ease;
}

.link-admin-login:hover {
  color: #E22440;
  transform: translateY(-1px);
}

/* ==============================================================
   Modal Styling
   ============================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.modal-overlay.active {
  display: flex;
  opacity: 1;
}

.modal-container,
.modal-content {
  background: #ffffff !important;
  border-radius: 16px;
  width: 100%;
  max-width: 580px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  position: relative;
  animation: modalSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.modal-header {
  background: #ffffff;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.modal-close-btn,
.alert-close {
  background: transparent;
  border: none;
  font-size: 1.4rem;
  color: #94a3b8;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
  border-radius: 6px;
  transition: all 0.15s;
}

.modal-close-btn:hover,
.alert-close:hover {
  color: #0f172a;
  background: #f1f5f9;
}

.modal-body {
  background: #ffffff;
  padding: 1.5rem;
}

.modal-footer {
  padding: 1rem 1.5rem;
  background: #f8fafc;
  border-top: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
}

.login-footer-bar {
  background-color: #E22440;
  color: #ffffff;
  padding: 0.85rem clamp(2.5rem, 7vw, 8rem);
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.login-footer-inner {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.login-footer-line1 {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #ffffff;
}

.login-footer-line2 {
  font-size: 0.825rem;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.95);
  line-height: 1.4;
}

@media (max-width: 992px) {
  .login-page-body {
    height: auto;
    min-height: 100vh;
    overflow-y: auto;
  }
  .login-navbar {
    padding: 0.65rem 1.5rem;
    justify-content: flex-start;
  }
  .login-navbar .landing-brand-img {
    height: 42px;
    max-height: 44px;
    max-width: 94vw;
  }
  .login-hero {
    min-height: 480px;
    padding: 3rem 1.5rem;
    background-position: 70% center;
  }
  .login-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.93) 0%, rgba(255, 255, 255, 0.85) 60%, rgba(255, 255, 255, 0.5) 100%);
    backdrop-filter: blur(1px);
    z-index: 1;
    display: block;
    width: 100%;
    height: 100%;
  }
  .login-hero-title {
    font-size: 1.85rem;
    margin-bottom: 1.75rem;
  }
  .login-hero-title .title-line1,
  .login-hero-title .title-line2 {
    white-space: normal;
  }
  .btn-dashboard-outline,
  .btn-epassport-primary {
    max-width: 100%;
    padding: 0.75rem 1.25rem;
    font-size: 1rem;
  }
  .login-footer-bar {
    padding: 0.85rem 1.5rem;
    font-size: 0.825rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
  }
}

/* ==============================================================
   Page Header & Action Toolbar
   ============================================================== */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.page-title-group h1 {
  font-size: 1.45rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.page-title-group p {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin: 0.25rem 0 0;
}

/* ==============================================================
   Card & Data Container Components
   ============================================================== */
.card {
  background: #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 1rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border-light);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.card-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0;
}

/* ==============================================================
   Filter Card & Forms
   ============================================================== */
.filter-card {
  background: #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-sm);
}

.filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)) auto;
  gap: 1rem;
  align-items: flex-end;
}

/* Single Row Filter Layout */
.filter-row-single {
  display: flex;
  align-items: flex-end;
  gap: 0.75rem;
  width: 100%;
}

.filter-row-single .form-group {
  margin-bottom: 0;
}

.filter-row-single .flex-search {
  flex: 2.5;
  min-width: 220px;
}

.filter-row-single .flex-select {
  flex: 1.2;
  min-width: 135px;
}

.filter-row-single .filter-btn-group {
  display: flex;
  gap: 0.4rem;
  flex-shrink: 0;
}

@media (max-width: 1100px) {
  .filter-row-single {
    flex-wrap: wrap;
    gap: 0.75rem;
  }
  .filter-row-single .flex-search {
    flex: 1 1 100%;
  }
  .filter-row-single .flex-select {
    flex: 1 1 calc(33.333% - 0.75rem);
  }
}

@media (max-width: 640px) {
  .filter-row-single .flex-select {
    flex: 1 1 100%;
  }
  .filter-row-single .filter-btn-group {
    width: 100%;
  }
  .filter-row-single .filter-btn-group .btn {
    flex: 1;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #334155;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.form-control {
  width: 100%;
  height: 42px;
  padding: 0.5rem 0.85rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: #1e293b;
  background-color: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-control:focus {
  border-color: var(--primary-red);
  box-shadow: 0 0 0 3px rgba(225, 29, 72, 0.12);
}

/* ==============================================================
   Stats Grid & Metric Cards
   ============================================================== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  background: #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--card-accent, var(--primary-red));
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
}

.stat-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.stat-label {
  font-size: 0.825rem;
  font-weight: 500;
  color: var(--text-muted);
}

.stat-value {
  font-family: var(--font-heading);
  font-size: 1.65rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.2;
}

.stat-subtext {
  font-size: 0.75rem;
  color: #94a3b8;
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--icon-bg, #f1f5f9);
  color: var(--icon-color, var(--primary-red));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

/* ==============================================================
   Custom Responsive Table
   ============================================================== */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.custom-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.custom-table thead th {
  background-color: #f8fafc;
  color: #475569;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border-color);
  white-space: nowrap;
}

.custom-table tbody td {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
  color: #334155;
}

.custom-table tbody tr {
  transition: background-color 0.15s ease;
}

.custom-table tbody tr:hover {
  background-color: #f8fafc;
}

/* ==============================================================
   Buttons & Actions
   ============================================================== */
.btn-primary {
  background-color: var(--primary-red);
  color: #ffffff;
  border: 1px solid var(--primary-red);
  box-shadow: 0 2px 6px rgba(225, 29, 72, 0.2);
}

.btn-primary:hover {
  background-color: var(--primary-red-hover);
  border-color: var(--primary-red-hover);
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-secondary {
  background-color: #ffffff;
  border: 1px solid var(--border-color);
  color: #334155;
}

.btn-secondary:hover {
  background-color: #f8fafc;
  border-color: #cbd5e1;
  color: #0f172a;
}

.btn-outline-primary {
  background-color: #ffffff;
  border: 1.5px solid var(--primary-red);
  color: var(--primary-red);
}

.btn-outline-primary:hover {
  background-color: #ffe4e6;
  color: var(--primary-red-hover);
}

.btn-sm {
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
}

/* ==============================================================
   Badges, Pills, and Avatars
   ============================================================== */
.badge-rank {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.825rem;
  font-weight: 600;
  white-space: nowrap;
}

.badge-prof {
  background: #fef3c7;
  color: #b45309;
  border: 1px solid #fde68a;
}

.badge-assoc {
  background: #e0f2fe;
  color: #0369a1;
  border: 1px solid #bae6fd;
}

.badge-asst {
  background: #f3e8ff;
  color: #7e22ce;
  border: 1px solid #e9d5ff;
}

.badge-lecturer {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

.badge-none {
  background: #f1f5f9;
  color: #64748b;
  border: 1px solid #e2e8f0;
}

.badge-rank-sm {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius-full);
  font-size: 0.775rem;
  font-weight: 500;
  white-space: nowrap;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.status-active {
  background: #ecfdf5;
  color: #059669;
  border: 1px solid #a7f3d0;
}
.status-active .status-dot { background: #10b981; }

.status-leave {
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
}
.status-leave .status-dot { background: #3b82f6; }

.status-retired {
  background: #f8fafc;
  color: #64748b;
  border: 1px solid #e2e8f0;
}
.status-retired .status-dot { background: #94a3b8; }

.status-resigned {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
}
.status-resigned .status-dot { background: #ef4444; }

.status-other {
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #cbd5e1;
}

.tenure-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #f8fafc;
  color: #334155;
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.825rem;
  border: 1px solid #e2e8f0;
  white-space: nowrap;
}

.tenure-pill i {
  color: #64748b;
}

.table-person-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.avatar-initial {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #e11d48, #be123c);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1rem;
  flex-shrink: 0;
}

.person-name {
  font-family: var(--font-heading);
  font-weight: 600;
  color: #0f172a;
  text-decoration: none;
  display: block;
  transition: color 0.15s;
}

.person-name:hover {
  color: var(--primary-red);
  text-decoration: underline;
}

.person-meta {
  font-size: 0.775rem;
  color: var(--text-muted);
  display: block;
}

/* ==============================================================
   Print Styles & Header
   ============================================================== */
.print-header {
  display: none;
}

@media print {
  .no-print,
  .app-sidebar,
  .app-topbar,
  .btn,
  .modal-overlay,
  .btn-mobile-sidebar {
    display: none !important;
  }

  body, .app-layout, .app-main, .page-container {
    background: #ffffff !important;
    color: #000000 !important;
    margin: 0 !important;
    padding: 0 !important;
    min-height: auto !important;
  }

  .print-header {
    display: block !important;
    margin-bottom: 20px !important;
  }

  .card {
    box-shadow: none !important;
    border: 1px solid #e2e8f0 !important;
    break-inside: avoid;
    padding: 1rem !important;
  }

  .custom-table {
    border-collapse: collapse !important;
    width: 100% !important;
  }

  .custom-table th, .custom-table td {
    border: 1px solid #cbd5e1 !important;
    padding: 6px 8px !important;
    font-size: 0.8rem !important;
  }
}
