/**
 * Site footer + sticky CTA (Phase FOOTER-2).
 * Own "almf-" / "almx-" namespaces; shares buttons, call icon and the live
 * dot with site-header.css (almh-btn, almh-call__icon, almh-live__dot).
 */

/* ---------- Footer shell ---------- */
.almf {
  position: relative; margin-top: 96px;
  display: flow-root; /* keeps the CTA card's negative margin from collapsing into the footer's */
  background:
    radial-gradient(circle at 85% 0%, rgba(201, 154, 58, .14), transparent 45%),
    linear-gradient(180deg, var(--alm-navy-2), var(--alm-navy) 38%);
  color: rgba(255, 255, 255, .78);
  direction: rtl; text-align: right;
}
.almf a { color: inherit; text-decoration: none; }

/* ---------- CTA card (overlaps the section above) ---------- */
.almf-cta { position: relative; margin-top: -64px; }
/* The theme gives every <section> 60px vertical padding; footer sections size themselves. */
.almf-cta, .almf-brand { padding: 0; }
.almf-cta__card {
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  padding: 28px 32px; border-radius: 28px;
  background:
    repeating-linear-gradient(135deg, rgba(16, 32, 51, .035) 0 2px, transparent 2px 14px),
    linear-gradient(135deg, #FBF7EF, var(--alm-sand));
  border: 1px solid rgba(201, 154, 58, .35);
  box-shadow: 0 24px 60px rgba(16, 32, 51, .22);
  color: var(--alm-navy);
}
.almf-cta__card::before { /* gold corner accent */
  content: ""; position: absolute; inset-inline-start: -60px; top: -60px; width: 180px; height: 180px; border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 154, 58, .35), transparent 70%);
}
.almf-cta__copy { position: relative; }
.almf-cta__kicker { margin: 0 0 6px; display: inline-flex; align-items: center; gap: 8px; font-weight: 900; font-size: .85rem; color: var(--alm-green); }
.almf-cta__title { margin: 0 0 12px; font-weight: 1000; font-size: clamp(1.25rem, 2.4vw, 1.7rem); line-height: 1.4; }
.almf-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 18px; font-weight: 800; color: var(--alm-slate); font-size: .92rem; }
.almf-steps li { display: inline-flex; align-items: center; gap: 8px; }
.almf-steps span {
  width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: var(--alm-navy); color: var(--alm-gold); font-weight: 1000; font-size: .8rem;
}
.almf-cta__actions { position: relative; display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.almf-cta__wa { padding: 15px 22px; font-size: 1.02rem; }
.almf-cta__call { display: inline-flex; align-items: center; gap: 10px; color: var(--alm-navy) !important; }
.almf-cta__call small { display: block; color: var(--alm-slate); font-weight: 800; font-size: .76rem; }
.almf-cta__call b { display: block; font-weight: 1000; direction: ltr; text-align: right; }
.almf-cta__call:hover .almh-call__icon { transform: rotate(-12deg) scale(1.05); }

/* ---------- Main grid ---------- */
.almf-main { padding: 52px 0 34px; }
.almf-grid { display: grid; grid-template-columns: 1.35fr 1fr 1.1fr 1.25fr; gap: 34px; align-items: start; }

.almf-logo { display: inline-block; }
.almf-logo .alm-footer__logoimg { height: 56px; width: auto; max-width: 190px; border-radius: 14px; background: var(--alm-sand); padding: 6px 10px; object-fit: contain; }
.almf-slogan { margin: 14px 0 6px; color: var(--alm-gold); font-weight: 1000; }
.almf-desc { margin: 0 0 14px; line-height: 1.9; font-size: .92rem; }
.almf-badges { list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.almf-badges li {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 11px; border-radius: 999px;
  background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .10);
  font-size: .82rem; font-weight: 800; color: #fff;
}
.almf-badges .alm-icon { color: var(--alm-gold); }
.almf-google {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 14px;
  background: #fff; color: var(--alm-navy) !important; font-weight: 900; font-size: .9rem;
  transition: transform .2s ease, box-shadow .2s ease;
}
.almf-google:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0, 0, 0, .25); }
.almf-google__stars { color: #F5B301; letter-spacing: 1px; }
.almf-social { display: flex; gap: 8px; margin-top: 12px; }
.almf-social a { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: rgba(255, 255, 255, .08); font-weight: 900; }
.almf-social a:hover { background: var(--alm-gold); color: var(--alm-navy); }

.almf-title {
  display: flex; align-items: center; justify-content: space-between; width: 100%;
  margin: 0 0 14px; padding: 0; border: 0; background: none; cursor: default;
  font: inherit; font-weight: 1000; font-size: 1.02rem; color: var(--alm-gold); text-align: right;
}
.almf-title .almh-chev { display: none; }
.almf-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.almf-links--2col { grid-template-columns: 1fr 1fr; column-gap: 14px; }
.almf-links a {
  position: relative; display: inline-block; padding: 5px 0; font-weight: 700; font-size: .93rem;
  transition: color .2s ease, padding .2s ease;
}
.almf-links a::before {
  content: ""; position: absolute; inset-inline-start: 0; top: 50%; width: 6px; height: 6px; margin-top: -3px;
  border-radius: 50%; background: var(--alm-gold); transform: scale(0); transition: transform .2s ease;
}
.almf-links a:hover { color: #fff; padding-inline-start: 14px; }
.almf-links a:hover::before { transform: scale(1); }
.almf-more { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; color: var(--alm-gold) !important; font-weight: 900; }
.almf-more:hover { text-decoration: underline; }

.almf-contact {
  padding: 20px; border-radius: 22px;
  background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .10);
}
.almf-contact__title { margin: 0 0 12px; color: var(--alm-gold); font-weight: 1000; font-size: 1.02rem; }
.almf-contact__phone { display: flex; align-items: center; gap: 10px; color: #fff !important; font-size: 1.35rem; margin-bottom: 8px; }
.almf-contact__phone .alm-icon { color: var(--alm-gold); }
.almf-contact__phone b { direction: ltr; font-weight: 1000; letter-spacing: .5px; }
.almf-contact__wa {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 12px; margin-bottom: 14px;
  background: rgba(37, 211, 102, .14); color: #7EE6A7 !important; font-weight: 900; font-size: .9rem;
}
.almf-contact__wa:hover { background: rgba(37, 211, 102, .24); }
.almf-contact__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-size: .88rem; line-height: 1.7; }
.almf-contact__list li { display: flex; align-items: flex-start; gap: 8px; }
.almf-contact__list .alm-icon { color: var(--alm-gold); flex: none; margin-top: 4px; }
.almf-contact__list .almh-live__dot { margin-top: 8px; }
.almf-contact__list strong { color: #fff; }
.almf-contact__list a { text-decoration: underline; text-underline-offset: 3px; }
.almf-contact__list a:hover { color: var(--alm-gold); }

/* ---------- Bottom ---------- */
.almf-bottom { border-top: 1px solid rgba(255, 255, 255, .08); }
.almf-bottom__inner { display: flex; align-items: center; gap: 16px; padding: 16px 0; flex-wrap: wrap; }
.almf-copy { margin: 0; font-size: .85rem; }
.almf-legal { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-inline-start: auto; font-size: .85rem; }
.almf-legal a:hover { color: var(--alm-gold); }
.almf-top {
  width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; cursor: pointer;
  background: transparent; border: 1px solid rgba(201, 154, 58, .6); color: var(--alm-gold); font-size: 18px;
  transition: background .2s ease, color .2s ease, transform .2s ease;
}
.almf-top .alm-icon { transform: rotate(180deg); }
.almf-top:hover { background: var(--alm-gold); color: var(--alm-navy); transform: translateY(-2px); }

/* ---------- Sticky CTA dock (phones) ---------- */
.almx {
  position: fixed; z-index: 990; inset-inline: 10px; bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  display: none; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 6px;
  padding: 8px 10px; border-radius: 22px; direction: rtl;
  background: rgba(16, 32, 51, .94);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  box-shadow: 0 16px 40px rgba(16, 32, 51, .35); border: 1px solid rgba(201, 154, 58, .25);
  transition: transform .3s cubic-bezier(.2, .8, .2, 1), opacity .3s ease;
}
.almx.is-hidden { transform: translateY(150%); opacity: 0; pointer-events: none; }
.almx__item {
  display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 4px 0;
  background: none; border: 0; cursor: pointer; font: inherit;
  color: rgba(255, 255, 255, .86); text-decoration: none; font-weight: 800; font-size: .74rem;
}
.almx__item:hover, .almx__item:focus-visible { color: #fff; }
.almx__icon { width: 34px; height: 34px; border-radius: 12px; display: grid; place-items: center; font-size: 18px; color: var(--alm-gold); background: rgba(255, 255, 255, .06); }
.almx__icon--menu { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 4px; }
.almx__icon--menu i { display: block; width: 16px; height: 2px; border-radius: 2px; background: var(--alm-gold); }
.almx__icon--menu i:nth-child(2) { width: 11px; margin-inline-start: 5px; }
.almx__main {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  margin-top: -26px; padding: 15px 20px; border-radius: 18px;
  background: linear-gradient(135deg, #D9B45A, var(--alm-gold) 55%, #A97E25);
  color: var(--alm-navy); font-weight: 1000; font-size: .95rem; text-decoration: none; white-space: nowrap;
  box-shadow: 0 12px 26px rgba(201, 154, 58, .45), 0 0 0 4px rgba(16, 32, 51, .94);
}
.almx__main { padding: 10px 16px 10px 18px; gap: 10px; }
.almx__phone {
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-size: 19px;
  background: var(--alm-navy); color: var(--alm-gold);
  animation: almx-shake 3.2s ease-in-out infinite;
}
@keyframes almx-shake { /* a short "ringing" nudge every few seconds */
  0%, 82%, 100% { transform: rotate(0); }
  85% { transform: rotate(-14deg); } 88% { transform: rotate(12deg); }
  91% { transform: rotate(-10deg); } 94% { transform: rotate(8deg); }
}
.almx__main-text { display: flex; flex-direction: column; line-height: 1.15; text-align: right; }
.almx__main-text b { font-weight: 1000; font-size: .98rem; }
.almx__main-text small { font-weight: 900; font-size: .78rem; direction: ltr; text-align: right; opacity: .85; }
.almx__item--wa .almx__icon { color: #7EE6A7; background: rgba(37, 211, 102, .14); }
.almx__ring {
  position: absolute; inset: -4px; border-radius: 22px; border: 2px solid rgba(201, 154, 58, .7);
  animation: almx-ring 2.4s ease-out infinite; pointer-events: none;
}
@keyframes almx-ring {
  0% { transform: scale(.96); opacity: .9; }
  80%, 100% { transform: scale(1.18); opacity: 0; }
}

/* ---------- Floating WhatsApp (desktop) ---------- */
.almx-fab {
  /* Right-hand side (RTL start): the back-to-top button sits at the left end of the footer bar. */
  position: fixed; z-index: 990; bottom: 26px; inset-inline-start: 26px;
  width: 62px; height: 62px; border-radius: 50%; display: grid; place-items: center;
  background: var(--alm-whatsapp); color: #fff; font-size: 28px; text-decoration: none;
  box-shadow: 0 14px 30px rgba(37, 211, 102, .45);
  transform: scale(.6) translateY(30px); opacity: 0; pointer-events: none;
  transition: transform .3s cubic-bezier(.2, .8, .2, 1), opacity .3s ease;
}
.almx-fab.is-visible { transform: none; opacity: 1; pointer-events: auto; }
.almx-fab:hover { color: #fff; }
.almx-fab__ring { position: absolute; inset: -6px; border-radius: 50%; border: 2px solid rgba(37, 211, 102, .6); animation: almx-ring 2.4s ease-out infinite; }
.almx-fab__tip {
  position: absolute; inset-inline-start: 74px; top: 50%; transform: translateY(-50%) translateX(8px);
  padding: 9px 14px; border-radius: 12px; white-space: nowrap; font-size: .88rem; font-weight: 900;
  background: var(--alm-navy); color: #fff; opacity: 0; pointer-events: none; transition: opacity .2s ease, transform .2s ease;
}
.almx-fab:hover .almx-fab__tip, .almx-fab:focus-visible .almx-fab__tip { opacity: 1; transform: translateY(-50%); }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .almf-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 1024px) {
  .almx { display: grid; }
  .almx-fab { display: none; }
  .almf-bottom__inner { padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
}
@media (max-width: 700px) {
  .almf { margin-top: 80px; }
  .almf-cta__card { padding: 22px 18px; border-radius: 24px; }
  .almf-cta__actions { width: 100%; }
  .almf-cta__wa { width: 100%; }
  .almf-grid { grid-template-columns: 1fr; gap: 6px; }
  .almf-brand { margin-bottom: 14px; }
  .almf-col { border-top: 1px solid rgba(255, 255, 255, .08); }
  .almf-title { cursor: pointer; margin: 0; padding: 15px 0; }
  .almf-title .almh-chev { display: inline-block; transition: transform .25s ease; }
  .almf-col.is-collapsed .almf-title .almh-chev { transform: rotate(-90deg); }
  .almf-col.is-collapsed .almf-links, .almf-col.is-collapsed .almf-more { display: none; }
  .almf-col .almf-links { padding-bottom: 12px; }
  .almf-contact { margin-top: 14px; }
  .almf-legal { margin-inline-start: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .almf *, .almx, .almx *, .almx-fab, .almx-fab * { transition: none !important; animation: none !important; }
}
