/* AI Thinking Loader — styles
   Drop-in visual companion for the LotterySpy AI report. Does not touch
   after_wp1.php; this only styles the loading state and the staged reveal
   of whatever HTML that endpoint returns. */

.ai-thinking {
  position: relative;
  padding: 24px 26px;
  border-radius: 16px;
  background: linear-gradient(135deg, #FFFCF6 0%, #FFF8EC 100%);
  border: 1px solid rgba(184,134,43,0.28);
  color: #241C0F;
  overflow: hidden;
}

.ai-thinking-badge {
  display: inline-block;
  padding: 4px 12px;
  margin-bottom: 16px;
  border-radius: 999px;
  background: #B8862B;
  color: #FFFDF7;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
}

.ai-thinking-log {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 22px;
}

.ai-thinking-log li {
  position: relative;
  padding-left: 22px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
  color: #B8A98A;
}

.ai-thinking-log li.is-active { color: #6B4E14; }
.ai-thinking-log li.is-done { color: #6B4E14; }

.ai-thinking-log li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 5px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1.5px solid #D9C79E;
  transition: background .2s ease, border-color .2s ease;
}
.ai-thinking-log li.is-active::before {
  border-color: #B8862B;
  animation: ai-thinking-pulse 1.4s ease-in-out infinite;
}
.ai-thinking-log li.is-done::before {
  background: #B8862B;
  border-color: #B8862B;
}
/* checkmark on completed lines */
.ai-thinking-log li.is-done::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 8px;
  width: 4px;
  height: 2px;
  border-left: 1.5px solid #FFFDF7;
  border-bottom: 1.5px solid #FFFDF7;
  transform: rotate(-45deg);
}

.ai-thinking-cursor {
  display: inline-block;
  width: 2px;
  height: 14px;
  margin-left: 2px;
  vertical-align: -2px;
  background: #B8862B;
  animation: ai-thinking-blink 0.9s step-end infinite;
}

@keyframes ai-thinking-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.5); opacity: .5; }
}
@keyframes ai-thinking-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* ---------- Staged reveal of the real report once it arrives ---------- */
.ai-reveal-pending {
  opacity: 0;
  transform: translateY(10px);
}
.ai-reveal-in {
  opacity: 1;
  transform: translateY(0);
  transition: opacity .45s ease, transform .45s ease;
}

@media (prefers-reduced-motion: reduce) {
  .ai-thinking-log li.is-active::before,
  .ai-thinking-cursor { animation: none; }
  .ai-reveal-pending, .ai-reveal-in { transition: none; opacity: 1; transform: none; }
}
