[hidden] {
  display: none !important;
}

.qaq-community-panel {
  position: absolute !important;
  inset: 0 !important;
  z-index: 3100;
  display: flex;
  flex-direction: column;
  width: 100% !important;
  height: 100% !important;
  background: #fafafa;
  overflow: hidden;
}

.qaq-community-head {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) 64px;
  align-items: center;
  flex: 0 0 auto;
  min-height: calc(56px + env(safe-area-inset-top, 0px));
  padding: calc(8px + env(safe-area-inset-top, 0px))
    12px 8px;
  border-bottom: 1px solid #ededed;
  background: #fff;
}

.qaq-community-head strong {
  text-align: center;
  font-size: 16px;
}

.qaq-community-head > button:last-child {
  justify-self: end;
}

.qaq-community-head button i {
  font-size: 19px;
}

.qaq-auth-view,
.qaq-account-view {
  max-width: 320px;
  width: calc(100% - 36px);
  margin: 24px auto;
}

.qaq-auth-view {
  display: flex;
  flex-direction: column;
  justify-content: center;
  flex: 1 1 auto;
  padding: 20px;
}

.qaq-auth-form {
  display: grid;
  gap: 9px;
}

.qaq-auth-form input {
  min-height: 40px;
  padding: 0 11px;
  border: 1px solid #ddd;
  border-radius: 10px;
  background: #fff;
  color: #222;
  user-select: text;
}

.qaq-auth-form button,
.qaq-account-view > button {
  min-height: 40px;
  border-radius: 10px;
  background: #292929;
  color: #fff;
}

.qaq-auth-message:empty {
  display: none;
}

.qaq-account-view {
  display: grid;
  gap: 10px;
}

.qaq-community-dock {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  flex: 0 0 auto;
  min-height: calc(68px + env(safe-area-inset-bottom, 0px));
  padding: 8px 10px
    env(safe-area-inset-bottom, 0px);
  border-top: 1px solid #ededed;
  background: #fff;
}

.qaq-community-dock button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: transparent;
  color: #858585;
  font-size: 11px;
}

.qaq-community-dock button i {
  font-size: 23px;
}

.qaq-community-dock button.qaq-active {
  color: #111;
}

.qaq-community-head button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 36px;
  padding: 6px 8px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #333;
  font-size: 13px;
}

.qaq-community-back {
  justify-self: start;
  gap: 5px;
}

.qaq-community-back i {
  font-size: 14px;
}

.qaq-community-back span {
  font-size: 12px;
}

.qaq-community-refresh {
  justify-self: end;
}

.qaq-community-refresh i {
  font-size: 18px;
}

.qaq-community-refresh.qaq-refreshing i {
  animation: qaq-community-rotate 500ms linear;
}

@keyframes qaq-community-rotate {
  to {
    transform: rotate(360deg);
  }
}

.qaq-publish-view {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
  padding: 18px;
  overflow: hidden;
  background: #fff;
}

.qaq-publish-view textarea {
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
  padding: 4px 0;
  border: 0;
  outline: 0;
  resize: none;
  background: transparent;
  color: #222;
  font: inherit;
  font-size: 16px;
  line-height: 1.7;
  user-select: text;
  -webkit-user-select: text;
}

.qaq-publish-view textarea::placeholder {
  color: #a0a0a0;
}

.qaq-publish-tools {
  display: flex;
  flex: 0 0 auto;
  gap: 10px;
  padding: 14px 0;
  border-top: 1px solid #ededed;
}

.qaq-publish-tools button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 11px;
  border-radius: 9px;
  background: #eeeeee;
  color: #444;
  font-size: 12px;
}

.qaq-publish-tools button i {
  font-size: 15px;
}

.qaq-toast {
  position: absolute;
  left: 50%;
  bottom: calc(86px + env(safe-area-inset-bottom, 0px));
  z-index: 6000;
  max-width: calc(100% - 48px);
  padding: 10px 15px;
  border-radius: 11px;
  background: rgba(40, 40, 40, 0.92);
  color: #fff;
  font-size: 13px;
  text-align: center;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, 10px);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.qaq-toast-show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.qaq-toast[data-qaq-type="error"] {
  background: rgba(130, 45, 45, 0.94);
}

.qaq-auth-heading {
  margin-bottom: 18px;
  color: #111;
  font-size: 22px;
  font-weight: 700;
  text-align: center;
}

.qaq-auth-form input {
  width: 100%;
  outline: none;
  font-size: 13px;
  -webkit-user-select: text;
  user-select: text;
}

.qaq-auth-form button {
  font-size: 13px;
  font-weight: 600;
}

.qaq-auth-switch {
  margin-top: 14px;
  color: #8e8e93;
  font-size: 13px;
  text-align: center;
}

.qaq-auth-switch button {
  min-height: auto;
  padding: 0;
  background: transparent;
  color: #007aff;
  font-size: 13px;
  font-weight: 600;
}

.qaq-auth-message {
  min-height: 20px;
  margin: 0 auto;
  color: #777;
  font-size: 12px;
  text-align: center;
}

.qaq-auth-message.qaq-error {
  color: #a33;
}

