/* Shared across every page. External rather than inline so the CSP can be a
   plain `style-src 'self'`: hashes would need one entry per page and would
   break silently whenever an edit changed a byte. No webfonts, no CDN. */

:root{
  --bg:#fbfaf8; --fg:#191c21; --muted:#5a626d; --accent:#2f6e7e;
  --line:#e4e5e2; --field:#fff; --ok:#2f6e4a; --bad:#a2432a;
}
@media (prefers-color-scheme:dark){
  :root{
    --bg:#141619; --fg:#e9eae7; --muted:#98a0a9; --accent:#74b6c5;
    --line:#2b2f35; --field:#1c1f24; --ok:#6fb58e; --bad:#d98a5f;
  }
}

*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{
  margin:0; min-height:100svh;
  display:flex; align-items:center; justify-content:center;
  background:var(--bg); color:var(--fg); padding:2rem 1.25rem;
  font:17px/1.7 ui-sans-serif,-apple-system,"Segoe UI",system-ui,sans-serif;
  -webkit-font-smoothing:antialiased;
}
/* Long pages sit at the top; vertical centring only suits a short page. */
body.doc{align-items:flex-start;padding-top:3.5rem}

main{max-width:34rem;text-align:center}
body.doc main{max-width:40rem;text-align:left}

.mark{display:block;margin:0 auto 1.5rem;width:132px;height:auto;color:var(--accent)}
body.doc .mark{margin-bottom:2rem}

h1{
  margin:0 0 1rem; font-size:2rem; font-weight:650;
  letter-spacing:-.02em; line-height:1.2; text-wrap:balance;
}
body.doc h1{font-size:1.7rem}
h2{margin:2rem 0 .5rem;font-size:1.05rem;font-weight:650;letter-spacing:-.01em}
p{margin:0;color:var(--muted);text-wrap:pretty}
body.doc p{margin:0 0 1rem}
ul{margin:0 0 1rem;padding-left:1.2rem;color:var(--muted)}
li{margin:.35rem 0}
a{color:var(--accent);text-underline-offset:2px}
:lang(zh){font-family:"PingFang SC","Hiragino Sans GB","Noto Sans SC","Microsoft YaHei",sans-serif}

/* Buttons and links that act as buttons share one look. */
.btn{
  display:inline-block; margin-top:1.75rem; padding:.7rem 1.4rem;
  font:inherit; font-weight:600; color:#fff; background:var(--accent);
  border:1px solid var(--accent); border-radius:8px; cursor:pointer;
  text-decoration:none; transition:opacity .12s;
}
.btn:hover{opacity:.88}
.btn:focus-visible{outline:2px solid var(--fg);outline-offset:2px}
.btn[disabled]{opacity:.55;cursor:default}

form{margin-top:1.75rem;display:flex;flex-direction:column;gap:.7rem;text-align:left}
label{font-size:.9rem;font-weight:600}
input[type=email]{
  width:100%; padding:.7rem .85rem; font:inherit;
  color:var(--fg); background:var(--field);
  border:1px solid var(--line); border-radius:8px;
}
input[type=email]:focus{outline:2px solid var(--accent);outline-offset:1px;border-color:var(--accent)}
form .btn{margin-top:.2rem;align-self:flex-start}

/* Bots fill hidden fields; people do not. Kept out of the accessibility tree
   and off-screen rather than display:none, which some bots detect. */
.trap{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}

.consent{display:flex;gap:.55rem;align-items:flex-start;font-size:.88rem;color:var(--muted)}
.consent input{margin-top:.35rem;flex:none}

.msg{margin-top:1rem;font-size:.95rem;min-height:1.5rem}
.msg.ok{color:var(--ok)}
.msg.bad{color:var(--bad)}

.fine{margin-top:2.5rem;font-size:.85rem;color:var(--muted)}
.fine a{color:var(--muted)}

@media (max-width:26rem){
  .mark{width:108px}
  h1{font-size:1.6rem}
  body{font-size:16px}
}
