.hero-visual {
  position: relative;
  overflow: visible;
  padding: 1.1rem;
  border-radius: 2.25rem;
  border: 1px solid rgba(148, 163, 184, 0.45);
  background: linear-gradient(145deg, #ffffff 0%, #f2f5fb 100%);
  box-shadow: 0 28px 60px rgba(15, 23, 42, 0.12);
}

.hero-visual::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(circle at 20% 15%, rgba(37, 99, 235, 0.14), transparent 45%),
    radial-gradient(circle at 82% 70%, rgba(15, 23, 42, 0.08), transparent 52%);
  opacity: 0.8;
  pointer-events: none;
}

.hero-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background-image:
    linear-gradient(to right, rgba(15, 23, 42, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 23, 42, 0.04) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.35;
  pointer-events: none;
}

.feature-icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: clamp(2.6rem, 4vw, 3.2rem);
  height: clamp(2.6rem, 4vw, 3.2rem);
  min-width: clamp(2.6rem, 4vw, 3.2rem);
  border-radius: clamp(0.85rem, 2vw, 1.1rem);
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.16), rgba(37, 99, 235, 0.08));
  color: var(--color-primary);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.12), 0 10px 20px rgba(15, 23, 42, 0.08);
}

.feature-icon .ph-bold {
  font-size: clamp(1rem, 2vw, 1.25rem);
  line-height: 1;
}

.mobile-hidden {
  display: none;
}

@media (min-width: 40rem) {
  .mobile-hidden {
    display: inline-flex;
  }

  .mobile-hidden.feature-icon {
    display: grid;
  }
}

.assistant-workspace {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  height: 100%;
  border-radius: 1.6rem;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 18px 40px rgba(15, 23, 42, 0.08);
  padding: 1rem;
  overflow: hidden;
  backdrop-filter: blur(12px);
}

.assistant-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.65rem;
  font-weight: 600;
  color: #475569;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.assistant-context {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.assistant-dot {
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 999px;
  background: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.assistant-status {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.1);
  color: #1d4ed8;
  font-size: 0.6rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0.02em;
}

.assistant-body {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 0.75rem;
  flex: 1;
  min-height: 0;
}

.assistant-thread {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.assistant-message {
  border-radius: 1rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(247, 248, 252, 0.9);
  padding: 0.65rem 0.75rem;
  font-size: 0.72rem;
  color: #0f172a;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.assistant-message--user {
  background: rgba(255, 255, 255, 0.95);
  border-style: dashed;
}

.assistant-message__meta {
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94a3b8;
}

.assistant-message__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  font-size: 0.6rem;
  color: #64748b;
}

.assistant-message__tags span {
  padding: 0.2rem 0.45rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.06);
}

.assistant-sidebar {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.assistant-panel {
  border-radius: 1rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(248, 250, 252, 0.9);
  padding: 0.6rem 0.7rem;
}

.assistant-panel__title {
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #64748b;
  margin-bottom: 0.3rem;
}

.assistant-panel__value {
  font-size: 0.82rem;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 0.35rem;
}

.assistant-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.assistant-chip {
  padding: 0.2rem 0.45rem;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.12);
  color: #1d4ed8;
  font-size: 0.6rem;
  font-weight: 600;
}

.assistant-sources {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.62rem;
  color: #475569;
}

.assistant-sources li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.assistant-sources li span {
  color: #2563eb;
  font-size: 0.7rem;
}

.assistant-input {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.55rem 0.7rem;
  border-radius: 0.95rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.8);
  color: #94a3b8;
  font-size: 0.7rem;
}

.assistant-input__hint {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.assistant-input__icons {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.assistant-input__icons span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 0.6rem;
  background: rgba(15, 23, 42, 0.06);
  color: #475569;
  font-size: 0.8rem;
}

.assistant-float {
  position: absolute;
  z-index: 2;
  padding: 0.65rem 0.75rem;
  border-radius: 1.2rem;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.12);
  backdrop-filter: blur(12px);
  font-size: 0.65rem;
  color: #475569;
  animation: floatCard 8s ease-in-out infinite;
}

.assistant-float--experts {
  top: 0.6rem;
  right: -0.4rem;
  width: 42%;
  max-width: 220px;
}

.assistant-float--quiz {
  bottom: -0.5rem;
  left: -0.4rem;
  width: 46%;
  max-width: 230px;
  animation-delay: 0.6s;
}

.assistant-float__header {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.62rem;
  font-weight: 600;
  color: #0f172a;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.assistant-float__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: 0.5rem;
}

.assistant-float__chips span {
  padding: 0.2rem 0.45rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(248, 250, 252, 0.9);
  font-size: 0.58rem;
  color: #475569;
}

.assistant-float__note {
  margin-top: 0.45rem;
  font-size: 0.58rem;
  color: #64748b;
}

.assistant-float__desc {
  margin-top: 0.45rem;
  font-size: 0.6rem;
  color: #64748b;
}

.assistant-float__meter {
  margin-top: 0.5rem;
}

.assistant-float__meter-label {
  display: block;
  font-size: 0.58rem;
  color: #475569;
  margin-bottom: 0.35rem;
}

.assistant-float__bar {
  height: 0.35rem;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.35);
  overflow: hidden;
}

.assistant-float__bar span {
  display: block;
  height: 100%;
  width: 72%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2563eb 0%, #1d4ed8 100%);
}

@media (min-width: 64rem) {
  .hero-visual {
    height: 460px;
  }
}

@keyframes floatCard {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .assistant-float {
    animation: none;
  }
}
