.layout {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.layout--100h {
  min-height: 100%;
}

.layout__h3 {
  font-weight: 500;
  font-size: 1.4rem;
  line-height: 1.5rem;
}

.layout__title {
  font-size: 1.8rem;
  line-height: 2rem;
  font-weight: var(--fw-medium);
  margin-bottom: 1.6rem;
}

.layout__box {
  background: var(--c-white);
  border: 0.1rem solid rgb(173 173 173 / 23%);
  box-sizing: border-box;
  box-shadow: 0 0.1rem 0.1rem rgb(0 0 0 / 4%);
  border-radius: 4px;
  margin-bottom: 2.4rem;
  position: relative;
  max-width: 100%;
}
.layout__box.layout__box--small {
  padding: 1.4rem 2.4rem;
  margin-bottom: 0;
}
.layout__box.visible {
  overflow: visible;
}

.layout__box.layout__box--p32 {
  padding: 2.4rem 1.6rem;
}

.layout__box-header {
  background-color: var(--c-light-grey);
  border-bottom: 1px solid hsla(0, 0%, 67.8%, 0.16);
  padding: 1.6rem;
  position: relative;
}

.layout__box-header-no-border {
  background-color: #fff;
  padding: 1.6rem 2.4rem;
  position: relative;
}

.layout__h4 {
  font-weight: 500;
  font-size: 1.4rem;
  line-height: 1.4rem;
}

.layout__wrapper {
  display: flex;
  background-color: var(--c-light-grey);
}

@media screen and (min-width: 992px) {
  .layout__wrapper {
    height: calc(100vh - 5.8rem);
  }
}

.layout__content-wrapper {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-width: 0;
}

@media screen and (min-width: 992px) {
  .layout__box-header {
    padding: 1.8rem 2.4rem;
  }

  .layout__box-header--small {
    padding: 1.8rem 0.6rem;
  }

  .layout__content-wrapper {
    flex-direction: row;
  }
  .layout__content .layout__box--600 {
    max-width: 60rem;
  }
}

.layout__content {
  width: 100%;
  padding: 2.4rem 1.6rem;
}

.layout__content .layout__content {
  padding: 0;
  height: auto;
}

@media screen and (min-width: 768px) {
  .layout__content {
    height: 100%;
    overflow-y: auto;
    padding: 2.4rem;
  }

  .layout__content::-webkit-scrollbar,
  .custom-scroll::-webkit-scrollbar,
  .table-overflow::-webkit-scrollbar {
    width: 8px;
    height: 8px;
    background-color: transparent;
  }

  .layout__content::-webkit-scrollbar-thumb,
  .custom-scroll::-webkit-scrollbar-thumb,
  .table-overflow::-webkit-scrollbar-thumb {
    border: 2px solid transparent;
    min-width: 8px;
    max-height: 8px;
    margin: 2px;
    background-color: var(--c-primary);
    background-clip: padding-box;
    border-radius: 4px;
  }

  .layout__content::-webkit-scrollbar-track,
  .custom-scroll::-webkit-scrollbar-track,
  .table-overflow::-webkit-scrollbar-track {
    display: none;
  }
}

.layout__grid {
  display: grid;
  grid-gap: 1rem;
  grid-template-columns: 1fr;
}

.layout__grid-element {
  grid-column: span 1;
}

@media screen and (min-width: 768px) {
  .layout__grid {
    width: 100%;
    grid-template-columns: 1fr 1fr 1fr 1fr;
  }

  .layout__box-header-no-border {
    padding: 2.4rem 3.2rem;
  }

  .layout__box.layout__box--p32 {
    padding: 3.2rem;
  }

  .layout__grid-element--size2 {
    grid-column: span 2;
  }

  .layout__grid-element--size3 {
    grid-column: span 3;
  }

  .layout__grid-element--size4 {
    grid-column: span 4;
  }
}

/* user preview in IB */
@media screen and (min-width: 992px) {
  #clientpaneldiv .layout__content-wrapper {
    flex-direction: column;
  }

  .ilpanel,
  .ilpanel > .hw-100,
  .ilpanel > .align-items-start,
  .ilpanel > .align-items-start > .hw-100 {
    width: 100%;
    height: 100%;
  }

  #il_panel #content {
    position: relative;
  }

  .ilpanel .panel {
    width: 100%;
    height: 100%;
  }
  .ilpanel .ilpanel {
    width: 100%;
  }

  #menu ~ .layout__wrapper.with-menu,
  #menu ~ .layout__wrapper.with-menu .layout__wrapper.with-menu,
  .h-100-min-menu {
    height: calc(100vh - 5.8rem - 3.9rem);
  }
  .h-100-percent-min-menu {
    height: calc(100% - 4rem);
  }
  .ilpanel .hw-100-content > .layout__content,
  .ilpanel .topbar ~ .layout__content {
    height: 90%;
    max-height: calc(100vh - 5.8rem - 3.5rem - 6rem);
    overflow-y: auto;
  }
  #clientacctlistdiv > .layout__content {
    max-height: calc(100vh - 5.8rem - 4rem);
  }
  .ilpanel .hw-100 {
    height: calc(100vh - 5.8rem - 3.5rem - 6rem);
  }

  .ilpanel > .d-flex {
    height: 100%;
  }

  .ilpanel > .layout__first {
    padding: 2.4rem;
    width: calc(100% - 18.5rem);
    position: absolute;
    background-color: #f7f8fb;
    right: 0%;
    top: 0;
    z-index: 2;
  }

  .layout__content.with-lg-space {
    padding-top: 160px;
  }
  #ccontent {
    height: 100%;
  }
}

@media screen and (max-width: 991px) {
  .layout__box.layout__box--p6 {
    padding-left: 0.6rem;
    padding-right: 0.6rem;
  }

  .layout__title {
    display: none;
  }

  #clientpaneldiv .layout__wrapper,
  #clientacctpanel {
    flex-direction: column;
  }
  .ilpanel {
    width: 100%;
  }
}
.hw-100-content .hw-100,
#clientpaneldiv > .layout__content {
  height: calc(100vh - 5.8rem - 3.5rem);
}
@media screen and (min-width: 1400px) {
  .ilpanel .layout__content .layout__content-right {
    width: calc(100% - 18.5rem - 18.5rem);
    min-width: 80%;
    margin: 0 auto 0 auto;
    padding-right: 0;
    padding-left: 0;
  }
}
.layout__box--small .topbar {
  margin-bottom: 0;
}
.layout__box.layout__box--small.mb-large {
  margin-bottom: 2rem;
}
.tab-pane > .layout__box {
  margin-bottom: 0;
}
.layout-header-flex {
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.6rem;
}
.layout-header-flex .layout__title {
  margin-bottom: 0rem;
}
#menu ~ #il_panel .tabs-content:first-child {
  padding-top: 1rem;
}
