/* ============================================================
   EDUCATION PAGE — page-specific styles only.
   Safe to append to the main stylesheet as well; every rule
   is scoped to classes that exist only on this page.
   Spec: ALL text on this page = Alegreya Sans.
   ============================================================ */

/* ---------- page title (bold, per site spec) ---------- */
.edu__title {
  font-family: "Alegreya Sans", "Helvetica Neue", Arial, sans-serif;
  font-weight: 700;
  text-align: center;
  font-size: clamp(1.75rem, 4vw, 2.3rem);
  margin: 3.5rem 0 2.75rem;
}

/* ---------- certificate collage ---------- */
.certs {
  max-width: var(--max-wide);
  margin: 0 auto;
  padding: 0 var(--space);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 1.75rem 2.25rem;
}

.certs__item img {
  width: 150px;
  height: auto;
  border-radius: 2px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.14);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.certs__item--sm img { width: 105px; }
.certs__item--lg img { width: 210px; }

.certs__item:hover img {
  transform: translateY(-4px);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.2);
}

.certs__cap {
  font-family: "Alegreya Sans", "Helvetica Neue", Arial, sans-serif;
  font-weight: 400;
  margin-top: 0.55rem;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-muted);
  text-align: center;
}

/* ---------- experience list ---------- */
.exp {
  max-width: var(--max-width);
  margin: 3.5rem auto 0;
  padding: 0 var(--space);
}

.exp__list {
  list-style: disc;
  padding-left: 1.1rem;
  font-family: "Alegreya Sans", "Helvetica Neue", Arial, sans-serif;
  font-weight: 400;
  font-size: 1.5rem;
  line-height: 1.65;
}

.exp__list li { margin-bottom: 0.8rem; }

.exp__list a {
  font-family: inherit;
  color: var(--color-taupe);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- sliding photo showcase ---------- */
.showcase {
  position: relative;
  margin-top: 6rem;
  width: 100%;
  overflow: hidden;
}

.showcase__viewport {
  overflow: hidden;
}

.showcase__track {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  list-style: none;
  transition: transform 0.6s cubic-bezier(0.22, 0.61, 0.36, 1);
  will-change: transform;
}

/* All photos have the same VISIBLE height, without cropping.
   Widths vary naturally to preserve each photo's aspect ratio. */
.showcase__slide {
  flex: 0 0 auto;
  width: max-content;
  height: min(70vh, 600px);
}

.showcase__slide img {
  display: block;
  width: auto;
  max-width: none;
  height: 100%;
  object-fit: contain;
  -webkit-user-drag: none;
}

.showcase__btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  background: rgba(64, 52, 42, 0.55);
  color: #fff;
  font-family: "Alegreya Sans", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.15rem;
  line-height: 1;
  backdrop-filter: blur(2px);
  transition: background 0.2s ease;
  z-index: 2;
}

.showcase__btn:hover {
  background: rgba(64, 52, 42, 0.8);
}

.showcase__btn--prev { left: 0.9rem; }
.showcase__btn--next { right: 0.9rem; }

/* ---------- mobile: certificates in rows of 4 ---------- */
@media (max-width: 767px) {
  .certs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem 0.75rem;
  }

  .certs__item img {
    width: 100%;
  }

  .certs__cap {
    margin-top: 0.3rem;
    font-size: 0.5rem;
    letter-spacing: 0.06em;
  }
}

@media (prefers-reduced-motion: reduce) {
  .showcase__track { transition: none; }
}
