/* Winita render base — correctness-bearing CSS emitted with every site.
   The LLM "skin" phase layers brand visuals on top of this; it must NOT remove
   these rules. They encode the accessibility / responsive / layout invariants the
   auditors check (container width, footer grid, mobile nav, focus-visible,
   reduced-motion, tap targets, table scroll, fluid grids, 16px body, hero clamp).
   The few non-negotiable a11y rules use !important so a theme can't drop them. */

:root {
  --tap-min: 44px;
  --maxw: 1100px;
  --focus-ring: #0a5ac9;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-size: 16px;
  line-height: 1.6;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

img {
  max-width: 100%;
  height: auto;
}

/* Accessible focus: visible ring for keyboard users only. !important so a brand
   theme can never silently remove the keyboard-focus indicator. */
:focus-visible {
  outline: 2px solid var(--focus-ring) !important;
  outline-offset: 2px !important;
}
:focus:not(:focus-visible) {
  outline: none;
}

/* Respect reduced-motion globally. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* No cross-document View Transitions: the root cross-fade re-ran on every
   internal navigation and read as the whole page "blinking" on each menu click. */

/* Skip-link: hidden until focused. */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  padding: 10px 16px;
  background: var(--focus-ring);
  color: #fff;
  z-index: 1000;
}
.skip-link:focus {
  left: 8px;
  top: 8px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ── Shared content container ──────────────────────────────────────────────
   Header inner, main, and footer inner all align to the same max width so the
   chrome never spills wider than the content column. */
main.page,
.mh-top,
.mh-cats-inner,
.mf-inner {
  max-width: var(--maxw);
  margin-inline: auto;
  width: 100%;
}
main.page {
  padding: 24px 16px;
}

/* ── Header ───────────────────────────────────────────────────────────────── */
header.mh {
  position: sticky;
  top: 0;
  z-index: 50;
}
.mh-top {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 60px;
  padding-inline: 16px;
}
.mh-right {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}
.mh-spacer {
  flex: 1 1 auto;
}
.mh-logo {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
  text-decoration: none;
}
.mh-cats-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  padding-inline: 16px;
  min-width: 0;
}
.mh-cats-inner a {
  /* display + centering are locked: a theme that flips these to inline-block
     leaves the link text top-aligned inside the 44px tap target. Colors,
     padding and radius remain free for the skin to restyle. */
  display: inline-flex !important;
  align-items: center !important;
  min-height: var(--tap-min);
  padding: 0 4px;
  text-decoration: none;
}
.mh-menu-toggle {
  display: none; /* desktop: nav is always visible; shown on mobile (below) */
  width: var(--tap-min);
  height: var(--tap-min);
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  background: none;
  border: 0;
}

/* Tap targets ≥ 44×44 (WCAG 2.5.5) for standalone controls. */
.btn,
summary {
  min-height: var(--tap-min);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* ── Breadcrumbs & related links ─────────────────────────────────────────── */
ol.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
}
nav[aria-label] ul.related {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  list-style: none;
  padding: 0;
}
ul.related a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
}

/* Tables scroll horizontally inside a wrapper instead of stretching the page. */
.tbl-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.tbl-wrap table {
  border-collapse: collapse;
  width: 100%;
}

/* Fluid card grid: minmax(0,1fr) prevents min-content blowout / overflow. */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(0, 1fr));
  gap: 16px;
  list-style: none;
  padding: 0;
}
@media (min-width: 640px) {
  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1100px) {
  .card-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* ── Footer ───────────────────────────────────────────────────────────────── */
.mf-inner {
  padding: 32px 16px;
}
.mf-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 24px;
  min-width: 0;
}
.mf-cols a {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  text-decoration: none;
}
.mf-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: 24px;
}

/* ── Mobile (≤ 860px): collapse nav behind the burger ─────────────────────── */
@media (max-width: 860px) {
  .mh-menu-toggle {
    display: inline-flex;
  }
  nav.mh-cats {
    display: none;
  }
  nav.mh-cats.is-open {
    display: block;
  }
  .mh-cats-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }
  .mh-cats-inner a {
    min-height: 48px;
    padding: 8px 4px;
  }
}

/* Long words (Italian/German) must wrap, not overflow, on small screens. */
@media (max-width: 480px) {
  h1 {
    font-size: 24px;
    line-height: 1.18;
    overflow-wrap: anywhere;
  }
}


/* --- brand theme --- */
:root {
  --brand-bg: #08090D;
  --brand-surface: #14161E;
  --brand-text: #F4F1E8;
  --brand-muted: #9B9AA3;
  --brand-primary: #F5B832;
  --brand-primary-fg: #161006;
  --brand-accent: #D7354E;
  --brand-border: #2A2D38;

  --font-display: "Montserrat", "Arial", sans-serif;
  --font-body: "Inter", "Arial", sans-serif;

  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.375rem;
  --text-2xl: 1.75rem;
  --text-3xl: 2.25rem;
  --text-4xl: 3rem;

  --weight-regular: 400;
  --weight-medium: 500;
  --weight-bold: 700;

  --leading-tight: 1.2;
  --leading-normal: 1.5;
  --leading-relaxed: 1.7;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-12: 3rem;
  --space-16: 4rem;

  --radius-sm: 0.375rem;
  --radius-md: 0.625rem;
  --radius-lg: 0.875rem;
  --radius-full: 999px;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.28);
  --shadow-md: 0 12px 28px rgba(0, 0, 0, 0.34);
  --shadow-lg: 0 24px 56px rgba(0, 0, 0, 0.48);
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 18% 0%, rgba(245, 184, 50, 0.13), transparent 32rem),
    radial-gradient(circle at 88% 8%, rgba(215, 53, 78, 0.12), transparent 28rem),
    var(--brand-bg);
  color: var(--brand-text);
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: var(--weight-regular);
  line-height: var(--leading-normal);
}

h1,
h2,
h3 {
  color: var(--brand-text);
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
  line-height: var(--leading-tight);
  letter-spacing: 0;
}

h1 {
  font-size: clamp(var(--text-3xl), 5vw, var(--text-4xl));
}

h2 {
  font-size: clamp(var(--text-2xl), 3vw, var(--text-3xl));
}

h3 {
  font-size: var(--text-xl);
}

p {
  color: var(--brand-muted);
  line-height: var(--leading-relaxed);
}

a {
  color: var(--brand-primary);
  text-decoration-color: rgba(245, 184, 50, 0.48);
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--brand-text);
  text-decoration-color: var(--brand-primary);
}

.mh {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(8, 9, 13, 0.94);
  border-bottom: 1px solid var(--brand-border);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(16px);
}

.mh-top {
  min-height: 4.5rem;
  padding: 0 var(--space-8);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
}

.mh-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--brand-text);
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: var(--weight-bold);
  letter-spacing: 0;
  text-decoration: none;
}

.mh-logo-img {
  display: block;
  width: clamp(9rem, 18vw, 14rem);
  height: auto;
  aspect-ratio: var(--logo-ratio);
  max-height: 4.25rem;
  background-image: var(--logo-url);
  background-position: left center;
  background-repeat: no-repeat;
  background-size: contain;
}

.mh-logo-img::after {
  content: "Betroom Casino";
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.mh-logo::after {
  content: "";
  color: var(--brand-text);
  font-family: var(--font-display);
  font-size: clamp(1rem, 2vw, 1.35rem);
  font-weight: var(--weight-bold);
  line-height: 1;
  white-space: nowrap;
}

.mh-logo::first-letter {
  color: var(--brand-primary);
}

.mh-cats {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-8);
  overflow-x: auto;
  border-top: 1px solid rgba(42, 45, 56, 0.72);
}

.mh-cats a {
  flex: 0 0 auto;
  padding: var(--space-2) var(--space-4);
  border: 1px solid transparent;
  border-radius: var(--radius-full);
  color: var(--brand-muted);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  text-decoration: none;
}

.mh-cats a:hover {
  border-color: var(--brand-border);
  background: var(--brand-surface);
  color: var(--brand-text);
}

.btn,
.btn-cta,
.btn-primary,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 2.75rem;
  padding: 0.75rem 1.25rem;
  border: 1px solid transparent;
  border-radius: var(--radius-full);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  line-height: 1;
  text-align: center;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
}

.btn,
.btn-primary,
.btn-cta {
  background: linear-gradient(180deg, var(--brand-primary), #d99b1f);
  color: var(--brand-primary-fg);
  border-color: rgba(245, 184, 50, 0.72);
}

.btn:hover,
.btn-primary:hover,
.btn-cta:hover {
  background: var(--brand-text);
  color: var(--brand-primary-fg);
}

.btn-secondary {
  background: var(--brand-surface);
  color: var(--brand-text);
  border-color: var(--brand-border);
}

.btn-secondary:hover {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

.crumbs {
  color: var(--brand-muted);
  font-size: var(--text-sm);
}

.crumbs a {
  color: var(--brand-muted);
  text-decoration: none;
}

.crumbs a:hover {
  color: var(--brand-primary);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr));
  gap: var(--space-4);
}

.card {
  padding: var(--space-4);
  background:
    linear-gradient(180deg, rgba(245, 184, 50, 0.06), transparent 45%),
    var(--brand-surface);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  color: var(--brand-text);
}

.card h2,
.card h3 {
  margin-top: 0;
}

.card p {
  color: var(--brand-muted);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-3);
  border: 1px solid rgba(245, 184, 50, 0.46);
  border-radius: var(--radius-full);
  background: rgba(245, 184, 50, 0.12);
  color: var(--brand-primary);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  line-height: var(--leading-tight);
  text-transform: uppercase;
}

.tbl-wrap {
  overflow-x: auto;
  background: var(--brand-surface);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

table {
  width: 100%;
  border-collapse: collapse;
  color: var(--brand-text);
  font-size: var(--text-sm);
}

th,
td {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--brand-border);
  text-align: left;
}

th {
  background: rgba(245, 184, 50, 0.09);
  color: var(--brand-primary);
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
}

tr:last-child td {
  border-bottom: 0;
}

tbody tr:hover {
  background: rgba(244, 241, 232, 0.04);
}

.related {
  padding: var(--space-6);
  background: rgba(20, 22, 30, 0.72);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.related a {
  color: var(--brand-text);
  font-weight: var(--weight-medium);
  text-decoration: none;
}

.related a:hover {
  color: var(--brand-primary);
}

.mf {
  margin-top: var(--space-16);
  padding: var(--space-12) var(--space-8);
  background: #08090D;
  border-top: 1px solid var(--brand-border);
  color: var(--brand-muted);
}

.mf-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr));
  gap: var(--space-8);
}

.mf a {
  color: var(--brand-muted);
  text-decoration: none;
}

.mf a:hover {
  color: var(--brand-primary);
}

.mf-trust {
  margin-top: var(--space-8);
  padding-top: var(--space-6);
  border-top: 1px solid var(--brand-border);
  color: var(--brand-muted);
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
}

.age-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  min-height: 2.5rem;
  padding: var(--space-2);
  border: 1px solid var(--brand-accent);
  border-radius: var(--radius-full);
  background: rgba(215, 53, 78, 0.14);
  color: var(--brand-text);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
}

@media (max-width: 720px) {
  .mh-top {
    padding: 0 var(--space-4);
  }

  .mh-logo-img {
    width: 8rem;
    height: auto;
    max-height: 3rem;
  }

  .mh-logo {
    gap: 0.5rem;
  }

  .mh-logo::after {
    content: "";
  }

  .mh-cats {
    padding: var(--space-3) var(--space-4);
  }

  .mf {
    padding: var(--space-8) var(--space-4);
  }

  th,
  td {
    padding: var(--space-3);
  }
}

/* Betroom visual polish */
main.page {
  padding-top: clamp(1.25rem, 3vw, 2.5rem);
}

main.page > h1 {
  max-width: 48rem;
  margin: 1rem 0 1.25rem;
  font-size: clamp(2.35rem, 5vw, 4.85rem);
  line-height: 0.98;
}

main.page > h1 + img {
  display: block;
  width: 100%;
  max-height: 34rem;
  margin: 0 0 clamp(2rem, 5vw, 4rem);
  object-fit: cover;
  object-position: center;
  border: 1px solid rgba(245, 184, 50, 0.26);
  border-radius: var(--radius-lg);
  box-shadow: 0 2rem 5rem rgba(0, 0, 0, 0.46);
}

main.page > section {
  margin-top: clamp(2rem, 5vw, 4rem);
  padding-top: clamp(1.5rem, 3vw, 2.5rem);
  border-top: 1px solid rgba(244, 241, 232, 0.08);
}

main.page > section > h2 {
  max-width: 46rem;
  margin-bottom: 1rem;
}

main.page > section > h2::after {
  content: "";
  display: block;
  width: 4.5rem;
  height: 0.18rem;
  margin-top: 0.75rem;
  border-radius: var(--radius-full);
  background: linear-gradient(90deg, var(--brand-primary), var(--brand-accent));
}

.card img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: calc(var(--radius-lg) - 0.2rem);
  border: 1px solid rgba(244, 241, 232, 0.08);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
}

.card-grid:has(.card:only-child) {
  grid-template-columns: 1fr;
}

.card-grid .card:only-child {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(17rem, 0.85fr);
  gap: clamp(1rem, 3vw, 2rem);
  align-items: center;
  padding: clamp(1rem, 3vw, 1.75rem);
}

.card-grid .card:only-child img {
  grid-row: 1 / span 3;
}

.card-title {
  align-self: end;
  margin-bottom: 0;
}

.card-title + .badge {
  justify-self: start;
  align-self: center;
}

.card-grid .card:only-child p {
  align-self: start;
  max-width: 36rem;
}

details {
  background: rgba(20, 22, 30, 0.7);
  border: 1px solid rgba(244, 241, 232, 0.08);
  border-radius: var(--radius-md);
}

details + details {
  margin-top: 0.75rem;
}

summary {
  padding: 1rem 1.125rem;
  cursor: pointer;
  color: var(--brand-text);
  font-weight: var(--weight-bold);
}

details p {
  margin: 0;
  padding: 0 1.125rem 1.125rem;
}

@media (max-width: 760px) {
  main.page > h1 {
    font-size: clamp(2.15rem, 11vw, 3.25rem);
  }

  main.page > h1 + img {
    min-height: 16rem;
  }

  .card-grid .card:only-child {
    grid-template-columns: 1fr;
  }

  .card-grid .card:only-child img {
    grid-row: auto;
  }
}
