/* ========================================
   Arabic Google Fonts - Professional & Beautiful
   ======================================== */
   @import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;500;600;700;800&display=swap');
   @import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@400;500;700;800&display=swap');
   @import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans+Arabic:wght@400;500;600;700&display=swap');
   @import url('https://fonts.googleapis.com/css2?family=Almarai:wght@400;700;800&display=swap');
   
   * {
       margin: 0;
       padding: 0;
       box-sizing: border-box;
   }
   
   :root {
       /* Corporate Dark Theme */
       --bg-primary: #0d1117;
       --bg-secondary: #161b22;
       --bg-tertiary: #1c2128;
       --bg-elevated: #22272e;
       --bg-hover: #2d333b;
       
       /* Professional Blue Palette */
       --primary: #0969da;
       --primary-hover: #0860ca;
       --primary-active: #0757ba;
       --primary-light: #1f6feb;
       
       /* Status Colors */
       --success: #1f883d;
       --success-light: #26a641;
       --warning: #bf8700;
       --warning-light: #d29922;
       --danger: #cf222e;
       --danger-light: #e5534b;
       --info: #0969da;
       
       /* Text Colors */
       --text-primary: #e6edf3;
       --text-secondary: #8b949e;
       --text-tertiary: #6e7681;
       --text-link: #2f81f7;
       
       /* Borders */
       --border-default: #30363d;
       --border-muted: #21262d;
       --border-emphasis: #444c56;
       
       /* Shadows */
       --shadow-sm: 0 1px 0 rgba(1, 4, 9, 0.1);
       --shadow-md: 0 3px 6px rgba(1, 4, 9, 0.12);
       --shadow-lg: 0 8px 24px rgba(1, 4, 9, 0.12);
       --shadow-xl: 0 16px 32px rgba(1, 4, 9, 0.16);
       
       /* Fonts */
       --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
       --font-arabic: "Cairo", "Tajawal", "IBM Plex Sans Arabic", "Almarai", -apple-system, sans-serif;
       --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
   }
   
   body {
       font-family: var(--font-sans);
       background: var(--bg-primary);
       color: var(--text-primary);
       line-height: 1.5;
       -webkit-font-smoothing: antialiased;
   }
   
   body.rtl {
       direction: rtl;
       font-family: var(--font-arabic);
       font-weight: 500;
       letter-spacing: 0.01em;
       -webkit-font-smoothing: antialiased;
       -moz-osx-font-smoothing: grayscale;
       text-rendering: optimizeLegibility;
   }
   /* ========================================
      Enhanced Arabic Typography
      ======================================== */
   
   /* تحسين العناوين العربية */
   body.rtl h1,
   body.rtl h2,
   body.rtl h3,
   body.rtl h4,
   body.rtl h5,
   body.rtl h6 {
       font-family: "Cairo", var(--font-arabic);
       font-weight: 700;
       letter-spacing: 0;
       line-height: 1.4;
   }
   
   /* تحسين الأزرار العربية */
   body.rtl button,
   body.rtl .btn,
   body.rtl .button {
       font-family: "Cairo", var(--font-arabic);
       font-weight: 600;
       letter-spacing: 0;
   }
   
   /* تحسين النصوص الصغيرة العربية */
   body.rtl small,
   body.rtl .small-text {
       font-family: "Tajawal", var(--font-arabic);
       font-weight: 500;
   }
   
   /* تحسين الـ Input العربي */
   body.rtl input,
   body.rtl textarea,
   body.rtl select {
       font-family: "Tajawal", var(--font-arabic);
       font-weight: 500;
   }
   
   /* تحسين الجداول العربية */
   body.rtl table,
   body.rtl th,
   body.rtl td {
       font-family: "IBM Plex Sans Arabic", var(--font-arabic);
       font-weight: 500;
   }
   
   /* تحسين القوائم العربية */
   body.rtl ul,
   body.rtl ol,
   body.rtl li {
       font-family: "Tajawal", var(--font-arabic);
       font-weight: 500;
       line-height: 1.7;
   }
   
   /* تحسين البطاقات والكروت العربية */
   body.rtl .card,
   body.rtl .product-card,
   body.rtl .stat-card {
       font-family: "Cairo", var(--font-arabic);
   }
   
   /* تحسين الأرقام العربية */
   body.rtl .number,
   body.rtl .price,
   body.rtl .amount {
       font-family: "Cairo", var(--font-arabic);
       font-weight: 700;
       font-variant-numeric: tabular-nums;
   }
   
   
   
   /* Professional Header */
   .main-header {
       position: fixed;
       top: 0; left: 0; right: 0;
       z-index: 1000;
       background: rgba(22, 27, 34, 0.9);
       border-bottom: 1px solid var(--border-default);
       box-shadow: var(--shadow-sm);
       backdrop-filter: blur(16px);
       -webkit-backdrop-filter: blur(16px);
   }
   
   .header-container {
       max-width: 1280px;
       margin: 0 auto;
       padding: 0 24px;
       height: 64px;
       display: flex;
       justify-content: space-between;
       align-items: center;
   }
   
   .logo {
       display: flex;
       align-items: center;
       gap: 12px;
       font-weight: 600;
       font-size: 16px;
       color: var(--text-primary);
       cursor: pointer;
       transition: opacity 0.2s;
   }
   
   .logo:hover {
       opacity: 0.8;
   }
   
   .logo-icon {
       width: 32px;
       height: 32px;
       background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
       border-radius: 6px;
       display: flex;
       align-items: center;
       justify-content: center;
       color: white;
       font-size: 18px;
       box-shadow: 0 2px 8px rgba(9, 105, 218, 0.3);
   }
   
   .header-nav {
       display: flex;
       align-items: center;
       gap: 16px;
   }
   
   .nav-links {
       display: flex;
       gap: 4px;
       list-style: none;
       margin: 0 16px 0 0;
   }
   
   body.rtl .nav-links {
       margin: 0 0 0 16px;
   }
   
   .nav-links a {
       padding: 8px 16px;
       color: var(--text-secondary);
       text-decoration: none;
       font-weight: 500;
       font-size: 14px;
       border-radius: 6px;
       transition: all 0.2s;
   }
   
   .nav-links a:hover {
       color: var(--text-primary);
       background: var(--bg-tertiary);
   }
   
   .nav-links a.active {
       color: var(--text-primary);
       background: var(--bg-elevated);
   }
   
   .search-container {
       position: relative;
       width: 300px;
   }
   
   .search-input {
       width: 100%;
       height: 36px;
       padding: 0 12px 0 36px;
       background: var(--bg-tertiary);
       border: 1px solid var(--border-default);
       border-radius: 6px;
       color: var(--text-primary);
       font-size: 14px;
       transition: all 0.2s;
   }
   
   body.rtl .search-input {
       padding: 0 36px 0 12px;
   }
   
   .search-input:focus {
       outline: none;
       border-color: var(--primary);
       background: var(--bg-primary);
       box-shadow: 0 0 0 3px rgba(9, 105, 218, 0.12);
   }
   
   .search-icon {
       position: absolute;
       left: 12px;
       top: 50%;
       transform: translateY(-50%);
       color: var(--text-tertiary);
       font-size: 16px;
       pointer-events: none;
   }
   
   body.rtl .search-icon {
       left: auto;
       right: 12px;
   }
   
   .header-actions {
       display: flex;
       align-items: center;
       gap: 8px;
   }
   
   .icon-btn {
       width: 36px;
       height: 36px;
       background: transparent;
       border: 1px solid var(--border-default);
       border-radius: 6px;
       display: flex;
       align-items: center;
       justify-content: center;
       cursor: pointer;
       color: var(--text-secondary);
       font-size: 16px;
       transition: all 0.2s;
       position: relative;
   }
   
   .icon-btn:hover {
       background: var(--bg-hover);
       border-color: var(--border-emphasis);
       color: var(--text-primary);
       transform: translateY(-1px);
   }
   
   .icon-btn.active {
       background: var(--bg-elevated);
       border-color: var(--primary);
       color: var(--primary);
   }
   
   .notification-badge {
       position: absolute;
       top: -4px;
       right: -4px;
       background: var(--danger);
       color: white;
       border-radius: 10px;
       padding: 2px 6px;
       font-size: 11px;
       font-weight: 600;
       line-height: 1;
       min-width: 18px;
       text-align: center;
       box-shadow: 0 2px 4px rgba(207, 34, 46, 0.4);
       animation: pulse 2s ease-in-out infinite;
   }
   
   @keyframes pulse {
       0%, 100% { transform: scale(1); }
       50% { transform: scale(1.1); }
   }
   
   /* ✅ NEW: Notifications Dropdown */
   /* ═══════ Notifications Panel ═══════ */
   .notifications-dropdown {
       position: absolute; top: calc(100% + 10px); right: 0;
       width: 355px;
       background: #161b22;
       border: 1px solid #30363d;
       border-radius: 12px;
       box-shadow: 0 16px 48px rgba(0,0,0,0.6), 0 0 0 1px rgba(255,255,255,0.02);
       opacity: 0; visibility: hidden;
       transform: translateY(-6px) scale(0.98);
       transform-origin: top right;
       transition: opacity 0.18s, transform 0.18s, visibility 0.18s;
       z-index: 1001; overflow: hidden;
   }
   .notifications-dropdown.show {
       opacity: 1; visibility: visible; transform: translateY(0) scale(1);
   }
   .notif-panel-header {
       padding: 13px 16px 0; border-bottom: 1px solid #30363d;
   }
   .notif-panel-title-row {
       display: flex; align-items: center;
       justify-content: space-between; margin-bottom: 10px;
   }
   .notif-panel-title {
       display: flex; align-items: center; gap: 7px;
       font-size: 13px; font-weight: 700; color: #e6edf3;
   }
   .notif-mark-all {
       font-size: 11.5px; font-weight: 600; color: #58a6ff;
       background: none; border: none; cursor: pointer; font-family: inherit;
       padding: 3px 8px; border-radius: 6px; transition: background 0.15s;
   }
   .notif-mark-all:hover { background: rgba(88,166,255,0.1); }
   .notif-tabs { display: flex; margin-bottom: -1px; }
   .notif-tab {
       padding: 6px 13px; font-size: 12px; font-weight: 600;
       color: #8b949e; background: none; border: none;
       border-bottom: 2px solid transparent;
       cursor: pointer; font-family: inherit;
       transition: color 0.15s, border-color 0.15s;
       display: flex; align-items: center; gap: 5px;
   }
   .notif-tab:hover { color: #e6edf3; }
   .notif-tab.active { color: #e6edf3; border-bottom-color: #0969da; }
   .notif-tab-count {
       display: inline-flex; align-items: center; justify-content: center;
       min-width: 16px; height: 16px; padding: 0 4px;
       background: #0969da; color: white;
       font-size: 9.5px; font-weight: 700; border-radius: 8px;
   }
   .notif-tab-count:empty { display: none; }
   .notifications-list {
       max-height: 320px; overflow-y: auto;
       scrollbar-width: thin; scrollbar-color: #30363d transparent;
   }
   .notifications-list::-webkit-scrollbar { width: 3px; }
   .notifications-list::-webkit-scrollbar-thumb { background: #30363d; border-radius: 2px; }
   .notification-item {
       display: flex; align-items: flex-start; gap: 11px;
       padding: 12px 16px; border-bottom: 1px solid #21262d;
       cursor: pointer; transition: background 0.15s; position: relative;
   }
   .notification-item:last-child { border-bottom: none; }
   .notification-item:hover { background: #1c2128; }
   .notification-item.unread { background: rgba(9,105,218,0.05); }
   .notification-item.unread:hover { background: rgba(9,105,218,0.09); }
   .notification-item.unread::before {
       content: ''; position: absolute;
       left: 0; top: 0; bottom: 0;
       width: 3px; background: #0969da; border-radius: 0 2px 2px 0;
   }
   .notification-icon {
       width: 34px; height: 34px; border-radius: 9px;
       display: flex; align-items: center; justify-content: center;
       font-size: 15px; flex-shrink: 0; border: 1px solid transparent;
   }
   .notification-icon.warning { background: rgba(191,135,0,0.12); color: #d29922; border-color: rgba(191,135,0,0.2); }
   .notification-icon.danger  { background: rgba(207,34,46,0.12);  color: #f85149; border-color: rgba(207,34,46,0.2); }
   .notification-icon.success { background: rgba(31,136,61,0.12);  color: #3fb950; border-color: rgba(31,136,61,0.2); }
   .notification-icon.info    { background: rgba(9,105,218,0.12);  color: #58a6ff; border-color: rgba(9,105,218,0.2); }
   .notification-content { flex: 1; min-width: 0; }
   .notification-title {
       font-size: 13px; font-weight: 700; color: #e6edf3; margin-bottom: 2px;
       white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
   }
   .notification-message {
       font-size: 12px; color: #8b949e; line-height: 1.4;
       display: -webkit-box; -webkit-line-clamp: 2;
       -webkit-box-orient: vertical; overflow: hidden;
   }
   .notification-time { font-size: 11px; color: #6e7681; margin-top: 4px; }
   .notif-unread-dot {
       width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0;
       background: #0969da; margin-top: 4px;
       box-shadow: 0 0 6px rgba(9,105,218,0.5);
   }
   .no-notifications { padding: 40px 20px; text-align: center; }
   .no-notifications-icon {
       width: 44px; height: 44px; background: #1c2128;
       border: 1px solid #30363d; border-radius: 12px;
       display: flex; align-items: center; justify-content: center;
       margin: 0 auto 12px; font-size: 20px; opacity: 0.5;
   }
   .no-notifications-text { color: #8b949e; font-size: 13px; font-weight: 600; }
   .notif-panel-footer {
       padding: 9px 16px; border-top: 1px solid #30363d;
       display: flex; justify-content: center;
   }
   .notif-footer-btn {
       font-size: 12px; font-weight: 600; color: #8b949e;
       background: none; border: none; cursor: pointer; font-family: inherit;
       padding: 4px 12px; border-radius: 6px; transition: background 0.15s, color 0.15s;
   }
   .notif-footer-btn:hover { background: #1c2128; color: #e6edf3; }
   .no-notifications-text {
       color: var(--text-secondary);
       font-size: 14px;
   }
   
   /* ✅ NEW: User Menu Dropdown */
   .user-menu {
       display: flex;
       align-items: center;
       gap: 8px;
       padding: 4px 4px 4px 12px;
       background: transparent;
       border: 1px solid var(--border-default);
       border-radius: 6px;
       cursor: pointer;
       transition: all 0.2s;
       position: relative;
   }
   
   body.rtl .user-menu {
       padding: 4px 12px 4px 4px;
   }
   
   .user-menu:hover {
       background: var(--bg-hover);
       border-color: var(--border-emphasis);
   }
   
   .user-menu.active {
       background: var(--bg-elevated);
       border-color: var(--primary);
   }
   
   .user-avatar {
       width: 28px;
       height: 28px;
       border-radius: 50%;
       background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
       display: flex;
       align-items: center;
       justify-content: center;
       color: white;
       font-weight: 600;
       font-size: 12px;
   }
   
   .user-name {
       font-weight: 500;
       font-size: 14px;
       color: var(--text-primary);
   }
   
   .user-menu-dropdown {
       position: absolute;
       top: calc(100% + 8px);
       right: 0;
       width: 240px;
       background: var(--bg-secondary);
       border: 1px solid var(--border-default);
       border-radius: 8px;
       box-shadow: var(--shadow-xl);
       opacity: 0;
       visibility: hidden;
       transform: translateY(-10px);
       transition: all 0.2s;
       z-index: 1000;
       overflow: hidden;
   }
   
   .user-menu-dropdown.show {
       opacity: 1;
       visibility: visible;
       transform: translateY(0);
   }
   
   .user-menu-header {
       padding: 16px;
       border-bottom: 1px solid var(--border-default);
   }
   
   .user-menu-name {
       font-size: 14px;
       font-weight: 600;
       color: var(--text-primary);
       margin-bottom: 4px;
   }
   
   .user-menu-email {
       font-size: 12px;
       color: var(--text-secondary);
   }
   
   .user-menu-list {
       padding: 8px 0;
   }
   
   .user-menu-item {
       padding: 10px 16px;
       display: flex;
       align-items: center;
       gap: 12px;
       cursor: pointer;
       transition: background 0.2s;
       border: none;
       background: none;
       width: 100%;
       text-align: left;
       font-family: inherit;
       color: var(--text-primary);
   }
   
   .user-menu-item:hover {
       background: var(--bg-tertiary);
   }
   
   .user-menu-item-icon {
       font-size: 16px;
       color: var(--text-secondary);
   }
   
   .user-menu-item-text {
       font-size: 14px;
       font-weight: 500;
   }
   
   .user-menu-separator {
       height: 1px;
       background: var(--border-default);
       margin: 8px 0;
   }
   
   .user-menu-item.danger {
       color: var(--danger-light);
   }
   
   .user-menu-item.danger .user-menu-item-icon {
       color: var(--danger-light);
   }
   
   /* ═══════════════════════════════════════════════════════════
      AUTH PAGE — v3 — Full dark, both panels harmonious
      ═══════════════════════════════════════════════════════════ */

   /* ─── Wrapper ─── */
   .auth-wrapper {
       display: flex;
       min-height: 100vh;
       background: #080e18;
       position: relative;  /* needed for pg-deco absolute positioning */
   }

   /* ════════════════════════════════════
      LEFT PANEL
      ════════════════════════════════════ */
   .auth-left {
       flex: 0 0 460px;
       background: #080e18;
       border-right: 1px solid rgba(48,54,61,0.6);
       display: flex;
       align-items: center;
       justify-content: center;
       padding: 48px 40px;
       position: relative;
       overflow: hidden;
   }
   /* Top accent bar */
   .auth-left::before {
       content: '';
       position: absolute;
       top: 0; left: 0; right: 0; height: 2px;
       background: linear-gradient(90deg, #0969da 0%, #58a6ff 55%, transparent 100%);
       z-index: 3;
   }
   /* Blobs */
   .alp-blob {
       position: absolute; border-radius: 50%;
       pointer-events: none;
   }
   .alp-blob-1 {
       width: 500px; height: 400px;
       top: -140px; right: -140px;
       background: radial-gradient(ellipse, rgba(9,105,218,0.13) 0%, transparent 65%);
   }
   .alp-blob-2 {
       width: 360px; height: 360px;
       bottom: -100px; left: -80px;
       background: radial-gradient(ellipse, rgba(88,166,255,0.07) 0%, transparent 65%);
   }
   /* Dot grid */
   .alp-grid {
       position: absolute; inset: 0;
       background-image: radial-gradient(circle, rgba(255,255,255,0.03) 1px, transparent 1px);
       background-size: 24px 24px;
       pointer-events: none;
   }
   .alp-inner {
       position: relative; z-index: 2;
       width: 100%;
   }

   /* Brand */
   .alp-brand {
       display: flex; align-items: center; gap: 11px;
       margin-bottom: 32px;
   }
   .alp-brand-icon {
       width: 38px; height: 38px;
       background: linear-gradient(135deg, #0969da 0%, #1f6feb 100%);
       border-radius: 10px;
       display: flex; align-items: center; justify-content: center;
       box-shadow: 0 4px 16px rgba(9,105,218,0.4);
       flex-shrink: 0;
   }
   .alp-brand-name {
       font-size: 14px; font-weight: 800;
       color: #e6edf3;
   }
   .alp-brand-tag {
       font-size: 11px; color: #6e7681; margin-top: 1px;
   }

   /* Headline */
   .alp-headline { margin-bottom: 22px; }
   .alp-eyebrow {
       font-size: 10px; font-weight: 700; letter-spacing: 1.3px;
       text-transform: uppercase; color: #58a6ff;
       margin-bottom: 10px;
       display: flex; align-items: center; gap: 8px;
   }
   .alp-eyebrow::before {
       content: ''; width: 16px; height: 2px;
       background: #58a6ff; border-radius: 2px;
   }
   .alp-title {
       font-size: 26px; font-weight: 900; color: #e6edf3;
       line-height: 1.22; margin-bottom: 10px; letter-spacing: -0.4px;
   }
   .alp-title-accent {
       background: linear-gradient(90deg, #58a6ff 0%, #79c0ff 100%);
       -webkit-background-clip: text; -webkit-text-fill-color: transparent;
       background-clip: text;
   }
   .alp-desc { font-size: 13px; color: #8b949e; line-height: 1.6; }

   /* ── Dashboard mockup ── */
   .alp-mockup {
       background: #161b22;
       border: 1px solid #30363d;
       border-radius: 10px;
       overflow: hidden;
       margin-bottom: 22px;
       box-shadow: 0 12px 40px rgba(0,0,0,0.55), inset 0 1px 0 rgba(255,255,255,0.04);
   }
   /* Browser bar */
   .alp-mb-bar {
       display: flex; align-items: center; gap: 0;
       padding: 7px 12px;
       background: #0d1117;
       border-bottom: 1px solid #30363d;
   }
   .alp-mb-dots { display: flex; gap: 5px; margin-right: 10px; }
   .alp-dot {
       width: 7px; height: 7px; border-radius: 50%;
   }
   .alp-dot.red    { background: #ff5f57; }
   .alp-dot.yellow { background: #febc2e; }
   .alp-dot.green  { background: #28c840; }
   .alp-mb-url {
       flex: 1; display: flex; align-items: center; justify-content: center;
       gap: 5px; font-size: 9.5px; color: #6e7681;
       font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
   }
   /* Mockup body */
   .alp-mb-body {
       padding: 11px; display: flex; flex-direction: column; gap: 7px;
   }
   /* Stat cards */
   .alp-mb-stats {
       display: grid; grid-template-columns: repeat(4,1fr); gap: 5px;
   }
   .alp-mb-stat {
       padding: 8px 4px; border-radius: 7px;
       text-align: center; border: 1px solid transparent;
   }
   .alp-mb-stat.c-blue   { background: rgba(9,105,218,0.1);  border-color: rgba(9,105,218,0.2);  }
   .alp-mb-stat.c-green  { background: rgba(40,200,64,0.1);  border-color: rgba(40,200,64,0.2);  }
   .alp-mb-stat.c-yellow { background: rgba(254,188,46,0.1); border-color: rgba(254,188,46,0.2); }
   .alp-mb-stat.c-red    { background: rgba(255,95,87,0.1);  border-color: rgba(255,95,87,0.2);  }
   .alp-mb-stat-n {
       font-size: 15px; font-weight: 900; color: #e6edf3; line-height: 1;
   }
   .alp-mb-stat-l {
       font-size: 8.5px; color: #6e7681; margin-top: 3px;
       font-weight: 600; text-transform: uppercase; letter-spacing: 0.2px;
   }
   /* Section label */
   .alp-mb-section-lbl {
       font-size: 9px; font-weight: 700; color: #6e7681;
       text-transform: uppercase; letter-spacing: 0.6px;
       padding: 0 2px;
   }
   /* Product rows */
   .alp-mb-product {
       display: flex; align-items: center; gap: 8px;
       background: #1c2128;
       border: 1px solid #30363d;
       border-radius: 7px; padding: 8px 9px;
       transition: border-color 0.2s;
   }
   .alp-mb-prod-icon {
       width: 26px; height: 26px; border-radius: 6px;
       display: flex; align-items: center; justify-content: center;
       font-size: 12px; flex-shrink: 0; border: 1px solid transparent;
   }
   .alp-mb-prod-icon.c-blue   { background: rgba(9,105,218,0.15);   border-color: rgba(9,105,218,0.2);  }
   .alp-mb-prod-icon.c-purple { background: rgba(188,140,255,0.15); border-color: rgba(188,140,255,0.2);}
   .alp-mb-prod-icon.c-orange { background: rgba(255,140,0,0.15);   border-color: rgba(255,140,0,0.2);  }
   .alp-mb-prod-info { flex: 1; min-width: 0; }
   .alp-mb-prod-name {
       font-size: 10.5px; font-weight: 700; color: #e6edf3;
       white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
   }
   .alp-mb-prod-key {
       font-size: 9px; color: #6e7681;
       font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
       margin-top: 1px;
   }
   .alp-mb-badge {
       font-size: 8.5px; font-weight: 700;
       padding: 2px 7px; border-radius: 10px; flex-shrink: 0;
       border: 1px solid transparent;
   }
   .alp-mb-badge.b-green  { background: rgba(40,200,64,0.1);  color: #3fb950; border-color: rgba(40,200,64,0.2);  }
   .alp-mb-badge.b-yellow { background: rgba(254,188,46,0.1); color: #d29922; border-color: rgba(254,188,46,0.2); }
   .alp-mb-badge.b-red    { background: rgba(255,95,87,0.1);  color: #f85149; border-color: rgba(255,95,87,0.2);  }

   /* Stats strip */
   .alp-stats {
       display: flex; align-items: center;
       padding: 14px 0 0;
       border-top: 1px solid rgba(48,54,61,0.7);
   }
   .alp-stat { flex: 1; text-align: center; }
   .alp-stat-n {
       font-size: 15px; font-weight: 900; color: #e6edf3; letter-spacing: -0.2px;
   }
   .alp-stat-l {
       font-size: 9.5px; color: #6e7681; margin-top: 2px;
       font-weight: 600; text-transform: uppercase; letter-spacing: 0.4px;
   }
   .alp-stat-sep { width: 1px; height: 26px; background: rgba(48,54,61,0.8); }

   /* ════════════════════════════════════
      RIGHT PANEL — dark, matching left
      ════════════════════════════════════ */
   .auth-right {
       flex: 1;
       display: flex;
       flex-direction: column;
       background: #080e18;
       position: relative;
       overflow-y: auto;
   }
   /* Top accent bar matching left */
   .auth-right::before {
       content: '';
       position: absolute;
       top: 0; left: 0; right: 0; height: 2px;
       background: linear-gradient(90deg, transparent 0%, #0969da 40%, #58a6ff 70%, transparent 100%);
       z-index: 3;
   }
   /* Matching blobs */
   .arp-blob {
       position: absolute; border-radius: 50%; pointer-events: none;
   }
   .arp-blob-1 {
       width: 400px; height: 400px;
       top: -80px; left: -80px;
       background: radial-gradient(ellipse, rgba(9,105,218,0.08) 0%, transparent 65%);
   }
   /* Matching dot grid */
   .arp-grid {
       position: absolute; inset: 0;
       background-image: radial-gradient(circle, rgba(255,255,255,0.02) 1px, transparent 1px);
       background-size: 24px 24px;
       pointer-events: none;
   }
   .arp-inner {
       flex: 1; display: flex; flex-direction: column;
       align-items: center; justify-content: center;
       padding: 48px 24px;
       position: relative; z-index: 3;
   }

   /* Mobile brand */
   .arp-mobile-brand {
       display: none; align-items: center; gap: 10px;
       margin-bottom: 24px; align-self: flex-start;
   }

   /* ── Form card ── */
   .arp-card {
       width: 100%; max-width: 400px;
       background: #161b22;
       border: 1px solid #30363d;
       border-radius: 14px;
       padding: 32px;
       box-shadow: 0 8px 32px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.03);
       position: relative;
       overflow: hidden;
   }
   /* Card top glow */
   .arp-card-glow {
       position: absolute;
       top: 0; left: 0; right: 0; height: 3px;
       background: linear-gradient(90deg, #0969da 0%, #58a6ff 55%, transparent 100%);
       z-index: 1;
   }
   .arp-card::after {
       content: '';
       position: absolute;
       top: -60px; right: -60px;
       width: 200px; height: 200px;
       border-radius: 50%;
       background: radial-gradient(circle, rgba(9,105,218,0.06) 0%, transparent 65%);
       pointer-events: none;
   }

   /* Form header */
   .arp-header {
       display: flex; align-items: flex-start; gap: 13px;
       margin-bottom: 24px;
       position: relative; z-index: 2;
   }
   .arp-header-icon {
       width: 40px; height: 40px; flex-shrink: 0;
       background: rgba(9,105,218,0.12);
       border: 1px solid rgba(9,105,218,0.25);
       border-radius: 10px;
       display: flex; align-items: center; justify-content: center;
       color: #58a6ff; margin-top: 2px;
   }
   .arp-title {
       font-size: 21px; font-weight: 800; color: #e6edf3;
       letter-spacing: -0.2px; margin-bottom: 4px;
   }
   .arp-subtitle { font-size: 13px; color: #8b949e; line-height: 1.4; }

   /* Fields */
   .arp-field { margin-bottom: 12px; position: relative; z-index: 2; }
   .arp-label {
       display: block; margin-bottom: 5px;
       font-size: 11.5px; font-weight: 700;
       color: #8b949e;
       text-transform: uppercase; letter-spacing: 0.5px;
   }
   .arp-input-wrap { position: relative; }
   .arp-field-ico {
       position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
       color: #6e7681; pointer-events: none; transition: color 0.2s;
   }
   .arp-input-wrap:focus-within .arp-field-ico { color: #58a6ff; }
   .arp-input-wrap input {
       width: 100%; height: 44px;
       padding: 0 40px 0 40px;
       background: #0d1117;
       border: 1px solid #30363d;
       border-radius: 9px;
       font-size: 14px; color: #e6edf3;
       transition: border-color 0.2s, box-shadow 0.2s;
       font-family: inherit;
       -webkit-appearance: none;
   }
   .arp-input-wrap input::placeholder { color: #484f58; }
   .arp-input-wrap input:focus {
       outline: none;
       border-color: #0969da;
       box-shadow: 0 0 0 3px rgba(9,105,218,0.15);
       background: #0b1220;
   }
   .arp-eye {
       position: absolute; left: 11px; top: 50%; transform: translateY(-50%);
       background: none; border: none; cursor: pointer;
       color: #6e7681; display: flex; align-items: center;
       padding: 4px; transition: color 0.15s;
   }
   .arp-eye:hover { color: #e6edf3; }

   /* strength bar */
   .auth-strength-wrap { margin: -4px 0 10px; position: relative; z-index: 2; }

   /* Submit */
   .arp-submit {
       width: 100%; height: 44px;
       border-radius: 9px; font-size: 14px; font-weight: 700;
       margin-top: 6px; display: flex; align-items: center;
       justify-content: center; gap: 7px;
       position: relative; z-index: 2;
       background: linear-gradient(135deg, #0969da 0%, #1f6feb 100%);
       border: none; color: white;
       box-shadow: 0 4px 14px rgba(9,105,218,0.35);
       transition: transform 0.15s, box-shadow 0.15s;
   }
   .arp-submit:hover:not(:disabled) {
       transform: translateY(-1px);
       box-shadow: 0 6px 20px rgba(9,105,218,0.45);
   }
   .arp-submit:hover:not(:disabled) svg { transform: translateX(3px); }
   .arp-submit svg { transition: transform 0.15s; }

   /* Divider */
   .arp-divider {
       display: flex; align-items: center; gap: 10px;
       margin: 16px 0; color: #484f58;
       font-size: 11px; font-weight: 600;
       text-transform: uppercase; letter-spacing: 0.5px;
       position: relative; z-index: 2;
   }
   .arp-divider::before, .arp-divider::after {
       content: ''; flex: 1; height: 1px; background: #30363d;
   }

   /* Google */
   .arp-google-btn {
       width: 100%; height: 42px;
       background: #1c2128;
       border: 1px solid #30363d;
       border-radius: 9px; color: #e6edf3;
       font-size: 13px; font-weight: 600;
       cursor: pointer; transition: all 0.2s; font-family: inherit;
       display: flex; align-items: center; justify-content: center; gap: 9px;
       position: relative; z-index: 2;
   }
   .arp-google-btn:hover {
       background: #21262d;
       border-color: #484f58;
       transform: translateY(-1px);
       box-shadow: 0 4px 14px rgba(0,0,0,0.3);
   }

   /* Switch */
   .arp-switch {
       display: flex; align-items: center; justify-content: center;
       gap: 6px; margin-top: 16px; position: relative; z-index: 2;
   }
   .arp-switch-text { font-size: 13px; color: #8b949e; }
   .arp-switch-btn {
       background: none; border: none; color: #58a6ff;
       font-size: 13px; font-weight: 700;
       cursor: pointer; font-family: inherit; padding: 0;
       transition: color 0.15s;
   }
   .arp-switch-btn:hover { color: #79c0ff; text-decoration: underline; }

   /* Trust row */
   .arp-trust {
       display: flex; align-items: center; justify-content: center;
       gap: 8px; margin-top: 20px; padding-top: 16px;
       border-top: 1px solid #21262d;
       position: relative; z-index: 2;
   }
   .arp-trust-item {
       display: flex; align-items: center; gap: 4px;
       font-size: 10.5px; font-weight: 600; color: #6e7681;
   }
   .arp-trust-dot {
       width: 3px; height: 3px; border-radius: 50%; background: #484f58;
   }

   /* ── Hide old classes ── */
   .tabs, .tab, .auth-input-icon, .auth-form-box,
   .auth-feature-list, .auth-left-panel, .auth-right-panel,
   .auth-left-content, .auth-brand-wrap, .auth-headline,
   .auth-stats-row, .auth-form-header, .auth-input-group,
   .auth-submit-btn, .auth-divider, .auth-google-btn,
   .auth-switch-row, .auth-form-title { }

   /* ── Welcome badge (stays above card) ── */
   .arp-welcome-badge {
       display: flex; align-items: center; gap: 7px;
       background: rgba(9,105,218,0.08);
       border: 1px solid rgba(9,105,218,0.2);
       border-radius: 20px;
       padding: 5px 13px 5px 9px;
       font-size: 11.5px; font-weight: 600; color: #58a6ff;
       margin-bottom: 16px; width: fit-content;
       letter-spacing: 0.1px;
   }
   .arp-wb-dot {
       width: 7px; height: 7px; border-radius: 50%;
       background: #3fb950; flex-shrink: 0;
       box-shadow: 0 0 7px rgba(63,185,80,0.7);
       animation: arp-pulse 2.5s ease-in-out infinite;
   }
   @keyframes arp-pulse {
       0%, 100% { opacity: 1; transform: scale(1); }
       50%       { opacity: 0.65; transform: scale(1.2); }
   }

   /* ══════════════════════════════════════════════════
      PAGE-LEVEL DECO — 2 floating cards on auth-wrapper
      Left panel = 460px. Right panel = rest.
      Form card ≈ 400px centered in right panel.

      pg-deco-a: upper-right zone (~75% from left, ~20% from top)
      pg-deco-b: lower-right zone (~82% from left, ~75% from top)
      ══════════════════════════════════════════════════ */

   .pg-deco {
       position: absolute;
       pointer-events: none;
       z-index: 2;
       animation: pgFloat 7s ease-in-out infinite;
   }
   .pg-deco-b { animation-delay: 2s; animation-duration: 8s; }

   @keyframes pgFloat {
       0%, 100% { transform: translateY(0); }
       50%       { transform: translateY(-9px); }
   }

   /* ── Deco A: Activity card — upper right of right panel ── */
   .pg-deco-a {
       right: 3%;
       top: 12%;
       width: 210px;
       background: rgba(22,27,34,0.82);
       border: 1px solid rgba(48,54,61,0.85);
       border-radius: 13px;
       padding: 13px 14px;
       backdrop-filter: blur(14px);
       -webkit-backdrop-filter: blur(14px);
       box-shadow: 0 10px 36px rgba(0,0,0,0.45),
                   inset 0 1px 0 rgba(255,255,255,0.03);
   }
   .pg-deco-card-hd {
       display: flex; align-items: center; gap: 6px;
       font-size: 10px; font-weight: 700; letter-spacing: 0.6px;
       text-transform: uppercase; color: #8b949e;
       margin-bottom: 11px;
   }
   .pg-deco-live {
       width: 6px; height: 6px; border-radius: 50%;
       background: #3fb950; flex-shrink: 0;
       box-shadow: 0 0 5px rgba(63,185,80,0.65);
       animation: pgLivePulse 2.5s ease-in-out infinite;
   }
   @keyframes pgLivePulse {
       0%, 100% { opacity: 1; }
       50%       { opacity: 0.5; }
   }

   .pg-deco-rows { display: flex; flex-direction: column; gap: 8px; }
   .pg-deco-row  { display: flex; align-items: center; gap: 8px; }

   .pg-deco-ico {
       width: 26px; height: 26px; border-radius: 7px;
       display: flex; align-items: center; justify-content: center;
       font-size: 12px; flex-shrink: 0; border: 1px solid transparent;
   }
   .pg-deco-ico.blue   { background:rgba(9,105,218,0.15);   border-color:rgba(9,105,218,0.25);   }
   .pg-deco-ico.purple { background:rgba(188,140,255,0.15); border-color:rgba(188,140,255,0.25); }
   .pg-deco-ico.orange { background:rgba(255,140,0,0.15);   border-color:rgba(255,140,0,0.25);   }

   .pg-deco-info { flex: 1; min-width: 0; }
   .pg-deco-name {
       font-size: 10.5px; font-weight: 700; color: #c9d1d9;
       white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
   }
   .pg-deco-time { font-size: 9.5px; color: #6e7681; margin-top: 1px; }

   .pg-deco-badge {
       font-size: 8.5px; font-weight: 700; padding: 2px 7px;
       border-radius: 8px; flex-shrink: 0;
   }
   .pg-deco-badge.green { background:rgba(63,185,80,0.1);  color:#3fb950; }
   .pg-deco-badge.blue  { background:rgba(9,105,218,0.12); color:#58a6ff; }

   /* ── Deco B: Users pill — lower right ── */
   .pg-deco-b {
       right: 3%;
       bottom: 14%;
       display: flex; align-items: center; gap: 11px;
       background: rgba(22,27,34,0.82);
       border: 1px solid rgba(48,54,61,0.85);
       border-radius: 14px;
       padding: 10px 15px 10px 11px;
       backdrop-filter: blur(14px);
       -webkit-backdrop-filter: blur(14px);
       box-shadow: 0 10px 36px rgba(0,0,0,0.45),
                   inset 0 1px 0 rgba(255,255,255,0.03);
   }
   .pg-deco-avatars { display: flex; }
   .pg-deco-av {
       width: 26px; height: 26px; border-radius: 50%;
       display: flex; align-items: center; justify-content: center;
       font-size: 9.5px; font-weight: 800; color: white;
       border: 2px solid #080e18;
       margin-right: -7px; flex-shrink: 0;
   }
   .pg-deco-avatars .pg-deco-av:last-child { margin-right: 0; }
   .pg-deco-pill-body { padding-left: 6px; }
   .pg-deco-pill-num {
       font-size: 13px; font-weight: 900; color: #e6edf3;
       letter-spacing: -0.2px; line-height: 1;
   }
   .pg-deco-pill-sub {
       font-size: 10px; color: #6e7681; margin-top: 2px;
   }

   /* Hide on screens < 1280px (not enough space) */
   @media (max-width: 1280px) {
       .pg-deco-a, .pg-deco-b { display: none; }
   }

   /* ── Responsive ── */
   @media (max-width: 920px) {
       .auth-left { display: none; }
       .arp-mobile-brand { display: flex; }
       .arp-inner { padding: 28px 16px; }
       .arp-card  { padding: 24px 20px; }
       .arp-features, .arp-deco-stats { max-width: 100%; }
   }
   @media (max-width: 480px) {
       .arp-card { border-radius: 10px; padding: 20px 16px; }
       .arp-welcome-badge { font-size: 10.5px; }
   }
   
   .form-group {
       margin-bottom: 16px;
   }
   
   .form-group label {
       display: block;
       margin-bottom: 6px;
       color: var(--text-primary);
       font-weight: 600;
       font-size: 14px;
   }
   
   .form-group input {
       width: 100%;
       height: 40px;
       padding: 0 12px;
       background: var(--bg-tertiary);
       border: 1px solid var(--border-default);
       border-radius: 6px;
       font-size: 14px;
       color: var(--text-primary);
       transition: all 0.2s;
       font-family: inherit;
   }
   
   .form-group input:focus {
       outline: none;
       border-color: var(--primary);
       background: var(--bg-primary);
       box-shadow: 0 0 0 3px rgba(9, 105, 218, 0.12);
   }
   
   .btn {
       width: 100%;
       height: 40px;
       border: none;
       border-radius: 6px;
       font-size: 14px;
       font-weight: 600;
       cursor: pointer;
       transition: all 0.2s;
       font-family: inherit;
   }
   
   .btn-primary {
       background: var(--primary);
       color: white;
   }
   
   .btn-primary:hover:not(:disabled) {
       background: var(--primary-hover);
       transform: translateY(-1px);
       box-shadow: 0 4px 12px rgba(9, 105, 218, 0.3);
   }
   
   .btn-primary:active:not(:disabled) {
       background: var(--primary-active);
       transform: translateY(0);
   }
   
   .btn:disabled {
       opacity: 0.5;
       cursor: not-allowed;
   }
   
   .btn-secondary {
       background: var(--bg-elevated);
       color: var(--text-primary);
       border: 1px solid var(--border-default);
   }
   
   .btn-secondary:hover:not(:disabled) {
       background: var(--bg-hover);
       border-color: var(--border-emphasis);
   }
   
   .divider {
       text-align: center;
       margin: 24px 0;
       position: relative;
   }
   
   .divider::before {
       content: '';
       position: absolute;
       top: 50%;
       left: 0;
       right: 0;
       height: 1px;
       background: var(--border-default);
   }
   
   .divider span {
       background: var(--bg-secondary);
       padding: 0 12px;
       position: relative;
       color: var(--text-tertiary);
       font-size: 12px;
       font-weight: 600;
       text-transform: uppercase;
   }
   
   .message {
       padding: 12px 16px;
       border-radius: 6px;
       margin-bottom: 16px;
       font-size: 14px;
       display: none;
       border: 1px solid;
   }
   
   .error-message {
       background: rgba(207, 34, 46, 0.1);
       color: var(--danger-light);
       border-color: var(--danger);
   }
   
   .success-message {
       background: rgba(31, 136, 61, 0.1);
       color: var(--success-light);
       border-color: var(--success);
   }
   
   /* Dashboard */
   .dashboard-wrapper {
       min-height: 100vh;
       padding-top: 64px;
   }
   
   .dashboard-container {
       max-width: 1280px;
       margin: 0 auto;
       padding: 24px;
   }
   
   /* Page Header */
   .page-header {
    background: var(--bg-secondary);
    border: 1px solid var(--border-default);
       border-radius: 12px;
       padding: 28px 28px 24px;
       margin-bottom: 24px;
       position: relative;
       overflow: hidden;
   }
   .page-header::before {
       content: '';
       position: absolute;
       top: 0; left: 0; right: 0;
       height: 2px;
       background: linear-gradient(90deg, var(--primary) 0%, var(--primary-light) 50%, transparent 100%);
   }
   /* subtle background glow */
   .page-header::after {
       content: '';
       position: absolute;
       top: -60px; right: -60px;
       width: 260px; height: 260px;
       border-radius: 50%;
       background: radial-gradient(circle, rgba(9,105,218,0.07) 0%, transparent 70%);
       pointer-events: none;
   }
   
   .page-header-top {
       display: flex;
       justify-content: space-between;
       align-items: flex-start;
       margin-bottom: 20px;
       padding-bottom: 20px;
       border-bottom: 1px solid var(--border-default);
   }
   
   .page-title-section h1 {
       font-size: 24px;
       font-weight: 700;
       color: var(--text-primary);
       margin-bottom: 6px;
   }
   
   .page-subtitle {
       color: var(--text-secondary);
       font-size: 14px;
   }
   
   .page-actions {
       display: flex;
       gap: 12px;
       align-items: center;
   }
   
   .btn-action {
       height: 36px;
       padding: 0 16px;
       font-size: 14px;
       font-weight: 500;
       border-radius: 6px;
       cursor: pointer;
       transition: all 0.2s;
       font-family: inherit;
       display: inline-flex;
       align-items: center;
       justify-content: center;
       white-space: nowrap;
   }
   
   .btn-new-product {
       background: var(--primary);
       color: white;
       border: none;
       box-shadow: var(--shadow-sm);
   }
   
   .btn-new-product:hover {
       background: var(--primary-hover);
       transform: translateY(-1px);
       box-shadow: 0 4px 12px rgba(9, 105, 218, 0.3);
   }
   
   .btn-new-product:active {
       background: var(--primary-active);
       transform: translateY(0);
   }
   
   .btn-sign-out {
       background: transparent;
       color: var(--text-secondary);
       border: 1px solid var(--border-default);
   }
   
   .btn-sign-out:hover {
       color: var(--text-primary);
       background: var(--bg-tertiary);
       border-color: var(--border-emphasis);
   }
   
   .btn-sign-out:active {
       background: var(--bg-elevated);
   }
   
   .user-info {
       display: flex; align-items: center; gap: 16px;
       padding: 16px 18px;
       background: var(--bg-tertiary);
       border: 1px solid var(--border-default);
       border-radius: 10px;
   }
   
   .user-info-avatar {
       width: 52px;
       height: 52px;
       border-radius: 8px;
       background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
       display: flex;
       align-items: center;
       justify-content: center;
       color: white;
       font-weight: 700;
       font-size: 20px;
       flex-shrink: 0;
       box-shadow: 0 4px 12px rgba(19, 20, 20, 0.15);
   }
   
   .user-info-details {
       flex: 1;
   }
   
   .user-info-details h3 {
       font-size: 16px;
       font-weight: 600;
       color: var(--text-primary);
       margin-bottom: 4px;
   }
   
   .user-info-details p {
       font-size: 14px;
       color: var(--text-secondary);
       margin-bottom: 6px;
   }
   
   .verified-badge {
       display: inline-flex; align-items: center; gap: 4px;
       padding: 3px 10px;
       background: rgba(31, 136, 61, 0.12);
       color: #3fb950;
       border: 1px solid rgba(31, 136, 61, 0.2);
       border-radius: 20px;
       font-size: 12px; font-weight: 700;
   }
   
   /* Stats Grid */
   .stats-grid {
       display: grid;
       grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
       gap: 16px;
       margin-bottom: 24px;
   }
   
   .stat-card {
       background: var(--bg-secondary);
       border: 1px solid var(--border-default);
       border-radius: 12px;
       padding: 22px;
       transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
       position: relative;
       overflow: hidden;
   }
   .stat-card::before {
       content: '';
       position: absolute;
       top: 0; left: 0; right: 0;
       height: 3px;
       background: linear-gradient(90deg, transparent 0%, var(--primary) 50%, transparent 100%);
       opacity: 0;
       transition: opacity 0.25s;
   }
   .stat-card:hover {
       border-color: rgba(9,105,218,0.4);
       transform: translateY(-4px);
       box-shadow: 0 8px 24px rgba(9,105,218,0.12), var(--shadow-lg);
   }
   .stat-card:hover::before { opacity: 1; }
   
   .stat-header {
       display: flex;
       justify-content: space-between;
       align-items: flex-start;
       margin-bottom: 16px;
   }
   
   .stat-icon {
       width: 50px; height: 50px;
       border-radius: 10px;
       display: flex; align-items: center; justify-content: center;
       font-size: 24px; transition: transform 0.3s;
       border: 1px solid rgba(255,255,255,0.05);
   }
   
   .stat-card:hover .stat-icon {
       transform: scale(1.1) rotate(5deg);
   }
   
   .stat-icon.blue {
       background: rgba(9, 105, 218, 0.15);
       color: var(--primary-light);
   }
   
   .stat-icon.green {
       background: rgba(31, 136, 61, 0.15);
       color: var(--success-light);
   }
   
   .stat-icon.yellow {
       background: rgba(191, 135, 0, 0.15);
       color: var(--warning-light);
   }
   
   .stat-icon.red {
       background: rgba(207, 34, 46, 0.15);
       color: var(--danger-light);
   }
   
   .stat-label {
       color: var(--text-secondary);
       font-size: 14px;
       font-weight: 500;
       margin-bottom: 8px;
   }
   
   .stat-value {
       font-size: 32px;
       font-weight: 700;
       color: var(--text-primary);
       line-height: 1;
   }
   
   .stat-change {
       display: inline-flex;
       align-items: center;
       gap: 4px;
       font-size: 13px;
       font-weight: 500;
       margin-top: 8px;
   }
   
   .stat-change.positive {
       color: var(--success-light);
   }
   
   .stat-change.negative {
       color: var(--danger-light);
   }
   
   .stat-change.neutral {
       color: var(--text-secondary);
   }
   
   /* Section Container */
   .section {
       background: var(--bg-secondary);
       border: 1px solid var(--border-default);
       border-radius: 12px;
       margin-bottom: 24px;
       animation: fadeIn 0.4s ease;
       overflow: hidden;
   }
   
   @keyframes fadeIn {
       from { opacity: 0; transform: translateY(10px); }
       to { opacity: 1; transform: translateY(0); }
   }
   
   .section-header {
       display: flex;
       justify-content: space-between;
       align-items: center;
       padding: 20px 24px;
       border-bottom: 1px solid var(--border-default);
   }
   
   .section-title {
       font-size: 18px;
       font-weight: 600;
       color: var(--text-primary);
   }
   
   .section-body {
       padding: 24px;
   }
   
   /* Quick Actions */
   .actions-grid {
       display: grid;
       grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
       gap: 16px;
   }
   
   .action-card {
       background: var(--bg-tertiary);
       border: 1px solid var(--border-default);
       padding: 20px;
       border-radius: 12px;
       cursor: pointer;
       transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
       display: flex; align-items: center; gap: 16px;
   }
   .action-card:hover {
       background: var(--bg-elevated);
       border-color: rgba(9,105,218,0.3);
       transform: translateY(-2px);
       box-shadow: 0 6px 18px rgba(9,105,218,0.1);
   }
   
   .action-icon {
       width: 48px;
       height: 48px;
       background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
       border-radius: 8px;
       display: flex;
       align-items: center;
       justify-content: center;
       font-size: 24px;
       color: white;
       flex-shrink: 0;
       box-shadow: 0 4px 12px rgba(9, 105, 218, 0.3);
   }
   
   .action-content h4 {
       font-size: 15px;
       font-weight: 600;
       color: var(--text-primary);
       margin-bottom: 4px;
   }
   
   .action-content p {
       font-size: 13px;
       color: var(--text-secondary);
   }
   
   /* Filter Buttons */
   .filter-group {
       display: flex;
       gap: 8px;
       flex-wrap: wrap;
   }
   
   .filter-btn {
       height: 30px;
       padding: 0 16px;
       background: transparent;
       border: 1px solid var(--border-default);
       border-radius: 20px;
       cursor: pointer;
       color: var(--text-secondary);
       font-size: 13px; font-weight: 600;
       transition: all 0.2s; font-family: inherit;
   }
   .filter-btn:hover {
       background: var(--bg-hover);
       color: var(--text-primary);
       border-color: var(--border-emphasis);
   }
   .filter-btn.active {
       background: var(--primary);
       color: white; border-color: var(--primary);
       box-shadow: 0 2px 10px rgba(9,105,218,0.3);
   }
   
   /* Products Grid */
   .products-grid {
       display: grid;
       grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
       gap: 16px;
   }
   
   .product-card {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: 8px;
    padding: 20px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-card:hover {
    border-color: var(--border-emphasis);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.product-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.product-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.product-type {
    display: inline-block;
    background: var(--bg-elevated);
    color: var(--text-secondary);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

.status-active {
    background: rgba(31, 136, 61, 0.15);
    color: var(--success-light);
}
.status-expiring {
       background: rgba(191,135,0,0.12);
       color: #d29922;
       border-color: rgba(191,135,0,0.2);
   }
   .status-expired {
       background: rgba(207,34,46,0.12);
       color: #f85149;
       border-color: rgba(207,34,46,0.2);
   }
   
   .product-details {
       margin: 16px 0;
   }
   
   .detail-row {
       display: flex;
       justify-content: space-between;
       padding: 10px 0;
       border-bottom: 1px solid var(--border-muted);
       font-size: 14px;
   }
   
   .detail-row:last-child {
       border-bottom: none;
   }
   
   .detail-label {
       color: var(--text-secondary);
       font-weight: 500;
   }
   
   .detail-value {
       color: var(--text-primary);
       font-weight: 600;
   }
   
   .license-box {
       background: var(--bg-elevated);
       border: 1px solid var(--border-default);
       border-radius: 6px;
       padding: 12px;
       margin: 16px 0;
   }
   
   .license-label {
       color: var(--text-secondary);
       font-size: 12px;
       font-weight: 600;
       margin-bottom: 8px;
       text-transform: uppercase;
       letter-spacing: 0.5px;
       display: flex;
       justify-content: space-between;
       align-items: center;
   }
   
   .license-code {
       display: flex;
       justify-content: flex-start;
       align-items: center;
       gap: 8px;
   }
   
   .license-text {
       font-family: var(--font-mono);
       font-size: 14px;
       font-weight: 600;
       color: var(--primary-light);
   }
   
   .copy-btn {
       background: transparent;
       color: var(--text-secondary);
       border: none;
       padding: 4px;
       border-radius: 4px;
       cursor: pointer;
       font-size: 18px;
       transition: all 0.2s;
       font-family: inherit;
       width: auto;
       height: auto;
       display: inline-flex;
       align-items: center;
       justify-content: center;
       margin-right: 4px;
   }

   body.rtl .copy-btn {
       margin-right: 0;
       margin-left: 4px;
   }
   
   .copy-btn:hover {
       color: var(--primary);
       transform: scale(1.15);
   }
   
   .copy-btn.copied {
       color: var(--success);
       animation: checkPulse 0.6s ease;
   }

   @keyframes checkPulse {
       0%, 100% { transform: scale(1); }
       50% { transform: scale(1.2); }
   }
   
   .btn-renew {
       width: 100%;
       height: 36px;
       background: var(--primary);
       color: white;
       border: none;
       border-radius: 6px;
       font-weight: 600;
       cursor: pointer;
       transition: all 0.2s;
       margin-top: 16px;
       font-family: inherit;
       font-size: 14px;
   }
   
   .btn-renew:hover {
       background: var(--primary-hover);
       transform: translateY(-1px);
       box-shadow: 0 4px 12px rgba(9, 105, 218, 0.3);
   }
   
   .empty-state {
       text-align: center;
       padding: 64px 20px;
       grid-column: 1/-1;
   }
   
   .empty-icon {
       font-size: 48px;
       margin-bottom: 16px;
       opacity: 0.4;
   }
   
   .empty-state h3 {
       font-size: 18px;
       font-weight: 600;
       color: var(--text-primary);
       margin-bottom: 8px;
   }
   
   .empty-state p {
       color: var(--text-secondary);
       font-size: 14px;
   }
   
   /* Progress Bar */
   .progress-container {
       margin-top: 8px;
   }
   
   .progress-bar {
       height: 6px;
       background: var(--bg-elevated);
       border-radius: 3px;
       overflow: hidden;
   }
   
   .progress-fill {
       height: 100%;
       background: linear-gradient(90deg, var(--primary) 0%, var(--primary-light) 100%);
       border-radius: 3px;
       transition: width 0.3s ease;
   }
   
   .progress-text {
       font-size: 12px;
       color: var(--text-secondary);
       margin-top: 6px;
       font-weight: 500;
   }
   
   /* Utilities */
   .hidden {
       display: none !important;
   }
   
   .loading {
       display: inline-block;
       width: 14px;
       height: 14px;
       border: 2px solid rgba(230, 237, 243, 0.3);
       border-radius: 50%;
       border-top-color: white;
       animation: spin 0.6s linear infinite;
   }
   
   @keyframes spin {
       to { transform: rotate(360deg); }
   }
   
   /* ══════════════════════════════════════
      Toast Notifications — v2
      Matches the notification panel design
      ══════════════════════════════════════ */
   .toast-container {
       position: fixed;
       top: 72px; right: 18px;
       z-index: 10000;
       pointer-events: none;
       display: flex; flex-direction: column; gap: 9px;
   }

   @keyframes toastIn {
       from { transform: translateX(calc(100% + 20px)) scale(0.96); opacity: 0; }
       to   { transform: translateX(0) scale(1); opacity: 1; }
   }
   @keyframes toastOut {
       from { transform: translateX(0) scale(1); opacity: 1; max-height: 100px; margin: 0; }
       to   { transform: translateX(calc(100% + 20px)) scale(0.96); opacity: 0; max-height: 0; margin: 0; }
   }

   .toast {
       /* Same card style as notification panel */
       background: #161b22;
       border: 1px solid #30363d;
       border-radius: 12px;
       padding: 0;
       min-width: 300px; max-width: 360px;
       box-shadow: 0 12px 40px rgba(0,0,0,0.55), 0 0 0 1px rgba(255,255,255,0.02);
       pointer-events: auto;
       animation: toastIn 0.28s cubic-bezier(0.34,1.26,0.64,1) forwards;
       display: flex; flex-direction: column;
       overflow: hidden; position: relative;
   }
   .toast.removing {
       animation: toastOut 0.25s ease-in forwards;
   }

   /* Inner layout — matches notification-item */
   .toast-inner {
       display: flex; align-items: flex-start; gap: 11px;
       padding: 13px 14px 13px 0;
       position: relative;
   }

   /* Left accent bar — matches unread notification bar */
   .toast-accent {
       width: 3px; flex-shrink: 0; align-self: stretch;
       border-radius: 0 2px 2px 0;
   }
   .toast.success .toast-accent { background: #3fb950; }
   .toast.error   .toast-accent { background: #f85149; }
   .toast.warning .toast-accent { background: #d29922; }
   .toast.info    .toast-accent { background: #58a6ff; }

   /* Icon box — matches notification-icon style */
   .toast-icon {
       width: 34px; height: 34px; flex-shrink: 0;
       border-radius: 9px;
       display: flex; align-items: center; justify-content: center;
       border: 1px solid transparent;
   }
   .toast.success .toast-icon { background: rgba(63,185,80,0.12);   border-color: rgba(63,185,80,0.22);   color: #3fb950; }
   .toast.error   .toast-icon { background: rgba(248,81,73,0.12);   border-color: rgba(248,81,73,0.22);   color: #f85149; }
   .toast.warning .toast-icon { background: rgba(210,153,34,0.12);  border-color: rgba(210,153,34,0.22);  color: #d29922; }
   .toast.info    .toast-icon { background: rgba(88,166,255,0.12);  border-color: rgba(88,166,255,0.22);  color: #58a6ff; }

   /* Content */
   .toast-content { flex: 1; min-width: 0; }
   .toast-title {
       font-size: 13px; font-weight: 700; color: #e6edf3;
       margin-bottom: 2px;
       white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
   }
   .toast-message {
       font-size: 12px; color: #8b949e; line-height: 1.4;
       display: -webkit-box;
       -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
   }

   /* Close button */
   .toast-close {
       background: none; border: none;
       color: #6e7681; cursor: pointer;
       width: 26px; height: 26px; flex-shrink: 0;
       display: flex; align-items: center; justify-content: center;
       border-radius: 7px; padding: 0; margin-top: 1px;
       transition: background 0.15s, color 0.15s;
   }
   .toast-close:hover { background: #21262d; color: #e6edf3; }

   /* Progress bar at bottom — shows time remaining */
   .toast-progress {
       height: 2px; width: 100%;
       background: #21262d;
       position: absolute; bottom: 0; left: 0;
   }
   .toast-progress-bar {
       height: 100%; width: 100%;
       border-radius: 0 0 12px 12px;
       transition: width linear;
   }
   .toast.success .toast-progress-bar { background: #3fb950; }
   .toast.error   .toast-progress-bar { background: #f85149; }
   .toast.warning .toast-progress-bar { background: #d29922; }
   .toast.info    .toast-progress-bar { background: #58a6ff; }
   
   /* Responsive */
   @media (max-width: 768px) {
       .header-container {
           padding: 0 16px;
       }
   
       .nav-links {
           display: none;
       }
   
       .search-container {
           width: 200px;
       }
   
       .user-name {
           display: none;
       }
   
       .dashboard-container {
           padding: 16px;
       }
   
       .page-header {
           padding: 16px;
       }
   
       .page-header-top {
           flex-direction: column;
           gap: 16px;
       }
   
       .page-actions {
           width: 100%;
       }
   
       .btn-action {
           flex: 1;
       }
   
       .stats-grid {
           grid-template-columns: repeat(2, 1fr);
       }
   
       .products-grid {
           grid-template-columns: 1fr;
       }
   
       .section-header {
           padding: 16px;
       }
   
       .section-body {
           padding: 16px;
       }
   
       .auth-container {
           padding: 32px 24px;
       }
   
       .notifications-dropdown {
           width: calc(100vw - 40px);
           right: -120px;
       }
   
       .toast-container {
           right: 10px;
           left: 10px;
       }
   
       .toast {
           min-width: auto;
           max-width: none;
       }
   }
   /* ========================================
      ⚙️ Settings Page Styles
      ======================================== */
   
      .settings-container {
       display: grid;
       grid-template-columns: 1fr;
       gap: 24px;
       max-width: 800px;
       margin: 0 auto;
   }
   
   .settings-card {
       background: var(--bg-secondary);
       border: 1px solid var(--border-default);
       border-radius: 8px;
       overflow: hidden;
       animation: fadeIn 0.4s ease;
   }
   
   .settings-card-header {
       padding: 20px 24px;
       border-bottom: 1px solid var(--border-default);
       background: var(--bg-tertiary);
   }
   
   .settings-card-header h3 {
       font-size: 18px;
       font-weight: 600;
       color: var(--text-primary);
       margin: 0;
   }
   
   .settings-card-body {
       padding: 24px;
   }
   
   /* Profile Photo Section */
   .profile-photo-section {
       margin-bottom: 32px;
   }
   
   .profile-photo-container {
       display: flex;
       align-items: center;
       gap: 24px;
   }
   
   .profile-photo {
       width: 120px;
       height: 120px;
       border-radius: 50%;
       background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
       display: flex;
       align-items: center;
       justify-content: center;
       overflow: hidden;
       box-shadow: 0 4px 12px rgba(9, 105, 218, 0.3);
       flex-shrink: 0;
   }
   
   .profile-photo-placeholder {
       font-size: 48px;
       font-weight: 700;
       color: white;
   }
   
   .profile-photo-actions {
       display: flex;
       flex-direction: column;
       gap: 12px;
       flex: 1;
   }
   
   .profile-photo-actions .btn {
       width: 100%;
       max-width: 200px;
   }
   
   /* Info Grid */
   .info-grid {
       display: grid;
       grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
       gap: 20px;
   }
   
   .info-item {
       padding: 16px;
       background: var(--bg-tertiary);
       border: 1px solid var(--border-default);
       border-radius: 6px;
   }
   
   .info-label {
       font-size: 12px;
       font-weight: 600;
       color: var(--text-secondary);
       text-transform: uppercase;
       letter-spacing: 0.5px;
       margin-bottom: 8px;
   }
   
   .info-value {
       font-size: 14px;
       font-weight: 600;
       color: var(--text-primary);
   }
   
   /* Button Styles for Settings */
   .btn-danger {
       background: var(--danger);
       color: white;
       border: none;
   }
   
   .btn-danger:hover:not(:disabled) {
       background: var(--danger-light);
       transform: translateY(-1px);
       box-shadow: 0 4px 12px rgba(207, 34, 46, 0.3);
   }
   
   .btn-danger:active:not(:disabled) {
       background: #b31d28;
       transform: translateY(0);
   }
   
   /* Responsive */
   @media (max-width: 768px) {
       .settings-container {
           padding: 0;
       }
   
       .profile-photo-container {
           flex-direction: column;
           align-items: flex-start;
       }
   
       .profile-photo {
           width: 100px;
           height: 100px;
       }
   
       .profile-photo-placeholder {
           font-size: 40px;
       }
   
       .profile-photo-actions .btn {
           max-width: 100%;
       }
   
       .info-grid {
           grid-template-columns: 1fr;
       }
   
       .settings-card-header,
       .settings-card-body {
           padding: 16px;
       }
   }
   
   /* RTL Support */
   body.rtl .profile-photo-container {
       direction: ltr;
   }
   
   body.rtl .profile-photo-actions {
       direction: rtl;
   }
   
   /* ==========================================
      🎨 NEW STYLES FOR DASHBOARD v4.3
      ========================================== */
   
   /* ==========================================
      1️⃣ Enhanced Language Switcher
      ========================================== */
   
      .language-switcher {
       position: relative;
   }
   
   .language-btn {
       display: flex;
       align-items: center;
       gap: 8px;
       padding: 8px 12px;
       background: var(--bg-secondary);
       border: 1px solid var(--border-default);
       border-radius: 8px;
       color: var(--text-primary);
       font-size: 14px;
       font-weight: 500;
       cursor: pointer;
       transition: all 0.2s ease;
   }
   
   .language-btn:hover {
       background: var(--bg-hover);
       border-color: var(--border-emphasis);
   }
   
   .language-btn.active {
       background: var(--bg-hover);
       border-color: var(--primary);
   }
   
   .language-icon {
       font-size: 18px;
   }
   
   .language-dropdown {
       position: absolute;
       top: calc(100% + 8px);
       right: 0;
       min-width: 180px;
       background: var(--bg-elevated);
       border: 1px solid var(--border-default);
       border-radius: 12px;
       box-shadow: var(--shadow-xl);
       padding: 8px;
       opacity: 0;
       visibility: hidden;
       transform: translateY(-10px);
       transition: all 0.2s ease;
       z-index: 1000;
   }
   
   .language-dropdown.show {
       opacity: 1;
       visibility: visible;
       transform: translateY(0);
   }
   
   .language-option {
       display: flex;
       align-items: center;
       gap: 12px;
       padding: 10px 12px;
       border-radius: 8px;
       color: var(--text-primary);
       font-size: 14px;
       font-weight: 500;
       cursor: pointer;
       transition: all 0.2s ease;
   }
   
   .language-option:hover {
       background: var(--bg-hover);
   }
   
   .language-option.active {
       background: rgba(37, 99, 235, 0.15);
       color: var(--primary-light);
   }
   
   .language-option-flag {
       font-size: 20px;
   }
   
   .language-option-text {
       flex: 1;
   }
   
   .language-option-check {
       font-size: 16px;
       color: var(--primary-light);
       opacity: 0;
       transition: opacity 0.2s ease;
   }
   
   .language-option.active .language-option-check {
       opacity: 1;
   }
   
   /* ==========================================
      2️⃣ Back Button
      ========================================== */
   
   .back-btn {
       display: inline-flex;
       align-items: center;
       gap: 8px;
       padding: 8px 16px;
       background: var(--bg-secondary);
       border: 1px solid var(--border-default);
       border-radius: 8px;
       color: var(--text-primary);
       font-size: 14px;
       font-weight: 500;
       cursor: pointer;
       transition: all 0.2s ease;
       margin-bottom: 24px;
   }
   
   .back-btn:hover {
       background: var(--bg-hover);
       border-color: var(--border-emphasis);
       transform: translateX(-4px);
   }
   
   .back-btn svg {
       transition: transform 0.2s ease;
   }
   
   .back-btn:hover svg {
       transform: translateX(-2px);
   }
   
   /* ==========================================
      3️⃣ Invoices Page
      ========================================== */
   
   .invoices-grid {
       display: grid;
       grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
       gap: 24px;
   }
   
   .invoice-card {
       background: var(--bg-secondary);
       border: 1px solid var(--border-default);
       border-radius: 12px;
       padding: 24px;
       transition: all 0.3s ease;
   }
   
   .invoice-card:hover {
       border-color: var(--border-emphasis);
       box-shadow: var(--shadow-lg);
       transform: translateY(-2px);
   }
   
   .invoice-header {
       display: flex;
       justify-content: space-between;
       align-items: flex-start;
       margin-bottom: 20px;
       padding-bottom: 16px;
       border-bottom: 1px solid var(--border-muted);
   }
   
   .invoice-info {
       flex: 1;
   }
   
   .invoice-number {
       font-size: 12px;
       font-weight: 600;
       color: var(--text-secondary);
       letter-spacing: 0.5px;
       margin-bottom: 8px;
   }
   
   .invoice-product-name {
       font-size: 18px;
       font-weight: 700;
       color: var(--text-primary);
       margin-bottom: 4px;
   }
   
   .invoice-type {
       font-size: 13px;
       color: var(--text-secondary);
   }
   
   .invoice-amount {
       font-size: 24px;
       font-weight: 700;
       color: var(--primary-light);
   }
   
   .invoice-details {
       display: flex;
       flex-direction: column;
       gap: 12px;
       margin-bottom: 20px;
   }
   
   .invoice-detail-item {
       display: flex;
       justify-content: space-between;
       align-items: center;
   }
   
   .invoice-detail-label {
       font-size: 13px;
       color: var(--text-secondary);
   }
   
   .invoice-detail-value {
       font-size: 14px;
       font-weight: 500;
       color: var(--text-primary);
   }
   
   .invoice-delivery-data {
       background: var(--bg-tertiary);
       border: 1px solid var(--border-muted);
       border-radius: 8px;
       padding: 16px;
       margin-bottom: 20px;
   }
   
   .delivery-code {
       display: block;
       padding: 12px;
       background: var(--bg-primary);
       border: 1px solid var(--border-default);
       border-radius: 6px;
       font-family: 'Monaco', 'Courier New', monospace;
       font-size: 13px;
       color: var(--primary-light);
       word-break: break-all;
       white-space: pre-wrap;
       margin: 8px 0;
   }
   
   .btn-copy-inline {
       padding: 6px 12px;
       background: var(--bg-secondary);
       border: 1px solid var(--border-default);
       border-radius: 6px;
       color: var(--text-primary);
       font-size: 12px;
       cursor: pointer;
       transition: all 0.2s ease;
   }
   
   .btn-copy-inline:hover {
       background: var(--bg-hover);
       border-color: var(--primary);
       color: var(--primary-light);
   }
   
   .invoice-actions {
       display: flex;
       gap: 8px;
       flex-wrap: wrap;
   }
   
   .btn-invoice-action {
       flex: 1;
       min-width: 100px;
       padding: 10px 16px;
       background: var(--bg-tertiary);
       border: 1px solid var(--border-default);
       border-radius: 8px;
       color: var(--text-primary);
       font-size: 13px;
       font-weight: 500;
       cursor: pointer;
       transition: all 0.2s ease;
       text-align: center;
   }
   
   .btn-invoice-action:hover {
       background: var(--bg-hover);
       border-color: var(--primary);
       color: var(--primary-light);
       transform: translateY(-1px);
   }
   
   /* ==========================================
      4️⃣ Invoice Details Modal
      ========================================== */
   
   .invoice-details-content {
       padding: 24px;
       max-height: 70vh;
       overflow-y: auto;
   }
   
   .invoice-details-header {
       display: flex;
       justify-content: space-between;
       align-items: flex-start;
       margin-bottom: 32px;
       padding-bottom: 20px;
       border-bottom: 2px solid var(--primary);
   }
   
   .company-info h2 {
       font-size: 28px;
       color: var(--primary-light);
       margin-bottom: 4px;
   }
   
   .company-info p {
       font-size: 14px;
       color: var(--text-secondary);
   }
   
   .invoice-meta {
       text-align: right;
   }
   
   .invoice-number-large {
       font-size: 32px;
       font-weight: 700;
       color: var(--primary-light);
       margin-bottom: 8px;
   }
   
   .invoice-date {
       font-size: 14px;
       color: var(--text-secondary);
   }
   
   .invoice-section {
       margin-bottom: 32px;
   }
   
   .invoice-section h4 {
       font-size: 16px;
       font-weight: 600;
       color: var(--text-primary);
       margin-bottom: 12px;
   }
   
   .customer-info {
       background: var(--bg-tertiary);
       border: 1px solid var(--border-default);
       border-radius: 8px;
       padding: 16px;
   }
   
   .customer-info div {
       padding: 4px 0;
       font-size: 14px;
       color: var(--text-primary);
   }
   
   .invoice-table {
       width: 100%;
       border-collapse: collapse;
       margin: 20px 0;
   }
   
   .invoice-table th,
   .invoice-table td {
       padding: 12px;
       text-align: left;
       border-bottom: 1px solid var(--border-default);
       font-size: 14px;
   }
   
   .invoice-table th {
       background: var(--bg-tertiary);
       font-weight: 600;
       color: var(--text-secondary);
   }
   
   .invoice-table td {
       color: var(--text-primary);
   }
   
   .delivery-box {
       background: var(--bg-tertiary);
       border: 1px solid var(--border-default);
       border-radius: 8px;
       padding: 16px;
   }
   
   .delivery-box code {
       display: block;
       padding: 12px;
       background: var(--bg-primary);
       border: 1px solid var(--border-default);
       border-radius: 6px;
       font-family: 'Monaco', 'Courier New', monospace;
       font-size: 13px;
       color: var(--primary-light);
       white-space: pre-wrap;
       word-break: break-all;
       margin-bottom: 12px;
   }
   
   .invoice-totals {
       max-width: 350px;
       margin-left: auto;
       margin-top: 32px;
       padding: 20px;
       background: var(--bg-tertiary);
       border: 1px solid var(--border-default);
       border-radius: 8px;
   }
   
   .total-row {
       display: flex;
       justify-content: space-between;
       padding: 8px 0;
       font-size: 14px;
       color: var(--text-primary);
   }
   
   .total-row.final {
       border-top: 2px solid var(--border-emphasis);
       margin-top: 12px;
       padding-top: 12px;
       font-size: 18px;
       font-weight: 700;
       color: var(--primary-light);
   }
   
   .paid-badge {
       margin-top: 16px;
       padding: 10px;
       background: rgba(34, 197, 94, 0.15);
       border: 1px solid rgba(34, 197, 94, 0.3);
       border-radius: 6px;
       text-align: center;
       font-weight: 600;
       color: var(--success-light);
   }
   
   .invoice-footer {
       margin-top: 40px;
       padding-top: 20px;
       border-top: 1px solid var(--border-default);
       text-align: center;
   }
   
   .invoice-footer p {
       font-size: 16px;
       color: var(--text-secondary);
       font-style: italic;
   }
   
   /* ==========================================
      5️⃣ Responsive Design
      ========================================== */
   
   @media (max-width: 768px) {
       .invoices-grid {
           grid-template-columns: 1fr;
       }
       
       .invoice-actions {
           flex-direction: column;
       }
       
       .btn-invoice-action {
           width: 100%;
       }
       
       .invoice-details-header {
           flex-direction: column;
           gap: 20px;
       }
       
       .invoice-meta {
           text-align: left;
       }
       
       .invoice-totals {
           margin-left: 0;
           margin-right: 0;
       }
       
       .language-dropdown {
           right: auto;
           left: 0;
       }
   }
   
   /* ==========================================
      6️⃣ RTL Support
      ========================================== */
   
   [dir="rtl"] .back-btn svg {
       transform: scaleX(-1);
   }
   
   [dir="rtl"] .back-btn:hover {
       transform: translateX(4px);
   }
   
   [dir="rtl"] .back-btn:hover svg {
       transform: scaleX(-1) translateX(2px);
   }
   
   [dir="rtl"] .language-dropdown {
       right: auto;
       left: 0;
   }
   
   [dir="rtl"] .invoice-table th,
   [dir="rtl"] .invoice-table td {
       text-align: right;
   }
   
   [dir="rtl"] .invoice-totals {
       margin-left: 0;
       margin-right: auto;
   }
   
   /* ==========================================
      7️⃣ Print Styles
      ========================================== */
   
   @media print {
       .back-btn,
       .invoice-actions,
       .modal-actions {
           display: none !important;
       }
       
       .invoice-details-content {
           max-height: none;
           overflow: visible;
       }
   }
   
   /* ==========================================
      8️⃣ Animations
      ========================================== */
   
   @keyframes slideInUp {
       from {
           opacity: 0;
           transform: translateY(20px);
       }
       to {
           opacity: 1;
           transform: translateY(0);
       }
   }
   
   .invoice-card {
       animation: slideInUp 0.3s ease;
   }
   
   .invoice-card:nth-child(1) { animation-delay: 0.05s; }
   .invoice-card:nth-child(2) { animation-delay: 0.1s; }
   .invoice-card:nth-child(3) { animation-delay: 0.15s; }
   .invoice-card:nth-child(4) { animation-delay: 0.2s; }
   .invoice-card:nth-child(5) { animation-delay: 0.25s; }
   .invoice-card:nth-child(6) { animation-delay: 0.3s; }
   
   .modal {
       position: fixed;
       top: 0;
       left: 0;
       width: 100%;
       height: 100%;
       z-index: 9999;
       display: flex;
       align-items: center;
       justify-content: center;
       opacity: 0;
       visibility: hidden;
       transition: all 0.3s ease;
       pointer-events: none;
   }
   
   .modal.active {
       opacity: 1;
       visibility: visible;
       pointer-events: all;
   }
   
   .modal-overlay {
       position: absolute;
       top: 0;
       left: 0;
       width: 100%;
       height: 100%;
       background: rgba(0, 0, 0, 0.75);
       backdrop-filter: blur(8px);
       -webkit-backdrop-filter: blur(8px);
       z-index: 1;
       cursor: pointer;
   }
   
   .modal-content {
       position: relative;
       background: var(--bg-secondary, #161b22);
       border: 1px solid var(--border-default, #30363d);
       border-radius: 16px;
       box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
       max-width: 600px;
       width: 90%;
       max-height: 90vh;
       overflow: hidden;
       z-index: 2;
       transform: scale(0.9) translateY(20px);
       transition: transform 0.3s ease;
       display: flex;
       flex-direction: column;
   }
   
   .modal.active .modal-content {
       transform: scale(1) translateY(0);
   }
   
   .modal-content.large {
       max-width: 1000px;
   }
   
   /* Modal Header */
   .modal-header {
       display: flex;
       justify-content: space-between;
       align-items: center;
       padding: 24px;
       border-bottom: 1px solid var(--border-default, #30363d);
       flex-shrink: 0;
   }
   
   .modal-header h3,
   .modal-title {
       font-size: 20px;
       font-weight: 700;
       color: var(--text-primary, #e6edf3);
       margin: 0;
   }
   
   .modal-close {
       width: 36px;
       height: 36px;
       display: flex;
       align-items: center;
       justify-content: center;
       background: var(--bg-tertiary, #1c2128);
       border: 1px solid var(--border-default, #30363d);
       border-radius: 8px;
       color: var(--text-secondary, #8b949e);
       font-size: 20px;
       font-weight: 700;
       cursor: pointer;
       transition: all 0.2s ease;
       flex-shrink: 0;
   }
   
   .modal-close:hover {
       background: var(--bg-hover, #2d333b);
       color: var(--danger-light, #e5534b);
       border-color: var(--danger-light, #e5534b);
       transform: scale(1.1);
   }
   
   /* Modal Body/Content */
   .modal-body {
       padding: 24px;
       overflow-y: auto;
       flex: 1;
   }
   
   .invoice-details-content {
       padding: 24px;
       max-height: calc(90vh - 180px);
       overflow-y: auto;
   }
   
   /* Custom Scrollbar */
   .modal-body::-webkit-scrollbar,
   .invoice-details-content::-webkit-scrollbar {
       width: 8px;
   }
   
   .modal-body::-webkit-scrollbar-track,
   .invoice-details-content::-webkit-scrollbar-track {
       background: var(--bg-tertiary, #1c2128);
       border-radius: 4px;
   }
   
   .modal-body::-webkit-scrollbar-thumb,
   .invoice-details-content::-webkit-scrollbar-thumb {
       background: var(--border-emphasis, #444c56);
       border-radius: 4px;
   }
   
   .modal-body::-webkit-scrollbar-thumb:hover,
   .invoice-details-content::-webkit-scrollbar-thumb:hover {
       background: var(--primary, #0969da);
   }
   
   /* Modal Actions/Footer */
   .modal-actions {
       display: flex;
       gap: 12px;
       padding: 20px 24px;
       border-top: 1px solid var(--border-default, #30363d);
       background: var(--bg-tertiary, #1c2128);
       flex-shrink: 0;
   }
   
   .modal-actions button {
       flex: 1;
       padding: 12px 20px;
       border-radius: 8px;
       font-size: 14px;
       font-weight: 600;
       cursor: pointer;
       transition: all 0.2s ease;
       border: 1px solid transparent;
   }
   
   .modal-actions .btn-primary {
       background: var(--primary, #0969da);
       color: white;
       border-color: var(--primary, #0969da);
   }
   
   .modal-actions .btn-primary:hover {
       background: var(--primary-hover, #0860ca);
       transform: translateY(-1px);
       box-shadow: 0 4px 12px rgba(9, 105, 218, 0.3);
   }
   
   .modal-actions .btn-secondary {
       background: var(--bg-secondary, #161b22);
       color: var(--text-primary, #e6edf3);
       border-color: var(--border-default, #30363d);
   }
   
   .modal-actions .btn-secondary:hover {
       background: var(--bg-hover, #2d333b);
       border-color: var(--border-emphasis, #444c56);
   }
   
   /* Invoice Details Specific */
   .invoice-details-header {
       display: flex;
       justify-content: space-between;
       align-items: flex-start;
       margin-bottom: 32px;
       padding-bottom: 20px;
       border-bottom: 2px solid var(--primary, #0969da);
   }
   
   .company-info h2 {
       font-size: 28px;
       color: var(--primary-light, #1f6feb);
       margin-bottom: 4px;
   }
   
   .company-info p {
       font-size: 14px;
       color: var(--text-secondary, #8b949e);
   }
   
   .invoice-meta {
       text-align: right;
   }
   
   .invoice-number-large {
       font-size: 32px;
       font-weight: 700;
       color: var(--primary-light, #1f6feb);
       margin-bottom: 8px;
   }
   
   .invoice-date {
       font-size: 14px;
       color: var(--text-secondary, #8b949e);
   }
   
   .invoice-section {
       margin-bottom: 32px;
   }
   
   .invoice-section h4 {
       font-size: 16px;
       font-weight: 600;
       color: var(--text-primary, #e6edf3);
       margin-bottom: 12px;
   }
   
   .customer-info {
       background: var(--bg-tertiary, #1c2128);
       border: 1px solid var(--border-default, #30363d);
       border-radius: 8px;
       padding: 16px;
   }
   
   .customer-info div {
       padding: 4px 0;
       font-size: 14px;
       color: var(--text-primary, #e6edf3);
   }
   
   .invoice-table {
       width: 100%;
       border-collapse: collapse;
       margin: 20px 0;
   }
   
   .invoice-table th,
   .invoice-table td {
       padding: 12px;
       text-align: left;
       border-bottom: 1px solid var(--border-default, #30363d);
       font-size: 14px;
   }
   
   .invoice-table th {
       background: var(--bg-tertiary, #1c2128);
       font-weight: 600;
       color: var(--text-secondary, #8b949e);
   }
   
   .invoice-table td {
       color: var(--text-primary, #e6edf3);
   }
   
   .delivery-box {
       background: var(--bg-tertiary, #1c2128);
       border: 1px solid var(--border-default, #30363d);
       border-radius: 8px;
       padding: 16px;
   }
   
   .delivery-box code {
       display: block;
       padding: 12px;
       background: var(--bg-primary, #0d1117);
       border: 1px solid var(--border-default, #30363d);
       border-radius: 6px;
       font-family: 'Monaco', 'Courier New', monospace;
       font-size: 13px;
       color: var(--primary-light, #1f6feb);
       white-space: pre-wrap;
       word-break: break-all;
       margin-bottom: 12px;
   }
   
   .btn-copy-inline {
       padding: 8px 12px;
       background: var(--bg-secondary, #161b22);
       border: 1px solid var(--border-default, #30363d);
       border-radius: 6px;
       color: var(--text-primary, #e6edf3);
       font-size: 13px;
       cursor: pointer;
       transition: all 0.2s ease;
   }
   
   .btn-copy-inline:hover {
       background: var(--bg-hover, #2d333b);
       border-color: var(--primary, #0969da);
       color: var(--primary-light, #1f6feb);
   }
   
   .invoice-totals {
       max-width: 350px;
       margin-left: auto;
       margin-top: 32px;
       padding: 20px;
       background: var(--bg-tertiary, #1c2128);
       border: 1px solid var(--border-default, #30363d);
       border-radius: 8px;
   }
   
   .total-row {
       display: flex;
       justify-content: space-between;
       padding: 8px 0;
       font-size: 14px;
       color: var(--text-primary, #e6edf3);
   }
   
   .total-row.final {
       border-top: 2px solid var(--border-emphasis, #444c56);
       margin-top: 12px;
       padding-top: 12px;
       font-size: 18px;
       font-weight: 700;
       color: var(--primary-light, #1f6feb);
   }
   
   .paid-badge {
       margin-top: 16px;
       padding: 12px;
       background: rgba(34, 197, 94, 0.15);
       border: 1px solid rgba(34, 197, 94, 0.3);
       border-radius: 6px;
       text-align: center;
       font-weight: 600;
       font-size: 14px;
       color: var(--success-light, #26a641);
   }
   
   .invoice-footer {
       margin-top: 40px;
       padding-top: 20px;
       border-top: 1px solid var(--border-default, #30363d);
       text-align: center;
   }
   
   .invoice-footer p {
       font-size: 16px;
       color: var(--text-secondary, #8b949e);
       font-style: italic;
   }
   
   /* RTL Support */
   [dir="rtl"] .invoice-meta {
       text-align: left;
   }
   
   [dir="rtl"] .invoice-totals {
       margin-left: 0;
       margin-right: auto;
   }
   
   [dir="rtl"] .invoice-table th,
   [dir="rtl"] .invoice-table td {
       text-align: right;
   }
   
   /* Responsive Design */
   @media (max-width: 768px) {
       .modal-content {
           width: 95%;
           max-height: 95vh;
           border-radius: 12px;
       }
       
       .modal-content.large {
           max-width: 95%;
       }
       
       .modal-header {
           padding: 20px;
       }
       
       .modal-header h3 {
           font-size: 18px;
       }
       
       .invoice-details-content {
           padding: 20px;
       }
       
       .modal-actions {
           flex-direction: column;
           padding: 16px 20px;
       }
       
       .modal-actions button {
           width: 100%;
       }
       
       .invoice-details-header {
           flex-direction: column;
           gap: 20px;
       }
       
       .invoice-meta {
           text-align: left;
       }
       
       .invoice-number-large {
           font-size: 24px;
       }
       
       .invoice-totals {
           margin-left: 0;
           margin-right: 0;
           max-width: 100%;
       }
       
       .company-info h2 {
           font-size: 22px;
       }
   }
   
   /* Animation */
   @keyframes modalFadeIn {
       from {
           opacity: 0;
           transform: scale(0.9) translateY(20px);
       }
       to {
           opacity: 1;
           transform: scale(1) translateY(0);
       }
   }
   
   .modal.active .modal-content {
       animation: modalFadeIn 0.3s ease;
   }
   
   /* Print Styles */
   @media print {
       .modal-overlay,
       .modal-close,
       .modal-actions {
           display: none !important;
       }
       
       .modal-content {
           box-shadow: none;
           border: none;
           max-width: 100%;
           max-height: none;
       }
       
       .invoice-details-content {
           max-height: none;
           overflow: visible;
       }
   }

   /* إخفاء شريط التمرير للصفحة الرئيسية */
body {
    overflow-y: scroll;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

body::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

/* إخفاء شريط التمرير لجميع العناصر */
* {
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

*::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

/* إخفاء شريط التمرير للمودال */
.modal-body::-webkit-scrollbar,
.invoice-details-content::-webkit-scrollbar {
    display: none;
}

.modal-body,
.invoice-details-content {
    scrollbar-width: none;
    -ms-overflow-style: none;
}

/* ========================================
   نظام التنبيهات المخصص
   ======================================== */

/* خلفية التنبيه */
.custom-alert-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* صندوق التنبيه */
.custom-alert-box {
    background: var(--bg-secondary);
    border: 1px solid var(--border-emphasis);
    border-radius: 12px;
    padding: 0;
    min-width: 400px;
    max-width: 500px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.3s ease;
    overflow: hidden;
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* رأس التنبيه */
.custom-alert-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-default);
    display: flex;
    align-items: center;
    gap: 12px;
}

.custom-alert-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.custom-alert-icon.info {
    background: rgba(9, 105, 218, 0.15);
    color: #1f6feb;
}

.custom-alert-icon.warning {
    background: rgba(191, 135, 0, 0.15);
    color: #d29922;
}

.custom-alert-icon.danger {
    background: rgba(207, 34, 46, 0.15);
    color: #e5534b;
}

.custom-alert-icon.success {
    background: rgba(31, 136, 61, 0.15);
    color: #26a641;
}

.custom-alert-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

/* محتوى التنبيه */
.custom-alert-body {
    padding: 20px 24px;
}

.custom-alert-message {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.6;
    white-space: pre-line;
}

/* أزرار التنبيه */
.custom-alert-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-default);
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.custom-alert-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 100px;
}

.custom-alert-btn-cancel {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 1px solid var(--border-default);
}

.custom-alert-btn-cancel:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.custom-alert-btn-confirm {
    background: #0969da;
    color: white;
}

.custom-alert-btn-confirm:hover {
    background: #0860ca;
}

.custom-alert-btn-confirm.danger {
    background: #cf222e;
}

.custom-alert-btn-confirm.danger:hover {
    background: #e5534b;
}

.custom-alert-btn-confirm.success {
    background: #1f883d;
}

.custom-alert-btn-confirm.success:hover {
    background: #26a641;
}


.btn-onesync-change {
    width: 100%;
    height: 36px;
    background: linear-gradient(135deg, #669bea 0%, #4b5ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 16px;
    font-family: inherit;
    font-size: 14px;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.2);
}

.btn-onesync-change:hover {
    background: linear-gradient(135deg, #669bea 0%, #4b5ba2 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
}

.btn-onesync-change:active {
    transform: translateY(0);
}
/* ==========================================
   🎯 تحسينات زر OneSync Details (Updated!)
   ========================================== */

/* تحسين شكل الأزرار في license-code */
.license-code {
    display: flex;
    align-items: center;
    gap: 0px;
    flex-wrap: wrap;
}

.license-code .copy-btn {
    white-space: nowrap;
    padding: 0px 8px;
    font-size: 11.5px;
}

/* تصميم متجاوب للأزرار */
@media (max-width: 768px) {
    .license-code {
        flex-direction: column;
        align-items: stretch;
    }
    
    .license-code .copy-btn {
        width: 100%;
        justify-content: center;
    }
}

/* ==========================================
   🎯 زر OneSync Info (Updated v2!)
   ========================================== */

.btn-onesync-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(9, 105, 218, 0.4);
}

.btn-onesync-info:active {
    transform: translateY(0);
}

/* ==========================================
   🎯 OneSync Compact Button (Updated v3!)
   ========================================== */

.btn-onesync-compact {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px 8px;
    background: rgba(139, 148, 158, 0.15);
    border: 1px solid var(--border-default);
    border-radius: 4px;
    color: var(--text-secondary);
    font-size: 11px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.btn-onesync-compact:hover {
    background: rgba(139, 148, 158, 0.25);
    border-color: var(--border-emphasis);
    color: var(--text-primary);
}

.btn-onesync-compact:active {
    opacity: 0.8;
}

/* ==========================================
   🎯 OneSync Details Modal - Redesigned
   ========================================== */

/* Modal Overlay */
.onesync-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(1, 4, 9, 0.8);
    backdrop-filter: blur(8px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 20px;
}

.onesync-modal-overlay.active {
    opacity: 1;
}

/* Modal Container - متناسق مع الثيم */
.onesync-modal-container {
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid var(--border-default);
    box-shadow: 0 16px 32px rgba(1, 4, 9, 0.4);
    width: 100%;
    max-width: 550px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

.onesync-modal-overlay.active .onesync-modal-container {
    transform: scale(1);
}

/* Modal Header */
.onesync-modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-default);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--bg-tertiary);
}

.onesync-modal-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.onesync-icon {
    font-size: 24px;
    line-height: 1;
}

.onesync-modal-title h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.onesync-modal-close {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.onesync-modal-close:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

/* Modal Body */
.onesync-modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

/* Detail Card - متناسق مع الثيم */
.onesync-detail-card {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-default);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
    transition: all 0.2s ease;
}

.onesync-detail-card:hover {
    background: var(--bg-hover);
    border-color: var(--border-emphasis);
}

.onesync-detail-card:last-child {
    margin-bottom: 0;
}

.onesync-detail-card.highlight {
    background: rgba(31, 111, 235, 0.1);
    border-color: rgba(31, 111, 235, 0.3);
}

.onesync-detail-icon {
    font-size: 20px;
    line-height: 1;
    flex-shrink: 0;
}

.onesync-detail-content {
    flex: 1;
    min-width: 0;
}

.onesync-detail-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.onesync-detail-value {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    word-break: break-word;
}

/* OneSync Code Box */
.onesync-code-box {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-primary);
    border: 1px solid var(--border-default);
    border-radius: 6px;
    padding: 10px 12px;
}

.onesync-code-text {
    flex: 1;
    font-family: var(--font-mono);
    font-size: 13px;
    color: var(--text-primary);
    background: none;
    border: none;
    word-break: break-all;
}

.onesync-copy-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 6px 10px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.onesync-copy-btn:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
}

.onesync-copy-btn.copied {
    background: var(--success);
}

.copy-icon {
    font-size: 12px;
}

.copy-text {
    font-size: 11px;
}

/* Links */
.onesync-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--primary-light);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s ease;
}

.onesync-link:hover {
    color: var(--primary);
    text-decoration: underline;
}

.link-icon {
    font-size: 14px;
    flex-shrink: 0;
}

/* Modal Footer */
.onesync-modal-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border-default);
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    background: var(--bg-tertiary);
}

.onesync-btn-copy-all,
.onesync-btn-close {
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.onesync-btn-copy-all {
    background: var(--primary);
    color: white;
}

.onesync-btn-copy-all:hover {
    background: var(--primary-hover);
}

.onesync-btn-close {
    background: var(--bg-hover);
    color: var(--text-primary);
    border: 1px solid var(--border-default);
}

.onesync-btn-close:hover {
    background: var(--bg-elevated);
    border-color: var(--border-emphasis);
}

/* RTL Support */
body.rtl .onesync-modal-title,
body.rtl .onesync-detail-card {
    flex-direction: row-reverse;
}

body.rtl .onesync-modal-footer {
    flex-direction: row-reverse;
}

body.rtl .onesync-code-box {
    flex-direction: row-reverse;
}

body.rtl .onesync-copy-btn {
    flex-direction: row-reverse;
}

body.rtl .onesync-link {
    flex-direction: row-reverse;
}

/* Responsive Design */
@media (max-width: 768px) {
    .onesync-modal-container {
        max-width: 95%;
        margin: 10px;
    }
    
    .onesync-modal-header {
        padding: 16px;
    }
    
    .onesync-modal-title h2 {
        font-size: 16px;
    }
    
    .onesync-modal-body {
        padding: 16px;
    }
    
    .onesync-detail-card {
        padding: 12px;
    }
    
    .onesync-code-box {
        flex-direction: column;
        align-items: stretch;
    }
    
    .onesync-copy-btn {
        width: 100%;
        justify-content: center;
    }
    
    .onesync-modal-footer {
        flex-direction: column;
        padding: 12px 16px;
    }
    
    .onesync-btn-copy-all,
    .onesync-btn-close {
        width: 100%;
    }
}

/* ==========================================
   🎯 OneSync Corner Button (Final Position!)
   ========================================== */

.btn-onesync-corner {
    position: absolute;
    top: 8px;
    right: 8px;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 4px 8px;
    background: rgba(139, 148, 158, 0.15);
    border: 1px solid var(--border-default);
    border-radius: 4px;
    color: var(--text-secondary);
    font-size: 10px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 10;
}

.btn-onesync-corner:hover {
    background: rgba(139, 148, 158, 0.25);
    border-color: var(--border-emphasis);
    color: var(--text-primary);
    transform: scale(1.05);
}

.btn-onesync-corner:active {
    transform: scale(0.98);
}

/* RTL Support */
body.rtl .btn-onesync-corner {
    right: auto;
    left: 8px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .btn-onesync-corner {
        top: 6px;
        right: 6px;
        padding: 3px 6px;
        font-size: 9px;
    }
    
    body.rtl .btn-onesync-corner {
        right: auto;
        left: 6px;
    }
}