/* Allgemeine Stile */
body {
  font-family: Arial, sans-serif;
  background-color: #121212;
  color: #ffffff;
  margin: 0;
  padding: 0;
  transition: background-color 0.3s, color 0.3s;
}

.container {
  padding: 20px;
}

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

h1 {
  margin: 0;
}

button {
  background-color: #1f1f1f;
  color: #ffffff;
  border: none;
  padding: 10px 20px;
  cursor: pointer;
  margin: 10px 0;
  border-radius: 4px;
  transition: background-color 0.3s;
}

button:hover {
  background-color: #333333;
}

/* Rezeptliste */
#recipes-list {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
}

.recipe-card {
  background-color: #1e1e1e;
  padding: 15px;
  border-radius: 8px;
  width: 300px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  transition: background-color 0.3s;
}

.recipe-card h3 {
  margin-top: 0;
}

.recipe-card button {
  margin: 5px 5px 5px 0;
}

.ingredients-list {
  margin-top: 10px;
  padding-left: 20px;
}

.ingredient-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 5px;
}

.ingredient-item span {
  flex: 1;
}

.ingredient-item button {
  margin-left: 5px;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 100;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.8);
}

.modal-content {
  background-color: #2c2c2c;
  margin: 5% auto;
  padding: 20px;
  border: 1px solid #888;
  width: 90%;
  max-width: 500px;
  border-radius: 8px;
  position: relative;
  transition: background-color 0.3s, color 0.3s;
}

.close-btn {
  color: #aaaaaa;
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

.close-btn:hover,
.close-btn:focus {
  color: #ffffff;
}

.modal-content h2 {
  margin-top: 0;
}

.modal-content form {
  display: flex;
  flex-direction: column;
}

.modal-content label {
  margin: 10px 0 5px;
}

.modal-content input,
.modal-content select {
  padding: 8px;
  border: none;
  border-radius: 4px;
}

.modal-content button {
  margin-top: 15px;
}

/* Dark Mode */
body.light-mode {
  background-color: #ffffff;
  color: #000000;
}

body.light-mode .recipe-card {
  background-color: #f9f9f9;
  color: #000000;
}

body.light-mode button {
  background-color: #e0e0e0;
  color: #000000;
}

body.light-mode .modal-content {
  background-color: #ffffff;
  color: #000000;
}

body.light-mode .recipe-card button {
  background-color: #d0d0d0;
  color: #000000;
}

body.light-mode .close-btn {
  color: #555555;
}

body.light-mode .close-btn:hover,
body.light-mode .close-btn:focus {
  color: #000000;
}

/* Responsive */
@media (max-width: 600px) {
  .recipe-card {
      width: 90%;
  }
}
