/* Custom Animations and Styles */

/* Prevent horizontal scroll on mobile */
html, body {
  overflow-x: hidden;
  max-width: 100%;
}

/* Mobile Menu Solid Background */
#mobileMenu {
  background-color: #2a2318 !important;
  backdrop-filter: none !important;
}

#mobileMenu > div {
  background-color: #2a2318 !important;
}

/* Egypt Pattern Background */
.egypt-pattern {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  opacity: 0.03;
  background-image: repeating-linear-gradient(
      45deg,
      transparent,
      transparent 35px,
      rgba(217, 119, 6, 0.1) 35px,
      rgba(217, 119, 6, 0.1) 70px
    ),
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 35px,
      rgba(245, 158, 11, 0.1) 35px,
      rgba(245, 158, 11, 0.1) 70px
    );
  pointer-events: none;
}

/* Floating Hero Animation */
@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

.floating-hero {
  animation: float 6s ease-in-out infinite;
}

/* Pulse Glow Animation */
@keyframes pulse-glow {
  0%,
  100% {
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.5);
  }
  50% {
    box-shadow: 0 0 40px rgba(245, 158, 11, 0.8), 0 0 60px rgba(245, 158, 11, 0.4);
  }
}

.pulse-glow {
  animation: pulse-glow 2s ease-in-out infinite;
}

/* Gradient Animation */
@keyframes gradient-shift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* Prose Styling for Readability */
.prose-custom {
  line-height: 1.75;
}

.prose-custom p {
  margin-bottom: 1.25rem;
}

.prose-custom h2 {
  font-size: 1.875rem;
  font-weight: 700;
  color: #fbbf24;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.prose-custom h3 {
  font-size: 1.5rem;
  font-weight: 600;
  color: #fbbf24;
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}

.prose-custom ul,
.prose-custom ol {
  margin-left: 1.5rem;
  margin-bottom: 1.25rem;
}

.prose-custom li {
  margin-bottom: 0.5rem;
}

.prose-custom a {
  color: #fbbf24;
  text-decoration: underline;
}

.prose-custom a:hover {
  color: #f59e0b;
}

/* Smooth Scroll */
html {
  scroll-behavior: smooth;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: #1a1510;
}

::-webkit-scrollbar-thumb {
  background: #78350f;
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: #92400e;
}

/* Shimmer Effect for Cards */
@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

.shimmer {
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.1) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  background-size: 1000px 100%;
  animation: shimmer 3s infinite;
}

/* Tilt Effect on Hover */
@media (hover: hover) {
  .hover\:scale-105:hover {
    transform: scale(1.05) perspective(1000px) rotateY(2deg);
    transition: transform 0.3s ease;
  }
}

/* Mobile Menu Overlay */
#mobileMenu {
  backdrop-filter: blur(10px);
}

/* Table Responsive */
@media (max-width: 768px) {
  table {
    font-size: 0.875rem;
  }

  th,
  td {
    padding: 0.75rem 0.5rem;
  }
}

/* Loading Animation */
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.animate-spin {
  animation: spin 1s linear infinite;
}

/* Fade In Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.6s ease-out;
}

/* Hieroglyphics Pattern (CSS only) */
.hieroglyph-pattern {
  background-image: radial-gradient(circle at 20% 50%, rgba(217, 119, 6, 0.1) 1px, transparent 1px),
    radial-gradient(circle at 80% 50%, rgba(245, 158, 11, 0.1) 1px, transparent 1px);
  background-size: 50px 50px;
}

/* Slots Category Menu - 3D Buttons */
.slots-menu-wrapper {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 1rem 0;
  width: 100%;
  max-width: 100%;
  -webkit-overflow-scrolling: touch;
}

.slots-menu-row {
  display: flex;
  gap: 1rem;
  min-width: max-content;
  padding: 0.5rem 0;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}

.slot-category-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  min-width: 180px;
  background: linear-gradient(145deg, #d97706, #b45309);
  border-radius: 12px;
  box-shadow: 
    0 8px 0 #92400e,
    0 12px 20px rgba(0, 0, 0, 0.4),
    inset 0 2px 4px rgba(251, 191, 36, 0.5),
    inset 0 -2px 4px rgba(120, 53, 15, 0.5);
  text-decoration: none;
  color: #fef3c7;
  font-weight: 700;
  font-size: 0.95rem;
  transition: all 0.15s ease;
  cursor: pointer;
  border: 2px solid #b45309;
  transform-style: preserve-3d;
}

.slot-category-btn:hover {
  transform: translateY(-2px);
  box-shadow: 
    0 10px 0 #92400e,
    0 14px 24px rgba(0, 0, 0, 0.5),
    inset 0 2px 6px rgba(251, 191, 36, 0.6),
    inset 0 -2px 6px rgba(120, 53, 15, 0.6);
  background: linear-gradient(145deg, #ea9a29, #d97706);
}

.slot-category-btn:active {
  transform: translateY(4px);
  box-shadow: 
    0 4px 0 #92400e,
    0 6px 12px rgba(0, 0, 0, 0.3),
    inset 0 2px 4px rgba(251, 191, 36, 0.3),
    inset 0 -2px 4px rgba(120, 53, 15, 0.8);
}

.category-text {
  flex: 1;
  text-align: left;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}

.category-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #fbbf24, #f59e0b);
  color: #78350f;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  min-width: 40px;
  box-shadow: 
    0 2px 4px rgba(0, 0, 0, 0.3),
    inset 0 1px 2px rgba(255, 255, 255, 0.5);
  border: 1px solid #d97706;
}

/* Scrollbar Styling for Menu */
.slots-menu-wrapper::-webkit-scrollbar {
  height: 8px;
}

.slots-menu-wrapper::-webkit-scrollbar-track {
  background: rgba(120, 53, 15, 0.3);
  border-radius: 4px;
}

.slots-menu-wrapper::-webkit-scrollbar-thumb {
  background: linear-gradient(to right, #d97706, #f59e0b);
  border-radius: 4px;
}

.slots-menu-wrapper::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(to right, #ea9a29, #fbbf24);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .slot-category-btn {
    min-width: 160px;
    padding: 0.875rem 1.25rem;
    font-size: 0.875rem;
  }
  
  .slots-menu-row {
    gap: 0.75rem;
  }
}

/* 3D Tips Cards */
.tip-card-3d {
  position: relative;
  background: linear-gradient(145deg, #78350f, #92400e);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 
    0 10px 0 #451a03,
    0 15px 25px rgba(0, 0, 0, 0.5),
    inset 0 2px 4px rgba(251, 191, 36, 0.3),
    inset 0 -2px 4px rgba(68, 26, 3, 0.8);
  border: 2px solid #92400e;
  transition: all 0.3s ease;
  transform-style: preserve-3d;
}

.tip-card-3d:hover {
  transform: translateY(-5px);
  box-shadow: 
    0 12px 0 #451a03,
    0 18px 30px rgba(0, 0, 0, 0.6),
    inset 0 2px 6px rgba(251, 191, 36, 0.4),
    inset 0 -2px 6px rgba(68, 26, 3, 0.9);
}

.tip-icon {
  width: 3.5rem;
  height: 3.5rem;
  background: linear-gradient(145deg, #fbbf24, #f59e0b);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  box-shadow: 
    0 4px 0 #d97706,
    0 6px 12px rgba(0, 0, 0, 0.3),
    inset 0 2px 4px rgba(255, 255, 255, 0.5);
  border: 2px solid #f59e0b;
}

/* Game Contribution Badges */
.contribution-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 1rem;
  border-radius: 12px;
  box-shadow: 
    0 6px 0 rgba(0, 0, 0, 0.3),
    0 8px 15px rgba(0, 0, 0, 0.4),
    inset 0 2px 4px rgba(255, 255, 255, 0.2);
  border: 2px solid;
  transition: all 0.3s ease;
  transform-style: preserve-3d;
}

.contribution-badge:hover {
  transform: translateY(-3px);
  box-shadow: 
    0 8px 0 rgba(0, 0, 0, 0.3),
    0 10px 20px rgba(0, 0, 0, 0.5),
    inset 0 2px 6px rgba(255, 255, 255, 0.3);
}

.contribution-badge.slots {
  background: linear-gradient(145deg, #10b981, #059669);
  border-color: #047857;
}

.contribution-badge.scratch {
  background: linear-gradient(145deg, #3b82f6, #2563eb);
  border-color: #1d4ed8;
}

.contribution-badge.table {
  background: linear-gradient(145deg, #f59e0b, #d97706);
  border-color: #b45309;
}

.contribution-badge.live {
  background: linear-gradient(145deg, #ef4444, #dc2626);
  border-color: #b91c1c;
}

.contribution-percentage {
  font-size: 2rem;
  font-weight: 800;
  color: #fef3c7;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  margin-bottom: 0.5rem;
}

.contribution-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: #fef3c7;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

/* Responsive adjustments for tips section */
@media (max-width: 768px) {
  .tip-card-3d {
    padding: 1.25rem;
  }
  
  .tip-icon {
    width: 3rem;
    height: 3rem;
  }
  
  .contribution-percentage {
    font-size: 1.5rem;
  }
}
