/* ============================================
   SAP CRM Frontend Styles
   Version: 2.2 - Fixed standalone button classes
   ============================================ */

body {
  font-family: 'Poppins', sans-serif;
}

/* ============================================
   CSS VARIABLES - SAP Brand Colors
   ============================================ */
:root {
  /* Brand Colors */
  --sap-purple: #7d5584;
  --sap-hot-pink: #dc195f;
  --sap-pink-hover: #c01452;
  --sap-light-purple: #9370db;
  --sap-dark-purple: #663a6c;

  /* Semantic Colors */
  --color-success: #10b981;
  --color-success-hover: #059669;
  --color-danger: #ef4444;
  --color-danger-hover: #dc2626;
  --color-warning: #f59e0b;
  --color-warning-hover: #d97706;
  --color-info: #3b82f6;
  --color-info-hover: #2563eb;
  --color-neutral: #6b7280;
  --color-neutral-hover: #4b5563;

  /* Sizing */
  --btn-padding-sm: 0.375rem 0.75rem;
  --btn-padding-md: 0.5rem 1rem;
  --btn-padding-lg: 0.75rem 1.5rem;
  --btn-radius: 0.5rem;
  --btn-font-weight: 600;

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-normal: 200ms ease;

  /* Spinner */
  --spinner-size-sm: 16px;
  --spinner-size-md: 24px;
  --spinner-size-lg: 40px;
  --spinner-border-width: 3px;

  /* Student Print Settings */
  --name-center-from-top: 1.9in;
  --name-center-from-right: 2.89in;
  --name-center-from-left: 5.61in;
  --name-font-size: 44pt;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */
.hidden {
  display: none !important;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* ============================================
   BUTTONS - Unified System
   ============================================ */

/* Base button styles (for use with .btn class) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: var(--btn-padding-md);
  font-weight: var(--btn-font-weight);
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: var(--btn-radius);
  border: none;
  cursor: pointer;
  transition: all var(--transition-normal);
  text-decoration: none;
  white-space: nowrap;
}

.btn:focus {
  outline: 2px solid var(--sap-purple);
  outline-offset: 2px;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* ============================================
   STANDALONE BUTTON CLASSES
   These work without needing the base .btn class
   ============================================ */

/* Primary Button - Hot Pink (main actions) */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: var(--sap-hot-pink);
  color: white;
}
.btn-primary:hover {
  background-color: var(--sap-pink-hover);
}
.btn-primary:active {
  background-color: #a8103f;
}
.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Secondary Button - Purple (secondary actions) */
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: var(--sap-purple);
  color: white;
}
.btn-secondary:hover {
  background-color: var(--sap-dark-purple);
}
.btn-secondary:active {
  background-color: #552d5a;
}
.btn-secondary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Tertiary Button - Light Purple (less prominent) */
.btn-tertiary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: var(--sap-light-purple);
  color: white;
}
.btn-tertiary:hover {
  background-color: var(--sap-purple);
}
.btn-tertiary:active {
  background-color: var(--sap-dark-purple);
}
.btn-tertiary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Success Button - Green (positive actions like Convert, Approve) */
.btn-success {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: var(--color-success);
  color: white;
}
.btn-success:hover {
  background-color: var(--color-success-hover);
}
.btn-success:active {
  background-color: #047857;
}
.btn-success:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Danger Button - Red (destructive actions like Delete) */
.btn-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: var(--color-danger);
  color: white;
}
.btn-danger:hover {
  background-color: var(--color-danger-hover);
}
.btn-danger:active {
  background-color: #b91c1c;
}
.btn-danger:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Warning Button - Orange (caution actions) */
.btn-warning {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: var(--color-warning);
  color: white;
}
.btn-warning:hover {
  background-color: var(--color-warning-hover);
}
.btn-warning:active {
  background-color: #b45309;
}
.btn-warning:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Info Button - Blue (informational actions) */
.btn-info {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: var(--color-info);
  color: white;
}
.btn-info:hover {
  background-color: var(--color-info-hover);
}
.btn-info:active {
  background-color: #1d4ed8;
}
.btn-info:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Neutral Button - Gray (cancel, close, less important) */
.btn-neutral {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: var(--color-neutral);
  color: white;
}
.btn-neutral:hover {
  background-color: var(--color-neutral-hover);
}
.btn-neutral:active {
  background-color: #374151;
}
.btn-neutral:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ============================================
   OUTLINE BUTTON VARIANTS
   ============================================ */

.btn-outline-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: transparent;
  color: var(--sap-hot-pink);
  border: 2px solid var(--sap-hot-pink);
}
.btn-outline-primary:hover {
  background-color: var(--sap-hot-pink);
  color: white;
}

.btn-outline-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: transparent;
  color: var(--sap-purple);
  border: 2px solid var(--sap-purple);
}
.btn-outline-secondary:hover {
  background-color: var(--sap-purple);
  color: white;
}

.btn-outline-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: transparent;
  color: var(--color-danger);
  border: 2px solid var(--color-danger);
}
.btn-outline-danger:hover {
  background-color: var(--color-danger);
  color: white;
}

/* Ghost variants (no border, subtle hover) */
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: transparent;
  color: var(--color-neutral);
}
.btn-ghost:hover {
  background-color: rgba(107, 114, 128, 0.1);
}

.btn-ghost-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-weight: 600;
  font-size: 0.875rem;
  line-height: 1.25rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: transparent;
  color: var(--color-danger);
}
.btn-ghost-danger:hover {
  background-color: rgba(239, 68, 68, 0.1);
}

/* Size variants (for use with .btn base class) */
.btn-sm {
  padding: var(--btn-padding-sm);
  font-size: 0.75rem;
  border-radius: 0.375rem;
}

.btn-lg {
  padding: var(--btn-padding-lg);
  font-size: 1rem;
}

/* Icon-only buttons */
.btn-icon {
  padding: 0.5rem;
  width: 2.5rem;
  height: 2.5rem;
}

.btn-icon-sm {
  padding: 0.375rem;
  width: 2rem;
  height: 2rem;
}

.btn-icon-lg {
  padding: 0.625rem;
  width: 3rem;
  height: 3rem;
}

/* Full width button */
.btn-block {
  width: 100%;
}

/* Button group */
.btn-group {
  display: inline-flex;
}

.btn-group .btn {
  border-radius: 0;
}

.btn-group .btn:first-child {
  border-top-left-radius: var(--btn-radius);
  border-bottom-left-radius: var(--btn-radius);
}

.btn-group .btn:last-child {
  border-top-right-radius: var(--btn-radius);
  border-bottom-right-radius: var(--btn-radius);
}

/* Legacy button class support (for backwards compatibility) */
.btn-primary-large {
  background-color: var(--sap-hot-pink);
  color: white;
  font-weight: bold;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s;
}
.btn-primary-large:hover {
  background-color: var(--sap-pink-hover);
}
.btn-primary-large:disabled {
  background-color: #f472b6;
  cursor: not-allowed;
}

.btn-icon-primary {
  background-color: var(--sap-hot-pink);
  color: white;
  padding: 0.5rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s;
}
.btn-icon-primary:hover {
  background-color: var(--sap-pink-hover);
}

.btn-icon-secondary {
  background-color: var(--sap-purple);
  color: white;
  padding: 0.5rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s;
}
.btn-icon-secondary:hover {
  background-color: var(--sap-dark-purple);
}

.btn-icon-neutral {
  background-color: #6b7280;
  color: white;
  padding: 0.5rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s;
}
.btn-icon-neutral:hover {
  background-color: #4b5563;
}

/* ============================================
   LOADING SPINNERS - Unified System
   ============================================ */

/* Base spinner */
.spinner {
  display: inline-block;
  width: var(--spinner-size-lg);
  height: var(--spinner-size-lg);
  border: var(--spinner-border-width) solid rgba(125, 85, 132, 0.2);
  border-top-color: var(--sap-purple);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* Size variants */
.spinner-sm {
  width: var(--spinner-size-sm);
  height: var(--spinner-size-sm);
  border-width: 2px;
}

.spinner-md {
  width: var(--spinner-size-md);
  height: var(--spinner-size-md);
}

.spinner-lg {
  width: var(--spinner-size-lg);
  height: var(--spinner-size-lg);
}

/* Color variants */
.spinner-white {
  border-color: rgba(255, 255, 255, 0.3);
  border-top-color: white;
}

.spinner-pink {
  border-color: rgba(220, 25, 95, 0.2);
  border-top-color: var(--sap-hot-pink);
}

.spinner-purple {
  border-color: rgba(125, 85, 132, 0.2);
  border-top-color: var(--sap-purple);
}

/* Spinner animation */
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Loading overlay (covers parent container) */
.loading-overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(255, 255, 255, 0.8);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  z-index: 10;
  backdrop-filter: blur(2px);
}

.loading-overlay-dark {
  background-color: rgba(0, 0, 0, 0.5);
}

.loading-overlay .loading-text {
  color: var(--sap-purple);
  font-weight: 500;
  font-size: 0.875rem;
}

.loading-overlay-dark .loading-text {
  color: white;
}

/* Fullscreen loading */
.loading-fullscreen {
  position: fixed;
  inset: 0;
  background-color: rgba(255, 255, 255, 0.9);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  z-index: 9999;
}

/* Button loading state */
.btn-loading {
  position: relative;
  color: transparent !important;
  pointer-events: none;
}

.btn-loading::after {
  content: '';
  position: absolute;
  width: 1rem;
  height: 1rem;
  top: 50%;
  left: 50%;
  margin-left: -0.5rem;
  margin-top: -0.5rem;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

/* Inline spinner (for text) */
.spinner-inline {
  display: inline-block;
  width: 1em;
  height: 1em;
  vertical-align: middle;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
  opacity: 0.7;
}

/* Skeleton loading */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: 0.25rem;
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.skeleton-text {
  height: 1rem;
  margin-bottom: 0.5rem;
}

.skeleton-title {
  height: 1.5rem;
  width: 60%;
  margin-bottom: 1rem;
}

.skeleton-avatar {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
}

.skeleton-card {
  height: 8rem;
}

/* ============================================
   TOAST NOTIFICATIONS - SAP Branded
   ============================================ */

/* Toast Container */
#toast-container {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 400px;
  pointer-events: none;
}

/* Individual Toast */
.toast {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem;
  border-radius: 0.75rem;
  box-shadow:
    0 10px 25px -5px rgba(0, 0, 0, 0.2),
    0 8px 10px -6px rgba(0, 0, 0, 0.1);
  pointer-events: auto;
  animation: toast-slide-in 0.3s ease-out;
  position: relative;
  overflow: hidden;
}

.toast.toast-hiding {
  animation: toast-slide-out 0.3s ease-in forwards;
}

@keyframes toast-slide-in {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes toast-slide-out {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(100%);
    opacity: 0;
  }
}

/* Toast icon */
.toast-icon {
  flex-shrink: 0;
  width: 1.5rem;
  height: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.toast-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}

/* Toast content */
.toast-content {
  flex: 1;
  min-width: 0;
}

.toast-title {
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 0.25rem;
}

.toast-message {
  font-size: 0.875rem;
  opacity: 0.9;
  word-wrap: break-word;
}

/* Toast close button */
.toast-close {
  flex-shrink: 0;
  background: none;
  border: none;
  padding: 0.25rem;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity var(--transition-fast);
  border-radius: 0.25rem;
  color: inherit;
}

.toast-close:hover {
  opacity: 1;
  background-color: rgba(255, 255, 255, 0.1);
}

.toast-close svg {
  width: 1rem;
  height: 1rem;
}

/* Toast progress bar */
.toast-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background-color: rgba(255, 255, 255, 0.4);
  animation: toast-progress linear forwards;
}

@keyframes toast-progress {
  from {
    width: 100%;
  }
  to {
    width: 0%;
  }
}

/* Toast variants */
.toast-error {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  color: white;
}

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

.toast-warning {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: white;
}

.toast-info {
  background: linear-gradient(135deg, var(--sap-purple) 0%, var(--sap-hot-pink) 100%);
  color: white;
}

/* ============================================
   CONFIRM MODAL - SAP Branded
   ============================================ */

#confirm-modal-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10001;
  backdrop-filter: blur(4px);
  animation: fade-in 0.2s ease-out;
}

#confirm-modal-backdrop.hidden {
  display: none;
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.confirm-modal {
  background: white;
  border-radius: 1rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  max-width: 400px;
  width: 90%;
  overflow: hidden;
  animation: modal-scale-in 0.2s ease-out;
}

@keyframes modal-scale-in {
  from {
    transform: scale(0.95);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.confirm-modal-header {
  background: linear-gradient(90deg, var(--sap-purple) 0%, var(--sap-hot-pink) 100%);
  color: white;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.confirm-modal-header svg {
  width: 1.5rem;
  height: 1.5rem;
}

.confirm-modal-header h3 {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0;
}

.confirm-modal-body {
  padding: 1.5rem;
}

.confirm-modal-body p {
  color: #374151;
  font-size: 0.9375rem;
  line-height: 1.6;
  margin: 0;
}

.confirm-modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  background-color: #f9fafb;
  border-top: 1px solid #e5e7eb;
}

/* ============================================
   MODAL COMPONENTS
   ============================================ */

.modal-header-gradient {
  background: linear-gradient(90deg, var(--sap-purple) 0%, var(--sap-hot-pink) 100%);
}

.modal-header {
  background: linear-gradient(90deg, var(--sap-purple) 0%, var(--sap-hot-pink) 100%);
  color: white;
  padding: 1rem;
  border-top-left-radius: 0.75rem;
  border-top-right-radius: 0.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h2,
.modal-header h3 {
  margin: 0;
  font-weight: 600;
}

.modal-close-btn {
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 0.25rem;
  transition: background-color var(--transition-fast);
}

.modal-close-btn:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

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

.card-white {
  background-color: white;
  border-radius: 0.75rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.card {
  background-color: white;
  border-radius: 0.75rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.card-header {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #e5e7eb;
}

.card-body {
  padding: 1.5rem;
}

.card-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid #e5e7eb;
  background-color: #f9fafb;
}

/* ============================================
   FORM STYLING
   ============================================ */

.form-section {
  background: #f9fafb;
  padding: 1.5rem;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
}

.form-section-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--sap-purple);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--sap-hot-pink);
}

.form-group {
  margin-bottom: 1rem;
}

.form-label {
  display: block;
  font-weight: 500;
  font-size: 0.875rem;
  color: #374151;
  margin-bottom: 0.375rem;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  transition:
    border-color var(--transition-fast),
    box-shadow var(--transition-fast);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--sap-purple);
  box-shadow: 0 0 0 3px rgba(125, 85, 132, 0.15);
}

.form-input:disabled,
.form-select:disabled,
.form-textarea:disabled {
  background-color: #f3f4f6;
  cursor: not-allowed;
}

.form-error {
  color: var(--color-danger);
  font-size: 0.75rem;
  margin-top: 0.25rem;
}

/* ============================================
   SIDEBAR & NAVIGATION
   ============================================ */

.sidebar-icon {
  width: 1.25rem;
  height: 1.25rem;
  stroke-width: 2;
}

.sidebar-sticky {
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.page-title {
  color: var(--sap-purple);
}

.view-btn.active {
  background-color: var(--sap-purple);
  color: white;
}

.white-butterfly {
  filter: brightness(0) invert(1);
}

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

.calendar-day {
  min-height: 120px;
}

/* ============================================
   BADGES & TAGS
   ============================================ */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.625rem;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 9999px;
}

.badge-primary {
  background-color: rgba(220, 25, 95, 0.1);
  color: var(--sap-hot-pink);
}

.badge-secondary {
  background-color: rgba(125, 85, 132, 0.1);
  color: var(--sap-purple);
}

.badge-success {
  background-color: rgba(16, 185, 129, 0.1);
  color: var(--color-success);
}

.badge-danger {
  background-color: rgba(239, 68, 68, 0.1);
  color: var(--color-danger);
}

.badge-warning {
  background-color: rgba(245, 158, 11, 0.1);
  color: var(--color-warning);
}

.badge-neutral {
  background-color: rgba(107, 114, 128, 0.1);
  color: var(--color-neutral);
}

/* ============================================
   PRINT MODAL STUDENT LIST
   ============================================ */

@font-face {
  font-family: 'Macis';
  src: url('https://r2.crm.thesapproject.com/fonts/macis-regular-4.otf') format('opentype');
  font-weight: normal;
  font-style: normal;
  font-display: block;
}

@font-face {
  font-family: 'MyriadPro';
  src: url('https://r2.crm.thesapproject.com/fonts/MyriadPro-Black.otf') format('opentype');
  font-weight: 900;
  font-style: normal;
  font-display: block;
}

.print-student-list {
  max-height: 300px;
  overflow-y: auto;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 0.5rem;
}

.print-student-item {
  display: flex;
  align-items: center;
  padding: 0.5rem;
  border-bottom: 1px solid #f3f4f6;
}

.print-student-item:last-child {
  border-bottom: none;
}

.print-student-item input[type='checkbox'] {
  width: 1.25rem;
  height: 1.25rem;
  margin-right: 0.75rem;
  accent-color: var(--sap-purple);
}

#student-print-container {
  display: none;
}

/* ============================================
   PRINT STYLES - Student Labels
   ============================================ */

@media print {
  /* Hide everything by default when printing student list */
  body.printing-students * {
    visibility: hidden;
    margin: 0;
    padding: 0;
  }

  body.printing-students #student-print-container {
    display: block;
    visibility: visible;
    position: absolute;
    left: 0;
    top: 0;
  }

  body.printing-students #student-print-container * {
    visibility: visible;
  }

  /* Page setup - 8.5 x 11 inch (full letter) */
  body.printing-students .student-print-page {
    width: 8.5in;
    height: 11in;
    page-break-after: always;
    position: relative;
    box-sizing: border-box;
    margin: 0;
    padding: 0;
  }

  body.printing-students .student-print-page:last-child {
    page-break-after: avoid;
  }

  /* Cover page styling - centered in TOP HALF of page */
  body.printing-students .cover-page {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    text-align: center;
    padding-top: 2.75in;
  }

  body.printing-students .cover-frame {
    border: 4pt solid #000;
    padding: 0.5in 0.75in;
    display: inline-block;
  }

  body.printing-students .cover-school-name {
    font-family: 'MyriadPro', 'Arial Black', sans-serif;
    font-size: 36pt;
    font-weight: 900;
    margin-bottom: 0.25in;
    color: #000;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  body.printing-students .cover-class-name {
    font-family: 'MyriadPro', 'Arial Black', sans-serif;
    font-size: 24pt;
    font-weight: 900;
    color: #000;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  /* STUDENT NAME - Positioned by CENTER POINT using transform */
  body.printing-students .student-name {
    position: absolute;
    left: var(--name-center-from-left);
    top: var(--name-center-from-top);
    transform: translate(-50%, -50%);
    font-family: 'Macis', 'Georgia', serif;
    font-size: var(--name-font-size);
    font-weight: normal;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    margin: 0;
    padding: 0;
    color: #000;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  @page {
    size: 8.5in 11in;
    margin: 0;
  }
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */

@media (max-width: 640px) {
  #toast-container {
    left: 1rem;
    right: 1rem;
    max-width: none;
  }

  .toast {
    width: 100%;
  }

  .confirm-modal {
    width: 95%;
  }

  .confirm-modal-footer {
    flex-direction: column;
  }

  .confirm-modal-footer .btn {
    width: 100%;
  }
}
