/* ===== Sağ alt sabit Ara + WhatsApp düğmeleri ===== */
.ag-fab {
  position: fixed;
  right: 26px;
  bottom: 92px;              /* "yukarı çık" düğmesinin üstünde */
  z-index: 1500;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  /* Başlangıçta gizli; açılış görseli geçilince .ag-fab-visible ile belirir */
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px);
  transition: opacity .3s, transform .3s, visibility .3s;
}
.ag-fab.ag-fab-visible { opacity: 1; visibility: visible; transform: none; }
.ag-fab-btn {
  position: relative;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 8px 22px rgba(0,0,0,0.28);
  transition: transform .2s, box-shadow .2s;
}
.ag-fab-btn:hover { transform: translateY(-2px) scale(1.05); box-shadow: 0 12px 28px rgba(0,0,0,0.32); }
.ag-fab-call { background: #1B4D3E; color: #fff; width: 50px; height: 50px; }
.ag-fab-wa { background: #25D366; color: #fff; }

/* Ara düğmesinin yanında çıkan küçük etiket */
.ag-fab-tip {
  position: absolute;
  right: calc(100% + 10px);
  top: 50%;
  transform: translateY(-50%);
  background: rgba(26,26,46,0.95);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 500;
  white-space: nowrap;
  padding: 7px 12px;
  border-radius: 6px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}
.ag-fab-call:hover .ag-fab-tip { opacity: 1; }

/* WhatsApp menüsü */
.ag-fab-wa-wrap { position: relative; }
.ag-fab-menu {
  position: absolute;
  right: 0;
  bottom: calc(100% + 12px);
  width: 270px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 18px 46px rgba(0,0,0,0.28);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity .2s, transform .2s, visibility .2s;
}
.ag-fab-menu::after {           /* menü ile düğme arasındaki boşlukta fare kaybolmasın */
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -14px; height: 14px;
}
.ag-fab-wa-wrap.open .ag-fab-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.ag-fab-menu-head {
  padding: 12px 12px 10px;
  font-weight: 700;
  color: #1a1a2e;
  font-size: 0.95rem;
  border-bottom: 1px solid #eee;
  margin-bottom: 4px;
}
.ag-fab-menu-head small { display: block; font-weight: 400; color: #777; font-size: 0.76rem; margin-top: 3px; }
.ag-fab-opt {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 9px;
  color: #1a1a2e;
  text-decoration: none;
  font-size: 0.9rem;
  transition: background .15s;
}
.ag-fab-opt:hover, .ag-fab-opt:focus-visible { background: #eafaf0; outline: none; }
.ag-fab-opt-ico { width: 22px; text-align: center; }

/* Dikkat çekmek için kısa nabız efekti (3 kez) */
.ag-fab-pulse .ag-fab-wa::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #25D366;
  z-index: -1;
  animation: agFabPulse 1.8s ease-out 3;
}
@keyframes agFabPulse {
  0% { transform: scale(1); opacity: .55; }
  100% { transform: scale(1.7); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) { .ag-fab-pulse .ag-fab-wa::before { animation: none; } }

/* Telefon: alt hızlı erişim çubuğunda zaten "Hemen Ara" var; yalnızca WhatsApp kalsın */
@media (max-width: 768px) {
  .ag-fab { right: 16px; bottom: 84px; }
  body.has-mobile-bar .ag-fab { bottom: 140px; }
  body.has-mobile-bar .ag-fab-call { display: none; }
  .ag-fab-btn { width: 52px; height: 52px; }
  .ag-fab-menu { width: min(270px, calc(100vw - 32px)); }
  /* Çerez bandı açıkken üst üste binmesin */
  body.cerez-acik .ag-fab { opacity: 0; pointer-events: none; }
}
