/*
 * 2999 — əsl qaranlıq tema (yalnız <html data-dark-native> olan səhifələr).
 * Hazırda: çərçivə (sidebar, üst panel, menyular) + Əsas səhifə.
 * Yeni modulu bura köçürmək üçün: şablonda {% block html_attrs %} data-dark-native{% endblock %}
 * və həmin modulun rənglərini aşağıda html[data-theme="dark"][data-dark-native] altında yazmaq.
 */
@media screen {
  html[data-theme="dark"][data-dark-native] {
    color-scheme: dark;
    --sc-bg: #0e1320;
    --sc-card: #1a2234;
    --sc-card-strong: #1f2840;
    --sc-border: rgba(148, 163, 184, 0.12);
    --sc-shadow: 0 10px 26px rgba(0, 0, 0, 0.28);
    --sc-text: #e7ebf3;
    --sc-muted: #8b97ad;
    --scd-frame: #131a2a;
    --scd-sidebar: #111726;
    --scd-line: rgba(148, 163, 184, 0.14);
    --scd-soft: rgba(255, 255, 255, 0.04);
    --scd-link: #7aa5ff;
    background: #0b0f1a;
  }

  /* ---------- Fon və çərçivə ---------- */
  html[data-theme="dark"][data-dark-native] body,
  html[data-theme="dark"][data-dark-native] .sc-body {
    background:
      radial-gradient(circle at top left, rgba(79, 124, 255, 0.10), transparent 26%),
      radial-gradient(circle at top right, rgba(255, 92, 168, 0.06), transparent 22%),
      #0b0f1a !important;
    color: var(--sc-text);
  }
  html[data-theme="dark"][data-dark-native] .sc-dashboard-frame {
    background: var(--scd-frame) !important;
    border-color: var(--scd-line) !important;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35) !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-main { background: var(--scd-frame) !important; }

  /* ---------- Sidebar ---------- */
  html[data-theme="dark"][data-dark-native] .sc-sidebar {
    background: var(--scd-sidebar) !important;
    border-right-color: var(--scd-line) !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-sidebar-label { color: #5f6b82; }
  html[data-theme="dark"][data-dark-native] .sc-sidebar-link { color: #b4bdcf; }
  html[data-theme="dark"][data-dark-native] .sc-sidebar-link:hover { background: rgba(79, 124, 255, 0.12); color: #c9d7ff; }
  html[data-theme="dark"][data-dark-native] .sc-sidebar-icon { background: rgba(79, 124, 255, 0.14); color: #7aa5ff; }
  html[data-theme="dark"][data-dark-native] .sc-sidebar-link:hover .sc-sidebar-icon { background: rgba(79, 124, 255, 0.22); color: #9dbcff; }
  html[data-theme="dark"][data-dark-native] .sc-sidebar-link.is-active { color: #fff; box-shadow: 0 12px 26px rgba(40, 80, 200, 0.35); }
  html[data-theme="dark"][data-dark-native] .sc-sidebar-link.is-active .sc-sidebar-icon { background: rgba(255, 255, 255, 0.16); color: #fff; }
  html[data-theme="dark"][data-dark-native] .sc-sidebar-badge { background: rgba(79, 124, 255, 0.2); color: #9dbcff; }
  html[data-theme="dark"][data-dark-native] .sc-mobile-sidebar-close,
  html[data-theme="dark"][data-dark-native] .sc-mobile-menu-button {
    background: var(--sc-card) !important;
    border-color: var(--scd-line) !important;
    color: var(--sc-text) !important;
  }

  /* ---------- Üst panel ---------- */
  html[data-theme="dark"][data-dark-native] .sc-page-title,
  html[data-theme="dark"][data-dark-native] .sc-section-title { color: var(--sc-text) !important; }
  html[data-theme="dark"][data-dark-native] .sc-page-subtitle,
  html[data-theme="dark"][data-dark-native] .sc-section-meta { color: var(--sc-muted) !important; }
  html[data-theme="dark"][data-dark-native] .sc-topbar-actions {
    background: rgba(255, 255, 255, 0.03) !important;
    border-color: var(--scd-line) !important;
    box-shadow: none !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-profile-pill,
  html[data-theme="dark"][data-dark-native] .sc-profile-menu[open] .sc-profile-pill,
  html[data-theme="dark"][data-dark-native] .sc-notif-menu[open] .sc-bell-button {
    background: var(--sc-card) !important;
    border-color: var(--scd-line) !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-bell-button { color: #b4bdcf; }
  html[data-theme="dark"][data-dark-native] .sc-employee-search-box {
    background: var(--sc-card) !important;
    border-color: var(--scd-line) !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-employee-search-input { color: var(--sc-text) !important; }
  html[data-theme="dark"][data-dark-native] .sc-employee-search-input::placeholder { color: #6f7b92; }
  html[data-theme="dark"][data-dark-native] .sc-employee-search-panel,
  html[data-theme="dark"][data-dark-native] .sc-employee-search-detail {
    background: #1b2337 !important;
    border-color: var(--scd-line) !important;
    color: var(--sc-text);
  }
  html[data-theme="dark"][data-dark-native] .sc-employee-result { color: var(--sc-text); }
  html[data-theme="dark"][data-dark-native] .sc-employee-result.is-active { background: rgba(79, 124, 255, 0.14) !important; }
  html[data-theme="dark"][data-dark-native] .sc-employee-detail-item,
  html[data-theme="dark"][data-dark-native] .sc-employee-detail-close {
    background: var(--scd-soft) !important;
    border-color: var(--scd-line) !important;
    color: var(--sc-text);
  }

  /* Bildiriş və profil menyuları */
  html[data-theme="dark"][data-dark-native] .sc-notif-dropdown,
  html[data-theme="dark"][data-dark-native] .sc-profile-dropdown {
    background: #1b2337 !important;
    border-color: var(--scd-line) !important;
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.45) !important;
    color: var(--sc-text);
  }
  html[data-theme="dark"][data-dark-native] .sc-notif-preview-item,
  html[data-theme="dark"][data-dark-native] .sc-notif-empty { background: var(--scd-soft) !important; color: var(--sc-text); }
  html[data-theme="dark"][data-dark-native] .sc-notif-preview-item:hover { background: rgba(79, 124, 255, 0.12) !important; }
  html[data-theme="dark"][data-dark-native] .sc-notif-preview-item.is-unread {
    background: linear-gradient(180deg, rgba(79, 124, 255, 0.16) 0%, rgba(255, 255, 255, 0.03) 100%) !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-profile-dropdown-link { color: #c3cbdb; }
  html[data-theme="dark"][data-dark-native] .sc-profile-dropdown-link:hover,
  html[data-theme="dark"][data-dark-native] .sc-profile-dropdown-link.is-current { background: rgba(79, 124, 255, 0.14) !important; }
  html[data-theme="dark"][data-dark-native] :is(.sc-notif-dropdown, .sc-profile-dropdown) :is(h1, h2, h3, h4, strong, b) { color: var(--sc-text); }
  html[data-theme="dark"][data-dark-native] :is(.sc-notif-dropdown-title, .sc-employee-detail-title, .sc-employee-detail-value, .sc-employee-result-name) {
    color: var(--sc-text) !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-profile-dropdown-link:focus { color: #fff; }

  /* ---------- Əsas səhifə kartları ---------- */
  html[data-theme="dark"][data-dark-native] .sc-card,
  html[data-theme="dark"][data-dark-native] .sc-ranking-card {
    background: var(--sc-card) !important;
    border-color: var(--scd-line) !important;
    box-shadow: var(--sc-shadow) !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-section-link {
    background: transparent !important;
    border-color: rgba(122, 165, 255, 0.55) !important;
    color: var(--scd-link) !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-section-link:hover { background: rgba(79, 124, 255, 0.12) !important; color: #a9c4ff !important; }
  html[data-theme="dark"][data-dark-native] .sc-birthday-branch,
  html[data-theme="dark"][data-dark-native] .sc-progress-text { color: var(--scd-link); }
  html[data-theme="dark"][data-dark-native] .sc-progress-track { background: rgba(148, 163, 184, 0.18); }
  html[data-theme="dark"][data-dark-native] .sc-ranking-row { background: var(--scd-soft); border-color: var(--scd-line); }
  html[data-theme="dark"][data-dark-native] .sc-ranking-badge.is-3 { background: #475569; }
  html[data-theme="dark"][data-dark-native] .sc-ops-row { border-bottom-color: var(--scd-line); }
  html[data-theme="dark"][data-dark-native] .sc-ops-pill { color: var(--scd-link); background: rgba(79, 124, 255, 0.16); }
  html[data-theme="dark"][data-dark-native] .sc-ops-pill.is-warning { color: #fbbf24; }
  html[data-theme="dark"][data-dark-native] .sc-ops-pill.is-danger { color: #f87171; }

  /* Davamiyyət cədvəli (inline stilləri olan cədvəl) */
  html[data-theme="dark"][data-dark-native] .sc-card table :is(th, td) {
    border-color: var(--scd-line) !important;
  }
  html[data-theme="dark"][data-dark-native] .sc-card table thead tr { color: var(--sc-muted) !important; }
  html[data-theme="dark"][data-dark-native] .sc-card table tbody td { color: var(--sc-text); }
  /* Əsas səhifə partial-larında inline yazılmış tünd mətn rəngi */
  html[data-theme="dark"][data-dark-native] .sc-main [style*=";color:#0f172a"],
  html[data-theme="dark"][data-dark-native] .sc-main [style^="color:#0f172a"] { color: var(--sc-text) !important; }
  html[data-theme="dark"][data-dark-native] .sc-main [style*="color:#d97706"] { color: #fbbf24 !important; }
  html[data-theme="dark"][data-dark-native] .dv-w-present { color: #4ade80; background: rgba(74, 222, 128, 0.14); }
  html[data-theme="dark"][data-dark-native] .dv-w-late { color: #fbbf24; background: rgba(251, 191, 36, 0.14); }
  html[data-theme="dark"][data-dark-native] .dv-w-absent { color: #f87171; background: rgba(248, 113, 113, 0.14); }
  html[data-theme="dark"][data-dark-native] .dv-w-no_checkout { color: #a78bfa; background: rgba(167, 139, 250, 0.14); }
  html[data-theme="dark"][data-dark-native] .dv-w-rest { color: #7aa5ff; background: rgba(122, 165, 255, 0.14); }
  html[data-theme="dark"][data-dark-native] :is(.dv-w-leave, .dv-w-hourly) { color: #2dd4bf; background: rgba(45, 212, 191, 0.14); }
  html[data-theme="dark"][data-dark-native] .dv-w-upcoming { color: #22d3ee; background: rgba(34, 211, 238, 0.14); }

  /* İşçi statusları (axtarış nəticələri) */
  html[data-theme="dark"][data-dark-native] .sc-employee-status.is-green { color: #4ade80; }
  html[data-theme="dark"][data-dark-native] .sc-employee-status.is-red { color: #f87171; }
  html[data-theme="dark"][data-dark-native] .sc-employee-status.is-amber { color: #fbbf24; }
  html[data-theme="dark"][data-dark-native] .sc-employee-status.is-purple { color: #a78bfa; }
  html[data-theme="dark"][data-dark-native] .sc-employee-status.is-pink { color: #f472b6; }
  html[data-theme="dark"][data-dark-native] .sc-employee-status.is-blue { color: #7aa5ff; }
  html[data-theme="dark"][data-dark-native] .sc-employee-status.is-teal { color: #2dd4bf; }
  html[data-theme="dark"][data-dark-native] .sc-employee-status.is-slate { color: #b4bdcf; }

  /* Şikayət dialoqu (Əsas səhifə) */
  html[data-theme="dark"][data-dark-native] .sc-complaint-dialog { background: #1b2337; color: var(--sc-text); }
  html[data-theme="dark"][data-dark-native] .sc-complaint-head h3 { color: var(--sc-text); }
  html[data-theme="dark"][data-dark-native] .sc-complaint-btn { color: var(--scd-link); }
}
