/* 案例页：沿用官网黑白体系，独立轻量布局 */

.cases-page {
  min-height: 100vh;
  background: #000;
  color: #fff;
}

.cases-page #page {
  background: transparent;
  min-height: 100vh;
}

.cases-page .noise:after,
.cases-page.noise:after {
  z-index: 1 !important;
}

.cases-page #header {
  position: sticky;
  top: 0;
  z-index: 50 !important;
  background: #000 !important;
  color: #fff;
  isolation: isolate;
}

/* 挡住下方滚动内容，避免大标题透出顶栏 */
.cases-page #header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  background: #000;
  z-index: -1;
}

.cases-page #header .page__container,
.cases-page #header nav,
.cases-page #header a,
.cases-page #header button {
  position: relative;
  z-index: 1;
}

.cases-page .mobile-menu-button__bar {
  background: #fff;
}

.cases-page.mobile-menu-open #header {
  z-index: 60 !important;
}

/* 手机：分类 Tab 可横滑；卡片入口始终可见 */
@media (max-width: 767px) {
  .cases-main {
    padding: 20px 0 72px;
  }

  .cases-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 4px;
    margin-bottom: 28px;
  }

  .cases-tabs::-webkit-scrollbar {
    display: none;
  }

  .cases-tab {
    flex: 0 0 auto;
    min-height: 44px;
    padding: 10px 14px;
    font-size: 14px;
  }

  .case-card__open {
    opacity: 1;
    transform: none;
  }

  .cases-title {
    font-size: clamp(36px, 11vw, 56px);
  }

  .cases-lead {
    font-size: 15px;
    margin-bottom: 24px;
  }
}

.cases-page #header .header__button-link {
  color: #fff;
}

.cases-page #header .header__button-link.is-current {
  opacity: 0.55;
}

.cases-page #logo,
.cases-page #logo__path {
  fill: #fff;
  color: #fff;
}

.cases-main {
  position: relative;
  z-index: 2;
  padding: 32px 0 96px;
  background: #000;
}

@media (min-width: 768px) {
  .cases-main {
    padding-top: 40px;
  }
}

.cases-kicker {
  margin: 0 0 12px;
  font-size: 12px;
  letter-spacing: 0.28em;
  color: #9a9a9a;
}

.cases-title {
  margin: 0 0 16px;
  font-size: clamp(42px, 8vw, 88px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: 0.04em;
}

.cases-lead {
  margin: 0 0 32px;
  max-width: 40em;
  color: #cdcdcd;
  font-size: clamp(15px, 1.6vw, 18px);
  line-height: 1.6;
}

/* 分类筛选 */
.cases-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 4px;
  margin: 0 0 40px;
  padding-bottom: 4px;
  border-bottom: 1px solid #222;
  background: #000;
}

@media (min-width: 640px) {
  .cases-tabs {
    gap: 8px 12px;
    margin-bottom: 48px;
  }
}

.cases-tab {
  appearance: none;
  -webkit-appearance: none;
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 14px;
  font-size: 13px;
  font-family: inherit;
  letter-spacing: 0.1em;
  color: #8f8f8f;
  background: transparent;
  border: none;
  border-bottom: 1px solid transparent;
  margin-bottom: -1px;
  transition: color 0.25s ease, border-color 0.25s ease;
  cursor: pointer;
}

.cases-tab:hover {
  color: #fff;
}

.cases-tab.is-active,
.cases-tab[aria-selected="true"] {
  color: #fff;
  border-bottom-color: #fff;
}

.cases-tab:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

/* 筛选面板：仅显示当前分类 */
.cases-section {
  margin-bottom: 0;
}

.cases-section[hidden] {
  display: none !important;
}

.cases-section__head {
  margin-bottom: 28px;
  max-width: 40em;
}

.cases-section__title {
  margin: 0 0 10px;
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 700;
  letter-spacing: 0.06em;
}

.cases-section__desc {
  margin: 0;
  color: #9a9a9a;
  font-size: 14px;
  line-height: 1.6;
}

.cases-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

@media (min-width: 768px) {
  .cases-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
  }
}

.case-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: opacity 0.25s ease;
}

.case-card:hover {
  opacity: 0.96;
}

.case-card:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 4px;
}

.case-card__media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #111;
}

.case-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.55s ease;
}

.case-card--soon {
  cursor: default;
  opacity: 0.88;
}

.case-card--soon:hover {
  opacity: 0.92;
}

.case-card--soon:hover .case-card__media img {
  transform: none;
}

.case-card__badge {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 2;
  padding: 8px 14px;
  font-size: 12px;
  letter-spacing: 0.12em;
  color: #fff;
  background: rgba(0, 0, 0, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.case-card__open {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 2;
  padding: 8px 14px;
  font-size: 12px;
  letter-spacing: 0.12em;
  color: #fff;
  background: rgba(0, 0, 0, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.28);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.case-card:hover .case-card__open,
.case-card:focus-visible .case-card__open {
  opacity: 1;
  transform: none;
}

.case-card:hover .case-card__media img {
  transform: scale(1.04);
}

.case-card__body {
  padding: 20px 0 8px;
}

.case-card__title {
  margin: 0 0 10px;
  font-size: clamp(22px, 2.4vw, 28px);
  font-weight: 700;
}

.case-card__text {
  margin: 0 0 14px;
  color: #bdbdbd;
  line-height: 1.55;
  font-size: 15px;
}

.case-card__tag {
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: #8f8f8f;
  border-bottom: 1px solid #3a3a3a;
  padding-bottom: 2px;
}

.cases-footer {
  position: relative;
  z-index: 2;
  border-top: 1px solid #222;
  padding: 28px 0 40px;
  color: #8a8a8a;
  font-size: 13px;
}

.cases-footer .page__container {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  justify-content: space-between;
  align-items: center;
}

.cases-footer a {
  color: #8a8a8a;
}

.cases-footer a:hover {
  color: #fff;
}
