/* ============================================================
   Helpme 后端开发板块页专属样式
   基调复用 css/style.css：酷黑 + 蓝紫渐变 + 圆角细边框 + 悬停上浮
   ============================================================ */

/* ---------- 导航栏当前页高亮 ---------- */
.nav-link.active {
  color: #fff;
  background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
}

.nav-link.active:hover {
  color: #fff;
  background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
}

.mobile-link.active {
  color: var(--text-primary);
}

/* ---------- Hero 区技术栈统计条 ---------- */
.hero-stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 8px;
}

.stat-card {
  min-width: 150px;
  padding: 18px 26px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
}

.stat-num {
  font-size: 32px;
  font-weight: 800;
  line-height: 1.1;
  background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.stat-label {
  margin-top: 6px;
  font-size: 13px;
  color: var(--text-secondary);
}

/* ---------- 语言分区 ---------- */
.lang-section {
  margin-bottom: 64px;
}

.lang-head {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 24px 28px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-bottom: 20px;
}

.lang-icon {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.16), rgba(168, 85, 247, 0.16));
  border: 1px solid var(--border);
}

.lang-info {
  flex: 1;
  min-width: 0;
}

.lang-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 6px;
}

.lang-name {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.lang-en {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  padding: 3px 10px;
  border-radius: 999px;
}

.lang-desc {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.lang-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag-accent {
  background: rgba(99, 102, 241, 0.12);
  border-color: rgba(99, 102, 241, 0.35);
  color: #c7d2fe;
}

.tag-soft {
  background: rgba(168, 85, 247, 0.12);
  border-color: rgba(168, 85, 247, 0.35);
  color: #e9d5ff;
}

/* ---------- 框架卡片网格 ---------- */
.frame-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 16px;
}

.frame-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 20px;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.frame-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-card);
}

.frame-name {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}

.frame-desc {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 12px;
  line-height: 1.55;
}

.frame-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* ---------- 后端技术栈全景 ---------- */
.stack-section {
  margin-top: 40px;
}

.stack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.stack-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 24px;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.stack-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-card);
}

.stack-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.stack-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
}

.stack-title {
  font-size: 17px;
  font-weight: 700;
}

.stack-desc {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 14px;
}

.stack-items {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.stack-item {
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.18), rgba(168, 85, 247, 0.18));
  border: 1px solid rgba(99, 102, 241, 0.35);
  border-radius: 999px;
}

/* ---------- 响应式 ---------- */
@media (max-width: 768px) {
  .lang-head {
    flex-direction: column;
    gap: 14px;
    padding: 20px;
  }

  .lang-icon {
    width: 48px;
    height: 48px;
    font-size: 26px;
  }

  .frame-grid {
    grid-template-columns: 1fr;
  }

  .stack-grid {
    grid-template-columns: 1fr;
  }

  .stat-card {
    min-width: 120px;
    padding: 14px 18px;
  }
}

/* ---------- Java 基础教程入口卡 ---------- */
.entry-card {
  background: linear-gradient(145deg, rgba(99, 102, 241, 0.14), rgba(168, 85, 247, 0.14));
  border: 1px solid rgba(99, 102, 241, 0.55);
  position: relative;
  overflow: hidden;
}

.entry-card::before {
  content: "📗";
  position: absolute;
  right: -14px;
  top: -14px;
  font-size: 76px;
  opacity: 0.14;
  transform: rotate(-12deg);
}

.entry-card:hover {
  border-color: var(--accent-1);
  box-shadow: 0 12px 32px rgba(99, 102, 241, 0.22);
}

.entry-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 17px;
  font-weight: 800;
  margin-bottom: 8px;
}

.entry-title .entry-badge {
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(90deg, var(--accent-1), var(--accent-2));
  border-radius: 999px;
  padding: 2px 10px;
}

.entry-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 14px;
}

.entry-btn {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(90deg, var(--accent-1), var(--accent-2));
  border-radius: 8px;
  padding: 8px 18px;
  text-decoration: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.entry-btn:hover {
  opacity: 0.88;
  transform: translateY(-2px);
}

/* ---------- 卡片统一弹性布局：按钮沉底对齐（对齐 frontend/ai/computer 板块） ---------- */
.frame-card {
  display: flex;
  flex-direction: column;
}

.frame-card .frame-tags {
  margin-bottom: 10px;
}

.frame-card .entry-btn {
  margin-top: 4px;
  align-self: flex-start;
}

.stack-card {
  display: flex;
  flex-direction: column;
}

.stack-card .stack-items {
  margin-bottom: 10px;
}

.stack-card .entry-btn {
  margin-top: 4px;
  align-self: flex-start;
}
