/* ProxDelta Shared Components — BETA badge, News Ticker, Contact Form */

/* ══════ BETA BADGE ══════ */
.pdx-beta-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: linear-gradient(135deg, #f59e0b22, #f59e0b11);
  border: 1px solid #f59e0b55;
  color: #f59e0b;
  font-size: .6rem;
  font-weight: 800;
  letter-spacing: .08em;
  padding: 2px 7px;
  border-radius: 4px;
  margin-left: 8px;
  vertical-align: middle;
  text-transform: uppercase;
  animation: pdx-badge-pulse 3s ease-in-out infinite;
}
@keyframes pdx-badge-pulse {
  0%, 100% { opacity: .85; }
  50% { opacity: 1; }
}

/* ══════ NEWS TICKER ══════ */
.pdx-ticker {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 99999;
  background: linear-gradient(90deg, #0f172a, #1e293b);
  border-bottom: 1px solid #334155;
  height: 28px;
  overflow: hidden;
  display: none; /* hidden until message loaded */
}
.pdx-ticker-inner {
  display: flex;
  align-items: center;
  height: 100%;
  white-space: nowrap;
  animation: pdx-ticker-scroll 30s linear infinite;
}
.pdx-ticker-msg {
  display: inline-block;
  padding: 0 3rem;
  font-size: .72rem;
  color: #94a3b8;
  font-weight: 500;
}
.pdx-ticker-msg b { color: #60a5fa; }
.pdx-ticker-msg a { color: #38bdf8; text-decoration: underline; }
.pdx-ticker-close {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #64748b;
  cursor: pointer;
  font-size: .85rem;
  padding: 2px 6px;
  border-radius: 3px;
}
.pdx-ticker-close:hover { color: #e2e8f0; background: #ffffff11; }
@keyframes pdx-ticker-scroll {
  0% { transform: translateX(100vw); }
  100% { transform: translateX(-100%); }
}

/* push body down when ticker visible */
body.pdx-has-ticker { padding-top: 28px !important; }

/* ══════ CONTACT FORM (floating micro) ══════ */
.pdx-contact-btn {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 99998;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  border: none;
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: 0 4px 12px #3b82f644;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .2s, box-shadow .2s;
}
.pdx-contact-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px #3b82f666;
}
.pdx-contact-btn.has-badge::after {
  content: '';
  position: absolute;
  top: -2px;
  right: -2px;
  width: 10px;
  height: 10px;
  background: #22c55e;
  border-radius: 50%;
  border: 2px solid #0f172a;
}

.pdx-contact-panel {
  position: fixed;
  bottom: 72px;
  right: 20px;
  z-index: 99998;
  width: 280px;
  background: #1e293b;
  border: 1px solid #334155;
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0,0,0,.4);
  display: none;
  overflow: hidden;
}
.pdx-contact-panel.open { display: block; }

.pdx-contact-header {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.pdx-contact-header span {
  color: #fff;
  font-size: .82rem;
  font-weight: 700;
}
.pdx-contact-header button {
  background: none;
  border: none;
  color: #ffffffaa;
  cursor: pointer;
  font-size: .9rem;
}
.pdx-contact-header button:hover { color: #fff; }

.pdx-contact-body {
  padding: 12px;
}
.pdx-contact-body input,
.pdx-contact-body textarea {
  width: 100%;
  background: #0f172a;
  border: 1px solid #334155;
  border-radius: 6px;
  padding: 7px 10px;
  color: #e2e8f0;
  font-size: .78rem;
  font-family: inherit;
  margin-bottom: 8px;
  outline: none;
  box-sizing: border-box;
  transition: border-color .2s;
}
.pdx-contact-body input:focus,
.pdx-contact-body textarea:focus {
  border-color: #3b82f6;
}
.pdx-contact-body textarea {
  height: 60px;
  resize: vertical;
  min-height: 40px;
  max-height: 120px;
}
.pdx-contact-send {
  width: 100%;
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  border: none;
  color: #fff;
  padding: 7px;
  border-radius: 6px;
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity .2s;
}
.pdx-contact-send:hover { opacity: .9; }
.pdx-contact-send:disabled { opacity: .5; cursor: wait; }
.pdx-contact-ok {
  color: #22c55e;
  font-size: .75rem;
  text-align: center;
  padding: 6px;
  display: none;
}
