:root {
  --bg: #171a28;
  --header: #161a28;
  --card: #212535;
  --orange: #d67414;
  --orange-hover: #e48622;
  --text: #ffffff;
  --muted: #c8ccd8;
  --line: #d67414;
  --max: 1110px;
  --header-h: 66px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
section { scroll-margin-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, Helvetica, Verdana, sans-serif;
  font-size: 16px;
  line-height: 1.35;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button, input, textarea { font-family: inherit; }

.wrapper { min-height: 100vh; }
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 40;
  height: var(--header-h);
  background: var(--header);
}
.header__inner {
  max-width: 1310px;
  height: 100%;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.logo img { height: 46px; width: auto; }
.main-nav__list {
  display: flex;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.main-nav__list a { font-size: 16px; }
.main-nav__list a:hover { color: var(--orange); }
.header-buttons { display: flex; align-items: center; gap: 10px; }
.login-btn, .registr-btn, .main-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  border: 0;
  cursor: pointer;
}
.login-btn {
  height: 40px;
  padding: 0 16px;
  background: #2b2f42;
}
.registr-btn, .main-button {
  background: var(--orange);
  font-weight: 700;
}
.registr-btn { height: 40px; padding: 0 16px; }
.registr-btn:hover, .main-button:hover, .login-btn:hover { background: var(--orange-hover); }
.login-btn:hover { background: #3a3f58; }
.menu-toggle, .burger, .nav-cta { display: none; }

main { padding-top: var(--header-h); }
.entry-content { padding-bottom: 40px; }
.main-section, .best-games, .content-section, .faq, .reviews, .updated-block {
  max-width: var(--max);
  margin: 0 auto;
  padding: 28px 16px 8px;
}
.main-section { text-align: center; padding-top: 28px; }
.main-section__title {
  margin: 0 0 20px;
  font-size: 60px;
  font-weight: 700;
  line-height: 1.05;
}
.hero-banner {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
}
.hero-banner img { width: 100%; border-radius: 12px; }
.lead {
  margin: 22px 0 8px;
  font-size: 17.6px;
  line-height: 1.45;
  text-align: left;
}
.main-button {
  width: 300px;
  max-width: 100%;
  height: 60px;
  margin: 18px auto 10px;
  font-size: 18px;
}

h2 {
  margin: 8px 0 28px;
  font-size: 40px;
  line-height: 1.15;
  text-align: center;
}
h3 {
  margin: 28px 0 8px;
  font-size: 26px;
  line-height: 1.25;
}
p { margin: 16px 0 18px; font-size: 17.6px; line-height: 1.45; color: var(--text); }
.content-section ul, .content-section ol { margin: 8px 0 20px; padding-left: 22px; }
.content-section li { margin: 8px 0; font-size: 17.6px; line-height: 1.45; }

.best-games__nav {
  display: flex;
  gap: 12px;
  list-style: none;
  margin: 0 0 22px;
  padding: 0;
}
.best-games__nav li { flex: 1; }
.best-games__nav a {
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--card);
  border-radius: 6px;
  font-weight: 700;
}
.best-games__nav a svg { fill: #fff; }
.best-games__nav a.active {
  outline: 2px solid var(--orange);
  outline-offset: -2px;
}
.best-games__nav a.active svg { fill: var(--orange); }
.tab { display: none; }
.tab.active { display: block; }
.best-games__list {
  display: flex;
  flex-wrap: wrap;
  margin: 0 -10px;
}
.best-games__item {
  width: calc(25% - 20px);
  margin: 0 10px 22px;
}
button.best-games__item {
  display: block;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.best-games__item-img {
  border-radius: 10px;
  overflow: hidden;
  background: #12141f;
  aspect-ratio: 263 / 156;
}
.pay-grid .best-games__item-img {
  background: #212535;
  border: 1px solid rgba(214, 116, 20, 0.55);
}
.best-games__item-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .35s ease;
}
.best-games__item:hover img { transform: scale(1.06); }
.best-games__item span {
  display: block;
  margin: 10px 0 4px;
  font-size: 18px;
}
.best-games__item small {
  display: block;
  font-size: 14px;
  color: var(--muted);
}

.table-wrap { overflow-x: auto; margin: 8px 0 28px; }
table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
}
th, td {
  background: var(--card);
  border: 1px solid var(--line);
  padding: 16px 22px;
  text-align: left;
  vertical-align: top;
  font-size: 16px;
}
th { font-weight: 700; }
.content-image {
  width: 100%;
  border-radius: 12px;
  margin: 12px 0 8px;
}

.faq__item {
  background: var(--header);
  border: 1px solid var(--orange);
  border-radius: 10px;
  padding: 18px 28px 8px;
  margin: 0 0 10px;
}
.faq__item h3 { margin: 0 0 6px; font-size: 20px; }
.faq__item p { margin-top: 8px; }

.updated-block { display: flex; justify-content: flex-end; }
.updated-block__box {
  background: var(--card);
  border-radius: 8px;
  padding: 10px 16px;
  color: var(--muted);
}

.reviews__box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}
.reviews__box-title { font-size: 18px; font-weight: 700; margin-bottom: 6px; }
.reviews__rate { display: flex; align-items: center; gap: 10px; }
.reviews__rate span { font-size: 28px; font-weight: 700; }
.stars { color: #f5b400; letter-spacing: 2px; font-size: 18px; }
.stars .dim { color: #3a3f55; }
.reviews__button, .load-reviews {
  background: var(--card);
  border-radius: 6px;
  padding: 12px 18px;
  font-weight: 700;
}
.reviews__list { display: flex; flex-wrap: wrap; margin: 0 -10px; }
.reviews__item {
  width: calc(33.333% - 20px);
  margin: 0 10px 16px;
  background: var(--header);
  border-radius: 10px;
  padding: 22px;
}
.reviews__item-user { display: flex; gap: 12px; align-items: center; }
.reviews__item-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--orange);
  display: grid;
  place-items: center;
  font-weight: 700;
}
.reviews__item-box small { color: var(--muted); }
.reviews__item-text p { font-size: 16px; }

.footer { background: var(--header); padding: 64px 0 0; margin-top: 20px; }
.footer__inner {
  max-width: 1110px;
  margin: 0 auto;
  padding: 0 16px 32px;
  display: flex;
  justify-content: space-between;
  gap: 40px;
}
.footer__images { display: flex; gap: 14px; align-items: center; margin-top: 18px; flex-wrap: wrap; }
.footer__images img { height: 42px; width: auto; }
.age-badge {
  width: 42px;
  height: 42px;
  border: 2px solid #fff;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 700;
}
.footer__links { display: flex; gap: 64px; }
.footer-nav__list { list-style: none; margin: 0; padding: 0; }
.footer-nav__list li { margin: 0 0 12px; }
.footer-nav__list button {
  background: none;
  border: 0;
  padding: 0;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
.footer-nav__list button:hover { color: var(--orange); }
.footer__bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 18px 16px 28px;
  text-align: center;
  color: var(--muted);
}
.footer__note {
  max-width: 820px;
  margin: 8px auto 0;
  font-size: 13px;
  line-height: 1.45;
}

.popup { display: none; position: fixed; inset: 0; z-index: 60; }
.popup.open { display: block; }
.popup__overlay { position: absolute; inset: 0; background: rgba(0,0,0,.62); }
.popup__holder {
  position: relative;
  max-width: 460px;
  margin: 12vh auto;
  background: #1c2030;
  border-radius: 12px;
  padding: 24px;
}
.review-popup__title, .review-success__title { font-size: 22px; font-weight: 700; margin-bottom: 14px; }
.review-popup__field span, .review-popup__field small { display: block; }
.review-popup__field small { color: var(--muted); margin: 4px 0 8px; }
.review-popup input, .review-popup textarea {
  width: 100%;
  background: var(--bg);
  color: #fff;
  border: 1px solid #34384c;
  border-radius: 6px;
  padding: 12px;
}
.review-popup textarea { min-height: 110px; resize: vertical; }
.comments-rating { border: 0; margin: 14px 0; padding: 0; }
.rating-container { display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 6px; }
.rating-container input { display: none; }
.rating-container label { cursor: pointer; color: #3a3f55; font-size: 0; }
.rating-container label::before { content: "★"; font-size: 26px; }
.rating-container input:checked ~ label,
.rating-container label:hover,
.rating-container label:hover ~ label { color: #f5b400; }
.review-popup__buttons { display: flex; justify-content: flex-end; gap: 10px; margin-top: 12px; }
.review-popup__cancel, .review-popup__submit {
  padding: 10px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 700;
}
.review-popup__cancel { background: #2b2f42; }
.review-popup__submit { background: var(--orange); }
.hide { display: none; }
.form-error { color: #ff8d8d; min-height: 1.2em; margin: 8px 0 0; font-size: 14px; }

@media (max-width: 980px) {
  .main-section__title { font-size: 40px; }
  h2 { font-size: 30px; }
  .best-games__item { width: calc(50% - 20px); }
  .reviews__item { width: calc(50% - 20px); }
  .footer__inner { flex-direction: column; }
}
@media (max-width: 760px) {
  .burger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 42px;
    height: 42px;
    margin-left: auto;
    cursor: pointer;
  }
  .burger span { display: block; height: 2px; background: #fff; border-radius: 2px; }
  .main-nav {
    display: none;
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    background: var(--header);
    padding: 12px 20px 18px;
    border-bottom: 1px solid rgba(255,255,255,.06);
  }
  .menu-toggle:checked ~ .main-nav { display: block; }
  .main-nav__list { flex-direction: column; gap: 14px; }
  .header-buttons { display: none; }
  .menu-toggle:checked ~ .main-nav .nav-cta { display: flex; gap: 10px; margin-top: 16px; }
  .best-games__nav { flex-wrap: wrap; }
  .best-games__nav li { width: calc(50% - 6px); }
  .best-games__nav a { height: 46px; font-size: 14px; }
  .reviews__box, .reviews__list { display: block; }
  .reviews__item, .best-games__item { width: calc(100% - 20px); }
  .main-section__title { font-size: 34px; }
}
