dialog {
  opacity: 0;
  transform: scaleY(0);
  transition: opacity 0.2s ease-out, transform 0.2s ease-out;
  max-width: 900px;
  border-radius: 24px;
  border: none;
  padding: 30px;
}

dialog[open] {
  opacity: 1;
  transform: scaleY(1);
}

@starting-style {
  dialog[open] {
    opacity: 0;
    transform: scaleY(0);
  }
}

.food-description-container {
  display: flex;
  flex-direction: row;
}

.food-description-picture {
  width: 600px;
  height: 400px;
  object-fit: cover;
  border-radius: 20px;
  margin-right: 50px;
}

.food-name {
  font-size: 25px;
  font-weight: bold;
  line-height: 50px;
}

.food-price {
  display: flex;
  align-items: center;
  padding-bottom: 20px;
}

.original-price {
  text-decoration: line-through;
  color: grey;
  font-weight: 500;
  font-size: 15px;
}

.discounted-price {
  padding-left: 6px;
  font-size: 24px;
  font-weight: 700;
}

.buy-button {
  border-radius: 15px;
  border-style: none;
  box-shadow: 0px 0px 5px rgba(0, 0, 0, 0.3);
  background-color: #ffea00;
  padding: 10px 30px;
  margin-right: 10px;
  margin-left: 0;
  color: rgb(0, 0, 0);
  font-weight: bold;
  font-size: 14px;
  cursor: pointer;
  transition: background-color 0.4s;
}

.buy-button:hover {
  background-color: #ffd500;
}

.description {
  padding-top: 20px;
}

.description-heading {
  font-size: 20px;
  padding-bottom: 10px;
  font-weight: 600;
}

.description-content {
  padding-right: 200px;
  font-size: 18px;
  font-weight: lighter;
  line-height: 1.5;
}

.veg-non-veg {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-top: 15px;
}

.food-sticker {
  width: 25px;
  height: 25px;
}

.veg-non {
  font-weight: 300;
  font-size: 16px;
}

.ingredients-heading {
  padding-top: 20px;
  font-size: 20px;
  font-weight: 600;
}

.ingredients-content {
  padding-top: 10px;
  padding-right: 200px;
  font-size: 18px;
  font-weight: lighter;
  line-height: 1.5;
}

.nutrients-heading {
  font-size: 20px;
  font-weight: 600;
  padding-top: 20px;
  padding-bottom: 20px;
}

.nutrients-content {
  display: grid;
  grid-template-columns: 100px 80px 80px 80px 100px;
  column-gap: 20px;
  align-items: center;
}

.nutrients-value {
  text-align: center;
}

.nutrients-number {
  font-size: 25px;
  font-weight: 700;
  margin-bottom: 5px;
}

.nutrients-value div:last-child {
  font-size: 13px;
  color: #666;
}

.dialog-close-btn {
  position: absolute;
  top: 15px;
  right: 15px;
  background: rgba(0, 0, 0, 0.6);
  color: white;
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  z-index: 10;
  line-height: 1;
}

.dialog-close-btn:hover {
  background: rgba(0, 0, 0, 0.8);
}

@media screen and (max-width: 768px) {
  .dialog-close-btn {
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    font-size: 20px;
  }
}



@media screen and (max-width: 1024px) {
  dialog {
    max-width: 85vw;
    padding: 25px;
  }

  .food-description-picture {
    width: 400px;
    height: 300px;
    margin-right: 30px;
  }

  .description-content,
  .ingredients-content {
    padding-right: 50px;
    font-size: 16px;
  }

  .nutrients-content {
    grid-template-columns: repeat(5, 1fr);
    column-gap: 15px;
  }
}



@media screen and (max-width: 768px) {
  dialog {
    max-width: 95vw !important;
    min-height: auto !important;
    max-height: 60vh;
    margin: 0px !important;
    padding: 0;
    overflow-y: auto;
  }

  .food-description-container {
    flex-direction: column;
  }

  .food-description-picture {
    width: 100%;
    height: auto;
    max-height: 300px;
    margin-right: 0;
    margin-bottom: 20px;
    border-radius: 16px;
  }

  .food-name {
    font-size: 12px;
    line-height: 1;
  }

  .food-price {
    padding-bottom: 10px;
  }

  .original-price {
    font-size: 14px;
  }

  .discounted-price {
    font-size: 20px;
    padding-left: 8px;
  }

  .buy-button {
    width: 100%;
    padding: 12px 20px;
    font-size: 15px;
    margin-bottom: 10px;
  }

  .description {
    padding-top: 15px;
  }

  .description-heading,
  .ingredients-heading {
    font-size: 18px;
    padding-bottom: 8px;
  }

  .description-content,
  .ingredients-content {
    padding-right: 0;
    font-size: 15px;
    line-height: 1.6;
  }

  .veg-non-veg {
    padding-top: 10px;
    gap: 8px;
  }

  .food-sticker {
    width: 22px;
    height: 22px;
  }

  .veg-non {
    font-size: 14px;
  }

  .nutrients-heading {
    font-size: 18px;
    padding-top: 15px;
    padding-bottom: 15px;
  }

  .nutrients-content {
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    row-gap: 20px;
  }

  .nutrients-value {
    text-align: center;
  }

  .nutrients-number {
    font-size: 22px;
  }

  .nutrients-value div:last-child {
    font-size: 12px;
  }
}


@media screen and (max-width: 480px) {
  dialog {
    max-width: 100vw !important;
    min-height: 80vh !important;
    max-height: 80vh;
    margin: 0 !important;
    padding: 15px;
    border-radius: 0;
  }

  .food-description {
    margin-top: 10px;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
  }

  .food-description-picture {
    max-height: 250px;
    border-radius: 12px;
    margin: 0;
  }

  .food-name {
    font-size: 15px;
    margin-top: 12px;
    max-width: 60px;
    max-height: 20px;
  }

  .food-price {
    max-width: 100px;
    margin-top: 14px;
    max-height: 20px;
  }

  .discounted-price {
    font-size: 10px;
  }

  .original-price {
    font-size: 10px;
    margin-left: 20px;
  }

  .buy-button {

    margin-left: 60px;
    padding: 14px;

    font-size: 14px;
    max-width: 60px;
    margin-top: 0;
  }

  .description-heading,
  .ingredients-heading,
  .nutrients-heading {
    font-size: 12px;
  }

  .description-content,
  .ingredients-content {
    font-size: 10px;
  }

  .nutrients-content {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    row-gap: 15px;
  }

  .nutrients-value {
    margin-top: 0;
    margin-bottom: 0;
  }

  .nutrients-number {
    font-size: 12px;

  }

  .nutrients-value div:last-child {
    font-size: 10px;
  }
}