/* Healthcare Report Automation - Styles */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: #f5f5f7;
  color: #1d1d1f;
  line-height: 1.6;
}

#app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header */
header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 2rem;
  text-align: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

header h1 {
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

header p {
  opacity: 0.9;
  font-size: 1rem;
}

/* Navigation */
nav {
  background: white;
  padding: 1rem 2rem;
  display: flex;
  gap: 1rem;
  border-bottom: 1px solid #e0e0e0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.nav-btn {
  background: transparent;
  border: none;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  cursor: pointer;
  border-radius: 8px;
  transition: all 0.2s;
  font-weight: 500;
}

.nav-btn:hover {
  background: #f5f5f7;
}

.nav-btn.active {
  background: #667eea;
  color: white;
}

/* Main Content */
main {
  flex: 1;
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

/* Cards */
.card {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.card h2 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: #667eea;
}

.card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
  color: #333;
}

/* Patient List */
.patient-list {
  display: grid;
  gap: 1rem;
}

.patient-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background: #f9f9fb;
  border-radius: 8px;
  border-left: 4px solid #667eea;
}

.patient-card.clickable {
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.patient-card.clickable:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  background: #f0f0f5;
}

.patient-info h4 {
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
}

.patient-info p {
  color: #666;
  font-size: 0.9rem;
}

.patient-stats {
  display: flex;
  gap: 1.5rem;
  text-align: center;
}

.stat {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-size: 1.5rem;
  font-weight: 600;
  color: #667eea;
}

.stat-label {
  font-size: 0.85rem;
  color: #666;
}

/* Import Page */
.import-zone {
  border: 2px dashed #667eea;
  border-radius: 12px;
  padding: 3rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: #f9f9fb;
}

.import-zone:hover {
  background: #f0f0f5;
  border-color: #764ba2;
}

.import-zone.dragover {
  background: #e8e8f0;
  border-color: #764ba2;
  border-style: solid;
}

.import-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

/* Buttons */
.btn {
  background: #667eea;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 500;
}

.btn:hover {
  background: #5568d3;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.btn:active {
  transform: translateY(0);
}

.btn-secondary {
  background: #6c757d;
}

.btn-secondary:hover {
  background: #5a6268;
}

/* Loading Spinner */
.spinner {
  border: 3px solid #f3f3f3;
  border-top: 3px solid #667eea;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 2rem auto;
}

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

/* Messages */
.message {
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
}

.message.success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.message.error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.message.info {
  background: #d1ecf1;
  color: #0c5460;
  border: 1px solid #bee5eb;
}

/* Hidden file input */
input[type="file"] {
  display: none;
}

/* Status Dashboard - Kanban Layout */
.status-dashboard {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.status-column {
  background: white;
  border-radius: 12px;
  padding: 1rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.status-column-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  margin-bottom: 1rem;
  border-radius: 8px;
}

.status-column-draft .status-column-header {
  background: #fee;
  border-left: 4px solid #dc3545;
}

.status-column-pending .status-column-header {
  background: #ffe;
  border-left: 4px solid #ffc107;
}

.status-column-ready .status-column-header {
  background: #efe;
  border-left: 4px solid #28a745;
}

.status-column-header .status-icon {
  font-size: 1.5rem;
}

.status-column-header h3 {
  flex: 1;
  font-size: 1.1rem;
  color: #333;
  margin: 0;
}

.status-column-header .status-count {
  background: rgba(0, 0, 0, 0.1);
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 600;
}

.status-column-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-height: 200px;
}

.empty-state {
  text-align: center;
  color: #999;
  padding: 2rem 0;
  font-style: italic;
}

/* Report Card */
.report-card {
  background: #f9f9fb;
  border-radius: 8px;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.2s;
  border-left: 3px solid #667eea;
}

.report-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  background: #f0f0f5;
}

.report-card-patient {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #333;
}

.report-card-status {
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 0.5rem;
}

.report-card-time {
  font-size: 0.85rem;
  color: #999;
  margin-bottom: 0.75rem;
}

.report-card-action {
  background: transparent;
  border: 1px solid #667eea;
  color: #667eea;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s;
  width: 100%;
  text-align: left;
  font-weight: 500;
}

.report-card-action:hover {
  background: #667eea;
  color: white;
}

/* Report Timeline */
.report-timeline {
  margin: 1.5rem 0;
  padding: 1rem;
  background: #f9f9fb;
  border-radius: 8px;
}

.timeline-track {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0;
}

.timeline-milestone {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
}

.timeline-circle {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.timeline-milestone-complete .timeline-circle {
  color: #28a745;
}

.timeline-milestone-current .timeline-circle {
  color: #667eea;
}

.timeline-milestone-pending .timeline-circle {
  color: #ccc;
}

.timeline-label {
  font-size: 0.85rem;
  color: #666;
  text-align: center;
}

.timeline-date {
  font-size: 0.75rem;
  color: #999;
  margin-top: 0.25rem;
}

.timeline-connector {
  flex: 1;
  height: 2px;
  margin: 0 0.5rem 2rem 0.5rem;
}

.timeline-connector-complete {
  background: #28a745;
}

.timeline-connector-pending {
  background: #e0e0e0;
}

/* Responsive */
@media (max-width: 768px) {
  header h1 {
    font-size: 1.5rem;
  }

  nav {
    padding: 0.75rem 1rem;
  }

  main {
    padding: 1rem;
  }

  .patient-card {
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
  }

  .patient-stats {
    width: 100%;
    justify-content: space-around;
  }

  /* Status Dashboard - Stack on mobile */
  .status-dashboard {
    grid-template-columns: 1fr;
  }

  .timeline-label {
    font-size: 0.7rem;
  }

  .timeline-circle {
    font-size: 1.2rem;
  }
}

/* Form Tabs */
.form-tabs {
  display: flex;
  gap: 0.5rem;
  border-bottom: 2px solid #e0e0e0;
  margin-bottom: 0;
  padding: 0 1rem;
}

.form-tab {
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  padding: 1rem 1.5rem;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 500;
  color: #666;
  white-space: nowrap;
}

.form-tab:hover {
  color: #667eea;
  background: #f5f5f7;
}

.form-tab.active {
  color: #667eea;
  border-bottom-color: #667eea;
  background: transparent;
}
