/* ===== Floating FAQ Agent (responsive) ===== */
.ai-agent{
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 9999;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

/* Floating button */
.ai-fab{
  width: 72px;
  height: 72px;
  border-radius: 999px;
  background: rgba(255,255,255,.96);
  border: 1px solid rgba(226,232,240,.95);
  box-shadow: 0 12px 28px rgba(2,6,23,.18);
  display: grid;
  place-items: center;
  cursor: pointer;
  padding: 0;
  overflow: hidden;
}

/* Goose icon */
.ai-goose-icon{
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 999px;
  pointer-events: none;
}

/* Panel */
.ai-panel{
  position: absolute;
  right: 0;
  bottom: 86px;
  width: min(360px, 92vw);
  height: min(460px, 70vh);
  border-radius: 18px;
  border: 1px solid rgba(226,232,240,.95);
  background: rgba(255,255,255,.96);
  box-shadow: 0 18px 45px rgba(2,6,23,.16);
  overflow: hidden;
  display: none;
}

.ai-panel.is-open{
  display: grid;
  grid-template-rows: auto auto 1fr auto;
}

.ai-head{
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid rgba(226,232,240,.95);
  background: linear-gradient(180deg, rgba(129,216,208,.30), rgba(255,255,255,.92));
}

.ai-title{ font-weight: 900; color: #043a35; font-size: 18px; }
.ai-sub{ font-size: 12px; color: rgba(71,85,105,.95); }

.ai-close{
  border: 1px solid rgba(226,232,240,.95);
  background: rgba(255,255,255,.95);
  border-radius: 12px;
  padding: 6px 10px;
  cursor: pointer;
  font-weight: 900;
}

/* Quick chips */
.ai-quick{
  padding: 10px 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  border-bottom: 1px solid rgba(226,232,240,.95);
  background: rgba(255,255,255,.92);
}

.ai-chip{
  border: 1px solid rgba(15,175,166,.25);
  background: rgba(129,216,208,.18);
  color: #043a35;
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}
.ai-chip:hover{ background: rgba(129,216,208,.28); }

/* Messages */
.ai-messages{
  padding: 12px;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ai-bubble{
  max-width: 85%;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(226,232,240,.95);
  font-size: 13px;
  line-height: 1.35;
  white-space: pre-line;
}

.ai-bot{
  align-self: flex-start;
  background: rgba(248,250,252,.95);
  color: rgba(15,23,42,.92);
}

.ai-user{
  align-self: flex-end;
  background: rgba(129,216,208,.22);
  color: #043a35;
  border-color: rgba(15,175,166,.28);
}

/* Input */
.ai-input{
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid rgba(226,232,240,.95);
  background: rgba(255,255,255,.95);
}

.ai-input input{
  border: 1px solid rgba(226,232,240,.95);
  border-radius: 12px;
  padding: 10px 12px;
  outline: none;
  font-size: 14px;
  min-width: 0;
}

.ai-input button{
  border: 1px solid rgba(15,175,166,.35);
  background: rgba(129,216,208,.95);
  color: #043a35;
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 900;
  cursor: pointer;
}

/* ===== Mobile tuning ===== */
@media (max-width: 480px){
  .ai-agent{
    right: 12px;
    bottom: 12px;
  }

  .ai-fab{
    width: 64px;
    height: 64px;
  }

  .ai-panel{
    right: 0;
    bottom: 76px;
    width: 92vw;
    height: 68vh;
    border-radius: 16px;
  }

  .ai-title{ font-size: 16px; }
  .ai-chip{ font-size: 12px; padding: 8px 10px; }
}
