/* Блок «Создайте курс с AI»: заметный, тёмный, с анимацией. Цвета — палитра брендбука «Все спим». */
:root {
  --ai-deep: #14352d;
  --ai-mid: #274b42;
  --ai-mint: #d0f2d8;
  --ai-emerald: #4d8a7d;
  --ai-milk: #f8f8f0;
}

.ai-spotlight {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(56px, 8vw, 104px) 0;
  color: var(--ai-milk);
  background: linear-gradient(135deg, var(--ai-deep) 0%, var(--ai-mid) 52%, #1d5a4e 100%);
}
.ai-orbs { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.ai-orbs i {
  position: absolute; border-radius: 50%; filter: blur(70px); opacity: .55;
  animation: ai-drift 16s ease-in-out infinite alternate;
}
.ai-orbs i:nth-child(1) { width: 520px; height: 520px; left: -140px; top: -160px; background: var(--ai-emerald); }
.ai-orbs i:nth-child(2) { width: 440px; height: 440px; right: -120px; top: 20%; background: #2f8f7a; animation-duration: 21s; animation-delay: -6s; }
.ai-orbs i:nth-child(3) { width: 380px; height: 380px; left: 38%; bottom: -200px; background: var(--ai-mint); opacity: .22; animation-duration: 18s; animation-delay: -3s; }

.ai-spotlight .course-copy h2 { color: var(--ai-milk); }
.ai-spotlight .course-copy p { color: #d6e9dc; max-width: 52ch; }
.ai-spotlight .course-takeaway { background: rgba(208, 242, 216, .14); color: var(--ai-mint); border: 1px solid rgba(208, 242, 216, .35); }

.ai-badge {
  position: relative; display: inline-flex; align-items: center; gap: 9px; overflow: hidden;
  padding: 8px 15px; border-radius: 999px; font-size: 12px; font-weight: 800; letter-spacing: .08em;
  color: var(--ai-deep); background: var(--ai-mint);
}
.ai-badge::after {
  content: ''; position: absolute; inset: 0; transform: translateX(-120%);
  background: linear-gradient(100deg, transparent 20%, rgba(255, 255, 255, .85) 50%, transparent 80%);
  animation: ai-sweep 3.2s ease-in-out infinite;
}
.ai-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ai-emerald); animation: ai-pulse 1.6s ease-out infinite; }

.ai-shimmer {
  font-style: normal;
  background: linear-gradient(90deg, #d0f2d8, #ffffff, #7fe0b0, #d0f2d8, #ffffff);
  background-size: 300% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: ai-sheen 4.5s linear infinite;
}

.ai-steps { list-style: none; margin: 22px 0 22px; padding: 0; display: grid; gap: 12px; }
.ai-steps li { display: flex; align-items: center; gap: 12px; color: #e7f3ea; font-weight: 600; }
.ai-steps b {
  flex: 0 0 auto; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%;
  color: var(--ai-deep); background: var(--ai-mint); font-size: 14px;
}

.ai-card {
  position: relative; border: 2px solid transparent; color: var(--launch-ink);
  background: linear-gradient(#f3f7ee, #f3f7ee) padding-box, linear-gradient(120deg, #d0f2d8, #4d8a7d, #ffffff, #d0f2d8) border-box;
  background-size: 100% 100%, 300% 300%;
  animation: ai-border 6s linear infinite;
  box-shadow: 0 0 0 6px rgba(208, 242, 216, .12), 0 30px 80px rgba(0, 0, 0, .38);
}
.ai-card h3 { display: flex; align-items: center; gap: 8px; }
.ai-spark { color: var(--ai-emerald); animation: ai-twinkle 2.4s ease-in-out infinite; }

.ai-cta { position: relative; overflow: hidden; animation: ai-glow 2.6s ease-in-out infinite; }
.ai-cta::after {
  content: ''; position: absolute; inset: 0; transform: translateX(-130%);
  background: linear-gradient(100deg, transparent 25%, rgba(255, 255, 255, .35) 50%, transparent 75%);
  animation: ai-sweep 3.6s ease-in-out infinite;
}
.ai-cta:disabled { animation: none; }

.course-gate > p { margin: 0 0 16px; }
.js-fields { border: 0; min-width: 0; padding: 0; margin: 0; }
.js-fields:disabled button { opacity: .75; cursor: wait; }
.js-fields button[type="submit"] { display: flex; width: 100%; }
.js-feedback { margin: 12px 0 0; }
.js-feedback:empty { display: none; }
.js-feedback.is-error { color: #883b2c; }
.lead-call a[hidden], .lead-call [hidden] { display: none; }

.nav-ai {
  color: var(--ai-deep) !important; font-weight: 800;
  padding: 7px 14px; border-radius: 999px;
  background: linear-gradient(90deg, #d0f2d8, #ffffff, #8fe3b0, #d0f2d8);
  background-size: 300% 100%; animation: ai-sheen 5s linear infinite;
}
.ai-hero-cta {
  display: inline-flex; align-items: center; gap: 8px; margin-left: 12px;
  color: var(--ai-deep); background: linear-gradient(90deg, #d0f2d8, #ffffff, #8fe3b0, #d0f2d8);
  background-size: 300% 100%; animation: ai-sheen 5s linear infinite;
  border: 1px solid #a9d9b8; font-weight: 800;
}

/* Прогресс генерации */
.ai-progress { margin-top: 18px; padding: 16px; border-radius: 14px; background: #fcfcf5; border: 1px solid #cfe0d2; }
.ai-progress-bar { height: 10px; border-radius: 999px; background: #dfe9dd; overflow: hidden; }
.ai-progress-bar span {
  display: block; height: 100%; width: 0; border-radius: inherit; transition: width .5s ease;
  background: linear-gradient(90deg, #4d8a7d, #7fe0b0, #4d8a7d); background-size: 200% 100%;
  animation: ai-sheen 1.8s linear infinite;
}
.ai-progress-text { margin: 10px 0 8px; font-weight: 800; }
.ai-progress-stages { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; font-size: 14px; color: #6a7f72; }
.ai-progress-stages li::before { content: '○ '; }
.ai-progress-stages li.is-active { color: var(--ai-deep); font-weight: 700; }
.ai-progress-stages li.is-active::before { content: '◉ '; color: var(--ai-emerald); }
.ai-progress-stages li.is-done::before { content: '✓ '; color: var(--ai-emerald); }

/* Тест с проверкой ответов */
.quiz { display: grid; gap: 14px; margin-top: 8px; }
.quiz-q { margin: 0; padding: 14px 16px; border: 1px solid #d3ddd0; border-radius: 12px; display: grid; gap: 8px; min-width: 0; }
.quiz-q legend { padding: 0 6px; font-weight: 800; }
.quiz-opt { display: flex; align-items: baseline; gap: 10px; padding: 9px 12px; border-radius: 10px; border: 1px solid transparent; cursor: pointer; }
.quiz-opt:hover { background: #eef3ea; }
.quiz-opt input { flex: 0 0 auto; accent-color: var(--ai-emerald); }
.quiz-opt:has(input:checked) { border-color: var(--ai-emerald); background: #e6f1e6; }
.quiz-q.is-correct { border-color: #4d8a7d; background: #f0f8f1; }
.quiz-q.is-wrong { border-color: #c9795f; background: #fdf3ee; }
.quiz-opt.is-right { border-color: #4d8a7d; background: #dcf0e0; font-weight: 700; }
.quiz-note { margin: 4px 0 0; font-size: 14px; }
.quiz-summary { margin: 0; font-size: 18px; font-weight: 800; }
.quiz-summary:empty { display: none; }
.quiz-retry { background: transparent; border: 1px solid var(--ai-mid); color: var(--ai-mid); width: fit-content; }
.quiz > .button { width: fit-content; }

@keyframes ai-sheen { from { background-position: 0% 50%; } to { background-position: 300% 50%; } }
@keyframes ai-sweep { 0% { transform: translateX(-130%); } 55%, 100% { transform: translateX(130%); } }
@keyframes ai-drift { from { transform: translate3d(0, 0, 0) scale(1); } to { transform: translate3d(70px, 50px, 0) scale(1.12); } }
@keyframes ai-pulse { 0% { box-shadow: 0 0 0 0 rgba(77, 138, 125, .7); } 100% { box-shadow: 0 0 0 10px rgba(77, 138, 125, 0); } }
@keyframes ai-glow { 0%, 100% { box-shadow: 0 0 0 0 rgba(77, 138, 125, .55); } 50% { box-shadow: 0 0 0 10px rgba(77, 138, 125, 0); } }
@keyframes ai-border { from { background-position: 0 0, 0% 50%; } to { background-position: 0 0, 300% 50%; } }
@keyframes ai-twinkle { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .5; transform: scale(.8) rotate(20deg); } }

@media (prefers-reduced-motion: reduce) {
  .ai-orbs i, .ai-badge::after, .ai-dot, .ai-shimmer, .ai-card, .ai-spark, .ai-cta, .ai-cta::after, .nav-ai, .ai-hero-cta, .ai-progress-bar span { animation: none; }
}
@media (max-width: 680px) {
  .ai-hero-cta { margin: 10px 0 0; }
  .nav-ai { display: inline-block; }
}

.ai-spotlight .course-result, .ai-spotlight .ai-progress, .ai-spotlight .ai-card { color: var(--launch-ink); }
.ai-spotlight .course-result h3, .ai-spotlight .course-result h4 { color: var(--launch-ink); }

.nav-ai { white-space: nowrap; line-height: 1.2; font-size: 13px; padding: 7px 13px; }
.hero-actions { flex-wrap: wrap; row-gap: 12px; }
.ai-hero-cta { margin-left: 0; white-space: nowrap; }
@media (min-width: 681px) { .ai-hero-cta { margin-left: 4px; } }
