/* Làm mượt font chữ trên mọi trình duyệt */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Chỉnh khoảng cách chữ cho font Inter trông gọn hơn giống IKEA */
h1, h2, h3, h4, h5, h6 {
    letter-spacing: -0.02em !important;
}
/* Flat Craft — footer com marca, links e redes */

.flat-craft-footer {
  font-family: inherit;
  color: #0f172a;
}

.flat-craft-brand {
  max-width: 22rem;
}

.flat-craft-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #0f172a;
  margin-bottom: 18px;
}

.flat-craft-logo__mark {
  position: relative;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

.flat-craft-logo__sq {
  position: absolute;
  width: 28px;
  height: 28px;
  border-radius: 8px;
}

.flat-craft-logo__sq--yellow {
  background: #facc15;
  left: 0;
  top: 0;
  z-index: 1;
}

.flat-craft-logo__sq--blue {
  background: #2563eb;
  right: 0;
  bottom: 0;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.35);
}

.flat-craft-logo__text {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.flat-craft-lead {
  margin: 0 0 22px;
  font-size: 0.95rem;
  line-height: 1.65;
  color: #475569;
}

.flat-craft-chat-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  border-radius: 8px;
  background: #2563eb;
  color: #fff !important;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: none;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
  transition: background 0.2s ease, box-shadow 0.2s ease;
}

.flat-craft-chat-btn:hover {
  background: #1d4ed8;
  color: #fff !important;
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.45);
}

.flat-craft-chat-btn__icon {
  display: flex;
  line-height: 0;
}

.flat-craft-nav__title {
  margin: 0 0 14px;
  font-size: 0.95rem;
  font-weight: 700;
  color: #0f172a;
}

.flat-craft-nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.flat-craft-nav__list li {
  margin: 0 0 10px;
}

.flat-craft-nav__list a {
  color: #475569;
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.15s ease;
}

.flat-craft-nav__list a:hover {
  color: #2563eb;
}

.flat-craft-bottom-row {
  border-top: 1px solid #e2e8f0;
  margin-top: 8px;
}

.flat-craft-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.flat-craft-copy {
  margin: 0;
  font-size: 0.8rem;
  color: #94a3b8;
}

.flat-craft-social {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.flat-craft-social__link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #64748b;
  transition: background 0.15s ease, color 0.15s ease;
}

.flat-craft-social__link:hover {
  background: #e2e8f0;
  color: #0f172a;
}

@media (max-width: 849px) {
  .flat-craft-brand {
    max-width: none;
  }

  .flat-craft-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}

/*Button with a thin font*/

.btn-thin {
    font-weight: 300 !important;
}

/*Item changes on hover*/

.it-menu:hover {
    background-color: #f8f8f8; /*change color of background here*/
    border-radius: 10px;
}

.it-menu:hover h3 {
    color: #2589E8; /*change color of heading here*/
}
/* Hiệu ứng đổ bóng và bo góc cho Mega Menu */
.nav-dropdown {
    border-radius: 20px !important;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    border: none !important;
    padding: 0 !important;
}

/* Thêm mũi tên nhỏ bên cạnh menu có dropdown */
.nav-top > li.has-dropdown > a:after {
    content: "\f107";
    font-family: "Flatsome-Icons";
    margin-left: 5px;
    opacity: .6;
}
/* 1. Thiết lập cơ bản cho các mục link */
.ux-menu-link a {
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
    display: inline-block;
    color: #666 !important; /* Màu xám nhẹ lúc bình thường */
    text-decoration: none !important; /* Chắc chắn không có gạch chân */
}

/* 2. Hiệu ứng khi di chuột vào từng mục con */
.ux-menu-link a:hover {
    color: #000 !important; /* Chữ chuyển sang đen hẳn */
    transform: translateX(6px); /* Chữ nhích sang phải 6px cực mượt */
}

/* 3. Làm cho các tiêu đề (Clothing, Accessories...) đứng yên và đậm hơn */
.ux-menu-title {
    color: #000 !important;
    font-weight: 800 !important;
    margin-bottom: 12px !important;
    cursor: default;
}

/* 4. Hiệu ứng cho các nhãn đi kèm (NEW, POPULAR) */
.ux-menu-link a:hover span.badge {
    box-shadow: 0 2px 8px rgba(0,0,0,0.15); /* Đổ bóng nhẹ cho nhãn khi hover */
}
/*Changes on Product Page components for Flat Pea*/

.product_meta>span {
	border-top: none !important;
}

.social-style .tooltip {
	border: none !important;
}

.social-style a.plain {
	color: #dedede !important;
}

.social-style a.plain:hover {
	color: black !important;
}

.social-style a.icon:not(.button), button.icon:not(.button) {
	margin-right: 0.5em;
	margin-left: 0.5em;
}

.tabs-mgn-20 .nav>li {
    margin: 0 20px;
}
/* Tạo khung chứa cho dòng cuối cùng của Card */
.tvb-card-footer {
    display: flex;
    justify-content: space-between; /* Đẩy 2 phần tử về 2 đầu */
    align-items: center;
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px solid #f0f0f0; /* Đường kẻ mờ ngăn cách */
}

/* Định dạng số lượt tải */
.tvb-count {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

/* Định dạng nút Download (Giống mẫu bạn gửi) */
.woocommerce ul.products li.product .button {
    margin-top: 0 !important;
    border: 1.5px solid #a855f7 !important; /* Màu tím */
    background: transparent !important;
    color: #a855f7 !important;
    border-radius: 25px !important;
    padding: 6px 18px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    transition: all 0.3s ease;
}

/* Tạo khung chứa cho dòng cuối cùng của Card */
.tvb-card-footer {
    display: flex;
    justify-content: space-between; /* Đẩy 2 phần tử về 2 đầu */
    align-items: center;
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px solid #f0f0f0; /* Đường kẻ mờ ngăn cách */
}

/* Định dạng số lượt tải */
.tvb-count {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

/* Định dạng nút Download (Giống mẫu bạn gửi) */
.woocommerce ul.products li.product .button {
    margin-top: 0 !important;
    border: 1.5px solid #a855f7 !important; /* Màu tím */
    background: transparent !important;
    color: #a855f7 !important;
    border-radius: 25px !important;
    padding: 6px 18px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    transition: all 0.3s ease;
}

/* Hiệu ứng khi di chuột vào nút */
.woocommerce ul.products li.product .button:hover {
    background: #a855f7 !important;
    color: #fff !important;
	}
/*Flat Clops style*/

.btn-thin {
    font-weight: 300 !important;
}

.custom-shadow-clops .col-inner:hover {
  box-shadow: 0 0px 44px 5px rgba(0,0,0,.05) !important;
  background: #fff  !important;
}

/* 1. Thiết lập chung cho nhãn gói thành viên trên Header */
.header-level-badge {
    display: inline-block;
    padding: 2px 14px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 800; /* Tăng độ đậm để chuyên nghiệp hơn */
    text-transform: uppercase;
    margin-left: 8px;
    vertical-align: middle;
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
    letter-spacing: 0.5px;
}

/* 2. Gói Miễn phí - Màu Xanh Green (Khớp màu Logo của bạn) */
.badge-mien-phi {
    background-color: #27ae60 !important; /* Màu xanh lá đặc trưng của ngành kiến trúc/BIM */
    color: #fff !important;
    border: 1px solid #1e8449;
}

/* 3. Gói VIP Member - Màu Vàng Gold sang trọng */
.badge-hang-thang, .badge-hang-nam, .badge-vip {
    background: linear-gradient(135deg, #f1c40f, #d4af37) !important;
    color: #000 !important; /* Chữ đen trên nền vàng để cực kỳ nổi bật */
    border: 1px solid #b8860b;
}
/* Thiết lập chung cho nhãn giá */
.tvb-badge-price {
    font-size: 13px !important;
    font-weight: 800 !important;
    padding: 3px 10px;
    border-radius: 4px;
    display: inline-block;
    margin-top: 5px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Nhãn Miễn phí - Màu Xanh Logo */
.free-price-tag {
    color: #27ae60 !important; /* Màu xanh lá green */
    background-color: rgba(39, 174, 96, 0.1); /* Nền xanh nhạt cho tinh tế */
    border: 1px solid #27ae60;
}

/* Nhãn VIP - Màu Vàng Gold */
.vip-price-tag {
    color: #000 !important;
    background: linear-gradient(135deg, #f1c40f, #d4af37) !important;
    border: 1px solid #b8860b;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Khống chế tên sản phẩm tại trang danh mục */
.woocommerce-loop-product__title, 
.products .product h2, 
.products .product h3 {
    white-space: nowrap;    /* Ép văn bản nằm trên 1 dòng */
    overflow: hidden;       /* Ẩn phần văn bản bị thừa */
    text-overflow: ellipsis; /* Thêm dấu "..." ở cuối */
    display: block;
    width: 100%;            /* Đảm bảo chiếm hết chiều ngang để căn giữa/thẳng hàng */
    padding-bottom: 5px;    /* Tạo khoảng cách nhỏ bên dưới */
}

/* Đảm bảo các khung sản phẩm có chiều cao bằng nhau (nếu cần) */
.products .product {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
/* Flat Pivot — Pricing Đen & Xanh Green (Thuvienbim Style) */

.flat-pivot {
  --fp-bg: #000000;
  --fp-card: #141414;
  --fp-card-inner: #121212;
  --fp-text: #ffffff;
  --fp-muted: #94a3b8;
  --fp-muted2: #64748b;
  /* Thay đổi: Sắc xanh Green thay cho Cyan/Purple */
  --fp-green-primary: #2ecc71; 
  --fp-green-secondary: #27ae60;
  --fp-track: #2a2a2a;
  /* Gradient mới từ Xanh sáng sang Xanh đậm chuyên nghiệp */
  --fp-gradient: linear-gradient(90deg, var(--fp-green-primary), var(--fp-green-secondary));
  font-family: 'Inter', 'Roboto', system-ui, -apple-system, sans-serif;
  color: var(--fp-text);
}

.flat-pivot-pricing .section-content {
  max-width: 1180px;
  margin-left: auto;
  margin-right: auto;
}

.flat-pivot-pricing__head {
  text-align: center;
  margin: 0 auto 32px;
  max-width: 36rem;
}

.flat-pivot-pricing__title {
  margin: 0 0 12px;
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--fp-text);
}

.flat-pivot-pricing__sub {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--fp-muted);
}

/* ----- Slider (Centrado) ----- */
.flat-pivot-slider {
  position: relative;
  max-width: 560px;
  width: 100%;
  margin: 0 auto 40px;
  padding: 42px 8px 0;
  box-sizing: border-box;
  --fp-tip: 19.9%;
}

.flat-pivot-slider__tooltip {
  position: absolute;
  top: 0;
  left: var(--fp-tip);
  transform: translateX(-50%);
  padding: 8px 14px;
  border-radius: 8px;
  background: #1e1e1e;
  border: 1px solid #333;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--fp-text);
  white-space: nowrap;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45);
  z-index: 3;
}

.flat-pivot-slider__track-wrap {
  position: relative;
  height: 28px;
  display: flex;
  align-items: center;
}

.flat-pivot-slider__rail {
  position: absolute;
  left: 0;
  right: 0;
  height: 6px;
  border-radius: 999px;
  background: var(--fp-track);
  pointer-events: none;
}

.flat-pivot-slider__fill {
  position: absolute;
  left: 0;
  height: 6px;
  border-radius: 999px;
  background: var(--fp-gradient); /* Fill thanh kéo sang màu Green */
  pointer-events: none;
  width: var(--fp-fill, 19.9%);
  max-width: 100%;
}

.flat-pivot-slider__ticks {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -10px;
  height: 6px;
  display: flex;
  justify-content: space-between;
  pointer-events: none;
  opacity: 0.35;
}

.flat-pivot-slider__ticks span {
  width: 1px;
  height: 4px;
  background: #555;
}

.flat-pivot-slider__input {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 28px;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  cursor: pointer;
}

.flat-pivot-slider__input::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #0a0a0a;
  border: 3px solid var(--fp-green-primary); /* Viền nút kéo sang Green */
  box-shadow: 0 0 0 2px rgba(46, 204, 113, 0.35); /* Đổ bóng Green */
}

.flat-pivot-slider__input::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #0a0a0a;
  border: 3px solid var(--fp-green-primary);
  box-shadow: 0 0 0 2px rgba(46, 204, 113, 0.35);
}

.flat-pivot-slider__input::-webkit-slider-runnable-track {
  height: 6px;
  background: transparent;
}

.flat-pivot-slider__input::-moz-range-track {
  height: 6px;
  background: transparent;
}

/* ----- Cards grid ----- */
.flat-pivot-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  align-items: stretch;
  width: 100%;
}

@media (max-width: 849px) {
  .flat-pivot-cards {
    grid-template-columns: 1fr;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
  }
}

.flat-pivot-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100%;
  height: 100%;
  padding: 28px 24px 24px;
  border-radius: 14px;
  background: var(--fp-card);
  border: 2px solid #252525;
  box-sizing: border-box;
}

.flat-pivot-card--featured {
  border: 2px solid transparent;
  padding: 28px 24px 24px;
  background: linear-gradient(var(--fp-card-inner), var(--fp-card-inner)) padding-box,
    var(--fp-gradient) border-box; /* Viền thẻ trung tâm sang Green Gradient */
  background-clip: padding-box, border-box;
  box-shadow: none;
}

.flat-pivot-card__inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.flat-pivot-card__name {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--fp-muted);
  margin: 0 0 12px;
  text-transform: capitalize;
}

.flat-pivot-card__price-row {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin: 0 0 12px;
}

.flat-pivot-card__currency {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--fp-text);
}

.flat-pivot-card__amount {
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--fp-text);
  line-height: 1;
}

.flat-pivot-card__period {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--fp-muted2);
}

.flat-pivot-card__desc {
  margin: 0 0 20px;
  font-size: 0.86rem;
  line-height: 1.55;
  color: var(--fp-muted);
  flex: 0 0 auto;
}

.flat-pivot-card__list {
  margin: 0 0 28px;
  padding: 0;
  list-style: none;
  flex: 1 1 auto;
}

.flat-pivot-card__list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 0.84rem;
  line-height: 1.45;
  color: #cbd5e1;
}

.flat-pivot-card__check {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  border-radius: 50%;
  background: #2a2a2a;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--fp-green-primary); /* Icon Check đổi sang Green */
}

.flat-pivot-card__info {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  margin-left: auto;
  border-radius: 50%;
  border: 1px solid #4b5563;
  color: #9ca3af;
  font-size: 0.65rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.flat-pivot-card__btn {
  display: block;
  width: 100%;
  text-align: center;
  padding: 14px 18px;
  margin-top: auto;
  border-radius: 10px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-decoration: none;
  color: var(--fp-text);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  flex-shrink: 0;
}

/* Nút cho thẻ thường (Viền Gradient Green) */
.flat-pivot-card:not(.flat-pivot-card--featured) .flat-pivot-card__btn {
  border: 2px solid transparent;
  background: linear-gradient(var(--fp-card), var(--fp-card)) padding-box, var(--fp-gradient) border-box;
  background-clip: padding-box, border-box;
}

.flat-pivot-card:not(.flat-pivot-card--featured) .flat-pivot-card__btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(46, 204, 113, 0.12);
  color: var(--fp-text);
}

/* Nút cho thẻ đặc biệt (Nền Gradient Green toàn bộ) */
.flat-pivot-card--featured .flat-pivot-card__btn {
  border: none;
  background: var(--fp-gradient);
  color: #fff;
  box-shadow: 0 8px 28px rgba(46, 204, 113, 0.25);
}

.flat-pivot-card--featured .flat-pivot-card__btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.1);
  color: #fff;
}
/* --- Chỉ chỉnh sửa phần tiêu đề sang màu đen --- */

.flat-pivot-pricing__title {
  margin: 0 0 12px;
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #000000; /* Đã đổi từ var(--fp-text) sang màu đen */
}

.flat-pivot-pricing__sub {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: #4b5563; /* Đổi màu chữ phụ sang xám đậm để dễ đọc trên nền sáng */
}
/* Đảm bảo nhãn và số lượt tải nằm gọn gàng trên 1 hàng ngang */
.products .product a + .badge-mien-phi, 
.products .product a + .badge-hang-nam,
.products .product a + .badge-hang-thang {
    float: left; /* Đẩy nhãn sang trái */
}

/* Xóa float sau khi chứa nhãn và lượt tải để khung sản phẩm không bị méo */
.products .product {
    display: flow-root; 
}

/* ==========================================================
   MASTER CSS: ÉP THẲNG HÀNG TRÊN MỌI TRANG (FLATSOME)
========================================================== */

/* 1. Nhắm vào mọi hộp chứa văn bản của sản phẩm */
.product-small .box-text, 
.product-small .price-wrapper {
    display: flex !important;
    flex-direction: column !important; /* Đảm bảo các dòng chính vẫn xếp dọc */
}

/* 2. Tìm đúng hàng chứa Nhãn và Số lượt tải để ép ngang */
.product-small .box-text > div:has(.tvb-count-wrap),
.product-small .price-wrapper {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important; /* Cấm tuyệt đối việc rớt dòng */
    justify-content: space-between !important; /* Đẩy nhãn sang trái, số sang phải */
    align-items: center !important;
    width: 100% !important;
}

/* 3. Khử khoảng trống dư thừa của nhãn */
.product-small .box-text .badge-mien-phi,
.product-small .box-text .badge-hang-nam,
.product-small .box-text .badge-hang-thang,
.product-small .box-text .header-level-badge {
    margin: 0 !important; /* Xóa margin để không chiếm chỗ của số lượt tải */
    flex-shrink: 0 !important; /* Không cho nhãn bị co lại */
}

/* 4. Định dạng lại cụm số lượt tải */
.tvb-count-wrap {
    margin-left: auto !important; /* Đảm bảo luôn dạt về bên phải */
    white-space: nowrap !important; /* Giữ icon và số luôn đi cùng nhau */
    color: #9ca3af !important;
}