/* Shofy — platform entegrasyonu (sepet / seçenek modalları). Görsel tema: assets/css/main.css */

body.theme-shofy .cartmini__area {
    z-index: 10001;
}

body.theme-shofy .body-overlay.opened {
    z-index: 10000;
}

body.theme-shofy #kf-product-options-modal.kf-options-modal,
body.theme-shofy .site-popup-overlay {
    z-index: 100050;
}

body.theme-shofy .kf-options-modal__dialog,
body.theme-shofy .site-popup-main {
    font-family: inherit;
}

body.kf-modal-open.theme-shofy {
    overflow: hidden;
}

/* Ürün seçenekleri — sepete ekle modal */
body.theme-shofy #kf-product-options-modal.kf-options-modal {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.22s ease, visibility 0.22s ease;
}

body.theme-shofy #kf-product-options-modal.kf-options-modal.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(1, 15, 28, 0.55);
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__dialog {
    position: relative;
    width: min(520px, 100%);
    max-height: min(90vh, 720px);
    overflow: auto;
    background: var(--tp-common-white, #fff);
    border-radius: 12px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18);
    padding: 20px;
    outline: none;
    z-index: 1;
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 50%;
    background: var(--tp-grey-1, #f4f7f9);
    color: var(--tp-text-body, #55585b);
    cursor: pointer;
    z-index: 2;
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__product {
    display: flex;
    gap: 14px;
    align-items: center;
    margin-bottom: 16px;
    padding-right: 36px;
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__image {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__title {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 4px;
    line-height: 1.3;
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__link {
    font-size: 13px;
    color: var(--tp-theme-primary, #0989ff);
    text-decoration: none;
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__footer {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px 16px;
    align-items: end;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid var(--tp-border-1, #eaeaea);
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__submit {
    grid-column: 1 / -1;
    width: 100%;
    padding: 12px 18px;
    border: none;
    border-radius: 6px;
    background: var(--tp-theme-primary, #0989ff);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

body.theme-shofy #kf-product-options-modal .kf-options-modal__submit:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

body.theme-shofy #kf-product-options-modal.is-loading .kf-options-modal__fields {
    opacity: 0.5;
    pointer-events: none;
}

body.theme-shofy .product-card .tp-product-tooltip {
    pointer-events: none;
}

.theme-shofy .cartmini__empty img {
    max-width: 120px;
    height: auto;
}

.theme-shofy .include-bg {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.theme-shofy .breadcrumb__area.include-bg {
    background-image: none;
    background-color: var(--tp-common-white, #fff);
}

.theme-shofy .tp-shop-widget-search {
    position: relative;
}

.theme-shofy .tp-shop-widget-search input[type="search"] {
    width: 100%;
    padding-right: 44px;
}

.theme-shofy .tp-shop-widget-search button {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    padding: 8px 12px;
    line-height: 1;
}

.theme-shofy .tp-product-category-thumb img,
.theme-shofy .tp-slider-thumb img {
    max-height: 420px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
}

.theme-shofy .tp-product-details-thumb-wrapper .tp-product-details-nav-main-thumb img {
    max-height: none;
    width: 100%;
    height: auto;
    object-fit: contain;
}

.theme-shofy .tp-product-details-thumb-wrapper .nav-tabs .nav-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.theme-shofy .sf-product-details-excerpt img {
    max-width: 100%;
    height: auto;
}

.theme-shofy .kf-product-option-btn.is-disabled,
.theme-shofy .tp-color-variation-btn:disabled,
.theme-shofy .tp-size-variation-btn:disabled {
    opacity: 0.45;
    pointer-events: none;
}

.theme-shofy .tp-product-details-variation-list .kf-product-option-btn.active,
.theme-shofy .tp-product-details-variation-list .tp-size-variation-btn.active,
.theme-shofy .tp-product-details-variation-list label.tp-size-variation-btn.sf-label-active {
    border-color: var(--tp-theme-primary, #0989ff);
    background-color: var(--tp-theme-primary, #0989ff);
    color: #fff;
}

/* Ürün detay: adet butonları — stok sınırında solu/devre dışı durumu */
.theme-shofy .tp-product-quantity .tp-cart-minus.sf-qty-at-min,
.theme-shofy .tp-product-quantity .tp-cart-plus.sf-qty-at-max {
    opacity: 0.35;
    cursor: not-allowed;
    pointer-events: none;
}

/* Radio tipi seçenekler: etiket seçili olduğunda görsel geri bildirim (CSS-only) */
.theme-shofy .tp-product-details-variation-list input[type="radio"]:checked + label.tp-size-variation-btn {
    border-color: var(--tp-theme-primary, #0989ff);
    background-color: var(--tp-theme-primary, #0989ff);
    color: #fff;
}
.theme-shofy .tp-product-details-variation-list input[type="radio"]:checked + label.tp-color-variation-btn,
.theme-shofy .tp-product-details-variation-list input[type="radio"]:checked + label.color {
    border-color: var(--tp-theme-primary, #0989ff);
    box-shadow: 0 0 0 2px var(--tp-theme-primary, #0989ff);
}

/* Sepet / ödeme — platform formları */
body.theme-shofy .tp-checkout-area .checkout-customer-type__title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
}

body.theme-shofy .tp-checkout-area .checkout-customer-type__choices {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 20px;
    margin-bottom: 16px;
}

body.theme-shofy .tp-checkout-shipping-wrap .shipping-method-wrapper {
    margin-top: 0 !important;
}

body.theme-shofy .tp-checkout-shipping-wrap .shipping-method-wrapper .title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 12px;
}

body.theme-shofy .tp-checkout-shipping-wrap .checkout-shipping-option {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid var(--tp-border-primary, #eaeaea);
    cursor: pointer;
    margin: 0;
}

body.theme-shofy .tp-checkout-shipping-wrap .checkout-shipping-option.is-selected {
    color: var(--tp-theme-primary, #0989ff);
}

body.theme-shofy .tp-checkout-agree .kf-checkout-agreements {
    margin: 0;
}

body.theme-shofy .tp-checkout-agree .kf-checkout-agreement {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    line-height: 1.5;
    cursor: pointer;
}

body.theme-shofy .tp-cart-area .alert {
    border-radius: 8px;
}

body.theme-shofy .tp-checkout-area .alert {
    border-radius: 8px;
}

body.theme-shofy .tp-checkout-verify-reveal .tp-checkout-login-form-reveal-btn,
body.theme-shofy .tp-checkout-verify-reveal .tp-checkout-coupon-form-reveal-btn {
    color: var(--tp-theme-primary, #0989ff);
    text-decoration: underline;
    font-weight: 500;
}

/* Sepet sayfası — cart.html hizası */
body.theme-shofy.page-cart .tp-cart-quantity form.os-cart-qty-form {
    margin: 0;
}

body.theme-shofy.page-cart .tp-cart-action-btn {
    border: 0;
    background: transparent;
    padding: 0;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

body.theme-shofy.page-cart .tp-cart-list .table {
    margin-bottom: 0;
}

body.theme-shofy.page-cart .sf-cart-list-price-old {
    display: block;
    font-size: 13px;
    color: #818487;
    margin-top: 4px;
}

body.theme-shofy.page-cart .sf-cart-summary-lines .sf-cart-summary-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 14px;
    color: #161c2d;
    padding: 4px 0;
}

body.theme-shofy.page-cart .sf-cart-summary-lines .sf-cart-summary-line.is-discount {
    color: var(--tp-theme-primary, #0989ff);
}

body.theme-shofy.page-cart .tp-header-search-2 button {
    border: 0;
    background: transparent;
    padding: 0;
    line-height: 1;
    color: inherit;
}

body.theme-shofy.page-cart .tp-cart-coupon-input input {
    border-radius: 0;
}

body.theme-shofy.page-cart .tp-cart-update-btn {
    display: inline-block;
    text-decoration: none;
}

body.theme-shofy.page-cart .os-cart-campaigns small {
    font-size: 13px;
}

body.theme-shofy.page-cart .tp-cart-option {
    font-size: 14px;
    color: #818487;
}

body.theme-shofy.page-cart .sf-cart-fee-line {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 14px;
    padding: 6px 0 6px 25px;
    color: #161c2d;
}

body.theme-shofy.page-login .tp-login-area .alert,
body.theme-shofy.page-register .tp-login-area .alert {
    border-radius: 8px;
    text-align: left;
}

body.theme-shofy .tp-header-top-menu-item ul {
    z-index: 100;
}
