/* =============================================================
   Playzini Casino – custom.css
   Alpine Spark Theme: Emerald & Gold on Dark Polished Backdrop
   ============================================================= */

/* ── Global Reset & Base ─────────────────────────────────── */
html {
  overflow-x: hidden;
  scroll-behavior: smooth;
}

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

body {
  word-break: break-word;
  overflow-x: hidden;
  background-color: #0a0f1a;
  color: #f1f5f9;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.6;
}

/* ── Typography ──────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  line-height: 1.25;
  font-weight: 700;
  word-break: break-word;
}

a {
  text-decoration: none;
  transition: color 0.2s ease;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ── Text Gradient (hero) ────────────────────────────────── */
.text-gradient-hero {
  background: linear-gradient(135deg, #10b981 0%, #34d399 40%, #f59e0b 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Utility ─────────────────────────────────────────────── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── Hero Section ────────────────────────────────────────── */
.hero-section {
  position: relative;
}

.hero-bg {
  will-change: transform;
  transform: translateZ(0);
  background-attachment: fixed;
}

@media (max-width: 768px) {
  .hero-bg {
    background-attachment: scroll;
  }
}

.scroll-dot {
  animation: scrollDot 1.5s ease-in-out infinite;
}

@keyframes scrollDot {
  0%, 100% { transform: translateY(0); opacity: 1; }
  50% { transform: translateY(10px); opacity: 0.3; }
}

/* ── Bonus Badge Glow ────────────────────────────────────── */
.bonus-badge-box {
  animation: badgePulse 3s ease-in-out infinite;
  overflow: visible;
}

.bonus-badge-label {
  white-space: nowrap;
  line-height: 1.2;
}

@keyframes badgePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.015); }
}

/* ── CTA Primary Shine ───────────────────────────────────── */
.cta-primary {
  position: relative;
  overflow: hidden;
}

.cta-primary::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -75%;
  width: 50%;
  height: 200%;
  background: rgba(255, 255, 255, 0.15);
  transform: skewX(-25deg);
  transition: left 0.6s ease;
}

.cta-primary:hover::after {
  left: 125%;
}

/* ── Particles ───────────────────────────────────────────── */
.particles-container {
  pointer-events: none;
  overflow: hidden;
}

/* Generated via JS pseudo-particles using CSS */
.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #10b981;
  opacity: 0;
  animation: particleFloat 6s ease-in-out infinite;
}

@keyframes particleFloat {
  0% { opacity: 0; transform: translateY(100vh) scale(0); }
  10% { opacity: 0.6; }
  90% { opacity: 0.2; }
  100% { opacity: 0; transform: translateY(-10vh) scale(1.5); }
}

/* ── Marquee Animation ───────────────────────────────────── */
.games-marquee-wrapper {
  overflow: hidden;
  cursor: grab;
  user-select: none;
}

.games-marquee-wrapper:active {
  cursor: grabbing;
}

.games-marquee {
  display: flex;
  gap: 1.5rem;
  width: max-content;
  animation: marqueeScroll 40s linear infinite;
  padding: 1rem 0;
}

.games-marquee:hover {
  animation-play-state: paused;
}

@keyframes marqueeScroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ── Game Cards ──────────────────────────────────────────── */
.game-card {
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  will-change: transform;
}

.game-card:hover {
  box-shadow: 0 20px 40px rgba(16, 185, 129, 0.2);
}

/* ── Promo Cards ─────────────────────────────────────────── */
.promo-card {
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.promo-card:hover {
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.4);
}

/* ── Step Cards ──────────────────────────────────────────── */
.step-card {
  padding: 2rem;
  background: linear-gradient(145deg, #111827, #1a2332);
  border: 1px solid #1e2d42;
  border-radius: 1.5rem;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.step-card:hover {
  border-color: rgba(16, 185, 129, 0.4);
  box-shadow: 0 12px 30px rgba(16, 185, 129, 0.15);
}

/* ── Review Block ────────────────────────────────────────── */
.review-block {
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.review-block:hover {
  border-color: rgba(16, 185, 129, 0.3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

/* ── Word Cloud / Provider Tags ──────────────────────────── */
.word-cloud {
  line-height: 1.8;
}

.provider-tag {
  display: inline-block;
  font-weight: 600;
  cursor: default;
  transition: opacity 0.2s ease, transform 0.2s ease;
  padding: 0.1em 0.25em;
  border-radius: 0.25rem;
}

.provider-tag:hover {
  opacity: 0.8;
  transform: scale(1.05);
}

.provider-tag.provider-sm  { font-size: 0.75rem; }
.provider-tag.provider-md  { font-size: 0.9rem; }
.provider-tag.provider-lg  { font-size: 1.05rem; }
.provider-tag.provider-xl  { font-size: 1.25rem; }

/* ── FAQ ─────────────────────────────────────────────────── */
.faq-item {
  transition: border-color 0.2s ease;
}

.faq-item:hover {
  border-color: rgba(16, 185, 129, 0.3);
}

.faq-content {
  border-top: 1px solid #1e2d42;
}

.faq-icon {
  transition: transform 0.3s ease;
}

/* ── Navigation ──────────────────────────────────────────── */
.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: #10b981;
  transform: translateX(-50%);
  transition: width 0.3s ease;
  border-radius: 1px;
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 60%;
}

/* ── Table Styles ────────────────────────────────────────── */
table {
  width: 100%;
  border-collapse: collapse;
  word-break: break-word;
}

th, td {
  text-align: left;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #1e2d42;
  white-space: normal;
}

th {
  font-weight: 700;
  color: #f1f5f9;
  background: #111827;
}

tr:last-child td {
  border-bottom: none;
}

/* ── Mandatory Table Scroll Wrapper ──────────────────────── */
.prose-casino .prose-table-scroll {
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  margin: 1.5em 0;
  border-radius: 0.5rem;
}

.prose-casino .prose-table-scroll table {
  margin-top: 0;
  margin-bottom: 0;
}

/* ── Homepage table panel (background + mobile scroll) ───── */
.home-table-panel {
  position: relative;
  margin: 1.5rem 0;
  padding: 1rem;
  border-radius: 1rem;
  border: 1px solid #1e2d42;
  background:
    linear-gradient(145deg, rgba(16, 185, 129, 0.08) 0%, rgba(17, 24, 39, 0.98) 35%, rgba(10, 15, 26, 1) 100%);
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(16, 185, 129, 0.12);
  overflow: hidden;
}

.home-table-panel::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%2310b981' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
  opacity: 0.85;
}

.home-table-panel::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.6), rgba(245, 158, 11, 0.5), transparent);
  pointer-events: none;
}

.home-table-panel--compact {
  padding: 0.75rem;
}

.home-table-scroll-hint {
  position: relative;
  z-index: 1;
  margin: 0 0 0.5rem;
  text-align: center;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #64748b;
}

.home-table-scroll {
  position: relative;
  z-index: 1;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  border-radius: 0.75rem;
  background: rgba(10, 15, 26, 0.55);
  border: 1px solid rgba(30, 45, 66, 0.8);
}

@media (max-width: 767px) {
  .home-table-panel .home-table-scroll {
    margin: 0 -0.25rem;
    padding-bottom: 0.25rem;
    scrollbar-width: thin;
    scrollbar-color: #10b981 #111827;
  }

  .home-table-panel .home-table-scroll::-webkit-scrollbar {
    height: 6px;
  }

  .home-table-panel .home-table-scroll::-webkit-scrollbar-thumb {
    background: #10b981;
    border-radius: 3px;
  }
}

.home-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.45;
  word-break: normal;
}

.home-table th,
.home-table td {
  padding: 0.875rem 1.125rem;
  border-bottom: 1px solid #1e2d42;
  border-right: 1px solid rgba(30, 45, 66, 0.6);
  vertical-align: middle;
  white-space: nowrap;
}

.home-table th:last-child,
.home-table td:last-child {
  border-right: none;
}

.home-table thead th {
  background: linear-gradient(180deg, #1a2332 0%, #111827 100%);
  color: #f1f5f9;
  font-weight: 700;
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.home-table tbody tr:last-child td {
  border-bottom: none;
}

.home-table tbody tr {
  transition: background-color 0.2s ease;
}

.home-table tbody tr:hover td {
  background: rgba(16, 185, 129, 0.06);
}

.home-table tbody td {
  color: #f1f5f9;
  background: rgba(17, 24, 39, 0.65);
}

.home-table--wide {
  min-width: 44rem;
}

.home-table--compact {
  min-width: 100%;
}

.home-table--compact th,
.home-table--compact td {
  white-space: normal;
  text-align: center;
}

.home-table--compact thead th:first-child,
.home-table--compact tbody td:first-child {
  text-align: left;
}

@media (max-width: 640px) {
  .home-table-panel {
    padding: 0.75rem;
    margin-left: -0.25rem;
    margin-right: -0.25rem;
  }

  .home-table {
    font-size: 0.875rem;
  }

  .home-table th,
  .home-table td {
    padding: 0.75rem 0.875rem;
    font-size: 0.875rem;
  }

  .home-table thead th {
    font-size: 0.75rem;
  }

  .home-table--compact th,
  .home-table--compact td {
    min-width: 5.25rem;
    padding: 0.75rem 0.625rem;
  }

  .home-table--wide {
    min-width: 40rem;
  }
}

/* ── Prose / Content Styling ─────────────────────────────── */
.prose-content {
  color: #cbd5e1;
  font-size: 1rem;
  line-height: 1.8;
  word-break: break-word;
}

.prose-content h1 {
  font-size: 2rem;
  font-weight: 800;
  color: #f1f5f9;
  margin-bottom: 1.5rem;
  line-height: 1.25;
}

.prose-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #f1f5f9;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #1e2d42;
}

.prose-content h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: #e2e8f0;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.prose-content h4 {
  font-size: 1rem;
  font-weight: 600;
  color: #cbd5e1;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

.prose-content p {
  margin-bottom: 1.25rem;
  color: #94a3b8;
}

.prose-content strong {
  color: #f1f5f9;
  font-weight: 600;
}

.prose-content em {
  color: #cbd5e1;
  font-style: italic;
}

.prose-content ul {
  list-style: none;
  padding-left: 0;
  margin-bottom: 1.25rem;
}

.prose-content ul li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.5rem;
  color: #94a3b8;
}

.prose-content ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 8px;
  height: 8px;
  background: #10b981;
  border-radius: 50%;
}

.prose-content ol {
  padding-left: 1.5rem;
  margin-bottom: 1.25rem;
  counter-reset: ol-counter;
  list-style: none;
}

.prose-content ol li {
  counter-increment: ol-counter;
  position: relative;
  padding-left: 1rem;
  margin-bottom: 0.5rem;
  color: #94a3b8;
}

.prose-content ol li::before {
  content: counter(ol-counter) '.';
  position: absolute;
  left: -1.5rem;
  color: #10b981;
  font-weight: 700;
}

.prose-content a {
  color: #34d399;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}

.prose-content a:hover {
  color: #6ee7b7;
}

.prose-content blockquote {
  border-left: 4px solid #10b981;
  padding-left: 1rem;
  margin: 1.5rem 0;
  font-style: italic;
  color: #64748b;
  background: #111827;
  border-radius: 0 0.5rem 0.5rem 0;
  padding: 1rem 1.25rem;
}

.prose-content code {
  background: #1a2332;
  color: #34d399;
  padding: 0.15em 0.4em;
  border-radius: 0.25rem;
  font-size: 0.875rem;
  font-family: 'Courier New', monospace;
}

.prose-content pre {
  background: #111827;
  border: 1px solid #1e2d42;
  border-radius: 0.75rem;
  padding: 1.25rem;
  overflow-x: auto;
  margin: 1.5rem 0;
}

.prose-content pre code {
  background: none;
  padding: 0;
  color: #94a3b8;
}

.prose-content hr {
  border: none;
  border-top: 1px solid #1e2d42;
  margin: 2rem 0;
}

.prose-content table {
  font-size: 0.875rem;
  border-radius: 0.5rem;
  overflow: hidden;
  border: 1px solid #1e2d42;
}

.prose-content table th {
  background: #111827;
  color: #f1f5f9;
  padding: 0.75rem 1rem;
  font-weight: 700;
}

.prose-content table td {
  background: transparent;
  color: #94a3b8;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #1e2d42;
}

.prose-content table tr:hover td {
  background: rgba(30, 45, 66, 0.5);
}

/* Wrap all tables in prose content for horizontal scroll */
.prose-content table {
  display: block;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  width: 100%;
}

/* ── Scrollbar Styling ───────────────────────────────────── */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: #0a0f1a;
}

::-webkit-scrollbar-thumb {
  background: #1e2d42;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #10b981;
}

/* ── Focus Styles ────────────────────────────────────────── */
:focus-visible {
  outline: 2px solid #10b981;
  outline-offset: 2px;
  border-radius: 4px;
}

/* ── Selection ───────────────────────────────────────────── */
::selection {
  background: rgba(16, 185, 129, 0.3);
  color: #f1f5f9;
}

/* ── Transitions ─────────────────────────────────────────── */
.transition-fast {
  transition: all 0.15s ease;
}

.transition-medium {
  transition: all 0.3s ease;
}

.transition-slow {
  transition: all 0.5s ease;
}

/* ── Loading / Skeleton ──────────────────────────────────── */
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.skeleton {
  background: linear-gradient(90deg, #111827 25%, #1a2332 50%, #111827 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

/* ── Responsive Helpers ──────────────────────────────────── */
@media (max-width: 640px) {
  .hero-section h1 {
    font-size: 2rem;
  }

  .bonus-badge-box {
    max-width: 100%;
  }

  .step-card {
    padding: 1.5rem;
  }

  table:not(.home-table) th,
  table:not(.home-table) td {
    padding: 0.5rem 0.75rem;
    font-size: 0.8rem;
  }
}

@media (max-width: 1024px) {
  .games-marquee {
    animation-duration: 30s;
  }
}

/* ── Overflow-x auto for tables on mobile ────────────────── */
.overflow-x-auto {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
}

/* ── Alpine Spark SVG Pattern Background ─────────────────── */
.pattern-bg {
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%2310b981' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* ── Glow effects ────────────────────────────────────────── */
.glow-emerald {
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.3);
}

.glow-gold {
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.3);
}

.text-glow-emerald {
  text-shadow: 0 0 20px rgba(16, 185, 129, 0.5);
}

.text-glow-gold {
  text-shadow: 0 0 20px rgba(245, 158, 11, 0.5);
}

/* ── Sticky header transition ────────────────────────────── */
#site-header {
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

#site-header.scrolled {
  background-color: rgba(13, 20, 36, 0.98);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.6);
}
