/* ===== Students infinite strip (minimal, adaptive) ===== */

:root{
  --st-gap: 14px;
  --st-card-w: 170px;
  --st-radius: 14px;
  --st-border: #e7edf5;
  --st-shadow: 0 0 16px rgba(17,24,39,.2);
  --st-text: #111827;
  --st-muted: rgba(17,24,39,.62);
  --st-small: rgba(17,24,39,.52);
}

/* container */
.students-strip{
  width:100%;
  overflow:hidden;
  position:relative;
  border-radius: var(--st-radius);
  padding: 0.6em 0;
}

/* nice fade on edges */
.students-strip::before,
.students-strip::after{
  content:"";
  position:absolute;
  top:0; bottom:0;
  width:48px;
  pointer-events:none;
  z-index:2;
}
.students-strip::before{
  left:0;
  background: linear-gradient(to right, rgba(255,255,255,1), rgba(255,255,255,0));
}
.students-strip::after{
  right:0;
  background: linear-gradient(to left, rgba(255,255,255,1), rgba(255,255,255,0));
}

/* track that moves */
.students-track{
  display:flex;
  width:max-content;
  will-change: transform;
  animation: students-marquee var(--st-duration, 60s) linear infinite;
}

/* two identical rows for seamless loop */
.students-row{
  display:flex;
  gap: var(--st-gap);
  padding: 6px 6px; /* tiny to avoid shadow clipping */
}

/* card */
.student-card{
  width: var(--st-card-w);
  flex: 0 0 var(--st-card-w);
  background:#fff;
  border:1px solid var(--st-border);
  border-radius: 14px;
  box-shadow: var(--st-shadow);
  overflow:hidden;
  text-decoration:none;
  color: var(--st-text);
  transform: translateZ(0);
}

/* square photo */
.student-card__photo{
  width:100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display:block;
  background:#f3f4f6;
}

/* content */
.student-card__body{
  padding: 10px 12px 12px 12px;
  line-height:1.25;
}

/* name: lighter / muted */
.student-card__name{
  font-weight: 800;
  font-size: 0.95em;
  color: var(--st-muted);
  margin: 0 0 6px 0;
}

/* university: main text */
.student-card__uni{
  font-weight: 700;
  font-size: 0.98em;
  color: var(--st-text);
  margin: 0 0 6px 0;
}

/* country: smaller */
.student-card__country{
  font-weight: 700;
  font-size: 0.82em;
  color: var(--st-small);
  margin: 0;
}

/* animation: move half-width because content is duplicated */
@keyframes students-marquee{
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ===== responsive tuning ===== */
@media (max-width: 900px){
  :root{ --st-card-w: 170px; --st-gap: 12px; }
}
@media (max-width: 690px){
  :root{ --st-card-w: 160px; --st-gap: 12px; }
  .students-strip{ --st-duration: 60s; } /* slower on mobile */
}
@media (max-width: 420px){
  :root{ --st-card-w: 150px; --st-gap: 10px; }
  .students-strip{ --st-duration: 70s; } /* even slower */
}

/* accessibility: reduce motion */
@media (prefers-reduced-motion: reduce){
  .students-track{ animation: none; }
  .students-strip::before, .students-strip::after{ display:none; }
}

/* ===== Infinite university logos strip ===== */

.uni-strip{
  position:relative;
  overflow:hidden;
  width:100%;
  height:300px;
  border-radius:14px;
}

/* fade edges */
.uni-strip::before,
.uni-strip::after{
  content:"";
  position:absolute;
  top:0; bottom:0;
  width:60px;
  z-index:2;
  pointer-events:none;
}

.uni-strip::before{
  left:0;
  background: linear-gradient(to right, #f7f7fb, rgb(247 247 251 / 0%));
}
.uni-strip::after{
  right:0;
  background:linear-gradient(to left, #f7f7fb, rgb(247 247 251 / 0%));
}

/* moving track */
.uni-track{
  display:flex;
  align-items:center;
  height:100%;
  width:max-content;
  animation: uniMarquee 55s linear infinite;
  will-change:transform;
}

/* images */
.uni-track img{
  height:300px;
  width:auto;
  flex:0 0 auto;
  display:block;
}

/* animation */
@keyframes uniMarquee{
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* reduced motion */
@media (prefers-reduced-motion: reduce){
  .uni-track{ animation:none !important; }
  .uni-strip::before,
  .uni-strip::after{ display:none; }
}