:root {
  /* Colors */
  --primary: #3B82F6; /* Bright Blue */
  --primary-dark: #2563EB;
  --secondary: #10B981; /* Green */
  --accent: #F59E0B; /* Orange/Yellow for alerts */
  --bg-color: #F3F4F6;
  --surface: #FFFFFF;
  --text-main: #1F2937;
  --text-muted: #6B7280;
  --text-light: #9CA3AF;
  --border: #E5E7EB;
  --danger: #EF4444;

  /* Spacing */
  --spacing-xs: 4px;
  --spacing-sm: 8px;
  --spacing-md: 16px;
  --spacing-lg: 24px;
  --spacing-xl: 32px;

  /* Typography */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --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);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font-family);
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Mobile Container Simulation */
.app-container {
  max-width: 480px;
  margin: 0 auto;
  background-color: var(--surface);
  min-height: 100vh;
  position: relative;
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 20px rgba(0,0,0,0.05);
}

/* Typography */
h1, h2, h3, h4, p {
  margin: 0;
}

h1 {
  font-size: 28px;
  font-weight: 700;
  color: var(--primary-dark);
}

h2 {
  font-size: 20px;
  font-weight: 600;
}

h3 {
  font-size: 16px;
  font-weight: 600;
}

.text-sm { font-size: 14px; }
.text-xs { font-size: 12px; }
.text-muted { color: var(--text-muted); }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-primary { color: var(--primary); }
.text-danger { color: var(--danger); }
.font-bold { font-weight: 700; }

/* Components */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 14px 20px;
  border-radius: var(--radius-md);
  border: none;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-primary:active {
  transform: translateY(1px);
  box-shadow: none;
}

.btn-secondary {
  background-color: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.btn-link {
  background: none;
  color: var(--primary);
  padding: 0;
  width: auto;
  font-weight: 500;
}

/* Forms */
.form-group {
  margin-bottom: var(--spacing-lg);
}

.label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: var(--spacing-sm);
  color: var(--text-muted);
}

.input {
  width: 100%;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 16px;
  background: var(--bg-color);
  transition: border-color 0.2s;
}

.input:focus {
  outline: none;
  border-color: var(--primary);
  background: white;
}

/* Cards */
.card {
  background: white;
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  margin-bottom: var(--spacing-md);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-sm);
}

/* Layouts */
.header {
  padding: var(--spacing-lg) var(--spacing-md);
  background: white;
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-main);
}

.content {
  padding: var(--spacing-md);
  flex: 1;
  overflow-y: auto;
  padding-bottom: 80px; /* Space for bottom nav */
}

/* Grid Menu */
.grid-menu {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--spacing-md);
}

.menu-item {
  background: white;
  padding: var(--spacing-lg);
  border-radius: var(--radius-lg);
  text-align: center;
  text-decoration: none;
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  transition: transform 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
}

.menu-item:active {
  transform: scale(0.98);
}

/* Icons (CSS Shapes/Placeholders) */
.icon-box {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--spacing-sm);
  font-weight: bold;
  font-size: 20px;
}

.icon-blue { background: #DBEAFE; color: var(--primary); }
.icon-green { background: #D1FAE5; color: var(--secondary); }
.icon-orange { background: #FEF3C7; color: var(--accent); }
.icon-red { background: #FEE2E2; color: var(--danger); }
.icon-purple { background: #EDE9FE; color: #8B5CF6; }
.icon-gray { background: #F3F4F6; color: var(--text-muted); }

/* Bottom Nav */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-around;
  padding: var(--spacing-sm);
  z-index: 20;
  max-width: 480px;
  margin: 0 auto; /* Keep centered in desktop view */
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  color: var(--text-muted);
  font-size: 11px;
  gap: 4px;
}

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

.nav-icon {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: #E5E7EB;
}

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

/* Specific Page Styles */

/* Profile Header */
.student-card {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  margin-bottom: var(--spacing-lg);
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  box-shadow: var(--shadow-md);
}

.avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: white;
  border: 3px solid rgba(255,255,255,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-weight: bold;
  font-size: 24px;
}

/* Badges */
.badge {
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
}
.badge-success { background: #D1FAE5; color: #065F46; }
.badge-warning { background: #FEF3C7; color: #92400E; }
.badge-danger { background: #FEE2E2; color: #991B1B; }

/* Timeline for Schedule */
.timeline-item {
  display: flex;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-md);
  border-bottom: 1px solid var(--border);
  padding-bottom: var(--spacing-md);
}
.timeline-time {
  min-width: 60px;
  font-weight: 600;
  color: var(--text-muted);
}
.timeline-content {
  flex: 1;
}

/* Notification Item */
.notif-item {
  display: flex;
  gap: var(--spacing-md);
  padding: var(--spacing-md);
  background: white;
  border-bottom: 1px solid var(--border);
}
.notif-item.unread {
  background: #F0F9FF;
}

/* Back Button */
.btn-back {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  padding: 0;
  margin-right: var(--spacing-sm);
}
