/* styles.css */

/* Base styles */
body {
  font-family: Arial, sans-serif;
  background-color: #f2f2f2; /* Light gray background */
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
  background-color: #fff; /* White container background */
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  min-height: 100vh;
}

.header {
  text-align: center;
  margin-bottom: 2rem;
  background-color: #c1272d; /* McDonald's red */
  color: #fff; /* White text */
  padding: 1rem;
  border-radius: 0.5rem;
}

.header h1 {
  font-size: 2rem;  /* Slightly increased font size */
  margin-bottom: 0.5rem;
}

.subtitle {
  font-size: 1.125rem;
}

.update-message { 
  font-size: 1rem;
  font-weight: bold;
  color: #ffc107; 
  margin-top: 0.5rem;
  padding: 0.5rem 1rem; 
  border-radius: 0.5rem;
  display: inline-block;
  /* Background from Bolt.new CSS */
  background: #FFC72C; 
  color: #27251F; 
  padding: 0.75rem 1.5rem; 
  border-radius: 50px; 
  box-shadow: 0 4px 12px rgba(255, 199, 44, 0.3); 
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}


/* Info box */
.info-box {
  background-color: #fff9e6; 
  color: #c1272d; 
  border: 2px solid #c1272d; 
  border-radius: 0.5rem;
  padding: 1rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center; 
  gap: 0.75rem;
}

.info-box p {
  font-size: .7.5rem; /* Adjust the value as needed */
  margin: 0; 
}

.info-icon {
  flex-shrink: 0;
  font-size: 1.2rem;
}

/* Calculator Section */
.calculator-section {
  margin-bottom: 2rem;
}

.calculator-section h2 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #c1272d; /* McDonald's red */
  margin-bottom: 1rem;
}

.instructions {
  list-style-type: decimal;
  padding-left: 2rem;
  color: #333;
}

/* Search inputs */
.search-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.search-group {
  width: 100%; 
  max-width: 400px; 
  background-color: #fff; 
  border-radius: 0.5rem;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  padding: 1rem;
  position: relative; /* To position the search results */
}

.search-group label {
  font-size: 1rem;
  font-weight: bold;
  color: #c1272d; 
  margin-bottom: 0.5rem;
}

.search-input {
  position: relative;
  display: flex;
  align-items: center; 
}

.search-icon {
  position: absolute;
  left: 1rem; 
  font-size: 1.2rem;
  color: #9ca3af;
}

.search-input input {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 3rem; 
  border: 2px solid #ffdd00; 
  border-radius: 0.375rem;
  font-size: 1rem;
  box-shadow: none; 
}

.search-input input:focus {
  outline: none;
  border-color: #c1272d; 
  box-shadow: 0 0 0 3px rgba(193, 39, 45, 0.2);
}

.search-results {
  position: absolute;
  top: calc(100% + 0.5rem); /* Position below the search box */
  left: 0; 
  width: 100%;
  z-index: 10;
  max-height: 15rem;
  overflow-y: auto;
  background: white;
  border-radius: 0.375rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  display: none;
}

.search-results.active {
  display: block;
}

.search-result-item {
  display: flex;
  align-items: center;
  padding: 0.5rem 1rem;
  cursor: pointer;
}

.search-result-item:hover {
  background-color: #f3f4f6;
}

.search-result-item img {
  width: 2rem;
  height: 2rem;
  border-radius: 9999px;
  object-fit: cover;
  margin-right: 0.75rem;
}

/* Nutrition table */
.nutrition-table {
  width: 100%;
  overflow-x: auto; 
  background: white;
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.nutrition-table table {
  width: 100%;
  border-collapse: collapse;
}

.nutrition-table th,
.nutrition-table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid #e5e7eb;
}

.nutrition-table th {
  font-weight: 600;
  color: #333;
}

.nutrition-table td {
  color: #374151;
}

.item-header {
  text-align: center;
}

.item-header img {
  width: 4rem;
  height: 4rem;
  border-radius: 9999px;
  object-fit: cover;
  margin: 0 auto 0.5rem;
}

.allergen-tag {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background-color: #fee2e2;
  color: #991b1b;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  margin: 0.25rem;
}

.ingredient-tag { 
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background-color: #e0f2fe; 
  color: #0284c7; 
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  margin: 0.25rem;
}

.value-highest {
  color: #dc2626; 
}

.value-lowest {
  color: #059669; 
}

.value-container {
  display: flex;
  align-items: center;
  gap: 16px;
}

.value-info {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.value {
  font-weight: 600;
  color: #333;
}

.daily-value {
  font-size: 0.875rem;
  color: #333 !important; /* Dark gray color */
}

.arrow {
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
}

.arrow.up {
  border-bottom: 12px solid #dc2626; 
}

.arrow.down {
  border-top: 12px solid #059669; 
}

.content-below {
  margin-top: 2rem;
}

.content-below h2 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #c1272d; /* McDonald's red */
  margin-bottom: 1rem;
}