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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: linear-gradient(135deg, #f0fdfa 0%, #ecfdf5 50%, #f9fafb 100%);
  min-height: 100vh;
  color: #1e293b;
  line-height: 1.6;
}

/* Main Container */
.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.header {
  text-align: center;
  margin-bottom: 3rem;
  color: #0f172a;
}

.header h1 {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, #0d9488 0%, #14b8a6 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: none;
}

.header p {
  font-size: 1.25rem;
  color: #64748b;
  font-weight: 400;
  max-width: 600px;
  margin: 0 auto;
}

/* Corner Buttons */
.corner-buttons {
  position: fixed;
  top: 24px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 1000;
}

.corner-btn {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 12px;
  padding: 0.75rem 1.25rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition: all 0.2s;
  font-size: 0.9rem;
  color: #0d9488;
  font-weight: 600;
  border: 1px solid #e2e8f0;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 110px;
}

.corner-btn:hover {
  background: #0d9488;
  color: white;
  border-color: #0d9488;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(13, 148, 136, 0.3);
}

/* Support and Suggestion Sections */
.support-section,
.suggestion-section {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 16px;
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  border: 1px solid #e2e8f0;
}

.support-section h3,
.suggestion-section h3 {
  color: #0d9488;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
}

.suggestion-input,
.suggestion-textarea {
  width: 100%;
  padding: 1rem;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  font-size: 0.95rem;
  margin-bottom: 1rem;
  font-family: inherit;
  transition: border-color 0.2s;
}

.suggestion-input:focus,
.suggestion-textarea:focus {
  border-color: #0d9488;
  outline: none;
  box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.1);
}

.suggestion-textarea {
  resize: vertical;
  min-height: 100px;
}

.suggestion-btn {
  padding: 1rem 1.5rem;
  background: #0d9488;
  color: white;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 0.95rem;
  font-weight: 600;
  width: 100%;
}

.suggestion-btn:hover {
  background: #0f766e;
  transform: translateY(-1px);
}

.warning-icon-large {
  font-size: 2.5rem;
  text-align: center;
  margin-bottom: 1rem;
}

.safety-warning h3 {
  color: #92400e;
  font-size: 1.4rem;
  margin-bottom: 1rem;
  text-align: center;
  font-weight: 700;
}

.safety-warning ul {
  margin: 1rem 0;
  padding-left: 1.5rem;
}

.safety-warning li {
  margin: 0.5rem 0;
  color: #78350f;
  line-height: 1.6;
}

.safety-warning .liability {
  margin-top: 1rem;
  font-weight: 600;
  color: #92400e;
  text-align: center;
  font-size: 1.05rem;
}

/* Search Card & Results */
.search-card,
.results-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
  border: 1px solid #e2e8f0;
}

.search-card {
  padding: 2.5rem;
  margin-bottom: 2rem;
}

.results-card {
  padding: 2rem;
}

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

.search-label {
  font-size: 1.1rem;
  font-weight: 600;
  color: #475569;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.search-input-container {
  position: relative;
  margin-bottom: 1.5rem;
}

.search-input {
  width: 100%;
  padding: 1.25rem 1.25rem 1.25rem 3.5rem;
  font-size: 1.1rem;
  border: 2px solid #e2e8f0;
  border-radius: 16px;
  outline: 0;
  transition: all 0.3s;
  background: #fff;
}

.search-input:focus {
  border-color: #0d9488;
  box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.1);
  transform: translateY(-1px);
}

.search-icon {
  position: absolute;
  left: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 1.1rem;
}

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

.allergen-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
}

.allergen-btn {
  padding: 1rem 1.25rem;
  border: 2px solid #e2e8f0;
  background: #fff;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3.5rem;
  font-size: 0.95rem;
}

.allergen-btn:hover {
  border-color: #0d9488;
  background: #f0fdfa;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.15);
}

.allergen-btn.selected {
  background: #0d9488;
  border-color: #0d9488;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.3);
}

.search-button {
  width: 100%;
  padding: 1.25rem 2rem;
  background: linear-gradient(135deg, #0d9488 0%, #14b8a6 100%);
  color: #fff;
  border: none;
  border-radius: 16px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  box-shadow: 0 4px 20px rgba(13, 148, 136, 0.3);
}

.search-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(13, 148, 136, 0.4);
}

.search-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: 0 4px 20px rgba(13, 148, 136, 0.15);
}

.source-info {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
  padding: 1.25rem 1.5rem;
  border-radius: 12px;
  font-size: 0.95rem;
  color: #0f172a;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border: 2px solid #0891b2;
  box-shadow: 0 4px 12px rgba(8, 145, 178, 0.15);
}

.source-info a {
  color: #0891b2;
  text-decoration: none;
  font-weight: 600;
}

.source-info a:hover {
  text-decoration: underline;
}

.results-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  color: #475569;
  font-weight: 600;
  font-size: 1.1rem;
}

.results-safety-note {
  background: #fef3c7;
  border-left: 4px solid #f59e0b;
  color: #92400e;
  padding: 0.75rem 1rem;
  border-radius: 0 8px 8px 0;
  font-size: 0.9rem;
  margin-bottom: 1rem;
  font-weight: 500;
}

.category-section {
  margin-bottom: 1.5rem;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  background: white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.category-header {
  background: linear-gradient(135deg, #0d9488 0%, #14b8a6 100%);
  color: white;
  padding: 1rem 1.25rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  user-select: none;
  margin: 0;
  transition: background 0.2s;
}

.category-header:hover {
  background: linear-gradient(135deg, #0f766e 0%, #0d9488 100%);
}

.category-header::-webkit-details-marker {
  display: none;
}

.category-items {
  padding: 0.75rem;
  background: #fefefe;
}

.menu-item {
  padding: 0.75rem 1rem;
  background: #fff;
  border: 1px solid #f1f5f9;
  border-radius: 8px;
  margin-bottom: 0.5rem;
  transition: all 0.15s;
  font-size: 0.95rem;
}

.menu-item:hover {
  border-color: #0d9488;
  background: #f0fdfa;
  transform: translateX(4px);
  box-shadow: 0 2px 8px rgba(13, 148, 136, 0.1);
}

.menu-item:last-child {
  margin-bottom: 0;
}

/* Disclaimer */
.disclaimer {
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  border: 1px solid #f59e0b;
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 2rem;
  font-size: 0.95rem;
  color: #78350f;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.15);
}

.disclaimer strong {
  color: #92400e;
}

/* Progress + Spinner */
.progress-wrapper {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: stretch;
}

.spinner {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 3px solid #e2e8f0;
  border-top-color: #0d9488;
  animation: spin 1s linear infinite;
  align-self: center;
}

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

.progress-bar {
  width: 100%;
  height: 8px;
  background: #e2e8f0;
  border-radius: 4px;
}

.progress {
  height: 100%;
  background: #0d9488;
  border-radius: 4px;
  transition: width 0.3s ease-in-out;
}

.progress-text {
  font-size: 0.95rem;
  color: #334155;
  text-align: center;
  margin-top: 2px;
}

.progress-steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  font-size: 0.8rem;
  color: #64748b;
}

.progress-steps li {
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 6px 8px;
  text-align: center;
}

.progress-steps li.active {
  border-color: #0d9488;
  background: #ecfeff;
  color: #0f766e;
  font-weight: 600;
}

.progress-steps li.done {
  background: #e2f7f5;
  color: #0f766e;
}

/* Footer */
.footer {
  margin-top: 4rem;
  text-align: center;
  color: #64748b;
  font-size: 0.9rem;
  padding: 2rem 0;
}

/* Responsive */
@media (max-width: 768px) {
  .container { padding: 1rem; }
  .header h1 { font-size: 2.75rem; }
  .search-card { padding: 2rem 1.5rem; }
  .allergen-grid {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 0.75rem;
  }
  .progress-steps {
    grid-template-columns: 1fr 1fr;
  }

}
/* Enhanced progress steps */
.progress-steps li.done {
  background: #d1fae5;
  border-color: #10b981;
  color: #065f46;
}

.progress-steps li.active {
  border-color: #0d9488;
  background: #ecfeff;
  color: #0f766e;
  font-weight: 600;
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
}

/* Ensure progress bar is visible */
.progress-bar {
  width: 100%;
  height: 10px;
  background: #e2e8f0;
  border-radius: 5px;
  overflow: hidden;
}

.progress {
  height: 100%;
  background: linear-gradient(90deg, #0d9488 0%, #14b8a6 100%);
  border-radius: 5px;
  transition: width 0.3s ease-in-out;
  min-width: 2%;
}
/* ============================================================================
   Donation Section Styles
   ============================================================================ */

.donation-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin: 1.5rem 0;
}

.custom-donation {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e2e8f0;
}

.custom-donation .search-input-container {
  flex: 2;
  margin-bottom: 0;
}

.custom-donation .allergen-btn {
  flex: 1;
  min-width: 140px;
}

/* Mobile responsive */
@media (max-width: 768px) {
  .donation-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .donation-grid {
    grid-template-columns: 1fr;
  }

  .custom-donation {
    flex-direction: column;
  }

  .custom-donation .allergen-btn {
    width: 100%;
  }
}
