/**
 * Mağaza doping — RGB/glow çerçeveler (header, ilan kartı, profil, ilan detay)
 * Profil büyük avatar KARE; ilan kartı / ilan detay KARE; header YUVARLAK.
 */

/* ── Listing / header mini avatar ── */
.seller-avatar-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border-radius: 50%;
    box-sizing: border-box;
}

.seller-avatar-wrap .seller-avatar,
.seller-avatar-wrap .avatar-image,
.seller-avatar-wrap .package-frame-inner img,
.satici-avatar-wrap .satici-avatar-big,
.satici-avatar-wrap img {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    position: relative;
    z-index: 1;
}

.seller-avatar-wrap .package-frame-inner,
.satici-avatar-wrap .package-frame-inner {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
}

.card-seller .seller-avatar-wrap {
    width: 24px;
    height: 24px;
}

/* Kurumsal Plus — animasyonlu RGB halka */
.frame-kurumsal-plus {
    position: relative;
    padding: 3px;
    border-radius: 50%;
    background: transparent;
    overflow: hidden;
    box-shadow:
        0 0 14px rgba(255, 0, 128, 0.45),
        0 0 28px rgba(0, 112, 243, 0.32);
}

.frame-kurumsal-plus::before {
    content: '';
    position: absolute;
    inset: -40%;
    z-index: 0;
    background: conic-gradient(from 0deg, #ff0080, #7928ca, #0070f3, #00dfd8, #ff0080);
    animation: framePlusRgbSpin 2.8s linear infinite;
}

@keyframes framePlusRgbSpin {
    to {
        transform: rotate(360deg);
    }
}

.frame-kurumsal-plus .seller-avatar,
.frame-kurumsal-plus .avatar-image,
.frame-kurumsal-plus .package-frame-inner .avatar-image,
.frame-kurumsal-plus .package-frame-inner img,
.frame-kurumsal-plus img,
.frame-kurumsal-plus .satici-avatar-big {
    border: none;
    border-radius: 50%;
    background: transparent;
}

.frame-kurumsal-plus .package-frame-inner {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    background: transparent;
}

/* Kurumsal Üye — gold / mor animasyonlu halka (Plus ile aynı yapı) */
.frame-kurumsal-uye {
    position: relative;
    padding: 3px;
    border-radius: 50%;
    background: transparent;
    overflow: hidden;
    box-shadow:
        0 0 14px rgba(251, 191, 36, 0.5),
        0 0 28px rgba(168, 85, 247, 0.35);
    animation: frameUyePulse 2.4s ease-in-out infinite;
}

.frame-kurumsal-uye::before {
    content: '';
    position: absolute;
    inset: -40%;
    z-index: 0;
    background: conic-gradient(from 0deg, #fbbf24, #f59e0b, #a855f7, #d946ef, #fcd34d, #fbbf24);
    animation: framePlusRgbSpin 3.2s linear infinite;
}

.frame-kurumsal-uye .seller-avatar,
.frame-kurumsal-uye .avatar-image,
.frame-kurumsal-uye .package-frame-inner .avatar-image,
.frame-kurumsal-uye .package-frame-inner img,
.frame-kurumsal-uye img,
.frame-kurumsal-uye .satici-avatar-big {
    border: none;
    border-radius: 50%;
    background: transparent;
}

.frame-kurumsal-uye .package-frame-inner {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    background: transparent;
}

@keyframes frameUyePulse {
    0%,
    100% {
        box-shadow:
            0 0 10px rgba(251, 191, 36, 0.45),
            0 0 20px rgba(168, 85, 247, 0.28);
    }
    50% {
        box-shadow:
            0 0 16px rgba(251, 191, 36, 0.75),
            0 0 32px rgba(168, 85, 247, 0.48);
    }
}

/* Header hesap tetikleyici — yuvarlak, ince RGB halka */
.header-account-trigger__avatar.seller-avatar-wrap {
    flex: 0 0 42px;
    width: 42px;
    height: 42px;
    overflow: hidden;
    border-radius: 50%;
}

.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-plus,
.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-uye {
    background: transparent !important;
    flex: 0 0 42px;
    width: 42px;
    height: 42px;
    padding: 3px !important;
    border-radius: 50% !important;
    overflow: hidden;
}

.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-plus {
    box-shadow:
        0 0 14px rgba(255, 0, 128, 0.45),
        0 0 28px rgba(0, 112, 243, 0.32);
}

.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-uye {
    box-shadow:
        0 0 14px rgba(251, 191, 36, 0.5),
        0 0 28px rgba(168, 85, 247, 0.35);
}

.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-plus::before,
.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-uye::before {
    border-radius: 50%;
    display: block;
    animation: framePlusRgbSpin 2.8s linear infinite;
}

.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-uye::before {
    animation-duration: 3.2s;
}

.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-plus .package-frame-inner,
.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-uye .package-frame-inner {
    width: 100%;
    height: 100%;
    border-radius: 50% !important;
    overflow: hidden;
}

.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-plus .package-frame-inner .avatar-image,
.header-account-trigger__avatar.seller-avatar-wrap.frame-kurumsal-uye .package-frame-inner .avatar-image {
    width: 100%;
    height: 100%;
    display: block;
    border-radius: 50% !important;
    object-fit: cover;
    object-position: center center;
}

.header-account-trigger__avatar.seller-avatar-wrap .package-frame-inner {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    width: 100%;
    height: 100%;
}

.header-account-trigger__avatar.seller-avatar-wrap .package-frame-inner .avatar-image {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center center;
}

.header-account-trigger__avatar.seller-avatar-wrap:has(img[src*="/avatar/animated/"]),
.header-account-trigger__avatar.seller-avatar-wrap:has(img[src$=".gif"]) {
    flex: 0 0 36px;
    width: 36px;
    height: 36px;
}

@media (max-width: 1024px) {
    .header-account-trigger__avatar.seller-avatar-wrap {
        flex: 0 0 28px;
        width: 28px;
        height: 28px;
    }

    .header-account-trigger__avatar.seller-avatar-wrap:has(img[src*="/avatar/animated/"]),
    .header-account-trigger__avatar.seller-avatar-wrap:has(img[src$=".gif"]) {
        flex: 0 0 30px;
        width: 30px;
        height: 30px;
    }
}

.header-account-trigger__avatar.seller-avatar-wrap img,
.user-menu-hero__avatar.seller-avatar-wrap img,
.header-account-trigger__avatar.seller-avatar-wrap .avatar-image,
.user-menu-hero__avatar.seller-avatar-wrap .avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#userMenuContainer .user-menu-hero__avatar.seller-avatar-wrap.frame-kurumsal-plus,
#userMenuContainer .user-menu-hero__avatar.seller-avatar-wrap.frame-kurumsal-uye {
    border: none !important;
    border-radius: 50% !important;
    overflow: hidden !important;
    box-shadow: none;
    background: transparent !important;
}

#userMenuContainer .user-menu-hero__avatar.seller-avatar-wrap .package-frame-inner .avatar-image {
    object-fit: cover !important;
}

#userMenuContainer .user-menu-hero__avatar.seller-avatar-wrap {
    width: 56px !important;
    height: 56px !important;
    min-width: 56px !important;
    flex: 0 0 56px !important;
}

/* ── Profil sayfası — kare avatar, animasyonlu kenarlık ── */
.profile-page .avatar-container.avatar-container--package-frame,
.profile-page .avatar-container.avatar-container--package-frame.frame-kurumsal-plus,
.profile-page .avatar-container.avatar-container--package-frame.frame-kurumsal-uye {
    position: relative;
    width: 160px;
    height: 160px;
    border-radius: 4px !important;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-sizing: border-box;
    background: transparent !important;
}

.profile-page .avatar-container.frame-kurumsal-plus::before,
.profile-page .avatar-container.frame-kurumsal-uye::before {
    border-radius: 4px;
}

.profile-page .avatar-container.avatar-container--package-frame .package-frame-inner {
    width: 100%;
    height: 100%;
    border-radius: 2px !important;
    overflow: hidden;
    position: relative;
    z-index: 1;
    background: transparent;
}

.profile-page .avatar-container.frame-kurumsal-plus .avatar-image,
.profile-page .avatar-container.frame-kurumsal-uye .avatar-image {
    border: none;
    background: transparent;
}

.profile-page .avatar-container.avatar-container--package-frame.frame-kurumsal-uye {
    animation: frameUyePulse 2.4s ease-in-out infinite;
}

.profile-page .avatar-container.avatar-container--package-frame .avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 2px !important;
}

@media (max-width: 767px) {
    .profile-page .avatar-container.avatar-container--package-frame,
    .profile-page .avatar-container.avatar-container--package-frame.frame-kurumsal-plus,
    .profile-page .avatar-container.avatar-container--package-frame.frame-kurumsal-uye {
        border-radius: 10px !important;
    }

    .profile-page .avatar-container.frame-kurumsal-plus::before,
    .profile-page .avatar-container.frame-kurumsal-uye::before {
        border-radius: 10px;
    }

    .profile-page .avatar-container.avatar-container--package-frame .package-frame-inner,
    .profile-page .avatar-container.avatar-container--package-frame .avatar-image {
        border-radius: 6px !important;
    }
}

/* ── Kare paket çerçevesi — profil ile aynı köşe (ilan kartı, ilan detay, panel) ── */
.card-seller .seller-avatar-wrap.frame-kurumsal-plus,
.card-seller .seller-avatar-wrap.frame-kurumsal-uye {
    border-radius: 6px !important;
    overflow: hidden;
    padding: 2px;
    box-shadow: none;
}

.card-seller .seller-avatar-wrap.frame-kurumsal-plus::before,
.card-seller .seller-avatar-wrap.frame-kurumsal-uye::before {
    border-radius: 6px;
    display: block;
    animation: framePlusRgbSpin 2.8s linear infinite;
}

.card-seller .seller-avatar-wrap.frame-kurumsal-uye::before {
    animation-duration: 3.2s;
}

.card-seller .seller-avatar-wrap.frame-kurumsal-plus .package-frame-inner,
.card-seller .seller-avatar-wrap.frame-kurumsal-uye .package-frame-inner {
    border-radius: 4px !important;
    background: transparent !important;
}

.card-seller .seller-avatar-wrap.frame-kurumsal-plus .seller-avatar,
.card-seller .seller-avatar-wrap.frame-kurumsal-uye .seller-avatar,
.card-seller .seller-avatar-wrap.frame-kurumsal-plus .avatar-image,
.card-seller .seller-avatar-wrap.frame-kurumsal-uye .avatar-image {
    border-radius: 4px !important;
    object-fit: cover;
    background: transparent;
}

.satici-avatar-wrap.frame-kurumsal-plus,
.satici-avatar-wrap.frame-kurumsal-uye {
    border-radius: 8px !important;
    overflow: hidden;
}

.satici-avatar-wrap.frame-kurumsal-plus::before,
.satici-avatar-wrap.frame-kurumsal-uye::before {
    border-radius: 8px;
    display: block;
    animation: framePlusRgbSpin 2.8s linear infinite;
}

.satici-avatar-wrap.frame-kurumsal-uye::before {
    animation-duration: 3.2s;
}

.satici-avatar-wrap.frame-kurumsal-plus .package-frame-inner,
.satici-avatar-wrap.frame-kurumsal-uye .package-frame-inner {
    border-radius: 6px !important;
    background: transparent !important;
}

.satici-avatar-wrap.frame-kurumsal-plus .satici-avatar-big,
.satici-avatar-wrap.frame-kurumsal-uye .satici-avatar-big,
.satici-avatar-wrap.frame-kurumsal-plus img,
.satici-avatar-wrap.frame-kurumsal-uye img {
    border-radius: 6px !important;
    object-fit: cover;
    background: transparent;
}

/* Panel RGB önizleme — yuvarlak, dönen halka */
.sd-frame-demo.seller-avatar-wrap.frame-kurumsal-plus.is-on,
.sd-frame-demo.seller-avatar-wrap.frame-kurumsal-uye.is-on {
    border-radius: 50% !important;
    overflow: hidden;
}

.sd-frame-demo.seller-avatar-wrap.frame-kurumsal-plus.is-on::before,
.sd-frame-demo.seller-avatar-wrap.frame-kurumsal-uye.is-on::before {
    border-radius: 50%;
    display: block !important;
    animation: framePlusRgbSpin 2.8s linear infinite !important;
}

.sd-frame-demo.seller-avatar-wrap.frame-kurumsal-uye.is-on::before {
    animation-duration: 3.2s !important;
}

.sd-frame-demo.seller-avatar-wrap.frame-kurumsal-plus.is-on .package-frame-inner,
.sd-frame-demo.seller-avatar-wrap.frame-kurumsal-uye.is-on .package-frame-inner,
.sd-frame-demo.seller-avatar-wrap.frame-kurumsal-plus.is-on .avatar-image,
.sd-frame-demo.seller-avatar-wrap.frame-kurumsal-uye.is-on .avatar-image {
    border-radius: 50% !important;
}

/* İlan detay — satıcı büyük avatar */
.satici-avatar-wrap {
    position: relative;
    display: inline-flex;
    flex-shrink: 0;
    border-radius: 50%;
    align-items: center;
    justify-content: center;
}

.satici-avatar-wrap.frame-kurumsal-plus,
.satici-avatar-wrap.frame-kurumsal-uye {
    padding: 3px;
}

.satici-avatar-wrap.frame-kurumsal-plus {
    box-shadow: 0 0 16px rgba(255, 0, 128, 0.45), 0 0 32px rgba(0, 112, 243, 0.28);
}

.satici-avatar-wrap.frame-kurumsal-uye {
    animation: frameUyePulse 2.4s ease-in-out infinite;
    box-shadow: 0 0 14px rgba(168, 85, 247, 0.4);
}

.satici-avatar-wrap .satici-avatar-big {
    border-radius: 50%;
    display: block;
    position: relative;
    z-index: 1;
}

.satici-avatar-wrap.frame-kurumsal-plus .satici-avatar-big,
.satici-avatar-wrap.frame-kurumsal-uye .satici-avatar-big {
    border: none;
    background: transparent;
}

.doping-magaza-featured-label {
    background: linear-gradient(90deg, #1d4ed8 0%, #3b82f6 50%, #6366f1 100%) !important;
}

.doping-magaza-featured-label .doping-label-char {
    color: #fff !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

@media (prefers-reduced-motion: reduce) {
    .frame-kurumsal-uye,
    .profile-page .avatar-container.avatar-container--package-frame.frame-kurumsal-uye,
    .satici-avatar-wrap.frame-kurumsal-uye {
        animation: none;
    }

    .frame-kurumsal-uye::before {
        animation: none;
    }
}

/* Profil GIF — kare alanı doldur (üst/alt boşluk kalmasın) */
img.avatar-image[src$=".gif"],
img.avatar-image[src*="/avatar/animated/"],
img.seller-avatar[src$=".gif"],
img.seller-avatar[src*="/avatar/animated/"],
.seller-avatar-wrap img[src$=".gif"],
.seller-avatar-wrap img[src*="/avatar/animated/"],
.satici-avatar-wrap img[src$=".gif"],
.satici-avatar-wrap img[src*="/avatar/animated/"],
.header-account-trigger__avatar img[src$=".gif"],
.header-account-trigger__avatar img[src*="/avatar/animated/"],
#userMenuContainer .user-menu-hero__avatar img[src$=".gif"],
#userMenuContainer .user-menu-hero__avatar img[src*="/avatar/animated/"],
.profile-page .avatar-container .avatar-image[src$=".gif"],
.profile-page .avatar-container .avatar-image[src*="/avatar/animated/"],
.profile-page .avatar-container .frame-preview-avatar-img[src$=".gif"],
.profile-page .avatar-container .frame-preview-avatar-img[src*="/avatar/animated/"] {
    object-fit: cover !important;
    object-position: center center !important;
}
