/* BrainKit question game + the crawlable answer lists + rebus cards (the lists sit in the page copy, so these styles load on the whole page) */
.bk-blurb { margin: 4px 0 2px; font-size: 14px; opacity: .85; }
.bk-help { margin-top: 14px; }
.bk-wrap { width: 100%; max-width: 760px; margin: 0 auto; align-self: stretch; box-sizing: border-box; }
.bk-hud { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; font: 800 15px system-ui, sans-serif; }
.bk-prog { flex: 1; min-width: 0; }
.bk-score { color: #fde047; white-space: nowrap; }
.bk-tb { display: flex; gap: 6px; flex-shrink: 0; }
.bk-tb button { background: rgba(15,23,42,.7); color: #fff; border: 1px solid rgba(255,255,255,.18); border-radius: 10px; padding: 6px 10px; font: 700 14px system-ui, sans-serif; cursor: pointer; }
.bk-bar { height: 8px; border-radius: 4px; background: rgba(255,255,255,.1); overflow: hidden; margin-bottom: 10px; }
.bk-bar i { display: block; height: 100%; width: 100%; background: #4dd9e2; border-radius: 4px; transition: background .2s; }
.bk-bar i.is-low { background: #f87171; }
.bk-card { background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.12); border-radius: 16px; padding: 18px; }
.bk-era { margin: 0 0 6px; font-size: 13px; font-weight: 700; opacity: .7; text-transform: uppercase; letter-spacing: .04em; }
.bk-q { margin: 0 0 14px; font-size: 21px; line-height: 1.35; }
.bk-ans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.bk-a { display: flex; align-items: center; gap: 10px; min-height: 58px; padding: 10px 14px 10px 12px; border-radius: 14px; border: 2px solid rgba(255,255,255,.16); background: rgba(255,255,255,.06); color: inherit; font: 700 16px system-ui, sans-serif; text-align: left; cursor: pointer; transition: border-color .15s, background .15s, transform .1s; }
.bk-a:hover:not(:disabled) { border-color: rgba(103,232,249,.75); background: rgba(103,232,249,.08); }
.bk-a:active:not(:disabled) { transform: scale(.98); }
.bk-a:focus-visible { outline: 3px solid #67e8f9; outline-offset: 2px; }
.bk-a:disabled { cursor: default; }
.bk-a kbd { flex-shrink: 0; display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; background: rgba(255,255,255,.12); font: 800 12px system-ui, sans-serif; }
.bk-a.is-right { border-color: #4ade80; background: rgba(74,222,128,.16); }
.bk-a.is-wrong { border-color: #f87171; background: rgba(248,113,113,.14); }
.bk-a:disabled:not(.is-right):not(.is-wrong) { opacity: .55; }
.bk-a.is-out { opacity: .25 !important; text-decoration: line-through; }
.bk-type { display: flex; gap: 8px; }
.bk-type input { flex: 1; min-width: 0; min-height: 50px; padding: 0 14px; border-radius: 12px; border: 2px solid rgba(255,255,255,.22); background: rgba(15,23,42,.55); color: #fff; font: 700 18px system-ui, sans-serif; box-sizing: border-box; }
.bk-type input:focus { outline: none; border-color: #67e8f9; }
.bk-type .btn { min-height: 50px; }
.bk-lh { margin: 10px 0 0; font: 800 18px ui-monospace, Consolas, monospace; letter-spacing: .08em; color: #fde047; overflow-wrap: anywhere; }
.bk-show { min-height: 50px; width: 100%; }
.bk-tools { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.bk-tool { min-height: 38px; padding: 6px 12px; border-radius: 10px; border: 1px solid rgba(255,255,255,.2); background: transparent; color: inherit; font: 700 14px system-ui, sans-serif; cursor: pointer; }
.bk-tool:hover:not(:disabled) { background: rgba(255,255,255,.08); }
.bk-tool:disabled { opacity: .4; cursor: default; }
.bk-self { margin-top: 2px; text-align: center; }
.bk-self p { margin: 0 0 8px; }
.bk-reveal { font-size: 24px; font-weight: 800; color: #fde047; }
.bk-btns2 { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.bk-fact { margin-top: 14px; padding: 14px; border-radius: 14px; background: rgba(15,23,42,.55); border: 1px solid rgba(255,255,255,.1); }
.bk-verdict { margin: 0 0 6px; font-size: 17px; }
.bk-f { margin: 0 0 12px; line-height: 1.5; }
.bk-next { min-height: 46px; margin-top: 4px; }
.bk-res { text-align: center; }
.bk-res h3 { margin: 4px 0 6px; font-size: 26px; }
.bk-stars { font-size: 36px; letter-spacing: 4px; margin-bottom: 6px; }
.bk-tip { opacity: .8; font-size: 14px; }
.bk-miss { text-align: left; margin: 12px auto; max-width: 560px; background: rgba(15,23,42,.5); border-radius: 12px; padding: 10px 14px; }
.bk-miss summary { cursor: pointer; font-weight: 700; }
.bk-miss li { margin: 8px 0; line-height: 1.4; }
.bk-miss .rb-box { margin: 0 0 4px; min-height: 0; padding: 8px; font-size: 16px; }
.bk-btns { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 14px; }

/* the answer lists in the page copy */
.bk-list { display: grid; gap: 6px; margin: 8px 0 20px; }
.bk-li { background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.1); border-radius: 10px; padding: 9px 12px; }
.bk-li summary { cursor: pointer; font-weight: 600; line-height: 1.4; }
.bk-li p { margin: 8px 0 2px; line-height: 1.5; }
.bk-li .rb-box { margin: 0; display: inline-block; min-height: 0; min-width: 150px; padding: 8px 16px; font-size: 16px; vertical-align: middle; }

/* rebus cards */
.rb-box { margin: 0 0 14px; padding: 18px 12px; min-height: 120px; display: flex; flex-direction: column; justify-content: center; gap: 4px; border-radius: 14px; background: #fffdf5; color: #1e293b; text-align: center; font: 800 26px/1.25 system-ui, sans-serif; overflow-wrap: anywhere; }
.rb-box hr { width: 60%; margin: 2px auto; border: 0; border-top: 3px solid #1e293b; }
.rb-b { font-size: 1.7em; line-height: 1.05; }
.rb-s { font-size: .55em; }
.rb-u { display: inline-block; transform: rotate(180deg); }
.rb-r { display: inline-block; transform: scaleX(-1); }
.rb-v { display: inline-block; writing-mode: vertical-rl; text-orientation: upright; letter-spacing: -.05em; vertical-align: middle; }
.rb-x { text-decoration: line-through; text-decoration-thickness: 3px; }
.rb-up { display: inline-block; transform: rotate(-22deg); margin: 8px 0; }
.rb-red { color: #dc2626; }
.rb-blue { color: #2563eb; }
.rb-green { color: #16a34a; }
.rb-frame { display: inline-block; min-width: 60px; min-height: 1.1em; padding: 4px 12px; border: 4px solid currentColor; border-radius: 4px; vertical-align: middle; white-space: pre; }
.bk-print { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 4px; }
#bk-sheet { display: none; }
@media print {
  body.bk-printing > *:not(#bk-sheet) { display: none !important; }
  body.bk-printing { background: #fff !important; color: #000 !important; }
  body.bk-printing #bk-sheet { display: block; color: #000; font: 15px/1.4 system-ui, sans-serif; }
  #bk-sheet h1 { font-size: 22px; margin: 0 0 4px; }
  #bk-sheet h2 { font-size: 16px; margin: 16px 0 6px; }
  #bk-sheet ol { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px 24px; padding-left: 22px; margin: 0; }
  #bk-sheet li { break-inside: avoid; }
  #bk-sheet .rb-box { margin: 0; min-height: 0; padding: 6px; font-size: 16px; background: none; border: 1px solid #999; }
  #bk-sheet .bk-sl { display: block; border-bottom: 1px solid #999; height: 22px; }
  #bk-sheet .bk-sa { display: block; font-weight: 700; }
}

@media (max-width: 560px) {
  .bk-hud { font-size: 13px; gap: 6px; }
  .bk-tb button { padding: 6px 8px; }
  .bk-card { padding: 14px 12px; }
  .bk-q { font-size: 18px; }
  .bk-ans { grid-template-columns: 1fr; gap: 8px; }
  .bk-a { min-height: 50px; font-size: 15px; }
  .rb-box { font-size: 22px; }
}
@media (pointer: coarse) { .bk-a kbd { display: none; } }

/* picture answers + the question picture (IQ Puzzle Challenge, Picture Riddles) */
.bk-pics .bk-ans { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.bk-pics .bk-a { position: relative; flex-direction: column; justify-content: center; padding: 6px; background: #fffdf5; }
.bk-pics .bk-a:hover:not(:disabled) { background: #e0f2fe; }
.bk-pics .bk-a.is-right { background: #bbf7d0; }
.bk-pics .bk-a.is-wrong { background: #fecaca; }
.bk-pics .bk-a kbd { position: absolute; left: 4px; top: 4px; background: #e2e8f0; color: #1e293b; }
.bk-pics .bk-a span { display: block; width: 100%; }
.bk-pics .bk-a svg { display: block; width: 100%; height: auto; max-height: 130px; }
.bk-pq { margin: 0 0 10px; font-size: 18px; font-weight: 700; line-height: 1.35; }
.bk-pic { display: block; width: 100%; max-width: 420px; max-height: 44vh; margin: 0 auto 12px; border-radius: 12px; background: #fffdf5; }
#bk-sheet .bk-pic { max-height: 170px; max-width: 240px; border: 1px solid #999; margin: 4px 0; }
#bk-sheet .bk-popts { display: flex; gap: 4px; }
#bk-sheet .bk-popts svg { width: 56px; height: 56px; border: 1px solid #999; }
@media (max-width: 560px) { .bk-pics .bk-ans { grid-template-columns: repeat(2, minmax(0, 1fr)); } .bk-pics .bk-a svg { max-height: 104px; } }
