/* Case Study: Back Track King. Page-only layout; shared series blocks live in bot-tutorial.css. */

/* Widget canvases (moved from the prototype page). */
#widget-btk-noise canvas { height: 330px; }
#widget-btk-timeline canvas { height: 400px; }

/* What each part of the story teaches, and where the series covers it. */
.btk-takeaway { margin: 1.4rem 0 2.2rem; padding: .85rem 1.1rem; border: 1px solid #2c3048; border-radius: 8px; background: #121420; }
.btk-takeaway p { margin: .3rem 0; font-size: .95rem; }
.btk-takeaway p:first-child { margin-top: 0; }
.btk-takeaway p:last-child { margin-bottom: 0; }
.btk-takeaway strong { color: #c4b5fd; }

/* Pitfalls. */
.pitfall-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .7rem; margin: 1.2rem 0; }
.pitfall { display: flex; flex-direction: column; gap: .25rem; padding: .75rem .9rem; border-left: 3px solid var(--tut-danger); border-radius: 0 8px 8px 0; background: var(--tut-surface); }
.pitfall strong { color: var(--tut-text); font-size: .9rem; }
.pitfall span { color: var(--tut-soft); font-size: .86rem; line-height: 1.5; }

/* The rebuild figure: a wide drawing on desktop, a tall one on phones. */
.bot-figure svg.btk-figure-tall { display: none; }
.bot-figure .btk-box { fill: #171a2b; stroke: #3d4463; stroke-width: 1.2; }
.bot-figure .btk-box-first { fill: #1d1830; stroke: #6b5bb0; }
.bot-figure .btk-box-last { fill: #122220; stroke: #2f7a66; }
.bot-figure .btk-step { fill: #a78bfa; font: 600 12px ui-monospace, monospace; }
.bot-figure .btk-title { fill: #eef0fa; font: 600 15px system-ui, sans-serif; }
.bot-figure .btk-line { fill: #c7cde1; font: 13px system-ui, sans-serif; }
.bot-figure .btk-credit { fill: #f6bd60; font: 12px ui-monospace, monospace; }
.bot-figure .btk-arrow { stroke: #8f96b3; stroke-width: 1.6; fill: none; }
.bot-figure .btk-arrowhead { fill: #8f96b3; }
.bot-figure .btk-figure-wide .btk-step { font-size: 16px; }
.bot-figure .btk-figure-wide .btk-title { font-size: 20px; }
.bot-figure .btk-figure-wide .btk-line { font-size: 17px; }
.bot-figure .btk-figure-wide .btk-credit { font-size: 15px; }

@media (max-width: 600px) {
  #widget-btk-noise canvas { height: 420px; }
  #widget-btk-timeline canvas { height: 470px; }
  .bot-figure svg.btk-figure-wide { display: none; }
  .bot-figure svg.btk-figure-tall { display: block; }
  .pitfall-grid { grid-template-columns: 1fr; }
}
