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

:root {
  --primary-deep: #0B2545;      /* Midnight Blue */
  --primary-royal: #134074;     /* Royal Blue */
  --primary-blue: #1E3A8A;      /* Strong Blue */
  --accent-blue: #00B4D8;       /* Bright Cyan/Blue */
  --accent-light: #E0F2FE;      /* Very Light Ice Blue */
  --text-dark: #0F172A;         /* Slate 900 */
  --text-muted: #64748B;        /* Slate 500 */
  --bg-page: #F8FAFC;           /* Slate 50 */
  --bg-card: #FFFFFF;
  --border-color: rgba(226, 232, 240, 0.8);
  --shadow-sm: 0 4px 6px -1px rgba(11, 37, 69, 0.05), 0 2px 4px -1px rgba(11, 37, 69, 0.03);
  --shadow-md: 0 10px 15px -3px rgba(11, 37, 69, 0.08), 0 4px 6px -2px rgba(11, 37, 69, 0.04);
  --shadow-lg: 0 20px 25px -5px rgba(11, 37, 69, 0.1), 0 10px 10px -5px rgba(11, 37, 69, 0.04);
  --transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --font-heading: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
}

body {
  background-color: var(--bg-page);
  color: var(--text-dark);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* Header Section */
.hero-header {
  background: linear-gradient(135deg, rgba(11, 37, 69, 0.55) 0%, rgba(19, 64, 116, 0.65) 100%), url('adminimage/bg1.JPG') no-repeat center center;
  background-size: cover;
  background-attachment: fixed;
  color: white;
  padding: 110px 0 100px 0;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  margin-bottom: 40px;
}

.hero-header::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -20%;
  width: 80%;
  height: 200%;
  background: radial-gradient(circle, rgba(0, 180, 216, 0.15) 0%, transparent 60%);
  pointer-events: none;
}

.hero-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 8px;
  background: linear-gradient(90deg, var(--accent-blue), #3b82f6, var(--accent-blue));
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 10;
}

.logo-info {
  display: flex;
  align-items: center;
  gap: 20px;
}

.logo-info img {
  height: 85px;
  width: auto;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  background: white;
  padding: 3px;
  transition: var(--transition);
}

.logo-info img:hover {
  transform: scale(1.05);
}

.header-title-section {
  text-align: left;
}

.header-title-section h1 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 2.25rem;
  letter-spacing: -0.025em;
  margin: 0;
  color: #FFFFFF;
  text-shadow: 0 2px 10px rgba(11, 37, 69, 0.85);
}

.header-title-section p {
  color: #FFFFFF;
  font-size: 1.05rem;
  margin: 8px 0 0 0;
  font-weight: 500;
  text-shadow: 0 2px 8px rgba(11, 37, 69, 0.85);
}

/* Controls (Search & Filters) */
.controls-wrapper {
  background: white;
  border-radius: 16px;
  padding: 16px 24px;
  margin-top: -25px;
  margin-bottom: 40px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
  position: relative;
  z-index: 20;
}

.filter-btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-btn {
  background: #F1F5F9;
  border: 1px solid transparent;
  color: var(--text-muted);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 10px 20px;
  border-radius: 30px;
  cursor: pointer;
  transition: var(--transition);
}

.filter-btn:hover {
  background: var(--accent-light);
  color: var(--primary-royal);
}

.filter-btn.active {
  background: var(--primary-royal);
  color: white;
  box-shadow: 0 4px 12px rgba(19, 64, 116, 0.25);
}

.search-input-wrapper {
  position: relative;
  width: 100%;
  max-width: 320px;
}

.search-input-wrapper i {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 0.95rem;
  transition: var(--transition);
}

.search-input {
  width: 100%;
  padding: 10px 16px 10px 42px;
  border-radius: 30px;
  border: 1px solid rgba(226, 232, 240, 1);
  background-color: #F8FAFC;
  font-size: 0.95rem;
  transition: var(--transition);
  color: var(--text-dark);
}

.search-input:focus {
  outline: none;
  border-color: var(--primary-royal);
  background-color: white;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
}

.search-input:focus + i {
  color: var(--primary-royal);
}

/* Sections & Grids */
.section-title-wrap {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 25px;
  margin-bottom: 25px;
  position: relative;
}

.section-title-wrap h2 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--primary-deep);
  margin: 0;
  position: relative;
  white-space: nowrap;
}

.section-title-wrap::after {
  content: '';
  flex-grow: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(226, 232, 240, 1), transparent);
}

/* Cards styling */
.card-wrapper {
  height: 100%;
  perspective: 1000px;
  transition: var(--transition);
}

.personnel-card {
  background: var(--bg-card);
  border-radius: 20px;
  border: 1px solid var(--border-color);
  padding: 20px 16px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.personnel-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: transparent;
  transition: var(--transition);
}

/* Leader Cards (Tier 1) styling */
.tier-executive .personnel-card {
  padding: 24px 20px;
  border-bottom: 4px solid var(--primary-royal);
}

.tier-executive .personnel-card::before {
  background: linear-gradient(90deg, var(--primary-royal), var(--accent-blue));
}

.tier-executive .img-wrapper {
  width: 150px;
  height: 185px;
  box-shadow: 0 8px 20px rgba(11, 37, 69, 0.15);
}

.tier-dean .personnel-card,
.tier-admin .personnel-card {
  padding: 16px 12px;
}

/* Image styling */
.img-wrapper {
  width: 125px;
  height: 155px;
  overflow: hidden;
  border-radius: 12px;
  margin-bottom: 15px;
  box-shadow: var(--shadow-md);
  border: 3px solid white;
  transition: var(--transition);
  position: relative;
}

.img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.personnel-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(30, 58, 138, 0.15);
}

.personnel-card:hover .img-wrapper {
  box-shadow: 0 12px 25px rgba(11, 37, 69, 0.2);
  border-color: var(--accent-light);
}

.personnel-card:hover .img-wrapper img {
  transform: scale(1.08);
}

/* Text elements inside cards */
.personnel-name {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--primary-deep);
  margin-bottom: 6px;
  line-height: 1.35;
  transition: var(--transition);
}

.personnel-card:hover .personnel-name {
  color: var(--primary-royal);
}

.tier-executive .personnel-name {
  font-size: 1.2rem;
}

.personnel-role {
  font-family: var(--font-body);
  font-size: 0.88rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 0;
  line-height: 1.4;
  flex-grow: 1; /* Pushes contacts to the bottom */
}

.tier-executive .personnel-role {
  font-size: 0.95rem;
}

/* Contact Links Bar */
.contact-actions {
  display: flex;
  gap: 12px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(226, 232, 240, 0.6);
  width: 100%;
  justify-content: center;
}

.contact-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: #F1F5F9;
  color: var(--primary-royal);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  text-decoration: none;
  font-size: 0.9rem;
}

.contact-btn:hover {
  background-color: var(--primary-royal);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(19, 64, 116, 0.2);
}

/* No Results placeholder */
.no-results {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
  background: white;
  border-radius: 20px;
  border: 1px dashed var(--border-color);
  margin-top: 30px;
}

.no-results i {
  font-size: 3rem;
  color: #CBD5E1;
  margin-bottom: 15px;
}

.no-results h3 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 8px;
}

/* Scroll to Top Button */
.scroll-top-btn {
  position: fixed !important;
  bottom: 40px !important;
  right: 40px !important;
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, var(--primary-royal) 0%, var(--primary-deep) 100%);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  z-index: 999;
  box-shadow: 0 6px 15px rgba(11, 37, 69, 0.25);
  border: 2px solid rgba(255, 255, 255, 0.1);
}

.scroll-top-btn.visible {
  opacity: 1;
  visibility: visible;
}

.scroll-top-btn:hover {
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 10px 20px rgba(11, 37, 69, 0.35);
  color: white;
}

/* Fancybox custom styles to match theme */
.fancybox-bg {
  background: rgba(11, 37, 69, 0.9) !important;
}

/* Responsive Grid adjustment */
@media (max-width: 992px) {
  .logo-info {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  .header-container {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 768px) {
  .hero-header {
    padding: 70px 0 75px 0;
  }
  .header-title-section h1 {
    font-size: 1.75rem;
  }
  .controls-wrapper {
    flex-direction: column;
    gap: 16px;
    padding: 16px;
  }
  .search-input-wrapper {
    max-width: 100%;
  }
  .scroll-top-btn {
    bottom: 20px !important;
    right: 20px !important;
    width: 44px;
    height: 44px;
  }
  .tier-executive .img-wrapper {
    width: 125px;
    height: 155px;
  }
  .img-wrapper {
    width: 105px;
    height: 130px;
    border-width: 2px;
    margin-bottom: 10px;
  }
}
