/**
 * Enhanced Order Status Page Styles
 * Modern, interactive design with timeline visualization
 * Following site's green theme and design system
 */

/* ===================================
   Enhanced Order Status Layout
   =================================== */

.wpl-enhanced-order-status {
	/* Remove max-width to use full container width */
	margin: 0;
	padding: 0;
	position: relative; /* Ensure container is relative */
}

/* Ensure no order status elements are sticky */
.wpl-enhanced-order-status > * {
	position: relative !important;
	top: auto !important;
}

/* ===================================
   Hero Section (Compact) - No Gradients
   =================================== */

.wpl-status-hero {
	background: var(--color-primary, #059669);
	color: white;
	padding: 3rem 2rem;
	border-radius: var(--radius-lg);
	margin-bottom: 2rem;
	text-align: center;
}

.wpl-hero-content {
	position: relative;
	z-index: 1;
}

.wpl-hero-title {
	font-size: 2rem;
	font-weight: 700;
	margin-bottom: 0.5rem;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
}

.wpl-hero-title i {
	font-size: 0.9em;
}

.wpl-hero-subtitle {
	font-size: 1.1rem;
	opacity: 0.9;
	margin: 0;
}

/* ===================================
   Enhanced Lookup Section - Centered Layout
   =================================== */

.wpl-lookup-section {
	display: flex;
	justify-content: center;
	align-items: center;
	min-height: 60vh;
	margin-bottom: 2rem;
	padding: 2rem;
}

.wpl-lookup-card {
	background: var(--color-surface, #ffffff);
	border: 2px solid #e5e7eb;
	border-radius: var(--radius-lg);
	box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
	padding: 3rem;
	max-width: 500px;
	width: 100%;
	text-align: center;
}

.wpl-lookup-header {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1rem;
	margin-bottom: 2rem;
	text-align: center;
}

.wpl-lookup-icon {
	width: 60px;
	height: 60px;
	background: var(--color-primary, #059669);
	border-radius: var(--radius-md);
	display: flex;
	align-items: center;
	justify-content: center;
	color: white;
	font-size: 1.75rem;
	flex-shrink: 0;
}

.wpl-lookup-info h3 {
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--color-text, #111827);
	margin-bottom: 0.5rem;
}

.wpl-lookup-info p {
	color: var(--color-text-secondary, #6b7280);
	margin: 0;
	font-size: 1rem;
	line-height: 1.5;
}

.wpl-lookup-form {
	display: flex;
	flex-direction: column;
	gap: 1.5rem;
}

.wpl-form-group {
	margin-bottom: 0;
}

.wpl-input-group {
	position: relative;
	display: flex;
	align-items: center;
	border: 2px solid #e5e7eb;
	border-radius: var(--radius-md);
	background: var(--color-background, #ffffff);
	transition: all 0.3s ease;
}

.wpl-input-group:focus-within {
	border-color: var(--color-primary, #059669);
	box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.1);
}

.wpl-input-prefix {
	font-size: 1.125rem;
	font-weight: 600;
	color: var(--color-text, #111827);
	padding: 1rem 0.75rem 1rem 1rem;
	border-right: 1px solid #e5e7eb;
	background: #f9fafb;
	border-radius: var(--radius-md) 0 0 var(--radius-md);
	user-select: none;
	pointer-events: none;
}

.wpl-form-input {
	width: 100%;
	padding: 1rem;
	border: none !important;
	outline: none;
	font-size: 1.125rem;
	background: transparent;
	text-align: center;
	font-weight: 600;
	color: var(--color-text, #111827);
}

.wpl-form-input:focus {
	outline: none;
}

.wpl-submit-btn {
	width: 100%;
	padding: 1rem 1.5rem;
	background: var(--color-primary, #059669);
	color: white;
	border: none;
	border-radius: var(--radius-md);
	font-size: 1rem;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.3s ease;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
}

.wpl-submit-btn:hover {
	background: #047857;
	transform: translateY(-1px);
}

.wpl-help-section {
	border-top: 1px solid var(--color-border, #e5e7eb);
	padding-top: 1.5rem;
}

.wpl-help-section h4 {
	font-size: 1rem;
	font-weight: 600;
	color: var(--color-text, #111827);
	margin-bottom: 1rem;
}

.wpl-help-items {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}

.wpl-help-item {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	color: var(--color-text-secondary, #6b7280);
	font-size: 0.875rem;
}

.wpl-help-item i {
	color: var(--color-primary, #059669);
	width: 20px;
	text-align: center;
}

/* ===================================
   Order Summary Section - Two Column Layout
   =================================== */

/* Order status page specific summary */
.wpl-enhanced-order-status .wpl-order-summary {
	margin-bottom: 2rem;
	padding: 2rem;
	background: var(--color-surface, #ffffff);
	border-radius: var(--radius-lg);
	box-shadow:
		0 -2px 4px rgba(0, 0, 0, 0.05), /* Top shadow */
		-2px 0 4px rgba(0, 0, 0, 0.05), /* Left shadow */
		2px 0 4px rgba(0, 0, 0, 0.05), /* Right shadow */
		0 2px 4px rgba(0, 0, 0, 0.05), /* Bottom shadow */
		0 -1px 2px rgba(0, 0, 0, 0.03), /* Top small shadow */
		-1px 0 2px rgba(0, 0, 0, 0.03), /* Left small shadow */
		1px 0 2px rgba(0, 0, 0, 0.03), /* Right small shadow */
		0 1px 2px rgba(0, 0, 0, 0.03); /* Bottom small shadow */
	position: relative !important; /* Force relative position */
	top: auto !important; /* Override any sticky top */
}

.wpl-summary-row {
	display: flex;
	flex-direction: column;
	gap: 2rem;
}

@media (min-width: 768px) {
	.wpl-summary-row {
		flex-direction: row;
	}
}

.wpl-summary-col {
	flex: 1;
}

.wpl-section-title {
	font-size: 1.125rem;
	font-weight: 600;
	color: var(--color-text, #111827);
	margin-bottom: 1rem;
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.wpl-section-title i {
	color: var(--color-primary, #059669);
}

.wpl-order-details {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.wpl-detail-item {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 0.75rem 1rem;
	background: var(--color-background, #f9fafb);
	border-radius: var(--radius-md);
}

.wpl-detail-label {
	color: var(--color-text-secondary, #6b7280);
	font-weight: 500;
}

.wpl-detail-value {
	color: var(--color-text, #111827);
	font-weight: 600;
}

.wpl-status-info {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.wpl-status-item {
	padding: 1rem;
	border-radius: var(--radius-md);
	display: flex;
	align-items: center;
	gap: 0.75rem;
}

.wpl-status-icon {
	font-size: 1.25rem;
	width: 40px;
	height: 40px;
	background: rgba(255, 255, 255, 0.2);
	border-radius: var(--radius-md);
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
}

.wpl-status-details {
	flex: 1;
}

.wpl-status-label {
	font-size: 0.875rem;
	opacity: 0.9;
	font-weight: 500;
}

.wpl-status-text {
	font-size: 1rem;
	font-weight: 600;
}

/* ===================================
   Timeline Section - Box Style with Arrows
   =================================== */

.wpl-timeline-section {
	margin-bottom: 2rem;
	padding: 2rem;
	background: var(--color-surface, #ffffff);
	border-radius: var(--radius-lg);
	box-shadow:
		0 -2px 4px rgba(0, 0, 0, 0.05), /* Top shadow */
		-2px 0 4px rgba(0, 0, 0, 0.05), /* Left shadow */
		2px 0 4px rgba(0, 0, 0, 0.05), /* Right shadow */
		0 2px 4px rgba(0, 0, 0, 0.05), /* Bottom shadow */
		0 -1px 2px rgba(0, 0, 0, 0.03), /* Top small shadow */
		-1px 0 2px rgba(0, 0, 0, 0.03), /* Left small shadow */
		1px 0 2px rgba(0, 0, 0, 0.03), /* Right small shadow */
		0 1px 2px rgba(0, 0, 0, 0.03); /* Bottom small shadow */
}

.wpl-timeline-boxes {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	gap: 0;
	padding: 1rem 0;
}

.wpl-progress-box {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding: 1rem 1.5rem;
	background: var(--color-background, #f9fafb);
	border: 2px solid var(--color-border, #e5e7eb);
	border-radius: var(--radius-lg);
	position: relative;
	min-width: 180px;
	transition: all 0.3s ease;
}

.wpl-progress-box::after {
	content: '▶';
	position: absolute;
	right: -20px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--color-border, #e5e7eb);
	font-size: 1rem;
	z-index: 1;
}

.wpl-progress-box:last-child::after {
	display: none;
}

.wpl-progress-box.completed {
	background: var(--color-primary, #059669);
	border-color: var(--color-primary, #059669);
	color: white;
}

.wpl-progress-box.completed::after {
	color: var(--color-primary, #059669);
}

.wpl-progress-box.active {
	background: rgba(5, 150, 105, 0.1);
	border-color: var(--color-primary, #059669);
	color: var(--color-primary, #059669);
}

.wpl-progress-box.active::after {
	color: var(--color-primary, #059669);
}

.wpl-box-icon {
	font-size: 1.25rem;
	transition: all 0.3s ease;
}

.wpl-progress-box.completed .wpl-box-icon {
	/* Icon stays white for completed boxes */
}

.wpl-progress-box:not(.completed):not(.active) .wpl-box-icon {
	color: var(--color-text-secondary, #6b7280);
}

.wpl-box-text {
	font-weight: 600;
	font-size: 0.875rem;
	white-space: nowrap;
}

/* Connecting line between boxes */
.wpl-timeline-connector {
	width: 40px;
	height: 2px;
	background: var(--color-border, #e5e7eb);
	position: relative;
	flex-shrink: 0;
}

.wpl-timeline-connector.completed {
	background: var(--color-primary, #059669);
}

/* Responsive adjustments */
@media (max-width: 768px) {
	.wpl-timeline-boxes {
		flex-direction: column;
		align-items: stretch;
		gap: 1rem;
	}

	.wpl-progress-box {
		min-width: auto;
		justify-content: center;
	}

	.wpl-progress-box::after {
		content: '▼';
		right: 50%;
		bottom: -20px;
		top: auto;
		transform: translateX(50%);
	}

	.wpl-progress-box:last-child::after {
		display: none;
	}

	.wpl-timeline-connector {
		width: 2px;
		height: 20px;
		align-self: center;
	}
}

/* ===================================
   Order Grid - Flexbox Layout
   =================================== */

.wpl-order-grid {
	display: flex;
	flex-direction: column;
	gap: 2rem;
	margin-bottom: 2rem;
}

@media (min-width: 768px) {
	.wpl-order-grid {
		flex-direction: row;
		align-items: flex-start;
	}

	.wpl-order-items-card {
		flex: 1;
	}

	.wpl-sidebar {
		width: 300px;
		flex-shrink: 0;
	}
}

/* ===================================
   Order Items Card
   =================================== */

.wpl-order-items-card,
.wpl-info-card {
	background: var(--color-surface, #ffffff);
	border-radius: var(--radius-lg);
	box-shadow:
		0 -2px 4px rgba(0, 0, 0, 0.05), /* Top shadow */
		-2px 0 4px rgba(0, 0, 0, 0.05), /* Left shadow */
		2px 0 4px rgba(0, 0, 0, 0.05), /* Right shadow */
		0 2px 4px rgba(0, 0, 0, 0.05), /* Bottom shadow */
		0 -1px 2px rgba(0, 0, 0, 0.03), /* Top small shadow */
		-1px 0 2px rgba(0, 0, 0, 0.03), /* Left small shadow */
		1px 0 2px rgba(0, 0, 0, 0.03), /* Right small shadow */
		0 1px 2px rgba(0, 0, 0, 0.03); /* Bottom small shadow */
	overflow: hidden;
}

.wpl-card-header {
	padding: 1.5rem;
	border-bottom: 1px solid var(--color-border, #e5e7eb);
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.wpl-card-title {
	font-size: 1.125rem;
	font-weight: 600;
	color: var(--color-text, #111827);
	margin: 0;
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.wpl-card-title i {
	color: var(--color-primary, #059669);
}

.wpl-item-count {
	font-size: 0.875rem;
	color: var(--color-text-secondary, #6b7280);
	background: var(--color-background, #f9fafb);
	padding: 0.25rem 0.75rem;
	border-radius: var(--radius-md);
}

.wpl-card-content {
	padding: 1.5rem;
}

.wpl-items-list {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	margin-bottom: 1.5rem;
}

.wpl-item-card {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	padding: 1rem;
	background: var(--color-background, #f9fafb);
	border-radius: var(--radius-md);
}

.wpl-item-info {
	flex: 1;
}

.wpl-item-title {
	font-size: 1rem;
	font-weight: 600;
	color: var(--color-text, #111827);
	margin-bottom: 0.25rem;
}

.wpl-item-quantity {
	font-size: 0.875rem;
	color: var(--color-text-secondary, #6b7280);
	margin: 0;
}

.wpl-item-price {
	text-align: right;
	display: flex;
	flex-direction: column;
	gap: 0.25rem;
}

.wpl-price-amount {
	font-size: 1.125rem;
	font-weight: 600;
	color: var(--color-text, #111827);
}

.wpl-price-unit {
	font-size: 0.75rem;
	color: var(--color-text-secondary, #6b7280);
}

.wpl-price-breakdown {
	border-top: 1px solid var(--color-border, #e5e7eb);
	padding-top: 1rem;
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}

.wpl-price-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 0.875rem;
}

.wpl-price-row.total {
	border-top: 1px solid var(--color-border, #e5e7eb);
	padding-top: 0.75rem;
	font-size: 1rem;
	font-weight: 600;
	color: var(--color-text, #111827);
}

.wpl-price-row.discount {
	color: var(--color-success, #059669);
}

/* ===================================
   Sidebar Information
   =================================== */

.wpl-info-header {
	padding: 1.5rem;
	border-bottom: 1px solid var(--color-border, #e5e7eb);
}

.wpl-info-title {
	font-size: 1.125rem;
	font-weight: 600;
	color: var(--color-text, #111827);
	margin: 0;
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.wpl-info-title i {
	color: var(--color-primary, #059669);
}

.wpl-info-content {
	padding: 1.5rem;
}

.wpl-info-item {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	margin-bottom: 1rem;
	font-size: 0.875rem;
}

.wpl-info-item:last-child {
	margin-bottom: 0;
}

.wpl-info-label {
	color: var(--color-text-secondary, #6b7280);
	font-weight: 500;
	flex-shrink: 0;
	margin-right: 1rem;
}

.wpl-info-value {
	color: var(--color-text, #111827);
	text-align: right;
	word-break: break-word;
}

.wpl-info-item.highlight .wpl-info-value {
	color: var(--color-primary, #059669);
	font-weight: 600;
}

/* ===================================
   Action Buttons
   =================================== */

.wpl-order-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
	justify-content: center;
	padding: 2rem 0;
}

.wpl-action-btn {
	padding: 0.875rem 1.5rem;
	border-radius: var(--radius-md);
	font-size: 1rem;
	font-weight: 500;
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	transition: all 0.3s ease;
}

.wpl-action-btn.primary {
	background: var(--color-primary, #059669);
	color: white;
}

.wpl-action-btn.primary:hover {
	background: #047857;
	transform: translateY(-1px);
}

.wpl-action-btn.secondary {
	background: var(--color-surface, #ffffff);
	color: var(--color-text, #111827);
	border: 1px solid var(--color-border, #e5e7eb);
}

.wpl-action-btn.secondary:hover {
	background: var(--color-background, #f9fafb);
	transform: translateY(-1px);
}

.wpl-action-btn.outline {
	background: transparent;
	color: var(--color-primary, #059669);
	border: 1px solid var(--color-primary, #059669);
}

.wpl-action-btn.outline:hover {
	background: var(--color-primary, #059669);
	color: white;
}

/* ===================================
   Responsive Design
   =================================== */

@media (max-width: 768px) {
	.wpl-hero-title {
		font-size: 1.75rem;
	}

	.wpl-timeline-simple {
		overflow-x: auto;
		justify-content: flex-start;
		gap: 2rem;
		padding-bottom: 1.5rem;
		padding-left: 1rem;
		padding-right: 1rem;
	}

	.wpl-order-actions {
		flex-direction: column;
	}

	.wpl-action-btn {
		width: 100%;
		justify-content: center;
	}
}

@media (max-width: 768px) {
	.wpl-lookup-section {
		min-height: auto;
		padding: 1rem;
	}

	.wpl-lookup-box {
		padding: 2rem;
	}
}

@media (max-width: 480px) {
	.wpl-lookup-box {
		padding: 1.5rem;
	}

	.wpl-card-header,
	.wpl-card-content,
	.wpl-info-header,
	.wpl-info-content {
		padding: 1rem;
	}

	.wpl-item-card {
		flex-direction: column;
		gap: 0.5rem;
	}

	.wpl-item-price {
		text-align: left;
	}

	.wpl-progress-icon {
		width: 40px;
		height: 40px;
		font-size: 1rem;
	}

	.wpl-progress-step.completed .wpl-progress-icon {
		font-size: 0.875rem;
	}
}