@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600&display=swap');

body {
  margin: 0;
  height: 100vh;
  font-family: Arial, sans-serif;
  background-color: #F8F9FC;
  display: flex;
  flex-direction: column;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 20px;
  box-sizing: border-box;
  background-color: #ffffff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
}

.container {
  flex: 1;
  display: flex;
  padding-top: 80px;
  background-color: #F8F9FC;
  overflow: hidden;
}

.sidebar {
  width: 300px;
  flex-shrink: 0;
  color: #4F5979;
  margin: 30px;
  overflow-y: auto;
  box-sizing: border-box;
  background-color: #ffffff;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.sidebar p {
  margin-bottom: 30px;
  line-height: 1.5;
  color: #4F5979;
  font-family: 'Open Sans', sans-serif;
}

.main-content {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  background-color: #F8F9FC;
  padding: 20px;
  width: 100%; /* Ocupa toda a largura disponível */
}

.footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: center;
  background-color: #FFFFFF;
  padding: 20px;
  box-sizing: border-box;
}

.footer-left {
  display: flex;
  align-items: center;
}

.footer-left img {
  height: 30px;
  margin-right: 10px;
}

.footer-left span {
  color: #4F5979;
}

.footer-right {
  display: flex;
  gap: 10px;
}

.footer-left a {
  text-decoration: none;
}

.footer-right img {
  width: 24px;
  height: 24px;
}

.logo {
  height: 40px;
}

.chatbot-iframe {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  border: none;
}

.sidebar-toggle {
  display: none;
  font-size: 24px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1002;
}

.overlay {
  display: none;
  position: fixed;
  top: 80px;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  transition: opacity 0.3s ease;
  opacity: 0;
}

.overlay.active {
  display: block;
  opacity: 1;
}

.close-sidebar {
  position: absolute;
  display: none;
  top: 10px;
  right: 10px;
  background-color: #ffffff;
  color: #ff6b6b;
  border: none;
  border-radius: 50%;
  font-size: 18px;
  width: 20px;
  height: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.close-sidebar:hover {
  color: #ff4c4c;
}

.close-sidebar:active {
  transform: scale(0.9);
}

@media (max-width: 1024px) {
  .container {
    flex-direction: column;
    align-items: center;
    position: relative;
  }

  .sidebar {
    position: fixed;
    top: 50%;
    left: 0;
    width: 80%;
    height: auto;
    max-height: 80vh;
    transform: translateX(-100%) translateY(-50%);
    transition: transform 0.3s ease, opacity 0.3s ease;
    z-index: 1001;
    opacity: 0;
  }

  .sidebar.active {
    transform: translateX(calc(50vw - 50%)) translateY(-50%);
    opacity: 1;
    margin: 0;
  }

  .sidebar.active .close-sidebar {
    display: flex;
  }

  .main-content {
    margin-left: 0;
    width: 100%;
  }

  .sidebar-toggle {
    display: block;
  }

  .overlay {
    top: 0;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
  }

  .overlay.active {
    opacity: 1;
  }
}
