/* Blog article. Tokens from layout.css. Layout matches site chapters, not a sidebar post. */

body {
  --copy: #eef4f8;
}

body.grid-bg {
  background:
    radial-gradient(ellipse 70% 52% at 50% 36%, rgba(0, 170, 210, 0.22) 0%, transparent 48%),
    radial-gradient(ellipse 90% 46% at 50% 100%, rgba(4, 14, 24, 0.88) 0%, transparent 58%),
    #050c14;
}

body.grid-bg::before {
  content: "";
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse at 50% 38%, transparent 44%, rgba(4, 10, 18, 0.58) 100%),
    linear-gradient(180deg, rgba(0, 216, 240, 0.05) 0%, transparent 18%, transparent 78%, rgba(4, 14, 24, 0.45) 100%);
}

main,
.footer { position: relative; z-index: 1; }

#readingProgress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0;
  z-index: 120;
  background: var(--lime);
  box-shadow: 0 0 12px rgba(0, 216, 240, 0.55);
  pointer-events: none;
}

.page-wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 var(--pad);
}

.article-page {
  padding-top: calc(var(--nav-h) + 40px);
  padding-bottom: 56px;
}

.article-intro {
  max-width: 640px;
  margin: 0 auto 36px;
  text-align: center;
}

.article-intro .label {
  font-size: 13px;
  color: var(--copy);
}

.crumbs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--copy);
}

.crumbs a { color: var(--lime); }

.crumbs a:hover { color: #5eefff; }

.article-intro h1 {
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.15;
  margin: 10px 0 12px;
}

.article-intro h1 .a { color: var(--lime); }

.article-intro p {
  font-size: 16px;
  line-height: 1.75;
  color: var(--copy);
}

.article-intro code,
.craft-lead code,
.article-copy code,
.split-col code,
.steps code,
.line-desc code,
.note code,
.article-intro kbd,
.craft-lead kbd,
.article-copy kbd,
.split-col kbd,
.steps kbd,
.line-desc kbd,
.note kbd {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 12px;
  color: #f5f5f5;
}

.article-intro kbd,
.craft-lead kbd,
.article-copy kbd,
.split-col kbd,
.steps kbd,
.line-desc kbd,
.note kbd {
  display: inline-block;
  padding: 0 6px;
  border: 1px solid var(--line);
}

.trust {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 22px;
  margin-top: 18px;
}

.trust span {
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--copy);
}

.trust span::before {
  content: "◆";
  color: var(--lime);
  margin-right: 8px;
  font-size: 8px;
}

.article-meta {
  margin-top: 16px;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.06em;
}

.chapter {
  padding: 28px 24px 12px;
  margin: 0 0 24px;
  border: 1px solid rgba(0, 216, 240, 0.28);
  background: rgba(5, 12, 20, 0.62);
  box-shadow: 0 0 64px rgba(0, 216, 240, 0.08);
}

.chapter h2[id] {
  scroll-margin-top: calc(var(--nav-h) + 20px);
}

.sec-head {
  display: grid;
  grid-template-columns: minmax(220px, 0.95fr) minmax(200px, 1.05fr);
  gap: 20px 48px;
  align-items: end;
  margin-bottom: 24px;
}

.sec-head h2 {
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(28px, 3.6vw, 44px);
  font-weight: 800;
  letter-spacing: -0.04em;
}

.sec-head h2 em {
  font-style: normal;
  color: var(--lime);
}

.craft-lead {
  color: var(--copy);
  font-size: 15px;
  line-height: 1.7;
  max-width: 520px;
}

.article-copy {
  max-width: 72ch;
}

.article-copy p,
.article-copy li,
.split-col p,
.note p {
  font-size: 15px;
  line-height: 1.85;
  color: var(--copy);
}

.article-copy p + p { margin-top: 14px; }

.article-copy h3 {
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 22px 0 10px;
}

.article-page a:not(.btn) {
  color: var(--lime);
  text-decoration: none;
  transition: color 0.25s, text-shadow 0.25s;
}

.article-page a:not(.btn):hover {
  color: #5eefff;
  text-shadow: 0 0 16px rgba(0, 216, 240, 0.4);
}

.article-page .btn-solid,
.article-page .btn-solid:hover {
  color: #041018;
  text-decoration: none;
  text-shadow: none;
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0;
  margin: 0 -24px;
  border-top: 1px solid var(--line);
}

.split-col {
  padding: 24px 24px 28px;
}

.split-col + .split-col {
  border-left: 1px solid var(--line);
}

.split-col .label {
  margin-bottom: 14px;
  color: var(--copy);
}

.split-col strong {
  display: block;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--white);
  margin-bottom: 8px;
}

.split-col p + p { margin-top: 10px; }

.article-copy {
  padding-bottom: 16px;
}

.article-copy.is-follow {
  padding-top: 20px;
}

.note {
  margin: 0 -24px;
  padding: 18px 24px 22px;
  border-top: 1px solid var(--line);
}

.note .label {
  margin-bottom: 8px;
  color: var(--copy);
}

.note.is-warn .label { color: #fbbf24; }

.steps {
  list-style: none;
  margin: 0 -24px;
  border-top: 1px solid var(--line);
}

.steps li {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 16px;
  padding: 22px 24px;
  border-bottom: 1px solid var(--line);
}

.step-num {
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--lime);
  padding-top: 4px;
}

.steps strong {
  display: block;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(18px, 2vw, 22px);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--white);
  margin-bottom: 6px;
}

.steps p {
  font-size: 15px;
  line-height: 1.7;
  color: var(--copy);
}

.line-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 40px;
}

.line-item {
  display: block;
  width: 100%;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: rgba(34, 211, 238, 0.12);
}

.line-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.line-item .name,
.next-item .name {
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #d2d2d2;
  transition: color 0.28s ease;
}

.line-item .num,
.next-item .num {
  font-size: 12px;
  letter-spacing: 0.12em;
  color: #b8b8b8;
  transition: color 0.28s ease;
}

.line-desc {
  display: block;
  margin-top: 10px;
  color: var(--copy);
  font-size: 15px;
  line-height: 1.7;
}

.next {
  padding-bottom: 28px;
  margin-bottom: 64px;
}

.next-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 36px;
}

.next-item {
  min-width: 160px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}

@media (hover: hover) and (pointer: fine) {
  .line-item:hover .name,
  .line-item:hover .num,
  .next-item:hover .name,
  .next-item:hover .num {
    color: var(--lime);
  }
}

@media (max-width: 960px) {
  .split { grid-template-columns: 1fr; }

  .split-col + .split-col {
    border-left: 0;
    border-top: 1px solid var(--line);
  }
}

@media (max-width: 860px) {
  .sec-head,
  .line-list { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .line-desc { display: none; }
  .line-item.is-on .line-desc { display: block; }
  .line-item.is-on .name,
  .line-item.is-on .num { color: var(--lime); }
  .next-item { width: 100%; }
  .steps li { grid-template-columns: 40px 1fr; }
}
