/**
 * Advanced Order Tracking — Frontend Tracking Form
 */

.aot-tracking-form-wrapper {
  max-width: 600px;
  margin: 0 auto;
}

.aot-tracking-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 16px;
  border-bottom: 2px solid #e2e8f0;
}

.aot-tab {
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  color: #64748b;
  background: none;
  border: none;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all 0.2s;
}

.aot-tab:hover {
  color: #2563eb;
}

.aot-tab--active {
  color: #2563eb;
  border-bottom-color: #2563eb;
  font-weight: 600;
}

.aot-input {
  display: block;
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 15px;
  margin-bottom: 10px;
  box-sizing: border-box;
  transition: border-color 0.2s;
}

.aot-input:focus {
  border-color: #2563eb;
  outline: none;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.aot-submit-btn {
  display: block;
  width: 100%;
  padding: 12px;
  background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.aot-submit-btn:hover {
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
  transform: translateY(-1px);
}

/* Results */

.aot-loading {
  text-align: center;
  padding: 20px;
  color: #64748b;
  font-size: 14px;
}

.aot-error {
  text-align: center;
  padding: 16px;
  background: #fef2f2;
  color: #dc2626;
  border-radius: 8px;
  font-size: 14px;
  margin-top: 16px;
}

.aot-result-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 20px;
  margin-top: 16px;
}

.aot-result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.aot-result-courier {
  font-size: 16px;
  font-weight: 600;
  color: #1e293b;
}

.aot-result-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.aot-result-badge--delivered { background: #f0fdf4; color: #16a34a; }
.aot-result-badge--in_transit,
.aot-result-badge--out_for_delivery { background: #fff7ed; color: #ea580c; }
.aot-result-badge--returned { background: #fef2f2; color: #dc2626; }
.aot-result-badge--created,
.aot-result-badge--printed { background: #eff6ff; color: #2563eb; }
.aot-result-badge--pending,
.aot-result-badge--cancelled { background: #f1f5f9; color: #64748b; }

.aot-result-tracking,
.aot-result-delivery,
.aot-result-date {
  padding: 6px 0;
  font-size: 14px;
  color: #475569;
  border-bottom: 1px solid #f1f5f9;
}

.aot-result-label {
  color: #94a3b8;
  font-size: 12px;
}

.aot-result-tracking code {
  font-size: 15px;
  font-weight: 600;
  color: #2563eb;
}

/* Timeline */

.aot-timeline {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid #e2e8f0;
}

.aot-timeline-title {
  font-size: 13px;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.aot-timeline-item {
  display: flex;
  gap: 12px;
  padding: 8px 0;
  position: relative;
}

.aot-timeline-item:not(:last-child)::before {
  content: '';
  position: absolute;
  left: 5px;
  top: 20px;
  bottom: -8px;
  width: 2px;
  background: #e2e8f0;
}

.aot-timeline-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #2563eb;
  flex-shrink: 0;
  margin-top: 4px;
}

.aot-timeline-date {
  font-size: 11px;
  color: #94a3b8;
}

.aot-timeline-text {
  font-size: 13px;
  color: #475569;
}

/* Link */

.aot-result-link {
  margin-top: 16px;
  text-align: center;
}

.aot-track-btn {
  display: inline-block;
  padding: 10px 24px;
  background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
  color: #fff !important;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none !important;
  transition: all 0.2s;
}

.aot-track-btn:hover {
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
  transform: translateY(-1px);
}
