/* ClearCraft reading pages. Scope is intentionally limited to preview-article. */
body.preview-article {
  margin: 0;
  max-width: none;
  padding: 0;
  color: #102c3b;
  background: #fff;
  font-family: var(--font-body, 'Avenir Next', 'PingFang TC', 'Microsoft JhengHei', sans-serif);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
  text-align: left;
}
body.preview-article *,
body.preview-article *::before,
body.preview-article *::after { box-sizing: border-box; }
body.preview-article > header {
  width: calc(100% - 64px);
  max-width: 72rem;
  min-height: 104px;
  margin: 0 auto;
  padding: 22px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid #dce7e9;
  background: #fff;
}
body.preview-article header nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
  font-size: 14px;
  line-height: 1.5;
  font-weight: 500;
}
body.preview-article header nav a {
  color: #526671;
  text-decoration: none;
  text-underline-offset: 6px;
  white-space: nowrap;
}
body.preview-article header nav a:hover {
  color: #096c58;
  text-decoration: underline;
}
body.preview-article header nav a:last-child {
  padding: 10px 16px;
  border: 1px solid #102c3b;
  border-radius: 7px;
  background: #102c3b;
  color: #fff;
}
body.preview-article header nav a:last-child:hover { background: #194253; }
body.preview-article > main {
  width: 100%;
  max-width: 72rem;
  margin: 0 auto;
  padding: 64px 32px 96px;
}
body.preview-article article {
  max-width: 48rem;
  margin: 0 auto;
  min-width: 0;
}
body.preview-article article > p:first-child {
  margin: 0 0 24px;
  color: #526671;
  font-size: 14px;
  line-height: 1.6;
}
body.preview-article h1,
body.preview-article h2,
body.preview-article h3,
body.preview-article h4 {
  color: #102c3b;
  font-family: var(--font-display, 'Avenir Next', 'PingFang TC', sans-serif);
  text-align: left;
  text-wrap: pretty;
}
body.preview-article h1 {
  margin: 0 0 28px;
  max-width: 100%;
  font-size: clamp(32px, 3.2vw, 46px);
  font-weight: 600;
  line-height: 1.34;
  letter-spacing: -.035em;
  overflow-wrap: break-word;
}
body.preview-article:lang(en) h1 {
  max-width: 25ch;
  font-size: clamp(32px, 3.4vw, 48px);
  line-height: 1.18;
  letter-spacing: -.035em;
}
body.preview-article h1 + p {
  margin: 0 0 20px;
  color: #405b68;
  font-size: 19px;
  line-height: 1.85;
}
body.preview-article article > p[style] {
  margin: 0 0 36px;
  padding-bottom: 28px;
  border-bottom: 1px solid #dce7e9;
  color: #637782 !important;
  font-size: 13px !important;
  line-height: 1.7;
}
body.preview-article h2 {
  margin: 52px 0 18px;
  font-size: clamp(23px, 2vw, 28px);
  font-weight: 600;
  line-height: 1.45;
  letter-spacing: -.022em;
}
body.preview-article h3,
body.preview-article h4 {
  margin: 32px 0 14px;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.55;
  letter-spacing: -.01em;
}
body.preview-article p {
  max-width: none;
  margin: 0 0 22px;
  color: #405b68;
  line-height: 1.85;
}
body.preview-article article strong { color: #102c3b; font-weight: 600; }
body.preview-article article a:not(.cta),
body.preview-article > p a {
  color: #096c58;
  text-decoration: underline;
  text-decoration-color: #9ecabf;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  overflow-wrap: anywhere;
}
body.preview-article article a:not(.cta):hover,
body.preview-article > p a:hover { text-decoration-color: #096c58; }
body.preview-article ul,
body.preview-article ol {
  padding-left: 1.5em;
  margin: 20px 0 30px;
  color: #405b68;
}
body.preview-article ul { list-style: disc; }
body.preview-article ol { list-style: decimal; }
body.preview-article li {
  max-width: none;
  margin: 0;
  padding: 0 0 12px 7px;
  line-height: 1.85;
}
body.preview-article li::marker { color: #096c58; font-weight: 500; }
body.preview-article li:last-child { padding-bottom: 0; }
body.preview-article table {
  width: 100%;
  display: block;
  overflow-x: auto;
  border-collapse: collapse;
  margin: 28px 0 36px;
  color: #405b68;
  font-size: 15px;
  line-height: 1.7;
}
body.preview-article td,
body.preview-article th {
  border: 1px solid #dce7e9;
  padding: 14px 16px;
  min-width: 9rem;
  text-align: left;
  vertical-align: top;
}
body.preview-article th { color: #102c3b; background: #f3f7f8; font-weight: 600; }
body.preview-article .notice {
  margin: 36px 0;
  border: 0;
  border-left: 3px solid #25d7a3;
  border-radius: 0;
  padding: 18px 22px;
  color: #526671;
  background: #f3f7f8;
  font-size: 14px;
  line-height: 1.8;
}
body.preview-article .cta {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  margin: 8px 0 4px;
  padding: 12px 22px;
  border: 1px solid #102c3b;
  border-radius: 7px;
  background: #102c3b;
  color: #fff;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.5;
  text-decoration: none;
  box-shadow: none;
}
body.preview-article .cta:hover { background: #194253; }
body.preview-article article #faq {
  max-width: none;
  padding: 0;
  margin: 52px 0 36px;
}
body.preview-article article #faq h2 { margin-top: 0; }
body.preview-article details {
  margin: 0;
  padding: 21px 0;
  border: 0;
  border-bottom: 1px solid #dce7e9;
  color: #102c3b;
}
body.preview-article summary {
  padding-right: 16px;
  font-size: 17px;
  font-weight: 500;
  line-height: 1.6;
  cursor: pointer;
}
body.preview-article summary::marker { color: #096c58; }
body.preview-article details p { margin: 16px 0 0; font-size: 16px; color: #526671; }
body.preview-article blockquote {
  margin: 32px 0;
  border-left: 3px solid #25d7a3;
  padding: 4px 0 4px 24px;
  color: #405b68;
}
body.preview-article code,
body.preview-article pre { font-size: .9em; }
body.preview-article pre {
  max-width: 100%;
  overflow-x: auto;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
  padding: 20px;
  border-radius: 7px;
  background: #f3f7f8;
}
body.preview-article > footer {
  width: calc(100% - 64px);
  max-width: 72rem;
  margin: 0 auto;
  padding: 32px 0 40px;
  border-top: 1px solid #dce7e9;
  color: #526671;
  font-size: 13px;
  line-height: 1.7;
}
body.preview-article footer p { margin: 12px 0 0; font-size: 13px; }
body.preview-article footer a { color: #096c58; text-underline-offset: 4px; }
body.preview-article :focus-visible { outline: 3px solid #096c58; outline-offset: 4px; }
body.preview-article ::selection { background: #c6fae9; color: #102c3b; }
/* The real 404 has direct body children instead of article markup. */
body.preview-article > h1,
body.preview-article > p {
  max-width: 42rem;
  margin-left: auto;
  margin-right: auto;
  padding-left: 32px;
  padding-right: 32px;
}
body.preview-article > p:first-child { margin-top: 96px; }
body.preview-article > h1 { margin-top: 20px; }
@media (max-width: 760px) {
  body.preview-article { font-size: 16px; line-height: 1.85; }
  body.preview-article > header {
    width: calc(100% - 40px);
    min-height: auto;
    padding: 22px 0 18px;
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }
  body.preview-article header nav { width: 100%; gap: 12px 19px; font-size: 13px; }
  body.preview-article header nav a:last-child { margin-left: auto; padding: 8px 12px; }
  body.preview-article > main { padding: 40px 20px 64px; }
  body.preview-article h1 { font-size: 32px; line-height: 1.4; letter-spacing: -.03em; margin-bottom: 24px; }
  body.preview-article:lang(en) h1 { font-size: 34px; line-height: 1.22; }
  body.preview-article h1 + p { font-size: 18px; line-height: 1.85; }
  body.preview-article article > p:first-child { margin-bottom: 22px; font-size: 13px; }
  body.preview-article article > p[style] { margin-bottom: 28px; padding-bottom: 24px; font-size: 12px !important; }
  body.preview-article h2 { margin-top: 40px; font-size: 23px; }
  body.preview-article h3,
  body.preview-article h4 { font-size: 19px; }
  body.preview-article p { margin-bottom: 20px; }
  body.preview-article .notice { margin: 28px 0; padding: 16px 18px; font-size: 13px; }
  body.preview-article article #faq { margin-top: 40px; }
  body.preview-article details { padding: 18px 0; }
  body.preview-article summary { font-size: 16px; }
  body.preview-article details p { font-size: 15px; }
  body.preview-article > footer { width: calc(100% - 40px); padding: 28px 0 32px; }
  body.preview-article > h1,
  body.preview-article > p { padding-left: 20px; padding-right: 20px; }
  body.preview-article > p:first-child { margin-top: 64px; }
}
@media (max-width: 380px) {
  body.preview-article header nav { gap: 10px 14px; font-size: 12px; }
  body.preview-article h1 { font-size: 30px; }
  body.preview-article:lang(en) h1 { font-size: 32px; }
}
@media (prefers-reduced-motion: reduce) {
  body.preview-article * { scroll-behavior: auto !important; transition: none !important; }
}
