/* Esular canlı destek penceresi — Views/Shared/_LiveChatWidget.cshtml + js/live-chat-widget.js */
.es-sohbet { --s-ana: var(--es-primary, #f24726); --s-ana-koyu: var(--es-primary-700, #b8331a); --s-metin: #0f172a; --s-gri: #64748b;
  --s-cizgi: #e2e8f0; --s-zemin: #f8fafc; --s-yesil: #16a34a; font-family: var(--es-font, 'Inter', 'Poppins', system-ui, sans-serif);
  position: fixed; right: 20px; bottom: 20px; z-index: 9998; color: var(--s-metin); }
.es-sohbet * { box-sizing: border-box; }
.es-sohbet button { font: inherit; }

.es-sohbet-ac { display: inline-flex; align-items: center; gap: 9px; padding: 13px 20px 13px 16px; border: 0; border-radius: 999px;
  background: var(--s-ana); color: #fff; font-weight: 700; font-size: 14.5px; cursor: pointer; position: relative;
  box-shadow: 0 10px 28px rgba(242, 71, 38, .38); transition: transform .18s ease, box-shadow .18s ease; }
.es-sohbet-ac:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(242, 71, 38, .45); }
.es-sohbet-ac i { font-size: 20px; line-height: 1; }
.es-sohbet-rozet { position: absolute; top: -5px; right: -3px; min-width: 21px; height: 21px; padding: 0 6px; border-radius: 999px;
  background: var(--s-yesil); color: #fff; font-size: 12px; font-weight: 700; display: grid; place-items: center; border: 2px solid #fff; }
.es-sohbet.acik .es-sohbet-ac { display: none; }

.es-sohbet-pencere { position: absolute; right: 0; bottom: 0; width: 384px; height: min(640px, calc(100vh - 110px)); display: none;
  flex-direction: column; background: #fff; border-radius: 18px; overflow: hidden;
  box-shadow: 0 24px 60px rgba(15, 23, 42, .28), 0 2px 6px rgba(15, 23, 42, .08); animation: esSohbetAc .2s ease; }
.es-sohbet.acik .es-sohbet-pencere { display: flex; }
@keyframes esSohbetAc { from { transform: translateY(12px); opacity: 0; } }

.es-sohbet-bas { display: flex; align-items: center; gap: 11px; padding: 15px 14px 15px 16px; background: #0f172a; color: #fff; }
.es-sohbet-logo { width: 38px; height: 38px; border-radius: 12px; background: var(--s-ana); display: grid; place-items: center; font-weight: 800; font-size: 17px; flex: none; position: relative; }
.es-sohbet-logo::after { content: ''; position: absolute; right: -2px; bottom: -2px; width: 11px; height: 11px; border-radius: 50%; background: #94a3b8; border: 2px solid #0f172a; }
.es-sohbet-logo.canli::after { background: #22c55e; }
.es-sohbet-baslik { flex: 1; min-width: 0; }
.es-sohbet-baslik b { display: block; font-size: 15px; }
.es-sohbet-baslik small { display: block; color: #cbd5e1; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.es-sohbet-dgm { width: 34px; height: 34px; border-radius: 10px; border: 0; background: transparent; color: #e2e8f0; cursor: pointer; display: grid; place-items: center; font-size: 17px; }
.es-sohbet-dgm:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.es-sohbet-menu { position: absolute; top: 60px; right: 10px; z-index: 3; background: #fff; color: var(--s-metin); border: 1px solid var(--s-cizgi);
  border-radius: 12px; box-shadow: 0 12px 30px rgba(15, 23, 42, .18); padding: 6px; min-width: 220px; display: grid; }
.es-sohbet-menu button, .es-sohbet-menu a { display: flex; gap: 10px; align-items: center; padding: 9px 10px; border: 0; background: none; border-radius: 8px;
  color: inherit; text-decoration: none; font-size: 14px; cursor: pointer; text-align: left; }
.es-sohbet-menu button:hover, .es-sohbet-menu a:hover { background: var(--s-zemin); }
.es-sohbet-menu .tehlike { color: #dc2626; }

.es-sohbet-govde { flex: 1; overflow-y: auto; background: var(--s-zemin); padding: 16px 14px 8px; position: relative; overscroll-behavior: contain; }
.es-sohbet-govde.surukle::after { content: attr(data-birak); position: absolute; inset: 10px; border: 2px dashed var(--s-ana); border-radius: 14px;
  background: rgba(255, 241, 236, .92); display: grid; place-items: center; font-weight: 700; color: var(--s-ana-koyu); }

.es-sohbet-giris { padding: 4px 4px 10px; }
.es-sohbet-giris h3 { font-size: 20px; margin: 4px 0 6px; font-weight: 800; }
.es-sohbet-giris p { color: var(--s-gri); font-size: 14px; margin: 0 0 16px; line-height: 1.5; }
.es-sohbet-alan { display: grid; gap: 5px; margin-bottom: 11px; font-size: 13px; font-weight: 600; color: #334155; }
.es-sohbet-alan input, .es-sohbet-alan textarea { width: 100%; border: 1px solid #cbd5e1; border-radius: 11px; padding: 10px 12px; font: inherit; font-size: 15px;
  font-weight: 400; color: var(--s-metin); background: #fff; resize: none; outline: none; }
.es-sohbet-alan input:focus, .es-sohbet-alan textarea:focus { border-color: var(--s-ana); box-shadow: 0 0 0 3px rgba(242, 71, 38, .14); }
.es-sohbet-alan small { color: var(--s-gri); font-weight: 400; }
.es-sohbet-ana-dgm { width: 100%; border: 0; border-radius: 12px; background: var(--s-ana); color: #fff; font-weight: 700; font-size: 15px; padding: 12px; cursor: pointer;
  display: flex; justify-content: center; gap: 8px; align-items: center; }
.es-sohbet-ana-dgm:hover { background: var(--s-ana-koyu); }
.es-sohbet-ana-dgm:disabled { opacity: .6; cursor: default; }
.es-sohbet-ikincil { width: 100%; border: 1px solid #cbd5e1; border-radius: 12px; background: #fff; color: var(--s-metin); font-weight: 600; font-size: 14px; padding: 11px; cursor: pointer; margin-top: 8px; display: flex; gap: 8px; justify-content: center; align-items: center; }
.es-sohbet-hata { background: #fef2f2; color: #b91c1c; border-radius: 10px; padding: 9px 11px; font-size: 13.5px; margin-bottom: 10px; }
.es-sohbet-not { font-size: 12px; color: var(--s-gri); margin-top: 10px; text-align: center; }
.es-sohbet-not a { color: inherit; }

.es-sohbet-gun { text-align: center; font-size: 11.5px; color: var(--s-gri); margin: 6px 0 12px; font-weight: 600; }
.es-sohbet-msj { display: flex; gap: 8px; margin: 0 0 4px; align-items: flex-end; }
.es-sohbet-msj.ben { justify-content: flex-end; }
.es-sohbet-msj + .es-sohbet-msj:not(.ayni) { margin-top: 12px; }
.es-sohbet-av { width: 28px; height: 28px; border-radius: 50%; background: #0f172a; color: #fff; font-size: 12px; font-weight: 700; display: grid; place-items: center; flex: none; }
.es-sohbet-msj.ayni .es-sohbet-av { visibility: hidden; }
.es-sohbet-balon { max-width: 78%; padding: 9px 12px; border-radius: 16px; background: #fff; border: 1px solid var(--s-cizgi); font-size: 14.5px; line-height: 1.45;
  white-space: pre-wrap; overflow-wrap: anywhere; }
.es-sohbet-msj.ben .es-sohbet-balon { background: var(--s-ana); color: #fff; border-color: transparent; border-bottom-right-radius: 5px; }
.es-sohbet-msj:not(.ben) .es-sohbet-balon { border-bottom-left-radius: 5px; }
.es-sohbet-balon a { color: inherit; text-decoration: underline; }
.es-sohbet-kim { font-size: 11.5px; color: var(--s-gri); margin: 0 0 3px 36px; font-weight: 600; }
.es-sohbet-saat { font-size: 10.5px; opacity: .72; margin-left: 8px; float: right; margin-top: 5px; }
.es-sohbet-sistem { text-align: center; margin: 12px 8px; }
.es-sohbet-sistem span { display: inline-block; font-size: 12.5px; color: #475569; background: #e2e8f0; padding: 6px 12px; border-radius: 999px; line-height: 1.4; }
.es-sohbet-gonderiliyor { opacity: .6; }

.es-sohbet-ekler { display: grid; gap: 6px; margin-top: 6px; }
.es-sohbet-ekler:first-child { margin-top: 0; }
.es-sohbet-resim { display: block; max-width: 100%; max-height: 220px; border-radius: 11px; cursor: zoom-in; background: #e2e8f0; }
.es-sohbet-dosya { display: flex; align-items: center; gap: 9px; padding: 8px 10px; border-radius: 11px; background: rgba(15, 23, 42, .06); text-decoration: none !important; color: inherit; min-width: 0; }
.es-sohbet-msj.ben .es-sohbet-dosya { background: rgba(255, 255, 255, .18); }
.es-sohbet-dosya i { font-size: 21px; flex: none; }
.es-sohbet-dosya span { min-width: 0; display: grid; }
.es-sohbet-dosya b { font-weight: 600; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.es-sohbet-dosya small { opacity: .75; font-size: 11.5px; }
.es-sohbet-ekler video { max-width: 100%; border-radius: 11px; background: #000; }
.es-sohbet-ekler audio { width: 230px; max-width: 100%; }

.es-sohbet-yaziyor { display: none; align-items: center; gap: 8px; font-size: 12.5px; color: var(--s-gri); padding: 2px 4px 8px; }
.es-sohbet-yaziyor.var { display: flex; }
.es-sohbet-noktalar { display: inline-flex; gap: 3px; background: #fff; border: 1px solid var(--s-cizgi); border-radius: 12px; padding: 8px 10px; }
.es-sohbet-noktalar i { width: 6px; height: 6px; border-radius: 50%; background: #94a3b8; animation: esSohbetNokta 1.2s infinite; }
.es-sohbet-noktalar i:nth-child(2) { animation-delay: .15s; }
.es-sohbet-noktalar i:nth-child(3) { animation-delay: .3s; }
@keyframes esSohbetNokta { 0%, 60%, 100% { transform: translateY(0); opacity: .5; } 30% { transform: translateY(-4px); opacity: 1; } }

.es-sohbet-yaz { border-top: 1px solid var(--s-cizgi); background: #fff; padding: 9px 10px 10px; }
.es-sohbet-bekleyen { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 7px; }
.es-sohbet-bekleyen:empty { display: none; }
.es-sohbet-parca { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--s-cizgi); border-radius: 10px; padding: 4px 6px 4px 4px; font-size: 12.5px; max-width: 100%; background: var(--s-zemin); }
.es-sohbet-parca img { width: 34px; height: 34px; object-fit: cover; border-radius: 7px; }
.es-sohbet-parca .ikon { width: 34px; height: 34px; border-radius: 7px; background: #e2e8f0; display: grid; place-items: center; font-size: 17px; }
.es-sohbet-parca span { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.es-sohbet-parca progress { width: 54px; height: 5px; }
.es-sohbet-parca button { border: 0; background: none; color: var(--s-gri); cursor: pointer; padding: 2px; font-size: 14px; }
.es-sohbet-parca.hata { border-color: #fecaca; background: #fef2f2; color: #b91c1c; }
.es-sohbet-satir { display: flex; align-items: flex-end; gap: 6px; }
.es-sohbet-satir textarea { flex: 1; border: 0; outline: none; resize: none; font: inherit; font-size: 15px; line-height: 1.4; max-height: 120px; padding: 9px 4px; color: var(--s-metin); background: transparent; }
.es-sohbet-ek-dgm { width: 38px; height: 38px; border: 0; border-radius: 11px; background: transparent; color: var(--s-gri); cursor: pointer; font-size: 19px; display: grid; place-items: center; flex: none; }
.es-sohbet-ek-dgm:hover { background: var(--s-zemin); color: var(--s-metin); }
.es-sohbet-gonder { width: 40px; height: 40px; border: 0; border-radius: 12px; background: var(--s-ana); color: #fff; cursor: pointer; font-size: 17px; display: grid; place-items: center; flex: none; }
.es-sohbet-gonder:disabled { background: #cbd5e1; cursor: default; }

.es-sohbet-son { text-align: center; padding: 6px 6px 12px; }
.es-sohbet-son h4 { font-size: 16px; font-weight: 800; margin: 6px 0 4px; }
.es-sohbet-son p { font-size: 13.5px; color: var(--s-gri); margin: 0 0 12px; }
.es-sohbet-yildiz { display: flex; justify-content: center; gap: 6px; margin-bottom: 12px; }
.es-sohbet-yildiz button { border: 0; background: none; font-size: 30px; color: #cbd5e1; cursor: pointer; padding: 0 2px; line-height: 1; }
.es-sohbet-yildiz button.dolu { color: #f59e0b; }

.es-sohbet-isik { position: fixed; inset: 0; z-index: 10050; background: rgba(2, 6, 23, .9); display: grid; place-items: center; cursor: zoom-out; }
.es-sohbet-isik img { max-width: 94vw; max-height: 90vh; border-radius: 8px; }

.es-sohbet-don { display: none; }

@media (max-width: 991.98px) {
  /* Mobilde yüzen düğme yok (alt menü/WhatsApp bandı var); sohbet "Canlı destek" bağlantılarıyla açılır.
     Süren bir sohbet varsa geri dönmek için küçük bir balon görünür. */
  .es-sohbet { right: 14px; bottom: 84px; }
  .es-sohbet-ac { display: none; }
  .es-sohbet.suruyor:not(.acik) .es-sohbet-don { display: grid; width: 54px; height: 54px; border-radius: 50%; border: 0; background: var(--s-ana); color: #fff;
    font-size: 23px; place-items: center; box-shadow: 0 10px 26px rgba(242, 71, 38, .4); cursor: pointer; position: relative; }
}
@media (max-width: 575.98px) {
  .es-sohbet.acik { inset: 0; right: 0; bottom: 0; z-index: 10040; }
  .es-sohbet-pencere { position: fixed; inset: 0; width: auto; height: 100%; height: 100dvh; border-radius: 0; animation: none; }
  .es-sohbet-bas { padding-top: max(14px, env(safe-area-inset-top)); }
  .es-sohbet-yaz { padding-bottom: max(10px, env(safe-area-inset-bottom)); }
  .es-sohbet-balon { max-width: 84%; }
}
@media (prefers-reduced-motion: reduce) {
  .es-sohbet-pencere, .es-sohbet-noktalar i { animation: none; }
}
