/* ==========================================================================
   "With Sellva, everybody wins" — one card per team.

   A row of closed cards with one open: the closed ones show only who they
   are for, the open one says what changes for that team. Opening a card
   grows it into the row's spare width (flex-grow animates; flex-basis to
   auto would not), and its silk fades in underneath.

   Since 23 Oct 2026 the cards open the Solution page (/<lang>/solutions/),
   on a linen ground, followed by the white "What changes with Sellva"
   section and a demo call. The homepage keeps a short band instead (bottom
   of this file).

   Below 1080px the row becomes a stacked accordion: there is no room for
   four closed cards beside an open one.
   ========================================================================== */

.rl-section {
  position: relative;
  background: #F6F7F2;
  padding: 104px 2rem 112px;
}
.rl-inner { max-width: 1180px; margin: 0 auto; }

/* ------------------------------------------------------------- header ----- */

.rl-header { max-width: 780px; margin-bottom: 56px; }

.rl-eyebrow {
  font: 700 11px/1 Inter, system-ui, sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #3F7D4E;
  margin-bottom: 14px;
}
.rl-headline {
  font: 800 clamp(28px, 4vw, 44px)/1.12 Poppins, Inter, sans-serif;
  color: #111827;
  letter-spacing: -0.03em;
  margin-bottom: 18px;
  text-wrap: balance;
}
.rl-sub {
  font: 400 17px/1.65 Inter, sans-serif;
  color: #475569;
  max-width: 64ch;
}

/* -------------------------------------------------------------- cards ----- */

.rl-track {
  --rl-c: 116px;        /* a closed card */
  --rl-gap: 12px;
  display: flex;
  gap: var(--rl-gap);
  min-height: 500px;
  container-type: inline-size;
}

/* z-index 2 lifts the cards above the page-motif rails and lines, as the
   list in motifs.css does for every other card; it lives here so that file's
   version, linked from 700 pages, need not change. */
.rl-card {
  position: relative;
  z-index: 2;
  flex: 0 0 var(--rl-c);
  min-width: 0;
  border-radius: 20px;
  background: #FFFFFF;
  border: 1px solid rgba(16, 24, 40, 0.08);
  overflow: hidden;
  transition:
    flex-grow 0.6s cubic-bezier(.2,.65,.3,1),
    border-color 0.25s ease,
    box-shadow 0.35s ease;
}
/* The same forest silk as the Sellva Agent card in the feature grid, with
   the same Fern wash: Guilherme wants silk to read green, never black. */
.rl-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(79,145,96,0.16), rgba(79,145,96,0.16)),
    url('/assets/silk-menu.jpg') center / cover no-repeat,
    #1E4A3A;
  opacity: 0;
  transition: opacity 0.45s ease;
}
.rl-card:not(.is-active):hover { border-color: rgba(63, 125, 78, 0.35); }
.rl-card.is-active {
  flex-grow: 1;
  border-color: transparent;
  box-shadow: 0 1px 2px rgba(18,42,28,0.10), 0 26px 52px -26px rgba(18,42,28,0.55);
}
.rl-card.is-active::before { opacity: 1; }
.rl-card:has(.rl-face:focus-visible) { outline: 2px solid #3F7D4E; outline-offset: 3px; }

/* The closed face: icon over label, the whole card a button. */
.rl-face {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 16px 10px;
  border: 0;
  background: transparent;
  color: #2F5E3B;
  cursor: pointer;
  transition: opacity 0.2s ease;
}
.rl-face:focus { outline: none; }
.rl-card.is-active .rl-face { opacity: 0; pointer-events: none; }

.rl-icon {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #EEF3EA;
  color: #3F7D4E;
}
.rl-face-label {
  font: 600 11px/1.4 Inter, system-ui, sans-serif;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: center;
  max-width: 96px;
}

/* The open panel. Its width is the open card's final width, fixed from the
   start, so the text never reflows while the card grows around it. */
.rl-panel {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
  width: calc(100cqw - 4 * var(--rl-c) - 4 * var(--rl-gap) - 2px);   /* 2px: the card's border */
  padding: 44px 48px 40px;
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0s linear 0.3s;
}
.rl-card.is-active .rl-panel {
  position: relative;
  min-height: 100%;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.45s ease 0.2s, visibility 0s;
}

.rl-who {
  display: flex;
  align-items: center;
  gap: 14px;
  font: 600 11.5px/1.3 Inter, system-ui, sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.84);
}
.rl-who .rl-icon { width: 40px; height: 40px; background: rgba(255,255,255,0.12); color: #FFFFFF; }

.rl-title {
  font: 800 clamp(26px, 2.6vw, 34px)/1.16 Poppins, Inter, sans-serif;
  letter-spacing: -0.025em;
  color: #FFFFFF;
  margin: 30px 0 16px;
  max-width: 22ch;
  text-wrap: balance;
}
.rl-desc {
  font: 400 16.5px/1.65 Inter, sans-serif;
  color: rgba(255, 255, 255, 0.86);
  max-width: 54ch;
  margin-bottom: 30px;    /* the least gap above the points, which sit at the foot */
}
.rl-desc strong { color: #FFFFFF; }

.rl-points {
  list-style: none;
  margin: auto 0 0;
  padding: 26px 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 32px;
}
.rl-points li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font: 500 14.5px/1.45 Inter, sans-serif;
  color: rgba(255, 255, 255, 0.94);
}
.rl-check {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: 0.5px;
  border-radius: 50%;
  background: rgba(191, 227, 197, 0.18);
  color: #BFE3C5;
}

/* ---------------------------------------------------------- accordion ----- */

@media (max-width: 1079px) {
  .rl-section { padding: 80px 1.25rem 88px; }
  .rl-header { margin-bottom: 36px; }
  .rl-track { flex-direction: column; min-height: 0; gap: 10px; }
  .rl-card { flex: none; border-radius: 16px; }

  .rl-face {
    position: relative;
    inset: auto;
    width: 100%;
    flex-direction: row;
    justify-content: flex-start;
    gap: 14px;
    padding: 12px 18px 12px 12px;
    text-align: left;
  }
  .rl-face::after {
    content: '+';
    margin-left: auto;
    font: 400 22px/1 Inter, sans-serif;
    color: #8FA395;
  }
  .rl-face-label { max-width: none; text-align: left; font-size: 12px; }
  /* Out of sight but still the button, so focus stays where it was. */
  .rl-card.is-active .rl-face {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }

  .rl-panel { display: none; position: static; width: auto; padding: 28px 24px 26px; }
  .rl-card.is-active .rl-panel { display: flex; }
  .rl-title { margin-top: 24px; font-size: 25px; }
  .rl-desc { font-size: 16px; margin-bottom: 24px; }
  .rl-points { grid-template-columns: 1fr; margin-top: 0; padding-top: 22px; }
}

/* --------------------------------------------------- the page ----- */

/* The page opens on the cards: less air above them than a homepage section
   needs, since the nav is right there. A card a link points at clears the
   sticky nav when the browser scrolls to it. */
.rl-section--page { padding-top: 56px; padding-bottom: 96px; }
.rl-card { scroll-margin-top: 96px; }

.rl-cta-wrap { padding: 0 2rem 104px; background: #FFFFFF; }
.rl-cta { max-width: 1180px; margin: 0 auto; padding: 40px 44px; }
.rl-cta h2 { font-size: clamp(21px, 2.2vw, 26px); }
.rl-cta-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; }
.rl-cta-demo {
  display: inline-block;
  padding: 13px 22px;
  border-radius: 10px;
  background: #FFFFFF;
  color: #111827;
  font: 600 15px/1 Inter, sans-serif;
  text-decoration: none;
  transition: background 0.15s ease, transform 0.15s ease;
}
.rl-cta-demo:hover { background: #F6F7F2; transform: translateY(-1px); }
.rl-cta-calc { color: #FFFFFF; font: 500 15px/1.4 Inter, sans-serif; text-decoration: none; }
.rl-cta-calc:hover { text-decoration: underline; text-underline-offset: 4px; }
.rl-cta-demo:focus-visible, .rl-cta-calc:focus-visible { outline: 2px solid #FFFFFF; outline-offset: 3px; }

@media (max-width: 1079px) {
  .rl-section--page { padding-top: 40px; padding-bottom: 72px; }
  .rl-cta-wrap { padding: 0 1.25rem 72px; }
  .rl-cta { padding: 28px 24px; }
}

/* ------------------------------------------------ the homepage band ----- */

/* The headline and the five teams, each a link to its card on the page:
   about a third of a screen where the two full sections took 3.4. */
.rl-band { background: #F6F7F2; padding: 88px 2rem; }
.rl-band-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 56px;
  align-items: center;
}
.rl-band-headline {
  font: 800 clamp(26px, 3.2vw, 38px)/1.14 Poppins, Inter, sans-serif;
  color: #111827;
  letter-spacing: -0.03em;
  margin-bottom: 14px;
  text-wrap: balance;
}
.rl-band-sub { font: 400 16.5px/1.65 Inter, sans-serif; color: #475569; margin-bottom: 22px; max-width: 46ch; }
.rl-band-link { font: 600 15px/1.4 Inter, sans-serif; color: #2F5E3B; text-decoration: none; }
.rl-band-link:hover { text-decoration: underline; text-underline-offset: 4px; }

.rl-band-roles { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.rl-band-role {
  position: relative;
  z-index: 2;           /* above the page-motif rails, like the cards */
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 18px 10px 10px;
  border-radius: 14px;
  background: #FFFFFF;
  border: 1px solid rgba(16, 24, 40, 0.08);
  text-decoration: none;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.rl-band-role::after {
  content: '→';
  margin-left: auto;
  color: #8FA395;
  font: 400 17px/1 Inter, sans-serif;
  transition: transform 0.2s ease, color 0.2s ease;
}
.rl-band-role:hover { border-color: rgba(63, 125, 78, 0.35); box-shadow: 0 10px 24px -18px rgba(18,42,28,0.45); }
.rl-band-role:hover::after { transform: translateX(3px); color: #3F7D4E; }
.rl-band-role:focus-visible { outline: 2px solid #3F7D4E; outline-offset: 2px; }
.rl-band-role .rl-icon { width: 40px; height: 40px; border-radius: 11px; }
.rl-band-role-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.rl-band-label { font: 600 15px/1.3 Inter, sans-serif; color: #101828; }
.rl-band-who { font: 400 13px/1.35 Inter, sans-serif; color: #667085; }

@media (max-width: 899px) {
  .rl-band { padding: 64px 1.25rem; }
  .rl-band-inner { grid-template-columns: 1fr; gap: 28px; }
}
/* On a phone the team name is enough; the job titles live on the page. */
@media (max-width: 599px) {
  .rl-band { padding: 56px 1.25rem; }
  .rl-band-who { display: none; }
  .rl-band-role { padding: 8px 16px 8px 8px; }
  .rl-band-role .rl-icon { width: 36px; height: 36px; }
}

@media (prefers-reduced-motion: reduce) {
  .rl-card, .rl-card::before, .rl-face, .rl-panel, .rl-card.is-active .rl-panel,
  .rl-cta-demo, .rl-band-role, .rl-band-role::after { transition: none; }
  .rl-cta-demo:hover { transform: none; }
}
