/* MyGit's site: one centred column on near-black, the logo's blue and green
   as the only colour, cards for everything that isn't a heading. */

:root {
  --bg: #07090F;
  --panel: rgba(255, 255, 255, .025);
  --panel-hi: rgba(255, 255, 255, .05);
  --border: rgba(255, 255, 255, .08);
  --border-hi: rgba(255, 255, 255, .16);
  --text: #EDF0F7;
  --muted: #8A93A8;
  --faint: #5A6378;
  --blue: #5B93FF;
  --blue-hi: #7FB2FF;
  --green: #34D399;
  --green-hi: #6EF0B4;
  --grad: linear-gradient(90deg, #7FB2FF, #6EF0B4);
  --sans: "Geist", "Noto Sans SC", -apple-system, "PingFang SC", sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --wrap: 1120px;
  --radius: 18px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
html[lang="zh-CN"] body { line-height: 1.75; }
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
code { font-family: var(--mono); font-size: .9em; }
::selection { background: rgba(91, 147, 255, .35); }

/* A faint glow and dot grid behind the top of the page. */
.backdrop {
  position: absolute;
  inset: 0 0 auto 0;
  height: 1400px;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(60% 50% at 50% 0%, rgba(61, 123, 255, .22), transparent 70%),
    radial-gradient(35% 30% at 72% 18%, rgba(31, 191, 122, .10), transparent 70%);
}
.backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: radial-gradient(70% 60% at 50% 20%, #000, transparent 75%);
  -webkit-mask-image: radial-gradient(70% 60% at 50% 20%, #000, transparent 75%);
}

/* ---------- Nav ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  background: rgba(7, 9, 15, .62);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.nav.scrolled { border-bottom-color: var(--border); }
.nav-inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  gap: 32px;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 17px; letter-spacing: -.01em; }
.nav-links { display: flex; gap: 26px; font-size: 14px; color: var(--muted); }
.nav-links a:hover { color: var(--text); }
.nav-end { margin-left: auto; display: flex; align-items: center; gap: 12px; }

.lang { display: flex; padding: 3px; border: 1px solid var(--border); border-radius: 999px; }
.lang button {
  border: 0;
  background: none;
  color: var(--muted);
  font: 500 12px var(--sans);
  padding: 4px 10px;
  border-radius: 999px;
  cursor: pointer;
}
.lang button[aria-pressed="true"] { background: var(--panel-hi); color: var(--text); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 500;
  font-size: 15px;
  transition: transform .15s, background .15s, border-color .15s, box-shadow .15s;
}
.btn:active { transform: translateY(1px); }
.btn-sm { height: 34px; padding: 0 14px; font-size: 13px; }
.btn-primary {
  color: #06101F;
  background: linear-gradient(180deg, #FFFFFF, #DCE6FA);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .2), 0 8px 30px -8px rgba(127, 178, 255, .6);
}
.btn-primary:hover { box-shadow: 0 0 0 1px rgba(255, 255, 255, .3), 0 10px 40px -6px rgba(127, 178, 255, .8); }
.btn-ghost { border: 1px solid var(--border-hi); background: var(--panel); }
.btn-ghost:hover { background: var(--panel-hi); border-color: rgba(255, 255, 255, .26); }

/* ---------- Layout ---------- */

main > section { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.section { padding-top: 140px; text-align: center; }
.eyebrow {
  margin: 0 0 14px;
  font: 500 13px var(--mono);
  letter-spacing: .04em;
  text-transform: uppercase;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -.035em; }
h2 { font-size: clamp(34px, 4.4vw, 52px); line-height: 1.08; }
html[lang="zh-CN"] h1, html[lang="zh-CN"] h2, html[lang="zh-CN"] h3 { letter-spacing: 0; }
html[lang="zh-CN"] h2 { line-height: 1.25; }
.section-lede { max-width: 620px; margin: 18px auto 0; color: var(--muted); font-size: 18px; }

.card {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
/* A soft light that follows the pointer across a card. */
.card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  transition: opacity .3s;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(127, 178, 255, .09), transparent 60%);
}
.card:hover::before { opacity: 1; }

/* ---------- Hero ---------- */

main > .hero { padding-top: 96px; text-align: center; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 10px;
  border: 1px solid var(--border-hi);
  border-radius: 999px;
  background: var(--panel);
  font-size: 13px;
  color: var(--muted);
  transition: border-color .2s, color .2s;
}
.pill:hover { color: var(--text); border-color: rgba(255, 255, 255, .26); }
.pill-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); }
.pill-arrow { transition: transform .2s; }
.pill:hover .pill-arrow { transform: translateX(3px); }

.hero h1 {
  margin: 28px auto 0;
  font-size: clamp(44px, 7vw, 84px);
  line-height: 1.02;
  letter-spacing: -.045em;
}
html[lang="zh-CN"] .hero h1 { line-height: 1.18; letter-spacing: 0; font-size: clamp(36px, 6.4vw, 78px); }
/* A phrase that breaks only around itself, never inside. */
.nw { display: inline-block; white-space: nowrap; }
.grad {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.lede { max-width: 600px; margin: 24px auto 0; color: var(--muted); font-size: 19px; }
.cta { display: flex; justify-content: center; gap: 12px; margin-top: 36px; flex-wrap: wrap; }
.platforms { margin: 18px 0 0; color: var(--faint); font-size: 13px; }

.hero-stage { position: relative; margin-top: 72px; }
.hero-glow {
  position: absolute;
  inset: 6% 10% auto;
  height: 70%;
  background: radial-gradient(closest-side, rgba(61, 123, 255, .5), rgba(31, 191, 122, .2) 60%, transparent);
  filter: blur(60px);
  z-index: -1;
}
.hero-shot {
  margin: 0;
  padding: 8px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .14), rgba(255, 255, 255, .03));
  box-shadow: 0 50px 120px -40px rgba(0, 0, 0, .9);
}
.hero-shot img { border-radius: 15px; }

/* ---------- Demo ---------- */

.video-frame { margin-top: 48px; padding: 8px; }
.video-frame video { width: 100%; aspect-ratio: 16 / 9; border-radius: 12px; background: #0A1022; }
.play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 84px;
  height: 84px;
  margin: -42px 0 0 -42px;
  display: grid;
  place-items: center;
  padding-left: 4px;
  border: 1px solid rgba(255, 255, 255, .3);
  border-radius: 50%;
  color: #fff;
  background: rgba(10, 16, 34, .55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  cursor: pointer;
  transition: transform .2s, background .2s;
}
.play:hover { transform: scale(1.06); background: rgba(61, 123, 255, .55); }
.video-frame.playing .play { display: none; }

/* ---------- Why ---------- */

.memory { max-width: 860px; margin: 56px auto 0; padding: 32px 36px; text-align: left; }
.bar-row { display: grid; grid-template-columns: 190px 1fr 92px; align-items: center; gap: 20px; padding: 10px 0; }
.bar-label { color: var(--muted); font-size: 15px; }
.bar-label b { color: var(--text); font-weight: 600; }
.bar { height: 12px; border-radius: 999px; background: rgba(255, 255, 255, .05); overflow: hidden; }
.fill { display: block; height: 100%; width: 0; border-radius: inherit; transition: width 1.6s cubic-bezier(.2, .8, .2, 1); }
.in .fill { width: var(--w); }
.fill-mygit { background: linear-gradient(90deg, var(--green), var(--green-hi)); box-shadow: 0 0 18px rgba(52, 211, 153, .5); }
.fill-other { background: linear-gradient(90deg, #3A4560, #56627E); }
.bar-value { text-align: right; font: 500 18px var(--mono); }
.bar-note { margin: 14px 0 0; color: var(--faint); font-size: 13px; }

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  max-width: 860px;
  margin: 20px auto 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.stats div { padding: 26px 20px; text-align: left; }
.stats div + div { border-left: 1px solid var(--border); }
.stats dt { font-size: 34px; font-weight: 600; letter-spacing: -.03em; line-height: 1; }
.stats dt small { font-size: 18px; color: var(--muted); margin-left: 2px; font-weight: 500; }
.stats dd { margin: 10px 0 0; color: var(--muted); font-size: 14px; line-height: 1.5; }

/* ---------- Compared ---------- */

.compare { max-width: 860px; margin: 56px auto 0; text-align: left; }
.compare-row {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1fr;
  gap: 24px;
  padding: 18px 28px;
  font-size: 15px;
  align-items: start;
}
.compare-row + .compare-row { border-top: 1px solid var(--border); }
.compare-row > span:first-child { color: var(--muted); }
.compare-head { padding-top: 22px; padding-bottom: 14px; font-size: 14px; }
.compare-head b:nth-child(2) { color: var(--green-hi); }
.compare-head b:nth-child(3) { color: var(--muted); font-weight: 500; }
.yes, .no { position: relative; padding-left: 24px; }
.yes::before, .no::before { position: absolute; left: 0; top: 0; font-weight: 600; }
.yes::before { content: "✓"; color: var(--green); }
.no { color: var(--muted); }
.no::before { content: "–"; color: var(--faint); }

/* ---------- Features ---------- */

.bento {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
  margin-top: 56px;
  text-align: left;
}
.tile { display: flex; flex-direction: column; }
.tile-6 { grid-column: span 6; flex-direction: row; align-items: center; }
.tile-4 { grid-column: span 4; }
.tile-2 { grid-column: span 2; }
.tile-copy { padding: 30px 30px 0; }
.tile-6 .tile-copy { flex: 0 0 34%; padding: 36px; }
.tile h3 { font-size: 22px; letter-spacing: -.02em; }
.tile p { margin: 10px 0 0; color: var(--muted); font-size: 15px; }
.tile p code, .lede code { color: var(--green-hi); }
.tile-shot {
  margin: 26px 0 0 30px;
  border-radius: 12px 0 0 0;
  border: 1px solid var(--border);
  border-right: 0;
  border-bottom: 0;
  box-shadow: 0 -20px 60px -30px rgba(61, 123, 255, .35);
}
.tile-6 .tile-shot { flex: 1; min-width: 0; margin: 36px 0 0; align-self: flex-end; }
.tile-shot-crop { height: 240px; width: auto; max-width: none; object-fit: cover; object-position: left top; margin-top: auto; }
.tile-2 .tile-copy { padding-bottom: 26px; }

.tile-list { padding: 12px; }
.more { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; }
.more li { padding: 18px 20px; display: flex; flex-direction: column; gap: 6px; border-radius: 12px; }
.more li:hover { background: var(--panel); }
.more code { color: var(--blue-hi); font-size: 13px; }
.more span { color: var(--muted); font-size: 14px; line-height: 1.5; }

/* ---------- Everywhere ---------- */

.chips {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  max-width: 860px;
  margin: 48px auto 0;
}
.chip {
  padding: 18px 22px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--panel);
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.chip b { font-weight: 600; font-size: 15px; }
.chip span { color: var(--muted); font-size: 13px; }

/* ---------- Install ---------- */

.install-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 16px;
  margin-top: 48px;
  text-align: left;
}
.install-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.downloads { padding: 8px 24px 20px; }
.dl-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.dl-row b { display: block; font-weight: 600; font-size: 16px; }
.dl-row b small { margin-left: 6px; font: 500 12px var(--mono); color: var(--green-hi); }
.dl-row div span { color: var(--muted); font-size: 13px; }
.dl-links { display: flex; gap: 8px; }
.dl-note { margin: 16px 0 0; color: var(--faint); font-size: 13px; line-height: 1.6; }
.dl-note code { font: 12px var(--mono); color: var(--muted); overflow-wrap: anywhere; }
.dl-more { margin: 0; font-size: 14px; }
.dl-more a { color: var(--muted); }
.dl-more a:hover { color: var(--text); }
.terminal { background: #0A0D16; }
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--faint);
  font: 12px var(--mono);
}
.terminal-bar i { width: 11px; height: 11px; border-radius: 50%; background: #2A3142; }
.terminal-bar span { margin-left: 8px; }
.copy {
  margin-left: auto;
  border: 1px solid var(--border-hi);
  background: none;
  color: var(--muted);
  font: 12px var(--sans);
  padding: 4px 10px;
  border-radius: 7px;
  cursor: pointer;
}
.copy:hover { color: var(--text); }
.terminal pre { margin: 0; padding: 20px 22px 24px; overflow-x: auto; font: 14px/1.9 var(--mono); }
.prompt { color: var(--green); user-select: none; }
.comment { color: var(--faint); }

.keys { padding: 26px 28px; }
.keys h3 { font-size: 17px; letter-spacing: -.01em; }
.keys dl { margin: 16px 0 0; }
.keys dl div { display: grid; grid-template-columns: 120px 1fr; align-items: center; padding: 7px 0; }
.keys dt { display: flex; gap: 4px; }
.keys dd { margin: 0; color: var(--muted); font-size: 14px; }
kbd {
  min-width: 26px;
  padding: 2px 7px;
  border: 1px solid var(--border-hi);
  border-bottom-width: 2px;
  border-radius: 6px;
  background: var(--panel-hi);
  font: 12px var(--sans);
  text-align: center;
}
.keys-note { margin: 14px 0 0; color: var(--faint); font-size: 13px; }

/* ---------- Footer ---------- */

.footer { margin-top: 140px; border-top: 1px solid var(--border); }
.footer-inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 28px 24px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  color: var(--muted);
  font-size: 14px;
}
.footer-line { display: flex; align-items: center; gap: 10px; margin: 0; }
.footer a:hover { color: var(--text); }
.footer-line a { color: var(--text); }
.footer-link { font-family: var(--mono); font-size: 13px; }

/* ---------- Motion ---------- */

.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s cubic-bezier(.2, .8, .2, 1), transform .8s cubic-bezier(.2, .8, .2, 1); }
.reveal.in { opacity: 1; transform: none; }
.hero > * { animation: rise .9s cubic-bezier(.2, .8, .2, 1) both; }
.hero > :nth-child(2) { animation-delay: .06s; }
.hero > :nth-child(3) { animation-delay: .14s; }
.hero > :nth-child(4) { animation-delay: .22s; }
.hero > :nth-child(5) { animation-delay: .28s; }
.hero > :nth-child(6) { animation-delay: .36s; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  .fill { width: var(--w); }
}

/* ---------- Why: the three steps ---------- */

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  max-width: 980px;
  margin: 56px auto 0;
  padding: 0;
  list-style: none;
  text-align: left;
}
.steps li { padding: 28px 28px 30px; }
.step-tag { font: 500 13px var(--mono); color: var(--green-hi); }
.steps h3 { margin: 10px 0 8px; font-size: 22px; font-weight: 600; letter-spacing: -.02em; }
.steps p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.6; }

.compare-2 .compare-row { grid-template-columns: 1fr 1.6fr; }
.compare-2 .compare-head b:nth-child(2) { color: var(--green-hi); }

/* ---------- Narrow screens ---------- */

@media (max-width: 900px) {
  .nav-links { display: none; }
  .section { padding-top: 100px; }
  .bento { grid-template-columns: 1fr; }
  .tile-6, .tile-4, .tile-2 { grid-column: auto; }
  .tile-6 { flex-direction: column; align-items: stretch; }
  .tile-6 .tile-copy { padding: 30px 30px 0; }
  .tile-6 .tile-shot { margin: 26px 0 0 30px; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stats div:nth-child(3) { border-left: 0; }
  .stats div:nth-child(n + 3) { border-top: 1px solid var(--border); }
  .chips { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr; max-width: 560px; }
  .install-grid { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  main > section, .nav-inner, .footer-inner { padding-left: 16px; padding-right: 16px; }
  .nav-inner { gap: 12px; }
  .nav-end .btn-sm { font-size: 0; gap: 0; padding: 0 10px; }
  main > .hero { padding-top: 64px; }
  .hero-stage { margin-top: 48px; }
  .memory { padding: 22px 20px; }
  .bar-row { grid-template-columns: 1fr 70px; gap: 8px 12px; }
  .bar-label { grid-column: 1 / -1; }
  .bar { grid-row: 2; }
  .bar-value { font-size: 15px; grid-row: 2; grid-column: 2; }
  .compare-row { grid-template-columns: 1fr 1fr; gap: 6px 16px; padding: 16px 18px; }
  .compare-row > span:first-child { grid-column: 1 / -1; color: var(--text); font-weight: 500; }
  .compare-head > span:first-child { display: none; }
  .compare-2 .compare-row { grid-template-columns: 1fr; }
  .compare-2 .compare-head { display: none; }
  .more { grid-template-columns: 1fr; }
  .chips { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}
