/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
               "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: #e0e0e0;
  background: #1a1a2e;
  background-image:
    radial-gradient(ellipse at 20% 20%, rgba(233, 69, 96, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 80%, rgba(26, 115, 232, 0.08) 0%, transparent 50%);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===== Header ===== */
.header {
  text-align: center;
  padding: clamp(32px, 6vw, 60px) clamp(16px, 4vw, 20px) clamp(24px, 4vw, 40px);
  position: relative;
  overflow: hidden;
}

.header-inner { position: relative; z-index: 1; }

.title {
  font-size: clamp(1.4rem, 4vw, 2.2rem);
  font-weight: 700;
  color: #f0f0f0;
  letter-spacing: 0.05em;
}

.subtitle {
  margin-top: clamp(4px, 1vw, 8px);
  font-size: clamp(0.85rem, 2vw, 1rem);
  color: #999;
  letter-spacing: 0.1em;
}

.header-glow {
  position: absolute;
  top: -80px;
  left: 50%;
  transform: translateX(-50%);
  width: min(360px, 80vw);
  height: 200px;
  background: radial-gradient(circle, rgba(233, 69, 96, 0.12) 0%, transparent 70%);
  pointer-events: none;
}

/* ===== Main Container ===== */
.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 clamp(12px, 3vw, 20px) clamp(40px, 8vw, 60px);
  flex: 1;
  width: 100%;
}

/* ===== Section ===== */
.section { margin-bottom: clamp(32px, 5vw, 48px); }

.section-title {
  font-size: clamp(1.1rem, 2.5vw, 1.3rem);
  font-weight: 600;
  color: #ccc;
  margin-bottom: clamp(14px, 2vw, 20px);
  padding-left: 4px;
}

/* ===== Card Grid ===== */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(250px, 100%), 1fr));
  gap: clamp(12px, 2vw, 20px);
}

/* ===== Card ===== */
.card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: clamp(18px, 3vw, 28px) clamp(16px, 2.5vw, 24px) clamp(16px, 2.5vw, 22px);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-decoration: none;
  color: inherit;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  min-height: 100px;
}

.card:not(.card--placeholder):hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.14);
}

.card:not(.card--placeholder):active {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
  background: rgba(255, 255, 255, 0.1);
  transition: transform 0.1s ease, box-shadow 0.1s ease;
}

.card--placeholder {
  cursor: default;
  opacity: 0.65;
}

/* ===== Card Icon ===== */
.card-icon {
  font-size: clamp(1.6rem, 3vw, 2rem);
  margin-bottom: clamp(8px, 1.5vw, 12px);
  line-height: 1;
}

/* ===== Card Body ===== */
.card-body { flex: 1; }

.card-title {
  font-size: clamp(1rem, 2vw, 1.1rem);
  font-weight: 600;
  color: #eee;
  margin-bottom: 4px;
}

.card-desc {
  font-size: clamp(0.8rem, 1.5vw, 0.9rem);
  color: #999;
}

/* ===== Card Link ===== */
.card-link {
  display: inline-block;
  margin-top: clamp(12px, 2vw, 16px);
  font-size: clamp(0.8rem, 1.5vw, 0.9rem);
  font-weight: 500;
  color: #e94560;
  transition: color 0.2s;
}

.card:not(.card--placeholder):hover .card-link { color: #ff6b81; }

.card-link--muted { color: #666; cursor: default; }

/* ===== Footer ===== */
.footer {
  text-align: center;
  padding: clamp(16px, 3vw, 24px) clamp(12px, 3vw, 20px);
  font-size: clamp(0.75rem, 1.5vw, 0.85rem);
  color: #666;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

/* ===== Tablet (≤768px) ===== */
@media (max-width: 768px) {
  .header-glow { height: 140px; top: -50px; }

  .card-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }
}

/* ===== Phone (≤480px) ===== */
@media (max-width: 480px) {
  .header-glow { height: 100px; top: -30px; }

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

  .card {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    padding: 16px;
    border-radius: 12px;
    min-height: unset;
  }

  .card-icon {
    font-size: 1.5rem;
    margin-bottom: 0;
    margin-right: 12px;
    flex-shrink: 0;
  }

  .card-body { flex: 1; min-width: 0; }

  .card-link {
    width: 100%;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
  }

  .section-title { padding-left: 2px; }
}
