/* Social Services Widget (Front) */
.fpsw-social-section,
.fpsw-social-section *{
  box-sizing: border-box;
}

.fpsw-social-section{
  position: relative;
  width: 100%;
  max-width: 100%;
  overflow: hidden; /* prevent sideways scroll on mobile */
  direction: rtl;
  padding: 26px 0;
  --fpsw-cols: 4;
  --fpsw-accent: #F4B42A;
  --fpsw-border: #1D4ED8;
  --fpsw-card-bg: #ffffff;
  --fpsw-title: #0F172A;
  --fpsw-text: #334155;
  --fpsw-bg: #1D4ED8;
  --fpsw-bg-opacity: 0.10;
  --fpsw-bg-speed: 16s;
}

/* container */
.fpsw-social-container{
  width: 100%;
  max-width: 1220px;
  margin: 0 auto;
  padding: 0 18px;
  position: relative;
  z-index: 2;
}

/* heading */
.fpsw-social-heading{
  text-align: center;
  margin-bottom: 22px;
}
.fpsw-social-heading h2{
  margin: 0 0 10px;
  font-size: clamp(22px, 2.4vw, 34px);
  line-height: 1.25;
  color: var(--fpsw-title);
  font-weight: 800;
}
.fpsw-social-heading p{
  margin: 0 auto;
  max-width: 860px;
  font-size: 15px;
  line-height: 1.85;
  color: var(--fpsw-text);
}

/* grid */
.fpsw-social-grid{
  display: grid;
  grid-template-columns: repeat(var(--fpsw-cols), minmax(0, 1fr));
  gap: 22px;
  align-items: stretch;
}

/* card */
.fpsw-social-card{
  position: relative;
  background: var(--fpsw-card-bg);
  border: 2px solid var(--fpsw-border);
  border-radius: 22px;
  padding: 26px 20px 22px;
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.10);
  overflow: hidden;
}

.fpsw-social-icon{
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}
.fpsw-social-icon img{
  width: 70px;
  height: 70px;
  object-fit: contain;
  display: block;
}
.fpsw-fallback-icon{
  width: 70px;
  height: 70px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  background: color-mix(in srgb, var(--fpsw-accent) 18%, transparent);
}
.fpsw-fallback-icon svg{
  width: 36px;
  height: 36px;
  fill: var(--fpsw-accent);
}

.fpsw-social-card h3{
  margin: 0 0 12px;
  text-align: center;
  font-size: 20px;
  line-height: 1.35;
  color: var(--fpsw-title);
  font-weight: 800;
}

/* bullets */
/* support both old/new classnames to avoid styling break */
.fpsw-social-bullets,
.fpsw-social-list{
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.fpsw-social-bullets li,
.fpsw-social-list li{
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--fpsw-text);
  font-size: 14px;
  line-height: 1.7;
}
.fpsw-social-check,
.fpsw-check{
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  color: #fff;
  background: var(--fpsw-accent);
  margin-top: 3px;
}
.fpsw-social-check svg,
.fpsw-check svg{
  width: 12px;
  height: 12px;
  display: block;
  fill: currentColor;
}

/* animated background */
.fpsw-social-bg{
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: var(--fpsw-bg-opacity);
}
.fpsw-social-bg .fpsw-bg-left,
.fpsw-social-bg .fpsw-bg-right{
  position: absolute;
  width: min(260px, 40vw);
  height: auto;
  color: var(--fpsw-bg);
  filter: drop-shadow(0 10px 22px rgba(15, 23, 42, 0.14));
  animation: fpswFloat var(--fpsw-bg-speed) ease-in-out infinite;
  transform-origin: center;
}
.fpsw-social-bg .fpsw-bg-left{
  left: -90px;
  top: 18px;
}
.fpsw-social-bg .fpsw-bg-right{
  right: -110px;
  bottom: 16px;
  animation-delay: -4s;
}
.fpsw-social-bg svg{
  width: 100%;
  height: auto;
  display: block;
}
.fpsw-social-bg svg polygon,
.fpsw-social-bg svg line{
  stroke: currentColor;
  stroke-width: 3;
  fill: none;
  opacity: 0.85;
}

@keyframes fpswFloat{
  0%   { transform: translateY(0) rotate(0deg); }
  50%  { transform: translateY(-14px) rotate(3deg); }
  100% { transform: translateY(0) rotate(0deg); }
}

/* responsive */
@media (max-width: 1024px){
  .fpsw-social-section{ --fpsw-cols: 2; }
}
@media (max-width: 767px){
  .fpsw-social-section{
    --fpsw-cols: 1;
    padding: 18px 0;
  }
  .fpsw-social-container{ padding: 0 14px; }
  .fpsw-social-card{
    padding: 20px 16px 18px;
    border-radius: 18px;
  }
  .fpsw-social-icon img,
  .fpsw-fallback-icon{
    width: 56px;
    height: 56px;
    border-radius: 14px;
  }
  .fpsw-fallback-icon svg{
    width: 30px;
    height: 30px;
  }
  .fpsw-social-card h3{
    font-size: 18px;
  }
  /* keep background inside viewport */
  .fpsw-social-bg .fpsw-bg-left{
    left: -110px;
    width: min(220px, 52vw);
  }
  .fpsw-social-bg .fpsw-bg-right{
    right: -120px;
    width: min(240px, 56vw);
  }
}

/* safety: prevent any svg in cards from exploding */
.fpsw-social-card svg{max-width:100%; height:auto;}

/* Safety: prevent oversized icons from theme CSS */
.fpsw-social-section svg{max-width:100%;} 
.fpsw-check svg{width:12px;height:12px;}
