
/* KSR_NATIVE_V2 — Server-rendered candidate only. */
.ksr-v2-native .cp-product-detail__container {
    display: grid !important;
    grid-template-columns: minmax(0,1fr) 352px !important;
    grid-template-areas:
        "main donation"
        "funding donation"
        "description donation" !important;
    align-items: start;
    gap: 24px 32px;
    direction: rtl;
}

.ksr-v2-native .cp-product-detail__cutaway {
    grid-area: main !important;
}

.ksr-v2-native .cp-product-detail__form-wrap {
    grid-area: donation !important;
}

.ksr-v2-native .ksr-v1-funding {
    grid-area: funding !important;
}

.ksr-v2-native .ksr-v1-about-preview {
    grid-area: description !important;
    min-width: 0;
}

.ksr-v2-native .cp-product-detail__form-wrap
.cp-product-detail__statistics,
.ksr-v2-native .cp-product-detail__form-wrap
.cp-product-detail__percent-bar {
    display: none !important;
}

/* Only the description already rendered in the new About section. */
.ksr-v2-native .ty-tabs__content:has(#content_description),
.ksr-v2-native .ty-tabs li:has(a[href="#content_description"]) {
    display: none !important;
}

@media (max-width: 1000px) {
    .ksr-v2-native .cp-product-detail__container {
        grid-template-columns: minmax(0,1fr) !important;
        grid-template-areas:
            "main"
            "funding"
            "donation"
            "description" !important;
    }
}

@media (max-width: 600px) {
    .ksr-v2-native .cp-product-detail__container {
        gap: 18px !important;
    }
}


/* KSR_V2_PRICING_FAITHFUL_V1
   Scoped to server-rendered V2. Visual styling only. */

.ksr-v2-native .ksr-v2-donation-card {
    direction: rtl;
    box-sizing: border-box !important;
    align-self: start;
}

.ksr-v2-native .ksr-v2-donation-card .ksr-v1-donate-heading {
    display: block !important;
    background: transparent !important;
    text-shadow: none !important;
}

.ksr-v2-native .ksr-v2-donation-card .subheader2,
.ksr-v2-native .ksr-v2-donation-card .subheader2 *,
.ksr-v2-native .ksr-v2-donation-card .cp-default-prices__title {
    color: #77716d !important;
    background: transparent !important;
    text-shadow: none !important;
    font-size: 14px !important;
    font-weight: 600 !important;
}

.ksr-v2-native .ksr-v2-donation-card
.ty-price-curency__input-wrap .currency-symbol {
    order: 2 !important;
    flex: 0 0 auto !important;
    display: flex !important;
    position: static !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 12px !important;
    margin: 0 !important;
    border: 0 !important;
    border-inline-start: 1px solid #eae6e2 !important;
    color: #81776f !important;
    background: #fff !important;
    font-size: 13px !important;
}

.ksr-v2-native .ksr-v2-donation-card
.cp-product-detail__buttons .button-items {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 9px !important;
    width: 100% !important;
    max-width: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.ksr-v2-native .ksr-v2-donation-card
.cp-product-detail__buttons .button-items > * {
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    float: none !important;
    margin: 0 !important;
}

.ksr-v2-native .ksr-v2-donation-card
.cp-product-detail__buttons .ty-btn__donate {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-height: 50px !important;
    padding: 10px !important;
    margin: 0 !important;
    border-radius: 11px !important;
    border: 1px solid #df493e !important;
    background: #df493e !important;
    color: #fff !important;
    opacity: 1 !important;
    box-shadow: none !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    box-sizing: border-box !important;
}

.ksr-v2-native .ksr-v2-donation-card
.cp-product-detail__buttons button[id^="button_cart_one_"] {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-height: 44px !important;
    padding: 10px !important;
    margin: 0 !important;
    border-radius: 11px !important;
    border: 1px solid #eae6e2 !important;
    background: #fff !important;
    color: #77716d !important;
    box-shadow: none !important;
    box-sizing: border-box !important;
}

.ksr-v2-native .ksr-v2-donation-card
button[id^="button_cart_one_"] i {
    display: none !important;
}

.ksr-v2-native .ksr-v2-donation-card
button[id^="button_cart_one_"]::after {
    content: "إضافة إلى السلة";
    font-size: 14px;
}

html[lang^="en"] .ksr-v2-native .ksr-v2-donation-card
button[id^="button_cart_one_"]::after {
    content: "Add to Cart";
}

.ksr-v2-native .ksr-v2-donation-card
.button-items > .ty-btn__donate,
.ksr-v2-native .ksr-v2-donation-card
.button-items > :has(.ty-btn__donate) {
    order: -1 !important;
}

.ksr-v2-native .ksr-v2-donation-card
.button-items > button[id^="button_cart_one_"],
.ksr-v2-native .ksr-v2-donation-card
.button-items > :has(button[id^="button_cart_one_"]) {
    order: 1 !important;
}

.ksr-v2-native .ksr-v2-donation-card
.cp-default-prices-button[data-ksr-price-match="true"] {
    background: #df493e !important;
    border-color: #df493e !important;
    color: #fff !important;
}


/* KSR_V2_MOBILE_POLISH_V1 */

/* The legacy description tab is duplicated by V2's About section.
   Keep all other CS-Cart tabs and the original tab system intact. */
.ksr-v2-native .ty-tabs__item#description,
body:has(.ksr-v2-native) .ty-tabs__list > li#description {
    display: none !important;
}

/* Hide only the duplicated description panel. */
.ksr-v2-native #content_description,
.ksr-v2-native .ty-tabs__content:has(> #content_description) {
    display: none !important;
}

/* On mobile, use clean surfaces without donation-card shadows.
   Do not affect buttons, inputs, selected states or submit actions. */
@media (max-width: 767px) {
    .ksr-v2-native .ksr-v2-donation-card,
    .ksr-v2-native .ksr-v2-donation-card .cp-product-detail__control,
    .ksr-v2-native .ksr-v2-donation-card .cp-product-detail__price,
    .ksr-v2-native .ksr-v2-donation-card .cp-default-prices,
    .ksr-v2-native .ksr-v2-donation-card .cp-default-prices__element,
    .ksr-v2-native .ksr-v2-donation-card .cp-default-prices-button,
    .ksr-v2-native .ksr-v2-donation-card .ty-price-curency__input-wrap,
    .ksr-v2-native .ksr-v2-donation-card .cp-product-detail__buttons {
        box-shadow: none !important;
        -webkit-box-shadow: none !important;
        filter: none !important;
    }
}


/* KSR_V2_MOBILE_FIX_V2 */

/* Hide only the legacy CS-Cart description tab in V2. */
.ksr-v2-native .ty-tabs__list > li#description,
body:has(.ksr-v2-native) .ty-tabs__list > li#description {
    display: none !important;
}

/* The complete description is already rendered in V2 About. */
.ksr-v2-native #content_description,
body:has(.ksr-v2-native) #content_description,
body:has(.ksr-v2-native)
.ty-tabs__content:has(> #content_description) {
    display: none !important;
}

/* Remove mobile donation shadow effects without touching actions. */
@media (max-width: 767px) {
    .ksr-v2-native .ksr-v2-donation-card,
    .ksr-v2-native .ksr-v2-donation-card
    .cp-product-detail__control,
    .ksr-v2-native .ksr-v2-donation-card
    .cp-product-detail__price,
    .ksr-v2-native .ksr-v2-donation-card
    .cp-default-prices,
    .ksr-v2-native .ksr-v2-donation-card
    .cp-default-prices__element,
    .ksr-v2-native .ksr-v2-donation-card
    .cp-default-prices-button,
    .ksr-v2-native .ksr-v2-donation-card
    .ty-price-curency__input-wrap,
    .ksr-v2-native .ksr-v2-donation-card
    .cp-product-detail__buttons {
        box-shadow: none !important;
        -webkit-box-shadow: none !important;
        filter: none !important;
        -webkit-backdrop-filter: none !important;
        backdrop-filter: none !important;
    }
}
