/* ================================================
   widgets.css — Yüzer Widget'lar
   ================================================ */

/* ---- Yüzer Butonlar ---- */
.float-btns {
  position: fixed;
  bottom: 30px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 180;
}
.float-btn {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--border-mid);
  background: var(--bg-2);
  color: var(--text-2);
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--t-fast);
  box-shadow: var(--shadow-card);
  position: relative;
  cursor: pointer;
}
.float-btn:hover { border-color: var(--blue); color: var(--blue); box-shadow: var(--shadow-glow-blue); }
#btnScrollTop { display: none; }

.notif-badge-dot {
  position: absolute;
  top: -3px;
  right: -3px;
  width: 18px;
  height: 18px;
  background: var(--red);
  color: #fff;
  border-radius: 50%;
  font-size: 9px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
}

/* FAB: Sunucu Ekle */
.fab-add {
  position: fixed;
  bottom: 30px;
  left: 24px;
  z-index: 180;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: var(--grad-blue);
  color: #fff;
  font-size: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 22px var(--blue-glow);
  transition: var(--t-mid);
  border: none;
  cursor: pointer;
}
.fab-add:hover { transform: rotate(45deg) scale(1.12); box-shadow: 0 8px 30px var(--blue-glow); }

/* ---- Bildirim Paneli ---- */
.notif-panel {
  position: fixed;
  bottom: 88px;
  right: 24px;
  width: 340px;
  z-index: 300;
  background: var(--bg-2);
  border: 1px solid var(--border-mid);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  display: none;
  overflow: hidden;
}
.notif-panel.open { display: block; }

.notif-panel-header {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-dim);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 14px;
  font-weight: 700;
}
.notif-panel-close {
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--bg-3); border: 1px solid var(--border-dim);
  color: var(--text-3); font-size: 12px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
}

.notif-panel-list { max-height: 310px; overflow-y: auto; }
.notif-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-dim);
  cursor: pointer;
  transition: var(--t-fast);
}
.notif-row:hover { background: var(--bg-3); }
.notif-row.unread { background: rgba(77,159,255,0.04); }
.notif-row-icon { font-size: 20px; flex-shrink: 0; margin-top: 1px; }
.notif-row-text { font-size: 12px; color: var(--text-2); line-height: 1.5; }
.notif-row-time { font-size: 10px; color: var(--text-3); margin-top: 3px; font-family: var(--font-mono); }

.notif-panel-footer {
  padding: 10px 16px;
  border-top: 1px solid var(--border-dim);
  display: flex;
  justify-content: space-between;
}
.notif-panel-footer a { font-size: 11px; color: var(--blue); text-decoration: none; }
.notif-panel-footer a:hover { color: var(--gold); }

/* ---- Chat Widget ---- */
.chat-widget {
  position: fixed;
  bottom: 88px;
  right: 88px;
  width: 360px;
  height: 440px;
  z-index: 300;
  background: var(--bg-2);
  border: 1px solid var(--border-mid);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  display: none;
  flex-direction: column;
  overflow: hidden;
}
.chat-widget.open { display: flex; }

.chat-header {
  padding: 13px 16px;
  border-bottom: 1px solid var(--border-dim);
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  flex-shrink: 0;
}
.chat-header-online { font-size: 11px; color: var(--green); margin-left: auto; font-family: var(--font-mono); }
.chat-close {
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--bg-3); border: 1px solid var(--border-dim);
  color: var(--text-3); font-size: 12px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; flex-shrink: 0;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.chat-msg { display: flex; gap: 8px; max-width: 88%; }
.chat-msg-avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--bg-3);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; flex-shrink: 0;
}
.chat-msg-bubble { background: var(--bg-3); border-radius: 0 10px 10px 10px; padding: 8px 12px; }
.chat-msg-name { font-size: 11px; color: var(--blue); font-weight: 700; margin-bottom: 3px; }
.chat-msg-text { font-size: 13px; color: var(--text-2); line-height: 1.4; }
.chat-msg.own { margin-left: auto; flex-direction: row-reverse; }
.chat-msg.own .chat-msg-bubble { background: rgba(77,159,255,0.14); border-radius: 10px 0 10px 10px; }

.chat-input-bar {
  padding: 10px 12px;
  border-top: 1px solid var(--border-dim);
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}
.chat-text-input {
  flex: 1;
  background: var(--bg-3);
  border: 1px solid var(--border-dim);
  border-radius: var(--r-full);
  padding: 8px 14px;
  color: var(--text-1);
  font-size: 13px;
  transition: var(--t-fast);
}
.chat-text-input:focus { border-color: var(--blue); }
.chat-text-input::placeholder { color: var(--text-3); }
.chat-send-btn {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--grad-blue); color: #fff;
  font-size: 14px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; border: none; cursor: pointer;
  transition: var(--t-fast);
}
.chat-send-btn:hover { transform: scale(1.1); }

/* ---- Cookie Banner ---- */
.cookie-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 400;
  background: rgba(7, 12, 26, 0.97);
  border-top: 1px solid var(--border-mid);
  padding: 14px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  backdrop-filter: blur(12px);
}
.cookie-text { font-size: 13px; color: var(--text-2); }
.cookie-text a { color: var(--blue); }
.cookie-actions { display: flex; gap: 10px; flex-shrink: 0; }
.btn-cookie-accept {
  padding: 8px 22px;
  border-radius: var(--r-sm);
  background: var(--grad-blue);
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  border: none;
  cursor: pointer;
}
.btn-cookie-decline {
  padding: 8px 18px;
  border-radius: var(--r-sm);
  border: 1px solid var(--border-mid);
  color: var(--text-3);
  font-size: 13px;
  cursor: pointer;
  transition: var(--t-fast);
}
.btn-cookie-decline:hover { color: var(--red); border-color: var(--red); }

/* ---- Toast ---- */
.toast-stack {
  position: fixed;
  top: 80px;
  right: 24px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}
.toast {
  min-width: 280px;
  max-width: 340px;
  background: var(--bg-2);
  border: 1px solid var(--border-mid);
  border-radius: var(--r-md);
  padding: 13px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-card);
  pointer-events: all;
  animation: toast-slide-in 0.3s var(--ease) forwards;
  font-size: 13px;
  color: var(--text-2);
}
.toast.success { border-left: 3px solid var(--green); }
.toast.error   { border-left: 3px solid var(--red); }
.toast.info    { border-left: 3px solid var(--blue); }
.toast.warning { border-left: 3px solid var(--gold); }
.toast-icon { font-size: 18px; flex-shrink: 0; }
.toast-dismiss {
  margin-left: auto;
  color: var(--text-3);
  font-size: 16px;
  cursor: pointer;
  background: none;
  border: none;
  pointer-events: all;
}
@keyframes toast-slide-in {
  from { transform: translateX(110%); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}
.toast.removing {
  animation: toast-slide-out 0.25s var(--ease) forwards;
}
@keyframes toast-slide-out {
  to { transform: translateX(110%); opacity: 0; }
}

/* ---- Toast ---- */
.toast-stack { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; z-index: 9999; pointer-events: none; }
.toast { pointer-events: all; padding: 12px 20px; border-radius: var(--r-md); font-size: 13px; font-weight: 600; background: var(--bg-2); border: 1px solid var(--border-mid); color: var(--text-1); box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 8px; min-width: 240px; max-width: 400px; animation: toastIn .3s ease; backdrop-filter: blur(12px); }
.toast.success { border-color: rgba(61,255,160,.4); background: rgba(61,255,160,.08); }
.toast.error   { border-color: rgba(255,61,96,.4);  background: rgba(255,61,96,.08); }
.toast.warning { border-color: rgba(240,192,96,.4); background: rgba(240,192,96,.08); }
.toast.info    { border-color: rgba(77,159,255,.4); background: rgba(77,159,255,.08); }
.toast-exit { animation: toastOut .3s ease forwards; }
@keyframes toastIn  { from { opacity:0; transform: translateY(16px); } to { opacity:1; transform: none; } }
@keyframes toastOut { from { opacity:1; } to { opacity:0; transform: translateY(8px); } }

/* ---- Float Buttons ---- */
.float-btns { position: fixed; bottom: 88px; right: 24px; display: flex; flex-direction: column; gap: 8px; z-index: 800; }
.float-btn { width: 44px; height: 44px; border-radius: 50%; background: var(--bg-2); border: 1px solid var(--border-mid); color: var(--text-2); font-size: 18px; cursor: pointer; transition: var(--t-fast); display: flex; align-items: center; justify-content: center; position: relative; box-shadow: var(--shadow-md); }
.float-btn:hover { background: var(--blue-dim); border-color: var(--blue); color: var(--blue); transform: scale(1.1); }
.notif-badge-dot { position: absolute; top: -2px; right: -2px; background: var(--red); color: #fff; font-size: 9px; font-family: var(--font-mono); border-radius: 50%; width: 16px; height: 16px; display: flex; align-items: center; justify-content: center; font-weight: 700; }
#btnScrollTop { display: none; }
.fab-add { position: fixed; bottom: 24px; right: 24px; width: 54px; height: 54px; border-radius: 50%; background: var(--grad-blue); color: #fff; font-size: 26px; border: none; cursor: pointer; z-index: 800; box-shadow: 0 4px 20px rgba(77,159,255,.4); transition: var(--t-fast); display: flex; align-items: center; justify-content: center; font-weight: 300; }
.fab-add:hover { transform: scale(1.1) rotate(45deg); box-shadow: 0 8px 32px rgba(77,159,255,.5); }

/* ---- Notification Panel ---- */
.notif-panel { position: fixed; top: 64px; right: 24px; width: 340px; background: var(--bg-2); border: 1px solid var(--border-mid); border-radius: var(--r-xl); box-shadow: var(--shadow-lg); z-index: 850; display: none; overflow: hidden; max-height: 500px; }
.notif-panel.open { display: block; }
.notif-panel-header { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--border-dim); font-size: 14px; font-weight: 700; }
.notif-panel-close { background: none; border: none; color: var(--text-3); font-size: 18px; cursor: pointer; transition: var(--t-fast); }
.notif-panel-close:hover { color: var(--text-1); }
.notif-panel-list { overflow-y: auto; max-height: 360px; }
.notif-row { display: flex; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--border-dim); cursor: pointer; transition: var(--t-fast); }
.notif-row:hover { background: var(--bg-3); }
.notif-row.unread { background: var(--blue-dim); }
.notif-row.unread::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--blue); flex-shrink: 0; margin-top: 6px; }
.notif-row-icon { font-size: 20px; flex-shrink: 0; }
.notif-row-text { font-size: 12px; color: var(--text-2); line-height: 1.5; }
.notif-row-time { font-size: 10px; color: var(--text-3); margin-top: 3px; font-family: var(--font-mono); }
.notif-panel-footer { padding: 10px 14px; border-top: 1px solid var(--border-dim); text-align: center; }
.notif-mark-all { font-size: 12px; color: var(--blue); cursor: pointer; background: none; border: none; transition: var(--t-fast); font-family: var(--font-body); }

/* ---- Chat Widget ---- */
.chat-widget { position: fixed; bottom: 88px; right: 80px; width: 320px; background: var(--bg-2); border: 1px solid var(--border-mid); border-radius: var(--r-xl); box-shadow: var(--shadow-lg); z-index: 850; display: none; overflow: hidden; }
.chat-widget.open { display: flex; flex-direction: column; }
.chat-header { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; background: var(--bg-3); border-bottom: 1px solid var(--border-dim); font-size: 13px; font-weight: 700; }
.chat-header-online { font-family: var(--font-mono); font-size: 10px; color: var(--green); }
.chat-close { background: none; border: none; color: var(--text-3); cursor: pointer; font-size: 16px; transition: var(--t-fast); }
.chat-close:hover { color: var(--text-1); }
.chat-messages { height: 280px; overflow-y: auto; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.chat-msg { display: flex; gap: 8px; align-items: flex-start; }
.chat-msg.own { flex-direction: row-reverse; }
.chat-avatar { font-size: 20px; flex-shrink: 0; }
.chat-bubble { background: var(--bg-3); border-radius: var(--r-md); padding: 7px 11px; max-width: 80%; }
.chat-msg.own .chat-bubble { background: var(--blue-dim); border: 1px solid rgba(77,159,255,.2); }
.chat-name { font-size: 10px; color: var(--blue); font-weight: 700; margin-bottom: 3px; }
.chat-text { font-size: 12px; color: var(--text-2); line-height: 1.4; }
.chat-input-bar { display: flex; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--border-dim); }
.chat-text-input { flex: 1; background: var(--bg-3); border: 1px solid var(--border-dim); border-radius: var(--r-sm); padding: 8px 12px; color: var(--text-1); font-size: 12px; transition: var(--t-fast); }
.chat-text-input:focus { border-color: var(--blue); outline: none; }
.chat-send-btn { width: 34px; height: 34px; border-radius: var(--r-sm); background: var(--grad-blue); color: #fff; border: none; cursor: pointer; font-size: 14px; transition: var(--t-fast); }
.chat-send-btn:hover { transform: scale(1.1); }

/* ---- Cookie Banner ---- */
.cookie-banner { position: fixed; bottom: 0; left: 0; right: 0; background: var(--bg-2); border-top: 1px solid var(--border-mid); padding: 16px 28px; display: flex; align-items: center; justify-content: space-between; gap: 16px; z-index: 900; flex-wrap: wrap; }
.cookie-text { font-size: 13px; color: var(--text-2); flex: 1; }
.cookie-btns { display: flex; gap: 10px; flex-shrink: 0; }
.cookie-btn-accept { padding: 8px 20px; border-radius: var(--r-sm); background: var(--grad-blue); color: #fff; border: none; font-size: 13px; font-weight: 700; cursor: pointer; transition: var(--t-fast); }
.cookie-btn-decline { padding: 8px 16px; border-radius: var(--r-sm); background: transparent; color: var(--text-3); border: 1px solid var(--border-dim); font-size: 13px; cursor: pointer; transition: var(--t-fast); }
.cookie-btn-decline:hover { color: var(--text-1); border-color: var(--border-mid); }
