.ust-sepet {
    position: relative;
    margin-inline-start: clamp(6px, .9vw, 16px);
}
.ust-sepet-baglantisi {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    gap: 11px;
    padding: 4px 7px;
    border-radius: 10px;
    color: var(--yazi);
}
.ust-sepet-baglantisi:is(:hover, [aria-expanded="true"]) {
    background: #f1f8f3;
    color: #185d36;
}
.ust-sepet-simgesi {
    position: relative;
    display: inline-flex;
    flex-shrink: 0;
}
.ust-sepet-simgesi > img { display: block; width: 26px; height: 26px; }
.ust-sepet-adedi {
    position: absolute;
    inset: -5px -5px auto auto;
    display: grid;
    place-items: center;
    min-width: 16px;
    height: 16px;
    padding-inline: 3px;
    border: 1.5px solid #fff;
    border-radius: 20px;
    color: #fff;
    background: #087e35;
    font-size: 9px;
    line-height: 1;
    font-weight: 750;
    font-variant-numeric: tabular-nums;
}
.ust-sepet-etiketi { display: grid; gap: 2px; text-align: start; line-height: 1.18; }
.ust-sepet-etiketi strong { font-size: 13px; font-weight: 675; }
.ust-sepet-tutari { color: #116b39; font-size: 12px; font-weight: 680; white-space: nowrap; }

.ust-sepet-menusu {
    --sepet-boslugu: 16px;
    position: absolute;
    z-index: 125;
    inset: calc(100% + 6px) 0 auto auto;
    display: flex;
    flex-direction: column;
    width: min(365px, calc(100vw - 32px));
    max-height: min(570px, calc(100vh - 100px));
    max-height: min(570px, calc(100dvh - 100px));
    overflow: auto;
    overscroll-behavior: contain;
    border: 1px solid #d7e3da;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 12px 35px #0d3b221f, 0 2px 6px #183f2714;
    color: var(--yazi);
    text-align: start;
}
.ust-sepet-menusu[hidden] { display: none; }
.ust-sepet:has(.ust-sepet-menusu:not([hidden]))::after {
    content: "";
    position: absolute;
    inset: 100% 0 auto 0;
    height: 7px;
    z-index: 124;
}
.ust-sepet-basligi {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 9px var(--sepet-boslugu);
    border-bottom: 1px solid #e5ece7;
}
.ust-sepet-basligi h2 { font-size: 17px; line-height: 1.3; letter-spacing: -.025em; }
.ust-sepet-kapat {
    display: grid;
    place-items: center;
    flex: none;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    background: #f3f6f4;
    border-radius: 50%;
}
.ust-sepet-kapat:hover { background: #e8f1eb; }
.ust-sepet-urunleri {
    flex: 0 1 auto;
    min-height: 60px;
    margin: 0;
    padding: 0 var(--sepet-boslugu);
    overflow-y: auto;
    overscroll-behavior: contain;
    list-style: none;
    scrollbar-width: thin;
}
.ust-sepet-urunleri li + li { border-top: 1px solid #e8ede9; }
.ust-sepet-urunu {
    display: grid;
    grid-template-columns: 60px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    padding-block: 12px;
    color: inherit;
}
.ust-sepet-urunu > img {
    width: 60px;
    height: 62px;
    padding: 4px;
    object-fit: contain;
    background: #fafcfb;
    border: 1px solid #e6ece8;
    border-radius: 10px;
}
.ust-sepet-urun-bilgisi { display: grid; gap: 3px; min-width: 0; overflow-wrap: anywhere; }
.ust-sepet-urun-bilgisi > strong { font-size: 13px; line-height: 1.32; font-weight: 660; }
.ust-sepet-urun-bilgisi > small, .ust-sepet-satir-ozeti { font-size: 12px; color: #56655c; }
.ust-sepet-urunu:hover .ust-sepet-urun-bilgisi > strong { color: #096e35; text-decoration: underline; }
.ust-sepet-satir-ozeti, .ust-sepet-ayrinti, .ust-sepet-toplami {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 2px 12px;
}
.ust-sepet-satir-ozeti { margin-top: 2px; }
.ust-sepet-satir-ozeti b { color: #16492e; font-size: 13px; }
.ust-sepet-alt { flex: none; padding: 12px var(--sepet-boslugu) var(--sepet-boslugu); border-top: 1px solid #e0e9e3; }
.ust-sepet-ayrinti { margin-bottom: 5px; color: #53645a; font-size: 12px; }
.ust-sepet-toplami { font-weight: 650; }
.ust-sepet-toplami strong { color: #116434; font-size: 18px; font-variant-numeric: tabular-nums; }
.ust-sepet-menusu .ust-sepet-git { display: flex; width: 100%; min-height: 44px; margin-top: 12px; }
.ust-sepet-bos {
    display: grid;
    justify-items: center;
    gap: 11px;
    padding: 24px var(--sepet-boslugu);
    text-align: center;
}
.ust-sepet-bos img {
    box-sizing: content-box;
    width: 30px;
    height: 30px;
    padding: 12px;
    border-radius: 50%;
    background: #edf7ef;
}
.ust-sepet-bos strong { font-size: 15px; }
.ust-sepet-alt .ust-sepet-git:first-child { margin-top: 0; }
.ust-sepet :is(a, button):focus-visible { outline: 2px solid #177644; outline-offset: -2px; }

@media (max-width: 767px), (pointer: coarse) and (max-width: 1024px) {
    .magaza-ic-sayfa .baslik-ust {
        grid-template-columns: 44px minmax(0, 1fr) auto auto;
        grid-template-areas: "geri logo islemler sepet" "arama arama arama arama";
        column-gap: 4px;
    }
    .magaza-ic-sayfa .baslik-islemler { display: flex; grid-area: sepet; }
    .magaza-ic-sayfa .baslik-islemler > :not(.ust-sepet) { display: none; }
    .ust-sepet { margin-inline-start: 0; }
    .ust-sepet-baglantisi { flex-direction: column; justify-content: center; gap: 2px; min-width: 44px; padding: 4px; }
    .ust-sepet-simgesi > img { width: 22px; height: 22px; }
    .ust-sepet-etiketi { justify-items: center; }
    .ust-sepet-etiketi strong { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); overflow: hidden; }
    .ust-sepet-tutari { font-size: 11px; line-height: 1.18; }
    .ust-sepet-menusu {
        max-height: calc(100vh - 124px - var(--mobil-menu-yuksekligi, 68px));
        max-height: calc(100dvh - 124px - var(--mobil-menu-yuksekligi, 68px));
    }
    .ust-sepet-kapat { width: 44px; height: 44px; }
    .ust-sepet-basligi { padding-block: 4px; }
}
@media (max-height: 500px) {
    .ust-sepet-menusu { max-height: calc(100dvh - 70px - var(--mobil-menu-yuksekligi, 0px)); }
    .ust-sepet-urunleri { flex: none; overflow: visible; }
}
