/* ═══════════════════════════════════════════════════════════
   ACP FOOTER ELEMENTS — footer-elements.css
   Footer + Back to Top + Need Help Button + Popup
   Place this file in your child theme folder.
═══════════════════════════════════════════════════════════ */

/* CSS Variables (only if your parent theme doesn't define these) */
:root {
  --acp-navy:        #0d1e35;
  --acp-navy-mid:    #152844;
  --acp-blue:        #1c5cbf;
  --acp-blue-lt:     #2c72e0;
  --acp-sky:         #e8f0fb;
  --acp-gold:        #b8842a;
  --acp-gold-bright: #d4a03c;
  --acp-gold-lt:     #faf3e4;
  --acp-gold-pale:   #f0ddb0;
  --acp-border:      #d8e3f0;
  --acp-border-lt:   #ecf2fb;
  --acp-muted:       #4f5e74;
  --acp-white:       #ffffff;
  --acp-font-display:'DM Serif Display', Georgia, serif;
  --acp-font-body:   'Jost', system-ui, sans-serif;
}

/* ── CONTAINER ── */
.acp-container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 28px;
}

/* ════════════════════════════════════════
   FOOTER
════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Jost:wght@200;300;400;500;600&display=swap');

footer {
  background: linear-gradient(160deg, #0d1e35 0%, #122a4a 40%, #1a3a5c 70%, #1c4f7a 100%) !important;
  font-family: 'Jost', sans-serif !important;
}

footer, footer * {
  font-family: 'Jost', sans-serif !important;
}

footer, footer * {
  font-family: 'Jost', system-ui, sans-serif !important;
  font-weight: 300 !important;
  letter-spacing: 0.01em !important;
  -webkit-font-smoothing: antialiased !important;
}

.footer-col h4 {
  font-weight: 600 !important;
  letter-spacing: 2.5px !important;
  text-transform: uppercase !important;
}

.footer-col a {
  font-weight: 300 !important;
}

.footer-brand p {
  font-weight: 300 !important;
}

footer {
  background: linear-gradient(160deg, #0d1e35 0%, #122a4a 40%, #1a3a5c 70%, #1c4f7a 100%);
  color: rgba(255,255,255,0.65);
  padding: 0;
  position: relative;
  overflow: hidden;
}
footer::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--acp-gold-bright), var(--acp-blue), transparent);
}

/* ── FLIGHT ANIMATION ── */
.footer-planes { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.fplane {
  position: absolute;
  font-size: 22px;
  opacity: 0.07;
  animation: flyAcross linear infinite;
  white-space: nowrap;
}
.fplane:nth-child(1) { top: 12%; animation-duration: 18s; animation-delay: 0s;   font-size: 18px; }
.fplane:nth-child(2) { top: 35%; animation-duration: 24s; animation-delay: -6s;  font-size: 26px; opacity: 0.05; }
.fplane:nth-child(3) { top: 58%; animation-duration: 20s; animation-delay: -10s; font-size: 16px; }
.fplane:nth-child(4) { top: 78%; animation-duration: 28s; animation-delay: -3s;  font-size: 20px; opacity: 0.06; }
.fplane:nth-child(5) { top: 22%; animation-duration: 15s; animation-delay: -14s; font-size: 14px; opacity: 0.05; }
@keyframes flyAcross  {
  from { transform: translateX(-120px) rotate(-5deg); left: -5%; }
  to   { transform: translateX(0)      rotate(-5deg); left: 110%; }
}
.fplane::after {
  content: '· · · ·';
  font-size: 10px; letter-spacing: 4px;
  margin-left: 4px;
  vertical-align: middle;
  opacity: 0.5;
}

/* ── FOOTER TOP ── */
.footer-top {
  padding: 72px 0 56px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  position: relative; z-index: 1;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1fr;
  gap: 60px;
}
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
}
@media (max-width: 560px) {
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
}

/* Brand col */
.footer-brand { display: flex; flex-direction: column; gap: 20px; }
.footer-logo  { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.footer-brand p {
  font-family: var(--acp-font-body);
  font-size: 15px; font-weight: 300;
  line-height: 1.85; color: rgba(255,255,255,0.7);
  max-width: 280px;
}
.footer-social { display: flex; gap: 10px; margin-top: 4px; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.08);
  display: flex; align-items: center; justify-content: center;
  text-decoration: none; color: #fff;
  transition: border-color 0.2s, background 0.2s, transform 0.2s, box-shadow 0.2s;
}
.footer-social a:hover {
  border-color: var(--acp-gold-bright);
  background: rgba(212,160,60,0.15);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  text-decoration: none;
}

/* Nav cols */
.footer-col h4 {
  font-family: var(--acp-font-body);
  font-size: 12px; font-weight: 600; color: var(--acp-gold-bright);
  margin-bottom: 22px; text-transform: uppercase; letter-spacing: 2.5px;
  display: flex; align-items: center; gap: 8px;
}
.footer-col h4::after {
  content: ''; flex: 1; height: 1px;
  background: linear-gradient(90deg, rgba(212,160,60,0.3), transparent);
}
.footer-col ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 2px; }
.footer-col a {
  font-family: var(--acp-font-body);
  font-size: 15px; font-weight: 300; color: rgba(255,255,255,0.75);
  transition: color 0.2s, padding-left 0.2s;
  display: inline-block; padding: 5px 0;
  text-decoration: none;
}
.footer-col a:hover { color: #fff; padding-left: 6px; text-decoration: none; }

/* Disclaimer */
.footer-disclaimer {
  padding: 28px 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  display: flex; gap: 16px; align-items: flex-start;
  position: relative; z-index: 1;
}
.footer-disclaimer-icon {
  flex-shrink: 0;
  width: 32px; height: 32px; border-radius: 8px;
  background: rgba(212,160,60,0.15);
  border: 1px solid rgba(212,160,60,0.35);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; margin-top: 2px;
}
.footer-disclaimer p {
  font-family: var(--acp-font-body);
  font-size: 14px; font-weight: 300; line-height: 1.85;
  color: rgba(255,255,255,0.65);
}
.footer-disclaimer strong { color: var(--acp-gold-bright); font-weight: 500; }

/* Bottom bar */
.footer-bottom {
  padding: 22px 0;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px;
  font-family: var(--acp-font-body); font-size: 14px; font-weight: 300;
  color: rgba(255,255,255,0.55);
  position: relative; z-index: 1;
}

/* ════════════════════════════════════════
   BACK TO TOP BUTTON
════════════════════════════════════════ */
#back-to-top {
  position: fixed; bottom: 110px; right: 28px; z-index: 899;
  width: 44px; height: 44px; border-radius: 50%;
  background: linear-gradient(135deg, #0d1e35, #1c3a5c);
  border: 1.5px solid rgba(255,255,255,0.15);
  color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 16px rgba(10,20,40,0.35);
  opacity: 0; transform: translateY(12px);
  transition: opacity 0.3s, transform 0.3s, background 0.2s, box-shadow 0.2s;
  pointer-events: none;
}
#back-to-top.visible {
  opacity: 1; transform: translateY(0); pointer-events: auto;
}
#back-to-top:hover {
  background: linear-gradient(135deg, var(--acp-blue), #1e8fd4);
  box-shadow: 0 6px 20px rgba(28,92,191,0.4);
  transform: translateY(-2px);
}

/* ════════════════════════════════════════
   HELP BUTTON
════════════════════════════════════════ */
#help-btn {
  position: fixed; bottom: 28px; right: 28px; z-index: 900;
  display: flex; align-items: center; gap: 9px;
  background: linear-gradient(135deg, #1565c0, #1e8fd4, #1565c0);
  background-size: 200% 200%;
  color: #fff; border: none;
  border-radius: 50px; padding: 13px 22px 13px 18px;
  font-family: var(--acp-font-body); font-size: 15px; font-weight: 700;
  cursor: pointer;
  box-shadow: 0 0 0 0 rgba(30,143,212,0.7);
  animation: acpAttention 1.8s ease-in-out infinite;
}
#help-btn:hover {
  background: linear-gradient(135deg, #0d47a1, #1565c0);
  transform: scale(1.06);
  box-shadow: 0 8px 30px rgba(26,111,168,0.7);
  animation: none;
}
@keyframes acpAttention {
  0%   { transform: scale(1);    box-shadow: 0 0 0 0 rgba(30,143,212,0.8); }
  40%  { transform: scale(1.07); box-shadow: 0 0 0 14px rgba(30,143,212,0); }
  60%  { transform: scale(0.97); }
  80%  { transform: scale(1.03); }
  100% { transform: scale(1);    box-shadow: 0 0 0 0 rgba(30,143,212,0); }
}
#help-btn::before {
  content: ''; position: absolute; inset: -6px; border-radius: 50px;
  border: 2.5px solid rgba(30,143,212,0.6);
  opacity: 0; animation: acpRingExpand 1.8s ease-out infinite;
}
#help-btn::after {
  content: ''; position: absolute; inset: -14px; border-radius: 50px;
  border: 2px solid rgba(30,143,212,0.3);
  opacity: 0; animation: acpRingExpand 1.8s ease-out infinite 0.35s;
}
#help-btn svg { animation: acpPhoneRing 1.8s ease-in-out infinite; transform-origin: center; }
@keyframes acpPhoneRing {
  0%,100% { transform: rotate(0deg)   scale(1);    }
  10%     { transform: rotate(-18deg) scale(1.15); }
  20%     { transform: rotate(18deg)  scale(1.15); }
  30%     { transform: rotate(-14deg) scale(1.1);  }
  40%     { transform: rotate(14deg)  scale(1.1);  }
  50%     { transform: rotate(-8deg)  scale(1.05); }
  60%     { transform: rotate(8deg)   scale(1.05); }
  70%     { transform: rotate(0deg)   scale(1);    }
}
@keyframes acpRingExpand {
  0%   { opacity: 0.9; transform: scale(0.95); }
  100% { opacity: 0;   transform: scale(1.3);  }
}

/* ════════════════════════════════════════
   POPUP
════════════════════════════════════════ */
#acp-popup-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(10,22,40,0.55); z-index: 1000;
  backdrop-filter: blur(3px);
  animation: acpFadeIn 0.2s ease;
}
#acp-popup-overlay.open { display: block; }

#acp-help-popup {
  display: none; position: fixed; bottom: 100px; right: 28px;
  width: min(360px, calc(100vw - 40px)); background: #fff;
  border-radius: 16px; padding: 32px 28px 24px; z-index: 1001;
  box-shadow: 0 20px 60px rgba(10,22,40,0.18), 0 4px 16px rgba(10,22,40,0.08);
  animation: acpSlideUp 0.25s cubic-bezier(0.34,1.2,0.64,1);
  font-family: var(--acp-font-body);
}
#acp-help-popup.open { display: block; }

@keyframes acpSlideUp {
  from { opacity:0; transform:translateY(20px) scale(0.97); }
  to   { opacity:1; transform:translateY(0) scale(1); }
}
@keyframes acpFadeIn {
  from { opacity:0; } to { opacity:1; }
}

#acp-popup-close {
  position: absolute; top: 14px; right: 16px;
  background: #f0ede8; border: none; border-radius: 50%;
  width: 30px; height: 30px; font-size: 18px; line-height: 30px;
  text-align: center; cursor: pointer; color: #2a2420; padding: 0;
  transition: background 0.15s;
}
#acp-popup-close:hover { background: #e2ddd6; }

#acp-popup-icon {
  width: 56px; height: 56px; border-radius: 50%;
  background: #0d1e35; display: flex; align-items: center;
  justify-content: center; margin-bottom: 16px;
}
#acp-popup-title {
  font-family: var(--acp-font-display);
  font-size: 19px; font-weight: 700; color: #0d1e35; line-height: 1.25; margin-bottom: 10px;
}
.acp-popup-sub { font-size: 13.5px; color: var(--acp-muted); line-height: 1.7; margin-bottom: 20px; }

#acp-popup-phone {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  background: #1a6fa8; color: #fff; text-decoration: none;
  border-radius: 10px; padding: 14px 20px;
  font-size: 20px; font-weight: 700; letter-spacing: 0.5px;
  transition: background 0.2s, transform 0.15s; margin-bottom: 12px;
}
#acp-popup-phone:hover { background: #155d8f; transform: scale(1.02); text-decoration: none; }

.acp-popup-hours {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-size: 12.5px; color: var(--acp-muted); margin-bottom: 18px;
}
.acp-popup-divider { height: 1px; background: var(--acp-border); margin-bottom: 14px; }
.acp-popup-disclaimer { font-size: 11.5px; color: #a09488; line-height: 1.6; text-align: center; }
