body {
    background-color: #f4f6fb;
    font-family: 'Segoe UI', 'Roboto', Arial, sans-serif;
    transition: background 0.3s, color 0.3s;
}
body.dark-mode {
    background-color: #181c24;
    color: #e9ecef;
}

.navbar {
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: background 0.3s, color 0.3s;
}
body.dark-mode .navbar {
    background: #232a36 !important;
}

.navbar-brand {
    font-weight: bold;
    letter-spacing: 1px;
    font-size: 1.5rem;
}

.nav-link {
    transition: color 0.2s, background 0.2s;
    border-radius: 0.3rem;
    margin-right: 0.2rem;
}
.nav-link:hover, .nav-link.active {
    background: #e3eafc;
    color: #0d6efd !important;
}
body.dark-mode .nav-link:hover, body.dark-mode .nav-link.active {
    background: #232a36;
    color: #ffd43b !important;
}

.dashboard-card {
    border: none;
    box-shadow: 0 2px 16px rgba(0,0,0,0.07);
    transition: transform 0.2s, box-shadow 0.2s, background 0.3s, color 0.3s;
    cursor: pointer;
    background: #fff;
}
.dashboard-card:hover {
    transform: translateY(-6px) scale(1.03);
    box-shadow: 0 6px 24px rgba(13,110,253,0.10);
}
body.dark-mode .dashboard-card {
    background: #232a36;
    color: #e9ecef;
    box-shadow: 0 2px 16px rgba(0,0,0,0.18);
}

.animate-fade-in {
    animation: fadeIn 0.7s;
}
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: none; }
}

#main-content {
    padding: 2rem 0;
    min-height: 60vh;
}

.table {
    background: #fff;
    border-radius: 0.5rem;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    animation: fadeInTable 0.6s;
}
@keyframes fadeInTable {
    from { opacity: 0; transform: scale(0.98); }
    to { opacity: 1; transform: none; }
}
body.dark-mode .table {
    background: #232a36;
    color: #e9ecef;
}
body.dark-mode .table-light th {
    background: #232a36;
    color: #ffd43b;
}

.spinner-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
}

/* Modal */
.modal-content {
    border-radius: 1rem;
    transition: background 0.3s, color 0.3s;
}
body.dark-mode .modal-content {
    background: #232a36;
    color: #e9ecef;
}

/* Toasts */
.toast {
    border-radius: 0.5rem;
    background: #fff;
    color: #232a36;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: background 0.3s, color 0.3s;
}
body.dark-mode .toast {
    background: #232a36;
    color: #ffd43b;
}

/* Search input */
.table-search {
    margin-bottom: 1rem;
    max-width: 350px;
    border-radius: 2rem;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
    border: 1px solid #dee2e6;
    padding-left: 2.5rem;
    background: #fff url('data:image/svg+xml;utf8,<svg fill="gray" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path d="M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001l3.85 3.85a1 1 0 0 0 1.415-1.415l-3.85-3.85zm-5.242 1.106a5 5 0 1 1 0-10 5 5 0 0 1 0 10z"/></svg>') no-repeat 0.75rem center/1.2rem 1.2rem;
}
body.dark-mode .table-search {
    background-color: #232a36;
    color: #ffd43b;
    border: 1px solid #444857;
}

/* Tooltip */
.tooltip-inner {
    background: #232a36;
    color: #ffd43b;
    border-radius: 0.5rem;
    font-size: 1rem;
    padding: 0.5rem 1rem;
}

/* Sidebar custom styles */
#mobileSidebar .offcanvas-title {
  font-weight: 600;
}
#mobileSidebar .navbar-nav .nav-link {
  font-size: 1.1rem;
  padding: 0.75rem 1rem;
}
#mobileSidebar .nav-item.mt-3 {
  margin-top: 2rem !important;
}
#darkModeToggleSidebar {
  margin-top: 1rem;
} 

/* --- Modern UI Enhancements for Finance Module and General Use --- */

/* Card hover and active transitions */
.card, .dashboard-card {
  transition: box-shadow 0.3s cubic-bezier(.4,2,.6,1), transform 0.2s cubic-bezier(.4,2,.6,1);
  border-radius: 1.1rem;
}
.card:hover, .dashboard-card:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.12), 0 1.5px 6px rgba(0,0,0,0.08);
  transform: translateY(-2px) scale(1.02);
}
.card:active, .dashboard-card:active {
  box-shadow: 0 2px 8px rgba(0,0,0,0.10);
  transform: scale(0.98);
}

/* Tab transitions */
.nav-tabs .nav-link {
  transition: background 0.2s, color 0.2s;
  border-radius: 0.7rem 0.7rem 0 0;
}
.nav-tabs .nav-link.active {
  background: linear-gradient(90deg, #e0e7ff 0%, #f8fafc 100%);
  color: #0d6efd;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(13,110,253,0.08);
}

/* Button hover/active effects */
.btn {
  transition: box-shadow 0.2s, transform 0.15s;
  border-radius: 0.7rem;
}
.btn:hover {
  box-shadow: 0 4px 16px rgba(13,110,253,0.10);
  transform: translateY(-1px) scale(1.03);
}
.btn:active {
  box-shadow: 0 1px 4px rgba(13,110,253,0.08);
  transform: scale(0.97);
}

/* Modal enhancements */
.modal-content {
  border-radius: 1.2rem;
  box-shadow: 0 8px 32px rgba(0,0,0,0.18);
  border: none;
}

/* Chart fade-in animation */
canvas {
  opacity: 0;
  animation: chartFadeIn 0.7s cubic-bezier(.4,2,.6,1) 0.1s forwards;
}
@keyframes chartFadeIn {
  to { opacity: 1; }
}

/* Subtle confetti animation for payment success */
.confetti {
  position: fixed;
  top: 0; left: 0; width: 100vw; height: 100vh;
  pointer-events: none;
  z-index: 2000;
}
.confetti-piece {
  position: absolute;
  width: 10px; height: 18px;
  border-radius: 3px;
  opacity: 0.85;
  animation: confetti-fall 1.2s cubic-bezier(.4,2,.6,1) forwards;
}
@keyframes confetti-fall {
  0% { transform: translateY(-40px) rotate(0deg); opacity: 0.7; }
  80% { opacity: 1; }
  100% { transform: translateY(100vh) rotate(360deg); opacity: 0; }
}

/* Finance module specific tweaks */
#module-finance .card, #module-finance .dashboard-card {
  background: linear-gradient(135deg, #f8fafc 60%, #e0e7ff 100%);
  border: none;
}
#module-finance .btn {
  font-size: 1.05rem;
  letter-spacing: 0.01em;
} 

form.animate-fade-in, .card form.animate-fade-in {
  animation: none !important;
} 