/******* Do not edit this file *******
Simple Custom CSS and JS - by Silkypress.com
Saved: Oct 02 2026 | 15:04:40 */
/* =====================================================
   ИСТОРИИ КЛИЕНТОВ — Reviews Ribbon plugin (block "Истории клиентов" / [rv_reviews])
   Paste into: Simple Custom CSS and JS › Add Custom CSS (front-end, header).
   The plugin itself loads this file only inside the block editor.
   Colors/fonts follow the landing-page tokens (landing.css).
   ===================================================== */

.rv-reviews {
  --rv-height: 300px;            /* overridden inline by the block "Высота ленты" setting */
  --rv-card-w: clamp(440px, 42vw, 580px);
  --rv-gap: 1.25rem;
  --rv-gutter: clamp(1.25rem, 5vw, 2.5rem);
  --rv-radius: 0.5rem;

  --rv-white: #ffffff;
  --rv-cream: #faf5f0;
  --rv-text: #2a2a2a;
  --rv-muted: #636363;
  --rv-beige: #cfcabe;
  --rv-moore: #354a3c;
  --rv-orange: #d8613c;
  --rv-orange-dark: #c0502a;

  position: relative;
  width: 100%;
  max-width: none !important;
  box-sizing: border-box;
  font-family: Inter, system-ui, sans-serif;
  color: var(--rv-text);
}

.rv-reviews *,
.rv-reviews *::before,
.rv-reviews *::after {
  box-sizing: border-box;
}

/* =====================================================
   RIBBON — one horizontal row, native touch scrolling + snap
   ===================================================== */

.rv-viewport {
  position: relative;
}

.rv-ribbon {
  position: relative;
  display: flex;
  gap: var(--rv-gap);
  height: var(--rv-height);
  margin: 0 !important;
  padding: 0 var(--rv-gutter) !important;
  list-style: none;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--rv-gutter);
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.rv-ribbon::-webkit-scrollbar { display: none; }
.rv-ribbon:focus-visible { outline: 2px solid var(--rv-orange); outline-offset: 2px; }

/* =====================================================
   CARD — named grid areas
   ===================================================== */

.rv-card {
  flex: 0 0 var(--rv-card-w);
  height: 100%;
  margin: 0 !important;
  padding: 0 !important;
  scroll-snap-align: start;
  display: grid;
  grid-template-columns: 38% 1fr;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  grid-template-areas:
    "photo title"
    "photo location"
    "photo lead"
    "photo more";
  column-gap: 1.25rem;
  background: var(--rv-white);
  border-radius: var(--rv-radius);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  overflow: hidden;
}
/* neutralise landing list bullets if the block sits inside .landing-detective */
.rv-card::before { content: none !important; }

.rv-card__photo {
  grid-area: photo;
  min-height: 0;
  background: var(--rv-beige);
}
.rv-card__photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rv-card__title {
  grid-area: title;
  margin: 1.25rem 1.25rem 0 0 !important;
  font-family: Cardo, Georgia, serif;
  font-size: clamp(1.15rem, 1.8vw, 1.4rem) !important;
  line-height: 1.2;
  color: var(--rv-moore);
}

.rv-card__location {
  grid-area: location;
  margin: 0.35rem 1.25rem 0 0 !important;
  font-size: 0.78rem !important;
  font-weight: 700;
  line-height: 1.4 !important;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--rv-orange) !important;
}

.rv-card__lead {
  grid-area: lead;
  min-height: 0;
  margin: 0.75rem 1.25rem 0 0;
  overflow: hidden;
  /* fade the lead out instead of a hard cut when it doesn't fit */
  -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 2.5em), transparent);
          mask-image: linear-gradient(to bottom, #000 calc(100% - 2.5em), transparent);
}
.rv-card__lead p {
  margin: 0 0 0.5em !important;
  font-size: 0.95rem !important;
  line-height: 1.6 !important;
  color: var(--rv-text);
}

.rv-card__more {
  grid-area: more;
  justify-self: start;
  margin: 0.75rem 1.25rem 1.25rem 0;
}

/* =====================================================
   BUTTONS — landing CTA style
   ===================================================== */

.rv-card__more,
.rv-popup__nav button {
  padding: 0.7rem 1.4rem;
  border: 2px solid var(--rv-orange);
  border-radius: var(--rv-radius);
  background: var(--rv-orange);
  color: var(--rv-white);
  font-family: Inter, system-ui, sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}
.rv-card__more:hover,
.rv-popup__nav button:hover {
  background: var(--rv-orange-dark);
  border-color: var(--rv-orange-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(216, 97, 60, 0.4);
}
.rv-card__more:focus-visible,
.rv-popup__nav button:focus-visible,
.rv-arrow:focus-visible,
.rv-dot:focus-visible,
.rv-popup__close:focus-visible {
  outline: 2px solid var(--rv-moore);
  outline-offset: 2px;
}

/* "Previous" = outline variant */
.rv-popup__nav .rv-popup__prev {
  background: transparent;
  color: var(--rv-orange);
}
.rv-popup__nav .rv-popup__prev:hover {
  background: var(--rv-orange);
  color: var(--rv-white);
}

/* =====================================================
   ARROWS (floating) + DOTS
   ===================================================== */

.rv-arrow {
  position: absolute;
  top: 50%;
  z-index: 2;
  width: 3rem;
  height: 3rem;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: var(--rv-white);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  transform: translateY(-50%);
  transition: opacity 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.rv-arrow::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0.7rem;
  height: 0.7rem;
  border-top: 2px solid var(--rv-moore);
  border-right: 2px solid var(--rv-moore);
}
.rv-arrow--prev { left: calc(var(--rv-gutter) / 2); }
.rv-arrow--next { right: calc(var(--rv-gutter) / 2); }
.rv-arrow--prev::before { transform: translate(-35%, -50%) rotate(-135deg); }
.rv-arrow--next::before { transform: translate(-65%, -50%) rotate(45deg); }
.rv-arrow:hover:not(:disabled) {
  transform: translateY(-50%) scale(1.08);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}
.rv-arrow:disabled {
  opacity: 0;
  pointer-events: none;
}

.rv-dots {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.25rem;
  padding: 0 var(--rv-gutter);
}
.rv-dot {
  width: 0.6rem;
  height: 0.6rem;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: var(--rv-beige);
  cursor: pointer;
  transition: width 0.25s ease, background-color 0.25s ease;
}
.rv-dot.is-active {
  width: 1.6rem;
  background: var(--rv-orange);
}

/* Everything fits on screen — nothing to scroll */
.rv-reviews--static .rv-arrow,
.rv-reviews--static .rv-dots {
  display: none;
}

/* =====================================================
   POPUP — native <dialog>
   ===================================================== */

html.rv-popup-open {
  overflow: hidden;
}

.rv-popup {
  width: min(880px, calc(100vw - 4rem));
  max-width: none;
  height: auto;
  max-height: calc(100dvh - 4rem);
  margin: auto;
  padding: 0;
  border: none;
  border-radius: calc(var(--rv-radius) * 2);
  background: var(--rv-white);
  color: var(--rv-text);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.3);
  overflow: hidden;
}
.rv-popup[open] {
  display: flex;
  flex-direction: column;
  animation: rv-pop 0.25s ease;
}
.rv-popup::backdrop {
  background: rgba(17, 17, 17, 0.6);
}
@keyframes rv-pop {
  from { opacity: 0; transform: translateY(16px) scale(0.98); }
  to   { opacity: 1; transform: none; }
}

.rv-popup__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 2;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: var(--rv-white);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
  cursor: pointer;
}
.rv-popup__close::before,
.rv-popup__close::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1.1rem;
  height: 2px;
  background: var(--rv-moore);
}
.rv-popup__close::before { transform: translate(-50%, -50%) rotate(45deg); }
.rv-popup__close::after  { transform: translate(-50%, -50%) rotate(-45deg); }
.rv-popup__close:hover { background: var(--rv-cream); }

.rv-popup__scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: clamp(1.5rem, 4vw, 2.75rem);
}

/* --- Story --- */

.rv-story__head {
  display: grid;
  grid-template-columns: 9rem 1fr;
  grid-template-rows: 1fr auto auto 1fr;
  grid-template-areas:
    "photo ."
    "photo title"
    "photo location"
    "photo .";
  column-gap: 1.5rem;
  margin: 0 3rem 1.75rem 0;
}
.rv-story__photo {
  grid-area: photo;
  width: 9rem;
  height: 9rem;
  border-radius: 50%;
  overflow: hidden;
  background: var(--rv-beige);
}
.rv-story__photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.rv-story__title {
  grid-area: title;
  margin: 0 !important;
  font-family: Cardo, Georgia, serif;
  font-size: clamp(1.6rem, 3.2vw, 2.2rem) !important;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--rv-moore);
}
.rv-story__location {
  grid-area: location;
  margin: 0.5rem 0 0 !important;
  font-size: 0.8rem !important;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--rv-orange) !important;
}

.rv-story__text p {
  margin: 0 0 1em;
  font-size: clamp(1rem, 1.6vw, 1.1rem);
  line-height: 1.72;
  color: var(--rv-text);
}

.rv-story__images {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1rem;
  margin-top: 1.75rem;
}
.rv-story__image {
  margin: 0;
}
.rv-story__image img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--rv-radius);
}

.rv-popup__nav {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 2px solid var(--rv-beige);
}

/* =====================================================
   MOBILE
   ===================================================== */

@media (max-width: 768px) {
  .rv-reviews {
    --rv-card-w: 82vw;
    --rv-gap: 0.85rem;
    --rv-gutter: 1.25rem;
  }

  /* touch: drag the ribbon with a finger, no arrows */
  .rv-arrow { display: none; }

  .rv-card {
    grid-template-columns: 4.5rem 1fr;
    grid-template-rows: auto auto minmax(0, 1fr) auto;
    grid-template-areas:
      "photo title"
      "photo location"
      "lead  lead"
      "more  more";
    column-gap: 1rem;
    padding: 1.25rem !important;
  }
  .rv-card__photo {
    width: 4.5rem;
    height: 4.5rem;
    border-radius: 50%;
    overflow: hidden;
    align-self: start;
  }
  .rv-card__title { margin: 0.4rem 0 0 !important; }
  .rv-card__location { margin: 0.25rem 0 0 !important; }
  .rv-card__lead { margin: 0.85rem 0 0; }
  .rv-card__more {
    justify-self: stretch;
    margin: 0.85rem 0 0;
  }

  /* popup: full screen */
  .rv-popup {
    width: 100vw;
    height: 100dvh;
    max-height: none;
    border-radius: 0;
  }
  .rv-popup__scroll {
    padding: 1.25rem 1.25rem 2rem;
  }

  .rv-story__head {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    grid-template-areas:
      "photo"
      "title"
      "location";
    margin: 0 0 1.5rem;
  }
  .rv-story__photo {
    width: 7rem;
    height: 7rem;
    margin-bottom: 1rem;
  }
  .rv-story__title { padding-right: 3rem; }

  .rv-story__images {
    grid-template-columns: 1fr;
  }

  .rv-popup__nav {
    flex-direction: column-reverse;
  }
  .rv-popup__nav button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rv-ribbon { scroll-behavior: auto; }
  .rv-popup[open] { animation: none; }
  .rv-card__more,
  .rv-popup__nav button,
  .rv-arrow,
  .rv-dot { transition: none; }
}
