/* 生成记录 / 作品详情 — 移动端 */

@media (max-width: 720px) {
  body.page-records.mobile-records-page .site-header,
  body.page-records.mobile-record-detail-page .site-header {
    display: none !important;
  }
}

body.page-records.mobile-records-page .app-shell,
body.page-records.mobile-record-detail-page .app-shell {
  width: 100%;
  max-width: none;
  padding: 0;
}

body.page-records.mobile-records-page,
body.page-records.mobile-record-detail-page {
  background: #f5f7fa;
}

.mobile-records-shell {
  max-width: 520px;
  margin: 0 auto;
  padding: max(6px, env(safe-area-inset-top, 0px)) 0 calc(88px + env(safe-area-inset-bottom, 0px));
}

.mobile-records-shell .mobile-home-header {
  padding-left: 16px;
  padding-right: 16px;
  margin-bottom: 4px;
}

.mobile-records-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 8px 16px 12px;
}

.mobile-records-head__title {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 800;
  color: #101828;
  letter-spacing: -0.03em;
}

.mobile-records-head__sub {
  margin: 0;
  font-size: 13px;
  color: #667085;
}

.mobile-records-tabs {
  display: flex;
  gap: 8px;
  padding: 0 16px 14px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.mobile-records-tabs::-webkit-scrollbar {
  display: none;
}

.mobile-records-tabs__item {
  flex-shrink: 0;
  padding: 8px 14px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #e8eef5;
  font-size: 13px;
  font-weight: 600;
  color: #475467;
  text-decoration: none;
  white-space: nowrap;
}

.mobile-records-tabs__item.is-active {
  background: #1e80ff;
  border-color: #1e80ff;
  color: #fff;
  box-shadow: 0 4px 12px rgba(30, 128, 255, 0.28);
}

.mobile-records-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0 16px;
}

.mobile-records-empty {
  padding: 48px 16px;
  text-align: center;
  font-size: 14px;
  color: #98a2b3;
  background: #fff;
  border-radius: 16px;
}

.mobile-records-card {
  display: flex;
  gap: 12px;
  padding: 12px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(16, 24, 40, 0.06);
}

.mobile-records-card__thumb {
  flex-shrink: 0;
  width: 88px;
  height: 88px;
  border-radius: 12px;
  overflow: hidden;
  background: #f2f4f7;
  display: block;
  text-decoration: none;
}

.mobile-records-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.mobile-records-card__ph {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  font-size: 11px;
  font-weight: 600;
  color: #98a2b3;
  padding: 6px;
  text-align: center;
}

.mobile-records-card__body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mobile-records-card__top {
  display: flex;
  align-items: flex-start;
  gap: 6px;
}

.mobile-records-card__title {
  flex: 1;
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: #101828;
  line-height: 1.35;
  text-decoration: none;
}

.mobile-records-card__more {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #98a2b3;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.mobile-records-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mobile-records-card__tags span {
  padding: 3px 8px;
  border-radius: 6px;
  background: #f2f4f7;
  font-size: 11px;
  font-weight: 600;
  color: #667085;
}

.mobile-records-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
}

.mobile-records-card__foot time {
  font-size: 11px;
  color: #98a2b3;
}

.mobile-records-card__regen {
  flex-shrink: 0;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid #1e80ff;
  background: #fff;
  color: #1e80ff;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.mobile-records-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 16px;
}

.mobile-records-pagination__btn {
  padding: 8px 14px;
  border-radius: 10px;
  border: 1px solid #e4e7ec;
  background: #fff;
  font-size: 13px;
  font-weight: 600;
  color: #344054;
  text-decoration: none;
}

.mobile-records-pagination__btn.is-disabled {
  opacity: 0.45;
  pointer-events: none;
}

.mobile-records-pagination__info {
  font-size: 13px;
  color: #667085;
}

/* —— 作品详情（布局与精选详情共用 mobile-feat-detail-*，此处仅补充差异样式） —— */
.mobile-record-detail-shell {
  /* 保留 class 供 desktop-mobile-frame 等选择器使用 */
}

.mobile-record-detail-hero__placeholder {
  min-height: 200px;
  display: grid;
  place-items: center;
  background: #f2f4f7;
  color: #98a2b3;
  font-weight: 600;
}

.mobile-record-detail-error {
  margin: 12px 0 0;
  padding: 10px;
  border-radius: 10px;
  background: #fef2f2;
  color: #b42318;
  font-size: 12px;
  line-height: 1.45;
}

body.page-records.mobile-record-detail-page:has(.image-viewer:not(.hidden)) {
  overflow: hidden;
}

body.page-records.mobile-record-detail-page .image-viewer {
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 0;
  padding: 12px 12px 0;
  background: rgba(71, 85, 105, 0.68);
}

body.page-records.mobile-record-detail-page .image-viewer-toolbar {
  display: none !important;
}

body.page-records.mobile-record-detail-page .image-viewer-footer {
  display: flex;
  background: transparent;
  border: none;
  padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
}

body.page-records.mobile-record-detail-page .image-viewer-stage {
  border: none;
  background: transparent;
}

body.page-records.mobile-record-detail-page .image-viewer-footer-btn--close {
  width: 48px;
  height: 48px;
  min-width: 48px;
  min-height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  box-shadow: none;
}

.mobile-feat-detail-btn--primary {
  text-decoration: none;
  box-sizing: border-box;
}

.mobile-feat-detail-btn--outline {
  font: inherit;
  appearance: none;
  -webkit-appearance: none;
}

/* 分享卡片弹层 */
.mobile-record-share {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0 12px calc(12px + env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
}

.mobile-record-share.hidden {
  display: none;
}

.mobile-record-share__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
}

.mobile-record-share__panel {
  position: relative;
  width: min(100%, 400px);
  max-height: min(88vh, 720px);
  overflow: auto;
  border-radius: 20px 20px 16px 16px;
  background: #fff;
  padding: 18px 16px 16px;
  box-shadow: 0 -8px 40px rgba(15, 23, 42, 0.18);
}

.mobile-record-share__heading {
  margin: 0 0 14px;
  font-size: 17px;
  font-weight: 800;
  color: #101828;
  text-align: center;
}

.mobile-record-share__card {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid #eef2f6;
  background: #f8fafc;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.mobile-record-share__card-media {
  background: #e8eef5;
  line-height: 0;
}

.mobile-record-share__card-img {
  width: 100%;
  max-height: 52vh;
  object-fit: contain;
  display: block;
  background: #fff;
}

.mobile-record-share__card-body {
  padding: 12px 14px 14px;
  background: linear-gradient(180deg, #fff 0%, #f8fbff 100%);
}

.mobile-record-share__card-title {
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 700;
  color: #101828;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mobile-record-share__card-meta {
  margin: 0 0 8px;
  font-size: 12px;
  color: #667085;
}

.mobile-record-share__card-brand {
  margin: 0;
  font-size: 11px;
  font-weight: 700;
  color: #1e80ff;
}

.mobile-record-share__actions {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.mobile-record-share__btn {
  width: 100%;
  min-height: 44px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  border: 0;
  cursor: pointer;
}

.mobile-record-share__btn--primary {
  color: #fff;
  background: linear-gradient(135deg, #1e80ff, #3b9bff);
  box-shadow: 0 6px 16px rgba(30, 128, 255, 0.28);
}

.mobile-record-share__btn--outline {
  color: #1e80ff;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
}

.mobile-record-share__cancel {
  display: block;
  width: 100%;
  margin-top: 10px;
  padding: 10px;
  border: 0;
  background: transparent;
  font-size: 14px;
  font-weight: 600;
  color: #667085;
  cursor: pointer;
}
