:root {
  --p6-bg: #1f2724;
  --p6-surface: rgba(71, 96, 85, 0.28);
  --p6-border: rgba(71, 96, 85, 0.55);
  --p6-text: #e5e6e1;
  --p6-muted: rgba(229, 230, 225, 0.74);
  --p6-accent: #b15f2d;
  --p6-radius-min: 10px;
}

.p6-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px 20px;
}

.p6-carousel {
  --p6-visible: 3;
  --p6-gap: 12px;
  width: 100%;
  border-radius: 22px;
  padding: 16px;
  background: var(--p6-surface);
  border: 1px solid var(--p6-border);
  backdrop-filter: blur(7px);
}

.p6-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.p6-kicker {
  margin: 0;
  color: var(--p6-muted);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.72rem;
}

.p6-counter {
  margin: 0;
  color: var(--p6-muted);
  font-weight: 600;
}

.p6-viewport {
  overflow: hidden;
  border-radius: 14px;
}

.p6-track {
  display: flex;
  gap: var(--p6-gap);
  transition: transform 620ms cubic-bezier(0.22, 1, 0.36, 1);
}

.p6-card-item {
  flex: 0 0
    calc((100% - (var(--p6-visible) - 1) * var(--p6-gap)) / var(--p6-visible));
  border-radius: 14px;
  overflow: hidden;
  background: rgba(71, 96, 85, 0.28);
  border: 1px solid rgba(71, 96, 85, 0.55);
  transform: translateY(0) scale(1);
  opacity: 1;
  transition:
    transform 420ms ease,
    opacity 420ms ease,
    border-color 420ms ease,
    box-shadow 420ms ease;
}

.p6-card-item:hover {
  transform: translateY(-5px) scale(1.06);
  border-color: rgba(216, 158, 109, 0.72);
  box-shadow: 0 24px 52px rgba(0, 0, 0, 0.36);
}

.p6-card-item[data-visible="false"] {
  opacity: 0.45;
}

.p6-carousel.is-animating .p6-card-item[data-visible="true"] {
  animation: p6-card-in 550ms ease;
}

.p6-card-item img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.p6-card-body {
  padding: 10px 12px 12px;
}

.p6-card-body h3 {
  margin: 0 0 4px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--p6-text);
}

.p6-card-body p {
  margin: 0;
  color: var(--p6-muted);
  font-size: 0.86rem;
}

.p6-dots {
  --autoplay-ms: 3800ms;
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}

.p6-dot {
  --p6-progress: 0turn;
  width: 12px;
  height: 12px;
  position: relative;
  overflow: visible;
  border: 0;
  border-radius: 50%;
  background: rgba(71, 96, 85, 0.45);
  cursor: pointer;
  transition:
    transform 180ms ease,
    background-color 180ms ease;
}

.p6-dot.is-active {
  transform: scale(1.12);
  background: var(--p6-accent);
}

.p6-dot::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  opacity: 0;
  background: conic-gradient(
    #d89e6d var(--p6-progress),
    rgba(71, 96, 85, 0.22) 0
  );
  -webkit-mask: radial-gradient(
    farthest-side,
    transparent calc(100% - 2.8px),
    #000 calc(100% - 2.2px)
  );
  mask: radial-gradient(
    farthest-side,
    transparent calc(100% - 2.8px),
    #000 calc(100% - 2.2px)
  );
}

.p6-dot.is-loading::after {
  opacity: 1;
  animation: p6-dot-load var(--autoplay-ms) linear forwards;
}

@property --p6-progress {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0turn;
}

@keyframes p6-dot-load {
  from {
    --p6-progress: 0turn;
  }

  to {
    --p6-progress: 1turn;
  }
}

@keyframes p6-card-in {
  from {
    transform: translateY(10px) scale(0.98);
    opacity: 0.25;
  }

  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

@media (max-width: 900px) {
  .p6-carousel {
    --p6-visible: 2;
  }
}

@media (max-width: 620px) {
  .p6-carousel {
    --p6-visible: 1;
  }

  .p6-page {
    padding: 16px 12px;
  }
}

/* Match main site spacing/theme */
.p6-page {
  padding: clamp(3rem, 5vw, 4.5rem) clamp(1rem, 3vw, 2.5rem);
}

.p6-carousel {
  --p6-gap: clamp(1rem, 2vw, 1.35rem);
  width: min(100%, 1200px);
  padding: clamp(1.1rem, 2vw, 1.75rem);
  border-radius: var(--p6-radius-min);
  border-color: rgba(247, 244, 238, 0.18);
  background: rgba(5, 5, 5, 0.72);
  box-shadow:
    0 28px 68px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.055);
}

.p6-head {
  margin-bottom: 1.1rem;
}

.p6-kicker,
.p6-counter {
  color: rgba(247, 244, 238, 0.72);
}

.p6-viewport,
.p6-card-item {
  border-radius: calc(var(--p6-radius-min) - 2px);
}

.p6-card-item {
  background: rgba(255, 255, 255, 0.035);
  border-color: rgba(247, 244, 238, 0.14);
}

.p6-card-item:hover {
  transform: translateY(-5px);
  border-color: rgba(198, 154, 97, 0.72);
}

.p6-card-body {
  padding: 0.95rem 1rem 1.05rem;
}

.p6-card-body h3 {
  color: #f7f4ee;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.p6-card-body p {
  color: rgba(247, 244, 238, 0.72);
  line-height: 1.55;
}

.p6-dot {
  border-radius: 0;
  background: rgba(247, 244, 238, 0.2);
}

.p6-dot.is-active {
  background: #c69a61;
}

@media (max-width: 620px) {
  .p6-page {
    padding: 2.6rem 0.9rem;
  }

  .p6-carousel {
    padding: 1rem;
  }
}
