/*
 * DESIGN NOTE: modern masonry-style card grid — each story is a self-
 * contained card with a photo carousel, a quote mark accent, and the
 * name signed off at the bottom. Replace the color tokens below with
 * your real theme variables (check :root on juplee.in in devtools)
 * before shipping.
 */
.juplee-stories-wall {
	--jp-accent: #A24552;
	--jp-accent-2: #B8895D;
	--jp-ink: #2B2420;
	--jp-bg: #F7F3EC;
	--jp-surface: #FFFFFF;
	--jp-border: #E7DFD3;
	--jp-font-display: 'Playfair Display', Georgia, serif;
	--jp-font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

	--jp-radius: 18px;
	--jp-shadow: 0 1px 2px rgba(43,36,32,0.04), 0 20px 44px -24px rgba(43,36,32,0.28);

	box-sizing: border-box;
	width: 100%;
	/*max-width: 1200px;*/
	margin: 0 auto;
	padding: 0;
	/*background: var(--jp-bg);*/
	color: var(--jp-ink);
}

.juplee-stories-wall *,
.juplee-stories-wall *::before,
.juplee-stories-wall *::after {
	box-sizing: border-box;
}

.juplee-stories-empty {
	text-align: center;
	padding-block: clamp(3rem, 10vw, 6rem);
	font-family: var(--jp-font-display);
	font-size: clamp(1.1rem, 2vw, 1.4rem);
}

/* ---------- Header ---------- */
.juplee-stories-head {
	text-align: center;
	max-width: 560px;
	margin: 0 auto clamp(2rem, 5vw, 3rem);
}

.juplee-stories-kicker {
	display: inline-block;
	font-size: 0.72rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--jp-accent);
	margin-bottom: 0.6rem;
}

.juplee-stories-title {
	font-family: var(--jp-font-display);
	font-size: clamp(1.6rem, 3vw + 1rem, 2.4rem);
	line-height: 1.2;
	margin: 0;
}

/* ---------- Masonry-style grid ---------- */
.juplee-stories-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: clamp(1rem, 2vw, 1.5rem);
	align-items: start;
}

@media (max-width: 980px) {
	.juplee-stories-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 620px) {
	.juplee-stories-grid { grid-template-columns: 1fr; }
}

/* Vary card heights slightly for an organic, non-boxy feel */
.juplee-story-card-item:nth-child(3n+2) { margin-top: clamp(0px, 3vw, 28px); }
@media (max-width: 620px) {
	.juplee-story-card-item:nth-child(3n+2) { margin-top: 0; }
}

/* ---------- Card ---------- */
.juplee-story-card-item {
	position: relative;
	background: var(--jp-surface);
	border: 1px solid var(--jp-border);
	border-radius: var(--jp-radius);
	box-shadow: var(--jp-shadow);
	overflow: hidden;
	opacity: 0; /* animated in via JS; see stories-wall.js */
	transform: translateY(28px);
	transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.juplee-story-card-item:hover {
	transform: translateY(-4px);
	box-shadow: 0 1px 2px rgba(43,36,32,0.05), 0 28px 52px -22px rgba(43,36,32,0.32);
}

/* ---------- Photo carousel ---------- */
.juplee-story-media {
	position: relative;
	overflow: hidden;
	cursor: grab;
	touch-action: pan-y;
}

.juplee-story-media.is-dragging {
	cursor: grabbing;
}

.juplee-story-media-track {
	display: flex;
}

.juplee-story-img {
	flex: 0 0 100%;
	width: 100%;
	aspect-ratio: 4 / 5;
	object-fit: cover;
	display: block;
	-webkit-user-drag: none;
	user-select: none;
	pointer-events: none;
}

.juplee-story-dots {
	position: absolute;
	left: 50%;
	bottom: 0.75rem;
	transform: translateX(-50%);
	display: flex;
	gap: 0.4rem;
	padding: 0.3rem 0.6rem;
	background: rgba(20,16,14,0.35);
	border-radius: 999px;
	backdrop-filter: blur(2px);
}

.juplee-story-dot {
	width: 6px;
	height: 6px;
		min-height: 6px;
	border-radius: 50%;
	border: none;
	background: rgba(255,255,255,0.55);
	cursor: pointer;
	padding: 0;
	transition: background 0.15s ease, transform 0.15s ease;
}

.juplee-story-dot.is-active {
	background: #fff;
	transform: scale(1.25);
}

/* ---------- Text ---------- */
.juplee-story-text {
	position: relative;
	padding: 1.5rem 1.5rem 1.75rem;
}

.juplee-story-quote {
	width: 28px;
	height: 22px;
	color: var(--jp-accent-2);
	opacity: 0.5;
	margin-bottom: 0.5rem;
}

.juplee-story-card-item--text-only .juplee-story-text {
	padding-top: 1.75rem;
}

.juplee-story-body {
	font-family: var(--jp-font-body);
	font-size: 0.98rem;
	line-height: 1.65;
	margin: 0 0 1rem;
	white-space: pre-line;
	color: var(--jp-ink);
}

.juplee-story-name {
	font-family: var(--jp-font-display);
	font-style: italic;
	font-size: 1.05rem;
	color: var(--jp-accent);
	margin: 0;
}

/* Respect users who've asked for reduced motion */
@media (prefers-reduced-motion: reduce) {
	.juplee-story-card-item {
		opacity: 1;
		transform: none;
		transition: none;
	}
}