:root {
  color-scheme: dark;
  --bg: #0d0d0e;
  --surface: rgba(255, 255, 255, 0.03);
  --surface-strong: rgba(255, 255, 255, 0.06);
  --surface-soft: rgba(13, 13, 14, 0.88);
  --ink: #ffffff;
  --muted: #ccced0;
  --steel: #9facb9;
  --line: rgba(204, 206, 208, 0.12);
  --line-strong: rgba(204, 206, 208, 0.18);
  --accent: #00c5f1;
  --accent-strong: #4ad0ff;
  --accent-live: #4cd964;
  --accent-error: #ff453a;
  --cool: #00c5f1;
  --navy: #0d0d0e;
  --navy-soft: rgba(0, 197, 241, 0.06);
  --shadow-xl: 0 30px 80px rgba(0, 0, 0, 0.7);
  --shadow-lg: 0 18px 44px rgba(0, 0, 0, 0.5);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --title-font: "Palatino Linotype", "Book Antiqua", Georgia, serif;
  --ui-font: "Trebuchet MS", "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  position: relative;
  overflow-x: hidden;
  background:
    radial-gradient(circle at top left, rgba(0, 197, 241, 0.18), transparent 40%),
    radial-gradient(circle at bottom right, rgba(159, 172, 185, 0.1), transparent 40%),
    var(--bg);
  color: var(--ink);
  font-family: var(--ui-font);
}

body::before,
body::after {
  content: "";
  position: fixed;
  border-radius: 999px;
  filter: blur(18px);
  pointer-events: none;
}

body::before {
  top: 80px;
  right: 6%;
  width: 260px;
  height: 260px;
  background: rgba(0, 197, 241, 0.1);
}

body::after {
  left: 4%;
  bottom: 90px;
  width: 220px;
  height: 220px;
  background: rgba(159, 172, 185, 0.07);
}

.site-demo {
  width: min(1180px, calc(100vw - 40px));
  margin: 0 auto;
  padding: 64px 0 120px;
}

.site-hero {
  max-width: 720px;
}

.site-kicker {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
}

.site-hero h1 {
  margin: 0;
  max-width: 13ch;
  font-family: var(--title-font);
  font-size: clamp(42px, 7vw, 76px);
  line-height: 0.95;
  letter-spacing: -0.05em;
}

.site-description {
  max-width: 58ch;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.75;
}

.site-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 28px;
}

.site-button,
.button,
.widget-launcher,
.widget-close {
  appearance: none;
  border: 0;
  cursor: pointer;
  font: inherit;
}

.site-button {
  padding: 14px 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--ink);
  font-weight: 700;
}

.site-button--primary {
  color: #0d0d0e;
  background: linear-gradient(135deg, #00c5f1 0%, #4ad0ff 100%);
  box-shadow: 0 14px 30px rgba(0, 197, 241, 0.24);
}

.site-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 18px;
  margin-top: 48px;
}

.site-card {
  min-height: 180px;
  padding: 22px;
  border-radius: 24px;
  border: 1px solid rgba(204, 206, 208, 0.14);
  background: rgba(255, 255, 255, 0.02);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(12px);
}

.site-card--feature {
  background:
    radial-gradient(800px 280px at 30% 0%, rgba(0, 197, 241, 0.1), transparent 60%),
    rgba(255, 255, 255, 0.02);
}

.site-card__tag {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(0, 197, 241, 0.12);
  color: #4ad0ff;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-card h2,
.site-card h3 {
  margin: 18px 0 0;
  line-height: 1.2;
}

.site-card p {
  margin: 14px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.widget-host {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 1000;
}

.widget-launcher {
  position: relative;
  z-index: 1002;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-width: 250px;
  padding: 14px 18px 14px 14px;
  border-radius: 999px;
  border: 1px solid rgba(0, 197, 241, 0.35);
  background: rgba(13, 13, 14, 0.92);
  color: white;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), 0 0 20px rgba(0, 197, 241, 0.06);
  backdrop-filter: blur(12px);
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease;
}

.widget-launcher:hover {
  transform: translateY(-1px);
  box-shadow: 0 24px 44px rgba(0, 0, 0, 0.7), 0 0 28px rgba(0, 197, 241, 0.12);
  border-color: rgba(0, 197, 241, 0.5);
}

.widget-launcher__icon {
  position: relative;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.16) 35%),
    linear-gradient(135deg, #00c5f1 0%, #4ad0ff 48%, #0080b0 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
  overflow: hidden;
}

.widget-launcher__icon span {
  position: absolute;
  width: 6px;
  bottom: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  animation: launcherMeter 1.15s ease-in-out infinite;
  animation-play-state: paused;
}

.widget-launcher__icon span:nth-child(1) {
  left: 12px;
  height: 13px;
}

.widget-launcher__icon span:nth-child(2) {
  left: 20px;
  height: 21px;
  animation-delay: 0.16s;
}

.widget-launcher__icon span:nth-child(3) {
  left: 28px;
  height: 16px;
  animation-delay: 0.32s;
}

.widget-launcher__copy {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  text-align: left;
}

.widget-launcher__label {
  font-size: 15px;
  font-weight: 700;
}

.widget-launcher__status {
  color: rgba(255, 255, 255, 0.55);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.widget-panel {
  position: absolute;
  right: 0;
  bottom: 78px;
  width: min(336px, calc(100vw - 20px));
  opacity: 0;
  transform: translateY(18px) scale(0.98);
  pointer-events: none;
  transition:
    opacity 200ms ease,
    transform 220ms ease;
  z-index: 1001;
}

.widget-backdrop {
  position: fixed;
  inset: 0;
  background: transparent;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.widget-host[data-open="true"] .widget-panel {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.widget-host[data-open="true"] .widget-backdrop {
  opacity: 1;
  pointer-events: auto;
}

.widget-host[data-open="true"] .widget-launcher {
  background: rgba(0, 197, 241, 0.08);
  border-color: rgba(0, 197, 241, 0.5);
}

.widget-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px;
  min-height: min(460px, calc(100vh - 96px));
  max-height: min(560px, calc(100vh - 96px));
  border-radius: 24px;
  border: 1px solid rgba(204, 206, 208, 0.14);
  background:
    radial-gradient(600px 200px at 50% 0%, rgba(0, 197, 241, 0.08), transparent 60%),
    rgba(13, 13, 14, 0.96);
  box-shadow: var(--shadow-xl);
  backdrop-filter: blur(18px);
}

.widget-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.widget-header__copy {
  display: grid;
  gap: 2px;
}

.widget-kicker {
  margin: 0 0 8px;
  color: var(--steel);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.widget-header h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.05;
  letter-spacing: -0.04em;
  color: var(--ink);
}

.widget-header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mini-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 700;
}

.mini-chip {
  padding: 6px 10px;
  background: rgba(0, 197, 241, 0.12);
  color: #4ad0ff;
  font-size: 11px;
}

.widget-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: var(--steel);
  font-size: 20px;
  line-height: 1;
}

.assistant-stage {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 0;
}

.voice-orb {
  position: relative;
  width: 56px;
  height: 56px;
}

.voice-orb__ring,
.voice-orb__core {
  position: absolute;
  border-radius: 50%;
}

.voice-orb__ring {
  inset: 6px;
  border: 1px solid rgba(0, 197, 241, 0.2);
  opacity: 0;
  transform: scale(0.92);
}

.voice-orb__ring--delay {
  inset: -4px;
}

.voice-orb__core {
  inset: 8px;
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.18) 35%),
    linear-gradient(135deg, #00c5f1 0%, #4ad0ff 48%, #0080b0 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 18px 42px rgba(0, 197, 241, 0.28);
}

.voice-orb__core::after {
  content: "";
  position: absolute;
  inset: 32%;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
}

.voice-meter {
  display: flex;
  gap: 4px;
  align-items: end;
  height: 14px;
}

.voice-meter span {
  width: 4px;
  height: 6px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(0, 197, 241, 0.9), rgba(74, 208, 255, 0.6));
  transform-origin: center bottom;
  opacity: 0.55;
  animation: meter 1.2s ease-in-out infinite;
  animation-play-state: paused;
}

.voice-meter span:nth-child(2) {
  animation-delay: 0.12s;
}

.voice-meter span:nth-child(3) {
  animation-delay: 0.24s;
}

.voice-meter span:nth-child(4) {
  animation-delay: 0.36s;
}

.voice-meter span:nth-child(5) {
  animation-delay: 0.48s;
}

.widget-presence {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(204, 206, 208, 0.12);
}

.widget-presence__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #6b7a88;
  box-shadow: 0 0 0 4px rgba(107, 122, 136, 0.16);
}

.widget-presence__text {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.button {
  flex: 1;
  min-height: 42px;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 700;
  transition:
    transform 180ms ease,
    opacity 180ms ease,
    box-shadow 180ms ease;
}

.button:hover:not(:disabled) {
  transform: translateY(-1px);
}

.button:disabled,
.site-button:disabled {
  opacity: 0.46;
  cursor: not-allowed;
}

.button--primary {
  background: linear-gradient(135deg, #00c5f1 0%, #4ad0ff 100%);
  color: #0d0d0e;
  box-shadow: 0 14px 30px rgba(0, 197, 241, 0.22);
}

.button--secondary {
  background: rgba(255, 255, 255, 0.07);
  color: var(--muted);
}

.chat-panel {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-height: 0;
  padding: 12px;
  border-radius: 18px;
  border: 1px solid rgba(204, 206, 208, 0.10);
  background: rgba(255, 255, 255, 0.02);
}

.chat-panel__header {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: flex-start;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.chat-panel__status {
  display: grid;
  justify-items: end;
  gap: 8px;
}

.chat-panel__hint {
  color: rgba(204, 206, 208, 0.42);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.chat-feed {
  display: grid;
  flex: 1;
  gap: 8px;
  margin-top: 10px;
  min-height: 0;
  overflow: auto;
  padding-right: 2px;
}

.chat-feed:empty {
  display: none;
}

.chat-empty {
  margin-top: 10px;
  display: grid;
  gap: 12px;
  min-height: 160px;
  place-items: center;
  padding: 18px;
  border-radius: 14px;
  border: 1px dashed rgba(204, 206, 208, 0.16);
  background: rgba(255, 255, 255, 0.01);
  color: rgba(204, 206, 208, 0.45);
  font-size: 12px;
  line-height: 1.55;
  text-align: center;
}

.chat-empty__text {
  margin: 0;
  max-width: 220px;
}

.chat-empty[hidden] {
  display: none;
}

.error {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255, 69, 58, 0.25);
  background: rgba(255, 69, 58, 0.08);
  color: #ff6b61;
  font-size: 13px;
  line-height: 1.45;
}

.chat-controls {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

/* Mode switch toggle */
.mode-switch {
  display: flex;
  gap: 3px;
  background: var(--surface-strong);
  border-radius: 999px;
  padding: 3px;
  flex-shrink: 0;
}

.mode-switch__btn {
  padding: 4px 12px;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-family: var(--ui-font);
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  white-space: nowrap;
}

.mode-switch__btn--active {
  background: var(--accent);
  color: #000;
}

/* Text input row */
.text-input-row {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  margin-top: 10px;
}

.text-input {
  flex: 1;
  background: var(--surface-strong);
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  color: var(--ink);
  font-family: var(--ui-font);
  font-size: 13px;
  line-height: 1.45;
  padding: 8px 12px;
  resize: none;
  min-height: 36px;
  max-height: 100px;
  outline: none;
  overflow-y: auto;
}

.text-input:focus {
  border-color: var(--accent);
}

.text-input::placeholder {
  color: var(--steel);
}

.text-input:disabled {
  opacity: 0.5;
}

.text-send-btn {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: #000;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.15s;
  padding: 0;
}

.text-send-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

/* Mode-based visibility */
.widget-card[data-mode="voice"] .text-input-row {
  display: none;
}

.widget-card[data-mode="text"] .chat-controls {
  display: none !important;
}

.widget-card[data-mode="text"] .chat-empty {
  display: none !important;
}

/* In text mode: keep chat-feed visible even when empty so flex fills space */
.widget-card[data-mode="text"] .chat-feed:empty {
  display: block;
  flex: 1;
}

/* Push text input to bottom */
.widget-card[data-mode="text"] .text-input-row {
  margin-top: auto;
}

/* Hide voice-specific status in text mode */
.widget-card[data-mode="text"] .widget-presence {
  display: none;
}

.widget-card[data-mode="text"] .chat-panel__hint {
  display: none;
}

.chat-message {
  display: grid;
  gap: 6px;
}

.chat-message--client {
  justify-items: end;
}

.chat-message__meta {
  color: rgba(204, 206, 208, 0.44);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.chat-message__bubble {
  max-width: 92%;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--ink);
  font-size: 13px;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
  border: 1px solid rgba(204, 206, 208, 0.1);
}

.chat-message--assistant .chat-message__bubble {
  background: rgba(0, 197, 241, 0.08);
  color: #e8f8ff;
  border: 1px solid rgba(0, 197, 241, 0.14);
}

.chat-message--client .chat-message__bubble {
  background: rgba(255, 255, 255, 0.07);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.chat-message__bubble a {
  color: inherit;
  text-decoration: underline;
  opacity: 0.85;
  word-break: break-all;
}

.chat-message__bubble a:hover {
  opacity: 1;
}

.chat-message__bubble--streaming::after {
  content: " ";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-left: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.55;
  animation: bubblePulse 1s ease-in-out infinite;
}

.widget-card[data-status="requesting-session"] .voice-orb__ring,
.widget-card[data-status="requesting-microphone"] .voice-orb__ring,
.widget-card[data-status="connecting"] .voice-orb__ring,
.widget-card[data-status="live"] .voice-orb__ring {
  animation: orbPulse 2.2s ease-out infinite;
}

.widget-card[data-status="requesting-session"] .voice-orb__ring--delay,
.widget-card[data-status="requesting-microphone"] .voice-orb__ring--delay,
.widget-card[data-status="connecting"] .voice-orb__ring--delay,
.widget-card[data-status="live"] .voice-orb__ring--delay {
  animation-delay: 1.05s;
}

.widget-card[data-status="requesting-session"] .voice-meter span,
.widget-card[data-status="requesting-microphone"] .voice-meter span,
.widget-card[data-status="connecting"] .voice-meter span,
.widget-card[data-status="live"] .voice-meter span,
.widget-launcher[data-status="requesting-session"] .widget-launcher__icon span,
.widget-launcher[data-status="requesting-microphone"] .widget-launcher__icon span,
.widget-launcher[data-status="connecting"] .widget-launcher__icon span,
.widget-launcher[data-status="live"] .widget-launcher__icon span {
  animation-play-state: running;
  opacity: 0.92;
}

.widget-card[data-status="live"] .voice-orb__core,
.widget-launcher[data-status="live"] .widget-launcher__icon {
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.2) 35%),
    linear-gradient(135deg, #4cd964 0%, #65d8a0 45%, #00c5f1 100%);
}

.widget-card[data-status="live"] .widget-presence__dot {
  background: var(--accent-live);
  box-shadow: 0 0 0 4px rgba(76, 217, 100, 0.2);
}

.widget-card[data-status="error"] .voice-orb__core,
.widget-launcher[data-status="error"] .widget-launcher__icon {
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.94), rgba(255, 255, 255, 0.2) 35%),
    linear-gradient(135deg, #ff453a 0%, #ff6b61 100%);
}

.widget-card[data-status="error"] .widget-presence__dot {
  background: var(--accent-error);
  box-shadow: 0 0 0 4px rgba(255, 69, 58, 0.2);
}

.widget-card[data-status="connecting"] .widget-presence__dot,
.widget-card[data-status="requesting-session"] .widget-presence__dot,
.widget-card[data-status="requesting-microphone"] .widget-presence__dot {
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(0, 197, 241, 0.2);
}

.widget-launcher[data-status="live"] {
  box-shadow: 0 22px 44px rgba(0, 0, 0, 0.6), 0 0 28px rgba(76, 217, 100, 0.2);
  border-color: rgba(76, 217, 100, 0.35);
}

.widget-launcher[data-status="error"] {
  box-shadow: 0 22px 44px rgba(0, 0, 0, 0.6), 0 0 28px rgba(255, 69, 58, 0.18);
  border-color: rgba(255, 69, 58, 0.35);
}

@keyframes orbPulse {
  0% {
    transform: scale(0.86);
    opacity: 0;
  }

  22% {
    opacity: 0.34;
  }

  100% {
    transform: scale(1.15);
    opacity: 0;
  }
}

@keyframes meter {
  0%,
  100% {
    transform: scaleY(0.55);
  }

  50% {
    transform: scaleY(1.9);
  }
}

@keyframes launcherMeter {
  0%,
  100% {
    transform: scaleY(0.7);
  }

  50% {
    transform: scaleY(1.45);
  }
}

@keyframes bubblePulse {
  0%,
  100% {
    transform: scale(0.7);
    opacity: 0.32;
  }

  50% {
    transform: scale(1);
    opacity: 0.8;
  }
}

/* ── Contact form overlay ─────────────────────────────────────── */

.contact-overlay[hidden] {
  display: none;
}

.contact-overlay:not([hidden]) {
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: absolute;
  top: 72px;
  right: 14px;
  bottom: 14px;
  left: 14px;
  z-index: 20;
  border-radius: 18px;
  padding: 14px;
  background: rgba(13, 13, 14, 0.97);
  border: 1px solid rgba(204, 206, 208, 0.12);
  backdrop-filter: blur(18px);
  overflow-y: auto;
}

.contact-overlay__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--line);
}

.contact-overlay__title {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--ink);
}

.contact-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex: 1;
  padding: 24px 12px;
  text-align: center;
}

.contact-success[hidden] {
  display: none;
}

.contact-success__icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--accent-live);
  color: white;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.contact-success__text {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  max-width: 220px;
}

.contact-form {
  display: flex;
  flex-direction: column;
}

.contact-form[hidden] {
  display: none;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 10px;
}

.form-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--steel);
}

.form-input {
  border: 1px solid rgba(204, 206, 208, 0.18);
  border-radius: 12px;
  padding: 9px 12px;
  font-size: 14px;
  font-family: var(--ui-font);
  color: var(--ink);
  background: rgba(255, 255, 255, 0.04);
  outline: none;
  resize: none;
  transition: border-color 0.15s;
}

.form-input::placeholder {
  color: rgba(204, 206, 208, 0.35);
}

.form-input:focus {
  border-color: var(--accent);
}

.form-error {
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 69, 58, 0.25);
  background: rgba(255, 69, 58, 0.08);
  color: #ff6b61;
  font-size: 13px;
  margin-bottom: 10px;
}

.form-error[hidden] {
  display: none;
}

@media (max-width: 900px) {
  .site-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .site-demo {
    width: min(100vw - 20px, 560px);
    padding-top: 40px;
    padding-bottom: 120px;
  }

  .widget-host {
    right: 12px;
    left: 12px;
    bottom: 12px;
  }

  .widget-launcher {
    width: 100%;
    min-width: 0;
  }

  .widget-panel {
    right: 0;
    bottom: 72px;
    width: 100%;
  }

  .widget-card {
    padding: 12px;
    border-radius: 20px;
    max-height: min(520px, calc(100vh - 88px));
  }

  .widget-header,
  .chat-panel__header {
    flex-direction: column;
    align-items: flex-start;
  }

  .widget-header__actions {
    width: 100%;
    justify-content: space-between;
  }

  .chat-panel__status {
    justify-items: start;
  }
}
