.match-member-area {
  .match-member-widget {
    width: 100%;
  }
}

.match-filter-widget {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;

  button {
    display: inline-block;
    height: 40px;
    border-radius: 4px;
    border: 1px solid $black_100;
    font-size: 16px;
    color: $black_500;
    line-height: 40px;
    padding: 0 16px;
    background-color: transparent;
    transition: all 0.3s ease-in-out;

    i {
      margin-right: 6px;
      font-size: 18px;
      transform: translateY(1px);
    }

    &:hover {
      background-color: rgba(255, 255, 255, 0.5);
    }

    &.active {
      background-color: $brand_color;
      border-color: $brand_color;
      color: #fff;
    }
  }
}

.match-member-widget {
  background: #fff;
  border-radius: 24px;
  padding: 20px;
  position: relative;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 1px solid rgba(0, 0, 0, 0.04);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.03);
  overflow: hidden;

  // Hover state
  &:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.08);
    border-color: transparent;

    img {
      transform: scale(1.05);
    }

    .title .follow-btn {
      background-color: $brand_color;
      color: #fff;
      transform: translateY(-3px);
      box-shadow: 0 5px 15px rgba($brand_color, 0.3);
    }
  }

  // Image
  img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 24px;
    transition: transform 0.6s ease;
    display: block; // Remove inline alignment gaps
  }

  // Content Area
  .title {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 18px;

    // Left side (Name + Stats)
    >div {
      flex: 1;
      padding-right: 15px;
    }

    h5 {
      font-size: 20px;
      font-weight: 800;
      color: $black_800;
      margin-bottom: 10px;
      display: flex;
      align-items: center;
      transition: color 0.3s ease;
      letter-spacing: -0.01em;

      &:hover {
        color: $brand_color;
      }

      span {
        // Online Status
        height: 10px;
        width: 10px;
        background-color: #10b981;
        border-radius: 50%;
        display: inline-block;
        margin-left: 8px;
        box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2);
        animation: pulse-green 2s infinite;
      }
    }

    .activity-stat {
      display: flex;
      flex-wrap: wrap;
      gap: 15px;

      div {
        font-size: 13px;
        color: $black_500;
        display: flex;
        align-items: center;
        font-weight: 500;

        span {
          font-weight: 700;
          color: $black_800;
          margin-right: 4px;
        }
      }
    }

    // Follow Button
    .follow-btn {
      padding: 8px 18px;
      font-size: 13px;
      font-weight: 700;
      color: $brand_color;
      background-color: rgba($brand_color, 0.07);
      border-radius: 10px;
      border: 1px solid transparent;
      transition: all 0.3s ease;
      text-decoration: none;
      white-space: nowrap;
      flex-shrink: 0;
      margin-top: 2px;
    }
  }

  // Bio Text
  .bio {
    font-size: 15px;
    line-height: 1.6;
    color: $black_600;
    margin-bottom: 0;
    font-weight: 500;

    a {
      font-weight: 700;
      color: $brand_color;
      margin-left: 3px;
      text-decoration: none;
      position: relative;
      display: inline-block;

      &::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        width: 100%;
        height: 1px;
        background: currentColor;
        transform: scaleX(0);
        transition: transform 0.3s ease;
        transform-origin: right;
      }

      &:hover::after {
        transform: scaleX(1);
        transform-origin: left;
      }
    }
  }
}

// Keyframes for the pulse if not defined elsewhere
@keyframes pulse-green {
  0% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
  }

  70% {
    box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

.match-member-area-two {
  background-color: rgba(#0fe493, 0.03);
  position: relative;
  z-index: 1;
  overflow: hidden;

  .bg-shape {
    position: absolute;
    top: 46%;
    left: -20px;
    z-index: 1;
  }

  .match-member-isotope {
    margin: 0 -12px;
  }

  .match-member-widget-two {
    width: calc((100% - 72px) / 3) !important; // Restore layout with precedence
    margin-right: 12px;
    margin-left: 12px;
    margin-bottom: 24px;
  }
}

.match-member-widget-two {
  padding: 10px;
  background-color: #fff;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(0, 0, 0, 0.04);
  position: relative;
  overflow: hidden;
  // height: 100%;
  display: flex;
  flex-direction: column;

  &:hover {
    box-shadow: 0 25px 50px rgba($brand_color, 0.15);
    transform: translateY(-8px);

    h5 {
      color: $brand_color;
    }
  }

  .img-box {
    position: relative;
    border-radius: 0;
    width: 100%;
    overflow: hidden;
    margin: 0;
    flex-shrink: 0; // Prevent shrinking

    .actv_status {
      font-size: 11px;
      font-weight: 700;
      color: $black_800;
      padding: 6px 14px;
      background-color: rgba(255, 255, 255, 0.9);
      backdrop-filter: blur(8px);
      -webkit-backdrop-filter: blur(8px);
      border-radius: 30px;
      display: inline-flex;
      align-items: center;
      line-height: 1;
      position: absolute;
      top: 15px;
      left: 15px;
      z-index: 2;
      box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
      text-transform: uppercase;
      letter-spacing: 0.5px;

      .dot {
        height: 7px;
        width: 7px;
        background-color: #13a10e;
        border-radius: 50%;
        margin-left: 6px;
        box-shadow: 0 0 0 2px rgba(19, 161, 14, 0.2);
        animation: pulse-green 2s infinite;
      }
    }

    .stat-box {
      z-index: 2;
      display: flex;
      align-items: center;
      font-size: 13px;
      color: #fff;
      font-weight: 500;
      gap: 15px;
      position: absolute;
      width: calc(100% - 30px);
      bottom: 15px;
      left: 15px;
      background: rgba(26, 26, 26, 0.75);
      backdrop-filter: blur(10px);
      -webkit-backdrop-filter: blur(10px);
      padding: 12px 18px;
      border-radius: 14px;
      line-height: 1;
      border: 1px solid rgba(255, 255, 255, 0.1);

      div {
        display: flex;
        align-items: center;

        img {
          width: 16px;
          height: auto;
          margin-right: 6px;
          filter: brightness(0) invert(1);
          border-radius: 0;
          margin-bottom: 0;
        }
      }

      .ms-auto {
        margin-left: auto !important;
        opacity: 0.9;
        font-size: 12px;
      }
    }

    .main-img {
      width: 100%;
      height: 280px; // Slightly reduced for better mobile/grid fit
      object-fit: cover;
      border-radius: 20px;
      transition: all 0.6s ease;
      display: block;
    }
  }

  // Wrapper for content
  .member-content {
    padding: 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
  }

  h5 {
    color: $black_800;
    font-weight: 800;
    font-size: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    line-height: 1.4;
    margin: 0 0 8px 0;
    transition: all 0.3s ease-in-out;

    .badge-icon {
      img {
        width: 18px;
        height: auto;
        display: block;
      }
    }

    &:hover {
      color: $brand_hover;
    }
  }

  p {
    font-size: 14px;
    color: $black_500;
    margin-bottom: 0;
    line-height: 1.6;
    font-weight: 500;

    i {
      color: $brand_color;
      margin-left: 5px;
    }
  }

  .member-actions {
    padding: 0 20px 24px;
    display: flex;
    gap: 10px;
    margin-top: auto;

    .action-btn {
      flex: 1;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      padding: 12px;
      border-radius: 12px;
      font-weight: 700;
      font-size: 14px;
      transition: all 0.3s ease;
      text-decoration: none;
      line-height: 1;
      border: 1px solid transparent;

      i {
        margin-right: 6px;
        font-size: 13px;
      }

      &.primary {
        background: var(--gradient-primary); // Use gradient if available, else brand color
        background-color: $brand_color;
        color: #fff;
        box-shadow: 0 4px 15px rgba($brand_color, 0.3);

        &:hover {
          transform: translateY(-2px);
          box-shadow: 0 8px 20px rgba($brand_color, 0.4);
          color: #fff;
        }
      }

      &.secondary {
        background-color: #fff;
        color: $black_700;
        border-color: $black_100;

        &:hover {
          background-color: $brand_color;
          border-color: $brand_color;
          color: #fff;
          transform: translateY(-2px);
          box-shadow: 0 8px 20px rgba($brand_color, 0.2);
        }
      }
    }
  }
}

.match-member-area-three {
  padding-top: 40px;
  padding-bottom: 130px;
  position: relative;
  z-index: 1;
  overflow: hidden;

  .bg-shape {
    img {
      position: absolute;

      &:nth-child(1) {
        top: 210px;
        left: -80px;
      }

      &:nth-child(2) {
        top: 50%;
        right: 10px;
      }

      &:nth-child(3) {
        top: 25%;
        right: 40px;
      }

      &:nth-child(4) {
        top: 80%;
        left: 10px;
      }
    }
  }

  .search-result-title {
    font-size: 24px;
    font-weight: 600;
    color: $black_800;
    margin-bottom: 16px;
  }

  .noresult-found {
    text-align: center;

    h1 {
      font-size: 40px;
      font-weight: 700;
      color: $black_800;
    }

    p {
      font-size: 18px;
      color: $black_600;
      margin-bottom: 80px;
    }
  }
}

.member-search-bar-widget {
  position: relative;
  margin-bottom: 50px;
  max-width: 750px;
  margin-left: auto;
  margin-right: auto;
  z-index: 10;

  .form-control {
    background-color: #ffffff;
    border-radius: 60px;
    height: 70px;
    font-size: 18px;
    font-weight: 500;
    color: $black_800;
    border: 3px solid rgba($brand_color, 0.05);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.05);
    padding-left: 70px;
    padding-right: 80px;
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);

    &::placeholder {
      font-size: 18px;
      font-weight: 400;
      color: $black_400;
      transition: all 0.3s ease;
    }

    &:focus {
      border-color: rgba($brand_color, 0.3);
      box-shadow: 0 20px 60px rgba($brand_color, 0.15);
      padding-left: 80px;

      &::placeholder {
        opacity: 0.5;
        transform: translateX(10px);
      }

      &+.search-icon {
        transform: translateY(-50%) scale(1.1);
        color: $brand_color;
      }
    }
  }

  .search-icon {
    position: absolute;
    left: 30px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 24px;
    color: $black_300;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 15; // Ensure icon is on top
  }

  .filter-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, $brand_color 0%, $brand_color 100%);
    color: #fff;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    outline: none;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 10px 25px rgba($brand_color, 0.3);
    z-index: 15;

    img {
      width: 22px;
      height: auto;
      filter: brightness(0) invert(1);
      transition: transform 0.4s ease;
    }

    &:hover {
      transform: translateY(-50%) scale(1.15) rotate(90deg);
      box-shadow: 0 15px 35px rgba($brand_color, 0.4);

      img {
        transform: rotate(-90deg); // Keep icon upright while button rotates
      }
    }

    &:active {
      transform: translateY(-50%) scale(0.95);
    }
  }
}

.pagination {
  .page-numbers {
    width: 32px;
    height: 32px;
    display: inline-flex;
    border-radius: 4px;
    border: 1px solid $black_50;
    text-align: center;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    vertical-align: middle;
    color: $black_900;
    transition: all 0.2s linear;
    line-height: 32px;

    &.dots {
      border: none;
      background-color: transparent !important;
      box-shadow: none !important;
      color: $black_900 !important;
    }

    i {
      font-size: 20px;
    }

    &+.page-numbers {
      margin-left: 5px;
    }

    &.current {
      background-color: $brand_color;
      border-color: $brand_color;
      box-shadow: 0 20px 30px 0 rgba(#e40f60, 0.2);
      color: #fff;
    }

    &:hover:not(.current) {
      background-color: rgb(228 15 96 / 20%);
      border-color: rgb(228 15 96 / 20%);
    }

    &.current {
      box-shadow: none;
    }
  }
}

body.modal-open {

  .body_wrapper,
  #preloader {
    filter: blur(8px);
    transition: filter 0.3s ease;
    pointer-events: none; // Disable interaction with background
  }

  // Add a subtle overlay effect for better visual separation
  &::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1040; // Below modal (1055) but above content
    pointer-events: none;
  }
}

.custom-modal {
  .modal-dialog:not(.container) {
    max-width: 580px;
  }

  .modal-content {
    @include glass-panel(rgba(255, 255, 255, 0.9), blur(30px));
    border-radius: 24px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
    padding: 30px 40px 40px;
    border: 1px solid rgba(255, 255, 255, 0.5);
  }

  .title {
    display: flex;
    align-items: center;
    margin-bottom: 24px;

    h4 {
      font-weight: 600;
      margin-bottom: 0;
      color: $black_800;
      margin-right: auto;
    }

    button {
      background-color: transparent;
      border: none;
      font-size: 18px;
      color: #242424;
    }

    .close {
      font-size: 25px
    }
  }

  .custom-select {
    width: 100%;
    margin-bottom: 24px;
    background-color: #ffffff;
    border: 1px solid rgba($black_100, 0.5);
    border-radius: 12px;
    height: 54px;
    line-height: 52px;

    .list {
      box-shadow: 0 15px 45px rgba(0, 0, 0, 0.1);
      border: none;
      border-radius: 12px;
      margin-top: 5px;
    }

    &.open {
      border-color: $brand_color;
    }

    .current {
      font-weight: 500;
      color: $black_800;
    }
  }

  textarea.form-control {
    padding: 20px 24px;
    color: $black_800;
    font-size: 14px;
    line-height: 24px;
    border: 1px solid rgba($black_100, 0.5);
    background-color: #fff;
    box-shadow: none;
    border-radius: 12px;
    margin-bottom: 32px;

    &::placeholder {
      color: $black_400;
    }

    &:focus {
      border-color: $brand_color;
    }
  }
}

.member-search-sidebar-area {
  display: flex;
  gap: 30px;
  align-items: flex-start;

  .left-bar {
    width: 300px;
    flex-shrink: 0;
    position: sticky;
    top: 100px;
    align-self: flex-start;
    z-index: 3;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);

    .title {
      color: $black_800;
      margin-bottom: 24px;
      font-size: 24px;
      font-weight: 800;
      letter-spacing: -0.02em;
      position: relative;
      display: inline-block;
      padding-left: 15px;

      &::before {
        content: '';
        position: absolute;
        left: 0;
        top: 50%;
        transform: translateY(-50%);
        width: 6px;
        height: 24px;
        background: $brand_color;
        border-radius: 4px;
      }
    }

    .widget-wrapper {
      background: #fff;
      border-radius: 20px;
      padding: 24px;
      box-shadow: 0 10px 40px rgba(0, 0, 0, 0.04);
      border: 1px solid rgba(0, 0, 0, 0.03);
    }

    .widget-box {
      margin-bottom: 20px;
      padding-bottom: 10px;
      border-bottom: 1px dashed rgba($black_100, 0.6);

      &:last-child {
        margin-bottom: 0;
        border-bottom: none;
        padding-bottom: 0;
      }

      .widget-title {
        font-size: 15px;
        font-weight: 700;
        color: $black_800;
        display: flex;
        justify-content: space-between;
        align-items: center;
        border: none;
        width: 100%;
        margin-bottom: 16px;
        background-color: transparent;
        padding: 0;
        text-transform: uppercase;
        letter-spacing: 0.03em;
        cursor: pointer;

        span {
          pointer-events: none; // Ensure clicks pass through to the button
          width: 26px;
          height: 26px;
          display: flex;
          align-items: center;
          justify-content: center;
          background: #f5f6f7;
          border-radius: 50%;
          font-size: 10px;
          color: $black_500;
          transition: all 0.3s ease;
        }

        &:hover {
          color: $brand_color;

          span {
            background: rgba($brand_color, 0.1);
            color: $brand_color;
          }
        }

        // Default state (Expanded)
        .plus {
          display: none;
        }

        .minus {
          display: block;
        }

        // Collapsed State
        &.collapsed {
          margin-bottom: 0;
          color: $black_600;

          span {
            transform: rotate(0deg);
            background-color: transparent;
            border: 1px solid $black_100;
          }

          .plus {
            display: block; // Show plus when collapsed
          }

          .minus {
            display: none; // Hide minus when collapsed
          }
        }
      }
    }

    .filter-link-group {
      display: flex;
      flex-direction: column;

      &.collapse:not(.show) {
        display: none;
      }

      .filter-link {
        display: flex;
        align-items: center;
        width: 100%;
        background-color: transparent;
        font-size: 14px;
        color: $black_600;
        padding: 8px 14px;
        border-radius: 10px;
        border: 1px solid transparent;
        transition: all 0.2s ease;
        justify-content: flex-start;
        font-weight: 500;

        span.icon {
          width: 20px;
          height: 20px;
          border: 1.5px solid #e0e0e0;
          border-radius: 6px;
          display: flex;
          align-items: center;
          justify-content: center;
          margin-right: 12px;
          font-size: 10px;
          color: transparent;
          transition: all 0.2s ease;
          flex-shrink: 0;

          i {
            transform: scale(0.5);
            opacity: 0;
            transition: all 0.2s ease;
          }
        }

        &:hover {
          background-color: #f9f9f9;
          color: $brand_color;
          padding-left: 18px;

          span.icon {
            border-color: var(--brand_color);
          }
        }

        &.active {
          background-color: rgba($brand_color, 0.04);
          color: $brand_color;
          font-weight: 600;

          span.icon {
            background-color: $brand_color;
            border-color: $brand_color;
            color: #fff;

            i {
              transform: scale(1);
              opacity: 1;
            }
          }
        }
      }
    }
  }

  .right-bar {
    flex: 1;

    .search-result-info {
      display: flex;
      justify-content: space-between;
      margin-bottom: 30px;
      align-items: center;
      margin-top: 0;
      background: #fff;
      padding: 15px 30px;
      border-radius: 12px;
      box-shadow: 0 5px 20px rgba(0, 0, 0, 0.03);
      border: 1px solid rgba(0, 0, 0, 0.02);

      .result-info {
        font-size: 16px;
        font-weight: 500;
        line-height: 1.5;
        color: $black_500;

        span {
          font-weight: 700;
          color: $brand_color;
          font-size: 18px;
        }
      }

      .sorting {
        display: flex;
        align-items: center;
        gap: 15px;

        span {
          font-size: 15px;
          font-weight: 600;
          color: $black_700;
        }

        .custom-select {
          height: 45px;
          line-height: 45px;
          border-radius: 8px;
          background: #f8f9fa;
          border: 1px solid #ebebeb;
          box-shadow: none;
          margin-left: 0;
          /* managed by gap */
          padding-left: 18px;
          padding-right: 40px;
          min-width: 180px;

          .current {
            color: $black_800;
            font-size: 14px;
            font-weight: 500;
          }

          &::after {
            color: $black_500;
            font-size: 14px;
            right: 18px;
          }

          &:hover {
            background: #fff;
            border-color: $brand_color;
          }
        }
      }
    }

    .match-member-widget-three {
      margin-bottom: 32px;
    }
  }
}

.match-member-widget-three {
  display: flex;
  background: #fff;
  border-radius: 20px;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  width: 100%;
  border: 1px solid rgba(0, 0, 0, 0.04);
  overflow: hidden;
  position: relative;
  margin-bottom: 30px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.02);

  &:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.08);

    .img-box .main-img {
      transform: scale(1.05);
    }

    .contact-box {
      background-color: rgba($brand_color, 0.02);
    }
  }

  .img-box {
    position: relative;
    width: 280px;
    flex-shrink: 0;
    overflow: hidden;
    margin: 10px;
    border-radius: 16px;

    .main-img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      transition: transform 0.6s ease;
      border-radius: 16px;
    }

    .stat-box {
      position: absolute;
      bottom: 12px;
      left: 12px;
      right: 12px;
      display: flex;
      gap: 8px;
      z-index: 2;

      div {
        flex: 1;
        background: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(4px);
        padding: 6px 10px;
        border-radius: 8px;
        color: #fff;
        font-size: 12px;
        font-weight: 600;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 6px;

        img {
          width: 14px;
          height: auto;
          filter: brightness(0) invert(1);
        }
      }
    }
  }

  .info-box {
    padding: 25px 30px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;

    .title {
      color: $black_800;
      font-weight: 800;
      font-size: 24px;
      display: flex;
      align-items: center;
      gap: 10px;
      margin-bottom: 8px;
      transition: color 0.3s ease;

      &:hover {
        color: $brand_color;
      }

      .badge-icon img {
        width: 22px;
      }
    }

    .last-seen {
      display: inline-flex;
      font-size: 13px;
      font-weight: 600;
      color: #10b981;
      margin-bottom: 16px;
      align-items: center;

      &::before {
        content: '';
        display: inline-block;
        width: 6px;
        height: 6px;
        background-color: currentColor;
        border-radius: 50%;
        margin-right: 6px;
      }
    }

    .bio {
      font-size: 15px;
      color: $black_600;
      line-height: 1.6;
      margin-bottom: 24px;
      max-width: 90%;

      .expand-text {
        font-weight: 600;
        color: $brand_color;
        margin-left: 4px;
        text-decoration: none;

        &:hover {
          text-decoration: underline;
        }
      }
    }

    .about-candidate-info-list {
      display: flex;
      flex-wrap: wrap;
      gap: 12px;
      margin-bottom: 0;
      padding: 0;
      list-style: none;

      li {
        display: flex;
        align-items: center;
        padding: 8px 14px;
        border-radius: 50px;
        background: #f7f8fa;
        border: 1px solid transparent;
        transition: all 0.3s ease;

        .icon {
          display: none; // Hide icon for cleaner look, or verify if user wants it.
          // If we want icons:
          /*
          width: 24px;
          height: 24px;
          margin-right: 8px;
          */
        }

        div {
          font-size: 13px;
          color: $black_500;
          font-weight: 500;

          .info {
            color: $black_800;
            font-weight: 700;
            margin-left: 4px;
          }
        }

        &:hover {
          background: #fff;
          border-color: rgba($brand_color, 0.2);
          box-shadow: 0 4px 10px rgba(0, 0, 0, 0.04);
          color: $brand_color;

          div .info {
            color: $brand_color;
          }
        }
      }
    }
  }

  .contact-box {
    width: 220px; // Slightly narrower
    padding: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    border-left: 1px solid rgba(0, 0, 0, 0.04);
    background-color: #fff;
    transition: background-color 0.3s ease;

    h5 {
      font-size: 16px;
      font-weight: 700;
      color: $black_800;
      margin-bottom: 18px;
      line-height: 1.4;
    }

    .theme-btn {
      width: 100%;
      padding: 12px 20px;
      border-radius: 12px;
      font-weight: 700;
      font-size: 14px;
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 8px;
      box-shadow: 0 8px 20px rgba($brand_color, 0.25);
      transition: all 0.3s ease;

      img {
        width: 16px;
        filter: brightness(0) invert(1);
      }

      &:hover {
        transform: translateY(-2px);
        box-shadow: 0 12px 25px rgba($brand_color, 0.35);
      }
    }
  }
}

.match-member-area-five {
  padding-top: calc(80px + 60px);
  padding-bottom: 130px;
}


.matching-percentage {
  cursor: pointer;
  border: none;
  width: 100%;
  margin-top: 65px;
  padding: 24px 30px 24px 35px;
  border-radius: 8px;
  background-color: #befab1;
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 130px;
  box-shadow: var(--subtle_shadow);
  transition: $transition;

  &:hover {
    box-shadow: $long_shadow;
    transform: translateY(-8px);
  }

  .profiles {
    display: flex;
    align-items: center;

    .s-profile {
      border: 2px solid #fff;
      border-radius: 50%;
      width: 32px;
      height: 32px;
      transition: $transition;

      &:hover {
        transform: translateY(-8px);
      }

      img {
        width: 100%;
        height: 100%;
      }

      &:last-child {
        margin-left: -10px;
      }
    }
  }

  h5 {
    color: $black_800;
    font-weight: 600;
    margin-bottom: 12px;
    line-height: 15px;
    text-align: left;
  }

  p {
    clear: $black_700;
    margin-bottom: 0;
    line-height: 14px;
    text-align: left;
  }

  h4 {
    margin-bottom: 0;
    font-size: 20px;
    color: $black_750;
    font-weight: 600;
    margin-left: auto;

    i {
      margin-left: 25px;
      vertical-align: middle;
      font-size: 34px;
      line-height: 25px;
    }
  }

  i::before {
    content: "\32";
  }

  &.collapsed {
    i::before {
      content: "\33";
    }
  }
}

.match-preferences-widget {
  padding: 0 20px;

  .widget-header {
    display: flex;
    align-items: center;

    .profile {
      text-align: center;

      img {
        width: 96px;
        height: 96px;
        border-radius: 50%;
        margin-bottom: 16px;
      }
    }

    .arrow-to-right {
      position: relative;
      flex: 1;

      i {
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        font-size: 30px;
        color: $black_300;
        margin-top: -1px;
      }

      div {
        width: calc(100% - 12px);
        height: 2px;
        background-color: $black_300;
      }
    }

    .match-result {
      border-radius: 8px;
      padding: 24px;
      background-color: #d8f9d1;
      font-size: 22px;
      color: $black_900;
      font-weight: 600;
      line-height: 20px;
      margin: 0 40px;
    }

    .arrow-to-left {
      position: relative;
      flex: 1;

      i {
        position: absolute;
        left: 0;
        top: 50%;
        transform: translateY(-50%);
        font-size: 30px;
        color: $black_300;
        margin-top: -1px;
      }

      div {
        width: calc(100% - 12px);
        margin-left: 12px;
        height: 2px;
        background-color: $black_300;
      }
    }
  }

  .preference-list {
    list-style: none;
    padding: 0;
    margin: 60px 0 95px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: $shadow_1;

    li {
      padding: 40px 43px 40px 50px;
      display: flex;
      align-items: center;

      .label {
        font-size: 24px;
        font-weight: 400;
        color: $black_700;
        display: flex;
        align-items: center;
        gap: 14px;

        span {
          font-weight: 600;
        }
      }

      .result {
        margin-left: auto;

        &.matched {
          i {
            background-color: #d8f9d1;
            color: #0bb62a;
          }

          .icon_close {
            display: none;
          }

          .icon_check {
            display: inline-block;
          }
        }

        i {
          font-size: 14px;
          width: 32px;
          height: 32px;
          border-radius: 50%;
          line-height: 32px;
          text-align: center;
          background-color: #fee7d6;
          color: #ff6345;
        }

        .icon_close {
          display: inline-block;
          font-size: 18px;
        }

        .icon_check {
          display: none;
        }
      }

      &:nth-child(odd) {
        background-color: #fff;
      }

      &:nth-child(even) {
        background-color: rgba(255, 255, 255, 0.5);
      }
    }
  }
}

@media (max-width: 991px) {
  .member-search-sidebar-area {
    flex-direction: column;
    gap: 30px;

    .left-bar {
      width: 100%;
      position: relative;
      top: 0;
    }
  }

  .match-member-widget-three {
    flex-direction: column;

    &::before {
      width: 100%;
      height: 6px;
    }

    .img-box {
      width: 100%;
      height: 350px;
    }

    .info-box {
      padding: 30px 25px;

      .about-candidate-info-list {
        grid-template-columns: 1fr;
      }
    }

    .contact-box {
      width: 100%;
      padding: 30px;
      border-left: none;
      border-top: 1px solid rgba($black_100, 0.5);
      background: rgba($black_25, 0.5);
    }
  }
}