/* Build Your Routine Section */
.routine-section {
	width: 100%;
	padding: 60px 20px;
	background: #ffffff;
}

.routine-container {
	max-width: 1400px;
	margin: 0 auto;
}

.routine-title {
	text-align: center;
	font-size: 34px;
	font-weight: 700;
	color: #111;
	margin: 0 0 35px;
}

/* Tabs Row */
.routine-tabs-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 15px;
	flex-wrap: wrap;
	gap: 15px;
}

.routine-tabs {
	display: flex;
	gap: 12px;
	flex-wrap: wrap;
}

.routine-tab {
	background: transparent;
	border: none;
	padding: 12px 22px;
	border-radius: 30px;
	font-size: 14px;
	font-weight: 500;
	color: #333;
	cursor: pointer;
	transition: all 0.3s ease;
}

.routine-tab.active {
	background: #111;
	color: #fff;
}

.routine-tab:not(.active):hover {
	background: #f0f0f0;
}

/* Shop by Concerns row - desktop pe hidden, apni jagah tabs ke saath */
.routine-concerns-row {
	display: none;
}

.routine-concerns-btn {
	display: inline-block;
	border: 1px solid #ccc;
	padding: 12px 24px;
	border-radius: 30px;
	font-size: 14px;
	font-weight: 500;
	color: #111;
	text-decoration: none;
	white-space: nowrap;
	transition: all 0.3s ease;
}

.routine-concerns-btn:hover {
	background: #111;
	color: #fff;
	border-color: #111;
}

/* Desktop: Shop by Concerns dikhega tabs row ke right side pe */
.routine-tabs-row::after {
	content: '';
}

/* Panels */
.routine-panel {
	display: none;
	margin-top: 25px;
}

.routine-panel.active {
	display: block;
}

/* Grid Box - Desktop: shared border box */
.routine-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	border: 1px solid #d0d0d0;
	border-radius: 16px;
	overflow: hidden;
	background: #ffffff;
}

.routine-column {
	padding: 40px;
	position: relative;
	box-sizing: border-box;
}

.routine-column:not(:last-child)::after {
	content: '';
	position: absolute;
	top: 0;
	right: 0;
	width: 1px;
	height: 100%;
	background-color: #d0d0d0;
}

.routine-heading {
	font-size: 30px;
	font-weight: 600;
	color: #111;
	margin: 0 0 30px;
}

/* Product Inside Column */
.routine-product {
	display: flex;
	align-items: center;
	gap: 20px;
}

.routine-product-image {
	flex-shrink: 0;
	width: 130px;
	height: 130px;
	border-radius: 50%;
	background: #eee;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
}

.routine-product-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.routine-product-info {
	flex: 1;
}

.routine-brand {
	display: block;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.5px;
	color: #888;
	margin-bottom: 4px;
}

.routine-product-title {
	font-size: 16px;
	font-weight: 600;
	margin: 0 0 4px;
	line-height: 1.4;
}

.routine-product-title a {
	color: #111;
	text-decoration: none;
}

.routine-product-desc {
	font-size: 12px;
	color: #999;
	margin: 0 0 10px;
	line-height: 1.4;
}

.routine-product-price {
	font-size: 15px;
	font-weight: 600;
	color: #111;
	margin-bottom: 8px;
}

.routine-product-rating {
	display: flex;
	align-items: center;
	gap: 3px;
	font-size: 12px;
	color: #f5a623;
	margin-bottom: 15px;
}

.routine-rating-count {
	color: #888;
	margin-left: 5px;
}

.routine-add-btn {
	display: inline-block;
	background: #111;
	color: #fff;
	padding: 10px 24px;
	border-radius: 30px;
	text-decoration: none;
	font-size: 13px;
	font-weight: 500;
	transition: background 0.3s ease;
}

.routine-add-btn:hover {
	background: #333;
	color: #fff;
}

.routine-no-product {
	font-size: 13px;
	color: #999;
}

/* Footer row (progress bar + arrows) - Desktop pe hidden */
.routine-footer-row {
	display: none;
}

/* ============================= */
/* TABLET */
/* ============================= */
@media (max-width: 992px) and (min-width: 577px) {
	.routine-grid {
		grid-template-columns: 1fr;
	}

	.routine-column:not(:last-child)::after {
		width: 100%;
		height: 1px;
		top: auto;
		bottom: 0;
		right: 0;
	}
}

/* ============================= */
/* MOBILE - CAROUSEL LAYOUT */
/* ============================= */
@media (max-width: 576px) {

	.routine-section {
		padding: 35px 15px;
	}

	.routine-title {
		font-size: 30px;
		margin-bottom: 20px;
		line-height: 1.2;
	}

	/* Tabs - horizontal scroll */
	.routine-tabs-row {
		margin-bottom: 15px;
	}

	.routine-tabs {
		overflow-x: auto;
		flex-wrap: nowrap;
		white-space: nowrap;
		width: 100%;
		scrollbar-width: none;
		gap: 10px;
	}

	.routine-tabs::-webkit-scrollbar {
		display: none;
	}

	.routine-tab {
		flex-shrink: 0;
		font-size: 14px;
		padding: 12px 20px;
	}

	/* Shop by Concerns - apni alag row, left aligned */
	.routine-concerns-row {
		display: block;
		margin-bottom: 25px;
	}

	.routine-concerns-btn {
		width: auto;
	}

	/* Grid becomes horizontal scroll carousel */
	.routine-grid {
		display: flex;
		gap: 15px;
		border: none;
		border-radius: 0;
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: none;
		padding-bottom: 5px;
	}

	.routine-grid::-webkit-scrollbar {
		display: none;
	}

	/* Har column apna individual card ban jata hai */
	.routine-column {
		flex: 0 0 88%;
		scroll-snap-align: center;
		border: 1px solid #d0d0d0;
		border-radius: 16px;
		padding: 25px 20px;
	}

	.routine-column::after {
		display: none; /* divider lines hata di - ab har card apna border hai */
	}

	.routine-heading {
		font-size: 36px;
		margin-bottom: 25px;
	}

	/* Product - image left, text right (row layout) */
	.routine-product {
		flex-direction: row;
		align-items: center;
		text-align: left;
		gap: 15px;
	}

	.routine-product-image {
		width: 100px;
		height: 100px;
	}

	.routine-product-title {
		font-size: 15px;
	}

	.routine-product-desc {
		font-size: 12px;
	}

	.routine-product-price {
		font-size: 16px;
	}

	.routine-add-btn {
		padding: 12px 28px;
		font-size: 13px;
	}

	/* Footer row - progress bar + arrows */
	.routine-footer-row {
		display: flex;
		align-items: center;
		gap: 15px;
		margin-top: 20px;
	}

	.routine-progress-track {
		flex: 1;
		height: 3px;
		background: #eee;
		border-radius: 10px;
		overflow: hidden;
	}

	.routine-progress-bar {
		height: 100%;
		width: 33.33%;
		background: #111;
		border-radius: 10px;
		transition: width 0.3s ease;
	}

	.routine-nav-arrows {
		display: flex;
		gap: 8px;
		flex-shrink: 0;
	}

	.routine-arrow {
		background: #fff;
		border: 1px solid #ddd;
		width: 36px;
		height: 36px;
		border-radius: 50%;
		display: flex;
		align-items: center;
		justify-content: center;
		cursor: pointer;
		font-size: 12px;
		color: #111;
	}

	.routine-arrow:hover {
		background: #111;
		color: #fff;
	}
}