.expert-accordion-widget .expert-card {
  border: 1px solid transparent;
  margin-bottom: 15px; /* Default spacing, can be overridden by Elementor control */
  position: relative;
  transition: all 0.3s ease; /* Ensures smooth transition for hover effects like scale */
}

/* Card Hover Scale - controlled by Elementor */
/* .expert-accordion-widget .expert-card:hover {
  transform: scale(1.05);
} */

.expert-accordion-widget .expert-header {
  display: flex;
  align-items: center;
  gap: 15px; /* Default gap, can be overridden by Elementor control */
  cursor: pointer;
  padding: 15px; /* Default padding, can be overridden by Elementor control */
}

.expert-accordion-widget .expert-image {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0; /* Prevents image from shrinking */
}

.expert-accordion-widget .expert-icon {
  font-size: 48px;
  flex-shrink: 0; /* Prevents icon from shrinking */
}

.expert-accordion-widget .expert-info {
    flex-grow: 1; /* Allows this div to take up available space */
}

.expert-accordion-widget .expert-name {
  font-weight: bold;
}

.expert-accordion-widget .expert-designation {
  color: #777;
}

.expert-accordion-widget .expert-bio {
  padding: 0 15px;
  overflow: hidden;
  /* Updated transition to match JS and Elementor control */
  transition: max-height 0.5s ease-in-out, padding 0.5s ease-in-out;
  max-height: 0;
}

.expert-accordion-widget .expert-card.open .expert-bio {
  padding: 0 15px 15px; /* Adds bottom padding when open */
}

.expert-accordion-widget .expert-toggle-icon {
  flex-shrink: 0; /* Prevents icon from shrinking */
  /* margin-left: auto; This will be handled by justify-content or specific margins from controls */
}

.expert-accordion-widget .expert-accordion-icon-inactive {
  display: inline-block;
}

.expert-accordion-widget .expert-accordion-icon-active {
  display: none;
}

.expert-accordion-widget .expert-card.open .expert-accordion-icon-inactive {
  display: none;
}

.expert-accordion-widget .expert-card.open .expert-accordion-icon-active {
  display: inline-block;
}

/* Spacing classes for Name/Designation */
.name-designation-spacing-none .expert-designation {
    margin-bottom: 0px !important;
}

.name-designation-spacing-small .expert-designation {
    margin-bottom: 5px !important;
}

.name-designation-spacing-normal .expert-designation {
    margin-bottom: 10px !important; /* Adjusted to a common normal spacing */
}

.name-designation-spacing-large .expert-designation {
    margin-bottom: 15px !important;
}

/* Spacing classes for Designation/Summary */
.designation-summary-spacing-none .expert-summary {
    margin-top: 0px !important;
}

.designation-summary-spacing-small .expert-summary {
    margin-top: 5px !important;
}

.designation-summary-spacing-normal .expert-summary {
    margin-top: 10px !important;
}

.designation-summary-spacing-large .expert-summary {
    margin-top: 15px !important;
}

/* Divider Styles */
.expert-accordion-widget .expert-divider-wrapper {
    width: 100%;
    /* margin-top and margin-bottom handled by Elementor control */
    display: none; /* Hidden by default, shown by JS when accordion opens */
    transition: all 0.3s ease; /* For smooth show/hide */
    text-align: center; /* For divider alignment */
}

.expert-accordion-widget .expert-divider {
    border-top-width: 1px;
    border-top-style: solid;
    border-top-color: #eee; /* Default color */
    width: 100%;
    position: relative;
    display: inline-flex; /* Use flex to align icon if present */
    align-items: center;
    justify-content: center;
}

.expert-accordion-widget .expert-divider-icon {
    background-color: white; /* Background to cut the line for icon */
    padding: 0 10px; /* Space around icon */
    position: relative;
    z-index: 1;
    color: inherit; /* Inherit color from divider_icon_color */
    font-size: 20px; /* Default icon size */
}

/* Adjustments for header horizontal align if needed */
/* The default justify-content: space-between covers most cases. */
/* If you need specific override for flex-start/center for info vs toggle, keep previous rules or define more specific ones. */