.tvmo-ai-widget-wrap,
.tvmo-ai-widget-wrap * {
  box-sizing: border-box;
}

.tvmo-ai-widget-wrap {
  --tvmo-primary: #0874cf;
  --tvmo-secondary: #22b96f;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  z-index: 9999999;
}

.tvmo-ai-floating {
  position: fixed;
  right: 22px;
  bottom: 22px;
}

.tvmo-ai-launcher {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 235px;
  border: 0;
  border-radius: 18px;
  padding: 13px 17px;
  background: linear-gradient(135deg, var(--tvmo-primary), var(--tvmo-secondary));
  color: #fff;
  box-shadow: 0 18px 45px rgba(0, 0, 0, .24);
  cursor: pointer;
  text-align: left;
}

.tvmo-ai-launcher-title {
  font-size: 15px;
  font-weight: 800;
  line-height: 1.2;
}

.tvmo-ai-launcher-sub {
  margin-top: 3px;
  font-size: 11px;
  font-weight: 600;
  opacity: .9;
}

.tvmo-ai-panel {
  display: none;
  width: min(390px, calc(100vw - 28px));
  height: min(540px, calc(100vh - 90px));
  overflow: hidden;
  border: 1px solid rgba(15, 118, 110, .18);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 24px 80px rgba(2, 44, 34, .24);
}

.tvmo-ai-panel.open {
  display: flex;
  flex-direction: column;
}

.tvmo-ai-head {
  display: flex;
  flex: 0 0 auto;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 16px;
  background: linear-gradient(135deg, var(--tvmo-primary), var(--tvmo-secondary));
  color: #fff;
}

.tvmo-ai-head strong {
  display: block;
  font-size: 16px;
  line-height: 1.2;
}

.tvmo-ai-head span {
  display: block;
  margin-top: 3px;
  font-size: 12px;
  line-height: 1.35;
  opacity: .92;
}

.tvmo-ai-close {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, .2);
  color: #fff;
  font-size: 24px;
  line-height: 31px;
  cursor: pointer;
}

.tvmo-ai-prechat {
  flex: 1;
  overflow: auto;
  padding: 20px;
  background: #f7fbfa;
}

.tvmo-ai-prechat-copy {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 17px;
  color: #0f172a;
}

.tvmo-ai-prechat-copy strong {
  font-size: 17px;
}

.tvmo-ai-prechat-copy span {
  color: #475569;
  font-size: 13px;
  line-height: 1.45;
}

.tvmo-ai-prechat-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tvmo-ai-prechat-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: #334155;
  font-size: 12px;
  font-weight: 800;
}

.tvmo-ai-prechat-form input,
.tvmo-ai-input {
  width: 100%;
  min-height: 44px;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  background: #fff;
  color: #0f172a;
  padding: 11px 13px;
  font: inherit;
  font-size: 14px;
  outline: none;
}

.tvmo-ai-prechat-form input:focus,
.tvmo-ai-input:focus {
  border-color: var(--tvmo-primary);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, .16);
}

.tvmo-ai-prechat-form button,
.tvmo-ai-form button {
  min-height: 44px;
  border: 0;
  border-radius: 12px;
  background: var(--tvmo-primary);
  color: #fff;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.tvmo-ai-prechat-form button:disabled,
.tvmo-ai-form button:disabled,
.tvmo-ai-end:disabled {
  cursor: wait;
  opacity: .65;
}

.tvmo-ai-consent {
  margin: 0;
  color: #64748b;
  font-size: 10px;
  line-height: 1.45;
}

.tvmo-ai-consent a {
  color: var(--tvmo-secondary);
  font-weight: 800;
}

.tvmo-ai-prechat-error {
  min-height: 18px;
  color: #b91c1c;
  font-size: 12px;
  font-weight: 700;
}

.tvmo-ai-honeypot {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

.tvmo-ai-chat-view {
  display: flex;
  flex: 1;
  min-height: 0;
  flex-direction: column;
}

.tvmo-ai-chat-view[hidden],
.tvmo-ai-prechat[hidden] {
  display: none !important;
}

.tvmo-ai-messages {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 13px;
  background: #f7fbfa;
}

.tvmo-ai-msg {
  max-width: 88%;
  margin: 0 0 9px;
  border-radius: 16px;
  padding: 10px 12px;
  font-size: 14px;
  line-height: 1.42;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.tvmo-ai-agent {
  border: 1px solid #e2e8f0;
  border-top-left-radius: 5px;
  background: #fff;
  color: #0f172a;
}

.tvmo-ai-customer {
  margin-left: auto;
  border-bottom-right-radius: 5px;
  background: var(--tvmo-secondary);
  color: #fff;
}

.tvmo-ai-form {
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  gap: 6px;
  padding: 10px;
  border-top: 1px solid #e5e7eb;
  background: #fff;
}

.tvmo-ai-input {
  flex: 1;
  min-width: 0;
  border-radius: 999px;
}

.tvmo-ai-compose-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tvmo-ai-form button[type="submit"] {
  min-height: 42px;
  border-radius: 999px;
  padding: 0 16px;
}

.tvmo-ai-attach {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  background: #f8fafc;
  cursor: pointer;
  font-size: 18px;
}

.tvmo-ai-attach input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.tvmo-ai-attachment-list {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.tvmo-ai-attachment-list:empty {
  display: none;
}

.tvmo-ai-file-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  max-width: 100%;
  border: 1px solid #dbe5e1;
  border-radius: 999px;
  background: #f1f8f6;
  color: #334155;
  padding: 5px 8px 5px 10px;
  font-size: 11px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tvmo-ai-file-chip button {
  min-height: 0 !important;
  width: 20px;
  height: 20px;
  padding: 0 !important;
  border-radius: 999px !important;
  background: transparent !important;
  color: #64748b !important;
  line-height: 18px;
}

.tvmo-ai-file-help {
  color: #64748b;
  font-size: 10px;
  line-height: 1.35;
  padding: 0 4px;
}

.tvmo-ai-end {
  flex: 0 0 auto;
  border: 0;
  border-top: 1px solid #eef2f7;
  background: #f8fafc;
  color: #64748b;
  padding: 9px;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.tvmo-ai-inline .tvmo-ai-panel {
  width: 100%;
  max-width: 720px;
  height: 540px;
}

.tvmo-ai-inline .tvmo-ai-close {
  display: none;
}

@media (max-width: 520px) {
  .tvmo-ai-floating {
    right: 12px;
    bottom: 12px;
  }

  .tvmo-ai-launcher {
    min-width: 210px;
  }

  .tvmo-ai-panel {
    width: calc(100vw - 24px);
    height: calc(100vh - 80px);
    max-height: 620px;
    border-radius: 20px;
  }
}

/* v1.14 conversion-focused TV Mounting Ocala blue/green chat bubble */
.tvmo-ai-widget-wrap{
  --tvmo-primary:#0874cf;
  --tvmo-secondary:#22b96f;
  --tvmo-navy:#062444;
}
.tvmo-ai-floating{right:20px;bottom:20px;z-index:9999999}
.tvmo-ai-launcher{
  position:relative;
  width:64px;
  height:64px;
  min-width:64px;
  padding:0;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,var(--tvmo-primary) 0%,#0ba7d5 48%,var(--tvmo-secondary) 100%);
  box-shadow:0 16px 40px rgba(5,74,127,.32),0 4px 12px rgba(0,0,0,.16);
  border:2px solid rgba(255,255,255,.88);
  transition:transform .18s ease,box-shadow .18s ease,filter .18s ease;
}
.tvmo-ai-launcher:hover{transform:translateY(-3px) scale(1.03);box-shadow:0 20px 46px rgba(5,74,127,.38),0 6px 14px rgba(0,0,0,.18);filter:saturate(1.05)}
.tvmo-ai-launcher:focus-visible{outline:4px solid rgba(8,116,207,.22);outline-offset:4px}
.tvmo-ai-launcher-icon{width:31px;height:31px;display:flex;align-items:center;justify-content:center}
.tvmo-ai-launcher-icon svg{width:31px;height:31px;display:block;fill:#fff}
.tvmo-ai-launcher-ping{position:absolute;right:3px;top:3px;width:14px;height:14px;border-radius:50%;background:#34e27f;border:3px solid #fff;box-shadow:0 0 0 4px rgba(52,226,127,.18)}
.tvmo-ai-sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
.tvmo-ai-launcher-title,.tvmo-ai-launcher-sub{display:none!important}
.tvmo-ai-panel{
  width:min(410px,calc(100vw - 32px));
  height:min(620px,calc(100vh - 105px));
  border-radius:24px;
  border:1px solid rgba(8,116,207,.14);
  box-shadow:0 26px 80px rgba(3,36,68,.28);
}
.tvmo-ai-head{padding:16px 17px;background:linear-gradient(135deg,var(--tvmo-primary) 0%,#0ba7d5 52%,var(--tvmo-secondary) 100%)}
.tvmo-ai-head strong{font-size:17px;font-weight:850;letter-spacing:-.015em}
.tvmo-ai-head span{font-size:11.5px;opacity:.95}
.tvmo-ai-prechat,.tvmo-ai-messages{background:linear-gradient(180deg,#f7fbff 0%,#f7fcf9 100%)}
.tvmo-ai-prechat{padding:20px 18px}
.tvmo-ai-prechat-copy strong{font-size:19px;color:var(--tvmo-navy);letter-spacing:-.02em}
.tvmo-ai-prechat-form input,.tvmo-ai-input{min-height:48px;border-color:#cddbe8;font-size:16px}
.tvmo-ai-prechat-form input:focus,.tvmo-ai-input:focus{border-color:var(--tvmo-primary);box-shadow:0 0 0 4px rgba(8,116,207,.12)}
.tvmo-ai-prechat-form button,.tvmo-ai-form button[type="submit"]{background:linear-gradient(135deg,var(--tvmo-primary),var(--tvmo-secondary));box-shadow:0 10px 24px rgba(8,116,207,.18)}
.tvmo-ai-prechat-form button{min-height:50px;font-size:15px;border-radius:13px}
.tvmo-ai-agent{border-color:#dce9f2;box-shadow:0 4px 12px rgba(3,36,68,.04)}
.tvmo-ai-customer{background:linear-gradient(135deg,var(--tvmo-primary),#0c8ed0);color:#fff}
.tvmo-ai-close{background:rgba(255,255,255,.18)}
.tvmo-ai-close:hover{background:rgba(255,255,255,.28)}
.tvmo-ai-end{background:#f7fafc;color:#63758a}
@media(max-width:520px){
  .tvmo-ai-floating{right:14px;bottom:calc(14px + env(safe-area-inset-bottom))}
  .tvmo-ai-launcher{width:60px;height:60px;min-width:60px;border-radius:50%}
  .tvmo-ai-panel{position:fixed;right:10px;left:10px;bottom:calc(10px + env(safe-area-inset-bottom));width:auto;height:min(680px,calc(100dvh - 20px));max-height:calc(100dvh - 20px);border-radius:22px}
  .tvmo-ai-prechat-form input,.tvmo-ai-input{font-size:16px}
}


/* v1.15 floating placement hardening */
.tvmo-ai-floating .tvmo-ai-panel{position:absolute;right:0;bottom:0}
@media(max-width:520px){.tvmo-ai-floating .tvmo-ai-panel{position:fixed;right:10px;left:10px;bottom:calc(10px + env(safe-area-inset-bottom))}}
