/* Adjusted styles */
html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: Arial, sans-serif;
}

.grid-container {
  display: grid;
  grid-template-columns: 1fr 50%;
  /* Adjust this according to your layout needs */
  height: 100%;
}

.browser-iframe {
  width: 100%;
  /* iframe takes the full width of its grid area */
  height: 100%;
  /* Adjust height as needed */
  border: none;
}

.overlay {
  position: absolute;
  top: 0;
  left: 50%;
  right: 0;
  bottom: 0;
  /* background: rgba(255, 255, 255, 0.75); */
  /* transparent overlay */
  z-index: 10;
  /* Ensure it's above the iframe */
  /* filter: grayscale(100%); */
  /* filter: brightness(30%); */
}

#chat-container {
  display: flex;
  flex-direction: column;
  height: 100vh;
}

#message-container {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px;
  background: #f0f0f0;
}

.sent {
  background-color: #007aff;
  color: white;
  align-self: flex-end;
  max-width: 80%;
  /* margin-bottom: 12px; */
  /* padding: 10px; */
  border-radius: 20px;
}

.message {
  max-width: 80%;
  margin-top: 12px;
  margin-bottom: 12px;
  padding: 10px;
  border-radius: 20px;
}

.message a {
  word-break: break-all;
  overflow-wrap: break-word;
}

.received {
  background-color: #e5e5ea;
  color: black;
  align-self: flex-start;
}

#message-form {
  display: flex;
  background: white;
  padding: 10px;
  border-top: 1px solid #ccc;
}

#message-input {
  flex-grow: 1;
  border: none;
  padding: 10px;
  margin-right: 10px;
  border-radius: 20px;
  outline: none;
  resize: none;
  /* Prevents the user from manually resizing the textarea */
  overflow-y: auto;
  /* Allows scrolling inside the textarea if the content exceeds its height */
}

button {
  padding: 10px 20px;
  border: none;
  background-color: #007aff;
  color: white;
  border-radius: 20px;
  cursor: pointer;
}

/* Add space between paragraphs */
.message p {
  margin-top: 0;
  margin-bottom: 20px;
  /* Adjust this value to control the space between paragraphs */
}

/* Remove space before the first paragraph */
.message p:first-child {
  margin-top: 0;
}

/* Remove space after the last paragraph */
.message p:last-child {
  margin-bottom: 0;
}

/* System or Info Message Style */
.info {
  margin: 0px;
  align-self: center;
  /* Ensures the message is centered horizontally */
  color: #666;
  /* A lighter text color for subtlety */
  font-size: 12px;
  /* Smaller text size */
  max-width: 100%;
  /* Allows the message to span the full width if necessary */
  text-align: center;
  /* Centers the text within the message */
}

.info p {
  margin-top: 0;
  margin-bottom: 0px;
  /* Adjust this value to control the space between paragraphs */
}

.info a {
  word-break: break-all; /* Breaks the text at any point to ensure it fits within its container */
  overflow-wrap: break-word; /* Allows unbreakable words to be broken */
}

/* Price Box Overlay CSS */
.price-box {
  position: absolute;
  top: 0;
  left: 0;
  background-color: white;
  border: 1px solid #ccc;
  padding: 5px;
  border-radius: 5px;
  font-size: 14px;
  margin: 10px;
  box-shadow: 0px 0px 5px rgba(0,0,0,0.2);
}

/* Spinner Styles */
.spinner-container {
  display: none; /* Use flexbox to center the spinner */
  justify-content: center; /* Center horizontally in the flex container */
  align-items: center; /* Center vertically in the flex container */
  padding: 10px; /* Add some padding around the spinner */
}

.spinner {
  border: 4px solid rgba(0, 0, 0, 0.1); /* Light grey border */
  border-top-color: #007aff; /* Blue color for the spinner */
  border-radius: 50%; /* Make it a circle */
  width: 24px;
  height: 24px;
  animation: spin 1s linear infinite; /* Spin animation */
}

@keyframes spin {
  0% {
    transform: rotate(0deg); /* Start position */
  }
  100% {
    transform: rotate(360deg); /* End position - a full circle */
  }
}
