/* "Hemen Sipariş Ver" (B2B_Tanimlar.AnindaSiparisAktif): düğmeler (_InstantOrderButton) + modal (instant-order.js).
   Yalnız ayar açık tenantta _Layout yükler. Düğme sepet düğmesinden ayrışsın diye koyu çerçeveli; modalda gönder
   düğmesi marka renginde, yazı --on-primary (sarı zeminde koyu, koyu zeminde beyaz). */

.io-open {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    min-height: 38px;
    margin-top: 8px;
    padding: 6px 12px;
    border: 2px solid #1f2329;
    border-radius: var(--r-10, 10px);
    background: #fff;
    color: #1f2329;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
    transition: background-color .15s ease, color .15s ease;
}
.io-open:hover, .io-open:focus-visible { background: #1f2329; color: #fff; }
.io-open:focus-visible { outline: 3px solid var(--primaryColor); outline-offset: 2px; }
.io-open i { font-size: 14px; }

/* Ürün detayı: sepete ekle düğmesiyle aynı boy (product-detail-cart-btn sınıfıyla gelir), çerçeveli görünüm korunur */
.product-detail-cart-btn.io-open--detail {
    margin-top: 0;
    background: #fff !important;
    color: #1f2329 !important;
    border: 2px solid #1f2329 !important;
}
.product-detail-cart-btn.io-open--detail:hover,
.product-detail-cart-btn.io-open--detail:focus-visible { background: #1f2329 !important; color: #fff !important; }

/* Liste satırı: yer dar → yuvarlak simge düğmesi, yazı ekran okuyucuya */
.io-open--list {
    width: 46px;
    min-height: 46px;
    height: 46px;
    margin: 6px 0 0;
    padding: 0;
    border-radius: 50%;
}
.io-open--list span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.io-open--list i { font-size: 18px; }

/* Son alınanlar paneli: "Tekrar Al" yanında küçük */
.io-open--recent { width: auto; min-height: 34px; margin: 0 0 0 6px; padding: 4px 10px; font-size: 13px; }
@media (max-width: 575.98px) {
    .io-open--recent span { display: none; }
}

/* Modal */
.io-dialog {
    width: min(420px, calc(100vw - 24px));
    max-height: calc(100vh - 24px);
    padding: 0;
    border: 0;
    border-radius: var(--r-16, 16px);
    background: #fff;
    color: #1f2329;
    box-shadow: 0 16px 48px rgba(0, 0, 0, .3);
    overflow: auto;
}
.io-dialog::backdrop { background: rgba(15, 17, 20, .55); }
.io-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; background: var(--primaryColor); color: var(--on-primary, #fff); }
.io-title { margin: 0; font-size: 18px; font-weight: 700; color: inherit; }
.io-close { width: 34px; height: 34px; border: 0; background: transparent; color: inherit; font-size: 18px; cursor: pointer; }
.io-close:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.io-body, .io-done { padding: 16px; }
.io-body[hidden], .io-done[hidden] { display: none; }
.io-product { margin: 0 0 14px; font-size: 15px; font-weight: 700; line-height: 1.35; color: #1f2329; }
.io-label { display: block; margin: 10px 0 4px; font-size: 13px; font-weight: 600; color: #1f2329; }
.io-input {
    display: block;
    width: 100%;
    min-height: 44px;
    padding: 0 12px;
    border: 1px solid #c9cdd4;
    border-radius: var(--r-10, 10px);
    background: #fff;
    color: #1f2329;
    font-size: 16px;
}
.io-input:focus, .io-qty-input:focus { outline: 2px solid var(--primaryColor); outline-offset: 1px; border-color: transparent; }
.io-qty { display: inline-flex; align-items: stretch; border: 1px solid #c9cdd4; border-radius: 999px; overflow: hidden; }
.io-step { width: 44px; border: 0; background: #eef0f3; color: #1f2329; font-size: 20px; font-weight: 700; cursor: pointer; }
.io-step:focus-visible { outline: 2px solid #1f2329; outline-offset: -2px; }
.io-qty-input { width: 64px; min-height: 42px; border: 0; text-align: center; font-size: 16px; font-weight: 700; color: #1f2329; -moz-appearance: textfield; }
.io-qty-input::-webkit-outer-spin-button, .io-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
/* Ödeme seçimi (KapidaOdemeAktif): iki seçenek yan yana kutu; seçili kutu koyu çerçeve */
.io-pay { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0; padding: 0; border: 0; min-width: 0; }
.io-pay legend { grid-column: 1 / -1; float: none; width: auto; padding: 0; }
.io-pay-opt {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 12px;
    border: 1px solid #c9cdd4;
    border-radius: var(--r-10, 10px);
    background: #fff;
    color: #1f2329;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}
.io-pay-opt input { width: 18px; height: 18px; margin: 0; accent-color: #1f2329; }
.io-pay-opt i { font-size: 15px; color: #4a515b; }
.io-pay-opt:has(input:checked) { border: 2px solid #1f2329; padding: 0 11px; }
.io-pay-opt:has(input:focus-visible) { outline: 2px solid var(--primaryColor); outline-offset: 2px; }
.io-note { margin: 14px 0 0; font-size: 12px; line-height: 1.45; color: #4a515b; }
.io-msg { min-height: 18px; margin: 8px 0 0; font-size: 13px; font-weight: 600; color: #b42318; }
.io-msg:empty { min-height: 0; margin: 0; }
.io-send {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 48px;
    margin-top: 12px;
    border: 0;
    border-radius: var(--r-10, 10px);
    background: var(--mgz-cta-bg, var(--primaryColor));
    color: var(--mgz-cta-fg, var(--on-primary, #fff));
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
}
.io-send:disabled { opacity: .6; cursor: default; }
.io-send:focus-visible { outline: 3px solid #1f2329; outline-offset: 2px; }
.io-done { text-align: center; }
.io-done-icon { font-size: 48px; color: #15803d; }
.io-done-text { margin: 8px 0 0; font-size: 15px; line-height: 1.45; color: #1f2329; }
.io-hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
@media (prefers-reduced-motion: reduce) {
    .io-open { transition: none; }
}
