/* ==========================================================================
   SOSYAL MEDYA BAR (Sadece Sosyal Bar Kodları)
   ========================================================================== */

/* Sayfa Açılış Animasyonu */
@keyframes slideInRight {
    0% {
        transform: translateY(-50%) translateX(100%);
        opacity: 0;
    }
    100% {
        transform: translateY(-50%) translateX(0);
        opacity: 1;
    }
}

/* Sosyal Medya Bar Ana Konum */
.social-sidebar {
    position: fixed;
    right: 0;
    top: 50%;
    z-index: 999;
    display: flex;
    align-items: center;
    
    transform: translateY(-50%) translateX(0);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease, visibility 0.3s ease;
    
    /* Sayfa açılışında yavaşça süzülür */
    animation: slideInRight 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

/* İçeri Girme / Kapanma Durumu */
.social-sidebar.closed {
    transform: translateY(-50%) translateX(calc(100% - 38px));
}

.social-sidebar.closed .toggle-btn .arrow {
    transform: rotate(180deg);
}

/* Ok (Gizle / Göster) Düğmesi */
.toggle-btn {
    background: var(--nav-color, #ffffff);
    backdrop-filter: var(--glass-effect, blur(10px));
    -webkit-backdrop-filter: var(--glass-effect, blur(10px));
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
    border-right: none;
    color: var(--text-color, #1a1a1a);
    padding: 12px 10px;
    cursor: pointer;
    border-radius: 10px 0 0 10px;
    transition: all 0.3s ease;
    outline: none;
    z-index: 2;
}

.toggle-btn:hover {
    background: var(--primary-color, rgb(240, 11, 11));
    color: #ffffff !important;
    box-shadow: -2px 0 12px var(--primary-color, rgba(240, 11, 11, 0.5));
}

.toggle-btn .arrow {
    display: inline-block;
    font-size: 14px;
    transition: transform 0.3s ease;
}

/* İkon Kapsayıcı Kutu */
.icons-wrapper {
    display: flex;
    flex-direction: column;
    background: var(--nav-color, #ffffff);
    backdrop-filter: var(--glass-effect, blur(10px));
    -webkit-backdrop-filter: var(--glass-effect, blur(10px));
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
    border-right: none;
    border-radius: 12px 0 0 12px;
    padding: 8px;
    gap: 8px;
    box-shadow: -5px 0 25px var(--shadow-color, rgba(0, 0, 0, 0.5));
}

/* İkon Bağlantıları */
.social-sidebar .icon {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    color: var(--text-color, #1a1a1a);
    text-decoration: none;
    padding: 10px 14px;
    border-radius: var(--border-radius, 8px);
    transition: all 0.3s ease;
    white-space: nowrap;
}

.social-sidebar .icon .text {
    font-size: 0.85rem;
    font-weight: 500;
    opacity: 0.9;
}

.social-sidebar .icon i {
    font-size: 1.2rem;
    width: 20px;
    text-align: center;
}

/* Her sosyal medya kendi renkleriyle hover etsin, Instagram ayrı özel renk */
.social-sidebar .icon.whatsapp:hover {
    background: linear-gradient(135deg, #25D366, #1ebe5b) !important;
    color: #ffffff !important;
    box-shadow: 0 0 12px rgba(37, 211, 102, 0.75),
                0 0 22px rgba(37, 211, 102, 0.5);
    transform: translateX(-2px);
}

.social-sidebar .icon.instagram:hover {
    background: linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888) !important;
    color: #ffffff !important;
    box-shadow: 0 0 12px rgba(188, 24, 136, 0.8),
                0 0 22px rgba(220, 39, 67, 0.6);
    transform: translateX(-2px);
}

.social-sidebar .icon.facebook:hover {
    background: linear-gradient(135deg, #1877F2, #0d5cd7) !important;
    color: #ffffff !important;
    box-shadow: 0 0 12px rgba(24, 119, 242, 0.75),
                0 0 22px rgba(24, 119, 242, 0.5);
    transform: translateX(-2px);
}

.social-sidebar .icon:hover {
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.7);
}

/* Light Mode (Gündüz) Uyumlu Stiller */
body.light-theme .toggle-btn,
body.light-theme .icons-wrapper,
body.light-mode .toggle-btn,
body.light-mode .icons-wrapper,
[data-theme="light"] .toggle-btn,
[data-theme="light"] .icons-wrapper {
    background: rgba(255, 255, 255, 0.88);
    border-color: rgba(0, 0, 0, 0.12);
    box-shadow: -5px 0 20px rgba(0, 0, 0, 0.08);
}

body.light-theme .social-sidebar .icon,
body.light-theme .toggle-btn,
body.light-mode .social-sidebar .icon,
body.light-mode .toggle-btn,
[data-theme="light"] .social-sidebar .icon,
[data-theme="light"] .toggle-btn {
    color: #1a1a1a;
}

/* Dark Mode */
body.dark .toggle-btn,
body.dark .icons-wrapper {
    background: var(--nav-color, #000000);
    border-color: rgba(255, 0, 0, 0.18);
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.5);
}

body.dark .social-sidebar .icon,
body.dark .toggle-btn {
    color: #ffffff;
}

body.dark .toggle-btn:hover {
    background: #ff1a1a;
    color: #ffffff;
    box-shadow: -2px 0 10px rgba(255, 26, 26, 0.55);
}

/* Mobil Ekran Uyumları */
@media (max-width: 768px) {
    /* Mobil menü açıldığında sosyal barı gizle */
    body.nav-active .social-sidebar,
    .nav-active .social-sidebar {
        opacity: 0 !important;
        pointer-events: none !important;
        visibility: hidden !important;
    }

    /* Mobilde yazıları sakla, sadece ikonlar görünsün */
    .social-sidebar .icon .text {
        display: none;
    }

    .social-sidebar .icon {
        padding: 10px 10px;
    }

    .social-sidebar.closed {
        transform: translateY(-50%) translateX(calc(100% - 34px));
    }
}