/* Root Variables & Colors */
:root {
  --primary: hsl(262, 70%, 55%);
  --primary-hover: hsl(262, 70%, 47%);
  --primary-light: hsl(262, 70%, 95%);
  --dark: hsl(220, 25%, 15%);
  --dark-sidebar: hsl(220, 30%, 12%);
  --light-bg: hsl(270, 30%, 96%);
  --card-bg: hsl(0, 0%, 100%);
  --text: hsl(220, 20%, 25%);
  --text-muted: hsl(220, 12%, 50%);
  --border: hsl(220, 15%, 90%);
  
  /* Status Colors */
  --success: hsl(145, 65%, 42%);
  --success-bg: hsl(145, 65%, 95%);
  --danger: hsl(355, 75%, 52%);
  --danger-bg: hsl(355, 75%, 96%);
  --warning: hsl(38, 92%, 46%);
  --warning-bg: hsl(38, 92%, 94%);
  --info: hsl(190, 80%, 45%);
  --info-bg: hsl(190, 80%, 94%);

  /* Typography & Sizing */
  --font-title: 'Outfit', 'Inter', sans-serif;
  --font-body: 'Inter', sans-serif;
  --sidebar-width: 260px;
  --transition-speed: 0.3s;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.08);
}

/* Global Reset */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  color: var(--text);
  background-color: var(--light-bg);
  line-height: 1.5;
  overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: hsl(220, 10%, 80%);
  border-radius: var(--radius-sm);
}
::-webkit-scrollbar-thumb:hover {
  background: hsl(220, 10%, 70%);
}

/* Helpers */
.hidden { display: none !important; }
.text-center { text-align: center; }
.mt-1 { margin-top: 5px; }
.mt-2 { margin-top: 10px; }
.mt-3 { margin-top: 15px; }
.mb-2 { margin-bottom: 10px; }
.mb-3 { margin-bottom: 15px; }
.mr-2 { margin-right: 10px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 16px;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 14px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition-speed) ease;
}

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

.btn-outline-primary {
  background-color: transparent;
  border-color: var(--primary);
  color: var(--primary);
}
.btn-outline-primary:hover {
  background-color: var(--primary-light);
}

.btn-danger {
  background-color: var(--danger);
  color: white;
}
.btn-danger:hover {
  background-color: hsl(355, 75%, 45%);
}

.btn-outline-danger {
  background-color: transparent;
  border-color: var(--danger);
  color: var(--danger);
}
.btn-outline-danger:hover {
  background-color: var(--danger-bg);
}

.btn-sm {
  padding: 4px 8px;
  font-size: 12px;
}

.btn-block {
  width: 100%;
}

.link-btn {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.link-btn:hover {
  text-decoration: underline;
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 50px;
  text-transform: capitalize;
}

.badge-success { background-color: var(--success-bg); color: var(--success); }
.badge-danger { background-color: var(--danger-bg); color: var(--danger); }
.badge-warning { background-color: var(--warning-bg); color: var(--warning); }
.badge-info { background-color: var(--info-bg); color: var(--info); }

/* Forms & Inputs */
.form-group {
  margin-bottom: 16px;
}

label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 6px;
  color: var(--dark);
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="date"],
select,
textarea {
  width: 100%;
  padding: 10px 12px;
  font-family: var(--font-body);
  font-size: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background-color: white;
  color: var(--text);
  outline: none;
  transition: border-color var(--transition-speed);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

.input-wrapper {
  position: relative;
}

.input-wrapper i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.input-wrapper input,
.input-wrapper select {
  padding-left: 36px;
}

/* Auth Layout */
.auth-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: linear-gradient(135deg, hsl(220, 25%, 15%) 0%, hsl(200, 85%, 25%) 100%);
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background-color: var(--card-bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 40px;
}

.auth-header {
  text-align: center;
  margin-bottom: 30px;
}

.auth-header .logo {
  font-family: var(--font-title);
  font-size: 28px;
  font-weight: 800;
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.auth-header .subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 5px;
}

.auth-tabs {
  display: flex;
  border-bottom: 2px solid var(--border);
  margin-bottom: 24px;
}

.auth-tab-btn {
  flex: 1;
  padding: 10px;
  font-family: var(--font-title);
  font-weight: 600;
  font-size: 14px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all var(--transition-speed);
}

.auth-tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.auth-form {
  display: none;
}
.auth-form.active {
  display: block;
}

.auth-error {
  background-color: var(--danger-bg);
  color: var(--danger);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  margin-top: 15px;
  border-left: 4px solid var(--danger);
}

.demo-logins {
  margin-top: 25px;
  padding-top: 15px;
  border-top: 1px dashed var(--border);
  font-size: 12px;
  color: var(--text-muted);
}

.demo-chips {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.demo-chips span {
  background-color: var(--light-bg);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 50px;
  cursor: pointer;
  font-weight: 600;
  transition: all var(--transition-speed);
}
.demo-chips span:hover {
  background-color: var(--primary-light);
  color: var(--primary);
  border-color: var(--primary);
}

/* App Main Layout */
.app-layout {
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
  min-height: 100vh;
}

/* Sidebar Styling */
.sidebar {
  background-color: var(--dark-sidebar);
  color: white;
  display: flex;
  flex-direction: column;
  height: 100vh;
  position: sticky;
  top: 0;
  z-index: 100;
  transition: transform var(--transition-speed) ease;
}

.sidebar-brand {
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid hsl(220, 20%, 20%);
}

.sidebar-brand .logo {
  font-family: var(--font-title);
  font-size: 22px;
  font-weight: 700;
  color: white;
  display: flex;
  align-items: center;
  gap: 10px;
}

.sidebar-brand .logo i {
  color: var(--primary);
}

.mobile-close-btn {
  background: none;
  border: none;
  color: white;
  font-size: 20px;
  cursor: pointer;
  display: none;
}

.sidebar-user-card {
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid hsl(220, 20%, 18%);
  background-color: hsl(220, 25%, 10%);
}

.sidebar-user-card .user-avatar {
  font-size: 36px;
  color: var(--primary);
  display: flex;
  align-items: center;
}

.sidebar-user-card .user-details h4 {
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 600;
}

.sidebar-user-card .user-details .badge {
  margin-top: 4px;
  background-color: hsl(220, 20%, 22%);
  color: hsl(220, 10%, 80%);
}

.sidebar-nav {
  flex: 1;
  padding: 20px 10px;
  overflow-y: auto;
}

.sidebar-nav ul {
  list-style: none;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  color: hsl(220, 10%, 75%);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  border-radius: var(--radius-sm);
  margin-bottom: 4px;
  transition: all var(--transition-speed);
}

.nav-item:hover {
  background-color: hsl(220, 20%, 18%);
  color: white;
}

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

.sidebar-footer {
  padding: 20px;
  border-top: 1px solid hsl(220, 20%, 18%);
}

/* Main Content Area Styling */
.main-content {
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow-y: auto;
}

.content-header {
  padding: 20px 30px;
  background-color: var(--card-bg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 90;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 15px;
}

.header-left h2 {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 700;
}

.mobile-menu-toggle {
  background: none;
  border: none;
  color: var(--text);
  font-size: 20px;
  cursor: pointer;
  display: none;
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.status-indicator .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.status-indicator .dot.connected {
  background-color: var(--success);
}

.content-viewport-pane {
  padding: 30px;
  flex: 1;
}

/* View Panes */
.view-pane {
  animation: fadeIn var(--transition-speed) ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Dashboard Summary Cards Grid */
.summary-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.summary-card {
  background-color: var(--card-bg);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}

.summary-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.summary-card .icon-wrapper {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.summary-card .icon-wrapper.primary { background-color: var(--primary-light); color: var(--primary); }
.summary-card .icon-wrapper.success { background-color: var(--success-bg); color: var(--success); }
.summary-card .icon-wrapper.warning { background-color: var(--warning-bg); color: var(--warning); }
.summary-card .icon-wrapper.info { background-color: var(--info-bg); color: var(--info); }

.summary-card .card-info .value {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 700;
  color: var(--dark);
}

.summary-card .card-info .label {
  font-size: 13px;
  color: var(--text-muted);
}

/* Detailed Grid */
.dashboard-details-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 25px;
}

.dashboard-card {
  background-color: var(--card-bg);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  padding: 24px;
}

.dashboard-card h3 {
  font-family: var(--font-title);
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 20px;
}

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

/* Table Design */
.table-container {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 14px;
}

table th {
  padding: 12px;
  background-color: var(--light-bg);
  color: var(--dark);
  font-weight: 600;
  border-bottom: 2px solid var(--border);
}

table td {
  padding: 12px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

table tbody tr:hover {
  background-color: hsl(220, 10%, 98%);
}

.table-compact th, .table-compact td {
  padding: 8px 10px;
  font-size: 13px;
}

/* Sys Info & Announcements */
.sys-info-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.sys-info-item {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
}

.sys-info-item .label {
  color: var(--text-muted);
}

.sys-info-item .value {
  font-weight: 600;
}

.quick-announcements {
  margin-top: 20px;
}

.quick-announcements h4 {
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 12px;
}

.announcement {
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.announcement:last-child {
  border-bottom: none;
}

.announcement .date {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
}

.announcement p {
  font-size: 12px;
  margin-top: 3px;
}

/* Grid Layout for Courses tab */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.course-card {
  background-color: var(--card-bg);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  padding: 20px;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-speed), box-shadow var(--transition-speed);
}

.course-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.course-card .course-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.course-card .course-code {
  font-size: 11px;
  font-weight: 700;
  background-color: var(--primary-light);
  color: var(--primary);
  padding: 2px 6px;
  border-radius: var(--radius-sm);
}

.course-card h4 {
  font-family: var(--font-title);
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--dark);
}

.course-card p {
  font-size: 13px;
  color: var(--text-muted);
  flex: 1;
  margin-bottom: 16px;
}

.course-card .course-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border);
  padding-top: 12px;
  font-size: 12px;
}

.course-card .teacher-name {
  color: var(--text);
  font-weight: 500;
}

/* Course details tabs layout */
.course-details-layout {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.course-detail-header-card {
  background-color: var(--card-bg);
  padding: 24px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.course-detail-tabs-menu {
  display: flex;
  gap: 10px;
  border-bottom: 2px solid var(--border);
  margin-bottom: 10px;
}

.course-detail-tab-btn {
  padding: 10px 16px;
  font-weight: 600;
  font-size: 14px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all var(--transition-speed);
}

.course-detail-tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.materials-list-wrapper,
.assignments-list-wrapper,
.quizzes-list-wrapper {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.item-row {
  background-color: var(--card-bg);
  padding: 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background-color var(--transition-speed);
}

.item-row:hover {
  background-color: hsl(220, 10%, 98%);
}

.item-row .item-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.item-row .item-left i {
  font-size: 20px;
  color: var(--primary);
}

.item-row .item-title {
  font-weight: 600;
  font-size: 14px;
}

.item-row .item-meta {
  font-size: 12px;
  color: var(--text-muted);
}

/* Modals styling */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-card {
  width: 100%;
  max-width: 520px;
  background-color: var(--card-bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 24px;
  position: relative;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  animation: modalEnter 0.25s ease-out;
}

@keyframes modalEnter {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
}

.modal-header h3 {
  font-family: var(--font-title);
  font-size: 18px;
  font-weight: 700;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
}
.modal-close:hover {
  color: var(--text);
}

.modal-scroll-body {
  overflow-y: auto;
  flex: 1;
  padding-right: 5px;
}

.help-text {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
  display: block;
}

.submission-meta-box {
  background-color: var(--light-bg);
  padding: 14px;
  border-radius: var(--radius-sm);
  margin-bottom: 15px;
  font-size: 13px;
}

/* Quiz creation styles */
.quiz-questions-builder {
  border-top: 1px dashed var(--border);
  margin-top: 15px;
  padding-top: 15px;
}

.quiz-question-field {
  background-color: var(--light-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  margin-bottom: 15px;
  position: relative;
}

.quiz-question-field .remove-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  background: none;
  border: none;
  color: var(--danger);
  cursor: pointer;
}

/* Take quiz question layout */
.quiz-take-question {
  margin-bottom: 20px;
  background-color: var(--light-bg);
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}

.quiz-take-question h5 {
  font-family: var(--font-title);
  font-weight: 600;
  margin-bottom: 12px;
}

.quiz-options-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.quiz-option-label {
  display: flex;
  align-items: center;
  gap: 10px;
  background-color: white;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  font-size: 13px;
  cursor: pointer;
  transition: all var(--transition-speed);
}
.quiz-option-label:hover {
  background-color: var(--primary-light);
  border-color: var(--primary);
}

.quiz-option-label input[type="radio"] {
  accent-color: var(--primary);
}

/* Attendance marking style */
.attendance-table-wrapper {
  margin-top: 15px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  max-height: 250px;
  overflow-y: auto;
}

.status-options-row {
  display: flex;
  gap: 10px;
}

.status-options-row label {
  margin-bottom: 0;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  cursor: pointer;
}

.status-options-row input[type="radio"] {
  accent-color: var(--primary);
}

/* Academic Summary UI */
.grades-aggregate-box {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-hover) 100%);
  color: white;
  border-radius: var(--radius-md);
  padding: 24px;
  margin-bottom: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.gpa-circle {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.2);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 3px solid white;
}

.gpa-circle .val {
  font-family: var(--font-title);
  font-size: 26px;
  font-weight: 800;
  line-height: 1;
}

.gpa-circle .lbl {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
}

/* Toast Notifications */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background-color: var(--dark);
  color: white;
  padding: 14px 20px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 2000;
  font-size: 14px;
  font-weight: 500;
  transition: transform var(--transition-speed) cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity var(--transition-speed);
  transform: translateY(0);
  opacity: 1;
}

.toast.hidden {
  transform: translateY(100px);
  opacity: 0;
  pointer-events: none;
}

.toast-icon {
  font-size: 16px;
}

.toast.success { border-left: 4px solid var(--success); }
.toast.success .toast-icon { color: var(--success); }

.toast.error { border-left: 4px solid var(--danger); }
.toast.error .toast-icon { color: var(--danger); }

.toast.info { border-left: 4px solid var(--info); }
.toast.info .toast-icon { color: var(--info); }

/* Responsive styles */
@media (max-width: 992px) {
  .dashboard-details-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .app-layout {
    grid-template-columns: 1fr;
  }
  
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: var(--sidebar-width);
    transform: translateX(-100%);
  }
  
  .sidebar.open {
    transform: translateX(0);
  }
  
  .mobile-close-btn {
    display: block;
  }
  
  .mobile-menu-toggle {
    display: block;
  }
  
  .content-header {
    padding: 15px 20px;
  }
  
  .content-viewport-pane {
    padding: 20px;
  }
  
  .course-detail-header-card {
    flex-direction: column;
    gap: 15px;
    align-items: stretch;
  }
}

/* ==========================================================================
   UNIVERSITY LMS SPECIFIC THEMES & LAYOUTS (IUK / KSMA REFERENCE LOOK)
   ========================================================================== */

/* Background blobs */
.bg-blob {
  position: fixed;
  border-radius: 50%;
  z-index: -1;
  pointer-events: none;
  filter: blur(80px);
  opacity: 0.7;
}
.blob-top-right {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(168, 85, 247, 0.35) 0%, rgba(168, 85, 247, 0.05) 75%);
  top: -80px;
  right: -80px;
}
.blob-bottom-left {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.3) 0%, rgba(59, 130, 246, 0.03) 75%);
  bottom: -60px;
  left: -60px;
}
.blob-mid-bottom {
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, rgba(168, 85, 247, 0.2) 0%, rgba(59, 130, 246, 0.02) 70%);
  bottom: 80px;
  right: 15%;
}

/* Frameless Login Screen */
.auth-wrapper {
  background-color: var(--light-bg);
  background-image: 
    radial-gradient(at 10% 20%, rgba(168, 85, 247, 0.08) 0px, transparent 50%),
    radial-gradient(at 90% 80%, rgba(59, 130, 246, 0.08) 0px, transparent 50%);
}

.auth-card {
  background: transparent;
  box-shadow: none;
  border: none;
  padding: 20px;
  max-width: 400px;
  width: 100%;
}

.welcome-text {
  text-align: center;
  font-size: 17px;
  font-weight: 700;
  color: hsl(255, 60%, 50%);
  margin-bottom: 25px;
  font-family: var(--font-title);
  letter-spacing: -0.2px;
}

.brand-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 15px;
}

.iuk-logo {
  height: 90px;
  width: auto;
  object-fit: contain;
  margin-bottom: 20px;
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.06));
}

.brand-title {
  font-family: var(--font-title);
  font-size: 56px;
  font-weight: 800;
  letter-spacing: 2px;
  text-align: center;
  line-height: 1;
  background: linear-gradient(90deg, hsl(270, 75%, 52%) 0%, hsl(210, 85%, 48%) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  text-align: center;
  font-size: 13.5px;
  font-weight: 600;
  color: #1e293b;
  max-width: 320px;
  margin: 0 auto 35px auto;
  line-height: 1.45;
  font-family: var(--font-body);
}

/* Auth Floating Input Fields (Rounded boxes, subtle shadow, right icon) */
.auth-form .form-group {
  margin-bottom: 20px;
}

.auth-form .input-wrapper input,
.auth-form .input-wrapper select {
  width: 100%;
  height: 52px;
  border-radius: 14px;
  border: 1px solid rgba(226, 232, 240, 0.8);
  background-color: white;
  padding-left: 20px;
  padding-right: 48px;
  font-size: 15px;
  color: #0f172a;
  outline: none;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
  transition: all var(--transition-speed) ease;
}

.auth-form .input-wrapper input:focus {
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.1), 0 0 0 3px rgba(139, 92, 246, 0.15);
}

.auth-form .input-wrapper .input-icon-right {
  position: absolute;
  right: 20px;
  left: auto;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 16px;
}

/* Auth LOGIN Button (Rounded gradient corners, bold text, shadow) */
.auth-form button[type="submit"] {
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(90deg, hsl(270, 75%, 52%) 0%, hsl(210, 85%, 48%) 100%);
  color: white;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.5px;
  border: none;
  box-shadow: 0 8px 16px rgba(139, 92, 246, 0.25);
  transition: all var(--transition-speed) ease;
  cursor: pointer;
  margin-top: 5px;
}

.auth-form button[type="submit"]:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(139, 92, 246, 0.35);
}

.toggle-auth-link-row {
  text-align: center;
  margin-top: 15px;
}

.toggle-link {
  font-size: 13px;
  color: #64748b;
  text-decoration: none;
  font-weight: 500;
}
.toggle-link:hover {
  color: var(--primary);
  text-decoration: underline;
}

/* Centered language switcher */
.lang-switcher {
  display: flex;
  justify-content: center;
  gap: 25px;
  margin-top: 40px;
  font-size: 13.5px;
}

.lang-btn {
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-body);
}

.lang-btn.active {
  font-weight: 700;
  color: #2563eb !important; /* active bold blue */
}

/* ==========================================================================
   STUDENT PROFILE CARD (Gradient, circular avatar, centered details)
   ========================================================================== */
.student-profile-card {
  background: linear-gradient(135deg, hsl(270, 75%, 52%) 0%, hsl(210, 85%, 48%) 100%);
  color: white;
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-md);
  margin-bottom: 25px;
}

.profile-avatar-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 15px;
}

.profile-avatar-img {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.8);
  object-fit: cover;
  box-shadow: var(--shadow-md);
  margin-bottom: 10px;
  background-color: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: white;
}

.profile-name {
  font-family: var(--font-title);
  font-size: 17px;
  font-weight: 700;
  text-align: center;
}

.profile-role {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.75);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 2px;
  text-align: center;
}

.profile-divider {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  margin: 14px 0;
}

.profile-field-centered {
  text-align: center;
}

.profile-field-centered .field-val {
  font-size: 14px;
  font-weight: 600;
  color: white;
}

.profile-field-centered .field-lbl {
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 3px;
}

.profile-gpa-val {
  font-family: var(--font-title);
  font-size: 36px;
  font-weight: 800;
  color: #4ade80; /* bright green */
  text-align: center;
  line-height: 1;
}

.profile-gpa-lbl {
  font-size: 10.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.75);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: center;
  margin-top: 4px;
}

/* ==========================================================================
   TRANSCRIPT & COURSE CARD STYLING (Left subject, right green score)
   ========================================================================== */
.transcript-container {
  display: flex;
  flex-direction: column;
  gap: 0; /* stacked list */
}

.transcript-card {
  padding: 16px 0;
  border-bottom: 1px solid #e2e8f0;
}

.transcript-card:last-child {
  border-bottom: none;
}

.transcript-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}

.transcript-card-title {
  font-weight: 700;
  font-size: 15px;
  color: #0f172a; /* bold black */
  font-family: var(--font-title);
}

.transcript-card-score {
  font-weight: 700;
  font-size: 15px;
  color: var(--success); /* green bold score */
  white-space: nowrap;
}

.transcript-detail-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 5px;
}

.transcript-detail-row:last-child {
  margin-bottom: 0;
}

.transcript-detail-label {
  color: #64748b; /* gray left label */
}

.transcript-detail-value {
  color: #0f172a; /* black right value */
  font-weight: 500;
}

/* Edit Avatar Overlay & Wrapper Styles */
.profile-avatar-wrapper {
  position: relative;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  cursor: pointer;
  overflow: hidden;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.profile-avatar-wrapper:hover .avatar-edit-overlay {
  opacity: 1;
}

.avatar-edit-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 20px;
  opacity: 0;
  transition: opacity 0.2s ease;
  border-radius: 50%;
}

