/* ==========================================================================
   Announcement bar
   ========================================================================== */
.tf-ticker {
  --tf-ticker-speed: 38s;
  background: var(--tf-brand-green);
  color: #fff;
  overflow: hidden;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.tf-ticker__run { display: flex; width: max-content; animation: tf-ticker-run var(--tf-ticker-speed) linear infinite; will-change: transform; }
.tf-ticker:hover .tf-ticker__run { animation-play-state: paused; }
.tf-ticker__list { display: flex; list-style: none; margin: 0; padding: 0; }
.tf-ticker__list li { display: flex; align-items: center; gap: 14px; padding: 8px 0 8px 44px; white-space: nowrap; }
.tf-ticker__list li::before { content: ""; width: 6px; height: 6px; background: #9fd0ad; transform: rotate(45deg); }
@keyframes tf-ticker-run { to { transform: translateX(-50%); } }
@media (min-width: 768px) { .tf-ticker { font-size: 13px; } .tf-ticker__list li { padding-block: 9px; } }

/* ==========================================================================
   Header
   ========================================================================== */
.tf-header { background: #fff; position: relative; z-index: 60; border-bottom: 1px solid var(--tf-line); }
.tf-sticky-header .tf-header { position: sticky; top: 0; }
.admin-bar.tf-sticky-header .tf-header { top: var(--wp-admin--admin-bar--height, 0px); }
@media (max-width: 600px) { .admin-bar.tf-sticky-header .tf-header { top: 0; } }
.tf-header.is-scrolled { box-shadow: 0 6px 20px -14px rgba(0, 0, 0, .35); }

.tf-header__main {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px;
  padding-block: 8px;
}
.tf-header__toggle { margin-left: -8px; }
.tf-brand { display: flex; align-items: center; min-width: 0; }
.tf-brand .custom-logo-link { display: block; line-height: 0; }
.tf-brand .custom-logo { width: auto; height: auto; max-height: 38px; max-width: 150px; object-fit: contain; }
.tf-brand__name { font-size: 20px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--tf-ink); }

.tf-header__search { grid-column: 1 / -1; grid-row: 2; display: none; padding-bottom: 4px; }
.tf-header.is-search-open .tf-header__search { display: block; animation: tf-drop .2s var(--tf-ease); }
@keyframes tf-drop { from { opacity: 0; transform: translateY(-6px); } }

.tf-search {
  display: flex;
  width: 100%;
  height: 46px;
  border: 1.5px solid var(--tf-green);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}
.tf-search__cat { display: none; }
.tf-search__input {
  flex: 1;
  min-width: 0;
  min-height: 0;
  border: 0 !important;
  border-radius: 0;
  box-shadow: none !important;
  padding: 0 14px;
  background: transparent;
}
.tf-search__btn { flex: none; display: flex; align-items: center; gap: 8px; border: 0; background: var(--tf-green); color: #fff; padding-inline: 16px; font-weight: 600; cursor: pointer; }
.tf-search__btn:hover { background: var(--tf-green-dark); }
.tf-search__btn-text { display: none; }

.tf-header__actions { display: flex; align-items: center; gap: 2px; justify-self: end; }
.tf-act { display: flex; align-items: center; gap: 10px; background: none; border: 0; padding: 0; cursor: pointer; color: var(--tf-ink); }
.tf-act__ic { position: relative; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; color: var(--tf-ink); transition: background .15s, color .15s; }
.tf-act__ic .tf-i { width: 22px; height: 22px; }
.tf-act:hover .tf-act__ic { background: var(--tf-green-tint); color: var(--tf-green); }
.tf-act__txt, .tf-act--wishlist { display: none; }
.tf-act__txt small { display: block; color: var(--tf-muted); font-size: 12px; line-height: 1.2; }
.tf-act__txt b { display: block; font-weight: 600; font-size: 14px; line-height: 1.3; white-space: nowrap; color: var(--tf-ink); }
.tf-count {
  position: absolute;
  top: 0;
  right: -2px;
  min-width: 18px;
  height: 18px;
  padding-inline: 5px;
  border-radius: 9px;
  border: 2px solid #fff;
  background: var(--tf-green);
  color: #fff;
  font-size: 10.5px;
  font-weight: 600;
  display: grid;
  place-items: center;
  line-height: 1;
  font-style: normal;
}
.tf-count[data-count="0"] { display: none; }
.tf-count.is-bump { animation: tf-bump .4s var(--tf-ease); }
@keyframes tf-bump { 40% { transform: scale(1.35); } }

/* Desktop: logo · search · actions in one row, menu bar below */
@media (min-width: 1024px) {
  .tf-header__main { grid-template-columns: auto minmax(0, 1fr) auto; gap: clamp(20px, 3vw, 44px); padding-block: 16px; transition: padding .2s; }
  .tf-header.is-scrolled .tf-header__main { padding-block: 10px; }
  .tf-header__toggle, .tf-act--search { display: none; }
  .tf-brand .custom-logo { max-height: 52px; max-width: 220px; }
  .tf-header__search { display: flex; justify-content: center; grid-column: auto; grid-row: auto; padding: 0; }
  .tf-search { max-width: 640px; height: 48px; border-width: 2px; }
  .tf-search__cat {
    display: block;
    width: auto;
    max-width: 170px;
    min-height: 0;
    border: 0;
    border-right: 1px solid var(--tf-line);
    border-radius: 0;
    background-color: var(--tf-soft);
    padding: 0 34px 0 14px;
    font-size: 13.5px;
    cursor: pointer;
  }
  .tf-search__btn { padding-inline: 22px; }
  .tf-search__btn-text { display: inline; }
  .tf-header__actions { gap: 18px; }
  .tf-act--wishlist { display: flex; }
  .tf-act__ic { width: 42px; height: 42px; background: var(--tf-green-tint); color: var(--tf-green); }
  .tf-act:hover .tf-act__ic { background: var(--tf-green); color: #fff; }
}
@media (min-width: 1200px) { .tf-act__txt { display: block; } }

/* ==========================================================================
   Menu bar (Appearance → Menus)
   ========================================================================== */
.tf-nav { display: none; border-top: 1px solid var(--tf-line); }
@media (min-width: 1024px) { .tf-nav { display: block; } }
.tf-nav__inner { display: flex; align-items: center; gap: 24px; }
.tf-menu { display: flex; flex-wrap: wrap; list-style: none; margin: 0; padding: 0; gap: 0 26px; }
.tf-menu > li { position: relative; }
.tf-menu > li > a { display: flex; align-items: center; gap: 6px; padding-block: 12px; font-weight: 500; font-size: 14.5px; color: var(--tf-ink); border-bottom: 2px solid transparent; white-space: nowrap; transition: color .15s, border-color .15s; }
.tf-menu > li > a:hover, .tf-menu > .current-menu-item > a, .tf-menu > .current-menu-ancestor > a { color: var(--tf-green); border-color: var(--tf-green); }
.tf-menu .menu-item-has-children > a::after { content: ""; width: 6px; height: 6px; border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: translateY(-2px) rotate(45deg); }
.tf-menu .sub-menu {
  position: absolute;
  top: 100%;
  left: -14px;
  min-width: 230px;
  list-style: none;
  margin: 0;
  padding: 8px 0;
  background: #fff;
  border: 1px solid var(--tf-line);
  border-radius: var(--tf-r);
  box-shadow: 0 18px 40px -22px rgba(0, 0, 0, .35);
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity .15s, transform .15s, visibility .15s;
  z-index: 20;
}
.tf-menu .sub-menu .sub-menu { top: -9px; left: 100%; }
.tf-menu li:hover > .sub-menu, .tf-menu li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.tf-menu .sub-menu li { position: relative; }
.tf-menu .sub-menu a { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 9px 18px; font-size: 14px; }
.tf-menu .sub-menu a:hover { background: var(--tf-green-tint); color: var(--tf-green); }
.tf-menu .sub-menu .menu-item-has-children > a::after { transform: rotate(-45deg); }
.tf-nav__note { margin-left: auto; display: flex; align-items: center; gap: 8px; font-weight: 500; font-size: 14px; white-space: nowrap; }
.tf-nav__note .tf-i { color: var(--tf-green); }

/* ==========================================================================
   Side panels: menu drawer (left) and cart drawer (right)
   ========================================================================== */
.tf-drawer-backdrop, .tf-overlay { position: fixed; inset: 0; background: rgba(17, 20, 17, .45); z-index: 190; opacity: 0; transition: opacity .25s; }
.tf-drawer-backdrop.is-on, .tf-overlay.is-on { opacity: 1; }
.tf-drawer, .tf-cart-drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  z-index: 200;
  width: min(88vw, 360px);
  background: #fff;
  display: flex;
  flex-direction: column;
  transition: transform .28s var(--tf-ease);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.tf-drawer { left: 0; transform: translateX(-100%); overflow-y: auto; overscroll-behavior: contain; }
.tf-cart-drawer { right: 0; width: min(92vw, 400px); transform: translateX(100%); }
.tf-drawer.is-open, .tf-cart-drawer.is-open { transform: none; }
.tf-drawer__head, .tf-cart-drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: calc(10px + env(safe-area-inset-top, 0px)) 12px 10px 20px;
  border-bottom: 1px solid var(--tf-line);
  flex: none;
}
.tf-drawer__title, .tf-cart-drawer__title { font-weight: 600; font-size: 16px; color: var(--tf-ink); display: flex; align-items: center; gap: 8px; }
.tf-cart-drawer__title .tf-count { position: static; border: 0; }
.tf-drawer__menu, .tf-drawer__menu .sub-menu { list-style: none; margin: 0; padding: 0; }
.tf-drawer__menu li { position: relative; border-bottom: 1px solid var(--tf-line); }
.tf-drawer__menu a { display: block; padding: 14px 56px 14px 20px; font-weight: 500; color: var(--tf-ink); }
.tf-drawer__menu .current-menu-item > a { color: var(--tf-green); }
.tf-drawer__menu .sub-menu { display: none; background: var(--tf-soft); }
.tf-drawer__menu .sub-menu li { border-bottom: 0; }
.tf-drawer__menu .sub-menu a { padding: 11px 56px 11px 34px; font-weight: 400; font-size: 14px; }
.tf-drawer__menu .sub-menu .sub-menu a { padding-left: 48px; }
.tf-drawer__menu li.is-open > .sub-menu { display: block; }
.tf-sub-toggle { position: absolute; top: 4px; right: 8px; width: 42px; height: 42px; border: 0; background: none; display: grid; place-items: center; cursor: pointer; color: var(--tf-green); }
.tf-sub-toggle .tf-i { transition: transform .2s; }
.tf-sub-toggle[aria-expanded="true"] .tf-i { transform: rotate(180deg); }
.tf-drawer__links { display: grid; padding: 12px 8px 24px; }
.tf-drawer__links a { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 10px; font-weight: 500; color: var(--tf-ink); }
.tf-drawer__links a .tf-i { color: var(--tf-green); }
.tf-drawer__links a:hover { background: var(--tf-green-tint); }

/* Mini cart inside the cart drawer */
.tf-cart-drawer .widget_shopping_cart_content { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.woocommerce-mini-cart { list-style: none; margin: 0; padding: 4px 16px; overflow-y: auto; flex: 1; overscroll-behavior: contain; }
.tf-mini-note { display: flex; align-items: center; gap: 8px; margin: 10px 0 4px; padding: 9px 12px; border-radius: 10px; background: var(--tf-green-tint); color: var(--tf-green-dark); font-size: 13px; font-weight: 500; }
.tf-mini-note .tf-i { width: 18px; height: 18px; }
.woocommerce-mini-cart-item {
  position: relative;
  display: grid;
  grid-template-columns: 64px 1fr;
  grid-template-rows: auto auto;
  column-gap: 12px;
  padding: 14px 30px 14px 0;
  border-bottom: 1px solid var(--tf-line);
  font-size: 14px;
}
.woocommerce-mini-cart-item > a:not(.remove) { display: contents; color: var(--tf-ink); font-weight: 500; line-height: 1.35; }
.woocommerce-mini-cart-item img { grid-row: 1 / 3; width: 64px; height: 64px; object-fit: cover; border-radius: 10px; background: var(--tf-soft); }
.woocommerce-mini-cart-item .quantity { grid-column: 2; display: block; height: auto; border: 0; background: none; color: var(--tf-muted); font-size: 13px; }
.woocommerce-mini-cart-item .quantity .amount { color: var(--tf-ink); font-weight: 600; }
.woocommerce-mini-cart-item .remove { position: absolute; top: 12px; right: 0; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; color: var(--tf-muted); font-size: 20px; line-height: 1; }
.woocommerce-mini-cart-item .remove:hover { background: var(--tf-red-tint); color: var(--tf-red); }
.woocommerce-mini-cart-item dl.variation { grid-column: 2; margin: 2px 0 0; font-size: 12px; color: var(--tf-muted); display: flex; gap: 4px; flex-wrap: wrap; }
.woocommerce-mini-cart-item dl.variation dd, .woocommerce-mini-cart-item dl.variation p { margin: 0; }
.woocommerce-mini-cart__total { display: flex; justify-content: space-between; padding: 14px 16px 6px; margin: 0; border-top: 1px solid var(--tf-line); font-size: 15px; flex: none; }
.woocommerce-mini-cart__total strong { font-weight: 500; }
.woocommerce-mini-cart__total .amount { font-weight: 700; color: var(--tf-ink); }
.woocommerce-mini-cart__buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 8px 16px 16px; margin: 0; flex: none; }
.woocommerce-mini-cart__empty-message { padding: 40px 20px; text-align: center; color: var(--tf-muted); }

/* ==========================================================================
   Phone bottom bar and floating WhatsApp
   ========================================================================== */
.tf-mnav { display: none; }
@media (max-width: 1023px) {
  .tf-has-mnav { --tf-bottom-ui: 62px; padding-bottom: calc(62px + env(safe-area-inset-bottom, 0px)); }
  .tf-mnav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 150;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
    background: rgba(255, 255, 255, .97);
    border-top: 1px solid var(--tf-line);
    padding-bottom: env(safe-area-inset-bottom, 0px);
    backdrop-filter: saturate(1.4) blur(10px);
    -webkit-backdrop-filter: saturate(1.4) blur(10px);
  }
  .tf-mnav a { display: grid; justify-items: center; gap: 2px; padding: 8px 0 7px; font-size: 11px; font-weight: 500; color: var(--tf-muted); }
  .tf-mnav a[aria-current] { color: var(--tf-green); }
  .tf-mnav .tf-i { width: 22px; height: 22px; color: var(--tf-ink); }
  .tf-mnav a[aria-current] .tf-i { color: var(--tf-green); }
  .tf-mnav__ic { position: relative; display: block; }
  .tf-mnav .tf-count { top: -6px; right: -10px; }
}

.tf-wa-float {
  position: fixed;
  right: 16px;
  bottom: calc(16px + var(--tf-bottom-ui) + env(safe-area-inset-bottom, 0px));
  z-index: 140;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--tf-wa);
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 10px 24px -8px rgba(31, 168, 85, .6);
  transition: transform .2s var(--tf-ease);
}
.tf-wa-float:hover { transform: scale(1.06); }
.tf-wa-float .tf-i { width: 28px; height: 28px; }
@media (min-width: 1024px) { .tf-wa-float { right: 24px; bottom: 24px; width: 56px; height: 56px; } }

/* Product categories in the menu --------------------------------------------------------- */
/* Phone side menu: "Menu" / "Categories" tabs */
.tf-drawer__tabs { display: grid; grid-template-columns: 1fr 1fr; padding: 10px 12px 0; gap: 6px; border-bottom: 1px solid var(--tf-line); flex: none; }
.tf-drawer__tabs button { padding: 11px 8px; border: 0; border-bottom: 2px solid transparent; background: none; font: inherit; font-weight: 600; font-size: 14.5px; color: var(--tf-muted); cursor: pointer; }
.tf-drawer__tabs button[aria-selected="true"] { color: var(--tf-green); border-bottom-color: var(--tf-green); }
.tf-cattree a { display: flex; align-items: center; gap: 12px; padding-top: 10px; padding-bottom: 10px; }
.tf-cattree__img { width: 36px; height: 36px; border-radius: 10px; object-fit: cover; flex: none; background: var(--tf-soft); }
.tf-cattree__img--empty { display: grid; place-items: center; color: var(--tf-green); }
.tf-cattree__img--empty .tf-i { width: 18px; height: 18px; }
.tf-cattree__name { flex: 1; min-width: 0; }
.tf-cattree__count { color: var(--tf-muted); font-size: 12px; }
.tf-cattree .sub-menu .tf-cattree__img { width: 28px; height: 28px; border-radius: 8px; }
.tf-drawer__menu.tf-cattree .sub-menu a { padding-left: 28px; }
