html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden; /* Ngăn chặn mọi thanh cuộn */
}

.p-home {
  /* background-image: url("../../images/background.png"); */
  width: 100vw;
  height: 100dvh;
  /* background-size: cover; */
  /* background-position: center; */
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overflow-x: hidden;
}

.loading {
  background: #000000;
  position: fixed;
  width: 100vw;
  height: 100dvh;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.container {
  --uib-size: 35px;
  --uib-color: white;
  --uib-speed: 1.2s;
  --uib-bg-opacity: 0.1;
  height: var(--uib-size);
  width: var(--uib-size);
  transform-origin: center;
  will-change: transform;
  overflow: visible;
}

.car {
  fill: none;
  stroke: var(--uib-color);
  stroke-dasharray: 25, 75;
  stroke-dashoffset: 0;
  animation: travel var(--uib-speed) linear infinite;
  will-change: stroke-dasharray, stroke-dashoffset;
  transition: stroke 0.5s ease;
}

.track {
  fill: none;
  stroke: var(--uib-color);
  opacity: var(--uib-bg-opacity);
  transition: stroke 0.5s ease;
}

@keyframes travel {
  0% {
    stroke-dashoffset: 0;
  }

  100% {
    stroke-dashoffset: -100;
  }
}

.slideshow {
  width: 100vw;
  height: 100dvh;
  position: absolute;
  z-index: -1;
  overflow: hidden;
}

.slideshow::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background-color: rgba(0, 0, 0, 0.5);
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover; /* Phủ đầy container */
  background-position: top center; /* Căn giữa hình ảnh */
  opacity: 0; /* Ẩn mặc định */
  transition: opacity 2s ease-in-out; /* Hiệu ứng mờ dần 2 giây */
  animation: fade 35s infinite; /* Tổng thời gian: 5 hình x 7s = 35s */
}

.slide:nth-child(1) {
  background-image: url("../../images/background/bg-1.jpg");
  animation-delay: 0s;
}

.slide:nth-child(2) {
  background-image: url("../../images/background/bg-2.jpg");
  animation-delay: 7s;
}

.slide:nth-child(3) {
  background-image: url("../../images/background/bg-3.jpg");
  animation-delay: 14s;
}

.slide:nth-child(4) {
  background-image: url("../../images/background/bg-4.jpg");
  animation-delay: 21s;
}

.slide:nth-child(5) {
  background-image: url("../../images/background/bg-5.jpg");
  animation-delay: 28s;
}

@keyframes fade {
  0% {
    opacity: 0;
  } /* Bắt đầu fade-in */
  5.71% {
    opacity: 1;
  } /* Fade-in hoàn tất (2s/35s ≈ 5.71%) */
  20% {
    opacity: 1;
  } /* Giữ hiển thị 5s (7s/35s ≈ 20%) */
  25.71% {
    opacity: 0;
  } /* Fade-out hoàn tất (2s/35s ≈ 5.71%) */
  100% {
    opacity: 0;
  } /* Ẩn cho đến chu kỳ tiếp theo */
}

header {
  display: flex;
  justify-content: end;
  padding: 0;
  flex: none;
}

.change_language {
  display: flex;
  flex-direction: column;
  position: relative;
  top: 0;
  right: 0;
}

.change_language button {
  width: 70px;
  height: 70px;
  background: transparent;
  color: white;
  cursor: pointer;
  font-size: 12px;
  font-weight: 300;
  background-color: #424f54;
}

.change_language .lang-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(to right, transparent 50%, #424f54 50%);
  background-size: 200% 100%;
  background-position: 0 0;
  transition: background-position 0.3s ease-out;
}

.change_language .lang-icon.show {
  background-position: 100% 0;
}

.language-options {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 70px;
  transform: translateX(100%);
  transition: transform 0.3s ease-out;
}

.language-options.show {
  transform: translateX(0);
}

.change_language[data-lang="2"] .lang-jp {
  color: rgba(255, 255, 255, 0.5);
}

.change_language[data-lang="2"] .lang-en {
  background-color: #2e3a3f;
}

.change_language[data-lang="3"] .lang-en {
  color: rgba(255, 255, 255, 0.5);
}

.change_language[data-lang="3"] .lang-jp {
  background-color: #2e3a3f;
}

@media screen and (min-width: 576px) {
  header {
    padding: 20px;
  }

  .change_language {
    flex-direction: row;
    position: relative;
    background-color: transparent;
  }

  .change_language button {
    width: 36px;
    height: 36px;
    background-color: transparent;
  }

  .change_language .lang-icon {
    display: none;
  }

  .language-options {
    flex-direction: row;
    transform: translateX(0);
    position: relative;
    top: unset;
  }

  .change_language[data-lang="2"] .lang-en {
    background-color: transparent;
  }

  .change_language[data-lang="3"] .lang-jp {
    background-color: transparent;
  }

  .change_language button:hover {
    background: rgb(255, 255, 255, 0.3);
  }
}

.description {
  text-align: center;
  color: white;
  flex: none;
  margin-bottom: 50px;
}

.description img {
  margin: 0 auto 10px;
  width: 240px;
  object-fit: cover;
}

.description h3 {
  font-size: 13px;
  line-height: 19px;
  margin-bottom: 10px;
}

.description h4 {
  font-size: 10px;
  line-height: 15px;
}

@media screen and (min-width: 576px) {
  .description img {
    width: 330px;
  }
  .description h3 {
    font-size: 19px;
    line-height: 27px;
  }

  .description h1 {
    font-size: 54px;
    line-height: 79px;
    margin-bottom: 10px;
  }

  .description h4 {
    font-size: 16px;
    line-height: 24px;
  }
}

.search {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  height: fit-content;
  min-height: 450px;
}

.search .tabs {
  flex: none;
  margin: 0 auto;
  display: flex;
  border-top-left-radius: 22px;
  border-top-right-radius: 22px;
  overflow: hidden;
}

.search .tabs .tab {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  width: 125px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

button .tab {
  color: rgb(0, 0, 0);
}

.search .tabs .tab .short-text {
  display: inline;
}

.search .tabs .tab .long-text {
  display: none;
}

@media screen and (min-width: 400px) {
  .search .tabs .tab {
    font-size: 15px;
  }
}

@media screen and (min-width: 576px) {
  .search .tabs .tab {
    width: 180px;
    font-size: 16px;
  }
}

@media screen and (min-width: 870px) {
  .search .tabs .tab {
    width: 277px;
  }

  .search .tabs .tab .short-text {
    display: none;
  }

  .search .tabs .tab .long-text {
    display: inline;
  }
}

.search .form {
  flex: 1 1 auto;
  height: 0;
}

#tab1,
#tab2,
#tab3 {
  height: 100%;
}

.tab-content {
  display: none;
}
.tab-content.active {
  display: block;
}

.tab.active {
  background: rgb(0, 0, 0, 0.75);
  color: white;
}
