/* ===========================
   Q&A WIDGET STYLES
   =========================== */

#qna-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 9998;
  padding: 12px 16px;
  background-color: var(--primary-color);
  color: white;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(232, 27, 57, 0.3);
  transition: all 0.3s ease;
  min-height: 44px;
  min-width: 44px;
  display: flex;
  align-items: center;
  gap: 8px;
}

#qna-button:hover {
  background-color: #c41630;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(232, 27, 57, 0.4);
}

#qna-button:active {
  transform: translateY(0);
}

.qna-drawer {
  position: fixed;
  bottom: 80px;
  right: 20px;
  z-index: 9999;
  width: 100%;
  max-width: 380px;
  max-height: 500px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: all 0.3s ease;
}

.qna-drawer.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.qna-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  border-bottom: 1px solid #f0f0f0;
}

.qna-header h3 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--text-dark);
}

.qna-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-light);
  transition: color 0.2s ease;
  padding: 0;
  min-width: 36px;
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.qna-close:hover {
  color: var(--text-dark);
}

.qna-content {
  flex: 1;
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.qna-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.qna-chip {
  padding: 8px 12px;
  background-color: #f0f0f0;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
  font-weight: 500;
  color: var(--text-dark);
}

.qna-chip:hover {
  background-color: rgba(232, 27, 57, 0.1);
  border-color: var(--primary-color);
  color: var(--primary-color);
}

.qna-chip:active {
  transform: scale(0.95);
}

.qna-input {
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 0.9rem;
  font-family: inherit;
  transition: all 0.2s ease;
}

.qna-input:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(232, 27, 57, 0.1);
}

.qna-answer {
  min-height: 80px;
  padding: 12px;
  background-color: #f9f9f9;
  border-radius: 6px;
  border-left: 3px solid var(--primary-color);
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text-dark);
}

.qna-answer p {
  margin: 0 0 10px 0;
  font-size: 0.9rem;
}

.qna-answer p:last-child {
  margin-bottom: 0;
}

.qna-link {
  display: inline-block;
  color: var(--primary-color);
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  margin-top: 8px;
}

.qna-link:hover {
  color: #c41630;
  text-decoration: underline;
}

.qna-feedback {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 8px 0 0 0;
}

.qna-feedback p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-light);
  font-weight: 600;
}

.qna-thumb {
  padding: 8px 12px;
  background-color: #f0f0f0;
  border: 1px solid #ddd;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.2s ease;
  font-weight: 500;
}

.qna-thumb:hover {
  background-color: #e8e8e8;
}

/* Mobile Responsive */
@media (max-width: 480px) {
  .qna-drawer {
    bottom: 0;
    right: 0;
    left: 0;
    max-width: none;
    max-height: 70vh;
    border-radius: 12px 12px 0 0;
  }

  #qna-button {
    bottom: 20px;
    right: 20px;
    font-size: 0.9rem;
    padding: 10px 14px;
  }

  .qna-chips {
    gap: 6px;
  }

  .qna-chip {
    padding: 7px 10px;
    font-size: 0.8rem;
  }

  .qna-content {
    gap: 10px;
    padding: 14px;
  }
}

@media (max-height: 700px) {
  .qna-drawer {
    max-height: 80vh;
  }

  .qna-content {
    gap: 8px;
    padding: 12px;
  }
}
