* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Inter, system-ui, -apple-system, sans-serif;
}

body {
  background-color: #f8fafc;
  color: #1e293b;
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
  width: 100%;
}

.logo-section {
  text-align: center;
  margin-bottom: 3rem;
}

.logo {
  width: 120px;
  height: auto;
  margin-bottom: 1.5rem;
}

.logo-section h1 {
  font-size: 2.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.logo-section p {
  color: #64748b;
  font-size: 1.125rem;
}

.auth-container {
  display: flex;
  gap: 2rem;
  justify-content: center;
  margin: 0 auto;
  max-width: 800px;
}

.auth-card {
  background: white;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  width: 100%;
  max-width: 320px;
}

.auth-card h2 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  font-weight: 600;
}

.auth-card input {
  width: 100%;
  padding: 0.75rem;
  margin-bottom: 1rem;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 1rem;
}

.auth-button {
  width: 100%;
  padding: 0.75rem;
  background: #3b82f6;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s;
}

.auth-button:hover {
  background: #2563eb;
}

.auth-form h2 {
  margin-bottom: 1rem;
}

.auth-form input {
  display: block;
  width: 100%;
  padding: 0.5rem;
  margin-bottom: 1rem;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.auth-form button {
  width: 100%;
  padding: 0.75rem;
  background: #3498db;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.upload-section {
  margin-bottom: 2rem;
}

.image-upload-container {
  display: flex;
  gap: 2rem;
  margin-bottom: 1rem;
}

.drop-area {
  flex: 1;
  border: 2px dashed #3498db;
  border-radius: 8px;
  padding: 2rem;
  text-align: center;
  background-color: #fff;
  transition: all 0.3s;
}

#drop-area.highlight {
  background-color: #ecf0f1;
  border-color: #2980b9;
}

#file-select-button {
  background-color: #3498db;
  color: white;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  margin-top: 1rem;
  font-size: 1rem;
  transition: background-color 0.3s;
}

#file-select-button:hover {
  background-color: #2980b9;
}

#preview-container {
  margin-top: 1.5rem;
}

#preview-image {
  max-width: 100%;
  max-height: 300px;
  margin-bottom: 1rem;
}

#change-image-btn, #analyze-btn {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  margin: 0 0.5rem;
}

#change-image-btn {
  background-color: #e74c3c;
  color: white;
}

#analyze-btn {
  background-color: #2ecc71;
  color: white;
}

#results-section {
  background-color: #fff;
  border-radius: 8px;
  padding: 2rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.error-message {
  padding: 1rem;
  background-color: #fee;
  border-left: 4px solid #e74c3c;
  border-radius: 4px;
}

.error-message h3 {
  color: #c0392b;
  margin-bottom: 0.5rem;
}

.error-message ul {
  margin: 1rem 0;
  padding-left: 1.5rem;
}

.error-message li {
  margin: 0.5rem 0;
  color: #666;
}

#results-section h2 {
  margin-bottom: 1rem;
  color: #2c3e50;
}

.toggle-container {
  display: flex;
  align-items: center;
  margin-bottom: 1.5rem;
}

.toggle {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
  margin-left: 1rem;
}

.toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: .4s;
}

input:checked + .slider {
  background-color: #2ecc71;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

.slider.round {
  border-radius: 34px;
}

.slider.round:before {
  border-radius: 50%;
}

.loader {
  border: 5px solid #f3f3f3;
  border-top: 5px solid #3498db;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  animation: spin 2s linear infinite;
  margin: 2rem auto;
}

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

#analysis-results {
  padding: 1rem;
}

.hidden {
  display: none;
}

.finding-item.medium-confidence {
  border-left-color: #f39c12;
}

.finding-item.low-confidence {
  border-left-color: #3498db;
}

.analysis-container {
  max-width: 800px;
  margin: 0 auto;
}

.section {
  margin-bottom: 2rem;
  padding: 1rem;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.section h3 {
  color: #2c3e50;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #ecf0f1;
}

.normal-findings-list {
  list-style-type: none;
  padding: 0;
}

.normal-findings-list li {
  padding: 0.5rem 0;
  border-bottom: 1px solid #ecf0f1;
}

.normal-findings-list li:last-child {
  border-bottom: none;
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.7);
  z-index: 1000;
  overflow-y: auto;
  padding: 20px;
}

.modal.show {
  display: block !important;
}

.error-message {
  background-color: #fee;
  border-left: 4px solid #e74c3c;
  padding: 1rem;
  margin: 1rem 0;
  border-radius: 4px;
}

.error-message h3 {
  color: #e74c3c;
  margin-top: 0;
}

.modal-content {
  background-color: #fefefe;
  margin: 20px auto;
  padding: 20px;
  border: 1px solid #888;
  width: 90%;
  max-width: 1200px;
  border-radius: 5px;
  position: relative;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
}

.close-modal {
  position: absolute;
  right: 1rem;
  top: 0.5rem;
  font-size: 2rem;
  cursor: pointer;
}

.close-modal:hover {
  color: #666;
}

/* New styles for analysis images */
.analysis-images {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
  justify-content: center;
}

.image-container {
  flex: 1;
  text-align: center;
}

.image-container img {
  max-width: 100%;
  height: auto;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.image-container h4 {
  margin: 10px 0;
}
.alert-warning {
  background-color: #fff3cd;
  border: 1px solid #ffeeba;
  color: #856404;
  padding: 12px;
  margin-bottom: 15px;
  border-radius: 4px;
}

.email-form {
  margin-top: 20px;
  padding: 15px;
  border-top: 1px solid #eee;
}

.email-form input {
  width: 100%;
  padding: 8px;
  margin: 10px 0;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.email-btn {
  background-color: #28a745;
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
}

.email-btn:hover {
  background-color: #218838;
}

#email-status {
  margin-top: 10px;
  padding: 8px;
  border-radius: 4px;
}

#email-status.error {
  background-color: #f8d7da;
  color: #721c24;
}

#email-status.success {
  background-color: #d4edda;
  color: #155724;
}

#email-status.info {
  background-color: #cce5ff;
  color: #004085;
}
