/* TravelStamps 1.0 — 100 城完整印章（520×520 矢量）。
 * 规则来自素材包 travel-stamps.css，必须放在 design/edition/polish/v2-app 之后：
 * 旧 .stamp::before/::after 会额外画环，旧 .stamp svg 会把完整章压成 65×42。
 * 仅作用于 .stamp.travel-stamp（命中专属章的按钮），未收录城市继续使用旧模板。
 * 字形轮廓许可见 assets/travel-stamps.js 头部：SIL OFL 1.1。 */
.stamp.travel-stamp {
  padding: 0 !important;
  gap: 0 !important;
  border: 0 !important;
  border-radius: 0;
  background: transparent !important;
  box-shadow: none;
  overflow: visible;
  line-height: 0;
  cursor: pointer;
}
.stamp.travel-stamp::before,
.stamp.travel-stamp::after {
  content: none !important;
  display: none !important;
}
.stamp.travel-stamp > svg.travel-stamp-svg {
  display: block;
  width: 100% !important;
  height: 100% !important;
  max-width: none;
  flex: 0 0 auto;
  pointer-events: none;
  overflow: visible;
}
/* 兼容节点：集章册交互与既有 e2e 依赖 <b> / 三个 <small> / data-city，
 * 完整章已把城名、日期、编号、状态画进 SVG，这里只做视觉隐藏，
 * 保留 DOM 与可访问文本（不用 display:none，避免 innerText 失效）。 */
.stamp.travel-stamp > b,
.stamp.travel-stamp > small {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
  border: 0 !important;
  pointer-events: none;
}
.stamp.travel-stamp:focus-visible {
  outline: 2px solid #4E6586;
  outline-offset: 5px;
}

/* 回退章（未收录城市）与 100 城完整章「同形制同尺寸、同双环格式」。
 *
 * 素材 rings 分组：外环 stroke-width 7.0 实线、内环 2.2 手绘虚线，
 * 在 520 画布缩到 ~176px 按钮后正是 2px / 1px；两环间距约 3.5% 画布。
 * 旧模板沿用 2px 实线外环 + 1px 虚线内环，间距统一到 4% 按钮宽。
 * 计划章外环虚线仍由 .stamp.plan 原规则生效，与素材计划章一致。
 *
 * 各形制外环边界（520 画布，逐像素实测 116 张 SVG）：
 *   正圆 464 / 圆角方 440 / 超椭圆·花边圆 468
 * → inset = (520 - 边界)/2/520：shape0 5.4%、shape1 7.7%、shape2 5%。
 * 这样「方章对方章」的边长与素材 rounded-rect 完全相等，圆/超椭圆同理；
 * 保留 .shape1 圆角方与 .shape2 超椭圆外形，不再一律压成圆形。 */
.stamp:not(.travel-stamp)::before,
.stamp:not(.travel-stamp)::after { border-radius: 50% !important; }
.stamp:not(.travel-stamp)::before { inset: 5.4% !important; }
.stamp:not(.travel-stamp)::after  { inset: 9.4% !important; }

.stamp.shape1:not(.travel-stamp)::before,
.stamp.shape1:not(.travel-stamp)::after { border-radius: 9% !important; }
.stamp.shape1:not(.travel-stamp)::before { inset: 7.7% !important; }
.stamp.shape1:not(.travel-stamp)::after  { inset: 11.7% !important; }

.stamp.shape2:not(.travel-stamp)::before,
.stamp.shape2:not(.travel-stamp)::after { border-radius: 42% !important; }
.stamp.shape2:not(.travel-stamp)::before { inset: 5% !important; }
.stamp.shape2:not(.travel-stamp)::after  { inset: 9% !important; }
@media (prefers-reduced-motion: reduce) {
  .stamp.travel-stamp { transition: none !important; }
}
