/* Filmové krystalické jádro ELIAᵖ.
   Klid = ENERGY FLOW, hlas = FRACTAL FORM. */
.ai-orb-wrap {
  width: 430px;
  height: 430px;
  transform: translate(-50%, -49%);
}

.ai-orb {
  position: relative;
  width: 430px;
  height: 430px;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  animation: diamond-breathe 5.8s ease-in-out infinite;
}

.ai-orb::before,
.ai-orb::after { display: none; }

.diamond-aura {
  position: absolute;
  z-index: 0;
  inset: 28px;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 49%, rgba(250,255,194,.38), rgba(82,255,65,.22) 22%, rgba(12,159,55,.09) 47%, transparent 71%);
  filter: blur(25px);
  animation: diamond-aura 4.4s ease-in-out infinite;
}

.diamond-visual {
  position: absolute;
  z-index: 3;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.diamond-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  user-select: none;
  transition: opacity .58s ease, transform .75s cubic-bezier(.18,.72,.16,1), filter .58s ease;
  will-change: opacity, transform, filter;
}

.energy-canvas {
  position: absolute;
  z-index: 2;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 1;
  transform: scale(1.12);
  filter: brightness(1.04) saturate(1.08) drop-shadow(0 0 10px rgba(255,232,112,.68)) drop-shadow(0 0 31px rgba(46,255,68,.48));
  pointer-events: none;
  transition: opacity .52s ease, transform .7s ease, filter .48s ease;
}

.fragment-video-source { display: none; }

.diamond-speaking-canvas {
  z-index: 3;
  opacity: 0;
  transform: scale(.84);
  filter: blur(3px) brightness(.82) saturate(1.08) drop-shadow(0 0 22px rgba(65,255,82,.48));
}

.diamond-particles {
  position: absolute;
  z-index: 4;
  inset: 28px;
  pointer-events: none;
}

.diamond-particles i {
  --x:50%; --y:50%; --delay:0s;
  position: absolute;
  top: var(--y);
  left: var(--x);
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #fff4a2;
  box-shadow: 0 0 8px #fff6aa, 0 0 18px #57ff36;
  opacity: .5;
  animation: particle-idle 3.7s var(--delay) ease-in-out infinite;
}

.diamond-particles i:nth-child(1){--x:13%;--y:27%;--delay:-.3s}.diamond-particles i:nth-child(2){--x:81%;--y:23%;--delay:-1.1s}.diamond-particles i:nth-child(3){--x:9%;--y:56%;--delay:-2.2s}.diamond-particles i:nth-child(4){--x:90%;--y:54%;--delay:-.7s}.diamond-particles i:nth-child(5){--x:26%;--y:78%;--delay:-1.8s}.diamond-particles i:nth-child(6){--x:74%;--y:81%;--delay:-2.8s}.diamond-particles i:nth-child(7){--x:36%;--y:12%;--delay:-1.4s}.diamond-particles i:nth-child(8){--x:63%;--y:9%;--delay:-2.4s}.diamond-particles i:nth-child(9){--x:20%;--y:43%;--delay:-.9s}.diamond-particles i:nth-child(10){--x:79%;--y:42%;--delay:-2s}.diamond-particles i:nth-child(11){--x:42%;--y:88%;--delay:-1.6s}.diamond-particles i:nth-child(12){--x:57%;--y:91%;--delay:-.5s}

.orb-content {
  position: absolute;
  z-index: 6;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  text-align: center;
  text-shadow: 0 0 9px #efff9e, 0 0 26px rgba(89,255,48,.98), 0 2px 8px #001d09;
}

.orb-content::before {
  position: absolute;
  z-index: -1;
  width: 190px;
  height: 105px;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(0,21,9,.72), rgba(0,19,8,.28) 54%, transparent 74%);
  filter: blur(4px);
  content: "";
}

.orb-content strong {
  margin: 0;
  color: #fff8c4;
  font: 800 2.05rem/1 Georgia,serif;
  letter-spacing: .065em;
  white-space: nowrap;
}

.orb-content span:not(.orb-diamond) {
  margin-top: 8px;
  color: #e7ffb3;
  font-size: .62rem;
  font-weight: 900;
  letter-spacing: .27em;
  white-space: nowrap;
}

.orb-content i {
  width: 52px;
  height: 2px;
  margin-top: 14px;
  border-radius: 8px;
  background: linear-gradient(90deg,transparent,#fff4a0,transparent);
  box-shadow: 0 0 17px var(--lime);
}

.ai-core-stage.thinking .diamond-aura { animation-duration: 1.25s; }
.ai-core-stage.thinking .energy-canvas { filter:brightness(1.24) saturate(1.18) drop-shadow(0 0 15px #fff0a0) drop-shadow(0 0 44px rgba(47,255,64,.78)); }
.ai-core-stage.listening .diamond-aura { filter: blur(17px); opacity: .98; }
.ai-core-stage.listening .energy-canvas { filter:brightness(1.16) saturate(1.12) drop-shadow(0 0 14px #fff0ae) drop-shadow(0 0 42px rgba(57,255,81,.74)); }

.ai-core-stage.speaking .ai-orb { animation: none; }
.ai-core-stage.speaking .energy-canvas { opacity: 0; }
.ai-core-stage.speaking .diamond-speaking-canvas {
  opacity: 1;
  transform: scale(1.06);
  filter: brightness(1.08) saturate(1.12) drop-shadow(0 0 11px rgba(255,230,102,.72)) drop-shadow(0 0 38px rgba(53,255,75,.66));
}
.ai-core-stage.speaking .diamond-aura { animation-duration: .72s; opacity: 1; }
.ai-core-stage.speaking .diamond-particles i { animation: particle-voice .8s var(--delay) ease-in-out infinite; opacity: 1; }
.ai-core-stage.speaking .orb-content { animation: title-voice .72s ease-in-out infinite alternate; }

@keyframes diamond-breathe { 50% { transform:translateY(-3px) scale(1.015); } }
@keyframes diamond-aura { 50% { transform:scale(1.12); opacity:.74; } }
@keyframes particle-idle { 50% { opacity:1; transform:scale(1.8); } }
@keyframes particle-voice { 50% { transform:translateY(-12px) scale(2.6); box-shadow:0 0 13px #fff5ae,0 0 31px #65ff37; } }
@keyframes title-voice { to { filter:brightness(1.28); text-shadow:0 0 15px #ffffba,0 0 38px #72ff38; } }

@media(max-width:480px) { .ai-orb-wrap { transform:translate(-50%,-49%) scale(.72); } }
@media(prefers-reduced-motion:reduce) { .ai-orb,.diamond-aura,.diamond-image,.diamond-particles i,.orb-content { animation-duration:8s!important; } }
