/* Saturday Robotics — site styles */
:root {
  --bg: #FFFFFF;
  --surface: #F6F6F3;
  --surface-2: #EDEDE8;
  --ink: #0A0A0B;
  --ink-2: #2A2B2F;
  --muted: #5E626A;
  --line: #E4E4DE;
  --line-2: #CFCFC7;
  --accent: #1D57F0;
  --accent-soft: #E8EEFF;
  --radius: 18px;
  --radius-sm: 12px;
  --font: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial,
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", "Noto Sans CJK SC", sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --logo-filter: none;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0A0B0D;
    --surface: #121418;
    --surface-2: #1A1D23;
    --ink: #F2F3F5;
    --ink-2: #CDD1D8;
    --muted: #9AA0AB;
    --line: #23262D;
    --line-2: #343842;
    --accent: #7FA6FF;
    --accent-soft: #17203A;
    --logo-filter: invert(1);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.6 var(--font); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* Bilingual: only the active language is shown */
html[data-lang="en"] .l-zh,
html[data-lang="zh"] .l-en { display: none !important; }

a { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
p { margin: 0 0 1em; }
.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 32px); }
.nb { display: inline-block; }
.logo-img { filter: var(--logo-filter); }

.skip { position: absolute; left: -9999px; top: 10px; z-index: 100; background: var(--ink); color: var(--bg); padding: 8px 12px; border-radius: 8px; text-decoration: none; }
.skip:focus { left: 12px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(14px); backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .2s;
}
.site-header.scrolled { border-bottom-color: var(--line); }
.header-inner { display: flex; align-items: center; gap: 18px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 16.5px; letter-spacing: -.01em; white-space: nowrap; }
.brand img { width: 38px; height: 38px; }
.nav { display: flex; gap: 2px; margin-left: auto; }
.nav a { text-decoration: none; color: var(--muted); font-size: 14.5px; padding: 8px 11px; border-radius: 999px; transition: color .15s, background .15s; }
.nav a:hover { color: var(--ink); background: var(--surface-2); }
.header-actions { display: flex; align-items: center; gap: 8px; }
.lang-toggle {
  appearance: none; cursor: pointer; min-width: 54px; border: 1px solid var(--line-2); background: var(--bg); color: var(--ink);
  font: 600 13px/1 var(--font); padding: 9px 12px; border-radius: 999px;
}
.lang-toggle:hover { border-color: var(--ink-2); }
@media (max-width: 960px) { .nav { display: none; } .header-actions { margin-left: auto; } }
@media (max-width: 420px) { .brand span { display: none; } }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none;
  font-weight: 600; font-size: 15px; line-height: 1.2; padding: 13px 20px; border-radius: 999px;
  border: 1px solid transparent; transition: transform .15s, border-color .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--ink); color: var(--bg); }
.btn-ghost { border-color: var(--line-2); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink-2); }
.btn-small { padding: 9px 14px; font-size: 13.5px; }
.btn-light { background: var(--bg); color: var(--ink); }

/* Type */
section { padding: clamp(64px, 9vw, 112px) 0; }
h1, h2, h3 { margin: 0; color: var(--ink); font-weight: 700; }
h1 { font-size: clamp(2.3rem, 4.8vw, 3.6rem); line-height: 1.06; letter-spacing: -.035em; }
h2 { font-size: clamp(1.85rem, 3.4vw, 2.6rem); line-height: 1.12; letter-spacing: -.025em; }
h3 { font-size: 1.12rem; line-height: 1.3; letter-spacing: -.01em; }
html[lang="zh-CN"] h1, html[lang="zh-CN"] h2, html[lang="zh-CN"] h3 { letter-spacing: 0; }
html[lang="zh-CN"] h1 { line-height: 1.18; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; margin: 0 0 16px;
  font: 600 12px/1.3 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
}
html[lang="zh-CN"] .eyebrow { font-family: var(--font); letter-spacing: .04em; }
.eyebrow::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); flex: none; }
.lede { font-size: clamp(1.05rem, 1.6vw, 1.18rem); color: var(--ink-2); max-width: 38em; }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px 48px; align-items: end; margin-bottom: 40px; }
.section-head p { margin: 0; color: var(--muted); font-size: 1.04rem; }
.alt { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.note { color: var(--muted); font-size: .88rem; margin: 18px 0 0; }
@media (max-width: 880px) { .section-head { grid-template-columns: 1fr; } }

/* Hero */
.hero { padding-top: clamp(32px, 6vw, 72px); padding-bottom: clamp(40px, 6vw, 72px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.wordmark { width: min(420px, 82%); margin: 0 0 26px; }
.hero h1 { margin-bottom: 20px; }
.hero .lede { margin: 0 0 28px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.facts { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 26px 0 0; padding: 0; list-style: none; font: 500 13px/1.5 var(--mono); color: var(--muted); }
html[lang="zh-CN"] .facts { font-family: var(--font); }
.facts li::before { content: "— "; color: var(--line-2); }
.hero-logo { justify-self: center; width: min(440px, 100%); aspect-ratio: 1; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); display: grid; place-items: center; }
.hero-logo img { width: 86%; }
@media (max-width: 920px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-logo { order: -1; width: min(240px, 70%); }
  .wordmark { width: min(320px, 90%); }
}

/* Photos */
.photos { display: grid; grid-template-columns: 1.25fr 1fr 1fr; gap: 12px; }
.photos figure { margin: 0; }
.photos img { width: 100%; height: clamp(220px, 24vw, 320px); object-fit: cover; border-radius: var(--radius-sm); background: var(--surface-2); }
.photos figcaption { font-size: .86rem; color: var(--muted); margin-top: 8px; }
.photo-credit { font-size: .8rem; color: var(--muted); margin-top: 10px; }
@media (max-width: 760px) { .photos { grid-template-columns: 1fr; } .photos img { height: auto; aspect-ratio: 4 / 3; } }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.stat { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 20px; }
.stat b { display: block; font-size: clamp(1.6rem, 3vw, 2.15rem); line-height: 1.1; letter-spacing: -.02em; margin-bottom: 6px; }
.stat span { color: var(--muted); font-size: .92rem; line-height: 1.4; display: block; }
@media (max-width: 880px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* How it works */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.step { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.alt .step { background: var(--bg); }
.step .kicker { font: 600 12px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; display: block; }
html[lang="zh-CN"] .step .kicker { font-family: var(--font); letter-spacing: .04em; }
.step h3 { margin-bottom: 8px; }
.step p { margin: 0; color: var(--muted); }
.quote { margin: 40px 0 0; padding: 28px 0 0; border-top: 1px solid var(--line); max-width: 900px; }
.quote p { font-size: clamp(1.3rem, 2.6vw, 1.85rem); line-height: 1.3; letter-spacing: -.015em; font-weight: 600; margin: 0 0 12px; }
html[lang="zh-CN"] .quote p { letter-spacing: 0; }
.quote cite { font-style: normal; color: var(--muted); font-size: .95rem; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 28px 0 0; }
.chips li { font-size: 13.5px; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--ink-2); background: var(--bg); }
@media (max-width: 880px) { .steps { grid-template-columns: 1fr; } }

/* Research nights */
.nights { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.night { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; display: flex; flex-direction: column; gap: 10px; background: var(--bg); }
.night .when { font: 500 12.5px/1.5 var(--mono); color: var(--muted); }
html[lang="zh-CN"] .night .when { font-family: var(--font); }
.night h3 { font-size: 1.2rem; }
.night p { margin: 0; color: var(--muted); }
.night .big { font-weight: 700; color: var(--ink); }
.night .more { margin-top: auto; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: .9rem; }
.night .more a { font-weight: 600; text-decoration: none; border-bottom: 1px solid var(--line-2); }
.night .more a:hover { border-color: var(--ink); }
.badge { display: inline-block; font: 600 10.5px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--accent); background: var(--accent-soft); padding: 4px 7px; border-radius: 6px; vertical-align: 2px; margin-left: 6px; }
html[lang="zh-CN"] .badge { font-family: var(--font); }
@media (max-width: 960px) { .nights { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .nights { grid-template-columns: 1fr; } }

/* Session archive */
.archive { border-top: 1px solid var(--line); }
.month { padding: 22px 0 6px; font: 600 12px/1.2 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
html[lang="zh-CN"] .month { font-family: var(--font); letter-spacing: .04em; }
.sessions { list-style: none; margin: 0; padding: 0; }
.session { display: grid; grid-template-columns: 64px 110px minmax(0, 1fr); gap: 4px 16px; padding: 14px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.session .num { font: 600 13px/1.5 var(--mono); color: var(--accent); }
.session .date { font: 500 13px/1.5 var(--mono); color: var(--muted); }
html[lang="zh-CN"] .session .date { font-family: var(--font); }
.session .title { font-weight: 600; }
.session .title a { text-decoration: none; border-bottom: 1px solid var(--line-2); }
.session .title a:hover { border-color: var(--ink); }
.session .meta { grid-column: 3; color: var(--muted); font-size: .94rem; }
.earlier { margin-top: 8px; }
.earlier summary {
  cursor: pointer; list-style: none; display: inline-flex; align-items: center; gap: 8px; margin: 22px 0 4px;
  font-weight: 600; padding: 10px 16px; border: 1px solid var(--line-2); border-radius: 999px;
}
.earlier summary::-webkit-details-marker { display: none; }
.earlier summary::after { content: "+"; font-weight: 700; color: var(--muted); }
.earlier[open] summary::after { content: "–"; }
@media (max-width: 640px) {
  .session { grid-template-columns: 48px minmax(0, 1fr); }
  .session .date { grid-column: 2; }
  .session .title, .session .meta { grid-column: 2; }
}

/* Hosts */
.hosts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.host { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 18px 20px; background: var(--bg); }
.host b { display: block; font-size: 1.02rem; margin-bottom: 4px; }
.host > span { color: var(--muted); font-size: .92rem; display: block; }
@media (max-width: 880px) { .hosts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .hosts { grid-template-columns: 1fr; } }

/* Organizations */
.orgs { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 32px; }
.orgs h3 { font: 600 12px/1.2 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; }
html[lang="zh-CN"] .orgs h3 { font-family: var(--font); letter-spacing: .04em; }
.org-list { list-style: none; margin: 0; padding: 0; font-size: 1.02rem; line-height: 1.9; color: var(--ink-2); }
.org-list li { display: inline; }
.org-list li:not(:last-child)::after { content: " · "; color: var(--line-2); }
@media (max-width: 880px) { .orgs { grid-template-columns: 1fr; } }

/* Recognition */
.recog { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.recog li { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 4px 24px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.recog b { font-weight: 700; }
.recog span { color: var(--ink-2); }
@media (max-width: 720px) { .recog li { grid-template-columns: 1fr; } }

/* Pricing */
.pricing { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.price-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; background: var(--bg); display: flex; flex-direction: column; gap: 10px; }
.price-card.wide { grid-column: 1 / -1; }
.price-card h3 { font-size: 1.15rem; }
.price { font-size: 1.6rem; font-weight: 700; letter-spacing: -.02em; line-height: 1.15; }
.price small { font-size: .95rem; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.price-card p { margin: 0; color: var(--muted); }
.price-card ul { margin: 0; padding-left: 18px; color: var(--muted); }
.tiers { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin: 6px 0 4px; }
.tier { border: 1px solid var(--line); border-radius: 10px; padding: 12px; background: var(--surface); }
.tier span { display: block; font: 600 11.5px/1.2 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
html[lang="zh-CN"] .tier span { font-family: var(--font); }
.tier b { font-size: 1.15rem; }
.partner-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 28px; }
@media (max-width: 880px) { .pricing { grid-template-columns: 1fr; } .tiers { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Team */
.team { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.person { border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; background: var(--bg); }
.avatar { width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center; font: 700 22px/1 var(--font); color: #fff; margin-bottom: 16px; }
.avatar.jz { background: linear-gradient(135deg, #1D57F0, #0A0A0B); }
.avatar.af { background: linear-gradient(135deg, #7C5CFF, #0A0A0B); }
.person h3 { font-size: 1.3rem; }
.person .role { color: var(--accent); font-weight: 600; margin: 4px 0 12px; }
.person p { color: var(--ink-2); }
.links { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 4px 0 0; }
.links a { display: inline-block; text-decoration: none; font-size: 13px; font-weight: 600; padding: 7px 11px; border: 1px solid var(--line-2); border-radius: 999px; }
.links a:hover { border-color: var(--ink-2); }
@media (max-width: 760px) { .team { grid-template-columns: 1fr; } }

/* Join */
.join-box { background: var(--ink); color: var(--bg); border-radius: 28px; padding: clamp(32px, 6vw, 64px); }
.join-box h2 { color: var(--bg); }
.join-box .eyebrow { color: var(--bg); opacity: .7; }
.join-box p { color: var(--bg); opacity: .78; font-size: 1.06rem; max-width: 40em; }
.channels { display: flex; flex-wrap: wrap; gap: 10px; margin: 24px 0 8px; }
.channels a { text-decoration: none; font-weight: 600; font-size: 14.5px; padding: 11px 16px; border-radius: 999px; border: 1px solid rgba(255,255,255,.28); color: var(--bg); }
@media (prefers-color-scheme: dark) { .channels a { border-color: rgba(0,0,0,.25); } }
.channels a.primary { background: var(--bg); color: var(--ink); border-color: transparent; }
.join-quote { margin-top: 26px; font-size: 1.15rem; font-weight: 600; opacity: .95 !important; }

/* Footer */
.site-footer { padding: 8px 0 56px; color: var(--muted); font-size: .9rem; }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; border-top: 1px solid var(--line); padding-top: 28px; }
.footer-inner p { margin: 0 0 4px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 18px; }
.footer-links a { text-decoration: none; }
.footer-links a:hover { color: var(--ink); }

/* Simple pages */
.page { padding: clamp(48px, 8vw, 96px) 0; }
.page .prose { max-width: 680px; }
.page .prose h1 { font-size: clamp(2.1rem, 4.5vw, 3rem); margin-bottom: 12px; }
.page .prose h2 { font-size: 1.25rem; letter-spacing: -.01em; margin: 32px 0 8px; }
.page .prose p { color: var(--ink-2); }
.page .updated { color: var(--muted); font: 500 13px/1.6 var(--mono); margin-bottom: 28px; }
