.roc-sauna-ai {
  position: fixed;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  z-index: 2147483000;
  /* The open panel is wider than the launcher; both stay pinned to the
     right edge so the launcher never drifts when the panel appears. */
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  color: #2f251e;
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.4;
}

.roc-sauna-ai__launcher {
  position: relative;
  min-height: 48px;
  padding: 0 20px;
  border: 0;
  border-radius: 999px;
  background: #a96121;
  box-shadow: 0 8px 28px rgba(47, 37, 30, 0.25);
  color: #fff;
  cursor: pointer;
  font: 600 15px/48px Arial, Helvetica, sans-serif;
}

/* A soft ripple invites the first click; it stops while the panel is open. */
.roc-sauna-ai__launcher[aria-expanded="false"]::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  animation: roc-launcher-pulse 2.4s ease-out infinite;
  pointer-events: none;
}

@keyframes roc-launcher-pulse {
  0% { box-shadow: 0 0 0 0 rgba(169, 97, 33, 0.45); }
  70% { box-shadow: 0 0 0 16px rgba(169, 97, 33, 0); }
  100% { box-shadow: 0 0 0 0 rgba(169, 97, 33, 0); }
}

.roc-sauna-ai__launcher:focus-visible,
.roc-sauna-ai__close:focus-visible {
  outline: 3px solid #2f74c0;
  outline-offset: 3px;
}

/* The panel is the frosted-glass layer: the page shows through the blur, and
   the iframe inside must stay transparent or it punches an opaque hole. */
.roc-sauna-ai__panel {
  width: min(684px, calc(100vw - 32px));
  height: min(860px, calc(100vh - 190px));
  margin-bottom: 12px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 28px;
  background: rgba(251, 247, 241, 0.62);
  -webkit-backdrop-filter: blur(28px) saturate(1.8);
  backdrop-filter: blur(28px) saturate(1.8);
  box-shadow:
    0 24px 80px rgba(47, 37, 30, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .roc-sauna-ai__panel { background: #fbf7f1; }
}

.roc-sauna-ai__panel[hidden] {
  display: none;
}

.roc-sauna-ai__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  padding: 0 14px 0 20px;
  border-bottom: 1px solid rgba(169, 97, 33, 0.14);
  background: transparent;
}

.roc-sauna-ai__title-group {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.roc-sauna-ai__title-group strong {
  font-size: 16px;
  white-space: nowrap;
}

.roc-sauna-ai__status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #5e5147;
  font-size: 12px;
  white-space: nowrap;
}

.roc-sauna-ai__status::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #4f8a58;
  box-shadow: 0 0 0 3px rgba(79, 138, 88, 0.14);
}

.roc-sauna-ai__close {
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #2f251e;
  cursor: pointer;
  font: 400 28px/34px Arial, Helvetica, sans-serif;
}

.roc-sauna-ai__body {
  height: calc(100% - 57px);
}

.roc-sauna-ai__frame {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: transparent;
}

@media (max-width: 520px) {
  .roc-sauna-ai {
    right: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
  }

  .roc-sauna-ai__panel {
    width: calc(100vw - 24px);
    height: min(80vh, 860px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .roc-sauna-ai *,
  .roc-sauna-ai *::before,
  .roc-sauna-ai *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
