/* LEGO Deal Single Post Styling */

/* Container */
.lego-deal-container {
	background-color: var(--color-white);
	padding: 2rem 0 4rem;
}

.single-post-container.lego-deal-container .row {
	display: flex;
	gap: 2rem;
}

/* Article */
.lego-deal-post {
	width: 100%;
	max-width: 860px;
	margin: 0 auto;
}

/* Post Header */
.lego-deal-header {
	margin-bottom: 1.5rem;
	padding-bottom: 1.5rem;
	border-bottom: 2px solid var(--color-border);
}

.lego-deal-title {
	margin: 0 0 0.75rem 0;
	color: var(--color-text-dark);
	font-family: 'Space Grotesk', sans-serif;
	font-size: 2.25rem;
	font-weight: 700;
	line-height: 1.2;
	letter-spacing: -0.02em;
}

.post-meta {
	display: flex;
	align-items: center;
	gap: 1rem;
	font-size: 0.9rem;
}

.post-date {
	color: var(--color-text-light);
	font-weight: 500;
}

.post-category-badge {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	background: rgba(34, 86, 169, 0.08);
	color: var(--color-primary-blue);
	padding: 0.25rem 0.75rem;
	border-radius: 50px;
	font-size: 0.8rem;
	font-weight: 600;
}

/* ========================================
   DEAL HERO ROW (Image + Pricing Sidebar)
   ======================================== */
.deal-hero-row {
	display: flex;
	gap: 1.5rem;
	margin-bottom: 2.5rem;
	align-items: stretch;
}

/* Image Side (70%) */
.deal-hero-image {
	flex: 0 0 68%;
	border-radius: var(--radius-md);
	overflow: hidden;
	box-shadow: var(--shadow-md);
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
}

.deal-hero-image img {
	width: 100%;
	height: 100%;
	display: block;
	object-fit: contain;
	max-height: 380px;
}

/* Pricing Sidebar (30%) */
.deal-hero-sidebar {
	flex: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 0.75rem;
	background: linear-gradient(160deg, #1a3f7f 0%, #2256a9 50%, #2d6bc4 100%);
	border-radius: var(--radius-md);
	padding: 1.5rem 1.25rem;
	text-align: center;
	position: relative;
	overflow: hidden;
}

/* subtle stud pattern on sidebar */
.deal-hero-sidebar::before {
	content: '';
	position: absolute;
	inset: 0;
	background-image: radial-gradient(circle, rgba(255,255,255,0.06) 2px, transparent 2px);
	background-size: 18px 18px;
	pointer-events: none;
}

.sidebar-discount {
	background: var(--color-accent-red);
	color: #fff;
	padding: 0.4rem 1rem;
	border-radius: 50px;
	font-family: 'Space Grotesk', sans-serif;
	font-weight: 700;
	font-size: 1.05rem;
	letter-spacing: 0.02em;
	box-shadow: 0 4px 14px rgba(230, 57, 70, 0.35);
	position: relative;
	z-index: 1;
}

.sidebar-expired {
	background: #999;
	color: #fff;
	padding: 0.4rem 1rem;
	border-radius: 50px;
	font-family: 'Space Grotesk', sans-serif;
	font-weight: 700;
	font-size: 1.05rem;
	letter-spacing: 0.02em;
	box-shadow: 0 4px 14px rgba(153, 153, 153, 0.35);
	position: relative;
	z-index: 1;
}

/* Rank Badge (for Most Wanted posts on single page) */
.sidebar-rank-badge {
	width: 60px;
	height: 60px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 700;
	font-family: 'Space Grotesk', sans-serif;
	z-index: 2;
	border: 3px solid #fff;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
	margin-bottom: 0.5rem;
	animation: rank-pulse 2s ease-in-out infinite;
}

@keyframes rank-pulse {
	0%, 100% {
		transform: scale(1);
	}
	50% {
		transform: scale(1.1);
	}
}

.sidebar-rank-number {
	font-size: 2rem;
	line-height: 1;
	color: #fff;
	text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Rank Medal Colors */
.sidebar-rank-badge.rank-gold {
	background: linear-gradient(135deg, #FFD700 0%, #FFC700 100%);
	box-shadow: 0 4px 20px rgba(255, 215, 0, 0.5), 0 0 0 2px #FFB700;
}

.sidebar-rank-badge.rank-silver {
	background: linear-gradient(135deg, #C0C0C0 0%, #A9A9A9 100%);
	box-shadow: 0 4px 20px rgba(192, 192, 192, 0.5), 0 0 0 2px #808080;
}

.sidebar-rank-badge.rank-bronze {
	background: linear-gradient(135deg, #CD7F32 0%, #B87333 100%);
	box-shadow: 0 4px 20px rgba(205, 127, 50, 0.5), 0 0 0 2px #8B4513;
}

.sidebar-rank-badge.rank-default {
	background: linear-gradient(135deg, #2256a9 0%, #1a3f7f 100%);
	box-shadow: 0 4px 20px rgba(34, 86, 169, 0.5), 0 0 0 2px #1a3f7f;
}

.sidebar-prices {
	width: 100%;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	position: relative;
	z-index: 1;
}

.sidebar-price-row {
	display: flex;
	flex-direction: column;
	gap: 0.1rem;
}

.sidebar-label {
	font-size: 0.7rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: rgba(255, 255, 255, 0.55);
}

.sidebar-msrp {
	font-family: 'Space Grotesk', sans-serif;
	font-size: 1.1rem;
	font-weight: 500;
	color: rgba(255, 255, 255, 0.45);
	text-decoration: line-through;
}

.sidebar-sale {
	font-family: 'Space Grotesk', sans-serif;
	font-size: 2rem;
	font-weight: 700;
	color: #fff;
	line-height: 1.1;
	text-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.sidebar-savings {
	font-size: 0.75rem;
	font-weight: 600;
	color: #6ee7a0;
	background: rgba(110, 231, 160, 0.12);
	padding: 0.25rem 0.75rem;
	border-radius: 50px;
	position: relative;
	z-index: 1;
}

.sidebar-cta {
	display: block;
	width: 100%;
	padding: 0.7rem 1rem;
	background: #fff;
	color: var(--color-primary-blue) !important;
	border-radius: var(--radius-sm);
	font-family: 'Space Grotesk', sans-serif;
	font-weight: 700;
	font-size: 0.9rem;
	text-decoration: none;
	transition: all 0.25s ease;
	position: relative;
	z-index: 1;
}

.sidebar-cta:hover {
	background: #f0f4ff;
	transform: translateY(-2px);
	box-shadow: 0 6px 20px rgba(0,0,0,0.2);
	color: var(--color-primary-blue) !important;
}

.deal-hero-sidebar .back-to-deals {
	color: rgba(255,255,255,0.5);
	font-size: 0.78rem;
	font-weight: 500;
	text-decoration: none;
	transition: color 0.2s ease;
	position: relative;
	z-index: 1;
}

.deal-hero-sidebar .back-to-deals:hover {
	color: #fff;
}

/* Expired deal styling */
.deal-hero-sidebar.is-expired {
	opacity: 0.65;
}

/* ========================================
   POST CONTENT
   ======================================== */
.lego-deal-content {
	line-height: 1.8;
	color: var(--color-text-dark);
	font-size: 1.05rem;
}

.lego-deal-content p {
	margin-bottom: 1.5rem;
	color: var(--color-text-light);
}

.lego-deal-content strong {
	color: var(--color-text-dark);
	font-weight: 600;
}

.lego-deal-content h2,
.lego-deal-content h3 {
	font-family: 'Space Grotesk', sans-serif;
	color: var(--color-text-dark);
	margin-top: 2.5rem;
	margin-bottom: 1rem;
	letter-spacing: -0.02em;
}

.lego-deal-content h2:first-of-type {
	margin-top: 0;
}

.lego-deal-content ul,
.lego-deal-content ol {
	margin: 1.5rem 0;
	padding-left: 1.5rem;
	list-style: none;
}

.lego-deal-content li {
	margin-bottom: 0.75rem;
	color: var(--color-text-light);
	position: relative;
	padding-left: 1.75rem;
}

/* Fun bullets using ::before pseudo-elements */
.lego-deal-content ul > li::before {
	content: '🧱';
	position: absolute;
	left: 0;
	font-size: 1.1rem;
	display: inline-block;
	width: 1.25rem;
}

.lego-deal-content ol {
	counter-reset: item;
	list-style-type: none;
	padding-left: 0;
}

.lego-deal-content ol > li {
	counter-increment: item;
	padding-left: 2.5rem;
}

.lego-deal-content ol > li::before {
	content: counter(item);
	position: absolute;
	left: 0;
	background: linear-gradient(135deg, var(--color-primary-blue), var(--color-gradient-blue));
	color: #fff;
	width: 1.75rem;
	height: 1.75rem;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 700;
	font-family: 'Space Grotesk', sans-serif;
	font-size: 0.85rem;
	box-shadow: 0 2px 6px rgba(34, 86, 169, 0.25);
}

/* Blockquotes */
.lego-deal-content blockquote {
	border-left: 4px solid var(--color-primary-blue);
	padding: 1rem 1.5rem;
	margin: 2rem 0;
	background: var(--color-light-bg);
	border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
	font-style: italic;
	color: var(--color-text-light);
}

/* Tables */
.lego-deal-content table {
	width: 100%;
	border-collapse: collapse;
	margin: 1.5rem 0;
	border-radius: var(--radius-sm);
	overflow: hidden;
}

.lego-deal-content table th,
.lego-deal-content table td {
	padding: 0.75rem 1rem;
	text-align: left;
	border-bottom: 1px solid var(--color-border);
}

.lego-deal-content table th {
	background-color: var(--color-light-bg);
	font-weight: 600;
	color: var(--color-text-dark);
	font-family: 'Space Grotesk', sans-serif;
}

/* ========================================
   BOTTOM CTA
   ======================================== */
.lego-deal-bottom-cta {
	margin-top: 3rem;
	padding: 2rem;
	background: linear-gradient(135deg, var(--color-light-bg) 0%, #e8edf5 100%);
	border-radius: var(--radius-md);
	text-align: center;
}

.lego-deal-bottom-cta h3 {
	font-family: 'Space Grotesk', sans-serif;
	margin: 0 0 0.5rem 0;
	color: var(--color-text-dark);
}

.lego-deal-bottom-cta p {
	color: var(--color-text-light);
	margin-bottom: 1rem;
}

.lego-deal-bottom-cta .btn-view-deals {
	display: inline-block;
	background: linear-gradient(135deg, var(--color-primary-blue), var(--color-gradient-blue));
	color: var(--color-white);
	padding: 0.75rem 2rem;
	border-radius: var(--radius-sm);
	font-weight: 600;
	font-family: 'Space Grotesk', sans-serif;
	text-decoration: none;
	transition: all 0.3s ease;
}

.lego-deal-bottom-cta .btn-view-deals:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 25px rgba(34, 86, 169, 0.35);
	color: var(--color-white);
}

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 768px) {
	.lego-deal-container {
		padding: 1.5rem 0 3rem;
	}

	.lego-deal-title {
		font-size: 1.75rem;
	}

	.deal-hero-row {
		flex-direction: column;
		gap: 1rem;
	}

	.deal-hero-image {
		flex: none;
		width: 100%;
	}

	.deal-hero-image img {
		max-height: 280px;
	}

	.deal-hero-sidebar {
		flex-direction: row;
		flex-wrap: wrap;
		justify-content: center;
		padding: 1.25rem;
		gap: 0.5rem 1rem;
	}

	.sidebar-prices {
		flex-direction: row;
		gap: 1rem;
		justify-content: center;
	}

	.sidebar-price-row {
		align-items: center;
	}

	.sidebar-sale {
		font-size: 1.5rem;
	}

	.sidebar-cta {
		width: auto;
		padding: 0.6rem 1.5rem;
	}

	.lego-deal-content {
		font-size: 1rem;
	}
}

/* Most Wanted Posts - No strikethrough on MSRP */
.is-most-wanted .sidebar-msrp {
	text-decoration: none;
	color: rgba(255, 255, 255, 0.8);
}

/* Affiliate Disclaimer */
.sidebar-affiliate-disclaimer {
	font-size: 0.7rem;
	text-align: center;
	margin-top: 0.5rem;
}

.sidebar-affiliate-disclaimer a {
	color: rgba(255, 255, 255, 0.5);
	text-decoration: none;
	transition: color 0.2s ease;
}

.sidebar-affiliate-disclaimer a:hover {
	color: rgba(255, 255, 255, 0.8);
	text-decoration: underline;
}

@media (max-width: 480px) {
	.deal-hero-sidebar {
		padding: 1rem;
	}

	.sidebar-sale {
		font-size: 1.3rem;
	}

	.sidebar-cta {
		width: 100%;
	}
}
