/* ============================================
   Atlantic Ace Casino - Custom Styles
   Coastal Elegance | Navy-Gold Tones
   ============================================ */

/* CSS Custom Properties */
:root {
  --navy-900: #0a1628;
  --navy-800: #0f2140;
  --navy-700: #1a3a5c;
  --navy-600: #264a6e;
  --gold-500: #d4af37;
  --gold-400: #e5c158;
  --gold-300: #f0d77a;
  --cream-100: #faf8f5;
  --cream-200: #f5f0e8;
  --teal-accent: #2dd4bf;
  --coral-accent: #f97068;
}

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

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

/* Particle Float Animation */
@keyframes particleFloat {
  0%, 100% {
    transform: translateY(0) translateX(0) scale(1);
    opacity: 0.6;
  }
  25% {
    transform: translateY(-1.5rem) translateX(0.5rem) scale(1.1);
    opacity: 0.8;
  }
  50% {
    transform: translateY(-2.5rem) translateX(-0.5rem) scale(1);
    opacity: 0.5;
  }
  75% {
    transform: translateY(-1rem) translateX(1rem) scale(0.9);
    opacity: 0.7;
  }
}

@keyframes particleDrift {
  0% {
    transform: translateY(100%) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 0.8;
  }
  90% {
    opacity: 0.8;
  }
  100% {
    transform: translateY(-100vh) rotate(360deg);
    opacity: 0;
  }
}

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

/* Shimmer Effect */
@keyframes shimmer {
  0% {
    background-position: -200% center;
  }
  100% {
    background-position: 200% center;
  }
}

/* Pulse Glow */
@keyframes pulseGlow {
  0%, 100% {
    box-shadow: 0 0 1rem rgba(212, 175, 55, 0.4);
  }
  50% {
    box-shadow: 0 0 2rem rgba(212, 175, 55, 0.7);
  }
}

/* Wave Animation */
@keyframes waveMotion {
  0% {
    transform: translateX(0) translateY(0);
  }
  50% {
    transform: translateX(-2%) translateY(0.25rem);
  }
  100% {
    transform: translateX(0) translateY(0);
  }
}

/* Fade In Up */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(1.5rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

.animate-particle {
  animation: particleFloat 6s ease-in-out infinite;
}

.animate-particle-drift {
  animation: particleDrift 15s linear infinite;
}

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

.animate-shimmer {
  background: linear-gradient(90deg, transparent 0%, rgba(212, 175, 55, 0.3) 50%, transparent 100%);
  background-size: 200% 100%;
  animation: shimmer 3s infinite;
}

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

.animate-wave {
  animation: waveMotion 8s ease-in-out infinite;
}

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

/* Staggered Delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }
.delay-700 { animation-delay: 0.7s; }
.delay-1000 { animation-delay: 1s; }

/* ============================================
   Particle System
   ============================================ */

.particle-container {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 1;
}

.particle {
  position: absolute;
  width: 0.5rem;
  height: 0.5rem;
  background: radial-gradient(circle, var(--gold-400) 0%, transparent 70%);
  border-radius: 50%;
  animation: particleDrift 12s linear infinite;
}

.particle:nth-child(1) { left: 10%; animation-delay: 0s; animation-duration: 14s; }
.particle:nth-child(2) { left: 20%; animation-delay: 2s; animation-duration: 12s; }
.particle:nth-child(3) { left: 35%; animation-delay: 4s; animation-duration: 16s; }
.particle:nth-child(4) { left: 50%; animation-delay: 1s; animation-duration: 13s; }
.particle:nth-child(5) { left: 65%; animation-delay: 3s; animation-duration: 15s; }
.particle:nth-child(6) { left: 80%; animation-delay: 5s; animation-duration: 11s; }
.particle:nth-child(7) { left: 90%; animation-delay: 2.5s; animation-duration: 14s; }

/* ============================================
   Marquee Component
   ============================================ */

.marquee-wrapper {
  overflow: hidden;
  white-space: nowrap;
}

.marquee-content {
  display: inline-flex;
  animation: marqueeScroll 25s linear infinite;
}

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

/* ============================================
   Navigation Overrides
   ============================================ */

.nav-sticky {
  backdrop-filter: blur(0.75rem);
  -webkit-backdrop-filter: blur(0.75rem);
}

.mobile-menu-bg {
  background-color: var(--navy-900);
  opacity: 1;
}

.nav-link-hover {
  position: relative;
}

.nav-link-hover::after {
  content: '';
  position: absolute;
  bottom: -0.25rem;
  left: 0;
  width: 0;
  height: 0.125rem;
  background: linear-gradient(90deg, var(--gold-500), var(--gold-300));
  transition: width 0.3s ease;
}

.nav-link-hover:hover::after {
  width: 100%;
}

/* ============================================
   Button Styles
   ============================================ */

.btn-primary {
  background: linear-gradient(135deg, var(--gold-500) 0%, var(--gold-400) 100%);
  color: var(--navy-900);
  font-weight: 700;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.5s ease;
}

.btn-primary:hover::before {
  left: 100%;
}

.btn-primary:hover {
  transform: translateY(-0.125rem);
  box-shadow: 0 0.5rem 1.5rem rgba(212, 175, 55, 0.4);
}

.btn-secondary {
  background: transparent;
  border: 0.125rem solid var(--gold-500);
  color: var(--gold-400);
  font-weight: 600;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background: var(--gold-500);
  color: var(--navy-900);
}

/* ============================================
   Card Styles
   ============================================ */

.card-coastal {
  background: linear-gradient(145deg, var(--navy-800) 0%, var(--navy-900) 100%);
  border: 0.0625rem solid rgba(212, 175, 55, 0.2);
  transition: all 0.3s ease;
}

.card-coastal:hover {
  border-color: var(--gold-500);
  transform: translateY(-0.25rem);
  box-shadow: 0 1rem 2rem rgba(0, 0, 0, 0.3);
}

/* ============================================
   Table Responsive Wrapper
   ============================================ */

.table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  width: 100%;
}

.table-responsive table {
  min-width: 100%;
}

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

.prose {
  color: var(--cream-100);
  font-size: 1rem;
  line-height: 1.75;
  max-width: 100%;
}

.prose h2 {
  color: var(--gold-400);
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  margin-top: 2.5em;
  margin-bottom: 1em;
  padding-bottom: 0.5em;
  border-bottom: 0.125rem solid rgba(212, 175, 55, 0.3);
  line-height: 1.3;
}

.prose h3 {
  color: var(--gold-300);
  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: var(--cream-100);
  font-size: clamp(1.1rem, 2.5vw, 1.25rem);
  font-weight: 600;
  margin-top: 1.5em;
  margin-bottom: 0.5em;
}

.prose p {
  margin-bottom: 1.25em;
  color: var(--cream-200);
}

.prose a {
  color: var(--gold-400);
  text-decoration: underline;
  text-underline-offset: 0.2em;
  transition: color 0.2s ease;
}

.prose a:hover {
  color: var(--gold-300);
}

.prose strong {
  color: var(--cream-100);
  font-weight: 700;
}

.prose em {
  color: var(--gold-300);
  font-style: italic;
}

/* Prose Lists */
.prose ul {
  list-style: none;
  padding-left: 1.5em;
  margin-bottom: 1.5em;
}

.prose ul li {
  position: relative;
  margin-bottom: 0.75em;
  padding-left: 0.5em;
  color: var(--cream-200);
}

.prose ul li::before {
  content: '◆';
  position: absolute;
  left: -1.25em;
  color: var(--gold-500);
  font-size: 0.6em;
  top: 0.5em;
}

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

.prose ol li {
  position: relative;
  margin-bottom: 0.75em;
  padding-left: 0.5em;
  color: var(--cream-200);
  counter-increment: prose-counter;
}

.prose ol li::before {
  content: counter(prose-counter) '.';
  position: absolute;
  left: -1.5em;
  color: var(--gold-500);
  font-weight: 700;
}

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

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

.prose thead {
  background: linear-gradient(135deg, var(--navy-700) 0%, var(--navy-800) 100%);
}

.prose th {
  color: var(--gold-400);
  font-weight: 700;
  text-align: left;
  padding: 1em;
  border-bottom: 0.125rem solid var(--gold-500);
  white-space: nowrap;
}

.prose td {
  padding: 1em;
  border-bottom: 0.0625rem solid rgba(212, 175, 55, 0.15);
  color: var(--cream-200);
}

.prose tbody tr {
  background: var(--navy-800);
  transition: background 0.2s ease;
}

.prose tbody tr:nth-child(even) {
  background: var(--navy-900);
}

.prose tbody tr:hover {
  background: var(--navy-700);
}

/* Prose Blockquotes */
.prose blockquote {
  border-left: 0.25rem solid var(--gold-500);
  background: linear-gradient(135deg, rgba(26, 58, 92, 0.5) 0%, rgba(15, 33, 64, 0.5) 100%);
  padding: 1.5em 2em;
  margin: 2em 0;
  border-radius: 0 0.5rem 0.5rem 0;
  font-style: italic;
  color: var(--cream-200);
}

.prose blockquote p {
  margin-bottom: 0;
}

/* Prose Images */
.prose img {
  max-width: 100%;
  height: auto;
  border-radius: 0.75rem;
  margin: 2em auto;
  display: block;
  box-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.3);
  border: 0.0625rem solid rgba(212, 175, 55, 0.2);
}

/* Prose Code */
.prose code {
  background: var(--navy-700);
  color: var(--gold-300);
  padding: 0.2em 0.4em;
  border-radius: 0.25rem;
  font-size: 0.875em;
  font-family: 'Monaco', 'Consolas', monospace;
}

.prose pre {
  background: var(--navy-800);
  border: 0.0625rem solid rgba(212, 175, 55, 0.2);
  border-radius: 0.5rem;
  padding: 1.5em;
  overflow-x: auto;
  margin: 2em 0;
}

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

/* Prose Horizontal Rule */
.prose hr {
  border: none;
  height: 0.0625rem;
  background: linear-gradient(90deg, transparent, var(--gold-500), transparent);
  margin: 3em 0;
}

/* ============================================
   SVG Patterns
   ============================================ */

.wave-pattern {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 320'%3E%3Cpath fill='%230f2140' fill-opacity='0.5' d='M0,192L48,176C96,160,192,128,288,133.3C384,139,480,181,576,186.7C672,192,768,160,864,149.3C960,139,1056,149,1152,170.7C1248,192,1344,224,1392,240L1440,256L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: bottom;
  background-size: 100% auto;
}

/* ============================================
   Utility Overrides
   ============================================ */

.gradient-navy {
  background: linear-gradient(180deg, var(--navy-900) 0%, var(--navy-800) 100%);
}

.gradient-gold-text {
  background: linear-gradient(135deg, var(--gold-400) 0%, var(--gold-300) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.border-gold-subtle {
  border-color: rgba(212, 175, 55, 0.25);
}

.text-balance {
  text-wrap: balance;
}

/* ============================================
   Responsive Breakpoint Helpers
   ============================================ */

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

@media (min-width: 1024px) {
  .prose {
    font-size: 1.0625rem;
  }
}

/* ============================================
   Focus States for Accessibility
   ============================================ */

a:focus-visible,
button:focus-visible {
  outline: 0.125rem solid var(--gold-400);
  outline-offset: 0.125rem;
}

/* ============================================
   Print Styles
   ============================================ */

@media print {
  .particle-container,
  .animate-marquee {
    display: none;
  }
  
  .prose {
    color: #000;
  }
  
  .prose h2,
  .prose h3 {
    color: #1a1a1a;
  }
}
