/*
 * Vortex Store — homepage sections.
 */

/* ------------------------------------------------------------------ */
/* Hero slideshow                                                      */
/* ------------------------------------------------------------------ */

.vs-hero { padding-top: 24px; }

.vs-slider {
	position: relative;
	overflow: hidden;
}

.vs-slider__track {
	display: flex;
	align-items: stretch;
	transition: transform .55s cubic-bezier(.3, 1, .3, 1);
	will-change: transform;
}

.vs-slide {
	position: relative;
	flex: 0 0 100%;
	border-radius: var(--vs-radius-block);
	overflow: hidden;
	transition: opacity .4s ease;
}

/* On wide screens the active slide is centred with its neighbours peeking,
   matching the source storefront's carousel. */
@media (min-width: 1024px) {
	.vs-slider__track { gap: 20px; }
	.vs-slide { flex: 0 0 75%; opacity: .45; }
	.vs-slide.is-active { opacity: 1; }
}

.vs-slide__img {
	width: 100%;
	aspect-ratio: var(--vs-hero-ratio);
	object-fit: cover;
}

.vs-slide__content {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 16px;
	padding: clamp(20px, 5vw, 64px);
	color: #fff;
	text-shadow: 0 2px 18px rgba(0, 0, 0, .45);
}

.vs-slide__content--center { align-items: center; text-align: center; }
.vs-slide__content--left   { align-items: flex-start; text-align: left; }
.vs-slide__content--right  { align-items: flex-end; text-align: right; }

.vs-slide__heading { margin: 0; color: inherit; }
.vs-slide__text { max-width: 46ch; }
.vs-slide__content .vs-btn { text-shadow: none; }

.vs-slider__dots {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: 20px;
}

.vs-slider__dot {
	width: 10px;
	height: 10px;
	padding: 0;
	border: 0;
	border-radius: 10px;
	background: rgba(var(--vs-fg-rgb), .2);
	cursor: pointer;
	transition: width .3s ease, background-color .3s ease;
}

.vs-slider__dot.is-active {
	width: 32px;
	background: var(--vs-fg);
}

/* ------------------------------------------------------------------ */
/* Trust badges                                                        */
/* ------------------------------------------------------------------ */

.vs-features__list {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 10px;
}

.vs-feature {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 10px 16px;
	border: 1px solid var(--vs-border);
	border-radius: 999px;
	background: var(--vs-bg);
	font-size: 1rem;
}

.vs-feature__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 34px;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: var(--vs-btn-secondary);
}

@media (max-width: 767px) {
	.vs-features__list { flex-direction: column; align-items: stretch; }
	.vs-feature { justify-content: center; text-align: center; }
}

/* ------------------------------------------------------------------ */
/* Product tabs                                                        */
/* ------------------------------------------------------------------ */

.vs-producttabs { padding-top: 60px; }

@media (min-width: 1024px) { .vs-producttabs { padding-top: 100px; } }

.vs-producttabs__header { margin-bottom: 28px; }

.vs-producttabs__nav {
	display: flex;
	gap: 24px;
	overflow-x: auto;
	scrollbar-width: none;
	-webkit-overflow-scrolling: touch;
}

.vs-producttabs__nav::-webkit-scrollbar { display: none; }

@media (min-width: 768px) { .vs-producttabs__nav { gap: 48px; flex-wrap: wrap; overflow: visible; } }

.vs-producttabs__tab {
	padding: 0;
	border: 0;
	background: none;
	color: rgba(var(--vs-fg-rgb), .33);
	white-space: nowrap;
	cursor: pointer;
	transition: color .2s ease;
}

.vs-producttabs__tab .h2 { margin: 0; }
.vs-producttabs__tab:hover { color: rgba(var(--vs-fg-rgb), .6); }
.vs-producttabs__tab.is-active { color: var(--vs-fg); }

.vs-producttabs__panel[hidden] { display: none; }
.vs-producttabs__panel.is-loading { opacity: .5; }

.vs-producttabs__placeholder { min-height: 320px; }

.vs-producttabs__more { margin-top: 32px; text-align: center; }

/* ------------------------------------------------------------------ */
/* Text block                                                          */
/* ------------------------------------------------------------------ */

.vs-richtext__heading { margin-bottom: .3em; }
.vs-richtext__body { max-width: 70ch; }
.vs-richtext__cta { margin-top: 24px; }

/* ------------------------------------------------------------------ */
/* Image with text                                                     */
/* ------------------------------------------------------------------ */

.vs-imagetext__grid {
	display: grid;
	gap: 24px;
	align-items: center;
}

@media (min-width: 768px) {
	.vs-imagetext__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; }
	.vs-imagetext--text-first .vs-imagetext__media { order: 2; }
	.vs-imagetext--text-first .vs-imagetext__content { padding-right: 48px; padding-left: 0; }
	.vs-imagetext__content { padding-left: 48px; }
}

.vs-imagetext__media { border-radius: var(--vs-radius-block); overflow: hidden; }
.vs-imagetext__img { width: 100%; height: 100%; object-fit: cover; }
.vs-imagetext__heading { margin-bottom: .3em; }

/* ------------------------------------------------------------------ */
/* Video                                                               */
/* ------------------------------------------------------------------ */

.vs-video__frame {
	position: relative;
	border-radius: var(--vs-radius-block);
	overflow: hidden;
	background: var(--vs-surface);
	aspect-ratio: 16 / 9;
}

.vs-video__poster { width: 100%; height: 100%; object-fit: cover; }

.vs-video__frame iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

.vs-video__play {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	border: 0;
	background: none;
	cursor: pointer;
}

.vs-video__play-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 76px;
	height: 76px;
	padding-left: 4px;
	border-radius: 50%;
	background: rgba(255, 255, 255, .92);
	color: #000;
	transition: transform .25s ease;
}

.vs-video__play:hover .vs-video__play-icon { transform: scale(1.08); }

/* ------------------------------------------------------------------ */
/* Instagram                                                           */
/* ------------------------------------------------------------------ */

.vs-instagram__heading { margin-bottom: 1em; }

.vs-instagram__grid {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: 40%;
	gap: 4px;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	-webkit-overflow-scrolling: touch;
	padding-inline: 15px;
}

@media (min-width: 768px) {
	.vs-instagram__grid {
		grid-auto-flow: row;
		grid-template-columns: repeat(4, minmax(0, 1fr));
		grid-auto-columns: auto;
		overflow: visible;
		padding-inline: 0;
	}
}

.vs-instagram__item { scroll-snap-align: start; }
.vs-instagram__link { display: block; }

.vs-instagram__img {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
	transition: opacity .25s ease;
}

.vs-instagram__link:hover .vs-instagram__img { opacity: .85; }

.vs-instagram__cta { margin-top: 24px; text-align: center; }
