#svsw-root {
  --svsw-accent: #d94f87;
  position: fixed;
  bottom: max(16px, env(safe-area-inset-bottom));
  right: max(16px, env(safe-area-inset-right));
  z-index: 999999;
  direction: rtl;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Tahoma, sans-serif;
  max-width: calc(100vw - 16px);
  color: #25212a;
}
#svsw-root[data-position="left"] { right: auto; left: max(16px, env(safe-area-inset-left)); }
#svsw-root, #svsw-root * { box-sizing: border-box; }
#svsw-root button { font: inherit; }
.svsw-launcher {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  max-width: calc(100vw - 24px); min-height: 52px;
  background: var(--svsw-accent); color: #fff; border: 0;
  padding: 12px 18px; border-radius: 999px;
  box-shadow: 0 6px 20px rgba(0,0,0,.2); font-weight: 700;
  cursor: grab; user-select: none; -webkit-user-select: none; touch-action: none;
}
.svsw-launcher:active { cursor: grabbing; }
.svsw-launcher:focus-visible, .svsw-close:focus-visible, .svsw-option:focus-visible { outline: 3px solid #3b82f6; outline-offset: 3px; }
.svsw-title-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.svsw-wa-icon { flex: 0 0 28px; width: 28px; height: 28px; background: rgba(255,255,255,.25); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 16px; }
.svsw-panel {
  position: absolute; bottom: calc(100% + 12px); right: 0;
  width: min(360px, calc(100vw - 24px)); max-width: calc(100vw - 16px);
  max-height: min(72dvh, 620px); background: #fff; border-radius: 18px;
  box-shadow: 0 10px 35px rgba(0,0,0,.24); overflow: hidden;
  display: flex; flex-direction: column; border: 1px solid rgba(0,0,0,.06);
}
#svsw-root[data-position="left"] .svsw-panel { right: auto; left: 0; }
.svsw-panel[hidden] { display: none; }
.svsw-header { flex: 0 0 auto; background: var(--svsw-accent); color: #fff; padding: 14px 16px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.svsw-header h3 { margin: 0; min-width: 0; font-size: 16px; line-height: 1.5; font-weight: 700; overflow-wrap: anywhere; }
.svsw-close { flex: 0 0 36px; width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center; background: transparent; border: 0; border-radius: 8px; color: #fff; font-size: 26px; line-height: 1; cursor: pointer; }
.svsw-content { padding: 16px; overflow-y: auto; overscroll-behavior: contain; }
.svsw-welcome { background: #fff0f5; padding: 12px; border-radius: 12px; margin: 0 0 15px; font-size: 14px; line-height: 1.7; overflow-wrap: anywhere; }
.svsw-section-title { font-weight: 700; font-size: 14px; line-height: 1.6; margin: 12px 0 8px; color: #444; }
.svsw-option { width: 100%; min-height: 46px; text-align: right; padding: 12px; border: 1px solid #eee; background: #f9f9f9; color: #29242b; border-radius: 10px; margin-bottom: 8px; cursor: pointer; font-size: 14px; line-height: 1.6; overflow-wrap: anywhere; transition: border-color .2s, background-color .2s; }
.svsw-option:hover { border-color: var(--svsw-accent); background: #fff5f8; }
.svsw-footer-note { font-size: 11px; line-height: 1.6; color: #777; text-align: center; margin-top: 12px; border-top: 1px solid #eee; padding-top: 10px; }
@media (max-width: 480px) {
  #svsw-root { bottom: max(10px, env(safe-area-inset-bottom)); right: max(10px, env(safe-area-inset-right)); max-width: calc(100vw - 20px); }
  #svsw-root[data-position="left"] { right: auto; left: max(10px, env(safe-area-inset-left)); }
  .svsw-launcher { min-height: 48px; padding: 10px 14px; gap: 8px; font-size: 13px; }
  .svsw-panel { width: min(340px, calc(100vw - 20px)); max-height: min(68dvh, 560px); bottom: calc(100% + 8px); border-radius: 16px; }
  .svsw-content { padding: 12px; }
}
@media (max-width: 340px) {
  .svsw-title-text { max-width: 190px; }
  .svsw-panel { width: calc(100vw - 16px); }
}
@media (prefers-reduced-motion: reduce) { .svsw-option { transition: none; } }
