/* /level-up — from vibe coder to forward-deployed engineer.
 *
 * Mobile-first. Pixel art is only ever scaled by whole multiples with image-rendering: pixelated:
 * the strip frames are 64x40 art stored at 6x (384x240), so they appear at 256 (4 px per art
 * pixel) or 384 (6 px); the bots are 16x16, shown at 48 (3x). Level colours: LV1 grey,
 * LV2 green, LV3 blue, LV4 orange (#FF8A3D, the same orange as the "Level up" nav button).
 */

:root { --orange: #FF8A3D; }
.doc { width: min(900px, 100% - 32px); margin-inline: auto; }
.lu-wide { width: min(1240px, 100% - 32px); margin-inline: auto; }

/* ---------- hero ---------- */
.lu-hero { padding: 48px 0 8px; }
.lu-eye { color: var(--orange); }
.lu-hero h1 { font-family: var(--head); font-weight: 700; font-size: clamp(36px, 4.4vw + 8px, 70px); line-height: 1.02; letter-spacing: -.025em; margin: 0 0 22px; max-width: 16ch; }
.lu-hero .ans { font-family: var(--head); font-weight: 500; font-size: clamp(19px, 1.1vw + 13px, 24px); line-height: 1.38; color: var(--white); margin: 0 0 26px; max-width: 44ch; }
.lu-hero .ans b { color: var(--orange); font-weight: 700; }
.lu-hero .ans .wm { font-size: inherit; }
.lu-hero .ans .wm b { color: var(--blue); }
.ctas { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 34px; }
.ctas .btn, .cta-box .btn { white-space: normal; text-align: center; }

/* the stage */
.lu-stage-wrap { width: min(1000px, 100% - 32px); margin-inline: auto; }
.lu-stage { border: 4px solid var(--line); background: #0B0B11; padding: 18px 12px 20px; display: grid; gap: 22px; justify-items: center; }
.lu-scene { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.lu-fr { margin: 0; position: relative; }
.lu-fr img { display: block; width: 256px; height: 160px; image-rendering: pixelated; border: 3px solid var(--line); background: var(--ink); }
.lu-fr.lv4f img { border-color: var(--orange); }
.lu-fr figcaption { margin: 10px 0 0; font-family: var(--pixel); font-size: 9px; line-height: 1.5; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); text-align: center; }
.lu-fr figcaption .k { color: var(--white); margin-right: 6px; }
.lu-fr.lv4f figcaption .k { color: var(--orange); }
.lu-arrow { color: var(--orange); width: 32px; height: 32px; transform: rotate(90deg); flex: none; }
.lu-pop { position: absolute; left: 50%; top: -14px; transform: translateX(-50%); font-family: var(--pixel); font-size: 12px; letter-spacing: .06em; color: var(--ink); background: var(--orange); padding: 8px 10px; box-shadow: 3px 3px 0 var(--white); white-space: nowrap; }
@media (min-width: 900px) {
  .lu-stage { padding: 26px 24px 24px; }
  .lu-scene { flex-direction: row; gap: 22px; }
  .lu-fr img { width: 384px; height: 240px; }
  .lu-arrow { transform: none; width: 40px; height: 40px; margin-bottom: 26px; }
}

/* XP bar */
.lu-xp { width: 100%; max-width: 830px; }
.lu-xp-top { display: flex; justify-content: space-between; align-items: baseline; font-family: var(--pixel); font-size: 11px; letter-spacing: .06em; margin: 0 0 8px; }
.lu-lv { color: var(--white); }
.lu-lv b { color: var(--orange); font-weight: 400; }
.lu-xpn { color: var(--muted); }
.lu-bar { display: grid; grid-template-columns: repeat(20, 1fr); gap: 3px; padding: 4px; border: 3px solid var(--white); background: var(--ink); box-shadow: 3px 3px 0 var(--line); }
.lu-bar i { display: block; height: 14px; background: var(--panel2); }
.lu-bar i:nth-child(-n+5)  { --f: var(--muted); }
.lu-bar i:nth-child(n+6)   { --f: var(--green); }
.lu-bar i:nth-child(n+11)  { --f: var(--blue); }
.lu-bar i:nth-child(n+16)  { --f: var(--orange); }
.lu-bar i { background: var(--f); }
.lu-xp.run .lu-bar i { background: var(--panel2); }
.lu-xp.run .lu-bar i.on { background: var(--f); }
.lu-marks { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); font-family: var(--pixel); font-size: 8px; line-height: 1.5; letter-spacing: .03em; text-transform: uppercase; }
.lu-marks li { margin: 0; color: var(--muted); padding-left: 2px; }
.lu-marks li:nth-child(2) { color: var(--green); }
.lu-marks li:nth-child(3) { color: var(--blue); }
.lu-marks li:nth-child(4) { color: var(--orange); }
.lu-stage.armed .lu-pop { visibility: hidden; }
.lu-stage.armed.done .lu-pop { visibility: visible; animation: lu-pop .5s steps(4, end) 1; }
@keyframes lu-pop { 0% { transform: translate(-50%, 10px); opacity: 0; } 100% { transform: translate(-50%, 0); opacity: 1; } }

/* the party */
.lu-party { width: 100%; max-width: 830px; }
.lu-party-k { font-family: var(--pixel); font-size: 9px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; text-align: center; }
.lu-party ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 6px; justify-items: center; }
.lu-party li { margin: 0; display: grid; justify-items: center; gap: 6px; }
.lu-party img { width: 48px; height: 48px; image-rendering: pixelated; }
.lu-party span { font-family: var(--mono); font-size: 12px; color: var(--muted); letter-spacing: .02em; }
@media (min-width: 600px) { .lu-party ul { grid-template-columns: repeat(6, 1fr); } }

/* ---------- section 2 ---------- */
article.post h2 { scroll-margin-top: calc(var(--nav) + 16px); }
article.post h2 + .sub { color: var(--muted); margin-top: -6px; }
article.post ul.lu-habits, article.post ul.lu-fde, article.post ul.check { padding-left: 0; }
.lu-habits { list-style: none; display: grid; gap: 10px; margin: 0 0 26px; }
@media (min-width: 700px) { .lu-habits { grid-template-columns: 1fr 1fr; } }
article.post .lu-habits li { margin: 0; border: 3px solid var(--line); background: var(--panel); padding: 14px 16px 15px; font-size: 17px; line-height: 1.45; color: var(--muted); }
.lu-habits .n { display: block; font-family: var(--pixel); font-size: 9px; color: var(--orange); margin: 0 0 8px; }
.lu-habits b { display: block; font-family: var(--head); font-size: 19px; color: var(--white); margin: 0 0 2px; }

/* ---------- skill tree ---------- */
.tree { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 26px; }
.lv { --c: var(--muted); margin: 0; border: 4px solid var(--c); background: var(--panel); padding: 0 0 16px; position: relative; display: flex; flex-direction: column; }
.lv-1 { --c: #8A8AA0; } .lv-2 { --c: var(--green); } .lv-3 { --c: var(--blue); } .lv-4 { --c: var(--orange); }
.lv-head { background: var(--ink); border-bottom: 4px solid var(--c); padding: 14px 16px 14px; position: relative; }
.lv-badge { margin: 0 0 10px; }
.lv-badge span { display: inline-block; font-family: var(--pixel); font-size: 11px; letter-spacing: .06em; color: var(--ink); background: var(--c); padding: 6px 8px 5px; box-shadow: 3px 3px 0 var(--white); }
.lv-head h3 { font-family: var(--head); font-weight: 700; font-size: 22px; line-height: 1.15; margin: 0 0 4px; color: var(--white); }
.lv-tag { margin: 0; font-size: 15.5px; line-height: 1.4; color: var(--muted); }
.lv-dl { margin: 14px 16px 6px; display: grid; gap: 2px; }
.lv-dl dt { font-family: var(--pixel); font-size: 8px; letter-spacing: .06em; text-transform: uppercase; color: var(--c); margin: 8px 0 4px; }
.lv-dl dt:first-child { margin-top: 0; }
.lv-dl dd { margin: 0; font-size: 15.5px; line-height: 1.45; color: var(--white); }
/* the tree between levels: a pixel connector on phones (down), arrow on desktop (right) */
.lv:not(:last-child)::after { content: ""; position: absolute; left: 50%; bottom: -26px; width: 8px; height: 22px; margin-left: -4px; background: repeating-linear-gradient(to bottom, var(--c) 0 4px, transparent 4px 8px); }

.nodes { list-style: none; margin: 8px 0 0; padding: 0 16px; display: grid; gap: 12px; position: relative; }
.nodes::before { content: ""; position: absolute; left: 36px; top: 20px; bottom: 20px; width: 4px; background: repeating-linear-gradient(to bottom, var(--c) 0 6px, transparent 6px 10px); opacity: .6; }
.node { margin: 0; display: grid; grid-template-columns: 44px 1fr; gap: 12px; align-items: start; position: relative; }
.ni { width: 44px; height: 44px; display: grid; place-items: center; background: var(--ink); border: 3px solid var(--c); box-shadow: 3px 3px 0 var(--c); color: var(--c); position: relative; z-index: 1; }
.ni svg { width: 24px; height: 24px; display: block; shape-rendering: crispEdges; }
.node p { margin: 0; }
.nn { font-family: var(--head); font-weight: 700; font-size: 17px; line-height: 1.25; color: var(--white); display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.nk { font-family: var(--pixel); font-weight: 400; font-size: 7px; letter-spacing: .06em; text-transform: uppercase; color: var(--c); border: 2px solid var(--c); padding: 3px 4px 2px; }
.nl { font-size: 15px; line-height: 1.4; color: var(--muted); margin-top: 3px !important; }
.nq { font-family: 'VT323', var(--mono); font-size: 21px; line-height: 1.1; color: var(--c); margin-top: 5px !important; }

@media (min-width: 700px) and (max-width: 1099px) {
  .tree { grid-template-columns: 1fr 1fr; gap: 20px; }
  .lv:not(:last-child)::after { display: none; }
}
@media (min-width: 1100px) {
  .tree { grid-template-columns: repeat(4, 1fr); gap: 20px; align-items: stretch; }
  .lv:not(:last-child)::after { left: auto; right: -20px; top: 34px; bottom: auto; width: 20px; height: 8px; margin: 0; background: repeating-linear-gradient(to right, var(--c) 0 4px, transparent 4px 8px); }
}

/* ---------- sprint 1 vs sprint 5 ---------- */
.vs { display: grid; gap: 18px; }
@media (min-width: 860px) { .vs { grid-template-columns: 1fr 1fr; gap: 22px; } }
.term { margin: 0; border: 4px solid var(--c); background: #08080C; box-shadow: 6px 6px 0 var(--ink); display: flex; flex-direction: column; min-width: 0; }
.term.t1 { --c: var(--red); } .term.t5 { --c: var(--green); }
.term figcaption { margin: 0; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 6px 12px; padding: 10px 12px; background: var(--c); color: var(--ink); font-family: var(--pixel); font-size: 10px; letter-spacing: .05em; text-transform: uppercase; }
.term figcaption .ts { font-family: var(--mono); font-size: 12px; letter-spacing: .02em; text-transform: none; }
.tb { padding: 14px 14px 16px; font-family: 'VT323', var(--mono); font-size: 20px; line-height: 1.15; color: #DCDCE6; }
.tb p { margin: 0 0 3px; overflow-wrap: anywhere; }
.tb .c { color: var(--white); }
.tb .c::first-letter { color: var(--orange); }
.tb .q { color: var(--yellow); padding-left: 2ch; }
.tb .note { color: #7C7C92; padding-left: 7ch; }
.tb .r { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.tb .w { display: inline-block; min-width: 7ch; }
.tb .w.a { color: var(--purple); } .tb .w.g { color: var(--white); } .tb .w.v { color: var(--blue); }
.tb .w.rw { color: #8FD0FF; } .tb .w.au { color: #D4D4E0; } .tb .w.y { color: var(--orange); }
.st { font-family: var(--pixel); font-weight: 400; font-size: 8px; letter-spacing: .05em; padding: 4px 5px 3px; border: 2px solid; flex: none; }
.st.no { color: var(--red); border-color: var(--red); transform: rotate(-3deg); }
.st.ok { color: var(--green); border-color: var(--green); }
.vs-note { font-family: var(--mono); font-size: 14px; color: var(--muted); letter-spacing: .02em; margin: 14px 0 0; }

/* the page is one article.post (the newsletter anchors on it); undo its prose defaults inside the components */
article.post .tree, article.post .nodes, article.post .lu-marks { padding-left: 0; margin-bottom: 0; }
article.post .tree { margin-bottom: 12px; }
article.post .nodes { padding: 0 16px; margin-top: 14px; }
article.post .tree li, article.post .nodes li { margin: 0; }
article.post .lv-head h3 { margin: 0 0 4px; font-size: 22px; }
article.post .lv-head p, article.post .node p, article.post .tb p { margin: 0; }
article.post .tb p { margin-bottom: 3px; }
article.post .lv-badge { margin: 0 0 10px; }
article.post .vs-note { margin: 14px 0 0; }

/* ---------- FDE, teams, close ---------- */
.lu-fde { list-style: none; display: grid; gap: 8px; margin: 0 0 26px; }
article.post .lu-fde li { margin: 0; padding: 0 0 0 26px; position: relative; font-size: 18px; color: var(--muted); }
.lu-fde li::before { content: ""; position: absolute; left: 2px; top: 10px; width: 10px; height: 10px; background: var(--orange); box-shadow: 2px 2px 0 var(--ink); }
.lu-fde b { color: var(--white); }
.rule { border: 4px solid var(--orange); background: var(--panel); padding: 18px 22px; margin: 0 0 12px; }
.rule .t { font-family: var(--pixel); font-size: 9px; letter-spacing: .06em; text-transform: uppercase; color: var(--orange); margin: 0 0 10px !important; }
.rule p { font-family: var(--head); font-weight: 700; font-size: clamp(20px, 1vw + 14px, 25px); line-height: 1.28; margin: 0 !important; color: var(--white); }
.rule .wm { font-size: inherit; }
.check.yes li::before { border-color: var(--green); background: var(--green); box-shadow: inset 0 0 0 3px var(--panel); }
article.post .check li { margin: 0; }
.check li b { color: var(--white); font-weight: 600; }
.cta-box { border-color: var(--orange); }
.cta-box .btns { display: flex; gap: 10px; flex-wrap: wrap; }
article.post .cta-box h2 { margin: 0 0 8px; }
article.post .cta-box p { margin: 0; }

/* page mark, as on the other pages */
.page-mark { position: fixed; z-index: -1; right: -18vw; top: 10vh; width: 90vw; height: 90vw; background: url("../assets/brand/mark-mono-white.svg?v=2") no-repeat center/contain; opacity: .05; pointer-events: none; }
@media (min-width: 900px) { .page-mark { right: -4vw; top: 6vh; width: min(58vw, 900px); height: min(58vw, 900px); } }

@media (max-width: 480px) {
  .lu-stage-wrap { width: 100%; }
  .lu-stage { border-left: 0; border-right: 0; }
  .tb { font-size: 19px; padding: 12px 10px 14px; }
  .tb .note { padding-left: 4ch; }
}
@media (prefers-reduced-motion: reduce) { .lu-stage.done .lu-pop { animation: none; } }

/* the pointer to the before-you-start guide */
.lu-pre{border:3px dashed var(--orange);padding:14px 16px;margin:8px 0 30px;color:var(--white);font-size:17px;line-height:1.5}
.lu-pre a{color:var(--orange)}
