/* ชิ้น bento ที่บท (_chapter) ใช้ซ้ำ · S08 how — v2/v2.1 (T-049) · ไฟล์นี้เหมือนกันทั้ง website และ website-pt */

/* ---------- bento (ใช้ในบท _chapter) ---------- */
.bento { display: grid; grid-template-columns: 1.62fr 1fr; gap: 20px; }
.bx { position: relative; border-radius: var(--r-lg); background: var(--bg2); padding: clamp(24px, 2.6vw, 36px); overflow: hidden; }
.bx-k { display: flex; align-items: center; gap: 10px; font-size: 13.5px; font-weight: 600; color: var(--txp); margin-bottom: 12px; }
.bx-k em { font-style: normal; font-family: var(--num); font-size: 13px; width: 30px; height: 30px; border-radius: 9px; background: var(--card); display: inline-flex; align-items: center; justify-content: center; box-shadow: var(--sh-1); }
.bx h3 { font-size: clamp(22px, 2vw, 28px); }
.bx > p, .bx-txt > p { margin-top: 10px; font-size: 15.5px; line-height: 1.65; color: var(--mut); }
.chk { display: grid; gap: 10px; margin-top: 20px; }
.chk li { display: flex; gap: 10px; font-size: 15px; line-height: 1.5; }
.chk .ic { width: 22px; height: 22px; padding: 4px; border-radius: 50%; background: var(--p1); color: var(--txp); margin-top: 1px; }
.bx-1 { display: grid; grid-template-columns: 1fr 280px; gap: 28px; background: linear-gradient(160deg, var(--p0), var(--p1)); min-height: 520px; }
.bx-ph { position: relative; margin-bottom: calc(-1 * clamp(24px, 2.6vw, 36px)); align-self: end; }
.bx-ph .ph { width: 280px; border-radius: 42px 42px 0 0; padding-bottom: 0; }
.bx-ph .ph img { border-radius: 34px 34px 0 0; height: 500px; object-fit: cover; object-position: top; }
.bx-2 { background: var(--s0); box-shadow: inset 0 0 0 1px var(--s1); }
.bx-2 .bx-k { color: var(--txs); }
.bx-2 .chk .ic { background: var(--s1); color: var(--txs); }
.bx-chips { display: flex; align-items: center; gap: 8px; margin-top: 26px; font-size: 14px; color: var(--txs); }
.bx-chips span { width: 40px; height: 40px; border-radius: 12px; background: var(--card); display: inline-flex; align-items: center; justify-content: center; box-shadow: var(--sh-1); }
.bx-chips b { margin-left: 6px; }
.bx-row { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.bx-s { display: flex; flex-direction: column; padding-bottom: 0; min-height: 520px; }
.bx-crop { margin-top: auto; padding-top: 26px; height: 300px; overflow: hidden; }
.bx-crop .ph { width: 84%; margin: 0 auto; border-radius: 36px 36px 0 0; }
.bx-crop .ph img { border-radius: 28px 28px 0 0; }

/* ---------- S07 how ---------- */
.how { padding: clamp(56px, 6vw, 88px) 0 clamp(88px, 9vw, 128px); }
.legend { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 16px; font-size: 13.5px; color: var(--mut); }
.lg { display: inline-flex; align-items: center; gap: 8px; }
.lg img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--p); }
.lg-b img { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--s); }
.lg-s i { width: 14px; height: 14px; border-radius: 4px; background: var(--bg2); box-shadow: inset 0 0 0 1px var(--line2); }
.steps { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; counter-reset: s; position: relative; }
.steps::before { content: ""; position: absolute; left: 4%; right: 4%; top: 22px; height: 2px; background: linear-gradient(90deg, var(--p) 0 50%, var(--s) 50% 100%); opacity: .35; }
.st { position: relative; display: flex; flex-direction: column; padding-top: 64px; }
.st-n { position: absolute; top: 0; left: 0; width: 46px; height: 46px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-family: var(--num); font-weight: 700; font-size: 19px; color: #fff; background: var(--p); box-shadow: 0 0 0 6px var(--bg), 0 10px 20px -6px color-mix(in srgb, var(--p) 70%, transparent); }
.st-b .st-n { background: var(--s); color: var(--on2); box-shadow: 0 0 0 6px var(--bg), 0 10px 20px -6px color-mix(in srgb, var(--s) 70%, transparent); }
.st-who { font-size: 12.5px; font-weight: 600; color: var(--txp); }
.st-b .st-who { color: var(--txs); }
.st b { font-size: 18px; margin-top: 4px; line-height: 1.35; }
.st > p { font-size: 14px; line-height: 1.55; color: var(--mut); margin-top: 6px; }
.st-sys { padding: 14px; border-radius: 16px; background: var(--bg2); font-size: 13.5px; line-height: 1.5; font-weight: 500; margin-top: 16px; flex: 1; }
.st-sys span { display: block; font-size: 11.5px; font-weight: 600; color: var(--mut2); margin-bottom: 4px; letter-spacing: .02em; }
.loop { display: flex; align-items: center; justify-content: center; gap: 8px; width: max-content; max-width: 100%; margin: 36px auto 0; padding: 12px 20px; border-radius: 99px; box-shadow: inset 0 0 0 1px var(--line); font-size: 14.5px; color: var(--mut); }
.loop .ic { color: var(--p); }
.loop b { color: var(--ink); }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .steps { grid-template-columns: repeat(3, 1fr); row-gap: 28px; }
  .steps::before { display: none; }
}
@media (max-width: 860px) {
  .bento { grid-template-columns: 1fr; }
  .bx-1 { grid-template-columns: 1fr; min-height: 0; }
  .bx-ph { justify-self: center; }
  .bx-row { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 14px; margin-inline: calc(-1 * clamp(20px, 4vw, 40px)); padding-inline: clamp(20px, 4vw, 40px); scrollbar-width: none; }
  .bx-row::-webkit-scrollbar { display: none; }
  .bx-row > .bx { flex: 0 0 82%; scroll-snap-align: start; min-height: 480px; }
}
@media (max-width: 640px) {
  .steps { grid-template-columns: 1fr; gap: 12px; }
  .st { padding: 0 0 0 62px; margin: 0 !important; }
  .st-n { width: 44px; height: 44px; }
  .st-sys { flex: none; margin-top: 10px; }
  .loop { width: auto; border-radius: 18px; flex-wrap: wrap; text-align: center; }
}
