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

/* Global Variables - Taguig City University Theme */
:root {
  /* TCU Official Colors */
  --primary-color: #800000;
  /* TCU Maroon */
  --primary-light: rgba(128, 0, 0, 0.1);
  --primary-medium: rgba(128, 0, 0, 0.5);
  --primary-dark: #500000;

  --accent-color: #A51C30;
  /* Secondary Red */
  --accent-light: rgba(165, 28, 48, 0.1);

  --luxury-gold: #C5B358;
  /* Gold Foil */
  --luxury-gold-light: rgba(197, 179, 88, 0.1);
  --luxury-gold-medium: rgba(197, 179, 88, 0.3);
  --luxury-gold-dark: #8B7500;

  --tcu-blue: #003366;
  /* Heritage Blue */

  --tcu-gradient: linear-gradient(135deg, #600000 0%, #800000 50%, #C5B358 100%);
  --gold-gradient: linear-gradient(135deg, #C5B358 0%, #E5C158 50%, #B8860B 100%);
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(197, 179, 88, 0.25);

  --dark-gray: #333333;
  --medium-gray: #777777;
  --light-gray: #EEEEEE;
  --lighter-gray: #FBFAFA;
  --white: #ffffff;
  --black: #111111;

  --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  --shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.12);
  --shadow-accent: 0 8px 25px rgba(128, 0, 0, 0.15);

  /* Theme-specific variables */
  --bg-primary: #ffffff;
  --bg-secondary: #fdfdfd;
  --bg-tertiary: #f5f5f5;
  --text-primary: #222222;
  --text-secondary: #444444;
  --text-muted: #888888;
  --border-color: #efefef;
  --card-bg: #ffffff;
  --input-bg: #ffffff;
  --header-bg: #ffffff;
  --footer-bg: #1a0000;
  --footer-text: #d1d1d1;

  /* Fonts */
  --font-heading: 'Playfair Display', serif;
  --font-body: 'Montserrat', sans-serif;
}

/* Dark Theme Variables */
[data-theme="dark"] {
  --primary-color: #A51C30;
  /* Lighter TCU Maroon */
  --primary-light: rgba(165, 28, 48, 0.2);
  --primary-medium: rgba(165, 28, 48, 0.6);
  --primary-dark: #800000;

  --accent-color: #CD5C5C;
  --accent-light: rgba(205, 92, 92, 0.1);

  --luxury-gold: #FFD700;
  /* Bright Gold for dark theme */
  --luxury-gold-light: rgba(255, 214, 0, 0.15);
  --luxury-gold-medium: rgba(255, 214, 0, 0.4);
  --luxury-gold-dark: #B8860B;

  --bg-primary: #121212;
  --bg-secondary: #1E1E1E;
  --bg-tertiary: #2D2D2D;
  --text-primary: #f5f5f5;
  --text-secondary: #d1d1d1;
  --text-muted: #999999;
  --border-color: #333333;
  --card-bg: #222222;
  --input-bg: #2A2A2A;
  --header-bg: #1E1E1E;
  --footer-bg: #0A0000;
  --footer-text: #888888;

  --tcu-gradient: linear-gradient(135deg, #800000 0%, #A51C30 50%, #FFD700 100%);
  --gold-gradient: linear-gradient(135deg, #FFD700 0%, #FFE57F 50%, #B8860B 100%);
  --glass-bg: rgba(30, 30, 30, 0.8);
  --glass-border: rgba(197, 179, 88, 0.15);
}

/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  background-color: var(--bg-secondary);
  color: var(--text-primary);
  font-family: var(--font-body);
  transition: background-color 0.3s ease, color 0.3s ease;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
}

header {
  margin: 0;
  padding: 0;
  background-color: var(--header-bg);
  transition: background-color 0.3s ease;
}

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

main,
.main-content {
  flex: 1;
  margin-top: 70px;
}


a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul {
  list-style: none;
}

/* Button Styles - Unified Design System */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 10px 22px;
  height: 44px;
  border-radius: 8px;
  border: 2px solid transparent;
  background: transparent;
  color: var(--text-primary);
  cursor: pointer;
  white-space: nowrap;
  user-select: none;
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  box-sizing: border-box;
  text-decoration: none;
  text-align: center;
}

/* Accessibility focus outline */
.btn:focus-visible {
  outline: 3px solid var(--primary-light);
  outline-offset: 1px;
}

/* Primary Button: Solid TCU Maroon with brand gradient */
.btn-primary {
  background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
  color: var(--white);
  border: none;
  box-shadow: 0 4px 12px rgba(128, 0, 0, 0.18);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(128, 0, 0, 0.28);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 4px 8px rgba(128, 0, 0, 0.15);
}

/* Secondary Button: Outlined grey/neutral */
.btn-secondary {
  background: var(--white);
  color: var(--text-primary);
  border-color: var(--border-color);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.btn-secondary:hover {
  background: var(--bg-tertiary);
  border-color: var(--medium-gray);
  color: var(--text-primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.08);
}

.btn-secondary:active {
  transform: translateY(0);
}

/* Accent Button: Gold foil design for important submissions/actions */
.btn-accent {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--luxury-gold) 100%);
  color: var(--white);
  border: none;
  box-shadow: 0 4px 14px rgba(197, 179, 88, 0.25);
}

.btn-accent:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 8px 24px rgba(197, 179, 88, 0.4);
  color: var(--white);
}

.btn-accent:active {
  transform: translateY(0) scale(1);
}

/* Outline Button: TCU Maroon border, transparent background */
.btn-outline {
  border-color: var(--primary-color);
  color: var(--primary-color);
  background: transparent;
}

.btn-outline:hover {
  background: var(--primary-color);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(128, 0, 0, 0.15);
}

.btn-outline:active {
  transform: translateY(0);
}

/* Ghost Button: Borderless, minimal styling */
.btn-ghost {
  border-color: transparent;
  color: var(--text-secondary);
  background: transparent;
}

.btn-ghost:hover {
  background: var(--primary-light);
  color: var(--primary-color);
}

/* Danger Button: Red theme for deletions, declines, rejections */
.btn-danger {
  background: var(--accent-color);
  color: var(--white);
  border-color: var(--accent-color);
  box-shadow: 0 4px 12px rgba(165, 28, 48, 0.15);
}

.btn-danger:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(165, 28, 48, 0.25);
}

/* Success Button: Green theme for approvals, accepts */
.btn-success {
  background: #2e7d32;
  color: var(--white);
  border-color: #2e7d32;
  box-shadow: 0 4px 12px rgba(46, 125, 50, 0.15);
}

.btn-success:hover {
  background: #1b5e20;
  border-color: #1b5e20;
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(46, 125, 50, 0.25);
}

/* Disabled State */
.btn:disabled,
.btn.disabled {
  background: var(--light-gray) !important;
  color: var(--medium-gray) !important;
  border-color: var(--border-color) !important;
  box-shadow: none !important;
  cursor: not-allowed !important;
  transform: none !important;
  opacity: 0.6;
}

/* Sizes */
.btn-sm {
  padding: 6px 14px;
  height: 32px;
  font-size: 0.85rem;
  border-radius: 6px;
}

.btn-md {
  padding: 10px 22px;
  height: 44px;
  font-size: 0.95rem;
}

.btn-lg {
  padding: 14px 32px;
  height: 52px;
  font-size: 1.05rem;
  border-radius: 10px;
}

/* Footer Styles */
/* Professional Footer Redesign */
.main-footer {
  background-color: var(--primary-dark);
  color: var(--white);
  padding: 80px 0 0;
  margin-top: auto;
  position: relative;
  overflow: hidden;
  border-top: 4px solid var(--luxury-gold);
}

.main-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 10% 20%, rgba(128, 0, 0, 0.4) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(165, 28, 48, 0.2) 0%, transparent 40%);
  pointer-events: none;
}

.footer-grid {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 40px;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: 50px;
  position: relative;
  z-index: 2;
}

.footer-section h3 {
  font-family: var(--font-heading);
  color: var(--white);
  font-size: 1.6rem;
  margin-bottom: 20px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.footer-section h4 {
  font-family: var(--font-heading);
  color: var(--luxury-gold);
  font-size: 1.2rem;
  margin-bottom: 25px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  position: relative;
  display: inline-block;
}

.footer-section h4::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 40px;
  height: 2px;
  background-color: var(--luxury-gold);
}

.footer-brand {
  margin-bottom: 25px;
}

.footer-brand-title {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 15px;
}

.footer-logo {
  width: 70px;
  height: 70px;
  object-fit: contain;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
  border: 2px solid var(--luxury-gold);
  border-radius: 50%;
  background: white;
  padding: 2px;
}

.footer-section p {
  color: #e0e0e0;
  line-height: 1.7;
  font-size: 0.95rem;
  margin-bottom: 25px;
  opacity: 0.9;
}

.footer-section ul {
  padding: 0;
  margin: 0;
}

.footer-section ul li {
  margin-bottom: 12px;
  list-style: none;
}

.footer-section ul li a {
  color: #d1d1d1;
  font-size: 0.95rem;
  transition: var(--transition);
  display: inline-block;
  cursor: pointer;
}

.footer-section ul li a:hover {
  color: var(--luxury-gold);
  transform: translateX(8px);
}

.social-links {
  display: flex;
  gap: 15px;
  margin-top: 25px;
}

.social-link {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.social-link:hover {
  background: var(--luxury-gold);
  color: var(--primary-dark);
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
  border-color: var(--luxury-gold);
}

.contact-info p {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: #d1d1d1;
  margin-bottom: 18px;
  font-size: 0.95rem;
  line-height: 1.4;
}

.contact-info i {
  color: var(--luxury-gold);
  font-size: 1.1rem;
  margin-top: 2px;
}

.footer-bottom {
  margin-top: 70px;
  padding: 30px 40px;
  background-color: rgba(0, 0, 0, 0.2);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
  z-index: 2;
}

.footer-bottom-content {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
}

.footer-bottom p {
  color: #999;
  font-size: 0.85rem;
  margin: 0;
}

.footer-links {
  display: flex;
  gap: 25px;
}

.footer-links a {
  color: #999;
  font-size: 0.85rem;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--luxury-gold);
}


/* Landing Footer Styles */
.landing-footer {
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
  color: white;
  padding: 40px 0 20px;
  margin-top: 60px;
}

/* Responsive Footer */
@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .footer-bottom-content {
    flex-direction: column;
    text-align: center;
  }

  .footer-links {
    justify-content: center;
  }
}

/* Header Styles */
.main-header,
.redesigned-header {
  background: var(--glass-bg) !important;
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.03) !important;
  border-bottom: 2px solid var(--glass-border) !important;
  position: fixed;
  width: 100%;
  top: 0;
  left: 0;
  z-index: 1000;
  padding: 0;
  transition: background-color 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.header-inner,
.main-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  height: 70px;
}

.logo-container {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
}


.logo-container h1 {
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--primary-color);
  letter-spacing: 1px;
}

.header-flex-center {
  flex: 1 1 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.main-nav ul,
.nav-center {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  color: var(--text-primary);
  font-weight: 500;
  font-size: 1.05rem;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary-color);
  border-bottom: 2px solid var(--primary-color);
}

.nav-link-disabled {
  color: var(--text-muted) !important;
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
  border-bottom: none !important;
}

.nav-right,
.auth-buttons,
.header-buttons {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
}

.dashboard-btn,
.logout-btn,
.login-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  padding: 8px 20px;
  height: 40px;
  min-width: 120px;
  box-sizing: border-box;
  border-radius: 6px;
  border: 1.5px solid var(--primary-color);
  background: transparent;
  color: var(--primary-color);
  font-weight: 600;
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  margin-left: 10px;
  cursor: pointer;
  text-decoration: none;
}

.dashboard-btn:hover,
.logout-btn:hover,
.login-btn:hover {
  background: var(--primary-light);
  color: var(--primary-color);
  transform: translateY(-1px);
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--primary-light) 100%);
  padding: 120px 0 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
  z-index: 1;
  border-bottom: 3px solid var(--primary-color);
  color: var(--text-primary);
}

.university-hero {
  background: radial-gradient(circle at 80% 20%, rgba(197, 179, 88, 0.15) 0%, transparent 50%),
              radial-gradient(circle at 10% 80%, rgba(128, 0, 0, 0.08) 0%, transparent 60%),
              linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%) !important;
  border-bottom: 4px solid var(--luxury-gold) !important;
}

.hero-content {
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.hero-eyebrow {
  display: inline-block;
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--primary-color);
  margin-bottom: 15px;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 25px;
  color: var(--text-primary);
}

.hero-title span {
  color: var(--primary-color);
  display: block;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  max-width: 700px;
  margin: 0 auto 40px;
  line-height: 1.6;
}

.hero-stats {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;
  margin-top: 50px;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-number {
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary-color);
}

.stat-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background-color: var(--border-color);
}

.hero::before {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-light) 0%, transparent 70%);
  z-index: -1;
  animation: pulse 10s infinite alternate;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30px;
  left: -30px;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--primary-light) 0%, transparent 70%);
  z-index: -1;
  animation: pulse 8s infinite alternate-reverse;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 20px;
  color: var(--text-primary);
  position: relative;
  display: inline-block;
  letter-spacing: 0.5px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.section-title::after {
  content: '';
  position: absolute;
  width: 60%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--luxury-gold), var(--accent-color));
  bottom: -12px;
  left: 20%;
  transform: scaleX(0);
  transform-origin: center;
  animation: scale-in 0.8s ease forwards 0.3s;
  border-radius: 2px;
  box-shadow: 0 2px 8px rgba(139, 0, 0, 0.3), 0 0 10px var(--luxury-gold-light);
}

@keyframes scale-in {
  to {
    transform: scaleX(1);
  }
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 30px;
}

.search-container {
  margin: 30px auto;
  max-width: 100%;
}

.search-form {
  display: flex;
  flex-direction: column;
  width: 100%;
  box-shadow: var(--shadow);
  border-radius: 8px;
  overflow: visible;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  position: relative;
}

/* Search Input Row */
.search-input-row {
  display: flex;
  align-items: center;
  gap: 0;
  width: 100%;
  background: var(--input-bg);
  border-radius: 8px 8px 0 0;
  border: 1px solid var(--border-color);
  border-bottom: none;
  overflow: hidden;
}

.search-input {
  flex: 1;
  padding: 12px 20px;
  border: none;
  font-size: 1rem;
  background-color: transparent;
  color: var(--text-primary);
  transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
  outline: none;
}

.search-input:focus {
  outline: none;
}

.search-button {
  background: linear-gradient(135deg, var(--primary-color), var(--luxury-gold));
  color: var(--white);
  border: none;
  padding: 12px 25px;
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition);
  box-shadow: 0 2px 8px rgba(139, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
  border-left: 1px solid var(--border-color);
  white-space: nowrap;
}

.search-button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, var(--luxury-gold-light), transparent);
  transition: left 0.5s ease;
}

.search-button:hover::before {
  left: 100%;
}

.search-button:hover {
  background: linear-gradient(135deg, var(--primary-dark), var(--luxury-gold-dark));
  box-shadow: 0 4px 15px rgba(139, 0, 0, 0.4), 0 0 20px var(--luxury-gold-light);
  transform: translateY(-2px);
}

/* Enhanced Hero Search Styles */
.hero-search-container {
  max-width: 800px;
  margin: 40px auto 0;
  padding: 0 15px;
}

.hero-search-form {
  background: var(--card-bg);
  padding: 8px;
  border-radius: 50px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(128, 0, 0, 0.05);
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  border: 1px solid var(--border-color);
}

.hero-search-form:focus-within {
  box-shadow: 0 20px 50px rgba(128, 0, 0, 0.15), 0 0 0 4px var(--primary-light);
  border-color: var(--primary-color);
  transform: translateY(-3px);
}

.search-input-group {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 0 10px;
}

.search-icon {
  color: var(--primary-color);
  font-size: 1.2rem;
  margin-left: 15px;
  opacity: 0.7;
}

.search-input-group input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 12px 15px;
  font-size: 1.1rem;
  color: var(--text-primary);
  outline: none;
}

.search-submit {
  background: linear-gradient(135deg, var(--primary-color), var(--accent-color)) !important;
  color: white !important;
  border: none !important;
  padding: 12px 30px !important;
  border-radius: 40px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1) !important;
  box-shadow: 0 4px 15px rgba(128, 0, 0, 0.3) !important;
}

.search-submit:hover {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary-color)) !important;
  box-shadow: 0 6px 20px rgba(128, 0, 0, 0.4), 0 0 15px var(--luxury-gold-medium) !important;
  transform: scale(1.02) translateY(0);
}

@keyframes shake {

  0%,
  100% {
    transform: translateX(0);
  }

  25% {
    transform: translateX(-5px);
  }

  75% {
    transform: translateX(5px);
  }
}

.shake {
  animation: shake 0.4s ease-in-out;
}

.table-responsive {
  overflow-x: auto;
  margin-bottom: 2rem;
  box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.05);
  border-radius: 8px;
}

.filter-container {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 20px;
}

.filter-dropdown {
  position: relative;
  flex: 1;
  max-width: 190px;
}

.filter-dropdown select {
  width: 100%;
  padding: 10px 15px;
  border: none;
  background-color: var(--light-gray);
  border-radius: 4px;
  appearance: none;
  cursor: pointer;
  box-shadow: var(--shadow);
  color: var(--medium-gray);
  transition: var(--transition);
}

.filter-dropdown::after {
  content: '\f107';
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: var(--primary-color);
}

.filter-dropdown select:focus {
  outline: none;
  box-shadow: 0 0 0 2px var(--primary-light);
}

/* Recently Added Section */
.recently-added {
  padding: 60px 0;
}

.thesis-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.thesis-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  background-color: var(--card-bg);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  position: relative;
  border: 1px solid var(--border-color);
  height: 220px;
}

.thesis-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary-color);
}

.thesis-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 0;
  background: linear-gradient(180deg, var(--primary-color), var(--accent-color));
  transition: height 0.4s ease;
  z-index: 10;
}

.thesis-card:hover::before {
  height: 100%;
}

.thesis-cover {
  width: 120px;
  height: 100%;
  background-image: url('/static/images/thesis-cover-default.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: var(--primary-color);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 1px solid var(--border-color);
}

.thesis-cover::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.15) 50%, transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.thesis-card:hover .thesis-cover::before {
  opacity: 1;
}

.thesis-cover-placeholder {
  display: flex;
  color: rgba(255, 255, 255, 0.6);
  font-size: 1.5rem;
  z-index: 2;
}

.thesis-tag {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(197, 179, 88, 0.1);
  color: var(--luxury-gold-dark);
  border: 1px solid rgba(197, 179, 88, 0.3);
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 700;
  z-index: 5;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.thesis-info {
  padding: 20px;
  background: var(--card-bg);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.thesis-title {
  font-size: 1.3rem;
  margin-bottom: 12px;
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.3;
  min-height: 2.6em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.thesis-author {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
  font-weight: 500;
}

.thesis-meta {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 20px;
  font-weight: 500;
}

.view-button {
  display: inline-block;
  padding: 5px 15px;
  background-color: var(--primary-color);
  color: #ffffff !important;
  border-radius: 4px;
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--transition);
}

.view-button:hover {
  background-color: var(--primary-dark);
  color: #ffffff !important;
  transform: translateY(-1px);
}

/* Status pills for submissions */
.status-pill {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.2px;
  background: var(--light-gray);
  color: var(--medium-gray);
}

.status-pill.status-draft {
  background: #fff8e1;
  color: #b36b00;
}

.status-pill.status-submitted {
  background: #e8f0ff;
  color: #2357d1;
}

.status-pill.status-approved {
  background: #e8f9ef;
  color: #1b7f3a;
}

.status-pill.status-rejected {
  background: #fde8e8;
  color: #b21c1c;
}

.pagination {
  display: flex;
  justify-content: center;
  margin-top: 40px;
}

.pagination-button {
  background-color: var(--primary-color);
  color: var(--white);
  padding: 10px 25px;
  border-radius: 4px;
  font-weight: 500;
  transition: var(--transition);
  text-align: center;
  box-shadow: var(--shadow);
}

.pagination-button:hover {
  background-color: var(--primary-medium);
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

/* Departments Section */
.departments {
  padding: 60px 0;
  background-color: var(--white);
}

.department-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.department-card-v2 {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 24px;
  padding: 40px 30px;
  text-align: center;
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
  position: relative;
  overflow: hidden;
  z-index: 1;
  
  /* Brand color variables default to TCU Maroon */
  --dept-color: var(--primary-color);
  --dept-color-light: var(--primary-light);
  --dept-color-rgb: 128, 0, 0;
}

/* College-Specific Theme Mappings */
.department-card-v2.dept-graduate { --dept-color: #0ea5e9; --dept-color-light: rgba(14, 165, 233, 0.08); --dept-color-rgb: 14, 165, 233; }  /* Light Blue */
.department-card-v2.dept-ce       { --dept-color: #2563eb; --dept-color-light: rgba(37, 99, 235, 0.08);  --dept-color-rgb: 37, 99, 235; }   /* Blue */
.department-card-v2.dept-cict     { --dept-color: #7c3aed; --dept-color-light: rgba(124, 58, 237, 0.08); --dept-color-rgb: 124, 58, 237; }  /* Violet */
.department-card-v2.dept-cas      { --dept-color: #9ca3af; --dept-color-light: rgba(156, 163, 175, 0.12); --dept-color-rgb: 156, 163, 175; } /* White/Silver */
.department-card-v2.dept-cbm      { --dept-color: #d97706; --dept-color-light: rgba(217, 119, 6, 0.08);  --dept-color-rgb: 217, 119, 6; }   /* Light Yellow */
.department-card-v2.dept-ccj      { --dept-color: #800000; --dept-color-light: rgba(128, 0, 0, 0.08);    --dept-color-rgb: 128, 0, 0; }     /* Maroon */
.department-card-v2.dept-chtm     { --dept-color: #16a34a; --dept-color-light: rgba(22, 163, 74, 0.08);  --dept-color-rgb: 22, 163, 74; }   /* Green */
.department-card-v2.dept-cet      { --dept-color: #ea580c; --dept-color-light: rgba(234, 88, 12, 0.08);  --dept-color-rgb: 234, 88, 12; }   /* Orange */
.department-card-v2.dept-ippg     { --dept-color: #dc2626; --dept-color-light: rgba(220, 38, 38, 0.08);  --dept-color-rgb: 220, 38, 38; }   /* Red */
.department-card-v2.dept-coll     { --dept-color: var(--primary-color); --dept-color-light: var(--primary-light); --dept-color-rgb: 128, 0, 0; }

.department-card-v2::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 6px;
  background: var(--dept-color) !important;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 2;
}

.department-card-v2:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(var(--dept-color-rgb), 0.15);
  border-color: rgba(var(--dept-color-rgb), 0.35) !important;
}

.department-card-v2:hover::before {
  opacity: 1;
}

.card-icon-wrapper {
  width: 90px;
  height: 90px;
  background: var(--dept-color-light) !important;
  border-radius: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 30px;
  color: var(--dept-color) !important;
  font-size: 2.2rem;
  transition: all 0.5s ease;
  transform: rotate(-5deg);
}

.department-card-v2:hover .card-icon-wrapper {
  background: var(--dept-color) !important;
  color: var(--white) !important;
  transform: rotate(0deg) scale(1.1);
  box-shadow: 0 10px 25px var(--dept-color-light) !important;
}

.department-card-v2 h3 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 18px;
  min-height: 4.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1.25;
}

.department-card-v2 p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 30px;
  opacity: 0.85;
  flex-grow: 1;
}

.card-link {
  color: var(--dept-color) !important;
  font-weight: 700;
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s ease;
  padding: 10px 20px;
  border-bottom: 2px solid transparent;
  width: fit-content;
}

.card-link i {
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.department-card-v2:hover .card-link {
  gap: 15px;
  color: var(--dept-color) !important;
  border-bottom-color: var(--dept-color) !important;
}

.department-card-v2:hover .card-link i {
  transform: translateX(8px) scale(1.2);
}

/* Background Highlight for Cards */
.department-card-v2::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, var(--dept-color-light) 0%, transparent 70%) !important;
  opacity: 0;
  transition: opacity 0.6s ease;
  z-index: -1;
  pointer-events: none;
}

.department-card-v2:hover::after {
  opacity: 0.4;
}

/* Legacy category styles for backward compatibility - Academic Styling */
.categories {
  padding: 60px 0;
  background: linear-gradient(135deg, #f8f6f0 0%, #f0ede5 100%);
  font-family: 'Georgia', 'Times New Roman', serif;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-top: 40px;
}

.category-card {
  background: linear-gradient(135deg, #ffffff 0%, #faf9f7 100%);
  border-radius: 0;
  border: 2px solid #8B0000;
  padding: 32px 24px;
  text-align: center;
  box-shadow: 0 10px 40px rgba(139, 0, 0, 0.15);
  transition: all 0.3s cubic-bezier(0.23, 1, 0.32, 1);
  min-height: 160px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.category-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
    repeating-linear-gradient(45deg,
      transparent,
      transparent 15px,
      rgba(139, 0, 0, 0.02) 15px,
      rgba(139, 0, 0, 0.02) 16px);
  pointer-events: none;
  z-index: 0;
}

.category-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 25px 70px rgba(139, 0, 0, 0.25);
  border-color: #D4AF37;
}

.category-icon {
  font-size: 2.5rem;
  color: #8B0000;
  margin-bottom: 16px;
  position: relative;
  z-index: 2;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.category-description {
  margin-bottom: 16px;
  color: #5C0000;
  font-weight: 600;
  font-family: 'Georgia', 'Times New Roman', serif;
  font-size: 1rem;
  line-height: 1.5;
  position: relative;
  z-index: 2;
}

.browse-button {
  display: inline-block;
  padding: 10px 20px;
  background: linear-gradient(135deg, #8B0000 0%, #A52A2A 100%);
  color: #ffffff;
  border-radius: 0;
  border: 2px solid #8B0000;
  font-weight: 700;
  font-family: 'Georgia', 'Times New Roman', serif;
  transition: all 0.3s ease;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 12px rgba(139, 0, 0, 0.2);
  position: relative;
  z-index: 2;
}

.browse-button:hover {
  background: linear-gradient(135deg, #A52A2A 0%, #8B0000 100%);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(139, 0, 0, 0.3);
}

/* Resources Section */
.resources {
  padding: 60px 0;
  background-color: var(--lighter-gray);
}

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

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

.resources-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.resource-card {
  background-color: var(--card-bg);
  border-radius: 8px;
  padding: 30px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  border: 1px solid var(--border-color);
}

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

.resource-card h3 {
  font-size: 1.4rem;
  margin-bottom: 15px;
  color: var(--text-primary);
}

.resource-card p {
  margin-bottom: 20px;
  color: var(--text-secondary);
}

.resource-button {
  display: inline-block;
  padding: 8px 20px;
  background-color: var(--primary-color);
  color: var(--white);
  border-radius: 4px;
  font-weight: 500;
  transition: var(--transition);
}

.resource-button:hover {
  background-color: var(--primary-medium);
  transform: translateY(-2px);
}

/* Footer Styles */
.main-footer {
  background-color: var(--footer-bg);
  color: var(--footer-text);
  padding: 60px 0 20px;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-section h3 {
  font-size: 1.2rem;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.footer-section h3::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 40px;
  height: 2px;
  background-color: var(--primary-color);
}

.footer-section p {
  color: #ccc;
  font-size: 0.9rem;
}

.footer-section ul li {
  margin-bottom: 10px;
}

.footer-section ul li a {
  color: #ccc;
  font-size: 0.9rem;
}

.footer-section ul li a:hover {
  color: var(--primary-color);
  padding-left: 5px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.footer-bottom p {
  font-size: 0.9rem;
  color: #aaa;
}

.footer-links a {
  margin-left: 20px;
  font-size: 0.9rem;
  color: #aaa;
}

.footer-links a:hover {
  color: var(--primary-color);
}

/* Responsive Styles */
@media (max-width: 768px) {
  .filter-container {
    flex-direction: column;
    align-items: center;
  }

  .filter-dropdown {
    width: 100%;
    max-width: 400px;
    margin-bottom: 10px;
  }

  .main-header .container,
  .header-inner {
    flex-direction: column;
    height: auto;
    padding: 15px;
  }

  .logo-container {
    margin-bottom: 15px;
  }

  .main-nav ul,
  .nav-center {
    flex-direction: column;
    align-items: center;
  }

  .main-nav ul li,
  .nav-center li {
    margin: 8px 0;
  }

  .auth-buttons {
    margin-top: 15px;
  }

  .footer-bottom {
    flex-direction: column;
  }

  .footer-links {
    margin-top: 10px;
  }

  .footer-links a {
    margin: 0 10px;
  }
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.05);
  }

  100% {
    transform: scale(1);
  }
}

@keyframes shake {

  0%,
  100% {
    transform: translateX(0);
  }

  20%,
  60% {
    transform: translateX(-5px);
  }

  40%,
  80% {
    transform: translateX(5px);
  }
}

@keyframes glow {
  0% {
    box-shadow: 0 0 3px rgba(139, 0, 0, 0.3);
  }

  50% {
    box-shadow: 0 0 15px rgba(139, 0, 0, 0.5);
  }

  100% {
    box-shadow: 0 0 3px rgba(139, 0, 0, 0.3);
  }
}

.shake {
  animation: shake 0.5s ease-in-out;
}

.pulse {
  animation: pulse 1s infinite;
}

.option-changed {
  animation: glow 0.5s ease-in-out;
}

.section-title,
.section-subtitle {
  animation: fadeIn 0.8s ease forwards;
}

.thesis-card,
.category-card,
.resource-card {
  animation: fadeIn 0.8s ease forwards;
}

/* Custom dropdown styling enhanced */
.filter-dropdown select.changed {
  background-color: var(--primary-light);
  color: var(--primary-color);
}

/* Search input enhancement */
.search-input:focus {
  border-left: 3px solid var(--primary-color);
  transition: border-left 0.3s ease;
}

/* Button hover effects */
.search-button:hover {
  background-color: var(--primary-medium);
  letter-spacing: 0.5px;
}

.resource-button:hover {
  background-color: var(--primary-medium);
  transform: translateY(-2px);
  letter-spacing: 0.5px;
}

/* Add animation delay to cards for cascading effect */
.thesis-card:nth-child(1),
.category-card:nth-child(1),
.resource-card:nth-child(1) {
  animation-delay: 0.1s;
}

.thesis-card:nth-child(2),
.category-card:nth-child(2),
.resource-card:nth-child(2) {
  animation-delay: 0.2s;
}

.thesis-card:nth-child(3),
.category-card:nth-child(3) {
  animation-delay: 0.3s;
}

.thesis-card:nth-child(4),
.category-card:nth-child(4) {
  animation-delay: 0.4s;
}

.thesis-card:nth-child(5),
.category-card:nth-child(5) {
  animation-delay: 0.5s;
}

.thesis-card:nth-child(6),
.category-card:nth-child(6) {
  animation-delay: 0.6s;
}

.button-spacing {
  margin-left: 10px;
  /* Adjust the value as needed */
}

/* --- CONSISTENT HEADER STYLES WITH SUBMISSION PORTAL --- */
.main-header,
.redesigned-header {
  background: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  position: fixed;
  width: 100%;
  top: 0;
  left: 0;
  z-index: 1000;
  padding: 0;
}

.header-inner,
.main-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  height: 70px;
}

.logo-container {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-container h1 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-color);
  letter-spacing: -0.5px;
  text-transform: uppercase;
}

.header-flex-center {
  flex: 1 1 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.main-nav ul,
.nav-center {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  color: var(--text-primary);
  font-weight: 500;
  font-size: 1.05rem;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary-color);
  border-bottom: 2px solid var(--primary-color);
}

.nav-right,
.auth-buttons,
.header-buttons {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
}

.dashboard-btn,
.logout-btn,
.login-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  padding: 8px 20px;
  height: 40px;
  min-width: 120px;
  box-sizing: border-box;
  border-radius: 6px;
  border: 1.5px solid var(--primary-color);
  background: transparent;
  color: var(--primary-color);
  font-weight: 600;
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  margin-left: 10px;
  cursor: pointer;
  text-decoration: none;
}

.dashboard-btn:hover,
.logout-btn:hover,
.login-btn:hover {
  background: var(--primary-light);
  color: var(--primary-color);
  transform: translateY(-1px);
}

/* Remove welcome user styles from main header */
.user-welcome {
  display: none !important;
}

@media (max-width: 900px) {

  .header-inner,
  .main-header .container {
    padding: 0 12px;
  }

  .main-nav ul,
  .nav-center {
    gap: 18px;
  }
}

@media (max-width: 700px) {

  .header-inner,
  .main-header .container {
    flex-direction: column;
    height: auto;
    padding: 8px 4px;
    gap: 8px;
  }

  .logo-container {
    margin-bottom: 6px;
  }

  .main-nav ul,
  .nav-center {
    gap: 10px;
    font-size: 0.98rem;
  }
}

/* --- END CONSISTENT HEADER STYLES --- */

/* Main Header Styles - Unique Scope */
.main-header {
  background: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  position: fixed;
  width: 100%;
  top: 0;
  left: 0;
  z-index: 1000;
  padding: 0;
}

.main-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  height: 70px;
}

.main-header .logo-container {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
}

.main-header .logo-image {
  width: 50px;
  height: 50px;
  object-fit: contain;
  border-radius: 50%;
  border: 2px solid var(--luxury-gold);
  box-shadow: 0 4px 12px rgba(128, 0, 0, 0.2);
  transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1), border-color 0.3s ease;
}

.main-header .logo-image:hover {
  transform: rotate(10deg) scale(1.08);
  border-color: var(--primary-color);
}

.main-header .logo-container h1 {
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--primary-color);
  letter-spacing: 1px;
}

.main-header .header-flex-center {
  flex: 1 1 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.main-header .main-nav ul,
.main-header .nav-center {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.main-header .nav-link {
  color: var(--text-primary);
  font-weight: 500;
  font-size: 1.05rem;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.main-header .nav-link:hover,
.main-header .nav-link.active {
  color: var(--primary-color);
  border-bottom: 2px solid var(--primary-color);
}

.main-header .nav-right,
.main-header .auth-buttons,
.main-header .header-buttons {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
}

.main-header .dashboard-btn,
.main-header .logout-btn,
.main-header .login-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  padding: 8px 20px;
  height: 40px;
  min-width: 120px;
  box-sizing: border-box;
  border-radius: 5px;
  border: 1.5px solid var(--primary-color);
  background: transparent;
  color: var(--primary-color);
  font-weight: 600;
  transition: background 0.2s, color 0.2s;
  margin-left: 10px;
  cursor: pointer;
}

.main-header .dashboard-btn:hover,
.main-header .logout-btn:hover,
.main-header .login-btn:hover {
  background: var(--primary-light);
  color: var(--primary-dark);
}

/* User Dropdown Styles */
.user-dropdown {
  position: relative;
  margin-left: 15px;
}

.user-dropdown-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  background: transparent;
  border: 1px solid var(--border-color);
  padding: 6px 14px;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.2s ease;
  color: var(--text-primary);
  font-family: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.user-dropdown-toggle:hover {
  background: var(--bg-tertiary);
  border-color: var(--primary-color);
}

.user-avatar-mini {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--white);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.dropdown-arrow {
  font-size: 0.8rem;
  opacity: 0.6;
  transition: transform 0.2s ease;
}

.user-dropdown.active .dropdown-arrow {
  transform: rotate(180deg);
}

.user-dropdown-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: 240px;
  background: var(--card-bg);
  border-radius: 12px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
  border: 1px solid var(--border-color);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  z-index: 1100;
}

.user-dropdown-menu.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-header {
  padding: 12px 16px 8px;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 8px;
}

.dropdown-user-role {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--primary-color);
  font-weight: 700;
  margin: 0;
}

.dropdown-item {
  display: flex !important;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.95rem;
  border-radius: 8px;
  transition: all 0.2s ease;
  font-weight: 500;
  margin-bottom: 2px;
  border-bottom: none !important;
}

.dropdown-item i {
  width: 20px;
  text-align: center;
  color: var(--primary-color);
  opacity: 0.8;
}

.dropdown-item:hover {
  background: var(--primary-light);
  color: var(--primary-dark) !important;
  transform: translateX(5px);
}

.dropdown-divider {
  height: 1px;
  background: var(--border-color);
  margin: 8px 0;
}

.logout-form {
  padding: 0;
  margin: 0;
  display: block;
}

.logout-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  background: transparent;
  border: none;
  color: #d32f2f;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 8px;
  transition: all 0.2s ease;
  text-align: left;
}

.logout-item:hover {
  background: #ffebee;
}

.logout-item i {
  width: 20px;
  text-align: center;
}

/* Redesign end */

/* Remove welcome user styles from main header */
.main-header .user-welcome {
  display: none !important;
}

@media (max-width: 900px) {
  .main-header-inner {
    padding: 0 12px;
  }

  .main-header .main-nav ul,
  .main-header .nav-center {
    gap: 18px;
  }
}

@media (max-width: 700px) {
  .main-header-inner {
    flex-direction: column;
    height: auto;
    padding: 8px 4px;
    gap: 8px;
  }

  .main-header .logo-container {
    margin-bottom: 6px;
  }

  .main-header .main-nav ul,
  .main-header .nav-center {
    gap: 10px;
    font-size: 0.98rem;
  }
}

/* Theme transition for smooth switching */
* {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Force white text on dark backgrounds for better readability */
[data-theme="dark"] .view-button,
[data-theme="dark"] .thesis-view-button,
[data-theme="dark"] .chip,
[data-theme="dark"] .keyword-chip {
  color: #ffffff !important;
}

/* End Main Header Styles */

/* Thesis Card Button Styles - Consistent with Category Pages */
.thesis-view-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
  border: none;
  cursor: pointer;
}

.thesis-view-button {
  background: var(--primary-color);
  color: #ffffff !important;
}

.thesis-view-button:hover {
  background: var(--primary-medium);
  color: #ffffff !important;
  transform: translateY(-1px);
}

/* Thesis Detail Page Styles */
.thesis-actions {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.view-button,
.preview-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
  border: 2px solid transparent;
  cursor: pointer;
  text-align: center;
  justify-content: center;
}

.view-button {
  background: var(--primary-color);
  color: #ffffff !important;
  border-color: var(--primary-color);
}

.view-button:hover {
  background: var(--white);
  color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.preview-button {
  background: var(--primary-light);
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.preview-button:hover {
  background: var(--primary-color);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.restricted-access {
  display: flex;
  flex-direction: column;
  gap: 15px;
  padding: 20px;
  background: var(--lighter-gray);
  border-radius: 12px;
  border: 2px solid var(--light-gray);
}

.login-required {
  text-align: center;
}

.restriction-notice {
  color: var(--medium-gray);
  font-size: 0.95rem;
  line-height: 1.5;
  margin: 0;
}

.restriction-notice i {
  color: var(--primary-color);
  margin-right: 8px;
}

.login-link {
  color: var(--primary-color);
  font-weight: 600;
  text-decoration: underline;
  transition: var(--transition);
}

.login-link:hover {
  color: var(--dark-gray);
  text-decoration: none;
}

.no-file {
  color: var(--medium-gray);
  font-style: italic;
  text-align: center;
  padding: 20px;
  background: var(--lighter-gray);
  border-radius: 8px;
  border: 1px dashed var(--light-gray);
}

@media (max-width: 768px) {
  .thesis-actions {
    gap: 12px;
  }

  .view-button,
  .preview-button {
    padding: 10px 20px;
    font-size: 0.95rem;
  }

  .restricted-access {
    padding: 15px;
  }

  .restriction-notice {
    font-size: 0.9rem;
  }
}


/* Co-Authors Styling */
.thesis-authors {
  margin: 1rem 0;
  padding: 1rem;
  background: var(--bg-secondary);
  border-radius: 8px;
  border-left: 4px solid var(--primary-color);
}

.thesis-authors .main-author {
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.thesis-authors .co-authors {
  margin-top: 0.5rem;
}

.thesis-authors .co-authors strong {
  color: var(--text-primary);
  font-size: 1rem;
}

.coauthor-list {
  list-style: none;
  padding: 0;
  margin: 0.5rem 0 0 0;
}

.coauthor-list li {
  padding: 0.25rem 0;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-color);
}

.coauthor-list li:last-child {
  border-bottom: none;
}

.coauthor-list li:before {
  content: "•";
  color: var(--primary-color);
  font-weight: bold;
  margin-right: 0.5rem;
}

/* Profile Card Page */
.profile-card-page {
  background: linear-gradient(135deg, #f8f6f0 0%, #f2eee4 100%);
  padding: 60px 20px 80px;
}

.profile-card-page .container {
  max-width: 900px;
  margin: 0 auto;
}

.profile-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: 18px;
  padding: 32px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.08);
}

.profile-card-header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 28px;
}

.profile-avatar {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  background: var(--primary-light);
  color: var(--primary-color);
  font-size: 1.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  text-transform: uppercase;
}

.profile-card-title h1 {
  margin: 0;
  font-size: 1.9rem;
  color: var(--primary-dark);
}

.profile-card-title span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.95rem;
  color: var(--medium-gray);
}

.profile-card-body {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}

.profile-info-block {
  padding: 16px 18px;
  border: 1px solid var(--border-color);
  border-radius: 14px;
  background: #fffdf9;
}

.profile-info-block label {
  font-size: 0.85rem;
  color: var(--medium-gray);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.profile-info-block p {
  margin: 6px 0 0;
  font-size: 1.05rem;
  color: var(--text-primary);
  font-weight: 600;
  word-break: break-word;
}

.profile-card-stats {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.profile-stat {
  flex: 1 1 180px;
  border-radius: 14px;
  padding: 18px;
  background: linear-gradient(135deg, rgba(139, 0, 0, 0.08), rgba(212, 175, 55, 0.1));
  border: 1px solid rgba(139, 0, 0, 0.2);
}

.profile-stat span {
  font-size: 0.85rem;
  color: var(--medium-gray);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.profile-stat strong {
  display: block;
  margin-top: 6px;
  font-size: 1.6rem;
  color: var(--primary-dark);
}

.profile-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.profile-card-actions .btn,
.profile-card-actions .dashboard-btn {
  flex: 1 1 200px;
  justify-content: center;
}

@media (max-width: 600px) {
  .profile-card {
    padding: 24px;
  }

  .profile-card-header {
    flex-direction: column;
    text-align: center;
  }

  .profile-card-actions .btn,
  .profile-card-actions .dashboard-btn {
    flex: 1 1 100%;
  }
}

/* Categories page co-author styling */
.cat-thesis-item-authors {
  margin: 0.5rem 0;
}

.cat-thesis-item-authors .author-label {
  font-weight: 600;
  color: var(--text-primary);
  margin-right: 0.5rem;
}

.cat-thesis-item-authors .coauthor-list {
  display: inline;
  list-style: none;
  padding: 0;
  margin: 0;
}

.cat-thesis-item-authors .coauthor-list li {
  display: inline;
  margin-right: 0.5rem;
  padding: 0;
  border: none;
}

.cat-thesis-item-authors .coauthor-list li:before {
  content: "";
}

.cat-thesis-item-authors .coauthor-list li:after {
  content: ", ";
}

.cat-thesis-item-authors .coauthor-list li:last-child:after {
  content: "";
}

.cat-thesis-item-authors .more-coauthors {
  color: var(--primary-color);
  text-decoration: none;
  font-size: 0.9rem;
  font-style: italic;
}

.cat-thesis-item-authors .more-coauthors:hover {
  text-decoration: underline;
}

/* Responsive co-author styling */
@media (max-width: 768px) {
  .thesis-authors {
    margin: 0.5rem 0;
    padding: 0.75rem;
  }
}

/* Deep Search Styling */
.search-input-group {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 0.5rem;
  flex-wrap: nowrap;
  padding: 0;
  background: transparent;
  border-radius: 0;
  border: none;
  box-shadow: none;
  width: 100%;
  max-width: 100%;
}

/* Search Controls Section */
.search-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  border-radius: 0 0 8px 8px;
  gap: 12px;
  flex-wrap: wrap;
}

.search-mode-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0;
  background: var(--bg-primary);
  border-radius: 6px;
  padding: 2px;
  border: 1px solid var(--border-color);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Make the categories search input a bit smaller */
.search-form .search-input {
  height: 40px;
  font-size: 0.95rem;
  padding: 0 12px;
}

.search-form .search-button {
  height: 40px;
  padding: 0 14px;
  font-size: 0.95rem;
}

.search-mode-label {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

/* hide native radios; style the pill text instead */
.search-mode-label input[type="radio"] {
  display: none;
}

/* base pill look */
.search-mode-text {
  display: inline-block;
  padding: 6px 12px;
  border: none;
  border-radius: 4px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  background: transparent;
  transition: var(--transition);
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
}

/* hover */
.search-mode-label:hover .search-mode-text {
  border-color: var(--primary-medium);
}

/* checked state */
.search-mode-label input[type="radio"]:checked+.search-mode-text {
  background: var(--primary-color);
  color: #fff;
  border: none;
  box-shadow: 0 1px 3px rgba(139, 0, 0, 0.2);
}

.deep-search-info {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--primary-light);
  border-radius: 6px;
  border-left: 3px solid var(--primary-color);
  font-size: 0.9rem;
  color: var(--text-primary);
  max-width: 100%;
  flex: 1;
  min-width: 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.deep-search-info i {
  color: var(--primary-color);
}

/* Deep Search Results */
.deep-search-results {
  margin-top: 1rem;
  padding: 1rem;
  background: var(--bg-secondary);
  border-radius: 8px;
  border-left: 4px solid var(--primary-color);
}

.deep-search-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--text-primary);
}

.deep-search-header i {
  color: var(--primary-color);
}

.deep-search-title {
  font-size: 0.9rem;
}

.deep-search-count {
  background: var(--primary-color);
  color: white;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
}

.deep-search-context {
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text-secondary);
  background: var(--bg-primary);
  padding: 0.75rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
}

.deep-search-context mark {
  background: var(--primary-color);
  color: white;
  padding: 0.1rem 0.2rem;
  border-radius: 3px;
  font-weight: 600;
}

/* Page-aware snippet list */
.deep-search-snippets {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.deep-search-snippets li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: start;
}

.deep-search-page {
  background: var(--primary-color);
  color: #fff;
  font-weight: 600;
  font-size: 0.8rem;
  border-radius: 12px;
  padding: 2px 8px;
  height: fit-content;
}

.deep-search-snippet {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 6px 8px;
  color: var(--text-secondary);
}

/* Responsive deep search styling */
@media (max-width: 768px) {
  .search-form {
    border-radius: 6px;
  }

  .search-input-row {
    border-radius: 6px 6px 0 0;
  }

  .search-controls {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 10px 12px;
  }

  .search-mode-toggle {
    width: 100%;
    justify-content: center;
  }

  .search-mode-label {
    flex: 1;
    text-align: center;
  }

  .deep-search-info {
    font-size: 0.85rem;
    padding: 6px 10px;
  }

  .deep-search-results {
    margin-top: 0.75rem;
    padding: 0.75rem;
  }

  .deep-search-context {
    padding: 0.5rem;
    font-size: 0.85rem;
  }
}

/* --- Global Logo Consistency --- */
.footer-logo {
  width: 60px;
  height: 60px;
  object-fit: contain;
  margin-bottom: 12px;
  transition: transform 0.3s ease;
}

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

.vision-seal img {
  width: 140px;
  height: 140px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.1));
  transition: transform 0.4s ease;
}

.vision-seal img:hover {
  transform: scale(1.05) rotate(2deg);
}

/* ============================================================
   University Banner / CTA Section
   ============================================================ */
.university-banner {
  position: relative;
  background: linear-gradient(135deg, #4a0000 0%, #800000 40%, #a31d23 70%, #2d0000 100%);
  padding: 90px 0;
  overflow: hidden;
  text-align: center;
}

/* Decorative animated orbs */
.university-banner::before {
  content: '';
  position: absolute;
  top: -80px;
  left: -80px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(197, 179, 88, 0.18) 0%, transparent 70%);
  animation: bannerOrb1 12s ease-in-out infinite alternate;
  pointer-events: none;
}

.university-banner::after {
  content: '';
  position: absolute;
  bottom: -60px;
  right: -60px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
  animation: bannerOrb2 10s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes bannerOrb1 {
  from {
    transform: translate(0, 0) scale(1);
  }

  to {
    transform: translate(40px, 30px) scale(1.15);
  }
}

@keyframes bannerOrb2 {
  from {
    transform: translate(0, 0) scale(1);
  }

  to {
    transform: translate(-30px, -20px) scale(1.1);
  }
}

.university-banner .container {
  position: relative;
  z-index: 2;
}

.banner-content {
  max-width: 760px;
  margin: 0 auto;
}

/* Gold topline accent */
.banner-content::before {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--luxury-gold), #e8d07a, var(--luxury-gold));
  margin: 0 auto 28px;
  border-radius: 2px;
  box-shadow: 0 0 12px rgba(197, 179, 88, 0.5);
}

.banner-content h2 {
  font-family: 'Playfair Display', serif;
  font-size: 2.6rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 18px;
  line-height: 1.2;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
  letter-spacing: 0.3px;
}

.banner-content p {
  font-size: 1.15rem;
  color: rgba(255, 255, 255, 0.82);
  margin-bottom: 40px;
  line-height: 1.7;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.banner-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Primary CTA — white fill */
.btn-primary-white {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: #ffffff;
  color: #800000;
  font-weight: 700;
  font-size: 0.95rem;
  border-radius: 50px;
  text-decoration: none;
  letter-spacing: 0.4px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25), 0 0 0 0 rgba(255, 255, 255, 0.4);
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
  border: 2px solid #ffffff;
}

.btn-primary-white:hover {
  background: #fff5f5;
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3), 0 0 0 4px rgba(255, 255, 255, 0.15);
}

/* Outline CTA — ghost style */
.btn-outline-white {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: transparent;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 50px;
  text-decoration: none;
  letter-spacing: 0.4px;
  border: 2px solid rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(4px);
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
}

.btn-outline-white:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.9);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

/* Responsive */
@media (max-width: 600px) {
  .banner-content h2 {
    font-size: 1.8rem;
  }

  .banner-content p {
    font-size: 1rem;
  }

  .banner-actions {
    flex-direction: column;
    align-items: center;
  }

  .btn-primary-white,
  .btn-outline-white {
    width: 100%;
    max-width: 300px;
    justify-content: center;
  }
}