.tab-container {
  display: flex;
  border-bottom: 2px solid #ccc;
  width: 100%;
}

#showQuestions {
  display: none;
}

#hideQuestions {
  display: none;
  z-index: 1001;
}

.invisible-slider {
  display: none;
}

#clockGridContainer::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 110px; /* Height of 2 rows plus gaps */
  border: 2px dotted #000; /* Dotted border styling */
  pointer-events: none; /* Ensure it does not block interactions */
}

.tab-button {
  flex: 1;
  background-color: #f1f1f1;
  border: 1px solid #ccc;
  border-bottom: none;
  padding: 1em 0;
  cursor: pointer;
  transition: background-color 0.3s ease;
  font-size: 14px;
  outline: none;
  text-align: center;
}

.tab-button:hover {
  background-color: #ddd;
}

.tab-button.active {
  background-color: white;
  font-weight: bold;
}

.tab-button:not(:last-child) {
  margin-right: 2px;
}

#col_aposentadoria, #col_perfil {
  transition: width 0.5s ease;
}

#col_rentabilidade, #col_expectativa {
  opacity: 0;
  max-height: 0;
  transition: opacity 0.5s ease, max-height 0.5s ease;
}

#col_rentabilidade.show, #col_expectativa.show {
  opacity: 1;
  max-height: 1000px; /* Large enough to accommodate the content */
}

#retiradas_aportes_form_group {
  opacity: 0;
  max-height: 0;
  transition: opacity 0.5s ease, max-height 0.5s ease; /* Large enough to accommodate the content */
}

#retiradas_aportes_form_group.show {
  opacity: 1;
  max-height: 1000px; /* Large enough to accommodate the content */
}

#retiradas_aportes::before.show {
  opacity: 1;
  max-height: 1000px; /* Large enough to accommodate the content */
}

#retiradas_aportes::before {
  content: "";
  display: inline-block;
  vertical-align: middle;
  position: absolute;
  height: 100%;
  width: 4px;
  background: #0BB2E0;
  left: -1.5rem;
  top: 0;
  display: none;
}

.arrow {
  position: fixed;
  bottom: 10px;
  width: 45px; /* 30px * 1.5 */
  height: 45px; /* 30px * 1.5 */
  line-height: 45px; /* Adjusted for centering content */
  text-align: center;
  background-color: #ccc;
  color: #333;
  cursor: pointer;
  border-radius: 50%;
  font-size: 30px; /* 20px * 1.5 */
  z-index: 1000;
}

#up-arrow {
  display: none;
}

#down-arrow {
  display: none;
}

.actions {
  display: flex;
  justify-content: flex-end;
}

.actions button {
  margin-left: 5px; /* Add some spacing between buttons */
}

#chart-container {
  position: relative;
}

#portfolioChart {
  display: none;
}

.btn-switch {
  position: fixed;
  bottom: 10%; /* Adjust as needed for desired spacing */
  right: 30%; /* Adjust as needed for desired spacing */
  z-index: 21001; /* Ensure above other content */
  display: none;
}

#portfolio-table {
  font-family: Arial, sans-serif;
  border-collapse: collapse;
  width: 100%;
}

#portfolio-table th, #portfolio-table td {
  border: 1px solid #dddddd;
  text-align: left;
  padding: 8px;
}

#portfolio-table th {
  background-color: #f2f2f2;
}

/* Hide ::before pseudo-element on desktop screens */
@media only screen and (max-width: 1000px) and (orientation: portrait) {
  .tabs-portfolio {
    display: none !important;
  }
  #questionsContainer {
    z-index: 1 !important;
    left: -50% !important;
    transition: margin-left 0.5s ease-in-out !important;
  }
  #portfolioChart {
    left: 0 !important;
    position: fixed;
    width: 100%;
    height: 70%;
    bottom: 0;
    z-index: 45;
    overflow-y: scroll;
    transform: translateY(100%);
    background-color: #ffffff;
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    border-radius: 12px 12px 0 0;
    box-shadow: 0 0 12px rgba(0, 0, 0, 0.15);
  }
  #portfolioChart2 {
    z-index: 45;
    width: 60%;
    height: 30%;
    margin-top: 5%;
    margin-left: 5%;
    margin-bottom: 40px;
  }
  .actions {
    flex-direction: column;
    align-items: flex-end;
    display: flex;
  }
  .actions button {
    margin-left: 0;
    margin-top: 5px;
  }
  #portfolioChart.visible {
    transform: translateY(0);
    opacity: 1;
  }
  #showQuestions {
    display: none;
  }
  #hideQuestions {
    display: none;
    z-index: 1001;
  }
  #down-arrow,
  #up-arrow {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    width: 45px;
    height: 45px;
    line-height: 45px;
    text-align: center;
    background-color: #ccc;
    color: #333;
    cursor: pointer;
    border-radius: 50%;
    font-size: 30px;
    z-index: 1000;
  }
  #down-arrow {
    bottom: 78%;
  }
  #up-arrow {
    bottom: 5%;
  }
  #tableContainer {
    top: 400px;
    right: 0;
    width: 100%;
    height: fit-content;
    margin-left: 0%;
    background-color: #ffffff;
    transition: width 0.5s ease, margin-left 0.5s ease;
  }
  #thirdContainer {
    top: 400px;
    right: 0;
    width: 100%;
    height: fit-content;
    margin-left: 0%;
    background-color: #ffffff;
    transition: width 0.5s ease, margin-left 0.5s ease;
  }
  .tabs-portfolio {
    display: none;
  }
  .wrapQuestions {
    z-index: 1;
  }
  .aportsdiv .col-md-4 {
    margin-top: 15px;
  }
  .aportsdiv select,
  .aportsdiv .input-group-addon {
    height: 38px;
  }
}
@media only screen and (max-width: 1000px) and (orientation: landscape) {
  .title-panel {
    display: none !important;
  }
  #down-arrow {
    display: none !important;
  }
  #up-arrow {
    display: none !important;
  }
  #portfolioChart {
    overflow-y: scroll;
    position: fixed;
    width: 100%;
    height: 100% !important;
    bottom: 0;
    transform: translateY(100%);
    opacity: 0;
    max-height: 100000%;
    margin-left: -16px;
    background-color: #ffffff; /* Added from portrait */
    border-radius: 12px 12px 0 0; /* Added from portrait */
    box-shadow: 0 0 12px rgba(0, 0, 0, 0.15); /* Added from portrait */
    transition: transform 0.3s ease, opacity 0.3s ease; /* Added from portrait */
  }
  #portfolioChart.visible {
    transform: translateY(0);
    opacity: 1;
  }
  #showQuestions {
    position: fixed;
    top: 55%;
    left: 10px;
    transform: translateY(-50%);
    cursor: pointer;
    z-index: 1960;
    display: block;
  }
  #hideQuestions {
    position: fixed;
    top: 50%;
    right: 45%;
    cursor: pointer;
    z-index: 1970;
    display: none;
  }
  #questionsContainer {
    overflow-y: scroll;
    position: fixed;
    top: 0;
    left: -50% !important;
    width: 50%;
    height: 100%;
    background-color: #f9f9f9;
    z-index: 950;
    padding: 20px;
    box-sizing: border-box;
    overflow-y: auto;
    transition: left 0.5s ease-in-out !important;
  }
  #questionsContainer.showQuestionsContainer {
    left: 0% !important;
  }
  .wrapQuestions {
    z-index: 1000 !important;
  }
  #portfolioChart2 {
    z-index: 45;
    width: fit-content;
    height: fit-content;
    margin-top: 5%;
    margin-left: 5%;
  }
  .tabs-portfolio {
    display: flex !important;
    justify-content: space-around !important;
    z-index: 100000 !important;
    background-color: white !important;
    list-style-type: none !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  .tabs-portfolio li {
    flex: 1 !important;
    text-align: center !important;
  }
  /* Merged from portrait */
  .actions {
    flex-direction: column;
    align-items: flex-end;
    display: flex;
  }
  .actions button {
    margin-left: 0;
    margin-top: 5px;
  }
}
@media (max-width: 900px) {
  #portfolioChart2 {
    width: 90%;
    height: 100%;
  }
}