/*
* demo.css
* File include item demo only specific css only
******************************************************************************/

.light-style .menu .app-brand.demo {
  height: 64px;
}

.dark-style .menu .app-brand.demo {
  height: 64px;
}

.app-brand-logo.demo {
  -ms-flex-align: center;
  align-items: center;
  -ms-flex-pack: center;
  justify-content: center;
  display: -ms-flexbox;
  display: flex;
  width: 34px;
  height: 24px;
}

.app-brand-logo.demo svg {
  width: 35px;
  height: 24px;
}

.app-brand-text.demo {
  font-size: 1.375rem;
}

/* ! For .layout-navbar-fixed added fix padding top tpo .layout-page */
.layout-navbar-fixed .layout-wrapper:not(.layout-without-menu) .layout-page {
  padding-top: 64px !important;
}

.layout-navbar-fixed .layout-wrapper:not(.layout-horizontal):not(.layout-without-menu) .layout-page {
  padding-top: 78px !important;
}

/* Navbar page z-index issue solution */
.content-wrapper .navbar {
  z-index: auto;
}

/*
* Content
******************************************************************************/

/* ? .demo-vertical-spacing class is used to have vertical margins between elements. To remove margin-top from the first-child, use .demo-only-element class with .demo-vertical-spacing class. For example, we have used this class in forms-input-groups.html file. */

/* Dropdown buttons going out of small screens */

/*
* Enhanced Menu Styling
******************************************************************************/

/* Simplified menu background */
.layout-menu {
  background: #1e293b !important;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}

/* Enhanced menu items */
.menu-item .menu-link {
  border-radius: 8px;
  margin: 2px 12px;
  padding: 12px 16px;
  position: relative;
}



.menu-item .menu-link:hover {
  background: rgba(115, 103, 240, 0.15);
}

.menu-item.active .menu-link {
  background: rgba(115, 103, 240, 0.2);
  border-left: 3px solid #7367f0;
}

/* Enhanced menu icons */
.menu-icon,
.menu-link .menu-icon {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  margin-right: 12px;
  visibility: visible !important;
  opacity: 1 !important;
}

.menu-item .menu-link:hover .menu-icon {
  color: #7367f0;
}

/* FINAL FIX: Active menu icons - ONE RULE TO RULE THEM ALL */

.menu-item.active > .menu-link .menu-icon,
.menu-item.active .menu-link .menu-icon,
.menu-item.active .menu-link i.menu-icon,
.menu-item.active .menu-link .ti,
li.menu-item.active a.menu-link i.menu-icon {
  color: #fff !important;
  font-family: "tabler-icons" !important;
  font-style: normal !important;
  font-weight: normal !important;
  font-variant: normal !important;
  text-transform: none !important;
  line-height: 1 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 20px !important;
  height: 20px !important;
  margin-right: 12px !important;
  visibility: visible !important;
  opacity: 1 !important;
  -webkit-font-smoothing: antialiased !important;
  -moz-osx-font-smoothing: grayscale !important;
}

/* Enhanced brand area */
.app-brand {
  padding: 24px 20px !important;
  background: rgba(115, 103, 240, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  margin-bottom: 8px;
}



.app-brand-link {
  position: relative;
  z-index: 1;
}

.app-brand-text {
  color: #f1f5f9;
  font-weight: 700 !important;
  letter-spacing: -0.5px;
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-svg {
  transition: all 0.3s ease;
}

/* Enhanced badges */
.badge {
  font-size: 0.65rem;
  padding: 4px 8px;
  border-radius: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Enhanced inner shadow */
.menu-inner-shadow {
  /* Simplified shadow */
  height: 20px;
  margin-bottom: 12px;
}

/* Enhanced menu inner */
.menu-inner {
  padding: 0 8px 20px 8px !important;
}

/* Menu headers styling */
.menu-header {
  padding: 20px 16px 8px 16px !important;
  margin-top: 16px;
  position: relative;
}

.menu-header:first-child {
  margin-top: 0;
}

.menu-header-text {
  color: rgba(255, 255, 255, 0.6);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 1px;
  position: relative;
}

.menu-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 16px;
  right: 16px;
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
}

/* Menu item badges */

.menu-link {
  display: flex;
  align-items: center;
}

/* Enhanced LinkedIn button */
.btn-outline-linkedin {
  background: rgba(0, 119, 181, 0.1);
  border: 1px solid rgba(0, 119, 181, 0.3);
  border-radius: 8px;
  margin: 16px 12px 8px 12px;
  padding: 10px 16px;
  font-weight: 500;
}

.btn-outline-linkedin:hover {
  background: rgba(0, 119, 181, 0.2);
  border-color: rgba(0, 119, 181, 0.5);
}

/* Simplified menu items */
.menu-item {
  transition: all 0.2s ease;
}

/* Custom scrollbar for menu */
.layout-menu::-webkit-scrollbar {
  width: 6px;
}

.layout-menu::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 10px;
}

.layout-menu::-webkit-scrollbar-thumb {
  background: #7367f0;
  border-radius: 10px;
}

.layout-menu::-webkit-scrollbar-thumb:hover {
  background: #5a52d5;
}

/* Responsive improvements */
@media (max-width: 1199.98px) {
  .layout-menu {
    width: 260px;
  }

  .menu-inner {
    padding: 0 4px 20px 4px !important;
  }

  .menu-item .menu-link {
    margin: 2px 8px;
    padding: 10px 12px;
  }

  .app-brand {
    padding: 20px 16px !important;
  }
}

@media (max-width: 767.98px) {

  .menu-header-text {
    font-size: 0.7rem;
  }
}

/*
* Layout demo
******************************************************************************/

/* Floating Machine Status Window */
.floating-machine-window {
  position: fixed !important;
  bottom: 20px !important;
  left: 20px !important;
  width: 320px !important;
  background: rgba(255, 255, 255, 0.95) !important;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  border-radius: 16px !important;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.08), 0 6px 12px rgba(0, 0, 0, 0.04) !important;
  z-index: 9999 !important;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  overflow: hidden !important;
  display: block !important;
  visibility: visible !important;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}


.floating-machine-window .floating-machine-content {
  max-height: 0;
  opacity: 0;
  padding: 0 16px;
  margin-top: 0;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  overflow: hidden;
}

.floating-machine-window.expanded .floating-machine-content {
  max-height: 200px;
  opacity: 1;
  padding: 12px 16px 16px 16px;
  margin-top: 0;
}

.floating-machine-window.collapsed .floating-machine-content {
  max-height: 0;
  opacity: 0;
  padding: 0 16px;
  margin-top: 0;
}

.floating-machine-window:not(.collapsed) .floating-machine-content {
  margin-top: 0;
}

.floating-machine-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
}

.floating-machine-header:hover {
  background: linear-gradient(135deg, rgba(116, 103, 240, 0.1) 0%, rgba(116, 103, 240, 0.05) 100%);
  transform: translateY(-1px);
}

.floating-machine-info {
  flex: 1;
}

.floating-machine-lab-link {
  text-decoration: none;
  color: inherit;
  display: block;
  transition: all 0.3s ease;
  border-radius: 8px;
  padding: 2px 4px;
  margin: -2px -4px;
}

.floating-machine-lab-link:hover {
  background: rgba(116, 103, 240, 0.1);
  color: #7367f0;
  text-decoration: none;
  transform: translateX(2px);
}

.floating-machine-lab-link:hover .floating-machine-lab-name {
  color: #7367f0;
}

.floating-machine-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.floating-machine-lab-name {
  font-weight: 700;
  font-size: 15px;
  color: #1a202c;
  margin-bottom: 6px;
  line-height: 1.3;
  letter-spacing: -0.01em;
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.floating-machine-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #64748b;
  font-weight: 500;
}

.floating-machine-status .status-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: linear-gradient(135deg, #10b981, #059669);
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.5), 0 0 4px rgba(16, 185, 129, 0.3);
  animation: statusPulse 2s ease-in-out infinite;
  position: relative;
}

.floating-machine-status .status-indicator::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.3), rgba(5, 150, 105, 0.3));
  animation: statusRipple 2s ease-in-out infinite;
}

.floating-machine-status .status-indicator.running {
  background: #28a745;
  box-shadow: 0 0 8px rgba(40, 167, 69, 0.4);
}

@keyframes statusPulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.8;
    transform: scale(1.1);
  }
}

@keyframes statusRipple {
  0% {
    opacity: 0.8;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(2);
  }
}

.floating-machine-toggle {
  background: rgba(116, 103, 240, 0.1);
  border: none;
  color: #7367f0;
  font-size: 18px;
  padding: 8px;
  border-radius: 12px;
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.floating-machine-toggle:hover {
  background: rgba(116, 103, 240, 0.2);
  color: #685dd8;
  transform: scale(1.1);
}



.floating-machine-toggle i {
  transition: transform 0.3s ease;
  transform: rotate(180deg); /* Default collapsed state - arrow points down */
}

.floating-machine-window.expanded .floating-machine-toggle i {
  transform: rotate(0deg); /* Expanded state - arrow points up */
}

.floating-machine-content {
  padding: 12px 16px 16px 16px;
  max-height: 150px;
  opacity: 1;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  overflow: hidden;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.02) 0%, rgba(255, 255, 255, 0.01) 100%);
}

.floating-machine-target {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  padding: 8px 12px;
  background: linear-gradient(135deg, rgba(116, 103, 240, 0.08) 0%, rgba(116, 103, 240, 0.04) 100%);
  border: 1px solid rgba(116, 103, 240, 0.15);
  border-radius: 12px;
  transition: all 0.3s ease;
}

.floating-machine-target:hover {
  background: linear-gradient(135deg, rgba(116, 103, 240, 0.12) 0%, rgba(116, 103, 240, 0.06) 100%);
  border-color: rgba(116, 103, 240, 0.25);
  transform: translateY(-1px);
}

.floating-machine-target .target-label {
  font-size: 13px;
  font-weight: 600;
  color: #7367f0;
  white-space: nowrap;
  letter-spacing: -0.01em;
}

.floating-machine-target .target-value {
  font-family: 'SF Mono', 'Monaco', 'Menlo', 'Roboto Mono', 'Ubuntu Mono', monospace;
  font-size: 13px;
  font-weight: 600;
  color: #1a202c;
  flex: 1;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 10px;
  border: 1px solid rgba(116, 103, 240, 0.2);
  letter-spacing: 0.01em;
  transition: all 0.3s ease;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
  cursor: pointer;
}

.floating-machine-target .target-value:hover {
  background: rgba(255, 255, 255, 1);
  border-color: rgba(116, 103, 240, 0.3);
}

.floating-machine-timer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
  padding: 10px 12px;
  background: rgba(116, 103, 240, 0.08);
  border: 1px solid rgba(116, 103, 240, 0.15);
  border-radius: 12px;
}

.timer-section {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.timer-label {
  font-size: 12px;
  font-weight: 500;
  color: #7367f0;
  white-space: nowrap;
}

.timer-value {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 600;
  color: #2c3e50;
}

.timer-value i {
  color: #7367f0;
}








/* Mobile responsiveness */
@media (max-width: 480px) {
  .floating-machine-window {
    left: 10px !important;
    right: 10px !important;
    width: auto !important;
    bottom: 10px !important;
    border-radius: 16px !important;
  }

  .floating-machine-header {
    padding: 14px 16px;
  }

    .floating-machine-header-actions {
    gap: 6px;
  }

  .floating-machine-content {
    padding: 12px 16px 16px 16px;
  }


  .floating-machine-target .target-value {
    font-size: 12px;
  }

  .floating-machine-timer {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 10px 12px;
  }

  .timer-section {
    justify-content: center;
  }

}

/* Tablet responsiveness */
@media (max-width: 768px) and (min-width: 481px) {
  .floating-machine-window {
    width: 300px !important;
  }
}

/* Coherent Navbar Responsive Design */
.layout-navbar {
  transition: all 0.3s ease;
}

/* Base navbar improvements */
.navbar .d-flex.gap-4 {
  transition: all 0.3s ease;
}

.navbar .nav-item .d-flex.align-items-center {
  transition: all 0.3s ease;
}

/* Large screens (Desktop) - Full experience */
@media (min-width: 1200px) {
  .layout-navbar {
    padding: 0.75rem 1.5rem;
  }
}

/* Medium-large screens (Tablet landscape) */
@media (max-width: 1199.98px) {
  .layout-navbar {
    padding: 0.75rem 1.25rem;
  }

  .navbar .d-flex.gap-4 {
    gap: 1.5rem;
  }

  .navbar .fw-semibold {
    font-size: 0.9rem;
  }

  .navbar small {
    font-size: 0.8rem;
  }
}

/* Medium screens (Tablet portrait) */
@media (max-width: 991.98px) {
  .layout-navbar {
    padding: 0.75rem 1rem;
  }

  .navbar .d-flex.gap-4 {
    gap: 1rem;
    flex-wrap: wrap;
  }

  .navbar .fw-semibold {
    font-size: 0.85rem;
  }

  .navbar small {
    font-size: 0.75rem;
  }
}

/* Small screens (Mobile landscape) */
@media (max-width: 767.98px) {
  .layout-navbar {
    padding: 0.5rem 1rem;
    min-height: auto;
  }

  .layout-menu-toggle {
    margin-right: 0.75rem;
  }

  .layout-menu-toggle .nav-link {
    padding: 0.5rem;
    font-size: 1.25rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
  }

  .layout-menu-toggle .nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
  }

  .navbar .navbar-nav {
    gap: 0.75rem;
  }

  .navbar .nav-item .d-flex.align-items-center {
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
    border-radius: 0.375rem;
  }

  .navbar .dropdown-user .avatar {
    width: 36px;
    height: 36px;
  }

  .navbar .btn {
    padding: 0.375rem 0.75rem;
    font-size: 0.85rem;
    border-radius: 0.375rem;
  }
}

/* Extra small screens (Mobile portrait) */
@media (max-width: 575.98px) {
  .layout-navbar {
    padding: 0.375rem 0.75rem;
  }

  .layout-menu-toggle {
    margin-right: 0.5rem;
  }

  .layout-menu-toggle .nav-link {
    padding: 0.625rem;
    font-size: 1.375rem;
  }

  .navbar .navbar-nav {
    gap: 0.5rem;
  }

  .navbar .nav-item .d-flex.align-items-center {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
  }

  .navbar .nav-item small {
    display: none;
  }

  .navbar .dropdown-user .avatar {
    width: 32px;
    height: 32px;
  }

  .navbar .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    min-width: auto;
  }

  .navbar .btn .d-none.d-md-block {
    display: none !important;
  }
}

/* Lab Button Layout Fixes - Override Bootstrap Grid Conflicts */
.answer-submit-container {
  display: flex !important;
  flex-wrap: nowrap !important;
  gap: 0.5rem !important;
  align-items: center !important;
  width: auto !important;
  max-width: none !important;
  flex: 0 0 auto !important;
}

/* Force buttons to stay on same line on larger screens */
@media (min-width: 992px) {
  .answer-submit-container {
    min-width: 200px !important;
    justify-content: flex-start !important;
  }

  .answer-submit-container .btn {
    flex-shrink: 0 !important;
    white-space: nowrap !important;
  }

  .answer-submit-container .btn-sm {
    font-size: 0.8rem !important;
    padding: 0.25rem 0.5rem !important;
  }
}

/* Medium screens - prevent wrapping */
@media (max-width: 991.98px) and (min-width: 768px) {
  .d-flex.gap-3.align-items-end {
    flex-wrap: nowrap !important;
    gap: 1rem !important;
  }

  .answer-input-container {
    flex: 1 1 auto !important;
    min-width: 0 !important;
  }

  .answer-submit-container {
    flex: 0 0 auto !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 0.5rem !important;
    min-width: 140px !important;
  }

  .answer-submit-container .btn {
    width: 100% !important;
    justify-content: center !important;
    font-size: 0.85rem !important;
  }

  .answer-submit-container .btn-sm {
    padding: 0.375rem 0.5rem !important;
    font-size: 0.75rem !important;
  }
}

/* Small screens - full vertical layout */
@media (max-width: 767.98px) {
  .d-flex.gap-3.align-items-end {
    flex-direction: column !important;
    gap: 1rem !important;
    align-items: stretch !important;
  }

  .answer-input-container,
  .answer-submit-container {
    width: 100% !important;
    max-width: none !important;
    flex: none !important;
  }

  .answer-submit-container {
    flex-direction: row !important;
    justify-content: space-between !important;
    gap: 0.75rem !important;
  }

  .answer-submit-container .btn {
    flex: 1 1 auto !important;
    min-width: 0 !important;
  }

  .answer-submit-container .btn-sm {
    flex: 0 0 auto !important;
    min-width: 100px !important;
    font-size: 0.8rem !important;
  }
}

/* Extra small screens - stack buttons vertically */
@media (max-width: 575.98px) {
  .answer-submit-container {
    flex-direction: column !important;
    gap: 0.5rem !important;
  }

  .answer-submit-container .btn {
    width: 100% !important;
    flex: none !important;
  }
}

/* Ensure hint button text doesn't break */
.btn-request-hint span,
.btn-outline-warning span {
  white-space: nowrap !important;
}

/* Enhanced responsive layout for new flex structure */
@media (max-width: 767.98px) {
  .d-flex.gap-3.align-items-end.flex-wrap {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 1rem !important;
  }

  .answer-input-container {
    min-width: auto !important;
  }

  .answer-submit-container {
    justify-content: space-between !important;
    width: 100% !important;
  }

  .answer-submit-container .btn {
    flex: 1 !important;
    margin-right: 0.5rem !important;
  }

  .answer-submit-container .btn:last-child {
    margin-right: 0 !important;
    flex: 0 0 auto !important;
    min-width: 120px !important;
  }
}

@media (max-width: 575.98px) {
  .answer-submit-container {
    flex-direction: column !important;
    gap: 0.5rem !important;
  }

  .answer-submit-container .btn {
    flex: none !important;
    width: 100% !important;
    margin-right: 0 !important;
  }
}

/* Ensure buttons don't wrap on medium screens */
@media (min-width: 768px) and (max-width: 991.98px) {
  .answer-submit-container {
    flex-wrap: nowrap !important;
    min-width: 200px !important;
  }

  .answer-submit-container .btn-sm {
    font-size: 0.75rem !important;
    padding: 0.25rem 0.5rem !important;
    white-space: nowrap !important;
  }
}

/* Animation for window appearance */
.floating-machine-window {
  animation: slideInUp 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideInUp {
  from {
    transform: translateY(100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Disabled Menu Items */
.menu-item-disabled .menu-link-disabled {
  opacity: 0.6;
  cursor: help;
  pointer-events: auto;
}

.menu-item-disabled .menu-link-disabled .menu-icon,
.menu-item-disabled .menu-link-disabled div {
  color: #a8aaae !important;
}

.menu-item-disabled .menu-link-disabled .ti-lock {
  opacity: 0.8;
  font-size: 14px;
  color: #6c757d;
}

/* Recommended Learning Labs Styling */
.menu-item-recommended {
  position: relative;
}

.menu-item-recommended::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(135deg, #00d4aa 0%, #00c497 50%, #00b386 100%);
  border-radius: 0 2px 2px 0;
  opacity: 0.8;
}

.recommended-icon {
  color: #00d4aa !important;
  animation: recommendedPulse 2s ease-in-out infinite;
}

@keyframes recommendedPulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
}

@keyframes arrowBounce {
  0%, 100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(2px);
  }
}