:root {
  --bg: #f6f5f1;
  --bg-soft: #efede7;
  --card: #ffffff;
  --ink: #17171c;
  --muted: #6d6d76;
  --line: #e7e4dc;
  --accent: #ff5a30;
  --accent-dark: #e8481f;
  --yellow: #ffc53d;
  --blue: #3b6cff;
  --green: #1ea672;
  --radius-lg: 24px;
  --radius-md: 16px;
  --shadow-card: 0 1px 2px rgba(23, 23, 28, 0.04), 0 12px 32px rgba(23, 23, 28, 0.07);
  --shadow-float: 0 2px 6px rgba(23, 23, 28, 0.06), 0 24px 60px rgba(23, 23, 28, 0.14);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

.container { max-width: 1120px; margin: 0 auto; padding: 0 28px; }

/* ---------- nav ---------- */
.nav-wrap { position: sticky; top: 0; z-index: 50; padding-top: 16px; }
.nav {
  max-width: 1120px; margin: 0 auto; padding: 10px 12px 10px 22px;
  display: flex; align-items: center; gap: 28px;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: 0 6px 24px rgba(23, 23, 28, 0.06);
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 17px; letter-spacing: -0.02em; }
.brand .dot {
  width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--accent), #ff8a3d); color: #fff;
  font-size: 15px; font-weight: 800;
}
.nav .links { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.nav .links a {
  padding: 8px 14px; border-radius: 999px; font-size: 14.5px; font-weight: 500; color: var(--muted);
  transition: all .18s ease;
}
.nav .links a:hover { color: var(--ink); background: var(--bg-soft); }
.nav .links a.active { color: var(--ink); background: var(--bg-soft); font-weight: 600; }
.nav .cta {
  display: inline-flex; align-items: center; gap: 7px;
  background: var(--ink); color: #fff; font-weight: 600; font-size: 14px;
  padding: 9px 18px; border-radius: 999px; margin-left: 8px;
  transition: all .18s ease;
}
.nav .cta:hover { background: var(--accent); transform: translateY(-1px); }

/* ---------- hero ---------- */
.hero { position: relative; padding: 88px 0 72px; }
.hero-blob { position: absolute; border-radius: 50%; filter: blur(2px); z-index: -1; }
.hero-blob.b1 { width: 520px; height: 520px; right: -140px; top: -80px; background: radial-gradient(circle at 30% 30%, #ffd76e, #ffc53d); opacity: .55; }
.hero-blob.b2 { width: 380px; height: 380px; right: 60px; top: 240px; background: radial-gradient(circle at 60% 40%, #6d94ff, #3b6cff); opacity: .35; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 7px 16px; font-size: 13.5px; font-weight: 600; color: var(--muted);
  box-shadow: 0 4px 14px rgba(23,23,28,.05);
}
.hero-eyebrow .pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px rgba(30,166,114,.18); }
h1.display {
  font-size: clamp(40px, 6.4vw, 72px); line-height: 1.08; letter-spacing: -0.03em;
  font-weight: 800; margin: 26px 0 10px; max-width: 720px;
}
h1.display .u { position: relative; white-space: nowrap; }
h1.display .u svg { position: absolute; left: 0; bottom: -10px; width: 100%; height: 14px; }
.hero-sub { font-size: 18.5px; color: var(--muted); max-width: 620px; margin-top: 18px; }
.hero-sub strong { color: var(--ink); font-weight: 600; }
.hero-actions { display: flex; gap: 14px; margin-top: 34px; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 14px 26px; border-radius: 999px; font-size: 15.5px; font-weight: 600;
  transition: all .18s ease; border: 1px solid transparent; cursor: pointer;
}
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 10px 26px rgba(255, 90, 48, 0.32); }
.btn-primary:hover { background: var(--accent-dark); transform: translateY(-2px); }
.btn-ghost { background: #fff; color: var(--ink); border-color: var(--line); box-shadow: 0 4px 14px rgba(23,23,28,.05); }
.btn-ghost:hover { border-color: var(--ink); transform: translateY(-2px); }

/* floating mini cards in hero */
.hero-visual { position: absolute; right: 0; top: 90px; width: 400px; z-index: -1; }
.float-card {
  position: absolute; background: #fff; border-radius: var(--radius-md);
  box-shadow: var(--shadow-float); border: 1px solid var(--line);
  padding: 14px 18px; display: flex; align-items: center; gap: 12px;
  animation: floaty 6s ease-in-out infinite;
}
.float-card .fc-icon {
  width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-size: 21px;
}
.float-card .fc-t { font-weight: 700; font-size: 14.5px; line-height: 1.25; }
.float-card .fc-s { font-size: 12.5px; color: var(--muted); }
.fc1 { right: 210px; top: 0; }
.fc2 { right: 0; top: 120px; animation-delay: -2s; }
.fc3 { right: 120px; top: 240px; animation-delay: -4s; }
@keyframes floaty { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }

/* ---------- stats strip ---------- */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin: 30px 0 0; }
.stat {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-md);
  padding: 20px 24px;
}
.stat .n { font-size: 30px; font-weight: 800; letter-spacing: -0.02em; }
.stat .n em { font-style: normal; color: var(--accent); }
.stat .l { color: var(--muted); font-size: 14px; margin-top: 2px; }

/* ---------- sections ---------- */
section { padding: 64px 0; }
.section-head { margin-bottom: 34px; }
.kicker {
  color: var(--accent); font-weight: 700; font-size: 14px; letter-spacing: .12em;
  text-transform: uppercase; margin-bottom: 10px;
}
h2 { font-size: clamp(28px, 4vw, 40px); letter-spacing: -0.025em; line-height: 1.15; font-weight: 800; }
.section-desc { color: var(--muted); font-size: 16.5px; margin-top: 12px; max-width: 640px; }

/* ---------- cards ---------- */
.cards-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 24px; display: flex; flex-direction: column; gap: 12px;
  box-shadow: var(--shadow-card);
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 4px 10px rgba(23,23,28,.05), 0 22px 48px rgba(23,23,28,.11); }
.card-top { display: flex; align-items: center; gap: 14px; }
.card-emoji {
  width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center;
  font-size: 27px; flex: none;
}
.card-name { font-size: 18.5px; font-weight: 750; letter-spacing: -0.01em; line-height: 1.3; }
.card-tagline { font-size: 13.5px; color: var(--muted); margin-top: 2px; }
.card-desc { font-size: 14.5px; color: #3d3d46; flex: 1; }
.card-tags { display: flex; flex-wrap: wrap; gap: 7px; }
.tag {
  font-size: 12px; font-weight: 600; color: var(--muted);
  background: var(--bg-soft); border-radius: 999px; padding: 4px 11px;
}
.card-foot { display: flex; align-items: center; gap: 10px; margin-top: 4px; padding-top: 16px; border-top: 1px dashed var(--line); }
.card-visit {
  display: inline-flex; align-items: center; gap: 7px;
  background: var(--ink); color: #fff; font-size: 13.5px; font-weight: 600;
  padding: 9px 18px; border-radius: 999px; transition: all .18s ease;
}
.card-visit:hover { background: var(--accent); }
.card-visit::after { content: "→"; font-size: 14px; transition: transform .18s ease; }
.card-visit:hover::after { transform: translateX(3px); }
.card-repo {
  margin-left: auto; color: var(--muted); display: inline-flex; align-items: center; gap: 6px;
  font-size: 12.5px; font-weight: 600; transition: color .18s ease;
}
.card-repo:hover { color: var(--ink); }
.card-url { font-size: 12px; color: #a3a3ab; margin-top: -4px; word-break: break-all; }

/* emoji tile backgrounds */
.g-amber { background: linear-gradient(135deg, #fff3e0, #ffd9a8); }
.g-violet { background: linear-gradient(135deg, #efe6ff, #d9c8ff); }
.g-mint { background: linear-gradient(135deg, #e2f8ec, #bdefd2); }
.g-sky { background: linear-gradient(135deg, #e3edff, #c4d8ff); }
.g-rose { background: linear-gradient(135deg, #ffe9ec, #ffc9d2); }
.g-lemon { background: linear-gradient(135deg, #fff7d6, #ffef9e); }
.g-slate { background: linear-gradient(135deg, #eceef2, #d5d9e2); }

/* ---------- about ---------- */
.about-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; align-items: start; }
.about-text p { color: #3d3d46; font-size: 16px; margin-bottom: 14px; }
.about-text strong { font-weight: 650; }
.chip-row { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 18px; }
.chip {
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 8px 16px; font-size: 13.5px; font-weight: 600; color: var(--ink);
  display: inline-flex; align-items: center; gap: 7px;
}
.about-side { display: grid; gap: 14px; }
.side-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-md);
  padding: 18px 20px; display: flex; gap: 14px; align-items: flex-start;
  box-shadow: var(--shadow-card);
}
.side-card .sc-icon { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; font-size: 18px; flex: none; }
.side-card .sc-t { font-weight: 700; font-size: 14.5px; }
.side-card .sc-s { color: var(--muted); font-size: 13.5px; }
.side-card a { color: var(--accent); font-weight: 600; }
.side-card a:hover { text-decoration: underline; }

/* ---------- filter pills ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 30px; }
.filter {
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 9px 20px; font-size: 14px; font-weight: 600; color: var(--muted);
  cursor: pointer; transition: all .16s ease; font-family: inherit;
}
.filter:hover { color: var(--ink); border-color: #c9c6bd; }
.filter.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.hidden { display: none !important; }

/* ---------- code-only repo list ---------- */
.repo-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.repo-item {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-md);
  padding: 16px 20px; display: flex; align-items: center; gap: 14px;
  transition: all .18s ease;
}
.repo-item:hover { border-color: #cfccc3; transform: translateY(-2px); box-shadow: var(--shadow-card); }
.repo-item .ri-icon { font-size: 22px; flex: none; }
.repo-item .ri-t { font-weight: 700; font-size: 15px; }
.repo-item .ri-s { color: var(--muted); font-size: 13.5px; }
.repo-item .ri-arrow { margin-left: auto; color: #b9b7af; font-size: 17px; }
.repo-item:hover .ri-arrow { color: var(--accent); }

/* ---------- footer ---------- */
footer { border-top: 1px solid var(--line); padding: 40px 0 48px; margin-top: 40px; }
.foot { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; color: var(--muted); font-size: 14px; }
.foot .f-brand { font-weight: 750; color: var(--ink); display: flex; gap: 9px; align-items: center; }
.foot .f-brand .dot { width: 24px; height: 24px; border-radius: 8px; display: grid; place-items: center; background: linear-gradient(135deg, var(--accent), #ff8a3d); color: #fff; font-size: 12px; font-weight: 800; }
.foot .right { margin-left: auto; display: flex; gap: 18px; }
.foot a:hover { color: var(--ink); }

/* ---------- responsive ---------- */
@media (max-width: 980px) {
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-visual { display: none; }
  .about-grid { grid-template-columns: 1fr; }
  .repo-list { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .cards-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr; }
  .nav .links a:not(.cta) { display: none; }
  .nav .links a.active { display: inline-block; }
  h1.display { font-size: 38px; }
  section { padding: 44px 0; }
}
