@import url("https://fonts.googleapis.com/css2?family=Tiro+Bangla:ital@0;1&family=Ubuntu:ital,wght@0,300;0,400;0,500;0,700;1,300;1,400;1,500;1,700&display=swap");

/* Use Ubuntu for English digits and ASCII letters inside Bangla text */
.bangla-ubuntu-fix,
body,
html,
[lang="bn"] {
  font-family: "Tiro Bangla", sans-serif;
}
.bangla-ubuntu-fix :is(span.en, .en, .ascii, .latin, .eng, .num, .number),
body :is(span.en, .en, .ascii, .latin, .eng, .num, .number),
html :is(span.en, .en, .ascii, .latin, .eng, .num, .number),
[lang="bn"] :is(span.en, .en, .ascii, .latin, .eng, .num, .number) {
  font-family: "Ubuntu", sans-serif !important;
  letter-spacing: 0.01em;
}

/* Automatic font for digits and ASCII letters using unicode-range (for modern browsers) */
@font-face {
  font-family: "UbuntuForDigits";
  src: local("Ubuntu"),
    url("https://fonts.gstatic.com/s/ubuntu/v20/4iCs6KVjbNBYlgoKcg72j00.woff2")
      format("woff2");
  unicode-range: U+0030-0039, U+0041-005A, U+0061-007A;
  font-style: normal;
  font-weight: 400;
}
body,
html,
[lang="bn"] {
  font-family: "Tiro Bangla", "UbuntuForDigits", sans-serif;
}

/* Purple Gradient Theme - Modern Compact Design */

/* Theme Variables */
:root {
  /* Purple Gradient Theme Colors */
  --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --secondary-gradient: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
  --success-gradient: linear-gradient(135deg, #d299c2 0%, #fef9d7 100%);
  --warning-gradient: linear-gradient(135deg, #fad0c4 0%, #ffd1ff 100%);
  --danger-gradient: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%);

  /* Background Gradients */
  --bg-gradient: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
  --card-gradient: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);

  /* Text Colors */
  --text-primary: #2d3748;
  --text-secondary: #4a5568;
  --text-muted: #718096;
  --text-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);

  /* Spacing and Sizing */
  --border-radius-sm: 0.375rem;
  --border-radius-md: 0.5rem;
  --border-radius-lg: 0.75rem;
  --border-radius-xl: 1rem;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07), 0 2px 4px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1), 0 4px 6px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.1), 0 10px 10px rgba(0, 0, 0, 0.04);

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-base: 0.2s ease;
  --transition-slow: 0.3s ease;
}

/* Purple Gradient Theme Utilities */
.gradient-bg {
  background: var(--primary-gradient);
}

.card-shadow {
  box-shadow: var(--shadow-xl);
}

.btn-hover {
  transition: all var(--transition-slow);
}

.btn-hover:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.animate-float {
  animation: subtleFloat 4s ease-in-out infinite;
}

@keyframes subtleFloat {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-4px);
  }
}

.text-gradient {
  background: var(--text-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Mobile-first responsive improvements */
@media (max-width: 768px) {
  .modern-btn {
    padding: 0.75rem 1.25rem;
    font-size: 0.95rem;
    min-height: 44px; /* Optimal touch targets */
  }

  .modern-input {
    padding: 0.75rem 1rem;
    font-size: 1rem;
    min-height: 44px;
  }

  .page-title {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
  }

  .page-subtitle {
    font-size: 0.95rem;
    margin-bottom: 1rem;
  }

  .modern-card {
    padding: 1rem;
    margin-bottom: 1rem;
  }

  /* Compact grid on mobile */
  .grid {
    grid-template-columns: 1fr !important;
    gap: 0.75rem;
  }

  .container {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
}

/* Compact section cards - Purple Gradient Theme */
.modern-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border-radius: 1.5rem;
  box-shadow: var(--shadow-xl);
  border: 1px solid rgba(102, 126, 234, 0.2);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  transition: all var(--transition-slow);
  position: relative;
  overflow: hidden;
}

.modern-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(102, 126, 234, 0.3);
  border-color: rgba(102, 126, 234, 0.3);
}

/* Compact form labels */
.form-label {
  font-size: 0.95rem;
  font-weight: 500;
  color: #374151;
  margin-bottom: 0.5rem;
  display: block;
}

/* Required field indicator */
.required::after {
  content: " *";
  color: #dc2626;
  font-weight: bold;
}

/* Compact spacing between form fields */
.form-group {
  margin-bottom: 1rem;
}

/* Simple loading indicator */
.loading {
  position: relative;
  pointer-events: none;
  opacity: 0.7;
}

.loading::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid #ffffff;
  border-radius: 50%;
  border-top-color: transparent;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Prevent horizontal overflow */
* {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
  width: 100%;
}

body {
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
  margin: 0;
  padding: 0;
  background: linear-gradient(135deg, #fafafa 0%, #f9fafb 50%, #f3f4f6 100%);
  min-height: 100vh;
  color: #1f2937;
  font-family: "Tiro Bangla", "Ubuntu", sans-serif;
  line-height: 1.5;
  font-size: 0.95rem;
}

/* Better container defaults */
.container {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1rem;
  padding-right: 1rem;
}

/* Ensure full width utilization */
.mx-auto {
  margin-left: auto;
  margin-right: auto;
}

.px-4 {
  padding-left: 1rem;
  padding-right: 1rem;
}

/* Override Tailwind's container if it's too restrictive */
@media (min-width: 640px) {
  .container {
    max-width: 640px;
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

@media (min-width: 768px) {
  .container {
    max-width: 768px;
  }
}

@media (min-width: 1024px) {
  .container {
    max-width: 1024px;
  }
}

@media (min-width: 1280px) {
  .container {
    max-width: 1280px;
  }
}

/* Modern Animation Classes - Subtle */
.animate-fade-in {
  animation: subtleFadeIn 0.3s ease-out both;
}

@keyframes subtleFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-slide-up {
  animation: subtleSlideUp 0.2s ease-out both;
}

@keyframes subtleSlideUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-scale-in {
  animation: subtleScaleIn 0.2s ease-out both;
}

@keyframes subtleScaleIn {
  from {
    opacity: 0;
    transform: scale(0.98);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Clean Report Section Styles - Minimal Design */
.report-section {
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 4px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.report-section h2 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #f3f4f6;
}

/* Modern Button Styles - Purple Gradient Theme */
.modern-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: var(--border-radius-lg);
  transition: all var(--transition-slow);
  text-decoration: none;
  border: none;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  min-height: 44px;
  background: var(--primary-gradient);
  color: white;
  overflow: hidden;
}

.modern-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: left 0.5s;
}

.modern-btn:hover::before {
  left: 100%;
}

.modern-btn:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-xl);
}

.modern-btn:active {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--primary-gradient);
  color: white;
}

.btn-primary:hover {
  box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
  background: var(--secondary-gradient);
  color: #4a5568;
}

.btn-success {
  background: var(--success-gradient);
  color: #2d3748;
}

.btn-warning {
  background: var(--warning-gradient);
  color: #2d3748;
}

.btn-danger {
  background: var(--danger-gradient);
  color: white;
}

.btn-outline {
  background: rgba(255, 255, 255, 0.9);
  color: #667eea;
  border: 2px solid #667eea;
  backdrop-filter: blur(10px);
}

.btn-outline:hover {
  background: var(--primary-gradient);
  color: white;
  border-color: transparent;
}

/* Modern Form Styles - Compact and Mobile-Friendly */
.modern-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #d1d5db;
  border-radius: var(--border-radius-md);
  font-size: 1rem;
  line-height: 1.5;
  transition: all var(--transition-fast);
  background: #ffffff;
  color: #1f2937;
  min-height: 44px;
}

.modern-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
  background: #ffffff;
}

.modern-select {
  appearance: none;
  background: #ffffff;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 0.75rem center;
  background-repeat: no-repeat;
  background-size: 1.25em 1.25em;
  padding-right: 2.5rem;
  color: #1f2937;
}

.modern-select option {
  background-color: #ffffff;
  color: #1f2937;
  padding: 0.5rem;
}

/* Modern Table Styles - Compact */
.modern-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: #ffffff;
  border-radius: var(--border-radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  min-width: 600px; /* Reduced from 800px */
  font-size: 0.9rem; /* Compact text size */
}

/* Table container for horizontal scrolling */
.table-container {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-sm);
  scrollbar-width: thin;
  scrollbar-color: #cbd5e0 #f7fafc;
  margin-bottom: 1rem; /* Reduced spacing */
}

.table-container::-webkit-scrollbar {
  height: 6px; /* Thinner scrollbar */
}

.table-container::-webkit-scrollbar-track {
  background: #f7fafc;
  border-radius: 3px;
}

.table-container::-webkit-scrollbar-thumb {
  background: #cbd5e0;
  border-radius: 3px;
}

.table-container::-webkit-scrollbar-thumb:hover {
  background: #a0aec0;
}

/* Enhanced mobile table scrolling */
.overflow-x-auto {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: #cbd5e0 #f7fafc;
  /* Add this to fix grid/flex container issues */
  min-width: 0;
}

/* Fix grid containers that prevent child overflow */
.grid.grid-cols-1 {
  /* Allow grid items to have overflow containers */
  grid-template-columns: minmax(0, 1fr);
}

/* Grid items containing scrollable content need min-width: 0 */
.grid.grid-cols-1 > * {
  min-width: 0;
}

/* Ensure tables inside overflow containers work properly */
.overflow-x-auto > table {
  /* Let table expand as needed */
  width: auto;
  min-width: 100%;
}

/* Mobile-specific table improvements */
@media (max-width: 768px) {
  .overflow-x-auto {
    /* Make scrollbar more visible on mobile */
    scrollbar-width: auto;
  }

  .overflow-x-auto::-webkit-scrollbar {
    height: 10px;
  }

  .overflow-x-auto::-webkit-scrollbar-track {
    background: #e2e8f0;
    border-radius: 4px;
  }

  .overflow-x-auto::-webkit-scrollbar-thumb {
    background: #94a3b8;
    border-radius: 4px;
  }

  .overflow-x-auto::-webkit-scrollbar-thumb:active {
    background: #64748b;
  }

  /* Ensure tables scroll properly */
  .overflow-x-auto table {
    display: table;
    width: auto;
    min-width: 100%;
  }
}

/* Additional mobile table improvements */
@media (max-width: 640px) {
  /* Extra small screens - more aggressive mobile optimizations */
  .overflow-x-auto table {
    font-size: 0.85rem;
  }
}

.modern-table thead {
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
  color: #374151;
}

.modern-table th {
  padding: 0.75rem 1rem; /* Reduced from 1rem 1.5rem */
  font-weight: 600;
  text-align: left;
  font-size: 0.85rem; /* Smaller header text */
  letter-spacing: 0.025em; /* Reduced letter spacing */
  white-space: nowrap;
  min-width: 100px; /* Reduced from 120px */
  border-bottom: 2px solid #e5e7eb;
}

.modern-table td {
  padding: 0.75rem 1rem; /* Reduced from 1rem 1.5rem */
  border-bottom: 1px solid #f1f5f9;
  transition: background-color 0.2s ease;
  white-space: nowrap;
  min-width: 100px; /* Reduced from 120px */
}

/* Allow wrapping for action columns */
.modern-table td:last-child,
.modern-table th:last-child {
  white-space: normal;
  min-width: 150px; /* Reduced from 200px */
}

.modern-table tbody tr:hover {
  background: rgba(59, 130, 246, 0.03);
}

.modern-table tbody tr:last-child td {
  border-bottom: none;
}

/* Modern Navigation Styles - Compact */
.modern-nav {
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
  box-shadow: var(--shadow-sm);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  backdrop-filter: blur(8px);
}

.nav-link {
  position: relative;
  transition: all 0.2s ease;
  text-decoration: none;
  border-radius: var(--border-radius-sm);
  font-weight: 500;
  font-size: 0.9rem;
}

.nav-link:hover {
  background-color: rgba(59, 130, 246, 0.05);
  transform: translateY(-1px);
}

/* Form Section Styles - Compact */
.form-section {
  background: white;
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid #e5e7eb;
  overflow: hidden;
  margin-bottom: 1rem; /* Reduced from default */
}

.form-section-header {
  background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
  padding: 0.75rem 1rem; /* Reduced from larger padding */
  border-bottom: 1px solid #e5e7eb;
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.95rem;
}

.form-section-content {
  padding: 1rem; /* Reduced from larger padding */
}

/* Layout and Container Styles - Compact */
.modern-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem; /* Reduced from 2rem */
}

@media (min-width: 768px) {
  .modern-grid {
    grid-template-columns: repeat(
      auto-fit,
      minmax(300px, 1fr)
    ); /* Reduced from 350px */
  }

  .modern-container {
    padding: 0 1.5rem;
  }
}

/* Modern Alert Styles */
.modern-alert {
  padding: 1rem 1.5rem;
  border-radius: var(--border-radius-md);
  border-left: 4px solid;
  margin-bottom: 1rem;
  backdrop-filter: blur(10px);
  animation: slideUp 0.5s ease-out;
}

.alert-success {
  background: rgba(16, 185, 129, 0.1);
  border-left-color: #10b981;
  color: #065f46;
}

.alert-danger {
  background: rgba(239, 68, 68, 0.1);
  border-left-color: #ef4444;
  color: #991b1b;
}

.alert-warning {
  background: rgba(245, 158, 11, 0.1);
  border-left-color: #f59e0b;
  color: #92400e;
}

.alert-info {
  background: rgba(59, 130, 246, 0.1);
  border-left-color: #3b82f6;
  color: #1e40af;
}

/* Modern Loading Spinner */
.modern-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid rgba(59, 130, 246, 0.2);
  border-top: 4px solid #3b82f6;
  border-radius: 50%;
  animation: modernSpin 1s linear infinite;
}

@keyframes modernSpin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Header Styling */
.page-header {
  text-align: center;
  padding: 2rem 0;
}

.page-title {
  font-size: 3rem;
  font-weight: 700;
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.5rem;
  animation: slideUp 0.8s ease-out;
}

.page-subtitle {
  font-size: 1.25rem;
  color: #64748b;
  animation: slideUp 0.8s ease-out 0.2s both;
}

/* Grid System Enhancement */
.modern-grid {
  display: grid;
  gap: 1.5rem;
  animation: modernFadeIn 1s ease-out;
}

.modern-grid > * {
  animation: scaleIn 0.6s ease-out both;
}

.modern-grid > *:nth-child(1) {
  animation-delay: 0.1s;
}
.modern-grid > *:nth-child(2) {
  animation-delay: 0.2s;
}
.modern-grid > *:nth-child(3) {
  animation-delay: 0.3s;
}
.modern-grid > *:nth-child(4) {
  animation-delay: 0.4s;
}
.modern-grid > *:nth-child(5) {
  animation-delay: 0.5s;
}
.modern-grid > *:nth-child(6) {
  animation-delay: 0.6s;
}

/* Print-specific styles for report pages */
@media print {
  .navbar,
  .footer,
  .sidebar,
  #downloadDropdownContainer,
  #report-filter-form-row {
    display: none !important;
  }
  body * {
    visibility: hidden;
  }
  .container,
  .container * {
    visibility: visible;
  }
  .container {
    position: absolute !important;
    left: 0;
    top: 0;
    width: 100vw;
    min-width: 0;
    background: white !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  .overflow-x-auto,
  .overflow-x-auto > div,
  .overflow-x-auto > table,
  .overflow-x-auto > .w-full,
  .overflow-x-auto > .min-w-full {
    overflow-x: visible !important;
    width: 100% !important;
    max-width: 100vw !important;
    display: block !important;
  }
  table {
    page-break-inside: avoid !important;
    width: 100% !important;
    max-width: 100vw !important;
    overflow-x: visible !important;
  }
  th,
  td {
    word-break: break-word;
    white-space: normal !important;
  }
}

/* Legacy Support Classes */
.fade-in {
  animation: subtleFadeIn 0.3s ease-out both;
}

.input-focus {
  width: 100%;
  padding: 1rem 1.25rem;
  border: 2px solid #e2e8f0;
  border-radius: var(--border-radius-md);
  font-size: 1rem;
  transition: border-color 0.2s ease;
  background: #ffffff;
  color: #1e293b;
}

.input-focus:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
  background: #ffffff;
}

.btn-animate {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  font-weight: 600;
  font-size: 1rem;
  border-radius: var(--border-radius-md);
  transition: all 0.2s ease;
  text-decoration: none;
  border: none;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  background: var(--secondary-gradient);
  color: white;
}

.btn-animate:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.card-animate {
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s ease;
  position: relative;
  animation: subtleFadeIn 0.3s ease-out both;
}

.card-animate:hover {
  box-shadow: var(--shadow-md);
}

@keyframes cardPop {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.table-row-animate {
  transition: background-color 0.2s ease;
}
.table-row-animate:hover {
  background: rgba(59, 130, 246, 0.02);
}

/* Breadcrumb and Footer Styles */
.breadcrumb {
  color: #64748b;
  font-size: 0.95rem;
  margin-bottom: 1rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.footer {
  background: rgba(241, 245, 249, 0.9);
  backdrop-filter: blur(20px);
  color: #64748b;
  font-size: 1rem;
  text-align: center;
  padding: 1.5rem 0 0.5rem 0;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
  margin-top: 2rem;
}

/* Utility Classes */
.bg-gradient-primary {
  background: var(--primary-gradient);
}

.bg-gradient-secondary {
  background: var(--secondary-gradient);
}

.shadow-modern {
  box-shadow: var(--shadow-lg);
}

.border-modern {
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--border-radius-lg);
}

/* Icon Enhancement - Subtle */
.icon-bounce {
  animation: subtleIconBounce 3s ease-in-out infinite;
}

@keyframes subtleIconBounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-2px);
  }
}

/* Accessibility Improvements */
.focus-visible {
  outline: 2px solid #3b82f6;
  outline-offset: 2px;
}

.reduce-motion {
  animation: none !important;
  transition: none !important;
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Compact buttons in button groups */
.btn-group {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.btn-group .modern-btn {
  flex: 1;
  min-width: 120px;
}

/* Mobile-optimized text sizes */
@media (max-width: 480px) {
  body {
    font-size: 0.9rem;
  }

  .page-title {
    font-size: 1.5rem;
  }

  .page-subtitle {
    font-size: 0.9rem;
  }

  .modern-card {
    padding: 0.75rem;
    margin-bottom: 0.75rem;
  }

  .btn-group .modern-btn {
    min-width: 100px;
    font-size: 0.85rem;
    padding: 0.6rem 1rem;
  }
}

/* Enhanced Mobile Navigation Styles */
.mobile-nav-link {
  display: block;
  padding: 12px 16px;
  margin: 2px 0;
  text-decoration: none;
  color: #374151;
  font-size: 16px; /* Prevents zoom on iOS */
  font-weight: 500;
  border-radius: 8px;
  transition: all 0.2s ease;
  min-height: 44px; /* Minimum touch target */
  display: flex;
  align-items: center;
  position: relative;
}

.mobile-nav-link:hover {
  background-color: rgba(139, 92, 246, 0.1);
  color: #7c3aed;
  transform: translateX(4px);
}

.mobile-nav-link.active {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.mobile-nav-link.active:hover {
  background: linear-gradient(135deg, #5a67d8 0%, #6b46c1 100%);
  transform: translateX(4px);
}

.mobile-nav-primary {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  font-weight: 600;
  text-align: center;
  margin-top: 8px;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.mobile-nav-primary:hover {
  background: linear-gradient(135deg, #5a67d8 0%, #6b46c1 100%);
  transform: translateX(4px);
}

.mobile-nav-logout {
  color: #dc2626;
  font-weight: 600;
  border: 1px solid #fecaca;
  background-color: rgba(220, 38, 38, 0.05);
}

.mobile-nav-logout:hover {
  background-color: #fef2f2;
  color: #b91c1c;
  border-color: #fca5a5;
  transform: translateX(4px);
}

/* Hamburger Menu Animation */
#nav-menu:not(.hidden) {
  max-height: 500px;
  opacity: 1;
}

/* Hamburger Icon Animation */
.hamburger-x #hamburger-icon path:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger-x #hamburger-icon path:nth-child(2) {
  opacity: 0;
}

.hamburger-x #hamburger-icon path:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -6px);
}

/* Screen Reader Only - Accessibility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.sr-only.focus:not-sr-only {
  position: static;
  width: auto;
  height: auto;
  padding: inherit;
  margin: inherit;
  overflow: visible;
  clip: auto;
  white-space: normal;
}

/* Mobile user info chevron rotation */
.rotate-180 {
  transform: rotate(180deg);
}
