/**
 * Balkanian Gold — theme overrides (RTL)
 */

:root {
	--bg-primary: #243c40;
	--bg-secondary: #bba57e;
	--bg-bg: #f0eeea;
	--bg-white: #ffffff;
	--bg-text: #243c40;
	--bg-text-muted: rgba(36, 60, 64, 0.7);
	--bg-radius: 12px;
	--bg-radius-lg: 24px;
	--bg-shadow: 0 6px 66px rgba(0, 0, 0, 0.1);
	--bg-font: "PeydaWeb", "YekanBakh", sans-serif;
	--bg-font-heading: "Aria", "PeydaWeb", sans-serif;
	--e-global-color-primary: #243c40;
	--e-global-color-secondary: #bba57e;
	--mainColor: #243c40;
	--secondaryColor: #bba57e;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
	font-family: var(--bg-font);
}

body,
body .site,
body #page,
button,
input,
select,
textarea,
time,
span,
p,
li,
td,
th,
label,
figcaption,
.entry-content,
.woocommerce,
.bg-features-list span,
.bg-blog-card time,
.bg-footer-about-text {
	font-family: var(--bg-font);
}

h1,
h2,
h3,
h4,
h5,
h6,
.bg-section-title,
.bg-hero-title,
.bg-page-title,
.zarnegar-custom-heading__title {
	font-family: var(--bg-font-heading);
}

body {
	margin: 0;
	font-family: var(--bg-font);
	font-size: 16px;
	line-height: 1.7;
	color: var(--bg-text);
	background: var(--bg-bg);
	direction: rtl;
	text-align: right;
	overflow-x: clip;
}

a {
	color: var(--bg-primary);
	text-decoration: none;
}

a:hover {
	color: var(--bg-secondary);
}

img {
	max-width: 100%;
	height: auto;
}

.bg-container {
	width: min(1200px, 92%);
	margin-inline: auto;
}

/* Header */
.bg-header {
	position: relative;
	z-index: 100;
}

.bg-header-top {
	background: var(--bg-secondary);
	color: #fff;
	font-size: 14px;
	padding: 8px 0;
	text-align: center;
}

.bg-header-main {
	background: #fff;
	box-shadow: var(--bg-shadow);
	border-radius: 0 0 var(--bg-radius-lg) var(--bg-radius-lg);
	margin-bottom: 24px;
}

.bg-header-main-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	padding: 16px 0;
	flex-wrap: wrap;
}

.bg-logo-link {
	display: flex;
	align-items: center;
	gap: 10px;
	font-family: var(--bg-font-heading);
	font-weight: 900;
	font-size: 20px;
	color: var(--bg-primary);
}

.bg-nav-primary {
	flex: 1;
	display: flex;
	justify-content: center;
}

.bg-menu {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: 24px;
	flex-wrap: wrap;
}

.bg-menu a {
	font-weight: 500;
	color: var(--bg-text-muted);
	padding: 8px 0;
	border-bottom: 3px solid transparent;
	transition: 0.2s;
}

.bg-menu a:hover,
.bg-menu .current-menu-item > a,
.bg-menu .current_page_item > a {
	color: var(--bg-primary);
	border-bottom-color: var(--bg-secondary);
}

.bg-menu .sub-menu {
	display: none;
	position: absolute;
	background: #fff;
	box-shadow: var(--bg-shadow);
	border-radius: var(--bg-radius);
	padding: 12px;
	min-width: 180px;
	list-style: none;
}

.bg-menu li {
	position: relative;
}

.bg-menu li:hover > .sub-menu {
	display: block;
}

.bg-header-support {
	display: none;
	flex-direction: row-reverse;
	align-items: center;
	gap: 15px;
	flex-shrink: 0;
}

.bg-header-support__icon {
	flex-shrink: 0;
	background: rgba(36, 60, 64, 0.09);
	padding: 11px 11px 2px;
	border-radius: 8px;
	line-height: 0;
}

.bg-header-support__body {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 0;
	text-align: right;
}

.bg-header-support__phones {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 1px;
}

.bg-header-support__phone {
	font-family: var(--bg-font-heading);
	font-weight: 700;
	font-size: 15px;
	line-height: 1.35;
	color: var(--bg-primary);
	unicode-bidi: plaintext;
	transition: color 0.2s;
}

.bg-header-support__phone:hover {
	color: var(--bg-secondary);
}

.bg-header-support__label {
	margin: 0;
	font-size: 14px;
	font-weight: 500;
	color: rgba(36, 60, 64, 0.5);
	line-height: 1.3;
}

.bg-header-actions {
	display: flex;
	align-items: center;
	gap: 12px;
}

.bg-nav-toggle {
	display: none;
	background: none;
	border: none;
	cursor: pointer;
	padding: 8px;
}

.bg-nav-toggle-bar {
	display: block;
	width: 24px;
	height: 2px;
	background: var(--bg-primary);
	margin: 5px 0;
}

/* Buttons */
.bg-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 10px 16px;
	border-radius: var(--bg-radius);
	font-weight: 500;
	border: 2px solid transparent;
	cursor: pointer;
	transition: 0.2s;
	font-family: inherit;
}

.bg-btn-primary {
	background: var(--bg-primary);
	color: #fff;
}

.bg-btn-primary:hover {
	background: var(--bg-secondary);
	color: #fff;
}

.bg-btn-outline {
	background: #fff;
	border-color: rgba(36, 60, 64, 0.2);
	color: var(--bg-primary);
}

.bg-btn-outline:hover {
	background: var(--bg-secondary);
	border-color: var(--bg-secondary);
	color: #fff;
}

/* Mini cart */
.bg-mini-cart {
	position: relative;
}

.bg-cart-toggle {
	background: var(--bg-primary);
	color: #fff;
	border: none;
	border-radius: var(--bg-radius);
	padding: 10px 12px;
	cursor: pointer;
	position: relative;
}

.bg-cart-count {
	position: absolute;
	top: -6px;
	left: -6px;
	background: var(--bg-secondary);
	color: #fff;
	font-size: 11px;
	min-width: 18px;
	height: 18px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
}

.bg-cart-dropdown {
	position: absolute;
	top: calc(100% + 8px);
	left: 0;
	min-width: 320px;
	background: #fff;
	border-radius: var(--bg-radius);
	box-shadow: var(--bg-shadow);
	padding: 16px;
	z-index: 200;
}

.bg-cart-dropdown.hide {
	display: none;
}

.bg-account-links {
	display: flex;
	gap: 8px;
}

/* Hero */
.bg-hero {
	background: linear-gradient(180deg, #fff 0%, var(--bg-bg) 100%);
	padding: 40px 0 60px;
	margin-bottom: 40px;
}

.bg-hero-inner {
	text-align: center;
}

.bg-hero-image {
	margin-bottom: 24px;
}

.bg-hero-title {
	font-family: var(--bg-font-heading);
	font-size: clamp(1.5rem, 4vw, 2.2rem);
	font-weight: 900;
	color: var(--bg-primary);
	margin: 0 0 12px;
}

.bg-hero-title span {
	color: var(--bg-secondary);
}

.bg-hero-desc {
	color: var(--bg-text-muted);
	max-width: 560px;
	margin: 0 auto 24px;
}

.bg-gold-price {
	max-width: 480px;
	margin: 0 auto;
	text-align: right;
	background: #fff;
	border-radius: var(--bg-radius-lg);
	padding: 20px;
	box-shadow: var(--bg-shadow);
	position: relative;
	overflow: hidden;
}

/* zarnegar skew overlay — white wash looks wrong on our white card */
.zarnegar-gold-price.design-1::before {
	display: none;
	content: none;
}

.bg-gold-price-updated {
	font-size: 12px;
	color: var(--bg-text-muted);
	margin: 12px 0 0;
	text-align: center;
}

.zarnegar-gold-price__price {
	font-size: 1.5rem;
	font-weight: 800;
}

.zarnegar-gold-price__changes.plus {
	color: #29a868;
}

.zarnegar-gold-price__changes.minus {
	color: #f06565;
}

/* Sections */
.bg-section {
	padding: 48px 0;
}

.bg-section-title {
	font-family: var(--bg-font-heading);
	font-size: 1.5rem;
	font-weight: 900;
	margin-bottom: 24px;
	color: var(--bg-primary);
}

.bg-section-more {
	text-align: center;
	margin-top: 24px;
}

.bg-features-list {
	list-style: none;
	padding: 0;
	margin: 0;
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 20px;
}

.bg-features-list li {
	background: #fff;
	padding: 24px;
	border-radius: var(--bg-radius-lg);
	box-shadow: var(--bg-shadow);
}

.bg-features-list strong {
	display: block;
	margin-bottom: 8px;
	color: var(--bg-primary);
}

.bg-blog-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
	gap: 24px;
}

.bg-blog-card {
	background: #fff;
	border-radius: var(--bg-radius);
	box-shadow: var(--bg-shadow);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	height: 100%;
	padding: 0;
}

.bg-blog-card-image {
	display: block;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: #f0eeea;
}

.bg-blog-card-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	display: block;
}

.bg-blog-card-body {
	padding: 16px;
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.bg-blog-card h3 {
	margin: 0;
	font-size: 1rem;
	line-height: 1.6;
	font-weight: 700;
}

.bg-blog-card h3 a {
	color: var(--bg-primary);
}

.bg-blog-card h3 a:hover {
	color: var(--bg-secondary);
}

.bg-blog-card time {
	font-size: 13px;
	color: rgba(36, 60, 64, 0.55);
	margin-top: auto;
}

.bg-faq-item {
	background: #fff;
	border-radius: var(--bg-radius);
	margin-bottom: 12px;
	padding: 16px 20px;
	box-shadow: var(--bg-shadow);
}

.bg-faq-item summary {
	cursor: pointer;
	font-weight: 700;
	color: var(--bg-primary);
}

/* Shop */
.bg-shop-layout {
	display: grid;
	grid-template-columns: 280px minmax(0, 1fr);
	gap: 24px;
	align-items: start;
}

.bg-shop-layout--full {
	grid-template-columns: minmax(0, 1fr);
}

.zarnegar-woo-archive-main {
	min-width: 0;
	max-width: 100%;
}

.bg-shop-sidebar {
	background: #fff;
	border-radius: var(--bg-radius-lg);
	padding: 20px;
	box-shadow: var(--bg-shadow);
}

.bg-widget-title {
	font-size: 1rem;
	margin: 0 0 12px;
	color: var(--bg-primary);
}

/* Product grid — override WooCommerce float columns */
.zarnegar-woo-products-grid,
.zarnegar-woo-archive-main ul.products.zarnegar-woo-products-grid {
	display: grid !important;
	width: 100%;
	max-width: 100%;
	min-width: 0;
	gap: 50px 15px;
	padding: 0;
	margin: 0;
	list-style: none;
	clear: both;
	overflow-x: clip;
}

.zarnegar-woo-products-grid.columns-3,
ul.products.zarnegar-woo-products-grid.columns-3 {
	grid-template-columns: repeat(3, 1fr);
}

.zarnegar-woo-products-grid.columns-4,
ul.products.zarnegar-woo-products-grid.columns-4 {
	grid-template-columns: repeat(4, 1fr);
}

.zarnegar-woo-products-grid::before,
.zarnegar-woo-products-grid::after,
ul.products.zarnegar-woo-products-grid::before,
ul.products.zarnegar-woo-products-grid::after {
	display: none !important;
	content: none !important;
}

.zarnegar-woo-products-grid > .product-box,
.zarnegar-woo-products-grid > li.product,
ul.products.zarnegar-woo-products-grid > li.product {
	width: 100% !important;
	max-width: none !important;
	float: none !important;
	margin: 0 !important;
	clear: none !important;
}

.bg-section-products .zarnegar-woo-products-container {
	width: 100%;
	min-width: 0;
	overflow-x: clip;
}

.bg-section-products .woocommerce {
	width: 100%;
}

/* Prevent decorative shadows from causing horizontal scroll (design-2) */
@media (min-width: 769px) {
	.zarnegar-woo-products-grid.design-2 > div:first-child::before,
	.zarnegar-woo-products-grid.design-2 > div:last-child::before {
		display: none !important;
		content: none !important;
	}
}

.product-box.design-2,
.product-box.design-3 {
	min-width: 0;
	max-width: 100%;
}

.product-box.design-2 > a.d-flex,
.product-box.design-3 > a.woocommerce-LoopProduct-link,
.product-box.design-3 > a .d-flex {
	min-width: 0;
	max-width: 100%;
}

.product-box.design-2 .product-box-main,
.product-box.design-3 .product-box-main,
.product-box.design-3 .product-box-image {
	min-width: 0;
}

.product-box.design-2 .product-box-main-title-english,
.product-box.design-3 .product-box-main-title-english {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.product-box.design-3 > a.woocommerce-LoopProduct-link {
	display: block;
	color: inherit;
	text-decoration: none;
}

.product-box.design-2 > a.d-flex {
	color: inherit;
	text-decoration: none;
}

.product-box.design-2 .product-box-main__top .product-box__button {
	background-color: #243c401a;
	color: var(--mainColor, var(--bg-primary, #243c40));
	border-radius: 12px;
	padding: 8px 16px;
	font-size: 14px;
	font-weight: 700;
	margin-top: 0;
	transition: background-color 0.2s ease, color 0.2s ease;
}

.product-box.design-2:hover .product-box-main__top .product-box__button {
	background-color: var(--e-global-color-primary, var(--bg-primary, #243c40));
	color: #fff;
}

/* design-2 price row — style.min.css sets both columns to width:100% */
.product-box.design-2 .product-box-main__details {
	min-width: 0;
	width: 100%;
}

.product-box.design-2 .product-box-main__details > .product-box-main__buy_price {
	display: none !important;
	width: 0 !important;
	flex: 0 0 0 !important;
	padding: 0;
	margin: 0;
	overflow: hidden;
}

.product-box.design-2 .product-box-main__main_price {
	width: auto !important;
	flex: 1 1 auto;
	min-width: 0;
	max-width: 100%;
}

.product-box.design-2 .product-box-main__main_price span.price {
	color: var(--mainColor, var(--bg-primary, #243c40));
	font-size: clamp(15px, 2.2vw, 21px);
	font-weight: 700;
	margin-bottom: 0;
	text-align: left;
	display: block;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.product-box.design-2 .product-box-main__main_price .price .woocommerce-Price-currencySymbol {
	color: #fff;
	font-size: 15px;
	background-color: var(--secondaryColor, var(--bg-secondary, #cfc0a5));
	border-radius: 6px;
	padding: 1px 5px;
}

.product-box.design-2 .product-box-main__title {
	min-width: 0;
	flex: 1 1 auto;
}

.product-box.design-2 .product-box-main__top {
	gap: 8px;
	min-width: 0;
}

.product-box.design-2 .product-box-main-main_title {
	display: block;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* design-3 shop cards — price overflow + layout */
.product-box.design-3 > a .d-flex {
	min-width: 0;
	gap: 10px;
	align-items: flex-start;
}

.product-box.design-3 .product-box-image {
	flex: 0 0 130px;
	min-width: 0;
}

.product-box.design-3 .product-box-image__image {
	overflow: hidden;
}

.product-box.design-3 .product-box-image__image img {
	width: 130px;
	max-width: 100%;
	max-height: 130px;
	object-fit: contain;
}

.product-box.design-3 .product-box-main {
	flex: 1 1 auto;
	min-width: 0;
}

.product-box.design-3 .product-box-main__title {
	min-width: 0;
}

.product-box.design-3 .woocommerce-loop-product__title {
	margin: 0;
	font-size: inherit;
	font-weight: inherit;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.product-box.design-3 .product-box-main__details {
	min-width: 0;
	width: 100%;
	gap: 8px;
}

.product-box.design-3 .product-box-main__buy_price,
.product-box.design-3 .product-box-main__main_price {
	min-width: 0;
	max-width: 100%;
	overflow: hidden;
}

.product-box.design-3 .product-box-main__buy_price:empty {
	display: none;
}

.product-box.design-3 .buy_price,
.product-box.design-3 .product-box-main__main_price span.price {
	display: block;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	max-width: 100%;
	font-size: clamp(13px, 1.8vw, 18px);
	font-weight: 700;
	color: var(--mainColor, var(--bg-primary, #243c40));
}

.product-box.design-3 .product-box-main__main_price .price .woocommerce-Price-currencySymbol {
	color: #fff;
	font-size: 13px;
	background-color: var(--secondaryColor, var(--bg-secondary, #cfc0a5));
	border-radius: 6px;
	padding: 1px 5px;
}

.product-box.design-3 .product-box__price_title {
	min-width: 0;
}

/* design-3 buy button — match zarnegar style.min.css */
.product-box.design-3 .product-box-button {
	display: flex;
	margin-top: 20px;
}

.product-box.design-3 .product-box-button .product-box__button {
	flex: 1;
	display: block;
	text-align: center;
	background-color: #243c401a;
	color: var(--mainColor, var(--bg-primary, #243c40));
	font-size: 16px;
	font-weight: 700;
	border: none;
	border-radius: 12px;
	padding: 12px;
	margin-top: 7px;
	transition: background-color 0.2s ease, color 0.2s ease;
}

.product-box.design-3:hover .product-box-button .product-box__button {
	background-color: var(--e-global-color-primary, var(--bg-primary, #243c40));
	color: #fff;
}

.justify-content-between { justify-content: space-between; }
.align-items-center { align-items: center; }
.text-center { text-align: center; }
.mt-2 { margin-top: 0.5rem; }
.flex-direction-column { flex-direction: column; }

/* Single product — see assets/css/single-product.css */
.bg-product-live-gold {
	background: linear-gradient(135deg, rgba(187, 165, 126, 0.15), rgba(36, 60, 64, 0.08));
	padding: 12px 16px;
	border-radius: var(--bg-radius);
	margin-bottom: 16px;
}

.bg-product-live-gold__label {
	display: block;
	font-size: 13px;
	color: var(--bg-text-muted);
}

.bg-product-reviews {
	margin-top: 0;
}

.bg-reviews-title {
	font-family: var(--bg-font-heading);
	margin-bottom: 20px;
}

.zarnegar-product-attributes ul {
	list-style: none;
	padding: 0;
	margin: 20px 0 0;
	display: flex;
	flex-wrap: wrap;
	gap: 0;
}

.zarnegar-product-attributes li.separator {
	width: 1px;
	background: rgba(36, 60, 64, 0.15);
	margin: 0 16px;
	align-self: stretch;
}

.zarnegar-pa-detail__title {
	font-size: 12px;
	color: var(--bg-text-muted);
}

.zarnegar-pa-detail__value {
	font-weight: 700;
}

.d-flex { display: flex; }
.gap-3 { gap: 12px; }
.align-items-center { align-items: center; }
.flex-direction-column { flex-direction: column; }

/* Single post — full width (sidebar removed) */
.single-post-page .bg-container {
	padding: 40px 0 48px;
}

.bg-single-title {
	font-family: var(--bg-font-heading);
	font-size: 2rem;
}

.bg-single-meta {
	color: var(--bg-text-muted);
	font-size: 14px;
	margin-bottom: 20px;
	display: flex;
	gap: 16px;
}

.bg-single-thumb {
	margin-bottom: 24px;
	border-radius: var(--bg-radius-lg);
	overflow: hidden;
}

/* Single post */
.bg-404-inner {
	text-align: center;
	padding: 80px 0;
}

.bg-404-code {
	font-size: 6rem;
	font-weight: 900;
	color: var(--bg-secondary);
	margin: 0;
	line-height: 1;
}

/* TML */
.bg-tml-wrap {
	max-width: 480px;
	margin: 40px auto;
	padding: 32px;
	background: #fff;
	border-radius: var(--bg-radius-lg);
	box-shadow: var(--bg-shadow);
}

/* WooCommerce tweaks */
.woocommerce-page .site-main {
	padding: 24px 0 48px;
	overflow-x: clip;
}

.woocommerce-shop .bg-container {
	overflow-x: clip;
	max-width: 100%;
}

.woocommerce .star-rating {
	color: var(--bg-secondary);
}

/* Responsive */
@media (max-width: 992px) {
	.zarnegar-woo-products-grid.columns-3,
	ul.products.zarnegar-woo-products-grid.columns-3 {
		grid-template-columns: repeat(2, 1fr);
		gap: 24px 12px;
	}
}

@media (max-width: 576px) {
	.zarnegar-woo-products-grid.columns-3,
	ul.products.zarnegar-woo-products-grid.columns-3 {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 992px) {
	.bg-shop-layout {
		grid-template-columns: 1fr;
	}

	.bg-nav-toggle {
		display: block;
	}

	.bg-nav-primary .bg-menu-primary {
		display: none;
		flex-direction: column;
		position: absolute;
		top: 100%;
		right: 0;
		left: 0;
		background: #fff;
		padding: 16px;
		box-shadow: var(--bg-shadow);
		z-index: 150;
	}

	.bg-nav-primary.is-open .bg-menu-primary {
		display: flex;
	}

	.bg-header-main-inner {
		position: relative;
	}

	.bg-account-links .bg-btn-outline {
		display: none;
	}
}

@media (min-width: 992px) {
	.bg-header-support {
		display: flex;
	}
}

@media (min-width: 1024px) {
	body:not(.home) .bg-header-main {
		margin-bottom: 40px;
	}
}
