/* ============================================
   ALKAZE CHAT WIDGET — Stylesheet
   Renk paleti: Alkaze Pembesi (#D81159) + Siyah + Beyaz
   ============================================ */

:root {
  --alkaze-red: #D81159;
  --alkaze-red-dark: #A50E45;
  --alkaze-black: #1A1A1A;
  --alkaze-gray-1: #F5F5F5;
  --alkaze-gray-2: #E5E5E5;
  --alkaze-gray-3: #999;
  --alkaze-white: #FFFFFF;
}

/* KAPALI BALON */
.alkaze-chat-bubble {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--alkaze-red);
  color: white;
  border: none;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(216, 17, 89, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: transform 0.2s, box-shadow 0.2s;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}
.alkaze-chat-bubble:hover {
  transform: scale(1.05);
  box-shadow: 0 12px 32px rgba(216, 17, 89, 0.5);
}
.alkaze-chat-bubble svg { width: 28px; height: 28px; }

.alkaze-chat-bubble::after {
  content: '';
  position: absolute;
  top: 8px;
  right: 8px;
  width: 12px;
  height: 12px;
  background: #fff;
  border: 2px solid var(--alkaze-red);
  border-radius: 50%;
  animation: alkazePulse 2s infinite;
}
@keyframes alkazePulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.2); opacity: 0.7; }
}

.alkaze-chat-bubble.hidden { display: none; }

/* PENCERE */
.alkaze-chat-window {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 380px;
  height: 580px;
  max-height: calc(100vh - 48px);
  background: white;
  border-radius: 16px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.2);
  display: none;
  flex-direction: column;
  overflow: hidden;
  z-index: 9999;
  animation: alkazeSlideUp 0.3s ease-out;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}
.alkaze-chat-window.open { display: flex; }
@keyframes alkazeSlideUp {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@media (max-width: 480px) {
  .alkaze-chat-window {
    width: calc(100vw - 24px);
    height: calc(100vh - 24px);
    bottom: 12px;
    right: 12px;
    max-height: calc(100vh - 24px);
  }
}

/* HEADER */
.alkaze-chat-header {
  background: var(--alkaze-black);
  color: white;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.alkaze-chat-header-info { display: flex; align-items: center; gap: 12px; }
.alkaze-logo-circle {
  width: 36px;
  height: 36px;
  background: var(--alkaze-red);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 16px;
  color: white;
}
.alkaze-header-text h3 { font-size: 15px; font-weight: 600; margin: 0 0 2px 0; }
.alkaze-header-text p {
  font-size: 12px;
  color: #aaa;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 6px;
}
.alkaze-status-dot {
  width: 8px;
  height: 8px;
  background: #4ADE80;
  border-radius: 50%;
}
.alkaze-close-btn {
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  padding: 4px;
  opacity: 0.7;
  transition: opacity 0.2s;
}
.alkaze-close-btn:hover { opacity: 1; }

/* MESAJ ALANI */
.alkaze-chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  background: var(--alkaze-gray-1);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.alkaze-msg {
  max-width: 85%;
  padding: 12px 14px;
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.5;
  animation: alkazeMsgIn 0.3s ease-out;
  word-wrap: break-word;
}
@keyframes alkazeMsgIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
.alkaze-msg.bot {
  background: white;
  color: var(--alkaze-black);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}
.alkaze-msg.user {
  background: var(--alkaze-red);
  color: white;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

/* HİZMET BUTONLARI */
.alkaze-options {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
}
.alkaze-option-btn {
  background: white;
  border: 1px solid var(--alkaze-gray-2);
  color: var(--alkaze-black);
  padding: 10px 14px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 13px;
  text-align: left;
  transition: all 0.2s;
  font-family: inherit;
}
.alkaze-option-btn:hover {
  border-color: var(--alkaze-red);
  background: #fdf2f6;
  transform: translateX(2px);
}

/* FORM */
.alkaze-form {
  background: white;
  padding: 14px;
  border-radius: 12px;
  margin-top: 8px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.alkaze-form input, .alkaze-form textarea {
  border: 1px solid var(--alkaze-gray-2);
  border-radius: 8px;
  padding: 9px 12px;
  font-size: 13px;
  font-family: inherit;
  outline: none;
  transition: border 0.2s;
}
.alkaze-form input:focus, .alkaze-form textarea:focus {
  border-color: var(--alkaze-red);
}
.alkaze-form textarea {
  min-height: 60px;
  resize: vertical;
}
.alkaze-form-submit {
  background: var(--alkaze-red);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 10px;
  font-weight: 600;
  cursor: pointer;
  font-size: 13px;
  transition: background 0.2s;
  font-family: inherit;
}
.alkaze-form-submit:hover { background: var(--alkaze-red-dark); }
.alkaze-form-submit:disabled {
  background: var(--alkaze-gray-3);
  cursor: not-allowed;
}

/* INPUT BAR */
.alkaze-input-bar {
  border-top: 1px solid var(--alkaze-gray-2);
  padding: 12px;
  background: white;
  display: flex;
  gap: 8px;
  align-items: center;
}
.alkaze-input-bar input {
  flex: 1;
  border: 1px solid var(--alkaze-gray-2);
  border-radius: 22px;
  padding: 10px 16px;
  font-size: 14px;
  outline: none;
  font-family: inherit;
}
.alkaze-input-bar input:focus { border-color: var(--alkaze-red); }
.alkaze-send-btn {
  background: var(--alkaze-red);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  transition: background 0.2s;
  flex-shrink: 0;
}
.alkaze-send-btn:hover { background: var(--alkaze-red-dark); }
.alkaze-send-btn svg { width: 18px; height: 18px; }

/* FOOTER */
.alkaze-footer {
  text-align: center;
  padding: 6px;
  font-size: 11px;
  color: var(--alkaze-gray-3);
  background: white;
  border-top: 1px solid var(--alkaze-gray-2);
}
.alkaze-footer strong { color: var(--alkaze-red); }

/* Yazıyor animasyonu */
.alkaze-typing {
  display: inline-flex;
  gap: 4px;
  padding: 4px 0;
}
.alkaze-typing span {
  width: 6px;
  height: 6px;
  background: var(--alkaze-gray-3);
  border-radius: 50%;
  animation: alkazeTypingBounce 1.4s infinite;
}
.alkaze-typing span:nth-child(2) { animation-delay: 0.2s; }
.alkaze-typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes alkazeTypingBounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-6px); opacity: 1; }
}

/* Scrollbar */
.alkaze-chat-messages::-webkit-scrollbar { width: 6px; }
.alkaze-chat-messages::-webkit-scrollbar-track { background: transparent; }
.alkaze-chat-messages::-webkit-scrollbar-thumb {
  background: var(--alkaze-gray-2);
  border-radius: 3px;
}
