/*
Banner Video DMs: (1200, 420) px
*/

.video-avatar {
  margin: 0 auto;
  /* Centers horizontally */
  position: absolute;
  /* important */
  left: 50%;
  transform: translateX(-50%);
  bottom: -70px;

  width: clamp(100px, 25vw, 160px);
  height: clamp(100px, 25vw, 160px);

  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--accent);

  z-index: 10;
  /* ensures it sits above video */
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
}

.video-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;

  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
}

.main-content {
  opacity: 0;
  animation: fadeUp 1s ease forwards;
  animation-delay: 0.5s;
}

.hero {
  position: relative;
  height: 30vw;
  overflow: visible;
}

/* Video background */
.hero-video {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: translate(-50%, -50%);
  z-index: 0;

  border: 2px solid var(--accent);
  border-radius: 12px;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
  background-color: black;
}

.hero::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;

  opacity: 0;
  animation: fadeUp 1s ease forwards;
}

.notice {
  opacity: 0;
  animation: fadeUp 1s ease forwards;
  animation-delay: 0.2s;
}

/* Carousel */
.featured-section {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  box-sizing: border-box;
}

.section-subtitle {
  text-align: center;
}

.carousel {
  position: relative;
  background: transparent;
  overflow: visible;
  /* arrows sit outside viewport */
  max-height: 75vh;
  max-width: 1200px;
  width: 100%;
  aspect-ratio: 16 / 9;
  margin: 0 auto;
  margin-bottom: 40px;
}

.carousel-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  max-height: 75vh;
  border-radius: 20px;
  border: 2px solid var(--accent);
  overflow: hidden;
  background: transparent;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
  width: 100%;
}

/* The viewport defines the visible area and gutters for padding */
.carousel-viewport {
  height: 100%;
  width: 100%;
}

/* track slides horizontally inside viewport */
.carousel-track {
  height: 100%;
  display: flex;
  align-items: center;
}

/* each slide is exactly one viewport width */
.carousel-slide {
  width: 100%;
  /* JS will set exact width */
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background-size: cover;
  /* fill width */
  background-position: center;
  /* center vertically */
  background-repeat: no-repeat;
  padding: 18px 28px;
  overflow: hidden;
  flex: 0 0 auto;
  /* allow JS width to take effect */
  border-radius: 12px;
}

.slide-info {
  position: absolute;
  left: 50%;
  bottom: 20px;
  transform: translate(-50%);

  color: #fff;
  z-index: 2;

  background: rgba(0, 0, 0, 0.65);
  padding: 16px 20px;
  border-radius: 16px;
  backdrop-filter: blur(4px);
}

.slide-title {
  font-size: 20px;
  font-weight: 700;
  text-align: center;
}

.slide-subtitle {
  font-size: 15px;
  font-style: italic;
  margin-top: 6px;
  font-weight: 400;
  opacity: 0.9;
  text-align: center;
}

@media (max-width: 900px) {
  .slide-title {
    font-size: 15px;
  }

  .slide-subtitle {
    font-size: 10px;
  }

  .slide-info {
    padding: 11px 11px;
    bottom: 11px;
  }
}

@media (max-width: 600px) {
  .slide-title {
    font-size: 10px;
  }

  .slide-subtitle {
    font-size: 5px;
  }

  .slide-info {
    padding: 6px 6px;
    bottom: 6px;
    border-radius: 5px;
  }
}

/* caption bottom-left */
.carousel-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
  gap: 10px;
  flex-wrap: wrap;
}

.carousel-caption {
  font-size: 28px;
  font-weight: 500;
  display: none
}

/* dots */
.carousel-dots {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  height: auto;
}

.carousel-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background: transparent;
  cursor: pointer;
  box-sizing: border-box;
  aspect-ratio: 1/1;

  padding: 0;
  margin: 0;
  line-height: 0;
  font-size: 0;
  display: inline-block;

  appearance: none;
  -webkit-appearance: none;
}

.carousel-dot.active {
  background: var(--accent);
}

/* arrows */
.carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 5;
  filter: drop-shadow(0 2px 0 rgba(0, 0, 0, 0.5));
}

.carousel-prev {
  left: 8px;
}

.carousel-next {
  right: 8px;
}

.carousel-nav svg {
  filter: drop-shadow(0 2px 0 rgba(0, 0, 0, 0.5));
}

.profile-meta {
  margin-top: calc(160px / 2 + 20px);
  /* half avatar + extra spacing */
}

/* All works */
.all-works .work {
  margin-top: 8px;
  padding: 6px 0;
}

.button-container {
  display: flex;
  justify-content: center;
  /* Centers the button horizontally */
}

.icon-button {
  display: inline-flex;
  /* Keeps the button inline while allowing flex rules */
  align-items: center;
  /* Perfectly centers the image and text vertically */
  gap: 8px;
  /* Adds a clean space between the image and text */
  padding: 10px 20px;
  /* Adds internal padding for the button look */
  cursor: pointer;
  /* Changes the cursor to a hand pointer on hover */
  background-color: var(--bg);
  font-size: 30px;

  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
  border: 4px solid rgb(255, 0, 0);
  border-radius: 12px;
  padding: 6px;
  color: var(--text);

  animation: rainbow-border 7.5s linear infinite;
}

.button-img {
  width: 40px;
  /* Restricts the image to icon-size */
  height: 40px;
  /* Maintains proportion */
  object-fit: contain;
  vertical-align: middle;
}

@keyframes rainbow-border {
  0% {
    filter: hue-rotate(0deg) brightness(1.5);
  }

  100% {
    filter: hue-rotate(360deg) brightness(1.5);
  }
}