/**
 * Godz Casino — header__ (BEM)
 */
.header {
  position: sticky;
  top: 0;
  z-index: 500;
  background: var(--color-bg-primary);
  border-bottom: 1px solid rgba(164, 164, 164, 0.1);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-height);
}

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

.header__nav {
  display: none;
}

.header__nav-list {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2vw, 2rem);
}

.header__nav-link {
  display: inline-block;
  padding: 0.5rem 0;
  color: var(--color-text-body);
  font-weight: var(--fw-medium);
  font-size: var(--fs-body);
  position: relative;
  transition: color var(--transition-base);
}

.header__nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: 0;
  background: var(--color-heading-accent);
  transition: width var(--transition-base);
}

.header__nav-link:hover,
.header__nav-link--active {
  color: var(--color-white);
}

.header__nav-link:hover::after,
.header__nav-link--active::after {
  width: 100%;
}

.header__actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.header__flag {
  display: none;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.header__flag img {
  display: block;
  width: 20px;
  height: 15px;
  object-fit: cover;
}

.header__btn {
  display: none;
  padding-inline: 1.1rem;
  font-size: var(--fs-small);
}

.header__burger {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 8px;
}

.header__burger-line {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--color-white);
  transition: transform var(--transition-base), opacity var(--transition-base);
}

.header__burger[aria-expanded="true"] .header__burger-line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.header__burger[aria-expanded="true"] .header__burger-line:nth-child(2) {
  opacity: 0;
}

.header__burger[aria-expanded="true"] .header__burger-line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (prefers-reduced-motion: reduce) {
  .header__burger-line,
  .header__nav-link,
  .header__nav-link::after {
    transition: none;
  }
}

/* ==== Мобільне меню (flat-список, без дропдаунів) ==== */
.header__mobile-menu {
  display: none;
  position: fixed;
  inset: var(--header-height) 0 0 0;
  background: var(--color-bg-primary);
  overflow-y: auto;
  z-index: 490;
}

.header__mobile-menu[data-open="true"] {
  display: block;
}

.header__mobile-inner {
  padding-block: 1.5rem 2.5rem;
  display: grid;
  gap: 1.75rem;
}

.header__mobile-cta {
  display: grid;
  gap: 0.75rem;
}

.header__mobile-list {
  display: grid;
  gap: 0.25rem;
}

.header__mobile-link {
  display: block;
  padding: 0.9rem 0.25rem;
  font-size: 1.05rem;
  font-weight: var(--fw-medium);
  color: var(--color-text-body);
  border-bottom: 1px solid rgba(164, 164, 164, 0.1);
}

.header__mobile-link--active,
.header__mobile-link:hover {
  color: var(--color-heading-accent);
}

.header__mobile-flag {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-text-body);
  font-size: 1.1rem;
}

.header__mobile-flag img {
  display: block;
  width: 20px;
  height: 15px;
  object-fit: cover;
}

/* ==== Планшети та десктоп (>=768px): повне меню, без бургера ==== */
@media (min-width: 768px) {
  .header__nav {
    display: block;
  }

  .header__flag {
    display: inline-flex;
  }

  .header__btn {
    display: inline-flex;
  }

  .header__burger,
  .header__mobile-menu {
    display: none;
  }
}

@media (min-width: 768px) and (max-width: 1023.98px) {
  .header__btn {
    padding-inline: 0.85rem;
    font-size: 0.78rem;
  }

  .header__nav-list {
    gap: 1rem;
  }
}
