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

/* =============================================
   CAMPUS SERVICE PORTAL — DESIGN SYSTEM
   Professional Dark Glassmorphism Theme
   ============================================= */

:root {
  /* Palette */
  --primary: #ff5f6d;
  --primary-light: #ff8a5b;
  --primary-dark: #ff3d7a;
  --secondary: #00c6ff;
  --accent: #8b5cf6;
  --success: #22c55e;
  --warning: #facc15;
  --danger: #ef4444;

  /* Background layers */
  --bg-base: #0f1117;
  --bg-surface: #1a1d27;
  --bg-card: rgba(255, 255, 255, 0.06);
  --bg-card-hover: rgba(255, 255, 255, 0.10);
  --bg-glass: rgba(255, 255, 255, 0.04);

  /* Text */
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  /* Borders */
  --border: rgba(255, 255, 255, 0.08);
  --border-focus: rgba(99, 102, 241, 0.6);

  /* Sidebar */
  --sidebar-w: 260px;
  --sidebar-bg: #111827;

  /* Radius & Shadow */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 30px rgba(99, 102, 241, 0.25);

  /* Transitions */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --duration: 0.25s;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ─── Scrollbar ─── */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-base);
}

::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary);
}

/* =============================================
   AUTH PAGES (login / register)
   ============================================= */

.auth-bg {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background:
    radial-gradient(ellipse 80% 60% at 20% 10%, rgba(99, 102, 241, 0.18) 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 80% 90%, rgba(168, 85, 247, 0.14) 0%, transparent 60%),
    var(--bg-base);
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--bg-card);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 44px 40px;
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  animation: slideUp 0.5s var(--ease) both;
}

.auth-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 32px;
}

.auth-logo .logo-icon {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.4);
  flex-shrink: 0;
}

.auth-logo .logo-text {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.auth-logo .logo-text span {
  color: var(--primary-light);
}

.auth-title {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-primary);
  text-align: center;
  margin-bottom: 6px;
  letter-spacing: -0.03em;
}

.auth-subtitle {
  font-size: 0.875rem;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 28px;
}

body.landing-page {
  background:
    radial-gradient(circle at top left, rgba(255, 95, 109, 0.34), transparent 25%),
    radial-gradient(circle at 80% 10%, rgba(251, 191, 36, 0.28), transparent 20%),
    radial-gradient(circle at right center, rgba(34, 197, 94, 0.24), transparent 30%),
    radial-gradient(circle at bottom left, rgba(139, 92, 246, 0.26), transparent 28%),
    linear-gradient(135deg, #0f1117, #191326 45%, #111827);
}

.landing-shell {
  min-height: 100vh;
  width: 100%;
  padding: 18px;
}

.brand-strip {
  position: absolute;
  top: 24px;
  left: 24px;
  z-index: 2;
}

.landing-hero {
  min-height: calc(100vh - 36px);
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  align-items: center;
  padding: 88px 28px 28px;
  border-radius: 32px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background:
    linear-gradient(135deg, rgba(255, 95, 109, 0.14), rgba(0, 198, 255, 0.10) 42%, rgba(139, 92, 246, 0.13)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03));
  box-shadow: 0 16px 48px rgba(255, 95, 109, 0.16), 0 0 0 1px rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.landing-copy {
  max-width: 720px;
}

.hero-badge {
  display: inline-block;
  margin-bottom: 18px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.16);
  color: var(--primary-light);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.landing-title {
  font-size: clamp(2.2rem, 4vw, 4.2rem);
  line-height: 1.05;
  letter-spacing: -0.05em;
  margin-bottom: 18px;
  color: var(--text-primary);
}

.landing-subtitle {
  max-width: 680px;
  font-size: 1.04rem;
  color: var(--text-secondary);
  margin-bottom: 28px;
}

.cta-row {
  display: flex;
  gap: 14px;
  margin: 28px 0 32px;
}

.cta-row .btn {
  min-width: 150px;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.feature-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
  text-align: left;
}

.feature-icon {
  font-size: 1.35rem;
  margin-bottom: 10px;
}

.feature-card h3 {
  font-size: 0.95rem;
  margin-bottom: 6px;
  color: var(--text-primary);
}

.feature-card p {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.landing-panel {
  display: grid;
  gap: 20px;
}

.panel-card {
  padding: 24px;
  border-radius: 24px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: var(--shadow-md);
}

.panel-glow {
  background:
    linear-gradient(135deg, rgba(255, 95, 109, 0.24), rgba(0, 198, 255, 0.18), rgba(139, 92, 246, 0.18)),
    rgba(255, 255, 255, 0.05);
}

.panel-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.panel-top strong {
  color: var(--text-primary);
  font-size: 1rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.stats-grid span,
.panel-list li {
  color: var(--text-secondary);
}

.stats-grid strong {
  display: block;
  margin-top: 6px;
  font-size: 1.35rem;
  color: var(--text-primary);
}

.panel-card h3 {
  margin-bottom: 14px;
  color: var(--text-primary);
}

.panel-list {
  padding-left: 18px;
}

.panel-list li {
  margin-bottom: 10px;
  line-height: 1.5;
}

@media (max-width: 980px) {
  .landing-hero {
    grid-template-columns: 1fr;
    min-height: auto;
  }
}

@media (max-width: 700px) {
  .landing-shell {
    padding: 10px;
  }

  .landing-hero {
    padding: 18px;
  }

  .cta-row,
  .feature-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .cta-row {
    flex-direction: column;
  }

  .cta-row .btn {
    width: 100%;
  }
}

/* ─── Form Fields ─── */
.form-group {
  margin-bottom: 18px;
  position: relative;
}

.form-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 7px;
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  transition: border-color var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease),
    background var(--duration) var(--ease);
  outline: none;
  appearance: none;
}

.form-control::placeholder {
  color: var(--text-muted);
}

.form-control:focus {
  border-color: var(--border-focus);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

select.form-control option {
  background: var(--bg-surface);
  color: var(--text-primary);
}

textarea.form-control {
  resize: vertical;
  min-height: 100px;
}

/* ─── Buttons ─── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border: none;
  border-radius: var(--radius-md);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--duration) var(--ease);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 28px rgba(99, 102, 241, 0.55);
  filter: brightness(1.1);
}

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

.btn-full {
  width: 100%;
}

.btn-success {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #fff;
}

.btn-danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #fff;
  padding: 6px 14px;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
}

.btn-warning {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #fff;
  padding: 6px 14px;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
}

.auth-footer {
  text-align: center;
  margin-top: 20px;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.auth-footer a {
  color: var(--primary-light);
  text-decoration: none;
  font-weight: 600;
}

.auth-footer a:hover {
  text-decoration: underline;
}

/* =============================================
   SIDEBAR + DASHBOARD LAYOUT
   ============================================= */

.app-layout {
  display: flex;
  min-height: 100vh;
}

/* ─── Sidebar ─── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  z-index: 100;
  padding: 0 0 24px;
  overflow-y: auto;
  transition: width var(--duration) var(--ease);
}

.sidebar-header {
  padding: 24px 20px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}

.sidebar-logo-icon {
  width: 38px;
  height: 38px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.sidebar-brand {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.sidebar-brand span {
  color: var(--primary-light);
}

.sidebar-section {
  padding: 16px 12px 0;
  flex: 1;
}

.sidebar-section-label {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0 8px;
  margin-bottom: 6px;
  margin-top: 16px;
}

.sidebar-section-label:first-child {
  margin-top: 0;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--duration) var(--ease);
  position: relative;
  margin-bottom: 2px;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
}

.nav-item.active {
  background: rgba(99, 102, 241, 0.15);
  color: var(--primary-light);
  border: 1px solid rgba(99, 102, 241, 0.2);
}

.nav-item.active .nav-icon {
  color: var(--primary-light);
}

.nav-item.logout {
  color: #f87171;
}

.nav-item.logout:hover {
  background: rgba(239, 68, 68, 0.12);
  color: #ef4444;
}

.nav-icon {
  font-size: 1.05rem;
  width: 22px;
  text-align: center;
  flex-shrink: 0;
}

.nav-label {
  font-size: 0.88rem;
}

.sidebar-user {
  padding: 16px 20px 0;
  border-top: 1px solid var(--border);
  margin-top: auto;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user-avatar {
  width: 34px;
  height: 34px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.user-info .user-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

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

/* ─── Main Content ─── */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background:
    radial-gradient(ellipse 50% 40% at 70% 5%, rgba(99, 102, 241, 0.08) 0%, transparent 60%),
    var(--bg-base);
}

/* ─── Top Navbar ─── */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 17, 23, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 0 28px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 14px;
}

.topbar-badge {
  padding: 4px 10px;
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.25);
  border-radius: 99px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--primary-light);
}

.topbar-time {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ─── Page Inner ─── */
.page-body {
  padding: 28px;
  flex: 1;
}

.page-header {
  margin-bottom: 24px;
}

.page-header h2 {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.page-header p {
  font-size: 0.87rem;
  color: var(--text-secondary);
  margin-top: 3px;
}

/* =============================================
   STAT CARDS
   ============================================= */

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

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 22px 20px;
  display: flex;
  align-items: flex-start;
  gap: 16px;
  transition: all var(--duration) var(--ease);
  cursor: default;
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--card-color, transparent), transparent 60%);
  opacity: 0;
  transition: opacity var(--duration) var(--ease);
}

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

.stat-card:hover::before {
  opacity: 1;
}

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

.stat-icon.purple {
  background: rgba(99, 102, 241, 0.18);
}

.stat-icon.blue {
  background: rgba(14, 165, 233, 0.18);
}

.stat-icon.green {
  background: rgba(16, 185, 129, 0.18);
}

.stat-icon.amber {
  background: rgba(245, 158, 11, 0.18);
}

.stat-body {}

.stat-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.stat-value {
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.1;
  margin-top: 2px;
}

.stat-delta {
  font-size: 0.75rem;
  color: var(--success);
  margin-top: 3px;
}

/* ─── clickable dashboard cards ─── */
.dash-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}

.dash-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  cursor: pointer;
  transition: all var(--duration) var(--ease);
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  position: relative;
  overflow: hidden;
}

.dash-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--card-accent, var(--primary));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--duration) var(--ease);
}

.dash-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(255, 255, 255, 0.14);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.dash-card:hover::after {
  transform: scaleX(1);
}

.dash-card-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  background: rgba(99, 102, 241, 0.15);
}

.dash-card h3 {
  font-size: 1rem;
  font-weight: 700;
}

.dash-card p {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

/* =============================================
   PANELS & TABLES
   ============================================= */

.panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 24px;
}

.panel-header {
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.panel-header h3 {
  font-size: 1rem;
  font-weight: 700;
}

.panel-body {
  padding: 22px;
}

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

.data-table th {
  padding: 11px 16px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--border);
  text-align: left;
}

.data-table td {
  padding: 14px 16px;
  font-size: 0.88rem;
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  vertical-align: middle;
}

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

.data-table tr:hover td {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
}

/* ─── Badge Pills ─── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.badge-pending {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.badge-approved {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.badge-rejected {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.25);
}

.badge-resolved {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.25);
}

/* ─── Form Panel ─── */
.form-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 30px;
  max-width: 600px;
}

/* =============================================
   TOAST NOTIFICATION
   ============================================= */
#toast {
  position: fixed;
  bottom: 28px;
  right: 28px;
  padding: 14px 20px;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow: var(--shadow-md);
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.35s var(--ease);
  z-index: 9999;
  pointer-events: none;
  max-width: 320px;
}

#toast.show {
  transform: translateY(0);
  opacity: 1;
}

#toast.error {
  background: linear-gradient(135deg, #ef4444, #dc2626);
}

#toast.success {
  background: linear-gradient(135deg, #10b981, #059669);
}

/* ─── Animations ─── */
@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }

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

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.animate-in {
  animation: slideUp 0.4s var(--ease) both;
}

.animate-in:nth-child(1) {
  animation-delay: 0.05s;
}

.animate-in:nth-child(2) {
  animation-delay: 0.10s;
}

.animate-in:nth-child(3) {
  animation-delay: 0.15s;
}

.animate-in:nth-child(4) {
  animation-delay: 0.20s;
}

/* =============================================
   PROFESSIONAL CALENDAR
   ============================================= */

.calendar-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  backdrop-filter: blur(16px);
}

.calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.calendar-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.calendar-controls {
  display: flex;
  gap: 8px;
}

.calendar-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--text-primary);
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--duration) var(--ease);
}

.calendar-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--primary-light);
}

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

.calendar-day-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  text-align: center;
  padding-bottom: 8px;
}

.calendar-day {
  min-height: 100px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-md);
  padding: 8px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all var(--duration) var(--ease);
  cursor: default;
  overflow: hidden;
}

.calendar-day:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.1);
}

.calendar-day.today {
  border-color: var(--primary);
  background: rgba(99, 102, 241, 0.05);
}

.calendar-day.other-month {
  opacity: 0.3;
  pointer-events: none;
}

.day-number {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.calendar-day.today .day-number {
  color: var(--primary-light);
}

/* Persistent Booking Items */
.day-bookings-container {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 8px;
  overflow-y: auto;
  max-height: 80px;
}

.day-booking-item {
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 4px;
  padding: 4px 6px;
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.booking-lab {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--primary-light);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.booking-time {
  font-size: 0.6rem;
  color: var(--text-secondary);
}

/* Tooltip removed in favor of persistent display */
.calendar-tooltip {
  display: none;
}

.tooltip-item {
  font-size: 0.75rem;
  border-bottom: 1px solid var(--border);
  padding: 4px 0;
}

.tooltip-item:last-child {
  border: none;
}

.tooltip-lab {
  font-weight: 700;
  color: var(--primary-light);
}

.tooltip-time {
  color: var(--text-muted);
}

.tooltip-student {
  color: var(--text-secondary);
  font-style: italic;
}

/* Chat Button */
#chatbot-toggle {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #6366f1;
  color: white;
  padding: 15px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
}

/* Chat Container */
#chatbot-container {
  position: fixed;
  bottom: 80px;
  right: 20px;
  width: 300px;
  background: #1e1e2f;
  border-radius: 10px;
  display: none;
  flex-direction: column;
  overflow: hidden;
}

/* Header */
#chatbot-header {
  background: #6366f1;
  padding: 10px;
  color: white;
  font-weight: bold;
}

/* Messages */
#chatbot-messages {
  height: 250px;
  overflow-y: auto;
  padding: 10px;
}

/* Input */
#chatbot-input-area {
  display: flex;
}

#chatbot-input {
  flex: 1;
  padding: 8px;
}

#chatbot-input-area button {
  background: #6366f1;
  border: none;
  color: white;
  padding: 8px 10px;
}

/* =============================================
   MOBILE RESPONSIVENESS
   ============================================= */

/* Menu Toggle Button (hidden by default) */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 8px;
  z-index: 1001;
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 99;
}

@media (max-width: 1024px) {
  :root {
    --sidebar-w: 260px; /* same but will be hidden */
  }

  .sidebar {
    transform: translateX(-100%);
    box-shadow: none;
  }

  .sidebar.active {
    transform: translateX(0);
    box-shadow: var(--shadow-lg);
  }

  .main-content {
    margin-left: 0;
  }

  .sidebar-overlay.active {
    display: block;
  }

  .mobile-nav-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .topbar {
    padding: 0 16px;
  }

  .topbar-title {
    font-size: 1rem;
  }

  .topbar-right {
    gap: 8px;
  }

  .topbar-badge {
    display: none; /* Hide badges on very small to save space */
  }

  .page-body {
    padding: 16px;
  }

  .stat-grid, .dash-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .panel-header {
    padding: 14px 16px;
  }

  .data-table th, .data-table td {
    padding: 10px 12px;
    font-size: 0.8rem;
  }

  /* Calendar Mobile Tweak */
  .calendar-card {
    padding: 16px;
  }

  .calendar-grid {
    gap: 4px;
  }

  .calendar-day {
    min-height: 80px;
    padding: 4px;
  }

  .day-number {
    font-size: 0.75rem;
  }

  .day-booking-item {
    padding: 2px 4px;
  }

  .booking-lab {
    font-size: 0.6rem;
  }

  .booking-time {
    display: none; /* Hide time on mobile to save space */
  }
}

@media (max-width: 640px) {
  .auth-card {
    padding: 32px 24px;
    border-radius: var(--radius-lg);
  }

  .auth-title {
    font-size: 1.35rem;
  }

  .topbar-time {
    display: none;
  }
}