/* Quicksand — toàn bộ web, hỗ trợ tiếng Việt */

:root {
  --style-font: var(--font-quicksand), "Quicksand", sans-serif;
  --title-font: var(--font-quicksand), "Quicksand", sans-serif;
  --body-font: var(--font-quicksand), "Quicksand", sans-serif;
  /* VinaStay — đồng bộ logo */
  --brand-primary: #0d4a78;
  --brand-accent: #2b9fd9;
  --brand-accent-hover: #2488be;
  --theme-color: var(--brand-accent);
  --primary-color: var(--brand-accent);
  --title-color: var(--brand-primary);
}

body.tourm-theme,
body.tourm-theme *:not(i):not([class*="fa-"]) {
  font-family: var(--font-quicksand), "Quicksand", sans-serif;
}

.sub-title {
  font-family: var(--font-quicksand), "Quicksand", sans-serif !important;
  font-size: 14px !important;
  line-height: 1.5 !important;
  font-weight: 600 !important;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--theme-color, #1ca8cb) !important;
  margin-bottom: 10px !important;
}

.hero-style1 .sub-title {
  color: rgba(255, 255, 255, 0.95) !important;
  letter-spacing: 0.16em;
}

.sec-title,
.box-title,
h1,
h2,
h3,
h4,
h5,
h6,
button,
input,
textarea,
select {
  font-family: var(--font-quicksand), "Quicksand", sans-serif;
}

@media (max-width: 480px) {
  .sub-title {
    font-size: 13px !important;
  }
}

/* About section — fix overlapping images */
.img-box1 {
  min-height: 640px;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.img-box1 .img1 {
  width: 56%;
  max-width: 312px;
}

.img-box1 .img1 img {
  width: 100%;
  height: 630px;
  max-height: min(630px, 70vw);
  object-fit: cover;
  display: block;
}

.img-box1 .img2 {
  width: 50%;
  max-width: 312px;
  z-index: 2;
}

.img-box1 .img2 img {
  width: 100%;
  height: 315px;
  max-height: 315px;
  object-fit: cover;
  display: block;
}

.img-box1 .img3 {
  width: 50%;
  max-width: 312px;
  bottom: 0;
  z-index: 3;
}

.img-box1 .img3 img {
  width: 100%;
  height: 315px;
  max-height: 315px;
  object-fit: cover;
  display: block;
}

@media (max-width: 1199px) {
  .img-box1 {
    min-height: 520px;
    max-width: 480px;
  }

  .img-box1 .img1 img {
    height: 500px;
    max-height: 500px;
  }

  .img-box1 .img2 img,
  .img-box1 .img3 img {
    height: 250px;
    max-height: 250px;
  }
}

/* Căn nổi bật — dòng mô tả thay cho widget sao bị lỗi */
.tour-box .tour-box_meta {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.5;
  color: #6b7884;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Card căn cao bằng nhau dù ảnh khác tỉ lệ */
.tour-slider .swiper-slide {
  height: auto;
}

.tour-box {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.tour-box .tour-box_img {
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

.tour-box .tour-box_img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Hàng action: thông tin lên trên, nút "Đặt ngay" xuống dưới cùng */
.tour-box .tour-content {
  display: flex;
  flex: 1;
  flex-direction: column;
  height: 100%;
}

.tour-box .tour-action {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  margin-top: auto;
}

.tour-box .tour-action > span {
  width: 100%;
}

.tour-box .tour-action .th-btn {
  white-space: nowrap;
}

/* Mũi tên thống nhất (line arrow) cho tất cả nút .th-btn.th-icon */
.th-btn.th-icon::after {
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%20fill='none'%20stroke='%23000'%20stroke-width='2.2'%20stroke-linecap='round'%20stroke-linejoin='round'%3E%3Cpath%20d='M5%2012h14M13%206l6%206-6%206'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2024%2024'%20fill='none'%20stroke='%23000'%20stroke-width='2.2'%20stroke-linecap='round'%20stroke-linejoin='round'%3E%3Cpath%20d='M5%2012h14M13%206l6%206-6%206'/%3E%3C/svg%3E");
  -webkit-mask-size: contain;
  mask-size: contain;
  width: 19px;
  height: 19px;
}

/* Thư viện ảnh — mosaic ảnh to nhỏ xen kẽ */
.gallery-mosaic {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: 165px;
  grid-auto-flow: dense;
  gap: 14px;
}

.gallery-mosaic__item {
  position: relative;
  overflow: hidden;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 16px;
  cursor: pointer;
  background: #eef3f7;
}

.gallery-mosaic__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.gallery-mosaic__item:hover img {
  transform: scale(1.08);
}

.gallery-mosaic__overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(180deg, rgba(13, 74, 120, 0) 35%, rgba(13, 74, 120, 0.5));
  opacity: 0;
  transition: opacity 0.4s ease;
}

.gallery-mosaic__overlay svg {
  transform: translateY(10px) scale(0.9);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.gallery-mosaic__item:hover .gallery-mosaic__overlay {
  opacity: 1;
}

.gallery-mosaic__item:hover .gallery-mosaic__overlay svg {
  transform: translateY(0) scale(1);
}

.gallery-mosaic__item:nth-child(7n + 1) {
  grid-column: span 2;
  grid-row: span 2;
}

.gallery-mosaic__item:nth-child(7n + 4) {
  grid-column: span 2;
}

.gallery-mosaic__item:nth-child(7n + 6) {
  grid-row: span 2;
}

@media (max-width: 991px) {
  .gallery-mosaic {
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 145px;
  }
}

@media (max-width: 575px) {
  .gallery-mosaic {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 120px;
    gap: 10px;
  }

  .gallery-mosaic__item:nth-child(7n + 4),
  .gallery-mosaic__item:nth-child(7n + 6) {
    grid-column: auto;
    grid-row: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gallery-mosaic__item img,
  .gallery-mosaic__overlay,
  .gallery-mosaic__overlay svg {
    transition: none !important;
  }
}

/* Lưới thương hiệu host — card click được, hiệu ứng hover mượt */
.host-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 28px;
}

@media (min-width: 992px) {
  .host-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 575px) {
  .host-card-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.host-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--brand-primary, #0d4a78) 10%, #fff);
  box-shadow: 0 12px 30px -18px rgba(13, 74, 120, 0.35);
  text-decoration: none;
  color: inherit;
  opacity: 0;
  transform: translateY(24px);
  animation: hostCardIn 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  transition:
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.45s ease,
    border-color 0.45s ease;
  will-change: transform;
}

@keyframes hostCardIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.host-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 28px 55px -22px rgba(13, 74, 120, 0.45);
  border-color: color-mix(in srgb, var(--brand-accent, #2b9fd9) 45%, #fff);
}

.host-card__media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.host-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.host-card:hover .host-card__media img {
  transform: scale(1.08);
}

.host-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(13, 74, 120, 0) 45%, rgba(13, 74, 120, 0.4));
  opacity: 0;
  transition: opacity 0.45s ease;
}

.host-card:hover .host-card__media::after {
  opacity: 1;
}

.host-card__badge {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--brand-primary, #0d4a78);
  background: rgba(255, 255, 255, 0.92);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  box-shadow: 0 6px 16px -8px rgba(0, 0, 0, 0.3);
}

.host-card__logo {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 2;
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.96);
  display: grid;
  place-items: center;
  padding: 7px;
  box-shadow: 0 8px 20px -10px rgba(0, 0, 0, 0.4);
}

.host-card__logo img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.host-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 8px;
  padding: 20px 22px 22px;
}

.host-card__title {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: var(--brand-primary, #0d4a78);
  transition: color 0.3s ease;
}

.host-card:hover .host-card__title {
  color: var(--brand-accent, #2b9fd9);
}

.host-card__desc {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: #5b6b78;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.host-card__cta {
  margin-top: auto;
  padding-top: 6px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--brand-accent, #2b9fd9);
}

.host-card__cta svg {
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.host-card:hover .host-card__cta svg {
  transform: translateX(5px);
}

@media (prefers-reduced-motion: reduce) {
  .host-card {
    animation: none;
    opacity: 1;
    transform: none;
  }

  .host-card,
  .host-card *,
  .host-card::after {
    transition: none !important;
  }
}

/* Section backgrounds — cover + center thay vì tile pattern xấu */
.team-section-bg,
.tour-area.bg-top-center {
  background-size: cover !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
}

@media (max-width: 480px) {
  .img-box1 {
    min-height: auto;
  }

  .img-box1 .img1 {
    width: 100%;
    max-width: 100%;
  }

  .img-box1 .img1 img {
    height: auto;
    max-height: none;
    aspect-ratio: 312 / 630;
  }
}

/* Logo VinaStay — cân bằng với khối logo-bg (~92px), gần admin (h-16 ≈ 64px) */
.header-layout1 .header-logo .site-brand-logo {
  display: block;
  width: auto !important;
  max-width: 200px !important;
  height: auto !important;
  max-height: 58px !important;
  object-fit: contain;
  object-position: left center;
}

.header-layout1 .header-logo {
  line-height: 0;
}

.header-layout1 .header-logo a {
  display: inline-block;
}

.th-menu-wrapper .mobile-logo .site-brand-logo {
  display: block;
  width: auto !important;
  max-width: 180px !important;
  max-height: 52px !important;
  margin: 0 auto;
  object-fit: contain;
  object-position: center;
}

.footer-layout1 .about-logo .site-brand-logo {
  display: block;
  width: auto !important;
  max-width: 180px !important;
  max-height: 48px !important;
  object-fit: contain;
}

/* Header gọn: không top bar, không nền logo-bg */
.header-layout1--minimal .logo-bg {
  display: none !important;
}

.header-layout1--minimal .main-menu {
  padding-left: 0 !important;
}

.header-layout1--minimal .menu-area {
  padding: 16px 0;
}

.host-branded-page .sub-title {
  color: var(--brand-accent, var(--theme-color, #2b9fd9)) !important;
}

.host-custom-html {
  line-height: 1.7;
}

.header-layout1--minimal .menu-area > .container {
  width: 100%;
  max-width: calc(var(--main-container) + var(--container-gutters));
  margin-left: auto;
  margin-right: auto;
}

.header-layout1--minimal .header-logo {
  position: relative;
  left: auto;
  margin: 0;
  padding: 0;
}

/* Header: logo trái — menu giữa — CTA phải */
.header-layout1--minimal .header-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

@media (min-width: 1200px) {
  .header-layout1--minimal .header-nav-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
  }

  .header-layout1--minimal .header-nav-logo {
    justify-self: start;
  }

  .header-layout1--minimal .header-nav-menu {
    justify-self: center;
  }

  .header-layout1--minimal .header-nav-actions {
    justify-self: end;
    display: flex;
    align-items: center;
  }
}

.header-layout1--minimal .header-nav-menu .main-menu > ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  margin: 0;
  padding: 0;
  gap: 0;
}

.header-layout1--minimal .main-menu > ul > li > a:hover,
.header-layout1--minimal .main-menu > ul > li > a.active {
  color: var(--brand-primary);
}

.header-layout1--minimal .main-menu > ul > li > a:before {
  background: var(--brand-accent);
}

/* Nút xanh — chỉ dùng MỘT màu xanh nhạt (accent); trắng/outline giữ nguyên.
   Hover làm đậm nhẹ cùng tông (accent-hover), không dùng navy. */
.th-btn {
  background-color: var(--brand-accent);
}

.th-btn:before {
  background-color: var(--brand-accent-hover);
}

/* style3: nút filled (trước là navy) -> xanh nhạt */
.th-btn.style3 {
  background-color: var(--brand-accent);
}

.th-btn.style3:before {
  background-color: var(--brand-accent-hover);
}

.th-btn.style3:hover {
  color: var(--white-color);
}

/* style4: nút outline (trước là navy) -> outline xanh nhạt */
.th-btn.style4 {
  color: var(--brand-accent);
  border-color: var(--brand-accent);
}

.th-btn.style4.th-icon:after {
  background-color: var(--brand-accent);
}

.th-btn.style4:before {
  background-color: var(--brand-accent);
}

.th-btn.style4:hover {
  color: var(--white-color);
  border-color: var(--brand-accent);
}

.th-btn.style4:hover.th-icon:after {
  background-color: var(--white-color);
}

/* Footer nền màu thương hiệu (navy) — chữ sáng */
.footer-wrapper.footer-layout1 .widget-area {
  background-color: var(--brand-primary);
}

.footer-wrapper.footer-layout1 .widget_title,
.footer-wrapper.footer-layout1 .footer-card .title {
  color: #fff;
}

.footer-wrapper.footer-layout1 .about-text,
.footer-wrapper.footer-layout1 .footer-widget .menu a,
.footer-wrapper.footer-layout1 .footer-widget li a,
.footer-wrapper.footer-layout1 .info-box_text,
.footer-wrapper.footer-layout1 .info-box_text a,
.footer-wrapper.footer-layout1 .info-box_text .details p,
.footer-wrapper.footer-layout1 .th-social a {
  color: rgba(255, 255, 255, 0.8);
}

.footer-wrapper.footer-layout1 .footer-widget .menu a:hover,
.footer-wrapper.footer-layout1 .footer-widget li a:hover,
.footer-wrapper.footer-layout1 .info-box_text a:hover,
.footer-wrapper.footer-layout1 .th-social a:hover {
  color: var(--brand-accent);
}

.footer-wrapper.footer-layout1 .copyright-wrap {
  background-color: #08305a;
  background-image: none !important;
}
