﻿#videos {
  --base-gap: 2rem;
  --hover-gap: 0.75rem;
  --base-width: 9rem;
  --hover-width: 14rem;

  display: flex;
  flex-direction: column;
  align-items: center;
  background: white;
  font-family: 'ClashDisplay', sans-serif;
  width: 100%;
  padding-top: 5rem;
  padding-bottom: 10rem;

  @media (max-width: 1024px) {
    padding-top: 3rem;
    padding-bottom: 5rem;

    --base-width: 7rem;
    --hover-width: 11rem;
  }

  @media (max-width: 768px) {
    --base-width: 6rem;
    --hover-width: 9rem;
    --base-gap: 1rem;
  }

  .videos-container {
    width: 72%;
    max-width: 84rem;

    @media (max-width: 1024px) {
      width: 80%;
    }

    @media (max-width: 768px) {
      width: 85%;
    }

    .videos-header {
      @media (max-width: 768px) {
        h1 {
          font-size: 0.8rem;
        }
      }

      letter-spacing: 0.2rem;
      text-align: center;
      line-height: 0.1em;


      .title {
        display: flex;
        text-align: center;
        justify-content: center;

        .horizontal-line {
          text-align: center;
          border-bottom: 1px solid black;
          line-height: 0.1em;
          width: 2.5rem;
          margin-left: 0.5rem;
          margin-right: 1rem;
        }
      }

      .subtitle {
        h1 {
          padding-top: 1rem;
        }
      }
    }

    .video-carousel {
      padding-top: 4rem;
      overflow: hidden;
      position: relative;

      @media (max-width: 1024px) {
        padding-top: 3rem;
      }

      @media (max-width: 768px) {
        padding-top: 2rem;
      }

      &::before,
      &::after {
        content: "";
        position: absolute;
        top: 0;
        bottom: 0;
        width: 100px;
        z-index: 2;
        pointer-events: none;
      }

      &::before {
        left: 0;
        background: linear-gradient(to right, white, transparent);
      }

      &::after {
        right: 0;
        background: linear-gradient(to left, white, transparent);
      }

      .video-track {
        display: flex;
        align-items: center;
        height: 22rem;
        gap: var(--base-gap);
        width: max-content;
        transition: gap 0.5s ease;

        @media (max-width: 1024px) {
          height: 18rem;
        }

        @media (max-width: 768px) {
          height: 15rem;
        }

        &:has(.video-item:hover) {
          gap: var(--hover-gap);
        }
      }

      .video-item {
        width: var(--base-width);
        height: 20rem;
        overflow: hidden;
        border-radius: 5rem;
        transition: all 0.5s ease;

        @media (max-width: 1024px) {
          height: 16rem;
        }

        @media (max-width: 768px) {
          height: 13rem;
        }

        &:hover {
          width: var(--hover-width);
          height: 22rem;
          border-radius: 1rem;

          @media (max-width: 1024px) {
            height: 18rem;
          }

          @media (max-width: 768px) {
            height: 15rem;
          }
        }

        img {
          width: 100%;
          height: 100%;
          object-fit: cover;
          object-position: center;
        }
      }
    }
  }
}
