/* ===== Baldi's Basics — Hub template ===== */
:root{
  --c-bg:#0d1712;
  --c-panel:#142219;
  --c-panel2:#1a2c21;
  --c-panel3:#22392b;
  --c-text:#f3f6ef;
  --c-muted:#a3b8a8;
  --c-accent:#45c84a;
  --c-accent-text:#06210b;
  --bb-green:#45c84a;
  --bb-green-d:#2a8f31;
  --bb-yellow:#ffd23f;
  --bb-red:#e8392f;
  --bb-blue:#2f6fdb;
  --bb-ink:#0a1209;
  --bb-chalk:rgba(243,246,239,.9);
  --bb-comic:"Comic Sans MS","Comic Sans","Chalkboard SE","Comic Neue",ui-rounded,"Nunito","Segoe UI",system-ui,sans-serif;
  --hub-line:rgba(243,246,239,.10);
  --hub-line-2:rgba(243,246,239,.18);
  --hub-glow:0 10px 26px -10px rgba(69,200,74,.55);
  --bb-ruler:linear-gradient(90deg,#3d2a10 2px,transparent 2px) 0 0/40px 75% repeat-x,linear-gradient(90deg,#3d2a10 1px,transparent 1px) 0 0/8px 40% repeat-x,linear-gradient(180deg,#f6d36a,#dca63a);
}

/* chalkboard background with faint chalk math */
body.tpl-hub{
  background-color:#0d1712 !important;
  background-image:
    radial-gradient(60% 50% at 20% 0%,rgba(69,200,74,.10),transparent 70%),
    radial-gradient(50% 50% at 100% 100%,rgba(47,111,219,.08),transparent 70%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='420' height='300'%3E%3Cg fill='%23f3f6ef' fill-opacity='.045' font-family='Comic Sans MS,cursive' font-size='22'%3E%3Ctext x='24' y='52' transform='rotate(-6 24 52)'%3E2 + 2 = 4%3C/text%3E%3Ctext x='250' y='92' transform='rotate(5 250 92)'%3E9 + 10 = %3F%3C/text%3E%3Ctext x='70' y='180' transform='rotate(3 70 180)'%3E7 %C3%97 6 = 42%3C/text%3E%3Ctext x='280' y='240' transform='rotate(-4 280 240)'%3E%E2%88%9A16 = 4%3C/text%3E%3Ctext x='20' y='272' transform='rotate(-2 20 272)'%3E1 2 3 4 5 6 7%3C/text%3E%3C/g%3E%3C/svg%3E"),
    linear-gradient(180deg,#0f1b15,#0b1410) !important;
  background-attachment:fixed !important;
}
body.tpl-hub ::selection{background:var(--bb-yellow);color:var(--bb-ink);}

/* ---------- top bar: hallway + ruler edge ---------- */
body.tpl-hub .header{
  background:linear-gradient(180deg,#17271d,#132119) !important;
  border-bottom:0 !important;
}
body.tpl-hub .header::after{content:"";position:absolute;left:0;right:0;bottom:-8px;height:8px;background:var(--bb-ruler);box-shadow:0 4px 10px rgba(0,0,0,.45);pointer-events:none;}
body.tpl-hub .text-logo{font-family:var(--bb-comic) !important;font-weight:700 !important;font-size:22px !important;letter-spacing:0 !important;color:#fff !important;text-shadow:2px 2px 0 var(--bb-ink);}
body.tpl-hub .text-logo b{color:var(--bb-green) !important;}
body.tpl-hub .hub-mark{filter:drop-shadow(2px 2px 0 var(--bb-ink)) !important;}

body.tpl-hub .search-input{
  background:#0b140f !important;border:2px solid #2b4434 !important;
  font-family:var(--bb-comic) !important;font-weight:400 !important;
}
body.tpl-hub .search-input:focus{border-color:var(--bb-green) !important;box-shadow:0 0 0 4px rgba(69,200,74,.18) !important;}
body.tpl-hub .btn-search{background:var(--bb-green) !important;box-shadow:inset 0 -3px 0 rgba(0,0,0,.25) !important;}
body.tpl-hub .btn-search:hover{background:var(--bb-yellow) !important;}

body.tpl-hub .hub-random{
  background:var(--bb-yellow) !important;color:var(--bb-ink) !important;
  border:2px solid var(--bb-ink) !important;border-radius:12px !important;
  box-shadow:3px 3px 0 var(--bb-ink) !important;
  font-family:var(--bb-comic) !important;font-weight:700 !important;
  transition:transform .12s,box-shadow .12s,background .12s !important;
}
body.tpl-hub .hub-random:hover{background:#ffe27a !important;color:var(--bb-ink) !important;transform:translate(-1px,-1px) rotate(-1deg);box-shadow:5px 5px 0 var(--bb-ink) !important;}
body.tpl-hub .hub-random svg{color:var(--bb-red) !important;}

/* ---------- left rail: chalkboard tray ---------- */
body.tpl-hub .header .menu nav{
  background:linear-gradient(180deg,#142219,#101c15) !important;
  border-right:0 !important;
  box-shadow:inset -6px 0 0 #5a3b1c,inset -8px 0 0 #3d2711 !important;
}
body.tpl-hub .header .menu ul li a{border-radius:12px !important;font-family:var(--bb-comic) !important;font-weight:700 !important;}
body.tpl-hub .header .menu ul li a:hover,body.tpl-hub .header .menu ul li:hover > a{
  background:rgba(69,200,74,.14) !important;color:#fff !important;
  box-shadow:inset 3px 0 0 var(--bb-green) !important;
}
body.tpl-hub .header .menu ul li a .menu-icon{color:var(--bb-green) !important;filter:drop-shadow(1.5px 1.5px 0 #000);}
body.tpl-hub .header .menu ul li a:hover .menu-icon,body.tpl-hub .header .menu ul li:hover > a .menu-icon{color:var(--bb-yellow) !important;}
body.tpl-hub .header .menu .dropdown_first li a{font-family:var(--bb-comic) !important;font-weight:400 !important;}
body.tpl-hub .header .menu .dropdown_first li a:hover{color:var(--bb-yellow) !important;}
@media (min-width:1024px){
  body.tpl-hub .header .menu nav:hover,body.tpl-hub .header .menu nav:focus-within{box-shadow:inset -6px 0 0 #5a3b1c,inset -8px 0 0 #3d2711,24px 0 60px rgba(0,0,0,.6) !important;}
}
body.tpl-hub .btn-menu{background:var(--bb-green) !important;border:2px solid var(--bb-ink) !important;box-shadow:2px 2px 0 var(--bb-ink) !important;}
body.tpl-hub .btn-menu .hamburger span{background:var(--bb-ink) !important;}

/* ---------- headings ---------- */
body.tpl-hub .block-title,body.tpl-hub .block-title h1,body.tpl-hub .hub-info__title{font-family:var(--bb-comic) !important;font-weight:700 !important;letter-spacing:0 !important;}
body.tpl-hub .block-title h1,body.tpl-hub .hub-info__title{color:#fff !important;text-shadow:3px 3px 0 var(--bb-ink),0 0 18px rgba(69,200,74,.25);}
body.tpl-hub .similiar-games .block-title::before,body.tpl-hub .character-games .block-title::before{
  width:26px !important;height:26px !important;border-radius:0 !important;background:none !important;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 26 26'%3E%3Cg stroke='%230a1209' stroke-width='1.6' stroke-linejoin='round'%3E%3Cpath d='M4 22l2.2-6.4L17.6 4.2l4.2 4.2L10.4 19.8z' fill='%23ffd23f'/%3E%3Cpath d='M17.6 4.2l1.8-1.8a1.6 1.6 0 0 1 2.3 0l1.9 1.9a1.6 1.6 0 0 1 0 2.3l-1.8 1.8z' fill='%23f28aa0'/%3E%3Cpath d='M4 22l2.2-6.4 4.2 4.2z' fill='%23f6d8a8'/%3E%3C/g%3E%3Cpath d='M4 22l1-2.9 1.9 1.9z' fill='%230a1209'/%3E%3C/svg%3E") center/contain no-repeat !important;
}

/* ---------- player ---------- */
body.tpl-hub .game-offer__window{
  border:3px solid var(--bb-ink) !important;
  box-shadow:6px 6px 0 var(--bb-ink),0 0 0 1px rgba(69,200,74,.25),0 26px 60px -24px #000 !important;
}
body.tpl-hub .player-overlay{background:#0d1a12 !important;}
body.tpl-hub .player-overlay::before{filter:blur(26px) brightness(.48) saturate(1.3) !important;}
body.tpl-hub .player-overlay::after{
  background:
    radial-gradient(60% 55% at 50% 110%,rgba(69,200,74,.35),transparent),
    radial-gradient(70% 70% at 50% 45%,transparent,rgba(0,0,0,.55)) !important;
}
body.tpl-hub .player-overlay-image img{
  border:3px solid #fff !important;border-radius:18px !important;
  box-shadow:5px 5px 0 var(--bb-ink),0 0 0 8px rgba(69,200,74,.22),0 18px 40px -10px #000 !important;
}
body.tpl-hub .player-overlay-name{font-family:var(--bb-comic) !important;font-weight:700 !important;text-shadow:3px 3px 0 var(--bb-ink),0 0 18px rgba(0,0,0,.6) !important;}
body.tpl-hub .player-overlay__start{
  background:var(--bb-green) !important;color:var(--bb-ink) !important;
  border:3px solid var(--bb-ink) !important;border-radius:16px !important;
  font-family:var(--bb-comic) !important;font-weight:700 !important;font-size:20px !important;
  box-shadow:5px 5px 0 var(--bb-ink),inset 0 -4px 0 rgba(0,0,0,.18) !important;
  transition:transform .12s,box-shadow .12s,background .12s !important;
}
body.tpl-hub .player-overlay__start:hover{
  background:var(--bb-yellow) !important;color:var(--bb-ink) !important;
  transform:translate(-2px,-2px) rotate(-1.5deg) !important;
  box-shadow:7px 7px 0 var(--bb-ink),inset 0 -4px 0 rgba(0,0,0,.12) !important;
}
body.tpl-hub .player-overlay__start .play-ico{color:var(--bb-red) !important;}
body.tpl-hub .hub-bar{background:#132119 !important;border-top:3px solid var(--bb-ink) !important;}
body.tpl-hub .hub-bar__name{font-family:var(--bb-comic) !important;font-weight:700 !important;}
body.tpl-hub .hub-ibtn,body.tpl-hub .btn-fullscreen,body.tpl-hub .like-dislike{background:#1a2c21 !important;border:2px solid #2b4434 !important;}
body.tpl-hub .hub-ibtn:hover,body.tpl-hub .btn-fullscreen:hover{border-color:var(--bb-green) !important;color:var(--bb-green) !important;}
body.tpl-hub .ld-btn:hover,body.tpl-hub .ld-btn.active{color:var(--bb-green) !important;}
body.tpl-hub .ld-btn:last-child:hover,body.tpl-hub .ld-btn:last-child.active{color:var(--bb-red) !important;}

/* ---------- panels ---------- */
body.tpl-hub .hub-info,body.tpl-hub .similiar-games,body.tpl-hub .character-games{
  background:linear-gradient(180deg,#16261c,#132118) !important;
  border:2px solid #24392b !important;
  box-shadow:0 14px 30px -18px #000 !important;
}
body.tpl-hub .hub-stats{background:#0f1a14 !important;border:2px solid #24392b !important;}
body.tpl-hub .hub-stat b{font-family:var(--bb-comic) !important;color:var(--bb-yellow) !important;}
body.tpl-hub .hub-tags a{font-family:var(--bb-comic) !important;font-weight:700 !important;border:2px solid #2b4434 !important;}
body.tpl-hub .hub-tags a:hover{color:var(--bb-ink) !important;background:var(--bb-green) !important;border-color:var(--bb-ink) !important;}
body.tpl-hub .hub-pill{background:var(--bb-green) !important;color:var(--bb-ink) !important;border:2px solid var(--bb-ink) !important;box-shadow:2px 2px 0 var(--bb-ink) !important;font-family:var(--bb-comic) !important;}
body.tpl-hub .hub-pill:hover{background:var(--bb-yellow) !important;}

/* ---------- cards ---------- */
body.tpl-hub .game-card{
  background:#1a2c21 !important;border:2px solid #24392b !important;border-radius:14px !important;
  transition:transform .15s ease,border-color .15s ease,box-shadow .15s ease !important;
}
body.tpl-hub .game-card:hover{transform:translateY(-4px) rotate(-1deg) !important;border-color:var(--bb-ink) !important;box-shadow:5px 5px 0 var(--bb-green) !important;}
body.tpl-hub .game-card:nth-child(even):hover{transform:translateY(-4px) rotate(1deg) !important;box-shadow:5px 5px 0 var(--bb-yellow) !important;}
body.tpl-hub .game-card .name{font-family:var(--bb-comic) !important;}
body.tpl-hub .game-card .name a{font-weight:700 !important;}
body.tpl-hub .game-card:hover .name a{color:var(--bb-green) !important;}
body.tpl-hub .game-card:nth-child(even):hover .name a{color:var(--bb-yellow) !important;}
body.tpl-hub .character-games__list ul li a{border:2px solid #24392b !important;}
body.tpl-hub .character-games__list ul li a:hover{border-color:var(--bb-ink) !important;box-shadow:4px 4px 0 var(--bb-green) !important;transform:translateY(-3px) rotate(-1deg) !important;}
body.tpl-hub .character-name span{font-family:var(--bb-comic) !important;font-weight:700 !important;}
body.tpl-hub .character-games__list li a:hover .character-name{background:linear-gradient(180deg,transparent,rgba(42,143,49,.92)) !important;}

/* ---------- text block = "You Can Think! Pad" notebook ---------- */
body.tpl-hub .game-offer__description{
  --c-text:#1d2742;--c-muted:#59627a;
  --c-panel:#ffffff;--c-panel2:#eef4fd;--c-panel3:#e1eafa;
  --c-accent:#1f8a2a;--c-accent-text:#ffffff;
  --hub-line:rgba(47,111,219,.18);--hub-line-2:rgba(47,111,219,.3);
  position:relative;
  background-color:#fdfdf7 !important;
  background-image:
    linear-gradient(90deg,transparent 47px,rgba(232,57,47,.55) 47px,rgba(232,57,47,.55) 49px,transparent 49px),
    repeating-linear-gradient(180deg,transparent 0 26px,rgba(47,111,219,.20) 26px 27px) !important;
  background-position:0 0,0 18px !important;
  color:#1d2742 !important;
  border:3px solid var(--bb-ink) !important;border-radius:6px !important;
  box-shadow:6px 6px 0 rgba(0,0,0,.55) !important;
  padding:28px 28px 28px 70px !important;
}
body.tpl-hub .game-offer__description::before{
  content:"";position:absolute;left:14px;top:22px;bottom:22px;width:16px;
  background:radial-gradient(circle,#0d1712 0 5px,rgba(0,0,0,.15) 6px,transparent 7px) center top/16px 72px repeat-y;
  pointer-events:none;
}
body.tpl-hub .game-offer__description p{color:#2a3550 !important;}
body.tpl-hub .game-offer__description a{color:#1f6fd1 !important;text-decoration-color:rgba(31,111,209,.4) !important;}
body.tpl-hub .game-offer__description h2{
  display:inline;padding:0 .15em !important;border:0 !important;
  font-family:var(--bb-comic) !important;font-weight:700 !important;color:#1d2742 !important;
  background:linear-gradient(180deg,transparent 58%,rgba(255,210,63,.75) 58%,rgba(255,210,63,.75) 92%,transparent 92%) !important;
  box-decoration-break:clone;-webkit-box-decoration-break:clone;
}
body.tpl-hub .game-offer__description h2::before,body.tpl-hub .game-offer__description h2::after{display:none !important;}
body.tpl-hub .game-offer__description h2 + *{margin-top:.8em !important;}
body.tpl-hub .game-offer__description h2:not(:first-child){display:table;margin-top:1.6em !important;}
body.tpl-hub .game-offer__description h2:first-child{display:table;}
body.tpl-hub .game-offer__description h3{font-family:var(--bb-comic) !important;color:var(--bb-green-d) !important;border:0 !important;padding-left:0 !important;}
body.tpl-hub .game-offer__description b,body.tpl-hub .game-offer__description strong{color:#141c33 !important;}
body.tpl-hub .game-offer__description ul li::before{
  content:"" !important;transform:none !important;width:16px !important;height:16px !important;border:0 !important;border-radius:0 !important;
  top:.3em !important;left:0 !important;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232a8f31' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 13l5 5L20 6'/%3E%3C/svg%3E") center/contain no-repeat !important;
  box-shadow:none !important;
}
body.tpl-hub .game-offer__description ul li{padding-left:26px !important;}
body.tpl-hub .game-offer__description ol{list-style:decimal !important;padding-left:1.6em !important;}
body.tpl-hub .game-offer__description ol li{padding-left:.3em !important;}
body.tpl-hub .game-offer__description ol li::marker{color:var(--bb-red) !important;font-family:var(--bb-comic);font-weight:700;}
body.tpl-hub .game-offer__description img{border:3px solid var(--bb-ink) !important;border-radius:8px !important;box-shadow:4px 4px 0 rgba(0,0,0,.25) !important;}

body.tpl-hub .game-offer__description table{background:#fff !important;border:2px solid #1d2742 !important;border-radius:8px !important;overflow:hidden;}
body.tpl-hub .game-offer__description thead th,body.tpl-hub .game-offer__description thead td,body.tpl-hub .game-offer__description .pp-table-head{
  background:var(--bb-green-d) !important;color:#fff !important;font-family:var(--bb-comic) !important;
}
body.tpl-hub .game-offer__description th,body.tpl-hub .game-offer__description td{border-color:rgba(47,111,219,.22) !important;color:#1d2742 !important;}
body.tpl-hub .game-offer__description table th[scope=row]{background:#eef4fd !important;color:#1d2742 !important;}
body.tpl-hub .game-offer__description table tr:nth-child(even) td{background:#f5f8fe !important;}

body.tpl-hub .game-offer__description .pp-tip{
  background:#fff1a1 !important;color:#2a2410 !important;
  border:2px solid #2a2410 !important;border-radius:4px !important;
  box-shadow:4px 4px 0 rgba(0,0,0,.2) !important;transform:rotate(-.6deg);
}
body.tpl-hub .game-offer__description .pp-tip *{color:#2a2410 !important;}
body.tpl-hub .game-offer__description .pp-quote{
  background:#e8f1ff !important;color:#1d2742 !important;
  border:2px solid #1d2742 !important;border-left:8px solid var(--bb-blue) !important;border-radius:6px !important;
  font-family:var(--bb-comic) !important;box-shadow:4px 4px 0 rgba(0,0,0,.18) !important;
}
body.tpl-hub .game-offer__description .pp-faq-item{
  background:#fff !important;border:2px solid #1d2742 !important;border-top:6px solid var(--bb-red) !important;
  border-radius:6px !important;box-shadow:3px 3px 0 rgba(0,0,0,.15) !important;
}
body.tpl-hub .game-offer__description .pp-controls{background:#f2f7ff !important;border:2px dashed var(--bb-blue) !important;border-radius:8px !important;}
body.tpl-hub .game-offer__description .pp-controls li b,body.tpl-hub kbd{
  background:#fff !important;color:#1d2742 !important;border:2px solid #1d2742 !important;border-radius:7px !important;
  box-shadow:0 3px 0 #1d2742 !important;font-family:var(--bb-comic) !important;
}
body.tpl-hub .game-offer__description hr,body.tpl-hub .game-offer__description .pp-rule{
  border:0 !important;height:8px !important;background:var(--bb-ruler) !important;border-radius:2px !important;opacity:.9;
}
body.tpl-hub .game-offer__description .breadcrumbs,body.tpl-hub .game-offer__description .breadcrumbs a{color:#59627a !important;}

/* info card merged into the notebook page */
body.tpl-hub .hub-merged .hub-info{background:none !important;border:0 !important;border-bottom:2px dashed rgba(47,111,219,.35) !important;box-shadow:none !important;border-radius:0 !important;padding:0 0 20px !important;}
body.tpl-hub .hub-merged .hub-info__title{color:#1d2742 !important;text-shadow:3px 3px 0 rgba(255,210,63,.75) !important;}
body.tpl-hub .hub-merged .hub-info__img img{border:3px solid #1d2742 !important;border-radius:12px !important;box-shadow:4px 4px 0 rgba(0,0,0,.2) !important;transform:rotate(-2deg);}
body.tpl-hub .hub-merged .hub-stats{background:#fff !important;border:2px solid #1d2742 !important;box-shadow:3px 3px 0 rgba(0,0,0,.15);}
body.tpl-hub .hub-merged .hub-stat{border-right-color:rgba(29,39,66,.2) !important;}
body.tpl-hub .hub-merged .hub-stat b{color:var(--bb-red) !important;}
body.tpl-hub .hub-merged .hub-stat b a{color:#1f6fd1 !important;text-decoration:none !important;}
body.tpl-hub .hub-merged .hub-tags a{background:#fff !important;color:#1d2742 !important;border:2px solid #1d2742 !important;}
body.tpl-hub .hub-merged .hub-tags a:hover{background:var(--bb-green) !important;color:var(--bb-ink) !important;}
body.tpl-hub .hub-merged .breadcrumbs{border-bottom-color:rgba(47,111,219,.25) !important;}

/* ---------- footer ---------- */
body.tpl-hub .footer__content{
  position:relative;background:#101c15 !important;border-top:0 !important;
}
body.tpl-hub .footer__content::before{content:"";position:absolute;left:0;right:0;top:0;height:8px;background:var(--bb-ruler);}
body.tpl-hub .footer .privacy a{font-family:var(--bb-comic) !important;}
body.tpl-hub .footer .privacy a:hover{color:var(--bb-yellow) !important;}
body.tpl-hub ::-webkit-scrollbar-thumb{background:var(--bb-green-d) !important;}

@media (max-width:767px){
  body.tpl-hub .game-offer__description{padding:22px 18px 22px 54px !important;background-image:
    linear-gradient(90deg,transparent 37px,rgba(232,57,47,.55) 37px,rgba(232,57,47,.55) 39px,transparent 39px),
    repeating-linear-gradient(180deg,transparent 0 26px,rgba(47,111,219,.20) 26px 27px) !important;}
  body.tpl-hub .game-offer__description::before{left:9px;}
  body.tpl-hub .text-logo{font-size:18px !important;}
}
@media (prefers-reduced-motion:reduce){body.tpl-hub .game-offer__description .pp-tip{transform:none;}}