/* Custom Styles for Healthcare Facility Portal */

/* Set medical blue color theme */
:root {
  --primary-blue: #3b82f6;
  --primary-dark-blue: #1e40af;
  --primary-light-blue: #93c5fd;
  --secondary-blue: #0f172a;
}

/* Better focus states */
*:focus {
  outline: none;
}

/* Base body styling */
body {
  padding-bottom: 40px !important;
  margin-bottom: 0;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  width: 100%;
  box-sizing: border-box;
}

/* Tab Content */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

.tab-content.hidden {
  display: none !important;
}

/* File Upload Styling */
.file-upload-area {
  position: relative;
  cursor: pointer;
  transition: all 0.2s ease;
}

.file-upload-area:hover {
  background-color: #f3f4f6;
}

/* Status Badge Styling */
.status-badge {
  padding: 0.25rem 0.5rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  text-align: center;
  white-space: nowrap;
}

.status-Bekliyor {
  background-color: #fef3c7;
  color: #92400e;
}

.status-Onaylandı {
  background-color: #d1fae5;
  color: #065f46;
}

.status-Tamamlandı {
  background-color: #dbeafe;
  color: #1e40af;
}

.status-Belge-Bekleniyor {
  background-color: #fee2e2;
  color: #991b1b;
}

.status-Bakanlıkta {
  background-color: #e0e7ff;
  color: #3730a3;
}

.status-İptal-Edildi {
  background-color: #f3f4f6;
  color: #1f2937;
}

/* Fixed Status Bar - Windows Explorer style */
.status-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: #f0f0f0;
  border-top: 1px solid #d1d5db;
  padding: 6px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 50;
  height: 28px;
  font-size: 0.8rem;
  color: #4b5563;
  box-shadow: 0 -1px 3px rgba(0, 0, 0, 0.05);
  width: calc(100% - 32px);
  box-sizing: border-box;
}

.status-bar-section {
  display: flex;
  align-items: center;
  gap: 12px;
}

.status-bar-item {
  display: flex;
  align-items: center;
  gap: 4px;
}

.status-bar-divider {
  width: 1px;
  height: 16px;
  background-color: #d1d5db;
  margin: 0 6px;
}

/* Main container with proper scrolling */
.container {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  padding-right: 8px; /* Add padding for scrollbar */
}

/* Smooth transitions */
.transition-all {
  transition: all 0.3s ease;
}

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

::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 10px;
}

::-webkit-scrollbar-thumb {
  background: var(--primary-blue);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-dark-blue);
}

/* For Firefox */
html {
  scrollbar-width: thin;
  scrollbar-color: var(--primary-blue) #f1f1f1;
}

/* Facility image preview */
.facility-image-container img {
  max-width: 100%;
  max-height: 100%;
}

/* Button hover effects */
button:hover, 
.tab-btn:hover {
  opacity: 0.9;
}

/* Tab button active state */
.tab-btn.active {
  color: var(--primary-dark-blue);
  font-weight: 600;
  border-bottom-color: var(--primary-dark-blue);
}

/* Document preview */
.document-preview {
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #f9fafb;
  border-radius: 0.5rem;
  overflow: hidden;
}

/* Notification animation */
@keyframes fade-in {
  0% { opacity: 0; transform: translateY(-10px); }
  100% { opacity: 1; transform: translateY(0); }
}

.notification {
  animation: fade-in 0.3s ease-out;
}

/* Progress Bar Styling */
#form-progress-bar {
  transition: width 0.3s ease-in-out;
}

#form-progress-labels {
  position: relative;
  height: 20px;
  margin-top: 6px;
  padding-top: 4px;
}

#form-progress-labels span {
  position: absolute;
  transform: translateX(-50%);
  white-space: nowrap;
  font-size: 0.75rem;
  color: #6b7280;
  transition: all 0.3s ease;
}

#form-progress-labels span.text-blue-700 {
  color: #1d4ed8;
}

/* Enhanced Mobile Responsiveness */
/* Mobile Media Queries */
@media (max-width: 768px) {
  /* Basic spacing adjustments */
  .container {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }
  
  /* Header adjustments for mobile */
  header .container {
    padding: 0.75rem !important;
  }
  
  header h1 {
    font-size: 1.25rem !important;
  }
  
  /* Status bar size adjustment for mobile */
  .status-bar {
    padding: 6px 8px;
    width: calc(100% - 16px);
    font-size: 0.7rem;
  }
  
  .status-bar-section {
    gap: 6px;
  }
  
  /* Hide non-critical status bar elements on very small screens */
  @media (max-width: 480px) {
    .status-bar-divider:nth-of-type(2),
    .status-bar-item:nth-of-type(3) {
      display: none;
    }
  }
  
  /* Form styles for mobile */
  .tab-buttons {
    flex-wrap: wrap;
  }
  
  .tab-btn {
    padding: 0.5rem !important;
    font-size: 0.8rem !important;
  }
  
  /* Table responsiveness */
  table {
    display: block;
    width: 100%;
    overflow-x: auto;
  }
  
  /* Form inputs and spacing */
  input, select, textarea {
    font-size: 16px !important; /* Prevents iOS zoom */
  }
  
  .form-grid {
    grid-template-columns: 1fr !important;
  }
  
  /* Adjust card padding */
  .bg-white.rounded-lg.shadow-md {
    padding: 1rem !important;
  }
  
  /* Better button touch targets */
  button, 
  .btn, 
  a.btn,
  input[type="submit"],
  input[type="button"] {
    min-height: 44px !important;
    padding: 0.625rem 1rem !important;
  }
  
  /* Adjust spacing between form elements */
  .space-y-6 {
    margin-top: 1.25rem !important;
  }
  
  /* File upload responsiveness */
  .file-upload-area {
    padding: 1rem !important;
  }
}

/* Tablet Media Queries */
@media (min-width: 769px) and (max-width: 1024px) {
  /* Adjust for tablets */
  .container {
    padding-left: 1.5rem !important;
    padding-right: 1.5rem !important;
  }
  
  /* Better form layout for tablets */
  .form-grid {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)) !important;
  }
}

/* Flexbox and grid helper classes for responsiveness */
.flex-col-mobile {
  display: flex;
  flex-direction: row;
}

@media (max-width: 768px) {
  .flex-col-mobile {
    flex-direction: column !important;
  }
  
  /* Stack items on mobile */
  .stack-on-mobile {
    display: flex;
    flex-direction: column !important;
  }
  
  .stack-on-mobile > * {
    width: 100% !important;
    margin-right: 0 !important;
    margin-bottom: 0.75rem !important;
  }
  
  /* Adjust modal sizes for mobile */
  .modal-content {
    width: 95% !important;
    max-width: 95% !important;
    margin: 10px auto !important;
    padding: 1rem !important;
  }
}

/* Navigation and menu improvements for mobile */
@media (max-width: 768px) {
  /* Improve header layout */
  header .flex.justify-between.items-center {
    flex-direction: column;
    align-items: flex-start;
  }
  
  header .flex.items-center {
    margin-top: 0.5rem;
    width: 100%;
    justify-content: space-between;
  }
  
  /* Adjust search and filter elements */
  #search-input {
    width: 100% !important;
  }
  
  .filter-dropdown {
    right: 0;
    left: 0;
    width: 100%;
  }
}

/* Improve visibility of form progress labels on mobile */
@media (max-width: 768px) {
  #form-progress-labels {
    height: 40px; /* Extra space for wrapping text */
  }
  
  #form-progress-labels span {
    font-size: 0.65rem;
  }
}

/* Print styles */
@media print {
  .status-bar,
  .no-print {
    display: none !important;
  }
  
  body {
    padding-bottom: 0 !important;
  }
} 