:root {
    --textfarbe: #EEF0F4;
    --hintergrundfarbe: #140531;
    --helle-hintergrundfarbe: #5b3d98;
    --dunkle-hintergrundfarbe: #11042a;
    --checked: #4dc51a;
}

html, body {
    margin: 0;
    padding: 0;
    font-family: Verdana, Geneva, Tahoma, sans-serif;
    background-color: var(--hintergrundfarbe);
    color: var(--textfarbe);
}

button:hover {
    cursor: pointer;
}

form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

input {
  padding: 10px;
  font-size: 16px;
  border: 1px solid #ccc;
  border-radius: 6px;
}

/* #################### Custom #################### */

.button {
    color: var(--textfarbe);
    background-color: var(--helle-hintergrundfarbe);
    border: none;
    padding: 10px;
    border-radius: 8px;
    font-family: Verdana, Geneva, Tahoma, sans-serif;
    font-size: 20px;
    font-weight: bold;
    text-align: center;
}

.iti {
  color: black;
}

.image-container {
  display: grid;
  grid-template-columns: 80px 150px 80px; /* fixed width for icons columns and cat image */
  align-items: center; /* center vertically */
  justify-content: center; /* center horizontally */
  gap: 20px;
}

#catImage {
  width: 150px;
  display: block;
}

.icons {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 15px;
}

.lord-icon {
  width: 60px;
  height: 60px;
}

#loader {
  width: 100px;
  height: 100px;
}

.container {
  display: flex;
  flex-direction: column;
  max-width: 320px;
  margin: auto;
  align-items: center;
  border-radius: 10px;
  padding: 2rem;
  gap: 1rem; 
}


.buttons {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.error-text {
  color: red;
  font-size: 14px;
}


#list-form {
  display:flex;
  flex-direction: row;
  justify-content: space-between;
}


#shopping-list {
  display: flex;
  flex-wrap: wrap;
  list-style-type: none;
  padding: 0;
  gap: 10px;
}

#shopping-list li {
  font-size: 20px;
  /* width:100%; */
  background-color: var(--helle-hintergrundfarbe);
  border-radius: 8px;
  flex-grow: 1;
  flex-shrink: 0;
  text-align: center;
  box-shadow: 0px 1px 4px rgba(0, 0, 0, 0.2);
  transition: 
      background-size 1.6s 0.4s cubic-bezier(.7,.2,.17,1),
      background-color 0.2s cubic-bezier(.7,.2,.17,1),
      height 0.2s 1s cubic-bezier(.7,.2,.17,1);
  position:relative;
  background-image: linear-gradient(to right, #FE5F55, red);
  background-size: 0 2px;
  background-repeat:no-repeat;
  background-position: left bottom;
  -webkit-user-select: none;
  -ms-user-select: none; 
  user-select: none; 
  padding: 12px 15px;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}


.checked {
    text-decoration: line-through;
    color: var(--checked);
}



button:disabled {
  background: grey;
  cursor: not-allowed;
}





/* State when an item is being dragged */
#shopping-list li.dragging {
    opacity: 0.5; /* Make dragged item semi-transparent */
    border: 2px dashed #3498db; /* Visual border */
    transform: scale(1.02);
}

/* Trash Bin Styles */
#trash-bin-area {
    margin-top: 20px;
    padding: 6px 0;
    text-align: center;
    background-color: #f8d7da; /* Light red background */
    border: 2px dashed #dc3545; /* Red dashed border */
    border-radius: 10px;
    color: #dc3545; /* Red text color */
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: background-color 0.2s ease-in-out, border-color 0.2s ease-in-out;
}

#trash-bin-area .material-icons {
    font-size: 4em; /* Large icon */
}

#trash-bin-area p {
    margin: 0;
    font-weight: bold;
}

/* State when a draggable item is over the trash bin */
#trash-bin-area.drag-over {
    background-color: #dc3545; /* Solid red when dragged over */
    border-color: #c82333;
    color: white; /* White text/icon */
}

#add-button {
  padding: 4px;
  text-align: center;
  background-color: #d7f8da; /* Light red background */
  border: 2px dashed #35dc72; /* Red dashed border */
  border-radius: 10px;
  color: #35dc54; /* Red text color */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: background-color 0.2s ease-in-out, border-color 0.2s ease-in-out;
}


.info-icon {
    cursor: pointer;
    margin-left: 5px;
    font-size: 0.8em;
    color:  var(--textfarbe); 
}

.hidden-info {
  display: none;
  background-color: var(--textfarbe);
  padding: 10px;
  border-radius: 5px;
  z-index: 100;
  font-style: italic;
  color: var(--hintergrundfarbe);
  text-align: justify;
}
