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

/*-----------------------------------------*/
/***** Main layout styling *****/
/*-----------------------------------------*/
/* #region */
/* Colors:
background: #F1F5F9
borders: #C4C9CE
active borders: #1d2c51
Gray text for labels: #6c757d;
Dark text for info: #2D3748
Rounded corners: 0.375rem/6px
Disabled fields: #e9ecef
Buttons: #1d2c51
Purple dropdown highlight: #727ac5
Focus purple: #F2F4FA
*/

:root {
  --bs-body-bg: #ffffff;
  --bs-modal-bg: #ffffff;
  --bs-border-color: #C4C9CE;
}

body.demo-site {
  --bs-body-bg: #FAFAF9;
  --bs-modal-bg: #FAFAF9;
  background-color: #FAFAF9;
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

body {
  display: flex;
  flex-direction: column;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color: #2D3748;
  background-color:#ffffff
  /* 
  #F1F5F9 Warm Alabaster
  #F1F5F9 Cool porcelain

  #F5F5F4 Tech White - slightly too warm
  #F1F5F9 Cool porcelain
  #F8F7FF Soft Silk - lavender white, too cool
  Rice #FAF5EF
  #1A1A1A
  #2D2D2D
  */
}

/* Soften Bootstrap's text-dark and any harsh blacks */
.text-dark, .fw-bold.text-dark {
  color: #2D3748 !important;
}

.main-content {
  flex: 1;
  min-height: 0;
  /* Critical for nested flex scroll */
  display: flex;
  flex-direction: column;
  padding: 1rem;
}
/* #endregion */


/*-----------------------------------------*/
/***** Top Bar *****/
/*-----------------------------------------*/
/* #region */
.top-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  background-color: #E9EEF4;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem;
  z-index: 1001;
}

.top-bar-left,
.top-bar-right {
  flex: 1;
  display: flex;
  align-items: center;
}

.top-bar-right {
  justify-content: flex-end;
}

.top-bar-logo-link {
  display: block;
  line-height: 0;
  /* flex: none keeps the logo at its natural width and truly centered */
}

.top-bar-logo {
  width: 170px;
  height: auto;
}

.top-bar-profile-link {
  display: block;
  line-height: 0;
}

/* Toggle button — inside the top bar */
.sidebar-toggle-btn {
  width: 32px;
  height: 32px;
  border-radius: 0.4rem;
  background-color: transparent;
  border: 1px solid #E2E8F0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  padding: 0;
  transition: background-color 0.15s ease;
}

.sidebar-toggle-btn:hover {
  background-color: #E2E8F0;
}

.sidebar-toggle-btn i {
  font-size: 0.85rem;
  color: #1A1A1A;
}

/* Profile dropdown — anchored below the top bar, right side */
.top-bar-profile-panel {
  position: fixed;
  top: 60px;
  right: 0;
  background-color: #FAF9F6;
  border: 1px solid #E2E8F0;
  border-top: none;
  padding: 1rem 1.25rem;
  z-index: 1000;
  white-space: nowrap;
  box-shadow: -2px 2px 8px rgba(0, 0, 0, 0.06);
  min-width: 160px;
}

/* Offset main content and footer below the top bar */
@media (min-width: 768px) {
  body {
    padding-top: 60px;
  }

  .alerts-container {
    top: 85px;
    left: 0;
    width: 100%;
  }
}
/* #endregion */

/*-----------------------------------------*/
/***** Home nav cards *****/
/*-----------------------------------------*/
/* #region */
.nav-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #ed1c24;
  border: 1px solid #da151c;
  border-radius: 16px;
  padding: 2rem 1rem;
  text-decoration: none;
  height: 100%;
  text-align: center;
  box-shadow: 0 2px 4px rgba(29, 44, 81, 0.1), 0 1px 2px rgba(29, 44, 81, 0.1);
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-card:active {
  transform: scale(0.97);
  box-shadow: none;
}

.icon-box {
  font-size: 2rem;
  color: #FFFFFF;
  margin-bottom: 1rem;
}

.card-title {
  display: block;
  font-weight: 600;
  font-size: 1.1rem;
  color: #FFFFFF;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.card-subtitle {
  display: block;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.75);
  margin-top: 4px;
}

body.demo-site .nav-card {
  background: #1d2c51;
  border-color: #131d35;
}

/* #endregion */


/*-----------------------------------------*/
/***** Breadcrumbs *****/
/*-----------------------------------------*/
/* #region */
.page-wrapper {
  position: relative;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.breadcrumb-nav {
  display: flex;
  align-items: center;
  line-height: 1;
}

.breadcrumb-link {
  font-size: 0.65rem;
  font-weight: 400;
  color: #6c757d;
  text-decoration: none;
}

.breadcrumb-link:hover {
  color: #5e656b;
  text-decoration: none;
}

.mobile-back-btn {
  display: inline-flex;
  align-items: center;
  padding-left: 0.5rem !important;
  padding-right: 0.5rem !important;
}

.breadcrumb-sep {
  font-size: 0.65rem;
  color: #6c757d;
  margin: 0 0.25rem;
}

.breadcrumb-current {
  font-size: 0.65rem;
  font-weight: 400;
  color: #6c757d;
}
/* #endregion */


/*-----------------------------------------*/
/***** Sidebar Navigation *****/
/*-----------------------------------------*/
/* #region */
.sidebar {
  width: 95px;
  height: calc(100vh - 60px);
  position: fixed;
  left: 0;
  top: 60px;
  background-color: #ffffff;
  border-right: 1px solid #E2E8F0;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
  z-index: 1000;
  visibility: visible;
  transition: transform 0.25s ease, visibility 0s linear 0s;
}

body.demo-site .sidebar {
  background-color: #FAF9F6;
}

body.sidebar-closed .sidebar,
html.sidebar-closed-init .sidebar {
  transform: translateX(-80px);
  visibility: hidden;
  transition: transform 0.25s ease, visibility 0s linear 0.25s;
}

html.sidebar-closed-init .sidebar {
  transition: none; /* no animation on first paint */
}

/* Sidebar overlay — dims content when sidebar is open */
.sidebar-overlay {
  display: none;
}

@media (min-width: 768px) {
  .sidebar-overlay {
    display: block;
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0);
    z-index: 999;
    pointer-events: none;
    transition: background 0.25s ease;
  }

  /* Only show dim after JS has taken control — prevents flash on first paint */
  body.sidebar-js-ready:not(.sidebar-closed) .sidebar-overlay {
    background: rgba(0, 0, 0, 0.25);
    pointer-events: auto;
  }
}

.sidebar-link {
  display: block;
  margin-bottom: 1.25rem;
  color: #1A1A1A;
  text-align: center;
  text-decoration: none;
  padding: 0.4rem 0.25rem;
  border-radius: 0.5rem;
  transition: background-color 0.15s ease;
  width: 100%;
}

.sidebar-link:hover,
.sidebar-link.active {
  background-color: #E2E8F0;
  color: #1A1A1A;
}

.sidebar-link i {
  font-size: 1.4rem;
  display: block;
}

.sidebar-link span {
  font-size: 0.6rem;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.05em;
  display: block;
  margin-top: 0.2rem;
}
/* #endregion */


/*-----------------------------------------*/
/***** Main layout styling *****/
/*-----------------------------------------*/
/* #region */
.env-pill {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  z-index: 9999;
  padding: 0.3rem 0.85rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: white;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
  pointer-events: none;
}

.env-pill-dev {
  background-color: #28a745;
}

.env-pill-meevo {
  background-color: #fd7e14;
}
/* #endregion */


/*-----------------------------------------*/
/***** Every Page styling *****/
/*-----------------------------------------*/
/* #region */
.header-content .d-flex {
  min-height: 3rem;
}

.header-content h1 {
  text-transform: uppercase;
}

.header-item {
  margin-bottom: .75rem;
}

/* Only the breadcrumb slot needs a min-width to balance the right-side button */
.header-content .header-item:first-child {
  min-width: 120px;
}

.form-container {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 1rem;
}

.form-content {
  max-width: 1200px;
  margin: 0 auto;
}

.show-page-container {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.student-info-card {
  flex-shrink: 0;
}

.show-tab-card {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.show-tab-card > .nav-tabs {
  flex-shrink: 0;
}

.show-tab-card > .card-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}

.card-group {
  max-width: 1200px;
  margin: 0 auto;
  margin-bottom: 100px;
}
/* #endregion */


/*-----------------------------------------*/
/***** Navbar styling *****/
/*-----------------------------------------*/
/* #region */
.navbar {
  padding: 0.25rem; 
  position: relative;
  box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.07);
  display: flex;
  align-items:centere;
  min-height: 60px;
}

.navbar-brand {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0;
  position: static;
  transform: none;
}

@media (min-width: 1200px) {
  .navbar-brand {
    position: static;
    transform: none;
    left: auto;
  }
}

.navbar-brand img {
  max-width: 200px;
  height: auto;
}

.navbar-collapse {
  text-align: left;
  padding-left: 1rem;
}

.navbar-nav {
  margin-left: auto;
  margin-top: 0.5rem;
}

.navbar-large .nav-link {
  color: #6c757d; /* Ensure it takes on navbar link styling */
  font-size: 0.75rem; /* Make the nav links smaller */
  padding: 0.2rem; /* Adjust padding between links */
}

.navbar-profile-collapse {
  text-align: right;
  padding-right: 1rem; /* Add some padding for better appearance */
}

/* Profile Picture */
.profile-pic {
  border-radius: 50%;
  width: 40px;
  height: 40px;
  margin-right: 0.25rem;
  cursor: pointer;
}

.profile-toggle, .profile-placeholder {
  position: absolute;
  right: 1.5rem;
  top: 1rem;
  transform: translateY(-50%);
}

.profile-placeholder {
  width: 40px; /* Matches the profile picture size */
  height: 40px; /* Matches the profile picture size */
}

.navbar-name {
  font-size: 1rem;
  padding: 0.25rem;
}

.navbar-nav .nav-link {
  font-size: 1rem;
  padding: 0.25rem; /* Reduce space between links */
}

.navbar-toggler,
.navbar-toggler:focus,
.navbar-toggler:focus-visible {
  --bs-navbar-toggler-border-color: transparent;
  --bs-navbar-toggler-focus-width: 0;
  appearance: none;
  -webkit-appearance: none;
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
}

/* Mobile nav links match sidebar style */
#mobileNavbarMenu .nav-link {
  font-size: 0.6rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #1A1A1A;
  padding: 0.4rem 0.25rem;
}

#mobileNavbarMenu .nav-link:hover {
  background-color: #E2E8F0;
  border-radius: 0.5rem;
}

.navbar-nav .nav-link.active {
  color: lightgray;
}

/* Adjust navbar and logo for the smallest screens */
@media (max-width: 767.99px) { /* Targets screens smaller than Bootstrap's "sm" breakpoint */
  .navbar {
    padding: 0.25rem;
    min-height: unset;
  }

  .navbar-brand {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
  }

  .navbar-brand img { /* Target the logo inside the navbar */
    max-width: 110px;
    height: auto;
  }

  .navbar-toggler {
    padding: 0.15rem 0.4rem;
    font-size: 0.875rem;
    border: none;
    box-shadow: none;
    outline: none;
  }

  .navbar-toggler:focus {
    box-shadow: none;
    outline: none;
  }

  .navbar-nav .nav-link {
    font-size: 0.85rem;
    padding: 0.25rem;
  }

  .navbar-name {
    font-size: 0.85rem;
    padding: 0.25rem;
  }

  .profile-pic {
    width: 30px;
    height: 30px;
  }

  .container-fluid {
    min-height: 40px;
  }
}

/* Adjust navbar and logo for tablet and smaller screens */
@media (min-width: 768px) and (max-width: 1199.98px) {
  .navbar {
    padding: 0.5rem; /* Minimize padding around the navbar for tablets */
  }

  .navbar-brand {
    position: absolute;
    left: 50%; /* Left-align logo */
    transform: translateX(-50%); /* Remove centering styles */
  }

  .navbar-brand img { /* Shrink logo size */
    max-width: 175px; /* Shrink logo size for tablets */
    height: auto; /* Maintain aspect ratio */
  }

  .navbar-toggler {
    padding: 0.4rem 0.8rem;
    border: none;
    box-shadow: none;
    outline: none;
  }

  .navbar-toggler:focus {
    box-shadow: none;
    outline: none;
  }

  .navbar-nav .nav-link {
    font-size: .9rem; /* Make nav links smaller */
    padding: 0.25rem; /* Reduce space between links */
  }

  .navbar-name {
    font-size: 0.9rem;
    padding: 0.25rem;
  }
}
/* #endregion */


/*-----------------------------------------*/
/***** Link styling *****/
/*-----------------------------------------*/
/* #region */
.active {
  color: #2D3748 !important;
  text-decoration: none; /* Remove underline */
}

.link-hover {
  color: #6c757d; /* Initial link color */
  text-decoration: none;
}

.link-hover:hover {
  color: #2D3748; /* Hover color */
  text-decoration: underline; /* Optional: adds underline on hover */
}
/* #endregion */


/*-----------------------------------------*/
/***** Button styling *****/
/*-----------------------------------------*/
/* #region */
.apply-btn:disabled {
  opacity: 0.65 !important;
  pointer-events: none !important;
  color: #6c757d !important;
  background-color: #e9ecef !important;
  border-color: #adb5bd !important;
}

.apply-btn.needs-change {
  text-decoration: line-through;
  font-style: italic;
  font-size: small;
}

.btn:not(.fa-arrow-left):not(.md-btn):not(.date-nav-btn):not(.drop-down):not(.mobile-back-btn) {
  min-width: 100px;
  font-weight: 500;
}

.btn.disabled,
.btn:disabled,
fieldset:disabled .btn {
  color: #6c757d;
  background-color: #e9ecef;
  border-color: #adb5bd;
  border-width: 1px;
}


/* Font Awesome overrides Bootstrap's line-height on icon buttons, making them shorter */
.btn.fas {
  line-height: 1.5;
}

/* Custom dropdown toggle buttons */
.dropdown-toggle-custom {
  border: 0 !important;
  background-color: #ffffff !important;
  border-color: #C4C9CE !important;
  color: #4a5568 !important;
  border-left: 0;
  align-items: center;
  justify-content: center;
  /* Override Bootstrap 5 CSS variables so hover/active states don't go gray */
  --bs-btn-hover-bg: #ffffff;
  --bs-btn-hover-border-color: #C4C9CE;
  --bs-btn-hover-color: #4a5568;
  --bs-btn-active-bg: #ffffff;
  --bs-btn-active-border-color: #C4C9CE;
  --bs-btn-active-color: #4a5568;
}

/* Higher specificity (0,2,1) beats Bootstrap's .btn-outline-secondary default and interactive states */
button.btn.dropdown-toggle-custom,
button.btn.dropdown-toggle-custom:hover,
button.btn.dropdown-toggle-custom:active,
button.btn.dropdown-toggle-custom:focus,
button.btn.dropdown-toggle-custom.show {
  background-color: #ffffff !important;
  border-color: #C4C9CE !important;
  color: #4a5568 !important;
  box-shadow: none !important;
  outline: none !important;
}

/* Disabled state matches modern-select:disabled */
button.btn.dropdown-toggle-custom:disabled {
  background-color: #e9ecef !important;
  color: #adb5bd !important;
}

.dropdown-toggle-custom::after {
  display: block !important;
  content: '';
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  border: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23A0AABA'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 14px;
  transition: transform 0.2s ease-in-out;
}

[aria-expanded="true"].dropdown-toggle-custom::after {
  transform: rotate(180deg);
}

/* Size variants */
.dropdown-toggle-compact {
  width: 50px !important;
  flex: 0 0 25px !important;
  padding: 0 !important;
  min-width: auto !important;
  align-self: stretch !important;
}

.dropdown-toggle-compact::after {
  width: 10px !important;
  height: 10px !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%234a5568'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E") !important;
  background-size: 10px !important;
}

/* Focus ring on bordered wrapper divs (filter dropdowns, score box, days late, etc.)
   Excludes .collapsible-card so the outer Filters card never highlights — inner elements handle their own focus rings */
.border.rounded:not(.collapsible-card):has(.dropdown-toggle-compact):focus-within,
.border.rounded:not(.collapsible-card):has(.dropdown-toggle-standard):focus-within {
  border-color: #6c757d !important;
  background-color: #FFFFFF;
  box-shadow: none;
  outline: 0;
}

.border.rounded:not(.collapsible-card):has(.dropdown-toggle-compact):focus-within .form-control,
.border.rounded:not(.collapsible-card):has(.dropdown-toggle-compact):focus-within button.btn.dropdown-toggle-custom,
.border.rounded:not(.collapsible-card):has(.dropdown-toggle-standard):focus-within .form-control,
.border.rounded:not(.collapsible-card):has(.dropdown-toggle-standard):focus-within button.btn.dropdown-toggle-custom {
  background-color: #FFFFFF !important;
}

body.demo-site .border.rounded:not(.collapsible-card):has(.dropdown-toggle-compact):focus-within,
body.demo-site .border.rounded:not(.collapsible-card):has(.dropdown-toggle-standard):focus-within {
  border-color: #1d2c51 !important;
  background-color: #F2F4FA;
  box-shadow: none;
}

body.demo-site .border.rounded:not(.collapsible-card):has(.dropdown-toggle-compact):focus-within .form-control,
body.demo-site .border.rounded:not(.collapsible-card):has(.dropdown-toggle-compact):focus-within button.btn.dropdown-toggle-custom,
body.demo-site .border.rounded:not(.collapsible-card):has(.dropdown-toggle-standard):focus-within .form-control,
body.demo-site .border.rounded:not(.collapsible-card):has(.dropdown-toggle-standard):focus-within button.btn.dropdown-toggle-custom {
  background-color: #F2F4FA !important;
}

/* Remove bottom border/radius from wrapper when open, connect dropdown menu */
.border.rounded:not(.collapsible-card):has(.dropdown-toggle-compact.show),
.border.rounded:not(.collapsible-card):has(.dropdown-toggle-standard.show) {
  border-bottom-color: transparent !important;
  border-bottom-left-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}

.border.rounded:has(.dropdown-toggle-compact) .dropdown-menu {
  width: 70px;
  border-top-left-radius: 0;
  border-top-right-radius: 0;
  background-color: #FFFFFF;
  border-color: #6c757d;
}

.border.rounded:has(.dropdown-toggle-standard) .dropdown-menu {
  left: -1px !important;
  right: -1px !important;
  margin-top: 0 !important;
  border-top-left-radius: 0 !important;
  border-top-right-radius: 0 !important;
  background-color: #FFFFFF;
  border-color: #6c757d;
}

body.demo-site .border.rounded:has(.dropdown-toggle-compact) .dropdown-menu {
  background-color: #F2F4FA;
  border-color: #1d2c51;
}

body.demo-site .border.rounded:has(.dropdown-toggle-standard) .dropdown-menu {
  background-color: #F2F4FA;
  border-color: #1d2c51;
}

.border.rounded:has(.dropdown-toggle-compact) .form-control:focus,
.border.rounded:has(.dropdown-toggle-standard) .form-control:focus,
.collapsible-header .form-control:focus {
  box-shadow: none;
}

.collapsible-header button:focus,
.collapsible-header button:focus-visible {
  box-shadow: none !important;
  outline: none !important;
  border: none !important;
}

.dropdown-toggle-standard {
  width: 50px !important;
  flex: 0 0 40px !important;
  padding: 0.375rem 0.5rem !important;
  min-width: auto !important;
}

input[type="submit"].btn,
button.btn:not(.dropdown-toggle-custom):not(.btn-outline-danger),
a.btn:not(.btn-outline-danger) {
  background-color: #ed1c24 !important;
  border: 1px solid #da151c !important;
  border-radius: 10px;
  color: #ffffff !important;
  outline: none;
  text-decoration: none;
  box-shadow: 0 2px 4px rgba(29, 44, 81, 0.1), 0 1px 2px rgba(29, 44, 81, 0.1);
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

input[type="submit"].btn:hover,
button.btn:not(.dropdown-toggle-custom):not(.btn-outline-danger):hover,
a.btn:not(.btn-outline-danger):hover {
  background-color: #d0161b !important;
  border-color: #d0161b !important;
}

input[type="submit"].btn:active,
button.btn:not(.dropdown-toggle-custom):not(.btn-outline-danger):active,
a.btn:not(.btn-outline-danger):active {
  background-color: #c01114 !important;
  border-color: #c01114 !important;
  transform: scale(0.97);
  box-shadow: none;
}

input[type="submit"].btn:focus,
button.btn:not(.dropdown-toggle-custom):not(.btn-outline-danger):focus,
a.btn:not(.btn-outline-danger):focus {
  outline: none; /* Remove blue outline */
  box-shadow: none; /* Remove shadow or blue glow */
  background-color: #ed1c24 !important;
  border-color: #ed1c24 !important;
}

/* Demo site: slate button colors */
body.demo-site input[type="submit"].btn,
body.demo-site button.btn:not(.dropdown-toggle-custom):not(.btn-outline-danger),
body.demo-site a.btn:not(.btn-outline-danger) {
  background-color: #1d2c51 !important;
  border: 1px solid #131d35 !important;
  border-radius: 10px;
  color: #ffffff !important;
  font-weight: 500;
  box-shadow: 0 2px 4px rgba(29, 44, 81, 0.1), 0 1px 2px rgba(29, 44, 81, 0.1);
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

body.demo-site input[type="submit"].btn:hover,
body.demo-site button.btn:not(.dropdown-toggle-custom):not(.btn-outline-danger):hover,
body.demo-site a.btn:not(.btn-outline-danger):hover {
  background-color: #1e293b !important;
  border-color: #1e293b !important;
}

body.demo-site input[type="submit"].btn:active,
body.demo-site button.btn:not(.dropdown-toggle-custom):not(.btn-outline-danger):active,
body.demo-site a.btn:not(.btn-outline-danger):active {
  background-color: #16223e !important;
  border-color: #16223e !important;
  transform: scale(0.97);
  box-shadow: none;
}

body.demo-site input[type="submit"].btn:focus,
body.demo-site button.btn:not(.dropdown-toggle-custom):not(.btn-outline-danger):focus,
body.demo-site a.btn:not(.btn-outline-danger):focus {
  background-color: #1d2c51 !important;
  border-color: #1d2c51 !important;
}

/* Demo site: slate outline-danger buttons */
body.demo-site input[type="submit"].btn-outline-danger,
body.demo-site button.btn-outline-danger,
body.demo-site a.btn-outline-danger {
  color: #1d2c51 !important;
  border-color: #1d2c51 !important;
  background-color: var(--bs-body-bg) !important;
  border-radius: 10px;
  box-shadow: 0 2px 4px rgba(29, 44, 81, 0.1), 0 1px 2px rgba(29, 44, 81, 0.1);
}

body.demo-site input[type="submit"].btn-outline-danger:hover,
body.demo-site button.btn-outline-danger:hover,
body.demo-site a.btn-outline-danger:hover {
  color: #ffffff !important;
  background-color: #1d2c51 !important;
  border-color: #1d2c51 !important;
}

body.demo-site input[type="submit"].btn-outline-danger:active,
body.demo-site button.btn-outline-danger:active,
body.demo-site a.btn-outline-danger:active {
  color: #ffffff !important;
  background-color: #1e293b !important;
  border-color: #1e293b !important;
}

body.demo-site input[type="submit"].btn-outline-danger:focus,
body.demo-site button.btn-outline-danger:focus,
body.demo-site a.btn-outline-danger:focus {
  color: #ffffff !important;
  outline: none;
  box-shadow: none;
}

/* Demo site: slate nav tabs */
body.demo-site .nav-tabs .nav-link.active,
body.demo-site .nav-tabs .nav-link:hover {
  background-color: #1d2c51 !important;
  color: #fff !important;
}

/* Demo site: slate appointment modal tabs */
body.demo-site .appointment-modal-tabs .nav-item:has(.nav-link.active),
body.demo-site .appointment-modal-tabs .nav-item:has(.nav-link:hover),
body.demo-site .appointment-modal-tabs .nav-item:hover {
  background-color: #1d2c51 !important;
}

/* Brand-colored dropdown item highlights (replaces Bootstrap gray) */
.dropdown-item:hover,
.dropdown-item:focus {
  background-color: #ed1c24 !important;
  color: #ffffff !important;
}

.dropdown-item.active,
.dropdown-item:active {
  background-color: #c01114 !important;
  color: #ffffff !important;
}

/* Demo site: purple dropdown item highlights */
body.demo-site .dropdown-item:hover,
body.demo-site .dropdown-item:focus {
  background-color: #727ac5 !important;
  color: #ffffff !important;
}

body.demo-site .dropdown-item.active,
body.demo-site .dropdown-item:active {
  background-color: #5a63b0 !important;
  color: #ffffff !important;
}

/* Demo site: slate accordion buttons */
body.demo-site .accordion-button:not(.collapsed),
body.demo-site .accordion-button:hover {
  background-color: #1d2c51 !important;
  color: #fff !important;
}

body.demo-site .accordion-button:focus {
  box-shadow: 0 0 0 0.25rem rgba(166, 188, 255, 0.682);
}

/* Demo site: slate toggle switches */
body.demo-site .form-check-input:checked {
  background-color: #1d2c51 !important;
  border-color: #1d2c51 !important;
}

body.demo-site .form-check-input:focus {
  border-color: #1d2c51 !important;
  box-shadow: none !important;
}

input[type="submit"].btn-outline-danger,
button.btn-outline-danger,
a.btn-outline-danger { /* For .btn-outline-danger buttons, submit tags, and link_to buttons */
  color: #ed1c24;
  background-color: var(--bs-body-bg) !important;
  border-color: #ed1c24;
  border-radius: 10px;
  box-shadow: 0 2px 4px rgba(29, 44, 81, 0.1), 0 1px 2px rgba(29, 44, 81, 0.1);
  outline: none;
}

input[type="submit"].btn-outline-danger:hover,
button.btn-outline-danger:hover,
a.btn-outline-danger:hover {
  color: #ffffff;
  background-color: #ed1c24 !important;
  border-color: #ed1c24;
}

input[type="submit"].btn-outline-danger:active,
button.btn-outline-danger:active,
a.btn-outline-danger:active {
  color: #ffffff;
  background-color: #d0161b;
  border-color: #d0161b;
}

input[type="submit"].btn-outline-danger:focus,
button.btn-outline-danger:focus,
a.btn-outline-danger:focus {
  color: #ffffff;
  outline: none;
  box-shadow: none;
}

.small-arrow {
  font-size: 0.95em;
  margin-left: 0;
}
/* #endregion */


/*-----------------------------------------*/
/***** Form styling *****/
/*-----------------------------------------*/
/* #region */
.date-nav-input {
  padding: 0.375rem 0.75rem !important;
  height: auto !important;
  line-height: 1.5 !important;
}

.date-nav-btn {
  /* Ensure arrow buttons use same sizing as regular buttons */
  padding: 0.375rem 0.75rem;
}

.date-range-pill {
  background-color: #ed1c24;
  color: #ffffff;
  padding: 0.375rem 1rem;
  border-radius: 50px;
  font-weight: 600;
  box-shadow: 0 2px 4px rgba(237, 28, 36, 0.2);
  white-space: nowrap;
}

body.demo-site .date-range-pill {
  background-color: #1d2c51;
  box-shadow: 0 2px 4px rgba(29, 44, 81, 0.2);
}

.date-range-pill-clear {
  color: rgba(255, 255, 255, 0.75);
  line-height: 1;
  text-decoration: none;
}

.date-range-pill-clear:hover {
  color: white;
}

.date-nav-group {
  box-shadow: 0 2px 4px rgba(29, 44, 81, 0.05);
  border-radius: 8px;
  overflow: hidden;
}

.date-nav-input {
  border: 1px solid #C4C9CE !important;
  border-left: none !important;
  border-right: none !important;
  color: #1d2c51;
  text-align: center;
}

.form-control,
.form-select {
  width: 100%;
  font-size: 1rem;
  line-height: 1.5;
  background-color: #ffffff;
  color: #4a5568;
  padding: 0.375rem 0.75rem;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Style the switch track — scoped to form-switch only */
.form-switch .form-check-input {
  appearance: none;
  width: 36px;
  height: 18px;
  background-color: #fff;
  border: 1px solid;
  border-color: #adb5bd;
  border-radius: 12px;
  position: relative;
  cursor: pointer;
  transition: background-color 0.3s, border-color 0.3s;
}

.form-switch .form-check-input:checked {
  background-color: #ed1c24;
  border-color: #ed1c24;
}

.form-switch .form-check-label {
  font-size: 0.925em;
}

.form-switch .form-check-input:focus {
  border-color: #6c757d;
  box-shadow: none;
}

body.demo-site .form-switch .form-check-input:focus {
  border-color: #1d2c51 !important;
  box-shadow: none !important;
}

/* Form control (text, date, time, number, textarea) focus */
.form-control:focus,
.form-select:focus {
  outline: none;
  box-shadow: none !important;
  border: 1px solid #6c757d !important;
  background-color: #FFFFFF;
}

body.demo-site .form-control:focus,
body.demo-site .form-select:focus {
  border: 1px solid #1d2c51 !important;
  background-color: #F2F4FA;
}

/* Inside input-groups, suppress individual focus border so it doesn't
   visually split the field from its connected button */
.input-group .form-control:focus,
.input-group .form-select:focus {
  box-shadow: none !important;
  outline: 0;
}

/* Checkbox styling */
.form-check-input[type="checkbox"]:checked {
  background-color: #ed1c24;
  border-color: #ed1c24;
}

.form-check-input[type="checkbox"]:focus {
  border-color: #6c757d;
  box-shadow: none;
  outline: none;
}

/* Override Bootstrap's filter:brightness active state — CSS filter creates a compositing
   layer that gets clipped incorrectly by overflow:hidden ancestors (modal-content, turbo-frame) */
.form-check-input[type="checkbox"]:active {
  filter: none;
  background-color: #c01114;
  border-color: #c01114;
}

body.demo-site .form-check-input[type="checkbox"]:checked {
  background-color: #1d2c51 !important;
  border-color: #1d2c51 !important;
}

body.demo-site .form-check-input[type="checkbox"]:focus {
  border-color: #1d2c51 !important;
  box-shadow: none !important;
  outline: none;
}

body.demo-site .form-check-input[type="checkbox"]:active {
  filter: none !important;
  background-color: #162040 !important;
  border-color: #162040 !important;
}

/* Remove border between input and dropdown button in input groups */
.input-group>.form-control:not(:last-child) {
  border-right: 0;
}

.input-group>.dropdown-toggle-custom {
  border-left: 0;
  margin-left: 0 !important;
}
/* #endregion */


/*-----------------------------------------*/
/***** Filter input container rounded corners *****/
/*-----------------------------------------*/
/* #region */
.filter-input-container .form-control {
  border-bottom-left-radius: calc(0.375rem - 1px);
}

.filter-input-container .dropdown-toggle-custom {
  border-bottom-right-radius: calc(0.375rem - 1px);
}
/* #endregion */


/*-----------------------------------------*/
/***** Collapsible card rounded corners *****/
/*-----------------------------------------*/
/* #region */

/* Header bottom corners — visible when card is collapsed */
.collapsible-header {
  cursor: pointer;
  overflow: hidden;
  background-color: #ffffff;
  border-radius: calc(0.375rem - 1px);
}

.collapsible-header:has(+ .collapse.show) {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
}

.collapsible-card {
  background-color: #ffffff;
}

.collapsible-card {
  box-shadow:
    0 4px 6px -1px rgba(29, 44, 81, 0.08),
    0 10px 20px -5px rgba(29, 44, 81, 0.04);
  transition: box-shadow 0.3s ease;
}

.collapsible-card .collapsible-header .form-control {
  border-bottom-left-radius: calc(0.375rem - 1px);
  cursor: pointer;
  background-color: #ffffff;
  pointer-events: none;
}

.collapsible-card .collapsible-header .dropdown-toggle-custom {
  border-bottom-right-radius: calc(0.375rem - 1px);
  border-left: 0 !important;
}


/* Content bottom corners — visible when card is expanded */
.collapsible-card .collapse .p-3 {
  border-bottom-left-radius: calc(0.375rem - 1px);
  border-bottom-right-radius: calc(0.375rem - 1px);
}
/* #endregion */


/*-----------------------------------------*/
/***** Select2 and dropdown type-to-search styling *****/
/*-----------------------------------------*/
/* #region */
.select2-container--default .select2-selection--single {
  background-color: #ffffff;
  border: 1px solid #C4C9CE;
  border-radius: 0.375rem;
  height: auto;
  padding: 0.375rem 2rem 0.375rem 0.75rem;
  font-family: inherit;
  font-size: inherit;
  line-height: 1.5;
  color: #4a5568;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
  color: #4a5568;
  line-height: 1.5;
  padding: 0;
  font-family: inherit;
}

.select2-container--default .select2-selection--single .select2-selection__placeholder {
  color: #6c757d;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
  height: 100%;
  top: 0;
  right: 8px;
  width: 30px;
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
  border: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23A0AABA'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 14px;
  width: 14px;
  height: 14px;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
}

.select2-container .select2-selection--single {
  display: flex;
  align-items: center;
}

.select2-container--disabled {
  pointer-events: none !important;
  cursor: not-allowed !important;
}

.select2-container--disabled .select2-selection--single {
  background-color: #ffffff !important;
  border-color: #C4C9CE !important;
}

.select2-container--disabled .select2-selection--single .select2-selection__rendered,
.select2-container--disabled .select2-selection--single .select2-selection__placeholder {
  color: #adb5bd !important;
}

body.demo-site .select2-container--disabled .select2-selection--single {
  background-color: #FAFAF9 !important;
}

.select2-container--default.select2-container--focus .select2-selection--single,
.select2-container--default.select2-container--open .select2-selection--single {
  border: 1px solid #6c757d !important;
  background-color: #FFFFFF !important;
  box-shadow: none !important;
  outline: none !important;
}

.select2-container--default.select2-container--focus .select2-selection--single .select2-selection__rendered,
.select2-container--default.select2-container--open .select2-selection--single .select2-selection__rendered {
  margin-left: -1px;
}

body.demo-site .select2-container--default.select2-container--focus .select2-selection--single,
body.demo-site .select2-container--default.select2-container--open .select2-selection--single {
  border: 1px solid #1d2c51 !important;
  background-color: #F2F4FA !important;
}

.select2-dropdown {
  background-color: #FFFFFF;
  border: 1px solid #C4C9CE;
  border-radius: 12px;
  font-family: inherit;
  font-size: inherit;
  color: #6c757d;
  box-shadow:
    0 4px 6px -1px rgba(29, 44, 81, 0.1),
    0 10px 15px -3px rgba(29, 44, 81, 0.1),
    0 20px 25px -5px rgba(29, 44, 81, 0.05);
}

.select2-container--open .select2-dropdown {
  border: 1px solid #6c757d;
}

body.demo-site .select2-container--open .select2-dropdown {
  border: 1px solid #1d2c51;
  background-color: #F2F4FA;
}

/* Single border join between selection field and dropdown */
.select2-container--open.select2-container--below .select2-selection--single {
  border-bottom-color: transparent !important;
  border-bottom-left-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}

.select2-dropdown--below {
  margin-top: -2px;
  border-top-left-radius: 0 !important;
  border-top-right-radius: 0 !important;
}

.select2-container--open.select2-container--above .select2-selection--single {
  border-top-color: transparent !important;
  border-top-left-radius: 0 !important;
  border-top-right-radius: 0 !important;
}

.select2-dropdown--above {
  margin-top: 2px;
  border-bottom-left-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}

.select2-search--dropdown .select2-search__field {
  background-color: #FFFFFF;
  border: 1px solid #C4C9CE;
  border-radius: 0.375rem;
  color: #6c757d;
  font-family: inherit;
  font-size: inherit;
  outline: none;
}

.select2-search--dropdown .select2-search__field:focus {
  border: 1px solid #6c757d;
  background-color: #FFFFFF;
}

body.demo-site .select2-search--dropdown .select2-search__field {
  background-color: #F2F4FA;
}

body.demo-site .select2-search--dropdown .select2-search__field:focus {
  background-color: #F2F4FA;
}

.select2-container--default .select2-results__option:not(.select2-results__option--highlighted) {
  background-color: #FFFFFF !important;
  color: inherit !important;
}

.select2-container--default .select2-results__option--highlighted {
  background-color: #ed1c24 !important;
  color: white !important;
}

body.demo-site .select2-container--default .select2-results__option:not(.select2-results__option--highlighted) {
  background-color: #F2F4FA !important;
  color: inherit !important;
}

body.demo-site .select2-container--default .select2-results__option--highlighted {
  background-color: #727ac5 !important;
  color: white !important;
}
/* #endregion */


/*-----------------------------------------*/
/***** Alert Styling *****/
/*-----------------------------------------*/
/* #region */
.alerts-container {
  position: fixed;
  top: 85px; /* Mobile: clears the hamburger navbar */
  left: 0;
  width: 100%;
  z-index: 1050;
  pointer-events: none;
  padding: 0 15px;
}

.alerts-container .alert {
  pointer-events: auto;
  margin: 0 auto 0.5rem;
  max-width: 500px;

  background-color: var(--bs-modal-bg, #ffffff);
  border: 1px solid #C4C9CE;
  border-left: 4px solid #6c757d;
  border-radius: 0.5rem;
  box-shadow: 0px 4px 16px rgba(0, 0, 0, 0.15);
  color: #2D3748;
  text-align: left;
}

.alerts-container .alert-danger  { border-left-color: #dc3545; }
.alerts-container .alert-info    { border-left-color: #1d2c51; }
.alerts-container .alert-warning { border-left-color: #d97706; }
.alerts-container .alert-success { border-left-color: #16a34a; }

#gradeSuccessToast {
  background-color: var(--bs-modal-bg, #ffffff);
  border: 1px solid #C4C9CE;
  border-left: 4px solid #16a34a;
  border-radius: 0.5rem;
  box-shadow: 0px 4px 16px rgba(0, 0, 0, 0.15);
  color: #2D3748;
}

/* Adjust the font size of the badge if necessary */
.badge {
  font-size: 0.75rem;
}

/* Filter count badges — gray on buttons by default (production) */
#filter-badge,
.bg-filter-count {
  background-color: #9ca8b3 !important;
  color: white !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
}

/* Red badge inside collapsible filter headers (white background) */
.collapsible-header .bg-filter-count {
  background-color: #ed1c24 !important;
  color: white !important;
}

/* Demo site: purple filter badges */
body.demo-site #filter-badge,
body.demo-site .bg-filter-count {
  background-color: #727ac5 !important;
  color: white !important;
}

/* Optional: Ensure the badge doesn't overflow on smaller screens */
.btn .badge {
  white-space: nowrap;
  background-color: #9ca8b3;
  color: white; /* Ensures text is readable */
  font-size: 0.75rem; /* Adjust font size for better fit */
  border-radius: 5px; /* Slight rounding for a modern look */
  white-space: nowrap; /* Prevents badge text from wrapping */
  position: absolute;
  top: 0;
  transform: translate(-50%, -50%);
}

/* #endregion */


/*-----------------------------------------*/
/***** Sort styling *****/
/*-----------------------------------------*/
/* #region */
.sort-icon {
  font-size: 0.75rem;
  margin-left: 0.25rem;
  display: inline-block;
  vertical-align: baseline;
}

.sort-status-header {
  position: relative;
  display: inline-flex !important;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.sort-status-header .sort-icon {
  position: absolute;
  left: calc(50% + 8px);
  margin-left: 0;
}

.sort-asc::before {
  content: "\2191"; /* Unicode for up arrow */
}

.sort-desc::before {
  content: "\2193"; /* Unicode for down arrow */
}
/* #endregion */


/*-----------------------------------------*/
/***** Table styling *****/
/*-----------------------------------------*/
/* #region */
/* Appointments page layout */
.appointments-page {
  flex: 1;
  min-height: 0; /* Critical for scroll containment */
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.students-page {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.students-table {
  flex: 1;
  min-height: 0;
  overflow: auto;
  border: 1px solid #C4C9CE;
  display: flex;
  flex-direction: column;
}

.service-categories-page {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.service-categories-table {
  flex: 1;
  min-height: 0;
  overflow: auto;
  border: 1px solid #C4C9CE;
  display: flex;
  flex-direction: column;
}

/* Frame containment */
#appointments-frame {
  flex: 1;
  min-height: 0; /* Critical for scroll */
  display: flex;
  flex-direction: column;
}

/* Frame containment for students claim page */
#students-frame {
  flex: 1;
  min-height: 0;
  /* Critical for scroll */
  display: flex;
  flex-direction: column;
}

/* Reusable panel shadow — apply to any surface that shouldn't clip its own shadow */
.panel-shadow {
  box-shadow:
    0 4px 6px -1px rgba(29, 44, 81, 0.08),
    0 10px 20px -5px rgba(29, 44, 81, 0.04);
  transition: box-shadow 0.3s ease;
}

/* Table shadow wrapper — overflow: visible so shadow isn't clipped */
.appointments-table-shadow {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

/* Table container */
.table-hover {
  --bs-table-hover-bg: rgba(226, 232, 240, 0.5);
}

body.demo-site .table-hover {
  --bs-table-hover-bg: rgba(0, 0, 0, 0.02);
}

.appointments-table {
  flex: 1;
  min-height: 0; /* Enables proper scrolling */
  overflow: auto;
  border: 1px solid #C4C9CE;
  display: flex;
  flex-direction: column;
}

.table-wrapper {
  flex: 1;
  overflow: auto;
}

.table-wrapper tbody tr,
.table-wrapper tbody td,
.table-wrapper tbody th {
  background-color: #ffffff;
}

.table-wrapper tbody td {
  border-bottom: 1px solid #C4C9CE;
}

.table-wrapper thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background-color: #E2E8F0;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: #6c757d;
  border-bottom: 1px solid #C4C9CE;
  padding: 8px 8px;
  vertical-align: bottom;
  box-shadow: 0 2px 4px -1px rgba(29, 44, 81, 0.08), 0 4px 8px -2px rgba(29, 44, 81, 0.04);
  clip-path: inset(0 -1px -20px -1px);
  white-space: nowrap;
}

.table-wrapper tbody td {
  padding: 14px 10px 10px;
  vertical-align: top;
}

.table-wrapper tbody td div {
  line-height: 1.2;
  margin-bottom: 1px;
}

.table-wrapper tbody td div:last-child {
  margin-bottom: 0;
}

 /* Custom Row Styling */
.appointment-row {
  transition: all 0.2s ease;
  border-bottom: 1px solid #C4C9CE !important;
}

 /* iPad Touch Feedback: Subtle highlight when tapped */
.appointment-row:active {
  background-color: #f0f7ff !important;
  transform: scale(0.995);
}

/* Compensate for internal border+padding of boxed elements so their text
   aligns with the first line of text in adjacent cells */
[data-controller="inline-instructor"],
.room-cell {
  padding-top: 9px !important;
  /* 14px cell padding - 1px border - 4px internal top padding */
}

.table-fixed {
  table-layout: fixed;
  width: 100%;
}

.table-padded td,
.table-padded th {
  padding: 0.55rem 0.5rem;
}

.clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Fixed header */
.table-fixed thead th {
  position: sticky;
  top: 0;
  background-color: #f8f9fa;
  z-index: 1;
  white-space: nowrap;
}

.table thead {
  border-bottom: 1px solid #D4D8DC;
}

.show-tab-card thead th {
  background-color: #E2E8F0;
}

.filter-section {
  margin-bottom: .5rem;
  margin-top: .5rem;
}

#filterMenu {
  margin-top: .5rem;
}
/* #endregion */


/*-----------------------------------------*/
/***** Accordion styling *****/
/*-----------------------------------------*/
/* #region */
.accordion-header button {
  font-weight: bold;
  background-color: #f8f9fa;
  color: #6c757d;
}

.accordion-header button.collapsed {
  color: #6c757d;
}

.accordion-header button:hover,
.accordion-header button.collapsed:hover,
.accordion-button:hover {
  color: #fff; /* Ensure white text on hover */
}

.accordion-body {
  background-color: #ffffff;
  padding: 1rem;
}

/* Default state of accordion button */
.accordion-button {
  color: #6c757d; /* Text color */
  transition: background-color 0.3s, border-color 0.3s, color 0.3s;
}

/* Active state of accordion button */
.accordion-button:not(.collapsed) {
  background-color: #ed1c24;
  color: #fff;
}

/* Hover on active state */
.accordion-button:not(.collapsed):hover {
  color: #fff; /* Maintain white text */
}

/* Focused state of accordion button */
.accordion-button:focus {
  box-shadow: 0 0 0 0.2rem rgba(237, 28, 36, 0.25);
  outline: none;
}

/* Optional: Hover state for better feedback */
.accordion-button:hover {
  background-color: #ed1c24; /* Slightly darker red */
  color: #fff; /* Maintain white text */
}

.accordion-button::after {
  background-image: none !important;
  background: none;
  /* Remove Bootstrap's default arrow */
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
  content: '\f078';
  /* fa-chevron-down */
  transform: rotate(0deg);
  transition: transform 0.2s ease-in-out;
}

.accordion-button:not(.collapsed)::after {
  transform: rotate(-180deg);
  /* Rotate to point up when expanded */
}
/* #endregion */


/*-----------------------------------------*/
/***** Nav Tabs styling (Theory Page) *****/
/*-----------------------------------------*/
/* #region */
.nav-tabs {
  border-bottom: 2px solid #C4C9CE
}
/* Default state of nav-tab link */
.nav-tabs .nav-link {
  color: #6c757d;
  /* Gray text for inactive */
  font-weight: bold;
  background-color: #f8f9fa;
  transition: background-color 0.3s, border-color 0.3s, color 0.3s;
  border-radius: 0;
  border: none;
  border-bottom: none;
}

/* Active state of nav-tab */
.nav-tabs .nav-link.active {
  background-color: #ed1c24;
  color: #fff !important;
}

/* Hover state for all tabs */
.nav-tabs .nav-link:hover {
  background-color: #ed1c24;
  color: #fff;
  border-bottom: none;
}

/* Hover on active tab */
.nav-tabs .nav-link.active:hover {
  color: #fff;
}

.nav-tabs .nav-item:first-child .nav-link {
  border-top-left-radius: 0.375rem;
  border-right: 2px solid #C4C9CE;
  /* Gray divider */
}

.nav-tabs .nav-item:last-child .nav-link {
  border-top-right-radius: 0.375rem;
}

.nav-tabs .nav-item:first-child .nav-link.active {
  border-right-color: #C4C9CE;
}

.nav-tabs .nav-item:first-child .nav-link:hover {
  border-right-color: #C4C9CE;
}

.nav-tabs .nav-item.tab-divider .nav-link {
  border-right: 2px solid #C4C9CE;
}

.nav-tabs .nav-item.tab-divider .nav-link.active,
.nav-tabs .nav-item.tab-divider .nav-link:hover {
  border-right-color: #C4C9CE;
}

/* #endregion */


/*-----------------------------------------*/
/* Modal Header / Footer Sizing */
/*-----------------------------------------*/
/* #region */
.modal-content {
  background-color: #ffffff;
  box-shadow:
    0 4px 6px -1px rgba(29, 44, 81, 0.1),
    0 10px 15px -3px rgba(29, 44, 81, 0.1),
    0 20px 25px -5px rgba(29, 44, 81, 0.05);
}

/* Match the compact height of the tab-bar header (nav-link uses 0.5rem padding) */
.modal-header,
.modal-footer {
  padding: 0.5rem 1rem;
}

.modal-footer {
  border-top: none;
  padding-top: 0;
}

.modal-title {
  font-size: 1rem;
  font-weight: bold;
  color: #6c757d;
}
/* #endregion */


/*-----------------------------------------*/
/* Appointment Modal Tab Bar */
/*-----------------------------------------*/
/* #region */
.appointment-modal-tabs {
  border-bottom: 2px solid #D4D8DC;
}

.appointment-modal-tabs .nav-item {
  background-color: #f8f9fa;
}

.appointment-modal-tabs .nav-item:has(.nav-link.active),
.appointment-modal-tabs .nav-item:has(.nav-link:hover),
.appointment-modal-tabs .nav-item:hover {
  background-color: #ed1c24;
}

.appointment-modal-tabs .nav-link {
  background-color: transparent;
}

.appointment-modal-close {
  transition: filter 0.2s;
}

/* X button turns white when its nav-item has a colored background */
.appointment-modal-tabs .nav-item:has(.nav-link.active) .appointment-modal-close,
.appointment-modal-tabs .nav-item:has(.nav-link:hover) .appointment-modal-close,
.appointment-modal-tabs .nav-item:hover .appointment-modal-close {
  filter: invert(1);
}

#appointmentModal .modal-content {
  overflow: hidden;
}

#deleteConfirmModal {
  z-index: 1060;
}
#deleteConfirmModal + .modal-backdrop {
  z-index: 1059;
}

#appointmentModal turbo-frame {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

#appointmentModal .modal-header {
  flex-shrink: 0;
  z-index: 10;
  background: #ffffff;
  width: 100%;
}

#appointmentModal .modal-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding-bottom: 1rem;
}

#gradeModal .modal-body {
  padding-bottom: 1rem;
}

#appointmentModal .form-container {
  overflow-y: visible;
  padding: 0;
  flex: none;
  min-height: auto;
}

/* iOS Safari reports 100vh including hidden browser chrome, which makes modals
   overflow the visible area in landscape. dvh tracks the actual visible viewport. */
@supports (height: 100dvh) {
  .modal-dialog-scrollable {
    max-height: calc(100dvh - 1rem);
  }
  .modal-dialog-centered.modal-dialog-scrollable {
    max-height: calc(100dvh - 1rem);
  }
}

/* Tighten appointment grade/edit modal on landscape iPad so less scrolling is needed.
   Halves the row margins and gutters (mb-md-3 → 0.5rem, g-md-3 → 0.5rem). */
@media (orientation: landscape) and (max-height: 900px) {
  #appointmentModal .modal-body {
    padding: 0.5rem 0.75rem 0.5rem;
  }
  #appointmentModal .form-content .row {
    margin-bottom: 0.5rem !important;
    --bs-gutter-y: 0.5rem;
    --bs-gutter-x: 2rem;
  }
}

.grade-btn-group {
  display: flex;
  width: 100%;
  border: 1px solid #C4C9CE;
  border-radius: 0.375rem;
  overflow: hidden;
}

.grade-radio {
  display: none;
}

.grade-option {
  flex: 1;
  min-width: 0;
  text-align: center;
  padding: 0.25rem 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: #6c757d;
  cursor: pointer;
  border: none;
  border-left: 1px solid #C4C9CE;
  background: #ffffff;
  user-select: none;
  line-height: 1.5;
}

.grade-option:first-of-type {
  border-left: none;
}

.grade-radio:checked + .grade-option {
  background-color: #6c757d;
  color: white;
}
/* #endregion */

/*-----------------------------------------*/
/***** Progress Bar styling *****/
/*-----------------------------------------*/
/* #region */
.progress {
  height: 20px;
  border-radius: 10px;
  background-color: #ffffff;
  border: 1px solid #C4C9CE;
  position: relative;
}

.progress-container .progress::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 2px 4px rgba(29, 44, 81, 0.1);
  pointer-events: none;
  z-index: 2;
}

.progress-bar {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 0 4px;
  height: 100%;
  line-height: 1;
}

.progress-bar.bg-success {
  background-color: #ed1c24 !important; /* Red for Complete */
}

body.demo-site .progress-bar.bg-success {
  background-color: #1d2c51 !important;
}

.progress-bar.bg-danger {
  background-color: hsla(213, 18%, 44%, 0.8) !important; /* Dark gray for Incomplete */
}

body.demo-site .progress-bar.bg-danger,
body.demo-site .progress-bar.bg-secondary {
  background-color: #727ac5 !important;
}

.progress-bar[data-bs-toggle="tooltip"]::after {
  content: attr(title);
  position: absolute; /* Out of flex flow so it never pushes the <span> out */
  visibility: hidden;
}

.progress-bar:hover[data-bs-toggle="tooltip"]::after {
  visibility: visible;
}

.progress-bar span {
  display: inline-block; /* Ensure text is treated as a single block */
  max-width: 100%; /* Restrict width to fit within the progress bar */
  overflow: hidden; /* Hide text overflow */
  text-overflow: ellipsis; /* Display ellipsis */
  white-space: nowrap; /* Prevent wrapping */
}

.status-dot {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.status-dot-complete { background: #ed1c24; }
.status-dot-active   { background: hsla(213, 18%, 44%, 0.8); }
.status-dot-upcoming { background: #C4C9CE; }

body.demo-site .status-dot-complete { background: #1d2c51; }
body.demo-site .status-dot-active   { background: #727ac5; }
/* #endregion */


/*-----------------------------------------*/
/***** Generic styling *****/
/*-----------------------------------------*/
/* #region */
.bold {
  font-weight: bold;
}

.filter-label {
  font-size: 0.75rem;
  font-weight: bold;
  color: #6c757d;
}

.form-value {
  line-height: 1.5;
}

input.form-control-plaintext[readonly],
div.form-control-plaintext {
  padding-top: 0;
  border-top: 0;
}

/* Filter dropdown wrapper — matches modern-select appearance */
[data-controller="filter-dropdown"] .border {
  border-color: #C4C9CE !important;
  border-radius: 0.375rem !important;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

[data-controller="filter-dropdown"] .border:focus-within {
  border-color: #C4C9CE !important;
  box-shadow: none !important;
}

body.demo-site [data-controller="filter-dropdown"] .border:focus-within {
  border-color: #C4C9CE !important;
  box-shadow: none !important;
}

[data-controller="filter-dropdown"].filter-active .border {
  border-color: #6c757d !important;
  background-color: #FFFFFF !important;
  box-shadow: none !important;
}

[data-controller="filter-dropdown"].filter-active .border .form-control,
[data-controller="filter-dropdown"].filter-active .border .btn {
  background-color: #FFFFFF !important;
}

body.demo-site [data-controller="filter-dropdown"].filter-active .border {
  border-color: #1d2c51 !important;
  background-color: #F2F4FA !important;
  box-shadow: none !important;
}

body.demo-site [data-controller="filter-dropdown"].filter-active .border .form-control,
body.demo-site [data-controller="filter-dropdown"].filter-active .border .btn {
  background-color: #F2F4FA !important;
}


[data-controller="filter-dropdown"] .form-control {
  color: #6c757d;
  font-family: inherit;
  font-size: inherit;
  pointer-events: none;
}

[data-controller="filter-dropdown"] .dropdown-menu {
  font-size: 0.875rem;
}

[data-controller="filter-dropdown"] .dropdown-item {
  color: #6c757d;
}

.centered-content {
  display: flex;
  justify-content: center;
}
/* #endregion */


/*-----------------------------------------*/
/***** Specific styling *****/
/*-----------------------------------------*/
/* #region */
.apply-btn, .today-btn { /* Appointment Index buttons */
  width: auto;
}
/* #endregion */


/*-----------------------------------------*/
/***** Responsive Styling *****/
/*-----------------------------------------*/
/* #region */
/* Small screens (phones) */
@media (max-width: 767.99px) {
  body {
    font-size: 0.75rem;
  }

  .main-content {
    padding: .75rem;
  }

  h1 {
    font-size: 1rem;
  }

  .header-content .d-flex {
    flex-wrap: wrap;
  }

  .header-content h1 {
    position: static !important;
    transform: none !important;
    order: -1;
    width: 100%;
    text-align: center !important;
    margin-bottom: 0.25rem;
  }

  .header-content .header-item:first-child {
    min-width: 0;
  }

  h2 {
    font-size: 1rem;
  }

  .btn {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 5px 10px;
    width: auto; /* Allows the buttons to fit side-by-side */
  }

  .btn:not(.fa-arrow-left):not(.md-btn):not(.date-nav-btn):not(.mobile-back-btn) {
    width: 100px;
  }

  .table {
    font-size: 0.75rem;
    letter-spacing: 0.025rem;
    margin-bottom: .5rem;
  }

  .table td, .table th {  /* Define a max-width for each cell */
    width: 100%;
    overflow: hidden;
  }

  .small-screen-form {
    gap: 5px; /* Controls space between elements */
    justify-content: flex-start;
  }

  .button-container .d-grid {
    display: flex !important;
    justify-content: flex-end !important;
  }

  .footer {
    background-color: #E9EEF4;
    box-shadow: 0 -1px 4px rgba(0, 0, 0, 0.08);
    width: 100%;
    height: 30px;
    max-height: 30px;
    display: flex;
    align-items: center;
    text-align: center;
  }

  .footer-logo {
    max-width: 80px; 
    height: auto;
  }

  .date-nav {
    margin-right: 10px;
  }

  .date-nav-input {
    font-size: .85rem;
    padding: 5px 10px;
  }

  .date-nav-btn {
    font-size: 0.85rem;
    padding: 5px 10px;
  }

  .nav-card {
    padding: 1rem 0.75rem;
  }

  .icon-box {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
  }

  .card-title {
    font-size: 0.9rem;
  }

  .card-subtitle {
    font-size: 0.65rem;
  }
}

/* Medium screens (tablets) */
@media (min-width: 768px) and (max-width: 1260.98px) {
  body {
    font-size: 0.85rem;
  }

  h1 {
    font-size: 1.2rem;
  }

  h2 {
    font-size: 1rem;
  }

  .btn {
    font-size: 0.85rem;
    letter-spacing: 0.025rem;
  }

  .table thead th {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.025em;
    text-transform: uppercase;
  }

  .form-control, .form-select {
    font-size: .85rem;
  }

  .date-nav-input {
    font-size: .85rem;
  }

  .select2 {
    font-size: .85rem;
  }

  .date-nav-input {
    font-size: 0.85rem;
    max-width: 160px;
  }

  .date-nav-btn {
    font-size: 0.85rem;
  }

  .table {
    font-size: 0.85rem;
  }

  .footer {
    background-color: #E9EEF4;
    box-shadow: 0 -1px 4px rgba(0, 0, 0, 0.08);
    width: 100%;
    height: 50px;
    max-height: 50px;
    display: flex;
    align-items: center;
    text-align: center;
  }
    
  .footer-logo {
    max-width: 120px; 
    height: auto;
  }
}

/* Medium screen navbar fix */
@media (min-width: 1025px) {
  .curriculum-overlay {
    display: none !important;
  }

  .curriculum-content-dimmed {
    opacity: 1 !important;
  }

  .curriculum-header-chevron {
    display: none !important;
  }
}

/* Large screens (desktops) */
@media (min-width: 1261px) {
  body {
    font-size: 1rem;
  }

  h1 {
    font-size: 1.5rem;
  }

  h2 {
    font-size: 1rem;
  }

  .btn {
    font-size: 1rem;
  }

  .date-nav-input {
    font-size: 1rem;
  }

  .date-nav-btn {
    font-size: 1rem;
  }

  .table {
    font-size: 1rem;
  }

  .footer {
    background-color: #E9EEF4;
    box-shadow: 0 -1px 4px rgba(0, 0, 0, 0.08);
    width: 100%;
    height: 55px;
    max-height: 55px;
    display: flex;
    align-items: center;
    text-align: center;
  }

  .footer-logo {
    max-width: 135px;
    height: auto;
  }
}

/* Landscape tablets/iPads — shrink nav cards so all fit without scrolling */
@media (orientation: landscape) and (max-height: 900px) {
  .nav-card {
    padding: 1rem;
  }
  .icon-box {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
  }
}

/* Landscape phones — very short viewport (~375–430px), switch to 3 columns
   and strip cards down to icon + title only so 2 rows fit without scrolling */
@media (orientation: landscape) and (max-height: 500px) {
  .row-cols-2 > * {
    width: 33.3333%;
  }
  .nav-card {
    padding: 0.5rem 0.75rem;
  }
  .icon-box {
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
  }
  .card-title {
    font-size: 0.8rem;
  }
  .card-subtitle {
    display: none;
  }
}

/* #endregion */

/*-----------------------------------------*/
/***** Dark Dev Mode styling *****/
/*-----------------------------------------*/
/* #region */
/* General background */
body.development-mode {
  background-color: #3a3a3a; /* Dark gray background */
  color: #9f9d9d; /* Light text color */
}

/* Header */
body.development-mode header {
  background-color: #353535; /* Even darker background for header */
  color: #9f9d9d; /* White text for header */
  border-bottom: 1px solid #444444; /* Subtle border */
}
/* Navbar */
body.development-mode .navbar-light {
  background-color: #353535 !important; /* Dark background for navbar */
  color: #879098 !important; /* Light text color */
  border-bottom: 1px solid #444444; /* Optional subtle border */
}

body.development-mode .navbar-light .navbar-nav .nav-link {
  color: #879098 !important; /* Light blue for links */
}

body.development-mode .navbar-light .navbar-nav .nav-link:hover {
  color: #334556 !important; /* Slightly brighter blue on hover */
}

body.development-mode .navbar-light .navbar-brand {
  color: #ffffff !important; /* White for brand text */
}

body.development-mode .navbar-light .navbar-toggler {
  border-color: #444444 !important; /* Subtle border for toggler */
}

/* Footer */
body.development-mode footer {
  background-color: #353535; /* Dark background for footer */
  color: #9f9d9d; /* White text for footer */
  border-top: 1px solid #444444; /* Subtle border */
}

/* Scrollable Table Container */
body.development-mode .scrollable-table {
  background-color: #292929; /* Dark background for the scrollable container */
  border: 1px solid #444444; /* Border around the scrollable table */
  color: #9f9d9d; /* Light text for the container */
}

/* Table within Scrollable Table */
body.development-mode .scrollable-table table {
  background-color: #292929; /* Match the container's background */
  color: #9f9d9d; /* Light text for the table */
  border-collapse: collapse;
}

/* Table Headings */
body.development-mode .scrollable-table table thead th {
  background-color: #333333; /* Slightly darker background for headers */
  color: #ffffff; /* White text for table headers */
  border-bottom: 1px solid #444444; /* Border below the headers */
  text-align: left;
  padding: 8px;
}

/* Table Rows */
body.development-mode .scrollable-table table tbody tr {
  background-color: #292929; /* Default row background */
}

body.development-mode .scrollable-table table tbody tr:nth-child(even) {
  background-color: #1f1f1f; /* Alternate row background */
}

body.development-mode .scrollable-table table tbody tr:hover {
  background-color: #444444; /* Highlight row on hover */
  color: #ffffff; /* White text on hover */
}

/* Table Cells */
body.development-mode .scrollable-table table th,
body.development-mode .scrollable-table table td {
  border: 1px solid #444444; /* Borders for table cells */
  padding: 8px; /* Padding for readability */
}

/* Links within Table */
body.development-mode .scrollable-table a {
  color: #879098; /* Light blue links */
}

body.development-mode .scrollable-table a:hover {
  color: #334556; /* Slightly brighter blue on hover */
}

/* Scrollbar Styling */
body.development-mode .scrollable-table::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

body.development-mode .scrollable-table::-webkit-scrollbar-thumb {
  background-color: #444444; /* Darker scrollbar thumb */
  border-radius: 4px;
}

body.development-mode .scrollable-table::-webkit-scrollbar-track {
  background-color: #292929; /* Match scrollbar track to the container */
}
/* Links */
body.development-mode a {
  color: #879098; /* Light blue links */
}

body.development-mode a:hover {
  color: #334556; /* Slightly brighter blue on hover */
}
/* #endregion */

/*-----------------------------------------*/
/***** Drag and sort *****/
/*-----------------------------------------*/
/* #region */
.cursor-grab {
  cursor: grab;
}
.cursor-grab:active {
  cursor: grabbing;
}
.drag-ghost {
  opacity: 0.5;
}
/* #endregion */

/*-----------------------------------------*/
/***** Theory Curriculum sidebar *****/
/*-----------------------------------------*/
/* #region */
.curriculum-page {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.curriculum-container {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.curriculum-panels {
  flex: 1;
  min-height: 0;
  display: flex;
  overflow: hidden;
}

.curriculum-sidebar {
  flex-shrink: 0;
  overflow-y: auto;
  overflow-x: hidden;
  transition: width 0.25s ease, padding 0.25s ease, opacity 0.25s ease;
}


.curriculum-sidebar-header {
  flex-shrink: 0;
  overflow: hidden;
  white-space: nowrap;
  transition: width 0.25s ease;
}

.curriculum-header-chevron {
  font-size: 0.75rem;
  line-height: 1;
  opacity: 0.5;
  cursor: pointer;
  color: #6c757d;
}

.curriculum-header-chevron:hover {
  opacity: 1;
}

.curriculum-content-wrapper {
  flex: 1;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.curriculum-content {
  flex: 1;
  overflow-y: auto;
}

.curriculum-content-dimmed {
  opacity: 0.4;
}

.curriculum-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.25);
  z-index: 10;
  cursor: pointer;
  pointer-events: auto;
}

.curriculum-sidebar-heading {
  font-size: 0.7rem;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #6c757d;
  margin-bottom: 0.25rem;
  margin-top: 1rem;
  padding-left: 0.25rem;
}

.curriculum-sidebar-heading:first-child {
  margin-top: 0;
}

.curriculum-sidebar-row {
  padding: 0.25rem 0.5rem;
}

.curriculum-sidebar-row:hover {
  background-color: #f0f0f0;
}

.curriculum-sidebar-row.active {
  background-color: #e8e8e8;
}

.curriculum-sidebar-link {
  font-size: 0.875rem;
  color: #212529;
  padding: 0.1rem 0.5rem 0.1rem 0;
}

.curriculum-sidebar-link.active {
  font-weight: bold;
  color: #212529;
}

/* #endregion */

.form-control::placeholder {
  color: #999;
}



/* Inline service category Select2 — fills cell width, truncates with ellipsis */
.service-categories-table td .select2-container {
  width: 100% !important;
  max-width: 100%;
  min-width: 0;
}

.service-categories-table td .select2-selection--single {
  min-width: 0;
  overflow: hidden;
}

.service-categories-table td .select2-selection__rendered {
  display: block !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  max-width: 100%;
  color: #6c757d !important;
}


/* Inline instructor Select2 — matches room badge height */
.inline-instructor-select:not(.select2-hidden-accessible) {
  visibility: hidden;
}


/* Hide native select until Select2 initializes to prevent flash */
.student-instructor-select:not(.select2-hidden-accessible) {
  visibility: hidden;
}

.batch-score-select:not(.select2-hidden-accessible) {
  visibility: hidden;
}

[data-controller="inline-instructor"] .select2-selection--single,
[data-controller="student-instructor"] .select2-selection--single {
  height: auto !important;
  padding: 4px 2rem 4px 8px !important;
  font-size: inherit !important;
  color: #6c757d !important;
  display: flex !important;
  align-items: center !important;
}

[data-controller="inline-instructor"] .select2-selection__rendered,
[data-controller="student-instructor"] .select2-selection__rendered {
  font-size: inherit !important;
  color: #6c757d !important;
  line-height: 1.5 !important;
  padding: 0 !important;
}

/* Days Late column: hidden until at least one Late checkbox is checked */
.days-late-col {
  display: none;
}

table.has-late .days-late-col {
  display: table-cell;
}

/* Days late wrapper: disabled state matches Item dropdown (gray text, same bg/border) */
.days-late-disabled .form-control:disabled {
  background-color: #ffffff !important;
  color: #adb5bd !important;
}

.days-late-disabled .form-control:disabled::placeholder {
  color: #adb5bd !important;
}

body.demo-site .days-late-disabled .form-control:disabled {
  background-color: #FAFAF9 !important;
}

.days-late-disabled button.btn.dropdown-toggle-custom:disabled {
  background-color: #ffffff !important;
  color: #adb5bd !important;
}

body.demo-site .days-late-disabled button.btn.dropdown-toggle-custom:disabled {
  background-color: #FAFAF9 !important;
}

/* Batch grade filter dropdowns (category + item selects) */
.batch-grade-filter + .select2-container .select2-selection__rendered {
  color: #6c757d !important;
}

/* Batch grade row inline fields: match height of inline-instructor dropdown (~34px) */
[data-controller="batch-grade-row"] .select2-selection--single {
  padding-top: 4px !important;
  padding-bottom: 4px !important;
  color: #6c757d !important;
}

[data-controller="batch-grade-row"] .select2-selection__rendered {
  color: #6c757d !important;
}

[data-controller="batch-grade-row"] .border.rounded {
  height: calc(1.5em + 0.5rem + 2px);
  display: flex;
  align-items: stretch;
  overflow: hidden;
}

/*-----------------------------------------*/
/***** Modern Minimal Dropdown *****/
/*-----------------------------------------*/
/* #region */
.modern-select {
  display: block;
  width: 100%;
  height: calc(2.25rem + 2px);
  appearance: none;
  background-color: #ffffff;
  border: 1px solid #C4C9CE;
  border-radius: 0.375rem;
  padding: 0.375rem 2rem 0.375rem 0.75rem;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.5;
  color: #4a5568;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23A0AABA'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 14px;
  transition: all 0.2s ease;
  cursor: pointer;
  margin: 0;
  box-sizing: border-box;
}

.modern-select:disabled {
  background-color: #e9ecef;
  color: #adb5bd;
  border-color: #C4C9CE;
  cursor: not-allowed;
}

.modern-select:focus {
  outline: none;
  border-color: #6c757d;
  box-shadow: 0 0 0 0.25rem rgba(108, 117, 125, 0.25);
  background-color: #FFFFFF;
}

body.demo-site .modern-select:focus {
  border-color: #1d2c51;
  box-shadow: 0 0 0 0.25rem rgba(166, 188, 255, 0.682);
  background-color: #F2F4FA;
}

.modern-select-sm {
  padding: 0.25rem 1.75rem 0.25rem 0.5rem;
  background-position: right 0.5rem center;
  background-size: 12px;
  font-size: 0.875rem;
}

/* #endregion */


/*-----------------------------------------*/
/***** Dropdowns & Popovers *****/
/*-----------------------------------------*/
/* #region */
.dropdown-menu {
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow:
    0 4px 6px -1px rgba(29, 44, 81, 0.1),
    0 10px 15px -3px rgba(29, 44, 81, 0.1),
    0 20px 25px -5px rgba(29, 44, 81, 0.05);
}

body.demo-site .dropdown-menu,
body.demo-site .modal-content,
body.demo-site #appointmentModal .modal-header,
body.demo-site .form-control,
body.demo-site .form-select,
body.demo-site .collapsible-card,
body.demo-site .collapsible-header,
body.demo-site .collapsible-card .collapsible-header .form-control,
body.demo-site .select2-container--default .select2-selection--single,
body.demo-site .modern-select,
body.demo-site .dropdown-toggle-custom,
body.demo-site .table-wrapper tbody tr,
body.demo-site .table-wrapper tbody td,
body.demo-site .table-wrapper tbody th,
body.demo-site .accordion-body,
body.demo-site .grade-option,
body.demo-site .progress,
body.demo-site .student-info-card {
  background-color: #FAFAF9;
}

body.demo-site .dropdown-toggle-custom {
  --bs-btn-hover-bg: #FAFAF9;
  --bs-btn-active-bg: #FAFAF9;
}

body.demo-site button.btn.dropdown-toggle-custom,
body.demo-site button.btn.dropdown-toggle-custom:hover,
body.demo-site button.btn.dropdown-toggle-custom:active,
body.demo-site button.btn.dropdown-toggle-custom:focus,
body.demo-site button.btn.dropdown-toggle-custom.show {
  background-color: #FAFAF9 !important;
}

.popover {
  border-radius: 12px;
  box-shadow:
    0 4px 6px -1px rgba(29, 44, 81, 0.1),
    0 10px 15px -3px rgba(29, 44, 81, 0.1),
    0 20px 25px -5px rgba(29, 44, 81, 0.05);
}
/* #endregion */


/* Table key popover */
.table-key-popover .popover-header {
  background-color: #f8f9fa;
  color: #6c757d;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid #D4D8DC;
}

.table-key-popover .popover-body {
  padding-top: 0.4rem;
  padding-bottom: 0.4rem;
}

/* Student Info Card */
.student-info-card {
  background-color: #ffffff;
  border: 1px solid #C4C9CE;
}

.info-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: #6c757d;
  margin-bottom: 1px;
}

body.demo-site .info-label {
  color: #5a63b0;
}

.info-value {
  font-size: 0.85rem;
  font-weight: 700;
  color: #1d2c51;
}

.student-info-card .border-end {
  border-color: #C4C9CE !important;
}

.student-info-card .border-end:last-child {
  border-right: none !important;
}

/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *



 */
