/* Hamyara 0.15.26 — pre-v1 pricing/product/dashboard hardening */

/* Top date chip: all contents sit on one baseline and are centered vertically/horizontally. */
body.readable-ui .date-chip-v168{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
}
body.readable-ui .date-chip-v168 .date-icon,
body.readable-ui .date-copy-v168,
body.readable-ui .tehran-live-time-v168{align-self:center!important}
body.readable-ui .date-copy-v168{display:flex!important;align-items:center!important;justify-content:center!important}
body.readable-ui .date-copy-v168 b{display:flex!important;align-items:center!important;justify-content:center!important;line-height:1!important}
body.readable-ui .date-copy-v168 b>*{line-height:1!important;vertical-align:middle!important}

/* Dashboard AI/data-mining figures: use the available card width before shrinking. */
body .data-mining-v17 .mining-grid-v17 strong,
body .data-mining-v17 .mining-grid-v17 .money-with-unit-v170{
  font-size:clamp(17px,1.35vw,25px)!important;
  line-height:1.2!important;
  letter-spacing:-.45px!important;
  font-weight:850!important;
}
body .data-mining-v17 .mining-grid-v17 strong small,
body .data-mining-v17 .mining-grid-v17 .money-with-unit-v170 small{font-size:11px!important}
body .ai-suggestion-v17 footer b,
body .ai-suggestion-v17 .metric,
body .intelligence-shell-v17 .ai-suggestion-v17 footer strong{
  font-size:clamp(15px,1.12vw,20px)!important;
  line-height:1.3!important;
  font-weight:850!important;
}
body .dashboard-transaction-description-v176{min-width:250px!important;max-width:520px!important}

/* Summary numbers must never escape their cards, even with long Persian-formatted values. */
body.transaction-page .money-grid{min-width:0!important}
body.transaction-page .money-grid>div{min-width:0!important;overflow:hidden!important}
body.transaction-page .money-grid>div>strong,
body.transaction-page .money-grid .remaining>strong{
  display:block!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  overflow:hidden!important;
  white-space:nowrap!important;
  text-overflow:clip!important;
  direction:ltr!important;
  text-align:center!important;
  font-size:clamp(10.5px,.92vw,15px)!important;
  letter-spacing:-.75px!important;
  line-height:1.35!important;
}

/* Product edit: compact image area + clean fields below it. */
body .product-form-v176 .product-intro-v176{display:grid!important;gap:14px!important}
body .product-form-v176 .product-intro-top-v176{
  display:grid!important;
  grid-template-columns:250px minmax(0,1fr)!important;
  gap:16px!important;
  align-items:start!important;
}
body .product-form-v176 .product-image-uploader-v176{
  min-height:108px!important;
  height:108px!important;
  max-height:108px!important;
  padding:8px!important;
  display:grid!important;
  grid-template-columns:86px minmax(0,1fr)!important;
  grid-template-rows:1fr 1fr!important;
  gap:3px 10px!important;
  align-items:center!important;
  justify-items:start!important;
  text-align:right!important;
  overflow:hidden!important;
}
body .product-form-v176 .product-image-uploader-v176 img{
  grid-column:1!important;
  grid-row:1/3!important;
  width:86px!important;
  height:86px!important;
  margin:0!important;
  object-fit:cover!important;
}
body .product-form-v176 .product-image-uploader-v176 span{grid-column:2!important;grid-row:1!important;align-self:end!important}
body .product-form-v176 .product-image-uploader-v176 small{grid-column:2!important;grid-row:2!important;align-self:start!important;line-height:1.5!important}
body .product-form-v176 .product-core-fields-v176{display:grid!important;grid-template-columns:1fr!important;gap:10px!important;min-width:0!important}
body .product-form-v176 .product-name-input-v176{font-weight:500!important}
body .product-form-v176 .product-core-fields-v176 textarea{min-height:62px!important;height:62px!important;resize:vertical!important}
body .product-form-v176 .product-quick-fields-v176{
  display:grid!important;
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
  gap:12px!important;
  align-items:stretch!important;
}
body .product-form-v176 .product-quick-fields-v176>.field,
body .product-form-v176 .product-active-toggle-v176{
  min-height:112px!important;
  height:112px!important;
  box-sizing:border-box!important;
}
body .product-form-v176 .product-active-toggle-v176{
  margin-top:0!important;
  border:1px solid #d7e0ea!important;
  border-radius:11px!important;
  background:#fbfcfe!important;
  padding:10px 12px!important;
}
body .product-form-v176 .product-quick-fields-v176 :is(.select,.input,.purchase-price-value-v175){height:50px!important;min-height:50px!important;max-height:50px!important}
body .product-form-v176 .purchase-history-v175{margin-top:0!important;padding-top:14px!important}
body .product-form-v176 .purchase-history-list-v175>div{
  grid-template-columns:100px minmax(180px,1.25fr) minmax(120px,.8fr) 80px 145px!important;
}

/* Multi color/size selection: visual chips, no browser checkmark UI. */
body .variant-multi-grid-v176{display:grid!important;grid-template-columns:1fr 1fr!important;gap:14px!important}
body .variant-choice-panel-v176{border:1px solid #dfe7ef!important;border-radius:14px!important;background:#fbfcfe!important;padding:14px!important;min-width:0!important}
body .variant-choice-panel-v176>header{margin-bottom:10px!important}
body .variant-choice-panel-v176>header strong,body .variant-choice-panel-v176>header small{display:block!important}
body .variant-choice-panel-v176>header small{color:#7e8fa1!important;margin-top:2px!important}
body .color-choice-grid-v176,body .size-choice-grid-v176{display:flex!important;gap:8px!important;flex-wrap:wrap!important}
body .variant-choice-v176{position:relative!important;display:inline-flex!important;align-items:center!important;gap:7px!important;min-height:40px!important;padding:7px 10px!important;border:1px solid #d7e2eb!important;border-radius:11px!important;background:#fff!important;cursor:pointer!important;transition:.16s!important;user-select:none!important}
body .variant-choice-v176:hover{border-color:#9fc4da!important;background:#f4faff!important}
body .variant-choice-v176 input{position:absolute!important;opacity:0!important;pointer-events:none!important}
body .variant-choice-v176:has(input:checked){border-color:#2c8fb0!important;background:#eaf7fb!important;box-shadow:0 0 0 2px rgba(44,143,176,.08)!important}
body .color-choice-v176>i{width:20px!important;height:20px!important;border-radius:7px!important;background:var(--choice-color)!important;border:1px solid rgba(0,0,0,.12)!important;box-shadow:inset 0 0 0 1px rgba(255,255,255,.4)!important}
body .variant-choice-v176>span{font-weight:700!important;font-size:13px!important}

/* Product summary uses the same understated product-name typography. */
body .product-form-v176 .sticky-form-summary-v13 h2{font-weight:600!important}

/* Pricing page: product-search column visually continues to the bottom of the workspace. */
body .pricing-page-v10{align-items:stretch!important}
body .pricing-product-list{align-self:stretch!important;height:100%!important;min-height:100%!important;display:flex!important;flex-direction:column!important}
body .pricing-product-scroll{flex:1 1 auto!important;max-height:none!important;min-height:0!important}
body .tier-field.partner-auto-v176 input[readonly]{background:#f5f7f9!important;color:#203d55!important;cursor:default!important;font-weight:800!important}

/* Keep invoice discount and its summary baseline aligned after label wording grows. */
body.transaction-page .invoice-discount-field-v29>span{line-height:1.35!important;min-height:40px!important;display:flex!important;align-items:center!important}
body.transaction-page .retail-items-metrics-v29{padding-top:24px!important}

@media(max-width:1180px){
  body .product-form-v176 .product-quick-fields-v176{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  body .product-form-v176 .variant-multi-grid-v176{grid-template-columns:1fr!important}
}
@media(max-width:760px){
  body .product-form-v176 .product-intro-top-v176{grid-template-columns:1fr!important}
  body .product-form-v176 .product-image-uploader-v176{width:100%!important}
  body .product-form-v176 .product-quick-fields-v176{grid-template-columns:1fr!important}
  body .product-form-v176 .product-quick-fields-v176>.field,
  body .product-form-v176 .product-active-toggle-v176{height:auto!important;min-height:92px!important}
  body .product-form-v176 .purchase-history-list-v175>div{grid-template-columns:1fr 1fr!important}
}
