/* =========================================
   FLOATING ACTIONS — Sağ Sabit Hızlı Erişim
   Sıra (üstten alta): WhatsApp · Telefon · Instagram · Yukarı Çık
   ========================================= */

.floating-actions {
    position: fixed;
    right: 20px;
    bottom: 24px;
    z-index: 900;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.floating-actions > * {
    pointer-events: auto;
}

/* === Ortak Buton (FAB) === */
.fab {
    position: relative;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
    transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
    border: none;
    cursor: pointer;
}

.fab:hover {
    transform: translateY(-2px) scale(1.06);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.25);
    filter: brightness(1.05);
}

.fab:active {
    transform: scale(0.96);
}

/* === Tooltip (data-tooltip ile) === */
.fab[data-tooltip]::before {
    content: attr(data-tooltip);
    position: absolute;
    right: calc(100% + 14px);
    top: 50%;
    transform: translateY(-50%) translateX(8px);
    background: #1a0b3d;
    color: #fff;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
    pointer-events: none;
    letter-spacing: 0.1px;
}

.fab[data-tooltip]::after {
    content: '';
    position: absolute;
    right: calc(100% + 8px);
    top: 50%;
    transform: translateY(-50%) translateX(8px);
    width: 0;
    height: 0;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-left: 6px solid #1a0b3d;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
    pointer-events: none;
}

.fab:hover::before,
.fab:hover::after {
    opacity: 1;
    visibility: visible;
    transform: translateY(-50%) translateX(0);
}

/* === Renk Varyantları === */
.fab--whatsapp {
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
}

.fab--phone {
    background: linear-gradient(135deg, var(--color-green) 0%, var(--color-green-dark) 100%);
}

.fab--instagram {
    background: linear-gradient(135deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
}

.fab--top {
    background: linear-gradient(135deg, #475569 0%, #1e293b 100%);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: opacity 0.3s ease, visibility 0.3s, transform 0.3s ease, background 0.25s ease, filter 0.25s ease;
}

.fab--top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* === WhatsApp Pulse Animasyonu (dikkat çekmek için) === */
.fab__pulse {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: #25d366;
    opacity: 0.5;
    z-index: -1;
    animation: fabPulse 2s ease-out infinite;
    pointer-events: none;
}

@keyframes fabPulse {
    0% {
        transform: scale(1);
        opacity: 0.5;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

/* === Mobil === */
@media (max-width: 768px) {
    .floating-actions {
        right: 14px;
        bottom: calc(14px + env(safe-area-inset-bottom, 0));
        gap: 10px;
    }
    .fab {
        width: 48px;
        height: 48px;
    }
    .fab svg {
        width: 20px;
        height: 20px;
    }
    /* Mobilde tooltip'leri gizle (touch'ta gereksiz) */
    .fab[data-tooltip]::before,
    .fab[data-tooltip]::after {
        display: none;
    }
}

/* === Safe area (iPhone home indicator) === */
@supports (padding: max(0px)) {
    .floating-actions {
        bottom: max(24px, env(safe-area-inset-bottom, 24px));
    }
}
