/* ========================================
   MAFIA ONLINE CASINO - CUSTOM STYLES
   Midnight Luxe Theme - France Edition
   ======================================== */

/* ----------------------------------------
   CSS VARIABLES
   ---------------------------------------- */
:root {
  --color-midnight-900: #0a0a12;
  --color-midnight-800: #12121f;
  --color-midnight-700: #1a1a2e;
  --color-midnight-600: #252542;
  --color-gold-400: #f4d03f;
  --color-gold-500: #d4af37;
  --color-gold-600: #b8962e;
  --color-cream-100: #faf8f5;
  --color-cream-200: #f0ebe3;
  --color-cream-300: #e6dfd4;
}

/* ----------------------------------------
   BASE STYLES
   ---------------------------------------- */
html {
  overflow-x: clip;
  overflow-y: auto;
  scroll-behavior: smooth;
}

body {
  overflow-x: clip;
}

/* ----------------------------------------
   PARTICLE ANIMATIONS
   ---------------------------------------- */
.particle-container {
  z-index: 0;
}

.particle {
  position: absolute;
  width: 0.5rem;
  height: 0.5rem;
  background: radial-gradient(circle, var(--color-gold-400), transparent);
  border-radius: 50%;
  opacity: 0.4;
  animation: particleFloat 15s infinite ease-in-out;
}

.particle-1 {
  top: 10%;
  left: 10%;
  animation-delay: 0s;
  animation-duration: 18s;
}

.particle-2 {
  top: 20%;
  right: 15%;
  animation-delay: 2s;
  animation-duration: 22s;
}

.particle-3 {
  top: 60%;
  left: 20%;
  animation-delay: 4s;
  animation-duration: 20s;
}

.particle-4 {
  top: 70%;
  right: 25%;
  animation-delay: 6s;
  animation-duration: 16s;
}

.particle-5 {
  top: 40%;
  left: 5%;
  animation-delay: 8s;
  animation-duration: 24s;
}

.particle-6 {
  top: 80%;
  right: 10%;
  animation-delay: 10s;
  animation-duration: 19s;
}

@keyframes particleFloat {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.3;
  }
  25% {
    transform: translate(2rem, -3rem) scale(1.2);
    opacity: 0.6;
  }
  50% {
    transform: translate(-1rem, -5rem) scale(0.8);
    opacity: 0.4;
  }
  75% {
    transform: translate(3rem, -2rem) scale(1.1);
    opacity: 0.5;
  }
}

/* ----------------------------------------
   TILT EFFECT BASE
   ---------------------------------------- */
.tilt-element {
  transition: transform 0.15s ease-out;
  transform-style: preserve-3d;
}

/* ----------------------------------------
   TABLE RESPONSIVE WRAPPER
   ---------------------------------------- */
.table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

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

/* ----------------------------------------
   PROSE STYLING FOR MARKDOWN CONTENT
   ---------------------------------------- */
.prose {
  color: var(--color-cream-200);
  font-size: 1rem;
  line-height: 1.75;
  max-width: 100%;
}

/* Headings */
.prose h2 {
  color: var(--color-cream-100);
  font-family: Georgia, serif;
  font-size: clamp(1.5rem, 4vw, 1.875rem);
  font-weight: 700;
  margin-top: 2.5em;
  margin-bottom: 1em;
  padding-bottom: 0.5em;
  border-bottom: 2px solid rgba(212, 175, 55, 0.2);
  line-height: 1.3;
}

.prose h2:first-child {
  margin-top: 0;
}

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

/* Paragraphs */
.prose p {
  margin-bottom: 1.5em;
  color: rgba(230, 223, 212, 0.85);
}

.prose p:last-child {
  margin-bottom: 0;
}

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

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

/* Strong & Emphasis */
.prose strong {
  color: var(--color-cream-100);
  font-weight: 600;
}

.prose em {
  font-style: italic;
  color: var(--color-cream-200);
}

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

.prose ul li {
  position: relative;
  padding-left: 1.75em;
  margin-bottom: 0.75em;
  color: rgba(230, 223, 212, 0.85);
}

.prose ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 0.5em;
  height: 0.5em;
  background: var(--color-gold-500);
  border-radius: 50%;
}

/* Lists - Ordered */
.prose ol {
  list-style: none;
  padding-left: 0;
  margin-bottom: 1.5em;
  counter-reset: list-counter;
}

.prose ol li {
  position: relative;
  padding-left: 2.5em;
  margin-bottom: 0.75em;
  color: rgba(230, 223, 212, 0.85);
  counter-increment: list-counter;
}

.prose ol li::before {
  content: counter(list-counter);
  position: absolute;
  left: 0;
  top: 0;
  width: 1.75em;
  height: 1.75em;
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8em;
  font-weight: 600;
  color: var(--color-gold-400);
}

/* Nested Lists */
.prose ul ul,
.prose ol ol,
.prose ul ol,
.prose ol ul {
  margin-top: 0.75em;
  margin-bottom: 0;
}

/* Tables */
.prose .table-responsive {
  margin: 2em 0;
  border-radius: 0.75rem;
  border: 1px solid rgba(212, 175, 55, 0.2);
  overflow-x: auto;
}

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

.prose thead {
  background: rgba(26, 26, 46, 0.8);
}

.prose th {
  padding: 1em 1.25em;
  text-align: left;
  font-weight: 600;
  color: var(--color-gold-400);
  border-bottom: 2px solid rgba(212, 175, 55, 0.3);
  white-space: nowrap;
}

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

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

.prose tbody tr:hover {
  background: rgba(26, 26, 46, 0.5);
}

/* Blockquotes */
.prose blockquote {
  margin: 2em 0;
  padding: 1.5em 2em;
  background: linear-gradient(135deg, rgba(26, 26, 46, 0.6), rgba(18, 18, 31, 0.6));
  border-left: 4px solid var(--color-gold-500);
  border-radius: 0 0.75rem 0.75rem 0;
  font-style: italic;
}

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

.prose blockquote p::before {
  content: open-quote;
  font-size: 1.5em;
  color: var(--color-gold-400);
  margin-right: 0.25em;
}

.prose blockquote p::after {
  content: close-quote;
  font-size: 1.5em;
  color: var(--color-gold-400);
  margin-left: 0.25em;
}

/* Images */
.prose img {
  max-width: 100%;
  height: auto;
  border-radius: 1rem;
  margin: 2em 0;
  border: 1px solid rgba(212, 175, 55, 0.2);
}

/* Horizontal Rule */
.prose hr {
  border: none;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.4), transparent);
  margin: 3em 0;
}

/* Code Inline */
.prose code {
  background: rgba(26, 26, 46, 0.8);
  padding: 0.2em 0.5em;
  border-radius: 0.375rem;
  font-size: 0.875em;
  color: var(--color-gold-400);
  font-family: ui-monospace, monospace;
}

/* Code Blocks */
.prose pre {
  background: var(--color-midnight-800);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 0.75rem;
  padding: 1.5em;
  overflow-x: auto;
  margin: 2em 0;
}

.prose pre code {
  background: transparent;
  padding: 0;
  color: var(--color-cream-200);
}

/* ----------------------------------------
   FOCUS STATES - ACCESSIBILITY
   ---------------------------------------- */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--color-gold-400);
  outline-offset: 2px;
}

/* ----------------------------------------
   ANIMATION UTILITIES
   ---------------------------------------- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(1.25rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

/* ----------------------------------------
   REDUCED MOTION PREFERENCES
   ---------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .particle {
    animation: none;
    opacity: 0.2;
  }

  .tilt-element {
    transform: none !important;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ----------------------------------------
   RESPONSIVE ADJUSTMENTS
   ---------------------------------------- */
@media (max-width: 640px) {
  .prose {
    font-size: 0.9375rem;
  }

  .prose h2 {
    margin-top: 2em;
  }

  .prose blockquote {
    padding: 1em 1.25em;
  }

  .prose th,
  .prose td {
    padding: 0.75em 1em;
  }
}
