/* ═══════════════════════════════════════════════════════
   PORTAL DESIGN SYSTEM (STUDENT, PARENT & TEACHER SUITE)
   Color Palette from DUSC Identity:
   ["aac641","61a739","193680","f7f3f8","231b1f","73a058","8c1a75","9e87ae","def3cd"]
═══════════════════════════════════════════════════════ */
:root {
  --portal-navy: #193680;
  --portal-navy-dark: #102354;
  --portal-navy-light: #eef2fb;
  --portal-green: #5FAF3D;
  --portal-moss: #579432;
  --portal-lime: #76c745;
  --portal-olive: #76c745;
  --portal-tint: #e3f5d8;
  --portal-plum: #911879;
  --portal-plum-light: #fbf5fa;
  --portal-mauve: #9e87ae;
  --portal-dark: #231b1f;
  --portal-bg: #fbf5fa;
  --portal-card-border: #edf2f7;
}

.portal-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.portal-nav-item.active {
  background: linear-gradient(135deg, #911879, #6f0e5b) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(145, 24, 121, 0.25);
}
.portal-nav-item.active i {
  color: #f8e5f4 !important;
}

.portal-card {
  background: #ffffff;
  border: 1px solid #edf2f7;
  border-radius: 20px;
  box-shadow: 0 2px 10px rgba(35, 27, 31, 0.025);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
@media (max-width: 640px) {
  .portal-card {
    border-radius: 18px;
  }
}
.portal-card:hover {
  border-color: #f8e5f4;
  box-shadow: 0 8px 24px rgba(145, 24, 121, 0.08);
}

.portal-stat-pill {
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 700;
}

/* Form Inputs & Controls in Portals */
.portal-input {
  width: 100%;
  padding: 9px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  font-size: 12px;
  background: #ffffff;
  color: var(--portal-dark);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.portal-input:focus {
  border-color: var(--portal-plum);
  box-shadow: 0 0 0 3px rgba(145, 24, 121, 0.1);
}

.portal-btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 18px;
  background: linear-gradient(135deg, #911879, #6f0e5b);
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(145, 24, 121, 0.25);
}
.portal-btn-primary:hover {
  background: linear-gradient(135deg, #6f0e5b, #911879);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(145, 24, 121, 0.35);
}

.portal-btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 18px;
  background-color: var(--portal-plum-light);
  color: var(--portal-plum);
  font-size: 12px;
  font-weight: 700;
  border-radius: 12px;
  border: 1px solid #f8e5f4;
  cursor: pointer;
  transition: all 0.2s ease;
}
.portal-btn-secondary:hover {
  background-color: #f8e5f4;
  transform: translateY(-1px);
}

.portal-btn-plum {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 18px;
  background-color: var(--portal-plum);
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(145, 24, 121, 0.2);
}
.portal-btn-plum:hover {
  background-color: #6f0e5b;
  transform: translateY(-1px);
}

/* Badges */
.portal-badge-green {
  background: #f8e5f4;
  color: #911879;
  font-weight: 700;
  font-size: 10px;
  padding: 4px 10px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.portal-badge-navy {
  background: #f8e5f4;
  color: #911879;
  font-weight: 700;
  font-size: 10px;
  padding: 4px 10px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.portal-badge-plum {
  background: #f8e5f4;
  color: #911879;
  font-weight: 700;
  font-size: 10px;
  padding: 4px 10px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.portal-badge-mauve {
  background: #fbf5fa;
  color: #9e87ae;
  font-weight: 700;
  font-size: 10px;
  padding: 4px 10px;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* Radial Donut Progress Ring */
.donut-circle-wrap {
  position: relative;
  width: 130px;
  height: 130px;
  margin: 0 auto;
}
.donut-circle-svg {
  transform: rotate(-90deg);
}

/* Multi-segmented Progress Bar */
.segmented-bar {
  display: flex;
  height: 8px;
  border-radius: 9999px;
  overflow: hidden;
  gap: 2px;
  background: #f1f5f9;
}

/* ═══════════════════════════════════════════════════════
   ADMIN CONSOLE DESIGN SYSTEM CLASSES
   ═══════════════════════════════════════════════════════ */
.adm-card {
  background: #ffffff;
  border: 1px solid #edf2f7;
  border-radius: 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.adm-card:hover {
  border-color: #e2e8f0;
  box-shadow: 0 6px 20px rgba(145, 24, 121, 0.04);
}

.adm-stat-card {
  background: #ffffff;
  border: 1px solid #edf2f7;
  border-radius: 20px;
  padding: 18px 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.adm-stat-card:hover {
  transform: translateY(-2px);
  border-color: #e2e8f0;
  box-shadow: 0 8px 24px rgba(145, 24, 121, 0.06);
}

.adm-sidebar-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
}
.adm-sidebar-nav-item:hover {
  color: var(--portal-plum);
  background: var(--portal-plum-light);
}
.adm-sidebar-nav-item.active {
  background: linear-gradient(135deg, #911879, #6f0e5b) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(145, 24, 121, 0.25);
}
.adm-sidebar-nav-item.active i {
  color: #f8e5f4 !important;
}

.adm-sub-nav-item {
  display: block;
  padding: 7px 12px 7px 28px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 500;
  color: #64748b;
  text-decoration: none;
  transition: all 0.15s ease;
}
.adm-sub-nav-item:hover {
  color: var(--portal-plum);
  background: var(--portal-plum-light);
  font-weight: 600;
}
.adm-sub-nav-item.active {
  color: var(--portal-plum);
  background: var(--portal-plum-light);
  font-weight: 700;
}

.adm-badge-active {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  background: #f8e5f4;
  color: #911879;
  font-size: 11px;
  font-weight: 700;
  border-radius: 9999px;
}

.adm-input {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  font-size: 12px;
  background: #ffffff;
  color: var(--portal-dark);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.adm-input:focus {
  border-color: var(--portal-plum);
  box-shadow: 0 0 0 3px rgba(145, 24, 121, 0.1);
}

.adm-btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  background: linear-gradient(135deg, #911879, #6f0e5b);
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(145, 24, 121, 0.2);
}
.adm-btn-primary:hover {
  background: linear-gradient(135deg, #6f0e5b, #911879);
  transform: translateY(-1px);
}

.adm-btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  background: #f8e5f4;
  color: #911879;
  font-size: 12px;
  font-weight: 700;
  border-radius: 10px;
  border: 1px solid #fad7fd;
  cursor: pointer;
  transition: all 0.2s ease;
}
.adm-btn-secondary:hover {
  background-color: #f7e1f4;
  transform: translateY(-1px);
}

/* Custom Switch Toggle */
.adm-switch {
  position: relative;
  display: inline-block;
  width: 32px;
  height: 18px;
}
.adm-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.adm-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #cbd5e1;
  transition: .3s;
  border-radius: 34px;
}
.adm-slider:before {
  position: absolute;
  content: "";
  height: 12px;
  width: 12px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .3s;
  border-radius: 50%;
}
.adm-switch input:checked + .adm-slider {
  background-color: #911879;
}
.adm-switch input:checked + .adm-slider:before {
  transform: translateX(14px);
}

/* ═══════════════════════════════════════════════════════
   FULL-PORTAL MOBILE RESPONSIVE ENHANCEMENTS
   ═══════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  /* Prevent table clipping on phone screens */
  .overflow-x-auto {
    -webkit-overflow-scrolling: touch;
    max-width: 100%;
  }

  /* Compact button paddings for mobile viewports */
  .portal-btn-primary, .portal-btn-secondary, .portal-btn-plum, .adm-btn-primary, .adm-btn-secondary {
    padding-top: 8px;
    padding-bottom: 8px;
    font-size: 11.5px;
  }

  /* Safe padding for fixed bottom floating navigation bars */
  body {
    padding-bottom: env(safe-area-inset-bottom, 20px);
  }

  /* Responsive cards */
  .portal-card, .adm-card {
    padding: 14px !important;
  }

  /* Form inputs touch-friendly */
  .portal-input, .adm-input {
    font-size: 13px !important;
  }
}

