/* ================= Base ================= */
body {
  font-family: Inter, ui-sans-serif, system-ui;
  transition: background-color .25s, color .25s;
}

* {
  transition: background-color 0.3s ease, color 0.3s ease;
}

.nav-btn.active svg {
  transform: scale(1.12);
}

svg {
  color: inherit;
  transition: transform .2s ease;
}

.nav-btn:hover svg {
  transform: scale(1.08);
}

/* ================= Mobile Navbar ================= */
#mobile-navbar {
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

@media (min-width:1025px) {
  #mobile-navbar {
    display: none;
  }
}
@media (max-width:1025px) {
  #sidebar {
    display: none !important;

  }
}

/* ================= Card ================= */
.card {
  padding: 20px;
  border-radius: 16px;
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.10);
  transition: .35s all;
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 28px black;
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
}

.card h3,
.card p,
.card svg {
  transition: color .4s ease;
}

.card:hover h3,
.card:hover p,
.card:hover svg {
  color: white !important;
  stroke: white !important;
}

.card-icon:hover {
  transform: scale(1.08);
}

/* ================= Dark / Light Mode ================= */
.light .card {
  background: white;
  box-shadow: 0 2px 10px rgba(255, 255, 255, 0.06);
}

.dark body {
  background: rgba(255, 255, 255, 0.06);
  color: #f9fafb;
}

.dark .card {
  background: #1f2937;
  color: #f9fafb;
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.06);
}

.dark .card:hover {
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
}

.light .active-tab {
  background: #4f46e5;
  color: white;
}

.dark .active-tab {
  background: #6366f1 !important;
  color: white !important;
}

.dark input,
.dark button {
  border-color: #334155;
  color: white;
}

.mode-btn {
  position: fixed;
  top: 18px;
  right: 18px;
  background: #4f46e5;
  color: white;
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  transition: .3s;
}

.dark .mode-btn {
  background: #6366f1;
}

/* ================= Date Input ================= */
.dark .date-box,
.dark input[type="date"] {
  background: #1f2937;
  border-color: #374151;
  color: #e5e7eb;
}

/* ================= Glass Panels ================= */
.glass {
  background: rgba(255, 255, 255, .75);
  backdrop-filter: blur(12px);
}

.dark .glass {
  background: rgba(15, 23, 42, .6);
}

/* ================= Scrollbar ================= */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background-color: rgba(100, 116, 139, .4);
  border-radius: 999px;
}

::-webkit-scrollbar-thumb:hover {
  background-color: rgba(100, 116, 139, .65);
}

* {
  scrollbar-width: thin;
  scrollbar-color: rgba(100, 116, 139, .5) transparent;
}

/* ================= Tables ================= */
table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

th,
td {
  padding: 8px;
  font-size: 12px;
  white-space: nowrap;
}

thead th {
  background: #f1f5f9;
  position: sticky;
  top: 0;
  z-index: 10;
  font-weight: 600;
  border-bottom: 2px solid #e5e7eb;
}

tbody tr:hover {
  background: #f8fafc;
}

tfoot td {
  font-weight: 700;
  background: #e2e8f0;
}

.dark thead th {
  background: #1e293b;
  color: #f1f5f9;
  border-bottom-color: #334155;
}

.dark tbody tr:hover {
  background: #334155;
}

.dark tfoot td {
  background: #1e293b;
  color: #f1f5f9;
}

/* ================= Animations ================= */
.bot-open {
  animation: botOpen .3s ease forwards;
}

.bot-close {
  animation: botClose .25s ease forwards;
}

@keyframes botOpen {
  from {
    transform: scale(.85);
    opacity: 0;
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes botClose {
  from {
    transform: scale(1);
    opacity: 1;
  }

  to {
    transform: scale(.85);
    opacity: 0;
  }
}

.msg-appear {
  animation: msgAppear .25s ease forwards;
}

@keyframes msgAppear {
  from {
    transform: translateY(10px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.welcome-card {
  opacity: 0;
  transform: translateY(15px) scale(.95);
  animation: welcomeShow .4s ease forwards;
}

.welcome-hide {
  animation: welcomeHide .35s ease forwards;
}

@keyframes welcomeShow {
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes welcomeHide {
  to {
    opacity: 0;
    transform: translateY(15px) scale(.9);
  }
}

.animate-pop {
  transform: scale(.9);
  opacity: 0;
  animation: popIn .3s forwards;
}

@keyframes popIn {
  to {
    transform: scale(1);
    opacity: 1;
  }
}

#chartCanvas {
  max-height: 250px;
  width: 100% !important;
}

#notification {
  transition: opacity .5s ease, transform .5s ease;
  transform: translateY(-20px);
}

#notification.show {
  opacity: 1;
  transform: translateY(0);
}

#notification.opacity-100 {
  transform: translateY(0);
}

.active-tab {
  background: #4f46e5;
  color: #fff
}

.itemBox {
  padding: 14px;
  border-radius: 10px;
  text-align: center;
  font-weight: 600
}

.animate-fadeIn {
  animation: fade .35s ease
}

@keyframes fade {
  from {
    opacity: 0;
    transform: translateY(10px)
  }

  to {
    opacity: 1;
    transform: translateY(0)
  }
}

/* Web (sm dan yuqori) — hammasi ko‘rinsin */
@media(min-width:640px) {

  #kirimBox,
  #chiqimBox,
  #qoldiqBox {
    display: block !important;
  }
}

/* Mobile — faqat tanlangan ko‘rinsin */
@media(max-width:639px) {

  #kirimBox,
  #chiqimBox,
  #qoldiqBox {
    display: none;
  }

  .activeBox {
    display: block !important;
  }
}


.btn.active {
  background: #2563eb !important;
  color: #fff !important;
  transform: scale(1.05);
}

@keyframes fade {
  from {
    opacity: .2;
    transform: translateY(-5px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.animate-fade {
  animation: .6s fade;
}

/* Mobil uchun Ortga tugmasini yashirish */
@media(max-width:640px) {
  #backBtnSidebar {
    display: none;
  }
}