.work {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.wrap-work {
  max-width: 1440px;
  width: 100%;
  padding: 4rem 1.2rem 2rem;
}

.w-title {
  margin-bottom: 2rem;
}

.work-box {
  width: 100%;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
}

.client {
  width: 48%;
  background: none;
  border: 1px solid #ffffff;
  margin-bottom: 4%;
  height: 120px;
  border-radius: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
  outline: none;
  cursor: pointer;
  transition: background-color 250ms ease-out, border-color 250ms ease-out;
}

.client img {
  opacity: 0.8;
  pointer-events: none; 
  transition: opacity 250ms ease-out, filter 250ms ease-out;
  /* CORREÇÃO FINAL: Lendo a variável CSS para a altura mobile */
  height: var(--mobile-height); 
}

.client:hover {
  background-color: var(--hover-color);
  border-color: var(--hover-color) !important;
}

.client:hover img {
  opacity: 1;
}

.client:hover img.filter-invert-on-hover {
  filter: brightness(0);
}

/* --- Media Queries --- */
@media screen and (min-width: 768px) {
  .w-title {
    margin-bottom: 3rem;
  }
}

@media screen and (min-width: 1024px) {
  .wrap-work {
    padding: 5rem 1.2rem;
  }
  .client {
    width: 32%;
    margin: 0.8rem 0;
    height: 160px;
  }
}

@media screen and (min-width: 1280px) {
  .wrap-work {
    padding: 8rem 0 4rem 0;
    width: 94%;
  }
  .client {
     margin-bottom: 0.8rem;
  }
}

@media screen and (min-width: 1440px) {
  .wrap-work {
    padding: 8rem 0;
  }
  .client {
    margin-bottom: 1rem;
    height: 200px;
  }
  .client img {
    /* CORREÇÃO FINAL: Lendo a variável CSS para a altura desktop */
    height: var(--desktop-height);
  }
}

/* --- Estilos do Drawer (sem alterações) --- */
.drawer {
  position: fixed;
  top: 0;
  right: -100%;
  height: 100vh;
  width: 100%;
  display: flex;
  flex-direction: column;
  overflow-y: scroll;
  overflow-x: hidden;
  z-index: 10;
  transition: right 0.5s ease-out;
  background-color: #fff;
}

.drawer.open {
  right: 0;
}

body.modal {
  overflow: hidden;
}

.col-close {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 12;
  width: 100%;
  height: 80px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  border-bottom: solid 1px lightgray;
  background-color: #fff;
}

.col-close svg {
  width: 48px;
  margin-right: 1.2rem;
}

.col-content {
  margin-top: 80px;
  padding: 2rem 1.2rem;
}

.client-title {
  font-size: 2.4rem;
  font-weight: 500;
  margin-bottom: 2rem;
}

.deliv-t {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 0.8rem;
}

.deliv-items {
  display: flex;
  flex-wrap: wrap;
  margin-bottom: 1.2rem;
}

.deliv-items span {
  font-size: 0.8rem;
  padding: 0.6rem;
  border: solid 1px #101727;
  border-radius: 50px;
  margin-right: 0.4rem;
  margin-bottom: 0.4rem;
}

.client-content p {
  font-size: 1.2rem;
  margin-bottom: 1.2rem;
  line-height: 1.4;
}

.div {
  width: 100%;
  height: 1px;
  background-color: lightgray;
  margin: 2rem 0;
}

.info-item {
  display: flex;
  justify-content: space-between;
  border-bottom: solid 1px lightgray;
  padding: 1.4rem 0;
}

.info-left {
  color: gray;
}

.client-screen {
  margin-top: 2rem;
  width: 100%;
}

.client-screen img {
  width: 100%;
  margin-bottom: 1rem;
}

.close {
  cursor: pointer;
  background: none;
  border: none;
}

.close:hover svg {
  transform: rotate(90deg);
  transition: 240ms ease-out;
}

.close:hover .close-f {
  fill: #F66135;
  transition: 240ms ease-out;
}

.close:hover .close-s {
  stroke: #F66135;
  transition: 240ms ease-out;
}

@media screen and (min-width: 1024px) {
  .overlay {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    height: 100vh;
    background-color: rgba(255, 255, 255, 0.36);
    z-index: 8;
    backdrop-filter: blur(4px);
    display: none;
  }

  .drawer {
    width: 840px;
    flex-direction: row; 
    right: -840px;
  }

  .col-close {
    position: relative;
    width: 120px;
    height: 100%;
    padding-top: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    border: none;
    background-color: transparent;
  }

  .col-close button {
    position: sticky;
    top: 20px;
  }

  .col-content {
    margin-top: 0;
    width: 720px;
    height: 100%;
    padding: 2rem 2rem 4rem;
    overflow-y: auto;
  }

  /* --- Estilos do Scrollbar Customizado --- */
  .col-content {
    scrollbar-width: thin;
    scrollbar-color: #dfdfdf #ffffff;
  }

  .col-content::-webkit-scrollbar {
    width: 8px;
  }

  .col-content::-webkit-scrollbar-track {
    background: #F1F1F1;
  }

  .col-content::-webkit-scrollbar-thumb {
    background-color: #AAAAAA;
    border-radius: 4px;
    border: 2px solid #F1F1F1;
  }

  .col-content::-webkit-scrollbar-thumb:hover {
    background-color: #888888;
  }
  
  .col-content::-webkit-scrollbar-button {
    width: 0;
    height: 0;
    display: none;
  }
}