/* ============================================
   TadLoop - Pure JavaScript Marquee/Carousel
   ============================================ */

/* Container */
.tad-loop {
  border-bottom: 1px solid #eee;
  padding-bottom: 0;
  overflow: hidden;
  position: relative;
}

/* Item wrapper - holds all items in a row */
.tad-loop .item-wrap {
  transform: translateX(0px);
  width: max-content;
  position: relative;
  white-space: nowrap;
  display: flex;
  will-change: transform;
}

/* Individual item */
.tad-loop .item {
  background: #d3d0d0;
  border-right: 1px solid #eee;
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
  min-width: 200px;
}

.tad-loop .item a {
  text-decoration: none;
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: #fff;
  font-weight: bold;
  line-height: 1.4;
  height: 100%;
  padding: 10px 20px;
  white-space: nowrap;
}

.tad-loop .item.active {
  background: #c0392b;
}

.tad-loop .item.active a {
  color: #fff;
}

/* ─── Controls ─────────────────────────────── */

.tadloop-controls {
  position: absolute;
  z-index: 1000;
  display: flex;
  gap: 5px;
}

.tadloop-btn {
  background-color: rgba(255, 255, 255, 0.7);
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  transition: all 0.2s ease;
  color: #333;
  font-size: 14px;
  line-height: 1;
}

.tadloop-btn:hover,
.tadloop-btn:focus {
  background-color: rgba(255, 255, 255, 0.95);
  outline: 2px solid #005fcc;
  outline-offset: 2px;
}

.tadloop-btn:active {
  transform: scale(0.95);
}

/* ─── Reduced Motion ───────────────────────── */

@media (prefers-reduced-motion: reduce) {
  .tad-loop .item-wrap {
    animation: none !important;
    transform: none !important;
  }
}

/* ─── Focus visible for keyboard users ─────── */

.tad-loop:focus-visible {
  outline: 3px solid #005fcc;
  outline-offset: 2px;
}