/**
 * Bizzo Casino — Global styles
 * Loaded after tokens.css and reset.css.
 */

body {
  background-color: var(--color-bg-primary);
  color: var(--color-text-main);
  font-family: var(--font-family-base);
  font-weight: var(--font-weight-regular);
  font-size: var(--font-size-body);
}

.container {
  max-width: var(--container-max-width);
  margin-inline: auto;
  padding-inline: var(--container-padding-inline);
}

main {
  display: block;
}

h1,
h2,
h3 {
  color: var(--color-white);
  font-weight: var(--font-weight-bold);
  line-height: 1.25;
}

h1 {
  font-size: var(--font-size-h1);
  font-weight: var(--font-weight-extrabold);
}

h2 {
  font-size: var(--font-size-h2);
  color: var(--color-heading-gold);
  margin-block-end: var(--space-h2-text);
  position: relative;
}

h3 {
  font-size: var(--font-size-h3);
  color: var(--color-white);
  margin-block-end: var(--space-h3-text);
}

p {
  margin-block-end: var(--space-paragraph);
}

p:last-child {
  margin-block-end: 0;
}

a {
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-heading-gold);
}

/* Focus visibility — never remove outline */
:focus-visible {
  outline: 3px solid var(--color-heading-gold);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: var(--color-heading-gold);
  color: var(--color-btn-text-dark);
  padding: 12px 20px;
  z-index: 1000;
  font-weight: var(--font-weight-semibold);
  border-radius: 0 0 var(--radius-card) 0;
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 0;
}

/* Sections */
.section {
  padding-block: var(--space-section);
}

.section--dark {
  background-color: var(--color-bg-dark);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-card);
  font-weight: var(--font-weight-semibold);
  font-size: var(--font-size-body);
  transition: transform var(--transition-fast), filter var(--transition-fast), background var(--transition-fast);
  cursor: pointer;
  white-space: nowrap;
}

.btn--primary {
  background: var(--color-btn-accent);
  color: var(--color-btn-text-dark);
  border: none;
}

.btn--primary:hover,
.btn--primary:focus-visible {
  filter: brightness(1.08);
  color: var(--color-btn-text-dark);
}

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

.btn--secondary:hover,
.btn--secondary:focus-visible {
  background: var(--color-btn-secondary-border);
  color: var(--color-white);
}

.btn--register {
  background: var(--color-neon-green);
  color: var(--color-btn-text-dark);
  border: none;
}

.btn--register:hover,
.btn--register:focus-visible {
  filter: brightness(1.1);
  color: var(--color-btn-text-dark);
}

.btn--block {
  width: 100%;
}

/* Cards */
.card {
  background-color: var(--color-card-bg);
  border-radius: var(--radius-card);
  padding: var(--space-card-padding);
  border: var(--border-card);
}

/* Data / characteristics tables */
.data-table {
  width: 100%;
  border-radius: var(--radius-card);
  overflow: hidden;
  background-color: var(--color-card-bg);
}

/* Narrow screens: if a table's natural column widths need more room than
   the viewport, let the TABLE scroll horizontally within its own box
   instead of the whole page growing wider than the viewport. */
@media (max-width: 767px) {
  .data-table {
    display: block;
    width: auto;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

.data-table caption {
  text-align: left;
  color: var(--color-white);
  font-weight: var(--font-weight-semibold);
  margin-block-end: 12px;
  font-size: var(--font-size-h3);
}

.data-table th,
.data-table td {
  text-align: left;
  vertical-align: top;
  padding: 14px 20px;
  font-size: var(--font-size-small);
  border-bottom: 1px solid rgba(241, 244, 244, 0.08);
}

.data-table th {
  color: var(--color-heading-gold);
  font-weight: var(--font-weight-semibold);
}

/* Simple 2-column "label → value" tables (th scope="row" per row, no <thead>):
   give the label column a fixed share so it doesn't get squeezed by long values. */
.data-table th[scope="row"] {
  width: 40%;
}

/* Multi-column comparison tables (<thead> with th scope="col") are left
   without a forced width so the browser's table auto-layout can size each
   column from its own content across every row — the column with the
   longest text naturally gets more room instead of being squeezed into
   whatever the first column's fixed width left over. */

.data-table td {
  color: var(--color-text-main);
}

.data-table tr:last-child th,
.data-table tr:last-child td {
  border-bottom: none;
}

/* Breadcrumb */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: var(--font-size-small);
  color: var(--color-text-main);
  margin-block-end: 16px;
}

.breadcrumb a {
  color: var(--color-text-main);
}

.breadcrumb a:hover {
  color: var(--color-heading-gold);
}

.breadcrumb__current {
  color: var(--color-white);
}

/* Content section media placement */
.content-block__media {
  order: -1;
  margin-block: var(--space-h2-text);
  border-radius: var(--radius-card);
  overflow: hidden;
}

.content-block__media img {
  /* Full width of the text block, own natural aspect ratio — never cropped. */
  display: block;
  width: 100%;
  height: auto;
}

@media (min-width: 1441px) {
  .content-block__media {
    /* Image now sits after the text/CTA instead of before it — keep the
       same margin-block on both sides so there's still breathing room
       above it (previously zeroed out, which left it touching the CTA). */
    order: 1;
  }
}

/* Grid helpers */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-card-gap);
}

.grid-4 {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-card-gap);
}

@media (min-width: 480px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 768px) {
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .grid-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Visually hidden (screen-reader only) */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Fade-in animation hook (used by js/animations.js) */
.fade-in {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 600ms ease, transform 600ms ease;
}

.fade-in.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .fade-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
