/**
 * TrackFlow Frontend Customer Portal Styles.
 *
 * @package TrackFlow
 */

:root {
	--tf-primary: #3b82f6;
	--tf-primary-light: #eff6ff;
	--tf-border: #e2e8f0;
	--tf-text: #1e293b;
	--tf-text-muted: #64748b;
	--tf-radius: 16px;
}

.trackflow-tracking-container {
	max-width: 800px;
	margin: 20px auto;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	color: var(--tf-text);
}

.tf-search-card {
	background: #ffffff;
	border: 1px solid var(--tf-border);
	border-radius: var(--tf-radius);
	padding: 32px;
	box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.01);
}

.tf-search-header {
	text-align: center;
	margin-bottom: 24px;
}

.tf-search-icon {
	width: 56px;
	height: 56px;
	background: var(--tf-primary-light);
	color: var(--tf-primary);
	border-radius: 50%;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 12px;
}

.tf-search-header h2 {
	font-size: 24px;
	font-weight: 800;
	color: var(--tf-text);
	margin: 0 0 6px 0;
}

.tf-search-header p {
	color: var(--tf-text-muted);
	font-size: 14px;
	margin: 0;
}

.tf-search-form {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

.tf-input-group {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.tf-input-group label {
	font-size: 13px;
	font-weight: 700;
	color: #334155;
}

.tf-input-group input {
	width: 100%;
	padding: 12px 16px;
	border: 1px solid #cbd5e1;
	border-radius: 10px;
	font-size: 15px;
	transition: all 0.2s ease;
	outline: none;
	box-sizing: border-box;
}

.tf-input-group input:focus {
	border-color: var(--tf-primary);
	box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.tf-submit-btn {
	background: var(--tf-primary);
	color: #ffffff;
	border: none;
	padding: 14px 24px;
	font-size: 16px;
	font-weight: 700;
	border-radius: 10px;
	cursor: pointer;
	transition: all 0.2s ease;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: 6px;
}

.tf-submit-btn:hover {
	background: #2563eb;
	transform: translateY(-1px);
}

/* Notice */
.tf-notice {
	padding: 12px 16px;
	border-radius: 8px;
	font-size: 14px;
	margin-top: 16px;
}
.tf-notice-error { background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; }
.tf-notice-info { background: #eff6ff; border: 1px solid #bfdbfe; color: #1e40af; }

/* Result Section */
.tf-result-card {
	background: #ffffff;
	border: 1px solid var(--tf-border);
	border-radius: var(--tf-radius);
	padding: 32px;
	margin-top: 24px;
	box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05);
}

.tf-result-header {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	flex-wrap: wrap;
	gap: 16px;
	border-bottom: 1px solid var(--tf-border);
	padding-bottom: 20px;
}

.tf-header-info h3 {
	font-size: 22px;
	font-weight: 800;
	margin: 8px 0 4px 0;
}

.tf-customer-sub {
	color: var(--tf-text-muted);
	font-size: 14px;
	margin: 0;
}

.tf-courier-box {
	text-align: right;
	background: var(--tf-bg-light, #f8fafc);
	padding: 12px 16px;
	border-radius: 12px;
	border: 1px solid var(--tf-border);
}

.tf-courier-title {
	display: block;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	color: var(--tf-text-muted);
}

.tf-courier-name {
	font-size: 16px;
	font-weight: 800;
	color: var(--tf-text);
}

.tf-awb-chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: #e2e8f0;
	padding: 2px 8px;
	border-radius: 6px;
	font-size: 12px;
	margin-top: 4px;
}

.tf-copy-awb-btn {
	background: transparent;
	border: none;
	cursor: pointer;
	padding: 0;
	display: flex;
	align-items: center;
	color: #475569;
}

.tf-dates-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
	margin: 20px 0;
	padding: 16px;
	background: #f8fafc;
	border-radius: 12px;
}

.tf-date-label {
	display: block;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	color: var(--tf-text-muted);
}

.tf-date-val {
	font-size: 15px;
	font-weight: 700;
}

.tf-highlight-date {
	color: var(--tf-primary);
}

/* Timeline Visual Stepper */
.tf-stepper-wrapper {
	position: relative;
	margin: 40px 0;
	padding: 0 10px;
}

.tf-stepper-progress-bg {
	position: absolute;
	top: 20px;
	left: 40px;
	right: 40px;
	height: 4px;
	background: #e2e8f0;
	z-index: 1;
}

.tf-stepper-progress-bar {
	height: 100%;
	background: var(--tf-primary);
	transition: width 0.4s ease;
}

.tf-stepper-steps {
	position: relative;
	z-index: 2;
	display: flex;
	justify-content: space-between;
}

.tf-step-item {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	width: 100px;
}

.tf-step-circle {
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background: #ffffff;
	border: 3px solid #cbd5e1;
	color: #94a3b8;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: all 0.3s ease;
}

.tf-step-item.is-completed .tf-step-circle {
	background: var(--tf-primary);
	border-color: var(--tf-primary);
	color: #ffffff;
}

.tf-step-item.is-current .tf-step-circle {
	background: #ffffff;
	border-color: var(--tf-primary);
	color: var(--tf-primary);
	box-shadow: 0 0 0 5px rgba(59, 130, 246, 0.25);
}

.tf-step-title {
	font-size: 12px;
	font-weight: 700;
	margin-top: 10px;
	color: #334155;
}

.tf-step-desc {
	font-size: 10px;
	color: var(--tf-text-muted);
	margin-top: 2px;
}

/* Footer & Buttons */
.tf-track-external-btn {
	background: var(--tf-primary);
	color: #ffffff !important;
	padding: 12px 24px;
	border-radius: 10px;
	font-weight: 700;
	text-decoration: none !important;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	transition: all 0.2s ease;
}

.tf-track-external-btn:hover {
	opacity: 0.95;
	transform: translateY(-1px);
}

/* Responsive adjustments */
@media (max-width: 640px) {
	.tf-stepper-steps {
		flex-direction: column;
		align-items: flex-start;
		gap: 20px;
	}
	.tf-stepper-progress-bg { display: none; }
	.tf-step-item {
		flex-direction: row;
		width: 100%;
		text-align: left;
		gap: 14px;
	}
	.tf-dates-grid { grid-template-columns: 1fr; }
}

/* Free Shipping Timer */
.trackflow-marketing-timer {
	display: flex;
	align-items: center;
	gap: 12px;
	background: var(--tf-primary-light, #eff6ff);
	border: 1px dashed var(--tf-primary, #3b82f6);
	padding: 12px 16px;
	border-radius: 8px;
	margin-bottom: 20px;
	color: var(--tf-text, #1e293b);
	font-weight: 600;
}
.trackflow-marketing-timer .tf-timer-icon {
	color: var(--tf-primary, #3b82f6);
	display: flex;
}
.trackflow-marketing-timer .tf-countdown {
	font-weight: 800;
	color: #be123c;
	background: #ffffff;
	padding: 2px 6px;
	border-radius: 4px;
	border: 1px solid #e2e8f0;
	margin: 0 4px;
}
