:root {
  --rv-red: #e50914;
  --rv-red-strong: #ff161f;
  --rv-black: #08090a;
  --rv-panel: #101113;
  --rv-border: rgba(229, 9, 20, 0.72);
  --rv-white: #ffffff;
  --rv-muted: #b8b9bc;
  --rv-shadow: 0 22px 70px rgba(0, 0, 0, 0.54);
}

.rv-assistant,
.rv-assistant * {
  box-sizing: border-box;
}

.rv-assistant button,
.rv-assistant a {
  font: inherit;
}

.rv-assistant [hidden] {
  display: none !important;
}

.rv-intro {
  position: fixed;
  inset: 0;
  z-index: 2147482000;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--rv-white);
  background:
    radial-gradient(circle at 48% 56%, rgba(229, 9, 20, 0.22), transparent 34%),
    linear-gradient(145deg, rgba(0, 0, 0, 0.96), rgba(12, 5, 6, 0.93));
  opacity: 0;
  animation: rvIntroEnter 420ms ease forwards;
}

.rv-intro::before {
  content: "";
  position: absolute;
  inset: 0;
  backdrop-filter: blur(4px);
}

.rv-intro.is-closing {
  pointer-events: none;
  animation: rvIntroExit 500ms ease forwards;
}

.rv-intro__skip {
  position: absolute;
  top: max(18px, env(safe-area-inset-top));
  right: 22px;
  z-index: 3;
  min-height: 42px;
  padding: 8px 15px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  color: var(--rv-white);
  background: rgba(0, 0, 0, 0.46);
  cursor: pointer;
}

.rv-intro__glow {
  position: absolute;
  width: min(58vw, 680px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(229, 9, 20, 0.26), transparent 68%);
  filter: blur(16px);
  animation: rvGlow 2.8s ease-in-out infinite;
}

.rv-intro__content {
  position: relative;
  z-index: 2;
  width: min(1100px, calc(100vw - 38px));
  display: grid;
  grid-template-columns: minmax(230px, 0.8fr) minmax(280px, 1fr);
  align-items: center;
  gap: clamp(28px, 5vw, 76px);
}

.rv-intro__robot-wrap {
  display: flex;
  justify-content: center;
}

.rv-intro__robot {
  display: block;
  width: min(390px, 38vw);
  height: auto;
  filter: drop-shadow(0 22px 28px rgba(0, 0, 0, 0.45)) drop-shadow(0 0 22px rgba(229, 9, 20, 0.28));
  animation: rvRobotArrive 700ms cubic-bezier(.2,.8,.2,1) both, rvFloat 3.2s ease-in-out 700ms infinite;
}

.rv-kicker {
  margin: 0 0 13px;
  color: #ff6b72;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.rv-intro__copy h2 {
  margin: 0;
  max-width: 760px;
  font-size: clamp(2rem, 5vw, 4.8rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.rv-intro__copy > p:not(.rv-kicker) {
  max-width: 640px;
  margin: 18px 0 0;
  color: #f6f6f6;
  font-size: clamp(1rem, 1.8vw, 1.28rem);
  line-height: 1.55;
}

.rv-intro__copy .rv-intro__support {
  color: var(--rv-muted);
  font-size: 0.98rem;
}

.rv-primary-button {
  margin-top: 24px;
  min-height: 50px;
  padding: 12px 22px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 13px;
  color: var(--rv-white);
  background: linear-gradient(135deg, var(--rv-red-strong), #bd0008);
  box-shadow: 0 12px 32px rgba(229, 9, 20, 0.25);
  font-weight: 800;
  cursor: pointer;
}

.rv-trigger {
  position: fixed;
  right: 24px;
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 2147481000;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 82px;
  min-height: 82px;
  padding: 4px 13px 4px 4px;
  border: 1px solid var(--rv-border);
  border-radius: 999px;
  color: var(--rv-white);
  background: rgba(8, 9, 10, 0.92);
  box-shadow: 0 16px 44px rgba(0,0,0,.42), 0 0 24px rgba(229,9,20,.19);
  backdrop-filter: blur(12px);
  cursor: pointer;
  transform-origin: right bottom;
  animation: rvTriggerEnter 520ms ease both, rvPulse 9s ease-in-out 2s infinite;
}

.rv-trigger picture {
  display: grid;
  place-items: end center;
  width: 68px;
  height: 68px;
  overflow: visible;
}

.rv-trigger img {
  display: block;
  width: 52px;
  height: auto;
  filter: drop-shadow(0 8px 10px rgba(0,0,0,.34));
  animation: rvFloatSmall 3.6s ease-in-out infinite;
}

.rv-trigger__label {
  white-space: nowrap;
  font-size: 0.9rem;
  font-weight: 800;
}

.rv-trigger__notification {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 10px;
  height: 10px;
  border: 2px solid #0d0e10;
  border-radius: 50%;
  background: var(--rv-red-strong);
}

.rv-trigger:hover {
  transform: translateY(-2px) scale(1.025);
  box-shadow: 0 18px 48px rgba(0,0,0,.48), 0 0 34px rgba(229,9,20,.3);
}

.rv-panel {
  position: fixed;
  right: 24px;
  bottom: calc(118px + env(safe-area-inset-bottom));
  z-index: 2147481500;
  width: min(390px, calc(100vw - 32px));
  max-height: min(720px, 76vh);
  overflow: hidden;
  border: 1px solid var(--rv-border);
  border-radius: 22px;
  color: var(--rv-white);
  background: var(--rv-panel);
  box-shadow: var(--rv-shadow), 0 0 32px rgba(229,9,20,.17);
  animation: rvPanelEnter 220ms ease both;
}

.rv-panel__header {
  display: grid;
  grid-template-columns: 54px 1fr 40px;
  align-items: center;
  gap: 11px;
  padding: 14px 14px 13px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  background: #090a0b;
}

.rv-panel__avatar {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  overflow: hidden;
  border: 1px solid rgba(229,9,20,.5);
  border-radius: 15px;
  background: radial-gradient(circle, rgba(229,9,20,.17), transparent 70%);
}

.rv-panel__avatar img {
  width: 38px;
  height: auto;
}

.rv-panel__header h2 {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.2;
}

.rv-panel__header p {
  margin: 4px 0 0;
  color: var(--rv-muted);
  font-size: 0.78rem;
}

.rv-panel__close {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  color: var(--rv-white);
  background: rgba(255,255,255,.05);
  font-size: 1.55rem;
  line-height: 1;
  cursor: pointer;
}

.rv-panel__body {
  max-height: calc(min(720px, 76vh) - 78px);
  padding: 15px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.rv-panel__welcome {
  margin: 0 0 13px;
  padding: 13px 14px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 15px;
  color: #e8e8e8;
  background: rgba(255,255,255,.035);
  font-size: 0.86rem;
  line-height: 1.52;
}

.rv-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.rv-action {
  min-height: 92px;
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 15px;
  color: var(--rv-white);
  text-align: left;
  background: rgba(255,255,255,.035);
  cursor: pointer;
}

.rv-action:hover,
.rv-action:focus-visible {
  border-color: var(--rv-border);
  background: rgba(229,9,20,.09);
}

.rv-action--wide {
  grid-column: 1 / -1;
  min-height: 72px;
}

.rv-action__icon {
  flex: 0 0 30px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(229,9,20,.5);
  border-radius: 10px;
  color: #ff747a;
  font-size: 0.72rem;
  font-weight: 900;
}

.rv-action strong,
.rv-action small {
  display: block;
}

.rv-action strong {
  font-size: 0.86rem;
  line-height: 1.25;
}

.rv-action small {
  margin-top: 5px;
  color: var(--rv-muted);
  font-size: 0.71rem;
  line-height: 1.35;
}

.rv-panel__note {
  margin: 12px 0 0;
  color: #a9aaad;
  font-size: 0.7rem;
  line-height: 1.4;
}

.rv-panel__back {
  min-height: 40px;
  margin: 0 0 12px;
  padding: 7px 0;
  border: 0;
  color: #ff747a;
  background: transparent;
  font-weight: 800;
  cursor: pointer;
}

.rv-service-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.rv-service {
  min-height: 54px;
  padding: 10px 12px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 13px;
  color: var(--rv-white);
  background: rgba(255,255,255,.035);
  text-align: left;
  font-size: .82rem;
  font-weight: 750;
  cursor: pointer;
}

.rv-service:hover,
.rv-service:focus-visible {
  border-color: var(--rv-border);
  background: rgba(229,9,20,.1);
}

.rv-noscript {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 9999;
  padding: 12px 18px;
  border-radius: 999px;
  color: #fff;
  background: #e50914;
  text-decoration: none;
  font-weight: 800;
}

.rv-assistant button:focus-visible,
.rv-assistant a:focus-visible {
  outline: 3px solid rgba(255, 255, 255, 0.94);
  outline-offset: 3px;
}

@keyframes rvIntroEnter {
  to { opacity: 1; }
}

@keyframes rvIntroExit {
  from { opacity: 1; }
  to { opacity: 0; visibility: hidden; }
}

@keyframes rvRobotArrive {
  from { opacity: 0; transform: translateY(32px) scale(.94); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes rvTriggerEnter {
  from { opacity: 0; transform: translateY(18px) scale(.85); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes rvPanelEnter {
  from { opacity: 0; transform: translateY(14px) scale(.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

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

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

@keyframes rvPulse {
  0%, 84%, 100% { box-shadow: 0 16px 44px rgba(0,0,0,.42), 0 0 24px rgba(229,9,20,.19); }
  90% { box-shadow: 0 18px 50px rgba(0,0,0,.46), 0 0 40px rgba(229,9,20,.38); }
}

@keyframes rvGlow {
  0%, 100% { transform: scale(.96); opacity: .75; }
  50% { transform: scale(1.04); opacity: 1; }
}

@media (max-width: 760px) {
  .rv-intro__content {
    grid-template-columns: 1fr;
    gap: 10px;
    text-align: center;
  }

  .rv-intro__robot {
    width: min(250px, 56vw);
    max-height: 45vh;
  }

  .rv-intro__copy {
    margin-top: -12px;
  }

  .rv-intro__copy h2 {
    font-size: clamp(2rem, 10vw, 3.2rem);
  }

  .rv-intro__copy > p:not(.rv-kicker) {
    margin-left: auto;
    margin-right: auto;
  }

  .rv-trigger {
    right: 12px;
    bottom: calc(82px + env(safe-area-inset-bottom));
    min-width: 68px;
    min-height: 68px;
    padding-right: 7px;
  }

  .rv-trigger picture {
    width: 58px;
    height: 58px;
  }

  .rv-trigger img {
    width: 46px;
  }

  .rv-trigger__label {
    display: none;
  }

  .rv-panel {
    right: 0;
    bottom: calc(64px + env(safe-area-inset-bottom));
    width: 100%;
    max-height: 82vh;
    border-right: 0;
    border-bottom: 0;
    border-left: 0;
    border-radius: 22px 22px 0 0;
    padding-bottom: env(safe-area-inset-bottom);
  }

  .rv-panel__body {
    max-height: calc(82vh - 78px - env(safe-area-inset-bottom));
  }
}

@media (max-width: 390px) {
  .rv-actions {
    grid-template-columns: 1fr;
  }

  .rv-action--wide {
    grid-column: auto;
  }

  .rv-action {
    min-height: 72px;
  }

  .rv-service-grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rv-assistant *,
  .rv-assistant *::before,
  .rv-assistant *::after {
    scroll-behavior: auto !important;
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
  }
}
