/*=======================
1-1.메인
=======================*/
.main {
  grid-area: main;
  background: var(--bg-2);
  min-width: 0;
  min-height: calc(100vh - 64px);
}

/*=======================
1-2.메인 네비
=======================*/
.main-nav-wrapper {
  position: sticky;
  top: 64px;
  z-index: 3;
}

.main-nav-container {
  position: relative;
}

.main-nav {
  border-top: 1px solid var(--bg-4);
  border-bottom: 1px solid var(--bg-4);
  background: var(--bg);
  height: 58px;
  width: 100%;
  padding: 12px 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.main-nav::-webkit-scrollbar {
  display: none;
}

.main-nav-ul {
  display: flex;
  gap: 12px;
  list-style: none;
  padding: 0 64px 0 20px;
  height: 100%;
  align-items: center;
  width: max-content;
}

.item {
  flex-shrink: 0;
  color: var(--text);
  border: 0.3px solid #aaaaaa;
  padding: 8px 12px;
  background: var(--bg-4);
  border-radius: 20px;
  cursor: pointer;
  text-transform: capitalize;
}

.item.active {
  background: #ffffff;
  color: #030303;
  font-weight: 700;
}

li:not(.active):hover {
  background: var(--hover);
  transition: background 0.3s;
}

.next-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  color: var(--text);
  position: absolute;
  right: 0;
  top: 1px;
  background: rgba(33, 33, 33, 0.9);
  font-weight: 700;
  cursor: pointer;
  font-size: 1rem;
}

.next-btn:hover {
  background: var(--hover);
}

/*=======================
2-1.비디오 카드
=======================*/
.video-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
  gap: 40px 16px;
  padding: 24px;
}

.video-card {
  padding: 10px;
  width: 100%;
  cursor: pointer;
  border-radius: 10px;
  transition:
    background 0.3s,
    transform 0.3s;
}

.video-card:hover {
  background: var(--bg-4);
  transform: scale(1.05);
}

.video-relative {
  position: relative;
}

.video-card-img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 12px;
}

.user-name {
  text-transform: capitalize;
}

.video-card-content h2::first-letter {
  text-transform: uppercase;
}

.play-time {
  position: absolute;
  background: var(--bg-2);
  color: var(--text);
  bottom: 10px;
  right: 10px;
  padding: 5px;
  font-size: 0.9rem;
  font-weight: 400;
}

.avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  flex-shrink: 0;
}

.video-card h2 {
  margin: 0;
  color: var(--text);
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.4;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.video-card-content p {
  margin: 4px 0 0;
  color: var(--text-2);
  font-size: 0.75rem;
}

.video-card-container {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 12px;
}

.video-card-content {
  flex: 1;
  min-width: 0;
}

.video-card-content img {
  border-radius: 50%;
}

@media (max-width: 768px) {
  .video-list {
    gap: 24px 12px;
    padding: 16px 12px;
  }

  .video-card {
    padding: 8px;
  }

  .video-card:hover {
    transform: none;
  }
}
