/* ============================================================
   Somiti (অগ্রযাত্রা সমবায় সমিতি) - High-Productivity Design System
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Hind+Siliguri:wght@400;500;600;700&family=Outfit:wght@400;500;600;700&display=swap');

:root {
  --font-bengali: 'Hind Siliguri', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-numeric: 'Outfit', 'Hind Siliguri', sans-serif;
  
  --primary: #059669;
  --primary-hover: #047857;
  --primary-light: #ecfdf5;
  --primary-glow: rgba(5, 150, 105, 0.25);
  
  --dark-sidebar: #090e17;
  --dark-card: #111827;
  --dark-border: #1f2937;
  
  --slate-bg: #f8fafc;
  --card-bg: #ffffff;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
}

* {
  box-sizing: border-box;
}

body {
  font-family: var(--font-bengali);
  background-color: var(--slate-bg);
  color: var(--text-main);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Numeric typography */
.font-num {
  font-family: var(--font-numeric);
}

/* Custom Scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes pulseGlow {
  0%, 100% {
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.25);
  }
  50% {
    box-shadow: 0 0 25px rgba(16, 185, 129, 0.5);
  }
}

.animate-fade-in {
  animation: fadeInUp 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.animate-scale-in {
  animation: scaleIn 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.glow-active {
  animation: pulseGlow 3s infinite;
}

/* Card hover subtle elevation */
.card-hover {
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s ease;
}

.card-hover:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 28px -6px rgba(0, 0, 0, 0.07), 0 10px 14px -6px rgba(0, 0, 0, 0.04);
}

/* Member Grid Card Styles */
.member-grid-card {
  transition: all 0.25s ease;
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  background: #ffffff;
}

.member-grid-card:hover {
  border-color: #10b981;
  transform: translateY(-3px);
  box-shadow: 0 14px 24px -6px rgba(16, 185, 129, 0.15);
}

/* Chart Canvas Responsive Wrappers */
.chart-container {
  position: relative;
  width: 100%;
  max-width: 100%;
  height: 250px;
}

/* Toast Notifications */
#toast-container {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1.25rem;
  border-radius: 0.875rem;
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: 0 12px 20px -3px rgba(0, 0, 0, 0.15), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  animation: fadeInUp 0.3s ease forwards;
  max-width: 26rem;
}

.toast-success {
  background-color: #064e3b;
  color: #ecfdf5;
  border: 1px solid #059669;
}

.toast-error {
  background-color: #881337;
  color: #ffe4e6;
  border: 1px solid #e11d48;
}

.toast-info {
  background-color: #0f172a;
  color: #f8fafc;
  border: 1px solid #334155;
}

/* Quick Date Buttons */
.quick-date-btn {
  padding: 0.25rem 0.625rem;
  font-size: 0.75rem;
  border-radius: 0.5rem;
  background-color: #f1f5f9;
  color: #475569;
  font-weight: 500;
  transition: all 0.15s ease;
}

.quick-date-btn:hover {
  background-color: #e2e8f0;
  color: #0f172a;
}

/* Drag-and-drop restore zone */
.dropzone {
  border: 2px dashed #94a3b8;
  border-radius: 1rem;
  padding: 2.25rem 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  background-color: #f8fafc;
}

.dropzone:hover, .dropzone.dragover {
  border-color: #059669;
  background-color: #ecfdf5;
}

/* Digital ID Card styling */
.id-card-wrap {
  background: linear-gradient(135deg, #064e3b 0%, #065f46 50%, #022c22 100%);
  color: white;
  border-radius: 1.25rem;
  padding: 1.5rem;
  box-shadow: 0 20px 25px -5px rgba(6, 78, 59, 0.4);
}

/* Print specific formatting */
@media print {
  .no-print,
  #toast-container,
  aside,
  header {
    display: none !important;
  }

  .print-only {
    display: block !important;
  }

  body {
    background: white !important;
    color: black !important;
    font-size: 11pt;
    padding: 0 !important;
    margin: 0 !important;
  }

  #receiptModal {
    position: static !important;
    background: white !important;
    padding: 0 !important;
    display: block !important;
  }

  #receipt-printable-card {
    border: 1px dashed #64748b !important;
    box-shadow: none !important;
    max-width: 100% !important;
    margin: 0 auto !important;
    padding: 1.5rem !important;
  }

  #view-reports {
    display: block !important;
  }

  #view-dashboard,
  #view-members,
  #view-collections,
  #view-investments,
  #view-expenses,
  #view-backup {
    display: none !important;
  }
}

.print-only {
  display: none;
}
