:root {
  --font-base: 'Open Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --color-body-bg: #0d0b08;
  --color-surface: #1a1510;
  --color-surface-alt: #2b1212;
  --color-overlay: rgba(255, 0, 0, 0.25);
  --color-border: rgba(255, 60, 60, 0.3);
  --color-text: #f8e7d2;
  --color-text-muted: #cda8a8;
  --color-primary: #ff351a;
  --color-primary-hover: #c71c1c;
  --color-secondary: rgba(255, 0, 0, 0.2);
  --color-badge-exclusive: #ff4600;
  --color-badge-jackpot: #ff5c3f;
  --color-on-primary: #ffffff;
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 8px;
  --shadow-lg: 0 24px 60px rgba(255, 17, 0, 0.25);
  --shadow-card: 0 14px 30px rgba(255, 0, 0, 0.15);
  --transition-base: 0.25s ease;
  --layout-max-width: 1200px;
  --spacing-section: clamp(3rem, 5vw, 5rem);
}

@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600;700&display=swap');

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

html,
body {
  height: 100%;
}

body {
  margin: 0;
  font-family: var(--font-base);
  background: var(--color-body-bg);
  color: var(--color-text);
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;

}

.page-wrapper {
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

.container {
  width: min(100% - 2rem, var(--layout-max-width));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(14, 14, 14, 0.92);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--color-border);
  box-shadow: 0 6px 16px rgba(71, 44, 4, 0.08);
}

.header-inner {
  position: relative;
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 1rem 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.logo img {
  height: 44px;
  width: auto;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-left: auto;
  margin-right: 1rem;
  font-weight: 600;
}

.site-nav a {
  position: relative;
  padding-bottom: 0.25rem;
}

.site-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(201, 149, 26, 0) 0%, rgba(201, 149, 26, 0.8) 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-base);
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  transform: scaleX(1);
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.header-actions {

  display: flex;
  gap: 0.75rem;
}

.header-burger {
  display: none;
    flex-direction: column;
    margin: 0;
  justify-content: center;
  gap: 0.3rem;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-sm);
  background: var(--color-secondary);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color var(--transition-base), transform var(--transition-base);
  margin-left: auto;
}

.header-burger span {
  display: block;
  height: 2px;
  width: 1.4rem;
  margin: 0 auto;
  background: var(--color-text);
  transition: transform var(--transition-base), opacity var(--transition-base);
  border-radius: 999px;
}

.header-burger.is-active {
  background: black;
}

.header-burger.is-active span {
  background: var(--color-on-primary);
}

.header-burger.is-active span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.header-burger.is-active span:nth-child(2) {
  opacity: 0;
}

.header-burger.is-active span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.2rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: background-color var(--transition-base), transform var(--transition-base), color var(--transition-base);
  border: none;
}

.btn.btn-register,
.btn.btn-primary {
  background: var(--color-primary);
      justify-content: center;
  padding-left: 5px;
    font-size: 1rem;
  width: 100px;
  color: var(--color-on-primary);
  box-shadow: var(--shadow-card);
}

.btn.btn-register:hover,
.btn.btn-primary:hover {
  background: var(--color-primary-hover);
  transform: translateY(-1px);
}

.btn.btn-login,
.btn.btn-outline {
  background: transparent;
  color: var(--color-text);
  border: 1px solid rgba(203, 168, 92, 0.35);
}

.btn.btn-login:hover,
.btn.btn-outline:hover {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-on-primary);
  box-shadow: var(--shadow-card);
}

.language-switcher {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.language-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.4rem 0.95rem;
  border-radius: 999px;
  font-size: 0.85rem;
  background: var(--color-secondary);
  transition: background-color var(--transition-base), color var(--transition-base), box-shadow var(--transition-base);
}

.language-item:hover {
  background: rgba(201, 149, 26, 0.18);
  color: var(--color-text);
}

.language-item.is-active {
  background: var(--color-primary);
  color: var(--color-on-primary);
  box-shadow: var(--shadow-card);
  cursor: default;
  pointer-events: none;
}

.hero {
  position: relative;
  overflow: hidden;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  margin-bottom: var(--spacing-section);
  background-size: cover;
  background-position: center;
  min-height: clamp(22rem, 60vw, 32rem);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(155deg, rgba(180, 15, 15, 0.95) 0%, rgba(150, 35, 15, 0.288) 65%, rgba(22, 20, 172, 0.95) 100%);
}

.hero-content {
  position: relative;
  padding: clamp(3rem, 6vw, 5rem) 0;
  max-width: 32rem;
}

.hero-content h1 {
  font-size: clamp(2.2rem, 5vw, 3rem);
  line-height: 1.1;
  margin-bottom: 1rem;
}

.hero-content p {
  font-size: 1.05rem;
  color: var(--color-text-muted);
  margin-bottom: 1.8rem;
}

.games-section {
  padding-block: var(--spacing-section);
}

.games-group + .games-group {
  margin-top: clamp(2rem, 5vw, 3.5rem);
}

.group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.group-header h2 {
  margin: 0;
  font-size: 1.65rem;
  letter-spacing: 0.04em;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
}

.game-card {
  background: linear-gradient(145deg, #000000, #e25502);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.game-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.game-card__image {
  position: relative;
  overflow: hidden;
}

.game-card__image img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 0;
}

.game-card__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: linear-gradient(180deg, rgba(16, 10, 28, 0.05) 0%, rgba(16, 10, 28, 0.75) 100%);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-base);
}

.game-card:hover .game-card__overlay,
.game-card:focus-within .game-card__overlay {
  opacity: 1;
  pointer-events: auto;
}

.game-card__overlay .btn {
  width: min(200px, 80%);
  justify-content: center;
  text-align: center;
}

.game-card__overlay .btn.btn-outline {
  background: rgba(0, 0, 0, 0.55);
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
}

.game-card__overlay .btn.btn-outline:hover {
  background: rgba(0, 0, 0, 0.7);
  border-color: rgba(255, 255, 255, 0.5);
}

.badge {
  position: absolute;
  top: 0.8rem;
  left: 0.8rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  backdrop-filter: blur(6px);
  box-shadow: 0 10px 20px rgba(71, 44, 4, 0.18);
}

.badge + .badge {
  top: 3rem;
}

.badge-exclusive {
  background: rgba(176, 123, 18, 0.92);
  color: var(--color-on-primary);
}

.badge-jackpot {
  background: rgba(227, 180, 63, 0.92);
  color: #3c2606;
}

.game-card__body {
  padding: 1.25rem 1.4rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-height: 120px;
  justify-content: center;
  text-align: center;
}

.game-card__body h3 {
  margin: 0;
  font-size: 1.15rem;
  line-height: 1.3;
  text-align: center;
}

.live-results-section {
  background: linear-gradient(160deg, rgba(0, 0, 0, 0.94), rgba(255, 9, 9, 0.9));
  backdrop-filter: blur(20px);
  padding-block: var(--spacing-section);
}

.live-results-section h2 {
  margin-top: 0;
  margin-bottom: 1.5rem;
  font-size: 1.75rem;
}

.table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  background: rgba(0, 0, 0, 0.92);
  box-shadow: var(--shadow-card);
}

.live-results-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 600px;
}

.live-results-table th,
.live-results-table td {
  padding: 1rem 1.25rem;
  text-align: left;
  border-bottom: 1px solid rgba(203, 168, 92, 0.2);
}

.live-results-table th {
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  color: var(--color-text-muted);
}

.live-results-table tbody tr:hover {
  background: rgba(201, 149, 26, 0.12);
}

.content-section {
  padding-block: var(--spacing-section);
  padding-inline: clamp(1rem, 4vw, 2rem);
}

.content-body {
  width: min(100% - 2rem, var(--layout-max-width));
  margin: 0 auto;
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  padding: clamp(2rem, 4vw, 3rem);
  box-shadow: var(--shadow-card);
}

.content-body h2,
.content-body h3,
.content-body h4 {
  margin-top: 2rem;
    font-size: 2rem;
  margin-bottom: 1rem;
  line-height: 1.3;
}

.content-body p {
  font-size: 1.5rem;
  margin-bottom: 2.5rem;
  color: var(--color-text-muted);
}

.content-body ul,
.content-body ol {
  margin: 1.5rem 0;
  padding-left: 1.5rem;
    font-size: 1.5rem;
  color: var(--color-text-muted);
}

.content-body table {
    font-size: 1.5rem;
  width: 100%;
  border-collapse: collapse;
  margin: 1.75rem 0;
  background: var(--color-surface-alt);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.content-body thead {
  background: rgba(201, 149, 26, 0.12);
}

.content-body th,
.content-body td {
  padding: 0.85rem 1.25rem;
  text-align: left;
  border-bottom: 1px solid rgba(203, 168, 92, 0.2);
  color: var(--color-text-muted);
}

.content-body th {
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: var(--color-text);
}

.content-body tbody tr:hover {
  background: rgba(201, 149, 26, 0.12);
}

.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--color-border);
  background: rgba(0, 0, 0, 0.9);
  box-shadow: 0 -6px 16px rgba(71, 44, 4, 0.08);
}

.footer-inner {
  padding: 1.5rem 0;
  display: flex;
  justify-content: center;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

@media (hover: none) {
  .game-card__overlay {
    opacity: 0;
    pointer-events: none;
  }

  .game-card:active .game-card__overlay,
  .game-card:focus-within .game-card__overlay {
    opacity: 1;
    pointer-events: auto;
    width: auto;
  }
}


/* Responsive adjustments */
@media (max-width: 1024px) {
  .header-inner {
    gap: 1rem;
  }

  .header-burger {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: calc(100% + 0.75rem);
    right: 0;
    left: 0;
    display: none;
    flex-direction: column;
    margin: 0;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    background: rgba(255, 255, 255, 0.95);
    z-index: 15;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
  }

  .site-nav.is-open {
    background-color: black;
    display: flex;
  }

  .site-nav a {
    padding: 0.45rem 0;
  }

  .header-actions {
    margin-left: auto;
  }
}

@media (max-width: 768px) {
  .header-inner {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 0.75rem;
  }

  .logo {
    order: 1;
    justify-self: start;
  }

  .header-burger {
    order: 2;
    margin: 0;
    justify-self: center;
  }

  .header-actions {
    order: 3;
    gap: 0.5rem;
    justify-self: end;
    margin-left: 5px;
  }

  .header-actions .btn {
    padding: 0.45rem 0.85rem;
    font-size: 0.85rem;
  }

  .hero {
    border-radius: 0 0 var(--radius-md) var(--radius-md);
  }

  .games-grid {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  }

  .game-card__body {
    align-items: center;
    text-align: center;
  }

  .game-card__actions {
    justify-content: center;
  }

  .live-results-table {
    min-width: 440px;
  }

  .content-body table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
    border-spacing: 0;
    -webkit-overflow-scrolling: touch;
  }

  .content-body thead,
  .content-body tbody,
  .content-body tr {
    width: max-content;
  }

  .content-body th,
  .content-body td {
    white-space: nowrap;
  }
}

@media (max-width: 540px) {
  .header-inner {
    gap: 0.5rem;
  }

  .header-actions {
    gap: 0.4rem;
  }

  .header-actions .btn {
    padding: 0.4rem 0.7rem;
    font-size: 0.8rem;
  }

  .games-grid {
    grid-template-columns: 1fr;
  }

  .game-card__actions {
    flex-direction: column;
    gap: 0.6rem;
  }

  .game-card__actions .btn {
    width: 100%;
  }

  .game-card__image img {
    height: 200px;
  }

  .content-body {
    padding: 1.75rem;
  }
