:root {
  --bs-primary: rgb(135, 135, 193) !important;
  --bs-primary-rgb: 135, 135, 193 !important;

  --bs-info: #e7e7f3 !important;
  --bs-info-rgb: 231, 231, 243 !important;
}

.doctor-interface-html,
.doctor-interface-html body {
  height: 100%;
}

.doctor-interface {
  --header-height: 56px;

  /* position: relative; */
  height: 100%;
  width: 100%;
}
.doctor-interface .modal {
  --bs-modal-bg: #e7e7f3;
}

#mainContent {
  overflow: hidden auto;
}

#mainContent .date-navigation .btn-group .btn:hover,
#mainContent .date-navigation .btn-group .btn:focus {
  color: white !important;
}

.doctor-interface .no-data-message {
  display: none;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  font-size: 24px;
  font-weight: bold;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.doctor-interface .btn-primary {
  min-width: 50%;
  border-radius: 20px;
  --bs-btn-bg: #8787c1;
  --bs-btn-border-color: #8787c1;
  --bs-btn-hover-bg: #7676ad;
  --bs-btn-hover-border-color: #7676ad;
  --bs-btn-active-bg: #6565a0;
  --bs-btn-active-border-color: #6565a0;
}

/* Sidebar buttons should be smaller */
.doctor-interface .sidebar .btn-primary {
  min-width: auto;
  width: 100%;
  font-size: 0.85rem;
  padding: 8px 12px;
}

/* PDF download button custom color */
.doctor-interface .sidebar .pdf-download-btn {
  --bs-btn-bg: #0395BA;
  --bs-btn-border-color: #0395BA;
  --bs-btn-hover-bg: #027a9a;
  --bs-btn-hover-border-color: #027a9a;
  --bs-btn-active-bg: #026580;
  --bs-btn-active-border-color: #026580;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.doctor-interface .sidebar .pdf-download-btn .pdf-icon {
  flex-shrink: 0;
}

.doctor-interface .sidebar .logout-btn {
  font-size: 0.85rem;
  padding: 8px 12px;
}


.doctor-interface .text-warning {
  color: #ffc107 !important;
}

.doctor-interface .text-success {
  color: #198754 !important;
}

.doctor-interface .text-danger {
  color: #dc3545 !important;
}

.doctor-interface .btn-outline-primary {
  --bs-btn-color: #8787c1;
  --bs-btn-border-color: #8787c1;
  --bs-btn-hover-bg: #8787c1;
  --bs-btn-hover-border-color: #8787c1;
  --bs-btn-active-bg: #8787c1;
  --bs-btn-active-border-color: #8787c1;
}

.doctor-interface .btn-outline-danger {
  --bs-btn-color: #d26386;
  --bs-btn-border-color: #d26386;
  --bs-btn-hover-bg: #d26386;
  --bs-btn-hover-border-color: #d26386;
  --bs-btn-active-bg: #d26386;
  --bs-btn-active-border-color: #d26386;
}

.doctor-interface .sidebar {
  background-color: #e7e7f3;
  min-height: 100vh;
  height: 100vh;
  padding: 15px 10px;
  top: 0;
  left: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
  width: 200px;
  flex-shrink: 0;
  position: sticky;
  overflow-y: auto;
  overflow-x: hidden;
}

.doctor-interface .sidebar .nav {
  position: relative;
}

.doctor-interface .sidebar-toggle-btn {
  display: none;
  position: absolute;
  top: 10px;
  right: 5px;
  width: 25px;
  height: 25px;
  background: #8787c1;
  border: none;
  border-radius: 50%;
  color: white;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  z-index: 10;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
  transition: all 0.3s ease;
}

.doctor-interface .sidebar-toggle-btn:hover {
  background: #7676ad;
}

.doctor-interface .sidebar-toggle-btn .toggle-icon {
  font-size: 16px;
  font-weight: bold;
  line-height: 1;
}

/* Default - Full sidebar with text */
.doctor-interface .sidebar .nav-text {
  display: inline;
}

.doctor-interface .sidebar .icon-text {
  display: none !important;
}

/* Responsive sidebar - icons only on medium screens */
@media (min-width: 768px) and (max-width: 1199.98px) {
  .doctor-interface .sidebar {
    width: 80px !important;
    padding: 20px 10px !important;
    align-items: center !important;
    min-height: 100vh !important;
    height: 100vh !important;
    position: sticky !important;
    overflow-y: auto !important;
  }
  
  .doctor-interface .sidebar-toggle-btn {
    display: flex !important;
  }
  
  .doctor-interface .sidebar.expanded {
    width: 200px !important;
    align-items: flex-start !important;
  }
  
  .doctor-interface .sidebar.expanded .sidebar-toggle-btn .toggle-icon {
    transform: rotate(180deg);
  }
  
  .doctor-interface .sidebar.expanded .nav-text {
    display: inline !important;
  }
  
  .doctor-interface .sidebar.expanded .icon-text {
    display: none !important;
  }
  
  .doctor-interface .sidebar.expanded .nav-link,
  .doctor-interface .sidebar.expanded .profile {
    justify-content: flex-start !important;
    padding: 8px 10px !important;
    text-align: left !important;
  }
  
  .doctor-interface .sidebar.expanded .sidebar-btn {
    width: 100% !important;
    padding: 8px 12px !important;
  }
  
  .doctor-interface .sidebar.expanded .pdf-download-btn .nav-text {
    display: inline !important;
  }

  .doctor-interface .sidebar .nav-text {
    display: none !important;
  }

  .doctor-interface .sidebar .icon-text {
    display: block !important;
    font-size: 20px !important;
  }

  .doctor-interface .sidebar .nav-link,
  .doctor-interface .sidebar .profile {
    justify-content: center !important;
    padding: 12px !important;
    min-width: 60px !important;
    text-align: center !important;
  }
  
  .doctor-interface .sidebar .nav-link img {
    margin: 0 !important;
  }

  .doctor-interface .sidebar .sidebar-btn {
    min-width: auto !important;
    padding: 12px !important;
    width: 60px !important;
  }

  .doctor-interface .sidebar .sidebar-btn .nav-text {
    display: none !important;
  }

  .doctor-interface .sidebar .sidebar-btn .icon-text {
    display: block !important;
  }
  
  .doctor-interface .sidebar .pdf-download-btn .nav-text {
    display: none !important;
  }
  
  .doctor-interface .sidebar .pdf-download-btn .pdf-icon {
    display: block !important;
  }

  .doctor-interface .sidebar .logout-btn img {
    margin: 0 !important;
  }
  
  .doctor-interface .sidebar #acronym {
    display: none !important;
  }
  
  .doctor-interface .sidebar .nav-pills {
    width: 100% !important;
  }
}

/* Full sidebar on large screens */
@media (min-width: 1200px) {
  .doctor-interface .sidebar {
    width: 200px !important;
    padding: 15px 10px !important;
    min-height: 100vh !important;
    height: 100vh !important;
    position: sticky !important;
    overflow-y: auto !important;
  }

  .doctor-interface .sidebar .nav-text {
    display: inline !important;
  }

  .doctor-interface .sidebar .icon-text {
    display: none !important;
  }
  
  .doctor-interface .sidebar #acronym {
    display: block !important;
  }
}

.doctor-interface .content {
  /* position: absolute; */
  top: 0;
  /* left: 250px; */
  right: 0;
  bottom: 0;
  overflow-y: auto;
  padding: 20px;
  flex: 1 1 auto;
  min-width: 0;
}

.doctor-interface .container-inner {
  flex: 1 1 auto;
  min-width: 0;
}

.doctor-interface .chart-container {
  width: 100%;
  height: 500px;
  margin-bottom: 30px;
  max-width: 100%;
  overflow: hidden;
}

.doctor-interface .info-message {
  background-color: #81cadd;
  color: white;
  padding: 10px 15px;
  border-radius: 4px;
  margin: 10px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.doctor-interface .info-message svg,
.doctor-interface .warning-message svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.doctor-interface .info-message img, 
.doctor-interface .warning-message img {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}


.doctor-interface .warning-message {
  background-color: #d66d85;
  color: white;
  padding: 10px 15px;
  border-radius: 4px;
  margin: 10px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.doctor-interface .warning-message svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.doctor-interface .warning-message img {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.doctor-interface #codeEntry {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #45B5D1 0%, #8787C1 100%);
  z-index: 9999;
  overflow-y: auto;
  padding: 20px;
}

.doctor-interface .code-entry-wrapper {
  display: flex;
  max-width: 1400px;
  width: 100%;
  gap: 40px;
  align-items: center;
}

.doctor-interface .code-entry-left {
  flex: 0 0 450px;
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.doctor-interface .logo-container {
  text-align: center;
}

.doctor-interface .tony-logo {
  height: 60px;
  width: auto;
}

.doctor-interface .login-card {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 12px;
  padding: 40px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.doctor-interface .login-title {
  font-size: 28px;
  font-weight: 600;
  color: #3a3b53;
  margin-bottom: 8px;
}

.doctor-interface .login-subtitle {
  font-size: 16px;
  color: #666;
  margin-bottom: 30px;
}

.doctor-interface .form-group {
  margin-bottom: 24px;
}

.doctor-interface .form-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: #3a3b53;
  margin-bottom: 8px;
}

.doctor-interface .info-icon {
  color: #8787c1;
  font-size: 16px;
  cursor: help;
}

.doctor-interface .code-entry-input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #d0d0d0;
  border-radius: 8px;
  font-size: 14px;
  transition: border-color 0.2s;
}

.doctor-interface .code-entry-input:focus {
  outline: none;
  border-color: #8787c1;
  box-shadow: 0 0 0 3px rgba(135, 135, 193, 0.1);
}

.doctor-interface .captcha-container {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.doctor-interface .captcha-image {
  height: 50px;
  width: auto;
  border: 1px solid #d0d0d0;
  border-radius: 8px;
  background: white;
  padding: 8px;
}

.doctor-interface .refresh-btn {
  padding: 10px 16px;
  border-radius: 8px;
  background: #8787c1;
  color: white;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
}

.doctor-interface .refresh-btn:hover {
  background: #7676ad;
}

.doctor-interface .refresh-icon {
  font-size: 20px;
  font-weight: bold;
}

.doctor-interface .login-btn {
  width: 100%;
  padding: 14px;
  border-radius: 20px;
  font-size: 16px;
  font-weight: 500;
  margin-top: 8px;
}

.doctor-interface .code-entry-right {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.doctor-interface .welcome-card {
  background: white;
  border-radius: 16px;
  padding: 50px;
  max-width: 700px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.doctor-interface .welcome-title {
  font-size: 42px;
  font-weight: 700;
  color: #3a3b53;
  margin-bottom: 16px;
  text-align: center;
}

.doctor-interface .welcome-subtitle {
  font-size: 24px;
  font-weight: 600;
  color: #3a3b53;
  margin-bottom: 24px;
  text-align: center;
}

.doctor-interface .welcome-text {
  font-size: 16px;
  color: #666;
  line-height: 1.6;
  margin-bottom: 32px;
  text-align: center;
}

.doctor-interface .chart-preview {
  text-align: center;
}

.doctor-interface .preview-image {
  width: 100%;
  max-width: 600px;
  height: auto;
  border-radius: 8px;
}

/* Responsive design */
@media (max-width: 1200px) {
  .doctor-interface #codeEntry {
    align-items: flex-start;
    padding-top: 40px;
  }
  
  .doctor-interface .code-entry-wrapper {
    flex-direction: column;
    max-width: 600px;
  }
  
  .doctor-interface .code-entry-left {
    flex: 1;
    width: 100%;
  }
  
  .doctor-interface .code-entry-right {
    width: 100%;
  }
  
  .doctor-interface .welcome-card {
    padding: 30px;
  }
  
  .doctor-interface .welcome-title {
    font-size: 32px;
  }
  
  .doctor-interface .welcome-subtitle {
    font-size: 20px;
  }
}

/* Small height screens */
@media (max-height: 600px) {
  .doctor-interface #codeEntry {
    align-items: flex-start;
    padding: 20px;
  }
  
  .doctor-interface .code-entry-wrapper {
    gap: 20px;
  }
  
  .doctor-interface .code-entry-left {
    gap: 15px;
  }
  
  .doctor-interface .logo-container {
    margin-bottom: 0;
  }
  
  .doctor-interface .tony-logo {
    height: 40px;
  }
  
  .doctor-interface .login-card {
    padding: 20px;
  }
  
  .doctor-interface .login-title {
    font-size: 22px;
    margin-bottom: 6px;
  }
  
  .doctor-interface .login-subtitle {
    font-size: 14px;
    margin-bottom: 20px;
  }
  
  .doctor-interface .form-group {
    margin-bottom: 16px;
  }
  
  .doctor-interface .welcome-card {
    padding: 20px;
  }
  
  .doctor-interface .welcome-title {
    font-size: 24px;
    margin-bottom: 12px;
  }
  
  .doctor-interface .welcome-subtitle {
    font-size: 18px;
    margin-bottom: 16px;
  }
  
  .doctor-interface .welcome-text {
    font-size: 14px;
    margin-bottom: 20px;
  }
}

.doctor-interface .code-input-group {
  display: flex;
  gap: 10px;
  justify-content: center;
  position: relative;
}

.doctor-interface .code-input, .doctor-interface .captcha-input  {
  width: 50px;
  height: 50px;
  text-align: center;
  font-size: 24px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  text-transform: uppercase;
}

.doctor-interface .date-navigation .btn-group .btn.active {
  background-color: #8787c1;
  border-color: #8787c1;
  color: white;
}

.doctor-interface .date-navigation .btn-group .btn:hover {
  border-color: #7676ad;
  color: #7676ad;
}

.doctor-interface .date-navigation .btn-group .btn.active:hover {
  background-color: #7676ad;
  border-color: #7676ad;
  color: white;
}

.doctor-interface .custom-range input[type="date"] {
  width: 150px;
}

.doctor-interface .custom-range.active input[type="date"] {
  background-color: #8787c1;
  color: white;
}
.doctor-interface
  .custom-range.active
  input[type="date"]::-webkit-calendar-picker-indicator {
  filter: invert(1);
}
.doctor-interface .form-label:hover {
  cursor: default;
  user-select: none;
}

.doctor-interface .custom-range label {
  pointer-events: none;
}

.doctor-interface .nav-pills {
  flex-grow: 1;
}

.doctor-interface .logout-btn {
  margin-top: auto;
  padding: 8px 16px;
}

.doctor-interface .nav-pills .nav-link.active {
  background-color: #8787c1 !important;
  color: white !important;
}

.doctor-interface .nav-pills .nav-link {
  color: #8787c1;
  max-width: 100%;
  text-overflow: ellipsis;
  overflow: hidden;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 8px;
  word-break: break-word;
  font-size: 0.9rem;
  padding: 8px 10px;
}

.doctor-interface .nav-pills .profile {
  color: #3a3b53;
  max-width: 100%;
  text-overflow: ellipsis;
  overflow: hidden;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  padding: 8px 10px;
}

.doctor-interface .nav-pills .nav-link .icon-active {
  display: none;
}

.doctor-interface .nav-pills .nav-link.active .icon-active {
  display: block;
}
.doctor-interface .nav-pills .nav-link.active .icon {
  display: none;
}

.doctor-interface .nav-pills .nav-link:hover {
  color: #7676ad;
}

.doctor-interface .nav-pills .nav-link.active:hover {
  color: white !important;
}

.doctor-interface .btn-primary:disabled {
  --bs-btn-disabled-bg: #8787c1;
  --bs-btn-disabled-border-color: #8787c1;
  opacity: 0.65;
}

.doctor-interface body {
  font-family: "Montserrat", sans-serif;
}

.doctor-interface h1,
.doctor-interface h2,
.doctor-interface h3,
.doctor-interface h4,
.doctor-interface h5,
.doctor-interface h6 {
  font-family: "Josefin Sans", sans-serif;
}

.doctor-interface .code-entry-container {
  position: relative;
  padding-bottom: 30px;
}

.doctor-interface #loginError {
  position: absolute;
  top: 7.5rem;
  left: 0;
  right: 0;
  text-align: center;
}

.doctor-interface .delete-button {
  position: absolute;
  right: -12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: 2px solid #dc3545;
  color: #dc3545;
  cursor: pointer;
  display: none;
  padding: 0;
  font-size: 24px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  line-height: 1;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s, border-color 0.2s;
}

.doctor-interface .delete-button[style*="display: block"] {
  display: flex !important;
}

.doctor-interface .delete-button:hover {
  color: #bb2d3b;
  background-color: rgba(220, 53, 69, 0.1);
  border-color: #bb2d3b;
}

.doctor-interface .h-screen {
  height: 100vh;
}

.doctor-interface .overflow-y-auto {
  overflow-y: auto;
}

.doctor-interface .overflow-hidden {
  overflow: hidden;
}

.doctor-interface .max-w-1200 {
  max-width: 1200px;
}

.doctor-interface .mx-auto {
  margin: 0 auto;
}

.doctor-interface .mb-4 {
  margin-bottom: 1rem;
}

.doctor-interface .mb-2 {
  margin-bottom: 0.5rem;
}

.doctor-interface .mt-4 {
  margin-top: 1rem;
}

.doctor-interface .w-full {
  width: 100%;
}

.doctor-interface .h-500 {
  height: 500px;
}

.doctor-interface .text-center {
  text-align: center;
}

.doctor-interface .flex {
  display: flex;
}

.doctor-interface .flex-col {
  flex-direction: column;
}

.doctor-interface .items-center {
  align-items: center;
}

.doctor-interface .mx-auto {
  margin: 0 auto;
}

.doctor-interface .modal-header {
  border-bottom: none;
  padding-bottom: 0;
}

.doctor-interface .modal-footer {
  border-top: none;
  display: flex;
  justify-content: center;
}

.doctor-interface .cursor-pointer {
  cursor: pointer;
}

.doctor-interface .percentage-circles {
  display: flex;
  justify-content: space-around;
  margin: 20px 0;
  padding: 0 20%;
}

.doctor-interface .circle-container {
  position: relative;
  width: 80px;
  height: 80px;
}

.doctor-interface .percentage-circle {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: white;
  position: relative;
}

.doctor-interface .circle-green {
  background-color: #4caf50;
}

.doctor-interface .circle-orange {
  background-color: #ff9800;
}

.doctor-interface .circle-red {
  background-color: #f44336;
}

.doctor-interface .med-stats {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  margin: 20px 0;
}

.doctor-interface .med-stats__legend {
  display: flex;
  align-items: center;
  gap: 20px;
}

.doctor-interface .med-stats__legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
}

.doctor-interface .med-stats__color-box {
  width: 20px;
  height: 20px;
}

.doctor-interface .med-stats__color-box.orange-box {
  background: repeating-linear-gradient(
  0deg,
  transparent,
  transparent 1px,
  #ffc107 0px,
  #ffc107 5px
  ) !important;
  color: black;
}

.doctor-interface .med-stats__color-box.red-box {
  background: repeating-linear-gradient(
  320deg,
  transparent,
  transparent 0.5px,
  #dc3545 0px,
  #dc3545 5px
  ) !important;
}

.doctor-interface .med-stats__circles {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.doctor-interface .med-stats__circle {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
}


.doctor-interface .med-stats__circle--green {
  background-color: #198754;
}

.doctor-interface .med-stats__circle--orange {
  background: repeating-linear-gradient(
  0deg,
  transparent,
  transparent 1px,
  #ffc107 0px,
  #ffc107 20px
  ) !important;
  color: black;
}

.doctor-interface .med-stats__circle--red {
  background: repeating-linear-gradient(
  320deg,
  transparent,
  transparent 0.5px,
  #dc3545 0px,
  #dc3545 20px
  ) !important;
}

.doctor-interface .med-stats__value {
  font-size: 24px;
}

.doctor-interface .med-stats__label {
  font-size: 14px;
  margin-top: 5px;
}

.doctor-interface .pagination .page-item.active .page-link {
  background-color: #8787c1;
  border-color: #8787c1;
  color: white;
}

.doctor-interface .pagination .page-link {
  color: #8787c1;
}

.doctor-interface .pagination .page-link:hover {
  color: #7676ad;
  border-color: #7676ad;
  background-color: transparent;
}

.doctor-interface .pagination .page-item.active .page-link:hover {
  background-color: #7676ad;
  border-color: #7676ad;
  color: white;
}

.doctor-interface .panel-content {
  background: #e7e7f3;
  padding: 10px;
  border-radius: 8px;
  margin-top: 1rem;
  overflow-wrap: break-word;
  word-wrap: break-word;
  .row>* {
    padding-right: 0 !important;
    padding-left: 0 !important;
  }
}

.doctor-interface .panel-content * {
  max-width: 100%;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.doctor-interface .side-panel {
  margin-top: 92px;
  min-width: 250px;
  max-width: 350px;
}

.doctor-interface .side-panel h3 {
  font-size: 1.1rem;
  margin-bottom: 1rem;
  color: #333;
  word-wrap: break-word;
}

.doctor-interface .med-plan-group {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.doctor-interface .med-item {
  border-bottom: 1px solid #dee2e6;
  padding-bottom: 1rem;
}

.doctor-interface .med-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.doctor-interface .med-name {
  font-weight: 500;
  color: #333;
  margin-bottom: 0.5rem;
}

.doctor-interface .med-schedule {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.doctor-interface .med-time {
  display: flex;
  justify-content: space-between;
  color: #666;
  font-size: 0.9rem;
}

.doctor-interface .med-plan-warning {
  margin-top: 1.5rem;
  border-top: 1px solid #dee2e6;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.75rem;
  align-items: center;
  font-size: 0.9rem;
  color: #666;
  text-align: center;
}

.doctor-interface .med-plan-warning img {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.doctor-interface .stat-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}

.doctor-interface .stat-item .stat-value {
  font-weight: 700;
  color: #8787c1;
}

.doctor-interface .max-h-70vh {
  max-height: 70vh;
}

.doctor-interface .max-w-25vw {
  max-width: 25vw;
}

/* Right side panels - ensure readable content */
#statsPanel,
#medPlanPanel,
#weightPanel {
  width: 300px !important;
  min-width: 300px !important;
  max-width: 300px !important;
  flex: 0 0 300px !important;
  transition: all 0.3s ease;
}

/* Push side panels below when sidebar is expanded on medium screens */
@media (min-width: 768px) and (max-width: 1199.98px) {
  .row.flex-wrap .sidebar {
    order: 1 !important;
    flex: 0 0 200px !important;
  }
  
  .row.flex-wrap .content {
    order: 2 !important;
    flex: 1 1 auto !important;
    min-width: 0 !important;
  }
  
  .row.flex-wrap #statsPanel,
  .row.flex-wrap #medPlanPanel,
  .row.flex-wrap #weightPanel {
    flex: 1 1 280px !important;
    margin-top: 20px !important;
    order: 3 !important;
    min-width: 280px !important;
    max-width: calc(33.333% - 10px) !important;
  }
}

/* Ensure panels don't shrink too much on medium screens */
@media (min-width: 992px) and (max-width: 1399.98px) {
  #statsPanel,
  #medPlanPanel,
  #weightPanel {
    width: 280px !important;
    min-width: 280px !important;
    max-width: 280px !important;
    flex: 0 0 280px !important;
  }
}

/* On large screens allow more space */
@media (min-width: 1400px) {
  #statsPanel,
  #medPlanPanel,
  #weightPanel {
    width: 320px !important;
    min-width: 320px !important;
    max-width: 320px !important;
    flex: 0 0 320px !important;
  }
}

.pagination {
  flex-wrap: nowrap;
  overflow-x: hidden;
}

.doctor-interface .overflow-y-auto {
  overflow-y: auto;
}

@media (max-width: 767.98px) {
  .doctor-interface .mobile-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: #fff;
    z-index: 1030;
    display: flex;
    align-items: center;
    padding: 0 15px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  }

  .doctor-interface .hamburger-btn {
    background: none;
    border: none;
    padding: 10px;
    margin-right: 10px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
  }

  .doctor-interface .hamburger-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--bs-primary);
    transition: transform 0.2s ease;
  }

  .doctor-interface .hamburger-btn.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .doctor-interface .hamburger-btn.active span:nth-child(2) {
    opacity: 0;
  }

  .doctor-interface .hamburger-btn.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  .doctor-interface .mobile-header h1 {
    margin: 0;
    font-size: 1.25rem;
  }

  .doctor-interface .sidebar {
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    background: white;
    transform: translateY(-100%);
    transition: transform 0.3s ease;
    z-index: 1029;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 0;
  }

  .doctor-interface .sidebar.show {
    transform: translateY(0);
  }

  .doctor-interface .nav-pills {
    flex-direction: column !important;
    margin: 0;
    padding: 0;
    flex: 1;
  }

  .doctor-interface .nav-pills .nav-link {
    padding: 15px 20px;
    border-radius: 0;
    border-bottom: 1px solid #eee;
    margin: 0;
  }

  .doctor-interface .nav-pills .nav-link.active {
    background-color: var(--bs-primary);
    color: white;
  }

  .doctor-interface .logout-btn {
    width: 100%;
    padding: 15px 20px;
    border-radius: 0;
    margin: 0;
    border: none;
  }

  .doctor-interface .side-panel {
    margin-top: 16px !important;
  }
  .doctor-interface #medPlanPanel {
    margin-top: 0 !important;
  }

  .doctor-interface .content {
    /* position: absolute; */
    margin-top: var(--header-height);
    /* 
    left: 0;
    right: 0;
    bottom: 0; */
    padding: 15px;
    overflow-y: auto;
  }

  .doctor-interface .date-navigation {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .doctor-interface .date-navigation .btn-group {
    width: 100%;
    justify-content: center;
  }

  .doctor-interface .date-navigation .custom-range {
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 8px;
    flex-direction: column;
    width: 100%;
  }

  .doctor-interface .custom-range input[type="date"] {
    width: calc(50% - 4px);
  }

  .doctor-interface .custom-range .btn {
    width: 100%;
    margin-top: 8px;
  }

  .doctor-interface .chart-container {
    height: 400px;
    margin: 20px 0;
  }

  .doctor-interface h1 {
    font-size: 1.5rem;
    margin: 0 0 1rem 0;
  }

  .doctor-interface .table-responsive {
    margin-top: 1rem;
  }

  .doctor-interface .pagination {
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px;
  }

}
