/* Sohbet widgeti: site temasiyla uyumlu, isleyisten bagimsiz gorsel katman. */
#chat-panel {
    width: min(410px, calc(100vw - 32px));
    height: min(640px, calc(100dvh - 104px));
    display: none;
    border: 1px solid #526067 !important;
    border-radius: 18px !important;
    background: #151c20 !important;
    box-shadow: 0 24px 70px rgba(0, 0, 0, .62), 0 0 0 1px rgba(225, 185, 112, .08) inset !important;
}
#chat-panel.chat-open { display: flex; flex-direction: column; }
#chat-panel .chat-head {
    flex: none;
    min-height: 70px;
    padding: 12px 16px;
    border-bottom: 1px solid #3e4b50 !important;
    background: linear-gradient(125deg, #263035, #1a2327 72%) !important;
}
#chat-panel .chat-head-identity { display: flex; align-items: center; gap: 11px; min-width: 0; }
#chat-panel .chat-head-icon {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    flex: none;
    border: 1px solid #86683c;
    border-radius: 12px;
    background: linear-gradient(145deg, #4b3a24, #252822);
    color: #f3d18f;
    font-size: 21px;
    box-shadow: 0 3px 12px #0004;
}
#chat-panel .chat-head .title { color: #f5d494 !important; font-size: 14px; letter-spacing: .02em; line-height: 1.35; }
#chat-panel .chat-head-subtitle { display: block; color: #adb8b9; font-size: 11px; line-height: 1.4; }
#chat-panel .chat-head .actions .btn {
    padding: 7px 10px;
    border: 1px solid #536166 !important;
    border-radius: 9px;
    background: #263136 !important;
    color: #dce2e0 !important;
    font-size: 12px;
}
#chat-panel .chat-head .actions .btn:hover { border-color: #b9965f !important; color: #f5d494 !important; }
#chat-widget-body {
    flex: 1;
    min-height: 0;
    height: auto;
    overflow: hidden;
    padding: 0;
    background: #151c20 !important;
}
#chat-widget-body .chat-widget-body {
    display: flex;
    flex-direction: column;
    gap: 0;
    height: 100%;
    min-height: 0;
    padding: 14px;
    background: transparent !important;
}
#chat-widget-body .chat-privacy-note {
    flex: none;
    margin: 0 0 12px !important;
    padding: 11px 12px !important;
    border: 1px solid #64543b !important;
    border-radius: 10px !important;
    background: #26251f !important;
    color: #d6d8d3 !important;
    font-size: 11px !important;
}
#chat-widget-body .chat-privacy-note[hidden] { display: none !important; }
#chat-widget-body #chatAd { min-width: 0; }
#chat-widget-body #chatAd:disabled { color: #e9d5ae !important; opacity: 1; }
#chat-widget-body .chat-widget-body > div:has(> #chatAd) { flex: none; margin-bottom: 11px !important; }
#chat-widget-body .form-control {
    min-height: 38px;
    padding: 8px 11px;
    border: 1px solid #48565c !important;
    border-radius: 9px !important;
    background: #11191d !important;
    color: #edf0ed !important;
    box-shadow: none !important;
    font-size: 13px;
}
#chat-widget-body .form-control:focus { border-color: #d7ae70 !important; box-shadow: 0 0 0 3px rgba(215, 174, 112, .14) !important; }
#chat-widget-body .form-control::placeholder { color: #849196; }
#chat-widget-body #sohbetiBitirBtn { padding: 7px 10px; border-radius: 9px; background: #71363a; border-color: #92494e; color: #fff; font-size: 12px; }
#chat-widget-body #sohbetiBitirBtn:hover { background: #8b4146; }
#chat-widget-body #chatBox {
    flex: 1;
    min-height: 120px;
    height: auto !important;
    margin: 0 0 12px !important;
    padding: 14px 11px !important;
    border: 1px solid #35434a !important;
    border-radius: 12px !important;
    background: radial-gradient(circle at 50% 0, rgba(195, 154, 88, .055), transparent 42%), #11191d !important;
    scrollbar-color: #637078 transparent;
    scrollbar-width: thin;
}
#chat-widget-body .chat-row { margin: 9px 0; }
#chat-widget-body .chat-bubble {
    max-width: 86%;
    padding: 10px 12px;
    border-radius: 13px;
    font-size: 12.5px;
    line-height: 1.5;
    box-shadow: 0 4px 10px #0002;
}
#chat-widget-body .chat-bubble.other { background: #243036; border-color: #425159; }
#chat-widget-body .chat-bubble.me { background: #34342c; border-color: #766448; }
#chat-widget-body .chat-bubble.admin { background: #322b20; border-color: #9a7845; }
#chat-widget-body .chat-author { color: #f1c978; font-weight: 800; }
#chat-widget-body .chat-time { margin-top: 6px; color: #a7b1b2; font-size: 10px; }
#chat-widget-body .chat-admin-badge { background: #514026; border-color: #b99558; color: #ffe0a0; }
#chat-widget-body .chat-system { max-width: 95%; border-color: #6e5a3b; background: #26251e; }
#chat-widget-body .chat-widget-body > div:has(> #chatMesaj) { flex: none; margin-bottom: 7px !important; }
#chat-widget-body #chatMesaj { flex: 1; min-width: 0; }
#chat-widget-body #chatGonderBtn, #chat-widget-body #chatBaslatBtn {
    min-height: 38px;
    padding: 7px 12px;
    border-radius: 9px !important;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}
#chat-widget-body .chat-emoji-wrap { flex: none; margin: 0 !important; }
#chat-widget-body #emojiToggle {
    padding: 5px 8px;
    border: 1px solid #46545a !important;
    border-radius: 8px;
    background: #222d31 !important;
    color: #cad2d1 !important;
    font-size: 11px;
}
#chat-widget-body #emojiToggle:hover { border-color: #ab8854 !important; color: #f5d494 !important; }
#chat-widget-body #chatUyari { flex: none; margin-top: 3px !important; min-height: 0 !important; font-size: 11px; }
#chat-widget-body #chatUyari:empty { display: none; }
#chat-panel #emojiPanel.emoji-panel { background: #263136; border: 1px solid #536166; }
@media (max-width: 576px) {
    #chat-panel { width: 100vw; max-width: 100vw; height: min(82dvh, 720px); border-radius: 18px 18px 0 0 !important; }
    #chat-widget-body .chat-widget-body { padding: 12px; }
    #chat-widget-body #chatBox { min-height: 100px; height: auto !important; }
}
