/* Level 2 / AMC 8 polish layer. Linked only from the harder-version houses and their parent home pages. */
/* --- level bubbles on the house home --- */
.lvl-stack{display:flex;flex-direction:column;gap:14px;margin:6px 0 22px}
.lvl-stack__head{font:400 22px var(--g-display,inherit);color:var(--g-gold-hi,#FFE08A);margin:4px 2px 0;text-shadow:0 2px 0 rgba(0,0,0,.3)}
a.lvl-card{position:relative;display:grid;grid-template-columns:76px minmax(0,1fr) 34px;align-items:center;gap:14px;padding:14px 14px 14px 14px;border-radius:24px;
  border:3px solid var(--g-navy-line,#3B6AD6);background:linear-gradient(160deg,rgba(43,84,170,.96),rgba(15,33,71,.96));color:#fff!important;text-decoration:none!important;
  box-shadow:0 6px 0 rgba(0,0,0,.28),0 14px 28px rgba(0,0,0,.28);transition:transform .15s ease,border-color .15s ease;-webkit-tap-highlight-color:transparent;min-height:104px;box-sizing:border-box}
a.lvl-card:hover,a.lvl-card:focus-visible{transform:translateY(-2px);border-color:var(--g-gold,#F5B82E)}
a.lvl-card:active{transform:translateY(2px);box-shadow:0 3px 0 rgba(0,0,0,.28)}
a.lvl-card.is-amc8{background:linear-gradient(160deg,rgba(122,52,160,.96),rgba(38,20,74,.96));border-color:#9C6BDB}
.lvl-card__art{position:relative;width:76px;height:76px;border-radius:50%;border:3px solid var(--g-gold,#F5B82E);overflow:hidden;background:#1b2e5c;box-shadow:0 4px 0 rgba(0,0,0,.3)}
.lvl-card__art img{width:100%;height:100%;object-fit:cover;display:block}
.lvl-card__badge{position:absolute;left:50%;bottom:-2px;transform:translateX(-50%);font:800 11px/1 var(--g-ui,system-ui);letter-spacing:.04em;color:#14213D;background:linear-gradient(180deg,#FFE08A,#F5B82E);border:2px solid #fff;border-radius:999px;padding:4px 7px;white-space:nowrap}
.lvl-card__body{min-width:0}
.lvl-card__eyebrow{font:800 11px/1.2 var(--g-ui,system-ui);letter-spacing:.1em;text-transform:uppercase;color:var(--g-gold-hi,#FFE08A);margin:0 0 4px}
.lvl-card__title{font:400 21px/1.15 var(--g-display,inherit);margin:0 0 4px;color:#fff}
.lvl-card__sub{font:600 14px/1.35 var(--g-ui,system-ui);color:rgba(255,255,255,.86);margin:0 0 8px}
.lvl-card__meta{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.lvl-card__bar{flex:1 1 90px;max-width:150px;height:8px;border-radius:99px;background:rgba(255,255,255,.18);overflow:hidden}
.lvl-card__bar i{display:block;height:100%;width:var(--p,0%);background:linear-gradient(90deg,#7CF08F,#2FBF5B);border-radius:inherit}
.lvl-card__count{font:800 12px/1 var(--g-ui,system-ui);color:rgba(255,255,255,.9);white-space:nowrap}
.lvl-card__lock{font:800 12px/1 var(--g-ui,system-ui);color:#14213D;background:rgba(255,255,255,.9);border-radius:999px;padding:5px 9px;white-space:nowrap}
.lvl-card__go{width:34px;height:34px;border-radius:50%;display:grid;place-items:center;font:900 18px/1 system-ui;color:#14213D;background:linear-gradient(180deg,#FFE08A,#F5B82E);box-shadow:0 3px 0 #B98A1E}
a.lvl-card.is-locked .lvl-card__art{filter:grayscale(.55)}
a.lvl-card.is-locked .lvl-card__go{background:rgba(255,255,255,.75);box-shadow:0 3px 0 rgba(0,0,0,.25)}
@media (max-width:360px){a.lvl-card{grid-template-columns:62px minmax(0,1fr) 28px;gap:10px;padding:12px 10px}.lvl-card__art{width:62px;height:62px}.lvl-card__title{font-size:18px}.lvl-card__sub{font-size:13px}.lvl-card__go{width:28px;height:28px;font-size:15px}}
/* --- level-home note card (replaces plain paragraph + underlined link) --- */
.lvl-note{display:flex;flex-direction:column;gap:12px;margin:6px 0 22px;padding:18px;border-radius:24px;border:3px solid var(--g-navy-line,#3B6AD6);background:linear-gradient(160deg,rgba(43,84,170,.92),rgba(15,33,71,.94));box-shadow:0 6px 0 rgba(0,0,0,.25);color:#fff}
.lvl-note.is-amc8{background:linear-gradient(160deg,rgba(122,52,160,.94),rgba(38,20,74,.96));border-color:#9C6BDB}
.lvl-note p{margin:0!important;font:600 15px/1.5 var(--g-ui,system-ui)!important;color:rgba(255,255,255,.92)!important}
.lvl-note p strong{color:var(--g-gold-hi,#FFE08A)}
.lvl-note a.lvl-back{align-self:flex-start;display:inline-flex;align-items:center;gap:6px;padding:9px 16px;border-radius:999px;font:800 14px/1 var(--g-ui,system-ui);color:#14213D!important;text-decoration:none!important;background:linear-gradient(180deg,#FFF6DE,#F1DDAE);box-shadow:0 3px 0 #B99650}
/* --- lesson pages (html.lvl set by the link below) --- */
html.lt.lvl nav.bty-nav{display:grid!important;grid-template-columns:1fr auto;gap:8px!important;align-items:center}
html.lt.lvl nav.bty-nav a{display:inline-flex!important;align-items:center;justify-content:center;min-height:38px;box-sizing:border-box;padding:6px 14px!important;border-radius:999px!important;font-size:14px!important;white-space:nowrap;margin:0!important;color:#fff!important;border:2px solid rgba(255,255,255,.35)!important}
html.lt.lvl nav.bty-nav a.bty-back{justify-self:start;max-width:100%;overflow:hidden;text-overflow:ellipsis}
html.lt.lvl nav.bty-nav a.bty-next{justify-self:end;color:#14213D!important;background:linear-gradient(180deg,#FFE08A,#F5B82E)!important;border-color:#fff!important;box-shadow:0 3px 0 #B98A1E}
html.lt.lvl nav.bty-nav a.bty-parents{justify-self:start;font-size:13px!important}
html.lt.lvl nav.bty-nav a.bty-who{justify-self:end;font-size:13px!important}
html.lt.lvl nav.bty-nav:not(:has(.bty-next)) a.bty-back{grid-column:1/-1}
html.lt.lvl .wrap{padding-top:14px}
html.lt.lvl .wrap>.subtitle{font-size:17px!important;line-height:1.5!important}
html.lt.lvl .wrap>.eyebrow{padding-top:14px!important}
html.lt.lvl .quiz-header{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:0 0 10px}
html.lt.lvl .quiz-header .hud{display:flex;gap:8px;margin-left:auto;flex-wrap:wrap;justify-content:flex-end}
html.lt.lvl .qcard{padding:18px 16px 18px!important}
html.lt.lvl .qcount{font-size:14px!important;letter-spacing:.03em!important;line-height:1.2!important;padding:6px 14px!important;white-space:nowrap;max-width:100%;overflow:hidden;text-overflow:ellipsis;box-sizing:border-box}
html.lt.lvl .qtext{margin:4px 0 16px!important;line-height:1.35!important;overflow-wrap:break-word}
html.lt.lvl #opts{display:flex;flex-direction:column;gap:10px}
html.lt.lvl #opts .opt{margin:0!important;min-height:56px}
html.lt.lvl .feedback:not(:empty){margin-top:14px!important;padding:16px!important;font-size:18px!important;line-height:1.5!important}
html.lt.lvl #continueWrap:not(:empty){display:flex;justify-content:center;margin-top:16px}
html.lt.lvl #continueWrap .btn{width:100%;max-width:340px;margin:0!important}
html.lt.lvl .complete-wrap{padding:30px 18px 24px!important;text-align:center}
html.lt.lvl .complete-wrap .btn{display:flex;justify-content:center;width:100%;max-width:320px;margin:10px auto 0!important;box-sizing:border-box}
@media (max-width:360px){html.lt.lvl nav.bty-nav a{font-size:13px!important;padding:6px 11px!important}html.lt.lvl .qcount{font-size:12px!important;padding:5px 10px!important}html.lt.lvl .qcard{padding:14px 12px!important}html.lt.lvl .quiz-header .hud{margin-left:0}}
/* "Meet the mentor" fold: was double-padded (card + summary), giving a tall empty box with off-centre text */
details.sk-about{padding:0!important;margin:0 0 18px!important}
details.sk-about>summary{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:14px 18px!important;font-size:17px!important}
details.sk-about>summary::after{content:"▾"!important;font-size:15px;transition:transform .2s}
details.sk-about[open]>summary::after{transform:rotate(180deg)}
details.sk-about>.in{padding:0 18px 16px!important}
/* --- question screen header: one clean, aligned stack (was: nav rows + bubble + hud + pill + empty bar all fighting) --- */
html.lt.lvl body:has(.wrap .qcard) nav.bty-nav{display:none!important}
html.lt.lvl .wrap:has(.qcard){padding-top:12px!important}
html.lt.lvl .wrap:has(.qcard)>.sk-scene{display:flex!important;align-items:center;gap:12px;margin:0 0 12px!important}
html.lt.lvl .wrap:has(.qcard)>.sk-scene>.sk-mentor{flex:0 0 64px;width:64px!important;margin:0!important;grid-column:auto!important}
html.lt.lvl .wrap:has(.qcard)>.sk-scene>.sk-mentor img{width:64px!important;height:64px!important}
html.lt.lvl .wrap:has(.qcard)>.sk-scene>.sk-mentor b{display:none}
html.lt.lvl .wrap:has(.qcard)>.sk-scene>.sk-bubble{flex:1 1 auto;margin:0!important;padding:10px 14px!important;font-size:16px!important;line-height:1.35!important;min-height:0!important;order:0!important}
html.lt.lvl .wrap:has(.qcard)>.quiz-header{display:flex!important;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px;margin:0 0 10px!important;padding:8px;border-radius:20px;background:rgba(15,30,60,.72);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);box-shadow:0 4px 14px rgba(0,0,0,.25)}
html.lt.lvl .wrap:has(.qcard)>.quiz-header .backlink{margin:0!important;padding:7px 12px!important;font-size:13px!important;line-height:20px!important;white-space:nowrap;border-radius:999px!important;border:2px solid rgba(255,255,255,.3)!important;background:rgba(255,255,255,.08)!important;color:#fff!important}
html.lt.lvl .wrap:has(.qcard)>.quiz-header .hud{display:flex!important;flex-wrap:wrap;justify-content:flex-end;gap:6px;margin:0 0 0 auto!important;min-width:0;max-width:100%}
html.lt.lvl .wrap:has(.qcard)>.quiz-header .hud>span{display:inline-block;line-height:20px;min-height:34px;box-sizing:border-box;padding:6px 10px!important;font-size:13px!important;white-space:nowrap;border-radius:999px!important;margin:0!important}
html.lt.lvl .wrap:has(.qcard)>.eyebrow{display:block!important;width:auto!important;max-width:none!important;box-shadow:none!important;border:0!important;color:var(--g-gold-hi,#FFE08A)!important;align-items:center;justify-content:space-between;gap:10px;margin:0!important;padding:12px 16px 8px!important;border-radius:20px 20px 0 0!important;background:rgba(15,30,60,.72)!important;font-size:13px!important;letter-spacing:.12em}
html.lt.lvl .wrap:has(.qcard)>.progress-track{margin:0 0 14px!important;height:auto!important;padding:0 16px 14px;border:0!important;border-radius:0 0 20px 20px!important;background:rgba(15,30,60,.72)!important;box-shadow:none!important;position:relative}
html.lt.lvl .wrap:has(.qcard)>.progress-track::before{content:"";display:block;height:10px;border-radius:99px;background:rgba(255,255,255,.18)}
html.lt.lvl .wrap:has(.qcard)>.progress-track>.progress-fill{position:absolute;left:16px;top:0;height:10px;max-width:calc(100% - 32px);min-width:10px;border-radius:99px;background:linear-gradient(90deg,#FFE08A,#F5B82E)!important}
html.lt.lvl .qcard .sk-secs{margin:6px 0 10px!important;text-align:right}
@media (max-width:360px){html.lt.lvl .wrap:has(.qcard)>.quiz-header .backlink{padding:6px 9px!important;font-size:12px!important}html.lt.lvl .wrap:has(.qcard)>.quiz-header .hud>span{padding:5px 8px!important;font-size:12px!important}html.lt.lvl .wrap:has(.qcard)>.sk-scene>.sk-mentor{flex-basis:52px;width:52px!important}html.lt.lvl .wrap:has(.qcard)>.sk-scene>.sk-mentor img{width:52px!important;height:52px!important}html.lt.lvl .wrap:has(.qcard)>.sk-scene>.sk-bubble{font-size:14px!important}}
/* v3: Loki fixes */
sup.lvl-sup{font-size:.68em;line-height:0;vertical-align:.62em;margin-left:.04em;white-space:nowrap}
a.lvl-card.is-locked{grid-template-columns:76px minmax(0,1fr)}
a.lvl-card.is-locked .lvl-card__go{display:none!important}
@media (max-width:360px){a.lvl-card.is-locked{grid-template-columns:62px minmax(0,1fr)}}
/* merged header+eyebrow+progress = one card */
html.lt.lvl .wrap:has(.qcard)>.quiz-header{margin:0!important;border-radius:20px 20px 0 0!important;padding:10px 10px 6px!important;flex-wrap:nowrap!important;box-shadow:none!important}
html.lt.lvl .wrap:has(.qcard)>.quiz-header .hud{flex-wrap:nowrap!important}
html.lt.lvl .wrap:has(.qcard)>.eyebrow{margin:0!important;padding:6px 16px 8px!important;border-radius:0!important;background:rgba(15,30,60,.72)!important;-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px)}
html.lt.lvl .wrap:has(.qcard)>.progress-track{margin:0 0 14px!important;-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px)}
@media (max-width:360px){
html.lt.lvl .wrap:has(.qcard)>.quiz-header{gap:4px!important;padding:8px 8px 4px!important}
html.lt.lvl .wrap:has(.qcard)>.quiz-header .hud{gap:4px!important}
html.lt.lvl .wrap:has(.qcard)>.quiz-header .backlink{padding:6px 8px!important;font-size:11px!important}
html.lt.lvl .wrap:has(.qcard)>.quiz-header .hud>span{padding:6px 7px!important;font-size:11px!important}}
/* finish screens: drop old nav, compact mentor */
html.lt.lvl body:has(.complete-wrap) nav.bty-nav{display:none!important}
html.lt.lvl .wrap:has(.complete-wrap){padding-top:12px!important}
html.lt.lvl .complete-wrap .btn{display:block;width:100%;max-width:340px;margin:10px auto 0!important;box-sizing:border-box}
html.lt.lvl,html.lt.lvl body{overflow-x:clip}
/* v4: readable 320 header */
@media (max-width:360px){html.lt.lvl .wrap:has(.qcard)>.quiz-header .backlink,html.lt.lvl .wrap:has(.qcard)>.quiz-header .hud>span{font-size:12px!important;padding:6px 9px!important}}
/* v5: intro spacing under gold divider + two paragraphs */
html.lt.lvl .wrap>.subtitle{padding-top:12px!important}
html.lt.lvl .wrap>.subtitle .lvl-para{display:block}
html.lt.lvl .wrap>.subtitle .lvl-para+.lvl-para{margin-top:10px}
