/* Aynı parçaya işlem ekle + "aynı ürün için mi?" (web). JS: assets/js/sepet-parca.js */
:root {
    --ap-kirmizi: #e52628;
    --ap-lacivert: #14213d;
    --ap-metin: #1f2937;
    --ap-soluk: #64748b;
    --ap-cizgi: #e5e7eb;
    --ap-zemin: #f8fafc;
}

/* ── Düğmeler ─────────────────────────────────────────────── */
.ap-dugme {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 12px;
    border: 1px solid transparent;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: background .15s ease, border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.ap-dugme:disabled { opacity: .5; cursor: not-allowed; }
.ap-dugme--ana { background: var(--ap-kirmizi); color: #fff; box-shadow: 0 6px 16px rgba(229, 38, 40, .22); }
.ap-dugme--ana:not(:disabled):hover { background: #c81e20; transform: translateY(-1px); }
.ap-dugme--ikincil { background: #fff; color: var(--ap-metin); border-color: var(--ap-cizgi); }
.ap-dugme--ikincil:hover { border-color: #cbd5e1; background: var(--ap-zemin); }

/* ── Soru penceresi (SweetAlert) ──────────────────────────── */
.ap-soru-pencere { border-radius: 20px !important; padding: 28px 24px 22px !important; }
.ap-soru-pencere .swal2-title { font-size: 21px; color: var(--ap-lacivert); padding: 0 8px; }
.ap-soru-pencere .swal2-actions { gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.ap-soru-pencere .swal2-actions .ap-dugme { margin: 0; }
.ap-cift { display: flex; align-items: stretch; justify-content: center; gap: 10px; margin: 6px 0 14px; }
.ap-cift__kalem {
    flex: 1 1 0;
    max-width: 190px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px 10px;
    border: 1px solid var(--ap-cizgi);
    border-radius: 14px;
    background: var(--ap-zemin);
    font-size: 13px;
    font-weight: 700;
    color: var(--ap-metin);
    line-height: 1.35;
}
.ap-cift__resim {
    width: 54px; height: 54px; border-radius: 12px; overflow: hidden;
    display: grid; place-items: center; background: #fff; color: var(--ap-soluk); font-size: 22px;
}
.ap-cift__resim img { width: 100%; height: 100%; object-fit: cover; }
.ap-cift__arti { align-self: center; font-size: 22px; font-weight: 800; color: var(--ap-kirmizi); }
.ap-soru-not { margin: 0; color: var(--ap-soluk); font-size: 13.5px; line-height: 1.55; }

/* ── İşlem ekle penceresi ─────────────────────────────────── */
.ap-modal .modal-content { border: 0; border-radius: 20px; overflow: hidden; box-shadow: 0 24px 60px rgba(15, 23, 42, .22); }
.ap-modal__bas { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px 22px 14px; border-bottom: 1px solid var(--ap-cizgi); }
.ap-ust { font-size: 11.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ap-kirmizi); display: flex; gap: 6px; align-items: center; }
.ap-modal__baslik { margin: 6px 0 4px; font-size: 19px; font-weight: 800; color: var(--ap-lacivert); }
.ap-modal__aciklama { margin: 0; font-size: 13px; color: var(--ap-soluk); line-height: 1.5; }
.ap-modal__govde { padding: 16px 22px; }
.ap-modal { z-index: 100000; }
.ap-ipucu { margin: 0; padding: 10px 22px; font-size: 12.5px; color: #92400e; background: #fffbeb; border-top: 1px solid #fde68a; line-height: 1.5; }
.ap-ipucu i { margin-right: 6px; }
.ap-modal__alt { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px 18px; border-top: 1px solid var(--ap-cizgi); background: #fff; }
.ap-modal__alt .ap-ekle { min-width: 170px; }

.ap-ara-kutu { position: relative; margin-bottom: 12px; }
.ap-ara-kutu i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--ap-soluk); font-size: 14px; }
.ap-ara { width: 100%; height: 44px; padding: 0 14px 0 38px; border: 1px solid var(--ap-cizgi); border-radius: 12px; font-size: 14px; }
.ap-ara:focus { outline: none; border-color: var(--ap-kirmizi); box-shadow: 0 0 0 3px rgba(229, 38, 40, .12); }

.ap-liste { display: grid; gap: 8px; }
.ap-secenek {
    display: grid;
    grid-template-columns: 20px 1fr auto;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid var(--ap-cizgi);
    border-radius: 14px;
    text-align: left;
    cursor: pointer;
    transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.ap-secenek:hover { border-color: #cbd5e1; background: var(--ap-zemin); }
.ap-secenek.is-secili { border-color: var(--ap-kirmizi); background: #fff6f6; box-shadow: 0 0 0 3px rgba(229, 38, 40, .10); }
.ap-secenek__isaret { width: 20px; height: 20px; border-radius: 50%; border: 2px solid #cbd5e1; position: relative; }
.ap-secenek.is-secili .ap-secenek__isaret { border-color: var(--ap-kirmizi); }
.ap-secenek.is-secili .ap-secenek__isaret::after { content: ""; position: absolute; inset: 3px; border-radius: 50%; background: var(--ap-kirmizi); }
.ap-secenek__ad { font-weight: 700; font-size: 14px; color: var(--ap-metin); line-height: 1.35; }
.ap-secenek__ad small { display: block; margin-top: 2px; font-weight: 600; font-size: 11.5px; color: var(--ap-soluk); }
.ap-secenek__fiyat { font-weight: 800; font-size: 14px; color: var(--ap-lacivert); white-space: nowrap; text-align: right; }
.ap-secenek__fiyat s { display: block; font-weight: 600; font-size: 11.5px; color: var(--ap-soluk); }
.ap-bos { padding: 18px; text-align: center; color: var(--ap-soluk); font-size: 13.5px; border: 1px dashed var(--ap-cizgi); border-radius: 14px; }

.ap-adet { margin-bottom: 14px; padding: 14px; border-radius: 14px; background: var(--ap-zemin); border: 1px solid var(--ap-cizgi); }
.ap-adet__baslik { font-size: 13.5px; font-weight: 700; color: var(--ap-metin); margin-bottom: 10px; }
.ap-seg { display: inline-flex; padding: 3px; border-radius: 12px; background: #e9eef5; gap: 3px; }
.ap-seg button { border: 0; background: transparent; padding: 8px 14px; border-radius: 9px; font-weight: 700; font-size: 13px; color: var(--ap-soluk); cursor: pointer; }
.ap-seg button.is-aktif { background: #fff; color: var(--ap-lacivert); box-shadow: 0 2px 6px rgba(15, 23, 42, .08); }
.ap-sayac { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.ap-sayac strong { min-width: 28px; text-align: center; font-size: 18px; color: var(--ap-lacivert); }
.ap-sayac span { color: var(--ap-soluk); font-size: 13px; }
.ap-adim { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--ap-cizgi); background: #fff; font-size: 18px; font-weight: 800; color: var(--ap-metin); cursor: pointer; }
.ap-adim:disabled { opacity: .4; cursor: not-allowed; }
.ap-adet__not { margin: 10px 0 0; font-size: 12.5px; color: var(--ap-soluk); line-height: 1.5; }

@media (max-width: 575px) {
    .ap-modal .modal-dialog { margin: 0; align-items: flex-end; min-height: 100%; }
    .ap-modal .modal-content { border-radius: 20px 20px 0 0; max-height: 92vh; }
    .ap-modal__alt { flex-direction: column-reverse; }
    .ap-modal__alt .ap-dugme { width: 100%; }
    .ap-soru-pencere .swal2-actions { flex-direction: column-reverse; width: 100%; }
    .ap-soru-pencere .swal2-actions .ap-dugme { width: 100%; }
}

/* Bölüm başlıkları (aynı parça / başka bölüm — ayrı etiket) */
.ap-bolum { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 10px 2px 2px; }
.ap-bolum:first-child { margin-top: 0; }
.ap-bolum__ad { font-weight: 800; font-size: 13px; color: var(--ap-lacivert); text-transform: uppercase; letter-spacing: .04em; }
.ap-bolum__rozet { font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 999px; background: #fff4e5; color: #9a4d04; }
.ap-bolum__rozet--ayni { background: #eef2ff; color: var(--ap-lacivert); }
.ap-bolum small { flex-basis: 100%; color: var(--ap-soluk); font-size: 12px; }
.ap-grup { margin: 6px 2px 0; font-size: 12px; font-weight: 700; color: var(--ap-soluk); }
