/* Social links: the fixed bar on the side, the WhatsApp button and the footer icons.
   Plain CSS (no Tailwind build needed). Logical properties: in Arabic (RTL) the bar sits on
   the right and WhatsApp on the left; in English (LTR) they swap. */

.social-rail {
  position: fixed;
  top: 50%;
  inset-inline-start: 20px;
  transform: translateY(-50%);
  z-index: 40;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 8px;
  margin: 0;
  list-style: none;
  background: #4a0f20;
  border-radius: 999px;
  box-shadow: 0 12px 30px rgba(34, 6, 16, 0.22);
}

.social-rail__link {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  color: #f5efe5;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.social-rail__link:hover,
.social-rail__link:focus-visible {
  background: #7a2a3e;
  color: #c9a24b;
  outline: none;
}

.social-rail__link:focus-visible {
  box-shadow: 0 0 0 2px #c9a24b;
}

.social-rail__icon {
  width: 20px;
  height: 20px;
}

/* The platform's name, shown next to the icon on hover and keyboard focus */
.social-rail__label {
  position: absolute;
  inset-inline-start: calc(100% + 12px);
  white-space: nowrap;
  padding: 6px 12px;
  border-radius: 8px;
  background: #220610;
  color: #f5efe5;
  font-size: 13px;
  line-height: 1.4;
  opacity: 0;
  pointer-events: none;
  transform: translateX(4px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

[dir="rtl"] .social-rail__label {
  transform: translateX(-4px);
}

.social-rail__link:hover .social-rail__label,
.social-rail__link:focus-visible .social-rail__label {
  opacity: 1;
  transform: none;
}

/* WhatsApp: a round icon button that opens the chat straight away */
.whatsapp-fab {
  position: fixed;
  bottom: 28px;
  inset-inline-end: 28px;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  border-radius: 999px;
  background: #25d366;
  color: #0b2e1a;
  text-decoration: none;
  box-shadow: 0 10px 28px rgba(11, 46, 26, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.whatsapp-fab:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 32px rgba(11, 46, 26, 0.34);
  color: #0b2e1a;
}

.whatsapp-fab:focus-visible {
  outline: 3px solid #c9a24b;
  outline-offset: 3px;
}

.whatsapp-fab__icon {
  width: 30px;
  height: 30px;
}

/* Footer icons */
.footer-social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.footer-social__link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(201, 162, 75, 0.45);
  color: #f5efe5;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.footer-social__link:hover,
.footer-social__link:focus-visible {
  background: #c9a24b;
  border-color: #c9a24b;
  color: #220610;
  outline: none;
}

.footer-social__icon {
  width: 19px;
  height: 19px;
}

/* Phones and tablets: no side bar (the footer has the links), a round WhatsApp button */
@media (max-width: 1023px) {
  .social-rail {
    display: none;
  }

  .whatsapp-fab {
    bottom: 20px;
    inset-inline-end: 16px;
    width: 56px;
    height: 56px;
  }

}

@media (prefers-reduced-motion: reduce) {
  .social-rail__link,
  .social-rail__label,
  .whatsapp-fab,
  .footer-social__link {
    transition: none;
  }
}

@media print {
  .social-rail,
  .whatsapp-fab {
    display: none;
  }
}
