/* testimonials.css - scoped to #testimonial-section to avoid conflicts */
:root{
    --primary:#0f5a73;
    --muted:#9aa6b2;
    --text:#2b3b4d;
    --bg:#ffffff;
    --max-width:1150px;
  }

  /* Section wrapper (NOT full-screen) */
  #testimonial-section {
    width: 100%;
    background: var(--bg);
    padding: 48px 18px;      /* smaller padding so it won't look full-screen */
    box-sizing: border-box;
    font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #344154;
  }

  /* inner centered container */
  #testimonial-section .testimonials-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    text-align: center;
  }

  /* headings */
  #testimonial-section .small-title {
    display: inline-block;
    letter-spacing: 2px;
    font-size: 12px;
    color: var(--primary);
    margin-bottom: 6px;
    border-top: 3px solid var(--primary);
    border-bottom: 3px solid var(--primary);
    padding: 2px 14px;
  }
  #testimonial-section .main-title {
    font-size: 34px;
    margin: 8px 0 28px;
    color: #0d2540;
    line-height:1.05;
  }

  /* cards row - responsive flex */
  #testimonial-section .cards {
    display: flex;
    gap: 28px;
    justify-content: center; /* center align to avoid edge stretching */
    align-items: flex-start;
    flex-wrap: nowrap;       /* keep them in a single row for desktop */
    margin-bottom: 20px;
    position: relative;
  }
  #testimonial-section .testimonials_card {
    cursor: pointer;
  }

  /* On narrow screens we allow wrap */
  @media (max-width:980px){
    #testimonial-section .cards { flex-wrap: wrap; justify-content: space-between; }
  }

  /* individual testimonial card (renamed to avoid conflicts) */
  #testimonial-section .testimonials_card {
    flex: 0 0 30%;
    min-width: 240px;
    max-width: 360px;
    background: transparent;
    padding-top: 36px;
    box-sizing: border-box;
    position: relative;
    transition: transform .28s cubic-bezier(.2,.9,.2,1), box-shadow .28s ease;
    z-index: 1; /* prevents overlap issues */
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  /* Avatar circle */
  #testimonial-section .testimonials_card .avatar {
    width: 86px;
    height: 86px;
    border-radius: 50%;
    background: #fff;
    margin: 0 auto 10px;
    box-shadow: 0 0 0 6px rgba(0,0,0,0.04), 0 2px 6px rgba(6,24,37,0.06);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
  }
  #testimonial-section .testimonials_card .avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }

  /* Name & role */
  #testimonial-section .testimonials_card .name {
    font-size: 18px;
    margin: 6px 0 2px;
    color: var(--text);
    text-align:center;
  }
  #testimonial-section .testimonials_card .role {
    font-size: 13px;
    margin-bottom: 14px;
    color: var(--muted);
    text-align:center;
  }

  /* Quote box */
  #testimonial-section .testimonials_card .quote {
    width: calc(100% - 8px);
    background: rgba(31, 102, 123, 0.06);
    padding: 18px 16px;
    font-size: 14px;
    line-height: 1.6;
    color: #556b75;
    min-height: 120px;
    box-shadow: inset 0 0 0 1px rgba(31,102,123,0.02);
    border-radius: 2px;
    transition: background .28s ease, color .28s ease, box-shadow .28s ease;
  }

  /* default active card in center */
  #testimonial-section .testimonials_card.active {
    transform: translateY(-12px) scale(1.02);
    z-index: 4; /* keep active card on top */
  }
  #testimonial-section .testimonials_card.active .quote {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 8px 26px rgba(15,90,115,0.18);
    border-radius: 2px;
  }

  /* Non-active hover */
  #testimonial-section .testimonials_card:not(.active):hover {
    transform: translateY(-6px);
    z-index: 2;
  }

  /* indicators (dots) */
  #testimonial-section .indicators {
    display: flex;
    gap: 10px;
    justify-content: center;
    align-items: center;
    margin-top: 8px;
  }
  #testimonial-section .indicators .dot {
    width: 14px;
    height: 14px;
    border-radius: 3px;
    border: 2px solid #dfeaf0;
    background: transparent;
    box-sizing: border-box;
    cursor: pointer;
  }
  #testimonial-section .indicators .dot.active {
    background: var(--primary);
    border-color: var(--primary);
  }

  /* Responsive rules */
  @media (max-width: 980px) {
    #testimonial-section .testimonials_card { flex-basis: 48%; max-width: 48%; }
    #testimonial-section .main-title { font-size: 30px; }
    #testimonial-section .testimonials_card.active { transform: translateY(-8px); }
  }

  @media (max-width: 620px) {
    #testimonial-section { padding: 28px 14px; }
    #testimonial-section .main-title { font-size: 24px; margin-bottom: 20px; }
    #testimonial-section .cards { flex-direction: column; gap: 18px; align-items: center; }
    #testimonial-section .testimonials_card { flex-basis: 100%; max-width: 92%; }
    #testimonial-section .testimonials_card.active { transform: translateY(0); } /* don't float on mobile */
    #testimonial-section .testimonials_card .quote { min-height: auto; }
  }

  /* Reduce motion for preference */
  @media (prefers-reduced-motion: reduce) {
    #testimonial-section .testimonials_card,
    #testimonial-section .testimonials_card.active,
    #testimonial-section .testimonials_card:not(.active):hover {
      transition: none;
      transform: none;
    }
  }
