.exchanges-container {
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin-top: 84px;

  h2 {
    font-weight: 500;
    font-size: 36px;
    line-height: 38px;
    letter-spacing: 0%;
    color: #000000;
  }

  .exchanges-full-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;
    width: 100%;

    .exchanges {
      display: grid;
      grid-template-columns: 1fr;
      gap: 24px;

      .exchange {
        width: 588px;
        height: fit-content;
        max-width: 588px;
        max-height: fit-content;
        border-radius: 20px;
        display: flex;
        flex-direction: column;
        position: relative;
        overflow: hidden;

        .exchange-image {
          width: 100%;
          height: 299px;
          position: relative;
          z-index: 1;

          img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            border-radius: 20px;
            display: block;
          }
        }

        .exchange-details {
          width: 95%;
          margin: -40px auto 0 auto;
          background: #ffffff;
          border: 1px solid #cccccc;
          border-radius: 16px;
          position: relative;
          z-index: 2;
          padding: 24px;
          display: flex;
          flex-direction: column;
          gap: 24px;

          .exchange-info {
            display: flex;
            flex-direction: column;
            gap: 32px;

            ul {
              display: flex;
              align-items: center;
              gap: 32px;

              li {
                display: flex;
                align-items: center;
                gap: 5px;

                img {
                  width: 15px;
                  height: 15px;
                }

                p {
                  font-weight: 400;
                  font-size: 14px;
                  line-height: 18px;
                  letter-spacing: -0.36px;
                  color: #7a7a7a;
                }
              }
            }

            h3 {
              a {
                font-weight: 500;
                font-size: 32px;
                line-height: 40px;
                letter-spacing: -0.64px;
                text-decoration: underline;
                text-decoration-style: solid;
                text-decoration-thickness: 0%;
                color: #05091d;
              }
            }
          }
        }
      }
    }

    .exchanges-category {
      width: 382px;
      max-width: 382px;
      height: fit-content;
      max-height: fit-content;
      border-radius: 10px;
      border: 1px solid #cccccc;
      padding: 20px;

      display: flex;
      flex-direction: column;
      gap: 28px;

      h3 {
        font-weight: 700;
        font-size: 24px;
        line-height: 37px;
        letter-spacing: 0px;
        color: #090f32;
      }

      .categories {
        ul {
          list-style: none;
          display: flex;
          flex-direction: column;
          gap: 28px;

          li {
            a {
              text-decoration: none;
              display: flex;
              align-items: center;
              justify-content: space-between;

              font-weight: 400;
              font-size: 24px;
              line-height: 40px;
              letter-spacing: 0px;
              color: #4f4f4f;

              span {
                font-weight: 400;
                font-size: 24px;
                line-height: 40px;
                letter-spacing: 0px;
                color: #4f4f4f;
              }
            }

            &.category-active {
              a {
                color: #d63832;

                span {
                  color: #d63832;
                }
              }
            }
          }
        }
      }
    }
  }
}

@media screen and (max-width: 450px) {
  .exchanges-container {
    margin-top: 60px !important;

    h2 {
      font-size: 28px !important;
      line-height: 38px !important;
    }

    .exchanges-full-container {
      .exchanges-category {
        display: none;
      }

      .exchanges {
        width: 100%;

        .exchange {
          width: 100% !important;
          height: fit-content !important;
          width: 100% !important;
          min-width: 343px !important;

          .exchange-details {
            width: 100% !important;
          }
        }
      }
    }
  }
}

@media screen and (min-width: 768px) and (max-width: 1024px) {
  /* All tablet overrides grouped here */

  .exchanges-container {
    margin-top: 72px;

    h2 {
      font-size: 32px;
      line-height: 40px;
    }

    .exchanges-full-container {
      flex-direction: column;
      align-items: stretch;

      .exchanges {
        grid-template-columns: 1fr;

        .exchange {
          width: 100%;
          max-width: none;
          display: grid;
          grid-template-columns: 1fr;
          align-items: stretch;

          .exchange-image,
          .exchange-details {
            grid-area: 1 / 1;
          }

          .exchange-details {
            width: 100%;
            align-self: flex-end;
          }
        }
      }

      .exchanges-category {
        width: 100%;
        max-width: none;
      }
    }
  }
}
