/* ========================================
   Lasting Win Boost - Custom CSS
   Canadian Casino Theme
   ======================================== */

/* CSS Custom Properties */
:root {
  --color-primary: #e63946;
  --color-primary-dark: #c1121f;
  --color-secondary: #f4a261;
  --color-accent: #2a9d8f;
  --color-gold: #ffd700;
  --color-dark: #1a1a2e;
  --color-darker: #0f0f1a;
  --color-light: #f8f9fa;
  --color-muted: #6c757d;
  --gradient-hero: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  --gradient-card: linear-gradient(180deg, rgba(26, 26, 46, 0.95) 0%, rgba(15, 15, 26, 0.98) 100%);
  --gradient-accent: linear-gradient(90deg, #e63946 0%, #f4a261 100%);
}

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

/* ========================================
   Keyframe Animations
   ======================================== */

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-1rem); }
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 1.25rem rgba(230, 57, 70, 0.4); }
  50% { box-shadow: 0 0 2.5rem rgba(230, 57, 70, 0.7); }
}

@keyframes shimmer {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

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

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

@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(1.5rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes rotate-slow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes bounce-subtle {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-0.5rem); }
}

@keyframes gradient-shift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* ========================================
   Animation Utility Classes
   ======================================== */

.animate-float {
  animation: float 3s ease-in-out infinite;
}

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

.animate-shimmer {
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  background-size: 200% 100%;
  animation: shimmer 2s infinite;
}

.animate-marquee {
  animation: marquee 25s linear infinite;
}

.animate-marquee-reverse {
  animation: marquee-reverse 25s linear infinite;
}

.animate-fade-in-up {
  animation: fade-in-up 0.6s ease-out forwards;
}

.animate-bounce-subtle {
  animation: bounce-subtle 2s ease-in-out infinite;
}

.animate-gradient {
  background-size: 200% 200%;
  animation: gradient-shift 4s ease infinite;
}

/* Parallax Container */
.parallax-container {
  perspective: 1px;
  height: 100vh;
  overflow-x: hidden;
  overflow-y: auto;
}

.parallax-layer {
  position: absolute;
  inset: 0;
  transform: translateZ(-1px) scale(2);
}

.parallax-content {
  position: relative;
  transform: translateZ(0);
}

/* ========================================
   Component Overrides
   ======================================== */

/* Navigation */
.nav-backdrop {
  backdrop-filter: blur(0.75rem);
  -webkit-backdrop-filter: blur(0.75rem);
}

.mobile-menu-bg {
  background: linear-gradient(180deg, #1a1a2e 0%, #0f0f1a 100%);
}

/* Bonus Badge */
.bonus-badge {
  background: var(--gradient-accent);
  background-size: 200% 200%;
  animation: gradient-shift 3s ease infinite;
}

/* CTA Buttons */
.cta-primary {
  background: var(--gradient-accent);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.cta-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transform: translateX(-100%);
  transition: transform 0.5s ease;
}

.cta-primary:hover::before {
  transform: translateX(100%);
}

.cta-primary:hover {
  transform: translateY(-0.125rem);
  box-shadow: 0 0.625rem 1.875rem rgba(230, 57, 70, 0.4);
}

.cta-secondary {
  border: 0.125rem solid var(--color-secondary);
  transition: all 0.3s ease;
}

.cta-secondary:hover {
  background: var(--color-secondary);
  color: var(--color-dark);
}

/* Game Cards */
.game-card {
  transition: all 0.3s ease;
}

.game-card:hover {
  transform: translateY(-0.5rem);
  box-shadow: 0 1.25rem 2.5rem rgba(0, 0, 0, 0.3);
}

/* Step Cards */
.step-badge {
  background: var(--gradient-accent);
  box-shadow: 0 0.25rem 0.9375rem rgba(230, 57, 70, 0.3);
}

/* Table Responsive Wrapper */
.table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  width: 100%;
}

/* Promo Cards */
.promo-card {
  background: var(--gradient-card);
  border: 0.0625rem solid rgba(244, 162, 97, 0.2);
  transition: all 0.3s ease;
}

.promo-card:hover {
  border-color: rgba(244, 162, 97, 0.5);
  transform: translateY(-0.25rem);
}

/* FAQ Accordion */
.faq-item {
  border-bottom: 0.0625rem solid rgba(255, 255, 255, 0.1);
}

.faq-question {
  transition: color 0.3s ease;
}

.faq-question:hover {
  color: var(--color-secondary);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-item.active .faq-answer {
  max-height: 31.25rem;
}

/* SVG Decorative Patterns */
.pattern-dots {
  background-image: radial-gradient(rgba(244, 162, 97, 0.15) 0.0625rem, transparent 0.0625rem);
  background-size: 1.25rem 1.25rem;
}

.pattern-grid {
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.03) 0.0625rem, transparent 0.0625rem),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 0.0625rem, transparent 0.0625rem);
  background-size: 3.125rem 3.125rem;
}

/* Decorative Shapes */
.shape-blob {
  border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
}

.shape-diamond {
  clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
}

/* ========================================
   Prose Styling for Markdown Content
   ======================================== */

.prose {
  color: #e5e7eb;
  max-width: 100%;
  line-height: 1.75;
  font-size: 1rem;
}

.prose > * + * {
  margin-top: 1.5em;
}

/* Headings */
.prose h2 {
  color: #f8f9fa;
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  margin-top: 2.5em;
  margin-bottom: 1em;
  line-height: 1.3;
  border-bottom: 0.125rem solid rgba(244, 162, 97, 0.3);
  padding-bottom: 0.5em;
}

.prose h3 {
  color: #f4a261;
  font-size: clamp(1.25rem, 3vw, 1.5rem);
  font-weight: 600;
  margin-top: 2em;
  margin-bottom: 0.75em;
  line-height: 1.4;
}

.prose h4 {
  color: #e5e7eb;
  font-size: clamp(1.125rem, 2.5vw, 1.25rem);
  font-weight: 600;
  margin-top: 1.5em;
  margin-bottom: 0.5em;
}

/* Paragraphs */
.prose p {
  margin-bottom: 1.25em;
  color: #d1d5db;
}

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

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

/* Links */
.prose a {
  color: #f4a261;
  text-decoration: underline;
  text-underline-offset: 0.1875rem;
  transition: color 0.2s ease;
}

.prose a:hover {
  color: #e63946;
}

/* Lists */
.prose ul {
  list-style-type: none;
  padding-left: 0;
  margin: 1.25em 0;
}

.prose ul li {
  position: relative;
  padding-left: 1.75em;
  margin-bottom: 0.75em;
  color: #d1d5db;
}

.prose ul li::before {
  content: '✦';
  position: absolute;
  left: 0;
  color: #f4a261;
  font-size: 0.875em;
}

.prose ol {
  list-style-type: none;
  padding-left: 0;
  margin: 1.25em 0;
  counter-reset: prose-counter;
}

.prose ol li {
  position: relative;
  padding-left: 2.5em;
  margin-bottom: 0.75em;
  color: #d1d5db;
  counter-increment: prose-counter;
}

.prose ol li::before {
  content: counter(prose-counter);
  position: absolute;
  left: 0;
  width: 1.75em;
  height: 1.75em;
  background: linear-gradient(135deg, #e63946, #f4a261);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75em;
  font-weight: 700;
  color: #fff;
}

/* Tables */
.prose .table-responsive {
  margin: 1.5em 0;
  border-radius: 0.5rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.prose table {
  width: 100%;
  min-width: 28rem;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.prose thead {
  background: linear-gradient(135deg, rgba(230, 57, 70, 0.2), rgba(244, 162, 97, 0.2));
}

.prose th {
  color: #f8f9fa;
  font-weight: 600;
  text-align: left;
  padding: 1em;
  border-bottom: 0.125rem solid rgba(244, 162, 97, 0.3);
  white-space: nowrap;
}

.prose td {
  padding: 1em;
  border-bottom: 0.0625rem solid rgba(255, 255, 255, 0.1);
  color: #d1d5db;
}

.prose tbody tr {
  transition: background 0.2s ease;
}

.prose tbody tr:hover {
  background: rgba(244, 162, 97, 0.05);
}

/* Blockquotes */
.prose blockquote {
  border-left: 0.25rem solid #f4a261;
  padding: 1em 1.5em;
  margin: 1.5em 0;
  background: rgba(244, 162, 97, 0.1);
  border-radius: 0 0.5rem 0.5rem 0;
  font-style: italic;
}

.prose blockquote p {
  margin: 0;
  color: #e5e7eb;
}

/* Code */
.prose code {
  background: rgba(230, 57, 70, 0.15);
  color: #f4a261;
  padding: 0.125em 0.375em;
  border-radius: 0.25rem;
  font-size: 0.875em;
  font-family: 'Fira Code', monospace;
}

.prose pre {
  background: rgba(15, 15, 26, 0.8);
  border: 0.0625rem solid rgba(244, 162, 97, 0.2);
  border-radius: 0.5rem;
  padding: 1.25em;
  overflow-x: auto;
  margin: 1.5em 0;
}

.prose pre code {
  background: transparent;
  padding: 0;
  color: #e5e7eb;
}

/* Images */
.prose img {
  max-width: 100%;
  height: auto;
  border-radius: 0.75rem;
  margin: 1.5em auto;
  display: block;
  box-shadow: 0 0.625rem 1.875rem rgba(0, 0, 0, 0.3);
}

/* Horizontal Rule */
.prose hr {
  border: none;
  height: 0.0625rem;
  background: linear-gradient(90deg, transparent, rgba(244, 162, 97, 0.5), transparent);
  margin: 2.5em 0;
}

/* First paragraph styling */
.prose > p:first-of-type {
  font-size: 1.125em;
  color: #e5e7eb;
  line-height: 1.8;
}

/* ========================================
   Responsive Adjustments
   ======================================== */

@media (max-width: 64rem) {
  .prose {
    font-size: 0.9375rem;
  }
  
  .prose ul li,
  .prose ol li {
    padding-left: 1.5em;
  }
  
  .prose ol li::before {
    width: 1.5em;
    height: 1.5em;
  }
}

@media (max-width: 48rem) {
  .prose {
    font-size: 0.875rem;
  }
  
  .prose h2 {
    margin-top: 2em;
  }
  
  .prose h3 {
    margin-top: 1.5em;
  }
  
  .prose table {
    font-size: 0.8125rem;
  }
  
  .prose th,
  .prose td {
    padding: 0.75em;
  }
}

/* ========================================
   Utility Classes
   ======================================== */

.text-gradient {
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.border-gradient {
  border: 0.125rem solid transparent;
  background: linear-gradient(var(--color-dark), var(--color-dark)) padding-box,
              var(--gradient-accent) border-box;
}

.glow-red {
  box-shadow: 0 0 1.875rem rgba(230, 57, 70, 0.3);
}

.glow-gold {
  box-shadow: 0 0 1.875rem rgba(255, 215, 0, 0.3);
}

/* Scrollbar Styling */
::-webkit-scrollbar {
  width: 0.5rem;
  height: 0.5rem;
}

::-webkit-scrollbar-track {
  background: var(--color-darker);
}

::-webkit-scrollbar-thumb {
  background: var(--gradient-accent);
  border-radius: 0.25rem;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary);
}

/* Selection */
::selection {
  background: rgba(230, 57, 70, 0.3);
  color: #fff;
}
