html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  margin: 0;
  background-color: #f3f4f6;
  color: #1f2937;
  line-height: 1.6;
  padding-top: 70px; /* 为电脑端固定头部留出空间 */
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
}

/* On larger screens, allow the container to be wider */
@media (min-width: 1536px) {

  /* Tailwind 2xl breakpoint */
  .container {
    max-width: 1440px;
    /* Adjust as needed */
  }
}

/* 电脑端头部导航栏样式 */
.desktop-header {
  background-color: #f1f1f1;
  color: white;
  padding: 0.6rem 0 0.6rem 10%;
  text-align: left;
  margin-bottom: 1rem;
  border-radius: 0;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.desktop-header nav ul {
  list-style-type: none;
  padding: 0;
}

.desktop-header nav ul li {
  display: inline;
  margin: 0;
}

.desktop-header nav ul li a {
  color: rgb(7, 7, 7);
  text-decoration: none;
  font-weight: 500;
  font-size: 1.17rem;
  padding: 0.9rem 1.2rem;
  border-radius: 0.15rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.desktop-header nav ul li a:hover {
  background-color: #474747;
  color: white;
  transform: none;
  box-shadow: none;
  text-shadow: none;
}

/* 移除下划线动画效果 */
.desktop-header nav ul li a::after {
  display: none;
}

/* 桌面端导航样式 */
.desktop-nav ul {
  list-style-type: none;
  padding: 0;
}

.desktop-nav ul li {
  display: inline;
  margin: 0 1rem;
}

.desktop-nav ul li a {
  color: white;
  text-decoration: none;
  font-weight: 500;
}

  /* 移动端隐藏桌面导航 */
  @media (max-width: 767px) {
    .desktop-nav {
      display: none;
    }
  }
  
  /* 移动端和电脑端独立样式 */
  @media (max-width: 767px) {
    /* 移动端样式 */
    .desktop-header {
      display: none; /* 移动端隐藏电脑端头部 */
    }
    
    .mobile-menu-toggle {
      display: block; /* 移动端显示汉堡按钮 */
    }
    
    body {
      padding-top: 0; /* 移动端不需要为头部留空间 */
    }
  }
  
  @media (min-width: 768px) {
    /* 电脑端样式 */
    .desktop-header {
      display: block; /* 电脑端显示头部导航 */
    }
    
    .mobile-menu-toggle {
      display: none; /* 电脑端隐藏汉堡按钮 */
    }
    
    .mobile-menu {
      display: none; /* 电脑端隐藏移动端菜单 */
    }
    
    body {
      padding-top: 70px; /* 电脑端为固定头部留空间 */
    }
  }
  
/* 移除不需要的样式 */

header nav input[type="search"] {
  padding: 0.5rem 0.75rem;
  border-radius: 9999px;
  border: 1px solid #d1d5db;
  margin-left: 1rem;
  width: 220px;
  color: #374151;
}

.breadcrumbs {
  margin-top: 1rem;
  margin-bottom: 1.0rem;
  font-size: 0.875rem;
  color: #6b7280;
}

.breadcrumbs a {
  color: #2563eb;
  text-decoration: none;
}

.breadcrumbs a:hover {
  text-decoration: underline;
}

.breadcrumbs span:not(:last-child):after {
  content: ' / ';
  margin: 0 0.25rem;
}

.main-layout-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.game-content-column {
  flex: 3;
  min-width: 0;
  order: 1;
}

.sidebar-column {
  flex: 1;
  min-width: 280px;
  order: 2;
}

.game-title-section {
  margin-bottom: 0.75rem;
  text-align: left;
}

.game-title-section h1 {
  font-size: 2.25rem;
  line-height: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
  margin-top: 0.25rem;
  color: #111827;
}

.subtitle {
  font-size: 1rem;
  color: #4b5867;
  margin-top: 0;
  margin-bottom: 1rem;
  line-height: 1.5;
}

.game-embed-area {
  background-color: #1f2937;
  width: 100%;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.game-visual-and-overlay {
  width: 100%;
  /*aspect-ratio: 16 / 9;*/
  height: 750px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: url('./img/pipsnyt-cover-1.webp');
  background-size: cover;
  background-position: center;
}

.game-launch-overlay {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background-color: rgba(0, 0, 0, 0.65);
  border-radius: 0.5rem;
  text-align: center;
  position: absolute;
  z-index: 10;
  inset: 0;
  /* Ensure it covers the parent */
}

.game-launch-overlay .game-logo-iframe {
  width: 88px;
  height: 88px;
  border-radius: 0.5rem;
  background-color: #7f8c8d;
  margin-bottom: 1rem;
  object-fit: contain;
  border: 3px solid rgba(255, 255, 255, 0.9);
}

.game-launch-overlay .game-title-iframe {
  font-size: 1.75rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 1.25rem;
}

.play-now-button-iframe {
  background-color: #e74c3c;
  color: white;
  padding: 0.75rem 1.5rem;
  text-decoration: none;
  /* Red button */
  font-size: 1.25rem;
  font-weight: 600;
  border-radius: 0.375rem;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.play-now-button-iframe:hover {
  background-color: #c0392b;
}

.game-embed-controls {
  background-color: #374151;
  padding: 0.5rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #e5e7eb;
  min-height: 52px;
  border-top: 1px solid #4b5563;
}

.game-embed-controls .game-info-bar {
  display: flex;
  align-items: center;
}

.game-embed-controls .game-logo-bar {
  width: 32px;
  height: 32px;
  border-radius: 0.25rem;
  margin-right: 0.75rem;
  object-fit: contain;
}

.game-embed-controls .game-title-in-bar {
  font-size: 0.95rem;
  font-weight: 500;
  margin-right: 1rem;
}

.game-embed-actions button {
  background: transparent;
  border: none;
  color: #d1d5db;
  font-size: 0.875rem;
  margin-left: 0.5rem;
  cursor: pointer;
  padding: 0.375rem 0.625rem;
  border-radius: 0.25rem;
  display: inline-flex;
  align-items: center;
  transition: background-color 0.2s, color 0.2s;
}

.game-embed-actions button:hover {
  background-color: #4b5563;
  color: #fff;
}

.game-embed-actions button .icon {
  margin-right: 0.375rem;
  font-size: 1.1em;
}

.icon-share::before {
  content: "🔗";
}

.icon-favorite::before {
  content: "⭐";
}

.icon-fullscreen::before {
  content: "↔️";
}

.icon-comment::before {
  content: "📝";
}

.ad-slot {
  background-color: #e5e7eb;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: 0.25rem;
  font-size: 0.875rem;
  color: #6b7280;
  border: 1px dashed #9ca3af;
}

.ad-slot-below-game {
  height: 90px;
  margin-bottom: 1.5rem;
}

.placeholder-ad-reviews {
  height: 120px;
  margin-bottom: 1rem;
}

.placeholder-ad-sidebar {
  height: 250px;
  margin-bottom: 1rem;
}

.related-games-main {
  margin-bottom: 1.5rem;
  padding: 1rem;
  background-color: #fff;
  border-radius: 0.5rem;
  border: 0px solid #e5e7eb;
}

.related-games-main h2 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: #1f2937;
  border-bottom: none;
  padding-bottom: 0;
}

.related-games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 1rem;
}

.content-details-wrapper {
  display: grid;
  grid-template-columns: 1fr;
  /* Default for small screens */
  gap: 1.5rem;
  /* Default gap */
}

@media (min-width: 768px) {

  /* md breakpoint */
  .content-details-wrapper {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    /* Slightly reduced gap for medium screens */
  }
}

@media (min-width: 1024px) {

  /* lg breakpoint */
  .content-details-wrapper {
    gap: 1.5rem;
    /* Restore or adjust gap for larger screens */
  }
}

.tabs-and-content-column {
  width: 100%;
}

@media (min-width: 768px) {

  /* md breakpoint */
  .tabs-and-content-column {
    grid-column: span 2 / span 2;
  }
}

.reviews-and-ads-column {
  width: 100%;
}

@media (min-width: 768px) {

  /* md breakpoint */
  .reviews-and-ads-column {
    grid-column: span 1 / span 1;
  }
}


.game-details-meta {
  padding: 1rem;
  background-color: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  margin-bottom: 1.5rem;
}

.game-details-meta .meta-item {
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

.game-details-meta .meta-item strong {
  color: #374151;
  min-width: 110px;
  display: inline-block;
  font-weight: 500;
}

/* Increased min-width for labels */
.game-details-meta .rating {
  color: #f59e0b;
  font-weight: 600;
}

.game-details-meta .tags span {
  background-color: #e5e7eb;
  color: #4b5563;
  padding: 0.25rem 0.625rem;
  border-radius: 9999px;
  margin-right: 0.375rem;
  font-size: 0.8rem;
  display: inline-block;
  margin-top: 0.25rem;
}

.game-details-meta .tags a {
  text-decoration: none;
  color: inherit;
}

.game-details-meta .tags a:hover span {
  background-color: #d1d5db;
}

.content-nav {
  display: flex;
  flex-wrap: wrap;
  border-bottom: none;
  margin-bottom: 1.5rem;
  background-color: #fff;
  padding: 0.5rem 0.25rem;
  border-radius: 0.5rem 0.5rem 0 0;
  position: sticky;
  top: 0;
  z-index: 50;
}

.nav-link-button {
  padding: 0.625rem 0.75rem;
  cursor: pointer;
  background-color: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  margin-right: 0.25rem;
  margin-bottom: 0.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #6b7280;
  white-space: nowrap;
  text-decoration: none;
  transition: color 0.2s, border-bottom-color 0.2s;
}

.nav-link-button:hover {
  color: #2563eb;
}

.nav-link-button.active {
  border-bottom-color: #2563eb;
  font-weight: 600;
  color: #2563eb;
}

/* 移除重复定义，使用下面的内容切换样式 */

.content-section h2 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-top: 0;
  color: #111827;
  border-bottom: none !important;
  text-decoration: none !important;
  padding-bottom: 0;
  margin-bottom: 1rem;
}

.content-section h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-top: 1.25rem;
  color: #1f2937;
  margin-bottom: 0.5rem;
}

.content-section h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-top: 1rem;
  color: #374151;
  margin-bottom: 0.25rem;
}

.content-section ul,
.content-section ol {
  padding-left: 1.25rem;
  margin-bottom: 1rem;
}

.content-section li {
  margin-bottom: 0.5rem;
}

.video-placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: 0.375rem;
  margin-bottom: 0.75rem;
}

.overview-layout {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 768px) {
  .overview-layout {
    flex-direction: row;
    align-items: flex-start;
  }
}

.overview-text {
  flex: 1;
}

.overview-screenshot-container {
  flex-shrink: 0;
  width: 100%;
  margin-top: 1rem;
}

@media (min-width: 768px) {
  .overview-screenshot-container {
    width: 30%;
    max-width: 250px;
    margin-top: 0;
    margin-left: 1rem;
  }
}

.inline-screenshot {
  width: 100%;
  height: auto;
  border-radius: 0.375rem;
  border: 1px solid #e5e7eb;
  display: block;
}

.inline-screenshot-caption {
  font-size: 0.75rem;
  color: #6b7280;
  margin-top: 0.25rem;
  text-align: center;
}

.feature-item-with-screenshot {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

@media (min-width: 640px) {
  .feature-item-with-screenshot {
    flex-direction: row;
    align-items: center;
  }
}

.feature-item-with-screenshot img {
  width: 120px;
  height: 80px;
  object-fit: cover;
  border-radius: 0.25rem;
  border: 1px solid #e5e7eb;
  flex-shrink: 0;
}

.feature-item-with-screenshot .feature-text {
  flex-grow: 1;
}

.screenshots-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 1rem;
}

.screenshot-card img {
  width: 100%;
  height: auto;
  border-radius: 0.25rem;
  border: 1px solid #e5e7eb;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.screenshot-card img:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.screenshot-card p {
  font-size: 0.875rem;
  text-align: center;
  margin-top: 0.25rem;
  color: #6b7280;
}

/* 图片放大模态框样式 */
.image-modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.image-modal.show {
  display: flex;
  opacity: 1;
  align-items: center;
  justify-content: center;
}

.image-modal-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.image-modal img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 0.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.image-modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  color: #fff;
  font-size: 2rem;
  font-weight: bold;
  cursor: pointer;
  background: rgba(0, 0, 0, 0.5);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease;
}

.image-modal-close:hover {
  background: rgba(0, 0, 0, 0.8);
}

.image-modal-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  border: none;
  font-size: 1.5rem;
  padding: 10px 15px;
  cursor: pointer;
  border-radius: 0.25rem;
  transition: background-color 0.2s ease;
}

.image-modal-nav:hover {
  background: rgba(0, 0, 0, 0.8);
}

.image-modal-prev {
  left: 20px;
}

.image-modal-next {
  right: 20px;
}

.image-modal-caption {
  position: absolute;
  bottom: -50px;
  left: 0;
  right: 0;
  color: #fff;
  text-align: center;
  font-size: 1rem;
  background: rgba(0, 0, 0, 0.7);
  padding: 10px;
  border-radius: 0.25rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .image-modal-content {
    max-width: 95%;
    max-height: 95%;
  }

  .image-modal-close {
    top: -35px;
    font-size: 1.5rem;
    width: 35px;
    height: 35px;
  }

  .image-modal-nav {
    font-size: 1.2rem;
    padding: 8px 12px;
  }

  .image-modal-prev {
    left: 10px;
  }

  .image-modal-next {
    right: 10px;
  }

  .image-modal-caption {
    bottom: -40px;
    font-size: 0.9rem;
    padding: 8px;
  }
}

.reviews-and-ads-column .section,
.sidebar-column .section {
  background-color: #fff;
  padding: 1rem;
  border-radius: 0.5rem;
  border: 1px solid #e5e7eb;
  margin-bottom: 1.5rem;
}

.reviews-and-ads-column .section-title,
.sidebar-column .section-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: #1f2937;
  border-bottom: none;
  padding-bottom: 0;
}

.review {
  border-bottom: 1px solid #f3f4f6;
  padding-bottom: 0.75rem;
  margin-bottom: 0.75rem;
}

.review:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.review p {
  margin-bottom: 0.25rem;
  font-size: 0.9rem;
}

.review .stars {
  color: #f59e0b;
}

.review cite {
  font-style: normal;
  font-size: 0.8rem;
  color: #6b7280;
  display: block;
  margin-top: 0.25rem;
}

.game-card {
  border: 1px solid #e5e7eb;
  text-align: center;
  border-radius: 0.375rem;
  background-color: #fff;
  overflow: hidden;
  padding-bottom: 0.5rem;
}

.game-card img {
  width: 100%;
  height: 80px;
  object-fit: cover;
  background-color: #e5e7eb;
}

.game-card p {
  margin: 0.5rem 0.25rem;
  font-size: 0.875rem;
  color: #374151;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
}

.game-card a {
  text-decoration: none;
}

.game-card a:hover p {
  color: #2563eb;
}

.sidebar-game-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

footer {
  background-color: #1f2937;
  color: #e5e7eb;
  text-align: center;
  padding: 1.5rem 0;
  margin-top: 2rem;
  border-radius: 0 0 0.5rem 0.5rem;
}

footer p {
  margin: 0.25rem 0;
  font-size: 0.875rem;
}

footer a {
  color: #60a5fa;
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

.chart-container {
  position: relative;
  width: 100%;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  height: 300px;
  max-height: 350px;
}

/* Ensure consistent width for tabs and reviews columns on medium screens and up */
@media (min-width: 768px) {
  .chart-container {
    height: 350px;
    max-height: 400px;
  }

  /* .tabs-and-content-column { width: 66.666667%; } */
  /* Replaced by grid-column */
  /* .reviews-and-ads-column { width: 33.333333%; } */
  /* Replaced by grid-column */
}

@media (max-width: 1024px) {
  .main-layout-wrapper {
    flex-direction: column;
  }

  .game-content-column,
  .sidebar-column {
    flex-basis: 100%;
    order: initial;
  }

  .sidebar-column {
    margin-top: 1.5rem;
  }
}

@media (max-width: 767px) {

  /* .content-details-wrapper { grid-template-columns: 1fr; } */
  /* Already default */
  .content-nav {
    position: static;
  }

  .game-title-section h1 {
    font-size: 1.875rem;
  }

  .subtitle {
    font-size: 0.95rem;
  }

  .game-launch-overlay .game-title-iframe {
    font-size: 1.25rem;
  }

  .play-now-button-iframe {
    font-size: 1rem;
    padding: 0.5rem 1rem;
  }

  .game-embed-controls {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }

  .game-embed-controls .game-info-bar {
    flex-basis: 100%;
    justify-content: center;
    margin-bottom: 0.25rem;
  }

  .game-embed-controls .game-embed-actions {
    flex-basis: 100%;
    display: flex;
    justify-content: space-around;
  }

  .game-embed-actions button {
    margin-left: 0.25rem;
    margin-right: 0.25rem;
    padding: 0.375rem 0.5rem;
    font-size: 0.8rem;
  }

  .overview-layout {
    flex-direction: column;
  }

  .overview-screenshot-container {
    width: 100%;
    max-width: 300px;
    margin-left: auto;
    margin-right: auto;
  }

  .feature-item-with-screenshot {
    flex-direction: column;
    align-items: flex-start;
  }

  .feature-item-with-screenshot img {
    width: 150px;
    margin-bottom: 0.5rem;
  }
}

/* 游戏懒加载相关样式 */
.game-iframe-container {
  width: 100%;
  height: 100%;
  position: relative;
}

.loading-spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #fff;
  font-size: 1.125rem;
  background-color: rgba(0, 0, 0, 0.7);
}

.loading-spinner::before {
  content: '';
  width: 20px;
  height: 20px;
  border: 2px solid #fff;
  border-top: 2px solid transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-right: 0.5rem;
}

.error-message {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #ef4444;
  font-size: 1rem;
  background-color: rgba(0, 0, 0, 0.8);
  text-align: center;
  padding: 1rem;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/* 全屏模式下的样式调整 */
#game-container:fullscreen {
  background-color: #000;
}

#game-container:fullscreen .game-iframe-container {
  width: 100vw;
  height: 100vh;
}

#game-container:fullscreen iframe {
  width: 100% !important;
  height: 100% !important;
}

/* 内容切换样式 - 面包屑导航响应式展示 */
.content-section {
  padding: 1.25rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  background-color: #fff;
  margin-bottom: 1.5rem;
  scroll-margin-top: 70px;
  /* 默认隐藏所有section */
  display: none;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

/* 只有激活的section才显示 */
.content-section.active {
  display: block !important;
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* SEO友好：搜索引擎爬虫时显示所有内容 */
.seo-mode .content-section {
  display: block !important;
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* 无JavaScript环境下显示所有内容 */
.no-js .content-section {
  display: block !important;
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* 视频懒加载样式 */
.lazy-video-container {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: #000;
  border-radius: 0.5rem;
  overflow: hidden;
  cursor: pointer;
  margin-bottom: 1rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.lazy-video-container:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.lazy-video-thumbnail {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.lazy-video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg,
      rgba(0, 0, 0, 0.3) 0%,
      rgba(0, 0, 0, 0.1) 50%,
      rgba(0, 0, 0, 0.4) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
}

.lazy-video-container:hover .lazy-video-overlay {
  background: linear-gradient(135deg,
      rgba(0, 0, 0, 0.2) 0%,
      rgba(0, 0, 0, 0.05) 50%,
      rgba(0, 0, 0, 0.3) 100%);
}

.lazy-video-play-button {
  width: 80px;
  height: 80px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.lazy-video-container:hover .lazy-video-play-button {
  background: rgba(255, 255, 255, 1);
  transform: scale(1.1);
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.4);
}

.lazy-video-play-icon {
  width: 0;
  height: 0;
  border-left: 24px solid #e74c3c;
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  margin-left: 6px;
}

.lazy-video-title {
  position: absolute;
  bottom: 50px;
  left: 16px;
  right: 16px;
  color: white;
  font-size: 1.1rem;
  font-weight: 600;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
  line-height: 1.3;
}

.lazy-video-duration {
  position: absolute;
  bottom: 16px;
  right: 16px;
  background: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.875rem;
  font-weight: 500;
}

/* 视频加载状态 */
.lazy-video-loading {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1rem;
  z-index: 10;
}

.lazy-video-loading::before {
  content: '';
  width: 24px;
  height: 24px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top: 3px solid white;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-right: 12px;
}

/* 嵌入的YouTube iframe样式 */
.lazy-video-iframe {
  width: 100%;
  height: 100%;
  border: none;
  border-radius: 0.5rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .lazy-video-play-button {
    width: 60px;
    height: 60px;
  }

  .lazy-video-play-icon {
    border-left: 18px solid #e74c3c;
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    margin-left: 4px;
  }

  .lazy-video-title {
    font-size: 1rem;
    bottom: 40px;
  }

  .lazy-video-duration {
    font-size: 0.8rem;
  }
}

/* 移动端自适应样式 - 保持现有结构，只优化移动端显示 */

/* 移动端基础优化 */
@media (max-width: 767px) {
  /* 容器优化 */
  .container {
    padding: 0.5rem;
  }
  
  /* 头部导航移动端适配 - 汉堡菜单 */
  header {
    padding: 0.5rem 0;
    border-radius: 0;
    position: relative;
  }
  
  /* 隐藏原有导航 */
  header nav ul {
    display: none;
  }
  
  /* 汉堡菜单按钮 - 完全独立，固定在视口左上角 */
  .mobile-menu-toggle {
    display: block;
    position: fixed;
    top: 0.75rem;
    left: 0.75rem;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: 0.375rem;
    padding: 0.5rem;
    color: white;
    font-size: 1.25rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
    z-index: 1000;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .mobile-menu-toggle:hover {
    background: rgba(26, 25, 25, 0.2);
  }
  
  /* 移动端下拉菜单 */
  .mobile-menu {
    display: none;
    position: fixed;
    top: 4rem; /* 汉堡按钮下方 */
    left: 0.75rem;
    background: #242424;
    border-radius: 0.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 999;
    padding: 0.5rem 0;
    min-width: 200px;
  }
  
  .mobile-menu.show {
    display: block;
  }
  
  .mobile-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
  }
  
  .mobile-menu ul li {
    margin: 0;
  }
  
  .mobile-menu ul li a {
    display: block;
    padding: 0.75rem 1rem;
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  
  .mobile-menu ul li:last-child a {
    border-bottom: none;
  }
  
  .mobile-menu ul li a:hover {
    background: rgba(255, 255, 255, 0.1);
  }
  
  /* 游戏标题移动端优化 */
  .game-title-section h1 {
    font-size: 1.75rem;
    line-height: 2rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }
  
  /* 移动端隐藏游戏标题区域，因为标题已移到头部 */
  @media (max-width: 767px) {
    .game-title-section {
      display: none;
    }
  }
  
  .subtitle {
    font-size: 1.25rem;
    line-height: 1.6;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    margin: 1.5rem 1rem 1rem 1rem;
    padding: 0;
    text-align: center;
  }
  
  /* 游戏容器高度优化 - 确保移动端有足够高度 */
  .game-visual-and-overlay {
    height: 900px; /* 大幅增加游戏容器高度，解决底部被截断问题 */
    min-height: 800px; /* 最小高度保证 */
  }
  
  /* 游戏启动覆盖层移动端优化 */
  .game-launch-overlay {
    padding: 1rem;
  }
  
  .game-launch-overlay .game-logo-iframe {
    width: 72px;
    height: 72px;
    margin-bottom: 0.75rem;
  }
  
  .game-launch-overlay .game-title-iframe {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }
  
  .play-now-button-iframe {
    font-size: 1.125rem;
    padding: 0.75rem 1.25rem;
    min-height: 48px; /* 触摸目标大小 */
  }
  
  /* 游戏控制栏移动端优化 */
  .game-embed-controls {
    padding: 0.75rem;
    flex-direction: column;
    gap: 0.5rem;
    min-height: auto;
  }
  
  .game-embed-controls .game-info-bar {
    justify-content: center;
    margin-bottom: 0;
  }
  
  .game-embed-controls .game-embed-actions {
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    width: 100%;
    flex-wrap: wrap;
    padding: 0 0.5rem;
    gap: 0.5rem;
  }
  
  .game-embed-controls .game-embed-actions button {
    margin: 0;
    padding: 0.5rem 0.75rem;
    font-size: 0.8rem;
    min-height: 44px; /* 触摸目标大小 */
    justify-content: center;
    flex: 1;
    min-width: 70px;
    max-width: 100px;
  }
  
  /* 内容导航移动端优化 */
  .content-nav {
    flex-direction: column;
    gap: 0.25rem;
    padding: 0.75rem;
  }
  
  .nav-link-button {
    width: 100%;
    text-align: left;
    padding: 0.75rem;
    margin: 0;
    border-radius: 0.375rem;
    border: 1px solid #e5e7eb;
    background-color: #f9fafb;
    min-height: 44px; /* 触摸目标大小 */
  }
  
  .nav-link-button.active {
    background-color: #2563eb;
    color: white;
    border-color: #2563eb;
  }
  
  /* 游戏详情元数据移动端优化 */
  .game-details-meta {
    padding: 0.75rem;
  }
  
  .game-details-meta .meta-item {
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
  }
  
  .game-details-meta .meta-item strong {
    display: block;
    margin-bottom: 0.25rem;
    min-width: auto;
  }
  
  /* 截图网格移动端优化 */
  .screenshots-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }
  
  .screenshot-card p {
    font-size: 0.8rem;
    margin-top: 0.5rem;
  }
  
  /* 视频容器移动端优化 */
  .lazy-video-container {
    margin-bottom: 1.5rem;
  }
  
  .lazy-video-title {
    font-size: 1rem;
    bottom: 45px;
    left: 12px;
    right: 12px;
  }
  
  .lazy-video-duration {
    bottom: 12px;
    right: 12px;
    font-size: 0.8rem;
  }
  
  /* 评论区域移动端优化 */
  .review {
    padding: 0.75rem 0;
  }
  
  .review p {
    font-size: 0.85rem;
    line-height: 1.4;
  }
  
  /* 概览布局移动端优化 */
  .overview-screenshot-container {
    max-width: 100%;
    margin: 1rem 0;
  }
  
  .inline-screenshot {
    max-width: 100%;
    height: auto;
  }
}

/* 小屏手机优化 (480px以下) */
@media (max-width: 480px) {
  .container {
    padding: 0.25rem;
  }
  
  .game-title-section h1 {
    font-size: 1.5rem;
    line-height: 1.75rem;
  }
  
  .subtitle {
    font-size: 0.85rem;
  }
  
  .game-visual-and-overlay {
    height: 700px;
    min-height: 600px;
  }
  
  .game-launch-overlay .game-logo-iframe {
    width: 64px;
    height: 64px;
  }
  
  .game-launch-overlay .game-title-iframe {
    font-size: 1.25rem;
  }
  
  .play-now-button-iframe {
    font-size: 1rem;
    padding: 0.625rem 1rem;
  }
  
  .screenshots-grid {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }
  
  .game-embed-controls .game-embed-actions {
    flex-direction: row;
    justify-content: space-around;
  }
  
  .game-embed-controls .game-embed-actions button {
    padding: 0.625rem 0.5rem;
    font-size: 0.875rem;
    min-width: 70px;
    max-width: 100px;
  }
}

/* 超小屏手机优化 (375px以下) */
@media (max-width: 375px) {
  .game-title-section h1 {
    font-size: 1.375rem;
    line-height: 1.625rem;
  }
  
  .subtitle {
    font-size: 0.8rem;
  }
  
  .game-visual-and-overlay {
    height: 650px;
    min-height: 550px;
  }
  
  .game-launch-overlay {
    padding: 0.75rem;
  }
  
  .game-launch-overlay .game-logo-iframe {
    width: 56px;
    height: 56px;
    margin-bottom: 0.5rem;
  }
  
  .game-launch-overlay .game-title-iframe {
    font-size: 1.125rem;
    margin-bottom: 0.75rem;
  }
  
  .play-now-button-iframe {
    font-size: 0.875rem;
    padding: 0.5rem 0.875rem;
  }
  
  .content-nav {
    padding: 0.5rem;
  }
  
  .nav-link-button {
    padding: 0.625rem;
    font-size: 0.8rem;
  }
  
  .game-details-meta {
    padding: 0.5rem;
  }
  
  .game-details-meta .meta-item {
    font-size: 0.8rem;
  }
}

/* 超小屏设备优化 (320px以下) */
@media (max-width: 320px) {
  .container {
    padding: 0.125rem;
  }
  
  .game-title-section h1 {
    font-size: 1.25rem;
    line-height: 1.5rem;
  }
  
  .subtitle {
    font-size: 0.75rem;
  }
  
  .game-visual-and-overlay {
    height: 600px;
    min-height: 500px;
  }
  
  .game-launch-overlay .game-logo-iframe {
    width: 48px;
    height: 48px;
  }
  
  .game-launch-overlay .game-title-iframe {
    font-size: 1rem;
  }
  
  .play-now-button-iframe {
    font-size: 0.8rem;
    padding: 0.5rem 0.75rem;
  }
  
  .game-embed-controls {
    padding: 0.5rem;
  }
  
  .game-embed-controls .game-embed-actions button {
    padding: 0.5rem;
    font-size: 0.75rem;
  }
  
  .content-nav {
    padding: 0.375rem;
  }
  
  .nav-link-button {
    padding: 0.5rem;
    font-size: 0.75rem;
  }
  
  .game-details-meta {
    padding: 0.375rem;
  }
  
  .game-details-meta .meta-item {
    font-size: 0.75rem;
  }
}

/* 高分辨率移动设备优化 (针对3200x1440等设备) */
@media (min-width: 768px) and (max-width: 1024px) and (min-resolution: 2dppx) {
  .game-visual-and-overlay {
    height: 700px; /* 高分辨率设备保持较高高度 */
  }
  
  .game-title-section h1 {
    font-size: 2rem;
    line-height: 2.25rem;
  }
  
  .subtitle {
    font-size: 1rem;
  }
}

/* 横屏模式优化 */
@media (max-width: 767px) and (orientation: landscape) {
  .game-visual-and-overlay {
    height: 400px; /* 横屏时降低高度 */
    min-height: 350px;
  }
  
  .game-launch-overlay .game-logo-iframe {
    width: 56px;
    height: 56px;
  }
  
  .game-launch-overlay .game-title-iframe {
    font-size: 1.125rem;
  }
  
  .play-now-button-iframe {
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
  }
  
  header nav ul {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding: 0 0.5rem;
  }
  
  header nav ul li a {
    white-space: nowrap;
    flex-shrink: 0;
  }
}

/* 触摸设备优化 */
@media (hover: none) and (pointer: coarse) {
  .nav-link-button:hover {
    background-color: #f9fafb;
    color: #6b7280;
  }
  
  .nav-link-button.active:hover {
    background-color: #2563eb;
    color: white;
  }
  
  .play-now-button-iframe:hover {
    background-color: #e74c3c;
  }
  
  .game-embed-actions button:hover {
    background-color: transparent;
    color: #d1d5db;
  }
  
  .screenshot-card img:hover {
    transform: none;
    box-shadow: none;
  }
  
  .lazy-video-container:hover {
    transform: none;
    box-shadow: none;
  }
  
  .lazy-video-container:hover .lazy-video-overlay {
    background: linear-gradient(135deg,
        rgba(0, 0, 0, 0.3) 0%,
        rgba(0, 0, 0, 0.1) 50%,
        rgba(0, 0, 0, 0.4) 100%);
  }
  
  .lazy-video-container:hover .lazy-video-play-button {
    background: rgba(255, 255, 255, 0.95);
    transform: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  }
}

/* 防止文本截断的通用优化 */
@media (max-width: 767px) {
  /* 确保文本不会截断 */
  .subtitle,
  .game-launch-overlay .game-title-iframe,
  .nav-link-button,
  .game-details-meta .meta-item,
  .review p,
  .lazy-video-title {
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
  }
  
  /* 长文本自动换行 */
  .game-details-meta .meta-item strong + * {
    word-break: break-word;
  }
  
  /* 标签自动换行 */
  .game-details-meta .tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
  }
  
  .game-details-meta .tags span {
    white-space: normal;
    word-break: break-word;
  }
}

/* Blog-style article list for Pips NYT Answer aggregate */
.articles-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 640px) {
  .articles-list {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1024px) {
  .articles-list {
    grid-template-columns: 1fr;
  }
}

.article-card {
  display: block;
  background-color: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.article-card a {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  text-decoration: none;
  color: inherit;
  padding: 1rem;
}

.article-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.article-thumb {
  width: 160px;
  height: 110px;
  object-fit: cover;
  border-radius: 0.375rem;
  border: 1px solid #e5e7eb;
  background-color: #f3f4f6;
  flex-shrink: 0;
  display: block;
}

.article-content {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.article-title {
  margin: 0 0 0.35rem 0;
  font-size: 1.125rem;
  font-weight: 700;
  color: #111827;
}

.article-meta {
  margin: 0 0 0.35rem 0;
  font-size: 0.875rem;
  color: #6b7280;
}

.article-excerpt {
  margin: 0;
  font-size: 0.95rem;
  color: #374151;
}

@media (max-width: 640px) {
  .article-card a {
    padding: 0.75rem;
    gap: 0.75rem;
    align-items: flex-start;
  }
  .article-thumb {
    width: 120px;
    height: 84px;
  }
  .article-title {
    font-size: 1rem;
  }
  .article-excerpt {
    font-size: 0.9rem;
  }
  .article-content {
    justify-content: flex-start;
  }
}

/* Ensure article titles align to the top even under .content-section h3 defaults */
.content-section h3.article-title {
  margin-top: 0 !important;
}

@media (max-width: 767px) {
  .breadcrumbs {
    margin-left: 0.5rem;
    padding-left: 0.5rem;
  }
}

@media (max-width: 767px) {
  /* 覆盖博客/嵌入区域分享链接在移动端的按钮化样式 */
  .game-embed-actions .nav-link-button {
    width: auto;
    padding: 0.375rem 0.5rem;
    margin: 0 0.25rem;
    background: transparent;
    border: none;
    border-radius: 0;
    min-height: 0;
    font-size: 0.875rem;
    color: #6b7280;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
  }

  .game-embed-actions .nav-link-button:hover {
    background: transparent;
    color: #2563eb;
    border: none;
  }
}

/* 博客正文图片全局居中（水平 + 在弹性/网格父容器内的垂直居中） */
.content-section article img {
  display: block;
  margin-left: auto;
  margin-right: auto;
  max-width: 100%;
  height: auto;
  align-self: center; /* 若父级为 flex/grid，则垂直/交叉轴居中 */
  object-fit: contain;
}