/* ===== 全站访问门（进入网站先验证密码）=====
   布局参考私密行程访问页：顶部 PRIVATE 栏 + 大标题 + 深色卡（卡内白色表单），
   配色沿用全站绿色主题。 */
body.access-locked > :not(#access-gate) { display: none !important; }

.access-gate {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow-y: auto;
  padding: 18px 20px 30px;
  background: #f6f9ef;
}
.access-gate[hidden] { display: none; }
.access-gate__inner { width: 100%; max-width: 420px; display: flex; flex-direction: column; }

.access-gate__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--muted);
  font: 700 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .18em;
}
.access-gate__bar i { font-style: normal; font-size: 14px; }

.access-gate__eyebrow {
  margin: 34px 0 0;
  color: var(--lake);
  font: 760 11px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .22em;
}
.access-gate__title {
  margin: 10px 0 0;
  color: var(--ink);
  font-size: clamp(30px, 9vw, 38px);
  line-height: 1.05;
  letter-spacing: -.04em;
  font-weight: 830;
}
.access-gate__sub { margin: 10px 0 0; color: var(--muted); font-size: 13px; line-height: 1.6; }

.access-gate__card {
  margin-top: 20px;
  border-radius: 18px;
  background: linear-gradient(165deg, #2a4232 0%, #1b2f22 55%, #132218 100%);
  box-shadow: 0 18px 40px rgba(19, 34, 24, .22);
  overflow: hidden;
}
.access-gate__card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 18px 4px;
  color: #9db691;
  font: 700 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .16em;
}
.access-gate__card-title {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px 16px;
}
.access-gate__card-title b { color: #f4faf0; font-size: 15px; font-weight: 780; letter-spacing: .02em; }
.access-gate__card-title i {
  flex: 1 1 auto;
  height: 0;
  border-top: 1px dashed rgba(244, 250, 240, .3);
}
.access-gate__card-title span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #cde5b9;
  font: 700 10px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .14em;
}
.access-gate__card-title span::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: 1.5px solid #cde5b9;
}

.access-gate__form {
  padding: 16px 18px 18px;
  background: #fff;
}
.access-gate__form > p { margin: 0 0 12px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.access-gate__label { display: block; margin-bottom: 7px; color: var(--ink); font-size: 12px; font-weight: 720; }
.access-gate__field { position: relative; }
.access-gate__field input {
  width: 100%;
  min-height: 52px;
  padding: 0 46px 0 14px;
  border: 1px solid rgba(27, 44, 33, .14);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font-size: 16px;
  letter-spacing: .18em;
  outline: none;
}
.access-gate__field input:focus { border-color: var(--lake); box-shadow: 0 0 0 3px rgba(85, 166, 48, .12); }
.access-gate__field input.is-shaking { animation: access-shake .4s ease; }
@keyframes access-shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  55% { transform: translateX(5px); }
  80% { transform: translateX(-3px); }
}
.access-gate__eye {
  position: absolute;
  top: 50%;
  right: 6px;
  transform: translateY(-50%);
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  color: var(--muted);
}
.access-gate__eye.is-visible { color: var(--lake); }

.access-gate__error { margin: 8px 0 0; color: var(--terracotta); font-size: 11.5px; font-weight: 640; }
.access-gate__remember {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 13px;
  color: var(--muted);
  font-size: 11.5px;
  cursor: pointer;
}
.access-gate__remember input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--lake);
}
.access-gate__submit {
  width: 100%;
  min-height: 52px;
  margin-top: 14px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(160deg, #61b23a 0%, #55a630 48%, #47922a 100%);
  color: #fff;
  font-size: 15px;
  font-weight: 780;
  letter-spacing: .04em;
  cursor: pointer;
}
.access-gate__submit:active { filter: brightness(.94); }
.access-gate__submit:disabled { opacity: .72; cursor: progress; filter: saturate(.85); }
.access-gate__submit:focus-visible { outline: 2px solid #55a630; outline-offset: 2px; }
.access-gate__form-hint { margin: 13px 0 0; color: var(--muted); font-size: 11px; text-align: center; }

.access-gate__foot {
  margin-top: 22px;
  color: var(--muted);
  font: 700 9px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .2em;
}

/* ===== 顶栏分享按钮 ===== */
.topbar .topbar-share {
  min-width: 44px;
  min-height: 44px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(27, 44, 33, .14);
  border-radius: 999px;
  background: #fff;
  color: var(--lake);
  font-size: 12px;
  font-weight: 750;
  cursor: pointer;
}
.topbar .topbar-share:active { background: #edf5e3; }

/* ===== 分享弹窗 ===== */
.share-dialog {
  width: min(360px, 92vw);
  padding: 0;
  border: 0;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(27, 44, 33, .28);
  overflow: hidden;
}
.share-dialog::backdrop { background: rgba(27, 44, 33, .45); }
.share-dialog__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 18px;
  background: #edf5e3;
}
.share-dialog__head b { color: var(--forest); font-size: 14px; font-weight: 800; }
.share-dialog__head button {
  min-width: 32px;
  min-height: 32px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, .7);
  color: var(--forest);
  font-size: 12px;
  cursor: pointer;
}
.share-dialog__body { padding: 14px 18px 18px; }
.share-dialog__link {
  display: flex;
  gap: 8px;
  align-items: center;
}
.share-dialog__link input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid rgba(27, 44, 33, .13);
  border-radius: 10px;
  background: #fafcf5;
  color: var(--muted);
  font-size: 11px;
  outline: none;
}
.share-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}
.share-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 14px 8px 12px;
  border: 1px solid rgba(27, 44, 33, .1);
  border-radius: 14px;
  background: #fafcf5;
  cursor: pointer;
}
.share-option i { font-style: normal; font-size: 24px; line-height: 1; }
.share-option b { color: var(--ink); font-size: 12.5px; font-weight: 760; }
.share-option span { color: var(--muted); font-size: 10px; line-height: 1.4; }
.share-option:active { background: #edf5e3; border-color: rgba(85, 166, 48, .35); }
.share-copy-feedback { margin: 10px 0 0; color: var(--lake); font-size: 11.5px; font-weight: 680; text-align: center; }
.share-qr { margin-top: 14px; padding-top: 14px; border-top: 1px dashed rgba(27, 44, 33, .12); text-align: center; }
.share-qr svg { width: 180px; height: 180px; }
.share-qr p { margin: 8px 0 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
