/* =========================================================================
 *  Product page V2 — Figma «Product Page +1024 / +768-1023 / Mobile V3» (2026-11)
 *  scope: .tk_pdp2 (desktop template) / .tk_pdp2_m (mobile template)
 *  ⚠️ .tk_single_add_to_cart_button: variation_select.js inline-sets display:block —
 *     layout of the button stays block + inline icon, never flex.
 * ====================================================================== */

/* ---------------------------------------------------------------- layout */
.tk_pdp2.tk_product_first_section { width: 1366px; max-width: 100%; padding: 16px 32px 0; box-sizing: border-box; }
.tk_pdp2 .tk_product_breadcrumb_container { width: 100%; margin: 0; }
.tk_pdp2 .tk_product_breadcrumb { font-size: 11px; font-weight: 400; line-height: 140%; color: #7E928F; }
.tk_pdp2 .tk_product_breadcrumb a { color: #7E928F; }
.tk_pdp2 .tk_product_breadcrumb_container > .tk_product_id { display: none; }
.tk_pdp2 .tk_product_summary_container {
  width: 100%; max-width: 1600px;
  display: flex; flex-direction: row; align-items: flex-start; gap: 20px;
  padding: 20px 0; box-sizing: border-box;
}
.tk_pdp2 .tk_product_images_section { flex: 1 1 431px; min-width: 225px; max-width: 449px; width: auto; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.tk_pdp2 .tk_product_summary_section { flex: 1 1 431px; min-width: 388px; width: auto; display: flex; flex-direction: column; gap: 24px; }
.tk_pdp2 .tk_product_action_section { flex: 1 1 400px; min-width: 307px; max-width: 400px; width: auto; }

/* ---------------------------------------------------------------- gallery */
.tk_pdp2 .tk_product_images_section .woocommerce-product-gallery { width: 431px; max-width: 100%; margin: 0; }
.tk_pdp2 .tk_product_images_section .woocommerce-product-gallery__wrapper img { width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: contain; }
.tk_pdp2 .tk_product_images_section ol.flex-control-nav.flex-control-thumbs {
  display: flex; flex-direction: row; flex-wrap: wrap; justify-content: flex-start; gap: 8px;
  padding: 16px 0 0; margin: 0;
}
.tk_pdp2 .tk_product_images_section .flex-control-nav.flex-control-thumbs li,
.tk_pdp2 .tk_product_images_section .flex-control-nav.flex-control-thumbs li:first-child {
  width: 56px; height: 56px; margin: 0; padding: 0; box-sizing: border-box;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid transparent; border-radius: 0; background: #FFFFFF; cursor: pointer;
}
.tk_pdp2 .tk_product_images_section .flex-control-nav.flex-control-thumbs li:hover { border-color: #CCD5D3; }
.tk_pdp2 .tk_product_images_section .flex-control-nav.flex-control-thumbs li:has(img.flex-active) { border-color: #060707; }
.tk_pdp2 .tk_product_images_section .flex-control-nav.flex-control-thumbs li img { width: 40px; height: 40px; margin: 0; object-fit: contain; opacity: 1; }
/* share / id moved to the middle column; toasts (position:fixed) stay in place */
.tk_pdp2:not(.tk_pdp2_m) .tk_under_image_section { border: 0; padding: 0; margin: 0; }
.tk_pdp2:not(.tk_pdp2_m) .tk_under_image_section > .tk_under_image_section_button,
.tk_pdp2:not(.tk_pdp2_m) .tk_under_image_section > .yith-wcwl-add-to-wishlist,
.tk_pdp2:not(.tk_pdp2_m) .tk_under_image_section > .tk_product_id { display: none !important; }

/* ---------------------------------------------------------------- middle column */
.tk_pdp2_head { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.tk_pdp2_stock {
  display: inline-flex; flex-direction: row-reverse; align-items: center; gap: 4px;
  height: 24px; padding: 0 6px 0 8px; box-sizing: border-box;
  background: #FFFFFF; box-shadow: 0 0 1px #7E928F; border-radius: 999px;
  font-family: 'Estedad-FD'; font-size: 13px; font-weight: 500; line-height: 140%; color: #394040;
}
.tk_pdp2 .tk_pdp2_title.tk_product_title {
  margin: 0; padding: 0 0 0 16px;
  font-family: 'Estedad-Num', 'Estedad-FD' !important; font-size: 17px !important; font-weight: 500; line-height: 200% !important; color: #060707 !important;
}
.tk_pdp2_meta {
  display: flex; flex-direction: row; justify-content: space-between; align-items: flex-start; gap: 12px;
  width: 100%; border-top: 1px dashed #E4E9E9;
}
.tk_pdp2_brand { display: flex; align-items: center; justify-content: center; width: 56px; height: 56px; background: #FFFFFF; font-size: 12px; color: #394040; }
.tk_pdp2_brand img { width: 48px; height: 48px; object-fit: contain; }
.tk_pdp2_meta_actions { display: flex; flex-direction: row-reverse; align-items: center; gap: 16px; padding-top: 8px; margin-right: auto; }
.tk_pdp2_id { font-family: 'Estedad-FD'; font-size: 12px; font-weight: 500; line-height: 140%; color: #7E928F; }
.tk_pdp2_id a { color: #7E928F; }
.tk_pdp2_share { display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; padding: 4px; border: 0; border-radius: 999px; background: none; cursor: pointer; }
.tk_pdp2_share:hover { background: #F5F6F6; }

/* old brand/catalog row: the popups inside meta_data stay, the visible row goes */
.tk_pdp2 .tk_product_data_row .tk_product_meta_data,
.tk_pdp2 .tk_product_data_row .tk_product_in_person_delivery { display: none; }
.tk_pdp2 .tk_product_data_row { margin: 0; padding: 0; border: 0; min-height: 0; }

/* variations (component variation_select) — desktop headings 16/700, badges 48 high */
@media (min-width: 768px) {
  .tk_pdp2 .tk_var_select { margin: 0; gap: 24px; }
  .tk_pdp2 .tk_var_group { gap: 16px; }
  .tk_pdp2 .tk_var_group_title { font-size: 16px; font-weight: 700; }
  .tk_pdp2 .tk_var_badge { min-height: 48px; font-size: 14px; line-height: 200%; }
  .tk_pdp2 .tk_mt_select { font-size: 14px; }
  .tk_pdp2 .tk_mt_note p { font-size: 13px; line-height: 170%; }
}

/* specs list */
.tk_pdp2_specs { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.tk_pdp2_h { margin: 0; font-family: 'Estedad-FD'; font-size: 16px; font-weight: 700; line-height: 140%; color: #060707; }
.tk_pdp2_specs_list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.tk_pdp2_specs_list li { margin: 0; font-family: 'Estedad-FD'; font-size: 15px; line-height: 170%; }
.tk_pdp2_specs_k { font-weight: 400; color: #394040; }
.tk_pdp2_specs_v { font-weight: 500; color: #060707; }
.tk_pdp2_more { margin: 0; }
.tk_pdp2_more span { display: inline-flex; flex-direction: row; align-items: center; gap: 4px; padding: 10px 8px; cursor: pointer; font-family: 'Estedad-FD'; font-size: 14px; font-weight: 500; color: #2A4ACA; }

/* ---------------------------------------------------------------- action box */
.tk_pdp2 .tk_product_action_section_box {
  width: 100%; box-sizing: border-box;
  display: flex; flex-direction: column; gap: 16px;
  padding: 16px 8px; border: 0; border-radius: 8px; background: #FFFFFF; box-shadow: 0 0 1px #394040; overflow: visible;
}
.tk_pdp2 .tk_product_price,
.tk_pdp2 .tk_add_to_cart { padding: 0; }
.tk_pdp2 .tk_product_buy_option { margin: 0; padding: 0; background: none; border: 0; }
.tk_pdp2 .tk_product_buy_option .installment_box,
.tk_pdp2 .know_better_price,
.tk_pdp2 .desktop_div .fast_shipping_box,
.tk_pdp2 .mobile_div .fast_shipping_box { display: none !important; }
/* warranty (pa_guarantee) = «گارانتی ۱۲ ماهه سازنده» line */
.tk_pdp2 .guarantee_box {
  display: flex; flex-direction: row; align-items: center; gap: 6px;
  height: auto; line-height: 140%; padding: 8px 4px; border: 0;
  font-family: 'Estedad-FD'; font-size: 13px; font-weight: 400; color: #060707;
}
.tk_pdp2 .guarantee_box img { width: 16px; height: 16px; margin: 0; }

/* price without tiers (components/product/price.php) */
.tk_pdp2 .tk_update_price { margin: 0 0 8px; font-family: 'Estedad-FD'; font-size: 14px; font-weight: 500; color: #04724D; }
.tk_pdp2 .tk_update_price span { color: #04724D; }
.tk_pdp2 .tk_single_price_section {
  display: flex; flex-direction: row; align-items: center; justify-content: space-between; gap: 8px;
  padding: 14px 12px 12px; border-radius: 4px; box-shadow: 0 5px 15px -3px rgba(6, 7, 7, .1), 0 0 1px #394040;
}
.tk_pdp2 .tk_single_price_section .tk_price { margin: 0; font-family: 'Estedad-FD'; font-size: 18px; font-weight: 600; color: #060707; }
.tk_pdp2 .tk_single_price_section .tk_price del { font-size: 12px; font-weight: 400; color: #7E928F; }
.tk_pdp2 .tk_single_price_section .discount-percentage {
  display: inline-flex; align-items: center; justify-content: center; height: 18px; padding: 1px 4px 0;
  border-radius: 4px; background: #FFFFFF; box-shadow: 0 0 1px #ED1C24; color: #394040; font-size: 14px; font-weight: 500;
}

/* delivery pills */
.tk_pdp2_pills { display: flex; flex-direction: row; justify-content: flex-start; align-items: center; gap: 8px; flex-wrap: wrap; }
.tk_pdp2 .tk_pdp2_pill,
.tk_pdp2 .tk_pdp2_pill.in_person_delivery {
  display: inline-flex; flex-direction: row-reverse; align-items: center; gap: 4px;
  height: 28px; padding: 0 6px 0 8px; margin: 0; border: 0; border-radius: 999px;
  background: #FFFFFF; box-shadow: 0 0 1px #7E928F; cursor: pointer;
  font-family: 'Estedad-FD'; font-size: 13px; font-weight: 400; line-height: 110%; color: #394040; white-space: nowrap;
}
.tk_pdp2 .tk_pdp2_pill:hover { background: #F5F6F6; }
.tk_pdp2 .tk_pdp2_pill img { width: 20px; height: 20px; margin: 0; }

/* add to cart */
.tk_pdp2 .tk_single_add_to_cart_button {
  box-sizing: border-box; height: 48px; line-height: 48px; padding: 0 24px; margin: 0;
  border: 0; border-radius: 2px; background: #FFD500; color: #060707;
  font-family: 'Estedad-FD'; font-size: 14px; font-weight: 600; text-align: center;
}
.tk_pdp2 .tk_single_add_to_cart_button::after {
  content: ""; display: inline-block; width: 20px; height: 20px; margin-right: 8px; vertical-align: middle;
  background: url("../../icon/v3-cart.svg") center / contain no-repeat;
}
.tk_pdp2 .tk_single_add_to_cart_button:hover { background: #F5C900; }
.tk_pdp2 .tk_single_add_to_cart_button.loading::after { display: none; }

/* ---------------------------------------------------------------- below the fold */
.tk_pdp2_second.tk_product_second_section { background: none; padding: 32px; max-width: 100%; box-sizing: border-box; }
.tk_pdp2_adv_wrap { width: 1206px; max-width: 100%; margin: 0 auto; }
.tk_pdp2_adv {
  display: flex; flex-direction: row-reverse; justify-content: flex-end; align-items: center; gap: 20px;
  padding: 40px 204px; box-sizing: border-box;
  background: rgba(6, 7, 7, .02); border: 1px solid #E4E9E9; border-radius: 4px;
}
.tk_pdp2_adv_item { flex: 1 1 0; display: flex; flex-direction: row-reverse; justify-content: flex-end; align-items: center; gap: 20px; }
.tk_pdp2_adv_txt { flex: 1 1 auto; display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.tk_pdp2_adv_txt strong { font-family: 'Estedad-FD'; font-size: 18px; font-weight: 500; line-height: 140%; color: #060707; }
.tk_pdp2_adv_txt span { font-family: 'Estedad-FD'; font-size: 13px; font-weight: 400; line-height: 140%; color: #394040; }
.tk_pdp2_adv_item img { flex: none; width: 56px; height: 56px; }
.tk_pdp2_adv_pct { flex: none; width: 56px; text-align: center; font-family: 'Estedad-FD'; font-size: 47px; font-weight: 700; line-height: 56px; color: #2A4ACA; }

.single-product .tk_customers_title { font-size: 18px; font-weight: 500; line-height: 140%; color: #394040; text-align: center; }
.single-product .tk_customers_logo_box img { opacity: .8; mix-blend-mode: luminosity; }

/* tabs — Figma Component 6 */
@media (min-width: 768px) {
  .single-product .tk_product_tab { width: 1206px; max-width: calc(100% - 64px); padding: 32px 0; }
  .single-product .tk_woocommerce-tabs .tabs.wc-tabs { margin: 0; padding: 0; }
  .single-product .tk_woocommerce-tabs .tabs.wc-tabs li,
  .single-product .tk_woocommerce-tabs .tabs.wc-tabs li a { width: 200px; height: 64px; font-size: 16px; }
  .single-product .tk_woocommerce-tabs .tabs.wc-tabs li { flex: 0 1 200px; overflow: visible; }
  .single-product .tk_woocommerce-tabs .tabs.wc-tabs li a { padding: 12px 8px 8px; box-sizing: border-box; }
  .single-product .tk_woocommerce-tabs .tabs.wc-tabs li.active a { color: #060707; }
  .single-product .tk_woocommerce-Tabs-panel { padding: 40px 16px 40px 80px; }
  .single-product #tab-description.tk_pdp2_clamp { max-height: 560px; overflow: hidden; position: relative; }
  .single-product #tab-description.tk_pdp2_clamp::after { content: ""; position: absolute; inset: auto 0 0; height: 80px; background: linear-gradient(to bottom, rgba(255,255,255,0), #FFFFFF); pointer-events: none; }
  .single-product .tk_pdp2_desc_more { display: inline-flex; align-items: center; gap: 2px; margin: 16px 16px 0 0; padding: 4px 0; border: 0; background: none; cursor: pointer; font-family: 'Estedad-FD'; font-size: 16px; font-weight: 500; color: #2A4ACA; }
}

/* ---------------------------------------------------------------- tablet 768–1023 */
@media (min-width: 768px) and (max-width: 1023px) {
  .tk_pdp2.tk_product_first_section { padding: 16px 24px 0 16px; }
  .tk_pdp2 .tk_product_summary_container { display: grid; grid-template-columns: minmax(0, 1fr) 336px; grid-auto-rows: auto; gap: 20px; }
  .tk_pdp2 .tk_product_images_section { grid-column: 1; grid-row: 1; max-width: none; min-width: 0; }
  .tk_pdp2 .tk_product_summary_section { grid-column: 1; grid-row: 2; min-width: 0; }
  .tk_pdp2 .tk_product_action_section { grid-column: 2; grid-row: 1 / span 2; max-width: 336px; min-width: 0; }
  .tk_pdp2 .tk_product_images_section .woocommerce-product-gallery { width: 286px; margin: 0 auto; }
  .tk_pdp2 .tk_var_badge { min-height: 60px; font-size: 16px; }
  .tk_pdp2_adv { padding: 24px; gap: 8px; }
  .tk_pdp2_adv_item { gap: 8px; }
  .tk_pdp2_adv_txt strong { font-size: 16px; }
}

/* ---------------------------------------------------------------- mobile template */
.tk_pdp2_m.tk_product_first_section { padding: 0; width: 100%; }
.tk_pdp2_m .tk_product_summary_container { display: flex; flex-direction: column; gap: 0; padding: 0; }
.tk_pdp2_m .tk_product_images_section,
.tk_pdp2_m .tk_product_summary_section,
.tk_pdp2_m .tk_product_action_section { max-width: none; min-width: 0; width: 100%; flex: none; }
.tk_pdp2_m .tk_product_breadcrumb_container { padding: 16px 24px; box-sizing: border-box; }
.tk_pdp2_m .tk_product_images_section .woocommerce-product-gallery { width: 100%; background: #F5F6F6; }
.tk_pdp2_m .tk_product_images_section .woocommerce-product-gallery__wrapper img { width: 224px; height: 224px; margin: 2px auto; display: block; }
.tk_pdp2_m .tk_mobile_product_title_div { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 16px 24px 0; box-sizing: border-box; }
.tk_pdp2_m .tk_mobile_product_title_div .tk_product_title { margin: 0; font-size: 16px !important; font-weight: 500; line-height: 200%; letter-spacing: .01em; }
.tk_pdp2_m .tk_product_action_section { padding: 24px; box-sizing: border-box; border-top: 6px solid #E4E9E9; }
.tk_pdp2_m .tk_product_action_section_box { padding: 0; box-shadow: none; border-radius: 0; gap: 16px; }
.tk_pdp2_m .tk_pdp2_pill { height: 24px; font-size: 12px; }
.tk_pdp2_m .tk_pdp2_pill img { width: 16px; height: 16px; }
.tk_pdp2_m .guarantee_box { font-size: 12px; }
.tk_pdp2_m .tk_product_images_section { order: 0; }
.tk_pdp2_m .tk_product_action_section { order: 1; }
.tk_pdp2_m .tk_product_summary_section { order: 2; padding: 24px; box-sizing: border-box; border-top: 6px solid #E4E9E9; }

/* ---------------------------------------------------------------- visual pass fixes (RTL/icons) */
/* «قیمت به‌روز است»: right-aligned, refresh icon on the right of the text */
.tkdp-v4--pdp .tkdp-v4-fresh { flex-direction: row !important; align-self: flex-start !important; justify-content: flex-start; }
.tkdp-v4--pdp .tkdp-v4-fresh img { order: 0; }
.tk_pdp2 .tk_update_price { text-align: right; }
/* brand right · (id, share) left — share is the leftmost */
.tk_pdp2_meta_actions { flex-direction: row; }
/* spec rows: «label: value» */
.tk_pdp2_specs_k { margin-left: 4px; }
.tk_pdp2 .tk_pdp2_more { width: auto; text-align: right; align-self: flex-start; }
.tk_pdp2 .tk_pdp2_more span { padding-right: 0; }
/* phone-order box isn't in the design (fast-shipping popups inside desktop_div stay) */
.tk_pdp2 .desktop_div > :not(.fast_shipping_box_popup):not(.fast_shipping_box_popup_back) { display: none !important; }
/* advantages: «قیمت بهتری» on the right, «فاکتور رسمی» on the left; icon right of each text */
.tk_pdp2_adv { flex-direction: row; justify-content: center; }
.tk_pdp2_adv_item { flex-direction: row; justify-content: flex-start; }
.tk_pdp2_adv_item > img, .tk_pdp2_adv_pct { order: -1; }
/* description «مشاهده بیشتر» — text link with chevron, only under the visible description tab */
.single-product .tk_pdp2_desc_more { border: 0 !important; background: none !important; box-shadow: none !important; flex-direction: row; }
.single-product .tk_pdp2_desc_more svg { order: 2; }
.single-product #tab-description[style*="none"] + .tk_pdp2_desc_more { display: none !important; }
/* mobile: «موجود» right, «…» button left; under-image tools open from «…» */
.tk_pdp2_m .tk_pdp2_mrow { display: flex; flex-direction: row; justify-content: space-between; align-items: center; width: 100%; }
.tk_pdp2_m .tk_pdp2_dots { display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; padding: 4px; border: 0; border-radius: 999px; background: none; cursor: pointer; }
.tk_pdp2_m .tk_under_image_section { display: none; padding: 0 24px; box-sizing: border-box; }
.tk_pdp2_m .tk_under_image_section.is-open { display: inline-flex; }
/* mobile parent is a block box: keep the fresh label pinned right, icon right of the text */
.tkdp-v4--pdp .tkdp-v4-fresh { display: flex !important; width: max-content; margin-left: auto !important; margin-right: 0 !important; direction: rtl; }
/* cart icon is markup now (variable button suppressed the ::after) — icon left of the label */
.tk_pdp2 .tk_single_add_to_cart_button::after { content: none !important; display: none !important; }
.tk_pdp2 .tk_single_add_to_cart_button .tk_pdp2_cart_ico { display: inline-block; width: 20px; height: 20px; margin-right: 8px; vertical-align: middle; }
.tk_mp_sticky_bar .tk_pdp2_cart_ico { display: none; }
