:root {
  /* Professional University Palette */
  --primary: #002147;
  /* Oxford Blue */
  --primary-light: #1a365d;
  --accent: #b45309;
  /* Muted Gold/Bronze for contrast */
  --accent-hover: #92400e;
  --accent-blue: #0056b3;
  /* Professional Blue */

  --background: #f1f5f9;
  /* Light Gray/Slate 100 */
  --surface: #ffffff;

  --text-main: #1e293b;
  /* Slate 800 */
  --text-muted: #64748b;
  /* Slate 500 */

  --border: #cbd5e1;
  /* Slate 300 - Higher contrast */
  --border-focus: #002147;

  --success: #15803d;
  /* Green 700 */
  --error: #b91c1c;
  /* Red 700 */
  --warning: #b45309;
  /* Amber 700 */

  /* Spacing & Radius */
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 8px;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

  /* Transitions */
  --transition: all 0.2s ease-in-out;
}

/* Reset & Base */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background-color: var(--background);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding-top: 90px;
  /* Compensate for fixed header */
}

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

a:hover {
  color: var(--primary);
  text-decoration: underline;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--primary);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

h1 {
  font-size: 1.875rem;
}

h2 {
  font-size: 1.5rem;
}

h3 {
  font-size: 1.25rem;
}

/* Layout */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.main-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 2rem;
  margin: 2rem 0;
}

@media (max-width: 900px) {
  .main-layout {
    grid-template-columns: 1fr;
  }
}

/* Header */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 0.75rem 0;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.logo {
  height: 48px;
  width: auto;
}

.brand-text h1 {
  font-size: 1.25rem;
  margin: 0;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.brand-text p {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.user-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-size: 0.9rem;
  font-weight: 500;
}

.user-nav span {
  color: var(--text-main);
}

/* Cards & Sections */
section {
  background: var(--surface);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  padding: 1.5rem;
  margin-bottom: 2rem;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--background);
}

.section-header h2 {
  margin: 0;
  font-size: 1.25rem;
  color: var(--primary);
}

/* Rotator */
.rotator {
  position: relative;
  height: 200px;
  /* Fixed height for rotation */
  overflow: hidden;
  background: var(--background);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  padding: 1rem;
}

.rotator-item {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  padding: 1rem;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.5s ease, transform 0.5s ease;
  font-size: 0.95rem;
  color: var(--text-main);
  overflow-y: auto;
  /* Allow scrolling */
  scrollbar-width: none;
  /* Firefox */
  white-space: pre-wrap;
  /* Preserve line breaks and spaces */
}

.rotator-item::-webkit-scrollbar {
  display: none;
  /* Chrome/Safari */
}

.rotator-item.active {
  opacity: 1;
  transform: translateY(0);
  z-index: 1;
}

/* Stat Cards (New Professional Design) */
/* Stat Cards (New Professional Design) */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  /* Force 4 columns */
  gap: 1rem;
  /* Reduced gap */
  margin: 1.5rem 0;
}

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

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

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1rem;
  /* Reduced padding */
  display: flex;
  align-items: center;
  /* Center vertically */
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  /* Slightly thinner accent */
  height: 100%;
  background: var(--primary);
}

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

.stat-content h3 {
  font-size: 0.75rem;
  /* Smaller label */
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
  font-weight: 600;
}

.stat-value {
  font-size: 1.5rem;
  /* Smaller value */
  font-weight: 700;
  color: var(--primary);
  line-height: 1;
}

.stat-icon {
  width: 40px;
  /* Smaller icon container */
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--background);
  border-radius: var(--radius-sm);
  color: var(--primary);
}

.stat-icon svg {
  width: 20px;
  /* Smaller icon */
  height: 20px;
  fill: currentColor;
}

/* Tables */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th {
  background: var(--background);
  color: var(--primary);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  padding: 1rem;
  text-align: left;
  border-bottom: 2px solid var(--border);
}

td {
  padding: 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-main);
  font-size: 0.9rem;
}

tr:last-child td {
  border-bottom: none;
}

tr:hover td {
  background: #f8fafc;
}

/* Forms */
.form-group {
  margin-bottom: 1.5rem;
}

label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
input[type="date"],
select,
textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text-main);
  font-size: 0.95rem;
  transition: var(--transition);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.05);
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 33, 71, 0.1);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
  gap: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.025em;
}

.btn.small {
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
}

.btn-primary {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

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

/* Alerts */
.alert {
  padding: 1rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-left: 4px solid;
}

.alert-error {
  background: #fef2f2;
  border-color: var(--error);
  color: var(--error);
}

.alert-info {
  background: #eff6ff;
  border-color: var(--accent-blue);
  color: var(--accent-blue);
}

/* Contact List */
.contact-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-item {
  display: flex;
  align-items: center;
  /* Align vertically center */
  padding: 1rem;
  background: var(--background);
  border-radius: var(--radius-sm);
  transition: var(--transition);
  border: 1px solid transparent;
}

.contact-item:hover {
  background: white;
  border-color: var(--border);
  box-shadow: var(--shadow-sm);
}

.contact-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: white;
  border-radius: 50%;
  color: var(--primary);
  margin-right: 1rem;
  /* Space between icon and text */
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
  /* Prevent icon from shrinking */
}

.contact-info {
  display: flex;
  flex-direction: column;
}

.contact-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.1rem;
}

.contact-value {
  color: var(--text-main);
  font-weight: 500;
  font-size: 0.95rem;
}

.contact-value:hover {
  color: var(--primary);
  text-decoration: none;
}

/* Footer */
.site-footer {
  margin-top: auto;
  background: var(--primary);
  color: rgba(255, 255, 255, 0.7);
  padding: 2rem 0;
  text-align: center;
  font-size: 0.85rem;
}

/* Utilities */
.w-full {
  width: 100%;
}

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

.mt-4 {
  margin-top: 1rem;
}

.badge {
  display: inline-block;
  padding: 0.25em 0.6em;
  font-size: 0.75em;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  vertical-align: baseline;
  border-radius: 0.25rem;
}