/* Game Detail Hero overlay and text readability */
.app-detail-hero {
    position: relative;
    min-height: 280px;
    overflow: hidden;
    background-size: cover;
    background-position: center;
}
.app-detail-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.75) 100%);
    pointer-events: none;
}
.app-detail-hero .app-header {
    position: relative;
    z-index: 1;
    padding: 96px 0 28px 0;
    display: flex;
    align-items: flex-end;
    gap: 24px;
    color: #fff;
}
.app-detail-hero .app-title {
    margin: 0 0 10px;
    font-size: 28px;
    line-height: 1.25;
    color: #fff;
    text-shadow: 0 2px 8px rgba(0,0,0,0.35);
}
.app-detail-hero .app-subtitle { color: #fff; opacity: 0.9; }
.app-detail-hero .app-meta { color: #fff; display: flex; gap: 12px; flex-wrap: wrap; }
.app-detail-hero .app-meta .category a { color: #fff; text-decoration: none; }
/* Download modal */
.download-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1100;
}
.download-modal.open {
  display: flex;
}
.download-modal .modal-content {
  background: #fff;
  color: #333;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
  width: min(560px, 94vw);
  padding: 22px 24px 18px;
  position: relative;
}
.download-modal h3 {
  margin: 0 0 12px;
  font-size: 20px;
}
.download-modal .modal-close-icon {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: #f1f3f5;
  color: #333;
  font-size: 20px;
  line-height: 32px;
  text-align: center;
  cursor: pointer;
}
.download-modal .modal-close-icon:hover { background: #e9ecef; }
.download-modal .download-list {
  list-style: none;
  margin: 8px 0 12px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}
.download-modal .download-list li { margin: 0; }
.download-modal .download-list a {
  display: block;
  padding: 10px 12px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fafafa;
  color: #333;
  text-decoration: none;
}
.download-modal .download-list a:hover { background: #f3f4f6; }
.download-modal .download-list a[aria-disabled="true"] { color: #aaa; pointer-events: none; }
.download-modal .modal-close {
  display: inline-block;
  margin-top: 4px;
  padding: 8px 14px;
  border: 1px solid #ddd;
  border-radius: 6px;
  background: #f7f7f7;
  cursor: pointer;
}

/* Recommend badge */
.rec_app {
  display: inline-flex;
  align-items: center;
  position: absolute;
  right: 40%;
  top: 15%;
}
.rec_app img {
  width: 100px;
}
.app-detail-hero .rating .stars { color: #fff; }

.app-detail-hero .btn.btn-ghost { color: #fff; border-color: rgba(255,255,255,0.7); }
.app-detail-hero .btn.btn-ghost .heart-icon { margin-right: 6px; }


/* 收藏按钮后的内联提示 */
.favorite-msg {
  margin-left: 10px;
  display: inline-block;
  vertical-align: middle;
  font-size: 13px;
  line-height: 1;
  opacity: 0;
  transition: opacity .2s ease;
}
.favorite-msg.is-success { color: #2ecc71; }
.favorite-msg.is-error { color: #ff4757; }

@keyframes fav-pop {
  0% { transform: scale(1); }
  50% { transform: scale(1.06); }
  100% { transform: scale(1); }
}

@media (max-width: 768px) {
    .app-detail-hero .app-header { flex-direction: column; align-items: flex-start; padding: 24px 0; }
    .app-detail-hero .app-title { font-size: 22px; }
}

.app-screenshots {
    margin-top: 24px;
}

.app-screenshots .swiper {
    --swiper-navigation-color: var(--color-text, #333);
    --swiper-pagination-color: var(--color-primary, #007acc);
}

.app-screenshots .swiper-slide img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    cursor: zoom-in;
}

.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s ease, visibility .2s ease;
    z-index: 1000;
}

.lightbox.open {
    opacity: 1;
    visibility: visible;
}

.lightbox-image {
    max-width: min(92vw, 1200px);
    max-height: 92vh;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.lightbox-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border: none;
    border-radius: 999px;
    width: 36px;
    height: 36px;
    font-size: 20px;
    line-height: 36px;
    text-align: center;
    cursor: pointer;
}

/* Hero 右侧半透明渐变 Logo */
.app-detail-hero { position: relative; overflow: hidden; }
.app-detail-hero .container { position: relative; z-index: 2; }
.hero-visual {
    position: absolute;
    right: 90px;
    top: -20px;
    width: min(42vw, 540px);
    height: min(42vw, 540px);
    pointer-events: none;
    z-index: 1;
}
.hero-visual::before {
    content: "";
    position: absolute;
    filter: blur(6px);
}
.hero-visual .hero-visual-logo {
    position: absolute;
    right: 50px;
    bottom: -50px;
    width: 100%;
    height: auto;
    opacity: 0.4;
    -webkit-mask-image: linear-gradient(180deg, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.6) 40%, rgba(0,0,0,0.2) 75%, rgba(0,0,0,0) 100%);
    mask-image: linear-gradient(180deg, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.6) 40%, rgba(0,0,0,0.2) 75%, rgba(0,0,0,0) 100%);
    rotate: -30deg;
}
@media (max-width: 992px) {
    .hero-visual { right: -20px; top: -10px; width: min(60vw, 420px); height: min(60vw, 420px); }
    .hero-visual .hero-visual-logo { opacity: 0.14; }
}