/* ============================================
   Neuro-style Sidebar for boost-like.ru
   Exact match to /neuro/frontend/ sidebar
   ============================================ */

/* --- CSS Variables --- */
:root {
  --ns-sidebar-bg: #20283c;
  --ns-sidebar-bg-fallback: #20283c;
  --ns-sidebar-text: rgba(255, 255, 255, 0.55);
  --ns-sidebar-text-active: #ffffff;
  --ns-sidebar-hover: rgba(255, 255, 255, 0.07);
  --ns-sidebar-active: rgba(99, 102, 241, 0.15);
  --ns-sidebar-accent: #818cf8;
  --ns-sidebar-border: rgba(255, 255, 255, 0.08);
  --ns-sidebar-section-text: rgba(255, 255, 255, 0.35);
  --ns-sidebar-width: 256px;
  --ns-sidebar-collapsed-width: 72px;
  --ns-header-height: 64px;
  --ns-accent: #6366f1;
  --ns-accent-text: #ffffff;
  --ns-border-primary: #e2e8f0;
  --ns-bg-primary: #ffffff;
  --ns-bg-tertiary: #f1f5f9;
  --ns-text-secondary: #64748b;
}

.theme-dark {
  --ns-sidebar-bg: #11131d;
  --ns-sidebar-bg-fallback: #11131d;
  --ns-sidebar-border: #1d1f2a;
  --ns-border-primary: #1d1f2a;
  --ns-bg-primary: #0d0f16;
  --ns-bg-tertiary: #1a1c27;
  --ns-text-secondary: #94a3b8;
}

/* ===== SIDEBAR ===== */

/* Reset & base */
.ns-sidebar {
  background: var(--ns-sidebar-bg) !important;
  background-color: var(--ns-sidebar-bg-fallback) !important;
  border-right: 1px solid var(--ns-sidebar-border) !important;
  width: var(--ns-sidebar-width) !important;
  min-width: var(--ns-sidebar-width) !important;
  max-width: var(--ns-sidebar-width) !important;
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  z-index: 50 !important;
  height: 100vh !important;
  height: 100dvh !important;
  display: flex !important;
  flex-direction: column !important;
  transition: width 0.3s ease, min-width 0.3s ease, max-width 0.3s ease, transform 0.3s ease !important;
  padding: 0 !important;
  overflow: visible !important;
  box-shadow: none !important;
}

/* Override any existing dark/light sidebar color from admin-core */
.ns-sidebar.navbar-dark,
.ns-sidebar.navbar-light,
.navbar-dark.ns-sidebar,
.navbar-light.ns-sidebar {
  background: var(--ns-sidebar-bg) !important;
}

/* Collapsed */
.ns-sidebar.navbar-folded {
  width: var(--ns-sidebar-collapsed-width) !important;
  min-width: var(--ns-sidebar-collapsed-width) !important;
  max-width: var(--ns-sidebar-collapsed-width) !important;
}

/* Hide old sidebar elements */
.ns-sidebar .mobile-logo,
.ns-sidebar > .flex-fill,
.ns-sidebar > .navbar-nav,
.ns-sidebar .navbar-heading {
  display: none !important;
}

/* ===== LOGO ===== */

.ns-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 20px;
  height: var(--ns-header-height);
  flex-shrink: 0;
}

.ns-logo a {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none !important;
}

.ns-logo-mark {
  display: flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  font-weight: 700;
  font-size: 14px;
  color: var(--ns-accent-text);
  background: linear-gradient(135deg, var(--ns-sidebar-accent) 0%, var(--ns-accent) 100%);
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
  flex-shrink: 0;
}

.ns-logo-img {
  max-height: 30px;
  width: auto;
  object-fit: contain;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.navbar-folded .ns-logo-img--full {
  opacity: 0;
  position: absolute;
  pointer-events: none;
  transform: translateX(-8px);
}

.ns-logo-img--mark {
  display: none;
  max-height: 36px;
  width: 36px;
  border-radius: 12px;
  object-fit: cover;
}

.navbar-folded .ns-logo-img--mark {
  display: block;
}

.ns-logo-text {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--ns-sidebar-text-active);
  white-space: nowrap;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.navbar-folded .ns-logo-text {
  opacity: 0;
  transform: translateX(-8px);
  position: absolute;
  pointer-events: none;
}

/* ===== NAV ===== */

.ns-nav {
  flex: 1;
  margin-top: 4px;
  padding: 0 12px 80px;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: transparent transparent;
}

@media (min-width: 1024px) {
  .ns-nav {
    padding-bottom: 16px;
  }
}

.ns-nav:hover {
  scrollbar-color: rgba(255,255,255,0.08) transparent;
}

.ns-nav::-webkit-scrollbar {
  width: 6px;
}
.ns-nav::-webkit-scrollbar-track {
  background: transparent;
}
.ns-nav::-webkit-scrollbar-thumb {
  background: transparent;
  border-radius: 9999px;
  transition: background 0.2s;
}
.ns-nav:hover::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.08);
}

.navbar-folded .ns-nav {
  padding: 0 8px;
  overflow: visible;
}

/* Section */
.ns-nav-section {
  margin-bottom: 4px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.ns-section-label {
  padding: 12px 12px 4px;
  margin: 0 0 4px 0;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ns-sidebar-section-text);
  transition: opacity 0.2s ease, transform 0.2s ease;
  line-height: 1;
}

.navbar-folded .ns-section-label {
  opacity: 0;
  height: 0;
  padding: 0;
  margin: 0;
  overflow: hidden;
  transition: none;
}

/* Divider shown only when collapsed (replaces section label) */
.ns-section-divider {
  margin: 12px 8px;
  border: 0;
  border-top: 1px solid var(--ns-sidebar-border);
  display: none;
}

.navbar-folded .ns-section-divider {
  display: block;
}

/* Spacer for first section in collapsed mode */
.navbar-folded .ns-nav-section:first-child {
  padding-top: 8px;
}

/* ===== NAV LINK ===== */

.ns-sidebar .ns-nav-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ns-sidebar-text);
  text-decoration: none !important;
  transition: all 0.2s ease;
  height: auto;
  box-shadow: none !important;
  background: transparent;
  line-height: 1.4;
}

.ns-sidebar .ns-nav-link:hover {
  background: var(--ns-sidebar-hover);
  color: var(--ns-sidebar-text-active);
}

.ns-sidebar .ns-nav-link.active {
  background: var(--ns-sidebar-active);
  color: var(--ns-sidebar-text-active);
}

/* Collapsed nav links */
.navbar-folded .ns-nav-link {
  justify-content: center;
  padding: 10px 0;
  gap: 0;
}

/* Active indicator bar */
.ns-active-indicator {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  height: 24px;
  width: 4px;
  border-radius: 0 9999px 9999px 0;
  background: var(--ns-sidebar-accent);
  transition: all 0.3s ease;
}

/* ===== NAV ICON ===== */

.ns-nav-icon {
  display: flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  flex-shrink: 0;
  transition: all 0.2s ease;
  background: transparent;
  color: inherit;
}

.ns-nav-icon i {
  font-size: 16px;
  line-height: 1;
}

.ns-nav-link.active .ns-nav-icon {
  background: var(--ns-sidebar-active);
  color: var(--ns-sidebar-accent);
}

.ns-nav-link:hover .ns-nav-icon {
  color: var(--ns-sidebar-text-active);
}

/* ===== NAV TEXT ===== */

.ns-nav-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.navbar-folded .ns-nav-text {
  opacity: 0;
  transform: translateX(-8px);
  position: absolute;
  pointer-events: none;
  width: 0;
  overflow: hidden;
}

/* Badge (tickets count) */
.ns-badge {
  margin-left: auto;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 9999px;
  background: var(--ns-sidebar-accent);
  color: var(--ns-accent-text);
  line-height: 1.3;
  flex-shrink: 0;
}

.navbar-folded .ns-badge {
  display: none;
}

/* ===== SERVICE SWITCHER ===== */

.ns-service-switcher-wrap {
  flex-shrink: 0;
  padding: 0 12px;
}

.ns-service-switcher-top {
  padding-top: 8px;
  padding-bottom: 4px;
}

.navbar-folded .ns-service-switcher-wrap {
  padding: 0 8px;
}

.navbar-folded .ns-service-switcher-top {
  padding-top: 8px;
  padding-bottom: 4px;
}

.ns-service-switcher {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none !important;
  color: var(--ns-sidebar-text-active) !important;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12) 0%, rgba(139, 92, 246, 0.12) 100%);
  border: 1px solid rgba(99, 102, 241, 0.2);
  transition: all 0.2s ease;
}

.ns-service-switcher:hover {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.22) 0%, rgba(139, 92, 246, 0.22) 100%);
  border-color: rgba(99, 102, 241, 0.35);
}

.navbar-folded .ns-service-switcher {
  justify-content: center;
  padding: 10px 0;
  gap: 0;
}

.ns-service-switcher-icon {
  display: flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--ns-sidebar-accent) 0%, var(--ns-accent) 100%);
  color: var(--ns-accent-text);
}

.ns-service-switcher-text {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.ns-service-switcher-text svg {
  transition: transform 0.2s ease;
}

.ns-service-switcher:hover .ns-service-switcher-text svg {
  transform: translateX(2px);
}

.navbar-folded .ns-service-switcher-text {
  opacity: 0;
  transform: translateX(-8px);
  position: absolute;
  pointer-events: none;
  width: 0;
  overflow: hidden;
}

.menu-expanded .ns-service-switcher-text {
  animation: ns-slide-fade-in 0.2s ease-out forwards;
}

/* ===== MOBILE BACKDROP ===== */

.ns-backdrop {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  background: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.ns-backdrop.visible {
  opacity: 1;
}

/* ===== MOBILE SIDEBAR ===== */

@media (max-width: 1023px) {
  .ns-sidebar {
    transform: translateX(-100%) !important;
  }

  .sidebar-opened .ns-sidebar {
    transform: translateX(0) !important;
  }

  .sidebar-opened .ns-backdrop {
    display: block;
  }
}

/* Desktop: sidebar always visible */
@media (min-width: 1024px) {
  .ns-sidebar {
    transform: translateX(0) !important;
  }
}

/* ===== MAIN AREA LAYOUT ===== */

.ns-main-area {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

@media (min-width: 1024px) {
  .ns-main-area {
    margin-left: var(--ns-sidebar-width);
    transition: margin-left 0.3s ease;
  }

  .menu-folded .ns-main-area {
    margin-left: var(--ns-sidebar-collapsed-width);
  }
}

/* ===== HEADER ADJUSTMENTS (user layout only — requires .ns-sidebar on page) ===== */

body:has(.ns-sidebar) .js-header {
  position: sticky !important;
  top: 0;
  z-index: 30;
  height: var(--ns-header-height);
  min-height: var(--ns-header-height);
  border-bottom: 1px solid var(--ns-border-primary) !important;
  background: var(--ns-bg-primary) !important;
  padding: 0 16px !important;
  display: flex;
  align-items: center;
}

body:has(.ns-sidebar) .js-header .header-wrap {
  display: flex;
  align-items: center;
  width: 100%;
  height: 100%;
}

/* Mobile hamburger: visible below 1024px */
body:has(.ns-sidebar) .js-header .mobile-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s ease;
  color: var(--ns-text-secondary);
  padding: 0 !important;
  border: none !important;
  background: transparent;
  flex-shrink: 0;
  margin-left: -8px;
}

body:has(.ns-sidebar) .js-header .mobile-menu .navbar-toggler-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: auto;
  height: auto;
  background-image: none !important;
}

body:has(.ns-sidebar) .js-header .mobile-menu:hover {
  background: var(--ns-bg-tertiary);
}

@media (min-width: 1024px) {
  body:has(.ns-sidebar) .js-header .mobile-menu {
    display: none !important;
    margin-left: 0;
  }
}

/* Mobile logo left-aligned */
@media (max-width: 1023px) {
  body:has(.ns-sidebar) .js-header .header-wrap {
    position: relative;
  }

  body:has(.ns-sidebar) .js-header .navbar-brand {
    position: static;
    transform: none;
    margin: 0 0 0 8px !important;
  }
}

/* Hide notification bell on small screens */
@media (max-width: 380px) {
  body:has(.ns-sidebar) .js-header .navbar-menu .notifcation {
    display: none !important;
  }
}

/* Desktop sidebar toggle */
.ns-desktop-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: background 0.15s ease;
  color: var(--ns-text-secondary);
  padding: 0;
}

.ns-desktop-toggle:hover {
  background: var(--ns-bg-tertiary);
}

.ns-desktop-toggle svg {
  width: 20px;
  height: 20px;
}

@media (min-width: 1024px) {
  .ns-desktop-toggle {
    display: flex;
  }
}

/* Header spacer */
.ns-header-spacer {
  flex: 1;
}

/* ===== TRANSITION ANIMATIONS ===== */

/* Slide-fade for labels/text */
@keyframes ns-slide-fade-in {
  from {
    opacity: 0;
    transform: translateX(-8px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes ns-slide-fade-out {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(-8px);
  }
}

/* Smooth sidebar expand animation for text */
.menu-expanded .ns-logo-text,
.menu-expanded .ns-section-label,
.menu-expanded .ns-nav-text,
.menu-expanded .ns-user-info,
.menu-expanded .ns-logo-img--full {
  animation: ns-slide-fade-in 0.2s ease-out forwards;
}

/* ===== TOOLTIP OVERRIDE FOR COLLAPSED STATE ===== */

.navbar-folded .ns-nav-link[data-toggle="tooltip"] + .tooltip {
  z-index: 9999;
}

/* ===== OVERRIDE ADMIN-CORE SIDEBAR STYLES ===== */

/* Remove any admin-core nav-link styles within ns-sidebar */
.ns-sidebar .nav-link,
.ns-sidebar .nav-item,
.ns-sidebar .navbar-nav {
  all: unset;
}

/* Override layout-main padding ONLY when ns-sidebar is present (user layout) */
@media (min-width: 1024px) {
  .ns-sidebar ~ .layout-main,
  .ns-sidebar ~ .d-flex > .layout-main {
    padding-left: 0 !important;
    margin-left: 0 !important;
  }
}

/* Override body sidebar-opened effect for desktop (user layout only) */
@media (min-width: 1024px) {
  body:has(.ns-sidebar) .sidebar-opened,
  .sidebar-opened:has(.ns-sidebar) {
    overflow: auto !important;
  }
}

/* ===== HEADER RIGHT-SIDE ACTIONS (user layout only) ===== */

body:has(.ns-sidebar) .js-header .navbar-menu {
  display: flex !important;
  align-items: center;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}

body:has(.ns-sidebar) .js-header .navbar-menu .nav-item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 !important;
  margin: 0 !important;
}

body:has(.ns-sidebar) .js-header .navbar-menu .nav-item .nav-link {
  padding: 0 !important;
  margin: 0 !important;
}

/* --- Balance Badge --- */
.ns-balance-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  border-radius: 9999px;
  background: rgba(99, 102, 241, 0.15);
  color: #6366f1;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none !important;
  transition: opacity 0.15s ease;
  white-space: nowrap;
  line-height: 1;
}

.ns-balance-badge:hover {
  opacity: 0.8;
  color: #6366f1;
  text-decoration: none !important;
}

.ns-balance-currency {
  font-weight: 500;
  font-size: 14px;
}

/* --- Theme Toggle --- */
.ns-theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: background 0.15s ease;
  color: var(--ns-text-secondary);
  padding: 0;
}

.ns-theme-toggle:hover {
  background: var(--ns-bg-tertiary);
}

.ns-theme-toggle svg {
  width: 20px;
  height: 20px;
}

.ns-theme-icon-sun,
.ns-theme-icon-moon {
  display: none;
}

/* --- Notification bell adjustments (user layout only) --- */
body:has(.ns-sidebar) .js-header .navbar-menu .notifcation .nav-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  padding: 0;
  transition: background 0.15s ease;
  color: var(--ns-text-secondary);
}

body:has(.ns-sidebar) .js-header .navbar-menu .notifcation .nav-link:hover {
  background: var(--ns-bg-tertiary);
}

body:has(.ns-sidebar) .js-header .navbar-menu .notifcation .nav-link .fe {
  font-size: 20px;
}

/* --- Bell notification dot --- */
.ns-bell-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ns-bell-dot {
  position: absolute;
  top: -1px;
  right: -1px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--ns-accent, #6366f1);
  border: 2px solid var(--ns-bg-primary, #ffffff);
  animation: ns-bell-pulse 2.5s ease-in-out infinite;
}

.theme-dark .ns-bell-dot {
  background: #818cf8;
  border-color: #11131d;
}

@keyframes ns-bell-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.2); }
}

/* --- Avatar Button --- */
.ns-avatar-btn {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 9999px;
  background: var(--ns-accent);
  color: var(--ns-accent-text) !important;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  text-decoration: none !important;
  cursor: pointer;
  transition: opacity 0.15s ease;
  line-height: 1;
  padding: 0;
}

.ns-avatar-btn:hover {
  opacity: 0.8;
  color: var(--ns-accent-text) !important;
  text-decoration: none !important;
}

/* --- Avatar Dropdown --- */
.ns-avatar-dropdown {
  min-width: 220px;
  border: 1px solid var(--ns-border-primary) !important;
  border-radius: 12px !important;
  background: var(--ns-bg-primary) !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1), 0 4px 10px rgba(0, 0, 0, 0.05) !important;
  padding: 4px 0 !important;
  margin-top: 8px !important;
}

.theme-dark .ns-avatar-dropdown {
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3), 0 4px 10px rgba(0, 0, 0, 0.2) !important;
}

.ns-avatar-info {
  padding: 12px 16px;
}

.ns-avatar-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--ns-text-secondary);
  margin: 0;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.theme-dark .ns-avatar-name {
  color: #e2e8f0;
}

.ns-avatar-email {
  font-size: 12px;
  color: var(--ns-text-secondary);
  margin: 2px 0 0 0;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ns-avatar-dropdown .dropdown-divider {
  border-top-color: var(--ns-border-primary);
  margin: 4px 0;
}

.ns-avatar-dropdown .dropdown-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  font-size: 14px;
  color: var(--ns-text-secondary);
  transition: background 0.15s ease;
}

.theme-dark .ns-avatar-dropdown .dropdown-item {
  color: #cbd5e1;
}

.ns-avatar-dropdown .dropdown-item:hover {
  background: var(--ns-bg-tertiary);
}

.ns-avatar-dropdown .dropdown-item .fe {
  font-size: 16px;
}

.ns-logout-item,
.ns-logout-item:hover {
  color: #ef4444 !important;
}

/* ===== APP CONTENT ===== */
.ns-main-area .app-content {
  flex: 1;
}

/* ===== DARK THEME — Dashboard Content ===== */

/* General page background & text */
.theme-dark .ns-main-area {
  background: var(--ns-bg-primary);
  color: #e2e8f0;
}

/* Cards */
.theme-dark .card {
  background: #1a1c27 !important;
  border-color: #2d2f3a !important;
  color: #e2e8f0;
}

.theme-dark .card-header {
  background: #1a1c27 !important;
  border-bottom-color: #2d2f3a !important;
  color: #e2e8f0;
}

.theme-dark .card-body {
  color: #e2e8f0;
}

/* --- 1. Order tabs (Одиночный заказ / Массовый заказ) --- */
.theme-dark .tabs-list .nav-tabs {
  border-bottom-color: transparent;
}

.theme-dark .tabs-list .tab-content {
  border-top-color: transparent;
}

/* Service description block */
.service-desc-block {
  padding: 16px 20px;
  min-height: 160px;
  background: #f8fafc;
  font-size: 13px;
  line-height: 1.65;
  color: #475569;
  border-radius: 10px;
}

.ns-order-card .service-desc-block {
  border: 1px solid #e2e8f0;
}

.ns-order-card .card.border {
  border: none !important;
  box-shadow: none !important;
  background: transparent !important;
}

.theme-dark .service-desc-block {
  background: #0d0f16;
  color: #cbd5e1;
}

.theme-dark .ns-order-card .service-desc-block {
  border-color: #2d2f3a;
}

.theme-dark .tabs-list .nav-tabs li > a {
  color: #94a3b8;
}

.theme-dark .tabs-list .nav-tabs li > a.active,
.theme-dark .tabs-list .nav-tabs li > a:hover {
  color: #fff;
  background: #6366f1;
}

/* --- 2. Select dropdowns & form controls --- */
.theme-dark .form-control,
.theme-dark select.form-control,
.theme-dark textarea.form-control,
.theme-dark input.form-control {
  background-color: #0d0f16 !important;
  border-color: #2d2f3a !important;
  color: #e2e8f0 !important;
}

.theme-dark .form-control:focus {
  border-color: #6366f1 !important;
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.15) !important;
}

.theme-dark .form-control::placeholder {
  color: #64748b !important;
}

.theme-dark select.form-control option {
  background-color: #1a1c27;
  color: #e2e8f0;
}

.theme-dark .form-group label,
.theme-dark label {
  color: #cbd5e1;
}

/* Custom select (Bootstrap) */
.theme-dark .custom-select {
  background-color: #0d0f16 !important;
  border-color: #2d2f3a !important;
  color: #e2e8f0 !important;
}

/* Selectize (tags input) */
.theme-dark .selectize-input {
  background-color: #0d0f16 !important;
  border-color: #2d2f3a !important;
  color: #e2e8f0 !important;
}

.theme-dark .selectize-dropdown {
  background-color: #1a1c27 !important;
  border-color: #2d2f3a !important;
  color: #e2e8f0 !important;
}

.theme-dark .selectize-dropdown .active {
  background-color: #6366f1 !important;
  color: #fff !important;
}

/* --- 3. Description block / info block --- */
.theme-dark .inf_order_title {
  color: #e2e8f0;
}

.theme-dark .inf_order_desc {
  color: #94a3b8;
}

.theme-dark .content-header-title h4,
.theme-dark .content-header-title h6 {
  color: #e2e8f0;
}

.theme-dark .mass_order_error {
  color: #94a3b8;
}

/* Order balance block in header */
.theme-dark .order_add_funds_block span,
.theme-dark .order_funds_txt span {
  color: #cbd5e1;
}

.theme-dark .order_funds_btn a {
  color: #fff;
}

/* Total charge button */
.theme-dark .total_charge {
  background: rgba(99, 102, 241, 0.15) !important;
  border-color: rgba(99, 102, 241, 0.3) !important;
  color: #818cf8 !important;
}

/* --- 4. Navigation filter buttons (orders, dripfeed, subscriptions) --- */
.theme-dark .order_btn_group .list-inline-item a.btn {
  color: #94a3b8;
  border-color: #2d2f3a;
  background: transparent;
}

.theme-dark .order_btn_group .list-inline-item a.btn:hover {
  color: #e2e8f0;
  border-color: #6366f1;
  background: rgba(99, 102, 241, 0.1);
}

.theme-dark .order_btn_group .list-inline-item a.btn.btn-info {
  color: #fff !important;
  background: #6366f1 !important;
  border-color: #6366f1 !important;
}

/* Nav tabs general (used on various pages) */
.theme-dark .nav-tabs {
  border-bottom-color: #2d2f3a;
}

.theme-dark .nav-tabs .nav-link {
  color: #94a3b8;
}

.theme-dark .nav-tabs .nav-link.active {
  color: #6366f1;
  border-color: #6366f1;
  background: transparent;
}

.theme-dark .nav-tabs .nav-link:hover:not(.disabled) {
  color: #e2e8f0;
  border-color: #6366f1;
}

/* --- General dark theme elements --- */

/* Page titles */
.theme-dark .page-title,
.theme-dark .page-title h1 {
  color: #e2e8f0;
}

/* Links */
.theme-dark a.btn-outline-primary {
  color: #818cf8;
  border-color: #818cf8;
}

.theme-dark a.btn-outline-primary:hover {
  background: #6366f1;
  border-color: #6366f1;
  color: #fff;
}

/* Buttons */
.theme-dark .btn-primary {
  background: #6366f1 !important;
  border-color: #6366f1 !important;
}

.theme-dark .btn-primary:hover {
  background: #4f46e5 !important;
  border-color: #4f46e5 !important;
}

.theme-dark .btn-info {
  background: #6366f1 !important;
  border-color: #6366f1 !important;
}

/* Tables */
.theme-dark .table {
  color: #e2e8f0;
}

.theme-dark .table thead th {
  border-bottom-color: #2d2f3a;
  color: #94a3b8;
}

.theme-dark .table td,
.theme-dark .table th {
  border-top-color: #2d2f3a;
}

.theme-dark .table-striped tbody tr:nth-of-type(odd) {
  background-color: rgba(255, 255, 255, 0.02);
}

.theme-dark .table-hover tbody tr:hover {
  background-color: rgba(99, 102, 241, 0.05);
}

/* Alerts */
.theme-dark .alert-danger {
  background-color: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.3);
  color: #fca5a5;
}

/* Text colors */
.theme-dark .text-muted {
  color: #64748b !important;
}

.theme-dark h1, .theme-dark h2, .theme-dark h3,
.theme-dark h4, .theme-dark h5, .theme-dark h6 {
  color: #e2e8f0;
}

/* Dropdown menus */
.theme-dark .dropdown-menu {
  background-color: #1a1c27;
  border-color: #2d2f3a;
}

.theme-dark .dropdown-item {
  color: #cbd5e1;
}

.theme-dark .dropdown-item:hover {
  background-color: rgba(99, 102, 241, 0.1);
  color: #e2e8f0;
}

.theme-dark .dropdown-divider {
  border-top-color: #2d2f3a;
}

/* Pagination */
.theme-dark .page-link {
  background-color: #1a1c27;
  border-color: #2d2f3a;
  color: #94a3b8;
}

.theme-dark .page-item.active .page-link {
  background-color: #6366f1;
  border-color: #6366f1;
  color: #fff;
}

.theme-dark .page-link:hover {
  background-color: rgba(99, 102, 241, 0.1);
  border-color: #2d2f3a;
  color: #e2e8f0;
}

/* Search area */
.theme-dark .search-area input {
  background-color: #0d0f16 !important;
  border-color: #2d2f3a !important;
  color: #e2e8f0 !important;
}

/* Custom switch */
.theme-dark .custom-switch-indicator {
  background: #2d2f3a;
  border-color: #3d3f4a;
}

/* Modal */
.theme-dark .modal-content {
  background-color: #1a1c27;
  border-color: #2d2f3a;
  color: #e2e8f0;
}

.theme-dark .modal-header {
  border-bottom-color: #2d2f3a;
}

.theme-dark .modal-footer {
  border-top-color: #2d2f3a;
}

/* Bottom mobile navigation — dark overrides handled in main.blade.php inline styles */

/* Stat cards / dashboard blocks */
.theme-dark .stat_header_item {
  background: #1a1c27;
  border-color: #2d2f3a;
}

/* Custom checkbox label */
.theme-dark .custom-control-label {
  color: #cbd5e1;
}

/* ===== MODERN ORDER FORM ===== */

/* --- Order page card --- */
.ns-order-card {
  border: none !important;
  border-radius: 16px !important;
  background: var(--ns-bg-primary) !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 6px 24px rgba(0, 0, 0, 0.06) !important;
  overflow: hidden;
}

.theme-dark .ns-order-card {
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 6px 24px rgba(0, 0, 0, 0.2) !important;
}

/* --- Order card header (tabs + balance) --- */
.ns-order-card > .card-header.order_head_funds {
  background: var(--ns-bg-primary) !important;
  border-bottom: 1px solid var(--ns-border-primary) !important;
  padding: 16px 24px !important;
  flex-wrap: wrap;
  gap: 12px;
}

/* --- Tabs styling --- */
.ns-order-card .tabs-list .nav-tabs {
  border-bottom: none !important;
  gap: 8px;
  display: flex;
}

.ns-order-card .tabs-list .nav-tabs li > a {
  color: var(--ns-text-secondary) !important;
  background: transparent !important;
  padding: 8px 16px !important;
  border-radius: 10px !important;
  margin: 0 4px 0 0 !important;
  font-size: 14px;
  font-weight: 500;
  border: 1px solid transparent !important;
  transition: all 0.2s ease;
  white-space: nowrap;
  display: inline-block;
}

.ns-order-card .tabs-list .nav-tabs li > a:hover {
  color: var(--ns-accent) !important;
  background: rgba(99, 102, 241, 0.06) !important;
}

.ns-order-card .tabs-list .nav-tabs li > a.active,
.ns-order-card .tabs-list .nav-tabs li > a.active:hover {
  color: #fff !important;
  background: var(--ns-accent) !important;
  border-color: var(--ns-accent) !important;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

.ns-order-card .tabs-list .tab-content {
  border-top: none !important;
}

/* --- Balance block in header --- */
.ns-order-card .order_add_funds_block {
  margin-left: auto;
  align-items: center;
  gap: 12px;
}

.ns-order-card .order_funds_txt span {
  font-size: 13px;
  color: var(--ns-text-secondary);
}

.ns-order-card .order_funds_txt b {
  color: var(--ns-accent);
  font-weight: 700;
}

.ns-order-card .order_funds_btn a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 600;
  color: #fff !important;
  background: var(--ns-accent);
  text-decoration: none !important;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.25);
}

.ns-order-card .order_funds_btn a:hover {
  background: #4f46e5;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
  transform: translateY(-1px);
}

/* --- Card body --- */
.ns-order-card > .card-body {
  padding: 24px !important;
}

/* --- Section headers --- */
.ns-order-card .content-header-title {
  margin-bottom: 20px;
}

.ns-order-card .content-header-title h4,
.ns-order-card .content-header-title h6 {
  font-size: 16px;
  font-weight: 600;
  color: #1e293b;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

.ns-order-card .content-header-title h4 i,
.ns-order-card .content-header-title h6 i {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: rgba(99, 102, 241, 0.1);
  color: var(--ns-accent);
  font-size: 14px;
}

.theme-dark .ns-order-card .content-header-title h4,
.theme-dark .ns-order-card .content-header-title h6 {
  color: #e2e8f0;
}

/* --- Form groups --- */
.ns-order-card .form-group {
  margin-bottom: 18px;
}

.ns-order-card .form-group label {
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  margin-bottom: 6px;
  letter-spacing: 0.01em;
}

.theme-dark .ns-order-card .form-group label {
  color: #94a3b8;
}

/* --- Form controls --- */
.ns-order-card .form-control {
  border: 1px solid #e2e8f0 !important;
  border-radius: 10px !important;
  padding: 10px 14px !important;
  font-size: 14px !important;
  background-color: #f8fafc !important;
  color: #1e293b !important;
  transition: all 0.2s ease !important;
  min-height: 44px !important;
}

.ns-order-card .form-control:focus {
  border-color: var(--ns-accent) !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12) !important;
  background-color: #fff !important;
}

.ns-order-card .form-control:read-only {
  background-color: var(--ns-bg-tertiary) !important;
  color: var(--ns-text-secondary) !important;
  cursor: default;
}

.ns-order-card select.form-control {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e") !important;
  background-position: right 12px center !important;
  background-repeat: no-repeat !important;
  background-size: 20px !important;
  padding-right: 40px !important;
}

.ns-order-card textarea.form-control {
  min-height: 120px !important;
  resize: vertical;
}

/* Dark theme form controls */
.theme-dark .ns-order-card .form-control {
  background-color: #0d0f16 !important;
  border-color: #2d2f3a !important;
  color: #e2e8f0 !important;
}

.theme-dark .ns-order-card .form-control:focus {
  background-color: #1a1c27 !important;
  border-color: var(--ns-accent) !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15) !important;
}

.theme-dark .ns-order-card .form-control:read-only {
  background-color: #11131d !important;
  color: #64748b !important;
}

.theme-dark .ns-order-card select.form-control {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%2394a3b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e") !important;
}

/* --- Order resume right panel --- */
.ns-order-card .order_resume {
  border-left: 1px solid var(--ns-border-primary);
  padding-left: 24px;
}

.theme-dark .ns-order-card .order_resume {
  border-left-color: #2d2f3a;
}

/* --- Service info card-based layout (right panel) --- */
.ns-order-card .service-info-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--ns-text-primary, #1e293b);
  margin-bottom: 16px;
  line-height: 1.4;
}

.theme-dark .ns-order-card .service-info-name {
  color: #e2e8f0;
}

.ns-order-card .service-info-stats {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.ns-order-card .service-info-stat {
  flex: 1;
  background: var(--ns-bg-tertiary, #f8fafc);
  border: 1px solid var(--ns-border-primary, #e2e8f0);
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.theme-dark .ns-order-card .service-info-stat {
  background: #0d0f16;
  border-color: #2d2f3a;
}

.ns-order-card .service-info-label {
  font-size: 11px;
  font-weight: 500;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.ns-order-card .service-info-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--ns-accent, #6366f1);
  line-height: 1.2;
}

.theme-dark .ns-order-card .service-info-value {
  color: #818cf8;
}

.ns-order-card .service-info-desc {
  background: var(--ns-bg-tertiary, #f8fafc);
  border-radius: 10px;
  padding: 14px 16px;
  font-size: 14px;
  line-height: 1.6;
  color: #64748b;
}

.theme-dark .ns-order-card .service-info-desc {
  background: #0d0f16;
  color: #94a3b8;
}

.ns-order-card .service-info-desc:empty {
  display: none;
}

/* Collapsible description */
.ns-order-card .service-info-desc-toggle ~ .service-info-desc {
  max-height: 120px;
  overflow: hidden;
  position: relative;
}

.ns-order-card .service-info-desc-toggle ~ .service-info-desc::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: linear-gradient(transparent, var(--ns-bg-tertiary, #f8fafc));
  pointer-events: none;
}

.theme-dark .ns-order-card .service-info-desc-toggle ~ .service-info-desc::after {
  background: linear-gradient(transparent, #0d0f16);
}

.ns-order-card .service-info-desc-toggle:checked ~ .service-info-desc {
  max-height: none;
}

.ns-order-card .service-info-desc-toggle:checked ~ .service-info-desc::after {
  display: none;
}

.ns-order-card .service-info-desc-more {
  display: inline-block;
  margin-top: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ns-accent, #6366f1);
  cursor: pointer;
}

.ns-order-card .service-info-desc-more::after {
  content: 'Показать полностью';
}

.ns-order-card .service-info-desc-toggle:checked ~ .service-info-desc-more::after {
  content: 'Свернуть';
}

/* Placeholder (empty state) */
.ns-order-card .service-info-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 16px 0;
}

.ns-order-card .service-info-placeholder-icon {
  margin-bottom: 16px;
}

.ns-order-card .service-info-placeholder-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--ns-text-primary, #1e293b);
  margin: 0 0 8px;
}

.theme-dark .ns-order-card .service-info-placeholder-title {
  color: #e2e8f0;
}

.ns-order-card .service-info-placeholder-hint {
  color: #94a3b8;
  font-size: 14px;
  margin: 0 0 8px;
}

.ns-order-card .service-info-placeholder-list {
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
  font-size: 13px;
  color: #64748b;
}

.theme-dark .ns-order-card .service-info-placeholder-list {
  color: #94a3b8;
}

.ns-order-card .service-info-placeholder-list li {
  padding: 2px 0;
}

.ns-order-card .service-info-placeholder-list li::before {
  content: '\2022';
  color: var(--ns-accent, #6366f1);
  margin-right: 6px;
}

.ns-order-card .service-info-placeholder .service-info-stats {
  width: 100%;
}

/* Skeleton chips */
.ns-order-card .service-info-stat--skeleton {
  background: var(--ns-bg-tertiary, #f8fafc);
  border: 1px dashed var(--ns-border-primary, #e2e8f0);
}

.theme-dark .ns-order-card .service-info-stat--skeleton {
  background: #0d0f16;
  border-color: #2d2f3a;
}

.ns-order-card .service-info-stat--skeleton .service-info-value {
  color: #94a3b8;
}

@media (max-width: 768px) {
  .ns-order-card .service-info-stats {
    gap: 8px;
  }
  .ns-order-card .service-info-stat {
    padding: 10px 12px;
  }
  .ns-order-card .service-info-value {
    font-size: 16px;
  }
}

@media (max-width: 430px) {
  .ns-order-card .service-info-stats {
    flex-direction: column;
  }
}

/* --- Legacy: Service info row (min/max/price) --- */
.ns-order-card #result_onChangeService .col-md-4 .form-control {
  text-align: center;
  font-weight: 600;
  font-size: 15px !important;
  color: var(--ns-accent) !important;
}

.theme-dark .ns-order-card #result_onChangeService .col-md-4 .form-control {
  color: #818cf8 !important;
}

/* --- Service description textarea --- */
.ns-order-card .order_resume textarea[name="service_desc"] {
  min-height: 160px !important;
  font-size: 13px !important;
  line-height: 1.6;
}

/* --- Total charge badge --- */
.ns-order-card .total_charge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  border-radius: 12px;
  background: rgba(99, 102, 241, 0.08) !important;
  border: 1px solid rgba(99, 102, 241, 0.15) !important;
  color: #475569 !important;
  font-size: 15px;
  font-weight: 500;
  cursor: default;
  margin-top: 8px;
  margin-bottom: 8px;
}

.ns-order-card .total_charge .charge_number {
  color: var(--ns-accent) !important;
  font-weight: 700;
  font-size: 16px;
}

.theme-dark .ns-order-card .total_charge {
  background: rgba(99, 102, 241, 0.12) !important;
  border-color: rgba(99, 102, 241, 0.25) !important;
  color: #cbd5e1 !important;
}

.theme-dark .ns-order-card .total_charge .charge_number {
  color: #818cf8 !important;
}

/* --- Submit button --- */
.ns-order-card .add_order_btn {
  padding: 12px 32px !important;
  border-radius: 12px !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%) !important;
  border: none !important;
  color: #fff !important;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
  transition: all 0.2s ease !important;
  min-width: 180px;
  text-align: center;
}

.ns-order-card .add_order_btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.ns-order-card .add_order_btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

/* Mass order submit button */
.ns-order-card #mass_order .btn-primary {
  padding: 12px 32px !important;
  border-radius: 12px !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%) !important;
  border: none !important;
  color: #fff !important;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
  transition: all 0.2s ease !important;
}

.ns-order-card #mass_order .btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

/* --- Drip feed section --- */
.ns-order-card .drip-feed-option {
  margin-top: 4px;
}

.ns-order-card .drip-feed-option .form-label {
  font-size: 14px;
  font-weight: 600;
  color: #475569;
  display: flex;
  align-items: center;
  gap: 8px;
}

.theme-dark .ns-order-card .drip-feed-option .form-label {
  color: #cbd5e1;
}

.ns-order-card .custom-switch-indicator {
  border-radius: 9999px;
}

/* --- Info section at bottom --- */
.ns-order-card .inf_order_title {
  font-size: 18px;
  font-weight: 700;
  color: #1e293b;
  margin-top: 32px !important;
  margin-bottom: 8px;
}

.ns-order-card .inf_order_desc {
  font-size: 14px;
  line-height: 1.7;
  color: #64748b;
  padding: 16px 20px;
  background: var(--ns-bg-tertiary);
  border-radius: 12px;
  border: 1px solid var(--ns-border-primary);
}

.theme-dark .ns-order-card .inf_order_title {
  color: #e2e8f0;
}

.theme-dark .ns-order-card .inf_order_desc {
  background: #11131d;
  border-color: #2d2f3a;
  color: #94a3b8;
}

/* --- Mass order note block --- */
.ns-order-card .mass_order_error {
  padding: 16px 20px;
  background: var(--ns-bg-tertiary);
  border-radius: 12px;
  border: 1px solid var(--ns-border-primary);
}

.theme-dark .ns-order-card .mass_order_error {
  background: #11131d;
  border-color: #2d2f3a;
}

/* --- Alert in order form --- */
.ns-order-card .alert {
  border-radius: 10px !important;
}

/* --- Input group (for datepicker) --- */
.ns-order-card .input-group .form-control {
  border-top-right-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}

.ns-order-card .input-group .btn {
  border-radius: 0 10px 10px 0 !important;
  border: 1px solid #e2e8f0;
  border-left: none;
}

.theme-dark .ns-order-card .input-group .btn {
  border-color: #2d2f3a;
  background: #1a1c27;
  color: #94a3b8;
}

/* --- Subscriptions section --- */
.ns-order-card .order-subscriptions .form-control {
  min-height: 44px !important;
}

/* --- Selectize (tags) override --- */
.ns-order-card .selectize-input {
  border: 1px solid #e2e8f0 !important;
  border-radius: 10px !important;
  padding: 8px 14px !important;
  min-height: 44px !important;
  background: #f8fafc !important;
  box-shadow: none !important;
}

.ns-order-card .selectize-input.focus {
  border-color: var(--ns-accent) !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12) !important;
  background: #fff !important;
}

.ns-order-card .selectize-dropdown {
  border: 1px solid #e2e8f0 !important;
  border-radius: 10px !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
  margin-top: 4px;
}

.theme-dark .ns-order-card .selectize-input {
  background: #0d0f16 !important;
  border-color: #2d2f3a !important;
  color: #e2e8f0 !important;
}

.theme-dark .ns-order-card .selectize-input.focus {
  background: #1a1c27 !important;
  border-color: var(--ns-accent) !important;
}

.theme-dark .ns-order-card .selectize-dropdown {
  background: #1a1c27 !important;
  border-color: #2d2f3a !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3) !important;
}

/* --- Mass order: align note block level with textarea --- */
.ns-order-card #mass_order .mass_order_error {
  margin-top: 39px;
}

/* Remove bottom margin from the last form-group in left column so heights match visually */
.ns-order-card #mass_order .x_content > .col-md-6:first-child .form-group:last-child {
  margin-bottom: 0;
}


/* ===== ORDER FORM MOBILE RESPONSIVE ===== */

@media (max-width: 767px) {
  .ns-order-card > .card-header.order_head_funds {
    padding: 12px 16px !important;
    flex-direction: column;
    align-items: flex-start;
  }

  .ns-order-card .order_add_funds_block {
    margin-left: 0;
    width: 100%;
    justify-content: space-between;
  }

  .ns-order-card > .card-body {
    padding: 16px !important;
  }

  .ns-order-card .tabs-list .nav-tabs li > a {
    padding: 7px 12px !important;
    font-size: 13px;
  }

  .ns-order-card .order_resume {
    border-left: none;
    padding-left: 0;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--ns-border-primary);
  }

  .theme-dark .ns-order-card .order_resume {
    border-top-color: #2d2f3a;
  }

  .ns-order-card .content-header-title {
    margin-bottom: 16px;
  }

  .ns-order-card .add_order_btn {
    width: 100%;
    min-width: unset;
  }

  .ns-order-card #mass_order .btn-primary {
    width: 100%;
  }

  .ns-order-card .inf_order_desc {
    padding: 14px 16px;
    font-size: 13px;
  }

  .ns-order-card .total_charge {
    width: 100%;
    justify-content: center;
  }

  /* Mass order: note block spacing on mobile */
  .ns-order-card #mass_order .mass_order_error {
    margin-top: 0;
  }

  .ns-order-card #mass_order .form-actions {
    margin-top: 20px;
  }

  /* Prevent iOS auto-zoom on focus (requires font-size >= 16px) */
  .ns-order-card .form-control,
  .ns-order-card select.form-control,
  .ns-order-card textarea.form-control {
    font-size: 16px !important;
    min-height: 48px !important;
  }

  .ns-order-card select.form-control {
    background-size: 22px !important;
    padding-right: 42px !important;
  }
}

/* --- Guides section below card --- */
.ns-order-guides .page-title h1 {
  font-size: 22px;
  font-weight: 700;
  color: #1e293b;
}

.theme-dark .ns-order-guides .page-title h1 {
  color: #e2e8f0;
}

.ns-order-guides .content {
  font-size: 14px;
  line-height: 1.7;
  color: #64748b;
  padding: 20px 24px;
  background: var(--ns-bg-primary);
  border-radius: 16px;
  border: 1px solid var(--ns-border-primary);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 6px 24px rgba(0, 0, 0, 0.06);
}

.theme-dark .ns-order-guides .content {
  background: #1a1c27;
  border-color: #2d2f3a;
  color: #94a3b8;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 6px 24px rgba(0, 0, 0, 0.2);
}

/* ============================================
   Neuro Order List Styles (.ns-ol-*)
   For /order and /admin/order pages
   ============================================ */

/* --- Page header --- */
.ns-ol-header {
  margin-bottom: 24px;
}

.ns-ol-header .ns-ol-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}

.ns-ol-title {
  font-size: 22px;
  font-weight: 700;
  color: #1e293b;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

.ns-ol-title .ns-ol-title-icon {
  display: inline-flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: rgba(99, 102, 241, 0.1);
  color: var(--ns-accent);
  font-size: 16px;
}

.theme-dark .ns-ol-title {
  color: #e2e8f0;
}

/* --- Add new order button --- */
.ns-ol-add-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 20px;
  border-radius: 9999px;
  font-size: 14px;
  font-weight: 600;
  color: #fff !important;
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  text-decoration: none !important;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.25);
  border: none;
}

.ns-ol-add-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
  color: #fff !important;
  text-decoration: none !important;
}

/* --- Filter pills --- */
.ns-ol-filters {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.ns-ol-filters li {
  margin: 0;
  padding: 0;
}

.ns-ol-filters li a {
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ns-text-secondary);
  background: var(--ns-bg-tertiary);
  border: 1px solid var(--ns-border-primary);
  text-decoration: none !important;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.ns-ol-filters li a:hover {
  color: var(--ns-accent);
  border-color: var(--ns-accent);
  background: rgba(99, 102, 241, 0.06);
}

.ns-ol-filters li a.ns-active {
  color: #fff !important;
  background: var(--ns-accent) !important;
  border-color: var(--ns-accent) !important;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

/* --- Admin filter wrapper (overrides helper output) --- */
.ns-ol-filters-wrap .list-inline,
.ns-ol-filters-wrap ul.order_btn_group {
  display: flex !important;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 !important;
  padding: 0;
  list-style: none;
}

.ns-ol-filters-wrap .list-inline .list-inline-item,
.ns-ol-filters-wrap .order_btn_group .list-inline-item {
  margin: 0 !important;
  padding: 0;
}

.ns-ol-filters-wrap .list-inline .list-inline-item a.btn,
.ns-ol-filters-wrap .order_btn_group .list-inline-item a.btn {
  display: inline-flex !important;
  align-items: center;
  gap: 6px;
  padding: 6px 16px !important;
  border-radius: 9999px !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  color: var(--ns-text-secondary) !important;
  background: var(--ns-bg-tertiary) !important;
  border: 1px solid var(--ns-border-primary) !important;
  text-decoration: none !important;
  transition: all 0.2s ease;
  white-space: nowrap;
  box-shadow: none !important;
  line-height: 1.4;
}

.ns-ol-filters-wrap .list-inline .list-inline-item a.btn:hover,
.ns-ol-filters-wrap .order_btn_group .list-inline-item a.btn:hover {
  color: var(--ns-accent) !important;
  border-color: var(--ns-accent) !important;
  background: rgba(99, 102, 241, 0.06) !important;
}

.ns-ol-filters-wrap .list-inline .list-inline-item a.btn.btn-info,
.ns-ol-filters-wrap .list-inline .list-inline-item a.btn.btn-primary,
.ns-ol-filters-wrap .order_btn_group .list-inline-item a.btn.btn-info,
.ns-ol-filters-wrap .order_btn_group .list-inline-item a.btn.btn-primary {
  color: #fff !important;
  background: var(--ns-accent) !important;
  border-color: var(--ns-accent) !important;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3) !important;
}

/* Badge count inside filter buttons */
.ns-ol-filters-wrap .badge {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 9999px;
  min-width: 18px;
  line-height: 1.3;
}

.ns-ol-filters-wrap .badge.bg-red {
  background: #ef4444 !important;
  color: #fff !important;
}

/* --- Search area --- */
.ns-ol-search {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ns-ol-search .form-group {
  margin: 0;
}

.ns-ol-search .input-group {
  max-width: 480px;
}

.ns-ol-search input.form-control {
  border: 1px solid var(--ns-border-primary) !important;
  background: var(--ns-bg-tertiary) !important;
  font-size: 13px;
  padding: 8px 14px;
  min-height: 38px;
  border-radius: 10px 0 0 10px !important;
}

.ns-ol-search select.form-control {
  border: 1px solid var(--ns-border-primary) !important;
  background: var(--ns-bg-tertiary) !important;
  font-size: 13px;
  padding: 8px 10px;
  min-height: 38px;
  border-radius: 0 !important;
  border-left: none !important;
  max-width: 140px;
}

.ns-ol-search .form-control:focus {
  border-color: var(--ns-accent) !important;
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.12) !important;
  background: var(--ns-bg-primary) !important;
}

.ns-ol-search .btn {
  border: 1px solid var(--ns-border-primary) !important;
  border-left: none !important;
  background: var(--ns-bg-tertiary) !important;
  color: var(--ns-text-secondary);
  padding: 8px 14px;
  border-radius: 0 !important;
}

.ns-ol-search .btn:last-child,
.ns-ol-search .btn-clear + .btn-clear,
.ns-ol-search .input-group .btn:last-of-type {
  border-radius: 0 10px 10px 0 !important;
}

.ns-ol-search .btn-search {
  background: var(--ns-accent) !important;
  border-color: var(--ns-accent) !important;
  color: #fff;
}

.ns-ol-search .btn-search:hover {
  background: #4f46e5 !important;
  border-color: #4f46e5 !important;
}

.ns-ol-search .btn-clear {
  border-left: none !important;
  color: var(--ns-text-secondary) !important;
  background: var(--ns-bg-tertiary) !important;
}

.ns-ol-search .btn:hover:not(.btn-search) {
  background: rgba(99, 102, 241, 0.06) !important;
  color: var(--ns-accent) !important;
}

.theme-dark .ns-ol-search input.form-control,
.theme-dark .ns-ol-search select.form-control {
  background: #0d0f16 !important;
  border-color: #2d2f3a !important;
  color: #e2e8f0 !important;
}

.theme-dark .ns-ol-search .btn:not(.btn-search) {
  background: #0d0f16 !important;
  border-color: #2d2f3a !important;
  color: #94a3b8;
}

/* --- Row with filters + search --- */
.ns-ol-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

/* --- Card --- */
.ns-ol-card {
  border: none !important;
  border-radius: 16px !important;
  background: var(--ns-bg-primary) !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 6px 24px rgba(0, 0, 0, 0.06) !important;
  overflow: visible;
}

.theme-dark .ns-ol-card {
  background: #1a1c27 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 6px 24px rgba(0, 0, 0, 0.2) !important;
}

.ns-ol-card-header {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.06) 0%, rgba(139, 92, 246, 0.06) 100%) !important;
  border-bottom: 1px solid var(--ns-border-primary) !important;
  padding: 14px 20px !important;
  border-radius: 16px 16px 0 0 !important;
}

.ns-ol-card-header .card-title {
  font-size: 15px;
  font-weight: 600;
  color: #1e293b;
  margin: 0;
}

.theme-dark .ns-ol-card-header {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(139, 92, 246, 0.08) 100%) !important;
  border-bottom-color: #2d2f3a !important;
}

.theme-dark .ns-ol-card-header .card-title {
  color: #e2e8f0;
}

/* Card-header options (collapse/remove icons) */
.ns-ol-card-header .card-options {
  display: flex;
  align-items: center;
  gap: 4px;
}

.ns-ol-card-header .card-options a {
  color: var(--ns-text-secondary) !important;
  transition: color 0.15s ease;
}

.ns-ol-card-header .card-options a:hover {
  color: var(--ns-accent) !important;
}

/* --- Table --- */
.ns-ol-table {
  margin: 0 !important;
  border: none !important;
}

.ns-ol-table thead th {
  font-size: 11px !important;
  font-weight: 700 !important;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ns-text-secondary) !important;
  padding: 12px 16px !important;
  border-bottom: 1px solid var(--ns-border-primary) !important;
  border-top: none !important;
  background: transparent !important;
  white-space: nowrap;
}

.ns-ol-table tbody td,
.ns-ol-table tbody th {
  padding: 12px 16px !important;
  vertical-align: middle !important;
  border-top: 1px solid var(--ns-border-primary) !important;
  border-bottom: none !important;
  font-size: 13px;
}

.ns-ol-table tbody tr:hover {
  background: rgba(99, 102, 241, 0.03) !important;
}

.theme-dark .ns-ol-table thead th {
  color: #64748b !important;
  border-bottom-color: #2d2f3a !important;
}

.theme-dark .ns-ol-table tbody td,
.theme-dark .ns-ol-table tbody th {
  border-top-color: #2d2f3a !important;
}

.theme-dark .ns-ol-table tbody tr:hover {
  background: rgba(99, 102, 241, 0.05) !important;
}

/* --- ID cell + copy button --- */
.ns-ol-id-cell {
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.ns-ol-id-row {
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.ns-ol-id-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--ns-text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  min-width: 20px;
}

.ns-ol-copy-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 5px;
  border: 1px solid var(--ns-border-primary);
  background: var(--ns-bg-tertiary);
  color: var(--ns-text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
  font-size: 11px;
  flex-shrink: 0;
}

.ns-ol-copy-btn:hover {
  border-color: var(--ns-accent);
  color: var(--ns-accent);
  background: rgba(99, 102, 241, 0.06);
}

.ns-ol-copy-btn.copied {
  border-color: #10b981;
  color: #10b981;
  background: rgba(16, 185, 129, 0.08);
}

.theme-dark .ns-ol-copy-btn {
  border-color: #2d2f3a;
  background: #11131d;
  color: #64748b;
}

.theme-dark .ns-ol-copy-btn:hover {
  border-color: var(--ns-accent);
  color: var(--ns-accent);
  background: rgba(99, 102, 241, 0.1);
}

/* --- Order details column --- */
.ns-ol-table .title h6 {
  font-size: 13px;
  font-weight: 600;
  color: #1e293b;
  margin: 0 0 4px 0;
  line-height: 1.4;
}

.theme-dark .ns-ol-table .title h6 {
  color: #e2e8f0;
}

/* --- Order details list (no markers) --- */
.ns-ol-details-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.ns-ol-details-list li {
  font-size: 12px;
  color: var(--ns-text-secondary);
  line-height: 1.6;
  word-break: break-all;
}

.ns-ol-details-list .ns-ol-details-label {
  font-weight: 600;
  color: #475569;
}

.theme-dark .ns-ol-details-list .ns-ol-details-label {
  color: #94a3b8;
}

.ns-ol-details-list li a {
  color: var(--ns-accent);
  text-decoration: none;
}

.ns-ol-details-list li a:hover {
  text-decoration: underline;
}

/* Fallback: style any ul inside table details without markers */
.ns-ol-table .title + div ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.ns-ol-table .title + div ul li {
  font-size: 12px;
  color: var(--ns-text-secondary);
  line-height: 1.6;
  word-break: break-all;
}

.ns-ol-table .title + div ul li a {
  color: var(--ns-accent);
  text-decoration: none;
}

.ns-ol-table .title + div ul li a:hover {
  text-decoration: underline;
}

/* --- Progress circle --- */
.ns-ol-progress {
  position: relative;
  width: 46px;
  height: 46px;
  margin: 0 auto;
}

.ns-ol-progress-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 10px;
  font-weight: 600;
  color: #495057;
}

.theme-dark .ns-ol-progress-text {
  color: #94a3b8;
}

/* ===== ORDER DETAILS CARD (SaaS style) ===== */

/* Details cell layout: progress + content side by side */
.ns-od-details-cell {
  padding: 12px 16px !important;
}

.ns-od-row {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

/* Enlarged circular progress */
.ns-od-progress {
  position: relative;
  width: 50px;
  height: 50px;
  flex-shrink: 0;
}

.ns-od-progress-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 11px;
  font-weight: 700;
  color: #1e293b;
  font-family: 'Inter', sans-serif;
}

.theme-dark .ns-od-progress-text {
  color: #e2e8f0;
}

.theme-dark .ns-od-progress svg circle:first-child {
  stroke: #2d2f3a;
}

/* Content wrapper */
.ns-od-content {
  flex: 1;
  min-width: 0;
}

/* Card wrapper */
.ns-od-card {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

/* Service name — top hierarchy */
.ns-od-service {
  font-size: 13px;
  font-weight: 600;
  color: #1e293b;
  line-height: 1.4;
  font-family: 'Inter', sans-serif;
}

.theme-dark .ns-od-service {
  color: #e2e8f0;
}

/* Link row */
.ns-od-link {
  display: flex;
  align-items: center;
  gap: 5px;
  max-width: 340px;
  overflow: hidden;
  font-size: 12px;
  line-height: 1.4;
}

.ns-od-link i {
  font-size: 11px;
  color: var(--ns-text-secondary, #64748b);
  flex-shrink: 0;
}

.ns-od-link a {
  color: var(--ns-accent, #6366f1);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.ns-od-link a:hover {
  color: #4f46e5;
  text-decoration: underline;
}

.theme-dark .ns-od-link a:hover {
  color: #a5b4fc;
}

.ns-od-link span {
  color: var(--ns-text-secondary, #64748b);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Chips container */
.ns-od-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

/* Single chip */
.ns-od-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 8px;
  background: rgba(99, 102, 241, 0.06);
  font-size: 12px;
  font-family: 'Inter', sans-serif;
  transition: all 0.2s ease;
  cursor: default;
}

.ns-od-chip:hover {
  background: rgba(99, 102, 241, 0.12);
  transform: translateY(-1px);
}

.ns-od-chip-label {
  color: var(--ns-text-secondary, #64748b);
  font-weight: 500;
  white-space: nowrap;
}

.ns-od-chip-value {
  font-weight: 700;
  color: #1e293b;
  white-space: nowrap;
}

.ns-od-chip-value a {
  color: var(--ns-accent, #6366f1);
  text-decoration: none;
  font-weight: 700;
}

.ns-od-chip-value a:hover {
  text-decoration: underline;
}

/* Dark theme chips */
.theme-dark .ns-od-chip {
  background: rgba(99, 102, 241, 0.1);
}

.theme-dark .ns-od-chip:hover {
  background: rgba(99, 102, 241, 0.18);
}

.theme-dark .ns-od-chip-label {
  color: #94a3b8;
}

.theme-dark .ns-od-chip-value {
  color: #e2e8f0;
}

.theme-dark .ns-od-chip-value a {
  color: #818cf8;
}

/* Unified badge styles for order status */
.ns-ol-table .badge,
.ns-ol-mobile-card .badge {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 9999px;
  font-family: 'Inter', sans-serif;
  letter-spacing: 0.02em;
  line-height: 1.4;
}

/* Enhanced row hover */
.ns-ol-table tbody tr:hover {
  background: rgba(99, 102, 241, 0.03);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.theme-dark .ns-ol-table tbody tr:hover {
  background: rgba(99, 102, 241, 0.05);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* --- Status cell --- */
.ns-ol-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

/* --- Pagination --- */
.ns-ol-pagination .pagination {
  gap: 4px;
}

.ns-ol-pagination .page-link {
  border-radius: 8px !important;
  font-size: 13px;
  padding: 6px 12px;
  border: 1px solid var(--ns-border-primary);
  color: var(--ns-text-secondary);
  transition: all 0.2s ease;
}

.ns-ol-pagination .page-item.active .page-link {
  background: var(--ns-accent);
  border-color: var(--ns-accent);
  color: #fff;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

.ns-ol-pagination .page-link:hover {
  background: rgba(99, 102, 241, 0.06);
  border-color: var(--ns-accent);
  color: var(--ns-accent);
}

/* --- Bulk actions bar (admin) --- */
.ns-ol-bulk-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.ns-ol-bulk-bar .btn {
  border-radius: 10px !important;
  font-size: 13px !important;
  padding: 6px 16px !important;
  font-weight: 500;
}

.ns-ol-bulk-bar .dropdown-toggle {
  border-radius: 10px !important;
  font-size: 13px !important;
  font-weight: 500;
  background: var(--ns-accent) !important;
  border-color: var(--ns-accent) !important;
  color: #fff !important;
}

.ns-ol-bulk-bar .dropdown-toggle:hover {
  background: #4f46e5 !important;
  border-color: #4f46e5 !important;
}

.ns-ol-bulk-bar .dropdown-menu {
  border-radius: 10px !important;
  border: 1px solid var(--ns-border-primary) !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08) !important;
  padding: 4px !important;
  margin-top: 4px !important;
}

.ns-ol-bulk-bar .dropdown-item {
  border-radius: 6px;
  font-size: 13px;
  padding: 6px 12px;
  transition: all 0.15s ease;
}

.ns-ol-bulk-bar .dropdown-item:hover {
  background: rgba(99, 102, 241, 0.06);
  color: var(--ns-accent);
}

.theme-dark .ns-ol-bulk-bar .dropdown-toggle {
  background: var(--ns-accent) !important;
  border-color: var(--ns-accent) !important;
}

.theme-dark .ns-ol-bulk-bar .dropdown-menu {
  background: #1a1c27 !important;
  border-color: #2d2f3a !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3) !important;
}

.theme-dark .ns-ol-bulk-bar .dropdown-item:hover {
  background: rgba(99, 102, 241, 0.1);
  color: #818cf8;
}

/* --- Bulk actions row (under controls) --- */
.ns-ol-bulk-actions-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 10px;
}

/* --- Action-options dropdown (bulk actions button) --- */
.action-options {
  position: relative;
  z-index: 110;
}

.action-options .btn-outline-primary.dropdown-toggle {
  border-radius: 10px !important;
  font-size: 13px !important;
  font-weight: 600;
  padding: 8px 18px !important;
  background: linear-gradient(135deg, var(--ns-accent) 0%, #8b5cf6 100%) !important;
  border: none !important;
  color: #fff !important;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.25);
  transition: all 0.2s ease;
}

.action-options .btn-outline-primary.dropdown-toggle:hover,
.action-options .btn-outline-primary.dropdown-toggle:focus {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%) !important;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
  transform: translateY(-1px);
}

.action-options .btn-outline-primary.dropdown-toggle .fe {
  margin-left: 4px;
  font-size: 12px;
}

.action-options .dropdown-menu {
  border-radius: 12px !important;
  border: 1px solid var(--ns-border-primary) !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12) !important;
  padding: 6px !important;
  margin-top: 6px !important;
  min-width: 180px;
  z-index: 1050;
}

.action-options .dropdown-item {
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  padding: 8px 14px;
  transition: all 0.15s ease;
  color: #334155;
}

.action-options .dropdown-item:hover {
  background: rgba(99, 102, 241, 0.08);
  color: var(--ns-accent);
}

.action-options .dropdown-item .dropdown-icon {
  margin-right: 8px;
  font-size: 14px;
  width: 18px;
  text-align: center;
}

.theme-dark .action-options .dropdown-menu {
  background: #1a1c27 !important;
  border-color: #2d2f3a !important;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35) !important;
}

.theme-dark .action-options .dropdown-item {
  color: #cbd5e1;
}

.theme-dark .action-options .dropdown-item:hover {
  background: rgba(99, 102, 241, 0.12);
  color: #818cf8;
}

/* --- Admin action buttons (three-dot menu) --- */
.ns-ol-table .item-action .icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  color: var(--ns-text-secondary);
  transition: all 0.15s ease;
}

.ns-ol-table .item-action .icon:hover {
  background: rgba(99, 102, 241, 0.06);
  color: var(--ns-accent);
}

.ns-ol-table .item-action .dropdown-menu {
  border-radius: 10px !important;
  border: 1px solid var(--ns-border-primary) !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08) !important;
  padding: 4px !important;
}

.ns-ol-table .item-action .dropdown-item {
  border-radius: 6px;
  font-size: 13px;
  padding: 6px 12px;
  transition: all 0.15s ease;
}

.ns-ol-table .item-action .dropdown-item:hover {
  background: rgba(99, 102, 241, 0.06);
  color: var(--ns-accent);
}

.theme-dark .ns-ol-table .item-action .icon {
  color: #64748b;
}

.theme-dark .ns-ol-table .item-action .dropdown-menu {
  background: #1a1c27 !important;
  border-color: #2d2f3a !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3) !important;
}

.theme-dark .ns-ol-table .item-action .dropdown-item:hover {
  background: rgba(99, 102, 241, 0.1);
  color: #818cf8;
}

/* --- Admin table status badges --- */
.ns-ol-table .badge {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 9999px;
}

/* --- Admin checkbox column --- */
.ns-ol-table th.w-1 {
  width: 40px !important;
}

.ns-ol-table .custom-checkbox .custom-control-label::before {
  border-radius: 6px;
  border-color: var(--ns-border-primary);
}

.ns-ol-table .custom-checkbox .custom-control-input:checked ~ .custom-control-label::before {
  background: var(--ns-accent);
  border-color: var(--ns-accent);
}

/* --- Mobile card layout (user order list) --- */
.ns-ol-mobile-cards {
  display: none;
  padding: 12px;
  flex-direction: column;
  gap: 12px;
}

.ns-ol-mobile-card {
  background: var(--ns-bg-primary);
  border: 1px solid var(--ns-border-primary);
  border-radius: 14px;
  padding: 16px;
  transition: box-shadow 0.2s ease;
}

.ns-ol-mobile-card:hover {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.theme-dark .ns-ol-mobile-card {
  background: #1a1c27;
  border-color: #2d2f3a;
}

.theme-dark .ns-ol-mobile-card:hover {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}

.ns-ol-mobile-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.ns-ol-mobile-card-id {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  font-size: 14px;
  color: #1e293b;
}

.theme-dark .ns-ol-mobile-card-id {
  color: #e2e8f0;
}

.ns-ol-mobile-card-progress {
  flex-shrink: 0;
}

.ns-ol-mobile-card-details {
  font-size: 13px;
  color: var(--ns-text-secondary);
  line-height: 1.5;
  margin-bottom: 12px;
  word-break: break-word;
}

.ns-ol-mobile-card-details .title {
  color: #1e293b;
}

.theme-dark .ns-ol-mobile-card-details .title {
  color: #e2e8f0;
}

/* Details list inside mobile cards */
.ns-ol-mobile-card-details .ns-ol-details-list {
  margin-top: 6px;
}

.ns-ol-mobile-card-details .ns-ol-details-list li {
  font-size: 12px;
}

/* Also remove markers from any ul inside mobile card details */
.ns-ol-mobile-card-details ul {
  margin: 4px 0 0;
  padding: 0;
  list-style: none;
}

.ns-ol-mobile-card-details ul li {
  font-size: 12px;
  color: var(--ns-text-secondary);
  line-height: 1.5;
  word-break: break-all;
}

.ns-ol-mobile-card-details ul li a {
  color: var(--ns-accent);
  text-decoration: none;
}

.ns-ol-mobile-card-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 12px;
  border-top: 1px solid var(--ns-border-primary);
}

.theme-dark .ns-ol-mobile-card-bottom {
  border-top-color: #2d2f3a;
}

.ns-ol-mobile-card-date {
  font-size: 12px;
  color: var(--ns-text-secondary);
}

.ns-ol-mobile-card-status {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

/* --- Mobile responsive --- */
@media (max-width: 767px) {
  .ns-ol-mobile-cards {
    display: flex;
  }

  /* Hide table only when mobile cards exist (user layout) */
  .ns-ol-card:has(.ns-ol-mobile-cards) .ns-ol-table-wrap {
    display: none !important;
  }

  .ns-ol-header {
    overflow: hidden;
  }

  .ns-ol-controls {
    flex-direction: column;
    align-items: stretch;
    max-width: 100%;
    overflow: hidden;
  }

  .ns-ol-filters {
    flex-wrap: wrap;
    gap: 6px;
  }

  .ns-ol-filters li a {
    padding: 5px 12px;
    font-size: 12px;
  }

  .ns-ol-filters-wrap .list-inline,
  .ns-ol-filters-wrap .order_btn_group {
    flex-wrap: wrap;
    gap: 6px;
  }

  .ns-ol-filters-wrap .list-inline .list-inline-item a.btn,
  .ns-ol-filters-wrap .order_btn_group .list-inline-item a.btn {
    padding: 5px 12px !important;
    font-size: 12px !important;
  }

  .ns-ol-search {
    width: 100%;
  }

  .ns-ol-search .input-group {
    max-width: none;
    width: 100%;
  }

  .ns-ol-title {
    font-size: 18px;
  }

  .ns-ol-add-btn {
    padding: 7px 16px;
    font-size: 13px;
  }

  /* Admin bulk bar on mobile */
  .ns-ol-bulk-bar .dropdown-toggle {
    font-size: 12px !important;
    padding: 5px 12px !important;
  }

  /* Order details chips responsive */
  .ns-od-chips {
    gap: 4px;
  }

  .ns-od-chip {
    padding: 3px 8px;
    font-size: 11px;
  }

  .ns-od-link {
    max-width: 240px;
  }

  /* Mobile card: progress inside card details */
  .ns-ol-mobile-card-details .ns-od-card {
    gap: 4px;
  }

  .ns-ol-mobile-card-details .ns-od-service {
    font-size: 12px;
  }

  .ns-ol-mobile-card-details .ns-od-link {
    max-width: 100%;
    font-size: 11px;
  }
}

/* ============================================================
   Neuro Font Family — Inter for all neuro elements
   ============================================================ */

.ns-ol-header,
.ns-ol-card,
.ns-ol-table,
.ns-ol-mobile-cards,
.ns-order-card,
.ns-od-card {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.ns-ol-title {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 800 !important;
  letter-spacing: -0.02em;
}

.ns-ol-card-header .card-title {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700 !important;
  font-size: 15px !important;
  letter-spacing: -0.01em;
}

.ns-ol-table tbody td {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.ns-ol-table tbody td .title {
  font-weight: 500;
  font-size: 13px;
  line-height: 1.5;
  color: #1e293b;
}

.theme-dark .ns-ol-table tbody td .title {
  color: #e2e8f0;
}

/* ============================================================
   SERVICES PAGE — Neuro Design
   ============================================================ */

/* Badge legend pills */
.ns-sv-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.ns-sv-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 14px;
  border-radius: 9999px;
  background: var(--ns-bg-tertiary);
  border: 1px solid var(--ns-border-primary);
  font-size: 12px;
  font-weight: 500;
  color: var(--ns-text-secondary);
  white-space: nowrap;
  transition: all 0.2s ease;
}

.ns-sv-badge:hover {
  border-color: var(--ns-accent);
  color: var(--ns-accent);
  background: rgba(99, 102, 241, 0.06);
}

/* Platform heading in services list */
.ns-sv-platform-heading {
  font-size: 18px;
  font-weight: 700;
  color: var(--ns-accent, #6366f1);
  margin: 20px 0 10px;
  padding: 10px 15px;
  border-left: 4px solid var(--ns-accent, #6366f1);
  background: rgba(99, 102, 241, 0.05);
  border-radius: 0 8px 8px 0;
}
.ns-sv-platform-heading i {
  margin-right: 8px;
}

/* Category filter select */
.ns-sv-category-filter {
  min-width: 220px;
  flex-shrink: 0;
}

.ns-sv-category-select {
  border: 1px solid var(--ns-border-primary) !important;
  background: var(--ns-bg-tertiary) !important;
  border-radius: 10px !important;
  min-height: 38px !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  color: var(--ns-text-secondary) !important;
  padding: 6px 14px !important;
  transition: all 0.2s ease !important;
  cursor: pointer;
  appearance: auto;
}

.ns-sv-category-select:focus {
  border-color: var(--ns-accent) !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12) !important;
  background: var(--ns-bg-primary) !important;
  color: #1e293b !important;
}

/* Price highlight */
.ns-sv-price {
  font-weight: 700;
  color: var(--ns-accent);
  font-size: 13px;
  white-space: nowrap;
}

/* Per 1000 label */
.ns-sv-per1k {
  font-size: 11px;
  font-weight: 400;
  color: var(--ns-text-secondary);
  opacity: 0.7;
  margin-left: 1px;
}

/* Min/Max text */
.ns-sv-minmax {
  font-size: 12px;
  font-weight: 500;
  color: var(--ns-text-secondary);
  white-space: nowrap;
}

.ns-sv-minmax-label {
  font-size: 11px;
  color: var(--ns-text-secondary);
  opacity: 0.7;
  margin-right: 4px;
}

/* Mobile cards for services */
.ns-sv-mobile-cards {
  display: none;
  padding: 12px;
  flex-direction: column;
  gap: 10px;
}

.ns-sv-mobile-card {
  background: var(--ns-bg-primary);
  border: 1px solid var(--ns-border-primary);
  border-radius: 14px;
  padding: 14px 16px;
  transition: all 0.2s ease;
}

.ns-sv-mobile-card:hover {
  border-color: rgba(99, 102, 241, 0.3);
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.08);
}

.ns-sv-mobile-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 8px;
}

.ns-sv-mobile-card-price-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.ns-sv-mobile-card-minmax-inline {
  font-size: 11px;
  font-weight: 500;
  color: var(--ns-text-secondary);
  opacity: 0.7;
}

.ns-sv-mobile-card-id {
  font-weight: 700;
  font-size: 13px;
  color: var(--ns-accent);
  background: rgba(99, 102, 241, 0.08);
  padding: 2px 10px;
  border-radius: 8px;
}

.ns-sv-mobile-card-name {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #1e293b;
  line-height: 1.5;
  margin-bottom: 10px;
  word-break: break-word;
}

.ns-sv-mobile-card-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 10px;
  border-top: 1px solid var(--ns-border-primary);
  gap: 8px;
  flex-wrap: wrap;
}

.ns-sv-mobile-card-minmax {
  display: flex;
  align-items: center;
  gap: 4px;
}

.ns-sv-mobile-card-desc .btn {
  padding: 4px 12px;
  font-size: 12px;
  border-radius: 8px;
}

/* Dark theme support for services */
.theme-dark .ns-sv-badge {
  background: rgba(255, 255, 255, 0.06);
  border-color: #2d2f3a;
  color: #94a3b8;
}

.theme-dark .ns-sv-badge:hover {
  background: rgba(99, 102, 241, 0.12);
  border-color: #818cf8;
  color: #818cf8;
}

.theme-dark .ns-sv-category-select {
  background: #1a1c27 !important;
  border-color: #2d2f3a !important;
  color: #94a3b8 !important;
}

.theme-dark .ns-sv-category-select:focus {
  background: #0d0f16 !important;
  border-color: #818cf8 !important;
  color: #e2e8f0 !important;
}

.theme-dark .ns-sv-price {
  color: #818cf8;
}

.theme-dark .ns-sv-mobile-card {
  background: #1a1c27;
  border-color: #2d2f3a;
}

.theme-dark .ns-sv-mobile-card:hover {
  border-color: rgba(129, 140, 248, 0.3);
}

.theme-dark .ns-sv-mobile-card-id {
  background: rgba(129, 140, 248, 0.12);
  color: #818cf8;
}

.theme-dark .ns-sv-mobile-card-name {
  color: #e2e8f0;
}

.theme-dark .ns-sv-mobile-card-bottom {
  border-top-color: #2d2f3a;
}

/* Services description & modal neuro style */
.ns-ol-card .btn-primary,
.ns-sv-mobile-card .btn-primary {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%) !important;
  border: none !important;
  border-radius: 8px !important;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  padding: 5px 14px !important;
  box-shadow: 0 2px 6px rgba(99, 102, 241, 0.2) !important;
  transition: all 0.2s ease !important;
}

.ns-ol-card .btn-primary:hover,
.ns-sv-mobile-card .btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3) !important;
}

/* Modal neuro font */
.modal-content {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.modal-content .modal-header {
  border-bottom: 1px solid var(--ns-border-primary);
}

.modal-content .modal-title {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-weight: 700;
  font-size: 15px;
}

.modal-content .modal-body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 13px;
  font-weight: 400;
  line-height: 1.6;
  color: #475569;
  max-height: calc(100vh - 200px);
  overflow-y: auto;
}

.theme-dark .modal-content .modal-body {
  color: #cbd5e1;
}

/* Services table description text (inline) */
.ns-ol-table tbody td:last-child {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 12px;
  line-height: 1.5;
  color: #64748b;
}

.ns-sv-mobile-card-desc {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 12px;
  line-height: 1.5;
  color: #64748b;
}

/* Responsive: mobile cards for services */
@media (max-width: 767px) {
  .ns-sv-mobile-cards {
    display: flex;
  }

  .ns-ol-card:has(.ns-sv-mobile-cards) .ns-ol-table-wrap {
    display: none !important;
  }

  .ns-sv-badges {
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .ns-sv-badges::-webkit-scrollbar {
    display: none;
  }

  .ns-sv-category-filter {
    min-width: 100%;
  }

  .ns-ol-controls:has(.ns-sv-badges) {
    flex-direction: column;
    gap: 10px;
    align-items: stretch;
  }
}

@media (max-width: 480px) {
  .ns-sv-mobile-card {
    padding: 12px 14px;
  }

  .ns-sv-mobile-card-name {
    font-size: 12px;
  }

  .ns-sv-mobile-card-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
}

/* ===== MOBILE ORDER FORM ===== */

/* Mobile summary — hidden on desktop */
.ns-order-mobile-summary {
  display: none;
}

/* Mobile sticky bar — hidden on desktop */
.ns-order-sticky-bar {
  display: none;
}


/* Quantity min/max limits hint */
.ns-order-qty-limits {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  font-size: 12px;
  color: var(--ns-text-secondary, #64748b);
}

.ns-order-qty-limit {
  font-weight: 500;
}

.ns-order-qty-sep {
  opacity: 0.4;
  font-size: 10px;
}

/* Mobile-only styles */
@media (max-width: 767.98px) {

  /* Hide desktop order resume column */
  .order_resume#order_resume {
    display: none !important;
  }

  /* Mobile summary block */
  .ns-order-mobile-summary {
    display: block;
    background: var(--ns-bg-tertiary, #f1f5f9);
    border: 1px solid var(--ns-border-primary, #e2e8f0);
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 16px;
  }

  .ns-order-mobile-summary-name {
    font-weight: 600;
    font-size: 14px;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 8px;
  }

  .theme-dark .ns-order-mobile-summary-name {
    color: #e2e8f0;
  }

  .ns-order-mobile-summary-placeholder {
    color: var(--ns-text-secondary, #64748b);
    font-weight: 400;
  }

  .ns-order-mobile-summary-name-text {
    color: inherit;
  }

  .ns-order-mobile-summary-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
  }

  .ns-order-chip {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    background: rgba(99, 102, 241, 0.1);
    color: #6366f1;
    white-space: nowrap;
  }

  .theme-dark .ns-order-chip {
    background: rgba(129, 140, 248, 0.15);
    color: #a5b4fc;
  }

  .ns-order-chip--price {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
  }

  .theme-dark .ns-order-chip--price {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
  }

  /* Mobile description */
  .ns-order-mobile-desc {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--ns-border-primary, #e2e8f0);
  }

  .ns-order-mobile-desc-body {
    font-size: 13px;
    line-height: 1.5;
    color: var(--ns-text-secondary, #64748b);
    max-height: 120px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Sticky checkout bar — sits above bottom nav */
  .ns-order-sticky-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: fixed;
    bottom: 58px; /* above .bottom-nav-footer-panel */
    left: 0;
    right: 0;
    z-index: 99; /* below bottom-nav z-index:100 */
    padding: 10px 16px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid var(--ns-border-primary, #e2e8f0);
    box-shadow: 0 -2px 16px rgba(0, 0, 0, 0.06);
  }

  .theme-dark .ns-order-sticky-bar {
    background: rgba(13, 15, 22, 0.95);
    box-shadow: 0 -2px 16px rgba(0, 0, 0, 0.3);
  }

  .ns-order-sticky-total {
    display: flex;
    flex-direction: column;
  }

  .ns-order-sticky-label {
    font-size: 11px;
    color: var(--ns-text-secondary, #64748b);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
  }

  .ns-order-sticky-price {
    font-size: 18px;
    font-weight: 700;
    color: #1e293b;
  }

  .theme-dark .ns-order-sticky-price {
    color: #e2e8f0;
  }

  .ns-order-sticky-btn {
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
    transition: transform 0.15s, box-shadow 0.15s;
    white-space: nowrap;
  }

  .ns-order-sticky-btn:active {
    transform: scale(0.97);
  }

  /* Compact form spacing on mobile */
  #new_order .form-group {
    margin-bottom: 12px;
  }

  #new_order .content-header-title {
    margin-bottom: 12px;
  }

  /* Add bottom padding for sticky bar + bottom nav */
  .ns-order-card .card-body {
    padding-bottom: 130px;
  }
}

/* Desktop: keep info section expanded */
@media (min-width: 768px) {
  .ns-order-mobile-summary {
    display: none !important;
  }

  .ns-order-sticky-bar {
    display: none !important;
  }
}

/* Hide ID column only in services table (has .serv_id_none in tbody) */
.ns-ol-card .ns-ol-table .serv_id_none,
.ns-ol-card .ns-ol-table:has(.serv_id_none) thead th:first-child {
  display: none;
}

/* General page (public) context adjustments */
.page .ns-ol-header {
  margin-bottom: 20px;
}

.page .ns-ol-card {
  margin-bottom: 20px;
}

/* Admin dropdown overflow fix — prevent card/table-responsive from clipping dropdown menus */
.app-content .ns-ol-card {
  overflow: visible;
}
.app-content .ns-ol-card .ns-ol-card-header {
  border-radius: 16px 16px 0 0;
}
@media (min-width: 768px) {
  .app-content .ns-ol-card .ns-ol-table-wrap,
  .app-content .ns-ol-card .table-responsive {
    overflow: visible;
  }
}
@media (max-width: 767px) {
  .app-content .ns-ol-card .ns-ol-table-wrap,
  .app-content .ns-ol-card .table-responsive {
    overflow-x: auto;
  }
}

/* Admin layout — prevent sticky header from overlapping page content */
.vertical-menu .layout-main .app-content {
  padding-top: calc(var(--ns-header-height, 64px) - 4px);
}
