/* 网页链接视频卡片：占位图 + 点击观看 */
.media-card-link {
  display: flex;
  flex-direction: column;
}

.media-link-placeholder {
  min-height: 140px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.85);
}

.media-link-icon {
  font-size: 32px;
  opacity: 0.9;
}

.media-link-hint {
  margin: 0;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
}

/* 链接视频封面：视频/占位 + 点击观看叠加 */
.media-link-cover {
  display: block;
  position: relative;
  min-height: 140px;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(42, 34, 48, 0.92);
  color: inherit;
}

.media-link-cover video {
  width: 100%;
  height: 100%;
  min-height: 140px;
  object-fit: cover;
  display: block;
}

.media-link-cover .media-link-placeholder {
  position: absolute;
  inset: 0;
  min-height: auto;
}

.media-link-play {
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(244, 114, 182, 0.9);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

.media-link-cover:hover .media-link-play,
.media-link-cover:focus-visible .media-link-play {
  background: rgba(251, 113, 133, 0.95);
}

.btn-inline {
  margin-top: 10px;
}

.btn-watch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity 0.18s ease-out, transform 0.1s ease-out;
}

.btn-watch:hover,
.btn-watch:focus-visible {
  opacity: 0.95;
  transform: translateY(-1px);
}

/* 关于我 · 一键下载简历 */
.about-download {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.btn-download-resume {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: opacity 0.18s ease-out, transform 0.1s ease-out;
}

.btn-download-resume:hover,
.btn-download-resume:focus-visible {
  opacity: 0.95;
  transform: translateY(-2px);
}

.btn-download-icon {
  font-size: 18px;
}

.about-download-hint {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--muted);
}

.about-download-hint code {
  background: rgba(0, 0, 0, 0.06);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
}

/* Banner 拉高、居中、简约 */
.section-home {
  min-height: 60vh;
}

.home-brief {
  margin: 8px 0 0;
  font-size: 14px;
  color: var(--muted);
}

@media (min-width: 768px) {
  .home-brief {
    font-size: 15px;
  }
}

/* 关于我 · 爱好照片 */
.about-hobby {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.about-hobby-title {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 600;
}

.about-photos {
  margin-top: 10px;
}

/* 小猫小狗：两大图横排 */
.about-photos-pets {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.about-photos-pets .image-thumb-button {
  display: block;
  padding: 0;
  border-radius: 14px;
  overflow: hidden;
  border: none;
  background: none;
  cursor: pointer;
  position: relative;
  aspect-ratio: 4 / 3;
}

.about-photos-pets .image-thumb-button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s ease-out;
}

.about-photos-pets .image-thumb-button:hover img {
  transform: scale(1.04);
}

@media (max-width: 520px) {
  .about-photos-pets {
    grid-template-columns: 1fr;
  }
}

.about-photo-label {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 8px 10px;
  background: linear-gradient(transparent, rgba(0,0,0,0.6));
  color: #fff;
  font-size: 13px;
  text-align: center;
}

/* 旅游：横向滚动大图 */
.about-photos-travel {
  margin-top: 8px;
  display: flex;
  gap: 14px;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 6px;
  scroll-snap-type: x proximity;
}

.about-photos-travel .image-thumb-button {
  flex: 0 0 auto;
  width: 200px;
  display: block;
  padding: 0;
  border-radius: 12px;
  overflow: hidden;
  border: none;
  background: none;
  cursor: pointer;
  position: relative;
  scroll-snap-align: start;
}

.about-photos-travel .image-thumb-button img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  display: block;
  transition: transform 0.2s ease-out;
}

.about-photos-travel .image-thumb-button:hover img {
  transform: scale(1.04);
}

.about-photos-travel .about-photo-label {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 6px 8px;
  background: linear-gradient(transparent, rgba(0,0,0,0.65));
  color: #fff;
  font-size: 12px;
  text-align: center;
}

/* 教育经历：缩减留白 */
.section-education {
  padding-top: 32px;
  padding-bottom: 32px;
}

.section-education .section-header {
  margin-bottom: 16px;
}

.section-education .experience-list {
  gap: 0;
}

.section-education .experience-item {
  padding-top: 12px;
  padding-bottom: 12px;
}

@media (min-width: 768px) {
  .section-education {
    padding-top: 40px;
    padding-bottom: 40px;
  }
}

/* 图文 · 公众号长图 9:16 竖版，纵向滑动 */
.gallery-long-wrap {
  aspect-ratio: 9 / 16;
  max-height: 70vh;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  border-radius: 10px;
  background: rgba(42, 34, 48, 0.04);
}

.gallery-long-wrap .image-thumb-button {
  display: block;
  width: 100%;
  padding: 0;
  border: none;
  border-radius: 0;
  background: none;
  cursor: pointer;
}

.gallery-long-wrap img {
  width: 100%;
  height: auto;
  display: block;
  vertical-align: top;
  transition: transform 0.18s ease-out;
}

.gallery-long .gallery-long-wrap .image-thumb-button:hover img {
  transform: scale(1.01);
}

.gallery-long .btn-watch {
  margin-top: 10px;
}

/* 图文 · 人像单图（非长图） */
.gallery-slider {
  display: block;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(42, 34, 48, 0.04);
}

.gallery-slider .image-thumb-button {
  display: block;
  width: 100%;
  padding: 0;
  border: none;
  border-radius: 0;
  background: none;
  cursor: pointer;
}

.gallery-slider img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.18s ease-out;
}

.gallery-card:hover .gallery-slider img,
.gallery-card:focus-within .gallery-slider img {
  transform: scale(1.02);
}

.gallery-card .btn-watch {
  margin-top: 10px;
}

/* 文字作品 · PDF 嵌入，字更大 */
.text-embed-wrap {
  width: 100%;
  min-height: 55vh;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border);
  margin-bottom: 12px;
}

.text-pdf {
  width: 100%;
  height: 55vh;
  min-height: 420px;
  border: 0;
  display: block;
}

.text-item .text-full {
  font-size: 1.05rem;
  line-height: 1.85;
}

/* 文字作品：右侧展开符号 ▼ */
.text-toggle {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-right: 12px;
}

.text-toggle-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.text-toggle-icon {
  flex-shrink: 0;
  font-size: 12px;
  color: var(--muted);
  transition: transform 0.2s ease-out;
}

.text-item.is-open .text-toggle-icon {
  transform: rotate(180deg);
}

.text-docx-fallback {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 12px;
}

.text-docx-fallback code {
  background: rgba(0, 0, 0, 0.06);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 12px;
}

.text-docx-body {
  font-size: 1.05rem;
  line-height: 1.85;
  margin-bottom: 12px;
}

.btn-expand-text {
  padding: 10px 18px;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.18s, transform 0.1s;
}

.btn-expand-text:hover,
.btn-expand-text:focus-visible {
  opacity: 0.95;
  transform: translateY(-1px);
}

/* 文字/PDF 放大弹窗 */
.text-viewer-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 40;
}

.text-viewer-modal.is-open {
  display: flex;
}

.text-viewer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(30, 20, 35, 0.75);
}

.text-viewer-content {
  position: relative;
  z-index: 1;
  width: min(94vw, 960px);
  max-height: 90vh;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.text-viewer-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 20px;
  cursor: pointer;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}

.text-viewer-inner {
  flex: 1;
  overflow: auto;
  padding: 48px 20px 24px 20px;
}

.text-viewer-inner iframe {
  width: 100%;
  height: 82vh;
  min-height: 560px;
  border: 0;
  display: block;
}

.text-viewer-inner .text-viewer-html {
  font-size: 1.15rem;
  line-height: 1.9;
  color: #2a2230;
}

.text-viewer-inner .text-viewer-html p {
  margin: 0 0 0.8em;
}

/* 联系方式 · 微信二维码 */
.contact-item-wechat {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.9);
  min-height: 48px;
}

.contact-qr {
  width: 100px;
  height: 100px;
  object-fit: contain;
  border-radius: 8px;
  margin-top: 4px;
}

/* 图片预览弹窗：适当大小、适配视窗，不滚动 */
.image-modal-content {
  max-width: min(88vw, 880px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.image-modal-content img {
  max-width: 100%;
  max-height: 72vh;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  border-radius: 10px;
}

.image-modal-title {
  flex-shrink: 0;
}

/* 9:16 视频排成一排：蓬皮杜、刘小东、艺术家在场 */
.video-row-9-16 {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

@media (max-width: 900px) {
  .video-row-9-16 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .video-row-9-16 {
    grid-template-columns: 1fr;
  }
}

.media-card-9-16 {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.media-video-9-16 {
  aspect-ratio: 9 / 16;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(42, 34, 48, 0.92);
}

.media-video-9-16 video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.media-card-9-16 .media-link-cover {
  aspect-ratio: 9 / 16;
  min-height: 0;
}

.media-card-9-16 .media-link-cover video {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
}

.btn-fullscreen {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--accent-soft);
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, border-color 0.18s;
}

.btn-fullscreen:hover,
.btn-fullscreen:focus-visible {
  background: rgba(244, 114, 182, 0.2);
  border-color: rgba(244, 114, 182, 0.5);
}

.media-card-link .btn-watch {
  margin-top: 10px;
}
