  :root {
      --primary: #3b82f6;
      --primary-light: #60a5fa;
      --cyan: #06b6d4;
      --purple: #8b5cf6;
      --purple-light: #a78bfa;
      --emerald: #10b981;
      --emerald-light: #34d399;
      --rose: #f43f5e;
      --rose-light: #fb7185;
      --amber: #f59e0b;
      --amber-light: #fbbf24;
      --font-jakarta: 'Plus Jakarta Sans', sans-serif;
      --sidebar-width: 272px;
      --sidebar-collapsed: 80px;
      --navbar-height: 68px;
      --transition-fast: 0.15s ease;
      --transition-normal: 0.3s ease;
      --safe-top: env(safe-area-inset-top, 0)
  }

  [data-theme="dark"] {
      --bg-primary: #0a0e1a;
      --bg-secondary: #111827;
      --bg-tertiary: #1f2937;
      --bg-card: rgba(17, 24, 39, 0.85);
      --bg-card-hover: rgba(31, 41, 55, 0.85);
      --bg-card-solid: #111827;
      --text-primary: #f1f5f9;
      --text-secondary: #94a3b8;
      --text-muted: #64748b;
      --border-color: rgba(148, 163, 184, 0.08);
      --border-hover: rgba(148, 163, 184, 0.2);
      --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.3);
      --gradient-primary: linear-gradient(135deg, #3b82f6, #06b6d4);
      --gradient-success: linear-gradient(135deg, #10b981, #06b6d4);
      --gradient-danger: linear-gradient(135deg, #f43f5e, #f59e0b);
      --gradient-purple: linear-gradient(135deg, #8b5cf6, #ec4899);
      --gradient-settings: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #06b6d4 100%)
  }

  [data-theme="light"] {
      --bg-primary: #f1f5f9;
      --bg-secondary: #ffffff;
      --bg-tertiary: #f8fafc;
      --bg-card: rgba(255, 255, 255, 0.92);
      --bg-card-hover: rgba(241, 245, 249, 0.92);
      --bg-card-solid: #ffffff;
      --text-primary: #0f172a;
      --text-secondary: #475569;
      --text-muted: #94a3b8;
      --border-color: rgba(148, 163, 184, 0.18);
      --border-hover: rgba(148, 163, 184, 0.35);
      --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.06);
      --gradient-primary: linear-gradient(135deg, #3b82f6, #06b6d4);
      --gradient-success: linear-gradient(135deg, #10b981, #06b6d4);
      --gradient-danger: linear-gradient(135deg, #f43f5e, #f59e0b);
      --gradient-purple: linear-gradient(135deg, #8b5cf6, #ec4899);
      --gradient-settings: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #06b6d4 100%)
  }

  *,
  *::before,
  *::after {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
      -webkit-tap-highlight-color: transparent
  }

  html {
      scroll-behavior: smooth;
      -webkit-text-size-adjust: 100%
  }

  body {
      font-family: var(--font-jakarta);
      background: var(--bg-primary);
      color: var(--text-primary);
      line-height: 1.6;
      overflow-x: hidden;
      min-height: 100vh;
      min-height: 100dvh;
      transition: background 0.3s, color 0.3s;
      -webkit-font-smoothing: antialiased
  }

  body.no-scroll {
      overflow: hidden;
      position: fixed;
      width: 100%
  }

  ::selection {
      background: rgba(59, 130, 246, 0.3)
  }

  ::-webkit-scrollbar {
      width: 6px;
      height: 6px
  }

  ::-webkit-scrollbar-track {
      background: transparent
  }

  ::-webkit-scrollbar-thumb {
      background: var(--text-muted);
      border-radius: 3px
  }

  a {
      text-decoration: none;
      color: inherit
  }

  ul,
  ol {
      list-style: none
  }

  img {
      max-width: 100%;
      display: block
  }

  button {
      cursor: pointer;
      font-family: inherit;
      border: none;
      background: none
  }

  input,
  select,
  textarea {
      font-family: inherit
  }

  .app-layout {
      display: flex;
      min-height: 100vh;
      min-height: 100dvh
  }

  .main-content {
      flex: 1;
      margin-left: var(--sidebar-width);
      min-height: 100vh;
      min-height: 100dvh;
      transition: margin-left var(--transition-normal);
      min-width: 0;
      width: 100%
  }

  .main-content.collapsed {
      margin-left: var(--sidebar-collapsed)
  }

  .page-content {
      padding: 24px;
      padding-top: calc(var(--navbar-height)+24px);
      display: flex;
      flex-direction: column;
      gap: 24px;
      max-width: 100%;
      overflow-x: hidden
  }

  /* Sidebar - same as all pages */
  .sidebar {
      position: fixed;
      top: 0;
      left: 0;
      width: var(--sidebar-width);
      height: 100vh;
      height: 100dvh;
      background: var(--bg-card-solid);
      border-right: 1px solid var(--border-color);
      z-index: 50;
      transition: width var(--transition-normal), transform var(--transition-normal);
      display: flex;
      flex-direction: column;
      overflow: hidden
  }

  .sidebar.collapsed {
      width: var(--sidebar-collapsed)
  }

  .sidebar-header {
      padding: 16px 20px;
      display: flex;
      align-items: center;
      gap: 12px;
      border-bottom: 1px solid var(--border-color);
      height: var(--navbar-height);
      flex-shrink: 0
  }

  .sidebar-logo {
      width: 40px;
      height: 40px;
      border-radius: 12px;
      background: var(--gradient-primary);
      display: flex;
      align-items: center;
      justify-content: center;
      flex-shrink: 0;
      position: relative;
      overflow: hidden
  }

  .sidebar-logo::after {
      content: '';
      position: absolute;
      inset: 0;
      background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.2) 50%, transparent 70%);
      animation: shimmer 3s ease infinite;
      background-size: 200% 100%
  }

  @keyframes shimmer {
      0% {
          background-position: 200% 0
      }

      100% {
          background-position: -200% 0
      }
  }

  .sidebar-brand {
      display: flex;
      flex-direction: column;
      overflow: hidden;
      white-space: nowrap;
      transition: opacity var(--transition-normal), width var(--transition-normal);
      min-width: 0
  }

  .sidebar.collapsed .sidebar-brand {
      opacity: 0;
      width: 0;
      pointer-events: none
  }

  .sidebar-brand h1 {
      font-size: 18px;
      font-weight: 800;
      background: var(--gradient-primary);
      -webkit-background-clip: text;
      -webkit-text-fill-color: transparent;
      background-clip: text;
      line-height: 1.2
  }

  .sidebar-brand span {
      font-size: 11px;
      color: var(--text-muted);
      font-weight: 500
  }

  .sidebar-nav {
      flex: 1;
      padding: 16px 12px;
      overflow-y: auto;
      overflow-x: hidden;
      -webkit-overflow-scrolling: touch
  }

  .nav-section {
      margin-bottom: 24px
  }

  .nav-section-title {
      font-size: 11px;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 1.2px;
      color: var(--text-muted);
      padding: 0 12px;
      margin-bottom: 8px;
      white-space: nowrap;
      overflow: hidden;
      transition: opacity var(--transition-normal)
  }

  .sidebar.collapsed .nav-section-title {
      opacity: 0;
      height: 0;
      margin: 0
  }

  .nav-link {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 11px 12px;
      border-radius: 10px;
      color: var(--text-secondary);
      font-size: 14px;
      font-weight: 500;
      transition: all var(--transition-fast);
      white-space: nowrap;
      margin-bottom: 2px;
      width: 100%;
      text-align: left;
      min-height: 44px
  }

  .nav-link:hover {
      background: var(--bg-card-hover);
      color: var(--text-primary)
  }

  .nav-link.active {
      background: var(--gradient-primary);
      color: #fff;
      box-shadow: 0 4px 15px rgba(59, 130, 246, 0.35)
  }

  .nav-link i,
  .nav-link svg {
      width: 20px;
      height: 20px;
      flex-shrink: 0
  }

  .nav-link .nav-text {
      overflow: hidden;
      transition: opacity var(--transition-normal), width var(--transition-normal)
  }

  .sidebar.collapsed .nav-link .nav-text,
  .sidebar.collapsed .nav-link .nav-badge {
      opacity: 0;
      width: 0;
      overflow: hidden
  }

  .nav-badge {
      margin-left: auto;
      font-size: 10px;
      font-weight: 700;
      padding: 2px 8px;
      border-radius: 6px;
      color: #fff;
      flex-shrink: 0
  }

  .nav-badge.red {
      background: var(--rose)
  }

  .nav-badge.green {
      background: var(--emerald)
  }

  .nav-badge.blue {
      background: var(--primary)
  }

  .nav-badge.purple {
      background: var(--purple)
  }

  .sidebar-footer {
      padding: 12px;
      border-top: 1px solid var(--border-color);
      flex-shrink: 0
  }

  .sidebar-user {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 10px;
      border-radius: 12px;
      background: var(--bg-card-hover);
      cursor: pointer;
      transition: all var(--transition-fast);
      width: 100%;
      text-align: left
  }

  .sidebar-user:hover {
      background: var(--gradient-primary)
  }

  .sidebar-user:hover .u-name,
  .sidebar-user:hover .u-role {
      color: #fff
  }

  .sidebar-user-avatar {
      width: 38px;
      height: 38px;
      border-radius: 10px;
      overflow: hidden;
      flex-shrink: 0;
      border: 2px solid var(--border-color)
  }

  .sidebar-user-avatar img {
      width: 100%;
      height: 100%;
      object-fit: cover
  }

  .sidebar-user-info {
      overflow: hidden;
      transition: opacity var(--transition-normal);
      min-width: 0
  }

  .sidebar.collapsed .sidebar-user-info {
      opacity: 0;
      width: 0
  }

  .u-name {
      font-size: 13px;
      font-weight: 600;
      color: var(--text-primary);
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis
  }

  .u-role {
      font-size: 11px;
      color: var(--text-muted);
      white-space: nowrap
  }

  .sidebar-overlay {
      display: none;
      position: fixed;
      inset: 0;
      background: rgba(0, 0, 0, 0.6);
      backdrop-filter: blur(4px);
      z-index: 45;
      opacity: 0;
      transition: opacity var(--transition-normal)
  }

  .sidebar-overlay.active {
      display: block;
      opacity: 1
  }

  /* Navbar */
  .navbar {
      position: fixed;
      top: 0;
      right: 0;
      left: var(--sidebar-width);
      height: var(--navbar-height);
      background: var(--bg-card-solid);
      border-bottom: 1px solid var(--border-color);
      z-index: 40;
      display: flex;
      align-items: center;
      padding: 0 24px;
      gap: 12px;
      transition: left var(--transition-normal)
  }

  .navbar.collapsed {
      left: var(--sidebar-collapsed)
  }

  .navbar-left {
      display: flex;
      align-items: center;
      gap: 10px;
      min-width: 0;
      flex: 1
  }

  .navbar-right {
      display: flex;
      align-items: center;
      gap: 8px;
      flex-shrink: 0
  }

  .nav-icon-btn {
      width: 40px;
      height: 40px;
      min-width: 40px;
      border-radius: 10px;
      border: 1px solid var(--border-color);
      background: transparent;
      color: var(--text-secondary);
      display: flex;
      align-items: center;
      justify-content: center;
      transition: all var(--transition-fast);
      position: relative;
      flex-shrink: 0;
      cursor: pointer
  }

  .nav-icon-btn:hover {
      background: var(--bg-card-hover);
      color: var(--text-primary);
      border-color: var(--border-hover)
  }

  .mobile-toggle {
      display: none
  }

  .theme-toggle {
      width: 40px;
      height: 40px;
      min-width: 40px;
      border-radius: 10px;
      border: 1px solid var(--border-color);
      background: transparent;
      color: var(--text-secondary);
      display: flex;
      align-items: center;
      justify-content: center;
      transition: all var(--transition-fast);
      flex-shrink: 0;
      cursor: pointer
  }

  .theme-toggle:hover {
      background: var(--bg-card-hover);
      color: var(--amber);
      border-color: var(--border-hover)
  }

  [data-theme="dark"] .icon-sun {
      display: block
  }

  [data-theme="dark"] .icon-moon {
      display: none
  }

  [data-theme="light"] .icon-sun {
      display: none
  }

  [data-theme="light"] .icon-moon {
      display: block
  }

  .navbar-profile {
      display: flex;
      align-items: center;
      gap: 10px;
      padding: 5px 12px 5px 5px;
      border-radius: 12px;
      border: 1px solid var(--border-color);
      background: transparent;
      cursor: pointer;
      transition: all var(--transition-fast);
      flex-shrink: 0
  }

  .navbar-profile:hover {
      background: var(--bg-card-hover);
      border-color: var(--border-hover)
  }

  .navbar-profile-avatar {
      width: 36px;
      height: 36px;
      border-radius: 8px;
      overflow: hidden;
      border: 2px solid var(--primary);
      flex-shrink: 0
  }

  .navbar-profile-avatar img {
      width: 100%;
      height: 100%;
      object-fit: cover
  }

  .np-info-text {
      text-align: left;
      min-width: 0
  }

  .np-name {
      font-size: 13px;
      font-weight: 600;
      color: var(--text-primary);
      line-height: 1.2;
      white-space: nowrap
  }

  .np-role {
      font-size: 11px;
      color: var(--text-muted);
      white-space: nowrap
  }

  /* Dropdown */
  .dropdown {
      position: relative
  }

  .dropdown-menu {
      position: absolute;
      top: calc(100%+8px);
      right: 0;
      min-width: 240px;
      background: var(--bg-card-solid);
      border: 1px solid var(--border-color);
      border-radius: 14px;
      box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
      opacity: 0;
      visibility: hidden;
      transform: translateY(-10px) scale(0.95);
      transition: all var(--transition-normal);
      z-index: 200;
      overflow: hidden
  }

  .dropdown-menu.show {
      opacity: 1;
      visibility: visible;
      transform: translateY(0) scale(1)
  }

  .dd-header {
      padding: 16px;
      border-bottom: 1px solid var(--border-color);
      display: flex;
      align-items: center;
      justify-content: space-between
  }

  .dd-body {
      padding: 8px;
      max-height: 340px;
      overflow-y: auto
  }

  .dd-item {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 10px 12px;
      border-radius: 10px;
      color: var(--text-secondary);
      font-size: 14px;
      cursor: pointer;
      transition: all var(--transition-fast);
      min-height: 44px
  }

  .dd-item:hover {
      background: var(--bg-card-hover);
      color: var(--text-primary)
  }

  /* Core Components */
  .card {
      background: var(--bg-card);
      backdrop-filter: blur(20px);
      -webkit-backdrop-filter: blur(20px);
      border: 1px solid var(--border-color);
      border-radius: 16px;
      transition: all var(--transition-normal);
      min-width: 0
  }

  .card:hover {
      border-color: var(--border-hover);
      box-shadow: var(--shadow-card)
  }

  .card-pad {
      padding: 24px
  }

  .card-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      margin-bottom: 20px;
      flex-wrap: wrap;
      gap: 12px
  }

  .card-header>div:first-child {
      min-width: 0;
      flex: 1
  }

  .card-title {
      font-size: 16px;
      font-weight: 700;
      color: var(--text-primary)
  }

  .card-subtitle {
      font-size: 13px;
      color: var(--text-muted);
      margin-top: 2px
  }

  .page-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      flex-wrap: wrap;
      gap: 16px
  }

  .page-header-left {
      min-width: 0;
      flex: 1
  }

  .page-title-wrap {
      display: flex;
      align-items: center;
      gap: 8px;
      margin-bottom: 6px;
      flex-wrap: wrap
  }

  .page-title {
      font-size: 26px;
      font-weight: 800;
      color: var(--text-primary);
      line-height: 1.2
  }

  .page-desc {
      font-size: 14px;
      color: var(--text-muted)
  }

  .breadcrumb {
      display: flex;
      align-items: center;
      gap: 8px;
      font-size: 12px;
      color: var(--text-muted);
      margin-bottom: 4px
  }

  .breadcrumb a {
      color: var(--text-muted);
      transition: color 0.2s
  }

  .breadcrumb a:hover {
      color: var(--primary)
  }

  .breadcrumb i {
      width: 12px;
      height: 12px
  }

  .page-header-actions {
      display: flex;
      gap: 10px;
      flex-wrap: wrap;
      flex-shrink: 0
  }

  .btn {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 8px;
      padding: 10px 20px;
      border-radius: 10px;
      font-size: 14px;
      font-weight: 600;
      font-family: var(--font-jakarta);
      transition: all var(--transition-fast);
      outline: none;
      overflow: hidden;
      white-space: nowrap;
      min-height: 44px;
      cursor: pointer;
      border: none
  }

  .btn-primary {
      background: var(--gradient-primary);
      color: #fff;
      box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3)
  }

  .btn-primary:hover {
      box-shadow: 0 6px 20px rgba(59, 130, 246, 0.5);
      transform: translateY(-2px)
  }

  .btn-outline {
      background: transparent;
      border: 1px solid var(--border-color);
      color: var(--text-primary)
  }

  .btn-outline:hover {
      background: var(--bg-card-hover);
      border-color: var(--border-hover)
  }

  .btn-danger {
      background: var(--gradient-danger);
      color: #fff
  }

  .btn-sm {
      padding: 6px 12px;
      font-size: 12px;
      border-radius: 8px;
      min-height: 32px
  }

  .badge {
      display: inline-flex;
      align-items: center;
      gap: 4px;
      padding: 4px 10px;
      border-radius: 6px;
      font-size: 12px;
      font-weight: 600;
      white-space: nowrap
  }

  .badge-primary {
      background: rgba(59, 130, 246, 0.15);
      color: var(--primary-light)
  }

  .badge-success {
      background: rgba(16, 185, 129, 0.15);
      color: var(--emerald-light)
  }

  .badge-danger {
      background: rgba(244, 63, 94, 0.15);
      color: var(--rose-light)
  }

  .badge-purple {
      background: rgba(139, 92, 246, 0.15);
      color: var(--purple-light)
  }

  .flex-between {
      display: flex;
      align-items: center;
      justify-content: space-between
  }

  /* TABS */
  .tabs-nav {
      display: flex;
      gap: 4px;
      border-bottom: 1px solid var(--border-color);
      overflow-x: auto;
      scrollbar-width: none;
      margin-bottom: 20px;
      -webkit-overflow-scrolling: touch
  }

  .tabs-nav::-webkit-scrollbar {
      display: none
  }

  .tab-btn {
      padding: 12px 18px;
      font-size: 14px;
      font-weight: 600;
      color: var(--text-muted);
      background: transparent;
      border: none;
      border-bottom: 2px solid transparent;
      cursor: pointer;
      transition: all var(--transition-fast);
      white-space: nowrap;
      display: flex;
      align-items: center;
      gap: 8px;
      margin-bottom: -1px;
      font-family: var(--font-jakarta)
  }

  .tab-btn * {
      pointer-events: none
  }

  .tab-btn i {
      width: 16px;
      height: 16px
  }

  .tab-btn:hover {
      color: var(--text-primary)
  }

  .tab-btn.active {
      color: var(--primary);
      border-bottom-color: var(--primary)
  }

  .tab-content {
      display: none
  }

  .tab-content.active {
      display: block;
      animation: fadeSlide 0.3s ease
  }

  @keyframes fadeSlide {
      from {
          opacity: 0;
          transform: translateY(8px)
      }

      to {
          opacity: 1;
          transform: translateY(0)
      }
  }

  /* Settings Hero */
  .settings-hero {
      background: var(--gradient-settings);
      border-radius: 24px;
      padding: 32px;
      position: relative;
      overflow: hidden;
      color: #fff
  }

  .settings-hero::before {
      content: '';
      position: absolute;
      top: -50%;
      right: -20%;
      width: 60%;
      height: 200%;
      background: radial-gradient(circle, rgba(255, 255, 255, 0.15) 0%, transparent 70%);
      pointer-events: none
  }

  .sh-inner {
      position: relative;
      z-index: 1;
      display: flex;
      align-items: center;
      gap: 24px;
      flex-wrap: wrap
  }

  .sh-avatar {
      width: 80px;
      height: 80px;
      border-radius: 20px;
      overflow: hidden;
      border: 3px solid rgba(255, 255, 255, 0.4);
      flex-shrink: 0;
      box-shadow: 0 0 30px rgba(255, 255, 255, 0.2)
  }

  .sh-avatar img {
      width: 100%;
      height: 100%;
      object-fit: cover
  }

  .sh-info {
      flex: 1;
      min-width: 200px
  }

  .sh-name {
      font-size: 24px;
      font-weight: 800;
      margin-bottom: 4px
  }

  .sh-email {
      font-size: 14px;
      opacity: 0.9;
      margin-bottom: 12px
  }

  .sh-badges {
      display: flex;
      gap: 8px;
      flex-wrap: wrap
  }

  .sh-badge {
      display: inline-flex;
      align-items: center;
      gap: 5px;
      padding: 5px 12px;
      background: rgba(255, 255, 255, 0.2);
      border: 1px solid rgba(255, 255, 255, 0.3);
      border-radius: 100px;
      font-size: 11px;
      font-weight: 700
  }

  .sh-badge i {
      width: 12px;
      height: 12px
  }

  .sh-actions {
      display: flex;
      gap: 10px;
      flex-wrap: wrap;
      flex-shrink: 0
  }

  .btn-glass {
      background: rgba(255, 255, 255, 0.2);
      color: #fff;
      backdrop-filter: blur(10px);
      border: 1px solid rgba(255, 255, 255, 0.3)
  }

  .btn-glass:hover {
      background: rgba(255, 255, 255, 0.3)
  }

  /* Settings Groups */
  .settings-group {
      padding: 24px;
      border-radius: 16px;
      background: var(--bg-card);
      border: 1px solid var(--border-color);
      margin-bottom: 20px;
      transition: all var(--transition-normal)
  }

  .settings-group:hover {
      border-color: var(--border-hover)
  }

  .settings-group-header {
      display: flex;
      align-items: center;
      gap: 14px;
      margin-bottom: 20px;
      padding-bottom: 16px;
      border-bottom: 1px solid var(--border-color)
  }

  .settings-group-icon {
      width: 44px;
      height: 44px;
      border-radius: 12px;
      display: flex;
      align-items: center;
      justify-content: center;
      flex-shrink: 0
  }

  .settings-group-icon i {
      width: 22px;
      height: 22px
  }

  .settings-group-info {
      flex: 1;
      min-width: 0
  }

  .settings-group-title {
      font-size: 16px;
      font-weight: 700;
      color: var(--text-primary);
      margin-bottom: 2px
  }

  .settings-group-desc {
      font-size: 13px;
      color: var(--text-muted)
  }

  .settings-item {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 14px 0;
      gap: 14px
  }

  .settings-item+.settings-item {
      border-top: 1px solid var(--border-color)
  }

  .settings-item-info {
      flex: 1;
      min-width: 0
  }

  .settings-item-name {
      font-size: 14px;
      font-weight: 600;
      color: var(--text-primary);
      margin-bottom: 3px
  }

  .settings-item-desc {
      font-size: 12px;
      color: var(--text-muted);
      line-height: 1.4
  }

  /* Toggle */
  .toggle-switch {
      width: 44px;
      height: 24px;
      background: var(--bg-card-solid);
      border-radius: 12px;
      border: 1px solid var(--border-color);
      cursor: pointer;
      position: relative;
      transition: all var(--transition-fast);
      flex-shrink: 0
  }

  .toggle-switch.on {
      background: var(--gradient-primary);
      border-color: transparent
  }

  .toggle-switch::after {
      content: '';
      position: absolute;
      top: 2px;
      left: 2px;
      width: 18px;
      height: 18px;
      border-radius: 50%;
      background: var(--text-muted);
      transition: all var(--transition-fast)
  }

  .toggle-switch.on::after {
      transform: translateX(20px);
      background: #fff
  }

  /* Form */
  .form-label {
      display: block;
      font-size: 13px;
      font-weight: 600;
      color: var(--text-secondary);
      margin-bottom: 6px
  }

  .form-input,
  .form-select {
      width: 100%;
      height: 44px;
      padding: 0 16px;
      border-radius: 10px;
      border: 1px solid var(--border-color);
      background: var(--bg-card-hover);
      color: var(--text-primary);
      font-size: 14px;
      outline: none;
      transition: all var(--transition-fast);
      font-family: var(--font-jakarta)
  }

  .form-input:focus,
  .form-select:focus {
      border-color: var(--primary);
      box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1)
  }

  .form-select {
      appearance: none;
      cursor: pointer;
      background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'/%3e%3c/svg%3e");
      background-repeat: no-repeat;
      background-position: right 12px center
  }

  /* API Key card */
  .api-key-card {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 14px;
      border-radius: 12px;
      background: var(--bg-card-hover);
      border: 1px solid var(--border-color);
      transition: all var(--transition-fast);
      margin-bottom: 10px
  }

  .api-key-card:hover {
      border-color: var(--border-hover)
  }

  .api-key-info {
      flex: 1;
      min-width: 0
  }

  .api-key-name {
      font-size: 14px;
      font-weight: 700;
      color: var(--text-primary);
      margin-bottom: 3px
  }

  .api-key-value {
      font-family: 'Courier New', monospace;
      font-size: 12px;
      color: var(--text-secondary);
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap
  }

  .api-key-meta {
      font-size: 11px;
      color: var(--text-muted);
      margin-top: 4px
  }

  .api-key-status {
      display: inline-flex;
      align-items: center;
      gap: 4px;
      padding: 3px 8px;
      border-radius: 5px;
      font-size: 10px;
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: 0.3px
  }

  .api-key-status.active {
      background: rgba(16, 185, 129, 0.15);
      color: var(--emerald)
  }

  .api-key-status.inactive {
      background: rgba(244, 63, 94, 0.15);
      color: var(--rose)
  }

  .api-key-actions {
      display: flex;
      gap: 6px;
      flex-shrink: 0
  }

  .api-key-btn {
      width: 32px;
      height: 32px;
      border-radius: 8px;
      border: 1px solid var(--border-color);
      background: transparent;
      color: var(--text-secondary);
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: all var(--transition-fast)
  }

  .api-key-btn:hover {
      background: var(--bg-card);
      color: var(--text-primary);
      border-color: var(--border-hover)
  }

  .api-key-btn.delete:hover {
      background: rgba(244, 63, 94, 0.15);
      color: var(--rose);
      border-color: var(--rose)
  }

  .api-key-btn i {
      width: 14px;
      height: 14px
  }

  /* Modal */
  .modal-overlay {
      position: fixed;
      inset: 0;
      background: rgba(0, 0, 0, 0.7);
      backdrop-filter: blur(8px);
      z-index: 9998;
      opacity: 0;
      visibility: hidden;
      transition: all var(--transition-normal);
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 20px;
      overflow-y: auto
  }

  .modal-overlay.show {
      opacity: 1;
      visibility: visible
  }

  .modal-box {
      background: var(--bg-card-solid);
      border: 1px solid var(--border-color);
      border-radius: 20px;
      width: 100%;
      max-width: 520px;
      max-height: 90vh;
      max-height: 90dvh;
      overflow: hidden;
      display: flex;
      flex-direction: column;
      transform: scale(0.9) translateY(20px);
      transition: transform var(--transition-normal);
      box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5)
  }

  .modal-overlay.show .modal-box {
      transform: scale(1) translateY(0)
  }

  .modal-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 20px 24px;
      border-bottom: 1px solid var(--border-color);
      flex-shrink: 0
  }

  .modal-head h3 {
      font-size: 18px;
      font-weight: 700;
      color: var(--text-primary)
  }

  .modal-close-btn {
      width: 36px;
      height: 36px;
      border-radius: 10px;
      border: 1px solid var(--border-color);
      background: transparent;
      color: var(--text-secondary);
      display: flex;
      align-items: center;
      justify-content: center;
      transition: all var(--transition-fast);
      cursor: pointer
  }

  .modal-close-btn:hover {
      background: rgba(244, 63, 94, 0.1);
      color: var(--rose);
      border-color: var(--rose)
  }

  .modal-body {
      padding: 24px;
      overflow-y: auto;
      flex: 1
  }

  .modal-foot {
      display: flex;
      align-items: center;
      justify-content: flex-end;
      gap: 12px;
      padding: 16px 24px;
      border-top: 1px solid var(--border-color);
      flex-wrap: wrap;
      flex-shrink: 0
  }

  .toast-container {
      position: fixed;
      top: calc(20px+var(--safe-top));
      right: 20px;
      z-index: 99999;
      display: flex;
      flex-direction: column;
      gap: 10px;
      pointer-events: none;
      max-width: calc(100vw - 40px)
  }

  .toast {
      min-width: 320px;
      max-width: 420px;
      padding: 14px 20px;
      border-radius: 12px;
      background: var(--bg-card-solid);
      border: 1px solid var(--border-color);
      box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
      display: flex;
      align-items: center;
      gap: 12px;
      pointer-events: all;
      animation: toast-in 0.3s ease-out
  }

  .toast.closing {
      animation: toast-out 0.3s ease-in forwards
  }

  .toast.t-success {
      border-left: 3px solid var(--emerald)
  }

  .toast.t-info {
      border-left: 3px solid var(--primary)
  }

  .toast.t-warning {
      border-left: 3px solid var(--amber)
  }

  .toast.t-error {
      border-left: 3px solid var(--rose)
  }

  @keyframes toast-in {
      from {
          transform: translateX(120%);
          opacity: 0
      }

      to {
          transform: translateX(0);
          opacity: 1
      }
  }

  @keyframes toast-out {
      from {
          transform: translateX(0);
          opacity: 1
      }

      to {
          transform: translateX(120%);
          opacity: 0
      }
  }

  .toast-title {
      font-size: 14px;
      font-weight: 600;
      color: var(--text-primary)
  }

  .toast-msg {
      font-size: 13px;
      color: var(--text-muted)
  }

  .toast-close {
      width: 24px;
      height: 24px;
      background: transparent;
      color: var(--text-muted);
      display: flex;
      align-items: center;
      justify-content: center;
      flex-shrink: 0;
      border-radius: 6px;
      cursor: pointer
  }

  .toast-close:hover {
      background: var(--bg-card-hover);
      color: var(--text-primary)
  }

  .page-loader {
      position: fixed;
      inset: 0;
      background: var(--bg-primary);
      z-index: 999999;
      display: flex;
      align-items: center;
      justify-content: center;
      flex-direction: column;
      gap: 20px;
      transition: opacity 0.5s ease, visibility 0.5s ease
  }

  .page-loader.hidden {
      opacity: 0;
      visibility: hidden;
      pointer-events: none
  }

  .loader-ring {
      width: 48px;
      height: 48px;
      border: 3px solid var(--border-color);
      border-top-color: var(--primary);
      border-radius: 50%;
      animation: spin 0.8s linear infinite
  }

  @keyframes spin {
      to {
          transform: rotate(360deg)
      }
  }

  .loader-label {
      font-size: 14px;
      font-weight: 700;
      color: var(--text-muted);
      letter-spacing: 3px;
      text-transform: uppercase
  }

  .main-footer {
      padding: 20px 0;
      border-top: 1px solid var(--border-color);
      display: flex;
      align-items: center;
      justify-content: space-between;
      flex-wrap: wrap;
      gap: 12px
  }

  .main-footer a {
      font-size: 13px;
      color: var(--text-muted);
      transition: color 0.2s
  }

  .main-footer a:hover {
      color: var(--primary)
  }

  .grid-2 {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 24px
  }

  /* Danger zone */
  .danger-zone {
      padding: 24px;
      border-radius: 16px;
      background: rgba(244, 63, 94, 0.05);
      border: 1px solid rgba(244, 63, 94, 0.2)
  }

  .danger-zone-title {
      font-size: 16px;
      font-weight: 700;
      color: var(--rose);
      margin-bottom: 8px;
      display: flex;
      align-items: center;
      gap: 8px
  }

  .danger-zone-title i {
      width: 20px;
      height: 20px
  }

  .danger-zone-desc {
      font-size: 13px;
      color: var(--text-secondary);
      margin-bottom: 16px;
      line-height: 1.5
  }

  /* Responsive */
  @media (max-width:1280px) {
      .live-ticker {
          display: none
      }
  }

  @media (max-width:1100px) {
      .navbar-search {
          display: none
      }

      .np-info-text {
          display: none
      }

      .navbar-profile {
          padding: 5px
      }

      .grid-2 {
          grid-template-columns: 1fr
      }

      .sh-inner {
          text-align: center;
          justify-content: center
      }

      .sh-actions {
          justify-content: center
      }
  }

  @media (max-width:768px) {
      :root {
          --navbar-height: 60px
      }

      .sidebar {
          transform: translateX(-100%);
          z-index: 60;
          width: 280px !important;
          box-shadow: 4px 0 30px rgba(0, 0, 0, 0.5)
      }

      .sidebar.mobile-open {
          transform: translateX(0)
      }

      .main-content {
          margin-left: 0 !important
      }

      .navbar {
          left: 0 !important;
          padding: 0 12px;
          gap: 8px
      }

      .mobile-toggle {
          display: flex
      }

      .desktop-toggle {
          display: none
      }

      .page-content {
          padding: 14px;
          padding-top: calc(var(--navbar-height)+14px);
          gap: 16px
      }

      .card-pad {
          padding: 16px
      }

      .settings-hero {
          padding: 20px;
          border-radius: 20px
      }

      .sh-name {
          font-size: 20px
      }

      .sh-avatar {
          width: 64px;
          height: 64px;
          border-radius: 16px
      }

      .toast-container {
          top: calc(12px+var(--safe-top));
          right: 12px;
          left: 12px;
          max-width: calc(100vw - 24px)
      }

      .toast {
          min-width: auto;
          max-width: 100%;
          padding: 12px 14px
      }

      .modal-overlay {
          padding: 12px;
          align-items: flex-end
      }

      .modal-box {
          border-radius: 18px;
          max-height: 88vh;
          max-height: 88dvh
      }

      .modal-foot .btn {
          flex: 1
      }

      .dropdown-menu {
          position: fixed;
          top: calc(var(--navbar-height)+8px) !important;
          right: 12px !important;
          left: 12px !important;
          min-width: auto !important;
          max-width: none !important
      }

      .navbar-profile {
          border: none;
          padding: 3px
      }

      .main-footer {
          padding: 16px 0
      }

      .main-footer>* {
          text-align: center;
          width: 100%
      }

      .navbar-right {
          gap: 4px
      }

      .nav-icon-btn,
      .theme-toggle {
          width: 38px;
          height: 38px;
          min-width: 38px
      }

      .page-title {
          font-size: 20px
      }

      .page-header-actions {
          width: 100%
      }

      .page-header-actions .btn {
          flex: 1
      }

      .tab-btn {
          padding: 10px 14px;
          font-size: 13px
      }
  }

  @media (max-width:640px) {
      .page-content {
          padding: 12px;
          padding-top: calc(var(--navbar-height)+12px);
          gap: 14px
      }

      .btn {
          padding: 9px 16px;
          font-size: 13px;
          min-height: 40px
      }

      .btn-sm {
          padding: 5px 10px;
          font-size: 11px;
          min-height: 28px
      }

      .sh-name {
          font-size: 18px
      }
  }

  @media (max-width:480px) {
      :root {
          --navbar-height: 56px
      }

      .page-content {
          padding: 10px;
          padding-top: calc(var(--navbar-height)+10px)
      }

      .card {
          border-radius: 14px
      }

      .card-pad {
          padding: 14px
      }

      .sidebar {
          width: 260px !important
      }

      .navbar {
          padding: 0 10px;
          gap: 6px
      }

      .nav-icon-btn,
      .theme-toggle {
          width: 36px;
          height: 36px;
          min-width: 36px
      }

      .navbar-profile-avatar {
          width: 32px;
          height: 32px
      }

      .modal-overlay {
          padding: 8px
      }

      .modal-box {
          border-radius: 16px
      }

      .settings-group {
          padding: 16px
      }
  }

  @media (hover:none) and (pointer:coarse) {
      .nav-link:hover {
          transform: none;
          background: transparent;
          color: var(--text-secondary)
      }

      .nav-link:active {
          background: var(--bg-card-hover);
          color: var(--text-primary)
      }

      .nav-link.active {
          background: var(--gradient-primary);
          color: #fff
      }

      .btn:hover,
      .card:hover {
          transform: none
      }

      .btn:active {
          transform: scale(0.97)
      }
  }

  @media print {

      .sidebar,
      .navbar,
      .sidebar-overlay,
      .toast-container,
      .page-loader {
          display: none !important
      }

      .main-content {
          margin-left: 0 !important
      }
  }