/* =============================================================
   SPEAKERS — speaking engagements & sliding photo galleries
   ============================================================= */

.talks__list {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.talk-card {
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
}

@media (min-width: 860px) {
  .talk-card {
    flex-direction: row;
  }
  .talk-card:nth-child(even) {
    flex-direction: row-reverse;
  }
}

.talk-card__gallery {
  flex: 0 0 auto;
  width: 100%;
}

@media (min-width: 860px) {
  .talk-card__gallery {
    flex: 0 0 42%;
  }
}

.talk-card__body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  padding: var(--space-6);
  min-width: 0;
}

.talk-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.talk-card__title {
  font-size: var(--fs-display-s);
  line-height: var(--lh-snug);
}

.talk-card__meta {
  font-family: var(--font-mono);
  font-size: var(--fs-body-s);
  color: var(--color-text-dim);
}

.talk-card__desc {
  color: var(--color-text-muted);
}

.talk-card--soon {
  border-style: dashed;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--space-7) var(--space-5);
  gap: var(--space-3);
  color: var(--color-text-muted);
}

.talk-card--soon .tag-row {
  justify-content: center;
}

/* ---------- Sliding photo gallery ---------- */
.gallery {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--color-surface-2);
}

@media (min-width: 860px) {
  .gallery {
    height: 100%;
    min-height: 340px;
    aspect-ratio: unset;
  }
}

.gallery__track {
  display: flex;
  height: 100%;
  transition: transform var(--dur-slow) var(--ease-in-out);
}

.gallery__slide {
  flex: 0 0 100%;
  height: 100%;
}

.gallery__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--color-border-strong);
  background: rgba(6, 10, 18, 0.55);
  color: var(--color-text);
  opacity: 0;
  transition: opacity var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out), background var(--dur-base) var(--ease-out);
  z-index: 3;
  cursor: pointer;
}

.gallery:hover .gallery__arrow,
.gallery:focus-within .gallery__arrow {
  opacity: 1;
}

.gallery__arrow--prev {
  left: var(--space-3);
}

.gallery__arrow--next {
  right: var(--space-3);
}

.gallery__arrow:hover {
  background: rgba(6, 10, 18, 0.85);
  border-color: var(--color-border-accent);
  color: var(--color-cyan);
}

.gallery__dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: var(--space-3);
  display: flex;
  justify-content: center;
  gap: var(--space-2);
  z-index: 3;
}

.gallery__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: none;
  padding: 0;
  background: rgba(234, 242, 251, 0.35);
  cursor: pointer;
  transition: transform var(--dur-base) var(--ease-out), background var(--dur-base) var(--ease-out);
}

.gallery__dot.is-active {
  background: var(--color-cyan);
  transform: scale(1.35);
}

.gallery__count {
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  font-family: var(--font-mono);
  font-size: var(--fs-mono-s);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  background: rgba(6, 10, 18, 0.55);
  color: var(--color-text-muted);
  z-index: 3;
}

@media (prefers-reduced-motion: reduce) {
  .gallery__track {
    transition: none;
  }
}
