/* =========================================================
   Eden Garden — Testimonials cu "Citeste mai mult" + modal
   Se pune in: Appearance > Customize > Additional CSS
   Se combina cu snippet-ul PHP din eden-testimonials.php
   ========================================================= */

/* ============ CARD LAYOUT ============ */
/* Swiper stretch: forteaza toate slide-urile la aceeasi inaltime */
.testimonials.testimon-style-info-top .wd-carousel-wrap,
.testimonials.testimon-style-info-top .swiper-wrapper { align-items: stretch !important; }
.testimonials.testimon-style-info-top .swiper-slide { height: auto !important; display: flex; }

/* gap vizual intre carduri — Woodmart foloseste .wd-carousel-wrap (flex), nu .swiper-slide.
   Trebuie compensata si latimea cardurilor (Woodmart le seteaza inline la 100%/cols),
   altfel gap-ul le impinge peste marginea containerului. */
.testimonials .wd-carousel-wrap { --eden-gap: 20px; column-gap: var(--eden-gap) !important; }

/* desktop >= 1025px : 3 carduri per view */
.testimonials .wd-carousel-wrap > .wd-testimon.wd-carousel-item {
  width: calc((100% - 2 * var(--eden-gap)) / 3) !important;
  flex: 0 0 calc((100% - 2 * var(--eden-gap)) / 3) !important;
  max-width: none !important;
}
/* tablet: 2 carduri per view */
@media (max-width: 1024px) and (min-width: 641px) {
  .testimonials .wd-carousel-wrap > .wd-testimon.wd-carousel-item {
    width: calc((100% - var(--eden-gap)) / 2) !important;
    flex: 0 0 calc((100% - var(--eden-gap)) / 2) !important;
  }
}
/* mobil: 1 card per view, fara gap */
@media (max-width: 640px) {
  .testimonials .wd-carousel-wrap { --eden-gap: 0px; }
  .testimonials .wd-carousel-wrap > .wd-testimon.wd-carousel-item {
    width: 100% !important;
    flex: 0 0 100% !important;
  }
}
/* fallback pentru variantele care folosesc totusi .swiper-slide */
.testimonials.testimon-style-info-top .swiper-slide .wd-testimon.wd-carousel-item {
  max-width: calc(100% - 20px);
  margin-inline-end: 20px;
}

.testimonials.testimon-style-info-top .wd-testimon.wd-carousel-item {
  --testimon-lines: 5;
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 28px 24px 24px !important;
  background: #fff
    url("https://www.eden-garden.testebossnet2.ro/wp-content/uploads/2026/07/google-badge.svg")
    no-repeat right 20px top 20px / 22px 22px;
  border: 1px solid #e4e6eb;
  border-radius: 0 !important;
  box-shadow: none !important;
  min-height: 306px;
  height: 100% !important;
  width: 100%;
}

/* header: avatar + nume + data */
.wd-testimon .wd-testimon-info { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 6px; }
.wd-testimon .wd-testimon-thumb { margin: 0 !important; flex: 0 0 auto; align-self: flex-start; margin-top: 2px !important; }
/* bate regula Woodmart .testimon-style-info-top .wd-testimon-thumb img { min-width:80px; max-width:80px } */
.wd-testimon .wd-testimon-thumb img,
.testimon-style-info-top .wd-testimon-thumb img {
  width: 50px !important; height: 50px !important;
  min-width: 50px !important; max-width: 50px !important;
  border-radius: 50%; object-fit: cover;
}
.wd-testimon .wd-testimon-bio { min-width: 0; }
.wd-testimon .wd-testimon-name {
  font-size: 14px; font-weight: 600;
  margin: 0 0 2px !important; line-height: 1.3;
}
.wd-testimon .wd-testimon-pos {
  font-size: 13px; color: #6b7280; margin: 0;
}

/* ============ STAR RATING + VERIFIED BADGE ============ */
.wd-testimon .star-rating {
  margin: 6px 0 10px !important; padding: 0;
  display: inline-block; position: relative;
}
.wd-testimon .star-rating::before { color: transparent !important; }
.wd-testimon .star-rating span::before { color: #F7BC16; font-size: 16px; }
.wd-testimon .star-rating::after {
  content: ''; display: inline-block;
  width: 16px; height: 16px; margin-left: 6px;
  background: url("https://www.tractaripremium.ro/wp-content/uploads/2025/01/TractariPremium_Verified.svg") no-repeat center/contain;
  vertical-align: middle;
}

/* ============ TEXT: CLAMP LA 5 RANDURI ============ */
/* neutralizeaza margin-top: 17px pus de tema Woodmart pe .testimon-style-info-top .wd-testimon-text */
.testimonials.testimon-style-info-top .wd-testimon-text,
.testimon-style-info-top .wd-testimon-text { margin-top: 0 !important; }

.wd-testimon .wd-testimon-text {
  padding: 0 !important; margin: 0 !important;
  color: #374151; font-size: 14px; line-height: 1.6;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: var(--testimon-lines);
  line-clamp: var(--testimon-lines);
  overflow: hidden;
  max-height: calc(var(--testimon-lines) * 1.6em);
  flex: 0 1 auto;
}
/* neutralizeaza clasele Tailwind pastrate accidental in continut (Ana Maria) */
.wd-testimon .wd-testimon-text > article,
.wd-testimon .wd-testimon-text > article > p,
.wd-testimon .wd-testimon-text p {
  all: unset; display: block; margin: 0 0 8px; color: inherit; font-size: inherit; line-height: inherit;
}
.wd-testimon .wd-testimon-text p:last-child { margin-bottom: 0; }

/* ============ CITESTE MAI MULT ============ */
.wd-testimon-readmore,
.wd-testimon-readmore:hover,
.wd-testimon-readmore:focus,
.wd-testimon-readmore:active {
  align-self: flex-start;
  margin-top: 14px !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  color: #1f1f1f !important;
  font-weight: 600 !important;
  font-size: 14px !important;
  line-height: 1.4 !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
  text-decoration: none !important;
  min-height: 0 !important;
  min-width: 0 !important;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.wd-testimon-readmore::after {
  content: '→';
  display: inline-block;
  font-weight: 400;
  transition: transform .18s ease;
}
.wd-testimon-readmore:hover::after { transform: translateX(3px); }
.wd-testimon-readmore:focus-visible { outline: 2px solid #1f1f1f; outline-offset: 4px; }

/* ============ MODAL ============ */
#eden-review-modal { display: none; position: fixed; inset: 0; z-index: 100000; }
#eden-review-modal.is-open { display: block; }
#eden-review-modal .eden-modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(15, 23, 42, .68);
  backdrop-filter: blur(2px);
  animation: eden-fade .18s ease-out;
}
#eden-review-modal .eden-modal-dialog {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  background: #fff; border-radius: 16px;
  width: min(640px, calc(100% - 32px));
  max-height: min(80vh, 700px);
  padding: 32px 32px 28px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, .35);
  display: flex; flex-direction: column;
  animation: eden-pop .22s cubic-bezier(.22, 1, .36, 1);
}
#eden-review-modal .eden-modal-close {
  position: absolute; top: 14px; right: 14px;
  width: 36px; height: 36px;
  border: 0; border-radius: 50%;
  background: #f3f4f6; color: #374151;
  font-size: 22px; line-height: 1;
  cursor: pointer;
}
#eden-review-modal .eden-modal-close:hover { background: #e5e7eb; }
#eden-review-modal .eden-modal-head {
  display: flex; align-items: center; gap: 14px; margin-bottom: 18px;
  padding-right: 40px;
}
#eden-review-modal .eden-modal-avatar {
  width: 48px; height: 48px; border-radius: 50%; object-fit: cover;
  flex: 0 0 auto; background: #e5e7eb;
}
#eden-review-modal .eden-modal-name { font-size: 17px; font-weight: 700; color: #111827; margin: 0 0 2px; }
#eden-review-modal .eden-modal-pos { font-size: 13px; color: #6b7280; margin: 0; }
#eden-review-modal .eden-modal-stars {
  display: flex; align-items: center; gap: 6px; margin-bottom: 16px;
  font-size: 15px; color: #F7BC16; letter-spacing: 2px;
}
#eden-review-modal .eden-modal-body {
  overflow-y: auto; padding-right: 6px;
  color: #374151; font-size: 15px; line-height: 1.7;
}
#eden-review-modal .eden-modal-body p { margin: 0 0 12px; }
#eden-review-modal .eden-modal-body article,
#eden-review-modal .eden-modal-body article p {
  all: unset; display: block; margin: 0 0 12px; color: inherit; font-size: inherit; line-height: inherit;
}

@keyframes eden-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes eden-pop { from { opacity: 0; transform: translate(-50%, -46%) scale(.96); } to { opacity: 1; transform: translate(-50%, -50%) scale(1); } }

/* mobil */
@media (max-width: 640px) {
  #eden-review-modal .eden-modal-dialog { padding: 24px 20px; }
  .testimonials.testimon-style-info-top .wd-testimon.wd-carousel-item { padding: 24px 18px !important; }
}

@media (prefers-reduced-motion: reduce) {
  #eden-review-modal .eden-modal-backdrop,
  #eden-review-modal .eden-modal-dialog { animation: none; }
}
