/* 666 game - Main Stylesheet
   All classes prefixed with g991-
   Dark gold theme - Mobile first, max-width 430px
   Code comments in English */

:root {
  --g991-primary: #FF8C00;
  --g991-bg: #0A0A0A;
  --g991-text: #FFD700;
  --g991-accent: #FFA500;
  --g991-secondary: #D4AF37;
  --g991-white: #FFF8E7;
  --g991-dark: #1A1A1A;
  --g991-gray: #888888;
  --g991-border: #333333;
  --g991-radius: 8px;
}

html {
  font-size: 62.5%;
  scroll-behavior: smooth;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--g991-bg);
  color: var(--g991-white);
  line-height: 1.5rem;
  max-width: 430px;
  margin: 0 auto;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* === HEADER === */
.g991-header {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px;
  height: 56px;
  background: linear-gradient(180deg, #1A1A1A 0%, #0A0A0A 100%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.2rem;
  z-index: 1000;
  border-bottom: 1px solid var(--g991-border);
}

.g991-logo-wrap {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  text-decoration: none;
}

.g991-logo-wrap img {
  width: 28px;
  height: 28px;
  border-radius: 4px;
}

.g991-logo-wrap span {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--g991-text);
  letter-spacing: 0.5px;
}

.g991-header-actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.g991-header-actions button {
  padding: 0.5rem 1.2rem;
  border: none;
  border-radius: 20px;
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, opacity 0.2s;
}

.g991-header-actions button:active {
  transform: scale(0.95);
}

.g991-btn-register {
  background: linear-gradient(135deg, var(--g991-primary), var(--g991-accent));
  color: #000;
}

.g991-btn-login {
  background: transparent;
  color: var(--g991-text);
  border: 1px solid var(--g991-secondary) !important;
}

.g991-hamburger {
  background: none;
  border: none;
  color: var(--g991-text);
  font-size: 2rem;
  cursor: pointer;
  padding: 0.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* === MOBILE MENU === */
.g991-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 9998;
}

.g991-mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 75%;
  max-width: 300px;
  height: 100%;
  background: #111;
  z-index: 9999;
  transform: translateX(-100%);
  transition: transform 0.3s ease;
  overflow-y: auto;
  padding: 2rem 1.6rem;
}

.g991-mobile-menu h3 {
  font-size: 1.4rem;
  color: var(--g991-secondary);
  margin: 1.6rem 0 0.8rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--g991-border);
}

.g991-mobile-menu a {
  display: block;
  color: var(--g991-white);
  text-decoration: none;
  font-size: 1.3rem;
  padding: 0.6rem 0;
  transition: color 0.2s;
}

.g991-mobile-menu a:hover {
  color: var(--g991-accent);
}

/* === MAIN CONTENT === */
.g991-main {
  padding-top: 56px;
  min-height: 100vh;
}

@media (max-width: 768px) {
  .g991-main {
    padding-bottom: 80px;
  }
}

/* === CAROUSEL === */
.g991-carousel {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: 0 0 var(--g991-radius) var(--g991-radius);
}

.g991-slide {
  display: none;
  width: 100%;
  cursor: pointer;
}

.g991-slide.g991-active {
  display: block;
}

.g991-slide img {
  width: 100%;
  height: auto;
  display: block;
}

.g991-dots {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 5;
}

.g991-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 215, 0, 0.4);
  cursor: pointer;
  transition: background 0.3s;
}

.g991-dot-active {
  background: var(--g991-text);
  transform: scale(1.2);
}

/* === SECTIONS === */
.g991-section {
  padding: 1.6rem 1.2rem;
}

.g991-section-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--g991-text);
  margin-bottom: 1.2rem;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--g991-secondary);
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.g991-section-title i {
  color: var(--g991-primary);
  font-size: 2rem;
}

/* === GAME GRID === */
.g991-game-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.8rem;
}

.g991-game-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
  transition: transform 0.2s;
  text-align: center;
}

.g991-game-item:active {
  transform: scale(0.95);
}

.g991-game-item img {
  width: 70px;
  height: 70px;
  border-radius: var(--g991-radius);
  object-fit: cover;
  border: 2px solid var(--g991-border);
  transition: border-color 0.2s;
}

.g991-game-item:hover img {
  border-color: var(--g991-primary);
}

.g991-game-item span {
  font-size: 1.1rem;
  color: var(--g991-white);
  margin-top: 0.4rem;
  line-height: 1.3rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* === CATEGORY TABS === */
.g991-category-label {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--g991-accent);
  margin: 1.6rem 0 1rem;
  padding-left: 0.8rem;
  border-left: 3px solid var(--g991-primary);
}

/* === CARDS === */
.g991-card {
  background: var(--g991-dark);
  border: 1px solid var(--g991-border);
  border-radius: var(--g991-radius);
  padding: 1.4rem;
  margin-bottom: 1.2rem;
}

.g991-card h2 {
  font-size: 1.6rem;
  color: var(--g991-text);
  margin-bottom: 0.8rem;
}

.g991-card h3 {
  font-size: 1.4rem;
  color: var(--g991-accent);
  margin-bottom: 0.6rem;
}

.g991-card p {
  font-size: 1.3rem;
  color: #ccc;
  line-height: 1.8rem;
  margin-bottom: 0.8rem;
}

/* === BUTTONS === */
.g991-promo-btn {
  display: inline-block;
  background: linear-gradient(135deg, var(--g991-primary), var(--g991-accent));
  color: #000;
  font-weight: 700;
  font-size: 1.3rem;
  padding: 0.8rem 2rem;
  border-radius: 25px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}

.g991-promo-btn:hover {
  box-shadow: 0 4px 15px rgba(255, 140, 0, 0.4);
}

.g991-promo-btn:active {
  transform: scale(0.95);
}

.g991-promo-link {
  color: var(--g991-accent);
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border-bottom: 1px dashed var(--g991-accent);
}

.g991-promo-link:hover {
  color: var(--g991-text);
}

/* === FOOTER === */
.g991-footer {
  background: #0D0D0D;
  padding: 2rem 1.2rem;
  border-top: 1px solid var(--g991-border);
}

.g991-footer-brand {
  font-size: 1.3rem;
  color: #aaa;
  line-height: 1.8rem;
  margin-bottom: 1.4rem;
}

.g991-footer-promos {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1.4rem;
}

.g991-footer-promos button {
  flex: 1;
  min-width: 120px;
  padding: 0.7rem;
  background: linear-gradient(135deg, var(--g991-primary), var(--g991-secondary));
  color: #000;
  border: none;
  border-radius: 6px;
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
}

.g991-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-bottom: 1.4rem;
}

.g991-footer-links a {
  color: var(--g991-gray);
  text-decoration: none;
  font-size: 1.2rem;
  transition: color 0.2s;
}

.g991-footer-links a:hover {
  color: var(--g991-accent);
}

.g991-footer-copy {
  font-size: 1.1rem;
  color: #555;
  text-align: center;
  padding-top: 1rem;
  border-top: 1px solid #222;
}

/* === BOTTOM NAV === */
.g991-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px;
  height: 60px;
  background: linear-gradient(180deg, #1A1A1A, #0A0A0A);
  border-top: 1px solid var(--g991-border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 1000;
}

.g991-bottom-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 60px;
  min-height: 56px;
  background: none;
  border: none;
  color: #888;
  cursor: pointer;
  transition: color 0.2s, transform 0.2s;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

.g991-bottom-btn:active {
  transform: scale(0.9);
}

.g991-bottom-btn .g991-bnav-icon {
  font-size: 22px;
  margin-bottom: 2px;
}

.g991-bottom-btn .g991-bnav-label {
  font-size: 1rem;
  font-weight: 500;
}

.g991-bottom-active {
  color: var(--g991-primary) !important;
}

.g991-bottom-active .g991-bnav-label {
  color: var(--g991-primary);
}

@media (min-width: 769px) {
  .g991-bottom-nav {
    display: none;
  }
}

/* === MISC === */
.g991-text-center { text-align: center; }
.g991-mt-1 { margin-top: 1rem; }
.g991-mt-2 { margin-top: 2rem; }
.g991-mb-1 { margin-bottom: 1rem; }
.g991-mb-2 { margin-bottom: 2rem; }

.g991-faq-item {
  margin-bottom: 1rem;
}

.g991-faq-item h3 {
  font-size: 1.3rem;
  color: var(--g991-text);
  margin-bottom: 0.4rem;
}

.g991-faq-item p {
  font-size: 1.2rem;
  color: #bbb;
  line-height: 1.7rem;
}

.g991-winner-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.8rem;
  background: var(--g991-dark);
  border-radius: 6px;
  margin-bottom: 0.6rem;
}

.g991-winner-item span:first-child {
  font-size: 1.2rem;
  color: var(--g991-gray);
  flex: 1;
}

.g991-winner-item span:last-child {
  font-size: 1.3rem;
  color: var(--g991-text);
  font-weight: 600;
}

.g991-payment-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  justify-content: center;
}

.g991-payment-item {
  background: var(--g991-dark);
  border: 1px solid var(--g991-border);
  border-radius: 6px;
  padding: 0.6rem 1.2rem;
  font-size: 1.2rem;
  color: var(--g991-white);
}

.g991-download-box {
  text-align: center;
  padding: 2rem 1rem;
  background: linear-gradient(135deg, #1A1A1A, #0A0A0A);
  border: 1px solid var(--g991-secondary);
  border-radius: var(--g991-radius);
}

.g991-download-box h3 {
  font-size: 1.6rem;
  color: var(--g991-text);
  margin-bottom: 0.8rem;
}

.g991-download-box p {
  font-size: 1.2rem;
  color: #aaa;
  margin-bottom: 1.2rem;
}

/* Review stars */
.g991-stars {
  color: var(--g991-text);
  font-size: 1.4rem;
  margin-bottom: 0.4rem;
}

/* Internal link style */
.g991-internal-link {
  color: var(--g991-accent);
  text-decoration: underline;
  font-size: 1.3rem;
}

.g991-internal-link:hover {
  color: var(--g991-text);
}
