/* ============================================================
   MyConnect Hub CRM — Warm light theme
   Palette: cream neutrals #FAF5EE / #F3E9DA · base charcoal #3D3D3D
            contrast white #FFFFFF · accent coral #D2604F
   ============================================================ */

:root {
  --cream: #faf5ee;
  --sand: #f3e9da;
  --base: #3d3d3d;
  --base-dark: #2a2a2a;
  --coral: #d2604f;
  --ink: #333230;
  --muted: #8a8378;
  --line: #eadfcd;
}

* { font-family: 'Quicksand', ui-sans-serif, system-ui, sans-serif; }

body { background: var(--cream); color: var(--ink); overflow-x: hidden; }

/* ---------- Animated background decor ---------- */
#bg-decor { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.blob {
  position: absolute; border-radius: 58% 42% 55% 45% / 45% 52% 48% 55%;
  filter: blur(70px); opacity: .5; will-change: transform;
}
.blob-gray {
  width: 44vw; height: 44vw; background: #e0ddd8;
  top: -12vw; right: -10vw;
  animation: drift-a 26s ease-in-out infinite alternate;
}
.blob-coral {
  width: 34vw; height: 34vw; background: #f3cfc4;
  bottom: -10vw; left: -8vw;
  animation: drift-b 32s ease-in-out infinite alternate;
}
.blob-sand {
  width: 30vw; height: 30vw; background: #f0e2c8;
  top: 40%; left: 55%;
  animation: drift-c 38s ease-in-out infinite alternate;
}
.deco-ring {
  position: absolute; width: 22rem; height: 22rem; border-radius: 999px;
  border: 3rem solid rgba(61, 61, 61, .05);
  top: 55%; left: -8rem;
  animation: spin-slow 60s linear infinite;
}
@keyframes drift-a {
  from { transform: translate(0, 0) rotate(0deg) scale(1); }
  to   { transform: translate(-6vw, 5vw) rotate(28deg) scale(1.12); }
}
@keyframes drift-b {
  from { transform: translate(0, 0) rotate(0deg) scale(1); }
  to   { transform: translate(5vw, -6vw) rotate(-24deg) scale(1.08); }
}
@keyframes drift-c {
  from { transform: translate(0, 0) scale(1); border-radius: 58% 42% 55% 45% / 45% 52% 48% 55%; }
  to   { transform: translate(-4vw, -5vw) scale(1.15); border-radius: 45% 55% 42% 58% / 55% 45% 55% 45%; }
}
@keyframes spin-slow { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  .blob, .deco-ring { animation: none; }
  * { transition-duration: .01ms !important; }
}

main#app { position: relative; z-index: 1; }

/* ---------- Navigation ---------- */
.nav-btn {
  position: relative;
  padding: .5rem 1rem;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 600;
  transition: color .2s, background .2s, transform .2s, box-shadow .2s;
}
.nav-btn:hover { color: var(--base-dark); background: var(--sand); transform: translateY(-2px); }
.nav-btn.active {
  color: #fff; background: var(--base);
  box-shadow: 0 6px 16px -6px rgba(61, 61, 61, .5);
}

/* ---------- Cards ---------- */
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  box-shadow: 0 2px 10px -4px rgba(60, 45, 20, .08);
  transition: transform .25s cubic-bezier(.34,1.56,.64,1), box-shadow .25s ease, border-color .25s ease;
}
.contact-card:hover, .platform-pick:hover, .shared-person:hover {
  transform: translateY(-5px);
  box-shadow: 0 16px 30px -12px rgba(60, 45, 20, .22);
  border-color: #dcd8d2;
}
.contact-card:hover .avatar, .platform-pick:hover i.fa-solid,
.platform-pick:hover i.fas, .platform-pick:hover i.fa-brands {
  transform: scale(1.12) rotate(-4deg);
}
.avatar {
  width: 2.5rem; height: 2.5rem; border-radius: 999px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; color: #fff; flex-shrink: 0;
  transition: transform .3s cubic-bezier(.34,1.56,.64,1);
}

/* ---------- Buttons ---------- */
.btn-primary {
  background: var(--base); color: #fff !important;
  border-radius: 999px !important;
  box-shadow: 0 6px 16px -6px rgba(61, 61, 61, .45);
  transition: transform .2s, box-shadow .2s, background .2s;
}
.btn-primary:hover {
  background: #545454;
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 12px 22px -8px rgba(61, 61, 61, .55);
}
.btn-primary:active { transform: translateY(0) scale(.98); }

.btn-soft {
  background: var(--sand); color: var(--base-dark);
  border-radius: 999px !important;
  transition: transform .2s, background .2s, box-shadow .2s;
}
.btn-soft:hover { background: #ecdfc8; transform: translateY(-2px); box-shadow: 0 8px 16px -8px rgba(60,45,20,.25); }
.btn-soft:active { transform: scale(.97); }

.btn-danger {
  background: #f9e5e0; color: var(--coral);
  border-radius: 999px !important;
  transition: transform .2s, background .2s;
}
.btn-danger:hover { background: var(--coral); color: #fff; transform: translateY(-2px); }

/* ---------- Badges & tags ---------- */
.platform-badge {
  display: inline-flex; align-items: center; gap: .25rem;
  font-size: .65rem; padding: .18rem .55rem; border-radius: 999px;
  font-weight: 700; text-transform: capitalize;
  transition: transform .2s;
}
.platform-badge:hover { transform: scale(1.08); }
.pb-phone     { background: #e6e4e0; color: #4a4a4a; }
.pb-email     { background: #f6e3cf; color: #a05f1f; }
.pb-linkedin  { background: #dedede; color: #3d3d3d; }
.pb-facebook  { background: #eceae6; color: #5c5952; }
.pb-instagram { background: #f7ddda; color: #b8443a; }
.pb-tiktok    { background: #d8d6d2; color: #38362f; }
.pb-manual    { background: #efece7; color: #6e6a61; }

.interest-tag {
  display: inline-flex; align-items: center; gap: .3rem;
  background: #e9e7e2; color: var(--base-dark);
  font-size: .7rem; font-weight: 600; padding: .22rem .65rem; border-radius: 999px;
  transition: transform .2s, background .2s;
}
.interest-tag:hover { transform: translateY(-2px); background: #dedbd4; }

/* ---------- Import drop zone ---------- */
.drop-zone {
  border: 2px dashed #d9cbb4; border-radius: 1.5rem;
  background: #fffdf9;
  transition: all .25s;
}
.drop-zone:hover { border-color: var(--base); transform: translateY(-2px); }
.drop-zone.dragover {
  border-color: var(--coral); background: #fdf1ec;
  transform: scale(1.02);
  box-shadow: 0 16px 32px -14px rgba(210, 96, 79, .35);
}
.drop-zone i { transition: transform .3s cubic-bezier(.34,1.56,.64,1); }
.drop-zone:hover i, .drop-zone.dragover i { transform: translateY(-6px) scale(1.15); }

/* ---------- Forms ---------- */
input, select, textarea {
  background: #fff !important;
  border: 1px solid var(--line) !important;
  color: var(--ink) !important;
  border-radius: .75rem;
  padding: .5rem .8rem;
  transition: border-color .2s, box-shadow .2s;
}
input::placeholder, textarea::placeholder { color: #b3a893; }
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--base) !important;
  box-shadow: 0 0 0 3px rgba(61, 61, 61, .15);
}
input[type="range"] { accent-color: var(--base); border: none !important; box-shadow: none !important; }

/* ---------- Modal ---------- */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(42, 42, 42, .35);
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  z-index: 50; padding: 1rem;
}
.modal-overlay .card { animation: pop-in .3s cubic-bezier(.34,1.56,.64,1); }

/* ---------- Animations ---------- */
.fade-in { animation: fadeIn .35s ease-out; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes pop-in { from { opacity: 0; transform: scale(.92) translateY(14px); } to { opacity: 1; transform: none; } }

/* Staggered card entrance */
.grid > .card { animation: fadeIn .4s ease-out backwards; }
.grid > .card:nth-child(2) { animation-delay: .05s; }
.grid > .card:nth-child(3) { animation-delay: .1s; }
.grid > .card:nth-child(4) { animation-delay: .15s; }
.grid > .card:nth-child(5) { animation-delay: .2s; }
.grid > .card:nth-child(6) { animation-delay: .25s; }

/* ---------- Auth landing ---------- */
.auth-tab {
  padding: .45rem 1rem; border-radius: 999px;
  font-size: .8rem; font-weight: 700; color: var(--muted);
  transition: all .2s;
}
.auth-tab.active { background: #fff; color: var(--base-dark); box-shadow: 0 2px 8px -2px rgba(60,45,20,.18); }

/* ---------- AI Discovery Engine ---------- */
.ai-pulse-dot {
  display: inline-block; width: .55rem; height: .55rem; border-radius: 999px;
  background: var(--coral); margin-right: .4rem; vertical-align: middle;
  animation: ai-pulse 1.6s ease-in-out infinite;
}
@keyframes ai-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(210, 96, 79, .5); }
  50% { box-shadow: 0 0 0 7px rgba(210, 96, 79, 0); }
}
.ai-feed {
  background: #fffdf9; border: 1px solid var(--line); border-radius: 1rem;
  height: 18rem; overflow-y: auto; padding: .75rem;
  font-size: .74rem; line-height: 1.35;
}
.ai-log-row {
  display: flex; gap: .5rem; align-items: flex-start;
  padding: .3rem .4rem; border-radius: .5rem; color: var(--muted);
  animation: fadeIn .3s ease-out;
}
.ai-log-row i { margin-top: .12rem; width: 1rem; text-align: center; flex-shrink: 0; }
.ai-log-row.ai-sys { color: #a89d8d; }
.ai-log-row.ai-hit { color: var(--base-dark); background: #f8f1e7; }
.ai-log-row.ai-hit i { color: var(--coral); }
.ai-log-row.ai-done { color: var(--base-dark); font-weight: 600; }
.ai-log-row.ai-done i { color: #6a8f6e; }
.ai-suggestion { border-radius: .9rem !important; transition: opacity .3s, transform .25s, box-shadow .25s; }
.ai-suggestion:hover { transform: translateY(-2px); box-shadow: 0 10px 20px -10px rgba(60,45,20,.2); }

/* ---------- Footer ---------- */
#site-footer {
  position: relative; z-index: 1;
  border-top: 1px solid var(--line);
  background: rgba(250, 245, 238, .85);
  backdrop-filter: blur(10px);
  margin-top: 2.5rem;
  color: var(--muted);
}
.footer-link {
  color: var(--muted); font-weight: 600;
  transition: color .2s, transform .2s;
}
.footer-link:hover { color: var(--coral); transform: translateY(-1px); }

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-thumb { background: #d9cbb4; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #c7b699; }
