/* ============================================================
   Footer + Floating LINE button
   ============================================================ */

.footer {
  position: relative;
  margin-top: var(--sp-12);
  padding: var(--sp-16) 0 var(--sp-8);
  background: linear-gradient(180deg, transparent, rgba(0,0,0,0.4));
  border-top: 1px solid var(--c-border-soft);
}

.footer-grid {
  display: grid;
  gap: var(--sp-8);
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: var(--sp-6);
  }
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-3);
  font-family: var(--ff-display);
  font-weight: var(--fw-black);
  font-size: 1.25rem;
  color: var(--c-text);
}
.footer-logo-mark {
  width: 32px; height: 32px;
  border-radius: 8px;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--c-accent) 0%, #8B5CF6 100%);
}
.footer-logo-mark svg {
  width: 18px; height: 18px;
  color: var(--c-bg);
}
.footer-tagline {
  color: var(--c-muted);
  font-size: var(--fs-small);
  line-height: var(--lh-snug);
  max-width: 32ch;
}
.footer-social {
  display: flex;
  gap: var(--sp-2);
  margin-top: var(--sp-2);
}
.footer-social a {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--c-border-soft);
  color: var(--c-muted);
  transition: all var(--dur-fast);
}
.footer-social a:hover {
  color: var(--c-accent);
  border-color: var(--c-border);
  background: rgba(34,211,238,0.06);
  transform: translateY(-2px);
}
.footer-social svg { width: 16px; height: 16px; }

.footer-col h5 {
  font-family: var(--ff-sans);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-text);
  margin-bottom: var(--sp-3);
}
.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}
.footer-col a {
  color: var(--c-muted);
  font-size: var(--fs-small);
  transition: color var(--dur-fast);
}
.footer-col a:hover { color: var(--c-accent); }

.footer-bottom {
  margin-top: var(--sp-10);
  padding-top: var(--sp-5);
  border-top: 1px solid var(--c-border-soft);
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  font-size: var(--fs-xs);
  color: var(--c-muted);
}
@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}
.footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
}
.footer-legal a:hover { color: var(--c-accent); }

/* ============================================================
   Floating LINE button — 永遠可見的右下角主 CTA
   ============================================================ */

.floating-line {
  position: fixed;
  bottom: var(--sp-5);
  right: var(--sp-5);
  z-index: var(--z-floating);
  width: 60px; height: 60px;
  border-radius: 50%;
  background: var(--c-line);
  display: grid;
  place-items: center;
  box-shadow: 0 10px 28px rgba(6,199,85,0.4);
  transition: transform var(--dur-base) var(--ease-out),
              box-shadow var(--dur-base);
  opacity: 0;
  transform: translateY(20px) scale(0.8);
  animation: float-in 0.6s var(--ease-out) 0.8s forwards;
  color: #fff;
}
.floating-line:hover {
  color: #fff;
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 16px 36px rgba(6,199,85,0.55);
}
.floating-line svg {
  width: 30px; height: 30px;
  fill: #fff;
}
@keyframes float-in {
  0%   { opacity: 0; transform: translateY(20px) scale(0.8); }
  60%  { opacity: 1; transform: translateY(-4px) scale(1.05); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

/* 持續微脈動 */
.floating-line::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: 0 0 0 0 rgba(6,199,85,0.5);
  animation: float-pulse 2.4s ease-out infinite;
  animation-delay: 1.5s;
  pointer-events: none;
}
@keyframes float-pulse {
  0%, 60% { box-shadow: 0 0 0 0 rgba(6,199,85,0.5); }
  100%    { box-shadow: 0 0 0 18px rgba(6,199,85,0); }
}

/* tooltip */
.floating-line-tip {
  position: absolute;
  right: calc(100% + var(--sp-3));
  top: 50%;
  transform: translateY(-50%);
  white-space: nowrap;
  background: var(--c-surface);
  color: var(--c-text);
  padding: 8px 14px;
  border-radius: var(--r-pill);
  border: 1px solid var(--c-border-soft);
  font-size: var(--fs-small);
  font-weight: var(--fw-semibold);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur-fast);
  box-shadow: var(--sh-md);
}
.floating-line:hover .floating-line-tip { opacity: 1; }

@media (max-width: 480px) {
  .floating-line { width: 56px; height: 56px; bottom: var(--sp-4); right: var(--sp-4); }
  .floating-line svg { width: 26px; height: 26px; }
  .floating-line-tip { display: none; }
}
