/* TechBites home (new UI) — "Poster Wall", Arabic-first. Scoped under .tbh, classes prefixed tbh- so styles.css/Tailwind never collide.
   Logical properties throughout, so the layout also works if the block is ever rendered LTR. */
.tbh {
  --bg: #0B0B0D; --s1: #151518; --s2: #1A1A1E; --line: rgba(255,255,255,.08); --line2: rgba(255,255,255,.14);
  --brand: #F39125; --brand2: #FFB04A; --green: #19E68C; --red: #FF1F4B; --cyan: #22D3EE; --violet: #A78BFA; --blue: #3B82F6; --sky: #93C5FD; --gold: #FBBF24;
  --tx: #F4F4F5; --tx2: #B4B4BD; --tx3: #85858F;
  --ar: 'Cairo', system-ui, sans-serif; --lat: 'Outfit', 'Cairo', sans-serif; --mono: 'JetBrains Mono', ui-monospace, monospace;
  --ease: cubic-bezier(.2,.8,.2,1);
  font-family: var(--ar); color: var(--tx); line-height: 1.6; padding-block: 84px 40px; overflow-x: clip;
}
.tbh *, .tbh *::before, .tbh *::after { box-sizing: border-box; }
.tbh a { color: inherit; text-decoration: none; }
.tbh img { display: block; max-width: 100%; }
.tbh h1, .tbh h2, .tbh h3, .tbh p { margin: 0; }
.tbh .ico { width: 1em; height: 1em; flex: none; }
.tbh :focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 10px; }
.tbh-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.tbh-wrap { max-width: 1240px; margin-inline: auto; padding-inline: 20px; }
.tbh-lat { font-family: var(--lat); }
.tbh-num { font-family: var(--mono); direction: ltr; unicode-bidi: isolate; }

/* countdown digits stay LTR inside Arabic text */
.tbh-clock { font-family: var(--mono); font-weight: 800; direction: ltr; unicode-bidi: isolate; }

/* atoms */
.tbh-pill { display: inline-flex; align-items: center; gap: 8px; min-height: 34px; padding-inline: 14px; border-radius: 999px; font-weight: 800; font-size: 13px; border: 1.5px solid; white-space: nowrap; }
.tbh-pill .tbh-lat { letter-spacing: .06em; text-transform: uppercase; font-size: 12px; }
.tbh-pill.steam { color: #66C0F4; border-color: rgba(102,192,244,.45); background: rgba(102,192,244,.08); }
.tbh-pill.brand { color: var(--brand); border-color: rgba(243,145,37,.5); background: rgba(243,145,37,.08); }
.tbh-pill.cyan { color: var(--cyan); border-color: rgba(34,211,238,.45); background: rgba(34,211,238,.08); }
.tbh-pill.blue { color: var(--sky); border-color: rgba(59,130,246,.5); background: rgba(59,130,246,.10); }
.tbh-pill.green { color: var(--green); border-color: rgba(25,230,140,.45); background: rgba(25,230,140,.08); }
.tbh-disc { direction: ltr; background: var(--red); color: #fff; font-family: var(--lat); font-weight: 900; border-radius: 14px; box-shadow: 0 10px 40px rgba(255,31,75,.45); letter-spacing: -.02em; line-height: 1.15; }
.tbh-price { direction: ltr; unicode-bidi: isolate; font-family: var(--mono); font-weight: 800; color: var(--green); text-shadow: 0 0 28px rgba(25,230,140,.45); letter-spacing: -.02em; white-space: nowrap; display: inline-block; }
.tbh-was { direction: ltr; unicode-bidi: isolate; font-family: var(--mono); color: var(--tx3); text-decoration: line-through; text-decoration-color: var(--red); text-decoration-thickness: 2px; white-space: nowrap; }
.tbh-cta { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding-inline: 26px; border-radius: 999px; background: linear-gradient(180deg, var(--brand2), var(--brand)); color: #160c00 !important; font-family: var(--ar); font-weight: 900; font-size: 16px; box-shadow: 0 10px 34px rgba(243,145,37,.42); border: 0; cursor: pointer; transition: transform .18s var(--ease), box-shadow .18s; white-space: nowrap; }
.tbh-cta:hover { transform: translateY(-2px); box-shadow: 0 16px 44px rgba(243,145,37,.55); }
.tbh-cta:active { transform: translateY(0) scale(.98); }
.tbh-cta[aria-busy="true"] { opacity: .7; pointer-events: none; }
.tbh-cta.ghost { background: rgba(255,255,255,.06); color: #fff !important; box-shadow: none; border: 1px solid var(--line2); }
.tbh-cta.cyan { background: linear-gradient(180deg, #67E8F9, var(--cyan)); color: #03161c !important; box-shadow: 0 10px 34px rgba(34,211,238,.4); }
.tbh-pay { display: flex; gap: 8px; flex-wrap: wrap; direction: ltr; }
.tbh-pay span { height: 32px; display: inline-flex; align-items: center; padding-inline: 12px; border-radius: 999px; font-family: var(--lat); font-weight: 800; font-size: 12.5px; }
.tbh-pay .ip { background: rgba(124,58,237,.18); border: 1px solid rgba(124,58,237,.5); color: #E9D5FF; }
.tbh-pay .vf { background: rgba(230,0,0,.16); border: 1px solid rgba(230,0,0,.45); color: #FECACA; }
.tbh-art { position: relative; overflow: hidden; background: #110f18; display: block; }
.tbh-art img { width: 100%; height: 100%; object-fit: cover; }
.tbh-skel { background: linear-gradient(90deg, rgba(255,255,255,.04), rgba(255,255,255,.09), rgba(255,255,255,.04)); background-size: 200% 100%; animation: tbh-shimmer 1.4s infinite linear; border-radius: 14px; }
@keyframes tbh-shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

/* section heads */
.tbh-sec { padding-block-start: 72px; }
.tbh-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-block-end: 26px; flex-wrap: wrap; }
.tbh-kicker { font-family: var(--lat); font-size: 12px; font-weight: 800; letter-spacing: .18em; color: var(--brand); text-transform: uppercase; display: block; margin-block-end: 6px; }
.tbh-head h2 { font-weight: 900; font-size: clamp(30px, 4.2vw, 46px); letter-spacing: -.01em; line-height: 1.15; color: #fff; }
.tbh-head h2 em { font-style: normal; color: var(--brand); }
.tbh-head p { margin-block-start: 6px; color: var(--tx2); font-size: 16px; font-weight: 600; }
.tbh-head p b { color: var(--red); }
.tbh-more { font-weight: 800; font-size: 14px; color: var(--brand) !important; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; min-height: 44px; }

/* reveal (stagger) */
.tbh-rv { opacity: 0; transform: translateY(18px); transition: opacity .55s var(--ease), transform .55s var(--ease); transition-delay: calc(var(--i, 0) * 60ms); }
.tbh-rv.in { opacity: 1; transform: none; }

/* ===== hero ===== */
.tbh-hero { position: relative; isolation: isolate; padding-block: 28px 8px; }
.tbh-hero::before { content: ""; position: absolute; inset: -84px 0 0; z-index: -1; pointer-events: none;
  background: radial-gradient(900px 520px at 10% -10%, rgba(243,145,37,.20), transparent 60%), radial-gradient(700px 500px at 110% 100%, rgba(20,184,166,.13), transparent 60%),
    linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 44px 44px, linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 44px 44px;
  mask-image: radial-gradient(ellipse at 50% 30%, #000 35%, transparent 78%); }
.tbh-search { display: flex; align-items: center; gap: 10px; height: 60px; padding-inline: 20px 8px; border-radius: 999px; background: var(--s1); border: 1.5px solid var(--line2); max-width: 560px; transition: border-color .2s, box-shadow .2s; color: var(--tx3); }
.tbh-search:focus-within { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(243,145,37,.15); }
.tbh-search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: #fff; font: 600 16px var(--ar); }
.tbh-search input::placeholder { color: var(--tx3); }
.tbh-search .tbh-cta { min-height: 46px; padding-inline: 20px; font-size: 15px; }

/* hero poster (01-sale-discount-square, live) */

/* trust row */
.tbh-trust { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-block-start: 44px; }
.tbh-trust > div { display: flex; gap: 12px; align-items: center; padding: 14px 16px; border-radius: 18px; background: rgba(21,21,24,.7); border: 1px solid var(--line); }
.tbh-trust > div > div { min-width: 0; }
.tbh-trust i { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; font-size: 20px; flex: none; font-style: normal; }
.tbh-trust b { display: block; font-size: 15px; line-height: 1.3; color: #fff; }
.tbh-trust span { font-size: 13px; color: var(--tx2); }

/* category posters */
.tbh-cats { display: grid; grid-template-columns: repeat(var(--n, 4), 1fr); gap: 18px; }
.tbh-cat { position: relative; border-radius: 26px; overflow: hidden; aspect-ratio: 4/5; display: flex; flex-direction: column; justify-content: space-between; padding: 22px; border: 1px solid var(--line2); isolation: isolate; transition: transform .3s var(--ease), box-shadow .3s; }
.tbh-cat:hover { transform: translateY(-6px); box-shadow: 0 30px 60px rgba(0,0,0,.5); }
.tbh-status { font-size: 12.5px; font-weight: 700; display: inline-flex; align-items: center; gap: 6px; }
.tbh-status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }

/* deals: tabs + rail */
.tbh-tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--s1); border: 1px solid var(--line); }
.tbh-tabs button { white-space: nowrap; min-height: 44px; padding-inline: 16px; border-radius: 999px; border: 0; background: none; color: var(--tx2); font: 800 14px var(--ar); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; transition: background .2s, color .2s; }
.tbh-tabs button[aria-selected="true"] { background: var(--brand); color: #160c00; }
.tbh-rail-wrap { position: relative; }
.tbh-rail { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 4 * 16px) / 5); gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding-block: 6px 10px; min-height: 360px; }
.tbh-rail::-webkit-scrollbar { display: none; }
.tbh-rail > * { scroll-snap-align: start; }
.tbh-dots { display: none; }
.tbh-endcard { border-radius: 20px; border: 1px dashed var(--line2); background: var(--s1); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; color: var(--tx); text-decoration: none; font: 800 15px var(--ar); min-height: 220px; transition: border-color .2s, background .2s; }
.tbh-endcard:hover, .tbh-endcard:focus-visible { border-color: var(--brand); background: rgba(243,145,37,.06); }
.tbh-endico { width: 48px; height: 48px; border-radius: 50%; background: var(--brand); color: #160c00; display: grid; place-items: center; }
.tbh-endico svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.tbh-rail-btn { position: absolute; inset-block-start: 38%; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line2); background: rgba(21,21,24,.92); color: #fff; display: grid; place-items: center; cursor: pointer; z-index: 3; box-shadow: 0 10px 30px rgba(0,0,0,.5); transition: opacity .2s, border-color .2s; }
.tbh-rail-btn:hover { border-color: var(--brand); }
.tbh-rail-btn.prev { inset-inline-start: -18px; } .tbh-rail-btn.next { inset-inline-end: -18px; }
.tbh-rail-btn[disabled] { opacity: 0; pointer-events: none; }
.tbh-card { border-radius: 20px; overflow: hidden; background: var(--s1); border: 1px solid var(--line); transition: transform .25s var(--ease), border-color .25s, box-shadow .25s; display: flex; flex-direction: column; }
.tbh-card:hover { transform: translateY(-5px); border-color: rgba(243,145,37,.55); box-shadow: 0 24px 50px rgba(0,0,0,.45); }
.tbh-card .tbh-art { aspect-ratio: 2/3; }
.tbh-card .tbh-art img { transition: transform .5s var(--ease); }
.tbh-card:hover .tbh-art img { transform: scale(1.05); }
.tbh-card .tbh-disc { position: absolute; inset-block-start: 10px; inset-inline-start: 10px; font-size: 16px; padding: 3px 9px; border-radius: 9px; }
.tbh-rank { position: absolute; inset-block-start: 8px; inset-inline-end: 10px; font-family: var(--lat); font-weight: 900; font-size: 44px; line-height: 1; color: #fff; -webkit-text-stroke: 2px rgba(0,0,0,.6); text-shadow: 0 4px 20px rgba(0,0,0,.8); }
.tbh-meta { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.tbh-meta b { font-family: var(--lat); font-size: 14.5px; font-weight: 700; line-height: 1.3; direction: ltr; text-align: end; color: #fff; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.tbh-row { display: flex; align-items: center; gap: 8px; margin-block-start: auto; }
.tbh-row > div { display: flex; flex-direction: column; line-height: 1.25; }
.tbh-card .tbh-price { font-size: 19px; text-shadow: 0 0 18px rgba(25,230,140,.35); }
.tbh-card .tbh-was { font-size: 12px; }
.tbh-add { flex: none; margin-inline-start: auto; width: 44px; height: 44px; border-radius: 50%; background: rgba(243,145,37,.12); color: var(--brand); border: 1px solid rgba(243,145,37,.4); display: grid; place-items: center; cursor: pointer; transition: background .2s, color .2s, transform .2s; }
.tbh-add:hover { background: var(--brand); color: #160c00; transform: scale(1.06); }

/* software */
.tbh-sw { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.tbh-sw > :nth-child(n+5) { display: none; }
.tbh-swc { border-radius: 20px; background: linear-gradient(180deg, #121a2e, var(--s1) 60%); border: 1px solid rgba(59,130,246,.25); padding: 14px; display: flex; flex-direction: column; gap: 12px; transition: transform .25s var(--ease), border-color .25s; }
.tbh-swc:hover { transform: translateY(-4px); border-color: rgba(59,130,246,.65); }
.tbh-swc img { border-radius: 14px; aspect-ratio: 16/10; object-fit: cover; width: 100%; }
.tbh-swc b { font-family: var(--lat); font-size: 15px; line-height: 1.35; min-height: 2.7em; direction: ltr; text-align: end; color: #fff; }
.tbh-swc .tbh-row { justify-content: space-between; }
.tbh-swc .tbh-price { color: var(--sky); text-shadow: 0 0 18px rgba(59,130,246,.5); font-size: 21px; }
.tbh-ok { font-size: 13px; font-weight: 800; color: var(--green); display: inline-flex; gap: 5px; align-items: center; }
.tbh-guar { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-block-start: 18px; }
.tbh-guar div { display: flex; align-items: center; gap: 12px; font-size: 14.5px; font-weight: 700; padding: 14px 16px; border-radius: 16px; background: rgba(59,130,246,.07); border: 1px solid rgba(59,130,246,.22); }
.tbh-guar i { font-style: normal; font-size: 22px; color: var(--sky); display: grid; }

/* how to buy */
.tbh-how { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.tbh-how > div { padding: 18px; border-radius: 18px; background: var(--s2); border: 1px solid var(--line); position: relative; overflow: hidden; }
.tbh-how .k { font-family: var(--mono); font-size: 34px; font-weight: 800; color: var(--brand); line-height: 1; direction: ltr; display: block; text-align: end; }
.tbh-how .ic { position: absolute; inset-block-start: 16px; inset-inline-end: 16px; font-size: 24px; color: var(--tx3); display: grid; }
.tbh-how b { display: block; font-size: 17px; margin-block-start: 12px; color: #fff; }
.tbh-how span { font-size: 14px; color: var(--tx2); }


/* reviews + recently viewed live below (existing markup) */
.tbh-legacy { padding-block-start: 72px; }

/* mobile bottom nav (home only) */
.tbh-bnav { display: none; }

@media (max-width: 1100px) {
  .tbh-rail { grid-auto-columns: calc((100% - 3 * 16px) / 4); }
  .tbh-cats { grid-template-columns: repeat(2, 1fr); }
  .tbh-sw { grid-template-columns: repeat(3, 1fr); } .tbh-sw > :nth-child(n+4) { display: none; }
  .tbh-trust { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .tbh-rail { grid-auto-columns: 44%; } .tbh-rail-btn { display: none; }
  .tbh-dots { display: flex; justify-content: center; gap: 6px; margin-top: 10px; } .tbh-dots:empty { display: none; }
  .tbh-dots i { width: 6px; height: 6px; border-radius: 3px; background: var(--line2); transition: width .25s var(--ease), background .25s; } .tbh-dots i.on { width: 20px; background: var(--brand); }
  .tbh-sw { grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: 64%; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; scrollbar-width: none; } .tbh-sw > * { scroll-snap-align: start; } .tbh-sw > :nth-child(n+4) { display: flex; }
  .tbh-guar { grid-template-columns: 1fr; }
  .tbh-how { grid-template-columns: 1fr 1fr; }
  .tbh-bnav { display: grid; grid-template-columns: repeat(var(--n, 5), 1fr); position: fixed; inset-inline: 10px; bottom: calc(10px + env(safe-area-inset-bottom)); z-index: 60; height: 64px; border-radius: 22px; background: rgba(21,21,24,.94); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid var(--line2); box-shadow: 0 16px 40px rgba(0,0,0,.6); font-family: var(--ar); direction: rtl; }
  .tbh-bnav a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 11.5px; font-weight: 700; color: var(--tx3); position: relative; text-decoration: none; }
  .tbh-bnav a .ico { width: 21px; height: 21px; }
  .tbh-bnav a.on { color: var(--brand); }
  .tbh-bnav .dot { position: absolute; inset-block-start: 9px; inset-inline-end: calc(50% - 18px); width: 8px; height: 8px; border-radius: 50%; background: var(--cyan); }
  .tbh-bnav .cnt { position: absolute; inset-block-start: 6px; inset-inline-end: calc(50% - 22px); min-width: 18px; height: 18px; border-radius: 9px; background: var(--brand); color: #111; font: 800 10px var(--mono); display: grid; place-items: center; }
  body.tbh-has-bnav { padding-bottom: calc(84px + env(safe-area-inset-bottom)); }
}
@media (max-width: 520px) {
  .tbh-wrap { padding-inline: 16px; }
  .tbh-hero { padding-top: 16px; }
  .tbh-cats { grid-template-columns: 1fr 1fr; gap: 12px; }
  .tbh-search { height: 56px; } .tbh-search .tbh-cta { padding-inline: 14px; } .tbh-search .tbh-cta .t { display: none; }
  .tbh-trust { grid-template-columns: 1fr; gap: 8px; margin-top: 32px; }
  .tbh-tabs { width: 100%; overflow-x: auto; } .tbh-tabs button { flex: 1; padding-inline: 8px; font-size: 13px; gap: 4px; }
  .tbh-sec, .tbh-legacy { padding-top: 56px; }
  .tbh-head .tbh-pay { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .tbh *, .tbh *::before, .tbh *::after { animation: none !important; transition: none !important; }
  .tbh-rv { opacity: 1; transform: none; }
}

.tbh [hidden], .tbh-bnav [hidden], .tbh[hidden] { display: none !important; }
@media (max-width: 860px) {
  body.tbh-has-bnav #toast-notification, body.tbh-has-bnav .floating-whatsapp-btn, body.tbh-has-bnav #social-proof-toast, body.tbh-has-bnav #whatsapp-floating-widget { bottom: calc(96px + env(safe-area-inset-bottom)) !important; }
  body.tbh-has-bnav .social-proof-popup { bottom: calc(156px + env(safe-area-inset-bottom)) !important; }
}

/* store-pick badge, gift card row */
.tbh-pick { position: absolute; inset-block-end: 10px; inset-inline-end: 10px; display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 999px; background: rgba(11,11,13,.82); border: 1px solid rgba(251,191,36,.55); color: var(--gold); font-size: 12px; font-weight: 800; backdrop-filter: blur(6px); }
.tbh-giftgrid .tbh-gcard { background: linear-gradient(180deg, #0f2219, var(--s1) 60%); border-color: rgba(25,230,140,.25); }
.tbh-giftgrid .tbh-gcard:hover { border-color: rgba(25,230,140,.6); }
.tbh-giftgrid .tbh-gimg img { border-radius: 14px; aspect-ratio: 16/10; object-fit: cover; width: 100%; }
.tbh-giftgrid .tbh-gcard b { min-height: 0; }
.tbh-giftgrid .tbh-price { color: var(--green); }
@media (min-width: 861px) { .tbh-giftgrid { grid-template-columns: repeat(3, 1fr); } }

/* Home rails use the All Games card (.tb-card, assets/game-card.css): landscape cover, hover screenshots. */
.tbh-rail { grid-auto-columns: calc((100% - 3 * 16px) / 4); min-height: 0; align-items: stretch; }
.tbh-rail .tb-card { height: 100%; }
.tbh-rail .tb-card { direction: ltr; text-align: left; font-family: 'Inter', system-ui, sans-serif; }   /* English card copy: same as All Games */
.tbh-ranked { counter-reset: tbh-rank; }
.tbh-ranked .tb-card { counter-increment: tbh-rank; }
.tbh-ranked .tb-card-cover::after { content: counter(tbh-rank); position: absolute; inset-block-end: 6px; inset-inline-end: 12px; z-index: 2; font-family: var(--lat); font-weight: 900; font-size: 46px; line-height: 1; color: #fff; -webkit-text-stroke: 2px rgba(0,0,0,.55); text-shadow: 0 4px 18px rgba(0,0,0,.85); pointer-events: none; }
.tbh-ranked .tb-card.previewing .tb-card-cover::after { opacity: 0; }
@media (max-width: 1100px) { .tbh-rail { grid-auto-columns: calc((100% - 2 * 16px) / 3); } }
@media (max-width: 860px) { .tbh-rail { grid-auto-columns: 62%; } }
@media (max-width: 520px) { .tbh-rail { grid-auto-columns: 78%; } .tbh-ranked .tb-card-cover::after { font-size: 38px; } }

/* Hero deal card v2: three clear layers (media / info / action) */
@media (max-width: 520px) {
}

/* hero search reuses the header typeahead (app.js initGlobalTypeaheadSearch: suggestions, covers, prices) */
.tbh-search { position: relative; }
.tbh-search #nav-global-search-dropdown { top: calc(100% + 10px); inset-inline: 0; left: auto; width: 100%; min-width: 0; max-width: none; max-height: 440px; z-index: 40; text-align: start; }
.tbh-search #nav-global-search-dropdown .search-dropdown-item { direction: ltr; text-align: left; }   /* English rows: same as the header dropdown */

/* ===== Category posters: the card IS the poster (title, art, CTA baked in) ===== */
.tbh-cats .tbh-cat { aspect-ratio: 4 / 5; padding: 0; display: block; border: 0; border-radius: 22px; background: #0B0B0D; container-type: inline-size; box-shadow: 0 18px 40px rgba(0,0,0,.45); }
.tbh-cats .tbh-cat > img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s var(--ease), filter .3s; }
.tbh-cats .tbh-cat:hover { transform: translateY(-6px); }
.tbh-cats .tbh-cat:focus-visible { outline: 3px solid var(--brand); outline-offset: 4px; }
@media (max-width: 1100px) { .tbh-cats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .tbh-cats .tbh-cat { border-radius: 16px; } }

/* ===== Hero B: search-first stage over a moving wall of covers ===== */
.tbh-stage { position: relative; z-index: 5; border-radius: 30px; overflow: visible; border: 1px solid var(--line2); background: #0d0d10; isolation: isolate; min-height: 520px; display: grid; place-items: center; text-align: center; padding: 64px 24px; }
/* only the cover wall is clipped to the rounded stage, so the search dropdown can overflow it */
.tbh-wallclip { position: absolute; inset: 0; z-index: -2; overflow: hidden; border-radius: inherit; pointer-events: none; }
.tbh-wall { position: absolute; inset: -70px -50px; z-index: -2; display: grid; align-content: center; gap: 14px; transform: rotate(-8deg); direction: ltr; opacity: 0; transition: opacity 1.2s var(--ease); pointer-events: none; }
.tbh-wall.on { opacity: .55; }
.tbh-lane { display: flex; gap: 14px; width: max-content; animation: tbh-lane 80s linear infinite; }
.tbh-lane.r { animation-direction: reverse; animation-duration: 100s; }
.tbh-lane img { width: 150px; height: auto; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 14px; background: #16161a; }
.tbh-wall.paused .tbh-lane { animation-play-state: paused; }
@keyframes tbh-lane { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.tbh-stage::after { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none; background: radial-gradient(ellipse 62% 58% at 50% 50%, rgba(11,11,13,.96) 32%, rgba(11,11,13,.6) 70%, rgba(11,11,13,.38) 100%); }
.tbh-stage-in { width: 100%; max-width: 760px; }
.tbh-stage h1 { font-weight: 900; font-size: clamp(38px, 5.6vw, 76px); line-height: 1.1; margin-block-start: 18px; color: #fff; }
.tbh-stage h1 em { font-style: normal; color: var(--brand); text-shadow: 0 0 44px rgba(243,145,37,.35); }
.tbh-stage .tbh-subline { color: var(--tx2); font-size: 18px; font-weight: 600; line-height: 1.75; margin: 14px auto 26px; max-width: 600px; }
.tbh-stage .tbh-search { width: min(660px, 100%); max-width: none; margin-inline: auto; height: 66px; background: rgba(21,21,24,.88); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); text-align: start; }


@media (max-width: 860px) {
  .tbh-stage { min-height: 0; padding: 48px 18px; border-radius: 24px; }
  .tbh-lane img { width: 110px; }
}
@media (max-width: 520px) {
  .tbh-stage { padding: 36px 14px; border-radius: 20px; }
  .tbh-stage .tbh-subline { font-size: 15.5px; }
  .tbh-stage .tbh-search { height: 58px; }
}
@media (prefers-reduced-motion: reduce) { .tbh-lane { animation: none; } }
.tbh-fade { animation: tbh-fade .45s var(--ease); }
@keyframes tbh-fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
/* hero search input: no inner box/glow (styles.css .global-search-input-field:focus is for the header);
   the outer .tbh-search already shows focus with its orange border (:focus-within) */
.tbh-search .global-search-input-field, .tbh-search .global-search-input-field:focus, .tbh-search .global-search-input-field:focus-visible { background: transparent; box-shadow: none; border: 0; outline: none; border-radius: 0; }
.tbh-search input[type="search"]::-webkit-search-cancel-button { filter: grayscale(1) brightness(1.6); cursor: pointer; }

/* ===== Category posters: live layers — background, 3 fanned cards (float + fan out on hover), real CTA ===== */
.tbh-cats .tbh-cat > img.tbh-cat-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: none; transition: filter .4s; }
.tbh-cats .tbh-cat:hover > img.tbh-cat-bg { transform: none; filter: brightness(1.12) saturate(1.1); }
.tbh-fan { position: absolute; inset: 0; direction: ltr; pointer-events: none; }
.tbh-fc { position: absolute; transform-origin: 50% 46.94%; transition: transform .6s cubic-bezier(.34,1.56,.64,1), filter .4s; will-change: transform; }
.tbh-fc img { display: block; width: 100%; height: 100%; animation: tbh-float 5s ease-in-out infinite; }
.tbh-fc0 { left: 11.1%; top: 42.84%; width: 33.3%; height: 35.28%; transform: rotate(-17deg); filter: brightness(.66) saturate(.9); z-index: 1; }
.tbh-fc2 { left: 55.6%; top: 42.84%; width: 33.3%; height: 35.28%; transform: rotate(17deg); filter: brightness(.66) saturate(.9); z-index: 1; }
.tbh-fc1 { left: 29.19%; top: 33.9%; width: 41.63%; height: 44.1%; z-index: 2; }
.tbh-fc0 img { animation-delay: -1.6s; } .tbh-fc2 img { animation-delay: -3.2s; }
@keyframes tbh-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-2.4%); } }
.tbh-cat:hover .tbh-fc0, .tbh-cat:focus-visible .tbh-fc0 { transform: translate(-16%, 3%) rotate(-25deg); filter: brightness(.86); }
.tbh-cat:hover .tbh-fc2, .tbh-cat:focus-visible .tbh-fc2 { transform: translate(16%, 3%) rotate(25deg); filter: brightness(.86); }
.tbh-cat:hover .tbh-fc1, .tbh-cat:focus-visible .tbh-fc1 { transform: translateY(-7%) scale(1.08); filter: drop-shadow(0 18px 30px rgba(0,0,0,.55)); }
/* real CTA (drawn where the poster's button was): x 70..730, y 836..940 of 800x1000 */
.tbh-cat-cta { position: absolute; left: 8.75%; top: 83.6%; width: 82.5%; height: 10.4%; border-radius: 999px; display: flex; align-items: center; justify-content: center; gap: 2.4cqw; font: 900 4.6cqw/1 var(--ar); color: #0b0b0d; box-shadow: 0 1.4cqw 3.6cqw rgba(0,0,0,.45); transition: transform .3s cubic-bezier(.34,1.56,.64,1), box-shadow .3s, filter .3s; z-index: 3; }
.tbh-cat-cta .ico { width: 5cqw; height: 5cqw; transition: transform .3s; }
.tbh-cat-games .tbh-cat-cta { background: #F39125; } .tbh-cat-offline .tbh-cat-cta { background: #22D3EE; } .tbh-cat-software .tbh-cat-cta { background: #60A5FA; } .tbh-cat-gift .tbh-cat-cta { background: #19E68C; }
.tbh-cat:hover .tbh-cat-cta { transform: translateY(-4%); filter: brightness(1.08); box-shadow: 0 2cqw 5cqw rgba(0,0,0,.5), 0 0 4cqw currentColor; }
.tbh-cat-games:hover .tbh-cat-cta { box-shadow: 0 2cqw 5cqw rgba(0,0,0,.5), 0 0 5cqw rgba(243,145,37,.55); }
.tbh-cat-offline:hover .tbh-cat-cta { box-shadow: 0 2cqw 5cqw rgba(0,0,0,.5), 0 0 5cqw rgba(34,211,238,.55); }
.tbh-cat-software:hover .tbh-cat-cta { box-shadow: 0 2cqw 5cqw rgba(0,0,0,.5), 0 0 5cqw rgba(96,165,250,.55); }
.tbh-cat-gift:hover .tbh-cat-cta { box-shadow: 0 2cqw 5cqw rgba(0,0,0,.5), 0 0 5cqw rgba(25,230,140,.55); }
.tbh-cat:hover .tbh-cat-cta .ico { transform: translateX(-30%); }
.tbh-cat:active .tbh-cat-cta { transform: scale(.97); }
@media (prefers-reduced-motion: reduce) { .tbh-fc img { animation: none; } .tbh-fc, .tbh-cat-cta { transition: none; } }

/* ===== Hero search polish: no orange focus box, cleaner animated results list ===== */
/* styles.css forces an orange outline on every input:focus-visible (!important); the hero field shows focus with a soft border instead */
#tbh-q:focus, #tbh-q:focus-visible { outline: none !important; box-shadow: none !important; }
.tbh-stage .tbh-search:focus-within { border-color: rgba(255,255,255,.32); box-shadow: 0 0 0 4px rgba(255,255,255,.06), 0 18px 40px rgba(0,0,0,.35); }
/* results list: only the Enter hint in the header (on the right), no count, no footer links */
#tbh-search .global-search-dropdown-menu:has(.search-dropdown-item) > div:first-child > span:first-child { display: none; }
#tbh-search .global-search-dropdown-menu:has(.search-dropdown-item) > div:first-child { justify-content: flex-start; }
#tbh-search .global-search-dropdown-menu:has(.search-dropdown-item) > div.border-t { display: none; }
/* open + results animation */
#tbh-search .global-search-dropdown-menu { animation: tbh-dd-in .22s var(--ease); transform-origin: top center; }
#tbh-search .search-dropdown-item { animation: tbh-dd-item .32s var(--ease) both; }
#tbh-search .search-dropdown-item:nth-child(2) { animation-delay: .04s; } #tbh-search .search-dropdown-item:nth-child(3) { animation-delay: .08s; }
#tbh-search .search-dropdown-item:nth-child(4) { animation-delay: .12s; } #tbh-search .search-dropdown-item:nth-child(5) { animation-delay: .16s; }
#tbh-search .search-dropdown-item:nth-child(n+6) { animation-delay: .2s; }
#tbh-search .search-dropdown-item img { transition: transform .25s var(--ease); }
#tbh-search .search-dropdown-item:hover img, #tbh-search .search-dropdown-item.highlighted img { transform: scale(1.06); }
@keyframes tbh-dd-in { from { opacity: 0; transform: translateY(-6px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes tbh-dd-item { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { #tbh-search .global-search-dropdown-menu, #tbh-search .search-dropdown-item { animation: none; } }
/* home rails: no "Store pick" tag on the cards (the All Games page keeps it) */
.tbh-rail .tb-card-tag { display: none; }

/* ===== Category posters: rounded CSS border (follows the corners) that draws itself 0 -> 100% on hover ===== */
@property --tbh-sweep { syntax: '<angle>'; inherits: false; initial-value: 0deg; }
.tbh-cat-games { --acc: 243,145,37; } .tbh-cat-offline { --acc: 34,211,238; } .tbh-cat-software { --acc: 96,165,250; } .tbh-cat-gift { --acc: 25,230,140; }
.tbh-cats .tbh-cat::before, .tbh-cats .tbh-cat::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: 4; }
.tbh-cats .tbh-cat::before { border: 1.5px solid rgba(var(--acc), .32); }
.tbh-cats .tbh-cat::after {
  padding: 2.5px;
  background: conic-gradient(from 0deg, rgb(var(--acc)) 0deg, rgb(var(--acc)) var(--tbh-sweep), transparent var(--tbh-sweep));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
          mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  --tbh-sweep: 0deg; transition: --tbh-sweep .9s cubic-bezier(.45,.05,.25,1); filter: drop-shadow(0 0 6px rgba(var(--acc), .8));
}
.tbh-cats .tbh-cat:hover::after, .tbh-cats .tbh-cat:focus-visible::after { --tbh-sweep: 360deg; }
.tbh-cats .tbh-cat:hover { box-shadow: 0 22px 50px rgba(0,0,0,.5), 0 0 34px rgba(var(--acc), .22); }
@media (prefers-reduced-motion: reduce) { .tbh-cats .tbh-cat::after { transition: none; } }

/* Classic featured-deal slider kept on the new home (owner, 2026-10-06): render it exactly like the old LTR home. */
.tbh-oldhero { text-align: left; }
.tbh-oldhero .icon-directional, [dir="rtl"] .tbh-oldhero .icon-directional { transform: none !important; }   /* styles.css flips them under any RTL parent */
.tbh-hero-classic { padding-block: 24px 8px; }
.tbh-hero-classic #hero-showcase-container { margin-bottom: 18px; }
