/**
 * Brandina Theme - Main styles
 *
 * مقادیر اصلی این فایل از «نمایش ← سفارشی‌سازی ← تنظیمات قالب برندینا»
 * کنترل می‌شوند. بخش‌های جدید باید از متغیرهای سراسری همین فایل استفاده کنند.
 */

:root {
	--brandina-font-family: "Vazirmatn", Tahoma, Arial, sans-serif;
	--brandina-font-size: 16px;
	--brandina-mobile-font-size: 15px;
	--brandina-body-weight: 400;
	--brandina-heading-weight: 700;
	--brandina-body-line-height: 1.85;
	--brandina-heading-line-height: 1.45;
	--brandina-primary: #ff6f8f;
	--brandina-primary-dark: #f04d75;
	--brandina-secondary: #8a4dff;
	--brandina-text: #1f2937;
	--brandina-muted: #6b7280;
	--brandina-background: #ffffff;
	--brandina-surface: #ffffff;
	--brandina-border: #e8e8ee;
	--brandina-success: #169b62;
	--brandina-danger: #df334f;
	--brandina-container: 1240px;
	--brandina-section-spacing: 72px;
	--brandina-section-spacing-mobile: 42px;
	--brandina-radius: 16px;
	--brandina-button-radius: 12px;
	--brandina-field-radius: 10px;
}

html {
	scroll-behavior: smooth;
}

body {
	margin: 0;
	color: var(--brandina-text);
	background: var(--brandina-background);
	font-family: var(--brandina-font-family);
	font-size: var(--brandina-font-size);
	font-weight: var(--brandina-body-weight);
	line-height: var(--brandina-body-line-height);
}

/* کلاس پایه برای تمام بخش‌های کدنویسی‌شده آینده */
.brandina-container {
	width: min(calc(100% - 32px), var(--brandina-container));
	margin-inline: auto;
}

.brandina-section {
	padding-block: var(--brandina-section-spacing);
}

/* جلوگیری از بیرون‌زدگی تصاویر */
img {
	max-width: 100%;
	height: auto;
}

/* سازگاری بهتر فیلدها و دکمه‌ها */
button,
input,
select,
textarea {
	font: inherit;
}

/* Brandina v1.18.2 — deterministic WooCommerce price direction everywhere.
 * The server wraps the formatted numeric run and currency as separate items,
 * preventing grouped values such as 745 000 from becoming 000 745 in RTL.
 */
.woocommerce-Price-amount{
	display:inline-flex!important;
	align-items:baseline!important;
	max-width:100%;
	direction:ltr!important;
	unicode-bidi:isolate!important;
	white-space:nowrap!important;
	font-variant-numeric:tabular-nums;
}
.woocommerce-Price-amount bdi.brandina-price-bdi{
	display:inline-flex!important;
	align-items:baseline!important;
	flex-direction:row!important;
	max-width:100%;
	direction:ltr!important;
	unicode-bidi:isolate!important;
	white-space:nowrap!important;
}
.woocommerce-Price-amount .brandina-price-number{
	display:inline-block;
	direction:ltr!important;
	unicode-bidi:isolate!important;
	white-space:nowrap!important;
}
.woocommerce-Price-amount .brandina-price-gap{
	display:inline-block;
	width:.22em;
	flex:0 0 .22em;
}
.woocommerce-Price-amount .woocommerce-Price-currencySymbol{
	display:inline-block;
	flex:0 0 auto;
	direction:rtl!important;
	unicode-bidi:isolate!important;
	white-space:nowrap!important;
}



/* Brandina v1.18.2 — remove unintended space above the site header. */
html,body{margin-top:0!important;}
.brandina-site-header{margin-top:0!important;}
body>.brandina-site-header:first-of-type{margin-block-start:0!important;}

/* Standalone WordPress foundations. */
*,*::before,*::after{box-sizing:border-box}
a{color:var(--brandina-primary-dark);text-underline-offset:.18em}
a:hover{color:var(--brandina-secondary)}
.screen-reader-text{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.screen-reader-text:focus,.skip-link:focus{z-index:100000;top:8px;right:8px;width:auto;height:auto;margin:0;padding:10px 16px;clip:auto;border-radius:8px;background:#fff;color:#111;box-shadow:0 8px 30px rgba(0,0,0,.18);font-weight:700}
.brandina-content-shell{padding-block:clamp(24px,5vw,72px);min-height:55vh}
.brandina-entry-header,.brandina-archive-header{margin-bottom:28px}
.brandina-entry-header h1,.brandina-archive-header h1{margin:0;color:var(--brandina-text);font-size:clamp(26px,4vw,44px);line-height:1.45}
.brandina-entry-meta{margin-top:10px;color:var(--brandina-muted);font-size:13px}
.brandina-entry-featured{overflow:hidden;margin-bottom:28px;border-radius:var(--brandina-radius)}
.brandina-entry-featured img{display:block;width:100%}
.brandina-entry-content{font-size:1rem;overflow-wrap:anywhere}
.brandina-entry-content>:first-child{margin-top:0}.brandina-entry-content>:last-child{margin-bottom:0}
.brandina-entry-content h2,.brandina-entry-content h3,.brandina-entry-content h4{margin-top:1.8em;color:var(--brandina-text)}
.brandina-entry-content p,.brandina-entry-content li{line-height:1.95}
.brandina-entry-content blockquote{margin:24px 0;padding:16px 20px;border-inline-start:4px solid var(--brandina-primary);border-radius:10px;background:color-mix(in srgb,var(--brandina-primary) 7%,#fff)}
.brandina-entry-content table{width:100%;border-collapse:collapse}.brandina-entry-content th,.brandina-entry-content td{padding:10px;border:1px solid var(--brandina-border)}
.brandina-entry-content pre{max-width:100%;overflow:auto;padding:18px;border-radius:12px;background:#111827;color:#f9fafb;direction:ltr;text-align:left}
.alignwide{width:min(100%,calc(var(--brandina-container) + 180px));max-width:none;margin-inline:50%;transform:translateX(50%)}
.alignfull{width:100vw;max-width:none;margin-inline:50%;transform:translateX(50%)}
.brandina-post-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px}
.brandina-post-card{display:grid;grid-template-columns:minmax(160px,34%) minmax(0,1fr);overflow:hidden;border:1px solid var(--brandina-border);border-radius:var(--brandina-radius);background:var(--brandina-surface)}
.brandina-post-card-media{display:block;min-height:190px;background:#f5f6f8}.brandina-post-card-media img{width:100%;height:100%;object-fit:cover}
.brandina-post-card-body{padding:22px}.brandina-post-card h2{margin:0 0 10px;font-size:19px;line-height:1.7}.brandina-post-card h2 a{color:inherit;text-decoration:none}
.brandina-entry-summary{color:var(--brandina-muted);font-size:14px}.brandina-entry-summary p{margin:0}
.navigation.pagination{margin-top:32px}.nav-links{display:flex;flex-wrap:wrap;justify-content:center;gap:7px}.page-numbers{display:grid;min-width:40px;height:40px;padding:0 10px;place-items:center;border:1px solid var(--brandina-border);border-radius:10px;background:#fff;color:var(--brandina-text);text-decoration:none}.page-numbers.current{border-color:var(--brandina-primary);background:var(--brandina-primary);color:#fff}
.brandina-empty-state{max-width:720px;margin:40px auto;padding:clamp(24px,5vw,54px);border:1px solid var(--brandina-border);border-radius:24px;background:#fff;text-align:center}.brandina-empty-state>span{display:block;color:var(--brandina-primary);font-size:clamp(64px,12vw,120px);font-weight:900;line-height:1}.brandina-empty-state .button{display:inline-flex;margin-top:18px;padding:11px 18px;background:var(--brandina-primary);color:#fff;text-decoration:none}
.brandina-search-form{display:flex;max-width:560px;margin:20px auto 0;gap:8px}.brandina-search-form input{min-width:0;flex:1;height:48px;padding:0 14px;border:1px solid var(--brandina-border);background:#fff}.brandina-search-form button{min-width:90px;border:0;border-radius:var(--brandina-button-radius);background:var(--brandina-primary);color:#fff;font-weight:800}
.brandina-post-navigation{margin-top:32px}.brandina-post-navigation .nav-links{display:grid;grid-template-columns:1fr 1fr;gap:16px}.brandina-post-navigation a{display:block;padding:18px;border:1px solid var(--brandina-border);border-radius:14px;text-decoration:none}.brandina-post-navigation span{display:block;color:var(--brandina-muted);font-size:11px}.brandina-post-navigation strong{display:block;margin-top:4px;color:var(--brandina-text)}
.brandina-comments-area{margin-top:42px;padding-top:28px;border-top:1px solid var(--brandina-border)}.comment-list{padding:0;list-style:none}.comment-list .comment-body{margin-bottom:14px;padding:18px;border:1px solid var(--brandina-border);border-radius:14px}.comment-meta{font-size:12px}.comment-content{margin-top:10px}.comment-respond input:not([type=submit]),.comment-respond textarea{width:100%;padding:10px 12px;border:1px solid var(--brandina-border);background:#fff}.comment-respond .submit{padding:10px 18px;border:0;background:var(--brandina-primary);color:#fff;cursor:pointer}
@media(max-width:900px){.brandina-post-list{grid-template-columns:1fr}.brandina-post-card{grid-template-columns:140px minmax(0,1fr)}}
@media(max-width:600px){.brandina-content-shell{width:min(calc(100% - 20px),var(--brandina-container))}.brandina-post-card{grid-template-columns:1fr}.brandina-post-card-media{min-height:180px}.brandina-post-card-body{padding:16px}.brandina-post-navigation .nav-links{grid-template-columns:1fr}.brandina-search-form{flex-direction:column}.brandina-search-form button{height:44px}}

/* Brandina 2.9.0 — compact card currency + one continuous old-price strike.
 * Keep the proven 2.8.8 variable range layout untouched. Only remove the
 * explicit spacer used by ordinary WooCommerce amounts inside product cards. */
.brandina-product-price .brandina-price-gap,
.brandina-shop-price .brandina-price-gap,
.brandina-single-related-price .brandina-price-gap{
  display:none!important;
  width:0!important;
  flex:0 0 0!important;
}

.brandina-product-price del,
.brandina-shop-price del,
.brandina-single-related-price del,
.brandina-search-result-price del{
  text-decoration:none!important;
  opacity:1!important;
}
.brandina-product-price del *,
.brandina-shop-price del *,
.brandina-single-related-price del *,
.brandina-search-result-price del *{text-decoration:none!important}

/* Simple sale price: one line across number + currency as a single amount. */
.brandina-product-price del>.woocommerce-Price-amount,
.brandina-shop-price del>.woocommerce-Price-amount,
.brandina-single-related-price del>.woocommerce-Price-amount,
.brandina-search-result-price del>.woocommerce-Price-amount{position:relative!important}
.brandina-product-price del>.woocommerce-Price-amount::after,
.brandina-shop-price del>.woocommerce-Price-amount::after,
.brandina-single-related-price del>.woocommerce-Price-amount::after,
.brandina-search-result-price del>.woocommerce-Price-amount::after{
  content:"";position:absolute;z-index:2;top:50%;right:0;left:0;height:1px;
  background:currentColor;transform:translateY(-50%);pointer-events:none;
}

/* Variable sale price: affect ONLY the old row, never the current range layout. */
.brandina-product-price del>.brandina-card-price-line,
.brandina-shop-price del>.brandina-card-price-line,
.brandina-single-related-price del>.brandina-card-price-line{
  position:relative!important;width:fit-content!important;max-width:100%!important;
  margin-left:auto!important;margin-right:0!important;
}
.brandina-product-price del>.brandina-card-price-line::after,
.brandina-shop-price del>.brandina-card-price-line::after,
.brandina-single-related-price del>.brandina-card-price-line::after{
  content:"";position:absolute;z-index:2;top:50%;right:0;left:0;height:1px;
  background:currentColor;transform:translateY(-50%);pointer-events:none;
}

/* Brandina 2.9.8 — compact variable-card price.
 * A variable product now paints one accurate starting price instead of a long
 * min/max range. Currency stays on the visual left and «از» on the visual
 * right, so the whole price remains a single responsive row. */
.brandina-product-card.is-variable-product .brandina-product-price .brandina-card-price-line.is-variable-start,
.brandina-shop-product-card.is-variable-product .brandina-shop-price .brandina-card-price-line.is-variable-start,
.brandina-single-related-card.is-variable-product .brandina-single-related-price .brandina-card-price-line.is-variable-start{
  display:inline-flex!important;
  width:auto!important;
  max-width:100%!important;
  align-items:baseline!important;
  gap:0!important;
  white-space:nowrap!important;
}
.brandina-product-card.is-variable-product .brandina-product-price .brandina-card-price-line.is-variable-start .brandina-card-price-values,
.brandina-shop-product-card.is-variable-product .brandina-shop-price .brandina-card-price-line.is-variable-start .brandina-card-price-values,
.brandina-single-related-card.is-variable-product .brandina-single-related-price .brandina-card-price-line.is-variable-start .brandina-card-price-values{
  display:inline-flex!important;
  min-width:0!important;
  flex:0 1 auto!important;
  align-items:baseline!important;
  flex-wrap:nowrap!important;
  gap:0!important;
  white-space:nowrap!important;
}
.brandina-card-price-line.is-variable-start .brandina-card-price-prefix{
  display:inline-block;
  flex:0 0 auto;
  margin-inline-start:.34em;
  color:inherit;
  direction:rtl;
  font-size:.72em;
  font-weight:700;
  letter-spacing:0;
  line-height:1;
  white-space:nowrap;
}

@media(max-width:767px){
  .brandina-product-card.is-variable-product .brandina-product-price .brandina-card-price-line.is-variable-start{
    font-size:clamp(10px,3vw,var(--brandina-product-price-mobile,12px))!important;
  }
  .brandina-shop-product-card.is-variable-product .brandina-shop-price .brandina-card-price-line.is-variable-start{
    font-size:clamp(9.5px,3vw,var(--shop-price-m,11px))!important;
  }
  .brandina-single-related-card.is-variable-product .brandina-single-related-price .brandina-card-price-line.is-variable-start{
    font-size:clamp(10px,3vw,12px)!important;
  }
}
