.tms-wrap {
  position: relative;
  width: 100%;
  overflow: hidden;
  cursor: grab;
  -webkit-user-select: none;
  user-select: none;
}
.tms-wrap.tms-dragging {
  cursor: grabbing;
}
.tms-wrap.tms-has-arrows {
  padding: 0 40px;
}

.tms-track {
  display: flex;
  align-items: stretch;
  gap: 24px;
  width: max-content;
  padding: 4px 0 24px 4px;
  will-change: transform;
}

/* Shared structural rules only — visual styling (background, border,
   radius, padding, shadow) is set independently per card type below
   (.tms-card-quote / .tms-card-photo) via the widget's Quote card /
   Photo card style controls, so the two can look completely different. */
.tms-card {
  flex: 0 0 380px;
  width: 380px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  text-align: left;
  pointer-events: none;
  box-sizing: border-box;
}

/* ---- Quote card ---- */
.tms-quote-icon {
  display: flex;
  color: #0C403E;
  margin-bottom: 14px;
  line-height: 0;
  transition: transform 0.35s ease;
}
.tms-quote-icon svg {
  display: block;
}
.tms-wrap.tms-icon-flip .tms-card-quote:hover .tms-quote-icon {
  transform: scaleX(-1);
}

.tms-heading {
  font-weight: 700;
  font-size: 20px;
  line-height: 1.3;
  color: #151515;
  margin-bottom: 10px;
}

.tms-quote {
  margin-top: 12px;
  text-align: left;
}
.tms-quote p {
  margin: 0;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.65;
  color: #8D8D8D;
}

.tms-divider {
  border-top: 1px solid #DAD2CD;
  margin: 24px 0 18px;
}

.tms-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
/* Right-aligned content: mirror the name/rating row so the name sits on
   the right (next to the text) and the stars sit on the left. */
.tms-wrap.tms-align-right .tms-footer {
  flex-direction: row-reverse;
}
/* Centered content: group the name and stars together in the middle. */
.tms-wrap.tms-align-center .tms-footer {
  justify-content: center;
}
.tms-wrap.tms-align-center .tms-meta {
  text-align: center;
}

.tms-meta {
  min-width: 0;
}

.tms-name {
  font-weight: 700;
  font-size: 16px;
  line-height: 1.3;
  color: #0C403E;
  margin-bottom: 4px;
}

.tms-role {
  font-size: 13px;
  line-height: 1.3;
  color: #8D8D8D;
}

.tms-rating {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 2px;
  font-size: 16px;
  line-height: 1;
  flex-shrink: 0;
}
.tms-star {
  display: inline-block;
}
.tms-star.is-filled {
  color: #F4C042;
}
.tms-star.is-empty {
  color: #e2e2e2;
}

/* ---- Quote card (background, padding, border, radius set by the Quote card style controls) ---- */
.tms-card-quote {
  flex: 0 0 380px;
  width: 380px;
  justify-content: center;
  background-color: #F5EFE9;
  border: 0 solid #ececec;
  border-radius: 20px;
  padding: 32px 24px;
  /* Re-enable hit-testing (the base .tms-card rule turns it off so the
     drag gesture isn't blocked) just enough for :hover — e.g. the quote
     icon flip — to register. Dragging still works: it's bound to the
     wrap element, and this click/hover still bubbles up to it. */
  pointer-events: auto;
}

/* ---- Photo card (background, border, radius set by the Photo card style controls) ---- */
.tms-card-photo {
  flex: 0 0 230px;
  width: 230px;
  padding: 0;
  overflow: hidden;
  background-color: #F5EFE9;
  border: 0 solid #ececec;
  border-radius: 20px;
}

.tms-photo-media {
  position: relative;
  width: 100%;
  height: 100%;
  flex: 1 1 auto;
  min-height: 0;
  pointer-events: auto;
  align-self: stretch;
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center center;
  -webkit-user-drag: none;
}

/* ---- Nav arrows ---- */
.tms-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: none;
  background: transparent;
  color: #1c1c1c;
  cursor: pointer;
  z-index: 5;
  transition: color 0.15s ease, transform 0.15s ease;
}
.tms-arrow svg {
  width: 100%;
  height: 100%;
}
.tms-arrow-prev {
  left: 0;
}
.tms-arrow-next {
  right: 0;
}
.tms-arrow:hover {
  color: #f5a623;
}
.tms-arrow:active {
  transform: translateY(-50%) scale(0.9);
}

@media (max-width: 768px) {
  .tms-wrap.tms-has-arrows {
    padding: 0 30px;
  }
}
