/**
 * ECS SF Express Query - Frontend Styles
 *
 * @package ECS_SF_Query
 */

/* ── Container ── */
.ecs-sfq-frontend-tracking {
	margin: 20px 0;
	padding: 20px;
	background: #fff;
	border: 1px solid #e0e0e0;
	border-radius: 6px;
}

.ecs-sfq-frontend-tracking h2 {
	margin: 0 0 15px;
	font-size: 1.2em;
	color: #333;
	border-bottom: 1px solid #eee;
	padding-bottom: 10px;
}

.ecs-sfq-tracking-number {
	margin-bottom: 15px;
	font-size: 14px;
}

.ecs-sfq-tracking-number strong {
	color: #555;
}

/* ── Loading ── */
.ecs-sfq-loading {
	color: #888;
	font-style: italic;
	padding: 10px 0;
}

.ecs-sfq-loading::before {
	content: '⏳ ';
}

/* ── Query Button ── */
.ecs-sfq-query-btn {
	display: inline-block;
	padding: 8px 20px;
	font-size: 14px;
	cursor: pointer;
	border: 1px solid #0073aa;
	background: #0073aa;
	color: #fff;
	border-radius: 4px;
	transition: background 0.2s, opacity 0.2s;
}

.ecs-sfq-query-btn:hover {
	background: #005a87;
	border-color: #005a87;
	color: #fff;
}

.ecs-sfq-query-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

/* ── Timeline ── */
.ecs-sfq-timeline {
	position: relative;
	padding: 0;
	margin: 15px 0;
	list-style: none;
}

.ecs-sfq-timeline::before {
	content: '';
	position: absolute;
	left: 10px;
	top: 0;
	bottom: 0;
	width: 2px;
	background: #e0e0e0;
}

.ecs-sfq-timeline-item {
	position: relative;
	padding: 0 0 20px 35px;
	margin: 0;
}

.ecs-sfq-timeline-item:last-child {
	padding-bottom: 0;
}

.ecs-sfq-timeline-dot {
	position: absolute;
	left: 4px;
	top: 3px;
	width: 14px;
	height: 14px;
	border-radius: 50%;
	background: #ccc;
	border: 2px solid #fff;
	box-shadow: 0 0 0 1px #ddd;
	transition: all 0.2s;
}

.ecs-sfq-timeline-item:first-child .ecs-sfq-timeline-dot {
	background: #0073aa;
	box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.2);
	width: 16px;
	height: 16px;
	left: 3px;
	top: 2px;
}

.ecs-sfq-timeline-time {
	display: block;
	font-size: 12px;
	color: #999;
	margin-bottom: 4px;
}

.ecs-sfq-timeline-remark {
	font-size: 14px;
	color: #333;
	line-height: 1.5;
}

.ecs-sfq-timeline-item:first-child .ecs-sfq-timeline-remark {
	font-weight: 600;
	color: #0073aa;
}

.ecs-sfq-timeline-address {
	font-size: 12px;
	color: #999;
	margin-top: 3px;
}

/* ── Cache Info ── */
.ecs-sfq-cache-info {
	margin-top: 10px;
}

.ecs-sfq-cache-info small {
	color: #888;
	font-size: 12px;
}

.ecs-sfq-cache-note {
	margin-top: 10px;
	padding: 8px 12px;
	border-radius: 4px;
	font-size: 12px;
	color: #666;
}

.ecs-sfq-cache-note.ecs-sfq-live {
	background: #edf7ed;
	border-left: 3px solid #46b450;
}

.ecs-sfq-cache-note.ecs-sfq-cached {
	background: #fff8e5;
	border-left: 3px solid #ffb900;
}

.ecs-sfq-cache-note.ecs-sfq-stale {
	background: #fbeaea;
	border-left: 3px solid #dc3232;
}

/* ── Error ── */
.ecs-sfq-error {
	color: #dc3232;
	font-style: italic;
	padding: 10px 0;
}

/* ── No Data ── */
.ecs-sfq-no-data {
	color: #999;
	font-style: italic;
	padding: 10px 0;
}

/* ── Responsive ── */
@media screen and (max-width: 600px) {
	.ecs-sfq-frontend-tracking {
		padding: 12px;
		margin: 10px 0;
	}

	.ecs-sfq-timeline-item {
		padding-left: 28px;
		padding-bottom: 15px;
	}

	.ecs-sfq-timeline-remark {
		font-size: 13px;
	}

	.ecs-sfq-timeline-time {
		font-size: 11px;
	}
}
