/* PlayArcade - 统一样式 */
:root {
  --bg: #f6f7fb;
  --card: #ffffff;
  --text: #1f2430;
  --muted: #6b7280;
  --primary: #4f46e5;
  --primary-dark: #4338ca;
  --border: #e5e7eb;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(17, 24, 39, .08), 0 4px 14px rgba(17, 24, 39, .05);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container { width: min(1100px, 92%); margin: 0 auto; }

/* Header */
.site-header {
  background: var(--card);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: .7rem;
  padding-bottom: .7rem;
}
.logo {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--primary);
  text-decoration: none;
  letter-spacing: -.01em;
}
.logo span { color: var(--text); }
.site-nav { display: flex; gap: 1rem; flex-wrap: wrap; }
.site-nav a { color: var(--muted); text-decoration: none; font-size: .92rem; }
.site-nav a:hover { color: var(--primary); }

/* Main */
main { flex: 1; padding: 1.5rem 0 3rem; }

h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  line-height: 1.25;
  margin: .5rem 0 .4rem;
  letter-spacing: -.02em;
}
.lead { color: var(--muted); font-size: 1.02rem; max-width: 60ch; margin-bottom: 1.4rem; }

h2 {
  font-size: 1.25rem;
  margin: 2rem 0 1rem;
  letter-spacing: -.01em;
}
h3 { font-size: 1.05rem; }

/* Game grid */
.game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: .9rem;
}
.game-card {
  display: block;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem;
  text-decoration: none;
  color: var(--text);
  transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}
.game-card:hover { transform: translateY(-2px); border-color: var(--primary); box-shadow: 0 6px 18px rgba(79, 70, 229, .12); }
.game-card .thumb {
  height: 84px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin-bottom: .6rem;
  background: linear-gradient(135deg, #eef0ff, #f7f8ff);
}
.game-card .name { font-weight: 700; font-size: .95rem; line-height: 1.3; }
.game-card .desc { color: var(--muted); font-size: .8rem; margin-top: .2rem; }

/* Game page layout */
.game-page .game-shell {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem;
  margin: 1rem 0 1.5rem;
}
.game-frame {
  width: 100%;
  aspect-ratio: 16 / 10;
  min-height: 420px;
  border: none;
  display: block;
  background: #0f172a;
  border-radius: 8px;
  overflow: hidden;
}
.game-meta { display: flex; gap: .6rem; flex-wrap: wrap; margin: 1rem 0; }
.tag {
  background: #eef0ff;
  color: var(--primary-dark);
  font-size: .78rem;
  padding: .2rem .6rem;
  border-radius: 999px;
  text-decoration: none;
}
.tag:hover { background: #e0e3ff; }

.prose { max-width: 72ch; }
.prose p { margin-bottom: .8rem; color: #374151; }
.prose ul { margin: 0 0 .8rem 1.3rem; }
.prose li { margin-bottom: .3rem; }

/* Related games */
.related { margin-top: 2rem; }

/* Breadcrumb */
.breadcrumb { font-size: .85rem; color: var(--muted); margin-bottom: .4rem; }
.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--primary); }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--card);
  padding: 1.4rem 0;
  color: var(--muted);
  font-size: .85rem;
}
.site-footer .container { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem; }

/* Buttons */
.btn {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: .55rem 1.2rem;
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
}
.btn:hover { background: var(--primary-dark); }
.btn-secondary { background: #eef0ff; color: var(--primary-dark); }
.btn-secondary:hover { background: #e0e3ff; }

/* Simple toast / notice */
.notice {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
  border-radius: 8px;
  padding: .6rem .9rem;
  font-size: .88rem;
  margin: .8rem 0;
}

@media (max-width: 640px) {
  .game-frame { min-height: 320px; }
  .game-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
}
