:root{--qa-guard:start}

:where(main :is([class*="grid"], [style*="grid"], [class*="layout"], .row, [class*="cols"], [class*="split"], [class*="columns"],
               [data-component], ol, ul, dl) > *) { min-width: 0; }
:where(main img, main video, main iframe) { max-width: 100%; }
:where(main img) { height: auto; }
:where(main pre) { overflow-x: auto; }
:where(main table) { max-width: 100%; }
:where(h1, h2, h3, h4, h5, h6) { line-height: 1.3; }
:where(footer a:not([class*="btn"]), .breadcrumb a, nav li a) { display: inline-block; padding-block: 4px; }
img[data-role="hero"] { object-position: 75% 30% !important; } 
.navbar-brand:has(> img.site-logo) { background: none !important; padding: 0 !important; box-shadow: none !important; border: 0 !important; }
.navbar-brand > img.site-logo { height: 40px; width: auto; display: block; }

.navbar:has(> div:empty):has(> :is([class*="container"], [class*="inner"])) { flex-direction: column; align-items: stretch; }
.navbar .navbar-brand { flex-shrink: 0; }
@media (min-width: 576px) {  
  .navbar :is(a, button)[class*="btn"] { flex-shrink: 0; }
  .navbar :is(.nav-link, a[class*="btn"], button[class*="btn"]) { white-space: nowrap; }
}

:is(.navbar, .navbar > *, .navbar :has(> .navbar-collapse)):has(.navbar-collapse:is(.show, .collapsing)) { height: auto !important; max-height: none !important; }

@media (min-width: 992px) {
  main .row > [class*="col"]:has(> img[data-role="section"]:only-child) { align-self: stretch; }
  main .row > [class*="col"] > img[data-role="section"]:only-child { height: 100% !important; object-fit: cover; }
}

main > :is(section, div):not(:first-child):not(:empty, [class*="divider"], [class*="separator"], [aria-hidden="true"]) { padding-block: clamp(28px, 3.5vw, 44px) !important; margin-block: 0 !important; }
main > :first-child, main > :first-child > :is(section, div) { min-height: 0 !important; }
main > :first-child { padding-block: clamp(24px, 4vw, 56px) !important; }
main :is(h1, h2, h3) { line-height: 1.35 !important; }
main :is(p, li, td, dd) { line-height: 1.55 !important; }
main > :is(section, div) :is(h2):first-of-type { margin-bottom: 12px; }
@media (max-width: 575.98px) {
  main [style*="grid-template-columns"]:not([style*="auto-fit"]):not([style*="auto-fill"]) { grid-template-columns: 1fr !important; }
  
  :is([data-component="game-grid"], [data-component="game-grid"] *):has(> .game-card) {
    display: grid !important; grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 12px !important; }
  .game-card .game-tag { position: static !important; display: inline-block; margin-top: 6px; }
  
  main :is(div, p, nav):has(> :is(a, button)[class*="btn"]):not([class*="scroll"], [class*="strip"], [class*="tab"], [class*="chip"]) {
    flex-wrap: wrap !important; flex-shrink: 1 !important; max-width: 100%; }
  main div:has(> :is(div, p) > :is(a, button)[class*="btn"]):not([class*="scroll"], [class*="strip"], [class*="tab"], [class*="chip"]) {
    flex-wrap: wrap !important; }  
  
  main :is(ol, ul, [data-component="steps"], [data-component="steps"] div):not([class*="scroll"], [class*="strip"], [class*="tab"], [class*="chip"]) {
    flex-wrap: wrap !important; }
  main :is(a, button)[class*="btn"] { white-space: normal !important; }
  
  main table:not(:is([class*="responsive"], [class*="scroll"], [style*="overflow"]) table) {
    display: block; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .game-card :is(.game-card-body, div:has(> h3)) { padding: 10px 12px 12px !important; }
}
.toc-auto { margin: 0 auto 24px; max-width: 1100px; padding: 12px 16px; border: 1px solid var(--border, rgba(255,255,255,.15)); border-radius: 12px; }
.toc-auto summary { cursor: pointer; font-weight: 700; min-height: 44px; display: flex; align-items: center; }
.toc-auto ol { margin: 8px 0 0; padding-left: 1.4em; }
[data-component="toc"] a { display: inline-block; padding-block: 4px; }
html { scroll-padding-top: 88px; }

:is(header, footer, main > :not(:first-child)) :is(.container, .container-fluid, .container-sm, .container-md, .container-lg, .container-xl, .container-xxl) {
  max-width: 1320px !important; margin-inline: auto !important; }
main > :not(:has([class*="container"])) { padding-inline: max(16px, calc((100% - 1320px) / 2)) !important; }  

:where(main > :first-child > :not([class*="container"], :has([class*="container"]), img, picture, video, [style*="absolute"])) {
  padding-inline: max(16px, calc((100% - 1320px) / 2)); }
main > :first-child :is(.container, .container-fluid, .container-sm, .container-md, .container-lg, .container-xl, .container-xxl):not(:has(> img[data-role="hero"])) {
  max-width: 1320px !important; margin-inline: auto !important; }
:where(main [style*="overflow-x"][style*="flex"]:not([style*="wrap"])) > * { min-width: auto; }

:where(main > :not(:first-child), body > footer) { content-visibility: auto; contain-intrinsic-size: auto 600px; }
@media (max-width: 767.98px) { :where(main > :not(:first-child), body > footer) { contain-intrinsic-size: auto 900px; } }  
:root{--qa-guard:end}

:root {
  --color-bg: #f3eff2;
  --color-surface: #fbfafb;
  --color-surface-alt: #e9e5e8;
  --color-primary: #a78215;
  --color-primary-text: #1a1a1a;
  --color-accent: #b4276b;
  --color-text: #2d2d2d;
  --color-text-muted: #666666;
  --color-border: #bb9128;
  --color-nav: #514246;
  --color-nav-dark: #392e31;
  --color-surface-light: #fffaeb;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  scroll-behavior: smooth;
}

body {
  font-family: 'Poppins', sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' seed='2' /%3E%3C/filter%3E%3Crect width='100' height='100' fill='%23000' filter='url(%23noise)' opacity='0.08'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: -1;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Righteous', sans-serif;
  font-weight: 700;
  line-height: 1.35;
  color: var(--color-primary-text);
}

h1 {
  font-size: clamp(2rem, 3.5vw, 3.5rem);
}

h2 {
  font-size: clamp(1.75rem, 2.5vw, 2.5rem);
  margin-bottom: 1.5rem;
}

h3 {
  font-size: 1.5rem;
}

p {
  margin-bottom: 1rem;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color 0.3s ease-out;
}

a:hover {
  color: var(--color-border);
}

::selection {
  background-color: var(--color-primary);
  color: white;
}

header {
  background-color: var(--color-nav);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.navbar {
  padding: 0.75rem 1.5rem;
  height: 72px;
  display: flex;
  align-items: center;
}

.navbar-brand {
  margin-right: auto;
}

.navbar-brand img {
  height: 48px;
  width: auto;
}

.navbar-nav {
  flex-direction: row;
  gap: 0.5rem;
}

.nav-link {
  color: #fbfafb !important;
  font-size: 16px;
  font-weight: 400;
  padding: 0.5rem 1rem !important;
  transition: color 0.3s ease-out;
}

.nav-link:hover {
  color: var(--color-border) !important;
}

.nav-link.active {
  color: var(--color-border) !important;
  font-weight: 600;
}

.navbar-toggler {
  border-color: rgba(251, 250, 251, 0.5);
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(251, 250, 251, 0.75)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.btn {
  border-radius: 999px;
  padding: 0.75rem 2rem;
  font-size: 16px;
  font-weight: 600;
  font-family: 'Poppins', sans-serif;
  transition: all 0.3s ease-out;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  border: none;
}

.btn:focus-visible {
  outline: 2px solid var(--color-border);
  outline-offset: 2px;
}

.btn-primary {
  background-color: var(--color-primary);
  color: #fbfafb;
  box-shadow: 0 4px 12px rgba(167, 130, 21, 0.2);
}

.btn-primary:hover {
  background-color: #8b6b0f;
  box-shadow: 0 8px 24px rgba(167, 130, 21, 0.3);
  transform: translateY(-2px);
}

.btn-secondary {
  background-color: transparent;
  color: var(--color-nav);
  border: 2px solid var(--color-nav);
}

.btn-secondary:hover {
  background-color: var(--color-bg);
  border-color: var(--color-nav);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

main {
  min-height: calc(100vh - 200px);
}

main > section {
  padding: clamp(28px, 3.5vw, 44px) 0;
}

.container, .container-xl {
  max-width: 1200px;
}

.card {
  background-color: var(--color-surface);
  border: none;
  border-radius: 32px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease-out;
  overflow: hidden;
}

.card:hover {
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.12);
  transform: translateY(-4px);
}

.game-card {
  display: block;
  background-color: var(--color-surface);
  border-radius: 24px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease-out;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
  position: relative;
}

.game-card:hover {
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.12);
  transform: translateY(-4px);
}

.game-card img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 24px 24px 0 0;
}

.game-card .game-info {
  padding: 1rem;
}

.game-card h3 {
  font-size: 1.125rem;
  margin: 0.5rem 0;
  color: var(--color-primary-text);
}

.game-card p {
  font-size: 14px;
  color: var(--color-text-muted);
  margin: 0;
}

.game-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  background-color: var(--color-bg);
  border: 1px solid var(--color-border);
  color: var(--color-primary);
  padding: 4px 12px;
  border-radius: 6px;
  margin-top: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

input, textarea, select {
  font-family: 'Poppins', sans-serif;
  border-radius: 12px;
  border: 1px solid var(--color-surface-alt);
  padding: 0.75rem 1rem;
  font-size: 16px;
  color: var(--color-text);
  transition: all 0.3s ease-out;
}

input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(167, 130, 21, 0.1);
}

footer {
  background-color: var(--color-nav-dark);
  color: #fbfafb;
  padding: clamp(28px, 3.5vw, 44px) 0;
  margin-top: auto;
}

footer h5 {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-border);
  margin-bottom: 1rem;
  font-family: 'Poppins', sans-serif;
}

footer a {
  color: #fbfafb;
  font-size: 14px;
}

footer a:hover {
  color: var(--color-primary);
}

footer ul {
  list-style: none;
  padding: 0;
}

footer li {
  margin-bottom: 0.5rem;
}

@media (max-width: 768px) {
  .navbar {
    padding: 0.5rem 1rem;
    height: auto;
  }

  .navbar-brand img {
    height: 36px;
  }

  h1 {
    font-size: clamp(1.5rem, 5vw, 2.5rem);
  }

  h2 {
    font-size: clamp(1.25rem, 4vw, 1.75rem);
  }

  .btn {
    padding: 0.6rem 1.5rem;
    font-size: 14px;
    min-height: 44px;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.text-center {
  text-align: center;
}

.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mt-5 { margin-top: 3rem; }

.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-5 { margin-bottom: 3rem; }

.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 1rem; padding-bottom: 1rem; }
.py-4 { padding-top: 1.5rem; padding-bottom: 1.5rem; }

.px-3 { padding-left: 1rem; padding-right: 1rem; }
.px-4 { padding-left: 1.5rem; padding-right: 1.5rem; }

.text-muted {
  color: var(--color-text-muted);
}

.badge-custom {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 12px;
  font-weight: 600;
  background-color: var(--color-surface);
  padding: 0.5rem 0.75rem;
  border-radius: 20px;
  color: var(--color-text);
}
