/* =====================================================
   COLORFUL FAQ FOR RANK MATH
   Targets Rank Math's native FAQ block only.
===================================================== */

#rank-math-faq.rank-math-block{
  --cs-faq-color:#d60000;
  --cs-faq-hover:#b90000;
  width:100%;
  max-width:900px;
  margin:30px auto;
}

/* FAQ list */
#rank-math-faq .rank-math-list{
  display:flex;
  flex-direction:column;
  gap:12px;
  margin:0;
  padding:0;
}

/* Individual FAQ */
#rank-math-faq .rank-math-list-item{
  display:block;
  margin:0;
  padding:0;
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:10px;
  overflow:hidden;
  box-shadow:0 2px 9px rgba(0,0,0,.06);
}

/* Question button-like heading */
#rank-math-faq .rank-math-question{
  position:relative;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:15px;

  width:100%;
  margin:0;
  padding:15px 52px 15px 18px;

  background:var(--cs-faq-color);
  color:#fff !important;

  border:0;
  border-radius:0;

  font-size:17px;
  font-weight:700;
  line-height:1.45;
  text-align:left;

  cursor:pointer;
  transition:background .2s ease, filter .2s ease;
}

#rank-math-faq .rank-math-question:hover{
  background:var(--cs-faq-hover);
  color:#fff !important;
}

/* Plus icon */
#rank-math-faq .rank-math-question::after{
  content:"+";
  position:absolute;
  right:15px;
  top:50%;
  transform:translateY(-50%);

  width:29px;
  height:29px;

  display:flex;
  align-items:center;
  justify-content:center;

  border:2px solid rgba(255,255,255,.9);
  border-radius:50%;

  color:#fff;
  font-size:22px;
  font-weight:400;
  line-height:1;
  transition:transform .2s ease;
}

/* Open state */
#rank-math-faq .rank-math-question.cs-faq-open::after{
  transform:translateY(-50%) rotate(45deg);
}

/* Answer */
#rank-math-faq .rank-math-answer{
  display:none;

  margin:0;
  padding:18px 20px;

  background:#fff;
  color:#333;

  border-top:1px solid #eee;

  font-size:16px;
  line-height:1.75;
  text-align:left;
  animation:csFaqOpen .2s ease;
}

#rank-math-faq .rank-math-answer.cs-faq-visible{
  display:block;
}

/* Answer content */
#rank-math-faq .rank-math-answer p{
  margin:0 0 12px;
}

#rank-math-faq .rank-math-answer p:last-child{
  margin-bottom:0;
}

#rank-math-faq .rank-math-answer ul,
#rank-math-faq .rank-math-answer ol{
  margin-bottom:15px;
}

/* Images */
#rank-math-faq .rank-math-answer img{
  max-width:100%;
  height:auto;
  border-radius:8px;
  margin:5px 0 15px;
}

@keyframes csFaqOpen{
  from{opacity:0;transform:translateY(-3px)}
  to{opacity:1;transform:translateY(0)}
}

/* =====================================================
   MOBILE
===================================================== */

@media(max-width:600px){

  #rank-math-faq.rank-math-block{
    margin:25px 0;
  }

  #rank-math-faq .rank-math-list{
    gap:10px;
  }

  #rank-math-faq .rank-math-question{
    padding:13px 48px 13px 14px;
    font-size:16px;
    line-height:1.45;
  }

  #rank-math-faq .rank-math-question::after{
    right:12px;
    width:27px;
    height:27px;
    font-size:20px;
  }

  #rank-math-faq .rank-math-answer{
    padding:15px 16px;
    font-size:15px;
    line-height:1.7;
  }
}

/* =====================================================
   VERY SMALL MOBILE
===================================================== */

@media(max-width:380px){

  #rank-math-faq .rank-math-question{
    font-size:15px;
  }

  #rank-math-faq .rank-math-answer{
    font-size:14px;
  }
}
