/* Legends Casino App - Theme Stylesheet
   All custom classes use the sd41- prefix
   Mobile-first design, max-width 430px, root font 62.5% */

:root {
  --sd41-primary: #40E0D0;
  --sd41-accent: #AD1457;
  --sd41-bg: #0C0C0C;
  --sd41-text-light: #FFFFBA;
  --sd41-text-muted: #E5E5E5;
  --sd41-card-bg: #1a1a1a;
  --sd41-card-border: #2a2a2a;
  --sd41-gradient: linear-gradient(135deg, #40E0D0 0%, #AD1457 100%);
  --sd41-header-bg: rgba(12, 12, 12, 0.96);
  --sd41-shadow: 0 0.4rem 1.2rem rgba(0, 0, 0, 0.5);
  --sd41-radius: 1.2rem;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 62.5%; scroll-behavior: smooth; }
body {
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  background: var(--sd41-bg);
  color: var(--sd41-text-muted);
  line-height: 1.5rem;
  font-size: 1.4rem;
  max-width: 430px;
  margin: 0 auto;
  position: relative;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--sd41-primary); text-decoration: none; }

/* ===== Header ===== */
.sd41-header {
  position: fixed; top: 0; left: 0; right: 0;
  max-width: 430px; margin: 0 auto;
  background: var(--sd41-header-bg);
  border-bottom: 0.2rem solid var(--sd41-primary);
  z-index: 1000;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.8rem 1rem; height: 6rem;
  box-shadow: var(--sd41-shadow);
}
.sd41-logo { display: flex; align-items: center; gap: 0.6rem; }
.sd41-logo img { width: 2.8rem; height: 2.8rem; border-radius: 0.6rem; }
.sd41-logo-text { font-size: 1.5rem; font-weight: 700; color: var(--sd41-text-light); white-space: nowrap; }
.sd41-header-actions { display: flex; align-items: center; gap: 0.6rem; }
.sd41-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
  min-height: 3.6rem; padding: 0 1.2rem;
  border-radius: 2rem; font-size: 1.3rem; font-weight: 600;
  border: none; cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.sd41-btn:active { transform: scale(0.95); }
.sd41-btn-register { background: var(--sd41-gradient); color: #fff; }
.sd41-btn-login { background: transparent; color: var(--sd41-primary); border: 0.15rem solid var(--sd41-primary); }
.sd41-menu-btn {
  background: transparent; color: var(--sd41-primary); border: none;
  font-size: 2rem; cursor: pointer;
  min-width: 4.4rem; min-height: 4.4rem;
  display: flex; align-items: center; justify-content: center;
}

/* ===== Mobile Menu ===== */
.sd41-mobile-menu {
  position: fixed; top: 6rem; left: 0; right: 0;
  max-width: 430px; margin: 0 auto;
  background: var(--sd41-header-bg);
  border-bottom: 0.2rem solid var(--sd41-accent);
  z-index: 9999; max-height: 0; overflow: hidden;
  transition: max-height 0.3s ease;
}
.sd41-mobile-menu.sd41-menu-open { max-height: 60rem; }
.sd41-mobile-menu ul { list-style: none; padding: 1rem; }
.sd41-mobile-menu li { border-bottom: 0.1rem solid #222; }
.sd41-mobile-menu li:last-child { border-bottom: none; }
.sd41-mobile-menu a {
  display: flex; align-items: center; gap: 0.8rem;
  padding: 1.2rem 1rem; color: var(--sd41-text-light);
  font-size: 1.4rem; min-height: 4.4rem;
}
.sd41-mobile-menu a:active { background: rgba(64, 224, 208, 0.12); }

/* ===== Main / Sections ===== */
.sd41-main { padding-top: 6rem; padding-bottom: 8rem; }
.sd41-section { padding: 2rem 1.2rem; }
.sd41-section h1 { color: var(--sd41-text-light); font-size: 1.8rem; margin-bottom: 1rem; line-height: 2.4rem; }
.sd41-section h2 {
  color: var(--sd41-text-light); font-size: 1.8rem; margin-bottom: 1rem;
  border-left: 0.3rem solid var(--sd41-primary); padding-left: 0.8rem;
}
.sd41-section h3 { color: var(--sd41-primary); font-size: 1.5rem; margin: 1rem 0 0.6rem; }
.sd41-section p { margin-bottom: 0.8rem; color: var(--sd41-text-muted); }

/* ===== Carousel ===== */
.sd41-carousel {
  position: relative; width: 100%; height: 18rem;
  overflow: hidden; border-radius: var(--sd41-radius); margin-bottom: 1.5rem;
}
.sd41-slide {
  position: absolute; inset: 0; opacity: 0;
  transition: opacity 600ms ease; cursor: pointer;
}
.sd41-slide.sd41-slide-active { opacity: 1; }
.sd41-slide img { width: 100%; height: 100%; object-fit: cover; }
.sd41-slide-overlay {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.85));
  padding: 1.2rem; color: var(--sd41-text-light);
}
.sd41-slide-overlay strong { font-size: 1.6rem; display: block; margin-bottom: 0.3rem; }
.sd41-dots { position: absolute; bottom: 0.8rem; right: 1rem; display: flex; gap: 0.4rem; }
.sd41-dot { width: 0.8rem; height: 0.8rem; border-radius: 50%; background: rgba(255,255,255,0.4); border: none; cursor: pointer; }
.sd41-dot.sd41-dot-active { background: var(--sd41-primary); }

/* ===== Game Grid ===== */
.sd41-game-section { margin-bottom: 1.5rem; }
.sd41-game-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.8rem; }
.sd41-game-card {
  background: var(--sd41-card-bg);
  border: 0.1rem solid var(--sd41-card-border);
  border-radius: 0.8rem; overflow: hidden; cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease;
  text-align: center;
}
.sd41-game-card:active { transform: scale(0.96); border-color: var(--sd41-primary); }
.sd41-game-card img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.sd41-game-card .sd41-game-name {
  font-size: 1.1rem; color: var(--sd41-text-light);
  padding: 0.5rem 0.3rem; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}

/* ===== Cards / Features ===== */
.sd41-card {
  background: var(--sd41-card-bg); border: 0.1rem solid var(--sd41-card-border);
  border-radius: var(--sd41-radius); padding: 1.5rem;
  margin-bottom: 1.2rem; box-shadow: var(--sd41-shadow);
}
.sd41-feature-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.sd41-feature-item {
  background: var(--sd41-card-bg); border-radius: 1rem; padding: 1.2rem;
  text-align: center; border: 0.1rem solid var(--sd41-card-border);
}
.sd41-feature-item .sd41-icon { font-size: 2.4rem; color: var(--sd41-primary); margin-bottom: 0.6rem; }
.sd41-feature-item h4 { color: var(--sd41-text-light); font-size: 1.3rem; margin-bottom: 0.4rem; }
.sd41-feature-item p { font-size: 1.2rem; color: var(--sd41-text-muted); }

/* ===== Promo Links ===== */
.sd41-promo-link { color: var(--sd41-primary); font-weight: 700; cursor: pointer; text-decoration: underline; }
.sd41-promo-banner {
  background: var(--sd41-gradient); border-radius: var(--sd41-radius);
  padding: 1.5rem; text-align: center; margin: 1.5rem 0;
  color: #fff; cursor: pointer;
}
.sd41-promo-banner h3 { color: #fff; font-size: 1.6rem; margin-bottom: 0.4rem; }
.sd41-promo-banner .sd41-btn { background: #fff; color: var(--sd41-accent); margin-top: 0.8rem; }

/* ===== Testimonials ===== */
.sd41-testimonial {
  background: var(--sd41-card-bg); border-left: 0.3rem solid var(--sd41-primary);
  border-radius: 0.8rem; padding: 1.2rem; margin-bottom: 1rem;
}
.sd41-testimonial p { font-style: italic; color: var(--sd41-text-muted); }
.sd41-testimonial .sd41-author { display: block; margin-top: 0.6rem; color: var(--sd41-primary); font-weight: 600; font-size: 1.2rem; }

/* ===== Payment Grid ===== */
.sd41-payment-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.8rem; }
.sd41-payment-item {
  background: var(--sd41-card-bg); border-radius: 0.8rem; padding: 1rem;
  text-align: center; border: 0.1rem solid var(--sd41-card-border);
}
.sd41-payment-item .sd41-icon { font-size: 2rem; color: var(--sd41-primary); }
.sd41-payment-item span { display: block; font-size: 1.1rem; margin-top: 0.4rem; color: var(--sd41-text-light); }

/* ===== Winners ===== */
.sd41-winner-list { list-style: none; }
.sd41-winner-list li {
  display: flex; justify-content: space-between;
  padding: 0.8rem 1rem; background: var(--sd41-card-bg);
  border-radius: 0.6rem; margin-bottom: 0.5rem; font-size: 1.2rem;
}
.sd41-winner-list .sd41-amount { color: var(--sd41-primary); font-weight: 700; }

/* ===== FAQ ===== */
.sd41-faq-item {
  background: var(--sd41-card-bg); border-radius: 0.8rem;
  margin-bottom: 0.8rem; overflow: hidden;
  border: 0.1rem solid var(--sd41-card-border);
}
.sd41-faq-item summary {
  padding: 1rem 1.2rem; font-weight: 600; color: var(--sd41-text-light);
  cursor: pointer; list-style: none; font-size: 1.3rem;
}
.sd41-faq-item summary::-webkit-details-marker { display: none; }
.sd41-faq-item p { padding: 0 1.2rem 1rem; color: var(--sd41-text-muted); font-size: 1.2rem; }

/* ===== Footer ===== */
.sd41-footer { background: #050505; padding: 2rem 1.2rem 9rem; border-top: 0.2rem solid var(--sd41-primary); }
.sd41-footer h4 { color: var(--sd41-text-light); font-size: 1.4rem; margin-bottom: 0.8rem; }
.sd41-footer p { color: var(--sd41-text-muted); font-size: 1.2rem; margin-bottom: 1rem; }
.sd41-footer-links { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-bottom: 1rem; }
.sd41-footer-links a { font-size: 1.1rem; color: var(--sd41-text-muted); padding: 0.4rem 0.8rem; background: var(--sd41-card-bg); border-radius: 0.6rem; }
.sd41-footer-copyright { text-align: center; font-size: 1.1rem; color: var(--sd41-text-muted); margin-top: 1rem; }

/* ===== Bottom Nav ===== */
.sd41-bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0;
  max-width: 430px; margin: 0 auto;
  height: 6rem; background: var(--sd41-header-bg);
  border-top: 0.2rem solid var(--sd41-primary);
  display: flex; justify-content: space-around; align-items: center;
  z-index: 1000; box-shadow: 0 -0.4rem 1rem rgba(0,0,0,0.5);
}
.sd41-navbtn {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-width: 6rem; min-height: 6rem;
  background: transparent; border: none; color: var(--sd41-text-muted);
  font-size: 1.1rem; cursor: pointer; gap: 0.2rem;
  transition: color 0.15s ease, transform 0.15s ease;
}
.sd41-navbtn .sd41-nav-icon { font-size: 2.2rem; line-height: 1; }
.sd41-navbtn:active { transform: scale(0.92); }
.sd41-navbtn.sd41-navbtn-active, .sd41-navbtn:active { color: var(--sd41-primary); }
.sd41-navbtn-promo .sd41-nav-icon { color: var(--sd41-accent); }

/* ===== Responsive ===== */
@media (min-width: 769px) {
  .sd41-bottom-nav { display: none; }
}
@media (max-width: 768px) {
  .sd41-main { padding-bottom: 8rem; }
}
@media (max-width: 360px) {
  .sd41-game-grid { grid-template-columns: repeat(2, 1fr); }
  .sd41-feature-grid, .sd41-payment-grid { grid-template-columns: 1fr; }
}
