
/* =========================================
   YALLA MEDITERRANEO — HOMEPAGE
========================================= */

/* =========================================
   01 / ORIGINAL HERO
========================================= */

.hero {
  position: relative;
  overflow: hidden;
  background: var(--navy);
  color: var(--off-white);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  align-items: center;
  gap: 38px;
  min-height: 655px;
  padding-block: 72px 45px;
}

.hero-copy {
  position: relative;
  z-index: 2;
}

.hero h1 {
  max-width: 720px;
  margin-bottom: 24px;
  font-size: clamp(3.35rem, 6.35vw, 6.6rem);
  font-weight: 850;
  letter-spacing: -.067em;
}

.hero-highlight {
  color: var(--saffron);
}

.hero-description {
  max-width: 550px;
  margin-bottom: 32px;
  color: var(--sand);
  font-size: 1.12rem;
  line-height: 1.75;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-location {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 48px;
  margin-bottom: 0;
  color: var(--mist);
  font-size: .69rem;
  font-weight: 750;
  letter-spacing: .1em;
}

.small-circle {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
}

.hero-art {
  position: relative;
  width: 100%;
  min-height: 525px;
  overflow: hidden;
  border: 1px solid rgba(247,248,250,.14);
  border-radius: 44% 44% 16px 16px;
  background: var(--blue);
  isolation: isolate;
}

.art-ring {
  position: absolute;
  border: 2px solid rgba(247,248,250,.38);
  border-radius: 50%;
}

.art-ring-one {
  width: 125%;
  aspect-ratio: 1;
  left: -12%;
  top: 10%;
}

.art-ring-two {
  width: 95%;
  aspect-ratio: 1;
  left: 3%;
  top: 23%;
  border-color: rgba(229,166,60,.65);
}

.art-disc {
  position: absolute;
  width: 60%;
  aspect-ratio: 1;
  border-radius: 50%;
  top: -15%;
  right: -20%;
  background: var(--teal);
  opacity: .76;
}

.art-center {
  position: absolute;
  top: 42%;
  left: 50%;
  transform: translate(-50%,-50%) rotate(-10deg);
  color: var(--saffron);
  font-size: clamp(4.8rem, 9vw, 9rem);
  font-weight: 900;
  letter-spacing: -.12em;
  line-height: 1;
  white-space: nowrap;
}

.art-note {
  position: absolute;
  z-index: 2;
  padding: 9px 17px;
  border: 1px solid rgba(247,248,250,.6);
  border-radius: 100px;
  color: var(--off-white);
  background: var(--navy);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .1em;
}

.art-note-one {
  top: 20%;
  left: 5%;
  transform: rotate(-13deg);
}

.art-note-two {
  top: 63%;
  right: 4%;
  transform: rotate(11deg);
  background: var(--coral);
}

.art-note-three {
  bottom: 18%;
  left: 10%;
  transform: rotate(-8deg);
}

.art-bottom {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  padding: 20px;
  background: var(--navy);
  font-size: .7rem;
  font-weight: 800;
  text-align: center;
  letter-spacing: .15em;
}

.art-bottom span {
  padding-inline: 8px;
  color: var(--saffron);
}

.hero-bottom {
  display: flex;
  justify-content: space-between;
  padding-bottom: 24px;
}

.scroll-cue {
  display: inline-flex;
  gap: 14px;
  align-items: center;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .13em;
}

.scroll-cue span:last-child {
  font-size: 1.3rem;
}

.hero-index {
  color: var(--mist);
  font-size: .72rem;
  letter-spacing: .12em;
}

/* =========================================
   02 / ORIGINAL WHO WE ARE
========================================= */

.intro-section {
  background: var(--off-white);
}

.intro-grid {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 100px;
}

.section-lead h2 {
  max-width: 670px;
  margin: 0;
}

.intro-text {
  padding-top: 47px;
}

.intro-text p {
  font-size: 1.09rem;
  line-height: 1.85;
}

.intro-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 35px;
}

.intro-tags span {
  padding: 8px 15px;
  border: 1px solid var(--mist);
  border-radius: 100px;
  color: var(--blue);
  font-size: .79rem;
  font-weight: 750;
}

/* =========================================
   03 / OUR TEAM
========================================= */

.team-section {
  overflow: hidden;
  background: var(--sand);
}

.team-slider {
  width: 100%;
  overflow: hidden;
  padding-block: 22px 28px;
  direction: ltr;
}

.team-track {
  display: flex;
  width: max-content;
  animation: home-team-scroll 42s linear infinite;
}

.team-set {
  display: flex;
  flex: 0 0 auto;
  gap: 20px;
  padding-inline-end: 20px;
}

.team-slider:hover .team-track,
.team-slider:focus-within .team-track,
.team-slider:active .team-track {
  animation-play-state: paused;
}

/* TEAM MEMBER CARD */

.team-card {
  position: relative;
  display: block;
  flex: 0 0 300px;
  width: 300px;
  height: 420px;
  overflow: hidden;
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  background: var(--blue);
  color: var(--off-white);
  text-align: start;
  cursor: pointer;
  transform: scale(1);
  transition:
    transform .35s var(--ease),
    box-shadow .35s var(--ease);
  isolation: isolate;
}

.team-card:nth-child(3n + 2) {
  background: var(--teal);
}

.team-card:nth-child(3n + 3) {
  background: var(--coral);
}

.team-card:hover,
.team-card:focus-visible,
.team-card.is-open {
  z-index: 3;
  transform: scale(1.055);
  box-shadow: 0 20px 35px rgba(21,43,85,.26);
}

.team-card-image,
.team-card-placeholder {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.team-card-image {
  object-fit: cover;
  object-position: center top;
  transition: transform .4s var(--ease);
}

.team-card-placeholder {
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 80% 10%, rgba(229,166,60,.35), transparent 40%),
    transparent;
}

.team-card-initials {
  font-size: 6.5rem;
  font-weight: 900;
  letter-spacing: -.09em;
  opacity: .8;
}

/* GRADIENT FOR READABLE NAME */

.team-card::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 35% 0 0;
  background: linear-gradient(
    transparent,
    rgba(21,43,85,.45) 35%,
    rgba(21,43,85,.93)
  );
  pointer-events: none;
}

.team-card-content {
  position: absolute;
  z-index: 2;
  inset-inline: 0;
  bottom: 0;
  padding: 27px;
}

.team-card-name {
  display: block;
  margin-bottom: 0;
  font-size: 2rem;
  font-weight: 850;
  line-height: 1.15;
}

.team-card-bio {
  display: block;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity .35s,
    max-height .4s var(--ease),
    transform .35s;
}

.team-card:hover .team-card-bio,
.team-card:focus-visible .team-card-bio,
.team-card.is-open .team-card-bio {
  max-height: 230px;
  padding-top: 17px;
  opacity: 1;
  transform: translateY(0);
}

.team-card-role {
  display: block;
  margin-bottom: 10px;
  color: var(--saffron);
  font-size: .9rem;
  font-weight: 850;
}

.team-card-experience {
  display: block;
  font-size: .88rem;
  line-height: 1.65;
}

.team-section-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 22px;
}

.team-section-bottom p {
  margin: 0;
  color: var(--blue);
  font-size: .9rem;
}

/* =========================================
   04 / OPPORTUNITIES
========================================= */

.opportunities-section {
  background: var(--blue);
  color: var(--off-white);
}

.opportunities-section .section-heading h2 {
  max-width: 700px;
}

.opportunities-section .section-intro {
  color: var(--mist);
}

.home-opportunities-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.home-opp-card {
  display: flex;
  flex-direction: column;
  min-height: 420px;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--off-white);
  color: var(--ink);
  transition: transform .3s var(--ease);
}

.home-opp-card:hover {
  transform: translateY(-7px);
}

.home-opp-art {
  position: relative;
  display: grid;
  place-items: center;
  height: 165px;
  overflow: hidden;
  background: var(--mist);
  color: var(--navy);
}

.home-opp-card:nth-child(2) .home-opp-art {
  background: var(--saffron);
}

.home-opp-card:nth-child(3) .home-opp-art {
  background: var(--coral);
  color: var(--off-white);
}

.home-opp-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.home-opp-art-number {
  font-size: 5.5rem;
  font-weight: 900;
  letter-spacing: -.07em;
  line-height: 1;
}

.home-opp-content {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 26px;
}

.home-opp-status {
  align-self: flex-start;
  margin-bottom: 18px;
  padding: 6px 11px;
  border-radius: 100px;
  background: var(--sand);
  color: var(--navy);
  font-size: .68rem;
  font-weight: 850;
}

.home-opp-card.is-published .home-opp-status {
  background: var(--mist);
}

.home-opp-content h3 {
  margin-bottom: 15px;
  color: var(--navy);
  font-size: 1.8rem;
}

.home-opp-meta {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--blue);
  font-size: .8rem;
  font-weight: 750;
}

.home-opp-content > p {
  margin-bottom: 22px;
  font-size: .94rem;
  line-height: 1.75;
}

.home-opp-link {
  margin-top: auto;
}

.home-opp-unavailable {
  align-self: flex-start;
  margin-top: auto;
  padding: 10px 15px;
  border: 1px solid var(--sand);
  border-radius: 100px;
  color: var(--blue);
  font-size: .78rem;
  font-weight: 750;
}

.home-opportunities-note {
  margin: 25px 0 0;
  color: var(--mist);
  font-size: .85rem;
}

.opportunities-bottom {
  display: flex;
  justify-content: center;
  margin-top: 42px;
}

/* =========================================
   05 / STORIES PORTRAIT SLIDER
========================================= */

.stories-section {
  overflow: hidden;
  background: var(--sand);
}

.home-stories-slider {
  width: 100%;
  overflow: hidden;
  padding-block: 16px 22px;
  direction: ltr;
}

.home-stories-track {
  display: flex;
  width: max-content;
  animation: home-story-scroll 50s linear infinite;
}

.home-stories-set {
  display: flex;
  flex: 0 0 auto;
  gap: 18px;
  padding-inline-end: 18px;
}

.home-stories-slider:hover .home-stories-track,
.home-stories-slider:focus-within .home-stories-track,
.home-stories-slider:active .home-stories-track {
  animation-play-state: paused;
}

/* STORY CARD — EXACT 9:16 */

.home-story-card {
  position: relative;
  display: block;
  flex: 0 0 280px;
  width: 280px;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--blue);
  color: var(--off-white);
  isolation: isolate;
}

.home-story-card:nth-child(3n + 2) {
  background: var(--teal);
}

.home-story-card:nth-child(3n + 3) {
  background: var(--coral);
}

.home-story-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s var(--ease);
}

.home-story-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 20% 30%, rgba(229,166,60,.45), transparent 38%),
    linear-gradient(145deg, transparent 25%, rgba(21,43,85,.3));
}

.home-story-placeholder span {
  font-size: 5.5rem;
  font-weight: 900;
  opacity: .45;
}

.home-story-overlay {
  position: absolute;
  z-index: 2;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 30px;
  background: rgba(36,69,130,.86);
  opacity: 0;
  transform: translateY(12px);
  transition:
    opacity .35s,
    transform .35s;
}

.home-story-card:nth-child(3n + 2) .home-story-overlay {
  background: rgba(43,154,154,.88);
}

.home-story-card:nth-child(3n + 3) .home-story-overlay {
  background: rgba(201,104,79,.88);
}

.home-story-card:hover .home-story-overlay,
.home-story-card:focus-visible .home-story-overlay,
.home-story-card:focus-within .home-story-overlay,
.home-story-card.is-open .home-story-overlay {
  opacity: 1;
  transform: translateY(0);
}

.home-story-card:hover img,
.home-story-card:focus-visible img,
.home-story-card.is-open img {
  transform: scale(1.07);
}

.home-story-overlay small {
  margin-bottom: 14px;
  color: var(--saffron);
  font-size: .76rem;
  font-weight: 850;
  letter-spacing: .08em;
}

.home-story-overlay strong {
  margin-bottom: 13px;
  font-size: 2rem;
  line-height: 1.15;
}

.home-story-overlay p {
  margin: 0;
  font-size: .95rem;
  line-height: 1.7;
}

.home-story-overlay .story-read-more {
  margin-top: 22px;
  font-size: .82rem;
  font-weight: 850;
}

.stories-section-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 25px;
}

.stories-section-bottom p {
  margin: 0;
  color: var(--blue);
  font-size: .9rem;
}

/* =========================================
   SEAMLESS CAROUSEL ANIMATIONS

   Four identical sets. Move exactly
   one set, i.e. 25% of total width.
========================================= */

@keyframes home-team-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-25%); }
}

@keyframes home-story-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-25%); }
}

/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 1150px) {
  .hero-grid { gap: 20px; }
  .intro-grid { gap: 60px; }
}

@media (max-width: 950px) {
  .hero-grid {
    grid-template-columns: 1fr;
    padding-block: 74px 40px;
  }

  .hero h1 { max-width: 800px; }

  .hero-art {
    width: min(100%, 650px);
    min-height: 400px;
    margin-inline: auto;
  }

  .intro-grid {
    grid-template-columns: 1fr;
    gap: 35px;
  }

  .intro-text { padding-top: 0; }

  .home-opportunities-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-opp-card:last-child {
    grid-column: span 2;
  }
}

@media (max-width: 650px) {
  .hero-grid {
    padding-block: 58px 20px;
  }

  .hero h1 {
    font-size: clamp(3rem, 12vw, 4.4rem);
  }

  .hero-description { font-size: 1rem; }

  .hero-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-buttons .btn { width: 100%; }

  .hero-location {
    margin-top: 33px;
    font-size: .6rem;
  }

  .hero-art {
    min-height: 330px;
    border-radius: 45% 45% 14px 14px;
  }

  .art-center {
    font-size: clamp(4.8rem, 18vw, 7rem);
  }

  .art-note {
    padding: 7px 11px;
    font-size: .57rem;
  }

  .art-bottom { font-size: .56rem; }

  .team-card {
    flex-basis: 245px;
    width: 245px;
    height: 355px;
  }

  .team-card-content { padding: 22px; }
  .team-card-name { font-size: 1.7rem; }
  .team-card-initials { font-size: 5.4rem; }

  .home-opportunities-grid {
    grid-template-columns: 1fr;
  }

  .home-opp-card:last-child {
    grid-column: auto;
  }

  .home-opp-card { min-height: 390px; }

  .home-story-card {
    flex-basis: 210px;
    width: 210px;
  }

  .home-story-overlay { padding: 19px; }
  .home-story-overlay strong { font-size: 1.5rem; }
  .home-story-overlay p { font-size: .82rem; }

  .team-section-bottom,
  .stories-section-bottom {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* =========================================
   RTL
========================================= */

html[dir="rtl"] .hero-location,
html[dir="rtl"] .art-note,
html[dir="rtl"] .art-bottom {
  letter-spacing: 0;
}

html[dir="rtl"] .art-center,
html[dir="rtl"] .art-bottom,
html[dir="rtl"] .hero-index {
  direction: ltr;
}

html[dir="rtl"] .art-center {
  letter-spacing: -.12em;
}

html[dir="rtl"] .team-card-content,
html[dir="rtl"] .home-story-overlay {
  direction: rtl;
  text-align: right;
}

html[dir="rtl"] .home-story-overlay {
  align-items: flex-start;
}

/* ACCESSIBLE ANIMATION */

@media (prefers-reduced-motion: reduce) {
  .team-track,
  .home-stories-track {
    animation: none;
  }

  .team-slider,
  .home-stories-slider {
    overflow-x: auto;
  }
}



/* ==========================================
   HOME — LIVE OPPORTUNITIES & STORIES
========================================== */

#home-opportunities-note[hidden] {
  display: none !important;
}

#home-opportunities-grid .ym-home-empty {
  grid-column: 1 / -1;
  margin: 0;
  padding: 28px 0;
  color: #f7f8fa;
  opacity: 0.85;
}

/* OPPORTUNITY CARDS */

.ym-home-op-card {
  min-width: 0;
  overflow: hidden;
  border-radius: 18px;
  background: #f7f8fa;
  color: #152b55;
  box-shadow: 0 12px 28px rgba(0,0,0,0.09);
}

.ym-home-op-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

.ym-home-op-visual {
  height: 180px;
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: #244582;
}

.ym-home-op-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.ym-home-op-link:hover .ym-home-op-visual img {
  transform: scale(1.05);
}

.ym-home-op-symbol {
  font-size: 4rem;
  color: #e5a63c;
}

.ym-home-op-program {
  position: absolute;
  left: 14px;
  bottom: 14px;
  padding: 6px 12px;
  border-radius: 100px;
  background: rgba(255,255,255,0.93);
  font-size: 0.75rem;
  font-weight: 700;
}

.ym-home-op-content {
  padding: 22px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  flex: 1;
}

.ym-home-op-status {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #2b9a9a;
}

.ym-home-op-content h3 {
  font-size: 1.25rem;
  line-height: 1.35;
  margin: 0;
}

.ym-home-op-content p {
  line-height: 1.65;
  margin: 0 0 8px;
  color: #4a5361;
}

.ym-home-op-location,
.ym-home-op-date {
  font-size: 0.85rem;
  color: #4a5361;
}

.ym-home-op-action {
  margin-top: auto;
  padding-top: 10px;
  font-weight: 800;
}

/* STORIES — INFINITE AUTO SLIDER */

#home-stories-track.ym-home-live-stories {
  display: flex;
  gap: 0;
  width: max-content;
  animation: none;
}

#home-stories-track.ym-home-stories-running {
  animation: ym-home-story-loop 48s linear infinite;
}

#home-stories-slider:hover
#home-stories-track.ym-home-stories-running,
#home-stories-slider:focus-within
#home-stories-track.ym-home-stories-running {
  animation-play-state: paused;
}

#home-stories-track .ym-home-story-set {
  display: flex;
  gap: 18px;
  flex: none;
  padding-inline-end: 18px;
}

.ym-home-story-card {
  position: relative;
  display: block;
  flex: none;
  width: clamp(185px, 23vw, 270px);
  aspect-ratio: 9 / 16;
  border-radius: 16px;
  overflow: hidden;
  background: #244582;
  color: #fff;
  text-decoration: none;
}

.ym-home-story-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.ym-home-story-card:hover img {
  transform: scale(1.06);
}

.ym-home-story-art {
  display: grid;
  place-items: center;
  height: 100%;
  font-size: 5rem;
  color: #e5a63c;
}

.ym-home-story-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
  padding: 22px;
  color: #fff;
  background: linear-gradient(
    180deg,
    transparent 22%,
    rgba(9,22,46,0.88) 100%
  );
}

.ym-home-story-overlay small {
  font-size: 0.65rem;
  letter-spacing: 0.06em;
}

.ym-home-story-overlay strong {
  font-size: 1.2rem;
  line-height: 1.3;
}

.ym-home-story-overlay > span {
  font-size: 0.83rem;
}

.ym-home-story-overlay em {
  font-size: 0.85rem;
  font-style: normal;
  font-weight: 700;
}

#home-stories-track .ym-home-empty {
  white-space: normal;
  max-width: 450px;
  margin: 16px auto;
  padding: 28px;
  text-align: center;
}

.ym-home-story-card:focus-visible,
.ym-home-op-link:focus-visible {
  outline: 3px solid #e5a63c;
  outline-offset: -3px;
}

@keyframes ym-home-story-loop {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  #home-stories-track.ym-home-stories-running {
    animation: none !important;
  }

  .ym-home-op-visual img,
  .ym-home-story-card img {
    transition: none;
  }
}

/* ==========================================
   STORIES SECTION — ALIGNMENT FIX
========================================== */

/* Align the slider with the page container */

#home-stories-slider {
  box-sizing: border-box;
  width: 100%;
  padding-inline: max(
    24px,
    calc((100% - 1100px) / 2)
  );
  overflow: hidden;
}

/* Keep the cards inside the slider */

#home-stories-track.ym-home-live-stories {
  display: flex;
  width: max-content;
  max-width: none;
  gap: 0;
}

/* Card spacing */

#home-stories-track .ym-home-story-set {
  display: flex;
  gap: 20px;
  flex-shrink: 0;
  padding-inline-end: 20px;
}

/* Card appearance */

#home-stories-track .ym-home-story-card {
  width: clamp(220px, 23vw, 270px);
  border-radius: 18px;
  flex-shrink: 0;
}

/* Mobile adjustments */

@media (max-width: 768px) {

  #home-stories-slider {
    padding-inline: 20px;
  }

  #home-stories-track .ym-home-story-set {
    gap: 14px;
    padding-inline-end: 14px;
  }

  #home-stories-track .ym-home-story-card {
    width: 220px;
  }

}



/* ==========================================
   TEAM SLIDER — DYNAMIC DATA
========================================== */

/* Stop the looping animation when the
   team contains fewer than two members. */

#team-track.ym-team-static {
  animation: none !important;
  transform: none !important;
}

/* Loading and empty states */

#team-track .ym-team-message {
  width: 100%;
  max-width: 600px;
  margin: 30px auto;
  padding: 30px 24px;
  text-align: center;
  line-height: 1.7;
  color: #244582;
}

/* Preserve multi-line biography text */

#team-track .team-card-experience {
  white-space: pre-line;
}



/* ==========================================
   TEAM SLIDER — FINAL INTERACTION FIX
========================================== */

/* JavaScript owns the pause/resume state.
   Override old :hover and :focus-within
   animation rules. */

#team-slider #team-track.team-track {
  animation-play-state: running !important;
}

/* Pause only when JavaScript requests it */

#team-slider.ym-team-paused #team-track.team-track {
  animation-play-state: paused !important;
}

/* Keep clicked card details visible */

#team-slider .team-card.is-open .team-card-bio {
  opacity: 1 !important;
  visibility: visible !important;
  transform: translateY(0) !important;
}

/* After closing by click, hide hover details
   until the pointer leaves the slider */

#team-slider:not(.ym-team-paused)
.team-card:not(.is-open) .team-card-bio {
  opacity: 0 !important;
  visibility: hidden !important;
  transform: translateY(12px) !important;
}

/* One member / static slider */

#team-slider #team-track.ym-team-static {
  animation: none !important;
}
