/* 加密文章访问门槛样式 */

.bb-gate {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 2.5em 0;
}

.bb-gate-card {
  width: 100%;
  max-width: 380px;
  padding: 2em 1.6em;
  background: var(--code-bg, #f5f5f5);
  border: 1px solid var(--border, #e2e2e2);
  border-radius: 14px;
  text-align: center;
  box-sizing: border-box;
}

.bb-gate-icon {
  font-size: 2.4em;
  line-height: 1;
  margin-bottom: 0.4em;
}

.bb-gate-title {
  margin: 0 0 0.35em;
  font-size: 1.25em;
  font-weight: 600;
}

.bb-gate-hint {
  margin: 0 0 1.1em;
  color: var(--secondary, #888);
  font-size: 0.95em;
  line-height: 1.5;
}

.bb-gate-form {
  display: flex;
  gap: 0.5em;
  margin-bottom: 0.4em;
}

.bb-gate-form input {
  flex: 1;
  min-width: 0;
  padding: 0.55em 0.8em;
  font-size: 1em;
  border: 1px solid var(--border, #ccc);
  border-radius: 8px;
  background: var(--theme, #fff);
  color: var(--content, #222);
  outline: none;
  transition: border-color 0.15s;
}

.bb-gate-form input:focus {
  border-color: var(--primary, #555);
}

.bb-gate-form button {
  padding: 0.55em 1.2em;
  font-size: 1em;
  border: 0;
  border-radius: 8px;
  background: var(--primary, #333);
  color: var(--theme, #fff);
  cursor: pointer;
  white-space: nowrap;
}

.bb-gate-form button:hover {
  filter: brightness(1.08);
}

.bb-gate-error {
  margin: 0.6em 0 0;
  color: #c0392b;
  font-size: 0.9em;
}

.bb-gate-foot {
  margin: 1.1em 0 0;
  font-size: 0.85em;
  color: var(--secondary, #888);
}

.bb-gate-foot a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px dotted currentColor;
}

@keyframes bb-shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-7px); }
  40% { transform: translateX(7px); }
  60% { transform: translateX(-5px); }
  80% { transform: translateX(5px); }
}

.bb-gate.shake .bb-gate-card {
  animation: bb-shake 0.32s ease;
}

/* 解锁后正文里嵌的图、代码块继承主题样式即可 */
#bb-protected-content {
  margin-top: 1em;
}
