/* ==========================================================================
   components.css — 按钮 / 徽章 / 卡片 / 图位 / 列表 / 问答 / 表格
   次级按钮用 inset 阴影描边，不用 border：1px 实边框会把按钮撑高 2px，
   和同一行的实心按钮对不齐。
   ========================================================================== */

/* --------------------------------------------------------------------------
   按钮
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: 14px 26px;
  border-radius: var(--r-md);
  font-size: var(--fs-md);
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease),
    background-color var(--dur) var(--ease);
}

.btn svg {
  flex: 0 0 auto;
}

.btn--primary {
  background: var(--brand);
  color: var(--text-on-brand);
  box-shadow: 0 10px 32px -10px rgba(245, 44, 140, 0.55);
}

.btn--primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 38px -8px rgba(245, 44, 140, 0.7);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  box-shadow: inset 0 0 0 1px var(--line-strong);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.09);
}

.btn--block {
  display: flex;
  width: 100%;
  padding-block: 15px;
}

.btn:active {
  transform: translateY(0);
}

/* --------------------------------------------------------------------------
   徽章 / 眉标
   -------------------------------------------------------------------------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 7px 14px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 0 0 1px var(--line);
  font-size: var(--fs-sm);
  color: var(--text-body);
}

.badge__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand-bright);
  box-shadow: 0 0 0 4px rgba(245, 44, 140, 0.16);
}

.eyebrow {
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--brand-ink);
}

/* 正文里的行内链接：靠颜色 + 下划线双重识别，不只靠颜色 */
.link {
  color: var(--brand-ink);
  text-decoration: underline;
  text-decoration-color: var(--brand-line);
  text-underline-offset: 3px;
  transition: text-decoration-color var(--dur) var(--ease);
}

.link:hover {
  text-decoration-color: currentColor;
}

/* --------------------------------------------------------------------------
   卡片
   -------------------------------------------------------------------------- */
.card {
  display: flex;
  flex-direction: column;
  gap: var(--sp-4);
  padding: var(--sp-7);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
}

.card--accent {
  box-shadow: inset 0 0 0 1px var(--brand-line);
}

.card--flush {
  padding: 0;
  overflow: hidden;
}

/* 图标方块 */
.icon-tile {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  flex: 0 0 auto;
}

.icon-tile--brand {
  background: var(--brand-soft);
  box-shadow: inset 0 0 0 1px var(--brand-line);
  color: var(--brand-bright);
}

.icon-tile--violet {
  background: var(--violet-soft);
  box-shadow: inset 0 0 0 1px var(--violet-line);
  color: var(--violet);
}

.icon-tile--sky {
  background: var(--sky-soft);
  box-shadow: inset 0 0 0 1px var(--sky-line);
  color: var(--sky);
}

.card__title {
  font-size: var(--fs-xl);
  color: var(--text);
}

.card__title--lg {
  font-size: 24px;
}

.card__desc {
  font-size: var(--fs-base);
  color: var(--text-muted);
  line-height: 1.72;
}

/* --------------------------------------------------------------------------
   图位（海报 / 通用媒体）
   -------------------------------------------------------------------------- */
.poster {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.poster__cover {
  position: relative;
  aspect-ratio: 196 / 261;
  overflow: hidden;
  border-radius: 14px;
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
}

.poster__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms var(--ease);
}

.poster:hover .poster__cover img {
  transform: scale(1.04);
}

.poster__title {
  font-size: var(--fs-base);
  font-weight: 500;
  color: var(--text-soft);
  line-height: 1.45;
}

.poster__meta {
  font-size: var(--fs-xs);
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   二维码
   -------------------------------------------------------------------------- */
.qr-plate {
  position: relative;
  width: var(--w-qr);
  aspect-ratio: 1;
  padding: 8px;
  border-radius: var(--r-lg);
  background: #fff;
  flex: 0 0 auto;
}

.qr-plate img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* --------------------------------------------------------------------------
   周放送表（信息展示，非控件）
   -------------------------------------------------------------------------- */
.day-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-5);
  align-items: center;
  font-size: var(--fs-sm);
  color: var(--text-muted);
}

.day-list__item[aria-current="true"] {
  color: var(--brand-ink);
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   规格行（下载卡内）
   -------------------------------------------------------------------------- */
.spec-list {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}

.spec-list li {
  display: flex;
  gap: var(--sp-2);
  font-size: var(--fs-sm);
  color: var(--text-body);
}

.spec-list li::before {
  content: "";
  flex: 0 0 auto;
  width: 4px;
  height: 4px;
  margin-top: 9px;
  border-radius: 50%;
  background: var(--brand-bright);
}

/* --------------------------------------------------------------------------
   编号步骤卡
   -------------------------------------------------------------------------- */
.step {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  padding: var(--sp-6);
  border-radius: var(--r-lg);
  background: var(--bg-sunken);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.step--accent {
  box-shadow: inset 0 0 0 1px var(--brand-line);
}

.step__no {
  font-family: var(--font-num);
  font-size: 18px;
  font-weight: 700;
  color: var(--brand-bright);
  letter-spacing: 0.04em;
}

.step__title {
  font-size: var(--fs-md);
  font-weight: 700;
  color: var(--text);
}

.step__desc {
  font-size: var(--fs-sm);
  color: var(--text-muted);
  line-height: 1.62;
}

/* --------------------------------------------------------------------------
   问答：原生 details，无 JS 也能展开
   -------------------------------------------------------------------------- */
.qa {
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.qa:last-child {
  border-bottom: 0;
}

.qa__q {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--sp-4);
  padding: 20px var(--sp-6);
  font-size: var(--fs-base);
  font-weight: 700;
  color: var(--text-soft);
  cursor: pointer;
  list-style: none;
  transition: color var(--dur) var(--ease);
}

.qa__q::-webkit-details-marker {
  display: none;
}

.qa__q:hover {
  color: var(--text);
}

.qa__q::after {
  content: "";
  flex: 0 0 auto;
  width: 10px;
  height: 10px;
  margin-top: 7px;
  border-right: 2px solid var(--text-muted);
  border-bottom: 2px solid var(--text-muted);
  transform: rotate(45deg);
  transition: transform var(--dur) var(--ease);
}

.qa[open] .qa__q::after {
  transform: rotate(-135deg);
}

.qa__a {
  padding: 0 var(--sp-6) 22px;
  font-size: var(--fs-sm);
  color: var(--text-muted);
  line-height: 1.7;
}

/* --------------------------------------------------------------------------
   更新日志
   -------------------------------------------------------------------------- */
.log-item {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: var(--sp-8);
  padding: 28px var(--sp-6);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.log-item:last-child {
  border-bottom: 0;
}

.log-item__ver {
  font-family: var(--font-num);
  font-size: var(--fs-xl);
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}

.log-item__date {
  font-size: var(--fs-xs);
  color: var(--text-muted);
}

.log-item__date--latest {
  color: var(--brand-ink);
  font-weight: 700;
}

.log-item__title {
  font-size: var(--fs-md);
  font-weight: 700;
  color: var(--text-soft);
}

.log-item__list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: var(--sp-2);
}

.log-item__list li {
  position: relative;
  padding-left: 14px;
  font-size: var(--fs-sm);
  color: var(--text-muted);
  line-height: 1.65;
}

.log-item__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 5px;
  height: 1px;
  background: var(--brand-bright);
}

/* --------------------------------------------------------------------------
   对比表：圆角与描边挂在包裹层上（table 自己不渲染 inset 阴影）
   -------------------------------------------------------------------------- */
.table-frame {
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
}

.cmp {
  width: 100%;
  border-collapse: collapse;
}

.cmp th,
.cmp td {
  padding: 17px var(--sp-6);
  text-align: left;
  font-size: var(--fs-sm);
  vertical-align: middle;
}

.cmp thead th {
  background: rgba(255, 255, 255, 0.03);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.cmp thead th:last-child {
  color: var(--brand-ink);
}

.cmp tbody td:first-child {
  width: 40%;
  font-size: var(--fs-base);
  font-weight: 500;
  color: var(--text-soft);
}

.cmp tbody td {
  color: var(--text-muted);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.cmp tbody td:last-child {
  color: var(--brand-ink);
  font-weight: 500;
}

/* --------------------------------------------------------------------------
   分隔线 / 元信息
   -------------------------------------------------------------------------- */
.divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  border: 0;
}

.meta-line {
  font-size: var(--fs-sm);
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   移动端：组件级覆盖写在这里，不写到 layout.css
   -------------------------------------------------------------------------- */
@media (max-width: 900px) {
  .card {
    padding: var(--sp-6);
  }

  .icon-tile {
    width: 44px;
    height: 44px;
  }

  .log-item {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--sp-2);
    padding: 22px var(--sp-5);
  }

  .log-item__ver {
    font-size: var(--fs-lg);
  }
}

@media (max-width: 560px) {
  .btn {
    padding: 13px 20px;
    font-size: var(--fs-base);
  }

  .day-list {
    gap: var(--sp-3);
  }

  .qr-plate {
    --w-qr: 140px;
  }

  .cmp th,
  .cmp td {
    padding: 13px 14px;
  }

  .cmp tbody td:first-child {
    width: 36%;
  }

  .qa__q {
    padding: 16px var(--sp-4);
  }

  .qa__a {
    padding: 0 var(--sp-4) 18px;
  }
}
