:root {
  --bg: #f7f7f5;
  --surface: #ffffff;
  --text: #16181d;
  --muted: #5d6270;
  --line: #e6e5e1;
  --accent: #2f6df6;
  --accent-soft: #e8efff;
  --radius: 18px;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.04), 0 8px 24px rgba(16, 24, 40, 0.06);
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1115;
    --surface: #171a21;
    --text: #eef0f4;
    --muted: #9aa1b0;
    --line: #262a33;
    --accent: #6d9bff;
    --accent-soft: #1b2540;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.25);
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Noto Sans SC", sans-serif;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 20px; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--text); letter-spacing: -0.01em; }
.brand:hover { text-decoration: none; }
.brand img { width: 28px; height: 28px; }
.nav { display: flex; gap: 20px; font-size: 15px; }
.nav a { color: var(--muted); }
.nav a:hover { color: var(--text); text-decoration: none; }

/* Hero */
.hero { padding: 72px 0 40px; }
.hero h1 { font-size: clamp(32px, 5vw, 48px); line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 16px; max-width: 720px; }
.hero p { font-size: 18px; color: var(--muted); margin: 0; max-width: 620px; }

/* Apps */
.section { padding: 24px 0 64px; }
.section h2 { font-size: 22px; margin: 0 0 20px; letter-spacing: -0.01em; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }

.card {
  display: flex; flex-direction: column; gap: 12px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow); color: var(--text);
  transition: transform 0.15s ease, border-color 0.15s ease;
}
.card:hover { transform: translateY(-2px); border-color: var(--accent); text-decoration: none; }
.card .icon {
  width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center;
  font-size: 26px; background: var(--accent-soft);
}
.card h3 { margin: 0; font-size: 18px; }
.card p { margin: 0; color: var(--muted); font-size: 15px; flex: 1; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 12px; padding: 2px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.card .go { font-size: 14px; font-weight: 600; color: var(--accent); }

/* About */
.about { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.about p { margin: 0 0 12px; color: var(--muted); }
.about p:last-child { margin-bottom: 0; }

/* Legal pages */
.doc { padding: 48px 0 72px; max-width: 760px; }
.doc h1 { font-size: 32px; margin: 0 0 4px; letter-spacing: -0.02em; }
.doc .updated { color: var(--muted); font-size: 14px; margin: 0 0 32px; }
.doc h2 { font-size: 20px; margin: 32px 0 8px; }
.doc p, .doc li { color: var(--muted); }
.doc ul { padding-left: 20px; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 28px 0 40px; color: var(--muted); font-size: 14px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; }
.site-footer nav { display: flex; gap: 20px; }
.site-footer a { color: var(--muted); }

@media (max-width: 560px) {
  .nav { gap: 14px; font-size: 14px; }
  .hero { padding: 48px 0 28px; }
  .hero p { font-size: 16px; }
}
