/* guides: ordered source sections, combined by the asset build. */
/* Shared by the public guide library and articles. Keep study-app styles separate. */
:root {
  color-scheme: light;
  --paper: #fff;
  --ink: #3d4651;
  --ink-2: #657080;
  --ink-3: #657080;
  --guide-brand: #d52b3a;
  --guide-blue: #a60023;
  --guide-blue-lip: #ad1d2e;
  --guide-line: #e3e8ed;
  --guide-soft: #eff9ff;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 110px;
}
body {
  background: #fff;
  color: var(--ink);
}
.wrap {
  max-width: none;
  padding: 0;
}
.guide-site {
  font-family: Nunito, system-ui, sans-serif;
}
.guide-site h1,
.guide-site h2,
.guide-site h3 {
  color: var(--ink);
  font-weight: 900;
  letter-spacing: -0.025em;
}
.guide-site a {
  text-underline-offset: 4px;
}
.guide-site :where(a, summary):focus-visible {
  outline: 3px solid #c77300;
  outline-offset: 5px;
}
.guide-container,
.guide-header-inner {
  width: min(1060px, calc(100% - 64px));
  margin-inline: auto;
}
.guide-skip {
  position: fixed;
  z-index: 30;
  top: 10px;
  left: 16px;
  padding: 12px 20px;
  border: 2px solid var(--guide-blue);
  border-radius: 12px;
  background: #fff;
  transform: translateY(-160%);
}
.guide-skip:focus {
  transform: none;
}
.guide-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 2px solid var(--guide-line);
  background: #fff;
}
.guide-header-inner {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.guide-wordmark {
  color: #d52b3a;
  font:
    700 34px/1 Fredoka,
    Nunito,
    sans-serif;
  text-decoration: none;
  letter-spacing: -0.7px;
}
.guide-header nav {
  display: flex;
  align-items: center;
  gap: 30px;
}
.guide-nav-current {
  font-size: 16px;
  font-weight: 900;
  color: var(--guide-blue);
  text-decoration: none;
}
.guide-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 12px 23px;
  margin-bottom: 5px;
  border: 0;
  border-radius: 14px;
  background: var(--guide-brand);
  color: #fff;
  box-shadow: 0 5px 0 var(--guide-blue-lip);
  font-size: 17px;
  font-weight: 900;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  transition:
    transform 0.12s ease-out,
    box-shadow 0.12s ease-out;
}
@media (hover: hover) and (pointer: fine) {
  .guide-button:hover {
    transform: translateY(5px);
    box-shadow: none;
  }
}
.guide-button:focus-visible {
  transform: translateY(5px);
  box-shadow: none;
}
.guide-button:active {
  transform: translateY(5px);
  box-shadow: none;
}
.guide-hero {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  align-items: center;
  gap: 46px;
  padding: 52px 20px 42px;
}
.guide-hero h1 {
  margin: 0 0 22px;
  font-size: clamp(38px, 4.8vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}
.guide-hero p {
  max-width: 43ch;
  margin-bottom: 22px;
  font-size: 20px;
  line-height: 1.65;
}
.guide-hero-moose {
  width: 100%;
  max-width: 340px;
  height: auto;
  justify-self: center;
}
.guide-free-note {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #587146;
  font-weight: 800;
  font-size: 15px;
}
.guide-free-note svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}
.guide-library {
  padding-top: 25px;
  border-top: 2px solid var(--guide-line);
}
.guide-library + .guide-library {
  margin-top: 44px;
}
.guide-about {
  max-width: 72ch;
  margin: 56px auto 0;
  padding: 26px;
  border: 2px solid var(--guide-line);
  border-radius: 22px;
}
.guide-about h2 {
  margin: 0 0 10px;
  font-size: 22px;
}
.guide-about p {
  margin: 0;
  font-size: 16px;
  line-height: 1.7;
}
.guide-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}
.guide-section-heading h2 {
  margin: 0;
  font-size: 25px;
  line-height: 1.25;
}
.guide-section-heading > span {
  color: var(--ink-2);
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
}
.guide-section-heading > a {
  color: var(--guide-blue);
  font-weight: 900;
  white-space: nowrap;
}
.guide-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  padding: 0;
  margin: 0;
  list-style: none;
}
.guide-grid > li {
  display: flex;
  min-width: 0;
  margin: 0;
}
.guide-card,
.guide-practice-card {
  width: 100%;
  padding: 25px;
  border: 2px solid var(--guide-line);
  border-radius: 22px;
  box-shadow: 0 4px 0 var(--guide-line);
}
.guide-card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  transition:
    border-color 0.12s,
    box-shadow 0.12s,
    transform 0.12s;
}
.guide-card:hover {
  border-color: #efa6ae;
  box-shadow: 0 4px 0 #efa6ae;
}
.guide-card:active {
  transform: translateY(4px);
  box-shadow: none;
}
.guide-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}
.guide-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  flex-shrink: 0;
  border-radius: 18px;
  box-shadow: inset 0 -4px 0 #0000000d;
}
.guide-icon svg {
  width: 32px;
  height: 32px;
}
.guide-icon--blue {
  background: #ddf3ff;
  color: #a31829;
}
.guide-icon--purple {
  background: #f0e6ff;
  color: #9356c6;
}
.guide-icon--green {
  background: #e8f5cf;
  color: #668e24;
}
.guide-icon--pink {
  background: #ffe5ed;
  color: #d9567a;
}
.guide-icon--gold {
  background: #fff2c7;
  color: #a77706;
}
.guide-reading-time {
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 800;
}
.guide-card h3,
.guide-practice-card h3 {
  margin: 0 0 12px;
  font-size: 22px;
  line-height: 1.25;
}
.guide-card p,
.guide-practice-card p {
  font-size: 16px;
  line-height: 1.6;
  margin-bottom: 24px;
}
.guide-card-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: var(--guide-blue);
  font-size: 16px;
  font-weight: 900;
  margin-top: auto;
}
.guide-card-action svg {
  width: 23px;
  height: 23px;
}
.guide-practice-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  background: var(--guide-soft);
  border-color: #d3ebfa;
  box-shadow: 0 4px 0 #d3ebfa;
}
.guide-practice-card > .guide-icon {
  margin-bottom: 22px;
  background: #fff;
}
.guide-practice-card .guide-button {
  width: 100%;
  margin-top: auto;
}
.guide-independent {
  max-width: 72ch;
  margin: 40px auto 30px;
  font-size: 13px;
  line-height: 1.7;
  text-align: center;
}
.site-footer {
  border-top: 2px solid var(--guide-line);
  padding: 26px 24px 34px;
  gap: 16px 28px;
  color: var(--ink-2);
}
.site-footer a {
  text-decoration: none;
  text-underline-offset: 4px;
}
.site-footer a:hover {
  text-decoration: underline;
}
/* The reading view keeps the article open and quiet, with navigation beside it. */
.guide-breadcrumb {
  margin: 36px 0 30px;
}
.guide-breadcrumb a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 32px;
  font-weight: 900;
  font-size: 16px;
  color: var(--guide-blue);
  text-decoration: none;
}
.guide-breadcrumb svg {
  width: 21px;
  height: 21px;
  transform: rotate(180deg);
}
.guide-article-header {
  max-width: 890px;
  padding-bottom: 35px;
}
.guide-article-header > .guide-icon {
  margin-bottom: 24px;
}
.guide-article-header h1 {
  font-size: clamp(32px, 4vw, 47px);
  line-height: 1.15;
  margin: 0 0 22px;
  text-wrap: balance;
}
.guide-description {
  max-width: 66ch;
  font-size: 20px;
  line-height: 1.65;
  margin-bottom: 22px;
}
.guide-byline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 700;
}
.guide-byline > span:first-child {
  color: var(--guide-blue);
  font-weight: 900;
}
.guide-reading-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 270px;
  align-items: start;
  gap: 64px;
  border-top: 2px solid var(--guide-line);
  padding-top: 36px;
}
.guide-sidebar {
  grid-column: 2;
  grid-row: 1;
  position: sticky;
  top: 116px;
}
.guide-contents {
  padding: 22px;
  border: 2px solid var(--guide-line);
  border-radius: 18px;
}
.guide-contents summary {
  cursor: pointer;
  font-size: 18px;
  font-weight: 900;
  color: var(--ink);
}
.guide-contents ol {
  padding-left: 21px;
  margin: 18px 0 0;
}
.guide-contents li {
  padding-left: 4px;
  margin-bottom: 14px;
  font-size: 14px;
  font-weight: 700;
  color: var(--ink-2);
}
.guide-contents li:last-child {
  margin-bottom: 0;
}
.guide-contents a {
  color: var(--ink-2);
  text-decoration: none;
}
.guide-contents a:hover {
  color: var(--guide-blue);
  text-decoration: underline;
}
.guide-sidebar-practice {
  padding: 24px 4px;
}
.guide-sidebar-practice h2 {
  margin: 0 0 10px;
  font-size: 22px;
  line-height: 1.3;
}
.guide-sidebar-practice p {
  font-size: 15px;
  line-height: 1.6;
}
.guide-sidebar-practice .guide-button {
  width: 100%;
  font-size: 16px;
}
.guide-article-body {
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
}
.guide-article-section {
  margin-bottom: 36px;
}
.guide-article-section h2 {
  margin: 0 0 16px;
  font-size: 27px;
  line-height: 1.25;
}
.guide-article-section p {
  margin: 0;
  font-size: 18px;
  line-height: 1.85;
}
.guide-article-section > :is(p, ul, ol, div) + :is(p, ul, ol, div) {
  margin-top: 18px;
}
.guide-article-body a {
  color: var(--guide-blue);
  font-weight: 800;
}
.guide-note {
  padding: 18px 22px;
  border: 2px solid #d3ebfa;
  border-radius: 18px;
  background: var(--guide-soft);
  color: var(--ink);
  font-weight: 700;
}
.guide-article-section :is(ul, ol) {
  margin-bottom: 0;
  padding-left: 26px;
  font-size: 18px;
  line-height: 1.75;
}
.guide-article-section li + li {
  margin-top: 8px;
}
.guide-article-section li::marker {
  color: var(--guide-blue);
  font-weight: 900;
}
.guide-table {
  max-width: 100%;
  overflow-x: auto;
  border: 2px solid var(--guide-line);
  border-radius: 18px;
}
.guide-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 16px;
  line-height: 1.55;
}
.guide-table caption {
  padding: 16px 18px 4px;
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 800;
  text-align: left;
}
.guide-table :is(th, td) {
  padding: 12px 18px;
  border-top: 2px solid var(--guide-line);
  text-align: left;
  vertical-align: top;
}
.guide-table thead th {
  border-top: 0;
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 900;
}
.guide-table tbody th {
  font-weight: 800;
  color: var(--ink);
}
.guide-faq h3 {
  margin: 26px 0 8px;
  font-size: 20px;
  line-height: 1.35;
}
.guide-faq h2 + h3 {
  margin-top: 0;
}
.guide-faq h3 + p {
  margin-top: 0;
}
.guide-sources {
  background: #f7fafc;
  border: 2px solid var(--guide-line);
  padding: 24px;
  border-radius: 18px;
}
.guide-sources h2 {
  margin: 0 0 10px;
  font-size: 23px;
}
.guide-sources p,
.guide-sources li {
  font-size: 15px;
  line-height: 1.7;
}
.guide-sources ul {
  margin: 0;
  padding-left: 20px;
}
.guide-sources li:last-child {
  margin-bottom: 0;
}
.guide-sources a {
  color: var(--guide-blue);
  font-weight: 800;
  overflow-wrap: anywhere;
}
.guide-finish {
  margin-top: 32px;
  padding: 30px;
  border: 2px solid #d3ebfa;
  border-radius: 22px;
  background: var(--guide-soft);
  text-align: center;
}
.guide-finish h2 {
  font-size: 25px;
  line-height: 1.3;
  margin: 0 0 12px;
}
.guide-finish p {
  margin-bottom: 22px;
  font-size: 16px;
}
.guide-related {
  margin-top: 60px;
  padding-top: 34px;
  border-top: 2px solid var(--guide-line);
}
@media (max-width: 950px) {
  .guide-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .guide-hero {
    gap: 25px;
    padding-inline: 0;
  }
  .guide-reading-layout {
    grid-template-columns: minmax(0, 1fr) 240px;
    gap: 32px;
  }
  .guide-header nav {
    gap: 20px;
  }
}
@media (max-width: 720px) {
  .guide-container,
  .guide-header-inner {
    width: calc(100% - 40px);
  }
  .guide-header-inner {
    min-height: 78px;
    gap: 16px;
  }
  .guide-wordmark {
    font-size: 28px;
  }
  .guide-nav-current {
    display: none;
  }
  .guide-header .guide-button {
    font-size: 14px;
    min-height: 42px;
    padding: 10px 14px;
    border-radius: 12px;
  }
  .guide-hero {
    grid-template-columns: 1fr 180px;
    padding: 34px 0;
    gap: 12px;
  }
  .guide-hero h1 {
    font-size: 37px;
  }
  .guide-hero p {
    font-size: 17px;
  }
  .guide-section-heading h2 {
    font-size: 22px;
  }
  .guide-card,
  .guide-practice-card {
    padding: 22px;
  }
  .guide-reading-layout {
    display: flex;
    flex-direction: column;
    gap: 30px;
    padding-top: 26px;
  }
  .guide-sidebar {
    position: static;
    width: 100%;
  }
  .guide-sidebar-practice {
    display: none;
  }
  .guide-article-body {
    width: 100%;
  }
  .guide-description {
    font-size: 18px;
  }
  .guide-breadcrumb {
    margin: 24px 0;
  }
  .guide-related {
    margin-top: 36px;
  }
}
@media (max-width: 520px) {
  .guide-header-inner {
    gap: 10px;
  }
  .guide-wordmark {
    font-size: 25px;
  }
  .guide-hero {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 8px;
    padding: 24px 0 30px;
  }
  .guide-hero-moose {
    grid-row: 1;
    width: 175px;
  }
  .guide-hero h1 {
    font-size: 37px;
    margin-bottom: 16px;
  }
  .guide-hero p {
    margin-bottom: 18px;
  }
  .guide-free-note {
    font-size: 14px;
  }
  .guide-section-heading {
    align-items: flex-start;
    gap: 12px;
  }
  .guide-section-heading h2 {
    font-size: 21px;
  }
  .guide-section-heading > span {
    font-size: 12px;
    padding-top: 4px;
  }
  .guide-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .guide-card-top {
    margin-bottom: 18px;
  }
  .guide-card h3 {
    font-size: 23px;
  }
  .guide-article-header h1 {
    font-size: 33px;
  }
  .guide-article-header > .guide-icon {
    width: 54px;
    height: 54px;
    margin-bottom: 18px;
  }
  .guide-article-section h2 {
    font-size: 25px;
  }
  .guide-article-section p,
  .guide-article-section :is(ul, ol) {
    font-size: 17px;
    line-height: 1.8;
  }
  .guide-table table {
    font-size: 15px;
  }
  .guide-table :is(th, td) {
    padding: 10px 14px;
    overflow-wrap: anywhere;
  }
  .guide-about {
    padding: 22px;
  }
  .guide-finish,
  .guide-sources {
    padding: 22px;
  }
  .guide-finish .guide-button {
    width: 100%;
  }
}
/* Checklists and tables are often printed or saved as PDF: keep the article, drop the chrome. */
@media print {
  .guide-header,
  .guide-skip,
  .guide-breadcrumb,
  .guide-sidebar,
  .guide-finish,
  .guide-related,
  .guide-button,
  .site-footer,
  .privacy-choices {
    display: none !important;
  }
  .guide-reading-layout {
    display: block;
    border: 0;
    padding: 0;
  }
  .guide-container {
    width: auto;
  }
  .guide-article-section,
  .guide-table,
  .guide-note {
    break-inside: avoid;
  }
  .guide-table {
    overflow: visible;
  }
  .guide-article-body a {
    color: inherit;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .guide-card,
  .guide-button {
    transition: none;
  }
  .guide-button:is(:hover, :focus-visible, :active) {
    transform: none;
  }
}
/* Chinese guide pages (zh-guide.js): Hong Kong typefaces for the characters,
   which Nunito lacks, and headings without the tight tracking set for Latin. */
.guide-site:lang(zh-HK) {
  font-family: Nunito, "PingFang HK", "Noto Sans HK", "Microsoft JhengHei", system-ui, sans-serif;
}
.guide-site:lang(zh-HK) :is(h1, h2, h3) {
  letter-spacing: 0;
}
