.krg-wp-purchase,.krg-wp-purchase *{box-sizing:border-box;font-family:IRANYekanX,Vazirmatn,Tahoma,Arial,sans-serif!important}
.krg-wp-purchase{direction:rtl;margin:18px 0;padding:18px;border:1px solid #dde5f0;border-radius:22px;background:linear-gradient(180deg,#fff 0,#fbfcff 100%);box-shadow:0 10px 32px rgba(13,27,61,.06)}
.krg-wp-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:14px}
.krg-wp-kicker{font-size:11px;font-weight:700;color:#F97316}
.krg-wp-head h3{margin:3px 0 0!important;font-size:18px!important;line-height:1.5!important;color:#0D1B3D!important;font-weight:900!important}
.krg-wp-pack-badge{display:inline-flex;align-items:center;min-height:32px;padding:6px 11px;border-radius:999px;background:#eef3fb;color:#18376F;font-size:11px;font-weight:800;white-space:nowrap}
.krg-wp-price-cards{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.krg-wp-price-card{position:relative;display:flex!important;align-items:center;gap:10px;min-width:0;padding:13px 14px;border:1.5px solid #dce4ef;border-radius:16px;background:#fff;cursor:pointer;transition:.18s ease;margin:0!important}
.krg-wp-price-card:hover{transform:translateY(-1px);border-color:#c7d3e4;box-shadow:0 8px 20px rgba(15,23,42,.05)}
.krg-wp-price-card input{position:absolute;opacity:0;pointer-events:none}
.krg-wp-radio{width:20px;height:20px;flex:0 0 20px;border:2px solid #b5c0d1;border-radius:50%;position:relative}
.krg-wp-price-card input:checked~.krg-wp-radio{border-color:#F97316}
.krg-wp-price-card input:checked~.krg-wp-radio:after{content:"";position:absolute;inset:4px;background:#F97316;border-radius:50%}
.krg-wp-price-card:has(input:checked){border-color:#F97316;background:#fffaf6;box-shadow:0 0 0 3px rgba(249,115,22,.08)}
.krg-wp-price-copy{display:flex;flex-direction:column;min-width:0;gap:2px}
.krg-wp-price-copy small{font-size:11px;color:#64748b;font-weight:700}
.krg-wp-price-copy strong{display:block;font-size:16px!important;line-height:1.45!important;color:#0D1B3D!important;font-weight:900!important;white-space:normal}
.krg-wp-price-copy strong .woocommerce-Price-amount{font-size:inherit!important;color:inherit!important}
.krg-wp-price-copy em{font-style:normal;font-size:10.5px;line-height:1.7;color:#697586}
.krg-wp-price-card.is-wholesale .krg-wp-price-copy strong{color:#d95f0b!important}
.krg-wp-price-card.is-disabled{cursor:default;opacity:.72;background:#f8fafc}
.krg-wp-price-card.is-disabled:hover{transform:none;box-shadow:none}
.krg-wp-lock{margin-right:auto;align-self:flex-start;font-size:9px;padding:3px 6px;border-radius:6px;color:#64748b;background:#eef2f7;font-weight:700}
.krg-wp-live-summary{display:grid;grid-template-columns:46px minmax(0,1fr) auto;align-items:center;gap:12px;margin-top:12px;padding:12px 13px;border-radius:16px;background:#0D1B3D;color:#fff;overflow:hidden}
.krg-wp-summary-icon{width:46px;height:46px;border-radius:14px;display:grid;place-items:center;background:rgba(255,255,255,.1)}
.krg-wp-summary-icon svg{width:25px;height:25px;fill:none;stroke:#FB923C;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.krg-wp-summary-main,.krg-wp-summary-total{display:flex;flex-direction:column;gap:2px;min-width:0}
.krg-wp-summary-main small,.krg-wp-summary-total small{font-size:9.5px;color:#b9c5d8}
.krg-wp-summary-main strong{font-size:12.5px;line-height:1.7;color:#fff;font-weight:800}
.krg-wp-summary-main span{font-size:9.5px;color:#dbe5f3;line-height:1.65}
.krg-wp-summary-total{padding-right:14px;border-right:1px solid rgba(255,255,255,.14);text-align:left;min-width:145px}
.krg-wp-summary-total strong{font-size:15px;color:#FDBA74;font-weight:900;white-space:nowrap}
.krg-wp-item-note{margin-top:12px}
.krg-wp-item-note label{display:flex;align-items:center;gap:7px;margin-bottom:6px;font-size:11.5px;font-weight:800;color:#24324a}
.krg-wp-item-note label span{font-size:9px;font-weight:600;color:#94a3b8}
.krg-wp-item-note textarea{display:block;width:100%;min-height:64px!important;padding:10px 12px!important;border:1px solid #dce3ed!important;border-radius:12px!important;background:#fff!important;color:#1f2937!important;font-size:11.5px!important;line-height:1.8!important;resize:vertical;box-shadow:none!important}
.krg-wp-item-note textarea:focus{outline:none!important;border-color:#F97316!important;box-shadow:0 0 0 3px rgba(249,115,22,.08)!important}
/* Integrate with the previously supplied Kargadan single-product template. */
.krg-wholesale-enabled .krg-sp__wholesale-mini,.krg-wholesale-enabled .krg-sp__bottom-cta{display:none!important}
.krg-wholesale-enabled form.cart .quantity{position:relative;margin-top:10px!important}
.krg-wholesale-enabled form.cart .quantity:before{content:attr(data-krg-qty-label);display:block;margin-bottom:5px;font-size:10.5px;font-weight:800;color:#475569}
.krg-wholesale-enabled form.cart .qty{min-height:44px!important;font-size:13px!important;font-weight:800!important;border-radius:12px!important}
.krg-wp-cart-pack-price{display:flex;flex-direction:column;gap:2px}.krg-wp-cart-pack-price strong{font-weight:800}.krg-wp-cart-pack-price small{color:#64748b}.krg-wp-cart-pack-price em{font-style:normal;font-size:10px;color:#94a3b8}
.krg-wp-cart-qty-note{display:block;margin-top:4px;color:#d95f0b;font-size:10px;font-weight:800}
.krg-wp-added-message{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.krg-wp-added-message strong{color:#166534}.krg-wp-added-message span{color:#475569}.krg-wp-added-message b{margin-right:auto;color:#d95f0b}
@media(max-width:767px){
 .krg-wp-purchase{margin:14px 0;padding:14px;border-radius:18px}
 .krg-wp-head{align-items:center}.krg-wp-head h3{font-size:16px!important}.krg-wp-pack-badge{font-size:9.5px;padding:5px 8px}
 .krg-wp-price-cards{grid-template-columns:1fr}
 .krg-wp-price-card{padding:12px}.krg-wp-price-copy strong{font-size:15px!important}.krg-wp-price-copy em{font-size:10px}
 .krg-wp-live-summary{grid-template-columns:40px minmax(0,1fr);gap:9px;padding:11px}
 .krg-wp-summary-icon{width:40px;height:40px;border-radius:12px}
 .krg-wp-summary-total{grid-column:1/-1;border-right:0;border-top:1px solid rgba(255,255,255,.13);padding:9px 0 0;display:flex;flex-direction:row;align-items:center;justify-content:space-between;text-align:right;min-width:0}
 .krg-wp-summary-total strong{font-size:14px}
 .krg-wp-item-note label{font-size:11px}.krg-wp-item-note textarea{font-size:11px!important}
}

/* v1.1.0: styled success notice with cart and checkout actions */
.krg-wholesale-enabled .krg-sp__notices .woocommerce-message,
.single-product.krg-wholesale-enabled .woocommerce-notices-wrapper .woocommerce-message{
  margin:0 0 18px!important;padding:0!important;border:0!important;background:transparent!important;box-shadow:none!important;color:inherit!important
}
.krg-wholesale-enabled .krg-sp__notices .woocommerce-message:before,
.single-product.krg-wholesale-enabled .woocommerce-notices-wrapper .woocommerce-message:before{display:none!important}
.krg-wp-added-message,.krg-wp-added-message *{box-sizing:border-box;font-family:IRANYekanX,Vazirmatn,Tahoma,Arial,sans-serif!important}
.krg-wp-added-message{display:grid;grid-template-columns:48px minmax(0,1fr) auto auto;align-items:center;gap:13px;width:100%;padding:15px 16px;border:1px solid #bbf7d0;border-right:5px solid #16a34a;border-radius:18px;background:linear-gradient(135deg,#f0fdf4 0,#fff 72%);box-shadow:0 12px 34px rgba(22,163,74,.09);direction:rtl}
.krg-wp-added-icon{display:grid;width:48px;height:48px;place-items:center;border-radius:15px;background:#dcfce7;color:#15803d}
.krg-wp-added-icon svg{width:25px;height:25px;fill:none;stroke:currentColor;stroke-width:2.4;stroke-linecap:round;stroke-linejoin:round}
.krg-wp-added-copy{display:flex;min-width:0;flex-direction:column;gap:3px}
.krg-wp-added-copy strong{font-size:13.5px!important;line-height:1.75!important;color:#14532d!important;font-weight:900!important}
.krg-wp-added-copy span{font-size:11.5px!important;line-height:1.7!important;color:#475569!important;font-weight:700!important}
.krg-wp-added-total{font-size:14px!important;line-height:1.5!important;color:#d95f0b!important;font-weight:900!important;white-space:nowrap}
.krg-wp-added-total .woocommerce-Price-amount{font-size:inherit!important;color:inherit!important}
.krg-wp-added-actions{display:flex;align-items:center;gap:8px;margin:0!important}
.krg-wp-added-actions .button{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-height:42px!important;margin:0!important;padding:9px 14px!important;border-radius:12px!important;font-size:11.5px!important;line-height:1.5!important;font-weight:900!important;text-decoration:none!important;white-space:nowrap!important;box-shadow:none!important}
.krg-wp-view-cart{border:1px solid #cbd5e1!important;background:#fff!important;color:#0D1B3D!important}
.krg-wp-view-cart:hover{border-color:#0D1B3D!important;background:#f8fafc!important;color:#0D1B3D!important}
.krg-wp-go-checkout{border:1px solid #F97316!important;background:linear-gradient(135deg,#F97316,#FB923C)!important;color:#fff!important;box-shadow:0 8px 18px rgba(249,115,22,.2)!important}
.krg-wp-go-checkout:hover{color:#fff!important;filter:brightness(.97)}
@media(max-width:900px){
 .krg-wp-added-message{grid-template-columns:44px minmax(0,1fr) auto}
 .krg-wp-added-actions{grid-column:1/-1;width:100%}
 .krg-wp-added-actions .button{flex:1 1 0}
}
@media(max-width:560px){
 .krg-wp-added-message{grid-template-columns:40px minmax(0,1fr);gap:10px;padding:13px;border-radius:15px}
 .krg-wp-added-icon{width:40px;height:40px;border-radius:12px}
 .krg-wp-added-total{grid-column:2/3}
 .krg-wp-added-actions{display:grid;grid-template-columns:1fr 1fr;gap:7px}
 .krg-wp-added-actions .button{min-height:44px!important;padding:8px!important;font-size:11px!important}
}

/* =========================================================
   Kargadan Wholesale Pricing 1.2.0
   Mobile layout repair for [kargadan_single_product]
   ========================================================= */
@media (max-width: 820px) {
  /* The wholesale panel is injected inside form.cart. The product template
     uses a multi-column cart grid on mobile, so the panel must explicitly
     span the complete grid or it collapses into the 76px quantity column. */
  body.krg-wholesale-enabled .krg-sp__product-shell form.cart > .krg-wp-purchase,
  .krg-wholesale-enabled .krg-sp__product-shell form.cart > .krg-wp-purchase,
  .krg-sp__product-shell form.cart > .krg-wp-purchase {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    flex: 0 0 100% !important;
    margin: 0 0 12px !important;
    padding: 16px !important;
    clear: both !important;
    border-radius: 18px !important;
    overflow: visible !important;
  }

  .krg-wp-head {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 8px !important;
    align-items: start !important;
    margin-bottom: 14px !important;
  }

  .krg-wp-head > div { min-width: 0 !important; }
  .krg-wp-kicker { font-size: 12px !important; line-height: 1.8 !important; }
  .krg-wp-head h3 {
    margin: 2px 0 0 !important;
    font-size: 19px !important;
    line-height: 1.55 !important;
  }
  .krg-wp-pack-badge {
    justify-self: start !important;
    width: auto !important;
    max-width: 100% !important;
    min-height: 34px !important;
    padding: 6px 11px !important;
    white-space: normal !important;
    font-size: 11px !important;
    line-height: 1.7 !important;
  }

  .krg-wp-price-cards {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 10px !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  .krg-wp-price-card {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 92px !important;
    padding: 13px 14px !important;
    gap: 11px !important;
    align-items: center !important;
    border-radius: 15px !important;
  }
  .krg-wp-radio {
    width: 22px !important;
    height: 22px !important;
    flex-basis: 22px !important;
  }
  .krg-wp-price-copy {
    width: 100% !important;
    min-width: 0 !important;
    gap: 3px !important;
  }
  .krg-wp-price-copy small {
    font-size: 12px !important;
    line-height: 1.7 !important;
  }
  .krg-wp-price-copy strong {
    font-size: 17px !important;
    line-height: 1.65 !important;
    overflow-wrap: anywhere !important;
  }
  .krg-wp-price-copy em {
    font-size: 11px !important;
    line-height: 1.85 !important;
    color: #536177 !important;
  }
  .krg-wp-lock {
    margin-right: auto !important;
    font-size: 9.5px !important;
  }

  .krg-wp-live-summary {
    width: 100% !important;
    grid-template-columns: 42px minmax(0,1fr) !important;
    gap: 10px !important;
    margin-top: 11px !important;
    padding: 12px !important;
    border-radius: 15px !important;
  }
  .krg-wp-summary-icon { width: 42px !important; height: 42px !important; }
  .krg-wp-summary-main small,
  .krg-wp-summary-total small { font-size: 10px !important; }
  .krg-wp-summary-main strong { font-size: 13px !important; line-height: 1.75 !important; }
  .krg-wp-summary-main span { font-size: 10px !important; line-height: 1.75 !important; }
  .krg-wp-summary-total {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    min-width: 0 !important;
    padding: 10px 0 0 !important;
    border-right: 0 !important;
    border-top: 1px solid rgba(255,255,255,.13) !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
  }
  .krg-wp-summary-total strong { font-size: 15px !important; }

  .krg-wp-item-note { width: 100% !important; }
  .krg-wp-item-note label { font-size: 11.5px !important; }
  .krg-wp-item-note textarea {
    width: 100% !important;
    min-height: 72px !important;
    font-size: 12px !important;
  }

  /* Keep quantity + primary add-to-cart button usable after the full-width panel. */
  .krg-wholesale-enabled .krg-sp__product-shell form.cart .quantity {
    min-width: 76px !important;
    margin: 0 !important;
  }
  .krg-wholesale-enabled .krg-sp__product-shell form.cart .qty {
    width: 100% !important;
    min-width: 76px !important;
    min-height: 50px !important;
    font-size: 15px !important;
  }
  .krg-wholesale-enabled .krg-sp__product-shell form.cart .single_add_to_cart_button {
    min-height: 50px !important;
  }
}

@media (max-width: 480px) {
  .krg-sp__product-shell form.cart > .krg-wp-purchase {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    min-width: 0 !important;
    padding: 14px !important;
  }
  .krg-wp-price-card { min-height: 88px !important; padding: 12px 13px !important; }
  .krg-wp-price-copy strong { font-size: 16.5px !important; }
  .krg-wp-price-copy em { font-size: 10.5px !important; }
}
