/* Load fonts (Google Fonts). */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Poppins:wght@500;600;700&display=swap");

:root{
  /* Fonts */
  --font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-family-display: "Poppins", "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-size: 16px;
  --text-xs: 0.75rem; /* 12px - Caption */
  --text-sm: 0.875rem; /* 14px - Small body */
  --text-base: 1rem; /* 16px - Body */
  --text-lg: 1.125rem; /* 18px - Subtitle */
  --text-xl: 1.25rem; /* 20px - H4 */
  --text-2xl: 1.5rem; /* 24px - H3 */
  --text-3xl: 1.875rem; /* 30px - H2 */
  --text-4xl: 2.25rem; /* 36px - H1 */
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  --line-height-tight: 1.25;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.75;
  --primary: #a6d3fa;
  --primary-light: #f6fafe;
  --primary-hover: #ebf3fa;
  --primary-pressed: #6f89a2;
  --primary-foreground: #212A32;
  --success: #1faf49;
  --success-light: #e8f7ed;
  --success-pressed: #157a33;
  --success-hover: #188c3a;
  --success-foreground: #ffffff;
  --danger: #ef4d48;
  --danger-hover: #d93d38;
  --danger-pressed: #c32e2a;
  --danger-light: #fdebea;
  --danger-foreground: #ffffff;
  --warning: #ffb800;
  --warning-hover: #e5a500;
  --warning-pressed: #cc9400;
  --warning-light: #fff0cc;
  --warning-foreground: #1a1a1a;
  --neutral-0: #ffffff;
  --neutral-5: #fafafa;
  --neutral-10: #f5f5f5;
  --neutral-15: #f0f0f0;
  --neutral-20: #ebebeb;
  --neutral-25: #e6e6e6;
  --neutral-30: #e0e0e0;
  --neutral-35: #dbdbdb;
  --neutral-40: #d6d6d6;
  --neutral-50: #c7c7c7;
  --neutral-60: #adadad;
  --neutral-70: #8f8f8f;
  --neutral-80: #6b6b6b;
  --neutral-90: #3d3d3d;
  --neutral-95: #2b2b2b;
  --neutral-100: #1a1a1a;
  --background: var(--neutral-0);
  --foreground: var(--neutral-100);
  --card: var(--neutral-0);
  --card-foreground: var(--neutral-100);
  --popover: var(--neutral-0);
  --popover-foreground: var(--neutral-100);
  --secondary: var(--neutral-10);
  --secondary-hover: var(--neutral-15);
  --secondary-pressed: var(--neutral-20);
  --secondary-foreground: var(--neutral-100);
  --muted: var(--neutral-20);
  --muted-foreground: var(--neutral-70);
  --accent: var(--neutral-10);
  --accent-foreground: var(--neutral-100);
  --destructive: var(--danger);
  --destructive-foreground: var(--danger-foreground);
  --border: var(--neutral-20);
  --border-strong: var(--neutral-30);
  --divider: var(--neutral-15);
  --input: transparent;
  --input-background: var(--neutral-10);
  --input-border: var(--neutral-30);
  --input-border-hover: var(--neutral-50);
  --input-border-focus: var(--primary);
  --input-disabled: var(--neutral-15);
  --input-disabled-text: var(--neutral-60);
  --hover-overlay: rgba(0, 0, 0, 0.04);
  --pressed-overlay: rgba(0, 0, 0, 0.08);
  --disabled-opacity: 0.4;
  --switch-background: var(--neutral-50);
  --ring: var(--neutral-70);
  /* Aktif / Pasif buton ve sekmeler – tek palet */
  --state-passive-bg: rgba(17, 24, 39, 0.04);
  --state-passive-text: rgba(17, 24, 39, 0.68);
  --state-passive-border: transparent;
  --state-passive-hover-bg: rgba(17, 24, 39, 0.07);
  --state-passive-hover-text: rgba(17, 24, 39, 0.92);
  --state-active-bg: rgba(166, 211, 250, 0.55);
  --state-active-bg-strong: rgba(166, 211, 250, 0.85);
  --state-active-text: #0b2a46;
  --state-active-border: rgba(129, 178, 223, 0.5);
  --state-active-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  --state-segmented-track: rgba(17, 24, 39, 0.06);
  --state-pill-passive-bg: #f1f5f9;
  --state-pill-passive-text: rgba(17, 24, 39, 0.72);
  --state-pill-active-bg: rgba(166, 211, 250, 0.9);
  --state-pill-active-text: #0b2a46;
  --state-pill-active-border: rgba(129, 178, 223, 0.55);
  --spacing-0: 0;
  --spacing-1: 0.25rem; /* 4px */
  --spacing-2: 0.5rem; /* 8px */
  --spacing-3: 0.75rem; /* 12px */
  --spacing-4: 1rem; /* 16px */
  --spacing-5: 1.25rem; /* 20px */
  --spacing-6: 1.5rem; /* 24px */
  --spacing-7: 1.75rem; /* 28px */
  --spacing-8: 2rem; /* 32px */
  --spacing-10: 2.5rem; /* 40px */
  --spacing-12: 3rem; /* 48px */
  --spacing-14: 3.5rem; /* 56px */
  --spacing-16: 4rem; /* 64px */
  --spacing-20: 5rem; /* 80px */
  --spacing-24: 6rem; /* 96px */
  --radius-none: 0;
  --radius-xs: 0.25rem; /* 4px */
  --radius-sm: 0.375rem; /* 6px */
  --radius-md: 0.5rem; /* 8px */
  --radius-lg: 0.75rem; /* 12px - Card default */
  --radius-xl: 1rem; /* 16px */
  --radius-2xl: 1.5rem; /* 24px */
  --radius-full: 9999px;
  --radius: var(--radius-lg); /* Default 12px */
  --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-sm:
  --shadow-md:
  --shadow-lg:
  --shadow-xl:
  --chart-1: var(--primary);
  --chart-2: #3b82f6;
  --chart-3: #8b5cf6;
  --chart-4: #f59e0b;
  --chart-5: #ec4899;
  --transition-fast: 150ms ease-in-out;
  --transition-base: 200ms ease-in-out;
  --transition-slow: 300ms ease-in-out;
  --z-base: 0;
  --z-dropdown: 1000;
  --z-sticky: 1100;
  --z-fixed: 1200;
  --z-modal-backdrop: 1300;
  --z-modal: 1400;
  --z-popover: 1500;
  --z-tooltip: 1600;
  /* Bootstrap’in koyu mavi kullanmaması için tema renklerine zorla */
  --bs-primary: #a6d3fa;
  --bs-primary-rgb: 166, 211, 250;
  --bs-secondary: var(--neutral-10);
  --bs-secondary-rgb: 245, 245, 245;
}

html,body{height:100%;}
body{
  font-family: var(--font-family, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif);
  font-size: 15px;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: var(--neutral-5, #f7f7f8);
  color: var(--neutral-100, #111827);
}

h1,h2,h3,h4,h5,h6,
.display-1,.display-2,.display-3,.display-4,.display-5,.display-6{
  font-family: var(--font-family-display);
  letter-spacing: -0.01em;
}
a{color: var(--primary, #0d6efd);}
.text-muted{color: var(--neutral-60, #6b7280)!important;}
.bg-app{background: var(--neutral-5, #f7f7f8);}
.card{border-color: rgba(17,24,39,.08);}
.card.shadow-soft{box-shadow: 0 10px 30px rgba(0,0,0,.05);}
.badge-soft{
  background: rgba(166,211,250,.25);
  color: #0b2a46;
  border: 1px solid rgba(166,211,250,.35);
}
.sidebar{
  width: 280px;
  background: var(--neutral-0, #ffffff);
  color: var(--neutral-90, #3d3d3d);
  border-right: 1px solid rgba(17,24,39,.08);
}
.desktop-sidebar{
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  overflow: hidden;
  z-index: var(--z-sticky, 1100);
}
.desktop-sidebar nav{
  overflow: auto;
}

@media (min-width: 992px){
  .main-with-sidebar{
    margin-left: 280px;
  }
}

body.sidebar-hidden .desktop-sidebar{
  width: 72px;
  min-width: 72px;
}
body.sidebar-hidden .desktop-sidebar .brand > div > div:last-child{
  display: none;
}
body.sidebar-hidden .desktop-sidebar .brand{
  justify-content: center;
  padding-left: 0;
  padding-right: 0;
}
body.sidebar-hidden .desktop-sidebar .brand > div{
  margin: 0;
}
body.sidebar-hidden .desktop-sidebar .nav-link{
  justify-content: center;
  padding: 0.65rem;
}
body.sidebar-hidden .desktop-sidebar .nav-link span{
  display: none;
}
body.sidebar-hidden .desktop-sidebar .nav-link .bi{
  margin: 0;
}
body.sidebar-hidden .desktop-sidebar .p-3.border-top{
  padding: 0.75rem !important;
}
body.sidebar-hidden .desktop-sidebar .p-3.border-top .btn{
  justify-content: center;
  padding: 0.5rem;
}
body.sidebar-hidden .desktop-sidebar .p-3.border-top .btn .sidebar-label{
  display: none;
}
body.sidebar-hidden .desktop-sidebar .p-3.border-top .btn .bi{
  margin: 0 !important;
}
body.sidebar-hidden .main-with-sidebar{
  margin-left: 72px !important;
}
.sidebar-toggle-when-visible{
  display: none;
}
@media (min-width: 992px){
  .sidebar-toggle-when-visible{
    display: inline-flex;
  }
}
body.sidebar-hidden .sidebar-toggle-when-visible{
  display: none !important;
}
.sidebar-toggle-when-hidden{
  display: none;
}
body.sidebar-hidden .sidebar-toggle-when-hidden{
  display: inline-flex !important;
}

.sidebar .brand{
  height: 64px;
  border-bottom: 1px solid rgba(17,24,39,.08);
}

/* Hesabizle logo – sidebar */
.brand-logo-wrap{
  width: 48px;
  height: 40px;
  min-width: 48px;
  min-height: 40px;
  flex-shrink: 0;
  background: transparent;
  padding: 2px;
}
.brand-logo-wrap .brand-logo-img{
  width: auto;
  height: 100%;
  max-height: 36px;
  object-fit: contain;
  display: block;
}
.sidebar .nav-link{
  color: var(--state-passive-text);
  border-radius: .75rem;
  padding: .65rem .75rem;
  transition: background .18s ease, color .18s ease;
}
.sidebar .nav-link:hover{
  background: var(--state-passive-hover-bg);
  color: var(--state-passive-hover-text);
}
.sidebar .nav-link.active{
  background: var(--state-active-bg);
  color: var(--state-active-text);
  font-weight: 600;
  box-shadow: var(--state-active-shadow);
}
.sidebar .nav-link .bi{opacity:.8;}
.sidebar .nav-link.active .bi{opacity:1;}
.topbar{
  height: 64px;
  background: rgba(255,255,255,.96);
  border-bottom: 1px solid rgba(17,24,39,.08);
  position: sticky;
  top: 0;
  z-index: var(--z-sticky, 1100);
}
.dropdown-menu{
  z-index: var(--z-tooltip, 1600);
}
/* Tema uyumlu: dropdown öğeleri tıklanınca koyu olmasın */
.dropdown-item:active,
.dropdown-item:focus{
  background: var(--state-passive-hover-bg);
  color: var(--state-passive-hover-text);
}
.dropdown-item.show{
  background: var(--state-passive-hover-bg);
  color: var(--state-passive-hover-text);
}
.kpi-icon{
  width: 44px; height: 44px;
  border-radius: 14px;
  background: rgba(166,211,250,.28);
  display:flex;align-items:center;justify-content:center;
}
.page-container{
  max-width: 1080px;
}
.avatar{
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: rgba(166,211,250,.7);
  color: #0b2a46;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}
.avatar-lg{
  width: 56px;
  height: 56px;
  border-radius: 999px;
  background: rgba(166,211,250,.7);
  color: #0b2a46;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.25rem;
}
.kpi-card .kpi-meta{
  color: rgba(17,24,39,.55);
  font-size: .85rem;
}
.kpi-card .kpi-value{
  font-size: 1.05rem;
  font-weight: 600;
}
.summary-card .text-muted{
  color: rgba(17,24,39,.55) !important;
}
.summary-icon{
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}
.summary-icon-fx{
  background: rgba(166,211,250,.28);
  color: #0b2a46;
}
.summary-value{
  font-weight: 600;
  font-size: 1.35rem;
  letter-spacing: -0.01em;
}
.segmented .btn-group{
  background: var(--state-segmented-track);
  padding: 6px;
  border-radius: 14px;
}
.btn-seg{
  border: 0 !important;
  background: transparent !important;
  color: var(--state-passive-text) !important;
  border-radius: 10px !important;
  padding: .5rem 1rem;
  transition: background .18s ease, color .18s ease, box-shadow .18s ease;
}
.btn-seg:hover:not(.active){
  background: var(--state-passive-hover-bg) !important;
  color: var(--state-passive-hover-text) !important;
}
.btn-seg.active{
  background: var(--state-active-bg-strong) !important;
  color: var(--state-active-text) !important;
  box-shadow: var(--state-active-shadow);
  border: 1px solid var(--state-active-border) !important;
}
.filter-bar .btn-seg{
  padding: .45rem .9rem;
}
.search-pill .input-group-text{
  background: transparent;
  border-right: 0;
}
.search-pill .form-control{
  border-left: 0;
}
.filter-pill{
  border-radius: 999px;
}
.filter-pill.active{
  background: var(--state-active-bg-strong) !important;
  border-color: var(--state-active-border) !important;
  color: var(--state-active-text) !important;
}

.applied-filters-row {
  min-height: 0;
}
.applied-filters-row:not(.has-chips) {
  display: none;
}
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.5rem 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 500;
  background: var(--state-active-bg);
  color: var(--state-active-text);
  border: 1px solid var(--state-active-border);
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.filter-chip.visible {
  opacity: 1;
}
.filter-chip-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.25rem;
  height: 1.25rem;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: inherit;
  opacity: 0.75;
  cursor: pointer;
  transition: background 0.15s ease, opacity 0.15s ease;
}
.filter-chip-remove:hover {
  background: rgba(11, 42, 70, 0.1);
  opacity: 1;
}

.select-like{
  border-radius: .9rem;
  border: 1px solid rgba(17,24,39,.12);
  background: var(--neutral-0);
  padding: .55rem .9rem;
}
.menu-card{
  border-radius: 16px;
  padding: .5rem;
  border: 1px solid rgba(17,24,39,.10);
  box-shadow: 0 16px 40px rgba(0,0,0,.12);
  max-height: 340px;
  overflow: auto;
}
.menu-item{
  border-radius: 12px;
  padding: .75rem .75rem;
  display: flex;
  align-items: center;
  gap: .75rem;
}
/* Override Bootstrap's .dropdown-item.active (white text) */
.menu-card .dropdown-item.menu-item,
.menu-card .dropdown-item.menu-item:active,
.menu-card .dropdown-item.menu-item.active{
  color: var(--state-passive-hover-text);
}
.menu-card .dropdown-item.menu-item.active{
  background: var(--state-active-bg);
  color: var(--state-active-text);
}
.menu-card .dropdown-item.menu-item:hover{
  background: var(--state-passive-hover-bg);
}
.menu-card .dropdown-item.menu-item:focus{
  background: var(--state-passive-hover-bg);
}
.menu-icon{
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex: 0 0 auto;
}
.menu-check{
  opacity: 0;
  color: var(--primary-pressed);
}
.menu-item.active .menu-check{
  opacity: 1;
}
.menu-checklist .menu-item{
  padding: .85rem .9rem;
}
.bg-purple{background:#7c3aed;}
.bg-orange{background:#f97316;}

/* Mobile: prevent horizontal overflow + allow scrollable pills */
@media (max-width: 576px){
  .filter-bar .card-body > .d-flex{
    gap: .5rem !important;
  }
  .filter-bar .segmented{
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .filter-bar .segmented .btn-group{
    flex-wrap: nowrap;
    width: max-content;
  }
  .filter-bar .filter-pill,
  .filter-bar .btn-primary{
    flex: 1 1 auto;
    white-space: nowrap;
  }
  .search-pill{
    width: 100%;
  }
}
.tx-table thead th{
  color: rgba(17,24,39,.55);
  font-weight: 600;
}
html.theme-dark .tx-table thead th{
  color: var(--dm-text-muted) !important;
  background: var(--dm-surface-elevated) !important;
  border-color: var(--dm-border);
}
html.theme-dark .tx-table td,
html.theme-dark .tx-table th{
  color: var(--dm-text) !important;
  border-color: var(--dm-border);
}
html.theme-dark .tx-icon{
  background: var(--dm-accent-bg);
  color: var(--dm-text-muted);
}
html.theme-dark .tx-icon.up{
  background: rgba(74, 222, 128, 0.15);
  color: var(--dm-success);
}
html.theme-dark .tx-icon.down{
  background: rgba(248, 113, 113, 0.15);
  color: var(--dm-danger);
}
html.theme-dark .tx-icon.neutral{
  background: var(--dm-primary-muted);
  color: var(--dm-primary);
}
.tx-table td, .tx-table th{
  padding-top: 1rem;
  padding-bottom: 1rem;
}
.tx-icon{
  width: 40px;
  height: 40px;
  border-radius: 999px;
  display:flex;
  align-items:center;
  justify-content:center;
  background: rgba(17,24,39,.04);
  color: rgba(17,24,39,.55);
}
.tx-icon.up{
  background: rgba(31,175,73,.10);
  color: #1faf49;
}
.tx-icon.down{
  background: rgba(239,77,72,.10);
  color: #ef4d48;
}
.tx-icon.neutral{
  background: rgba(166,211,250,.35);
  color: #0b2a46;
}
.accounts-grid-card {
  background: var(--card);
}
.accounts-table thead th,
.accounts-table.accounts-table-head th {
  color: rgba(17,24,39,.72);
  font-weight: 600;
  background: var(--neutral-10);
}
.accounts-table td,
.accounts-table th {
  padding-top: 1rem;
  padding-bottom: 1rem;
  background: var(--card);
  color: var(--foreground);
  border-color: var(--border);
}
.accounts-table tbody tr:nth-of-type(even) td {
  background: var(--neutral-5);
}
.accounts-table-body td,
.accounts-table-body th {
  background: inherit;
  color: inherit;
}
html.theme-dark .accounts-grid-card,
html.theme-dark .accounts-table {
  background: var(--dm-surface);
}
html.theme-dark .accounts-table thead th,
html.theme-dark .accounts-table.accounts-table-head th {
  background: var(--dm-surface-elevated) !important;
  color: var(--dm-text-muted) !important;
  border-color: var(--dm-border);
}
html.theme-dark .accounts-table tbody td,
html.theme-dark .accounts-table tbody th {
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border);
}
html.theme-dark .accounts-table tbody tr:nth-of-type(even) td {
  background: var(--dm-surface-elevated) !important;
  color: var(--dm-text) !important;
}
html.theme-dark .accounts-empty-title {
  color: var(--dm-text) !important;
}
html.theme-dark #accountsGridLoading {
  background: rgba(30, 41, 59, 0.85) !important;
}
html.theme-dark #accountsGridLoading .text-muted,
html.theme-dark #accountsGridLoading .small{
  color: var(--dm-text-muted) !important;
}
.categories-table thead th{
  color: rgba(17,24,39,.55);
  font-weight: 600;
}
html.theme-dark .categories-table{
  background: var(--dm-surface);
}
html.theme-dark .categories-table thead th{
  color: var(--dm-text-muted) !important;
  background: var(--dm-surface-elevated) !important;
  border-color: var(--dm-border);
}
html.theme-dark .categories-table tbody td,
html.theme-dark .categories-table tbody th{
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border);
}
html.theme-dark .categories-table tbody tr:nth-of-type(even) td{
  background: var(--dm-surface-elevated) !important;
  color: var(--dm-text) !important;
}
html.theme-dark .categories-table td,
html.theme-dark .categories-table th{
  color: var(--dm-text) !important;
  border-color: var(--dm-border);
}
.categories-table td, .categories-table th{
  padding-top: .9rem;
  padding-bottom: .9rem;
}
.categories-table .category-name-cell-root{
  font-weight: 600;
}
.categories-table .category-name-cell-child{
  font-size: 0.9rem;
  color: var(--neutral-80);
}
.categories-table .tree-toggle-btn{
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: none;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--neutral-60);
  padding: 0;
}
.categories-table .tree-toggle-btn:hover{
  background: rgba(15,23,42,.06);
  color: var(--neutral-80);
}
html.theme-dark .categories-table .tree-toggle-btn{
  color: var(--dm-text-muted);
}
html.theme-dark .categories-table .tree-toggle-btn:hover{
  background: rgba(148,163,184,.2);
  color: var(--dm-text);
}
.categories-table .tree-toggle-spacer{
  width: 22px;
  height: 22px;
  display:inline-block;
}
.categories-table tr.category-row-child td{
  background: rgba(15,23,42,.02);
}
html.theme-dark .categories-table tr.category-row-child td{
  background: rgba(148,163,184,.12);
}
.categories-table tr.category-row-child .category-name-cell{
  position: relative;
}
.categories-table tr.category-row-child .category-name-cell::before{
  content: "";
  position: absolute;
  left: var(--tree-offset, 16px);
  top: 0;
  bottom: 0;
  border-left: 1px solid rgba(148,163,184,.7);
}
.categories-table tr.category-row-child .category-name-cell::after{
  content: "";
  position: absolute;
  left: var(--tree-offset, 16px);
  top: 50%;
  width: 18px;
  border-bottom: 1px solid rgba(148,163,184,.7);
  transform: translateY(-50%);
}
.cat-color-dot{
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.04);
}
.status-chip{
  padding: .2rem .7rem;
  border-radius: 999px;
  font-size: .75rem;
}
.status-active{
  background: rgba(22,163,74,.10);
  color: #166534;
}
.status-archived{
  background: rgba(148,163,184,.15);
  color: #475569;
}
.category-pill-shell{
  background: var(--neutral-0);
  border-radius: 20px;
  padding: 4px;
  border: 1px solid rgba(17, 24, 39, .08);
  box-shadow: 0 2px 12px rgba(17, 24, 39, .06);
  display: inline-flex;
}
.category-pill-group .cat-pill{
  border-radius: 999px;
  padding: .45rem 1rem;
  font-size: .9rem;
  color: var(--state-pill-passive-text);
  background: var(--state-pill-passive-bg);
  border: 1px solid transparent;
  display: inline-flex;
  align-items: center;
  transition: background .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.category-pill-group .cat-pill:hover:not(.active){
  background: var(--state-passive-hover-bg);
  color: var(--state-passive-hover-text);
}
.category-pill-group .cat-pill.active{
  background: var(--state-pill-active-bg);
  border-color: var(--state-pill-active-border);
  color: var(--state-pill-active-text);
  box-shadow: var(--state-active-shadow);
  font-weight: 600;
}
.category-pill-group .cat-pill .badge{
  border-radius: 999px;
  font-weight: 500;
  background: rgba(17, 24, 39, .06);
  color: var(--state-passive-text);
}
.category-pill-group .cat-pill.active .badge{
  background: rgba(166, 211, 250, .4);
  color: var(--primary-pressed);
}
.color-swatch{
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 2px solid transparent;
  background: var(--swatch-color);
  transition: border-color .18s ease, box-shadow .18s ease;
}
.color-swatch:hover{
  box-shadow: 0 0 0 2px var(--state-passive-hover-bg);
}
.color-swatch.active{
  border-color: var(--state-active-text);
  box-shadow: 0 0 0 2px var(--state-active-border);
}
.icon-swatch{
  width: 32px;
  height: 32px;
  border-radius: 12px;
  border: 1px solid rgba(17, 24, 39, .12);
  background: var(--state-pill-passive-bg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--state-passive-text);
  transition: background .18s ease, border-color .18s ease, color .18s ease;
}
.icon-swatch:hover{
  background: var(--state-passive-hover-bg);
  color: var(--state-passive-hover-text);
}
.icon-swatch.active{
  border-color: var(--state-active-border);
  background: var(--state-active-bg);
  color: var(--state-active-text);
}
.icon-action{
  color: rgba(17,24,39,.55);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
}
.icon-action:hover{
  background: rgba(17,24,39,.05);
  color: rgba(17,24,39,.85);
}
html.theme-dark .icon-action{
  color: var(--dm-text-muted);
}
html.theme-dark .icon-action:hover{
  background: var(--dm-accent-bg);
  color: var(--dm-text);
}
html.theme-dark .icon-action.text-danger,
html.theme-dark .icon-action .text-danger{
  color: var(--dm-danger) !important;
}
.empty-state{
  min-height: 240px;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-direction:column;
  gap: .75rem;
  color: rgba(17,24,39,.55);
}
.empty-state .empty-icon{
  width: 48px;
  height: 48px;
  border-radius: 999px;
  background: rgba(17,24,39,.04);
  display:flex;
  align-items:center;
  justify-content:center;
  color: rgba(17,24,39,.45);
}
html.theme-dark .empty-state{
  color: var(--dm-text-muted);
}
html.theme-dark .empty-state .empty-icon{
  background: var(--dm-accent-bg);
  color: var(--dm-text-muted);
}
html.theme-dark .empty-state .fw-semibold{
  color: var(--dm-text) !important;
}
.table td, .table th{vertical-align: middle;}
.form-control, .form-select{
  border-radius: .9rem;
  border-color: rgba(17,24,39,.12);
}
.btn{
  border-radius: .9rem;
  transition: background .18s ease, border-color .18s ease, color .18s ease, filter .18s ease;
}
/* Tema uyumlu: tıklanınca/fokus koyu renk olmasın */
.btn:focus,
.btn:focus-visible{
  box-shadow: 0 0 0 3px var(--state-active-border);
  outline: 0;
}
/* Tüm butonlarda hover/active: koyu mavi yok, sadece tema renkleri */
.btn-primary{
  background-color: var(--primary) !important;
  border-color: var(--primary) !important;
  color: var(--state-active-text) !important;
  font-weight: 600;
}
.btn-primary:hover{
  background-color: var(--primary-hover) !important;
  border-color: var(--primary-hover) !important;
  color: var(--state-active-text) !important;
  filter: none;
}
.btn-primary:active,
.btn-primary:focus,
.btn-primary:focus-visible{
  background-color: var(--primary) !important;
  border-color: var(--primary) !important;
  color: var(--state-active-text) !important;
  filter: brightness(0.98);
}
.btn-primary:focus,
.btn-primary:focus-visible{
  box-shadow: 0 0 0 3px rgba(166, 211, 250, 0.5);
}
.btn-light{
  background-color: var(--neutral-10) !important;
  border-color: rgba(17, 24, 39, .1) !important;
  color: var(--state-passive-hover-text) !important;
}
.btn-light:hover{
  background-color: var(--state-passive-hover-bg) !important;
  border-color: rgba(17, 24, 39, .14) !important;
  color: var(--neutral-100) !important;
}
.btn-light:active,
.btn-light:focus,
.btn-light:focus-visible{
  background-color: var(--state-passive-hover-bg) !important;
  border-color: rgba(17, 24, 39, .14) !important;
  color: var(--neutral-100) !important;
}
.btn-light:focus,
.btn-light:focus-visible{
  box-shadow: 0 0 0 3px var(--state-active-border);
}
.btn-outline-secondary{
  background-color: transparent !important;
  border-color: rgba(17, 24, 39, .18) !important;
  color: var(--state-passive-text) !important;
}
.btn-outline-secondary:hover{
  background-color: var(--state-passive-hover-bg) !important;
  border-color: rgba(17, 24, 39, .22) !important;
  color: var(--state-passive-hover-text) !important;
}
.btn-outline-secondary:active,
.btn-outline-secondary:focus,
.btn-outline-secondary:focus-visible{
  background-color: var(--state-passive-hover-bg) !important;
  border-color: rgba(17, 24, 39, .22) !important;
  color: var(--state-passive-hover-text) !important;
}
.btn-outline-secondary:focus,
.btn-outline-secondary:focus-visible{
  box-shadow: 0 0 0 3px var(--state-active-border);
}
.btn-outline-light{
  border-color: rgba(255,255,255,.18);
}
.btn-outline-light:hover{
  background-color: rgba(255,255,255,.1) !important;
  border-color: rgba(255,255,255,.25) !important;
  color: #fff !important;
}
.btn-link{
  color: var(--primary) !important;
}
.btn-link:hover{
  color: var(--primary-pressed) !important;
  background-color: transparent !important;
  border-color: transparent !important;
}
.note-card{
  border-radius: var(--radius-lg);
}
.kanban-drop{
  min-height: 120px;
  border-radius: var(--radius-md);
  transition: background 0.15s ease, box-shadow 0.15s ease;
}
.kanban-drop.kanban-drop-over{
  background: rgba(166,211,250,.12);
  box-shadow: inset 0 0 0 2px var(--primary);
}
.task-card{
  cursor: grab;
  border-radius: var(--radius-md);
}
.task-card:active{
  cursor: grabbing;
}
.reports-tabs{
  background: var(--state-segmented-track);
  padding: 6px;
  border-radius: 14px;
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
}
.reports-tabs .nav-item{
  list-style: none;
}
.reports-tabs .reports-tab{
  border: 0;
  border-radius: 10px;
  color: var(--state-passive-text);
  padding: .5rem 1rem;
  background: transparent;
  transition: color .18s ease, background .18s ease, box-shadow .18s ease;
}
.reports-tabs .reports-tab:hover:not(.active){
  color: var(--state-passive-hover-text);
  background: var(--state-passive-hover-bg);
}
.reports-tabs .reports-tab.active{
  color: var(--state-active-text);
  font-weight: 600;
  background: var(--state-active-bg-strong);
  box-shadow: var(--state-active-shadow);
  border: 1px solid var(--state-active-border);
}
/* Genel nav-tabs: seçili tab beyaz kalmasın, tema rengi */
.nav-tabs .nav-link{
  border: 0;
  border-radius: 10px;
  padding: .5rem 1rem;
  color: var(--state-passive-text);
  background: transparent;
  transition: color .18s ease, background .18s ease;
}
.nav-tabs .nav-link:hover:not(.active){
  color: var(--state-passive-hover-text);
  background: var(--state-passive-hover-bg);
}
.nav-tabs .nav-link.active{
  color: var(--state-active-text);
  font-weight: 600;
  background: var(--state-active-bg-strong);
  border: 1px solid var(--state-active-border);
  box-shadow: var(--state-active-shadow);
}

.report-summary-card{
  border-radius: var(--radius-lg);
}
.category-dot{
  width: 10px;
  height: 10px;
  border-radius: 999px;
  flex-shrink: 0;
}
.category-dist-list li:last-child{
  border-bottom: none !important;
}
.settings-section-title{
  font-size: 1rem;
  font-weight: 600;
  color: rgba(17,24,39,.9);
}
.settings-row:last-child{border-bottom: none !important;}
.form-check-input{
  transition: background-color .18s ease, border-color .18s ease;
}
.form-check-input:checked{
  background-color: var(--primary);
  border-color: var(--primary);
}
.list-group-item{
  transition: background .18s ease, color .18s ease, border-color .18s ease;
}
.list-group-item-action:hover{
  background: var(--state-passive-hover-bg);
}
.list-group-item.active{
  background: var(--state-active-bg);
  border-color: var(--state-active-border);
  color: var(--state-active-text);
  font-weight: 500;
}
.plan-card{border-radius: var(--radius-lg);}
.usage-card{border-radius: var(--radius-md);}
.subscription-usage-item{
  background: var(--bs-body-bg);
  border: 1px solid var(--bs-border-color);
}
.modal-alert{
  font-size: .85rem;
  margin-bottom: .75rem;
  border-radius: var(--radius-md);
}
.topbar-dropdown-btn{
  border-radius: var(--radius-lg);
  padding: .4rem .75rem;
  border: 1px solid rgba(17, 24, 39, .1);
  font-weight: 500;
  color: var(--state-passive-hover-text) !important;
  background-color: var(--neutral-10) !important;
  border-color: rgba(17, 24, 39, .1) !important;
  transition: background .18s ease, border-color .18s ease, color .18s ease;
}
.topbar-dropdown-btn:hover,
.topbar-dropdown-btn:focus,
.topbar-dropdown-btn.show{
  background-color: var(--state-passive-hover-bg) !important;
  border-color: rgba(17, 24, 39, .14) !important;
  color: var(--neutral-100) !important;
}
.topbar-dropdown-menu{
  border-radius: var(--radius-lg);
  border: 1px solid rgba(17,24,39,.08);
  padding: .35rem;
  min-width: 160px;
}
.topbar-dropdown-menu .dropdown-item{
  border-radius: var(--radius-md);
  padding: .5rem .75rem;
  font-size: .9rem;
}
.topbar-dropdown-menu .dropdown-item:hover{
  background: rgba(17,24,39,.04);
}
.topbar-dropdown-menu .dropdown-item.active,
.topbar-dropdown-menu .lang-option.active,
.topbar-dropdown-menu .theme-option.active{
  background: var(--state-active-bg);
  color: var(--state-active-text);
  font-weight: 500;
}
.topbar-dropdown-menu .dropdown-item .bi-check2{
  opacity: 0;
  width: 1rem;
  display: inline-block;
  text-align: center;
}
.topbar-dropdown-menu .dropdown-item.active .bi-check2,
.topbar-dropdown-menu .lang-option.active .bi-check2,
.topbar-dropdown-menu .theme-option.active .bi-check2{
  opacity: 1;
}

/* ========== Koyu tema (renk uyumlu palet) ========== */
html.theme-dark{
  --dm-bg: #0f172a;
  --dm-surface: #1e293b;
  --dm-surface-elevated: #334155;
  --dm-border: rgba(148, 163, 184, 0.12);
  --dm-border-strong: rgba(148, 163, 184, 0.2);
  --dm-text: #f1f5f9;
  --dm-text-muted: #94a3b8;
  --dm-text-subtle: #64748b;
  --dm-primary: #7dd3fc;
  --dm-primary-muted: rgba(125, 211, 252, 0.2);
  --dm-primary-muted-strong: rgba(125, 211, 252, 0.3);
  --dm-accent-bg: rgba(148, 163, 184, 0.08);
  --dm-accent-bg-hover: rgba(148, 163, 184, 0.14);
  --dm-success: #4ade80;
  --dm-danger: #f87171;
  --dm-warning: #fbbf24;
  /* Bootstrap koyu temada koyu mavi kullanmasın */
  --bs-primary: #7dd3fc;
  --bs-primary-rgb: 125, 211, 252;
}

html.theme-dark body.bg-app{
  background: var(--dm-bg);
  color: var(--dm-text);
}

html.theme-dark .topbar{
  background: var(--dm-surface);
  border-bottom-color: var(--dm-border);
  color: var(--dm-text);
}

html.theme-dark .sidebar{
  background: var(--dm-bg);
  border-right-color: var(--dm-border);
  color: var(--dm-text);
}

html.theme-dark .sidebar .brand{
  border-bottom-color: var(--dm-border);
}

html.theme-dark .sidebar .nav-link{
  color: var(--dm-text-muted);
}

html.theme-dark .sidebar .nav-link:hover{
  background: var(--dm-accent-bg);
  color: var(--dm-text);
}

html.theme-dark .sidebar .nav-link.active{
  background: var(--dm-primary-muted-strong);
  color: var(--dm-primary);
  font-weight: 600;
}

html.theme-dark .sidebar .nav-link.active .bi{
  color: var(--dm-primary);
}

html.theme-dark .sidebar .border-top{
  border-color: var(--dm-border) !important;
}

html.theme-dark .sidebar .btn-outline-secondary{
  border-color: var(--dm-border-strong);
  color: var(--dm-text-muted);
}

html.theme-dark .sidebar .btn-outline-secondary:hover{
  background: var(--dm-accent-bg);
  border-color: var(--dm-border-strong);
  color: var(--dm-text);
}

html.theme-dark .sidebar .brand .text-muted,
html.theme-dark .sidebar .small.text-muted{
  color: var(--dm-text-subtle) !important;
}

html.theme-dark .sidebar .rounded-3[style*="background:var(--primary)"]{
  background: var(--dm-primary-muted-strong) !important;
  color: var(--dm-primary) !important;
}
html.theme-dark .sidebar .brand .brand-logo-wrap{
  background: transparent;
}

html.theme-dark .card,
html.theme-dark .card.shadow-soft{
  background: var(--dm-surface);
  border-color: var(--dm-border);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

html.theme-dark .card-body,
html.theme-dark .card-header{
  background: transparent;
  color: var(--dm-text);
  border-color: var(--dm-border);
}

html.theme-dark .text-muted{
  color: var(--dm-text-muted) !important;
}

html.theme-dark h1, html.theme-dark h2, html.theme-dark h3, html.theme-dark h4, html.theme-dark h5, html.theme-dark h6,
html.theme-dark .fw-semibold, html.theme-dark .fw-bold{
  color: var(--dm-text);
}

html.theme-dark .btn-light{
  background-color: var(--dm-surface-elevated) !important;
  border-color: var(--dm-border) !important;
  color: var(--dm-text) !important;
}

html.theme-dark .btn-light:hover{
  background-color: var(--dm-accent-bg-hover) !important;
  border-color: var(--dm-border-strong) !important;
  color: var(--dm-text) !important;
}

html.theme-dark .btn-primary{
  background-color: var(--dm-primary) !important;
  border-color: var(--dm-primary) !important;
  color: #0f172a !important;
}

html.theme-dark .btn-primary:hover{
  background-color: var(--dm-primary) !important;
  border-color: var(--dm-primary) !important;
  color: #0f172a !important;
  filter: brightness(1.08);
}

html.theme-dark .btn-outline-secondary{
  background-color: transparent !important;
  border-color: var(--dm-border-strong) !important;
  color: var(--dm-text-muted) !important;
}

html.theme-dark .btn-outline-secondary:hover{
  background-color: var(--dm-accent-bg) !important;
  border-color: var(--dm-border-strong) !important;
  color: var(--dm-text) !important;
}

html.theme-dark .btn-primary:active,
html.theme-dark .btn-primary:focus,
html.theme-dark .btn-primary:focus-visible{
  background-color: var(--dm-primary) !important;
  border-color: var(--dm-primary) !important;
  color: #0f172a !important;
  filter: brightness(1.05);
}
html.theme-dark .btn-primary:focus,
html.theme-dark .btn-primary:focus-visible{
  box-shadow: 0 0 0 3px var(--dm-primary-muted);
}
html.theme-dark .btn-light:active,
html.theme-dark .btn-light:focus,
html.theme-dark .btn-light:focus-visible{
  background-color: var(--dm-accent-bg-hover) !important;
  border-color: var(--dm-border-strong) !important;
  color: var(--dm-text) !important;
}
html.theme-dark .btn-light:focus,
html.theme-dark .btn-light:focus-visible{
  box-shadow: 0 0 0 3px var(--dm-primary-muted);
}
html.theme-dark .btn-outline-secondary:active,
html.theme-dark .btn-outline-secondary:focus,
html.theme-dark .btn-outline-secondary:focus-visible{
  background-color: var(--dm-accent-bg) !important;
  border-color: var(--dm-border-strong) !important;
  color: var(--dm-text) !important;
}
html.theme-dark .btn-outline-secondary:focus,
html.theme-dark .btn-outline-secondary:focus-visible{
  box-shadow: 0 0 0 3px var(--dm-primary-muted);
}
html.theme-dark .dropdown-item:active,
html.theme-dark .dropdown-item:focus,
html.theme-dark .dropdown-item.show{
  background: var(--dm-accent-bg);
  color: var(--dm-text);
}

html.theme-dark .topbar-dropdown-btn{
  background-color: var(--dm-surface-elevated) !important;
  border-color: var(--dm-border) !important;
  color: var(--dm-text) !important;
}

html.theme-dark .topbar-dropdown-btn:hover,
html.theme-dark .topbar-dropdown-btn:focus,
html.theme-dark .topbar-dropdown-btn.show{
  background-color: var(--dm-accent-bg-hover) !important;
  border-color: var(--dm-border-strong) !important;
  color: var(--dm-text) !important;
}

html.theme-dark .dropdown-menu{
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

html.theme-dark .dropdown-item{
  color: var(--dm-text);
}

html.theme-dark .dropdown-item:hover{
  background: var(--dm-accent-bg);
  color: var(--dm-text);
}

html.theme-dark .dropdown-divider{
  border-color: var(--dm-border);
}

html.theme-dark .topbar-dropdown-menu .dropdown-item.active,
html.theme-dark .topbar-dropdown-menu .lang-option.active,
html.theme-dark .topbar-dropdown-menu .theme-option.active{
  background: var(--dm-primary-muted);
  color: var(--dm-primary);
}

html.theme-dark .avatar{
  background: var(--dm-primary-muted-strong);
  color: var(--dm-primary);
}

html.theme-dark .form-control,
html.theme-dark .form-select{
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  color: var(--dm-text);
}

html.theme-dark .form-control::placeholder{
  color: var(--dm-text-subtle);
}

html.theme-dark .form-control:focus,
html.theme-dark .form-select:focus{
  border-color: var(--dm-primary);
  box-shadow: 0 0 0 3px var(--dm-primary-muted);
}

html.theme-dark .input-group-text{
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  color: var(--dm-text-muted);
}

html.theme-dark .table-light th,
html.theme-dark .table thead th{
  background: var(--dm-surface-elevated) !important;
  color: var(--dm-text-muted) !important;
  border-color: var(--dm-border);
}

html.theme-dark .table td,
html.theme-dark .table th{
  border-color: var(--dm-border);
  color: var(--dm-text);
}

html.theme-dark .table-hover tbody tr:hover{
  background: var(--dm-accent-bg);
}

html.theme-dark .badge.bg-light,
html.theme-dark .badge.bg-light.text-dark{
  background: var(--dm-surface-elevated) !important;
  color: var(--dm-text-muted) !important;
}

html.theme-dark .progress{
  background: var(--dm-surface-elevated);
}

html.theme-dark .progress-bar{
  background: var(--dm-primary);
}

html.theme-dark .progress-bar.bg-warning{
  background: var(--dm-warning);
}

html.theme-dark .text-success{ color: var(--dm-success) !important; }
html.theme-dark .text-danger{ color: var(--dm-danger) !important; }
html.theme-dark .border-light,
html.theme-dark .border-bottom.border-light{
  border-color: var(--dm-border) !important;
}

html.theme-dark .list-group-item,
html.theme-dark .list-group-item-action{
  background: var(--dm-surface);
  border-color: var(--dm-border);
  color: var(--dm-text);
}

html.theme-dark .list-group-item.active{
  background: var(--dm-primary-muted-strong);
  border-color: var(--dm-primary);
  color: var(--dm-primary);
}

html.theme-dark .category-dot{ opacity: .9; }
html.theme-dark .category-pill-shell{
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  box-shadow: none;
}

html.theme-dark .cat-pill{
  background: var(--dm-surface);
  color: var(--dm-text-muted);
}

html.theme-dark .cat-pill.active{
  background: var(--dm-primary-muted-strong);
  border-color: var(--dm-primary);
  color: var(--dm-primary);
}

html.theme-dark .kanban-drop{
  background: var(--dm-surface);
}

html.theme-dark .kanban-drop.kanban-drop-over{
  background: var(--dm-primary-muted);
  box-shadow: inset 0 0 0 2px var(--dm-primary);
}

html.theme-dark .task-card{
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
}

html.theme-dark .report-summary-card,
html.theme-dark .usage-card{
  background: var(--dm-surface-elevated) !important;
  border-color: var(--dm-border);
}

html.theme-dark .settings-section-title{ color: var(--dm-text); }
html.theme-dark .settings-row{ border-color: var(--dm-border); }
html.theme-dark .form-check-input:checked{
  background-color: var(--dm-primary);
  border-color: var(--dm-primary);
}

html.theme-dark .plan-card{
  background: var(--dm-surface);
  border-color: var(--dm-border);
}

html.theme-dark .plan-card .card-body{ color: var(--dm-text); }

html.theme-dark .kpi-card,
html.theme-dark .summary-card{
  background: var(--dm-surface);
  border-color: var(--dm-border);
}

html.theme-dark .subscription-usage-item{
  background: var(--dm-surface);
  border-color: var(--dm-border);
}

html.theme-dark .kpi-meta{ color: var(--dm-text-muted); }
html.theme-dark .kpi-value{
  color: var(--dm-text) !important;
}
html.theme-dark .summary-icon-fx{
  background: var(--dm-primary-muted-strong);
  color: var(--dm-primary);
}
html.theme-dark .summary-card .text-muted{
  color: var(--dm-text-muted) !important;
}
html.theme-dark .summary-value{
  color: var(--dm-text) !important;
}
html.theme-dark .summary-value.text-danger{
  color: var(--dm-danger) !important;
}
html.theme-dark .offcanvas.sidebar{
  background: var(--dm-bg);
  color: var(--dm-text);
}

html.theme-dark .offcanvas .btn-close{
  filter: invert(1);
}

html.theme-dark .modal-content{
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
}

html.theme-dark .modal-header,
html.theme-dark .modal-footer{
  border-color: var(--dm-border);
}

html.theme-dark .modal-title{
  color: var(--dm-text);
}

html.theme-dark .modal .btn-close{
  filter: invert(1);
}

html.theme-dark .alert-light{
  background: var(--dm-accent-bg);
  border-color: var(--dm-border);
  color: var(--dm-text);
}

html.theme-dark .reports-tabs{
  background: var(--dm-surface-elevated);
  border-radius: 14px;
  padding: 6px;
}
html.theme-dark .reports-tabs .reports-tab{
  color: var(--dm-text-muted);
}
html.theme-dark .reports-tabs .reports-tab:hover:not(.active){
  color: var(--dm-text);
  background: var(--dm-accent-bg);
}
html.theme-dark .reports-tabs .reports-tab.active{
  color: var(--dm-primary);
  background: var(--dm-primary-muted-strong);
  border-color: var(--dm-primary);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

html.theme-dark .nav-tabs .nav-link{
  color: var(--dm-text-muted);
  background: transparent;
}
html.theme-dark .nav-tabs .nav-link:hover:not(.active){
  color: var(--dm-text);
  background: var(--dm-accent-bg);
}
html.theme-dark .nav-tabs .nav-link.active{
  color: var(--dm-primary);
  background: var(--dm-primary-muted-strong);
  border-color: var(--dm-primary);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

html.theme-dark .status-chip,
html.theme-dark .status-active,
html.theme-dark .status-archived{
  border: 1px solid var(--dm-border);
}
html.theme-dark .status-active{
  background: rgba(74, 222, 128, 0.15);
  color: var(--dm-success);
}
html.theme-dark .status-archived{
  background: var(--dm-accent-bg);
  color: var(--dm-text-muted);
}

html.theme-dark .filter-bar .card,
html.theme-dark .filter-bar .card-body{
  background: var(--dm-surface) !important;
  border-color: var(--dm-border);
}

html.theme-dark .filter-chip {
  background: var(--dm-primary-muted-strong);
  color: var(--dm-primary);
  border-color: var(--dm-primary);
}
html.theme-dark .filter-chip-remove:hover {
  background: rgba(15, 23, 42, 0.3);
}

html.theme-dark .filter-pill.active {
  background: var(--dm-primary-muted-strong) !important;
  border-color: var(--dm-primary) !important;
  color: var(--dm-primary) !important;
}

html.theme-dark .segmented .btn-group{
  background: var(--dm-surface-elevated);
}
html.theme-dark .btn-seg{
  color: var(--dm-text-muted) !important;
}

html.theme-dark .btn-seg.active{
  background: var(--dm-primary-muted-strong) !important;
  color: var(--dm-primary) !important;
  border-color: var(--dm-primary) !important;
}

html.theme-dark .select-like,
html.theme-dark .dropdown .btn-light.select-like{
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  color: var(--dm-text);
}

html.theme-dark .search-pill .form-control,
html.theme-dark .search-pill .input-group-text{
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  color: var(--dm-text);
}
html.theme-dark .search-pill .input-group-text .bi,
html.theme-dark .search-pill .input-group-text i{
  color: var(--dm-text-muted) !important;
}
/* Genel input-group (search-pill olmayan) koyu mod */
html.theme-dark .input-group .input-group-text{
  background: var(--dm-surface-elevated) !important;
  border-color: var(--dm-border);
  color: var(--dm-text-muted) !important;
}
html.theme-dark .input-group .input-group-text .bi,
html.theme-dark .input-group .input-group-text i{
  color: var(--dm-text-muted) !important;
}

/* ========== Ödeme sayfası – renk uyumu ========== */
.payment-step-num{
  width: 28px;
  height: 28px;
  font-size: .8rem;
  transition: background .18s ease, color .18s ease, border-color .18s ease;
}
.payment-step-done{
  background: var(--state-active-bg);
  color: var(--state-active-text);
  border: 1px solid var(--state-active-border);
}
.payment-step-current{
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}
.payment-step-pending{
  background: transparent;
  color: var(--state-passive-text);
  border: 2px solid var(--border);
}
.payment-card .payment-card-title{
  color: var(--foreground);
}
.payment-icon{
  color: var(--primary);
}
.payment-secure-icon{
  color: var(--state-passive-text);
}
.payment-secure-note{
  color: var(--state-passive-text);
}
.payment-submit-btn{
  background: var(--primary) !important;
  border-color: var(--primary) !important;
  color: #0b2a46 !important;
}
.payment-submit-btn:hover{
  filter: brightness(.96);
  background: var(--primary) !important;
  border-color: var(--primary) !important;
  color: #0b2a46 !important;
}
.payment-summary-card .fw-bold,
.payment-summary-card .fw-semibold{
  color: var(--foreground);
}
.payment-success-icon{
  width: 64px;
  height: 64px;
  background: rgba(31, 175, 73, .12);
  color: var(--success);
}
.payment-success-modal .modal-content{
  border-radius: var(--radius-2xl);
}

/* ========== Global modern modal – tüm popup'lar ========== */
.modal-backdrop {
  background: rgba(11, 42, 70, 0.35);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.modal-backdrop.show {
  animation: modalBackdropIn 0.25s ease-out;
}
@keyframes modalBackdropIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
.modal .modal-dialog {
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.25s ease-out;
}
.modal.show .modal-dialog {
  transform: scale(1);
  opacity: 1;
}
.modal:not(.show) .modal-dialog {
  transform: scale(0.92);
  opacity: 0;
}
.modal .modal-content {
  border-radius: var(--radius-2xl);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.14), 0 0 0 1px rgba(17, 24, 39, 0.04);
  border: 1px solid rgba(17, 24, 39, 0.06);
  overflow: hidden;
  position: relative;
}
.modal .modal-content::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary) 0%, rgba(166, 211, 250, 0.6) 100%);
  opacity: 0.9;
}
.modal .modal-header {
  padding: 1.25rem 1.5rem 0;
  padding-top: 1.5rem;
  border-bottom: none;
  gap: 0.75rem;
}
.modal .modal-title {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--foreground);
}
.modal .modal-body {
  padding: 1rem 1.5rem 1.25rem;
  color: var(--foreground);
}
.modal .modal-footer {
  padding: 0 1.5rem 1.5rem;
  border-top: none;
  gap: 0.5rem;
}
.modal .btn-close {
  opacity: 0.65;
  padding: 0.5rem;
  border-radius: var(--radius-md);
  transition: opacity 0.2s, background 0.2s;
}
.modal .btn-close:hover {
  opacity: 1;
  background: rgba(17, 24, 39, 0.06);
}

/* Modal içi kaydetme loading overlay – şık ve kaliteli */
.modal-loading-overlay {
  background: rgba(255, 255, 255, 0.92) !important;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: opacity 0.2s ease-out;
}
html.theme-dark .modal-loading-overlay {
  background: rgba(18, 24, 32, 0.94) !important;
}
html.theme-dark .modal-loading-overlay .text-muted,
html.theme-dark .modal-loading-overlay .small{
  color: var(--dm-text-muted) !important;
}

html.theme-dark .modal-backdrop {
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(12px);
}
html.theme-dark .modal .modal-content {
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5), 0 0 0 1px var(--dm-border);
  border-color: var(--dm-border);
}
html.theme-dark .modal .modal-content::before {
  background: linear-gradient(90deg, var(--dm-primary) 0%, rgba(166, 211, 250, 0.4) 100%);
}
html.theme-dark .modal .modal-title {
  color: var(--dm-text);
}
html.theme-dark .modal .modal-body {
  color: var(--dm-text);
}
html.theme-dark .modal .btn-close:hover {
  background: var(--dm-accent-bg);
}

/* Yeni Not Ekle modal – tasarım uyumu */
.note-modal-dialog {
  max-width: 520px;
}
.note-modal-content {
  border-radius: var(--radius-2xl);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.14), 0 0 0 1px rgba(17, 24, 39, 0.04);
  border: 1px solid rgba(17, 24, 39, 0.06);
}
.note-modal-header .modal-title {
  font-size: 1.2rem;
  color: var(--foreground);
}
.note-modal-header .modal-title {
  font-size: 1.125rem;
  color: var(--foreground);
}
.note-modal-body {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}
.note-modal-textarea {
  border-radius: var(--radius-md);
  border: 1px solid var(--input-border);
  min-height: 140px;
  resize: vertical;
}
.note-modal-textarea:focus {
  border-color: var(--input-border-focus);
  box-shadow: 0 0 0 3px rgba(166, 211, 250, 0.25);
}
.note-modal-shortcut {
  font-size: 0.8125rem;
}
.note-modal-footer {
  padding-top: 1rem;
  padding-bottom: 1.25rem;
}

html.theme-dark .note-modal-content {
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}
html.theme-dark .note-modal-header .modal-title {
  color: var(--dm-text);
}
html.theme-dark .note-modal-textarea {
  background: var(--dm-surface);
  border-color: var(--dm-border);
  color: var(--dm-text);
}
html.theme-dark .note-modal-textarea:focus {
  border-color: var(--dm-primary);
  box-shadow: 0 0 0 3px var(--dm-primary-muted);
}
html.theme-dark .note-modal-shortcut {
  color: var(--dm-text-muted);
}

/* Görev Ekle / Düzenle modal – Notlar ile uyumlu */
.task-modal-dialog {
  max-width: 520px;
}
.task-modal-content {
  border-radius: var(--radius-2xl);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.14), 0 0 0 1px rgba(17, 24, 39, 0.04);
  border: 1px solid rgba(17, 24, 39, 0.06);
}
.task-modal-header .modal-title {
  font-size: 1.125rem;
  color: var(--foreground);
}
.task-modal-body {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}
.task-modal-body .form-control,
.task-modal-body .form-select {
  border-radius: var(--radius-md);
  border: 1px solid var(--input-border);
}
.task-modal-body .form-control:focus {
  border-color: var(--input-border-focus);
  box-shadow: 0 0 0 3px rgba(166, 211, 250, 0.25);
}
.task-modal-footer {
  padding-top: 1rem;
  padding-bottom: 1.25rem;
}
.task-card {
  transition: background-color 0.15s ease, box-shadow 0.15s ease;
}
.task-card:hover {
  background: var(--neutral-5);
}
.task-card.completed .task-title {
  text-decoration: line-through;
  color: var(--muted-foreground);
}
html.theme-dark .task-modal-content {
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}
html.theme-dark .task-modal-header .modal-title {
  color: var(--dm-text);
}
html.theme-dark .task-modal-body .form-control {
  background: var(--dm-surface);
  border-color: var(--dm-border);
  color: var(--dm-text);
}
html.theme-dark .task-modal-body .form-control:focus {
  border-color: var(--dm-primary);
  box-shadow: 0 0 0 3px var(--dm-primary-muted);
}
html.theme-dark .task-card:hover {
  background: var(--dm-accent-bg);
}
html.theme-dark .task-card.completed .task-title {
  color: var(--dm-text-muted);
}

/* Fatura Bilgilerini Düzenle modal */
.billing-modal-dialog {
  max-width: 500px;
}
.billing-modal-content {
  border-radius: var(--radius-2xl);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.14), 0 0 0 1px rgba(17, 24, 39, 0.04);
  border: 1px solid rgba(17, 24, 39, 0.06);
}
.billing-modal-header .modal-title {
  font-size: 1.125rem;
  color: var(--foreground);
}
.billing-modal-body {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}
.billing-modal-textarea {
  border-radius: var(--radius-md);
  border: 1px solid var(--input-border);
  resize: vertical;
}
.billing-modal-textarea:focus {
  border-color: var(--input-border-focus);
  box-shadow: 0 0 0 3px rgba(166, 211, 250, 0.25);
}
.billing-modal-footer {
  padding-top: 1rem;
  padding-bottom: 1.25rem;
}

html.theme-dark .billing-modal-content {
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}
html.theme-dark .billing-modal-header .modal-title {
  color: var(--dm-text);
}
html.theme-dark .billing-modal-textarea {
  background: var(--dm-surface);
  border-color: var(--dm-border);
  color: var(--dm-text);
}
html.theme-dark .billing-modal-textarea:focus {
  border-color: var(--dm-primary);
  box-shadow: 0 0 0 3px var(--dm-primary-muted);
}

/* Yeni Hesap Ekle modal – tasarım uyumu */
.account-modal-dialog {
  max-width: 480px;
}
.account-modal-content {
  border-radius: var(--radius-2xl);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.14), 0 0 0 1px rgba(17, 24, 39, 0.04);
  border: 1px solid rgba(17, 24, 39, 0.06);
}
.account-modal-header .modal-title {
  font-size: 1.125rem;
  color: var(--foreground);
}
.account-modal-body {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}
.account-modal-body .form-control,
.account-modal-body .form-select {
  border-radius: var(--radius-md);
  border: 1px solid var(--input-border);
}
.account-modal-body .form-control:focus,
.account-modal-body .form-select:focus {
  border-color: var(--input-border-focus);
  box-shadow: 0 0 0 3px rgba(166, 211, 250, 0.25);
}
.account-modal-footer {
  padding-top: 1rem;
  padding-bottom: 1.25rem;
}

html.theme-dark .account-modal-content {
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}
html.theme-dark .account-modal-header .modal-title {
  color: var(--dm-text);
}
html.theme-dark .account-modal-body .form-control,
html.theme-dark .account-modal-body .form-select {
  background: var(--dm-surface);
  border-color: var(--dm-border);
  color: var(--dm-text);
}
html.theme-dark .account-modal-body .form-control:focus,
html.theme-dark .account-modal-body .form-select:focus {
  border-color: var(--dm-primary);
  box-shadow: 0 0 0 3px var(--dm-primary-muted);
}

/* Koyu tema – ödeme sayfası */
html.theme-dark .payment-step-done{
  background: var(--dm-primary-muted-strong);
  color: var(--dm-primary);
  border-color: var(--dm-primary);
}
html.theme-dark .payment-step-current{
  color: var(--dm-primary);
  border-color: var(--dm-primary);
}
html.theme-dark .payment-step-pending{
  color: var(--dm-text-muted);
  border-color: var(--dm-border);
}
html.theme-dark .payment-card .payment-card-title{
  color: var(--dm-text);
}
html.theme-dark .payment-icon{
  color: var(--dm-primary);
}
html.theme-dark .payment-secure-icon,
html.theme-dark .payment-secure-note{
  color: var(--dm-text-muted);
}
html.theme-dark .payment-summary-card .fw-bold,
html.theme-dark .payment-summary-card .fw-semibold{
  color: var(--dm-text);
}
html.theme-dark .payment-success-icon{
  background: rgba(74, 222, 128, .2);
  color: var(--dm-success);
}
html.theme-dark .payment-submit-btn{
  background: var(--dm-primary) !important;
  border-color: var(--dm-primary) !important;
  color: #0f172a !important;
}
html.theme-dark .payment-submit-btn:hover{
  filter: brightness(1.1);
  background: var(--dm-primary) !important;
  border-color: var(--dm-primary) !important;
  color: #0f172a !important;
}

/* ========== Tablo sayfalama (pagination) – modern grid ========== */
.table-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  padding: 0.75rem 1rem;
  background: var(--neutral-5);
  border: 1px solid rgba(17, 24, 39, 0.08);
  border-top: none;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}
.table-toolbar .table-info {
  font-size: 0.875rem;
  color: var(--muted-foreground);
}
.table-toolbar .table-info strong {
  color: var(--foreground);
}
.pagination-modern {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-wrap: wrap;
}
.pagination-modern .page-link {
  min-width: 2.25rem;
  height: 2.25rem;
  padding: 0 0.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--foreground);
  background: var(--neutral-0);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.pagination-modern .page-link:hover {
  background: var(--neutral-10);
  border-color: var(--border-strong);
  color: var(--foreground);
}
.pagination-modern .page-link.active {
  background: var(--state-active-bg);
  border-color: var(--state-active-border);
  color: var(--state-active-text);
  box-shadow: var(--state-active-shadow);
}
.pagination-modern .page-link:disabled,
.pagination-modern .page-link.disabled {
  opacity: 0.5;
  pointer-events: none;
}
.pagination-modern .page-item.sep {
  width: 0.25rem;
  overflow: hidden;
  color: var(--muted-foreground);
}
.rows-per-page-select {
  font-size: 0.875rem;
  padding: 0.35rem 1.75rem 0.35rem 0.5rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--neutral-0);
  color: var(--foreground);
  min-height: 2.25rem;
}
.rows-per-page-select:focus {
  border-color: var(--input-border-focus);
  outline: none;
  box-shadow: 0 0 0 2px rgba(166, 211, 250, 0.3);
}

html.theme-dark .table-toolbar {
  background: var(--dm-surface);
  border-color: var(--dm-border);
}
html.theme-dark .table-toolbar .table-info {
  color: var(--dm-text-muted);
}
html.theme-dark .table-toolbar .table-info strong {
  color: var(--dm-text);
}
html.theme-dark .pagination-modern .page-link {
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  color: var(--dm-text);
}
html.theme-dark .pagination-modern .page-link:hover {
  background: var(--dm-accent-bg);
  border-color: var(--dm-border);
  color: var(--dm-text);
}
html.theme-dark .pagination-modern .page-link.active {
  background: var(--dm-primary-muted-strong);
  border-color: var(--dm-primary);
  color: var(--dm-primary);
}
html.theme-dark .rows-per-page-select {
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  color: var(--dm-text);
}

/* ========== Anasayfa widget dashboard ========== */
.dashboard-widgets-wrap {
  position: relative;
}
.dashboard-edit-toolbar {
  display: none;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
  padding: 0.75rem 1rem;
  background: linear-gradient(135deg, rgba(166, 211, 250, 0.2) 0%, rgba(166, 211, 250, 0.08) 100%);
  border: 1px dashed rgba(17, 24, 39, 0.15);
  border-radius: var(--radius-xl);
}
.dashboard-edit-mode .dashboard-edit-toolbar {
  display: flex;
}
.dashboard-edit-toolbar .btn-add-widget {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}
.dashboard-edit-toolbar .edit-hint {
  font-size: 0.8125rem;
  color: var(--muted-foreground);
}
.dashboard-widgets-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: minmax(100px, auto);
  gap: 1rem 1.25rem;
  transition: opacity 0.2s ease;
}
@media (max-width: 1199px) {
  .dashboard-widgets-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 767px) {
  .dashboard-widgets-grid { grid-template-columns: 1fr; }
}
.dashboard-widget {
  min-height: 0;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.dashboard-widget .card {
  height: 100%;
  transition: box-shadow 0.2s, border-color 0.2s;
}
.dashboard-edit-mode .dashboard-widget {
  cursor: grab;
  position: relative;
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}
.dashboard-edit-mode .dashboard-widget:active {
  cursor: grabbing;
}
.dashboard-edit-mode .dashboard-widget .card {
  border: 2px dashed rgba(17, 24, 39, 0.12);
  border-radius: var(--radius-xl);
}
.dashboard-edit-mode .dashboard-widget:hover .card {
  border-color: rgba(166, 211, 250, 0.5);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}
.dashboard-widget.dashboard-widget-dragging .card {
  opacity: 0.85;
  transform: scale(0.98);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  border-color: var(--primary);
  z-index: 10;
}
.dashboard-widget.dashboard-widget-drag-over {
  outline: none;
}
.dashboard-widget.dashboard-widget-drag-over .card {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(166, 211, 250, 0.4);
}
.widget-drag-handle,
.widget-remove {
  position: absolute;
  z-index: 5;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-md);
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: var(--muted-foreground);
  background: var(--neutral-0);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
  transition: color 0.2s, background 0.2s, border-color 0.2s;
}
.dashboard-edit-mode .widget-drag-handle,
.dashboard-edit-mode .widget-remove {
  display: inline-flex;
}
.widget-drag-handle {
  top: 0.5rem;
  left: 0.5rem;
  cursor: grab;
}
.widget-drag-handle:active {
  cursor: grabbing;
}
.widget-drag-handle:hover {
  color: var(--foreground);
  background: var(--neutral-10);
  border-color: var(--border-strong);
}
.widget-remove {
  top: 0.5rem;
  right: 0.5rem;
  cursor: pointer;
}
.widget-remove:hover {
  color: var(--danger);
  background: var(--danger-light);
  border-color: rgba(239, 77, 72, 0.3);
}
.dashboard-widget[data-size="wide"] {
  grid-column: span 2;
}
.dashboard-widget[data-size="tall"] {
  grid-row: span 2;
}
@media (max-width: 1199px) {
  .dashboard-widget[data-size="wide"] { grid-column: span 2; }
  .dashboard-widget[data-size="tall"] { grid-row: span 2; }
}
@media (max-width: 767px) {
  .dashboard-widget[data-size="wide"] { grid-column: span 1; }
  .dashboard-widget[data-size="tall"] { grid-row: span 1; }
}
.widget-size-btn {
  position: absolute;
  bottom: 0.5rem;
  right: 0.5rem;
  z-index: 5;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-md);
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  color: var(--muted-foreground);
  background: var(--neutral-0);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
  cursor: pointer;
  transition: color 0.2s, background 0.2s;
}
.dashboard-edit-mode .widget-size-btn {
  display: inline-flex;
}
.widget-size-btn:hover {
  color: var(--foreground);
  background: var(--neutral-10);
  border-color: var(--border-strong);
}
html.theme-dark .widget-size-btn {
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  color: var(--dm-text-muted);
}
html.theme-dark .widget-size-btn:hover {
  color: var(--dm-text);
  background: var(--dm-accent-bg);
}
#widgetPool {
  display: none;
}
.dashboard-empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 2.5rem 1.5rem;
  background: var(--neutral-5);
  border: 2px dashed var(--border);
  border-radius: var(--radius-xl);
  color: var(--muted-foreground);
}
.dashboard-edit-mode .dashboard-empty-state {
  border-color: rgba(166, 211, 250, 0.4);
  background: rgba(166, 211, 250, 0.06);
}
.dropdown-menu-widgets {
  min-width: 240px;
  max-height: 280px;
  overflow-y: auto;
}
.dropdown-menu-widgets .dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.dropdown-menu-widgets .dropdown-item i {
  font-size: 1.1rem;
  opacity: 0.9;
}

html.theme-dark .dashboard-edit-toolbar {
  background: linear-gradient(135deg, var(--dm-primary-muted) 0%, rgba(166, 211, 250, 0.06) 100%);
  border-color: var(--dm-border);
}
html.theme-dark .dashboard-edit-toolbar .edit-hint {
  color: var(--dm-text-muted);
}
html.theme-dark .dashboard-edit-mode .dashboard-widget .card {
  border-color: var(--dm-border);
}
html.theme-dark .dashboard-edit-mode .dashboard-widget:hover .card {
  border-color: var(--dm-primary);
}
html.theme-dark .dashboard-widget.dashboard-widget-dragging .card {
  border-color: var(--dm-primary);
}
html.theme-dark .dashboard-widget.dashboard-widget-drag-over .card {
  border-color: var(--dm-primary);
}
html.theme-dark .widget-drag-handle,
html.theme-dark .widget-remove {
  background: var(--dm-surface-elevated);
  border-color: var(--dm-border);
  color: var(--dm-text-muted);
}
html.theme-dark .widget-drag-handle:hover {
  color: var(--dm-text);
  background: var(--dm-accent-bg);
}
html.theme-dark .widget-remove:hover {
  color: var(--danger);
  background: var(--danger-light);
}
html.theme-dark .dashboard-empty-state {
  background: var(--dm-surface);
  border-color: var(--dm-border);
  color: var(--dm-text-muted);
}
html.theme-dark .dashboard-edit-mode .dashboard-empty-state {
  background: var(--dm-primary-muted);
  border-color: var(--dm-primary);
}

.content-wrap{min-height: calc(100vh - 64px);}

/* Yardım sayfası – accordion tema uyumu */
.help-page-icon{
  background: rgba(166, 211, 250, 0.35);
  color: #0b2a46;
}
html.theme-dark .help-page-icon{
  background: var(--dm-primary-muted-strong);
  color: var(--dm-primary);
}
.help-page .accordion-button {
  background: var(--neutral-0);
  color: var(--foreground);
  border: none;
  box-shadow: none;
}
.help-page .accordion-button:not(.collapsed) {
  background: var(--neutral-5);
  color: var(--foreground);
  box-shadow: none;
}
.help-page .accordion-button:hover {
  background: var(--state-passive-hover-bg);
}
.help-page .accordion-button:focus {
  box-shadow: 0 0 0 2px var(--state-active-border);
  border-color: transparent;
}
.help-page .accordion-body {
  background: var(--neutral-0);
  padding: 1rem 1.25rem;
}
html.theme-dark .help-page .accordion-button {
  background: var(--dm-surface);
  color: var(--dm-text);
}
html.theme-dark .help-page .accordion-button:not(.collapsed) {
  background: var(--dm-surface-elevated);
}
html.theme-dark .help-page .accordion-button:hover {
  background: var(--dm-accent-bg);
}
html.theme-dark .help-page .accordion-body {
  background: var(--dm-surface);
  color: var(--dm-text);
}
html.theme-dark .help-page .accordion-body .text-muted,
html.theme-dark .help-page .accordion-body ol li{
  color: var(--dm-text-muted) !important;
}
html.theme-dark .help-page .accordion-item{
  background: var(--dm-surface);
  border-color: var(--dm-border);
}

/* Firmalar tablosu – satır arka planları tema uyumlu */
.companies-table thead th{
  background: var(--neutral-10);
  color: var(--neutral-80);
  font-weight: 600;
  border-color: var(--border);
}
.companies-table tbody td{
  background: var(--card);
  color: var(--foreground);
  border-color: var(--border);
}
.companies-table tbody tr:nth-of-type(even) td{
  background: var(--neutral-5);
}
.companies-table tbody tr.table-secondary td{
  background: var(--neutral-15);
}
html.theme-dark .companies-table thead th{
  background: var(--dm-surface-elevated) !important;
  color: var(--dm-text-muted) !important;
  border-color: var(--dm-border);
}
html.theme-dark .companies-table tbody td{
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border);
}
html.theme-dark .companies-table tbody tr:nth-of-type(even) td{
  background: var(--dm-surface-elevated) !important;
  color: var(--dm-text) !important;
}
html.theme-dark .companies-table tbody tr.table-secondary td{
  background: var(--dm-accent-bg) !important;
  color: var(--dm-text) !important;
}

/* Firmalar – ücretsiz plan bilgi kutusu (tema uyumlu) */
.company-free-limit-info{
  background: rgba(166, 211, 250, 0.2);
  border: 1px solid rgba(166, 211, 250, 0.35);
}
html.theme-dark .company-free-limit-info{
  background: var(--dm-primary-muted);
  border-color: var(--dm-primary-muted-strong);
}
html.theme-dark .company-free-limit-info .text-primary{
  color: var(--dm-primary) !important;
}

/* Sayfa yardım (rehber) ikonu – tüm ekranlarda sabit */
.page-help-float {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 50%;
  background: var(--primary);
  color: var(--primary-foreground);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  z-index: 9999;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
}
.page-help-float:hover {
  color: var(--primary-foreground);
  transform: scale(1.08);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}
html.theme-dark .page-help-float {
  background: var(--dm-primary);
  color: var(--dm-primary-foreground);
}
