:root {
  --al-primary: #1e407a;
  --al-accent: #ffc53a;
  --al-secondary: #3b82f6;
  --al-tertiary: #02c39a;
  --al-soft: #cdd4fb;
  --al-chip-bg: #b7d8ef;
  --al-text-main: #292929;
  --al-text-muted: #545454;
  --al-border-soft: #e0e0e0;
  --al-page-bg: #f8f9fa;
  --al-card-bg: #ffffff;
  --al-radius-lg: 20px;
  --al-radius-md: 14px;
  --al-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  --al-shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.12);
  --al-transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Hide theme headers */
.post-type-archive-alumni .page-header,
.post-type-archive-alumni .page-title,
.post-type-archive-alumni .entry-title,
.post-type-archive-alumni #sub-header,
.post-type-archive-alumni .elementor-page-title {
  display: none !important;
}

body.post-type-archive-alumni {
  background: var(--al-page-bg);
  color: var(--al-text-main);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  margin: 0;
}

/* OVERFLOW FIX */
.limit-wrapper,
.vamtam-box-outer-padding {
  overflow: visible !important;
}

/* ========================================
   1. HERO SECTION (Full-bleed)
   ======================================== */
.al-hero-wrapper {
  position: relative !important;
  width: 100vw !important;
  max-width: none !important;
  margin-left: calc(50% - 50vw) !important;
  margin-top: 0 !important;
  height: 450px;
  background-size: cover;
  background-position: center;
  background-color: var(--al-primary);
  display: flex;
  align-items: flex-end;
  margin-bottom: 3rem;
}

.al-hero-overlay-box {
  background: var(--al-primary);
  color: #ffffff;
  padding: 2.5rem 3rem;
  width: 90%;
  max-width: 600px;
  margin-left: 10%;
  margin-bottom: -3rem;
  position: relative;
  z-index: 10;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  border-top-left-radius: var(--al-radius-lg);
  border-top-right-radius: var(--al-radius-lg);
}

.al-hero-title {
  margin: 0 0 0.75rem;
  font-size: 2.5rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #ffffff !important;
}

.al-hero-subtitle {
  font-size: 1.05rem;
  line-height: 1.6;
  opacity: 0.9;
  margin: 0;
}

/* RTL Hero */
html[dir="rtl"] .al-hero-wrapper {
  margin-right: calc(50% - 50vw) !important;
  margin-left: 0 !important;
  right: 0;
  left: auto;
}

html[dir="rtl"] .al-hero-overlay-box {
  margin-left: 0;
  margin-right: 10%;
  text-align: right;
  direction: rtl;
}

/* ========================================
   2. ARCHIVE PAGE WRAPPER
   ======================================== */
.al-archive-page {
  padding: 60px 0 80px;
}

.al-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ========================================
   3. HEADER BAR WITH STATS
   ======================================== */
.al-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 40px;
  margin-top: 20px;
}

.al-header-main {
  display: flex;
  flex-direction: column;
}

.al-header-title {
  font-size: 2rem !important;
  font-weight: 800 !important;
  color: var(--al-primary) !important;
  margin: 0 !important;
}

/* Stat Card */
.al-stat-card {
  min-width: 220px;
  padding: 14px 18px;
  border-radius: var(--al-radius-md);
  background: linear-gradient(135deg, var(--al-primary), #164885);
  color: #ffffff;
  box-shadow: 0 16px 40px rgba(6, 30, 72, 0.45);
}

.al-header-label {
  display: block;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--al-text-muted);
  margin-bottom: 4px;
  font-weight: 600;
}

.al-stat-value {
  font-size: 1.8rem;
  font-weight: 800;
  display: block;
  line-height: 1;
}

.al-stat-label {
  font-size: 0.85rem;
  opacity: 0.9;
  font-weight: 500;
}

.al-stat-note {
  font-size: 0.7rem;
  opacity: 0.7;
  display: block;
  margin-top: 4px;
}

/* ========================================
   4. SMART FILTERS - PREMIUM PILL STYLE
   ======================================== */
.al-smart-filters {
  margin-bottom: 50px;
}

/* Controls Wrapper */
.al-controls-wrapper {
  background: #ffffff;
  border: 1px solid var(--al-border-soft);
  border-radius: var(--al-radius-lg);
  padding: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-end;
  box-shadow: var(--al-shadow);
}

.al-control-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 220px;
  flex: 1;
}

.al-group-search {
  min-width: 280px;
  flex: 1.5;
}

.al-control-label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 800;
  color: var(--al-primary);
  margin-bottom: 6px;
  display: block;
  padding-left: 10px;
  border-left: 3px solid var(--al-accent);
  line-height: 1;
}

html[dir="rtl"] .al-control-label {
  padding-left: 0;
  padding-right: 10px;
  border-left: none;
  border-right: 3px solid var(--al-accent);
}

.al-select,
.al-input {
  width: 100%;
  padding: 12px 18px;
  border-radius: 10px;
  border: 2px solid var(--al-border-soft);
  background: var(--al-page-bg);
  font-size: 0.95rem;
  color: var(--al-text-main);
  transition: var(--al-transition);
  box-sizing: border-box;
  font-weight: 500;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231e407a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 16px;
}

html[dir="rtl"] .al-select {
  background-position: left 1rem center;
  /* background-image is same, positioning flips */
}

.al-select:focus,
.al-input:focus {
  outline: none;
  border-color: var(--al-primary);
  box-shadow: 0 0 0 3px rgba(30, 64, 122, 0.15);
}

.al-input {
  background-image: none;
}

/* ========================================
   5. GRID & CARDS
   ======================================== */
.al-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  min-height: 400px;
}

.al-grid.loading {
  pointer-events: none;
}

@media (max-width: 992px) {
  .al-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .al-grid {
    grid-template-columns: 1fr;
  }
}

.al-card {
  background: var(--al-card-bg);
  border-radius: var(--al-radius-lg);
  box-shadow: var(--al-shadow);
  border: 1px solid rgba(205, 212, 251, 0.5);
  overflow: hidden;
  transition: var(--al-transition);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.al-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.al-card-photo-wrap {
  height: 380px;
  overflow: hidden;
  background: #f1f5f9;
}

.al-card-photo {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: top center !important;
  transition: transform 0.4s ease;
  display: block;
}

.al-card:hover .al-card-photo {
  transform: scale(1.03);
}

.al-card-content {
  padding: 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.al-card-header {
  margin-bottom: 12px;
  position: relative;
}

.al-card-title {
  margin: 0 0 6px;
  font-size: 1.2rem !important;
  font-weight: 700 !important;
  line-height: 1.3;
}

.al-card-title a {
  color: var(--al-primary) !important;
  text-decoration: none;
  transition: color 0.2s ease;
}

.al-card-title a:hover {
  color: var(--al-secondary) !important;
}

.al-card-job {
  font-size: 0.95rem;
  color: var(--al-text-muted);
  margin: 0;
  line-height: 1.4;
  font-weight: 500;
}

.al-card-org {
  color: var(--al-secondary);
  font-weight: 600;
  display: inline-block;
  margin-top: 2px;
}

.al-card-meta {
  margin-top: auto;
  margin-bottom: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.al-meta-item {
  font-size: 0.75rem;
  background: #f1f5f9;
  padding: 4px 12px;
  border-radius: 6px;
  color: var(--al-text-muted);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.al-card-footer {
  margin-top: auto;
  border-top: 1px solid var(--al-border-soft);
  padding-top: 20px;
  width: 100%;
}

body .al-btn-view {
  display: block;
  text-align: center;
  width: 100%;
  padding: 14px;
  background: var(--al-primary) !important;
  color: #ffffff !important;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  transition: var(--al-transition);
  box-shadow: 0 4px 6px rgba(30, 64, 122, 0.2);
}

body .al-btn-view:hover {
  background: #16345f !important;
  color: #ffffff !important;
  transform: translateY(-2px);
  box-shadow: 0 8px 12px rgba(30, 64, 122, 0.3);
}

/* No Results */
.al-no-results {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  background: #f8fafc;
  border: 2px dashed var(--al-border-soft);
  border-radius: var(--al-radius-lg);
  color: var(--al-text-muted);
}

.al-no-results h3 {
  font-size: 1.5rem;
  color: var(--al-primary);
  margin-bottom: 10px;
}

/* ========================================
   6. PREMIUM PAGINATION
   ======================================== */
.al-pagination {
  margin-top: 60px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.al-pagination ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 8px;
  align-items: center;
}

.al-pagination li {
  display: inline-block;
}

.al-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  height: 44px;
  padding: 0 14px;
  background: #ffffff;
  border: 2px solid var(--al-border-soft);
  border-radius: 22px;
  color: var(--al-text-main);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: var(--al-transition);
}

.al-pagination .page-numbers.current,
.al-pagination .page-numbers.current:hover {
  background: var(--al-primary);
  color: #ffffff;
  border-color: var(--al-primary);
  box-shadow: 0 4px 12px rgba(30, 64, 122, 0.3);
}

.al-pagination .page-numbers:hover:not(.current) {
  transform: translateY(-2px);
  box-shadow: var(--al-shadow);
  border-color: var(--al-primary);
  color: var(--al-primary);
}


/* ========================================
   7. RESPONSIVE & RTL
   ======================================== */
@media (max-width: 768px) {
  .al-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }

  html[dir="rtl"] .al-header {
    align-items: flex-end;
  }

  .al-hero-overlay-box {
    width: 95%;
    margin-left: 2.5%;
    padding: 2rem;
  }

  html[dir="rtl"] .al-hero-overlay-box {
    margin-right: 2.5%;
    margin-left: 0;
  }

  .al-filters {
    grid-template-columns: 1fr;
  }
}

/* IMAGE FIT FIX FOR ARABIC */
html[dir="rtl"] .al-card-photo-wrap {
  direction: ltr;
}

html[dir="rtl"] .al-card-photo {
  object-fit: cover !important;
  object-position: top center !important;
  width: 100% !important;
  height: 100% !important;
}

/* Button fix for both LTR and RTL */
.al-card-footer {
  margin-top: auto;
  border-top: 1px solid var(--al-border-soft);
  padding-top: 20px;
  width: 100%;
  text-align: center;
}

body .al-btn-view {
  display: block !important;
  text-align: center !important;
  width: 100% !important;
  box-sizing: border-box !important;
}