/*
 * What the people who studied say («Відгуки», layout reviews) of the department
 * block page. Loaded only on a page that has the block (enqueue.php), after
 * page-department.css. One review fills the width at a time; the track snaps
 * from one to the next, by the buttons or a swipe.
 */

.dept-reviews__track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.dept-reviews__track::-webkit-scrollbar {
  display: none;
}

.dept-reviews__track:focus-visible {
  outline: 2px solid var(--color-blue-200);
  outline-offset: 4px;
}

.dept-reviews__item {
  margin: 0;
  padding: 0 0 4px;
  scroll-snap-align: start;
}

/* The review in large type, opened by a red mark of quotation of the arms' colour. */
.dept-reviews__text {
  position: relative;
  max-width: 62ch;
  margin: 0;
  padding: 0;
  font-size: clamp(1.25rem, 1rem + 0.9vw, 1.75rem);
  font-weight: 500;
  line-height: 1.45;
  color: var(--color-text-heading);
}

.dept-reviews__text::before {
  content: "«";
  display: block;
  margin-bottom: 4px;
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 0.8;
  color: var(--color-red);
}

.dept-reviews__who {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 28px;
}

.dept-reviews__photo {
  flex: none;
  width: 56px;
  height: 56px;
  object-fit: cover;
}

.dept-reviews__who strong {
  display: block;
  font-size: 1rem;
  color: var(--color-text-heading);
}

.dept-reviews__who span span {
  display: block;
  font-size: 0.875rem;
  color: var(--color-text-secondary);
}

/* Square buttons with the count between them, as the site's other sliders. */
.dept-reviews__nav {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 32px;
}

.dept-reviews__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--color-border-strong);
  background: none;
  color: var(--color-text-heading);
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.dept-reviews__btn:hover,
.dept-reviews__btn:focus-visible {
  border-color: var(--color-blue-200);
  background: var(--color-blue-200);
  color: var(--color-white);
}

.dept-reviews__count {
  min-width: 3.5em;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: center;
  color: var(--color-text-heading);
}

/* Phones: the review a size smaller, the buttons at the page's phone scale. */
@media (max-width: 599px) {
  .dept-reviews__text {
    font-size: 1.125rem;
  }

  .dept-reviews__text::before {
    font-size: 2.75rem;
  }
}
